/* ==========================================================================
   storefront.css — shop-base storefront chrome + layout (Shop Minimal)
   --------------------------------------------------------------------------
   Strict grid minimalism: white ground, near-black ink, 1px hairlines,
   radius 0, uppercase micro-typography. TOKEN-ONLY (Layer B/C, var(--shop-*)).
   No hex literals; no raw px in padding/margin/gap (DESIGN.md §11 gates 1/3);
   raw px only for 1px hairlines + fixed component boxes; letter-spacing in em.
   Base tokens + @font-face come from shop-tokens.css (bundled in app.min.css);
   the admin Theme tab override <link> is injected after this file.
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html:has(body.storefront) {
    overscroll-behavior: none;
}
body.storefront {
    margin: 0;
    min-height: 100vh;
    background: var(--shop-bg);
    color: var(--shop-text);
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-base);
    line-height: var(--shop-lh-normal);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overscroll-behavior: none;
}
body.storefront img { max-width: 100%; height: auto; display: block; }
/* Inherit colour for plain links, but NOT buttons — `body.storefront a`
   (0,1,2) would otherwise outrank `.storefront-btn--primary` (0,1,0) and make
   white-on-ink button text inherit ink (invisible). */
body.storefront a:not(.storefront-btn) { color: inherit; }

/* shared container -------------------------------------------------------- */
.storefront-header__inner,
.storefront-footer__inner,
.storefront-section__inner,
.storefront-page__inner {
    width: 100%;
    max-width: var(--shop-container-max);
    margin-right: auto;
    margin-left: auto;
    padding-right: var(--shop-container-px);
    padding-left: var(--shop-container-px);
}

/* micro-typography helpers ------------------------------------------------ */
.storefront-eyebrow,
.storefront-section__eyebrow {
    display: block;
    margin-bottom: var(--shop-s-3);
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

/* skip-link --------------------------------------------------------------- */
.storefront-skip {
    position: absolute;
    left: var(--shop-s-2);
    top: var(--shop-s-2);
    z-index: var(--shop-z-toast);
    background: var(--shop-text);
    color: var(--shop-text-inverse);
    padding: var(--shop-s-2) var(--shop-s-4);
    border-radius: var(--shop-radius-none);
    font-size: var(--shop-text-sm);
    text-decoration: none;
    transform: translateY(-200%);
    transition: transform var(--shop-duration-fast) var(--shop-ease-out);
}
.storefront-skip:focus { transform: translateY(0); }

/* buttons ------------------------------------------------------------------
   Rectangular, radius 0, uppercase micro-type.
   Primary = ink block, hover inverts to white/ink outline.
   Ghost   = 1px ink outline, hover inverts to ink block.
   Ghost-inverse lives on ink bands (white outline).                        */
.storefront-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--shop-s-2);
    min-height: 44px;
    padding: var(--shop-btn-padding-y) var(--shop-s-8);
    border: 1px solid transparent;
    border-radius: var(--shop-btn-radius);
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
    transition: background var(--shop-duration-base) var(--shop-ease-out),
                color var(--shop-duration-base) var(--shop-ease-out),
                border-color var(--shop-duration-base) var(--shop-ease-out);
}
.storefront-btn--primary {
    background: var(--shop-accent);
    color: var(--shop-text-on-accent);
    border-color: var(--shop-accent);
}
.storefront-btn--primary:hover {
    background: var(--shop-bg);
    color: var(--shop-accent);
    border-color: var(--shop-accent);
}
.storefront-btn--ghost {
    background: transparent;
    color: var(--shop-text);
    border-color: var(--shop-border-strong);
}
.storefront-btn--ghost:hover {
    background: var(--shop-accent);
    color: var(--shop-text-on-accent);
    border-color: var(--shop-accent);
}
.storefront-btn--ghost-inverse {
    background: transparent;
    color: var(--shop-text-inverse);
    border-color: var(--shop-text-inverse);
}
.storefront-btn--ghost-inverse:hover {
    background: var(--shop-text-inverse);
    color: var(--shop-text);
    border-color: var(--shop-text-inverse);
}

/* ==========================================================================
   ANNOUNCEMENT BAR (configurable promo above the header — {{shop:banner}})
   ========================================================================== */
.shop-banner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--shop-s-3);
    padding: var(--shop-s-2) var(--shop-s-4);
    background: var(--shop-text);
    color: var(--shop-text-inverse);
    text-align: center;
}
.shop-banner[hidden] { display: none; }
.shop-banner__text {
    margin: 0;
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.shop-banner__link {
    font-weight: var(--shop-weight-semi);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}
.shop-banner__close {
    position: absolute;
    right: var(--shop-s-1);
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0;
    color: var(--shop-text-inverse);
    font-size: var(--shop-text-2xl);
    line-height: 1;
    cursor: pointer;
}

/* ==========================================================================
   HEADER — white, sticky, hairline bottom
   Desktop 3-zone grid: nav (left) · wordmark (centre) · icons (right)
   ========================================================================== */
.storefront-header {
    position: sticky;
    top: 0;
    z-index: var(--shop-z-header);
    background: var(--shop-bg);
    border-bottom: 1px solid var(--shop-border);
}
.storefront-header__inner {
    display: flex;
    align-items: center;
    gap: var(--shop-s-4);
    min-height: var(--shop-header-h);
}
@media (min-width: 768px) {
    .storefront-header__inner { min-height: var(--shop-header-h-md); }
}

.storefront-logo { display: inline-flex; align-items: center; text-decoration: none; line-height: var(--shop-lh-tight); }
/* optional uploaded logo replaces the text wordmark.
   body.storefront selector so it outranks the global `body.storefront img`
   reset (height:auto) — an SVG logo without it collapses to 0x0. */
body.storefront .storefront-logo__img { display: block; height: var(--shop-s-12); width: auto; max-width: none; }
body.storefront .storefront-logo__img[src=""] { display: none; }
.storefront-logo:has(.storefront-logo__img:not([src=""])) .storefront-logo__text { display: none; }
.storefront-logo__text {
    font-family: var(--shop-font-display);
    font-size: var(--shop-text-lg);
    font-weight: var(--shop-weight-semi);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    white-space: nowrap;
}

.storefront-actions {
    display: flex;
    align-items: center;
    gap: var(--shop-s-2);
    margin-left: auto;
}

/* burger ------------------------------------------------------------------ */
.storefront-burger {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: var(--shop-s-1);
    width: 44px;
    height: 44px;
    padding: var(--shop-s-3);
    background: transparent;
    border: 0;
    cursor: pointer;
    color: var(--shop-text);
}
.storefront-burger__line {
    display: block;
    width: 100%;
    height: 1px;
    background: currentColor;
    transition: transform var(--shop-duration-fast) var(--shop-ease-out),
                opacity var(--shop-duration-fast) var(--shop-ease-out);
}

/* nav-drawer (mobile = slide-out left drawer; desktop = inline) ----------- */
.storefront-nav__close {
    align-self: flex-end;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 0;
    font-size: var(--shop-text-3xl);
    line-height: 1;
    color: var(--shop-text);
    cursor: pointer;
}
.storefront-nav {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 84vw;
    max-width: 360px;
    z-index: var(--shop-z-drawer);
    background: var(--shop-bg);
    border-right: 1px solid var(--shop-border);
    padding: var(--shop-s-4) var(--shop-container-px) var(--shop-s-8);
    display: flex;
    flex-direction: column;
    gap: var(--shop-s-2);
    transform: translateX(-100%);
    visibility: hidden;
    overflow-y: auto;
    transition: transform var(--shop-duration-base) var(--shop-ease-out),
                visibility var(--shop-duration-base) var(--shop-ease-out);
}
.storefront-header.is-nav-open .storefront-nav {
    transform: translateX(0);
    visibility: visible;
}
.storefront-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: var(--shop-s-1);
}
.storefront-nav a {
    display: block;
    padding: var(--shop-s-4) 0;
    font-size: var(--shop-text-sm);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--shop-text);
    border-bottom: 1px solid var(--shop-border);
}
.storefront-nav a:hover {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.4em;
}

.storefront-nav-backdrop {
    position: fixed;
    inset: 0;
    z-index: calc(var(--shop-z-header) - 1);
    background: var(--shop-bg-overlay);
    opacity: 0;
    transition: opacity var(--shop-duration-base) var(--shop-ease-out);
}
.storefront-nav-backdrop:not([hidden]) { opacity: 1; }

@media (min-width: 900px) {
    .storefront-burger,
    .storefront-nav__close { display: none; }
    /* 3-column grid: menu (start) · brand (true centre) · actions (end). The
       auto centre column is centred by the symmetric 1fr side columns, so the
       brand sits at the real header midpoint regardless of menu/actions widths. */
    .storefront-header__inner {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
    }
    /* Pin all three to row 1 (sparse auto-flow can't backtrack across the
       explicit column placements). Brand LEFT, menu CENTER, actions RIGHT. */
    .storefront-logo { grid-column: 1; grid-row: 1; justify-self: start; }
    .storefront-nav  { grid-column: 2; grid-row: 1; justify-self: center; }
    .storefront-actions { grid-column: 3; grid-row: 1; justify-self: end; }
    .storefront-nav {
        position: static;
        width: auto;
        max-width: none;
        transform: none;
        visibility: visible;
        overflow: visible;
        border-right: 0;
        background: transparent;
        padding: 0;
        flex-direction: row;
    }
    .storefront-nav ul {
        flex-direction: row;
        align-items: center;
        gap: var(--shop-s-6);
    }
    .storefront-nav a {
        padding: var(--shop-s-2) 0;
        font-size: var(--shop-text-xs);
        border-bottom: 0;
    }
    .storefront-nav-backdrop { display: none; }
    /* search + account live in the header actions on desktop, not the drawer.
       `.storefront-header` prefix wins over the base drawer rules below. */
    .storefront-header .storefront-nav__search,
    .storefront-header .storefront-nav__account { display: none; }
}

/* mobile header layout: burger left · wordmark centre · icons right -------- */
@media (max-width: 899px) {
    .storefront-header__inner { position: relative; }
    .storefront-logo {
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
    }
    /* secondary actions move into the nav-drawer on mobile (cart + ♥ stay).
       `.storefront-header` prefix raises specificity above the base
       action-icon rule (which appears later in source). */
    .storefront-header .storefront-actions .shop-search-toggle,
    .storefront-header .storefront-actions .shop-account-icon { display: none; }

    /* The drawer is nested in the header's (sticky) stacking context, so the
       backdrop can't paint above it. While the drawer is open, hide the header
       actions so the cart/♥ icons in the uncovered right strip aren't clickable
       behind the modal. */
    .storefront-header.is-nav-open .storefront-actions { visibility: hidden; }
}

/* nav-drawer search + account (mobile only) ------------------------------- */
.storefront-nav__search {
    display: flex;
    align-items: center;
    gap: var(--shop-s-2);
    margin-bottom: var(--shop-s-4);
    padding: 0 var(--shop-s-3);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius-none);
}
.storefront-nav__search-input {
    flex: 1 1 auto;
    min-width: 0;
    padding: var(--shop-s-3) 0;
    border: 0;
    background: transparent;
    color: var(--shop-text);
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-base);
}
.storefront-nav__search-input:focus { outline: none; }
.storefront-nav__search-btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 0;
    color: var(--shop-text-muted);
    cursor: pointer;
}
.storefront-nav__account {
    margin-top: var(--shop-s-2);
    padding: var(--shop-s-4) 0;
    font-size: var(--shop-text-sm);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--shop-text);
}
.storefront-nav__account:hover {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.4em;
}

/* header action icons (search/wishlist/account/cart) ---------------------- */
.storefront-actions .shop-cart-icon,
.storefront-actions .shop-wishlist-icon,
.storefront-actions .shop-account-icon,
.storefront-actions .shop-search-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 0;
    color: var(--shop-text);
    text-decoration: none;
    cursor: pointer;
    position: relative;
    transition: opacity var(--shop-duration-fast) var(--shop-ease-out);
}
.storefront-actions .shop-cart-icon:hover,
.storefront-actions .shop-wishlist-icon:hover,
.storefront-actions .shop-account-icon:hover,
.storefront-actions .shop-search-toggle:hover { opacity: 0.6; }

.shop-wishlist-icon__glyph,
.shop-cart-icon__glyph { position: relative; display: inline-flex; }
.shop-wishlist-icon__count,
.shop-cart-icon__count {
    position: absolute;
    top: -6px;
    right: -8px;
    min-width: 16px;
    height: 16px;
    padding: 0 var(--shop-s-1);
    border-radius: var(--shop-radius-full);
    background: var(--shop-text);
    color: var(--shop-text-inverse);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-semi);
    line-height: 16px;
    text-align: center;
}

/* search overlay ---------------------------------------------------------- */
.storefront-search {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--shop-z-modal);
    background: var(--shop-bg);
    border-bottom: 1px solid var(--shop-border);
    padding: var(--shop-s-4) var(--shop-container-px);
}
.storefront-search__form {
    display: flex;
    align-items: center;
    gap: var(--shop-s-3);
    max-width: var(--shop-container-max);
    margin-right: auto;
    margin-left: auto;
}
.storefront-search__glass { display: inline-flex; flex-shrink: 0; color: var(--shop-text-muted); }
.storefront-search__input {
    flex: 1 1 auto;
    min-width: 0;
    padding: var(--shop-s-3) 0;
    border: 0;
    background: transparent;
    color: var(--shop-text);
    font-family: var(--shop-font-display);
    font-size: var(--shop-text-xl);
    font-weight: var(--shop-weight-medium);
}
.storefront-search__input:focus { outline: none; }
.storefront-search__submit {
    flex-shrink: 0;
    min-height: 44px;
    padding: var(--shop-s-2) var(--shop-s-5);
    background: var(--shop-text);
    color: var(--shop-text-inverse);
    border: 1px solid var(--shop-text);
    border-radius: var(--shop-btn-radius);
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background var(--shop-duration-base) var(--shop-ease-out),
                color var(--shop-duration-base) var(--shop-ease-out);
}
.storefront-search__submit:hover {
    background: var(--shop-bg);
    color: var(--shop-text);
}
.storefront-search__close {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 0;
    font-size: var(--shop-text-3xl);
    line-height: 1;
    color: var(--shop-text);
    cursor: pointer;
}

/* ==========================================================================
   CART DRAWER (ST3) — slide-out mini-cart (DOM built by shop.js)
   ========================================================================== */
.shop-cart-drawer {
    position: fixed;
    inset: 0;
    z-index: var(--shop-z-modal);
    visibility: hidden;
    opacity: 0;
    transition: opacity var(--shop-duration-base) var(--shop-ease-out),
                visibility var(--shop-duration-base) var(--shop-ease-out);
}
.shop-cart-drawer.is-open { visibility: visible; opacity: 1; }
.shop-cart-drawer__backdrop {
    position: absolute;
    inset: 0;
    background: var(--shop-bg-overlay);
}
.shop-cart-drawer__panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 92vw;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    background: var(--shop-bg);
    border-left: 1px solid var(--shop-border);
    transform: translateX(100%);
    transition: transform var(--shop-duration-base) var(--shop-ease-out);
}
.shop-cart-drawer.is-open .shop-cart-drawer__panel { transform: translateX(0); }

.shop-cart-drawer__head {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--shop-s-3);
    padding: var(--shop-s-4) var(--shop-container-px);
    border-bottom: 1px solid var(--shop-border);
}
.shop-cart-drawer__title {
    margin: 0;
    font-family: var(--shop-font-display);
    font-size: var(--shop-text-lg);
    font-weight: var(--shop-weight-semi);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--shop-text);
}
.shop-cart-drawer__close {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 0;
    font-size: var(--shop-text-3xl);
    line-height: 1;
    color: var(--shop-text);
    cursor: pointer;
}
.shop-cart-drawer__close:hover { opacity: 0.6; }

.shop-cart-drawer__body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: var(--shop-s-2) var(--shop-container-px);
}
.shop-cart-drawer__items {
    list-style: none;
    margin: 0;
    padding: 0;
}
.shop-cart-drawer__item {
    position: relative;
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: var(--shop-s-3);
    padding: var(--shop-s-4) 0;
    border-bottom: 1px solid var(--shop-border);
}
.shop-cart-drawer__thumb {
    width: 64px;
    height: 80px;
    /* contain + centered so the whole product shows (cover crops the top). */
    object-fit: contain;
    object-position: center;
    border-radius: var(--shop-radius-none);
    background: var(--shop-bg-alt);
}
.shop-cart-drawer__thumb--empty { display: block; }
.shop-cart-drawer__main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: var(--shop-s-1);
    padding-right: var(--shop-s-6);
}
.shop-cart-drawer__name {
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-sm);
    font-weight: var(--shop-weight-medium);
    line-height: var(--shop-lh-snug);
    color: var(--shop-text);
    text-decoration: none;
}
.shop-cart-drawer__name:hover { text-decoration: underline; text-underline-offset: 0.25em; }
.shop-cart-drawer__variant {
    margin: 0;
    font-size: var(--shop-text-sm);
    color: var(--shop-text-muted);
}
.shop-cart-drawer__row {
    margin-top: var(--shop-s-1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--shop-s-3);
}
.shop-cart-drawer__qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius-none);
}
.shop-cart-drawer__qty-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 0;
    color: var(--shop-text);
    cursor: pointer;
}
.shop-cart-drawer__qty-btn:disabled { color: var(--shop-text-muted); cursor: default; }
.shop-cart-drawer__qty-btn:not(:disabled):hover { background: var(--shop-bg-alt); }
.shop-cart-drawer__qty-val {
    min-width: 32px;
    text-align: center;
    font-size: var(--shop-text-sm);
    font-variant-numeric: tabular-nums;
    color: var(--shop-text);
}
.shop-cart-drawer__price {
    font-size: var(--shop-text-base);
    font-weight: var(--shop-weight-semi);
    color: var(--shop-text);
    white-space: nowrap;
}
.shop-cart-drawer__remove {
    position: absolute;
    top: var(--shop-s-3);
    right: 0;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0;
    color: var(--shop-text-muted);
    cursor: pointer;
}
.shop-cart-drawer__remove:hover { color: var(--shop-text); }

.shop-cart-drawer__foot {
    flex-shrink: 0;
    padding: var(--shop-s-4) var(--shop-container-px) var(--shop-s-6);
    border-top: 1px solid var(--shop-border);
}
.shop-cart-drawer__subtotal {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: var(--shop-s-4);
    font-size: var(--shop-text-base);
    color: var(--shop-text);
}
.shop-cart-drawer__subtotal-value {
    font-size: var(--shop-text-xl);
    font-weight: var(--shop-weight-semi);
}
/* Quantity-discount + total lines in the drawer footer. The discount row sits
   tight under the subtotal; its value is smaller than the headline subtotal. */
.shop-cart-drawer__subtotal--discount {
    margin-top: calc(-1 * var(--shop-s-3));
    margin-bottom: var(--shop-s-2);
    font-size: var(--shop-text-sm);
    color: var(--shop-success-text);
}
.shop-cart-drawer__subtotal--discount .shop-cart-drawer__subtotal-value {
    font-size: var(--shop-text-sm);
    font-weight: var(--shop-weight-medium);
    color: var(--shop-success-text);
}
.shop-cart-drawer__subtotal--total {
    padding-top: var(--shop-s-3);
    border-top: 1px solid var(--shop-border);
}
.shop-cart-drawer__checkout {
    display: block;
    width: 100%;
    padding: var(--shop-s-3) var(--shop-s-5);
    background: var(--shop-text);
    color: var(--shop-text-inverse);
    border: 1px solid var(--shop-text);
    border-radius: var(--shop-btn-radius);
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    text-align: center;
    text-decoration: none;
    transition: background var(--shop-duration-base) var(--shop-ease-out),
                color var(--shop-duration-base) var(--shop-ease-out);
}
.shop-cart-drawer__checkout:hover {
    background: var(--shop-bg);
    color: var(--shop-text);
}
.shop-cart-drawer__view {
    display: block;
    margin-top: var(--shop-s-3);
    text-align: center;
    font-size: var(--shop-text-sm);
    color: var(--shop-text-muted);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}
.shop-cart-drawer__view:hover { color: var(--shop-text); }

.shop-cart-drawer__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: var(--shop-s-2);
    padding: var(--shop-s-8) var(--shop-s-4);
}
.shop-cart-drawer__empty-title {
    margin: 0;
    font-family: var(--shop-font-display);
    font-size: var(--shop-text-xl);
    font-weight: var(--shop-weight-medium);
    color: var(--shop-text);
}
.shop-cart-drawer__empty-text {
    margin: 0;
    font-size: var(--shop-text-sm);
    color: var(--shop-text-muted);
}
.shop-cart-drawer__empty-link {
    margin-top: var(--shop-s-2);
    font-size: var(--shop-text-sm);
    color: var(--shop-text);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}

/* The site-wide base rule `body.storefront a:not(.storefront-btn){color:inherit}`
   (specificity 0,2,2) out-ranks the single-class drawer link rules above, so the
   action links would inherit ink — fatally, the checkout button would be ink-on-ink.
   Re-assert their colours with a `body.storefront a.<class>` selector (ties on
   specificity, wins on source order). Backgrounds are untouched by the base rule. */
body.storefront a.shop-cart-drawer__name { color: var(--shop-text); }
body.storefront a.shop-cart-drawer__checkout { color: var(--shop-text-inverse); }
body.storefront a.shop-cart-drawer__checkout:hover { color: var(--shop-text); }
body.storefront a.shop-cart-drawer__view { color: var(--shop-text-muted); }
body.storefront a.shop-cart-drawer__view:hover { color: var(--shop-text); }
body.storefront a.shop-cart-drawer__empty-link { color: var(--shop-text); }
/* Same trap for the generic button-as-link classes (cart page checkout /
   continue / empty-state browse): without this they inherit ink → ink-on-ink. */
body.storefront a.shop-btn-gradient { color: var(--shop-btn-primary-text); }
body.storefront a.shop-btn-gradient:hover { color: var(--shop-btn-primary-hover-text); }
body.storefront a.shop-btn-outline { color: var(--shop-btn-ghost-text); }
body.storefront a.shop-btn-outline:hover { color: var(--shop-btn-ghost-hover-text); }

@media (prefers-reduced-motion: reduce) {
    .shop-cart-drawer,
    .shop-cart-drawer__panel { transition: none; }
}

/* ==========================================================================
   HERO — 3 owner-selectable modes (section-level select id="mode"):
     --photo   first slide only, full-bleed cover, no text/controls (default,
               baked into the template markup for the no-JS path)
     --slider  autoplay crossfade over all slides, line-dash indicators,
               no arrows/text (storefront.js HeroSlider)
     --classic first slide as background + scrim + centred text/CTA block
   storefront.js reads the hidden mode <span> and swaps the mode class.
   ========================================================================== */
.storefront-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}
.storefront-hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 70vh;
    overflow: hidden;
    background: var(--shop-bg-alt);
}
/* phones: a 70vh band over-crops the wide banner — keep it shorter */
@media (max-width: 767px) {
    .storefront-hero { min-height: 48vh; }
}
/* The section-level select renders as a hidden metadata span; hide it in the
   raw template state too (before content substitution inlines display:none). */
.storefront-hero__mode { display: none; }

/* slide stack — fills the band in every mode ------------------------------ */
.storefront-hero__slides {
    position: absolute;
    inset: 0;
}
.storefront-hero__slide {
    position: absolute;
    inset: 0;
}
/* Scoped so `height: 100%` outranks the global `body.storefront img
   { height: auto }` reset (0,1,2) — without this the hero img keeps its
   intrinsic ratio and never cover-crops the band. Static centre crop. */
.storefront-hero /* slide link wrapper — fills the slide; empty href is neutralised in JS */
.storefront-hero__slide-link { display: block; width: 100%; height: 100%; cursor: pointer; }
.storefront-hero__slide-link:not([href]) { cursor: default; }
/* Scoped (0,2,0) so height:100% outranks the `body.storefront img
   { height: auto }` reset (0,1,2) — otherwise the image keeps its intrinsic
   ratio and floats as a thin strip inside the 70vh band (visible on mobile). */
.storefront-hero .storefront-hero__media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}
/* Empty media collapses — the band keeps its --shop-bg-alt ground. */
.storefront-hero__media:not([src]),
.storefront-hero__media[src=""] { display: none; }
/* Editor-bridge hover-highlight adds `.nwl-highlight` { position: relative },
   which (equal specificity, loaded later) would drop the slide into normal
   flow and make the hero jump. Pin it absolute regardless. */
.storefront-hero__slide.nwl-highlight,
.storefront-hero__slide.nwl-highlight--active,
.storefront-hero__slide.nwl-highlight--container {
    position: absolute !important;
}

/* scrim + text: hidden by default, mode classes opt them in ---------------- */
.storefront-hero__scrim {
    position: absolute;
    inset: 0;
    opacity: 0;
    background: var(--shop-hero-scrim);
}
.storefront-hero__inner { display: none; }

/* MODE photo (default): first slide only, nothing else -------------------- */
.storefront-hero--photo .storefront-hero__slide:not(:first-child) { display: none; }
/* Photo mode is a single full-bleed banner. From tablet up, size the band by
   the banner's own aspect ratio instead of a fixed 70vh: a 70vh cover-crop on a
   wide 2:1 banner clipped the top of the composition on wide viewports, hiding
   it under the sticky header. Aspect-ratio sizing shows the banner whole, so it
   always sits fully below the header. Phones keep the 48vh cover band (a wide
   banner can't show whole on a narrow screen). Ratio matches the demo banner;
   override --storefront-hero-ratio to match a different uploaded image. */
@media (min-width: 768px) {
    .storefront-hero--photo {
        min-height: 0;
        aspect-ratio: var(--storefront-hero-ratio, 1773 / 887);
    }
}

/* MODE slider: crossfade stack + indicators (built by storefront.js) ------- */
.storefront-hero--slider { background: var(--shop-text); }
.storefront-hero--slider .storefront-hero__slide {
    opacity: 0;
    transition: opacity var(--shop-duration-slower) var(--shop-ease-out);
}
/* Before JS boots (or with JS off) the first slide stands in statically. */
.storefront-hero--slider .storefront-hero__slides:not(.is-init) .storefront-hero__slide:first-child { opacity: 1; }
.storefront-hero--slider .storefront-hero__slide.is-active { opacity: 1; z-index: 1; }
/* The just-departed slide holds full opacity beneath the incoming one so the
   crossfade never dips to the hero background. */
.storefront-hero--slider .storefront-hero__slide.is-leaving { opacity: 1; z-index: 0; }
.storefront-hero__indicators {
    position: absolute;
    left: 50%;
    bottom: var(--shop-s-6);
    z-index: 2;
    display: flex;
    gap: var(--shop-s-2);
    transform: translateX(-50%);
}
.storefront-hero__indicator {
    display: block;
    width: var(--shop-s-8);
    height: 2px;
    background: var(--shop-text-inverse);
    opacity: 0.35;
    transition: opacity var(--shop-duration-base) var(--shop-ease-out);
}
.storefront-hero__indicator.is-active { opacity: 1; }

/* MODE classic: first slide as background + scrim + centred text/CTA ------- */
.storefront-hero--classic { background: var(--shop-text); }
.storefront-hero--classic .storefront-hero__slide:not(:first-child) { display: none; }
.storefront-hero--classic .storefront-hero__scrim { opacity: 1; }
.storefront-hero--classic .storefront-hero__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: var(--shop-container-max);
    margin-right: auto;
    margin-left: auto;
    padding: var(--shop-s-24) var(--shop-container-px);
    text-align: center;
}
.storefront-hero__eyebrow {
    display: block;
    margin-bottom: var(--shop-s-4);
    color: var(--shop-text-inverse);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.16em;
    text-transform: uppercase;
}
.storefront-hero__title {
    margin: 0 0 var(--shop-s-4);
    max-width: 18ch;
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    line-height: var(--shop-lh-tight);
    letter-spacing: var(--shop-tracking-tight);
    color: var(--shop-text-inverse);
}
.storefront-hero__subtitle {
    margin: 0 0 var(--shop-s-8);
    max-width: 48ch;
    color: var(--shop-text-inverse);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
}

/* ==========================================================================
   SECTIONS — left-aligned heads; optional right-side text link
   ========================================================================== */
.storefront-section__inner {
    padding-top: var(--shop-s-20);
    padding-bottom: var(--shop-s-20);
}
.storefront-section__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--shop-s-4);
    margin-bottom: var(--shop-s-10);
    text-align: left;
}
.storefront-section__eyebrow { margin-bottom: var(--shop-s-2); }
.storefront-section__title {
    margin: 0;
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    line-height: var(--shop-lh-snug);
    letter-spacing: var(--shop-tracking-tight);
}
.storefront-section__link {
    flex-shrink: 0;
    padding-bottom: var(--shop-s-1);
    color: var(--shop-text);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.4em;
    white-space: nowrap;
    transition: opacity var(--shop-duration-fast) var(--shop-ease-out);
}
/* centred variant for home section heads */
.storefront-section__head--center {
    justify-content: center;
    text-align: center;
}
.storefront-section__head--center .storefront-section__eyebrow::before,
.storefront-section__head--center .storefront-section__eyebrow::after { content: none; }

.storefront-section__link::after { content: "\2192"; margin-left: var(--shop-s-2); }
.storefront-section__link:hover { opacity: 0.6; }

/* ==========================================================================
   CATEGORY BAND (home) — full-width band, hairline top+bottom; restyles the
   {{shop:categories}} output (.shop-cat-cards from ShopRenderer) into a
   horizontal row of uppercase cells separated by hairline verticals.
   ========================================================================== */
.storefront-cats {
    border-top: 1px solid var(--shop-border);
    border-bottom: 1px solid var(--shop-border);
}
.storefront-cats__inner {
    padding-top: var(--shop-s-16);
    padding-bottom: var(--shop-s-16);
}
.storefront-cats__head { margin-bottom: var(--shop-s-8); text-align: center; }
/* hairline-table trick: container draws top+left, every cell right+bottom —
   survives any category count and any wrap point. */
/* Photo tiles: category image (inline background-image from ShopRenderer)
   as a 4/3 tile with a white caption bar; falls back to bg-alt when the
   category has no image. */
.storefront-cats .shop-cat-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--shop-s-4);
}
@media (min-width: 900px) {
    .storefront-cats .shop-cat-cards { grid-template-columns: repeat(4, 1fr); gap: var(--shop-s-5); }
}
.storefront-cats .shop-cat-card {
    display: block;
    aspect-ratio: auto;
    height: auto;
    overflow: visible;
    border-radius: var(--shop-radius-none);
    /* the inline background-image paints in ::before (the photo area) only —
       hide it on the card itself so it can't bleed behind the name row */
    background-size: 0 0 !important;
    background-color: transparent !important;
    background-repeat: no-repeat;
    text-decoration: none;
}
.storefront-cats .shop-cat-card::before {
    content: "";
    display: block;
    aspect-ratio: var(--shop-pc-image-ratio);
    background: inherit;
    background-color: var(--shop-bg-alt);
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat;
}
.storefront-cats .shop-cat-card__icon { display: none; }
.storefront-cats .shop-cat-card__name {
    display: block;
    padding: var(--shop-s-4) var(--shop-s-2) 0;
    text-align: center;
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--shop-text);
    transition: background-color var(--shop-duration-fast) var(--shop-ease-out),
                color var(--shop-duration-fast) var(--shop-ease-out);
}
.storefront-cats .shop-cat-card:hover .shop-cat-card__name {
    text-decoration: underline;
    text-underline-offset: 0.35em;
    text-decoration-thickness: 1px;
}

/* ==========================================================================
   FEATURED (home) — one symmetric row (scroll-snap carousel when more than
   fit). Cards are deliberately NOT catalog-like: bg-alt panel, centred text,
   no add-to-cart/qty chrome; the image keeps var(--shop-pc-image-ratio).
   ========================================================================== */
.storefront-featured .shop-featured,
.storefront-featured .shop-featured.shop-featured--centered {
    display: flex;
    gap: var(--shop-s-5);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding-bottom: var(--shop-s-2);
}
.storefront-featured .shop-featured::-webkit-scrollbar { display: none; }
.storefront-featured .shop-featured > .shop-card {
    flex: 0 0 78%;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    background: var(--shop-bg-alt);
    padding: var(--shop-s-5);
    text-align: center;
}
@media (min-width: 640px) {
    .storefront-featured .shop-featured > .shop-card { flex-basis: calc((100% - var(--shop-s-5)) / 2); }
}
@media (min-width: 1024px) {
    .storefront-featured .shop-featured > .shop-card { flex-basis: calc((100% - 3 * var(--shop-s-5)) / 4); }
}
/* image tile keeps the theme ratio, sits on white inside the panel —
   without the module's accent border (the bg-alt panel is frame enough) */
.storefront-featured .shop-card__img-wrap,
.storefront-featured .shop-card--featured .shop-card__img-wrap {
    background: var(--shop-bg);
    border: 0;
}
/* centred meta, display-font name, roomier price */
.storefront-featured .shop-card__title,
.storefront-featured .shop-card__name {
    font-family: var(--shop-font-display);
    font-size: var(--shop-text-base);
    text-align: center;
}
.storefront-featured .shop-card__price { text-align: center; justify-content: center; }
/* hide catalog chrome — the whole card reads as a curated highlight
   (the ХІТ badge stays: it labels the curated row) */
.storefront-featured .shop-card__btn,
.storefront-featured .shop-card .shop-qty { display: none; }
/* slider arrows — thin hairline squares at the row's sides (desktop only) */
.storefront-featured .storefront-section__inner { position: relative; }
.storefront-featured__arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--shop-border-strong);
    background: var(--shop-bg);
    color: var(--shop-text);
    cursor: pointer;
    transition: background-color var(--shop-duration-fast) var(--shop-ease-out),
                color var(--shop-duration-fast) var(--shop-ease-out);
}
.storefront-featured__arrow:hover { background: var(--shop-accent); color: var(--shop-text-on-accent); border-color: var(--shop-accent); }
.storefront-featured__arrow--prev { left: calc(-1 * var(--shop-s-3)); }
.storefront-featured__arrow--next { right: calc(-1 * var(--shop-s-3)); }
.storefront-featured__arrow[disabled] { opacity: 0.3; cursor: default; }
.storefront-featured__arrow[disabled]:hover { background: var(--shop-bg); color: var(--shop-text); border-color: var(--shop-border-strong); }
@media (min-width: 1024px) {
    .storefront-featured.has-overflow .storefront-featured__arrow { display: inline-flex; }
}



/* ==========================================================================
   SALE (home «Акції») — uniform catalog-style grid (deliberately NOT the
   featured carousel): sale badges stay visible, corner cart present.
   ========================================================================== */
.storefront-sale { background: var(--shop-bg); border-top: 1px solid var(--shop-border); }
.storefront-sale .shop-sale-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--shop-s-5);
}
@media (min-width: 900px) {
    .storefront-sale .shop-sale-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1200px) {
    .storefront-sale .shop-sale-grid { gap: var(--shop-s-6); }
    /* 7–12 sale items → denser 4-up rows (renderer adds the modifier) */
    .storefront-sale .shop-sale-grid--cols-4 { grid-template-columns: repeat(4, 1fr); }
}

/* ==========================================================================
   SPLIT BAND (home «Про магазин») — asymmetric 7/12 image | 5/12 text,
   text vertically centred, uppercase caption under the image
   ========================================================================== */
.storefront-split { border-top: 1px solid var(--shop-border); }
.storefront-split__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--shop-s-10);
    align-items: center;
}
@media (min-width: 900px) {
    .storefront-split__inner { grid-template-columns: 1fr 1fr; gap: var(--shop-s-16); align-items: center; }
    .storefront-split__text { align-self: center; }
}
.storefront-split__media {
    aspect-ratio: 1 / 1;
    background: var(--shop-bg-alt);
    overflow: hidden;
}
/* wider 7/12 column → landscape crop instead of the mobile portrait */

/* checklist — accent check squares */
.storefront-split__checks {
    list-style: none;
    margin: var(--shop-s-6) 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: var(--shop-s-3);
}
.storefront-split__check {
    display: flex;
    align-items: center;
    gap: var(--shop-s-3);
    font-size: var(--shop-text-sm);
}
.storefront-split__check::before {
    content: "";
    flex: 0 0 auto;
    width: var(--shop-s-5);
    height: var(--shop-s-5);
    background-color: var(--shop-accent);
    -webkit-mask: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2.4"><polyline points="20 6 9 17 4 12"/></svg>') center / contain no-repeat;
    mask: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="white" stroke-width="2.4"><polyline points="20 6 9 17 4 12"/></svg>') center / contain no-repeat;
}
.storefront-split__caption {
    text-align: center;
    display: block;
    margin-top: var(--shop-s-3);
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.storefront-split__img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform calc(var(--shop-duration-slower) * 1.6) var(--shop-ease-in-out);
}
.storefront-split__media:hover .storefront-split__img { transform: scale(1.05); }
.storefront-split__img[src=""],
.storefront-split__img:not([src]) { display: none; }
.storefront-split__body {
    margin: var(--shop-s-5) 0 var(--shop-s-8);
    max-width: 48ch;
    color: var(--shop-text-muted);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
}
.storefront-split__body p { margin: 0 0 var(--shop-s-4); }
.storefront-split__body p:last-child { margin-bottom: 0; }

/* ==========================================================================
   NUMBERS BAND (home) — bg-alt, 3 columns separated by hairline rules:
   huge display figure + small muted uppercase label
   ========================================================================== */
.storefront-numbers {
    background: linear-gradient(to bottom,
        var(--shop-bg) 0%,
        var(--shop-bg-alt) 22%,
        var(--shop-bg-alt) 78%,
        var(--shop-bg) 100%);
}
.storefront-numbers__inner {
    display: grid;
    grid-template-columns: 1fr;
    padding-top: var(--shop-s-20);
    padding-bottom: var(--shop-s-20);
}
@media (min-width: 768px) {
    .storefront-numbers__inner { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
    .storefront-numbers__inner { grid-template-columns: repeat(4, 1fr); }
}
.storefront-numbers__cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: var(--shop-s-4);
    padding: var(--shop-s-6) var(--shop-s-8);
}
@media (min-width: 1024px) {
    .storefront-numbers__cell { border-bottom: 0; }
}
.storefront-numbers__value {
    font-family: var(--shop-font-display);
    font-size: clamp(3rem, 5.5vw, 4.75rem);
    font-weight: var(--shop-weight-semi);
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--shop-text);
}
/* short accent tick between the figure and its label */
.storefront-numbers__cell::after {
    content: "";
    order: 2;
    width: var(--shop-s-8);
    height: 2px;
    background: var(--shop-accent);
}
.storefront-numbers__value { order: 1; }
.storefront-numbers__label {
    order: 3;
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

/* ==========================================================================
   CTA BAND — full-bleed ink; the single centred exception
   ========================================================================== */
.storefront-cta-band {
    position: relative;
    isolation: isolate;
    background: var(--shop-text);
    color: var(--shop-text-inverse);
    overflow: hidden;
}
/* editable background banner behind an ink scrim (text always readable);
   blurred so busy covers never compete with the CTA copy — slight scale-up
   keeps the blurred edge from revealing the band background */
.storefront-cta-band__bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(14px);
    transform: scale(1.06);
}
.storefront-cta-band__bg[src=""] { display: none; }
.storefront-cta-band::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--shop-hero-scrim);
}
.storefront-cta-band__inner {
    padding-top: var(--shop-s-10);
    padding-bottom: var(--shop-s-10);
}
/* inset hairline frame — the band reads as a deliberate closing plate */
.storefront-cta-band__frame {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--shop-s-8);
    padding: var(--shop-s-20) var(--shop-s-8);
    border: 1px solid var(--shop-text-inverse);
    text-align: center;
}
.storefront-cta-band__eyebrow {
    color: var(--shop-text-inverse);
    opacity: 0.6;
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.2em;
    text-transform: uppercase;
}
.storefront-cta-band__title {
    margin: 0;
    max-width: 18ch;
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-semi);
    font-size: clamp(2.25rem, 5vw, 3.75rem);
    line-height: var(--shop-lh-tight);
    letter-spacing: -0.01em;
}
.storefront-cta-band .storefront-btn--solid-inverse {
    background: var(--shop-text-inverse);
    color: var(--shop-text);
    border-color: var(--shop-text-inverse);
}
.storefront-cta-band .storefront-btn--solid-inverse:hover {
    background: transparent;
    color: var(--shop-text-inverse);
}
.storefront-cta-band__note {
    margin: 0;
    color: var(--shop-text-inverse);
    opacity: 0.55;
    font-size: var(--shop-text-xs);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

/* ==========================================================================
   PAGE HEAD (about / contacts) — big display H1 under a hairline
   ========================================================================== */
.storefront-pagehead { border-bottom: 1px solid var(--shop-border); }
.storefront-pagehead__inner {
    padding-top: var(--shop-s-20);
    padding-bottom: var(--shop-s-16);
}
.storefront-pagehead__title {
    margin: 0;
    max-width: 20ch;
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: clamp(2.25rem, 5vw, 3.75rem);
    line-height: var(--shop-lh-tight);
    letter-spacing: var(--shop-tracking-tight);
}
.storefront-pagehead__lead {
    margin-top: var(--shop-s-5);
    max-width: 56ch;
    color: var(--shop-text-muted);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
}
.storefront-pagehead__lead p { margin: 0 0 var(--shop-s-3); }
.storefront-pagehead__lead p:last-child { margin-bottom: 0; }
/* centred hero variant (about) */
.storefront-pagehead--center .storefront-pagehead__inner { text-align: center; }
.storefront-pagehead--center .storefront-pagehead__title,
.storefront-pagehead--center .storefront-pagehead__lead {
    margin-left: auto;
    margin-right: auto;
}

/* ==========================================================================
   ABOUT — magazine story: photo|text chapters, pull-quote, outro link
   ========================================================================== */
/* chapters sit closer than regular sections — the flow arrows carry the
   rhythm between them, so the default s-20 stack would read as a hole */
.storefront-chapter .storefront-section__inner {
    padding-top: var(--shop-s-12);
    padding-bottom: var(--shop-s-12);
}
/* hand-drawn flow arrow between blocks — centred, small, no full-width rule */
.storefront-flow {
    display: flex;
    justify-content: center;
    padding: var(--shop-s-2) 0;
    color: var(--shop-text-muted);
}
.storefront-flow__arrow { width: var(--shop-s-16); height: auto; }
.storefront-flow--flip .storefront-flow__arrow { transform: scaleX(-1); }

.storefront-chapter__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--shop-s-8);
    align-items: center;
}
@media (min-width: 900px) {
    .storefront-chapter__inner {
        grid-template-columns: 1fr 1fr;
        gap: var(--shop-s-16);
    }
    /* alternate chapters mirror the layout: photo right, text left */
    .storefront-chapter--reverse .storefront-chapter__media { order: 2; }
    .storefront-chapter--reverse .storefront-chapter__body  { order: 1; }
}
.storefront-chapter__media { margin: 0; }
.storefront-chapter__img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    background: var(--shop-bg-alt);
}
/* no image yet → calm placeholder square instead of a collapsed strip */
.storefront-chapter__img[src=""],
.storefront-chapter__img:not([src]) { min-height: 320px; }
.storefront-chapter__num {
    display: block;
    margin-bottom: var(--shop-s-3);
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.18em;
}
.storefront-chapter__title {
    margin: 0 0 var(--shop-s-5);
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: clamp(1.5rem, 2.6vw, 2.25rem);
    line-height: var(--shop-lh-tight);
    letter-spacing: var(--shop-tracking-tight);
}
.storefront-chapter__text {
    color: var(--shop-text);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
    max-width: 52ch;
}
.storefront-chapter__text p { margin: 0 0 var(--shop-s-4); }
.storefront-chapter__text p:last-child { margin-bottom: 0; }

/* pull-quote — centred display line (no full-width rules on this page) ---- */
.storefront-quote__inner {
    padding-top: var(--shop-s-16);
    padding-bottom: var(--shop-s-16);
    text-align: center;
}
.storefront-quote__text {
    margin: 0 auto;
    max-width: 26ch;
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: clamp(1.5rem, 3.4vw, 2.5rem);
    line-height: var(--shop-lh-snug);
    letter-spacing: var(--shop-tracking-tight);
    quotes: "«" "»";
}
.storefront-quote__text::before { content: open-quote; }
.storefront-quote__text::after { content: close-quote; }
.storefront-quote__author {
    display: block;
    margin-top: var(--shop-s-5);
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

/* outro — centred farewell paragraph + arrow link (no ink band) ----------- */
.storefront-outro__inner { text-align: center; }
.storefront-outro__text {
    margin: 0 auto;
    max-width: 48ch;
    color: var(--shop-text);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
}
.storefront-outro__text p { margin: 0; }
body.storefront a.storefront-outro__link {
    display: inline-flex;
    align-items: center;
    gap: var(--shop-s-2);
    margin-top: var(--shop-s-6);
    color: var(--shop-text);
    font-size: var(--shop-text-sm);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.35em;
}
body.storefront a.storefront-outro__link:hover { color: var(--shop-accent); }
body.storefront a.storefront-outro__link svg { transition: transform var(--shop-duration-base) var(--shop-ease-out); }
body.storefront a.storefront-outro__link:hover svg { transform: translateX(4px); }

/* ==========================================================================
   CONTACTS — hero with a right-hand contact list, note, info tabs
   ========================================================================== */
/* ONE shared band for the whole page, set on the section inners themselves
   (never on inner text elements): every block's content box = 60rem. The
   container paddings live on these same divs, so they're added on top. */
.storefront-contactshero__inner,
.storefront-contactsnote .storefront-section__inner,
.storefront-tabs .storefront-section__inner {
    max-width: calc(60rem + 2 * var(--shop-container-px));
}
.storefront-contactshero__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--shop-s-10);
    align-items: start;
}
@media (min-width: 900px) {
    .storefront-contactshero__inner { grid-template-columns: 1.2fr 1fr; gap: var(--shop-s-16); }
}
.storefront-contactshero__list {
    display: flex;
    flex-direction: column;
}
.storefront-contactshero__row {
    display: flex;
    align-items: center;
    gap: var(--shop-s-4);
    padding: var(--shop-s-3) 0;
    text-decoration: none;
}
/* desktop 2-col hero: the list mirrors the intro — pinned to the right edge;
   on phones (single column) it stays a plain left list under the title */
@media (min-width: 900px) {
    .storefront-contactshero__list { align-items: flex-end; text-align: right; }
    .storefront-contactshero__row { justify-content: flex-end; }
}
.storefront-contactshero__value {
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: var(--shop-text-xl);
    line-height: var(--shop-lh-snug);
    transition: color var(--shop-duration-fast) var(--shop-ease-out);
}
body.storefront a.storefront-contactshero__row { color: var(--shop-text); }
body.storefront a.storefront-contactshero__row:hover { text-decoration: none; }
a.storefront-contactshero__row:hover .storefront-contactshero__value {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.3em;
}
.storefront-contactshero__row--social { align-items: center; }
.storefront-contactshero__social {
    display: flex;
    gap: var(--shop-s-3);
}
body.storefront a.storefront-contactshero__social-link {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--shop-s-10);
    height: var(--shop-s-10);
    border: 1px solid var(--shop-border);
    border-radius: var(--shop-radius-full);
    color: var(--shop-text);
    font-size: var(--shop-text-base);
    transition: background var(--shop-duration-base) var(--shop-ease-out),
                color var(--shop-duration-base) var(--shop-ease-out),
                border-color var(--shop-duration-base) var(--shop-ease-out);
}
body.storefront a.storefront-contactshero__social-link:hover {
    background: var(--shop-accent);
    border-color: var(--shop-accent);
    color: var(--shop-text-on-accent);
    text-decoration: none;
}

/* note band — «how we work» (online-only / pickup points etc.) */
.storefront-contactsnote .storefront-section__inner {
    padding-top: var(--shop-s-12);
    padding-bottom: var(--shop-s-6);
}
/* the note and tab columns are narrower than the container — centre them */
.storefront-contactsnote__inner { text-align: center; }
.storefront-contactsnote__title {
    margin: 0 0 var(--shop-s-4);
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: var(--shop-text-2xl);
    letter-spacing: var(--shop-tracking-tight);
}
.storefront-contactsnote__text {
    color: var(--shop-text);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
}
.storefront-contactsnote__text p { margin: 0 0 var(--shop-s-3); }
.storefront-contactsnote__text p:last-child { margin-bottom: 0; }

/* info tabs — «Як замовити / Доставка й оплата / Повернення» */
.storefront-tabs .storefront-section__inner {
    padding-top: var(--shop-s-10);
    padding-bottom: var(--shop-s-20);
}
.storefront-tabs__nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--shop-s-6);
}
.storefront-tabs__btn {
    appearance: none;
    background: none;
    border: 0;
    margin: 0;
    padding: 0 0 var(--shop-s-4);
    cursor: pointer;
    color: var(--shop-text-muted);
    font-family: inherit;
    font-size: var(--shop-text-sm);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    /* active indicator sits on the hairline */
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: color var(--shop-duration-fast) var(--shop-ease-out),
                border-color var(--shop-duration-fast) var(--shop-ease-out);
}
.storefront-tabs__btn:hover { color: var(--shop-text); }
.storefront-tabs__btn.is-active {
    color: var(--shop-text);
    border-bottom-color: var(--shop-accent);
}
.storefront-tabs__panel {
    display: none;
    padding-top: var(--shop-s-8);
    /* anchor targets (#delivery / #returns from the footer) clear the header */
    scroll-margin-top: calc(var(--shop-header-h-md) + var(--shop-s-8));
}
.storefront-tabs__panel.is-active { display: block; }
.storefront-tabs__text {
    color: var(--shop-text);
    font-size: var(--shop-text-lg);
    line-height: var(--shop-lh-relaxed);
}
.storefront-tabs__text p { margin: 0 0 var(--shop-s-4); }
.storefront-tabs__text p:last-child { margin-bottom: 0; }

/* ==========================================================================
   STATIC / LEGAL PAGES (legal.html layout prose)
   ========================================================================== */
.storefront-page__inner {
    padding-top: var(--shop-s-16);
    padding-bottom: var(--shop-s-20);
    max-width: 96ch;
}
.storefront-page__eyebrow {
    display: block;
    margin-bottom: var(--shop-s-3);
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.storefront-page__title {
    margin: 0 0 var(--shop-s-6);
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: clamp(2rem, 4vw, 2.75rem);
    line-height: var(--shop-lh-tight);
    letter-spacing: var(--shop-tracking-tight);
}
.storefront-page__body {
    color: var(--shop-text-muted);
    font-size: var(--shop-text-base);
    line-height: var(--shop-lh-relaxed);
}
.storefront-page__body p { margin: 0 0 var(--shop-s-4); }
/* long-form prose (legal pages: offer / privacy) ------------------------- */
.storefront-page__prose h2 {
    margin: var(--shop-s-10) 0 var(--shop-s-3);
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: var(--shop-text-2xl);
    line-height: var(--shop-lh-tight);
    color: var(--shop-text);
}
.storefront-page__prose h2:first-child { margin-top: 0; }
.storefront-page__prose h3 {
    margin: var(--shop-s-6) 0 var(--shop-s-2);
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: var(--shop-text-xl);
    color: var(--shop-text);
}
.storefront-page__prose ul {
    margin: 0 0 var(--shop-s-4);
    padding-left: var(--shop-s-6);
}
.storefront-page__prose li { margin-bottom: var(--shop-s-2); }
.storefront-page__prose strong { color: var(--shop-text); font-weight: var(--shop-weight-semi); }
.storefront-page__prose a {
    color: var(--shop-text);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.25em;
}
.storefront-page__prose a:hover { color: var(--shop-text-muted); }

/* ==========================================================================
   FOOTER — white, hairline top, 4 cols (brand / shop / info / contacts)
   ========================================================================== */
.storefront-footer {
    background: var(--shop-bg);
    border-top: 1px solid var(--shop-border);
}
.storefront-footer__inner {
    padding-top: var(--shop-s-16);
    padding-bottom: var(--shop-s-10);
}
.storefront-footer__cols {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--shop-s-10);
}
.storefront-footer__col {
    display: flex;
    flex-direction: column;
    gap: var(--shop-s-3);
}
body.storefront .storefront-footer__logo { display: block; align-self: flex-start; height: var(--shop-s-16); width: auto; max-width: none; object-fit: contain; object-position: left; margin-bottom: var(--shop-s-3); }
body.storefront .storefront-footer__logo[src=""] { display: none; }
.storefront-footer__col--brand:has(.storefront-footer__logo:not([src=""])) .storefront-footer__brand { display: none; }
.storefront-footer__brand {
    font-family: var(--shop-font-display);
    font-size: var(--shop-text-lg);
    font-weight: var(--shop-weight-semi);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--shop-text);
}
.storefront-footer__tagline {
    margin: 0;
    max-width: 34ch;
    color: var(--shop-text-muted);
    font-size: var(--shop-text-sm);
    line-height: var(--shop-lh-relaxed);
}
.storefront-footer__social {
    display: flex;
    gap: var(--shop-s-2);
    margin-top: var(--shop-s-2);
}
.storefront-footer__social-item { display: inline-flex; }
.storefront-footer__social-link i { font-size: var(--shop-text-base); line-height: 1; }
.storefront-footer__social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: var(--shop-text);
    text-decoration: none;
    transition: opacity var(--shop-duration-fast) var(--shop-ease-out);
}
.storefront-footer__social-link:hover { opacity: 0.6; }
.storefront-footer__social-icon { width: 20px; height: 20px; }
.storefront-footer__heading {
    margin: 0 0 var(--shop-s-2);
    color: var(--shop-text-muted);
    font-family: var(--shop-font-body);
    font-size: var(--shop-text-xs);
    font-weight: var(--shop-weight-medium);
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.storefront-footer__links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: var(--shop-s-2);
}
.storefront-footer__links a {
    text-decoration: none;
    font-size: var(--shop-text-sm);
}
.storefront-footer__phone {
    text-decoration: none;
    font-family: var(--shop-font-display);
    font-weight: var(--shop-weight-medium);
    font-size: var(--shop-text-lg);
}
.storefront-footer__email { text-decoration: none; font-size: var(--shop-text-sm); }
.storefront-footer__bottom {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--shop-s-3);
    margin-top: var(--shop-s-12);
    padding-top: var(--shop-s-6);
}
.storefront-footer__copyright {
    margin: 0;
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    letter-spacing: var(--shop-tracking-wide);
}
.storefront-footer__made-by {
    color: var(--shop-text-muted);
    font-size: var(--shop-text-xs);
    letter-spacing: var(--shop-tracking-wide);
    text-decoration: none;
}
body.storefront a.storefront-footer__made-by { color: var(--shop-text-muted); }
body.storefront a.storefront-footer__made-by:hover { color: var(--shop-text); }
/* the agency name reads as the link's visual anchor */
.storefront-footer__made-by-brand {
    color: var(--shop-text);
    font-weight: var(--shop-weight-medium);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.3em;
}
body.storefront a.storefront-footer__made-by:hover .storefront-footer__made-by-brand {
    color: var(--shop-accent);
}
/* footer link colours must out-rank body.storefront a:not(.storefront-btn) (0,2,2) */
body.storefront a.storefront-footer__email { color: var(--shop-text-muted); }
body.storefront .storefront-footer a:hover {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.3em;
}

@media (min-width: 768px) {
    .storefront-footer__cols {
        grid-template-columns: 1.6fr 1fr 1.4fr 1fr;
        gap: var(--shop-s-10);
    }
}

/* reduced motion ---------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    body.storefront *, body.storefront *::before, body.storefront *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}


