/* ============================================================
   Branding Operationalized — storefront design system
   Neutral, modern base. Per-tenant brand color/font are injected
   as --brand-* variables on the .store-root wrapper (set inline
   from the resolved Brand), so the same chassis re-skins per tenant.
   --brand-on-* are contrast-safe foregrounds (WCAG luminance) so text
   on a brand background is never invisible.
   ============================================================ */

.store-root {
    /* Brand variables — overridden inline per tenant; these are fallbacks. */
    --brand-primary: #1f1f1f;
    --brand-secondary: #f0f2f5;
    --brand-header: var(--brand-secondary);
    --brand-button: var(--brand-primary);
    --brand-on-primary: #ffffff;
    --brand-on-header: #1f1f1f;
    --brand-on-button: var(--brand-on-primary);
    --brand-font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --brand-body-font: var(--brand-font);
    --brand-bg: var(--surface);
    --brand-on-bg: var(--ink);

    /* Neutral system tokens */
    --surface: #ffffff;
    --surface-muted: #f7f8fa;
    --store-page: #e7ecf1; /* product-area background (Voda light cool gray; swap to exact brand hex) */
    --line: #e7e9ee;
    --ink: #1f1f1f;
    --ink-muted: #6b7280;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06), 0 1px 3px rgba(16, 24, 40, 0.10);
    --shadow-md: 0 4px 6px -1px rgba(16, 24, 40, 0.08), 0 2px 4px -2px rgba(16, 24, 40, 0.06);
    --maxw: 1180px;

    font-family: var(--brand-body-font);
    color: var(--ink);
    background: var(--store-page);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.store-root * { box-sizing: border-box; }

/* --- Type scale --- */
.store-root h1, .store-root h2, .store-root h3 { font-family: var(--brand-font); font-weight: 700; line-height: 1.15; margin: 0; }
.store-root h1 { font-size: clamp(1.9rem, 4vw, 3rem); }
.store-root h2 { font-size: clamp(1.4rem, 2.5vw, 2rem); }
.store-root h3 { font-size: 1.1rem; }
.store-muted { color: var(--ink-muted); }

/* --- Header --- */
.store-header {
    background: var(--brand-header);
    border-bottom: 1px solid var(--line);
}
.store-header-inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0.9rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
}
.store-logo { height: 44px; width: auto; object-fit: contain; }
.store-logo-fallback {
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--brand-on-header);
    letter-spacing: -0.01em;
}
.store-nav { display: flex; gap: 1.25rem; margin-left: 0.5rem; flex: 1; }
.store-nav a { color: var(--brand-on-header); text-decoration: none; font-weight: 600; opacity: 0.85; }
.store-nav a:hover { opacity: 1; }
.store-contact { color: var(--brand-on-header); font-size: 0.85rem; text-align: right; opacity: 0.9; }
.store-cart {
    display: inline-flex; align-items: center; gap: 0.4rem;
    background: var(--brand-button); color: var(--brand-on-button);
    border-radius: 999px; padding: 0.45rem 0.9rem; font-weight: 600; font-size: 0.9rem;
}

/* --- Category nav strip --- */
.store-categories { background: var(--surface); border-bottom: 1px solid var(--line); }
.store-categories-inner {
    max-width: var(--maxw); margin: 0 auto; padding: 0.6rem 1.25rem;
    display: flex; gap: 1.25rem; flex-wrap: wrap;
}
.store-categories a { color: var(--ink-muted); text-decoration: none; font-weight: 600; font-size: 0.9rem; }
.store-categories a:hover { color: var(--brand-primary); }

/* --- Hero --- */
.store-hero {
    background: linear-gradient(180deg, var(--brand-secondary) 0%, var(--surface) 100%);
    border-bottom: 1px solid var(--line);
}
.store-hero-inner {
    max-width: var(--maxw); margin: 0 auto; padding: 3rem 1.25rem 2.5rem;
}
.store-hero h1 { color: var(--ink); }
.store-hero p { margin: 0.6rem 0 0; max-width: 60ch; font-size: 1.05rem; }

/* --- Layout --- */
.store-main { flex: 1; max-width: var(--maxw); margin: 0 auto; padding: 2rem 1.25rem 3rem; width: 100%; }
.store-section-title { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 1.25rem; }

/* --- Product grid + card --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
}
.product-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: box-shadow .2s ease, transform .2s ease;
    display: flex; flex-direction: column;
}
.product-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.product-thumb {
    aspect-ratio: 1 / 1; width: 100%; object-fit: contain; background: var(--surface);
    padding: 0.75rem; box-sizing: border-box;
    display: flex; align-items: center; justify-content: center;
    color: var(--ink-muted); font-size: 0.8rem; border-bottom: 1px solid var(--line);
}
.product-body { padding: 0.9rem 1rem 1rem; display: flex; flex-direction: column; gap: 0.4rem; flex: 1; }
.product-name { font-weight: 600; font-size: 0.98rem; }
.product-price { font-weight: 800; font-size: 1.15rem; color: var(--ink); }
.product-chip {
    align-self: flex-start; font-size: 0.72rem; font-weight: 600;
    background: var(--surface-muted); color: var(--ink-muted);
    border: 1px solid var(--line); border-radius: 999px; padding: 0.15rem 0.55rem;
}

/* --- Buttons --- */
.btn-main {
    display: inline-block; cursor: pointer; text-decoration: none; text-align: center;
    background: var(--brand-button); color: var(--brand-on-button);
    font-weight: 600; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 0.02em;
    padding: 0.75rem 1.5rem; border: 0; border-radius: var(--radius);
    transition: background-color .2s ease, color .2s ease;
}
/* Hover: navy -> glacier-blue bg, white -> navy text (matches the live Voda buttons) */
.btn-main:hover { background: var(--brand-secondary); color: var(--brand-primary); }
.store-cart { transition: background-color .2s ease, color .2s ease; }
.store-cart:hover { background: var(--brand-secondary); color: var(--brand-primary); }
.admin-login .btn-main:hover, .admin-main .btn-main:hover { background: #1d3358; color: #fff; }

/* --- Accessibility: visible keyboard focus (WCAG 2.4.7) --- */
.store-root a:focus-visible,
.btn-main:focus-visible,
.store-cart:focus-visible {
    outline: 3px solid currentColor;
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* --- Empty / gate states --- */
.store-empty {
    text-align: center; padding: 3rem 1rem; color: var(--ink-muted);
    border: 1px dashed var(--line); border-radius: var(--radius); background: var(--surface-muted);
}

/* Store closed / opening-soon splash (open/close window) */
.store-closed { flex: 1; display: flex; align-items: center; justify-content: center; padding: 4rem 1.25rem; }
.store-closed-inner {
    text-align: center; max-width: 560px; background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--radius); padding: 2.75rem 2rem; box-shadow: var(--shadow-sm);
}
.store-closed-inner h1 { color: var(--ink); margin-bottom: 0.6rem; }
.store-closed-inner p { color: var(--ink-muted); font-size: 1.05rem; margin: 0.45rem 0; }
.store-countdown {
    font-family: var(--brand-font, system-ui); font-size: clamp(1.6rem, 5vw, 2.4rem); font-weight: 800;
    color: var(--brand-primary, #1f1f1f); font-variant-numeric: tabular-nums; margin: 1.1rem 0 0.2rem;
}

/* Fundraising progress bar */
.fundraise { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.25rem; }
.fundraise-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; font-size: 0.95rem; color: var(--ink); margin-bottom: 0.55rem; }
.fundraise-head strong { font-size: 1.15rem; color: var(--brand-primary, var(--ink)); }
.fundraise-pct { font-weight: 800; color: var(--brand-primary, var(--ink)); font-variant-numeric: tabular-nums; }
.fundraise-track { height: 12px; background: var(--surface-muted); border-radius: 999px; overflow: hidden; }
.fundraise-fill { height: 100%; background: var(--brand-button, var(--brand-primary, #1f1f1f)); border-radius: 999px; transition: width .3s ease; }

/* --- Footer --- */
.store-footer {
    background: var(--surface-muted); border-top: 1px solid var(--line);
    color: var(--ink-muted); font-size: 0.85rem;
}
.store-footer-inner {
    max-width: var(--maxw); margin: 0 auto; padding: 1.5rem 1.25rem;
    display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem; justify-content: space-between; align-items: center;
}

/* --- Responsive: mobile header/hero --- */
@media (max-width: 640px) {
    .store-header-inner { flex-wrap: wrap; gap: 0.6rem 1rem; }
    .store-nav { order: 3; flex-basis: 100%; margin-left: 0; }
    .store-contact { text-align: left; }
    .store-hero-inner { padding: 2rem 1rem 1.75rem; }
    .store-main { padding: 1.5rem 1rem 2.5rem; }
}

/* --- Respect reduced-motion preference --- */
@media (prefers-reduced-motion: reduce) {
    .product-card, .btn-main { transition: none; }
    .product-card:hover { transform: none; }
}

/* --- Product detail --- */
.product-detail { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 2rem; margin-top: 1rem; align-items: start; }
.product-detail-media .product-thumb {
    width: 100%; border-radius: var(--radius); border: 1px solid var(--line);
    aspect-ratio: 1 / 1; object-fit: cover;
}
.product-detail-info h1 { margin-bottom: 0.5rem; }
.add-to-cart { display: flex; align-items: flex-end; gap: 0.75rem; margin-top: 1.25rem; }
.qty-label { display: flex; flex-direction: column; font-size: 0.85rem; font-weight: 600; gap: 0.25rem; }
.qty-input { width: 5rem; padding: 0.5rem; border: 1px solid var(--line); border-radius: var(--radius-sm); }
@media (max-width: 640px) { .product-detail { grid-template-columns: 1fr; } }

/* --- Cart --- */
.cart-table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
.cart-table th, .cart-table td { text-align: left; padding: 0.6rem 0.5rem; border-bottom: 1px solid var(--line); }
.cart-table th { font-size: 0.8rem; color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.02em; }
.cart-summary { display: flex; justify-content: flex-end; gap: 1rem; align-items: baseline; font-size: 1.1rem; margin: 0.5rem 0 1.25rem; }
.cart-actions { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.btn-link { background: none; border: 0; color: var(--ink-muted); text-decoration: underline; cursor: pointer; font-size: 0.85rem; padding: 0; }
.btn-link:hover { color: var(--ink); }
.btn-main:disabled { opacity: 0.5; cursor: not-allowed; }

/* --- Checkout --- */
/* Navy checkout page so the white form + summary cards pop */
.checkout-page { background: var(--brand-primary); border-radius: var(--radius); padding: 1.25rem 1.25rem 1.75rem; margin-top: 1rem; }
.store-main.checkout-page > h1 { color: #fff; font-size: 1.7rem; margin-bottom: 1rem; }
.checkout-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 1.25rem; align-items: start; }
.checkout-form { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.1rem 1.25rem; display: flex; flex-direction: column; gap: 0.45rem; }
.checkout-section { margin: 0.5rem 0 0; font-size: 0.92rem; color: var(--ink); border-top: 1px solid var(--line); padding-top: 0.7rem; }
.checkout-form > .checkout-section:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.checkout-form label { display: flex; flex-direction: column; gap: 0.2rem; font-size: 0.78rem; font-weight: 600; color: var(--ink); }
.checkout-form label.checkbox { flex-direction: row; align-items: center; gap: 0.5rem; font-weight: 500; }
.checkout-form input, .checkout-form textarea, .checkout-form select { width: 100%; padding: 0.45rem 0.55rem; border: 1px solid var(--line); border-radius: var(--radius-sm); font: inherit; box-sizing: border-box; background: var(--surface); }
.checkout-hint { margin: 0.05rem 0 0.25rem; font-size: 0.78rem; }
.checkout-gate { color: #b35900; font-size: 0.82rem; font-weight: 700; margin: 0; }
.checkout-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 0.75rem; }
.checkout-summary { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.25rem; }
.checkout-summary h3 { color: var(--ink); margin-bottom: 0.6rem; }
.summary-line { display: flex; justify-content: space-between; gap: 1rem; padding: 0.35rem 0; font-size: 0.9rem; border-bottom: 1px solid var(--line); }
.summary-sub { color: var(--ink-muted); font-size: 0.82rem; }
.summary-total { display: flex; justify-content: space-between; gap: 1rem; padding-top: 0.75rem; font-size: 1.05rem; color: var(--ink); }
.validation-message, .validation-errors { color: #db4444; font-size: 0.85rem; }
@media (max-width: 760px) { .checkout-grid { grid-template-columns: 1fr; } }

/* --- Admin (back-office; not store-branded) --- */
.admin-shell { min-height: 100vh; display: flex; flex-direction: column; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: #1f1f1f; background: #f7f8fa; }
.admin-header { background: #152644; }
.admin-header-inner { max-width: 1180px; margin: 0 auto; padding: 0.85rem 1.25rem; display: flex; align-items: center; gap: 1.25rem; }
.admin-brand { color: #fff; font-weight: 800; text-decoration: none; font-size: 1.05rem; }
.admin-nav { display: flex; gap: 1rem; flex: 1; }
.admin-nav a { color: #cdd5e0; text-decoration: none; font-weight: 600; }
.admin-nav a:hover { color: #fff; }
.admin-user { color: #cdd5e0; font-size: 0.9rem; }
.admin-logout-form { margin: 0; }
.admin-logout { color: #fff; background: transparent; border: 1px solid rgba(255,255,255,0.4); padding: 0.3rem 0.8rem; border-radius: 6px; cursor: pointer; font: inherit; font-size: 0.9rem; text-decoration: none; white-space: nowrap; }
.admin-logout:hover { background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,0.7); }
.admin-main { max-width: 1180px; width: 100%; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }
.admin-table th, .admin-table td { font-size: 0.9rem; }
.admin-login { max-width: 360px; margin: 3rem auto; background: #fff; border: 1px solid #e7e9ee; border-radius: 12px; padding: 1.5rem; }
.admin-login h1 { font-size: 1.4rem; margin: 0 0 1rem; }
.admin-login form { display: flex; flex-direction: column; gap: 0.75rem; }
.admin-login label { display: flex; flex-direction: column; gap: 0.25rem; font-weight: 600; font-size: 0.85rem; }
.admin-login input { padding: 0.5rem; border: 1px solid #e7e9ee; border-radius: 8px; font: inherit; }
.admin-login .btn-main { background: #152644; color: #fff; }
.admin-main .btn-main { background: #152644; color: #fff; align-self: flex-start; }
.admin-form { max-width: 560px; }

/* Core reporting — /admin/reports */
.report-filter { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0.75rem; margin: 0 0 1.25rem; }
.report-filter label { display: flex; flex-direction: column; gap: 0.2rem; font-size: 0.78rem; font-weight: 600; color: var(--ink); }
.report-filter input { padding: 0.45rem 0.55rem; border: 1px solid var(--line); border-radius: var(--radius-sm); font: inherit; }
.report-filter .btn-main { align-self: flex-end; }
.report-filter .report-clear { align-self: flex-end; padding: 0.4rem 0.2rem; font-size: 0.85rem; color: var(--ink-muted); text-decoration: underline; }
.report-filter .report-export { margin-left: auto; align-self: flex-end; }
.report-section { margin: 1.75rem 0; }
.report-section h2 { font-size: 1.05rem; margin: 0 0 0.25rem; }
.report-num { text-align: right; white-space: nowrap; }
.admin-table tfoot td { font-weight: 700; border-top: 2px solid var(--line); }

/* Admin table readability — zebra rows, row hover, column separators, and aligned numerals so the
   eye tracks straight across a line of order/report data instead of drifting through white space. */
.admin-table { border: 1px solid var(--line); }
.admin-table thead th { background: #e9edf3; color: var(--ink); border-bottom: 2px solid #c7d0dd; }
.admin-table tbody tr:nth-child(even) td { background: #f4f6f9; }
.admin-table tbody tr:hover td { background: #e6eefa; }
.admin-table th:not(:last-child), .admin-table td:not(:last-child) { border-right: 1px solid #e9ecf1; }
.admin-table td, .admin-table tfoot td { font-variant-numeric: tabular-nums; }
.report-num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* Slice 3 — location branding override: saved flash, effective-branding preview, advanced disclosure */
.admin-ok { color: #157347; font-weight: 600; font-size: 0.9rem; margin: 0 0 0.75rem; }
.admin-warn { color: #8a5a00; background: #fff6e5; border: 1px solid #f2d48a; border-radius: 8px; padding: 0.5rem 0.7rem; font-size: 0.85rem; margin: 0.4rem 0; }
.email-preview { white-space: pre-wrap; background: var(--surface-muted, #f7f8fa); border: 1px solid var(--line, #e7e9ee); border-radius: 8px; padding: 0.75rem; font-size: 0.82rem; margin: 0.5rem 0 0; overflow-x: auto; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.brand-preview { max-width: 560px; border: 1px solid var(--line, #e7e9ee); border-radius: 12px; padding: 1rem; margin: 0 0 1.25rem; background: var(--surface, #fff); }
.brand-preview-head { display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem; font-weight: 700; font-size: 0.95rem; margin-bottom: 0.75rem; }
.brand-swatches { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.5rem; }
.brand-swatch { border-radius: 8px; padding: 0.55rem 0.5rem; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; display: flex; flex-direction: column; gap: 0.25rem; min-height: 54px; border: 1px solid rgba(0,0,0,0.08); }
.brand-swatch span { font-weight: 500; text-transform: none; letter-spacing: 0; font-size: 0.7rem; opacity: 0.85; }
.brand-preview-meta { display: flex; align-items: center; gap: 1rem; margin-top: 0.75rem; font-size: 0.85rem; color: var(--ink-muted, #6b7280); flex-wrap: wrap; }
.brand-preview-logo { max-height: 40px; max-width: 160px; margin-left: auto; object-fit: contain; }
.admin-advanced { max-width: 560px; margin: 0.5rem 0 1rem; border: 1px solid var(--line, #e7e9ee); border-radius: 8px; padding: 0.5rem 0.75rem; }
.admin-advanced summary { cursor: pointer; font-weight: 600; font-size: 0.9rem; }
.admin-advanced label { margin-top: 0.6rem; }

/* Store access gate (employee-store shared code) — minimal, brand-themed chrome */
.store-gate { max-width: 420px; margin: 3.5rem auto; padding: 2rem 1.5rem; text-align: center; }
.store-gate h1 { font-size: 1.5rem; margin: 0 0 0.5rem; }
.store-gate-form { display: flex; flex-direction: column; gap: 0.75rem; margin-top: 1.25rem; }
.store-gate-form input { padding: 0.6rem 0.75rem; border: 1px solid #d5d8df; border-radius: 8px; font: inherit; text-align: center; }

/* Customer accounts (storefront) */
.store-account { color: var(--brand-on-header); text-decoration: none; font-weight: 600; font-size: 0.92rem; opacity: 0.9; }
.store-account:hover { opacity: 1; }
.account-panel { max-width: 680px; margin: 2.5rem auto; padding: 0 1.25rem; }
.account-panel h1 { font-size: 1.5rem; margin: 0 0 0.35rem; }
.account-form { display: flex; flex-direction: column; gap: 0.75rem; max-width: 380px; margin: 1.25rem 0; }
.account-form label { display: flex; flex-direction: column; gap: 0.25rem; font-weight: 600; font-size: 0.85rem; }
.account-form input { padding: 0.55rem 0.7rem; border: 1px solid #d5d8df; border-radius: 8px; font: inherit; }
.account-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.account-logout-form { margin: 0; }
.btn-outline { background: transparent; border: 1px solid var(--brand-button, #1f1f1f); color: var(--brand-button, #1f1f1f); padding: 0.4rem 0.9rem; border-radius: 8px; cursor: pointer; font: inherit; font-size: 0.9rem; }
.btn-outline:hover { background: rgba(0,0,0,0.05); }

/* === Brand composition: navy top (categories + hero) + LIGHT shopping area + navy footer === */
.store-header, .store-categories, .store-hero, .store-main, .store-footer { position: relative; z-index: 1; }

/* Dots now live INSIDE the navy hero (see .store-hero::before/::after below) */

/* Category nav lives in the cyan top ribbon: navy links, inline next to the logo */
.store-categories { display: flex; gap: 1.1rem; align-items: center; flex-wrap: wrap; background: transparent; border: 0; padding: 0; }
.store-categories a { color: var(--brand-on-header); opacity: 0.82; text-decoration: none; font-weight: 600; font-size: 0.92rem; }
.store-categories a:hover { opacity: 1; }

/* Hero: navy band featuring the white Voda logo, with the brand dots flanking it */
.store-hero { background: var(--brand-primary); border-bottom: 0; position: relative; text-align: center; overflow: hidden; }
/* Shack Shine: cyan accent presence carried over from the retired form — hairline
   under the white header, cyan rule under the hero, cyan underline on section
   titles. Decorative bars only: cyan TEXT on the light shopping area fails WCAG. */
.store-root[data-slug="shackshine"] .store-header { border-bottom: 1px solid #e5e4e0; }
.store-root[data-slug="shackshine"] .store-hero { border-bottom: 3px solid var(--brand-secondary); }
.store-root[data-slug="shackshine"] .store-section-title h2::after {
    content: ""; display: block; width: 48px; height: 3px; margin-top: 0.4rem;
    background: var(--brand-secondary); border-radius: 2px;
}

/* Dot art is a Voda brand asset — scoped to the voda store so it never bleeds onto other tenants' heroes. */
.store-root[data-slug="voda"] .store-hero::before, .store-root[data-slug="voda"] .store-hero::after { content: ""; position: absolute; top: 0; bottom: 0; width: 330px; background-repeat: no-repeat; opacity: 0.85; pointer-events: none; z-index: 0; }
.store-root[data-slug="voda"] .store-hero::before { left: 0; background-image: url("/brand/voda-dots-left.svg"); background-position: left center; background-size: auto 156%; }
.store-root[data-slug="voda"] .store-hero::after { right: 0; background-image: url("/brand/voda-dots-right.svg"); background-position: right center; background-size: auto 156%; }
.store-hero-inner { position: relative; z-index: 1; }
.store-hero h1 { color: #fff; }
.store-hero p { color: #fff; opacity: 0.88; margin: 0.5rem auto 0; }
.store-hero-logo { height: 176px; width: auto; max-width: 90%; display: block; margin: 0 auto 0.9rem; }
@media (max-width: 700px) { .store-hero::before, .store-hero::after { display: none; } }
@media (max-width: 640px) { .store-hero-logo { height: 110px; } }

/* Header + footer contact (Need help? + phone/email) */
.store-contact { display: flex; flex-direction: column; align-items: flex-end; gap: 0.05rem; line-height: 1.35; margin-left: auto; }
.store-contact-label { font-weight: 700; }
.store-contact a { color: var(--brand-on-header); text-decoration: none; }
.store-contact a:hover { text-decoration: underline; }
.store-footer a { color: #fff; text-decoration: underline; }
.store-footer-contact { display: inline-flex; gap: 0.6rem; align-items: center; flex-wrap: wrap; }

/* Light shopping area: dark text */
.store-section-title h2 { color: var(--ink); }
.store-section-title .store-muted { color: var(--ink-muted); }
.store-main > h1 { color: var(--ink); }
.store-main > a:not(.btn-main) { color: var(--brand-primary); opacity: 0.85; }
.confirm-note { max-width: 62ch; margin: 0.6rem 0 1.25rem; line-height: 1.55; color: var(--ink); }
.confirm-sign { display: inline-block; margin-top: 0.5rem; font-weight: 700; color: var(--brand-primary); }

/* Order confirmation — branded table */
.order-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; margin: 1rem 0 1.5rem; }
.order-table { width: 100%; border-collapse: collapse; }
.order-table thead th { background: var(--brand-primary); color: #fff; text-align: left; font-family: var(--brand-font, inherit); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.05em; padding: 0.75rem 1rem; }
.order-table th.num, .order-table td.num { text-align: right; }
.order-table tbody td { padding: 0.7rem 1rem; border-top: 1px solid var(--line); color: var(--ink); font-size: 0.92rem; }
.order-table tbody tr:nth-child(even) { background: var(--surface-muted); }
.order-totals { padding: 0.85rem 1rem 1rem; border-top: 3px solid var(--brand-secondary); }
.order-total-line { display: flex; justify-content: space-between; gap: 1rem; padding: 0.2rem 0; font-size: 0.92rem; color: var(--ink); }
.order-grand { font-size: 1.15rem; font-weight: 700; color: var(--brand-primary); padding-top: 0.5rem; }
.order-grand strong { color: var(--brand-primary); }
.order-invoice-note { margin-top: 0.45rem; font-size: 0.8rem; color: var(--ink-muted); }
.order-shipto { margin-bottom: 1.25rem; }
.order-shipto h3 { color: var(--ink); }
.store-empty { color: var(--ink-muted); background: var(--surface); border-color: var(--line); }

/* Footer: navy band */
.store-footer { background: var(--brand-primary); border-top: 0; color: #fff; }
.store-footer .store-footer-inner { opacity: 0.85; }

/* Product detail / cart panels (white cards on the light area) */
.store-panel { background: var(--surface); color: var(--ink); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow-sm); border: 1px solid var(--line); margin-top: 0.5rem; }
.store-panel .store-muted { color: var(--ink-muted); }
.product-detail { background: var(--surface); color: var(--ink); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow-sm); border: 1px solid var(--line); }
.product-detail .store-muted { color: var(--ink-muted); }
.product-detail h1 { color: var(--ink); }
.cart-table { background: var(--surface); color: var(--ink); border-radius: var(--radius); overflow: hidden; }
.cart-table th { background: var(--surface-muted); }
.cart-summary, .cart-actions { color: var(--ink); }

/* Responsive (laptop + mobile) */
@media (max-width: 640px) {
    .product-detail { padding: 1rem; }
    .store-main { padding: 1.25rem 1rem 2.5rem; }
    .store-header-inner { flex-wrap: wrap; row-gap: 0.5rem; }
    .store-cart { margin-left: auto; }
    .store-hero-inner { padding: 1.75rem 1rem 1.5rem; }
}

/* === Order-form engine (product detail) === */
.order-form { display: flex; flex-direction: column; gap: 1rem; margin-top: 1.25rem; }

/* Volume-pricing tier cards */
.tier-cards { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.75rem 0; }
.tier-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.5rem 0.8rem; min-width: 84px; text-align: center; transition: border-color .15s, background-color .15s; }
.tier-card.active { border: 2px solid var(--brand-primary); background: var(--brand-secondary); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18); }
.tier-card.active .tier-qty, .tier-card.active .tier-price, .tier-card.active .tier-price span { color: var(--brand-primary); }
.tier-qty { font-size: 0.78rem; color: var(--ink-muted); font-weight: 600; }
.tier-price { font-weight: 700; color: var(--ink); }
.tier-price span { font-size: 0.72rem; color: var(--ink-muted); font-weight: 500; margin-left: 1px; }
.price-from { font-size: 0.8rem; color: var(--ink-muted); font-weight: 600; margin-right: 0.25rem; }

/* Size matrix */
.size-matrix { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.5rem; }
.size-cell { display: flex; flex-direction: column; gap: 0.2rem; font-size: 0.78rem; font-weight: 600; color: var(--ink-muted); text-align: center; }
.size-input, .qty-input { width: 100%; padding: 0.45rem; border: 1px solid var(--line); border-radius: var(--radius); font-size: 1rem; text-align: center; box-sizing: border-box; }
.qty-label { display: flex; flex-direction: column; gap: 0.25rem; max-width: 140px; font-weight: 600; }

/* Amber warnings (min order / increment) — stand out clearly */
.order-warning { background: #fff3c4; border: 1px solid #e0a82e; border-left: 5px solid #e0a82e; color: #7a5500; padding: 0.65rem 0.85rem; border-radius: var(--radius); font-size: 0.88rem; font-weight: 600; }

/* Setup-fee callout — glacier-blue fill, navy text (matches the live Voda form) */
.setup-callout { background: var(--brand-secondary); color: var(--brand-primary); padding: 0.75rem 0.95rem; border-radius: var(--radius); }
.setup-callout-head { font-weight: 800; color: var(--brand-primary); }
.setup-callout p { margin: 0.35rem 0 0; font-size: 0.85rem; color: var(--brand-primary); opacity: 0.82; }
.setup-waive { font-weight: 700; opacity: 1 !important; }

/* Product image carousel (one large uncropped image at a time + arrows/dots/enlarge) */
.gallery-stage { position: relative; aspect-ratio: 1 / 1; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.gallery-slide { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 0.85rem; opacity: 0; transition: opacity .2s ease; cursor: zoom-in; }
.gallery-slide.active { opacity: 1; }
.gallery-solo { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; padding: 0.85rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); cursor: zoom-in; box-sizing: border-box; }
.gallery-zoom { position: absolute; top: 0.6rem; right: 0.6rem; z-index: 3; background: rgba(8, 18, 36, 0.78); color: #fff; border: 0; border-radius: 999px; padding: 0.35rem 0.75rem; font-size: 0.78rem; font-weight: 700; cursor: pointer; }
.gallery-zoom:hover { background: var(--brand-primary); }
.gallery-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 38px; height: 38px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.92); color: var(--ink); font-size: 1.5rem; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.gallery-arrow:hover { background: #fff; border-color: var(--brand-secondary); }
.gallery-prev { left: 0.5rem; }
.gallery-next { right: 0.5rem; }
.gallery-counter { position: absolute; left: 0.6rem; bottom: 0.6rem; z-index: 3; background: rgba(8, 18, 36, 0.7); color: #fff; border-radius: 999px; padding: 0.2rem 0.6rem; font-size: 0.75rem; font-weight: 600; }
.gallery-thumbs { display: flex; gap: 0.5rem; margin-top: 0.65rem; flex-wrap: wrap; }
.gallery-thumb { width: 72px; height: 72px; padding: 3px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; box-sizing: border-box; }
.gallery-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.gallery-thumb:hover { border-color: var(--brand-secondary); }
.gallery-thumb.active { border: 2px solid var(--brand-secondary); }

/* Split-shipping checkout: destination cards + allocation grid */
.btn-secondary { display: inline-block; cursor: pointer; background: var(--surface); color: var(--brand-primary); border: 1px solid var(--brand-primary); border-radius: var(--radius-sm); padding: 0.45rem 0.9rem; font-weight: 600; font-size: 0.85rem; }
.btn-secondary:hover { background: var(--brand-secondary); border-color: var(--brand-secondary); color: var(--brand-primary); }
.multi-ship-actions { display: flex; gap: 0.6rem; margin: 0.5rem 0 0.8rem; flex-wrap: wrap; }
.dest-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.85rem; margin-bottom: 0.8rem; background: var(--surface-muted); box-shadow: 0 2px 8px rgba(10, 20, 40, 0.08); }
.dest-head { display: flex; gap: 0.5rem; align-items: center; margin-bottom: 0.5rem; }
.dest-name { flex: 1; }
.dest-remove { background: none; border: 0; color: var(--ink-muted); cursor: pointer; font-size: 1rem; line-height: 1; }
.dest-remove:hover { color: #b00020; }
.dest-card > input { width: 100%; padding: 0.5rem; border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: 0.4rem; box-sizing: border-box; }
.dest-card .checkout-row input { width: 100%; padding: 0.5rem; border: 1px solid var(--line); border-radius: var(--radius-sm); box-sizing: border-box; }
.dest-allocs { margin-top: 0.5rem; display: flex; flex-direction: column; }
.alloc-product { padding: 0.5rem 0.55rem; border-radius: var(--radius-sm); }
.alloc-product:nth-child(odd) { background: rgba(10, 20, 40, 0.05); }
.alloc-name { font-weight: 700; font-size: 0.84rem; margin: 0; }
.alloc-product.sized .alloc-name { margin-bottom: 0.3rem; }
.alloc-product.single { display: flex; align-items: center; gap: 0.6rem; }
.alloc-product.single .alloc-name { flex: 0 0 auto; }
.alloc-total { font-size: 0.78rem; font-weight: 700; color: var(--ink-muted); white-space: nowrap; }
.alloc-total.done { color: #1a7f37; }
.alloc-product.single .alloc-total { flex: 1; text-align: right; }
.checkout-form .alloc-input-inline { width: 90px; flex: none; text-align: center; }
.alloc-cells { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.alloc-cell { display: flex; flex-direction: column; align-items: center; font-size: 0.72rem; gap: 0.1rem; }
.alloc-cell input { width: 56px; text-align: center; padding: 0.3rem; margin: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
/* Allocation status — glacier-blue panel so the cart contents stand out; bolder per-item badges */
.alloc-panel { background: var(--surface-muted); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.8rem; margin-top: 0; }
.alloc-title { font-size: 0.88rem; font-weight: 800; color: var(--ink); margin: 0; }
.alloc-status { display: flex; flex-direction: column; gap: 0.4rem; max-height: 200px; overflow-y: auto; padding-right: 0.25rem; }
.alloc-group-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.2rem; }
.alloc-group-name { font-weight: 800; color: var(--ink); font-size: 0.92rem; }
.alloc-input.filled { border: 2px solid var(--brand-secondary); background: #e6fbfd; font-weight: 700; }

/* Checkbox shouldn't stretch full-width (the generic input rule did that) */
.checkout-form input[type="checkbox"] { width: auto; }
/* Field focus so the form reads less plain */
.checkout-form input:focus, .checkout-form select:focus, .checkout-form textarea:focus { outline: none; border-color: var(--brand-secondary); box-shadow: 0 0 0 3px rgba(0, 217, 229, 0.18); }
/* Right column (summary + allocation) stays visible while scrolling the destination cards */
.checkout-side { position: sticky; top: 0.6rem; align-self: start; display: flex; flex-direction: column; gap: 1rem; }
.alloc-panel { box-shadow: 0 6px 18px rgba(10, 20, 40, 0.14); }
@media (max-width: 760px) { .checkout-side { position: static; } }
.alloc-panel-head { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 0.7rem; }
.alloc-panel-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* Quantity input area — stands out amid the tier / warning / setup colors */
.qty-block { background: var(--surface-muted); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.85rem 1rem; margin: 0.4rem 0 0.3rem; }
.qty-block-label { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-muted); margin-bottom: 0.5rem; }
.qty-label { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-muted); display: flex; flex-direction: column; gap: 0.4rem; align-items: flex-start; }
.qty-input { width: 8rem; padding: 0.6rem 0.7rem; border: 2px solid var(--brand-primary); border-radius: var(--radius-sm); font-size: 1.2rem; font-weight: 700; color: var(--ink); box-sizing: border-box; }
.qty-input:focus { outline: none; border-color: var(--brand-secondary); box-shadow: 0 0 0 3px rgba(0, 217, 229, 0.22); }
.qty-block .size-input { border: 2px solid var(--brand-primary); font-weight: 700; }
.qty-block .size-input:focus { outline: none; border-color: var(--brand-secondary); box-shadow: 0 0 0 3px rgba(0, 217, 229, 0.22); }
.alloc-dist { background: var(--brand-primary); color: #fff; border: 0; border-radius: var(--radius-sm); padding: 0.18rem 0.55rem; font-size: 0.7rem; font-weight: 700; cursor: pointer; }
.alloc-dist:hover { opacity: 0.9; }
.alloc-badges { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.alloc-badge { font-size: 0.74rem; font-weight: 700; border-radius: 999px; padding: 0.15rem 0.5rem; }
.alloc-badge.ok { background: #1a7f37; color: #fff; }
.alloc-badge.bad { background: #fff; color: #b35900; border: 1px solid #e0a82e; }

/* State dropdowns (checkout + destination cards) match the text inputs */
.checkout-form select, .dest-state { width: 100%; padding: 0.5rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); box-sizing: border-box; }

/* Lightbox (appended to <body>, outside .store-root — literal values, not brand vars) */
.lightbox { position: fixed; inset: 0; background: rgba(8, 18, 36, 0.86); display: flex; align-items: center; justify-content: center; z-index: 1000; cursor: zoom-out; padding: 2rem; }
.lightbox img { max-width: 92vw; max-height: 92vh; border-radius: 12px; box-shadow: 0 12px 48px rgba(0, 0, 0, 0.55); background: #fff; }
.lightbox-stage { cursor: default; display: flex; align-items: center; justify-content: center; }
.lightbox-close, .lightbox-arrow {
    position: fixed; border: 0; background: rgba(255, 255, 255, 0.14); color: #fff;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    line-height: 1; transition: background-color .15s ease;
}
.lightbox-close:hover, .lightbox-arrow:hover { background: rgba(255, 255, 255, 0.30); }
.lightbox-close { top: 1rem; right: 1.25rem; width: 2.6rem; height: 2.6rem; border-radius: 50%; font-size: 1.8rem; }
.lightbox-arrow { top: 50%; transform: translateY(-50%); width: 3rem; height: 3rem; border-radius: 50%; font-size: 2rem; }
.lightbox-prev { left: 1.25rem; }
.lightbox-next { right: 1.25rem; }
.lightbox-counter {
    position: fixed; bottom: 1.25rem; left: 50%; transform: translateX(-50%);
    color: #fff; font-size: 0.95rem; font-weight: 600;
    background: rgba(0, 0, 0, 0.45); padding: 0.3rem 0.85rem; border-radius: 999px;
}
@media (max-width: 640px) {
    .lightbox-arrow { width: 2.5rem; height: 2.5rem; font-size: 1.6rem; }
    .lightbox-prev { left: 0.4rem; }
    .lightbox-next { right: 0.4rem; }
}

/* Persistent ordering rule (minimum + increment) — always visible, not a violation warning */
.order-rule { display: flex; gap: 0.45rem 0.6rem; flex-wrap: wrap; margin: 0; }
/* Minimum-order / increment pills — Voda apple-green (the dot palette). Client-specific via --brand-accent. */
.order-rule span { background: var(--brand-accent, #C6FF95); border: 1px solid #a9e673; border-radius: 999px; padding: 0.2rem 0.65rem; font-size: 0.8rem; font-weight: 700; color: var(--brand-primary); }

/* Special instructions */
.instructions-label { display: flex; flex-direction: column; gap: 0.3rem; font-weight: 600; }
.instructions-input { width: 100%; padding: 0.55rem; border: 1px solid var(--line); border-radius: var(--radius); font: inherit; box-sizing: border-box; resize: vertical; }

/* Live line summary */
.order-summary-live { border-top: 1px solid var(--line); padding-top: 0.8rem; display: flex; flex-direction: column; gap: 0.25rem; }
.order-summary-live .order-line-total { font-size: 1.15rem; }
.order-summary-live .order-line-total strong { color: var(--brand-primary); }

@media (max-width: 520px) { .size-matrix { grid-template-columns: repeat(4, 1fr); } }
