:root {
    /* Color Palette */
    --bg-deep: #0f0f0f;
    --sidebar-bg: #181818;
    --text-primary: #ffffff;
    --text-dim: #808080;
    --border-color: #2d2d2d;
    --accent-green: #9ef61d;
    --rainbow-grad: linear-gradient(90deg, #9ef61d, #1ca263, #9ef61d);
    
    /* Layout Constants */
    --sidebar-width: 200px;
    --sidebar-collapsed: 60px;
}

/* --- BASE STYLES --- */
body {
    margin: 0;
    background-color: var(--bg-deep);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    display: flex;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* --- SIDEBAR --- */
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border-color);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), left 0.3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.sidebar.collapsed { width: var(--sidebar-collapsed); }

.sidebar-header { 
    width: var(--sidebar-collapsed); 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    padding-top: 20px; 
    gap: 15px; 
}

.home-img { 
    width: 24px; 
    height: 24px; 
    object-fit: contain; 
    transition: transform 0.2s ease;
}

.home-link:hover .home-img { transform: scale(1.1); }

.nav-links { padding: 0; margin: 0; display: flex; flex-direction: column; list-style: none; }

.nav-item { 
    display: flex; 
    align-items: center; 
    height: 48px; 
    text-decoration: none; 
    color: var(--text-dim); 
    position: relative; 
    width: 100%; 
}

.nav-item .material-icons-outlined { 
    min-width: var(--sidebar-collapsed); 
    display: flex; 
    justify-content: center; 
    font-size: 20px; 
}

.link-text { opacity: 1; font-size: 0.9rem; white-space: nowrap; transition: opacity 0.2s; }
.sidebar.collapsed .link-text { opacity: 0; visibility: hidden; }

.nav-item:hover, .nav-item.active { background: #1f1f1f; color: #fff; }

.nav-item::after { 
    content: ""; 
    position: absolute; 
    bottom: 0; left: 10%; 
    width: 0; height: 1px; 
    background: var(--rainbow-grad); 
    background-size: 200%; 
    transition: width 0.3s ease; 
}

.nav-item:hover::after, .nav-item.active::after { width: 80%; }
.nav-item:hover::after { animation: flow 3s linear infinite; }

@keyframes flow { 0% { background-position: 0% 50%; } 100% { background-position: 200% 50%; } }

/* --- MAIN LAYOUT --- */
.main-content { flex-grow: 1; display: flex; flex-direction: column; min-width: 0; }
.content-wrapper { flex: 1; padding: 40px; max-width: 1100px; margin: 0 auto; width: 100%; box-sizing: border-box; }

.top-bar { margin-top: 40px; margin-bottom: 10px; }
.main-logo-img { height: 28px; width: auto; filter: brightness(1.1); }

/* --- HERO & LOCAL CORE --- */
.hero-section { margin-bottom: 80px; }
.hero-title { font-size: 3.5rem; font-weight: 700; letter-spacing: -1.5px; line-height: 1.1; margin: 0; }
.hero-subtitle { font-size: 1.2rem; color: var(--text-dim); max-width: 600px; margin-top: 20px; }

.local-core { margin-bottom: 80px; padding: 40px; background: rgba(158, 246, 29, 0.02); border: 1px solid var(--border-color); }
.local-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.local-text h3 { font-size: 1.8rem; margin: 10px 0 20px 0; color: #fff; }
.local-text p strong { color: var(--accent-green); }

.consultation-card { 
    background: var(--bg-deep); 
    border: 1px solid var(--accent-green); 
    padding: 30px; 
    display: flex; 
    gap: 20px; 
}
.consultation-card .material-icons-outlined { color: var(--accent-green); }

/* --- SERVICES & PROCESS --- */
.content-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; margin-bottom: 100px; }
.service-card { background: var(--sidebar-bg); border: 1px solid var(--border-color); padding: 40px; transition: border-color 0.3s ease; }
.service-card:hover { border-color: var(--accent-green); }
.service-card .material-icons-outlined { color: var(--accent-green); margin-bottom: 20px; font-size: 28px; }

.section-label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 3px; color: var(--accent-green); margin-bottom: 20px; display: block; }

.process-stepper { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 30px; }
.process-card { background: var(--sidebar-bg); border: 1px solid var(--border-color); padding: 35px; transition: 0.3s; }
.process-card:hover { border-color: var(--accent-green); transform: translateY(-3px); }
.step-header .material-icons-outlined { color: var(--accent-green); font-size: 32px; }
.step-number { font-family: monospace; color: var(--accent-green); opacity: 0.4; font-weight: 700; }

/* --- BUTTONS --- */
.cta-group { display: flex; gap: 15px; }

.btn-primary, .btn-secondary { 
    padding: 12px 24px; 
    text-decoration: none; 
    font-weight: 600; 
    font-size: 0.9rem; 
    border-radius: 4px; 
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease; 
    display: inline-block; 
}

.btn-primary { background: var(--accent-green); color: #000; border: 1px solid var(--accent-green); }
.btn-primary:hover { box-shadow: 0 0 20px rgba(158, 246, 29, 0.4); transform: translateY(-1px); }

.btn-secondary { border: 1px solid var(--border-color); color: var(--text-primary); }
.btn-secondary:hover { background: #1f1f1f; transform: translateY(-1px); }

/* --- HYPE SECTION --- */
.hype-section { margin-top: 80px; padding: 50px 30px; background: #111; border: 1px solid var(--border-color); text-align: center; }
.hype-content h2 { font-size: 2rem; margin-bottom: 12px; letter-spacing: -1px; }
.hype-content p { font-size: 0.95rem; color: var(--text-dim); max-width: 550px; margin: 0 auto 25px auto; line-height: 1.6; }

.btn-grand {
    padding: 12px 32px;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: var(--accent-green);
    color: #000;
    border: 1px solid var(--accent-green);
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    backface-visibility: hidden;
}

.btn-grand:hover { transform: translateY(-1px); box-shadow: 0 0 20px rgba(158, 246, 29, 0.4); }

/* --- FOOTER --- */
.main-footer { padding: 40px; font-size: 0.75rem; color: #444; border-top: 1px solid var(--border-color); text-align: center; }

.menu-btn { background: none; border: none; color: var(--text-dim); cursor: pointer; padding: 8px; border-radius: 50%; display: flex; outline: none; transition: 0.2s; }
.menu-btn:hover { background: #252525; color: #fff; }

/* --- ABOUT & CONTACT --- */
.story-text h3 { font-size: 2rem; margin: 10px 0 20px 0; }
.story-text p { color: var(--text-dim); line-height: 1.8; max-width: 800px; margin-bottom: 20px; font-size: 1.05rem; }
.story-text strong { color: var(--accent-green); }

.values-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; margin-bottom: 100px; }
.value-item { border-left: 1px solid var(--accent-green); padding-left: 25px; }
.value-item h4 { font-family: monospace; font-size: 0.9rem; color: var(--accent-green); margin-bottom: 15px; text-transform: uppercase; }
.value-item p { color: var(--text-dim); font-size: 0.95rem; line-height: 1.6; }

.tech-stack-preview { text-align: center; padding: 60px 20px; background: rgba(255, 255, 255, 0.02); border: 1px solid var(--border-color); margin-bottom: 80px; }
.tech-stack-preview h3 { font-size: 1.2rem; margin-bottom: 30px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 2px; }
.stack-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 15px; }
.stack-tags span { background: var(--sidebar-bg); border: 1px solid var(--border-color); padding: 8px 20px; border-radius: 20px; font-size: 0.85rem; color: var(--text-primary); transition: 0.3s; }
.stack-tags span:hover { border-color: var(--accent-green); }

.contact-layout { display: grid; grid-template-columns: 1fr 1.5fr; gap: 80px; margin-top: 40px; }
.info-block { display: flex; gap: 20px; margin-bottom: 40px; align-items: flex-start; }
.info-block .material-icons-outlined { color: var(--accent-green); font-size: 24px; margin-top: 4px; }
.info-block h4 { margin: 0 0 5px 0; font-size: 1rem; color: #fff; }
.info-block p { color: var(--text-dim); font-size: 0.95rem; line-height: 1.5; }

.frontier-form { display: flex; flex-direction: column; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-group label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-dim); }
.form-group input, .form-group select, .form-group textarea {
    background: #181818; border: 1px solid var(--border-color); padding: 12px 16px; color: #fff; font-family: inherit; font-size: 0.95rem; border-radius: 4px; transition: 0.2s; outline: none;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--accent-green); box-shadow: 0 0 10px rgba(158, 246, 29, 0.1); }
.form-group select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23808080' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; padding-right: 40px; }

/* --- MOBILE & TABLET REFINEMENTS --- */
@media (max-width: 850px) {
    /* Navbar Overlay Logic */
    .sidebar {
        position: fixed;
        left: -100%; /* Hide off-screen by default */
        width: 240px !important;
        height: 100vh;
        background: var(--sidebar-bg);
        box-shadow: none;
    }

    /* Class to be added via JS */
    .sidebar.mobile-open {
        left: 0;
        box-shadow: 20px 0 50px rgba(0, 0, 0, 0.9);
    }

    .sidebar-header {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        padding: 20px;
    }

    /* Pull text back in for mobile drawer */
    .sidebar.mobile-open .link-text {
        opacity: 1;
        visibility: visible;
    }

    /* Main Content Spacing */
    .content-wrapper {
        padding: 40px 20px;
    }

    /* Fix the "Proximity Matters" weirdness */
    .local-core {
        padding: 30px 20px;
    }

    .local-grid {
        grid-template-columns: 1fr; /* Stack vertically */
        gap: 30px;
    }

    .consultation-card {
        flex-direction: column; /* Stack icon on top of text */
        text-align: center;
        align-items: center;
        gap: 15px;
    }

    /* General Typography Scaling */
    .hero-title {
        font-size: 2.6rem;
        letter-spacing: -1px;
    }

    .cta-group {
        flex-direction: column;
        width: 100%;
    }

    .btn-primary, .btn-secondary {
        width: 100%;
        text-align: center;
        box-sizing: border-box;
    }

    .contact-layout {
        grid-template-columns: 1fr;
        gap: 60px;
    }
}

@media (max-width: 480px) {
    .hero-title { font-size: 2.2rem; }
}
/* Hide mobile trigger on desktop */
.mobile-menu-trigger {
    display: none;
}

@media (max-width: 850px) {
    .mobile-menu-trigger {
        display: flex;
        position: fixed;
        top: 20px;
        left: 20px;
        z-index: 999; /* Below the open sidebar, but above everything else */
        background: var(--sidebar-bg);
        border: 1px solid var(--border-color);
        color: var(--accent-green);
        padding: 10px;
        border-radius: 4px;
        cursor: pointer;
        transition: 0.2s;
    }

    .mobile-menu-trigger:active {
        transform: scale(0.95);
        background: #252525;
    }

    /* Shift content down slightly so the logo doesn't hit the button */
    .top-bar {
        margin-top: 70px; 
    }
    .sidebar-header {
        width: 100% !important; /* Force it to expand */
        flex-direction: row !important; /* Icons side-by-side */
        justify-content: space-between; /* Logo left, Button right */
        padding: 20px !important; /* Give the button breathing room */
        box-sizing: border-box;
    }

    /* Make sure the internal toggle button is fully visible */
    #toggle-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        margin-right: 0; /* Remove any desktop offsets */
    }
}