/* Storefront header: hamburger + popup menu, compact bar on narrow viewports, warehouse modal.
   Loaded with js/gator-mobile-site-nav.js on supported pages; body[data-gator-mobile-nav] required. */

/* Shared hamburger + menu panel (also used on pages that only had partial header CSS). */
.navbar-menu-button {
    cursor: pointer;
    border: 1px solid #072415;
}

.navbar-menu-icon {
    background-color: #072415;
    margin: 10px;
    height: 20px;
}

.navbar-menu-button-desktop {
    width: 100px;
}

.navbar-menu-icon-desktop {
    width: 80px;
}

.popup-menu {
    position: absolute;
    background-color: #b3d1a4;
    padding: 20px;
    padding-top: 25px;
    border: 1px solid #072415;
    display: none;
    left: 0;
    z-index: 5000;
    box-sizing: border-box;
}

.popup-menu-option {
    color: black;
    font-weight: bold;
    padding: 10px;
    cursor: pointer;
    font-size: 15pt;
    font-family: Arial, Helvetica, sans-serif;
}

.popup-menu-option-desktop {
    font-size: 15pt;
}

button.popup-menu-option {
    width: 100%;
    text-align: left;
    font-family: inherit;
    background: transparent;
    border: none;
}

/* Popup menu option appearance (all viewports; same rules as former mobile-only block) */
body[data-gator-mobile-nav] #popupMenu .popup-menu-option,
body[data-gator-mobile-nav] #popupMenu .popup-menu-option-desktop,
body[data-gator-mobile-nav] #popupMenu a.popup-menu-option.customer-header-email-btn,
body[data-gator-mobile-nav] #popupMenu a.popup-menu-option.cc-header-email-btn {
    font-size: calc(15pt * 0.8) !important;
}

body[data-gator-mobile-nav] #popupMenu a.popup-menu-option.customer-header-email-btn,
body[data-gator-mobile-nav] #popupMenu a.popup-menu-option.cc-header-email-btn,
body[data-gator-mobile-nav] #popupMenu #gatorMobileNavCustomerLink.popup-menu-option,
body[data-gator-mobile-nav] #popupMenu #customerAccountEmailLink.popup-menu-option {
    color: #000 !important;
    background: transparent !important;
    background-color: transparent !important;
    border-radius: 0 !important;
    padding: 10px !important;
    font-weight: bold !important;
    text-decoration: none !important;
    max-width: none !important;
    overflow: visible !important;
    text-overflow: clip !important;
    white-space: normal !important;
    display: block !important;
    vertical-align: baseline !important;
    box-sizing: border-box !important;
}

body[data-gator-mobile-nav] #popupMenu a.popup-menu-option.customer-header-email-btn:hover,
body[data-gator-mobile-nav] #popupMenu a.popup-menu-option.cc-header-email-btn:hover,
body[data-gator-mobile-nav] #popupMenu #gatorMobileNavCustomerLink.popup-menu-option:hover,
body[data-gator-mobile-nav] #popupMenu #customerAccountEmailLink.popup-menu-option:hover {
    filter: none !important;
}

@media (max-width: 992px) {
    /* Menu control: 25% smaller than 100px / 80px reference */
    body[data-gator-mobile-nav] .navbar-menu-button.navbar-menu-button-desktop,
    body[data-gator-mobile-nav] .gator-cc-header-menu-btn {
        width: calc(100px * 0.75) !important;
        box-sizing: border-box;
    }

    body[data-gator-mobile-nav] .navbar-menu-icon.navbar-menu-icon-desktop,
    body[data-gator-mobile-nav] .gator-cc-header-menu-btn .navbar-menu-icon-desktop {
        width: calc(80px * 0.75) !important;
    }

    body[data-gator-mobile-nav] .navbar-menu-button .navbar-menu-icon-desktop {
        margin: calc(10px * 0.75) !important;
        height: calc(20px * 0.75) !important;
    }

    /* Gator logo: 25% smaller than 100px height */
    body[data-gator-mobile-nav] .logo-desktop,
    body[data-gator-mobile-nav] .cc-header-logo,
    body[data-gator-mobile-nav] .cc-logo-desktop {
        height: calc(100px * 0.75) !important;
        max-height: calc(100px * 0.75) !important;
        width: auto !important;
        margin-left: min(12px, 3vw) !important;
    }

    /* Hide nonessential header chrome; keep menu, logo, cart */
    body[data-gator-mobile-nav] .gator-header-hide-mobile,
    body[data-gator-mobile-nav] .customer-account-header-td,
    body[data-gator-mobile-nav] .cc-header-account,
    body[data-gator-mobile-nav] .cc-header-tagline,
    body[data-gator-mobile-nav] .cc-header-location,
    body[data-gator-mobile-nav] #kioskMicTd {
        display: none !important;
    }

    body[data-gator-mobile-nav] .header-right-mobile {
        display: none !important;
    }

    body[data-gator-mobile-nav] .header-cart-td {
        display: table-cell !important;
        vertical-align: middle;
    }

    body[data-gator-mobile-nav] .main-header-table-desktop,
    body[data-gator-mobile-nav] .main-header-table {
        height: auto !important;
        min-height: 0 !important;
    }

    body[data-gator-mobile-nav] .main-header-table tr {
        vertical-align: middle;
    }

    /* Checkout header grid: menu | logo | cart */
    body[data-gator-mobile-nav="checkout"] .cc-site-header__inner {
        grid-template-columns: auto auto 1fr auto;
        grid-template-areas: "menu brand . cart";
        align-items: center;
        min-height: 0;
        padding-top: 8px;
        padding-bottom: 10px;
    }

    body[data-gator-mobile-nav="checkout"] .gator-cc-header-menu-wrap {
        grid-area: menu;
    }

    body[data-gator-mobile-nav="checkout"] .cc-header-brand {
        grid-area: brand;
    }

    body[data-gator-mobile-nav="checkout"] .gator-cc-header-cart-wrap {
        grid-area: cart;
        justify-self: end;
    }

    body[data-gator-mobile-nav="checkout"] .cc-header-logo {
        margin-left: 0;
    }

    body[data-gator-mobile-nav="checkout"] .gator-cc-header-menu-btn {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: stretch;
        cursor: pointer;
        border: 1px solid #072415;
        background: transparent;
        padding: 0;
    }

    body[data-gator-mobile-nav="checkout"] .gator-cc-header-menu-btn .navbar-menu-icon-desktop {
        margin-left: calc(10px * 0.75);
        margin-right: calc(10px * 0.75);
    }

    body[data-gator-mobile-nav="checkout"] .gator-cc-header-menu-wrap,
    body[data-gator-mobile-nav="checkout"] td.gator-cc-header-menu-wrap {
        position: relative;
    }

    body[data-gator-mobile-nav="checkout"] .gator-cc-checkout-popup {
        left: 0;
        top: calc(100% + 6px);
    }

    /* cart-finished table header */
    body[data-gator-mobile-nav="checkout"] .cc-main-header-table tr {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: nowrap;
    }

    body[data-gator-mobile-nav="checkout"] .cc-main-header-table .gator-header-hide-mobile {
        display: none !important;
    }
}

/* Warehouse modal (all viewports when shown) */
.gator-warehouse-hours-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 9500;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 30px;
    box-sizing: border-box;
}

.gator-warehouse-hours-overlay[hidden] {
    display: none !important;
}

.gator-warehouse-hours-dialog {
    background: #fff;
    border-radius: 10px;
    padding: 22px 26px;
    max-width: 420px;
    width: calc(100% - 32px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    border: 1px solid #ccc;
}

.gator-warehouse-hours-title {
    margin: 0 0 14px;
    font-size: 16pt;
    color: #38622f;
}

.gator-warehouse-hours-body {
    margin: 0 0 12px;
    font-size: 14pt;
    line-height: 1.45;
    color: #222;
}

.gator-warehouse-hours-actions {
    margin-top: 18px;
    text-align: right;
}

.gator-warehouse-hours-ok {
    font-size: 14pt;
    padding: 10px 22px;
    background: green;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}

.gator-warehouse-hours-ok:focus-visible {
    outline: 3px solid #38622f;
    outline-offset: 2px;
}

/* Kiosk storefront: hide header cart (body.gator-storefront-kiosk from gator-mobile-site-nav.js). */
body.gator-storefront-kiosk .header-cart-td,
body.gator-storefront-kiosk .gator-cc-header-cart-wrap,
body.gator-storefront-kiosk .header-right-mobile .cart-mobile {
    display: none !important;
}

/* Kiosk: header warehouse address is display-only (no maps link / no span easter-egg clicks). */
body.gator-storefront-kiosk .header-warehouse,
body.gator-storefront-kiosk .header-warehouse * {
    pointer-events: none;
    cursor: default;
}
