/* =============================================
   HEADER — Apple-Style Floating Glass Nav 2026
   ============================================= */

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 14px 24px 0;
    pointer-events: none;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0.6rem 0.6rem 0.6rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0;
    background: rgba(10, 10, 10, 0.62);
    backdrop-filter: blur(40px) saturate(200%);
    -webkit-backdrop-filter: blur(40px) saturate(200%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 100px;
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.2),
                0 0 0 0.5px rgba(255, 255, 255, 0.05) inset;
    pointer-events: all;
    transition: background 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.header.scrolled .nav-container {
    background: rgba(10, 10, 10, 0.88);
    box-shadow: 0 8px 48px rgba(0, 0, 0, 0.35),
                0 0 0 0.5px rgba(255, 255, 255, 0.06) inset;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Logo */
.logo, .mobile-logo {
    text-decoration: none;
    display: flex;
    align-items: baseline;
    gap: 1px;
    font-weight: 800;
    letter-spacing: -0.03em;
    flex-shrink: 0;
    margin-right: auto;
}

.logo-main {
    font-size: 1.5rem;
    color: #ffffff;
    transition: opacity 0.2s;
}

.logo:hover .logo-main {
    opacity: 0.85;
}

.logo-domain {
    font-size: 1.15rem;
    color: #A78BFA;
    font-weight: 700;
}

/* Nav Links */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 4px;
    margin: 0;
    padding: 0;
    margin-right: 0.6rem;
}

.nav-link {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 1.1rem;
    border-radius: 100px;
    position: relative;
    transition: color 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                background 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: block;
    white-space: nowrap;
    letter-spacing: -0.01em;
}

.nav-link::after {
    display: none;
}

.nav-link:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.nav-link.active {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
}

/* CTA Button */
.btn-header-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.6rem 1.4rem;
    background: linear-gradient(135deg, #A78BFA 0%, #7C3AED 100%);
    color: #fff;
    border-radius: 100px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 12px rgba(167, 139, 250, 0.25);
}

.btn-header-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-header-cta:hover::before {
    left: 100%;
}

.btn-header-cta:hover {
    transform: translateY(-1px) scale(1.03);
    box-shadow: 0 6px 28px rgba(167, 139, 250, 0.5);
}

.btn-header-cta i {
    font-size: 0.7rem;
    transition: transform 0.2s;
}

.btn-header-cta:hover i {
    transform: translateX(3px);
}

/* =============================================
   MOBILE MENU TOGGLE
   ============================================= */

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
    margin-left: auto;
}

.hamburger-line {
    width: 20px;
    height: 2px;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 2px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-menu-toggle.active .hamburger-line:nth-child(2) { opacity: 0; }
.mobile-menu-toggle.active .hamburger-line:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* =============================================
   MOBILE MENU OVERLAY + PANEL
   ============================================= */

.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    pointer-events: all;
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

.mobile-menu {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: min(360px, 90vw);
    max-height: 85dvh;
    background: rgba(18, 18, 20, 0.7);
    backdrop-filter: blur(60px) saturate(180%);
    -webkit-backdrop-filter: blur(60px) saturate(180%);
    z-index: 999;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                visibility 0.35s;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5),
                0 0 0 1px rgba(255, 255, 255, 0.08) inset;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 28px;
    overflow: hidden;
    pointer-events: all;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

.mobile-menu-header {
    padding: 1.5rem 1.8rem 1rem;
    text-align: center;
}

.mobile-logo {
    justify-content: center;
}

.mobile-nav {
    list-style: none;
    padding: 0.5rem 1rem;
    margin: 0;
    flex: 1;
}

.mobile-nav li {
    opacity: 0;
    transform: translateY(12px) scale(0.97);
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transition-delay: var(--delay, 0s);
}

.mobile-menu.active .mobile-nav li {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.9rem 1rem;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
    font-size: 1.05rem;
    border-radius: 16px;
    transition: background 0.25s, color 0.25s;
}

.mobile-nav-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.mobile-link-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(167, 139, 250, 0.15);
    border-radius: 12px;
    color: #A78BFA;
    font-size: 0.95rem;
}

.mobile-link-text { flex: 1; }
.mobile-link-arrow { color: rgba(255, 255, 255, 0.15); font-size: 0.75rem; }

.mobile-menu-footer {
    padding: 1rem 1.8rem 1.5rem;
}

.btn-mobile-cta {
    display: block;
    text-align: center;
    padding: 0.9rem;
    background: linear-gradient(135deg, #A78BFA 0%, #7C3AED 100%);
    color: #fff;
    border-radius: 16px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.75rem;
    transition: transform 0.25s, box-shadow 0.25s;
    box-shadow: 0 4px 20px rgba(167, 139, 250, 0.25);
}

.btn-mobile-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 28px rgba(167, 139, 250, 0.4);
}

.mobile-menu-contact { text-align: center; margin: 0; }
.mobile-menu-contact a { color: rgba(255, 255, 255, 0.35); text-decoration: none; font-size: 0.85rem; transition: color 0.2s; }
.mobile-menu-contact a:hover { color: #A78BFA; }

/* =============================================
   RESPONSIVE
   ============================================= */

@media (max-width: 768px) {
    .header {
        padding: 8px 12px 0;
    }

    .nav-container {
        padding: 0.5rem 0.75rem 0.5rem 1rem;
        border-radius: 20px;
    }

    .nav-menu,
    .btn-header-cta {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .logo-main { font-size: 1.25rem; }
    .logo-domain { font-size: 0.9rem; }
}

@media (max-width: 480px) {
    .header {
        padding: 6px 8px 0;
    }

    .nav-container {
        border-radius: 16px;
    }

    .mobile-menu {
        width: 92vw;
        border-radius: 24px;
    }

    .logo-main { font-size: 1.35rem; }
    .logo-domain { font-size: 1rem; }

    .mobile-nav-link {
        font-size: 1.15rem;
    }
}

/* Prevent body scroll when menu open */
body.menu-open {
    overflow: hidden;
}

/* Reduced motion */
@media (prefers-reduced-motion: no-preference) {
    .logo,
    .nav-link,
    .btn-header-cta,
    .mobile-nav-link {
        transition-duration: 0.35s;
    }
}

/* Focus states */
.logo:focus-visible,
.nav-link:focus-visible,
.btn-header-cta:focus-visible,
.mobile-menu-toggle:focus-visible {
    outline: 2px solid #A78BFA;
    outline-offset: 4px;
    border-radius: 100px;
}