/* =========================================
   1. HEADER CORE & SCROLL TRANSITIONS
   ========================================= */
#main-header {
    position: fixed; 
    /* Hamesha center align rakhne ke liye base rules */
    left: 0;
    right: 0;
    margin-left: auto;
    margin-right: auto;
    z-index: 999; /* Taake content ke upar rahe */
    
    /* Smooth transition */
    transition: width 0.3s ease, top 0.3s ease, border-radius 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease, border-color 0.3s ease;
}

.header-initial {
    width: 100%;
    max-width: 100%; /* Initial state mein poori screen cover kare */
    top: 0;
    border-color: transparent;
    border-radius: 0;
    box-shadow: none;
    padding-left: 64px; 
    padding-right: 64px;
}

@media (max-width: 768px) {
    .header-initial {
        padding-left: 16px; 
        padding-right: 16px;
    }
}

.header-scrolled {
    width: 95%;
    max-width: 1440px; /* Scrolled state mein box layout ban jaye */
    top: 16px;
    border-radius: 1rem; 
    border-color: rgba(70, 70, 74, 0.2); 
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(12px);
    padding-left: 2rem;
    padding-right: 2rem;
}



/* =========================================
   2. GLASS PANEL & MISC
   ========================================= */
.backdrop-blur-md {
    max-width: 100% !important;
}

.glass-panel {
    background: rgba(23, 23, 25, 0.4);
    backdrop-filter: blur(12px);
    border: 1px solid #46464a; /* Fallback color (Original theme variable) */
    box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
}



/* =========================================
   4. MOBILE MENU
   ========================================= */
.mobile-menu {
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
}

.mobile-menu.open {
    transform: translateX(0);
}

body.menu-open {
    overflow: hidden;
}

.mobile-submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.mobile-submenu.open {
    max-height: 2000px;
}

/* =========================================
   5. WORDPRESS ADMIN BAR FIXES (from SECOND FILE)
   ========================================= */
.admin-bar #main-header.header-initial { top: 32px; }
.admin-bar #main-header.header-scrolled { top: 48px; }

@media screen and (max-width: 782px) {
    .admin-bar #main-header.header-initial { top: 46px; }
    .admin-bar #main-header.header-scrolled { top: 58px; }
}

.admin-bar .mobile-menu { top: 32px; }

@media screen and (max-width: 782px) { 
    .admin-bar .mobile-menu { top: 46px; } 
}

#main-header nav, #main-header div, #main-header a { 
    box-shadow: none; 
}

/* =========================================
   6. HEADER BUTTONS (SHINY CTA)
   ========================================= */
.shiny-btn {
    --shiny-cta-highlight: #5b21b6;
    --shiny-cta-highlight-subtle: #00b0f4;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 32px;
    border-radius: 12px;
    font-weight: 700;
    color: #fff;
    background: rgba(23, 23, 25, 0.8);
    overflow: hidden;
    transition: all 0.3s ease;
    z-index: 1;
    text-decoration: none;
}

.shiny-btn-primary {
    background: var(--shiny-cta-highlight);
}

.shiny-btn::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 14px;
    background: conic-gradient(
        from 90deg at 50% 50%,
        transparent 0%,
        #a78bfa 50%,
        transparent 100%
    );
    z-index: -2;
    animation: rotate-border 4s linear infinite;
}

.shiny-btn::after {
    content: '';
    position: absolute;
    inset: 2px;
    border-radius: 10px;
    background: inherit;
    z-index: -1;
}

.shiny-btn-shimmer {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transform: translateX(-100%);
    animation: shimmer 3s infinite;
}

.shiny-btn .content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 8px;
}

@keyframes rotate-border {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}
/* =========================================
   3. MEGA MENU (DESKTOP) - CLEAN & WORKING
   ========================================= */

/* Container - Full viewport width, no cutoff */
/* Container: hamesha rendered, sirf visibility se hide/show (taake delay lag sake) */
.mega-menu-container {
    display: block !important;
    position: fixed !important;
    top: 100% !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 50;

    visibility: hidden;
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none !important; /* container ki full-width strip clicks block na kare */

    /* band hone mein 0.3s ka grace time */
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0.3s;
}

/* Show on hover / keyboard focus */
.nav-item-services:hover .mega-menu-container,
.nav-item-services:focus-within .mega-menu-container {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0s;
}

/* Panel asli clickable area hai */
.mega-menu-panel {
    pointer-events: auto !important;
}

/* HOVER BRIDGE: button aur panel ke beech ka gap cover karta hai */
.nav-item-services::after {
    content: '';
    position: absolute;
    top: 100%;
    left: -60px;
    right: -60px;
    height: 90px;
    pointer-events: none;
}
.nav-item-services:hover::after {
    pointer-events: auto;
}

@keyframes megaSlideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Panel - Centered with max-width */
.mega-menu-panel {
    max-width: 1400px;
    margin: 0 auto;
    background: linear-gradient(180deg, rgba(13, 11, 26, 0.98) 0%, rgba(10, 1, 24, 0.98) 100%);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
    pointer-events: auto;
}

/* Icon boxes */
.mega-icon-box {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}

.nav-item-services:hover .mega-icon-box {
    background: rgba(0, 176, 244, 0.1);
    border-color: rgba(0, 176, 244, 0.3);
}

/* Links */
.mega-link {
    transition: all 0.2s ease;
}

.mega-link:hover {
    padding-left: 4px;
}

.mega-link svg {
    transition: transform 0.2s ease;
}

.mega-link:hover svg {
    transform: translateX(3px);
}

/* Bottom bar */
.mega-bottom-bar {
    animation: megaFadeIn 0.4s ease-out 0.1s both;
}

@keyframes megaFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* View All button */
.mega-view-all {
    transition: all 0.3s ease;
}

.mega-view-all:hover {
    background: #00b0f4;
    border-color: #00b0f4;
    transform: translateX(2px);
}

/* Let's Talk icon */
.lets-talk-btn svg {
    transition: transform 0.3s ease;
}

.lets-talk-btn:hover svg {
    transform: scale(1.1);
}

/* Prevent text overflow */
.mega-group-title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mega-link span:first-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Responsive columns */
@media (max-width: 1280px) {
    .mega-menu-panel .grid {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

@media (max-width: 1024px) {
    .mega-menu-panel .grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 768px) {
    .mega-menu-panel .grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}
/* =========================================
   BLINKING DOT - Let's Talk Button
   ========================================= */
.blinking-dot {
    position: relative;
    display: inline-block;
    width: 4px;
    height: 4px;
    background: #00B0F4;
    border-radius: 50%;
    flex-shrink: 0;
    margin-right: 4px;
    top: -7px;
    left: 17px;
}

.blinking-dot::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: #00B0F4;
    opacity: 0.6;
    animation: blinkPulse 2s ease-in-out infinite;
}

.blinking-dot::after {
    content: '';
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: #00B0F4;
    opacity: 0.3;
    animation: blinkPulse 2s ease-in-out infinite 0.3s;
}

@keyframes blinkPulse {
    0%, 100% { transform: scale(1); opacity: 0.6; }
    50% { transform: scale(1.5); opacity: 0; }
}
.lets-talk-btn {
    color: #fff !important;
}
/* =========================================
   OFFER POPUP - Premium Overlay
   ========================================= */
.offer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(5, 2, 15, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
}

.offer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.offer-popup {
    position: relative;
    background: linear-gradient(145deg, rgba(21, 10, 46, 0.98), rgba(10, 1, 24, 0.98));
    border: 1px solid rgba(0, 176, 244, 0.25);
    border-radius: 24px;
    padding: 44px 36px;
    max-width: 460px;
    width: 100%;
    box-shadow: 
        0 25px 60px -12px rgba(0, 0, 0, 0.7),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        0 0 100px -20px rgba(0, 176, 244, 0.35);
    transform: scale(0.92) translateY(20px);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

.offer-overlay.active .offer-popup {
    transform: scale(1) translateY(0);
}

.offer-popup::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 20%, rgba(0, 176, 244, 0.12) 0%, transparent 50%);
    pointer-events: none;
}

.offer-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #9CA3AF;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    font-size: 17px;
    padding: 0;
    line-height: 1;
}

.offer-close:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    transform: rotate(90deg);
}

/* Offer Badge */
.offer-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(0, 176, 244, 0.1);
    border: 1px solid rgba(0, 176, 244, 0.3);
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: #00B0F4;
    margin-bottom: 18px;
    text-transform: uppercase;
}

.offer-badge-dot {
    width: 6px;
    height: 6px;
    background: #00B0F4;
    border-radius: 50%;
    animation: blinkPulse 1.5s ease-in-out infinite;
}

/* Title */
.offer-title {
    font-family: 'Nike Futura ND', Arial, sans-serif;
    font-size: 26px;
    font-weight: 800;
    line-height: 1.2;
    color: #fff;
    margin: 0 0 10px 0;
    letter-spacing: -0.02em;
    text-transform: uppercase;
}

.offer-highlight {
    background: linear-gradient(90deg, #00B0F4 0%, #02C0E4 50%, #67D4FF 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.offer-subtitle {
    font-size: 14px;
    line-height: 1.6;
    color: #9CA3AF;
    margin: 0 0 24px 0;
}

/* Email Form */
.offer-email-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.offer-input-wrap {
    position: relative;
}

.offer-input-wrap svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #6B7280;
    pointer-events: none;
}

.offer-input {
    width: 100%;
    padding: 13px 14px 13px 42px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.offer-input:focus {
    border-color: #00B0F4;
    background: rgba(0, 176, 244, 0.05);
    box-shadow: 0 0 0 3px rgba(0, 176, 244, 0.1);
}

.offer-input::placeholder {
    color: #6B7280;
}

.offer-msg {
    font-size: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    display: none;
}

.offer-msg.error {
    display: block;
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.3);
    color: #F87171;
}

.offer-msg.success {
    display: block;
    background: rgba(0, 182, 122, 0.1);
    border: 1px solid rgba(0, 182, 122, 0.3);
    color: #00B67A;
}

.offer-btn {
    width: 100%;
    padding: 13px 22px;
    background: linear-gradient(90deg, #00B0F4 0%, #02C0E4 100%);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    font-family: 'Nike Futura ND', Arial, sans-serif;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.offer-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px -5px rgba(0, 176, 244, 0.5);
}

.offer-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Coupon Box */
.offer-coupon-box {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px;
    background: rgba(0, 176, 244, 0.08);
    border: 2px dashed rgba(0, 176, 244, 0.4);
    border-radius: 12px;
    margin: 18px 0;
}

.offer-coupon-code {
    flex: 1;
    font-family: 'JetBrains Mono', monospace;
    font-size: 20px;
    font-weight: 700;
    color: #00B0F4;
    letter-spacing: 2px;
    text-align: center;
}

.offer-copy-btn {
    padding: 7px 12px;
    background: rgba(0, 176, 244, 0.15);
    border: 1px solid rgba(0, 176, 244, 0.3);
    border-radius: 8px;
    color: #00B0F4;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.offer-copy-btn:hover {
    background: rgba(0, 176, 244, 0.25);
}

.offer-copy-btn.copied {
    background: rgba(0, 182, 122, 0.2);
    border-color: rgba(0, 182, 122, 0.4);
    color: #00B67A;
}

/* Success/Existing Icon */
.offer-icon-circle {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
}

.offer-icon-circle.success {
    background: linear-gradient(135deg, rgba(0, 182, 122, 0.2), rgba(0, 176, 244, 0.2));
    border: 2px solid rgba(0, 182, 122, 0.4);
    color: #00B67A;
}

.offer-icon-circle.existing {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(217, 70, 239, 0.2));
    border: 2px solid rgba(139, 92, 246, 0.4);
    color: #A78BFA;
}

.offer-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 13px 22px;
    background: linear-gradient(90deg, #00B0F4 0%, #02C0E4 100%);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    font-family: 'Nike Futura ND', Arial, sans-serif;
    letter-spacing: 0.5px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    margin-top: 10px;
}

.offer-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px -5px rgba(0, 176, 244, 0.5);
    color: #fff;
}

/* State transitions */
.offer-state {
    position: relative;
    z-index: 1;
    animation: fadeSlideIn 0.4s ease;
}

.offer-state.hidden {
    display: none !important;
}

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Spinner */
.offer-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 640px) {
    .offer-popup {
        padding: 30px 22px;
    }
    .offer-title {
        font-size: 22px;
    }
}