/* ==========================================================================
   Murphy Central — site stylesheet
   One storefront, two departments (Tech + Health & Beauty).
   Design language: minimalist luxury, Apple-style type scale and motion.
   ========================================================================== */

/* --- Design tokens ------------------------------------------------------ */
:root {
    --paper:        #fbfbfd;   /* default light page background          */
    --paper-alt:    #f2f2f5;   /* banded light section                   */
    --ink:          #0c0c0f;   /* near-black, used as dark background    */
    --ink-soft:     #16161a;
    --navy:         #0a1f44;   /* brand: trust / corporate stability     */
    --navy-lift:    #12305f;
    --gold:         #c9a227;   /* brand: designer + beauty side          */
    --gold-soft:    #e3c76a;

    --text-strong:  #0c0c0f;
    --text:         #33333a;
    --text-muted:   #6e6e78;
    --hairline:     rgba(12, 12, 15, 0.10);

    --radius-sm:    10px;
    --radius:       18px;
    --radius-lg:    28px;

    --shell:        1180px;   /* max content width */
    --gutter:       clamp(20px, 5vw, 56px);

    --ease:         cubic-bezier(0.22, 0.61, 0.36, 1);
    --ease-soft:    cubic-bezier(0.4, 0, 0.2, 1);

    --font-sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
                 "Helvetica Neue", "Segoe UI", Roboto, Arial, sans-serif;
    --font-serif: "Bodoni Moda", "Didot", "Times New Roman", serif;
    --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

/* Dark surfaces flip the text tokens rather than re-styling every element. */
.on-dark {
    --text-strong: #ffffff;
    --text:        rgba(255, 255, 255, 0.78);
    --text-muted:  rgba(255, 255, 255, 0.50);
    --hairline:    rgba(255, 255, 255, 0.14);
}

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

/* Components below set their own `display`, which would otherwise win over
   the UA stylesheet's [hidden] rule and leave "hidden" elements on screen. */
[hidden] { display: none !important; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 76px;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 17px;
    line-height: 1.5;
    color: var(--text);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    transition: background-color 700ms var(--ease-soft), color 700ms var(--ease-soft);
}

/* Page-level theme, driven by the scroll engine in site.js. */
body.theme-dark { background: var(--ink); color: rgba(255, 255, 255, 0.78); }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.022em; color: var(--text-strong); }
p  { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 3px;
    border-radius: 4px;
}

/* --- Type scale (Apple-ish: huge, tight, optically balanced) ------------ */
.t-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--gold);
}
/* Hairline rule before the eyebrow — the small editorial cue that separates
   a considered page from a template. */
.t-eyebrow::before {
    content: "";
    width: 26px;
    height: 1px;
    background: currentColor;
    opacity: 0.55;
    flex: 0 0 auto;
}
.t-eyebrow--bare::before { display: none; }
.t-center .t-eyebrow, .scrolly__panel .t-eyebrow { justify-content: center; }

/* Display sizes carry negative tracking that tightens as they grow, which is
   what keeps very large Apple-style headlines from looking loose. */
.t-display  { font-size: clamp(3rem, 8.2vw, 6.25rem);    line-height: 0.98; letter-spacing: -0.038em; font-weight: 600; }
.t-headline { font-size: clamp(2.125rem, 5vw, 3.75rem);  line-height: 1.06; letter-spacing: -0.03em;  font-weight: 600; }
.t-title    { font-size: clamp(1.4rem, 2.4vw, 2.125rem); line-height: 1.14; letter-spacing: -0.022em; }
.t-lead     { font-size: clamp(1.125rem, 1.6vw, 1.5rem); line-height: 1.42; letter-spacing: -0.012em; color: var(--text); font-weight: 400; }
.t-body     { font-size: 1.0625rem; line-height: 1.6; color: var(--text); }
.t-small    { font-size: 0.8125rem; line-height: 1.5; color: var(--text-muted); }
.t-serif    { font-family: var(--font-serif); font-weight: 500; }
/* One accented word per headline, never two. */
.t-shine {
    background: linear-gradient(96deg, var(--gold) 0%, var(--gold-soft) 46%, var(--gold) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.t-balance { text-wrap: balance; }
.t-gold     { color: var(--gold); }
.t-center   { text-align: center; }
.measure    { max-width: 46ch; }
.measure-wide { max-width: 62ch; }
.mx-auto    { margin-left: auto; margin-right: auto; }

/* --- Layout ------------------------------------------------------------- */
.shell {
    width: 100%;
    max-width: var(--shell);
    margin-inline: auto;
    padding-inline: var(--gutter);
}
.shell--narrow { max-width: 820px; }
.section { padding-block: clamp(72px, 11vw, 148px); }
.section--tight { padding-block: clamp(48px, 7vw, 88px); }
.section--paper { background: var(--paper); }
.section--alt   { background: var(--paper-alt); }
.section--ink   { background: var(--ink); }
.section--navy  { background: var(--navy); }
.stack > * + * { margin-top: 1.25rem; }
.stack-lg > * + * { margin-top: 2rem; }
.hairline { border: 0; border-top: 1px solid var(--hairline); margin: 0; }

.grid { display: grid; gap: clamp(20px, 3vw, 32px); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }

/* --- Buttons ------------------------------------------------------------ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 26px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 0.9375rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    cursor: pointer;
    background: none;
    transition: background-color 220ms var(--ease), color 220ms var(--ease),
                border-color 220ms var(--ease), transform 220ms var(--ease),
                opacity 220ms var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--navy); color: #fff; }
.btn--primary:hover { background: var(--navy-lift); }
.btn--gold { background: var(--gold); color: #1a1405; font-weight: 600; }
.btn--gold:hover { background: var(--gold-soft); }
.btn--ghost { border-color: var(--hairline); color: var(--text-strong); }
.btn--ghost:hover { border-color: var(--text-strong); }
.btn--quiet { padding: 6px 2px; color: var(--navy); border-radius: 0; }
.btn--quiet:hover { text-decoration: underline; text-underline-offset: 4px; }
.btn--block { width: 100%; }
.btn--sm { padding: 9px 18px; font-size: 0.875rem; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.4; cursor: not-allowed; transform: none; }
.on-dark .btn--ghost { border-color: rgba(255,255,255,0.3); color: #fff; }
.on-dark .btn--ghost:hover { border-color: #fff; background: rgba(255,255,255,0.08); }

.link-arrow { display: inline-flex; align-items: center; gap: 6px; color: var(--navy); font-weight: 500; }
.on-dark .link-arrow { color: var(--gold-soft); }
.link-arrow svg { transition: transform 220ms var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }

/* --- Navigation --------------------------------------------------------- */
.nav {
    position: sticky;
    top: 0;
    z-index: 900;
    background: rgba(251, 251, 253, 0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--hairline);
    transition: background-color 500ms var(--ease-soft), border-color 500ms var(--ease-soft);
}
body.theme-dark .nav {
    background: rgba(12, 12, 15, 0.72);
    border-bottom-color: rgba(255, 255, 255, 0.12);
}
body.theme-dark .nav,
body.theme-dark .nav .nav__link { color: #fff; }

.nav__inner {
    max-width: var(--shell);
    margin-inline: auto;
    padding: 0 var(--gutter);
    height: 60px;
    display: flex;
    align-items: center;
    gap: 28px;
}
.nav__brand { display: flex; align-items: baseline; gap: 10px; margin-right: auto; }
.nav__mark {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--text-strong);
}
body.theme-dark .nav__mark { color: #fff; }
.nav__mark span { color: var(--gold); }
.nav__tagline {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-muted);
}
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__link {
    font-size: 0.8125rem;
    font-weight: 400;
    letter-spacing: 0.01em;
    color: var(--text);
    opacity: 0.85;
    transition: opacity 180ms var(--ease);
    background: none;
    border: 0;
    padding: 0;
    cursor: pointer;
}
.nav__link:hover { opacity: 1; }
.nav__link[aria-current="page"] { font-weight: 600; opacity: 1; color: var(--text-strong); }
body.theme-dark .nav__link[aria-current="page"] { color: #fff; }

.nav__bag { position: relative; display: inline-flex; align-items: center; gap: 7px; }
.nav__bag-count {
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    display: inline-grid;
    place-items: center;
    background: var(--gold);
    color: #1a1405;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
.nav__bag-count[hidden] { display: none; }

/* Mega dropdown (the Products menu, grouped by department) */
/* Static, so the panel resolves against .nav itself. The nav's
   backdrop-filter would otherwise make `fixed` behave unpredictably. */
.navmenu { position: static; }
.navmenu__panel {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 899;
    background: var(--paper);
    border-bottom: 1px solid var(--hairline);
    box-shadow: 0 30px 60px -30px rgba(10, 31, 68, 0.28);
    padding-block: 34px 44px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 260ms var(--ease), transform 260ms var(--ease), visibility 260ms;
}
body.theme-dark .navmenu__panel { background: #101014; border-bottom-color: rgba(255,255,255,0.12); }
.navmenu__panel.is-open { opacity: 1; visibility: visible; transform: translateY(0); }
.navmenu__inner { max-width: var(--shell); margin-inline: auto; padding-inline: var(--gutter); }
.navmenu__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.navmenu__heading {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 14px;
}
.navmenu__list > li + li { margin-top: 9px; }
.navmenu__list a {
    font-size: 1.0625rem;
    font-weight: 500;
    letter-spacing: -0.015em;
    color: var(--text-strong);
    transition: color 160ms var(--ease);
}
.navmenu__list a:hover { color: var(--gold); }
.navmenu__list .t-small { display: block; font-weight: 400; }

.nav__toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }

@media (max-width: 900px) {
    .nav__links {
        position: fixed;
        inset: 60px 0 auto;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: var(--paper);
        border-bottom: 1px solid var(--hairline);
        padding: 8px var(--gutter) 24px;
        max-height: calc(100vh - 60px);
        overflow-y: auto;
        transform: translateY(-12px);
        opacity: 0;
        visibility: hidden;
        transition: opacity 240ms var(--ease), transform 240ms var(--ease), visibility 240ms;
    }
    body.theme-dark .nav__links { background: var(--ink); }
    .nav__links.is-open { opacity: 1; visibility: visible; transform: translateY(0); }
    .nav__links > * { padding-block: 14px; border-bottom: 1px solid var(--hairline); text-align: left; }
    .nav__toggle { display: block; order: 3; }
    .navmenu__panel { position: static; padding-block: 8px 18px; background: none !important; border: 0; box-shadow: none; }
    .navmenu__inner { padding-inline: 0; }
    .navmenu__grid { gap: 20px; }
    .navmenu__panel:not(.is-open) { display: none; }
    .navmenu__panel.is-open { opacity: 1; visibility: visible; transform: none; }
}

/* --- Scroll reveal ------------------------------------------------------ */
.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 900ms var(--ease), transform 900ms var(--ease);
    transition-delay: var(--reveal-delay, 0ms);
    will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: none; }
.reveal--scale { transform: translateY(26px) scale(0.97); }
.reveal--scale.is-visible { transform: none; }

/* --- Pinned scroll-scrub stage -----------------------------------------
   Markup:
   <section class="scrolly" data-scrolly data-theme="dark" style="--track:340vh">
     <div class="scrolly__track">
       <div class="scrolly__stage">
         <div class="scrolly__layer" data-scrolly-bg>…</div>
         <div class="scrolly__panels">
           <div class="scrolly__panel" data-scrolly-panel>…</div>
   The engine writes --p (0..1) on the section and drives the panels so that
   one block fades out while the next slides up into its place.             */
.scrolly { position: relative; }
.scrolly__track { height: var(--track, 300vh); }
.scrolly__stage {
    position: sticky;
    top: 0;
    height: 100vh;
    overflow: hidden;
    display: grid;
    place-items: center;
}
.scrolly__layer {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 600ms var(--ease-soft);
    pointer-events: none;
}
.scrolly__layer.is-active { opacity: 1; }
.scrolly__panels {
    position: relative;
    width: 100%;
    max-width: var(--shell);
    padding-inline: var(--gutter);
    display: grid;
    place-items: center;
    min-height: 58vh;
}
.scrolly__panel {
    grid-area: 1 / 1;
    width: 100%;
    text-align: center;
    will-change: opacity, transform;
    pointer-events: none;
}
.scrolly__panel.is-active { pointer-events: auto; }
.scrolly__progress {
    position: absolute;
    bottom: 34px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}
.scrolly__dot {
    width: 30px; height: 2px;
    border-radius: 999px;
    background: currentColor;
    opacity: 0.20;
    transition: opacity 400ms var(--ease), width 400ms var(--ease);
}
.scrolly__dot.is-active { opacity: 0.95; width: 52px; }

/* Parallax drift, driven by data-parallax="0.25" */
[data-parallax] { will-change: transform; }

/* --- Surface grain ------------------------------------------------------
   A very low-opacity noise layer stops large dark gradients from banding on
   cheap panels and gives the dark sections a printed-paper depth.          */
.grain { position: relative; }
/* The noise sits behind the content, never over it. */
.grain > * { position: relative; z-index: 1; }
.grain::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0.13;
    mix-blend-mode: overlay;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}

/* --- Provenance ticker --------------------------------------------------
   Slow marquee of real lot references. Provenance is the product here, so
   it gets to be decoration.                                               */
.ticker {
    overflow: hidden;
    border-block: 1px solid var(--hairline);
    padding-block: 15px;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
}
.ticker__track {
    display: flex;
    gap: 44px;
    width: max-content;
    animation: tickerRun 46s linear infinite;
}
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--text-muted);
    white-space: nowrap;
}
.ticker__item::before { content: "◆"; color: var(--gold); font-size: 7px; }
@keyframes tickerRun { from { transform: translate3d(0,0,0); } to { transform: translate3d(-50%,0,0); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }

/* --- Stat band ---------------------------------------------------------- */
.stats { display: grid; gap: 1px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.stat { padding: 30px 8px; text-align: center; }
.stat__value {
    font-size: clamp(2.25rem, 4.4vw, 3.5rem);
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 1;
    color: var(--text-strong);
    font-variant-numeric: tabular-nums;
}
.stat__label {
    margin-top: 12px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-muted);
}

/* --- Hero --------------------------------------------------------------- */
.hero {
    position: relative;
    min-height: min(92vh, 900px);
    display: grid;
    place-items: center;
    text-align: center;
    padding-block: clamp(80px, 14vh, 160px);
    background:
        radial-gradient(90% 60% at 50% 0%, rgba(18, 48, 95, 0.55) 0%, transparent 62%),
        radial-gradient(60% 50% at 82% 88%, rgba(201, 162, 39, 0.20) 0%, transparent 70%),
        var(--ink);
    overflow: hidden;
}
.hero__glow {
    position: absolute;
    width: 74vmax; height: 74vmax;
    left: 50%; top: -34vmax;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(201,162,39,0.13) 0%, transparent 58%);
    pointer-events: none;
}
.hero__inner { position: relative; }

/* Split "two departments" visual */
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--hairline); border-radius: var(--radius-lg); overflow: hidden; }
.duo__half { padding: clamp(28px, 4vw, 52px); background: var(--paper); }
.duo__half--b { background: var(--paper-alt); }
.duo__icon { font-size: 30px; line-height: 1; margin-bottom: 18px; }
@media (max-width: 720px) { .duo { grid-template-columns: 1fr; } }

/* --- Product cards ------------------------------------------------------ */
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: var(--radius);
    padding: 22px;
    transition: transform 320ms var(--ease), box-shadow 320ms var(--ease), border-color 320ms var(--ease);
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 26px 56px -26px rgba(10, 31, 68, 0.34);
    border-color: rgba(10, 31, 68, 0.20);
}
.card:hover .card__media { background-position: 100% 50%; }
.card:hover .card__media img { transform: scale(1.045); }
body.theme-dark .card { background: var(--ink-soft); border-color: rgba(255,255,255,0.10); }
.card__media {
    aspect-ratio: 4 / 3;
    border-radius: var(--radius-sm);
    background: linear-gradient(120deg, #eef0f4 0%, #e6e9ef 45%, #edeef2 100%);
    background-size: 200% 100%;
    background-position: 0 50%;
    transition: background-position 700ms var(--ease);
    display: grid;
    place-items: center;
    font-size: 44px;
    margin-bottom: 18px;
    overflow: hidden;
}
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease); }
.card__dept {
    font-size: 9px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--text-muted);
}
.card__title { font-size: 1.0625rem; font-weight: 600; letter-spacing: -0.015em; margin-top: 6px; }
.card__meta { margin-top: 4px; }
.card__price-row { margin-top: auto; padding-top: 18px; display: flex; align-items: baseline; gap: 10px; }
.card__price { font-size: 1.25rem; font-weight: 600; color: var(--text-strong); font-variant-numeric: tabular-nums; }
.card__was { font-size: 0.8125rem; color: var(--text-muted); text-decoration: line-through; }
.card__save { font-size: 0.75rem; font-weight: 700; color: #1c7a4a; }
.card__actions { margin-top: 14px; display: flex; gap: 8px; }
.pill {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
    background: rgba(10, 31, 68, 0.07);
    color: var(--navy);
}
.pill--gold { background: rgba(201, 162, 39, 0.16); color: #7a6112; }
.pill--new  { background: rgba(28, 122, 74, 0.12); color: #1c7a4a; }
.card__flag {
    position: absolute; top: 14px; right: 14px;
    background: var(--gold); color: #1a1405;
    font-size: 9px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase;
    padding: 4px 9px; border-radius: 999px;
}

/* --- Filter bar + custom dropdown -------------------------------------- */
.filters {
    position: sticky;
    top: 60px;
    z-index: 700;
    background: rgba(251, 251, 253, 0.86);
    backdrop-filter: saturate(180%) blur(18px);
    -webkit-backdrop-filter: saturate(180%) blur(18px);
    border-bottom: 1px solid var(--hairline);
    padding-block: 14px;
}
.filters__inner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.filters__count { margin-left: auto; }
.seg { display: inline-flex; padding: 3px; background: rgba(12,12,15,0.06); border-radius: 999px; }
.seg__btn {
    border: 0; background: none; cursor: pointer;
    padding: 7px 16px; border-radius: 999px;
    font-size: 0.8125rem; font-weight: 500; color: var(--text);
    transition: background-color 200ms var(--ease), color 200ms var(--ease), box-shadow 200ms var(--ease);
}
.seg__btn[aria-pressed="true"] { background: #fff; color: var(--text-strong); font-weight: 600; box-shadow: 0 1px 3px rgba(0,0,0,0.12); }

.select { position: relative; }
.select__btn {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 9px 16px;
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: 999px;
    font-size: 0.875rem;
    cursor: pointer;
    transition: border-color 200ms var(--ease);
}
.select__btn:hover { border-color: rgba(12,12,15,0.3); }
.select__btn svg { transition: transform 240ms var(--ease); }
.select__btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.select__menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 280px;
    max-height: 60vh;
    overflow-y: auto;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(20px);
    border: 1px solid var(--hairline);
    border-radius: var(--radius);
    box-shadow: 0 24px 60px -20px rgba(10, 31, 68, 0.35);
    padding: 10px;
    z-index: 750;
    opacity: 0; visibility: hidden; transform: translateY(-6px) scale(0.985);
    transform-origin: top left;
    transition: opacity 200ms var(--ease), transform 200ms var(--ease), visibility 200ms;
}
.select__menu.is-open { opacity: 1; visibility: visible; transform: none; }
.select__group + .select__group { margin-top: 8px; border-top: 1px solid var(--hairline); padding-top: 8px; }
.select__label {
    padding: 8px 12px 6px;
    font-size: 9px; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--text-muted);
}
.select__option {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    width: 100%;
    padding: 9px 12px;
    border: 0; background: none; cursor: pointer;
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    text-align: left;
    transition: background-color 150ms var(--ease);
}
.select__option:hover { background: rgba(10, 31, 68, 0.06); }
.select__option[aria-selected="true"] { font-weight: 600; color: var(--navy); background: rgba(10,31,68,0.06); }
.select__option .t-small { font-variant-numeric: tabular-nums; }

/* --- Forms -------------------------------------------------------------- */
.field { display: block; }
.field + .field, .field-row + .field, .field + .field-row, .field-row + .field-row { margin-top: 18px; }
.field__label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: var(--text-strong);
    margin-bottom: 7px;
}
.field__hint { display: block; margin-top: 6px; font-size: 0.75rem; color: var(--text-muted); }
.field__error { display: none; margin-top: 6px; font-size: 0.75rem; font-weight: 600; color: #b42318; }
.field.is-invalid .field__error { display: block; }
.field.is-invalid .input, .field.is-invalid .select-native { border-color: #b42318; }
.field-row { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }

.input, .select-native, textarea.input {
    width: 100%;
    padding: 12px 14px;
    font: inherit;
    font-size: 0.9375rem;
    color: var(--text-strong);
    background: #fff;
    border: 1px solid rgba(12,12,15,0.18);
    border-radius: var(--radius-sm);
    transition: border-color 180ms var(--ease), box-shadow 180ms var(--ease);
}
.input:focus, .select-native:focus, textarea.input:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(10, 31, 68, 0.12);
}
textarea.input { min-height: 120px; resize: vertical; line-height: 1.5; }
.select-native { appearance: none; background-image: none; cursor: pointer; }
.input-prefixed { position: relative; }
.input-prefixed .input { padding-left: 30px; }
.input-prefixed__mark { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); font-size: 0.9375rem; }
.checkline { display: flex; gap: 11px; align-items: flex-start; font-size: 0.875rem; }
.checkline input { margin-top: 3px; flex: 0 0 auto; }

.panel {
    background: #fff;
    border: 1px solid var(--hairline);
    border-radius: var(--radius);
    padding: clamp(22px, 3vw, 34px);
}
.panel--flush { padding: 0; overflow: hidden; }
.panel__head { padding: 20px clamp(22px, 3vw, 30px); border-bottom: 1px solid var(--hairline); display: flex; align-items: center; gap: 12px; }
.panel__body { padding: clamp(22px, 3vw, 30px); }
.note {
    display: flex; gap: 12px;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    background: rgba(201, 162, 39, 0.10);
    border: 1px solid rgba(201, 162, 39, 0.35);
    font-size: 0.8125rem;
    line-height: 1.5;
}
.note--info { background: rgba(10, 31, 68, 0.05); border-color: rgba(10, 31, 68, 0.18); }
.note--warn { background: rgba(180, 35, 24, 0.06); border-color: rgba(180, 35, 24, 0.28); }
.note strong { color: var(--text-strong); }

/* --- Checkout ----------------------------------------------------------- */
.checkout { display: grid; gap: clamp(24px, 4vw, 44px); grid-template-columns: minmax(0, 1.55fr) minmax(300px, 1fr); align-items: start; }
@media (max-width: 940px) { .checkout { grid-template-columns: 1fr; } .checkout__aside { order: -1; } }
.checkout__aside { position: sticky; top: 84px; }
.steps { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-bottom: 30px; }
.steps__item { display: flex; align-items: center; gap: 9px; font-size: 0.8125rem; color: var(--text-muted); }
.steps__num {
    width: 22px; height: 22px; border-radius: 999px;
    display: grid; place-items: center;
    background: rgba(12,12,15,0.08);
    font-size: 11px; font-weight: 700;
}
.steps__item.is-current { color: var(--text-strong); font-weight: 600; }
.steps__item.is-current .steps__num { background: var(--navy); color: #fff; }
.steps__item.is-done .steps__num { background: #1c7a4a; color: #fff; }

.line {
    display: grid;
    grid-template-columns: 62px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding-block: 16px;
}
.line + .line { border-top: 1px solid var(--hairline); }
.line__thumb {
    width: 62px; height: 62px;
    border-radius: var(--radius-sm);
    background: linear-gradient(145deg, #eef0f4, #e3e6ec);
    display: grid; place-items: center;
    font-size: 26px;
    overflow: hidden;
}
.line__thumb img { width: 100%; height: 100%; object-fit: cover; }
.line__title { font-size: 0.9375rem; font-weight: 600; color: var(--text-strong); }
.line__right { text-align: right; font-variant-numeric: tabular-nums; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--hairline); border-radius: 999px; overflow: hidden; margin-top: 8px; }
.qty button { width: 28px; height: 28px; border: 0; background: none; cursor: pointer; font-size: 15px; line-height: 1; }
.qty button:hover { background: rgba(12,12,15,0.06); }
.qty output { min-width: 26px; text-align: center; font-size: 0.8125rem; font-variant-numeric: tabular-nums; }

.totals { font-variant-numeric: tabular-nums; }
.totals__row { display: flex; justify-content: space-between; gap: 16px; padding-block: 9px; font-size: 0.9375rem; }
.totals__row--grand { border-top: 1px solid var(--hairline); margin-top: 8px; padding-top: 16px; font-size: 1.125rem; font-weight: 600; color: var(--text-strong); }
.empty { text-align: center; padding-block: 56px; }

/* --- Wizard ------------------------------------------------------------- */
.wizard { display: grid; gap: clamp(24px, 4vw, 40px); grid-template-columns: 232px minmax(0, 1fr); align-items: start; }
@media (max-width: 900px) { .wizard { grid-template-columns: 1fr; } }
.wizard__rail { position: sticky; top: 84px; }
@media (max-width: 900px) { .wizard__rail { position: static; } }
.wizard__step {
    display: flex; gap: 12px; align-items: flex-start;
    padding: 11px 12px;
    border-radius: var(--radius-sm);
    border: 0; background: none; width: 100%; text-align: left; cursor: pointer;
    color: var(--text-muted);
    transition: background-color 180ms var(--ease), color 180ms var(--ease);
}
.wizard__step:hover { background: rgba(12,12,15,0.04); }
.wizard__step.is-current { background: rgba(10,31,68,0.07); color: var(--text-strong); }
.wizard__step.is-current .wizard__step-name { font-weight: 600; }
.wizard__badge {
    flex: 0 0 auto;
    width: 22px; height: 22px; border-radius: 999px;
    display: grid; place-items: center;
    background: rgba(12,12,15,0.08);
    font-size: 11px; font-weight: 700;
}
.wizard__step.is-current .wizard__badge { background: var(--navy); color: #fff; }
.wizard__step.is-done .wizard__badge { background: #1c7a4a; color: #fff; }
.wizard__step-name { font-size: 0.875rem; display: block; }
.wizard__pane { display: none; }
.wizard__pane.is-active { display: block; animation: paneIn 480ms var(--ease) both; }
@keyframes paneIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.wizard__bar { display: flex; align-items: center; gap: 12px; margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--hairline); }
.wizard__bar .btn--primary { margin-left: auto; }
.wizard__meter { height: 3px; background: rgba(12,12,15,0.09); border-radius: 999px; overflow: hidden; margin-bottom: 26px; }
.wizard__meter span { display: block; height: 100%; background: var(--gold); border-radius: 999px; transition: width 420ms var(--ease); }

.choice-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.choice {
    display: block; width: 100%; text-align: left; cursor: pointer;
    padding: 18px;
    border: 1px solid var(--hairline);
    border-radius: var(--radius);
    background: #fff;
    transition: border-color 200ms var(--ease), box-shadow 200ms var(--ease), transform 200ms var(--ease);
}
.choice:hover { transform: translateY(-2px); border-color: rgba(10,31,68,0.3); }
.choice[aria-pressed="true"], .choice.is-selected {
    border-color: var(--navy);
    box-shadow: 0 0 0 2px rgba(10, 31, 68, 0.18);
}
.choice__icon { display: block; font-size: 26px; line-height: 1; margin-bottom: 10px; }
.choice__name { display: block; font-weight: 600; color: var(--text-strong); font-size: 0.9375rem; }
.choice .t-small { display: block; margin-top: 5px; }
.choice > span { display: block; }

.dropzone {
    border: 1.5px dashed rgba(12,12,15,0.25);
    border-radius: var(--radius);
    padding: 40px 24px;
    text-align: center;
    background: rgba(12,12,15,0.02);
    transition: border-color 200ms var(--ease), background-color 200ms var(--ease);
    cursor: pointer;
}
.dropzone.is-hot { border-color: var(--gold); background: rgba(201,162,39,0.08); }
.thumbs { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); margin-top: 16px; }
.thumb { position: relative; aspect-ratio: 1; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--hairline); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb button {
    position: absolute; top: 5px; right: 5px;
    width: 22px; height: 22px; border-radius: 999px;
    border: 0; cursor: pointer;
    background: rgba(12,12,15,0.72); color: #fff;
    font-size: 13px; line-height: 1;
    display: grid; place-items: center;
}
.thumb__flag {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: rgba(12,12,15,0.72); color: #fff;
    font-size: 9px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
    text-align: center; padding: 3px;
}

.readout { display: grid; gap: 1px; background: var(--hairline); border-radius: var(--radius); overflow: hidden; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.readout__cell { background: #fff; padding: 16px 18px; }
.readout__k { font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-muted); }
.readout__v { font-size: 1.375rem; font-weight: 600; color: var(--text-strong); margin-top: 5px; font-variant-numeric: tabular-nums; }
.readout__v small { font-size: 0.75rem; font-weight: 500; color: var(--text-muted); }
.readout__v.is-good { color: #1c7a4a; }
.readout__v.is-bad  { color: #b42318; }

.kv { display: grid; grid-template-columns: minmax(120px, 34%) 1fr; gap: 10px 20px; font-size: 0.9375rem; }
.kv dt { color: var(--text-muted); font-size: 0.875rem; }
.kv dd { margin: 0; color: var(--text-strong); }

/* --- Timeline / method steps ------------------------------------------- */
.rail { display: grid; gap: 0; }
.rail__item { display: grid; grid-template-columns: 54px 1fr; gap: 20px; padding-block: 26px; border-top: 1px solid var(--hairline); }
.rail__num { font-family: var(--font-serif); font-size: 1.75rem; color: var(--gold); line-height: 1; }

/* --- Footer ------------------------------------------------------------- */
.footer { background: var(--paper-alt); border-top: 1px solid var(--hairline); padding-block: 48px 36px; font-size: 0.8125rem; }
body.theme-dark .footer { background: #08080a; border-top-color: rgba(255,255,255,0.10); }
.footer__grid { display: grid; gap: 28px; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.footer__heading { font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-strong); margin-bottom: 12px; }
.footer__list li + li { margin-top: 8px; }
.footer__list a { color: var(--text-muted); }
.footer__list a:hover { color: var(--text-strong); text-decoration: underline; text-underline-offset: 3px; }
.footer__legal { margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--hairline); display: flex; flex-wrap: wrap; gap: 8px 20px; color: var(--text-muted); }

/* --- Toast -------------------------------------------------------------- */
.toast {
    position: fixed;
    left: 50%; bottom: 28px;
    transform: translate(-50%, 140%);
    z-index: 1000;
    display: flex; align-items: center; gap: 12px;
    padding: 13px 20px;
    background: rgba(12, 12, 15, 0.92);
    backdrop-filter: blur(14px);
    color: #fff;
    border-radius: 999px;
    font-size: 0.875rem;
    box-shadow: 0 20px 50px -18px rgba(0,0,0,0.6);
    transition: transform 420ms var(--ease);
}
.toast.is-up { transform: translate(-50%, 0); }

/* --- Utilities ---------------------------------------------------------- */
.sr-only {
    position: absolute; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
    position: absolute; left: 12px; top: -60px; z-index: 1000;
    background: var(--navy); color: #fff;
    padding: 10px 16px; border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    transition: top 200ms var(--ease);
}
.skip:focus { top: 0; }
.flex { display: flex; align-items: center; gap: 12px; }
.flex-wrap { flex-wrap: wrap; }
.flex-between { justify-content: space-between; }
.mt-0 { margin-top: 0 !important; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 36px; }
.mt-5 { margin-top: 56px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 36px; }
.tabular { font-variant-numeric: tabular-nums; }

/* --- Motion preferences ------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .reveal { opacity: 1 !important; transform: none !important; }
    .scrolly__track { height: auto !important; }
    .scrolly__stage { position: static; height: auto; overflow: visible; padding-block: 64px; }
    .scrolly__panels { display: block; min-height: 0; }
    .scrolly__panel { opacity: 1 !important; transform: none !important; margin-block: 56px; }
    .scrolly__layer { display: none; }
    .scrolly__progress { display: none; }
}

/* --- Print -------------------------------------------------------------- */
@media print {
    .nav, .filters, .footer, .toast, .wizard__rail, .wizard__bar { display: none !important; }
    body { background: #fff; }
}
