/* ============================================================
   HARISHYA PREMIUM HEADER & NAVIGATION BAR
   File: css/header.css
   ============================================================ */

/* ==========================================
   1. HEADER FOUNDATION & GLASSMORPHISM
   ========================================== */
.header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(7, 16, 29, 0.88);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

[data-theme="light"] .header {
    background: rgba(255, 255, 255, 0.90) !important;
    border-bottom: 1px solid rgba(11, 79, 138, 0.12) !important;
    box-shadow: 0 10px 30px rgba(11, 79, 138, 0.08) !important;
}

/* Ambient Top Glowing Gradient Line */
.header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2.5px;
    background: linear-gradient(90deg, #0b4f8a, #38bdf8, #f47b0b, #38bdf8, #0b4f8a);
    background-size: 200% 100%;
    animation: headerGrad 8s linear infinite;
    z-index: 2;
}

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

.nav {
    min-height: var(--header-height, 78px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

/* ==========================================
   2. COMPANY BRAND (MATCHING FOOTER SHINE)
   ========================================== */
.company-brand {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    height: 64px;
    flex-shrink: 0;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.brand-logo {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    flex-shrink: 0;
}

.brand-logo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.35s ease, filter 0.35s ease;
}

.company-brand:hover .brand-logo img {
    transform: scale(1.08);
    filter: drop-shadow(0 4px 12px rgba(41, 182, 246, 0.35));
}

.company-name {
    display: flex;
    flex-direction: column;
    justify-content: center;
    line-height: 1;
    overflow: hidden;
}

/* Dark Mode Brand Shine (Identical to Footer) */
.brand-main-name {
    font-family: "Poppins", "Montserrat", Arial, sans-serif;
    font-size: 24px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 2px;
    background: linear-gradient(90deg, #ffffff 0%, #ffffff 40%, #63a4ff 50%, #ffffff 60%, #ffffff 100%);
    background-size: 220% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: background-position 0.6s ease;
    white-space: nowrap;
}

.company-brand:hover .brand-main-name {
    background-position: 100% center;
}

.brand-sub-name {
    margin-top: 3px;
    font-family: "Poppins", "Montserrat", Arial, sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2.5px;
    color: #ff9a2f;
    white-space: nowrap;
    transition: letter-spacing 0.3s ease;
}

.company-brand:hover .brand-sub-name {
    letter-spacing: 3.5px;
}

.brand-tagline {
    margin-top: 4px;
    font-family: "Open Sans", Arial, sans-serif;
    font-size: 8px;
    font-weight: 600;
    letter-spacing: 1.6px;
    color: #aebdca;
    white-space: nowrap;
}

/* Light Theme Brand Colors */
[data-theme="light"] .brand-main-name {
    background: linear-gradient(90deg, #0b4f8a 0%, #0b4f8a 40%, #0284c7 50%, #0b4f8a 60%, #0b4f8a 100%);
    background-size: 220% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
[data-theme="light"] .brand-sub-name {
    color: #f47b0b;
}
[data-theme="light"] .brand-tagline {
    color: #64748b;
}

/* Small Premium Brand Accent Line */
.company-name::after {
    content: "";
    width: 0;
    height: 2px;
    margin-top: 4px;
    border-radius: 20px;
    background: linear-gradient(90deg, #0b4f8a, #f47b0b);
    transition: width 0.35s ease;
}
.company-brand:hover .company-name::after {
    width: 45px;
}

/* ==========================================
   3. DESKTOP NAVIGATION LINKS
   ========================================== */
.nav-links {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}

.nav-links a {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 8px 14px;
    color: var(--muted);
    border-radius: 12px;
    font-size: 0.94rem;
    font-weight: 650;
    text-decoration: none;
    transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.nav-links a:hover {
    color: var(--text);
    background: rgba(41, 182, 246, 0.08);
    transform: translateY(-1px);
}

.nav-links a.active {
    color: var(--primary);
    background: rgba(41, 182, 246, 0.12);
    font-weight: 750;
}

.nav-links a::after {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 3px;
    height: 2.5px;
    border-radius: 10px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transition: transform 0.25s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    transform: scaleX(1);
}

/* ==========================================
   4. NAVIGATION ACTIONS GROUP
   ========================================== */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

/* ==========================================
   5. CELESTIAL THEME BUTTON (SUN & MOON)
   ========================================== */
.celestial-toggle, #themeToggle {
    position: relative;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: linear-gradient(145deg, var(--surface2), var(--surface));
    border: 1px solid var(--line);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: hidden;
}

.celestial-toggle:hover, #themeToggle:hover {
    transform: translateY(-2px) scale(1.05);
    border-color: rgba(245, 158, 11, 0.6);
    box-shadow: 0 8px 24px rgba(245, 158, 11, 0.28);
}

[data-theme="light"] .celestial-toggle, [data-theme="light"] #themeToggle {
    background: linear-gradient(145deg, #ffffff, #f1f5f9);
    border-color: rgba(245, 158, 11, 0.35);
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.12);
}

[data-theme="light"] .celestial-toggle:hover, [data-theme="light"] #themeToggle:hover {
    border-color: #f59e0b;
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.35);
}

.theme-icon-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    pointer-events: none;
}

.theme-icon-wrap svg {
    width: 24px;
    height: 24px;
    display: block;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.3));
}

/* ==========================================
   6. VIBRANT LANGUAGE BUTTON (CLEAN PILL BADGE)
   ========================================== */
.lang-glow-btn, #langToggle {
    min-height: 42px !important;
    padding: 0 16px !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    cursor: pointer;
    background: linear-gradient(145deg, var(--surface2), var(--surface));
    border: 1px solid var(--line);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    color: var(--text);
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-weight: 700;
}

.lang-glow-btn:hover, #langToggle:hover {
    transform: translateY(-2px) scale(1.05);
    border-color: rgba(56, 189, 248, 0.6);
    box-shadow: 0 8px 24px rgba(56, 189, 248, 0.25);
}

[data-theme="light"] .lang-glow-btn, [data-theme="light"] #langToggle {
    background: linear-gradient(145deg, #ffffff, #f1f5f9);
    border-color: rgba(11, 79, 138, 0.25);
    box-shadow: 0 4px 15px rgba(11, 79, 138, 0.08);
}

[data-theme="light"] .lang-glow-btn:hover, [data-theme="light"] #langToggle:hover {
    border-color: #0b4f8a;
    box-shadow: 0 8px 25px rgba(11, 79, 138, 0.22);
}

.lang-text-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.96rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    color: var(--primary-2);
}

[data-theme="light"] .lang-text-badge {
    color: #0b4f8a;
}

/* ==========================================
   7. RESPONSIVE BREAKPOINTS
   ========================================== */
.mobile-only, .nav-toggle, #menuToggle { 
    display: none !important; 
}

@media (max-width: 991px) {
    .nav-links { 
        display: none !important; 
    } 
    .mobile-only, .nav-toggle, #menuToggle { 
        display: inline-flex !important; 
    } 
}

@media (max-width: 768px) {
    .company-brand {
        height: 56px;
        gap: 8px;
    }
    .brand-logo {
        width: 46px;
        height: 46px;
    }
    .brand-main-name {
        font-size: 19px;
        letter-spacing: 1.5px;
    }
    .brand-sub-name {
        font-size: 10px;
        letter-spacing: 2px;
    }
    .brand-tagline {
        font-size: 6.5px;
        letter-spacing: 1.2px;
    }
}

@media (max-width: 420px) {
    .company-brand {
        gap: 6px;
    }
    .brand-logo {
        width: 40px;
        height: 40px;
    }
    .brand-main-name {
        font-size: 16px;
        letter-spacing: 1px;
    }
    .brand-sub-name {
        font-size: 8.5px;
        letter-spacing: 1.5px;
    }
    .brand-tagline {
        font-size: 5.5px;
    }
}