/* ==========================================================================
   Rivexo Athletics - main stylesheet
   Load order: tokens.css, then this file.
   Section padding lives on .section only, so specificity never fights itself.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Base
   -------------------------------------------------------------------------- */

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

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

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--step-0);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, p, figure, blockquote, dl, dd, ul, ol, fieldset { margin: 0; }
ul, ol { padding: 0; list-style: none; }
fieldset { border: 0; padding: 0; min-width: 0; }

img, svg, video { display: block; max-width: 100%; height: auto; }

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }

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

::selection { background: var(--red); color: var(--white); }

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; top: 0; left: var(--gutter);
  transform: translateY(-120%); z-index: 100;
  background: var(--red); color: var(--white);
  padding: var(--space-2xs) var(--space-s);
  font-size: var(--step--1); font-weight: 500;
  transition: transform 160ms var(--ease);
}
.skip-link:focus-visible { transform: translateY(0); }

/* --------------------------------------------------------------------------
   2. Typography roles
   -------------------------------------------------------------------------- */

.display-xl, .display-l, .display-m, .display-s {
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  line-height: var(--lh-tight);
  /* Condensed type is already tight, so it needs far less negative tracking. */
  letter-spacing: -0.005em;
  text-wrap: balance;
}

.display-xl { font-size: var(--step-7); font-weight: 900; }
.display-l  { font-size: var(--step-5); }
.display-m  { font-size: var(--step-4); line-height: var(--lh-snug); }
.display-s  { font-size: var(--step-2); font-stretch: var(--wd-normal); letter-spacing: -0.01em; line-height: var(--lh-snug); }

.lede {
  font-size: var(--step-1);
  line-height: 1.55;
  color: var(--ink-60);
  max-width: 46ch;
}

.meta { font-size: var(--step--1); color: var(--ink-60); }

.prose { max-width: var(--measure); }
.prose > * + * { margin-top: var(--space-m); }
.prose h2 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-3); font-weight: 700; letter-spacing: -0.005em; line-height: var(--lh-snug); margin-top: var(--space-xl); }
.prose h3 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-1); font-weight: 600; letter-spacing: -0.005em; margin-top: var(--space-l); }
.prose ul { padding-left: 1.2em; }
.prose ul li { position: relative; }
.prose ul li + li { margin-top: var(--space-2xs); }
.prose ul li::before { content: ''; position: absolute; left: -1em; top: 0.68em; width: 0.5em; height: 2px; background: var(--red); }
.prose ol { counter-reset: n; padding-left: 1.6em; }
.prose ol li { counter-increment: n; position: relative; }
.prose ol li + li { margin-top: var(--space-2xs); }
.prose ol li::before { content: counter(n) '.'; position: absolute; left: -1.6em; color: var(--red); font-weight: 600; }
.prose a { text-decoration: underline; }
.prose a:hover { color: var(--red); }
.prose strong { font-weight: 600; }
.prose blockquote { border-left: 3px solid var(--red); padding-left: var(--space-m); font-size: var(--step-1); line-height: 1.5; }

/* --------------------------------------------------------------------------
   3. Layout primitives
   -------------------------------------------------------------------------- */

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.container-narrow { max-width: var(--container-narrow); }

.section { padding-block: var(--section-y); }
.section-tight { padding-block: calc(var(--section-y) * 0.6); }

.on-paper { background: var(--paper); }
.on-ink { background-color: var(--ink); background-image: var(--gloss); color: var(--on-dark); }
.on-ink .lede, .on-ink .meta { color: var(--on-dark-60); }

/* --------------------------------------------------------------------------
   Section heads
   Every section opener on the site is styled from here, once. A section only
   ever needs the bare markup:

     <div class="section-head">
       <h2>Twelve sports, one factory</h2>
       <p>We build team uniforms across all of them…</p>
     </div>

   No utility classes on the heading, no lede class on the paragraph, and
   nothing to add to the stylesheet when a new section appears. The heading
   and the paragraph are set by their element, inside this one component.
   -------------------------------------------------------------------------- */

/*
 * Width is set in rem, not ch. A ch on this element resolves against body
 * size, so a `ch` cap here was measuring the paragraph and then applying
 * that same width to a 53px display heading, wrapping headings far earlier
 * than they needed to. The heading gets the full width; the paragraph is
 * held tighter by its own rule below.
 */
.section-head {
  max-width: 42rem;
  margin-bottom: var(--space-2xl);
}

/* Spacing lives on the stack, so a section head can carry two elements or
   four without anything needing a bespoke margin. */
.section-head > * + * { margin-top: var(--space-s); }

.section-head h2 {
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  font-size: var(--step-5);
  line-height: 1;
  letter-spacing: -0.005em;
  /* Keeps a two-line heading from dropping a single orphaned word. */
  text-wrap: balance;
}

.section-head p {
  font-size: var(--step-1);
  line-height: 1.5;
  color: var(--ink-60);
  max-width: 34rem;
  /* Stops a paragraph ending on a single orphaned word. */
  text-wrap: pretty;
}

.on-ink .section-head p { color: var(--on-dark-60); }

/* Heading on the left, a link or action on the right. */
.section-head-split {
  display: grid;
  gap: var(--space-m);
  align-items: end;
  margin-bottom: var(--space-2xl);
}
.section-head-split .section-head { margin-bottom: 0; }
@media (min-width: 56rem) {
  .section-head-split { grid-template-columns: minmax(0, 1fr) auto; }
}

.rule { height: var(--hairline); background: var(--line); border: 0; }

.split { display: grid; gap: var(--space-xl); }
@media (min-width: 62rem) { .split { grid-template-columns: minmax(0, 1fr) 21rem; } }

.info-panel { background: var(--paper); border-radius: var(--radius-lg); padding: var(--space-l); align-self: start; }
.info-panel h3 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-0); font-weight: 600; margin-bottom: var(--space-2xs); }
.info-panel + .info-panel, .info-panel .info-block + .info-block { margin-top: var(--space-l); }
.info-panel p, .info-panel address { font-size: var(--step--1); color: var(--ink-60); font-style: normal; line-height: 1.7; }
.info-panel a { color: var(--ink); }

/* --------------------------------------------------------------------------
   The card wash
   A disc that covers the whole card, anchored at the point the pointer
   crossed the edge. The script writes --wx, --wy and --wr; everything else
   is a transform, so the flood runs on the compositor and never touches
   layout.

   --wr is the measured distance from that entry point to the furthest
   corner. It was a flat 300% of the card's width to begin with, which is
   fine on a square tile but left a visible arc across the bottom of the
   taller category cards, where the diagonal is longer than 1.5 widths.
   -------------------------------------------------------------------------- */

.wash {
  position: absolute;
  top: var(--wy, 50%);
  left: var(--wx, 50%);
  width: calc(var(--wr, 32rem) * 2);
  height: calc(var(--wr, 32rem) * 2);
  border-radius: 50%;
  background: var(--ink);
  /* 20%: a tint that sweeps across, not a cover. At 0.95 it buried the
     photograph entirely, which is what made the tiles read as solid black
     on hover. */
  opacity: 0.2;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0);
}

.stack-s > * + * { margin-top: var(--space-s); }
.stack-m > * + * { margin-top: var(--space-m); }
.stack-l > * + * { margin-top: var(--space-l); }

/* --------------------------------------------------------------------------
   4. Image placeholders
   Photography is not in yet. These stand in deliberately rather than
   leaving broken images, and disappear the moment a real file is set.
   -------------------------------------------------------------------------- */

.ph {
  position: relative;
  display: grid; place-items: center;
  background: var(--paper-2);
  border: var(--hairline) solid var(--line);
  color: var(--ink-40);
  overflow: hidden;
}
.ph::before {
  content: '';
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(
    -45deg, transparent 0 11px, rgba(0, 0, 0, 0.028) 11px 22px
  );
}
.ph span {
  position: relative;
  font-size: var(--step--2);
  letter-spacing: 0.04em;
  text-align: center;
  padding: var(--space-s);
  max-width: 22ch;
}
.on-ink .ph { background: var(--ink-raise); border-color: var(--dark-line); color: var(--ink-40); }
.on-ink .ph::before { background-image: repeating-linear-gradient(-45deg, transparent 0 11px, rgba(255,255,255,0.03) 11px 22px); }

.ratio-4x5 { aspect-ratio: 4 / 5; }
.ratio-1x1 { aspect-ratio: 1 / 1; }
.ratio-3x2 { aspect-ratio: 3 / 2; }
.ratio-16x9 { aspect-ratio: 16 / 9; }

.media { overflow: hidden; background: var(--paper-2); }
.media img { width: 100%; height: 100%; object-fit: cover; }

/* --------------------------------------------------------------------------
   5. Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--space-2xs);
  padding: 0.95em 1.7em;
  font-family: var(--font-text);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.005em;
  border: 1.5px solid transparent;
  border-radius: var(--radius);
  cursor: pointer; text-decoration: none;
  transition: background-color 150ms var(--ease), border-color 150ms var(--ease), color 150ms var(--ease);
}

.btn-primary { background: var(--red); color: var(--white); border-color: var(--red); }
.btn-primary:hover { background: var(--red-deep); border-color: var(--red-deep); }

.btn-dark { background: var(--ink); color: var(--white); border-color: var(--ink); box-shadow: var(--gloss-edge); }
.btn-dark:hover { background: var(--ink-80); border-color: var(--ink-80); }

.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink); }

.on-ink .btn-ghost { color: var(--white); border-color: #4A4A4A; }
.on-ink .btn-ghost:hover { border-color: var(--white); }

.btn-light { background: var(--white); color: var(--ink); border-color: var(--white); }
.btn-light:hover { background: var(--paper); border-color: var(--paper); }

.btn-row { display: flex; flex-wrap: wrap; gap: var(--space-xs); }

.link-more {
  display: inline-block;
  font-size: var(--step--1); font-weight: 600;
  text-decoration: none;
  border-bottom: 2px solid var(--red);
  padding-bottom: 2px;
  transition: color 150ms var(--ease);
}
.link-more:hover { color: var(--red); }

/* --------------------------------------------------------------------------
   6. Site header
   Three bands, deliberately unlike each other:

     utility  dark, 36px, small light text at regular weight
     brand    white, roomy, the logo and the one red button
     sports   white with a hairline, condensed uppercase black

   The contrast is the point. A slim dark strip reads as service information
   and gets out of the way; the sports bar reads as navigation.
   -------------------------------------------------------------------------- */

/*
 * Sticky with a NEGATIVE offset equal to the utility strip's height. The
 * header scrolls normally until its top edge reaches -2.5rem, at which point
 * it pins with the strip already out of view and the brand row and sports bar
 * still on screen.
 *
 * This replaces an earlier version that animated the header's own height on
 * scroll. Because a sticky element still takes up space in flow, shrinking it
 * pulled the page up, which moved scrollY, which un-set the class, which
 * restored the height: the header visibly shook. Nothing here changes
 * geometry in response to scrolling, so there is no loop to get into.
 */
.site-header { position: sticky; top: -2.5rem; z-index: 50; }

/* --- Band 1: utility strip ---------------------------------------------- */

.header-utility {
  background-color: var(--ink);
  background-image: var(--gloss);
  color: var(--on-dark-60);
  overflow: hidden;
  max-height: 2.5rem;
  box-shadow: var(--gloss-edge);
}

.header-utility-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-m);
  height: 2.5rem;
}

.nav-utility { display: flex; align-items: center; gap: var(--space-m); }
.nav-utility a {
  font-size: var(--step--2);
  font-weight: 400;
  letter-spacing: 0.012em;
  color: var(--on-dark-60);
  text-decoration: none;
  position: relative;
  white-space: nowrap;
}
.nav-utility a:hover,
.nav-utility .current-menu-item > a { color: var(--white); }

.utility-contact {
  display: flex; align-items: center; gap: var(--space-xs);
  font-size: var(--step--2);
  color: var(--on-dark-60);
  white-space: nowrap;
}
.utility-contact a { color: var(--on-dark-60); text-decoration: none; }
.utility-contact a:hover { color: var(--white); }
.utility-sep { flex: none; width: var(--hairline); height: 0.9rem; background: var(--dark-line); }

/* The strapline carries its own divider, so hiding it on a narrow screen
   takes the divider with it and leaves the phone and the mailbox joined by
   the one that belongs to them. */
.utility-note { display: flex; align-items: center; gap: var(--space-xs); color: #7C838B; }

/* --- Band 2: brand row --------------------------------------------------- */

.header-brand {
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(160%) blur(10px);
}
.header-brand-inner { display: flex; align-items: center; gap: var(--space-m); min-height: 4.5rem; }

.brand {
  display: flex; align-items: center; gap: 0.55rem;
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800; font-size: var(--step-3);
  letter-spacing: 0.005em; text-transform: uppercase;
  text-decoration: none; margin-right: auto; line-height: 1;
}
.brand img { max-height: 2.75rem; width: auto; }
.brand-mark { width: 0.55rem; height: 1.4rem; background: var(--red); border-radius: 1px; }

/* --- Band 3: sports bar -------------------------------------------------- */

.header-nav {
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(160%) blur(10px);
  border-top: var(--hairline) solid var(--line);
  border-bottom: var(--hairline) solid var(--line);
}

.header-nav-inner {
  /* Safety valve: a longer sport name added later scrolls the bar rather
     than wrapping it into a broken second line. */
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.header-nav-inner::-webkit-scrollbar { display: none; }

.sports-list {
  display: flex; align-items: stretch; justify-content: space-between;
  gap: clamp(0.125rem, 0.9vw, 1rem);
}

.sports-list a {
  display: block; position: relative;
  padding: 0.85rem 0.35rem;
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 700;
  font-size: var(--step--2);
  letter-spacing: 0.035em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  color: var(--ink);
}
.sports-list .current-menu-item > a { color: var(--red); }

.sports-list .menu-item-has-children { position: relative; }
.sports-list .sub-menu {
  position: absolute; top: 100%; left: 0;
  min-width: 12rem; padding: var(--space-2xs);
  background: var(--white);
  border: var(--hairline) solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 48px -20px rgba(0, 0, 0, 0.28);
}
.sports-list .sub-menu a { padding: 0.45rem 0.6rem; font-size: var(--step--2); border-radius: var(--radius); text-transform: none; letter-spacing: 0; }
.sports-list .sub-menu a:hover { background: var(--paper); color: var(--red); }

/* --- Shared -------------------------------------------------------------- */

.nav-toggle {
  display: none;
  background: transparent; border: var(--hairline) solid var(--line-strong);
  color: var(--ink); border-radius: var(--radius);
  padding: 0.55rem 0.85rem;
  font-family: var(--font-text); font-size: var(--step--1); font-weight: 500;
  cursor: pointer;
}

.header-cta { padding: 0.75em 1.4em; }

.nav-panel-extra { display: none; }

/* Footer reuses the plain list layout. */
.nav-list { display: flex; align-items: center; gap: var(--space-m); }
.nav-list a { font-size: var(--step--1); font-weight: 500; text-decoration: none; position: relative; }

@media (max-width: 61.999rem) {
  .nav-toggle { display: inline-block; }
  .header-cta { display: none; }

  /* The utility strip keeps only the phone and the mailbox, which is the
     part a visitor on a phone actually wants. The strapline goes, and its
     divider goes with it. */
  .nav-utility { display: none; }
  .header-utility-inner { justify-content: center; }
  .utility-note { display: none; }

  .header-brand-inner { min-height: 3.75rem; }
  .brand { font-size: var(--step-2); }

  .header-nav {
    position: absolute; inset-inline: 0; top: 100%;
    border-top: 0;
    box-shadow: var(--shadow-lift);
    display: none;
    max-height: calc(100vh - 6.25rem);
    overflow-y: auto;
  }
  .header-nav[data-open='true'] { display: block; }

  .header-nav-inner { overflow-x: visible; padding-block: var(--space-2xs) var(--space-m); }

  .sports-list { flex-direction: column; gap: 0; }
  .sports-list > li { border-bottom: var(--hairline) solid var(--line); }
  .sports-list a { padding: var(--space-s) 0; font-size: var(--step-0); letter-spacing: 0.02em; }

  .sports-list .sub-menu {
    position: static; min-width: 0; padding: 0 0 var(--space-2xs) var(--space-s);
    background: transparent; border: 0; box-shadow: none;
  }

  .nav-panel-extra { display: block; padding-top: var(--space-m); }
  .nav-panel-extra .nav-list { flex-direction: column; align-items: stretch; gap: 0; margin-bottom: var(--space-m); }
  .nav-panel-extra .nav-list li { border-bottom: var(--hairline) solid var(--line); }
  .nav-panel-extra .nav-list a { display: block; padding-block: var(--space-s); font-size: var(--step-0); }
  .nav-panel-extra .btn { width: 100%; }
}

/* --------------------------------------------------------------------------
   7. Footer
   -------------------------------------------------------------------------- */

.site-footer { background-color: var(--ink); background-image: var(--gloss); color: var(--on-dark); padding-block: var(--space-2xl) var(--space-l); }
.footer-grid { display: grid; gap: var(--space-xl); }
@media (min-width: 48rem) { .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; } }
.footer-head { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step--1); font-weight: 600; margin-bottom: var(--space-s); letter-spacing: -0.01em; }
.footer-list li + li { margin-top: var(--space-2xs); }
.footer-list a { font-size: var(--step--1); color: var(--on-dark-60); text-decoration: none; }
.footer-list a:hover { color: var(--white); }
.footer-address { font-size: var(--step--1); color: var(--on-dark-60); line-height: 1.75; font-style: normal; }
.footer-address a { color: var(--on-dark-60); }
.footer-address a:hover { color: var(--white); }
.footer-base {
  margin-top: var(--space-xl); padding-top: var(--space-m);
  border-top: var(--hairline) solid var(--dark-line);
  display: flex; flex-wrap: wrap; gap: var(--space-s) var(--space-m);
  justify-content: space-between;
  font-size: var(--step--2); color: var(--on-dark-60);
}
.footer-base .nav-list a { color: var(--on-dark-60); }
.footer-base .nav-list a:hover { color: var(--white); border-bottom-color: var(--red); }

/* --------------------------------------------------------------------------
   8. Banner - full-bleed photograph with overlaid headline
   -------------------------------------------------------------------------- */

.banner {
  position: relative;
  display: grid; align-items: end;
  min-height: clamp(30rem, 76vh, 46rem);
  background-color: var(--ink);
  color: var(--white);
  overflow: hidden;
}

.banner-media { position: absolute; inset: 0; }
.banner-media img { width: 100%; height: 100%; object-fit: cover; }
.banner-media .ph { width: 100%; height: 100%; border: 0; }

/* Scrim. Without it, white type over an unknown photograph is a gamble. */
.banner::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.84) 0%,
    rgba(0, 0, 0, 0.54) 42%,
    rgba(0, 0, 0, 0.18) 78%,
    rgba(0, 0, 0, 0.30) 100%
  );
}

.banner-inner { position: relative; z-index: 1; padding-block: clamp(3rem, 6vw, 5.5rem); }
.banner h1 { max-width: 18ch; margin-bottom: var(--space-m); }
.banner .lede { color: rgba(255, 255, 255, 0.86); max-width: 48ch; margin-bottom: var(--space-l); }

.banner-eyebrow {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-size: var(--step--1); font-weight: 500;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: var(--space-m);
}
.banner-eyebrow::before { content: ''; width: 2rem; height: 2px; background: var(--red); }

/* --------------------------------------------------------------------------
   8b. Key terms band
   The four numbers a buyer checks first, as a slim band of its own between
   the banner and the first section.

   It is red, not black. The banner above it is black and the section below
   is white, so a black band here read as more of the same. Red is the one
   accent the site owns, and this is the place to spend it: the page's first
   proof point, in the colour nothing else on the page uses at this scale.
   -------------------------------------------------------------------------- */

/*
 * Flat, true --red. No gloss layer and no gradient.
 *
 * An earlier version put the white sheen over the top of this band and a 17%
 * black gradient across the bottom, which meant almost none of it was
 * actually #C8102E: it read lighter at the top and darker at the bottom than
 * the buttons, so the band looked like a second, different red. The accent
 * only reads as one colour if it is used as one colour.
 */
.facts {
  position: relative;
  background-color: var(--red);
  color: var(--white);
  overflow: hidden;
  isolation: isolate;
}

.facts-slab {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (min-width: 56rem) {
  .facts-slab { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.fact {
  position: relative;
  padding: clamp(1rem, 1.6vw, 1.35rem) clamp(0.9rem, 1.6vw, 1.5rem);
}
/* The first and last cells align with the container edge, not its padding. */
@media (min-width: 56rem) {
  .fact:first-child { padding-left: 0; }
  .fact:last-child { padding-right: 0; }
}

/* Dividers are white at low opacity, not the dark hairline used elsewhere:
   a near-black rule on red goes muddy rather than reading as a line. */
.facts { --fact-divider: rgba(255, 255, 255, 0.24); }

/* Two columns: rules between, never around the outside. */
.fact:nth-child(n+3) { border-top: var(--hairline) solid var(--fact-divider); }
.fact:nth-child(even) { border-left: var(--hairline) solid var(--fact-divider); }

/* Four columns: one rule between each pair, no rows to divide. */
@media (min-width: 56rem) {
  .fact { border-top: 0; }
  .fact + .fact { border-left: var(--hairline) solid var(--fact-divider); }
}

/* Secondary text on this band is white held back, not grey. --on-dark-60 is
   tuned against black and drops to about 2:1 on red, which is unreadable.
   White at 88% gives 4.8:1, which clears AA at this small size. */
.facts { --fact-quiet: rgba(255, 255, 255, 0.88); }

.fact-label {
  font-size: var(--step--2);
  color: var(--fact-quiet);
  letter-spacing: 0.015em;
  margin-bottom: 0.2rem;
}

/*
 * Inline rather than flex on purpose. A flex row puts its gap between every
 * child, which pushed the two halves of a range apart ("15 - 25"). Inline
 * children sit on the baseline with no gap, and only the unit is spaced.
 */
.fact-value {
  margin: 0;
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  font-size: clamp(1.35rem, 1.05rem + 1.1vw, 1.85rem);
  line-height: 1.08;
  letter-spacing: 0;
  color: var(--white);
}

.fact-num { font-variant-numeric: tabular-nums; }
.fact-num-text { font-size: 0.78em; }
/* The dash was red to stand out on black. On red it would vanish, so it
   steps back to a soft white instead of trying to compete with the figures. */
.fact-dash { color: rgba(255, 255, 255, 0.62); margin-inline: 0.02em; }

.fact-unit {
  font-family: var(--font-text);
  font-size: var(--step--1);
  font-weight: 500;
  letter-spacing: 0;
  color: var(--fact-quiet);
  /* No margin: the newline between the figure and the unit in the template
     already renders one space, in the parent's display font. Adding margin
     on top of it spaced them twice. */
  margin-left: 0;
}

/* The rule under each figure draws itself on reveal and runs out across the
   cell on hover. It is black rather than red now: a red rule on a red band
   is invisible, and black ties the band back to the rest of the site.
   Kept thin and close, so it costs the band almost no height. */
.fact-rule {
  display: block;
  height: 2px;
  width: 1.75rem;
  margin-top: 0.5rem;
  background: var(--ink);
  border-radius: 2px;
}

/* --------------------------------------------------------------------------
   9. Category cards
   -------------------------------------------------------------------------- */

.cards { display: grid; gap: var(--space-m); }
@media (min-width: 38rem) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 62rem) { .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 82rem) { .cards-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.card {
  display: flex; flex-direction: column;
  background: var(--white);
  border: var(--hairline) solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  isolation: isolate;
  text-decoration: none;
}
.card:focus-within { border-color: var(--ink); }

.card-media { position: relative; }
.card-media .ph, .card-media .media { border: 0; border-radius: 0; }

/* The body sits above the wash; the picture and the border sit under it. */
.card-body { position: relative; z-index: 1; display: flex; flex-direction: column; gap: var(--space-2xs); padding: var(--space-m); flex: 1; }
.card-body h3 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-1); font-weight: 600; letter-spacing: -0.02em; line-height: var(--lh-snug); }
.card-body h3 a { text-decoration: none; }
.card-body h3 a::after { content: ''; position: absolute; inset: 0; }
.card-body p { font-size: var(--step--1); color: var(--ink-60); }

.card-spec {
  margin-top: auto; padding-top: var(--space-s);
  border-top: var(--hairline) solid var(--line);
  font-size: var(--step--2); color: var(--ink-60);
  display: flex; justify-content: space-between; gap: var(--space-s);
}
.card-spec b { font-weight: 600; color: var(--ink); }

.sport-hero { position: relative; display: grid; align-items: end; min-height: clamp(20rem, 46vh, 30rem); background-color: var(--ink); color: var(--white); overflow: hidden; }
.sport-hero > .ph, .sport-hero > .media { position: absolute; inset: 0; height: 100%; border: 0; border-radius: 0; }

/* The real photograph, now that every sport has one. Square source cropped
   to a wide hero, anchored high so heads are not cut off. */
.sport-hero-media {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% 32%;
}
.sport-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,0.88) 0%, rgba(0,0,0,0.55) 45%, rgba(0,0,0,0.2) 100%); }
.sport-hero-inner { position: relative; z-index: 1; padding-block: clamp(2rem, 4vw, 3.5rem); }
.sport-hero h1 { margin-bottom: var(--space-s); }
.sport-hero .lede { color: rgba(255,255,255,0.86); margin-bottom: var(--space-l); }
.sport-hero .breadcrumb { color: rgba(255,255,255,0.7); }
.sport-hero .breadcrumb span { color: rgba(255,255,255,0.45); }

/* --------------------------------------------------------------------------
   9b. Sport tiles
   -------------------------------------------------------------------------- */

/*
 * Four across on desktop, so twelve sports read as three even rows.
 *
 * The tile IS the photograph: square, edge to edge, nothing beside it. At
 * rest it shows only the sport's name over the picture. Bringing a pointer
 * to a tile opens the kit list and the call to action over the image, so the
 * grid stays calm until someone is actually looking at one of them.
 *
 * Everything sits in one stacking context on top of the picture, painted in
 * document order:
 *   .sport-media    the photograph, absolutely filling the tile
 *   .sport-veil     the gradient that keeps white type legible on any image
 *   .wash           the red flood, above both, below the words
 *   .sport-content  the name, and the panel that opens under it (z-index 1)
 */

.sports { display: grid; gap: var(--space-s); grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 40rem) { .sports { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-m); } }
@media (min-width: 62rem) { .sports { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.sport {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  isolation: isolate;
  background: var(--ink);
  text-decoration: none;
  color: var(--white);
}

.sport-media { position: absolute; inset: 0; overflow: hidden; background: var(--paper-2); }
.sport-media .ph, .sport-media .media {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0; border-radius: 0;
}
.sport-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Without this, white type on a pale photograph is a gamble. */
.sport-veil {
  position: absolute; inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.88) 0%,
    rgba(0, 0, 0, 0.55) 30%,
    rgba(0, 0, 0, 0.12) 62%,
    rgba(0, 0, 0, 0.3) 100%
  );
}

.sport-content {
  position: absolute; inset-inline: 0; bottom: 0; z-index: 1;
  padding: var(--space-m);
}

.sport-name {
  display: block;
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  font-size: var(--step-2);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1.05;
  color: var(--white);
}

/* The panel. Collapsed by rows rather than by height, so it opens to whatever
   the content actually measures without anything being hard-coded. */
.sport-detail {
  display: grid;
  grid-template-rows: 0fr;
}
.sport-detail-inner { overflow: hidden; min-height: 0; }

.sport-kit {
  display: flex; flex-wrap: wrap; gap: 0.3rem;
  padding-top: var(--space-s);
}
/*
 * Red chips on the black wash.
 *
 * These began as white at 10% over the photograph, so their contrast was
 * whatever the picture behind them happened to be. A solid fill fixed that.
 * The colour then has to follow the wash, because the chips are only ever
 * visible while it is up: against a red wash they had to be black, and now
 * the wash is black they go back to red, which puts the accent into the
 * open state. White on red is 5.9:1.
 */
.sport-kit li {
  font-size: var(--step--1);
  font-weight: 500;
  line-height: 1.25;
  padding: 0.25rem 0.55rem;
  border: 0;
  border-radius: var(--radius);
  background: var(--red);
  color: var(--white);
}

/* Underlined in red for the same reason the chips are red: it only ever
   shows while the black wash is up. */
.sport-go {
  display: inline-block;
  margin-top: var(--space-s);
  font-size: var(--step--1);
  font-weight: 600;
  padding-bottom: 2px;
  border-bottom: 2px solid var(--red);
}

/* A red rule seals the bottom edge of the tile on hover. */
.sport::after {
  content: '';
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  height: 4px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
}

/* --------------------------------------------------------------------------
   10. Trust
   -------------------------------------------------------------------------- */

/*
 * Four claims, each closing on a fact. The items stretch to equal height and
 * the fact line is pushed to the bottom with margin-top:auto, so the four
 * facts sit on one line across the row however long the copy above them runs.
 * That alignment is what makes the block read as evidence rather than as four
 * paragraphs that happen to be side by side.
 */

.trust-points { display: grid; gap: var(--space-l); align-items: stretch; }
@media (min-width: 40rem) { .trust-points { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-l) var(--space-xl); } }
@media (min-width: 66rem) { .trust-points { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.trust-item {
  position: relative;
  display: flex;
  flex-direction: column;
  padding-top: var(--space-m);
  border-top: var(--hairline) solid var(--line);
}

/* The red index rule, drawn in on scroll and run out on hover. */
.trust-item::before {
  content: '';
  position: absolute; top: -1px; left: 0;
  width: 2.75rem; height: 3px;
  background: var(--red);
  transform-origin: left;
}

.trust-item h3 {
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  font-size: var(--step-1);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1.15;
  margin-bottom: var(--space-2xs);
}

.trust-item p { font-size: var(--step--1); color: var(--ink-60); }

.trust-fact {
  margin-top: auto;
  padding-top: var(--space-s);
  font-size: var(--step--2);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.01em;
}
.trust-fact::before {
  content: '';
  display: block;
  width: 100%; height: var(--hairline);
  background: var(--line);
  margin-bottom: var(--space-s);
}

/* On black */
.on-ink .trust-item { border-top-color: var(--dark-line); }
.on-ink .trust-item p { color: var(--on-dark-60); }
.on-ink .trust-fact { color: var(--white); }
.on-ink .trust-fact::before { background: var(--dark-line); }

/* The logo strip gets a label, so a row of marks reads as a claim someone is
   making rather than as decoration that failed to load. */
.logo-strip { margin-top: var(--space-2xl); }

.logo-strip-label {
  font-size: var(--step--2);
  color: var(--ink-60);
  margin-bottom: var(--space-m);
}
.on-ink .logo-strip-label { color: var(--on-dark-60); }

/* --------------------------------------------------------------------------
   11. How it works - a real sequence, so it is genuinely numbered
   -------------------------------------------------------------------------- */

/*
 * Each stage is photographed, with its number set into the bottom corner of
 * the picture and a red rule opening the text beneath it.
 *
 * Numbering is legitimate here: this genuinely is a sequence, brief through
 * to shipping, and the order is the information.
 */

.process { display: grid; gap: var(--space-xl) var(--space-m); align-items: stretch; }
@media (min-width: 46rem) { .process { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 68rem) { .process { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.step { position: relative; display: flex; flex-direction: column; }

.step-media {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  margin-bottom: var(--space-m);
}
.step-media .ph, .step-media .media { border: 0; border-radius: 0; }
.step-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Keeps the number readable whatever the photograph turns out to be. */
.step-media::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.18) 34%, transparent 62%);
}

.step-num {
  position: absolute; left: var(--space-s); bottom: 0.35rem; z-index: 1;
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 900;
  font-size: var(--step-5);
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--white);
}

.step-body {
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 1;
  border-top: 2px solid var(--line);
  padding-top: var(--space-m);
}

/* The red mark that opens each stage. Drawn in as the step scrolls up. */
.step-body::after {
  content: '';
  position: absolute; top: -2px; left: 0;
  width: 3rem; height: 2px;
  background: var(--red);
  transform-origin: left;
}

.step h3 {
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  font-size: var(--step-1);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1.15;
  margin-bottom: var(--space-2xs);
}

.step p { font-size: var(--step--1); color: var(--ink-60); }

/* Pushed to the bottom, so all six lead times sit on one line across a row
   however long the copy above them runs. Same device as the trust facts. */
.step .step-time {
  display: block;
  margin-top: auto;
  padding-top: var(--space-s);
  font-size: var(--step--2);
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.01em;
}
.step .step-time::before {
  content: '';
  display: block;
  width: 100%; height: var(--hairline);
  background: var(--line);
  margin-bottom: var(--space-s);
}

/* On black. The rule moved onto .step-body when the photographs went in, so
   the dark override has to follow it. */
.on-ink .step-body { border-top-color: var(--dark-line); }
.on-ink .step p { color: var(--on-dark-60); }
.on-ink .step .step-time { color: var(--white); }
.on-ink .step .step-time::before { background: var(--dark-line); }

/* --------------------------------------------------------------------------
   11b. Supporting page components
   Used by the fabrics, FAQ, size guide, terms and sport pages.
   -------------------------------------------------------------------------- */

/* A closing line under a section, linking on to the page that owns the
   subject in full. */
.section-aside {
  margin-top: var(--space-l);
  padding-top: var(--space-m);
  border-top: var(--hairline) solid var(--line);
  font-size: var(--step--1);
  color: var(--ink-60);
  max-width: 52rem;
}
.section-aside a { color: var(--ink); transition: color var(--dur-fast) var(--ease); }
.section-aside a:hover { color: var(--red); }
.on-ink .section-aside { border-top-color: var(--dark-line); color: var(--on-dark-60); }
.on-ink .section-aside a { color: var(--white); }
.on-ink .section-aside a:hover { color: var(--red); }

/* One decoration method, set out in full on /capabilities/. A rule on the left
   rather than a card: six cards in a column would read as a repeat of the six
   summary cards higher up the same page. */
.method-detail {
  border-left: 3px solid var(--line);
  padding-left: clamp(1rem, 0.4rem + 2vw, 2rem);
  max-width: 60rem;
  /* Deep links arrive here from the sport pages, and the header is sticky. */
  scroll-margin-top: 7rem;
}
.method-detail + .method-detail { margin-top: var(--space-2xl); }
.method-detail:hover { border-left-color: var(--red); }
.method-detail { transition: border-color var(--dur) var(--ease-out); }

.method-detail h3 {
  font-family: var(--font-display);
  font-stretch: var(--wd-normal);
  font-size: var(--step-2);
  font-weight: 700;
  letter-spacing: -0.005em;
}
.method-lead { margin-top: var(--space-xs); max-width: var(--measure); }

.method-specs { margin-top: var(--space-m); }
.method-spec {
  display: grid;
  grid-template-columns: 11rem 1fr;
  gap: var(--space-m);
  padding-block: var(--space-xs);
  border-top: var(--hairline) solid var(--line);
}
.method-spec dt { font-size: var(--step--1); font-weight: 600; color: var(--ink-60); }
.method-spec dd { margin: 0; font-size: var(--step--1); }

.method-sports { margin-top: var(--space-m); font-size: var(--step--1); color: var(--ink-60); }
.method-sports a { color: var(--ink); transition: color var(--dur-fast) var(--ease); }
.method-sports a:hover { color: var(--red); }

@media (max-width: 40rem) {
  .method-spec { grid-template-columns: 1fr; gap: var(--space-3xs); }
}

/* A subject heading plus its questions, on the FAQ and terms pages. */
.faq-group + .faq-group { margin-top: var(--space-2xl); }
.faq-group .section-head { margin-bottom: var(--space-m); }

/* The fabric library: a colour chip beside its specification. */
.fabric-row {
  display: grid;
  gap: var(--space-m);
  align-items: start;
  padding-bottom: var(--space-l);
  border-bottom: var(--hairline) solid var(--line);
}
@media (min-width: 48rem) {
  .fabric-row { grid-template-columns: 12rem minmax(0, 1fr); gap: var(--space-xl); }
}

.fabric-chip {
  position: relative;
  aspect-ratio: 3 / 2;
  border-radius: var(--radius-lg);
  border: var(--hairline) solid var(--line);
  overflow: hidden;
}
/* The same woven texture the home page swatches use, so a fabric reads as
   fabric rather than as a flat colour block. */
.fabric-chip::after {
  content: '';
  position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.10) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.07) 0 1px, transparent 1px 3px);
}

.fabric-detail h3 {
  font-family: var(--font-display);
  font-stretch: var(--wd-tight);
  font-weight: 800;
  font-size: var(--step-2);
  text-transform: uppercase;
  letter-spacing: 0.015em;
  line-height: 1.1;
  margin-bottom: var(--space-2xs);
}
.fabric-detail > p { font-size: var(--step-0); color: var(--ink-60); max-width: 54ch; }

.fabric-specs {
  display: grid;
  gap: var(--space-2xs) var(--space-l);
  margin-top: var(--space-m);
}
@media (min-width: 34rem) {
  .fabric-specs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.fabric-specs > div { border-top: 2px solid var(--ink); padding-top: var(--space-2xs); }
.fabric-specs dt { font-size: var(--step--2); color: var(--ink-60); }
.fabric-specs dd { margin: 0; font-size: var(--step--1); font-weight: 600; }

.fabric-uses { margin-top: var(--space-m); font-size: var(--step--1); color: var(--ink-60); }
.fabric-uses a { color: var(--ink); text-decoration: underline; text-underline-offset: 0.18em; }
.fabric-uses a:hover { color: var(--red); }

/* --------------------------------------------------------------------------
   12. Fabric swatches
   -------------------------------------------------------------------------- */

.swatches { display: grid; gap: var(--space-m); }
@media (min-width: 38rem) { .swatches { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 62rem) { .swatches { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 82rem) { .swatches { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.swatch { background: var(--white); border: var(--hairline) solid var(--line); border-radius: var(--radius-lg); overflow: hidden; isolation: isolate; }
.swatch-chip {
  aspect-ratio: 3 / 2;
  position: relative;
  border-bottom: var(--hairline) solid var(--line);
}
/* A woven texture drawn in CSS, so a swatch reads as fabric before any
   photography exists. The chip colour comes from an inline custom property. */
.swatch-chip::after {
  content: '';
  position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(90deg, rgba(255,255,255,0.10) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(0deg, rgba(0,0,0,0.07) 0 1px, transparent 1px 3px);
}
/* Positioned so it paints above the wash, which is absolutely placed and
   would otherwise cover it. */
.swatch-body { position: relative; z-index: 1; padding: var(--space-m); }
.swatch-body h3 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-0); font-weight: 600; letter-spacing: -0.005em; margin-bottom: var(--space-2xs); }
.swatch-body > p { font-size: var(--step--2); color: var(--ink-60); margin-bottom: var(--space-s); }
.swatch-spec { display: flex; justify-content: space-between; gap: var(--space-s); font-size: var(--step--2); padding-block: 0.4rem; border-top: var(--hairline) dotted var(--line-strong); }
.swatch-spec dt { color: var(--ink-60); }
.swatch-spec dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }

/* --------------------------------------------------------------------------
   13. Decoration methods
   -------------------------------------------------------------------------- */

.methods { display: grid; gap: var(--space-m); }
@media (min-width: 38rem) { .methods { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 62rem) { .methods { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.method { background: var(--white); border: var(--hairline) solid var(--line); border-radius: var(--radius-lg); overflow: hidden; isolation: isolate; display: flex; flex-direction: column; }
/* Positioned so it paints above the wash. */
.method-body { position: relative; z-index: 1; padding: var(--space-m); display: flex; flex-direction: column; gap: var(--space-2xs); flex: 1; }
.method-body h3 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-1); font-weight: 600; letter-spacing: -0.005em; }
.method-body p { font-size: var(--step--1); color: var(--ink-60); }
.method-note { margin-top: auto; padding-top: var(--space-s); border-top: var(--hairline) solid var(--line); font-size: var(--step--2); font-weight: 600; color: var(--red); }

/* --------------------------------------------------------------------------
   14. Sizing
   -------------------------------------------------------------------------- */

.table-scroll { overflow-x: auto; border: var(--hairline) solid var(--line); border-radius: var(--radius-lg); background: var(--white); }
.size-table { width: 100%; border-collapse: collapse; min-width: 40rem; }
.size-table caption { text-align: left; padding: var(--space-m) var(--space-m) 0; font-size: var(--step--1); color: var(--ink-60); }
.size-table th, .size-table td { padding: 0.85rem var(--space-m); text-align: left; font-size: var(--step--1); border-bottom: var(--hairline) solid var(--line); }
.size-table thead th { font-family: var(--font-display); font-stretch: var(--wd-normal); font-weight: 600; font-size: var(--step--1); border-bottom: 2px solid var(--ink); white-space: nowrap; }
.size-table tbody th { font-weight: 600; }
.size-table tbody tr:nth-child(even) { background: var(--paper); }
.size-table tbody tr:last-child td, .size-table tbody tr:last-child th { border-bottom: 0; }
.size-table td { font-variant-numeric: tabular-nums; color: var(--ink-60); }

.sizing-notes { display: grid; gap: var(--space-m); margin-top: var(--space-l); }
@media (min-width: 52rem) { .sizing-notes { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.sizing-note h3 { font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-0); font-weight: 600; margin-bottom: var(--space-3xs); }
.sizing-note p { font-size: var(--step--1); color: var(--ink-60); }

/* --------------------------------------------------------------------------
   15. Capacity figures
   -------------------------------------------------------------------------- */

.figures { display: grid; gap: var(--space-l); }
@media (min-width: 38rem) { .figures { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 66rem) { .figures { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.figure-item { border-top: 2px solid var(--red); padding-top: var(--space-s); }
.figure-value {
  display: block;
  font-family: var(--font-display); font-stretch: var(--wd-tight); font-weight: 900;
  font-size: var(--step-5); line-height: 1; letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
  margin-bottom: var(--space-2xs);
}
.figure-label { font-size: var(--step--1); color: var(--ink-60); }
.on-ink .figure-label { color: var(--on-dark-60); }

/* --------------------------------------------------------------------------
   16. Portfolio gallery
   -------------------------------------------------------------------------- */

.gallery { display: grid; gap: var(--space-2xs); grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 48rem) { .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-s); } }
@media (min-width: 70rem) { .gallery { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.gallery-item { position: relative; overflow: hidden; isolation: isolate; border-radius: var(--radius-lg); }
.gallery-item .ph, .gallery-item .media { height: 100%; border-radius: 0; }
.gallery-caption { position: relative; z-index: 1; }

/* One tile leads, so the grid is not a wall of identical squares. */
@media (min-width: 48rem) {
  .gallery-item-lead { grid-column: span 2; grid-row: span 2; }
}

.gallery-caption {
  position: absolute; inset-inline: 0; bottom: 0;
  padding: var(--space-s);
  font-size: var(--step--2); color: var(--white);
  background: linear-gradient(to top, rgba(0,0,0,0.78), transparent);
}

/* --------------------------------------------------------------------------
   17. FAQ - native details/summary, so it works without JavaScript
   -------------------------------------------------------------------------- */

.faq { max-width: 58rem; border-top: var(--hairline) solid var(--line); }
.faq-item { border-bottom: var(--hairline) solid var(--line); }

.faq-item summary {
  display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-m);
  padding-block: var(--space-m);
  cursor: pointer; list-style: none;
  font-family: var(--font-display); font-stretch: var(--wd-normal); font-size: var(--step-1); font-weight: 600;
  letter-spacing: -0.005em; line-height: var(--lh-snug);
  transition: color 150ms var(--ease);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--red); }
.faq-item summary::after {
  content: '+';
  font-family: var(--font-text); font-weight: 400;
  font-size: var(--step-2); line-height: 1; color: var(--red);
  flex: none; transition: transform 200ms var(--ease);
}

.faq-answer { padding-bottom: var(--space-m); max-width: 62ch; color: var(--ink-60); font-size: var(--step-0); }
.faq-answer > * + * { margin-top: var(--space-s); }
.faq-answer a { color: var(--ink); text-decoration: underline; }
.faq-answer a:hover { color: var(--red); }

/* --------------------------------------------------------------------------
   18. Forms
   -------------------------------------------------------------------------- */

.form-grid { display: grid; gap: var(--space-m); }
@media (min-width: 44rem) { .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.field-wide { grid-column: 1 / -1; }

/* The privacy line under the submit button. Quiet, but not hidden: it sits
   where the decision to send is actually made. */
.form-legal {
  font-size: var(--step--2);
  color: var(--ink-60);
  max-width: 44rem;
  margin-top: calc(var(--space-s) * -1);
}
.form-legal a { color: var(--ink); transition: color var(--dur-fast) var(--ease); }
.form-legal a:hover { color: var(--red); }

.field { display: flex; flex-direction: column; gap: var(--space-3xs); }
.field label, .field legend { font-size: var(--step--1); font-weight: 500; }
.field .hint { font-size: var(--step--2); color: var(--ink-60); }
.field .req { color: var(--red); }

.field input, .field select, .field textarea {
  font-family: var(--font-text); font-size: var(--step-0);
  color: var(--ink); background: var(--white);
  border: var(--hairline) solid var(--line-strong);
  border-radius: var(--radius);
  padding: 0.75em 0.9em; width: 100%;
  transition: border-color 150ms var(--ease), box-shadow 150ms var(--ease);
}
.field textarea { min-height: 9.5rem; resize: vertical; line-height: 1.55; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--ink-40); }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06); }
.field input[type='file'] { padding: 0.6em; background: var(--paper); border-style: dashed; }

/* --------------------------------------------------------------------------
   Artwork upload

   The browser's own file input is the most generic control on the form, and
   this is the field that decides whether a quote can be costed at all, so it
   is worth the surface area.

   Without JS the native input above is what you get. Everything below is
   gated on .js, because a drop zone that cannot report which file you picked
   is worse than the plain control.
   -------------------------------------------------------------------------- */

.filefield-drop { display: none; }

.js .filefield-input {
  /* Clipped, not hidden: it must stay in the tab order and stay the control
     the label points at. display:none would remove both. */
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.js .filefield-drop {
  display: flex;
  align-items: center;
  gap: var(--space-m);
  padding: var(--space-m) var(--space-l);
  background: var(--paper);
  border: 2px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  cursor: pointer;
  position: relative;
  isolation: isolate;
  transition:
    border-color var(--dur) var(--ease-out),
    background-color var(--dur) var(--ease-out),
    transform var(--dur) var(--ease-out);
}

.js .filefield-drop:hover { border-color: var(--ink-40); background: var(--white); }

/* The drop surface is aria-hidden, so the hint stays as the input's described-by
   text. With JS on it would be the same sentence printed twice, so it is
   clipped rather than removed. */
.js .filefield .hint {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Dragging a file over it, and keyboard focus on the real input, are the same
   state as far as the eye is concerned. */
.js .filefield-input:focus-visible ~ .filefield-drop,
.js .filefield.is-dragging .filefield-drop {
  border-color: var(--red);
  border-style: solid;
  background: var(--red-wash);
}
.js .filefield.is-dragging .filefield-drop { transform: scale(1.01); }

.filefield-copy { display: flex; flex-direction: column; gap: 0.15rem; min-width: 0; }
.filefield-prompt { font-size: var(--step-0); font-weight: 600; }
.filefield-formats { font-size: var(--step--2); color: var(--ink-60); max-width: 46ch; }

/* A registration mark, not a cloud. It is what the floor actually aligns
   artwork to, and it is the one thing on this form that could only belong to
   a printer. The brackets open out when a file is dragged over. */
.filefield-mark {
  position: relative;
  flex: none;
  width: 3rem;
  height: 3rem;
  background:
    linear-gradient(var(--ink-40) 0 0) center / 2px 1rem no-repeat,
    linear-gradient(var(--ink-40) 0 0) center / 1rem 2px no-repeat;
  transition: background-size var(--dur) var(--ease-out);
}
.filefield-mark::before,
.filefield-mark::after {
  content: '';
  position: absolute;
  width: 0.9rem;
  height: 0.9rem;
  border: 2px solid var(--red);
  transition: inset var(--dur) var(--ease-out), width var(--dur) var(--ease-out), height var(--dur) var(--ease-out);
}
.filefield-mark::before { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.filefield-mark::after { bottom: 0; right: 0; border-left: 0; border-top: 0; }

.js .filefield-drop:hover .filefield-mark::before,
.js .filefield.is-dragging .filefield-mark::before { width: 1.25rem; height: 1.25rem; }
.js .filefield-drop:hover .filefield-mark::after,
.js .filefield.is-dragging .filefield-mark::after { width: 1.25rem; height: 1.25rem; }

/* The chosen file, once there is one. */
.filefield-chosen {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-m);
  margin-top: var(--space-2xs);
  padding: var(--space-xs) var(--space-s);
  background: var(--white);
  border: var(--hairline) solid var(--line-strong);
  border-left: 3px solid var(--red);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.filefield-chosen[hidden] { display: none; }

.filefield-file { display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.filefield-name {
  font-size: var(--step--1);
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.filefield-size { font-size: var(--step--2); color: var(--ink-60); font-variant-numeric: tabular-nums; }

.filefield-clear {
  flex: none;
  font-family: var(--font-text);
  font-size: var(--step--2);
  color: var(--ink-60);
  background: none;
  border: 0;
  padding: 0.35rem 0.1rem;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.18em;
  transition: color var(--dur-fast) var(--ease);
}
.filefield-clear:hover { color: var(--red); }

/* An oversized file, caught before the upload is attempted. */
.filefield.is-toobig .filefield-chosen { border-left-color: var(--red); background: var(--red-wash); }
.filefield-error { font-size: var(--step--2); color: var(--red); margin-top: var(--space-3xs); }

@media (max-width: 34rem) {
  .js .filefield-drop { flex-direction: column; align-items: flex-start; gap: var(--space-s); padding: var(--space-m); }
}

.check-grid { display: grid; gap: var(--space-2xs); grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); }
.check { display: flex; align-items: flex-start; gap: 0.55rem; font-size: var(--step--1); cursor: pointer; }
.check input { width: 1.05rem; height: 1.05rem; margin-top: 0.22rem; accent-color: var(--red); flex: none; }

.form-notice { padding: var(--space-m); border-left: 3px solid var(--red); background: var(--red-wash); font-size: var(--step--1); margin-bottom: var(--space-l); border-radius: 0 var(--radius) var(--radius) 0; }
.form-notice-ok { border-left-color: var(--ok); background: var(--ok-wash); }

.form-errors { margin-bottom: var(--space-l); padding: var(--space-m); border-left: 3px solid var(--red); background: var(--red-wash); border-radius: 0 var(--radius) var(--radius) 0; }
.form-errors li { font-size: var(--step--1); }
.form-errors li + li { margin-top: var(--space-3xs); }

.form-panel { background: var(--white); border: var(--hairline) solid var(--line); border-radius: var(--radius-lg); padding: clamp(1.25rem, 0.5rem + 2.5vw, 2.5rem); }

/* --------------------------------------------------------------------------
   19. Inner pages, listings, 404
   -------------------------------------------------------------------------- */

.page-hero { border-bottom: var(--hairline) solid var(--line); padding-block: clamp(2.5rem, 1.5rem + 4vw, 4.5rem); }
.page-hero h1 { margin-bottom: var(--space-s); }
.page-hero .lede { margin-bottom: 0; }

.breadcrumb { font-size: var(--step--2); color: var(--ink-60); margin-bottom: var(--space-m); }
.breadcrumb a { text-decoration: none; }
.breadcrumb a:hover { color: var(--red); text-decoration: underline; }
.breadcrumb span { color: var(--ink-40); padding-inline: 0.4rem; }

.index-list { border-top: var(--hairline) solid var(--line); }
.index-row { display: grid; gap: var(--space-2xs) var(--space-m); padding-block: var(--space-m); border-bottom: var(--hairline) solid var(--line); align-items: baseline; }
@media (min-width: 48rem) { .index-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) auto; } }
.index-name { font-family: var(--font-display); font-stretch: var(--wd-normal); font-weight: 600; font-size: var(--step-2); letter-spacing: -0.005em; line-height: var(--lh-snug); }
.index-desc { font-size: var(--step--1); color: var(--ink-60); max-width: 44ch; }
.index-spec { font-size: var(--step--2); color: var(--ink-60); white-space: nowrap; }

.error-404 { padding-block: var(--space-3xl); }

.wp-caption, figure.wp-block-image { margin-block: var(--space-l); }
.wp-caption-text, figcaption { font-size: var(--step--2); color: var(--ink-60); margin-top: var(--space-2xs); }
.alignleft { float: left; margin: 0 var(--space-m) var(--space-s) 0; }
.alignright { float: right; margin: 0 0 var(--space-s) var(--space-m); }
.aligncenter { margin-inline: auto; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
