/**
 * GoldieCircle Professional Header Navigation
 * Logo left, menu right, with Spanish translation
 *
 * @version 1.0.4
 * @lastUpdated 2026-01-11
 *
 * CHANGELOG:
 * ---------------------------------------------------------------------------
 * v1.0.4 (2026-01-11) - Claude Opus 4.5
 *   NEW: Compact user profile dropdown styles (.gc-user-dropdown)
 *   - Small button with emoji avatar + username + arrow
 *   - Dropdown menu appears below on click
 *   - Replaces old fixed overlay approach
 *   - Mobile: hides username, shows only avatar
 *
 * v1.0.3 (2026-01-11) - Claude Opus 4.5
 *   FIX: Reverted conditional .gc-accessibility-active rules
 *   - Works with new JS "Profile Widget approach" for accessibility panel
 *
 * v1.0.2 (2026-01-10) - Claude Sonnet 4.5
 *   - Added conditional overflow rules for accessibility panel
 *
 * v1.0.1 - Google Translate integration
 *
 * v1.0.0 - Initial: Custom header replacing Neve theme
 * ---------------------------------------------------------------------------
 */

/* ============================================
   HIDE NEVE'S DEFAULT HEADER
   ============================================ */

/* Hide Neve's header completely */
.header-wrapper,
.header--row,
.hfg-header,
header.header {
    display: none !important;
}

/* Show only our custom header */
body.gc-custom-header .gc-header-professional {
    display: block !important;
}

/* ============================================
   DESKTOP HEADER - NEW LAYOUT
   ============================================ */

/* Override WordPress/Neve theme link defaults - ALL pages consistent */
.gc-header-professional a,
.gc-header-professional a:link,
.gc-header-professional a:visited,
.gc-header-professional a:hover,
.gc-header-professional a:active,
.gc-header-professional a:focus {
    text-decoration: none !important;
}

/* Prevent Neve theme from forcing blue color */
body .gc-header-professional a {
    color: inherit;
}

.gc-header-professional {
    background: #FFFFFF;
    border-bottom: 3px solid #0B5394;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0; /* Remove padding, let flex container handle it */

    /* CRITICAL: Prevent header from causing horizontal overflow */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Allow user dropdown to overflow, but hide horizontal overflow on smaller viewports */
.gc-header-professional {
    overflow: visible !important; /* Changed from overflow-x: hidden to allow dropdown */
}

.gc-header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 30px 0 20px;
    display: flex;
    align-items: center !important; /* CRITICAL: Vertical center everything */
    justify-content: flex-start; /* Allow gap to work properly */
    flex-wrap: nowrap !important; /* Force one line */
    gap: 16px; /* Consistent spacing between ALL elements */
    min-height: 90px; /* Taller for bigger elements */

    /* CRITICAL: Prevent container from exceeding viewport width */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.gc-header-container {
    overflow: visible !important; /* Changed to allow user dropdown to appear */
}

/* ============================================
   LOGO (FAR LEFT) - BIGGER SIZE
   ============================================ */

.gc-header-logo {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    margin: 0 !important; /* No extra margins - gap handles spacing */
}

.gc-header-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.gc-header-logo img {
    height: 70px;
    width: auto;
    transition: transform 0.3s ease;
}

.gc-header-logo a:hover img {
    transform: scale(1.05); /* Subtle hover effect */
}

/* ============================================
   NAVIGATION MENU (CENTER-RIGHT)
   ============================================ */

.gc-header-nav {
    flex: 0 1 auto;
    display: flex;
    align-items: center; /* Vertical center */
    margin: 0 !important; /* No extra margins - gap handles spacing */
}

.gc-nav-menu {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 4px 10px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.gc-nav-item {
    display: flex;
    align-items: center;
    margin: 0;
    list-style: none !important;
}

/* Remove any bullets or separators that might be added */
.gc-nav-item::before,
.gc-nav-item::after,
.gc-nav-menu::before,
.gc-nav-menu::after {
    content: '' !important;
    display: none !important;
}

.gc-nav-link,
.gc-nav-link:link,
.gc-nav-link:visited {
    display: flex; /* Changed from block for better alignment */
    align-items: center; /* Vertical center */
    padding: 12px 18px; /* Good padding */
    font-size: 22px !important; /* BIGGER! Was 17px */
    font-weight: 700; /* Extra bold */
    color: #2c3e50 !important;
    text-decoration: none !important;
    border-bottom: none !important;
    border-radius: 8px;
    transition: all 0.3s;
    white-space: nowrap;
    line-height: 1.2;
}

.gc-nav-link:hover,
.gc-nav-link:focus,
.gc-nav-link:active {
    background: #E8F2F7;
    color: #0B5394 !important;
    text-decoration: none !important;
    border-bottom: none !important;
}

/* Chat CTA styling removed - now matches other menu items */

/* Active page indicator */
.gc-nav-link.active {
    background: #E8F2F7;
    color: #0B5394;
}

/* ============================================
   ACCESSIBILITY ICON (Between Nav and Actions)
   ============================================ */

.gc-accessibility-icon,
.accessibility-widget,
[class*="accessibility"],
.gc-header-accessibility {
    display: flex;
    align-items: center;
    align-self: center;
    flex-shrink: 0;
    margin: 0 !important; /* Let gap handle all spacing */
    padding: 0 !important;
}

.gc-accessibility-icon button,
.gc-accessibility-icon a,
.accessibility-widget button,
.accessibility-widget a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    padding: 0;
    margin: 0;
}

.gc-accessibility-icon img,
.gc-accessibility-icon svg,
.accessibility-widget img,
.accessibility-widget svg {
    width: 32px;
    height: 32px;
    display: block;
}

/* ============================================
   CONTROLS GROUP (Spanish + Text Size)
   ============================================ */

.gc-controls-group {
    display: flex;
    flex-direction: column; /* Stack vertically */
    align-items: center; /* Center align both controls */
    gap: 6px; /* Tight vertical gap */
    flex-shrink: 0;
    padding: 0; /* No padding by default */
    margin: 0; /* No margin by default */
}

/* Google Translate - Show dropdown, hide everything else */

/* Hide Google Translate banner at top of page */
.goog-te-banner-frame {
    display: none !important;
}

/* HIDE GOOGLE TRANSLATE BOTTOM TOOLBAR */
.goog-te-ftab {
    display: none !important;
}

.skiptranslate iframe {
    display: none !important;
}

body {
    top: 0 !important;
    position: static !important;
}

/* Show the widget - don't hide it! */
#google_translate_element {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Show the dropdown */
.goog-te-gadget {
    font-size: 0 !important; /* Hide "Select Language" text */
}

.goog-te-gadget .goog-te-combo {
    font-size: 18px !important; /* Show dropdown with readable text */
    padding: 8px 12px !important;
    border-radius: 6px !important;
    border: 2px solid #dee2e6 !important;
    background: #f8f9fa !important;
}

/* Hide "Powered by" but KEEP the dropdown visible */
.goog-logo-link {
    display: none !important;
}

/* Hide the "Powered by" text and image, but SHOW the dropdown */
.goog-te-gadget > span > a {
    display: none !important;
}

.goog-te-gadget img {
    display: none !important;
}

/* Show "Select Language:" text before dropdown */
.goog-te-gadget > span {
    display: inline-block !important;
}

/* Google Translate Dropdown Widget - FORCE VISIBLE */
.gc-translate-widget {
    flex-shrink: 0;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-width: 120px; /* Reduced from 150px */
    max-width: 180px; /* Prevent it from getting too wide */
    height: auto;
}

/* Style Google's translate dropdown - MAKE SURE IT'S VISIBLE */
#google_translate_element {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
}

/* Force the Google Translate select dropdown to be visible */
.goog-te-combo {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

#google_translate_element select,
select.goog-te-combo {
    background: #f8f9fa !important;
    border: 2px solid #dee2e6 !important;
    color: #2c3e50 !important;
    padding: 8px 12px !important; /* Reduced from 10px 16px */
    border-radius: 6px !important;
    font-size: 16px !important; /* Reduced from 18px */
    font-weight: 700 !important;
    cursor: pointer !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-width: 120px !important; /* Reduced from 150px */
    max-width: 180px !important; /* Prevent overflow */
    height: auto !important;
    transition: all 0.3s;
    outline: none;
}

#google_translate_element select:hover {
    background: #e9ecef;
    border-color: #0B5394;
}

#google_translate_element select:focus {
    border-color: #0B5394;
    box-shadow: 0 0 0 3px rgba(11, 83, 148, 0.1);
}

/* Hide Google's branding text */
.goog-te-gadget {
    color: transparent !important;
    font-size: 0 !important;
}

.goog-te-gadget span {
    display: none !important;
}

/* Hide "Powered by" text */
.goog-te-gadget > span > a {
    display: none !important;
}

/* Keep only the dropdown visible */
.goog-te-gadget .goog-te-combo {
    display: inline-block !important;
}

.goog-logo-link {
    display: none !important;
}

/* Style the dropdown options */
.goog-te-menu-value {
    font-size: 18px;
}

.goog-te-menu-value span {
    color: #2c3e50 !important;
}

/* ============================================
   TEXT SIZE CONTROLS
   ============================================ */

/* Text Size Classes - Applied to <html> element */
html.gc-text-small {
    font-size: 87.5%; /* 14px base */
}

html.gc-text-normal {
    font-size: 100%; /* 16px base - default */
}

html.gc-text-large {
    font-size: 125%; /* 20px base */
}

/* Ensure text scales proportionally */
html.gc-text-small body,
html.gc-text-normal body,
html.gc-text-large body {
    font-size: 1rem; /* Inherit from html */
}

.gc-text-sizer {
    display: flex;
    flex-direction: row; /* Keep text size buttons horizontal */
    align-items: center;
    justify-content: center; /* Center the A- A A+ buttons */
    gap: 4px;
    flex-shrink: 0;
}

.gc-size-btn {
    background: none;
    border: none;
    color: #6c757d;
    font-size: 20px; /* Reduced from 24px to save space */
    font-weight: 700; /* Extra bold */
    padding: 8px 10px; /* Reduced from 10px 14px */
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 4px;
}

.gc-size-btn:hover {
    background: #E8F2F7;
    color: #0B5394;
}

.gc-size-btn.active {
    color: #0B5394;
    font-weight: 700;
}

.gc-size-btn:focus {
    outline: 2px solid #0B5394;
    outline-offset: 2px;
}

/* ============================================
   USER ACTIONS (FAR RIGHT)
   ============================================ */

.gc-header-actions {
    display: flex;
    align-items: center !important; /* CRITICAL: Vertical center */
    align-self: center;
    gap: 16px; /* SAME as container gap for consistency */
    flex-shrink: 0;
    padding: 0;
    margin: 0 !important; /* No extra margins - gap handles spacing */
}

.gc-header-signin,
.gc-header-signin:link,
.gc-header-signin:visited {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50 !important;
    text-decoration: none !important;
    border-radius: 8px;
    transition: all 0.3s;
    white-space: nowrap;
    line-height: 1.2;
    flex-shrink: 0;
    margin: 0 !important; /* No extra margins */
}

.gc-header-signin:hover,
.gc-header-signin:focus,
.gc-header-signin:active {
    background: #F5F7FA;
    color: #0B5394 !important;
    text-decoration: none !important;
}

.gc-header-signup,
.gc-header-signup:link,
.gc-header-signup:visited {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    font-size: 18px;
    font-weight: 700;
    color: white !important;
    background: #27AE60 !important;
    text-decoration: none !important;
    border-radius: 8px;
    transition: all 0.3s;
    white-space: nowrap;
    line-height: 1.2;
    flex-shrink: 0;
    margin: 0 !important; /* No extra margins */
}

.gc-header-signup:hover,
.gc-header-signup:focus,
.gc-header-signup:active {
    color: white !important;
    background: #52C67A !important;
    text-decoration: none !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.3);
}

/* ============================================
   USER PROFILE BUTTON - ALIGN WITH MENU
   ============================================ */

/* Profile button container & button itself */
.gc-user-profile,
.gc-user-menu,
.gc-profile-button,
.gc-user-profile button,
.gc-user-menu button,
button.gc-profile-btn,
.gc-header-actions button,
.gc-header-actions > button,
.gc-header-actions > a.button,
[class*="user-profile"],
[class*="user-menu"] {
    display: flex !important;
    align-items: center !important; /* CRITICAL: Vertical center */
    justify-content: center !important;
    align-self: center !important; /* CRITICAL: Force vertical centering in flex parent */

    /* Match menu item sizing */
    padding: 12px 20px !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;

    /* Styling */
    border: 2px solid #FFB800 !important; /* Gold border */
    border-radius: 50px !important; /* Pill shape */
    background: white !important;
    color: #2c3e50 !important;
    cursor: pointer !important;
    gap: 10px !important;
    white-space: nowrap !important;

    /* Remove any extra spacing - CRITICAL for alignment */
    margin: auto 0 !important; /* Auto top/bottom, 0 left/right */
    vertical-align: middle !important;
    height: auto !important;
    position: relative !important;
    top: auto !important;
    bottom: auto !important;

    transition: all 0.3s;
}

/* User icon/avatar in button */
.gc-user-profile img,
.gc-user-profile .avatar,
.gc-user-profile button img,
.gc-user-profile button .avatar,
.gc-profile-button img,
.gc-profile-btn img,
.gc-header-actions button img {
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    display: block !important;
    margin: 0 !important;
}

/* User name text */
.gc-user-profile .username,
.gc-user-profile button .username,
.gc-profile-button .username,
.gc-profile-btn .username {
    font-size: 18px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    color: #2c3e50 !important;
}

/* Dropdown arrow */
.gc-user-profile .arrow,
.gc-user-profile button .arrow,
.gc-profile-button .arrow,
.gc-profile-btn .arrow,
.gc-user-profile::after {
    content: '▼' !important;
    font-size: 10px !important;
    color: #2c3e50 !important;
    margin-left: 4px !important;
}

/* Hover state */
.gc-user-profile:hover,
.gc-user-profile button:hover,
.gc-profile-button:hover,
.gc-profile-btn:hover,
.gc-header-actions button:hover {
    background: #FFF8E1 !important; /* Light gold */
    border-color: #FFA000 !important;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(255, 184, 0, 0.2);
}

/* ============================================
   COMPACT USER PROFILE DROPDOWN (v1.0.4)
   Clean dropdown integrated into header
   ============================================ */

/* CRITICAL: Override header overflow to allow dropdown to appear */
.gc-header-actions {
    overflow: visible !important;
}

.gc-user-dropdown {
    position: relative;
    display: flex;
    align-items: center;
    overflow: visible !important;
}

.gc-user-btn {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 8px 16px !important;
    background: white !important;
    border: 2px solid #D89000 !important;
    border-radius: 50px !important;
    cursor: pointer !important;
    font-family: inherit !important;
    transition: all 0.3s ease !important;
    white-space: nowrap !important;
}

.gc-user-btn:hover {
    background: #FFF9E6 !important;
    border-color: #B87700 !important;
    box-shadow: 0 2px 8px rgba(216, 144, 0, 0.3) !important;
}

.gc-user-avatar {
    font-size: 20px !important;
    line-height: 1 !important;
    /* Gold gradient background to match profile widget and dashboard */
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 40px !important;
    height: 40px !important;
    background: linear-gradient(135deg, #FFD700, #D89000) !important; /* Gold gradient */
    border: 3px solid #B87700 !important; /* Darker gold border */
    border-radius: 50% !important;
    flex-shrink: 0 !important;
    box-shadow: 0 2px 8px rgba(216, 144, 0, 0.4) !important; /* Gold shadow */
}

.gc-user-name {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #2c3e50 !important;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gc-user-arrow {
    font-size: 12px !important;
    color: #666 !important;
    transition: transform 0.3s ease !important;
}

.gc-user-dropdown.active .gc-user-arrow {
    transform: rotate(180deg);
}

/* Dropdown Menu - Hidden by default - VERTICAL STACK with GOLD BORDER */
.gc-user-menu {
    position: absolute !important;
    top: calc(100% + 8px) !important;
    right: 0 !important;
    background: white !important;
    border: 3px solid #D89000 !important; /* Gold border to match theme */
    border-radius: 12px !important;
    box-shadow: 0 4px 20px rgba(216, 144, 0, 0.3) !important; /* Gold shadow */
    min-width: 200px !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transform: translateY(-10px) !important;
    transition: all 0.2s ease !important;
    z-index: 10000 !important;
    overflow: hidden !important;
    /* Vertical stack - flex column */
    display: flex !important;
    flex-direction: column !important;
}

.gc-user-dropdown.active .gc-user-menu {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

.gc-user-menu a {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 14px 18px !important;
    color: #2c3e50 !important;
    text-decoration: none !important;
    font-size: 16px !important; /* Bigger text */
    font-weight: 600 !important;
    transition: all 0.2s ease !important;
    border-bottom: 1px solid #e0e0e0 !important;
}

.gc-user-menu a:last-child {
    border-bottom: none !important;
}

.gc-user-menu a:hover {
    background: #FFF9E6 !important; /* Light gold hover */
    color: #B87700 !important;
    padding-left: 22px !important;
}

.gc-user-menu a.gc-logout {
    color: #e74c3c !important;
}

.gc-user-menu a.gc-logout:hover {
    background: #fef5f5 !important;
    color: #c0392b !important;
}

.gc-menu-icon {
    font-size: 22px !important; /* Bigger icons for better emoji visibility */
    display: inline-block !important;
    width: 24px !important;
    text-align: center !important;
    margin-right: 8px !important;
}

/* Mobile: Hide name, show only avatar */
@media (max-width: 768px) {
    .gc-user-name {
        display: none !important;
    }

    .gc-user-btn {
        padding: 8px 12px !important;
    }

    .gc-user-menu {
        right: -10px !important;
    }
}

/* ============================================
   MOBILE BOTTOM TAB BAR
   ============================================ */

.gc-mobile-tabs {
    display: none; /* Hidden on desktop */
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-top: 2px solid #E0E4E8;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    padding: 8px 0 calc(8px + env(safe-area-inset-bottom));
}

.gc-mobile-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 4px;
    text-decoration: none;
    color: #6c757d;
    transition: all 0.2s;
    border-radius: 8px;
}

.gc-mobile-tab:active {
    background: #F5F7FA;
}

.gc-tab-icon {
    font-size: 24px;
    line-height: 1;
}

.gc-tab-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Primary tab (Ask Goldie) */
.gc-mobile-tab-primary {
    color: #0B5394;
}

.gc-mobile-tab-primary .gc-tab-icon {
    font-size: 28px;
}

/* Active tab */
.gc-mobile-tab.active {
    color: #0B5394;
    background: #E8F2F7;
}

/* ============================================
   RESPONSIVE BREAKPOINTS
   ============================================ */

/* ================================
   CREST LOGO — FINAL HEADER SCALE
   ================================ */

@media (min-width: 1301px) {

    .gc-header-professional {
        padding-top: 16px !important;
        padding-bottom: 16px !important;
    }

    .gc-header-professional {
        overflow: visible !important; /* Allow dropdown on mobile too */
    }

    .gc-header-container {
        align-items: center !important;
        justify-content: flex-start !important;
        flex-wrap: nowrap;
        gap: 16px !important; /* Consistent spacing */
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        overflow: visible !important; /* Allow dropdown on mobile */
    }

    .gc-header-logo {
        flex: 0 1 420px !important; /* Allow shrinking if needed */
        max-width: 420px !important;
        min-width: 280px !important; /* Set reasonable minimum */
        margin-right: 0 !important;
    }

    .gc-header-logo img {
        height: 96px !important; /* PERFECT SIZE */
        width: 100% !important; /* Flexible width within container */
        max-width: 420px !important;
        object-fit: contain !important;
        object-position: left center;
        display: block;
    }

    .gc-header-nav {
        flex: 1 1 auto !important;
        justify-content: center !important;
        min-width: 0 !important;
    }

    .gc-header-actions,
    .gc-controls-group {
        flex: 0 0 auto !important;
        align-items: center !important; /* CRITICAL: Vertical center */
        gap: 16px !important; /* Consistent spacing within actions */
        padding-top: 0 !important; /* Remove any padding from responsive breakpoints */
        padding-bottom: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }

    .gc-accessibility-icon,
    .accessibility-widget,
    [class*="accessibility"],
    .gc-header-accessibility {
        margin-left: auto !important; /* Push to right */
        margin-right: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
        padding: 0 !important;
    }

    .gc-header-logo,
    .gc-header-nav,
    .gc-header-actions {
        margin: 0 !important; /* No margins - gap handles spacing */
    }
}

/* Tablet: Reduce spacing */
@media (max-width: 1200px) {
    .gc-header-container {
        padding: 0 20px;
        gap: 15px;
    }

    .gc-nav-menu {
        gap: 4px;
    }

    .gc-nav-link {
        padding: 10px 16px;
        font-size: 18px; /* Keep it readable on tablet */
    }

    .gc-nav-cta .gc-nav-link {
        padding: 10px 20px;
    }

    .gc-accessibility-icon,
    .accessibility-widget,
    [class*="accessibility"],
    .gc-header-accessibility {
        margin-left: auto !important; /* Push to right */
        margin-right: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }
}

/* Medium screens: Two-row layout - INCREASED BREAKPOINT */
@media (max-width: 1300px) {
    .gc-header-professional {
        padding: 15px 0 12px 0;
    }

    .gc-header-container {
        flex-wrap: wrap; /* Allow wrapping to second row */
        gap: 10px 15px; /* Reduced gaps to save space */
    }

    /* === FIRST ROW: Logo + Navigation === */
    .gc-header-logo {
        order: 1;
        flex: 0 0 auto;
    }

    .gc-header-nav {
        order: 2;
        flex: 1 1 auto;
    }

    /* === SECOND ROW: Translate + Text Size + Auth Buttons === */
    .gc-controls-group {
        order: 3;
        width: auto; /* Don't force full width */
        flex: 0 0 auto;
        padding-top: 8px;
        /* gap: 6px is set globally, no need to override */
    }

    .gc-header-actions {
        order: 4;
        flex: 0 0 auto;
        margin-left: auto; /* Push to the right */
        padding-top: 8px;
        gap: 8px; /* Tighter gap between sign in/up buttons */
    }

    /* Add subtle divider between rows */
    .gc-controls-group::before {
        content: '';
        position: absolute;
        left: 20px;
        right: 20px;
        top: 56px; /* Adjust based on logo height */
        height: 1px;
        background: #E8F2F7;
    }

    /* Compact navigation */
    .gc-nav-link {
        padding: 8px 12px;
        font-size: 14px;
    }

    /* Smaller auth buttons on second row */
    .gc-header-signin,
    .gc-header-signup {
        padding: 10px 20px;
        font-size: 16px;
    }
}

/* Tablet: Smaller logo, compact nav */
@media (max-width: 992px) {
    .gc-header-logo img {
        height: 40px;
    }

    .gc-nav-link {
        padding: 8px 12px;
        font-size: 16px; /* Better readability on small tablets */
    }

    .gc-header-signin,
    .gc-header-signup {
        padding: 8px 16px;
        font-size: 14px;
    }

    .gc-accessibility-icon,
    .accessibility-widget,
    [class*="accessibility"],
    .gc-header-accessibility {
        margin-left: auto !important; /* Push to right */
        margin-right: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }
}

/* Mobile: Hide desktop nav, show bottom tabs */
@media (max-width: 768px) {
    .gc-header-professional {
        padding: 12px 0;
    }

    .gc-header-container {
        padding: 0 15px;
    }

    /* Hide desktop navigation */
    .gc-header-nav {
        display: none;
    }

    /* Show Google Translate on mobile, hide text size controls */
    .gc-controls-group {
        display: flex;
        gap: 10px;
    }

    /* Hide text size controls on mobile, keep translate */
    .gc-text-sizer {
        display: none;
    }

    /* Make sure translate widget shows on mobile */
    .gc-translate-widget {
        display: inline-block !important;
    }

    /* Simplify header to just logo + actions - BIGGER */
    .gc-header-logo img {
        height: 55px; /* Increased from 36px to 55px for better visibility */
    }

    .gc-header-actions {
        gap: 8px;
    }

    .gc-header-signin {
        padding: 8px 12px;
        font-size: 13px;
    }

    .gc-header-signup {
        padding: 8px 16px;
        font-size: 13px;
    }

    /* Show mobile bottom tabs */
    .gc-mobile-tabs {
        display: flex;
    }

    /* Add padding to body so content doesn't hide under tabs */
    body {
        padding-bottom: 70px;
    }
}

/* Small mobile: Minimal header - BIGGER LOGO */
@media (max-width: 480px) {
    .gc-header-logo img {
        height: 48px; /* Increased from 32px to 48px for better visibility */
    }

    .gc-header-signin {
        padding: 8px;
    }

    .gc-tab-label {
        font-size: 10px;
    }

    .gc-tab-icon {
        font-size: 22px;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

/* Skip to main content link */
.gc-skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: #0B5394;
    color: white;
    padding: 12px 20px;
    text-decoration: none;
    font-weight: 600;
    z-index: 10000;
}

.gc-skip-link:focus {
    top: 0;
}

/* Focus indicators */
.gc-nav-link:focus,
.gc-header-signin:focus,
.gc-header-signup:focus,
.gc-mobile-tab:focus,
.gc-spanish-toggle:focus {
    outline: 3px solid #0B5394;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .gc-header-professional {
        border-bottom: 4px solid #000;
    }

    .gc-nav-link {
        border: 2px solid transparent;
    }

    .gc-nav-link:hover,
    .gc-nav-link.active {
        border-color: #0B5394;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .gc-nav-link,
    .gc-header-signup,
    .gc-header-signin,
    .gc-mobile-tab,
    .gc-spanish-toggle {
        transition: none;
    }

    .gc-nav-cta .gc-nav-link:hover,
    .gc-header-signup:hover {
        transform: none;
    }
}

/* ============================================
   GOOGLE TRANSLATE - HIDE ONLY BANNER/TOOLBAR
   ============================================ */

/* Hide Google Translate banner at top of page */
.goog-te-banner-frame.skiptranslate {
    display: none !important;
}

/* Hide Google Translate bottom toolbar */
.skiptranslate iframe {
    display: none !important;
}

/* Prevent body from being pushed down by Google Translate */
body {
    top: 0 !important;
}

body.translated-ltr {
    top: 0 !important;
}

/* NOTE: DO NOT hide the dropdown! It's controlled by the rules at the top of this file (lines 152-265) */