/**
 * AWB Platform Unified Navigation Bar (.site-nav)
 * Ensures 100% visual consistency across Homepage, Plans/Points, Returns Policy, Legal pages, and Marketing pages.
 */

:root {
    --platform-primary: #4F46E5;
    --platform-accent: #0284C7;
    --platform-gradient: linear-gradient(135deg, #4F46E5 0%, #06B6D4 100%);
    --platform-text: #0F172A;
    --platform-muted: #64748B;
    --platform-line: #E2E8F0;
}

.site-nav {
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 14px 0;
    transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.85);
}

.site-nav.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
    border-bottom-color: #E2E8F0;
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

/* Brand */
.nav-brand {
    font-size: 22px;
    font-weight: 700;
    color: #0F172A;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.nav-brand img,
.nav-brand svg {
    width: 30px;
    height: 30px;
    object-fit: contain;
    flex-shrink: 0;
}

.brand-wrap {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-main {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #0F172A;
}

.brand-sub {
    font-size: 12px;
    font-weight: 500;
    color: #64748B;
    margin-top: 3px;
}

/* Navigation Links */
.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.platform-nav-link {
    color: #475569;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.18s ease, background 0.18s ease;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
}

.platform-nav-link:hover {
    color: #4F46E5;
    background: #EEF2FF;
}

.platform-nav-link.active {
    color: #4F46E5 !important;
    background: #EEF2FF !important;
    font-weight: 600;
}

/* Cart Button */
.nav-cart-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    background: #FFFFFF;
    border: 1px solid #CBD5E1;
    text-decoration: none;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-cart-btn:hover {
    background: #F8FAFC;
    border-color: #94A3B8;
    color: #4F46E5;
}

.nav-cart-btn i {
    font-size: 16px;
    color: #4F46E5;
}

.nav-cart-btn .cart-badge {
    position: absolute;
    top: -7px;
    right: -7px;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: #F59E0B;
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.4);
}

/* Auth Buttons */
.btn-ghost {
    color: #334155 !important;
    border: 1px solid #CBD5E1;
    padding: 8px 20px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    background: #FFFFFF;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.btn-ghost:hover {
    background: #F1F5F9;
    border-color: #94A3B8;
    color: #0F172A !important;
}

.btn-primary-custom {
    background: linear-gradient(135deg, #4F46E5 0%, #06B6D4 100%);
    color: #FFFFFF !important;
    border: none;
    padding: 8px 24px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.btn-primary-custom:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
    color: #FFFFFF !important;
}

/* Responsive */
.nav-mobile-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    border: 1px solid #CBD5E1;
    background: #FFFFFF;
    color: #0F172A;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    flex-shrink: 0;
    padding: 0;
}
.nav-mobile-toggle:focus-visible {
    outline: 2px solid #4F46E5;
    outline-offset: 2px;
}
.platform-mobile-nav {
    border-top: 1px solid #E2E8F0;
    background: #FFFFFF;
}
.platform-mobile-nav-inner {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 16px 16px;
    max-width: 1200px;
    margin: 0 auto;
}
.platform-mobile-nav .platform-nav-link {
    display: flex;
    width: 100%;
    padding: 12px 14px;
    border-radius: 10px;
    white-space: normal;
}
.platform-mobile-nav .platform-nav-link.hide-mobile {
    display: flex !important;
}

.platform-lang-switch {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-right: 4px;
    white-space: nowrap;
}

.platform-lang-link {
    color: #64748B;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    padding: 4px 2px;
    transition: color 0.18s ease;
}

.platform-lang-link:hover {
    color: #4F46E5;
}

.platform-lang-link.is-active {
    color: #4F46E5;
}

.platform-lang-sep {
    color: #CBD5E1;
    font-size: 12px;
    user-select: none;
}

.platform-mobile-lang {
    padding: 12px 8px 4px;
    border-top: 1px solid #E2E8F0;
    margin-top: 8px;
}

@media (max-width: 991px) {
    .nav-links > .platform-lang-switch {
        display: none;
    }
}

@media (max-width: 991px) {
    .platform-nav-link.hide-mobile {
        display: none !important;
    }
    .nav-mobile-toggle {
        display: inline-flex;
    }
    .nav-inner {
        gap: 10px;
        min-width: 0;
    }
    .nav-links {
        flex-shrink: 0;
    }
}

@media (max-width: 768px) {
    .nav-inner {
        padding: 0 16px;
    }
    .brand-sub {
        display: none;
    }
    .nav-cart-btn .nav-cart-text {
        display: none;
    }
    .btn-ghost {
        padding: 8px 14px;
    }
    .btn-primary-custom {
        padding: 8px 16px;
    }
}
