/* iv8 storefront (formerly 8shop) — "Krējums".
 *
 * A warm-cream retail system: an oat page rather than a white one, white cards
 * standing on it, deep ink for type and the primary button, and vermilion as the
 * one colour that means "act". Yellow is its quieter partner and marks a
 * campaign; green means a thing is in stock and nothing else.
 *
 * Three details carry it, and they are the ones to protect when editing:
 *
 *  1. THREE TYPEFACES, THREE JOBS. Archivo (800/900) sets headlines and prices.
 *     Manrope sets everything a person reads. IBM Plex Mono sets the things that
 *     are not really words — article numbers, dates, stock counts, the basket
 *     total. Losing the mono is what makes a shop like this look generic.
 *  2. BIG CORNERS. 28px on the blocks, 16–22 inside them, pills on anything you
 *     press. The page is a stack of soft slabs on cream, not boxes with rules.
 *  3. CREAM IS THE GROUND, WHITE IS THE CARD. Nothing on this page is white on
 *     white; if a card needs separating from another card, it goes on cream.
 *
 * Single theme by intent. There is no dark variant and no prefers-color-scheme
 * block: the palette is a lit retail floor. The [data-theme] rules restate the
 * light values so a stray attribute cannot produce a half-dark page.
 *
 * Variable NAMES are carried across systems because templates reference them
 * inline (var(--space-4), var(--ok), var(--border)…). Only the values move.
 */

/* ---------------------------------------------------------------- fonts ---- */

/* Self-hosted rather than linked from a font CDN: the shop serves EU customers,
 * a third party does not need their IP address to render a price, and the whole
 * set is smaller than one product photograph.
 *
 * latin-ext is not optional here. Ā Č Ē Ģ Ī Ķ Ļ Ņ Š Ū Ž all live in that subset,
 * so a latin-only build silently falls back mid-word on Latvian text.
 *
 * Cyrillic is the same rule one language later, and it was missed for the whole
 * first week of /ru/: every @font-face declared latin and latin-ext only, so
 * U+0400-04FF matched no rule and 238 text nodes on the Russian home page
 * rendered in Segoe UI beside Latin set in Manrope. Nothing failed — a fallback
 * font is a working font — and it is visible the moment anyone looks at the page.
 *
 * ARCHIVO HAS NO CYRILLIC. The typeface does not include it and no subset can be
 * downloaded, so the Cyrillic half of the display family below is Manrope at its
 * heaviest weight, published under the Archivo family name. One family, two
 * files, the browser choosing by codepoint: a heading reads Archivo 900 in
 * Latvian and Manrope 800 in Russian, which is the closest the two scripts can
 * get without a fourth typeface.
 *
 * The filenames are the cache key — these URLs are served immutable, so a
 * different font means a different filename, never a new file at the old name. */

@font-face {
  font-family: Manrope; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url(/assets/fonts/manrope-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: Manrope; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url(/assets/fonts/manrope-lext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: Archivo; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url(/assets/fonts/archivo-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: Archivo; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url(/assets/fonts/archivo-lext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/assets/fonts/plexmono-400-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/assets/fonts/plexmono-400-lext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url(/assets/fonts/plexmono-500-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url(/assets/fonts/plexmono-500-lext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Cyrillic. Two ranges per face, matching the split the subsets ship in:
 * U+0400-045F is the Russian alphabet and is what /ru/ almost entirely uses;
 * the -ext range carries the historic and minority-language letters and is a
 * couple of kilobytes, so it costs nothing to be complete. U+2116 is № and
 * U+0301 the combining stress accent, both of which appear in ordinary text. */
@font-face {
  font-family: Manrope; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url(/assets/fonts/manrope-cyrillic.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Manrope; font-style: normal; font-weight: 400 800; font-display: swap;
  src: url(/assets/fonts/manrope-cyrillic-ext.woff2) format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F,
    U+FE2E-FE2F;
}

/* Archivo's Cyrillic, which is Manrope — see the note at the top of this block.
 *
 * Declared 400-900 to match every weight the display face is used at, even
 * though the file itself stops at 800: a variable font clamps to its own axis,
 * so a heading asking for 900 gets Manrope's heaviest rather than no match and a
 * fallback. Getting this wrong is invisible in Latvian and only shows on /ru/. */
@font-face {
  font-family: Archivo; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url(/assets/fonts/manrope-cyrillic.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Archivo; font-style: normal; font-weight: 400 900; font-display: swap;
  src: url(/assets/fonts/manrope-cyrillic-ext.woff2) format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F,
    U+FE2E-FE2F;
}

@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/assets/fonts/plexmono-400-cyrillic.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/assets/fonts/plexmono-400-cyrillic-ext.woff2) format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F,
    U+FE2E-FE2F;
}
@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url(/assets/fonts/plexmono-500-cyrillic.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url(/assets/fonts/plexmono-500-cyrillic-ext.woff2) format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F,
    U+FE2E-FE2F;
}

/* --------------------------------------------------------------- tokens ---- */

:root {
  /* Ink does chrome, body text and the primary button. One dark for all three is
   * what keeps a page this warm from looking like a toy. */
  --chrome: #23262b;
  --chrome-deep: #23262b;
  --chrome-text: #ffffff;
  --chrome-muted: #a4a8ac;

  /* Cream is the ground; white is the card. Nothing is white on white. */
  --surface: #ffffff;
  --page: #faf7f3;
  --surface-sunken: #faf7f3;
  --surface-raised: #ffffff;
  --surface-soft: #faf7f3;
  --tint-strong: #faf7f3;

  --text: #23262b;
  --text-muted: #5a6066;
  --text-faint: #a4a8ac;

  --border: #e8e5e0;
  --border-soft: #e8e5e0;
  --border-strong: #e8e5e0;

  /* Vermilion means act. --accent-deep is the one that passes contrast as text
   * on cream; --accent itself is for fills and marks. */
  --accent: #e2593a;
  --accent-hover: #c94a2e;
  --accent-soft: #faf7f3;
  --accent-deep: #c94a2e;
  /* A tint for "this one is chosen". --accent-soft and --surface-sunken are
     both #faf7f3, the page cream — so a selected filter on a white card was
     the same colour as a hovered one and neither read as selected. */
  --accent-wash: rgba(226, 89, 58, 0.10);
  --accent-text: #ffffff;
  --accent-lift: #e2593a;

  /* Yellow marks a campaign and never an action. */
  --promo: #e2593a;
  --promo-soft: #faf7f3;
  --promo-ink: #ffffff;

  /* Primary action is the ink pill. Vermilion is spent on the buy button and on
   * the marks that carry a saving — spending it everywhere marks nothing. */
  --cta: #23262b;
  --cta-hover: #3a3f46;
  --cta-text: #ffffff;

  --ok: #16855c;
  --ok-surface: #faf7f3;
  --warn: #c94a2e;
  --warn-surface: #faf7f3;
  --danger: #c94a2e;
  --danger-surface: #faf7f3;

  --cut: #e2593a;
  --star: #e2593a;

  --font: Manrope, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --font-display: Archivo, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  /* Not a decoration. Article numbers, dates, stock counts and the basket total
   * are data, and setting them in mono is what stops a product card reading like
   * a paragraph. */
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Consolas, monospace;

  --text-xs: 11px;
  --text-sm: 12px;
  --text-base: 14px;
  --text-lg: 17px;
  --text-xl: 24px;
  --text-2xl: 30px;
  --text-3xl: 42px;

  --leading: 1.5;
  --leading-tight: 1.1;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 30px;
  --space-7: 40px;
  --space-8: 56px;

  /* Big corners. 28 on the slabs, 22/18/16 inside them, 10–12 on the small
   * things, and a pill on anything you press. */
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(35, 38, 43, .06);
  --shadow: 0 12px 30px rgba(35, 38, 43, .10);
  --shadow-lg: 0 20px 44px rgba(35, 38, 43, .16);

  --container: 1440px;
  --gutter: 40px;
  --ring: 0 0 0 3px rgba(226, 89, 58, .32);
}

:root[data-theme="dark"],
:root[data-theme="light"] {
  --surface: #ffffff;
  --page: #faf7f3;
  --surface-sunken: #faf7f3;
  --surface-raised: #ffffff;
  --surface-soft: #faf7f3;
  --tint-strong: #faf7f3;
  --text: #23262b;
  --text-muted: #5a6066;
  --text-faint: #a4a8ac;
  --border: #e8e5e0;
  --border-soft: #e8e5e0;
  --border-strong: #e8e5e0;
  --accent: #e2593a;
  --accent-hover: #c94a2e;
  --accent-soft: #faf7f3;
  --accent-deep: #c94a2e;
  --accent-text: #ffffff;
  --cta: #23262b;
  --cta-hover: #3a3f46;
  --cta-text: #ffffff;
  --ok: #16855c;
  --ok-surface: #faf7f3;
  --danger: #c94a2e;
  --danger-surface: #faf7f3;
}

/* ---------------------------------------------------------------- base ---- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  /* The surround, a shade deeper than the page, so the shop reads as a sheet
   * laid on a table rather than as content adrift. Both values are the
   * design's. */
  background: #faf7f3;
  color: var(--text);
  font-family: var(--font);
  font-size: var(--text-base);
  line-height: var(--leading);
  -webkit-font-smoothing: antialiased;
}

/* The design's canvas: 1440 wide, centred, cream, and a 20px rhythm between
 * every block on it. `max-width` rather than `width` is the one liberty taken —
 * the design is drawn at a single size and says nothing about narrower screens.
 *
 * The 40px side margin lives on the blocks themselves, inline, exactly as the
 * design writes it. That is where the 1360px content measure comes from; there
 * is no .container in the ported markup and adding one back would reintroduce
 * the second, competing measure this rebuild removed. */
.page {
  max-width: var(--container);
  margin: 0 auto;
  background: var(--page);
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-bottom: 40px;
  min-height: 100vh;
}

/* main is a pass-through: its children are page blocks and must sit in the same
 * 20px rhythm as the header group above and the footer below. */
main {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  margin: 0 0 var(--space-3);
  font-family: var(--font-display);
  font-weight: 800;
  line-height: var(--leading-tight);
  letter-spacing: -0.015em;
}
h1 { font-size: var(--text-2xl); }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); }
h4 { font-size: var(--text-base); font-weight: 700; }
p { margin: 0 0 var(--space-3); }

:where(a, button, input, select, textarea):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Kept for the views that still lay themselves out rather than carrying the
 * design's inline geometry: the inner pages below the shop window. */
.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }

.spacer { flex: 1 1 auto; }
.row { display: flex; align-items: center; gap: var(--space-3); }
.row-wrap { display: flex; align-items: center; gap: var(--space-3); flex-wrap: wrap; }
.stack > * + * { margin-top: var(--space-5); }
.grow { flex: 1 1 auto; min-width: 0; }

.faint { color: var(--text-faint); font-size: var(--text-sm); }
.muted { color: var(--text-muted); }
.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.hint { color: var(--text-muted); font-size: var(--text-sm); margin: var(--space-3) 0 0; }

.price, .price-big, .amount, .counts b, .stepper input {
  font-family: var(--font-display);
  font-variant-numeric: tabular-nums;
}

/* -------------------------------------------------------------- ported ---- */

/* Everything below supports markup that carries the design's own inline styles.
 *
 * The rule for this section: it holds ONLY what an inline style attribute
 * cannot express — :hover, :checked, :focus, transitions, and the narrow-screen
 * overrides the design (drawn once, at 1440) has no opinion about. Anything
 * that is simply a value the design states goes inline in the template, next to
 * the element it belongs to, because that is what keeps this a port rather than
 * a second interpretation.
 *
 * If you find yourself adding a padding or a colour here, check the design
 * first: it probably belongs in the template. */

/* --- hover states, one per ported element ---------------------------------- */

/* The ink pill: header basket, hero primary, add-to-cart, "atvērt nodaļu". */
.h-ink { transition: background .15s ease; }
.h-ink:hover { background: #3a3f46 !important; color: #fff; }
.h-ink[disabled] { background: var(--tint-strong) !important; color: var(--text-faint); cursor: not-allowed; }
.h-ink[disabled]:hover { background: var(--tint-strong) !important; color: var(--text-faint); }

/* Vermilion: search, "jautāt", newsletter, the outlet's primary. */
.h-accent { transition: background .15s ease; }
.h-accent:hover { background: var(--accent-hover) !important; color: #fff; }

/* The hero's outlined secondary, on cream. */
.h-out:hover { background: var(--surface-sunken); border-color: var(--text-muted) !important; }
/* The same on ink. */
.h-outline:hover { background: rgba(255, 255, 255, .12); border-color: #fff !important; }

.h-chip:hover { background: var(--accent-soft) !important; color: var(--accent-deep); }
.h-pill:hover { border-color: var(--accent) !important; color: var(--accent-deep) !important; }
.h-leaf:hover { color: var(--accent-deep) !important; }
.h-tab:hover { background: var(--accent-soft) !important; color: var(--accent-deep) !important; }
.h-more:hover { color: var(--accent-hover) !important; }
.h-util:hover { color: var(--text); }
/* The shop's number, in full ink and bold: it is the one thing in the utility
   bar a worried shopper is looking for. */
.h-phone { display: inline-flex; align-items: center; gap: 6px; color: var(--text); font-weight: 700; white-space: nowrap; }
.h-foot:hover, .h-foot2:hover { opacity: 1; color: var(--accent-lift); }
.h-foot { opacity: .72; transition: opacity .15s ease, color .15s ease; }

/* The signup column goes when the footer can no longer hold its five columns.
 *
 * The footer is repeat(auto-fit, minmax(190px, 1fr)) with 28px gaps inside 36px
 * padding inside a 40px page margin, so five columns need
 * 5×190 + 4×28 + 72 + 80 = 1214px. One pixel under that, auto-fit drops to four
 * and the newsletter — the last child and the only one that is a form — wrapped
 * onto a row of its own, a lone box under four link lists.
 *
 * Hiding it costs the signup on phones, which is a real loss and a deliberate
 * one: it was asked for, and the four columns that remain are links, which
 * stack down to one column without ever looking stranded.
 *
 * The column's own layout is here rather than in a style attribute, which is
 * the whole reason the rule below works: an inline display:flex outranks any
 * stylesheet, media query or not, so the first version of this hid nothing. */
.foot-signup { display: flex; flex-direction: column; gap: 10px; }
@media (max-width: 1213px) {
  .foot-signup { display: none; }
}

/* Cards lift rather than outline: the design gives the deal card a shadow on
 * hover and nothing else. */
.h-card, .h-lift, .h-outlet, .h-brand {
  transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease, background .15s ease;
}
.h-card:hover, .h-lift:hover { box-shadow: 0 12px 30px rgba(35, 38, 43, .1); }
.h-outlet:hover { background: rgba(255, 255, 255, .12) !important; }
.h-brand:hover { border-color: var(--accent) !important; }
.h-guide:hover span:nth-of-type(3) { color: var(--accent-deep); }

/* --- header ---------------------------------------------------------------- */

/* The campaign strip runs edge to edge. The page is a 1440 canvas centered in
 * the viewport, and an announcement band that stops at the canvas edge reads
 * as a misprint on anything wider. The 50vw breakout can poke under the
 * scrollbar by its own width, so the page clips sideways overflow — clip, not
 * hidden, which would quietly become a scroll container. */
.c-bar { margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); }
/* Both, not just body: the breakout overhangs by the scrollbar's width and
   clipping only the body left the root still scrollable — the category page
   could be dragged eight pixels sideways. clip rather than hidden, which would
   quietly turn these into scroll containers and break position:sticky. */
html, body { overflow-x: clip; }
.c-bar a:hover { background: var(--accent-soft) !important; }
.c-disc { transition: box-shadow .15s ease; }
.c-disc:hover { box-shadow: 0 4px 12px rgba(35, 38, 43, .14) !important; }

/* The basket: a quiet disc beside the account one, not a filled pill. The one
 * solid-black control in the header read as the page's main action, and a
 * basket is a status. Under a mouse it fills black; the count badge is the
 * signal the rest of the time. !important, because the disc's white ground is
 * an inline style like the rest of the header. */
.c-cart { position: relative; transition: background .12s ease; }
.c-cart svg { transition: stroke .12s ease; }
@media (hover: hover) and (pointer: fine) {
  .c-cart:hover { background: #23262b !important; }
  .c-cart:hover svg { stroke: #fff; }
}
.c-cart-n {
  position: absolute;
  top: -3px;
  right: -4px;
  min-width: 17px;
  height: 17px;
  padding: 0 2px;
  background: var(--accent);
  color: #fff;
  border: 2px solid #faf7f3;
  border-radius: 999px;
  font: 800 10px/17px Manrope;
  text-align: center;
  box-sizing: content-box;
}
.c-search:focus-within { box-shadow: 0 0 0 2px var(--accent-lift) !important; }
.c-search .input::placeholder { color: var(--text-faint); }
/* A search input carries the browser's own clear button, which lands on top of
 * the submit pill. */
.c-search .input::-webkit-search-cancel-button { -webkit-appearance: none; }

/* The department nav. The chevron is the design's: a 7px square with two
 * borders, turned 45°. */
/* Positioned, so the phone's full-width department panels have something
 * OUTSIDE the scrolling strip to anchor to. */
.c-navwrap { position: relative; }
.c-nav { overflow-x: auto; scrollbar-width: none; }
.c-nav::-webkit-scrollbar { display: none; }
.h-nav {
  height: 38px;
  padding: 0 14px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  gap: 7px;
  font: 700 13px/1 Manrope;
  color: var(--text);
  white-space: nowrap;
  flex: none;
  transition: background .15s ease, color .15s ease;
}
.h-nav:hover { background: var(--page); color: var(--accent-hover); }
.h-nav i {
  display: block;
  width: 7px;
  height: 7px;
  border-right: 1.6px solid #a4a8ac;
  border-bottom: 1.6px solid #a4a8ac;
  transform: rotate(45deg) translateY(-2px);
}
.h-sale { transition: background .15s ease, color .15s ease; }
.h-sale:hover { background: var(--accent) !important; color: #fff !important; }

/* One row, always. The five cards used to reflow 5 → 4 → 3 → 2 → 1 as the page
 * narrowed, which turned a shop window into a stack and pushed everything below
 * it off the screen. They now stay on one line and the row scrolls: clipped
 * under a mouse, dragged with a finger.
 *
 * minmax(210px, 1fr) is what makes both true at once — the cards divide the
 * width evenly while there is room, and stop shrinking at the width a product
 * photo, a price and an add-to-basket button actually need. Below roughly
 * 1130px the row overflows and becomes scrollable, which is the intent.
 *
 * overscroll-behavior-inline keeps a swipe that reaches the end of the row from
 * turning into a browser back-navigation, which on a phone is the difference
 * between a carousel and losing the page. */
.dealgrid {
  /* No grid-template-columns: the cards are auto-placed into one row, so the
     count is whatever the block holds rather than a hard-coded five. */
  grid-auto-flow: column;
  grid-auto-columns: minmax(210px, 1fr);
  /* A flex item will not shrink below its content without this, and an
     unshrinkable child cannot scroll — it widens the panel instead. */
  min-width: 0;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
  /* Room for the card's own shadow, which a clipping container would cut. */
  padding-bottom: 2px;
}

.dealgrid::-webkit-scrollbar { display: none; }
.dealgrid > * { scroll-snap-align: start; }

/* --- category grid ----------------------------------------------------------
 * Every department at once: a row is an icon and a name, four to a line. This
 * replaced the master-detail browser, which showed one department at a time
 * behind a radio rail — a directory you have to operate. */
.catgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px 14px; }
.catrow {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 14px;
  min-width: 0;
  transition: background .12s ease;
}
.catrow:hover { background: var(--page); }
.catart {
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 12px;
  overflow: hidden;
  background: #faf7f3;
}
.catart img { width: 100%; height: 100%; object-fit: cover; display: block; }
.catname {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  font: 700 13px/1.25 Manrope;
  color: var(--text);
}
/* Ellipsis, not a clip: Skaistumkopšana is one fifteen-letter word and a
 * half-column is not fifteen letters wide. */
.catname .catlabel { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.catname .catn { font: 500 11px/1 'IBM Plex Mono', monospace; color: var(--text-faint); }
@media (max-width: 1010px) { .catgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* --- delivery: locker or address ------------------------------------------- */

/* Both fields are always in the DOM and the chosen radio decides which one is
   shown, so switching option needs neither a round trip nor a script. */
.d-parcel, .d-addr { display: block; margin-top: var(--space-3); }

@supports selector(:has(*)) {
  /* Default is the address box: it suits the courier, and it is the field that
     was there before there was a picker. */
  .d-parcel { display: none; }
  /* One picker per carrier: the option chosen decides which network's lockers
     are offered, because the two are priced separately and a parcel booked
     with the wrong carrier is the other one's price. */
  /* Keyed by a data attribute rather than a generated class name: the class is
     written by a range over the carriers, and a class the stylesheet cannot
     see spelled out is one the template lint reports as unstyled — correctly,
     since nothing would catch a carrier whose rule nobody added. */
  .panel-body:has(input[value="parcel_omniva"]:checked) .d-parcel[data-carrier="omniva"] { display: block; }
  .panel-body:has(input[value="parcel_dpd"]:checked) .d-parcel[data-carrier="dpd"] { display: block; }
  .panel-body:has(input[value="parcel_omniva"]:checked) .d-addr,
  .panel-body:has(input[value="parcel_dpd"]:checked) .d-addr { display: none; }
  /* Collection needs neither — we agree a time, and there is nothing to type. */
  .panel-body:has(input[value="pickup"]:checked) .d-addr,
  .panel-body:has(input[value="pickup"]:checked) .d-parcel { display: none; }
  /* Nor does a basket with nothing to deliver. */
  .panel-body:has(input[value="none"]:checked) .d-addr,
  .panel-body:has(input[value="none"]:checked) .d-parcel { display: none; }
}

/* The search box the checkout script puts over each locker select. It wears
   the select's chevron so it still reads as "choose one". The list is in the
   flow rather than floating: a dropdown inside a panel can be clipped by it,
   and on a phone a floating one opens under the keyboard. */
.pick-box {
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23a4a8ac' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 10px 6px;
  scroll-margin-top: var(--space-4);
}
.pick-list {
  margin: 4px 0 0;
  padding: 4px 0;
  list-style: none;
  max-height: min(300px, 45vh);
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
}
.pick-list li {
  padding: 8px 12px;
  font-size: var(--text-sm);
  line-height: 1.35;
  cursor: pointer;
}
@media (hover: hover) { .pick-list li:hover { background: var(--surface-sunken); } }
.pick-list li.on { background: var(--accent-wash); }
.pick-list li[aria-selected="true"] { font-weight: 600; }
.pick-list li.pick-none { color: var(--text-faint); cursor: default; }

/* --- department dropdown --------------------------------------------------- */

/* The chevron in the nav pointed at a menu that did not exist. It does now.
 *
 * Three ways in, because there are three kinds of visitor:
 *   - a mouse opens it on hover, guarded by @media (hover: hover) so a touch
 *     screen never inherits a menu it cannot dismiss;
 *   - a keyboard opens it with :focus-within, which needs no script;
 *   - a finger presses the chevron button, which is the only one of the three
 *     that works on a phone, and is why the chevron is a real button rather
 *     than the decorative <i> it used to be.
 * The department name itself stays an ordinary link in all three cases. */
/* Static, never relative: the chip lives inside .c-nav, which scrolls
 * horizontally, and an overflow container clips any panel whose containing
 * block sits inside it — which is why the hover menu opened invisibly for as
 * long as this was position:relative. Anchoring the panel to .c-navwrap, one
 * element OUTSIDE the scroller, is what lets it actually appear. */
.h-drop {
  display: flex;
  align-items: center;
  flex: none;
  /* Full bar height, not just the 38px link. The bar is 54px with the chip
     centred in it, so the eight pixels above and below the link belonged to
     .c-nav — and a cursor travelling down from the link crossed them, lost
     :hover, and closed the menu before it could reach the bridge below. The
     hover target has to reach the bar's own edge for the bridge to join up. */
  align-self: stretch;
}

.h-drop-btn {
  width: 22px;
  height: 38px;
  margin-left: -8px;
  border: 0;
  background: none;
  cursor: pointer;
  padding: 0;
  /* Only shown where it is the only way in. With a mouse, hover already opens
     the panel and a second control beside every department is clutter. */
  display: none;
}
.h-drop-btn::before {
  content: "";
  display: block;
  width: 7px;
  height: 7px;
  margin: 0 auto;
  border-right: 1.6px solid #a4a8ac;
  border-bottom: 1.6px solid #a4a8ac;
  transform: rotate(45deg) translateY(-2px);
  transition: transform .15s ease;
}
.h-drop-btn[aria-expanded="true"]::before {
  transform: rotate(-135deg) translateY(-2px);
}

/* Spans the whole bar, on every screen: with .h-drop static the panel anchors
 * to .c-navwrap, so per-chip positioning is gone — and a full-width panel is
 * the better menu anyway, on a phone and under a mouse alike.
 *
 * The insets match the navwrap's own padding, so the panel's edges line up
 * with the white bar it hangs from rather than with the wrapper around it —
 * left/right 0 made the menu 40px wider than the bar on each side. */
.h-panel {
  position: absolute;
  top: calc(100% + 6px);
  left: 40px;
  right: 40px;
  z-index: 60;
  display: none;
  padding: var(--space-4);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(35, 38, 43, 0.14);
}
.h-panel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 2px var(--space-4);
}
.h-panel-grid a {
  display: block;
  padding: 6px 8px;
  border-radius: 8px;
  font: 600 13px/1.3 Manrope;
  color: var(--text);
}
.h-panel-grid a:hover { background: var(--page); color: var(--accent-hover); }
.h-panel-all {
  display: block;
  margin: 0 0 var(--space-3);
  padding: 0 8px var(--space-3);
  border-bottom: 1px solid var(--border);
  font: 800 12px/1.3 Manrope;
  color: var(--accent);
}

/* "Visas kategorijas" — the way in once seven chips no longer fit.
 *
 * The bar scrolls horizontally with its scrollbar hidden, so below roughly
 * 1140px the departments past the right edge were simply gone: no scrollbar,
 * no affordance, nothing saying more existed. One labelled control that opens
 * the whole list is a better answer than a row that hides half of itself.
 *
 * It is the same .h-drop as a department, so it inherits the hover panel, the
 * touch toggle, the keyboard rule and the outside-click close for free. The
 * overrides below are only about making .h-drop-btn — a 22px chevron with no
 * text — read as a labelled chip. */
.h-all { display: none; }
.h-all .h-drop-btn,
.h-all-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  width: auto;
  height: 38px;
  margin-left: 0;
  padding: 0 14px;
  border-radius: 11px;
  background: none;
  /* 800, matching .h-sale and the footer headings: this is the one chip in the
     bar that is a control rather than a department, and weight is what says so
     when it is sitting in a row of 700-weight names. */
  font: 800 13px/1 Manrope;
  color: var(--text);
  cursor: pointer;
}
/* The burger, drawn as three background stripes on one empty span.
   currentColor rather than a fixed grey, so the bars follow the label into the
   hover colour instead of staying behind. */
.h-all-btn .h-burger {
  width: 15px;
  height: 11px;
  flex: none;
  background:
    linear-gradient(currentColor, currentColor) left top / 100% 1.8px no-repeat,
    linear-gradient(currentColor, currentColor) left 50% / 100% 1.8px no-repeat,
    linear-gradient(currentColor, currentColor) left bottom / 100% 1.8px no-repeat;
}
/* The chevron is the <i> inside, matching .h-nav, so the pseudo-element one
   that every other .h-drop-btn draws would be a second arrow. */
.h-all .h-drop-btn::before { content: none; }
.h-all .h-drop-btn i {
  display: block;
  width: 7px;
  height: 7px;
  border-right: 1.6px solid #a4a8ac;
  border-bottom: 1.6px solid #a4a8ac;
  transform: rotate(45deg) translateY(-2px);
  transition: transform .15s ease;
}
.h-all .h-drop-btn[aria-expanded="true"] i { transform: rotate(-135deg) translateY(1px); }
.h-all .h-drop-btn:hover { background: var(--page); color: var(--accent-hover); }

/* The bar sheds departments one at a time rather than all at once.
 *
 * Every number below is measured, not estimated. Each element in the row was
 * read off the live page: the chip is 172.6px with its burger, the seven
 * department names are 166.2, 174.4, 99.7, 113.1, 127.8, 181.1 and 136.0, and
 * the tail — a 1px divider inside 20px of margin, the 109px price-drops link
 * and the 132.9px sale pill — is 262.9. Add 2px per gap, 20px of nav padding,
 * the 80px page inset and a 15px scrollbar, and each rung's floor is
 *
 *   7 deps, no chip  1395     2 deps + chip   902
 *   5 deps + chip    1248     1 dep  + chip   725
 *   4 deps + chip    1118     0 deps + chip   557
 *   3 deps + chip    1003
 *
 * so the breakpoint is one pixel under the rung above it. The estimated ladder
 * this replaces was out by up to 37px, which showed as the row overflowing for
 * a band of widths on either side of every step.
 *
 * There is no six-department rung: six plus the chip needs 1431, wider than
 * seven on their own, so the first step drops two. Adding the burger widened
 * the chip by 24px and moved every step with it — a reason to derive these
 * rather than tune them by eye.
 *
 * nth-of-type counts every div in the bar and .h-all is the FIRST of them, so
 * the departments are divs two through eight: showing N of them means hiding
 * from div N+2 onward. :not() keeps the all-categories chip out of it whatever
 * the arithmetic.
 */
@media (max-width: 1394px) {
  .h-all { display: flex; }
  .c-nav > .h-drop:not(.h-all):nth-of-type(n + 7) { display: none; }
}
@media (max-width: 1247px) { .c-nav > .h-drop:not(.h-all):nth-of-type(n + 6) { display: none; } }
@media (max-width: 1117px) { .c-nav > .h-drop:not(.h-all):nth-of-type(n + 5) { display: none; } }
@media (max-width: 1002px) { .c-nav > .h-drop:not(.h-all):nth-of-type(n + 4) { display: none; } }
@media (max-width: 901px)  { .c-nav > .h-drop:not(.h-all):nth-of-type(n + 3) { display: none; } }
@media (max-width: 724px)  { .c-nav > .h-drop:not(.h-all):nth-of-type(n + 2) { display: none; } }

/* Under 557 even the tail does not fit beside the chip: the sale pill was being
   cut off at the right edge on a phone. The price-drops link goes — the pill
   points at the same goods — and the divider with it. */
@media (max-width: 556px) {
  .c-nav > span,
  .c-nav > a.h-nav { display: none; }
}


/* Keyboard, everywhere — but :focus-visible, never :focus-within. A tap and a
 * click also focus the chip, and :focus-within held the panel open after the
 * close was pressed: aria-expanded said closed, lingering focus said open,
 * and the menu could be opened but never dismissed. :focus-visible is the
 * browser's own "this focus came from a keyboard" signal. */
.h-drop:has(.h-nav:focus-visible) .h-panel,
.h-drop:has(.h-drop-btn:focus-visible) .h-panel { display: block; }
.h-drop-btn[aria-expanded="true"] + .h-panel { display: block; }

/* Mouse only: hovering a department opens that department's panel — the
   shelves of the thing under the cursor. (A full-catalogue directory used to
   open here instead, every department at once; pointing at one department and
   being answered with all of them made the menu read as broken.) The panel is
   a DOM child of the chip, so moving the cursor down into it keeps :hover
   true and the panel open. A hover-opened menu on a touch screen would open
   on the tap that was meant to follow the link and then have no way to close,
   so a finger keeps the chevron button. */
@media (hover: hover) and (pointer: fine) {
  .h-drop:hover .h-panel { display: block; }

  /* The 6px the panel sits below the link is a gap the CURSOR has to cross, and
     nothing occupies it — so :hover ends the moment the mouse leaves the link
     and the menu closes before it can be reached. The menu was unusable with a
     mouse for exactly this reason, while every rule in it was correct.
     This bridges the gap with a transparent strip, present only while hovering
     so it can never sit over anything the rest of the time. */
  .h-drop:hover::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    /* Covers the 6px the panel sits below the bar, with margin either side.
       Anchored to .c-navwrap like the panel itself, since .h-drop is static. */
    height: 12px;
    z-index: 59;
  }
}

/* Touch, and anything without a fine pointer: the button is the way in. */
@media (hover: none), (pointer: coarse) {
  .h-drop-btn { display: block; }
  /* The link's decorative chevron goes: with the button beside it every
   * department wore two arrows, and only one of them does anything. */
  .h-nav i { display: none; }
}

/* --- hero carousel --------------------------------------------------------- */

/* Three slides, cross-fading, steered by radio inputs so the whole thing works
 * with script switched off. The inputs are taken out of flow rather than hidden
 * with display:none — display:none would also take them out of the tab order,
 * and the dots are the only way to steer this by keyboard. */
.slidepick {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
/* The hero photograph, kept clear of the card and kept WHOLE.
 *
 * These are supplier product shots on white, not ambient art: full-bleed cover
 * threw away 34% of the frame and sliced the goods, and what survived sat
 * behind the 400px card. Inset past the card and contained, the product is
 * shown entire, beside the words, which is what a product photograph is for. */
/* The editorial cover. The photograph runs full bleed, the scrim earns the
 * contrast, and the headline sits straight on the scene — a magazine cover,
 * not a card floating on a photo, which is the hero every shop already has. */
.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top,
    rgba(20, 22, 26, .78) 0%, rgba(20, 22, 26, .3) 45%, rgba(20, 22, 26, 0) 72%);
}
.hero-copy {
  position: absolute;
  left: 40px;
  right: 40px;
  bottom: 34px;
  max-width: 760px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 13px;
}
.hero-kicker {
  align-self: flex-start;
  font: 800 11px/1 var(--font);
  letter-spacing: .14em;
  padding: 8px 13px;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 999px;
}
.hero-copy h1 {
  margin: 0;
  font: 900 60px/0.98 var(--font-display);
  letter-spacing: -.045em;
  text-wrap: balance;
  text-shadow: 0 2px 26px rgba(20, 22, 26, .4);
}
.hero-meta { margin: 0; font: 500 13px/1.5 var(--font-mono); opacity: .85; }
.hero-cta {
  align-self: flex-start;
  background: #fff;
  color: #23262b;
  padding: 15px 26px;
  border-radius: 999px;
  font: 800 13px/1 var(--font);
  transition: background .15s ease, color .15s ease;
}
.hero-cta:hover { background: var(--accent); color: #fff; }
@media (max-width: 1200px) {
  .hero-copy h1 { font-size: 42px; }
}
@media (max-width: 560px) {
  .hero-copy { left: 20px; right: 20px; bottom: 22px; }
  .hero-copy h1 { font-size: 30px; }
}

.hero-img {
  position: absolute;
  inset: 0 0 0 42%;
  width: auto;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 30px;
  display: block;
}

/* A scene, not a product. It is meant to fill the slab and be read behind the
 * card, so it takes the whole frame and crops — which costs a photograph of a
 * room nothing, and would cost a photograph of a kettle its handle. */
.hero-scene {
  inset: 0;
  width: 100%;
  object-fit: cover;
  padding: 0;
}

.slides { position: absolute; inset: 0; }
.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .6s ease, visibility .6s;
}
.slidepick:nth-of-type(1):checked ~ .slides .slide:nth-child(1),
.slidepick:nth-of-type(2):checked ~ .slides .slide:nth-child(2),
.slidepick:nth-of-type(3):checked ~ .slides .slide:nth-child(3) {
  opacity: 1;
  visibility: visible;
}

/* Numbered, not dotted: 01 02 03 in the mono, the active one underlined —
 * a cover's folio, matching the editorial treatment above. */
.hero-dots label {
  font: 500 12px/1 var(--font-mono);
  color: rgba(255, 255, 255, .55);
  padding-bottom: 5px;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: color .3s ease, border-color .3s ease;
}
.slidepick:nth-of-type(1):checked ~ .hero-dots label:nth-child(1),
.slidepick:nth-of-type(2):checked ~ .hero-dots label:nth-child(2),
.slidepick:nth-of-type(3):checked ~ .hero-dots label:nth-child(3) {
  color: #fff;
  border-bottom-color: #fff;
}
.slidepick:focus-visible ~ .hero-dots label { outline: 2px solid #fff; outline-offset: 2px; }

/* --- department browser ---------------------------------------------------- */

/* The design drives this from a JS hover handler. Ours is radio inputs and
 * sibling selectors: the inputs sit as direct children of .browser, ahead of
 * both columns, so a plain ~ can reach the panel a label controls. Nesting them
 * in the list would need :has(), and this needs no such thing.
 *
 * Taken out of flow for the same reason as the slides, and additionally because
 * a grid child that is not display:none would claim a cell. */
.deptpick {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.browser-list label {
  height: 37px;
  flex: none;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border-radius: 12px;
  box-sizing: border-box;
  background: transparent;
  font: 700 13px/1 Manrope;
  color: var(--text);
  cursor: pointer;
  transition: background .12s ease, color .12s ease;
}
.browser-list label .n {
  margin-left: auto;
  font: 500 10px/1 "IBM Plex Mono", monospace;
  color: var(--text-faint);
}
.browser-list label .arrow { font: 800 12px/1 Manrope; color: var(--text-faint); }
.browser-list label:hover { background: var(--page); }

/* The selected row: ink, white type, half-opacity white for the count. */
.deptpick:nth-of-type(1):checked ~ .browser-list label:nth-child(1),
.deptpick:nth-of-type(2):checked ~ .browser-list label:nth-child(2),
.deptpick:nth-of-type(3):checked ~ .browser-list label:nth-child(3),
.deptpick:nth-of-type(4):checked ~ .browser-list label:nth-child(4),
.deptpick:nth-of-type(5):checked ~ .browser-list label:nth-child(5),
.deptpick:nth-of-type(6):checked ~ .browser-list label:nth-child(6),
.deptpick:nth-of-type(7):checked ~ .browser-list label:nth-child(7),
.deptpick:nth-of-type(8):checked ~ .browser-list label:nth-child(8),
.deptpick:nth-of-type(9):checked ~ .browser-list label:nth-child(9),
.deptpick:nth-of-type(10):checked ~ .browser-list label:nth-child(10),
.deptpick:nth-of-type(11):checked ~ .browser-list label:nth-child(11),
.deptpick:nth-of-type(12):checked ~ .browser-list label:nth-child(12) {
  background: var(--chrome);
  color: #fff;
}
.deptpick:nth-of-type(1):checked ~ .browser-list label:nth-child(1) :is(.n, .arrow),
.deptpick:nth-of-type(2):checked ~ .browser-list label:nth-child(2) :is(.n, .arrow),
.deptpick:nth-of-type(3):checked ~ .browser-list label:nth-child(3) :is(.n, .arrow),
.deptpick:nth-of-type(4):checked ~ .browser-list label:nth-child(4) :is(.n, .arrow),
.deptpick:nth-of-type(5):checked ~ .browser-list label:nth-child(5) :is(.n, .arrow),
.deptpick:nth-of-type(6):checked ~ .browser-list label:nth-child(6) :is(.n, .arrow),
.deptpick:nth-of-type(7):checked ~ .browser-list label:nth-child(7) :is(.n, .arrow),
.deptpick:nth-of-type(8):checked ~ .browser-list label:nth-child(8) :is(.n, .arrow),
.deptpick:nth-of-type(9):checked ~ .browser-list label:nth-child(9) :is(.n, .arrow),
.deptpick:nth-of-type(10):checked ~ .browser-list label:nth-child(10) :is(.n, .arrow),
.deptpick:nth-of-type(11):checked ~ .browser-list label:nth-child(11) :is(.n, .arrow),
.deptpick:nth-of-type(12):checked ~ .browser-list label:nth-child(12) :is(.n, .arrow) {
  color: rgba(255, 255, 255, .5);
}

/* The display value lives ONLY in the :checked rules. Putting `display: grid`
 * on the base rule and `display: none` before it is how all twelve panels ended
 * up visible at once last time — the later declaration won. */
.browser-panel { display: none; }
.deptpick:nth-of-type(1):checked ~ .browser-panels .browser-panel:nth-child(1),
.deptpick:nth-of-type(2):checked ~ .browser-panels .browser-panel:nth-child(2),
.deptpick:nth-of-type(3):checked ~ .browser-panels .browser-panel:nth-child(3),
.deptpick:nth-of-type(4):checked ~ .browser-panels .browser-panel:nth-child(4),
.deptpick:nth-of-type(5):checked ~ .browser-panels .browser-panel:nth-child(5),
.deptpick:nth-of-type(6):checked ~ .browser-panels .browser-panel:nth-child(6),
.deptpick:nth-of-type(7):checked ~ .browser-panels .browser-panel:nth-child(7),
.deptpick:nth-of-type(8):checked ~ .browser-panels .browser-panel:nth-child(8),
.deptpick:nth-of-type(9):checked ~ .browser-panels .browser-panel:nth-child(9),
.deptpick:nth-of-type(10):checked ~ .browser-panels .browser-panel:nth-child(10),
.deptpick:nth-of-type(11):checked ~ .browser-panels .browser-panel:nth-child(11),
.deptpick:nth-of-type(12):checked ~ .browser-panels .browser-panel:nth-child(12) {
  display: grid;
}
.browser-panels { min-width: 0; }

/* --- the assistant --------------------------------------------------------- */

.ask-form:focus-within { box-shadow: 0 0 0 2px var(--accent-lift); }

/* The assistant slab is the page's one dark block, so its chips carry their
 * own hover here. */
.b-ask .h-chip:hover { background: rgba(255, 255, 255, 0.14) !important; }

/* The suggestion pills are buttons that fill the composer, so they carry the
 * chip look themselves — a button inherits nothing and defaults to grey. */
.ask-chip {
  font: 600 12px/1 var(--font);
  color: #fff;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.28);
  padding: 10px 14px;
  border-radius: 999px;
  white-space: nowrap;
  cursor: pointer;
}

/* The chat anatomy: a greeting bubble from the assistant, the visitor's own
 * message echoed back as a bubble on submit, and a messenger composer with a
 * round send button. This is what tells a glance "this is a chatbot" — the
 * previous form told a glance "this is another input". */
.chat { display: flex; flex-direction: column; gap: 10px; }
.chat-msg { display: flex; gap: 10px; align-items: flex-start; max-width: 56ch; }
.chat-msg p {
  margin: 0;
  background: #fff;
  color: var(--text);
  font: 500 13.5px/1.55 var(--font);
  padding: 12px 16px;
  border-radius: 16px 16px 16px 4px;
}
.chat-avatar {
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 999px;
  background: var(--accent);
  display: grid;
  place-items: center;
  margin-top: 2px;
}
.chat-you { align-self: flex-end; }
.chat-you p {
  background: var(--accent);
  color: #fff;
  border-radius: 16px 16px 4px 16px;
}
/* The bold the model is allowed: product names and prices inside an answer. */
.chat-msg p strong { font-weight: 800; }
/* The answer-on-its-way bubble breathes; the composer dims and locks while it
 * does. Disabled inputs already refuse keystrokes — the opacity is so the
 * refusal reads as "wait" rather than "broken". */
.chat-wait p { animation: chat-wait 0.9s ease-in-out infinite alternate; }
@keyframes chat-wait {
  from { opacity: 0.45; }
  to { opacity: 0.95; }
}
.chat-composer.busy { opacity: 0.65; }
.chat-composer {
  height: 56px;
  background: #fff;
  border-radius: 999px;
  display: flex;
  align-items: center;
  padding: 0 6px 0 22px;
  gap: 10px;
}
.chat-composer input {
  font: 400 14px/1.3 var(--font);
  color: var(--text);
  flex: 1;
  min-width: 0;
  border: 0;
  background: none;
  outline: none;
}
.chat-composer button {
  width: 44px;
  height: 44px;
  flex: none;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background .12s ease;
}
.chat-composer button:hover { background: var(--accent-hover); }
.ask-form input::placeholder { color: var(--text-faint); }

/* --- the newsletter -------------------------------------------------------- */

.c-signup input::placeholder { color: var(--text-faint); }

/* --------------------------------------------------------------- cards ---- */

/* Cards have no border. On cream they do not need one, and a hairline around a
 * 28px corner is the detail that makes a soft system look printed. */
.card {
  background: var(--surface);
  border: 0;
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.panel { background: var(--surface); border: 0; border-radius: var(--radius-xl); }
/* No margin between panels: main is a flex column with the design's 20px gap,
 * and a margin here would stack on top of it. */
/* The side padding MUST match .panel-body's, or every heading sits four pixels
 * to the left of the fields it heads — which is what made the sign-in and
 * checkout panels look broken. These two rules are the whole of it, and they
 * are shared by checkout, cart, account, order, product, category, search and
 * info, so they are worth keeping in step. */
.panel-head {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-5) var(--space-5) var(--space-2);
  flex-wrap: wrap;
}
.panel-head h2 { margin: 0; font-size: var(--text-xl); letter-spacing: -0.03em; }
.panel-head .sub { color: var(--text-muted); font-size: var(--text-base); }
.panel-head .more {
  margin-left: auto;
  color: var(--accent);
  font-weight: 800;
  font-size: var(--text-base);
  white-space: nowrap;
}
.panel-head .more:hover { color: var(--accent-hover); }
.panel-body { padding: var(--space-5); padding-top: var(--space-3); }

.notice {
  background: var(--accent-soft);
  border: 1px solid #faf7f3;
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-sm);
}
.notice.warn { background: var(--warn-surface); border-color: #e8e5e0; }
.notice.bad { background: var(--danger-surface); border-color: #e8e5e0; }

.section-head {
  display: flex;
  align-items: baseline;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}
.section-head h2 { margin: 0; font-size: var(--text-xl); }
.section-head .more { margin-left: auto; color: var(--accent-deep); font-weight: 600; font-size: var(--text-sm); }

/* The shop-window section header: centred, one big line in the display face, a
 * quiet second line under it, then air. A left-aligned heading with its subtitle
 * sitting beside it reads as an admin table — which is what the home page was
 * doing, and the single biggest reason it felt unlike the shops it is modelled
 * on. Measured off those: 32px/800 title, 18px/400 subtitle, 32px below. */
.block-head { text-align: center; margin: 0 auto var(--space-6); max-width: 62ch; }
.block-head h2 { margin: 0 0 6px; font-size: 30px; text-wrap: balance; }
.block-head .sub {
  display: block;
  color: var(--text-muted);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.35;
}

/* Blocks separate by ground and air rather than by a hairline box each. */
.block { margin: 0 0 40px; }
.block-tint {
  background: var(--surface-sunken);
  border-radius: var(--radius-xl);
  padding: var(--space-7) var(--space-6);
}
.block-foot { display: flex; justify-content: center; margin-top: var(--space-5); }

/* ------------------------------------------------------------ controls ---- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  background: var(--cta);
  color: var(--cta-text);
  font-family: inherit;
  font-size: var(--text-sm);
  font-weight: 800;
  padding: 13px 22px;
  cursor: pointer;
  text-align: center;
  line-height: 1;
  /* One height for every variant. Padding alone does not give one: .btn-ghost
   * carries a 1.5px border against .btn's 1px, so the two rendered 40px and
   * 38px tall side by side on the sign-in panel. A minimum settles it whatever
   * a variant does to its border or padding. */
  min-height: 40px;
}
.btn:hover { background: var(--cta-hover); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn[disabled] { background: var(--tint-strong); color: var(--text-faint); cursor: not-allowed; }
.btn[disabled]:hover { background: var(--tint-strong); color: var(--text-faint); }

/* Outlined rather than filled, so a secondary action does not compete with the
 * ink pill next to it. */
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border-strong);
  font-weight: 800;
  padding: 12px 22px;
}
.btn-ghost:hover { background: var(--surface-sunken); color: var(--text); border-color: var(--text-muted); }

/* The one vermilion button on the site. It is the buy button and nothing else —
 * everything that merely continues a journey is the ink pill. */
.btn-buy {
  background: var(--accent);
  color: var(--accent-text);
  font-weight: 800;
  font-size: var(--text-base);
  padding: 15px 24px;
}
.btn-buy:hover { background: var(--accent-hover); color: #fff; }

/* On ink, the outline flips to white. */
.slab-ink .btn-ghost, .askus .btn-ghost {
  border-color: rgba(255, 255, 255, .28);
  color: #fff;
}
.slab-ink .btn-ghost:hover, .askus .btn-ghost:hover {
  background: rgba(255, 255, 255, .12);
  border-color: #fff;
  color: #fff;
}
.slab-ink .btn, .askus .btn { background: var(--accent); }
.slab-ink .btn:hover, .askus .btn:hover { background: var(--accent-hover); }

.btn-block { display: flex; width: 100%; }

.input, select.input, textarea.input {
  width: 100%;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
  font-family: inherit;
  font-size: var(--text-sm);
  padding: 10px 12px;
}
.input::placeholder { color: var(--text-faint); }
.input:focus { outline: 2px solid var(--accent); outline-offset: -1px; border-color: var(--accent); }

/* Our own chevron instead of the platform's.
 *
 * The browser draws its arrow hard against the right content edge, which is
 * fine in a square field and wrong in a pill: the sort control has a 999px
 * radius, so the arrow sat inside the curve with a couple of pixels of white
 * beside it. Drawing it ourselves puts it where we choose in every field and at
 * every radius, and makes the sort pill and the locker picker look related.
 *
 * After the shared rule, not inside it — `background: #fff` there is the
 * shorthand, which would wipe the image. */
select.input {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23a4a8ac' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 10px 6px;
}

/* --------------------------------------------------------------- chips ---- */

.badge {
  display: inline-block;
  border-radius: var(--radius-pill);
  padding: 2px 10px;
  font-size: var(--text-xs);
  font-weight: 600;
  background: var(--surface-sunken);
  color: var(--text-muted);
  white-space: nowrap;
}
.badge-ok { background: var(--ok-surface); color: var(--ok); }
.badge-warn { background: var(--warn-surface); color: var(--warn); }
.badge-danger { background: var(--danger-surface); color: var(--danger); }

.chips { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-bottom: var(--space-3); }
/* Outlined pill. Filled chips fought the buttons for attention; a hairline pill
 * reads as "another thing you could look at" rather than as an action. */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
  padding: 9px 13px;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
}
.chip:hover { border-color: var(--accent); color: var(--accent-deep); }
.chip.on { background: var(--chrome); border-color: var(--chrome); color: #fff; font-weight: 700; }
/* On a cream slab the outline disappears, so those get a solid white pill. */
.slab-cream .chip, .browser-panel .chip { background: var(--surface); border-color: var(--surface); }
.slab-cream .chip:hover, .browser-panel .chip:hover { border-color: var(--accent); color: var(--accent-deep); }

/* --------------------------------------------------------------- tiles ---- */

/* The listing grid. minmax(0,…) for the same reason the ported grids use it: a
 * nowrap article number would otherwise set the floor for every column. The
 * 16px gap is the design's deal grid. */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: var(--space-4); }

/* One line, always complete.
 *
 * For a row of related products, where wrapping is the wrong answer: six items
 * on a 900px screen wrapped to four and two, and the short second row read as a
 * loading failure rather than a layout. This drops from the end instead — a
 * hidden child leaves the grid entirely, so grid-auto-flow: column makes
 * exactly as many equal columns as there are products still shown.
 *
 * The steps are where the next tile would go under about 180px wide, given a
 * 40px page gutter each side, 16px gaps, and a .panel-flat body that adds no
 * padding of its own. Deliberately not .grid + an override: .grid is respecified
 * at two narrow breakpoints, and inheriting rules written for wrapping is how a
 * one-line row quietly becomes two. */
/* !important because a tile carries display:flex in a style attribute — that is
 * deliberate (see tile.html: the card's numbers are inline so this card and the
 * home page's cannot drift apart), and an inline declaration outranks any
 * stylesheet rule without it. Without the flag these rules hid nothing and six
 * tiles squeezed to 52px on a phone. */
.onerow { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: var(--space-4); }
@media (max-width: 1239px) { .onerow > :nth-child(n + 6) { display: none !important; } }
@media (max-width: 1043px) { .onerow > :nth-child(n + 5) { display: none !important; } }
@media (max-width: 847px)  { .onerow > :nth-child(n + 4) { display: none !important; } }
/* Two is the floor, matching the product grid on a phone. */
@media (max-width: 651px)  { .onerow > :nth-child(n + 3) { display: none !important; } .onerow { gap: var(--space-2); } }

/* tile.html carries the card's geometry inline, to the same numbers as the
 * design's deal card — see the note at the top of that file. What is left here
 * is the part an inline style cannot say. */
.tile:hover { z-index: 2; }
.tile:hover .name { color: var(--accent-deep); }

.placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  background: var(--surface-soft);
  border-radius: var(--radius-sm);
  color: var(--text-faint);
  font-size: var(--text-xs);
}

/* A row of tiles that runs off the edge of the screen instead of wrapping. The
 * cut-off card at the right edge is the thing that says "there is more". */
.scroller {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(212px, 1fr);
  gap: var(--space-3);
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-bottom: var(--space-2);
  scrollbar-width: thin;
}
.scroller > * { scroll-snap-align: start; }

/* Carousel controls, added by script and therefore never in the way when there
 * is nothing to scroll. Inset rather than hung outside the rail: at 16px of
 * container padding an outside button is a sideways scrollbar. */
.railwrap { position: relative; }
.railwrap .scroller, .railwrap .circle-rail { scroll-behavior: smooth; }
.railnav {
  position: absolute;
  top: 46%;
  transform: translateY(-50%);
  z-index: 3;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--chrome);
  box-shadow: var(--shadow);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: opacity .15s ease, background .15s ease;
}
.railnav svg { width: 20px; height: 20px; }
.railnav.prev { left: 6px; }
.railnav.next { right: 6px; }
.railnav:hover { background: var(--chrome); color: #fff; border-color: var(--chrome); }
.railnav[disabled] { opacity: 0; pointer-events: none; }
@media (hover: none) {
  /* A touch screen already has the gesture; the buttons would only cover a card. */
  .railnav { display: none; }
}

/* -------------------------------------------------------------- browse ---- */

.crumbs { font-size: var(--text-sm); color: var(--text-faint); padding: var(--space-1) 0 var(--space-4); }
.crumbs a { color: var(--text-muted); }
.crumbs a:hover { color: var(--accent-deep); text-decoration: underline; }

.browse { display: grid; grid-template-columns: 264px minmax(0, 1fr); gap: var(--space-5); align-items: start; }
.browse .rail { display: grid; gap: var(--space-4); align-self: start; }

/* The rail follows you down a long listing.
 *
 * Only where it is a column beside the goods: below 1010px .browse is one
 * column and the rail is a full-width block, where sticking it would pin a
 * wall of filters over the products.
 *
 * max-height with its own scroll because the rail is often taller than the
 * viewport — a sticky element taller than the screen simply stops following,
 * which looks like the feature failing rather than not being there. */
@media (min-width: 1011px) {
  .browse .rail {
    position: sticky;
    top: var(--space-4);
    max-height: calc(100vh - var(--space-4) * 2);
    overflow-y: auto;
    scrollbar-width: thin;
  }
}

/* Below a column, no rail at all.
 *
 * It used to move under the goods, which fixed the first problem — landing on a
 * department and being met by eleven subcategory links instead of a product —
 * and left a worse one: five filter cards stacked at the bottom of a phone
 * page, past the paging, where they are neither found nor wanted.
 *
 * What it costs is filtering on a phone. The active-filter chips stay, so a
 * filtered link opened on a phone still shows what is applied and can still
 * clear it; what is gone is starting a filter there. A "Filtri" sheet is the
 * proper answer and is not this change. */
@media (max-width: 1010px) {
  .browse .rail { display: none; }
}

/* A filter block is a white card on the cream, like every other block on the
 * site. It used to be a cream box with a hairline border on a cream page — the
 * outlined-box look this system replaced everywhere else. */
/* padding-bottom so the last pill clears the card's curve; without it the
   bottom row sat in the corner and the radius read as a mistake. */
.facet {
  background: var(--surface);
  border: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  padding-bottom: var(--space-2);
}
.facet + .facet { margin-top: 0; }
.facet h4 {
  margin: 0;
  color: var(--text);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 800;
  padding: 14px var(--space-4) 10px;
}
/* Rows are inset pills, not full-bleed bands.
 *
 * The card has a 22px radius and the rows had square, edge-to-edge fills, so
 * the bottom one was sliced by the curve and its highlight pinched into the
 * corner — which is what made the panel look wrong whenever a row was hovered
 * or chosen. Insetting them means nothing ever meets the curve, and a rounded
 * highlight reads as deliberate. It is also what .browser-list already does a
 * few hundred lines up, so this is the system's own idiom rather than a new one.
 *
 * The hairline separators go with it: pills and rules are two ways of saying
 * the same thing, and together they were fussy.
 */
.facet .opt {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0 var(--space-2);
  padding: 7px var(--space-2);
  border-radius: 10px;
  font-size: var(--text-sm);
  color: var(--text-muted);
}
/* Ink at four per cent, not the page cream. --page is #faf7f3 on a #ffffff
   card, which is a difference you have to look for — and it was the same
   colour the selected row used, so hover and chosen were indistinguishable. */
.facet .opt:hover { background: rgba(35, 38, 43, 0.05); color: var(--accent-deep); }

.facet .opt .lb { flex: 1 1 auto; min-width: 0; }
.facet .opt .n { color: var(--text-faint); font-size: var(--text-xs); font-variant-numeric: tabular-nums; }
.facet .opt .box {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  line-height: 1;
  color: transparent;
}
/* Selected has to survive being next to hover, which is also a pale wash.
   The ink bar down the left edge is what carries it: colour alone at these
   opacities is a difference somebody has to look for. */
.facet .opt.on {
  color: var(--accent-deep);
  font-weight: 600;
  background: var(--accent-wash);
}
.facet .opt.on:hover { background: var(--accent-wash); color: var(--accent-deep); }
.facet .opt.on .box { background: var(--accent); border-color: var(--accent); color: #fff; }
/* "Rādīt visus". A disclosure, so the rest of a long filter list is one click
   away and costs nothing when it is not wanted — and it works with scripting
   off, like every other control in this rail. */
.facet-more > summary {
  margin: 2px var(--space-2) 0;
  padding: 6px var(--space-2);
  border-radius: 10px;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--accent-deep);
  cursor: pointer;
  list-style: none;
}
.facet-more > summary::-webkit-details-marker { display: none; }
.facet-more > summary::after { content: " ▾"; }
.facet-more[open] > summary::after { content: " ▴"; }
.facet-more > summary:hover { background: rgba(35, 38, 43, 0.05); }

/* Open, the control moves under what it revealed and becomes "Sakļaut".
 *
 * Closed it is a promise of more below it, so it belongs at the bottom of the
 * short list; open, the same button is now the way back and belongs at the
 * bottom of the long one — otherwise the reader has to scroll back past twenty
 * values to find the control that closes them.
 *
 * A <summary> is always the first child, so this is flex order rather than
 * markup: the options keep the default 0 and the summary goes to 1. Only while
 * open, since a closed <details> renders nothing but the summary anyway. */
.facet-more[open] { display: flex; flex-direction: column; }
.facet-more[open] > summary { order: 1; margin-top: var(--space-1); }
.facet-more > summary .less-lbl { display: none; }
.facet-more[open] > summary .more-lbl { display: none; }
.facet-more[open] > summary .less-lbl { display: inline; }

/* The range slider, for a measure with more values than a list can hold.
 *
 * Two range inputs stacked on one track. The inputs themselves are transparent
 * and pointer-events: none, so the track underneath is ours to draw and only
 * the two thumbs are grabbable — without that the upper input would swallow
 * every click meant for the lower one's handle, and the pair would behave as a
 * single slider. Keyboard focus is untouched by pointer-events, so both handles
 * still take arrow keys.
 */
.rslider { padding: 2px var(--space-4) var(--space-3); }
.rslider .rout {
  display: block;
  padding: 2px 0 12px;
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text);
}
.rtrack { position: relative; height: 20px; }
/* The unfilled rail. A pseudo-element, so it cannot be mistaken for one of the
   inputs and needs no markup of its own. */
.rtrack::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 8px;
  height: 4px;
  border-radius: 2px;
  background: var(--border);
}
/* The chosen span, positioned from two custom properties the script writes.
   Static values so the bar is drawn correctly before the script runs. */
.rfill {
  position: absolute;
  top: 8px;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
  left: var(--lo, 0%);
  right: calc(100% - var(--hi, 100%));
}
.rtrack input[type="range"] {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 20px;
  margin: 0;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  background: none;
  pointer-events: none;
}
.rtrack input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  box-shadow: 0 1px 3px rgba(35, 38, 43, 0.25);
  cursor: grab;
}
.rtrack input[type="range"]::-moz-range-thumb {
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  box-shadow: 0 1px 3px rgba(35, 38, 43, 0.25);
  cursor: grab;
}
.rtrack input[type="range"]::-moz-range-track { background: none; }
.rtrack input[type="range"]:focus { outline: none; }
.rtrack input[type="range"]:focus-visible::-webkit-slider-thumb {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.rtrack input[type="range"]:focus-visible::-moz-range-thumb {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
/* Applying a range needs a button only where nothing can auto-submit. The
   script adds .live once its listeners are attached, so this hides on exactly
   the pages where it would be redundant, and never before. */
.rslider .rbtn { margin-top: var(--space-3); padding: 6px 14px; font-size: var(--text-xs); }
.rslider.live .rbtn { display: none; }

.facet .range { display: flex; gap: var(--space-2); padding: var(--space-3) var(--space-4); border-top: 1px solid var(--border-soft); }
.facet .range .input { padding: 7px 10px; font-size: var(--text-sm); }
.facet .range .btn { padding: 7px 16px; }

.listing-head {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 0 0 var(--space-4);
  margin-bottom: var(--space-4);
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.listing-head h1 { margin: 0; font-size: var(--text-2xl); }
.listing-head .count { color: var(--text-faint); font-size: var(--text-sm); }
.listing-head .sorter { margin-left: auto; }
/* 34px on the right so the chevron clears the pill's curve — a 36px-tall pill
   has an 18px radius, and 12px of padding put the arrow inside it. */
.listing-head .sorter .input { width: auto; padding: 8px 34px 8px 16px; font-size: var(--text-sm); border-radius: var(--radius-pill); }

/* ------------------------------------------------------------- product ---- */

.pdp { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: var(--space-6); align-items: start; }
/* Cream on the white slab, no border — the same pairing as the photo box on a
 * product card, at the block scale. */
.pdp .media { background: var(--page); border: 0; border-radius: var(--radius-lg); padding: var(--space-5); }
.pdp .buy { align-self: start; }
/* Amazon's buy box: white with a hairline, never a tinted surface. The border
 * is what says "this box is the transaction" — the tint was one more
 * background on a page the owner reviewed as having too many. */
.pdp .buy .card { background: #fff; border: 1px solid var(--border); }

.gallery .hero-shot { width: 100%; height: 440px; object-fit: contain; mix-blend-mode: multiply; }
.gallery .strip { display: flex; gap: var(--space-2); margin-top: var(--space-4); overflow-x: auto; scrollbar-width: thin; }
.gallery .strip img {
  width: 72px;
  height: 72px;
  flex: 0 0 auto;
  object-fit: contain;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 4px;
  background: #fff;
  cursor: pointer;
}
.gallery .strip img:hover { border-color: var(--accent); }

.price-big { font-size: 38px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.05; }
.taxline { color: var(--text-faint); font-size: var(--text-sm); margin: var(--space-1) 0 0; }

.stock-line { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-sm); font-weight: 600; color: var(--ok); }
.stock-line .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: 0 0 auto; }
.stock-line.out { color: var(--text-muted); font-weight: 500; }
.stock-line.out .dot { background: var(--text-faint); }

.terms { list-style: none; margin: var(--space-5) 0 0; padding: var(--space-4) 0 0; border-top: 1px solid var(--border); }
.terms ul { list-style: none; margin: 0; padding: 0; }
.terms li { padding: 5px 0; font-size: var(--text-sm); color: var(--text-muted); }
.terms li:first-child { padding-top: 0; }
.terms b { color: var(--text); font-weight: 600; }

/* How far the basket is from a threshold — the minimum order, or free
   delivery. Amber rather than red: neither is an error, both are a number to
   reach. */
.threshold {
  margin: var(--space-4) 0 0;
  padding: var(--space-3) var(--space-4);
  background: var(--warn-surface);
  border-radius: var(--radius);
  font-size: var(--text-sm);
  color: var(--warn);
}
.threshold b { font-weight: 700; }

.idblock { margin: var(--space-4) 0 0; padding: var(--space-3) 0 0; border-top: 1px solid var(--border); }
.idblock div { display: flex; gap: var(--space-3); padding: 3px 0; font-size: var(--text-sm); }
.idblock dt { color: var(--text-faint); min-width: 78px; }
.idblock dd { margin: 0; font-family: var(--font-mono); }

.spec-table { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.spec-table td { padding: 10px var(--space-4); font-size: var(--text-sm); border-top: 1px solid var(--border-soft); }
.spec-table tr:first-child td { border-top: 0; }
/* Hairline rows, no zebra: the striped rows were the "patterns" in the
 * owner's product-page review, and the row rule already separates. */
.spec-table .sname { color: var(--text-muted); width: 240px; }

/* The product description, folded to about six lines until the button opens
 * it (the script in product.html adds .is-short only when the text is long
 * enough to be worth folding). The fade is the page colour, since the panel
 * it sits in is transparent. */
.desc.is-short:not(.is-open) .desc-body { position: relative; max-height: 9em; overflow: hidden; }
.desc.is-short:not(.is-open) .desc-body::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4.5em;
  background: linear-gradient(to bottom, rgba(250, 247, 243, 0), var(--page));
  pointer-events: none;
}
.desc-toggle { margin-top: var(--space-3); }
.desc-toggle[hidden] { display: none; }
.desc-toggle .less-lbl { display: none; }
.desc-toggle[aria-expanded="true"] .more-lbl { display: none; }
.desc-toggle[aria-expanded="true"] .less-lbl { display: inline; }

/* The delivery page's live price list (deliveryinfo.go). It scrolls inside
 * its own box on a phone rather than pushing the page sideways. */
.price-table-wrap { overflow-x: auto; margin: var(--space-3) 0; }
.price-table { width: 100%; border-collapse: collapse; border: 1px solid var(--border); font-size: var(--text-sm); }
.price-table th, .price-table td { padding: 8px var(--space-3); border-top: 1px solid var(--border-soft); text-align: left; vertical-align: top; }
.price-table th { background: var(--surface-soft); font-weight: 600; border-top: 0; }
.price-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.price-table td.num { white-space: nowrap; font-weight: 700; color: var(--text); }
/* A phone fits four columns once the carrier names may wrap and the cells
 * give back their padding; the box still scrolls if a fifth comes back. */
@media (max-width: 560px) {
  .price-table th, .price-table td { padding: 6px 8px; }
}

/* ---------------------------------------------------------------- cart ---- */

.basket { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: var(--space-5); align-items: start; }
.basket .lines { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); }
.basket .summary {
  background: var(--surface-sunken);
  border: 0;
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  align-self: start;
}

.line { display: flex; align-items: center; gap: var(--space-4); padding: var(--space-4); }
.line + .line { border-top: 1px solid var(--border-soft); }
.line .shot { width: 84px; height: 72px; flex: 0 0 auto; object-fit: contain; mix-blend-mode: multiply; }
.line .grow { min-width: 0; }
.line .lineamount {
  min-width: 104px;
  text-align: right;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.stepper { display: inline-flex; border: 1px solid var(--border-strong); border-radius: var(--radius-pill); overflow: hidden; background: #fff; }
.stepper button {
  border: 0;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-weight: 600;
  width: 34px;
  cursor: pointer;
}
.stepper button:hover:not([disabled]) { background: var(--surface-sunken); }
.stepper button[disabled] { color: var(--text-faint); cursor: not-allowed; }
.stepper input {
  width: 46px;
  border: 0;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  text-align: center;
  font: inherit;
  font-weight: 600;
  padding: 7px 0;
  -moz-appearance: textfield;
}
.stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* The checkout summary: a sticky sidebar beside the form, a full-width block
 * under it.
 *
 * align-self keeps the column its content's own height — a stretched flex item
 * has nothing to stick within, so without it position: sticky does nothing.
 *
 * On one column it stops being 320px wide. The form column above it is
 * flex: 1 1 460px, so once the row wraps the summary sat at 320px against a
 * full-width form: a narrow card with the total and the place-order button in
 * it, indented from everything else on the page. Sticky goes with it, because
 * a block pinned to the top of a phone screen covers the fields being filled
 * in. The breakpoint is where 460 + 320 + the gap stops fitting. */
/* The order's consent line: a tick-box and a sentence, above the button it
   gates rather than below it as small print. Laid out like the newsletter's
   consent, because it is the same kind of thing being asked. */
.consent {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  font-size: var(--text-xs);
  line-height: 1.5;
  color: var(--text-muted);
  cursor: pointer;
}
.consent input { margin: 2px 0 0; flex: none; accent-color: var(--accent); }
.consent a { color: var(--accent-deep); text-decoration: underline; }

.co-sum { flex: 0 0 320px; position: sticky; top: var(--space-4); align-self: flex-start; }
@media (max-width: 820px) {
  .co-sum { flex: 1 1 100%; position: static; }
}

/* 14px with 16px amounts: at 12px the figures a shopper is agreeing to pay were
   the smallest type on the page (owner, 2026-11-11). */
.total-row { display: flex; align-items: baseline; gap: var(--space-3); padding: 6px 0; font-size: var(--text-base); }
.total-row .amount { margin-left: auto; font-weight: 700; font-size: 16px; white-space: nowrap; }
.sum-name { flex: 1; color: var(--text); font-weight: 700; }
/* A basket no delivery option can take: on the basket and in the checkout. */
.dblock { border: 1px solid var(--danger); background: #fdf3f1; border-radius: var(--radius); padding: var(--space-3) var(--space-4); margin: var(--space-3) 0; font-size: var(--text-base); }
.dblock-title { display: block; color: var(--danger); margin-bottom: var(--space-2); }
.dblock p { margin: var(--space-2) 0; }
.dblock ul { margin: var(--space-2) 0; padding-left: 1.2em; font-weight: 700; }
.dblock-contact { display: flex; gap: var(--space-4); flex-wrap: wrap; font-weight: 700; }

/* The checkout phone: country code chosen beside the number. */
.phone-row { display: flex; gap: var(--space-2); }
.phone-row .phone-cc { flex: 0 0 auto; width: auto; }
.phone-row input { flex: 1; min-width: 0; }
.sum-qty { color: var(--text-muted); font-weight: 500; white-space: nowrap; }
/* The postage line. Full ink and bold against the faint product lines above it,
   because it is the one line in the summary that is a charge rather than a
   description of something already counted. */
.total-row.deliv { color: var(--text); font-weight: 700; padding-top: var(--space-2); }
.total-row.deliv .amount { font-weight: 700; }
.total-row.grand {
  border-top: 1px solid var(--tint-strong);
  margin-top: var(--space-2);
  padding-top: var(--space-3);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 800;
}
.total-row.grand .amount { font-size: inherit; font-weight: inherit; }

.choice {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-4);
  cursor: pointer;
  background: #fff;
}
.choice + .choice { margin-top: var(--space-2); }
.choice:hover { border-color: var(--border-strong); }
.choice input { margin-top: 3px; accent-color: var(--accent); }
.choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }

/* ------------------------------------------------- order confirmation ---- */

/* The page after payment. Green here and nowhere else in the shop: it is the
 * one moment that has genuinely gone right, and the colour should not have been
 * spent on decoration elsewhere. */
.confirm { border-top: 3px solid var(--ok); border-radius: var(--radius-lg); }
.confirm .tick { color: var(--ok); display: flex; justify-content: center; }
.confirm h1 { font-size: var(--text-2xl); }
.confirm .mono { font-size: 1.05em; }

/* ------------------------------------------------------------ oddments ---- */

.empty-state {
  background: var(--surface-sunken);
  border: 0;
  border-radius: var(--radius-lg);
  padding: var(--space-7) var(--space-5);
  text-align: center;
  color: var(--text-muted);
}
.empty-state svg { color: var(--text-faint); margin-bottom: var(--space-3); }


/* --------------------------------------------------------------- views ---- */

/* The rest of the shop, on the design's system.
 *
 * The home page carries the design's geometry inline because it was ported from
 * the design's own markup. The inner pages have no counterpart in the design —
 * it draws a home page and nothing else — so they are built here, from the same
 * vocabulary the port established: a 28px slab on cream, 22 inside it, pills on
 * anything you press, Archivo for heads and prices, mono for the things that are
 * data rather than words.
 *
 * The one rule that ties them together is the measure. Every direct child of
 * main sits on the design's 40px side margin, which is where the 1360px content
 * width comes from. The ported blocks state the same 40 inline, so this changes
 * nothing about the home page and aligns every other page to it. */

main > * { margin-left: 40px; margin-right: 40px; }

/* A page heading lines up with the CONTENT of the panels under it, not with
 * their outer edge. main > * is inset 40px, so a bare h1 started exactly where
 * the white card starts — and every field inside that card began 20px further
 * in, which reads as the heading being out of line with its own page. Matches
 * .panel-head's side padding, and only applies to headings that are direct
 * children of main: the ones inside a hero or a panel already have theirs. */
main > h1 {
  padding-left: var(--space-5);
  padding-right: var(--space-5);
}

/* A page block. `.v-slab` is the white card the design uses for a section;
 * `.v-plain` is a block that stands on the cream with nothing under it. */
.v-slab {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
}
.v-cream { background: var(--surface-sunken); }
.v-ink { background: var(--chrome); color: #fff; }
.v-ink h1, .v-ink h2, .v-ink h3 { color: #fff; }

/* The section head, at the design's sizes: 27px/900 Archivo with a quiet
 * 13px line under it and the link pushed to the right. */
.blockhead {
  display: flex;
  align-items: flex-end;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
  flex-wrap: wrap;
}
.blockhead h1, .blockhead h2 {
  margin: 0;
  font: 900 27px/1 var(--font-display);
  letter-spacing: -0.03em;
  color: var(--text);
}
.blockhead .sub { font: 500 13px/1.4 var(--font); color: #5a6066; }
.blockhead .more {
  margin-left: auto;
  font: 800 13px/1 var(--font);
  color: var(--accent);
  white-space: nowrap;
}
.blockhead .more:hover { color: var(--accent-hover); }
.blockhead .stamp {
  margin-left: auto;
  font: 500 12px/1 var(--font-mono);
  color: #5a6066;
}
.blockhead .stamp + .more { margin-left: 0; }
/* Most heads wrap their title and subtitle in a div so the link can be pushed
 * to the far edge. */
.blockhead > div { display: flex; flex-direction: column; gap: 8px; min-width: 0; }

/* The eyebrow above a title. Never on its own — it labels the thing under it. */
.kicker {
  font: 800 10px/1 var(--font);
  letter-spacing: 0.1em;
  color: var(--accent);
  text-transform: uppercase;
}

/* --- guides ---------------------------------------------------------------- */

.guides { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-5); }
.guide { display: flex; flex-direction: column; gap: 13px; }
.guide .shot {
  aspect-ratio: 1.85;
  border-radius: 20px;
  overflow: hidden;
  background: var(--surface-sunken);
  display: block;
}
.guide .shot img { width: 100%; height: 100%; object-fit: cover; }
.guide b { font: 700 17px/1.3 var(--font-display); color: var(--text); }
.guide > span:last-child { font: 400 13px/1.5 var(--font); color: #5a6066; }
.guide:hover b { color: var(--accent-deep); }

/* --- one article ----------------------------------------------------------- */

.article-hero {
  aspect-ratio: 2.4;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--surface-sunken);
  margin-bottom: var(--space-6);
}
/* Used both as a wrapper and directly on the <img>, so the fit is stated on
 * both. */
.article-hero img, img.article-hero { width: 100%; height: 100%; object-fit: cover; }

/* Body copy is the one place on the site with a reading measure. 68 characters,
 * not the 1360px the rest of the page uses — a line of prose that wide is one
 * nobody finishes. */
.prose { max-width: 68ch; font-size: var(--text-lg); line-height: 1.7; color: var(--text); }
.prose h2 { margin: var(--space-7) 0 var(--space-3); font: 900 24px/1.15 var(--font-display); letter-spacing: -0.03em; }
.prose h3 { margin: var(--space-6) 0 var(--space-2); font: 800 18px/1.25 var(--font-display); }
.prose p { margin: 0 0 var(--space-4); }
.prose ul, .prose ol { margin: 0 0 var(--space-4); padding-left: 22px; }
.prose li { margin: 0 0 6px; }
.prose a { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 2px; }
.prose strong, .prose b { font-weight: 700; }

/* --- account and search department lists ----------------------------------- */

/* The department grid on the search page, inset like a panel body.
 *
 * It had none of its own padding, so it ran to all four edges of a card with a
 * 28px corner radius: the chips started 20px left of the heading above them,
 * and the bottom row was sliced by the curve. Same defect the filter rows had,
 * same fix — nothing meets the card's edge. */
.deps {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--space-2);
  padding: var(--space-2) var(--space-5) var(--space-5);
}

/* "Atrasts kategorijās" — where a set of results actually lives.
 *
 * A row of links out of the search, so it reads as a way onward rather than as
 * the filters below it: the label sits on the same line and the chips wrap
 * under it. */
.incats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}
.incats-lbl { color: var(--text-faint); font-size: var(--text-sm); }
.dep {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  background: var(--surface-sunken);
  border-radius: var(--radius);
  padding: 11px 14px;
  font: 700 13px/1 var(--font);
  color: var(--text);
}
.dep:hover { background: var(--accent-soft); color: var(--accent-deep); }
.dep .n { margin-left: auto; font: 500 10px/1 var(--font-mono); color: var(--text-faint); }
.dep .arrow { font: 800 12px/1 var(--font); color: var(--text-faint); }

/* --- panels, on the design's radii ----------------------------------------- */

/* The inner pages are built from .panel rather than the design's slab because
 * they carry forms and tables, which need a head and a body with different
 * padding. Same corner, same ground, same type. */
.panel { border-radius: var(--radius-xl); }
.panel-head h1, .panel-head h2 {
  margin: 0;
  font: 900 22px/1.1 var(--font-display);
  letter-spacing: -0.03em;
}
.listing-head h1 { font: 900 27px/1 var(--font-display); letter-spacing: -0.03em; }
.listing-head { border-bottom: 0; }

/* One layer of surface, at every width. This started as the phone treatment
 * and the owner's Walmart/Amazon review promoted it to the whole site: the
 * cream ground holds white, hairlined cards, and slabs exist only where they
 * are a single thing — the buy box, the assistant, the subscribe band. The
 * separation tool is the hairline, never a background change. */
.b-cats, .b-deals {
  background: transparent !important;
  padding: 0 !important;
  border-radius: 0 !important;
}
.b-deals .h-card { background: #fff !important; border: 1px solid #e8e5e0; }
.b-deals .h-tab { background: #fff !important; border: 1px solid #e8e5e0 !important; }
.catrow { background: #fff; border: 1px solid var(--border); }
.catrow:hover { background: #fff; border-color: var(--text-faint); }
.panel-flat { background: transparent; }
.panel-flat > .panel-head, .panel-flat > .panel-body { padding-left: 0; padding-right: 0; }
.panel-flat > .spec-table { margin: 0; }

.listing .grid { gap: var(--space-4); }

/* ---------------------------------------------------------- responsive ---- */

/* The design is drawn once, at 1440. Everything below is the part it does not
 * cover, and every rule here is an override of an inline style — hence the
 * !important, which in this one section is structural rather than a smell: the
 * inline value IS the desktop design, and this is the documented exception to
 * it.
 *
 * A portrait monitor lands around 1080–1200 wide. That is narrower than a
 * landscape screen, not small, and treating it as small is what left the hero
 * half empty the first time. */

@media (max-width: 1320px) {
  .brandwall { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; }
  .b-facts { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
  .droprow { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}

@media (max-width: 1320px) {
  /* Five week cards on a calendar need about 900px before the department names
     inside them start breaking mid-word. */
  .b-calendar-top { flex-direction: column; align-items: stretch !important; }
}

@media (max-width: 1180px) {
  .b-hero { grid-template-columns: minmax(0, 1fr) !important; }
  .b-promo { grid-template-columns: minmax(0, 1fr) !important; gap: 20px !important; }
  .b-promises { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .b-outlet { grid-template-columns: minmax(0, 1fr) !important; gap: 24px !important; padding: 30px !important; }
}

@media (max-width: 1010px) {
  .browse { grid-template-columns: minmax(0, 1fr); }
  /* The rail becomes a row of panels above the listing rather than
   * disappearing: on a phone the filters are the only way through 21 831
   * products. */
  .browse .rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pdp { grid-template-columns: minmax(0, 1fr); }
  .gallery .hero-shot { height: 320px; }
  .basket { grid-template-columns: minmax(0, 1fr); }

  /* The department browser turns from master-detail into a scrolling row of
   * department names with one panel under it. */
  .browser { grid-template-columns: minmax(0, 1fr) !important; }
  .browser-list { flex-direction: row !important; overflow-x: auto; gap: 8px !important; scrollbar-width: thin; }
  .browser-list label { flex: none; }
  .browser-list label :is(.n, .arrow) { display: none; }
  .b-mosaic { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}

@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); }
  /* Both, or the base min-height would hold it at 440 and the override would
   * silently do nothing — the columns are stacked here, so nothing needs to
   * stretch to match. */
  .hero-main { height: 380px !important; min-height: 0 !important; }
  /* Stacked layout for the product-shot fallback: the picture takes the top
   * of the slab and the scrim copy holds the bottom. A scene keeps filling
   * the whole frame. */
  .hero-img { inset: 0 0 40% 0 !important; padding: 18px !important; height: auto !important; }
  .hero-scene { inset: 0 !important; padding: 0 !important; height: 100% !important; }
  .hero-copy h1 { font-size: 34px; }
  .guidegrid { grid-template-columns: minmax(0, 1fr) !important; }
  .outlet-grid { grid-template-columns: 1fr 1fr !important; }
  .droprow { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}

@media (max-width: 860px) {
}

@media (max-width: 760px) {
  /* iOS zooms the whole page in when a focused field is sized under 16px, and
   * that zoom is what "breaks" the layout the moment the keyboard opens — it
   * never zooms back out on its own. Every field meets the threshold on a
   * phone; the design's smaller sizes return with the desktop. !important
   * because the search and newsletter inputs carry their sizes inline. */
  input, select, textarea { font-size: 16px !important; }

  /* The 40px side margin is a 1440-page measurement. On a phone it is a fifth
   * of the screen, so every ported block and the chrome above it come in to 12.
   * These are the only places the design's 40 appears. */
  main > *,
  .b-hero, .b-ask, .b-deals, .b-drops,
  .b-subscribe, .b-outlet, .b-brands, .b-foot, .b-legal,
  .b-calendar, .b-promo {
    margin-left: 12px !important;
    margin-right: 12px !important;
  }
  /* Tighter vertical rhythm too: 20px between slabs is desktop air, and on a
   * phone it is a fifth of the screen given to nothing. */
  main { gap: 12px; }
  .b-calendar, .b-promo { padding: 20px !important; }
  .b-calendar h2, .b-promo h1 { font-size: 28px !important; }
  /* Week cards scroll rather than shrink: four of them at 80px wide is a row of
     unreadable stubs, and the dates are the whole point of the block. */
  .weekrow {
    display: flex !important;
    overflow-x: auto;
    scrollbar-width: thin;
    margin: 0 -24px;
    padding: 0 24px 6px;
  }
  .weekrow > a { flex: 0 0 150px; }
  .c-bar, .c-util, .c-head, .c-navwrap { padding-left: 12px !important; padding-right: 12px !important; }

  .c-head { flex-wrap: wrap !important; }
  .c-search { order: 3; flex-basis: 100% !important; }
  .b-foot { padding: 22px !important; }
  .b-legal-row { flex-direction: column; gap: 8px !important; }
  /* The utility bar holds six links and a phone fits two. */
  .c-util { font-size: 11px !important; }
  .c-util a:nth-child(n+2) { display: none; }
  .c-util > div:last-child a:nth-child(n+2) { display: none; }

  /* The flattening itself is site-wide now (see the one-layer section); the
   * phone only tightens what remains. */
  .catgrid { gap: 8px !important; }
  .v-slab { background: transparent; padding: 0; }
  .b-ask { padding: 22px !important; }
  .b-hero { border-radius: 22px !important; }
  .hero-main { border-radius: 22px !important; }
  .b-deals h2 { font-size: 22px !important; }
  .b-cats h2 { font-size: 22px !important; }
  .b-subscribe h2 { font-size: 26px !important; }
  .b-ask h2 { font-size: 24px !important; }

  /* A basket line is a photograph, a name, a stepper, a remove button and a
   * total. That is 420px of content and a phone has 326 — without wrapping the
   * whole page scrolls sideways, which it did. */
  .line { flex-wrap: wrap; }
  .line .grow { min-width: 150px; }
  .line .lineamount { margin-left: auto; }
  .panel-head, .listing-head, .section-head { flex-wrap: wrap; }
  .listing-head .sorter { margin-left: 0; width: 100%; }
  .listing-head .sorter .input { width: 100%; }
  .container { padding: 0 16px; }

  /* The panel's insets track the navwrap padding at this width too. */
  .h-panel { left: 12px; right: 12px; }

  /* The phone home page keeps four things: the hero slider, the assistant,
   * the category grid and the deals. The rest of the home page is desktop
   * furniture — stacked single-file on a 375px screen it was five screens of
   * scrolling before the first product. main is already a flex column, so
   * hiding is display and order is order. */
  .b-subscribe, .b-drops, .b-outlet, .b-brands { display: none !important; }
  .b-hero { order: -3; }
  .b-ask { order: -2; }
  .b-cats { order: -1; }
  .catgrid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 2px 8px; }
}

@media (max-width: 620px) {
  .droprow { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .brandwall { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
}

@media (max-width: 560px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); }
  .browse .rail { grid-template-columns: minmax(0, 1fr); }
  .tile .shot { height: 132px; }
  .price-big { font-size: 30px; }
  .gallery .hero-shot { height: 240px; }
  .spec-table .sname { width: 130px; }

  .outlet-grid { grid-template-columns: minmax(0, 1fr) !important; }
  .hero-main { height: 360px !important; min-height: 0 !important; }
  /* Two up, not one. A single full-width product card is a poster, and it
   * pushes everything below it a screen further down. */
  .dealgrid { gap: 10px !important; }
  .b-browser > div:first-child h2 { font-size: 20px !important; }
}

@media (max-width: 430px) {
  .b-hero { gap: 12px !important; }
}

@media (prefers-reduced-motion: reduce) {
  .btn:active { transform: none; }
  .scroller { scroll-behavior: auto; }
  .slide { transition: none; }
  .hero-dots label { transition: none; }
}

/* --- department artwork fit ------------------------------------------------ */

/* The mosaic tiles are about 1.41:1 and the artwork is 16:9, so a SCENE loses a
   tenth off each side to the crop and nobody can tell. */
.art-scene { object-fit: cover; }

/* A product cut-out is a different thing and croppng it beheads the product —
   the storage tile was a USB stick with its connector and its keyring cut off,
   which reads as a picture that failed to load. Contained, nothing is lost, and
   because the picture's own background is white the tile is made white too so
   there is no letterbox to see. */
.art-cutout { object-fit: contain; background: #fff; }

/* Whatever holds it goes white, matched structurally rather than by naming the
   containers. The picture appears in the mosaic AND in the department browser,
   and a rule listing class names had already missed the second one — where the
   beige tile behind a white-background photograph is precisely the letterbox
   this is meant to avoid. */
a:has(> .art-cutout) { background: #fff !important; }

/* --- cookie notice ---------------------------------------------------------- */

/* Bottom of the viewport, above everything, but deliberately small: it informs
   about two strictly necessary cookies, so it has no business taking the screen
   hostage the way a consent wall does. */
.cookie-note {
  position: fixed;
  left: var(--space-4);
  right: var(--space-4);
  bottom: var(--space-4);
  z-index: 200;
  margin: 0 auto;
  max-width: 760px;
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  background: #23262b;
  color: #fff;
  border-radius: 14px;
  box-shadow: 0 10px 34px rgba(35, 38, 43, 0.28);
  font-size: var(--text-sm);
  line-height: 1.5;
}
/* hidden must beat the display the layout needs — the exact trap the prize
 * wheel's box once fell into. Without this, pressing Sapratu "worked" and
 * changed nothing anyone could see: the script set hidden, and display:flex
 * above overrode it. */
.cookie-note[hidden] { display: none; }
.cookie-note a { color: #ffffff; text-decoration: underline; }
.cookie-ok {
  flex: none;
  border: 0;
  cursor: pointer;
  padding: 10px 18px;
  border-radius: 10px;
  background: #fff;
  color: #23262b;
  font: 800 13px/1 Manrope;
}
.cookie-ok:hover { background: var(--accent-soft); }

@media (max-width: 640px) {
  .cookie-note { flex-direction: column; align-items: stretch; text-align: left; }
  .cookie-ok { width: 100%; }
}

/* The question box's answers.
 *
 * Cards rather than a list because the answer is products, and a product
 * without its price beside it is a link rather than a recommendation. Laid out
 * on the dark hero panel the composer sits on, so the surface is light-on-dark
 * rather than the cream used everywhere else. */
.ask-found {
  display: grid;
  gap: 10px;
  margin-top: var(--space-3);
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
}
.ask-card {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  text-decoration: none;
}
.ask-card:hover { background: rgba(255, 255, 255, 0.14); }
/* Product photographs are cut-outs on white, so the frame is white however
 * dark the slab behind it — contain, never cover, or a tall appliance loses
 * its feet. */
.ask-card img {
  width: 100%;
  height: 110px;
  object-fit: contain;
  background: #fff;
  border-radius: 10px;
  padding: 6px;
  box-sizing: border-box;
  margin-bottom: 4px;
}
.ask-card strong { font: 700 13px/1.35 Manrope; }
.ask-card-price { font: 800 15px/1.2 Archivo; }
.ask-card small { font: 400 11px/1.4 Manrope; opacity: 0.72; }

/* The out-of-stock card: a plain box whose name carries the link, with the
 * waiting-list form underneath. The picture dims — the product is real but
 * not on the shelf, and the card should read that way at a glance. */
.ask-card-out img { opacity: 0.55; }
.ask-card-name {
  font: 700 13px/1.35 Manrope;
  color: #fff;
  text-decoration: none;
}
.ask-card-name:hover { text-decoration: underline; }
.ask-alert-note { font: 400 11px/1.4 Manrope; color: #f2b8a8; }
.ask-alert { display: flex; gap: 6px; margin-top: 6px; }
.ask-alert input {
  flex: 1;
  min-width: 0;
  height: 34px;
  border: 0;
  border-radius: 999px;
  padding: 0 12px;
  font: 400 12px/1 var(--font);
  color: var(--text);
  outline: none;
}
.ask-alert button {
  height: 34px;
  flex: none;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font: 800 11px/1 var(--font);
  padding: 0 14px;
  cursor: pointer;
}
.ask-alert button:disabled { opacity: 0.6; cursor: default; }

/* ------------------------------------------------- energy label arrow ---- */

/* The class and its ladder, beside the price.
 *
 * Both halves are required, not decorative: the delegated acts ask an
 * advertisement or a distance sale for "the energy efficiency class and the
 * range of energy efficiency classes available on the label". A bare letter is
 * half a statement — C is near the top of A-G and near the bottom of A+++ to D.
 *
 * The fill and the ink arrive inline because they are per-product data. They
 * are the only inline values here; the shape and the sizing stay in one place
 * so the arrow on a tile and the arrow on a product page cannot drift.
 *
 * --elabel-size is set by whatever prints the price, because the EC's guidance
 * for dealers is that the arrow matches the price's own font size. Anything
 * that shows a price and forgets to set it gets 1em rather than nothing. */
.elabel {
  display: inline-flex;
  /* stretch, not center: the scale box takes its height from the arrow beside
   * it, so the two read as one pictogram rather than two things that happen to
   * be adjacent. */
  align-items: stretch;
  gap: 0.28em;
  font-family: var(--font-display);
  /* A floor, because the pictogram has a size below which it stops being one.
   * The ladder box stacks two classes and an arrow into the height of a single
   * letter, so its text lands at about a third of --elabel-size — fine at the
   * 28px a product page prints, and four pixels at the 15px the basket used to
   * ask for. The dealer guidance sets the price's font size as the floor for
   * the arrow, not the ceiling, so rounding up is allowed where rounding down
   * would be unreadable. */
  font-size: max(26px, var(--elabel-size, 1em));
  line-height: 1;
  white-space: nowrap;
  vertical-align: baseline;
}

/* The arrow itself: a block clipped to a point on the right, the way the
 * pointer is drawn on the label. clip-path rather than a border triangle so
 * the colour stays one value that can be set from data. */
.elabel-class {
  /* 1em, so --elabel-size IS the letter size and a caller can set it to the
   * price beside it without doing arithmetic. The dealer guidance asks for the
   * arrow at the price's own font size; anything indirect here is a place for
   * one surface to drift smaller than the rule allows. */
  background: var(--e-fill);
  color: var(--e-ink);
  font-weight: 800;
  letter-spacing: -0.01em;
  padding: 0.2em 0.62em 0.2em 0.38em;
  border-radius: 3px 0 0 3px;
  clip-path: polygon(0 0, calc(100% - 0.42em) 0, 100% 50%, calc(100% - 0.42em) 100%, 0 100%);
}

/* The ladder, drawn the way the label draws it: the best class above the worst
 * with an arrow between, boxed. It replaced "A+++–D" set in half-size grey,
 * which said the same thing and was read by nobody.
 *
 * Sized as a fraction of the badge rather than pinned to a minimum of its own.
 * Two letters, an arrow, two gaps, padding and a border have to fit the height
 * of one class letter, which spends the budget at almost exactly a third — so
 * a floor here does not make the text bigger, it makes the BOX taller than the
 * arrow beside it. Pinning 9px turned the basket's 15px badge into a 39px one:
 * legible, and three times the height of the price it sat next to. The floor
 * belongs on .elabel, where it lifts the whole pictogram together. */
.elabel-scale {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  box-sizing: border-box;
  /* Every value below is spent out of one budget: two letters, an arrow, two
   * gaps, padding and a border have to add up to the height of a single class
   * letter. Trimming the arrow and the gaps is what buys the letters their
   * size, so these are tuned together and none of them is arbitrary. */
  font-size: 0.37em;
  font-weight: 700;
  line-height: 1;
  /* Its own em from here down, which is the small one. */
  padding: 0.2em 0.32em;
  gap: 0.12em;
  border: 0.13em solid currentColor;
  border-radius: 0.26em;
  color: var(--text);
}

/* Drawn rather than typed — see the template. Sized in the scale box's own em
 * so it tracks the letters above and below it. */
.elabel-scale-arrow {
  display: block;
  width: 0.44em;
  height: 0.88em;
}

.elabel-scale-end {
  display: block;
  letter-spacing: 0.01em;
}

/* The nested display: the label and the information sheet, behind the arrow.
 *
 * A <details>, so it works with scripting off. The acts call this a "nested
 * display" — an image reached by a click or a roll-over on another image — and
 * a disclosure is exactly that without a line of JavaScript to break.
 *
 * The marker is removed because the arrow IS the affordance; a browser triangle
 * beside it reads as a second, unrelated control. */
.elabel-more { display: block; }
.elabel-more > summary {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  cursor: pointer;
  list-style: none;
  width: fit-content;
}
.elabel-more > summary::-webkit-details-marker { display: none; }

/* The words beside the arrow, so the click target says what it opens. Without
 * them a coloured letter is a badge, and nobody clicks a badge. */
.elabel-open {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.elabel-more[open] > summary .elabel-open { color: var(--text); }

.elabel-panel {
  margin-top: var(--space-3);
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: #fff;
  width: fit-content;
  max-width: 100%;
}
/* The label is a tall portrait sheet. Capped by height rather than width so it
 * cannot run past the buy card on a narrow screen, and never upscaled: it is a
 * legal document and a blurry one is worse than a small one. */
.elabel-panel img {
  display: block;
  height: auto;
  max-width: 100%;
  max-height: 460px;
  width: auto;
}
.elabel-fiche {
  display: inline-block;
  margin-top: var(--space-3);
  font-size: var(--text-sm);
  font-weight: 600;
}
.elabel-src {
  margin: var(--space-2) 0 0;
  font-size: var(--text-xs);
  color: var(--text-faint);
}

/* The price-comparison sites' buttons under the footer (base.html). */
.b-badges { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 4px 0 10px; }
.b-badges img { display: block; height: auto; max-width: 100%; }
.b-badges a { display: inline-flex; border-radius: 6px; }
.b-badges a:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }
