/*
 * Storefront header — append layer.
 *
 * Everything here is scoped under .ss-notice / .ss-header so style.css keeps
 * owning the rest of the front end. Loaded after style.css and responsive.css.
 */

:root {
    --ss-notice-bg: #faf6ef;
    --ss-ink: #2b2b2b;
    --ss-ink-soft: #4a4a4a;
    --ss-line: #ece7dd;
    --ss-pill-line: #ded6c8;
}

/* ---------------------------------------------------------- promise strip */

.ss-notice {
    background: var(--ss-notice-bg);
    border-bottom: 1px solid var(--ss-line);
    font-size: 13px;
    line-height: 1;
    color: var(--ss-ink-soft);
}

.ss-notice-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 38px;
}

.ss-notice-promise,
.ss-notice-contact {
    display: flex;
    align-items: center;
    gap: 24px;
}

.ss-notice-promise i,
.ss-notice-contact i {
    font-size: 14px;
    margin-inline-end: 8px;
}

.ss-notice-promise span,
.ss-notice-contact span {
    vertical-align: middle;
}

.ss-notice-contact a {
    color: var(--ss-ink-soft);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.ss-notice-contact a:hover {
    color: var(--ss-ink);
}

/* ----------------------------------------------------------- header shell */

.navbar.ss-header {
    background: #fff;
    border-bottom: 1px solid var(--ss-line);
}

.ss-header .ss-header-row {
    display: flex;
    align-items: center;
    gap: 24px;
    width: 100%;
    min-height: 78px;
    padding: 10px 0;
}

.ss-header .ss-logo {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
}

.ss-header .ss-logo img {
    height: 58px;
    width: auto;
    max-width: 200px;
}

/* ------------------------------------------------------------- search bar */

.ss-header .ss-search {
    flex: 1 1 auto;
    max-width: 560px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    height: 46px;
    padding: 0 6px 0 4px;
    border: 1px solid var(--ss-pill-line);
    border-radius: 999px;
    background: #fff;
}

/* style.css gives every .dropdown a pill shadow; inside the search bar that
   paints a second box around the category label. Flex (rather than the default
   block) also stops the inline-flex button sitting on a text baseline, which
   added descender space below it and pushed the label above the pill's centre. */
.ss-header .ss-search-cat {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    height: auto;
    border-radius: 0;
    box-shadow: none;
}

.ss-header .ss-search-cat-btn {
    /* style.css hangs margin-bottom: 10px on every button, which shifts a
       vertically centred flex item up by half of it. */
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 14px;
    border: 0;
    background: transparent;
    border-radius: 999px;
    font-size: 14px;
    color: var(--ss-ink);
    white-space: nowrap;
}

.ss-header .ss-search-cat-btn i {
    font-size: 12px;
}

.ss-header .ss-search-cat-menu {
    max-height: 320px;
    overflow-y: auto;
    border: 1px solid var(--ss-line);
    border-radius: 10px;
    padding: 6px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .08);
}

.ss-header .ss-search-cat-menu .dropdown-item {
    font-size: 14px;
    border-radius: 6px;
    padding: 8px 12px;
    color: var(--ss-ink);
}

.ss-header .ss-search-divider {
    flex: 0 0 auto;
    width: 1px;
    height: 22px;
    background: var(--ss-pill-line);
    margin: 0 4px;
}

.ss-header .ss-search-input {
    flex: 1 1 auto;
    min-width: 0;
    height: 40px;
    padding: 0 12px;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 14px;
    color: var(--ss-ink);
}

.ss-header .ss-search-input::placeholder {
    color: #9a9184;
}

.ss-header .ss-search-btn {
    margin: 0;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--ss-ink);
    font-size: 17px;
}

.ss-header .ss-search-btn:hover {
    background: var(--ss-notice-bg);
}

/* --------------------------------------------------------- right actions */

.ss-header .ss-actions {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 26px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ss-header .ss-action-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--ss-ink);
    text-decoration: none;
    cursor: pointer;
}

.ss-header .ss-action-link:hover {
    color: var(--bs-primary, #2b2b2b);
}

.ss-header .ss-action-link > i {
    font-size: 19px;
}

.ss-header .ss-cart-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    font-size: 19px;
}

.ss-header .ss-cart-count {
    position: absolute;
    top: -9px;
    inset-inline-end: -10px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 999px;
    background: var(--bs-primary, #2e7d32);
    color: #fff;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
    font-style: normal;
}

.ss-header .ss-cart-total {
    white-space: nowrap;
}

/* -------------------------------------------------------------- responsive */

/* Logo, search and cart share one row all the way down; the pill takes whatever
   width is left over rather than wrapping to a line of its own. */
@media (max-width: 991.98px) {
    .ss-header .ss-header-row {
        flex-wrap: nowrap;
        gap: 12px;
        min-height: 0;
    }

    .ss-header .ss-logo img {
        height: 42px;
        max-width: 120px;
    }

    .ss-header .ss-search {
        flex: 1 1 auto;
        min-width: 0;
        max-width: none;
        margin: 0;
        height: 42px;
    }

    .ss-header .ss-search-cat-btn {
        padding: 0 10px;
        font-size: 13px;
        max-width: 130px;
    }

    .ss-header .ss-search-cat-btn span {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .ss-header .ss-actions {
        gap: 16px;
    }

    .ss-header .ss-action-link > span:not(.ss-cart-icon):not(.ss-cart-total) {
        display: none;
    }
}

/* On a phone there is not enough room for the category picker AND a usable
   input on the same line, so the pill becomes search-everything. Browsing by
   category stays on the bottom bar and in the sidebar. */
@media (max-width: 575.98px) {
    .ss-header .ss-header-row {
        gap: 8px;
    }

    .ss-header .ss-logo img {
        height: 38px;
        max-width: 96px;
    }

    .ss-header .ss-search-cat,
    .ss-header .ss-search-divider {
        display: none;
    }

    .ss-header .ss-search {
        height: 40px;
        padding: 0 4px 0 8px;
    }

    .ss-header .ss-cart-total {
        display: none;
    }
}


/* ------------------------------------------------ section-theme chrome (5b) */
/* Header and footer groups rendered by App\Theme\ThemeChrome (spec §12.2). The group wrapper adds no box, so a
   sticky header section sticks to the page and not to the wrapper. style.css removes every outline, so the
   chrome gets its keyboard ring back here. Generic section and colour-scheme rules come from sections.css
   (header.blade.php links it when a group is active), not from this file. */
.ss-chrome { display: contents; }
.ss-chrome :focus-visible { outline: 2px solid var(--ss-focus, var(--bs-primary)) !important; outline-offset: 2px; }

/* Sticky header: the section sticks; with the top bar on (desktop, 38px + 1px border) only the bar scrolls away. */
.ss-chrome .ss-section--header:has(> .main-sticky-top) { position: sticky; top: 0; z-index: 1020; }
@media (min-width: 992px) {
    .ss-chrome .ss-section--header:has(> .ss-notice):has(> .main-sticky-top) { top: -39px; }
}

/* Logo widths (0 = the standard size from the rules above). */
@media (min-width: 992px) {
    .ss-header--logo-w .ss-logo img { width: var(--ss-logo-w); height: auto; max-width: none; max-height: 96px; object-fit: contain; }
}
@media (max-width: 991.98px) {
    .ss-header--logo-w-m .ss-logo img { width: var(--ss-logo-w-m); height: auto; max-width: none; max-height: 64px; object-fit: contain; }
}
.ss-header--no-search .ss-actions { margin-inline-start: auto; }

/* Desktop menu row (header layout "menu below"). */
.navbar.ss-header .ss-nav { flex: 0 0 100%; border-top: 1px solid var(--ss-line); }
.ss-nav-list { display: flex; flex-wrap: wrap; gap: 0 4px; list-style: none; margin: 0; padding: 0; }
.ss-nav-item { position: relative; }
.ss-nav-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px; border: 0; background: none; color: var(--ss-ink); font-size: 15px; font-weight: 500; text-decoration: none; cursor: pointer; }
.ss-nav-link:hover, .ss-nav-link[aria-current="page"], .ss-nav-toggle[aria-expanded="true"] { color: var(--bs-primary); }
.ss-nav-toggle i { font-size: 12px; transition: transform .15s ease; }
.ss-nav-toggle[aria-expanded="true"] i { transform: rotate(180deg); }
.ss-nav-dropdown { display: none; position: absolute; top: 100%; inset-inline-start: 0; z-index: 1030; min-width: 240px; max-width: 360px; margin: 0; padding: 8px 0; list-style: none; background: #fff; border: 1px solid var(--ss-line); border-radius: 12px; box-shadow: 0 12px 32px rgba(17, 24, 39, .12); }
.ss-nav-item.is-open > .ss-nav-dropdown { display: block; }
/* No JavaScript yet (or at all): hover and keyboard focus open the dropdowns. */
.ss-nav:not(.is-ready) .ss-nav-item--parent:hover > .ss-nav-dropdown,
.ss-nav:not(.is-ready) .ss-nav-item--parent:focus-within > .ss-nav-dropdown { display: block; }
.ss-nav-sublink { display: flex; align-items: center; min-height: 44px; padding: 0 16px; color: var(--ss-ink); font-size: 14px; text-decoration: none; }
.ss-nav-sublink:hover, .ss-nav-sublink[aria-current="page"] { background: var(--ss-notice-bg); color: var(--bs-primary); }
.ss-nav-sublink--all { font-weight: 600; }
.ss-nav-sub { list-style: none; margin: 0 0 4px; padding: 0 0 0 12px; }
.ss-nav-sublink--3 { color: var(--ss-ink-soft); font-size: 13px; }
/* Dark header identities (style.css turns every header link light): the dropdown takes the header's colour. */
body.ss-theme-21 .ss-nav-dropdown { background: #29190f; border-color: rgba(255, 255, 255, .14); }
body.ss-theme-23 .ss-nav-dropdown { background: #16191d; border-color: rgba(255, 255, 255, .14); }
body.ss-theme-25 .ss-nav-dropdown { background: #101013; border-color: #26262c; }
body:is(.ss-theme-21, .ss-theme-23, .ss-theme-25) .ss-nav-sublink:hover { background: rgba(255, 255, 255, .08); }
@media (prefers-reduced-motion: reduce) {
    .ss-nav-toggle i { transition: none; }
}

/* Announcement bar. Without a colour scheme it is a dark strip; with one it takes the scheme's colours. */
.ss-section--announcement-bar:not([class~="ss-scheme"]) .ss-announce { background: #111827; color: #fff; }
.ss-announce { font-size: 13px; line-height: 1.4; }
.ss-announce-inner { display: flex; align-items: center; justify-content: center; gap: 8px; }
.ss-announce-list { flex: 1 1 auto; margin: 0; padding: 0; list-style: none; text-align: center; }
.ss-announce-item { display: flex; align-items: center; justify-content: center; min-height: 44px; }
.ss-announce-item[hidden] { display: none; }
.ss-announce-item a { display: inline-flex; align-items: center; min-height: 44px; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.ss-announce-toggle { flex: 0 0 44px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: transparent; color: inherit; }
.ss-announce-toggle[hidden] { display: none; }
.ss-announce-toggle:hover { background: rgba(255, 255, 255, .12); }
.ss-announce-item.is-entering { animation: ss-announce-in .35s ease; }
@keyframes ss-announce-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
    .ss-announce-item.is-entering { animation: none; }
}

/* Footer section, "columns" layout. */
.ss-section--footer:not([class~="ss-scheme"]) .ss-footer--columns { background: #f8f9fa; }
.ss-footer--columns { padding: 48px 0 32px; font-size: 14px; }
.ss-footer-heading { margin-bottom: 12px; font-size: 16px; font-weight: 700; }
.ss-footer-subheading { margin: 12px 0 6px; font-size: 14px; font-weight: 600; }
.ss-footer-links, .ss-footer-contact, .ss-footer-hours, .ss-footer-social, .ss-footer-payments { margin: 0; padding: 0; list-style: none; }
.ss-footer-links a { display: inline-flex; align-items: center; min-height: 44px; color: inherit; text-decoration: none; }
.ss-footer-links a:hover { color: var(--bs-primary); text-decoration: underline; }
.ss-footer-links--sub { padding-inline-start: 12px; }
.ss-footer-contact li { display: flex; align-items: flex-start; gap: 8px; margin-bottom: 4px; }
.ss-footer-contact li > i { margin-top: 3px; }
.ss-footer-contact a { display: inline-flex; align-items: center; min-height: 44px; margin-top: -12px; color: inherit; }
.ss-footer-hours li { display: flex; justify-content: space-between; gap: 12px; }
.ss-footer-social { display: flex; flex-wrap: wrap; gap: 8px; }
.ss-footer-social a { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid currentColor; border-radius: 50%; color: inherit; }
.ss-footer-apps { display: flex; flex-wrap: wrap; gap: 8px; }
.ss-footer-copy { margin: 24px 0 0; }
.ss-footer-payments { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ss-footer-payments img { width: auto; height: 24px; }
@media (max-width: 991.98px) {
    /* Room for the fixed bottom bar (.mobile-menu-footer). */
    .ss-footer--columns { padding-bottom: 88px; }
}

/* Mobile menu drawer of a section header. */
.ss-menu-drawer .ss-drawer-list { list-style: none; }
.ss-menu-drawer .ss-drawer-link { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-height: 48px; padding: 0 4px; border: 0; background: none; color: var(--primary-color, #111); font-size: 15px; text-align: start; text-decoration: none; cursor: pointer; }
.ss-menu-drawer summary { list-style: none; }
.ss-menu-drawer summary::-webkit-details-marker { display: none; }
.ss-menu-drawer .ss-drawer-chevron { transition: transform .15s ease; }
.ss-menu-drawer details[open] > summary .ss-drawer-chevron { transform: rotate(180deg); }
.ss-menu-drawer .ss-drawer-sub { list-style: none; padding-inline-start: 12px !important; }
.ss-menu-drawer .ss-drawer-sub .ss-drawer-item { border-bottom: 0 !important; }
.ss-menu-drawer .ss-drawer-heading { margin: 16px 4px 4px; color: #6b7280; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.ss-menu-drawer :focus-visible { outline: 2px solid var(--bs-primary) !important; outline-offset: -2px; }
@media (prefers-reduced-motion: reduce) {
    .ss-menu-drawer .ss-drawer-chevron { transition: none; }
}
/* The drawer's close button and logo link are full-size tap targets (44 x 44). */
.ss-menu-drawer .btn-close { box-sizing: border-box; width: 44px; height: 44px; padding: 14px; background-size: 16px; }
.ss-menu-drawer .offcanvas-header > a { display: inline-flex; align-items: center; min-height: 44px; }
