/* ============================================
   Vertex Realty Group - Header & Nav Styles
   Single source of truth — extracted from homepage.
   ============================================ */

        /* TOPBAR */
        .topbar { background: var(--navy); color: #fff; font-size: 0.8rem; letter-spacing: 0.03em; }
        .topbar a.topbar-cta:hover { background: rgba(200,168,98,0.25); border-color: rgba(200,168,98,0.5); color: #fff; }

        /* HEADER */
        .site-header {
            background: rgba(255,255,255,0.97);
            backdrop-filter: blur(12px);
            border-bottom: 1px solid #e8e4dc;
            position: sticky;
            top: 0;
            z-index: 100;
            transition: box-shadow 0.3s;
        }
        .site-header.scrolled { box-shadow: 0 4px 20px rgba(0,0,0,0.08); }

        /* NAV */
        .nav-link {
            position: relative;
            font-weight: 500;
            color: var(--navy);
            font-size: 0.9rem;
            letter-spacing: 0.02em;
            transition: color 0.2s;
        }
        .nav-link:hover { color: var(--gold); }
        .nav-link::after {
            content: '';
            position: absolute;
            bottom: -4px;
            left: 0;
            width: 0;
            height: 2px;
            background: var(--gold);
            transition: width 0.3s;
        }
        .nav-link:hover::after { width: 100%; }

        /* DROPDOWN */
        .dropdown { position: relative; }
        .dropdown-menu {
            display: none;
            position: absolute;
            top: 100%;
            left: 50%;
            transform: translateX(-50%);
            background: #fff;
            border: 1px solid #e8e4dc;
            border-radius: 12px;
            padding: 12px 0;
            min-width: 220px;
            box-shadow: 0 12px 40px rgba(0,0,0,0.1);
            z-index: 200;
        }
        .dropdown:hover .dropdown-menu { display: block; }
        .dropdown-menu a {
            display: block;
            padding: 8px 20px;
            font-size: 0.85rem;
            color: var(--navy);
            transition: background 0.15s, color 0.15s;
        }
        .dropdown-menu a:hover {
            background: var(--cream);
            color: var(--gold);
        }

        /* MEGA MENU (for Buyers dropdown) */
        .mega-menu {
            display: none;
            position: fixed;
            top: auto;
            left: 0;
            right: 0;
            background: #fff;
            border-top: 1px solid #e8e4dc;
            box-shadow: 0 12px 40px rgba(0,0,0,0.08);
            z-index: 200;
            padding: 32px 0;
        }
        .dropdown:hover .mega-menu { display: block; }
        .mega-menu-inner {
            max-width: 960px;
            margin: 0 auto;
            padding: 0 24px;
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 12px 48px;
        }
        .mega-menu-col h5 {
            font-family: 'DM Sans', sans-serif;
            font-size: 0.68rem;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.1em;
            color: var(--gold);
            margin-bottom: 12px;
            padding-bottom: 8px;
            border-bottom: 1px solid #f0ece4;
        }
        .mega-menu-col a {
            display: block;
            padding: 8px 0;
            text-decoration: none;
            border-bottom: 1px solid transparent;
            transition: all 0.15s;
        }
        .mega-menu-col a:hover {
            border-bottom-color: #f0ece4;
        }
        .mega-menu-col a .mm-title {
            font-size: 0.88rem;
            font-weight: 600;
            color: var(--navy);
            transition: color 0.15s;
        }
        .mega-menu-col a:hover .mm-title {
            color: var(--gold);
        }
        .mega-menu-col a .mm-desc {
            font-size: 0.75rem;
            color: #8896a8;
            margin-top: 2px;
            line-height: 1.4;
        }

        /* BUTTONS */
        .btn-primary {
            background: var(--gold);
            color: var(--navy);
            padding: 14px 32px;
            font-weight: 600;
            font-size: 0.9rem;
            border-radius: 6px;
            letter-spacing: 0.03em;
            transition: all 0.3s;
            display: inline-block;
            text-decoration: none;
            border: 2px solid var(--gold);
        }
        .btn-primary:hover {
            background: transparent;
            color: var(--gold);
        }
        .btn-secondary {
            background: transparent;
            color: var(--navy);
            padding: 14px 32px;
            font-weight: 600;
            font-size: 0.9rem;
            border-radius: 6px;
            letter-spacing: 0.03em;
            transition: all 0.3s;
            display: inline-block;
            text-decoration: none;
            border: 2px solid var(--navy);
        }
        .btn-secondary:hover {
            background: var(--navy);
            color: #fff;
        }
        .btn-white {
            background: #fff;
            color: var(--navy);
            padding: 14px 32px;
            font-weight: 600;
            font-size: 0.9rem;
            border-radius: 6px;
            letter-spacing: 0.03em;
            transition: all 0.3s;
            display: inline-block;
            text-decoration: none;
            border: 2px solid #fff;
        }
        .btn-white:hover {
            background: transparent;
            color: #fff;
        }

        /* MOBILE MENU */
        .mobile-menu {
            display: none;
            position: fixed;
            inset: 0;
            background: rgba(12,30,58,0.98);
            z-index: 999;
            padding: 80px 32px 32px;
            overflow-y: auto;
        }
        .mobile-menu.active { display: block; }
        .mobile-menu a {
            display: block;
            color: #fff;
            font-size: 1.2rem;
            padding: 12px 0;
            border-bottom: 1px solid rgba(255,255,255,0.08);
            text-decoration: none;
        }
        .mobile-menu a:hover { color: var(--gold); }

        /* MOBILE ACCORDION */
        .mobile-accordion {
            border-bottom: 1px solid rgba(255,255,255,0.08);
        }
        .mobile-accordion-toggle {
            display: flex;
            align-items: center;
            justify-content: space-between;
            width: 100%;
            background: none;
            border: none;
            color: #fff;
            font-family: 'DM Sans', sans-serif;
            font-size: 1.2rem;
            font-weight: 500;
            padding: 12px 0;
            cursor: pointer;
            text-align: left;
        }
        .mobile-accordion-toggle:hover { color: var(--gold); }
        .mobile-accordion-icon {
            font-size: 1.4rem;
            font-weight: 300;
            transition: transform 0.3s;
            color: var(--gold);
        }
        .mobile-accordion.open .mobile-accordion-icon {
            transform: rotate(45deg);
        }
        .mobile-accordion-panel {
            max-height: 0;
            overflow: hidden;
            transition: max-height 0.35s ease;
        }
        .mobile-accordion-panel a {
            font-size: 0.95rem !important;
            padding: 8px 0 8px 16px !important;
            color: #94a3b8 !important;
            border-bottom: none !important;
        }
        .mobile-accordion-panel a:hover {
            color: var(--gold) !important;
        }
        .mobile-accordion + a {
            /* Remove top border on links right after an accordion since the accordion has its own border */
        }



        /* RESPONSIVE */
        @media (max-width: 1024px) {
            .hero-img-container { display: none; }
            .stat-number { font-size: 2.2rem; }
            .desktop-nav { display: none !important; }
            .mobile-toggle { display: flex !important; }
        }

        @media (max-width: 768px) {
            .topbar { font-size: 0.72rem; }

            .site-header img[alt*="Royal LePage"] {
                height: 28px !important;
            }

            .topbar > div {
                flex-direction: column !important;
                gap: 4px !important;
                text-align: center;
            }
        }

        @media (max-width: 480px) {
            .site-header [style*="height:32px;width:1px"] {
                display: none !important;
            }
            .site-header img[alt*="Royal LePage"] {
                height: 24px !important;
            }
            .site-header [style*="width:42px;height:42px"] {
                width: 36px !important;
                height: 36px !important;
            }
            .site-header [style*="font-size:1.15rem"] {
                font-size: 1rem !important;
            }
        }


