/* Topsheet on the website: the /shop/ page only (owner, 2026-10-14: the game's UI moved to Topsheet; the shop and the
   leaderboards follow, the rest of the site keeps its look, the header and footer stay as they are).
   Loaded on /shop/ alone (templates.mjs layout) and scoped under .page-shop, so no other page can change with it.

   The source is the game (f-int, read-only): src/ui/kit/tokens.js TOPSHEET (the palette below, the same values),
   src/ui/kit/topsheet.js (Archivo Expanded Black Italic for the shouting, Nunito for what you read twice, one
   yellow block on the lean for the one thing to press, die-cut stickers) and src/ui/kitWall.js (the hero and the
   wall of boards). Where kitWall.js writes "12u" (the menu unit) the hero here writes calc(var(--hu) * 12): the
   hero's width over the mock's 790, so the hero keeps the game's proportions at any size.

   Never a backtick in this file: the markup it styles is built in template literals (AGENTS.md). */

@font-face { font-family: 'Archivo'; font-style: italic; font-weight: 700 900; font-stretch: 100% 125%; font-display: swap;
  src: url('/fonts/archivo-latin-italic-variable.woff2') format('woff2'); }

.page-shop {
  --ts-ink: #15141b; --ts-ink2: #24232c; --ts-paper: #ffffff; --ts-paper-lip: #9a96a3; --ts-off: #f3f0ea; --ts-muted: #5f5c68;
  --ts-y: #f2a93b; --ts-y-hi: #ffbb4d; --ts-ylip: #b9761c; --ts-coral: #ff6a4d; --ts-cobalt: #3557ff; --ts-sky: #a9d8ff;
  --ts-navy: #14215a; --ts-fgold: #e2ad3f; --ts-own: #5cc26a; --ts-discord: #5865f2; --ts-discord-lip: #3c45a5;
  --ts-lean: -10deg;
  --ts-face: 'Archivo', var(--display);
  --ts-w: min(1400px, 100vw - 2 * var(--gutter));
  background: var(--ts-ink);
}
.page-shop .ts-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.page-shop .ts-i { width: 1em; height: 1em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.page-shop .ts-wrap { width: var(--ts-w); margin-inline: auto; }

/* The display face, as the game sets it: italic, black, expanded, upper case. */
.page-shop :is(.ts-title, .ts-h2, .ts-name, .ts-label, .ts-tabs a, .ts-tag, .ts-chips, .ts-price, .ts-btn, .ts-vn b, .ts-pp, .ts-steps h3, .ts-no, .ts-swatches li) {
  font-family: var(--ts-face); font-style: italic; text-transform: uppercase; }
.page-shop .ts-label { margin: 0 0 10px; font-weight: 800; font-size: 13px; line-height: 1; font-stretch: 112%; letter-spacing: .08em; color: var(--ts-y); }
.page-shop .ts-h2 { margin: 0; font-weight: 900; font-size: clamp(30px, 3.4vw, 48px); line-height: .95; font-stretch: 125%; letter-spacing: -.01em; color: #fff; }

/* ---------- The store: ink, with one wide plane on the lean behind the wall ---------- */
.page-shop .ts-store { position: relative; overflow: clip; padding: clamp(100px, 8.5vw, 124px) 0 clamp(44px, 5vw, 72px); color: #fff;
  background: linear-gradient(170deg, transparent 0 58%, var(--ts-ink2) 58% 74%, transparent 74%), var(--ts-ink); }
.page-shop .ts-head { display: grid; grid-template-columns: auto auto 1fr; align-items: end; gap: 18px 34px; margin-bottom: 26px; }
.page-shop .ts-title { margin: 0; font-weight: 900; font-size: clamp(44px, 4.8vw, 72px); line-height: .88; font-stretch: 125%; letter-spacing: -.015em; color: #fff; text-shadow: 3px 4px 0 rgba(0,0,0,.35); }
.page-shop .ts-lead { justify-self: end; max-width: 30ch; margin: 0; text-align: right; font-weight: 800; font-size: 15px; line-height: 1.35; color: rgba(255,255,255,.8); }
.page-shop .ts-phone { margin: -8px 0 18px; font-size: 15px; font-weight: 700; color: rgba(255,255,255,.8); }

/* The page's tabs: outlined chips on the lean, the one you are on filled yellow (topsheet.js k-seg). */
.page-shop .ts-tabs { display: flex; flex-wrap: wrap; gap: 10px; padding: 0 5px 4px; }
.page-shop .ts-tabs a { position: relative; isolation: isolate; display: inline-flex; align-items: center; height: 36px; padding: 0 16px; color: #fff; text-decoration: none;
  font-weight: 800; font-size: 13px; line-height: 1; font-stretch: 112%; letter-spacing: .03em; white-space: nowrap; }
.page-shop .ts-tabs a::before { content: ''; position: absolute; inset: 0; z-index: -1; border-radius: 3px; transform: skewX(var(--ts-lean)); box-shadow: inset 0 0 0 2px rgba(255,255,255,.5); transition: background .15s, box-shadow .15s; }
.page-shop .ts-tabs a:hover::before { background: rgba(255,255,255,.08); box-shadow: inset 0 0 0 2px #fff; }
.page-shop .ts-tabs a.is-on { color: var(--ts-ink); }
.page-shop .ts-tabs a.is-on::before { background: var(--ts-y); box-shadow: none; }
.page-shop .ts-tabs a:focus-visible { outline: none; }
.page-shop .ts-tabs a:focus-visible::before { box-shadow: inset 0 0 0 2px #fff, 0 0 0 3px var(--ts-y); }

/* ---------- The hero: one colour plane per kit, the rider over his name, outlined huge behind him ---------- */
.page-shop .ts-hero { position: relative; overflow: hidden; border-radius: 16px; background: var(--kp); color: #fff; isolation: isolate; box-shadow: 0 10px 30px rgba(0,0,0,.35); scroll-margin-top: 90px; }
.page-shop .ts-plane { position: relative; overflow: hidden; }
.page-shop .ts-ghost { position: absolute; left: -1.2cqw; top: 2.5cqh; z-index: 0; display: flex; flex-direction: column; pointer-events: none;
  font: italic 900 23cqh / .84 var(--ts-face); font-stretch: 125%; text-transform: uppercase; letter-spacing: -.02em; white-space: nowrap;
  color: transparent; -webkit-text-stroke: max(1.5px, .45cqh) rgba(255,255,255,.2); }
/* Two bands on the lean: the kit's accent, then its second colour, like a topsheet graphic. */
.page-shop :is(.ts-stripe, .ts-stripe2) { position: absolute; left: -12%; right: -12%; z-index: 0; transform: rotate(-10deg); }
.page-shop .ts-stripe { top: 69%; height: 21%; background: var(--ks); }
.page-shop .ts-stripe2 { top: 93%; height: 3.8%; background: var(--ks2); }
/* The cut-out frames the rider between 6% and 76% of its height (the game's kitWall.js note): at 110% of the plane
   from -3% he flies from 4% to 81%, over his name. Centred on 37% of the plane's width: the game's 46% put his
   outstretched pole hand under the facts column on the wider web hero. */
.page-shop .ts-art { position: absolute; z-index: 1; top: -3cqh; left: calc(37cqw - 44cqh); height: 110cqh; width: auto; max-width: none; pointer-events: none; user-select: none;
  filter: drop-shadow(0 10px 18px rgba(0,0,0,.45)); }

/* Stickers: a die-cut white edge, a little tilt, a hard printed shadow. */
.page-shop .ts-tag { display: inline-flex; align-items: center; padding: 8px 14px 7px; border-radius: 8px; transform: rotate(2.5deg);
  background: var(--kt); color: var(--ts-ink); box-shadow: 0 0 0 2.5px #fff, 3px 4px 0 2.5px rgba(0,0,0,.3);
  font-weight: 800; font-size: 13px; line-height: 1; font-stretch: 112%; letter-spacing: .02em; white-space: nowrap; }
#founding-rider .ts-tag { color: var(--ts-navy); }
/* The price on a tilted white sheet. */
.page-shop .ts-price { position: absolute; z-index: 3; margin: 0; padding: 10px 18px 9px; border-radius: 12px; text-align: center; transform: rotate(7deg);
  background: #fff; color: var(--ts-ink); box-shadow: 0 0 0 3px var(--ts-ink), 5px 6px 0 3px rgba(0,0,0,.3); }
.page-shop .ts-price b { display: block; font-weight: 900; font-size: 36px; line-height: 1; font-stretch: 118%; white-space: nowrap; }
.page-shop .ts-price small { display: block; margin-top: 4px; font: 800 12px/1 var(--body); text-transform: none; color: #55525d; }
.page-shop .ts-price.t-earn { background: var(--ts-sky); }

.page-shop .ts-name { z-index: 2; margin: 0; display: flex; flex-direction: column; color: #fff; pointer-events: none;
  font-weight: 900; line-height: .9; font-stretch: 125%; letter-spacing: -.01em; text-shadow: 3px 4px 0 rgba(0,0,0,.35); white-space: nowrap; }

/* What is in it: every piece as an outlined chip on the lean, with its icon; what comes with it, one line each. */
.page-shop .ts-facts { z-index: 2; display: flex; flex-direction: column; gap: 12px; }
.page-shop .ts-line { margin: 4px 0 0; font-weight: 800; font-size: 15px; line-height: 1.38; color: rgba(255,255,255,.9); text-shadow: 0 1px 10px rgba(0,0,0,.35); }
.page-shop .ts-chips { display: flex; flex-wrap: wrap; gap: 8px 10px; margin: 2px 0 0; padding: 0 4px; }
.page-shop .ts-chips li { position: relative; isolation: isolate; display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 12px;
  font-weight: 800; font-size: 12px; line-height: 1; font-stretch: 112%; letter-spacing: .03em; white-space: nowrap; }
.page-shop .ts-chips li::before { content: ''; position: absolute; inset: 0; z-index: -1; border-radius: 3px; transform: skewX(var(--ts-lean));
  background: rgba(21,20,27,.22); box-shadow: inset 0 0 0 2px rgba(255,255,255,.55); }
.page-shop .ts-chips .ts-i { font-size: 17px; }
.page-shop .ts-extras { display: grid; gap: 6px; margin: 2px 0 0; }
.page-shop .ts-extras li { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 14px; line-height: 1.25; color: rgba(255,255,255,.86); }
.page-shop .ts-extras .ts-i { font-size: 17px; color: var(--ks); }
#park-rat .ts-extras .ts-i { color: #fff; }
/* A promise that is not live yet (Mega Park) says so on a small sky sticker, as the game's list marks it "soon". */
.page-shop .ts-soon { display: inline-block; margin-left: 2px; padding: 3px 6px 2px; border-radius: 4px; transform: rotate(-3deg);
  background: var(--ts-sky); color: var(--ts-ink); font-weight: 900; font-size: 10.5px; line-height: 1; font-stretch: 112%; letter-spacing: .04em; text-transform: uppercase; }

/* The one thing to press: the yellow block on the lean, with its darker lip (topsheet.js k-btn primary). */
.page-shop .ts-acts { z-index: 3; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.page-shop .ts-btn { position: relative; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 56px; padding: 0 28px; border: 0; background: none; cursor: pointer;
  color: var(--ts-ink); text-decoration: none; font-weight: 900; font-size: 20px; line-height: 1; font-stretch: 125%; letter-spacing: .01em; white-space: nowrap;
  transition: transform .16s cubic-bezier(.3,1.4,.5,1); }
.page-shop .ts-btn::before { content: ''; position: absolute; inset: 0; z-index: -1; border-radius: 6px; transform: skewX(var(--ts-lean)); background: var(--ts-y); box-shadow: 0 5px 0 var(--ts-ylip); transition: box-shadow .16s, background .16s; }
.page-shop .ts-btn:hover::before { background: var(--ts-y-hi); box-shadow: 0 5px 0 var(--ts-ylip), 0 0 0 3px #fff; }
.page-shop .ts-btn:active { transform: translateY(4px); }
.page-shop .ts-btn:active::before { box-shadow: 0 1px 0 var(--ts-ylip); }
.page-shop .ts-btn:focus-visible { outline: none; }
.page-shop .ts-btn:focus-visible::before { box-shadow: 0 5px 0 var(--ts-ylip), 0 0 0 3px #fff; }
/* The second action: a white outline on the same lean, a dark fill so it reads across the white stripe. */
.page-shop .ts-btn.ts-out { min-height: 46px; padding: 0 22px; font-size: 15px; color: #fff; }
.page-shop .ts-btn.ts-out::before { background: rgba(21,20,27,.55); box-shadow: inset 0 0 0 2.5px #fff; }
.page-shop .ts-btn.ts-out:hover::before, .page-shop .ts-btn.ts-out:focus-visible::before { background: rgba(255,255,255,.14); box-shadow: inset 0 0 0 2.5px #fff, 0 0 0 3px var(--ts-y); }

/* ---------- The wall of boards: round ends, the kit's colour, the rider at the top, the name up the side ---------- */
.page-shop .ts-wall ul { display: flex; gap: 9px; margin: 0; padding: 0; }
.page-shop .ts-wall li { display: flex; flex: 1 1 0; min-width: 0; }
.page-shop .ts-board { position: relative; flex: 1; display: block; min-width: 0; overflow: hidden; border-radius: 999px; container-type: size; text-decoration: none;
  background: var(--kp); color: #fff; box-shadow: inset 0 0 0 2.5px rgba(255,255,255,.18), 0 6px 16px rgba(0,0,0,.3);
  transition: transform .18s cubic-bezier(.3,1.4,.5,1), box-shadow .18s; }
.page-shop .ts-board:hover, .page-shop .ts-board:focus-visible { outline: none; transform: translateY(-8px); box-shadow: inset 0 0 0 3px #fff, 0 0 0 3px var(--ts-y), 0 12px 22px rgba(0,0,0,.4); }
/* The rider standing on skis, above where the name starts; every board at one scale, the skis on one line. */
.page-shop .ts-bart { position: absolute; top: 5.5%; left: 50%; height: 36%; width: auto; max-width: none; transform: translateX(-50%); pointer-events: none; }
.page-shop .ts-vn { position: absolute; left: 0; right: 0; top: 42%; bottom: 13%; display: flex; align-items: center; justify-content: center; }
/* The name fits the band between the art and the sticker: 43% of the board's height over its letters, 21 px at most. */
.page-shop .ts-vn b { writing-mode: vertical-rl; transform: rotate(180deg); white-space: nowrap;
  font-weight: 900; font-size: min(21px, calc(43cqh / (var(--len, 10) * .8))); line-height: 1; font-stretch: 118%; letter-spacing: .01em; }
.page-shop .ts-pp { position: absolute; left: 50%; bottom: 5%; transform: translateX(-50%) rotate(-8deg); padding: 6px 6px 5px; border-radius: 6px; white-space: nowrap;
  background: #fff; color: var(--ts-ink); box-shadow: 2px 3px 0 rgba(0,0,0,.3); font-weight: 900; font-size: 12.5px; line-height: 1; font-stretch: 100%; }
.page-shop .ts-pp small { font-size: .62em; font-stretch: 100%; margin-right: 1px; }
.page-shop .ts-pp.t-earn { background: var(--ts-sky); }

/* ---------- Wide screens: the wall beside the hero, as in the game ---------- */
@media (min-width: 1100px) {
  /* Seven boards since the 10-16 line-up: at the old .29 each board thinned to 4% of the stage and cropped its rider and
     price (owner 2026-10-15: "skis should be bigger"). .38 makes each board wider than the six-board wall was. */
  .page-shop .ts-stage { --ts-wall-w: calc(var(--ts-w) * .38);
    --ts-h: min(calc((var(--ts-w) - var(--ts-wall-w) - 20px) / 1.39), max(540px, 100svh - 250px));
    display: grid; grid-template-columns: minmax(0, 1fr) var(--ts-wall-w); gap: 20px; align-items: start; }
  .page-shop .ts-wall { grid-column: 2; grid-row: 1; position: sticky; top: 92px; height: var(--ts-h); padding-top: 4px; }
  .page-shop .ts-wall ul { height: 100%; }
  .page-shop .ts-board.is-on { transform: translateY(-8px); box-shadow: inset 0 0 0 3px #fff, 0 0 0 3.5px var(--ts-y), 0 12px 22px rgba(0,0,0,.4); }
  .page-shop .ts-heroes { grid-column: 1; grid-row: 1; display: grid; gap: 28px; }
  .page-shop .ts-hero { height: var(--ts-h); container-type: size; }
  /* Inside the hero, sizes follow the hero (the mock's 790 x 570), so it keeps its proportions at every width. */
  .page-shop .ts-hero > * { --hu: min(calc(100cqw / 790), calc(100cqh / 570)); }
  .page-shop .ts-plane { position: absolute; inset: 0; }
  /* The sticker sits low on the stripe, beside the buttons, so the longer perk lists (up to eight) clear it. */
  .page-shop .ts-price { right: calc(var(--hu) * 34); bottom: calc(var(--hu) * 100); min-width: calc(var(--hu) * 150); }
  .page-shop .ts-price b { font-size: calc(var(--hu) * 38); }
  .page-shop .ts-price.t-earn b { font-size: calc(var(--hu) * 32); }
  .page-shop .ts-name { position: absolute; left: calc(var(--hu) * 34); bottom: calc(var(--hu) * 96); font-size: calc(var(--hu) * 50); }
  .page-shop .ts-facts { position: absolute; right: calc(var(--hu) * 30); top: calc(var(--hu) * 28); width: calc(var(--hu) * 300); align-items: flex-end; text-align: right; }
  .page-shop .ts-line { font-size: max(13px, calc(var(--hu) * 14.5)); }
  .page-shop .ts-chips { justify-content: flex-end; }
  .page-shop .ts-extras li { justify-content: flex-end; font-size: max(12.5px, calc(var(--hu) * 13)); }
  /* Seven kits carry up to eight perks each (10-16 final line-up), so on the wide hero the pieces are icons on one row:
     the names stay for screen readers and on hover, and the first perk line says the count ("7-piece kit + ..."). With
     the labels shown, Patron's list ran under the price sticker at 1280 and 1440. */
  .page-shop .ts-chips { gap: calc(var(--hu) * 4); padding: 0; flex-wrap: nowrap; }
  .page-shop .ts-extras { gap: calc(var(--hu) * 5); }
  .page-shop .ts-chips li { width: calc(var(--hu) * 31); height: calc(var(--hu) * 31); padding: 0; justify-content: center; }
  .page-shop .ts-chips .ts-i { font-size: calc(var(--hu) * 18); }
  .page-shop .ts-chips .ts-cl { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .page-shop .ts-acts { position: absolute; left: calc(var(--hu) * 40); right: calc(var(--hu) * 30); bottom: calc(var(--hu) * 26); }
  .page-shop .ts-btn { min-height: calc(var(--hu) * 56); font-size: calc(var(--hu) * 20); }
  .page-shop .ts-btn.ts-out { min-height: calc(var(--hu) * 46); font-size: calc(var(--hu) * 15); }

  /* With shop-wall.js: the heroes share one spot and a board swaps them. The new hero is there at once and the old
     one fades out on top of it (the game's fadeHero, 220 ms); the stickers on the new one land with a small settle. */
  .page-shop .ts-stage.is-swap .ts-hero { grid-area: 1 / 1; opacity: 0; visibility: hidden; }
  .page-shop .ts-stage.is-swap .ts-hero.is-on { z-index: 1; opacity: 1; visibility: visible; }
  /* Only the hero a click is leaving fades (shop-wall.js marks it for the length of the fade): a resize across this
     width, or a full-page capture, shows the picked hero straight away instead of every hero fading out at once. */
  .page-shop .ts-stage.is-swap .ts-hero.is-leaving { z-index: 2; transition: opacity .22s ease-out, visibility 0s linear .22s; }
  .page-shop .ts-stage.is-swap .ts-hero.is-on :is(.ts-price, .ts-tag) { animation: ts-settle .26s .12s cubic-bezier(.3,1.4,.5,1) backwards; }
}
@keyframes ts-settle { from { opacity: 0; scale: 1.06; } }

/* ---------- Narrower: the wall is a strip of boards over the kits, each board scrolls to its kit ---------- */
@media (max-width: 1099px) {
  .page-shop .ts-head { grid-template-columns: 1fr; align-items: start; gap: 16px; }
  .page-shop .ts-lead { justify-self: start; text-align: left; }
  .page-shop .ts-wall { margin: 0 calc(var(--gutter) * -1) 22px; padding: 10px var(--gutter) 4px; overflow-x: auto; scrollbar-width: none; }
  .page-shop .ts-wall::-webkit-scrollbar { display: none; }
  .page-shop .ts-wall ul { min-width: 330px; }
  .page-shop .ts-wall li { min-width: 60px; }
  .page-shop .ts-board { height: clamp(330px, 44vw, 420px); }
  .page-shop .ts-board:hover, .page-shop .ts-board:focus-visible { transform: translateY(-6px); }
  .page-shop .ts-bart { top: 4%; height: 33%; }
  .page-shop .ts-vn { top: 38%; bottom: 14%; }
  .page-shop .ts-vn b { font-size: min(20px, calc(48cqh / (var(--len, 10) * .78))); }
  .page-shop .ts-heroes { display: grid; gap: 22px; max-width: 760px; margin-inline: auto; }
  .page-shop .ts-hero { display: grid; grid-template-columns: minmax(0, 1fr); }
  .page-shop .ts-plane { grid-area: 1 / 1; aspect-ratio: 16 / 11; container-type: size; }
  .page-shop .ts-art { top: -4cqh; left: calc(50cqw - 45cqh); height: 112cqh; }
  .page-shop .ts-price { top: 18px; right: 18px; transform: rotate(6deg); }
  .page-shop .ts-price b { font-size: clamp(24px, 6.4vw, 34px); }
  .page-shop .ts-name { grid-area: 1 / 1; align-self: end; margin: 0 0 clamp(18px, 4vw, 30px) clamp(16px, 4vw, 30px); font-size: clamp(32px, 9.6vw, 58px); }
  .page-shop .ts-facts { grid-row: 2; align-items: flex-start; padding: 22px clamp(16px, 4vw, 30px) 0; }
  .page-shop .ts-chips { padding: 0 4px; }
  .page-shop .ts-acts { grid-row: 3; padding: 22px clamp(16px, 4vw, 30px) 26px; }
  .page-shop .ts-hero:not(:has(.ts-acts)) .ts-facts { padding-bottom: 26px; }
  .page-shop .ts-btn { min-height: 52px; font-size: 17px; padding: 0 24px; }
}
@media (max-width: 600px) {
  .page-shop .ts-plane { aspect-ratio: 1 / 1; }
  /* On a square plane the rider sits left of centre and a little smaller, so the price sticker clears his head. */
  .page-shop .ts-art { top: 4cqh; left: calc(40cqw - 40cqh); height: 100cqh; }
  .page-shop .ts-price { top: 14px; right: 12px; padding: 8px 13px 7px; }
  .page-shop .ts-price b { font-size: 25px; }
  .page-shop .ts-price small { font-size: 11px; }
  .page-shop .ts-head { margin-bottom: 18px; }
  .page-shop .ts-tabs a { height: 44px; padding: 0 14px; }
  .page-shop .ts-wall ul { gap: 7px; }
  .page-shop .ts-pp { font-size: 11px; padding: 5px 5px 4px; }
  .page-shop .ts-chips li { height: 34px; font-size: 11.5px; padding: 0 11px; }
  .page-shop .ts-acts .ts-btn { width: calc(100% - 8px); margin-inline: 4px; }
}

/* ---------- How to buy and the free gear: plain white sheets, the same type, no planes ---------- */
.page-shop .ts-more { position: relative; overflow: clip; padding: clamp(40px, 5vw, 70px) 0 clamp(80px, 9vw, 120px); color: #fff; background: var(--ts-ink); }
.page-shop .ts-sec-head { margin-bottom: 24px; }
.page-shop .ts-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin: 0; padding: 0; }
/* Under the steps: how the Discord role reaches you, one plain line. */
.page-shop .ts-note { margin: 18px 4px 0; font-weight: 700; font-size: 15px; line-height: 1.45; color: rgba(255,255,255,.78); }
.page-shop .ts-steps li { position: relative; display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; align-content: start; padding: 22px 24px 24px; border-radius: 12px; background: var(--ts-paper); color: var(--ts-ink); }
.page-shop .ts-no { grid-row: 1 / 3; position: relative; isolation: isolate; display: grid; place-items: center; width: 48px; height: 48px; font-weight: 900; font-size: 28px; line-height: 1; font-stretch: 118%; color: var(--ts-ink); }
.page-shop .ts-no::before { content: ''; position: absolute; inset: 0; z-index: -1; border-radius: 6px; transform: skewX(var(--ts-lean)); background: var(--ts-y); box-shadow: 0 4px 0 var(--ts-ylip); }
.page-shop .ts-steps h3 { margin: 4px 0 0; font-weight: 900; font-size: 20px; line-height: 1.05; font-stretch: 118%; }
.page-shop .ts-steps p { margin: 0; font-weight: 700; font-size: 15px; line-height: 1.45; color: var(--ts-muted); }
.page-shop .ts-steps kbd { display: inline-flex; align-items: center; height: 22px; padding: 0 7px; border-radius: 3px; transform: skewX(var(--ts-lean)); vertical-align: 1px;
  background: var(--ts-ink); color: #fff; box-shadow: none; font: italic 800 11.5px/1 var(--ts-face); font-stretch: 112%; text-transform: uppercase; }

.page-shop .ts-free { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 22px 40px; margin-top: 46px; padding: 28px 32px; border-radius: 12px; background: var(--ts-paper); color: var(--ts-ink); }
.page-shop .ts-free .ts-h2 { color: var(--ts-ink); font-size: clamp(26px, 2.6vw, 36px); }
.page-shop .ts-free .ts-label { color: var(--ts-muted); }
.page-shop .ts-swatches { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 16px 22px; margin: 0; padding: 0 6px; }
.page-shop .ts-swatches li { display: grid; justify-items: center; gap: 9px; font-weight: 800; font-size: 12px; line-height: 1; font-stretch: 112%; letter-spacing: .03em; white-space: nowrap; }
.page-shop .ts-swatches i { width: 74px; height: 44px; border-radius: 5px; transform: skewX(var(--ts-lean)); background: var(--c); box-shadow: inset 0 0 0 1.5px rgba(0,0,0,.14), 3px 4px 0 rgba(21,20,27,.18); }
@media (max-width: 1180px) { .page-shop .ts-steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px) {
  .page-shop .ts-steps { grid-template-columns: 1fr; }
  .page-shop .ts-free { grid-template-columns: 1fr; padding: 24px 22px; }
  .page-shop .ts-swatches { justify-content: flex-start; }
}
@media (max-width: 600px) {
  .page-shop .ts-swatches { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 10px; }
  .page-shop .ts-swatches i { width: 62px; height: 38px; }
}

/* The closing band keeps the site's buttons (already a yellow block on a lean) and takes the display face. */
.page-shop .closing.sky-night { background: radial-gradient(110% 70% at 70% 0%, #24232c 0%, var(--ts-ink) 60%); }
.page-shop .closing .display { font-family: var(--ts-face); font-style: italic; font-stretch: 125%; text-transform: uppercase; letter-spacing: -.01em; line-height: .9; }

@media (prefers-reduced-motion: reduce) {
  .page-shop :is(.ts-btn, .ts-btn::before, .ts-board) { transition: none; }
  .page-shop .ts-board:hover, .page-shop .ts-board:focus-visible { transform: none; }
  .page-shop .ts-stage.is-swap .ts-hero.is-leaving { transition: opacity .12s ease-out, visibility 0s linear .12s; }
  .page-shop .ts-stage.is-swap .ts-hero.is-on :is(.ts-price, .ts-tag) { animation: none; }
}

/* ---------- Ranks: one column per kit, its nameplate as the rank tag, one row per perk (src/shop.mjs rankGroups) ---------- */
.page-shop .ts-ranks { padding: clamp(40px, 5vw, 70px) 0 0; color: #fff; background: var(--ts-ink); }
.page-shop .ts-rank-lead { max-width: 64ch; margin: 12px 0 0; font-weight: 700; font-size: 16px; line-height: 1.5; color: rgba(255,255,255,.8); }
.page-shop .rk-scroll { overflow-x: auto; margin-top: 26px; border-radius: 12px; background: var(--ts-paper); color: var(--ts-ink); -webkit-overflow-scrolling: touch; }
.page-shop .ts-rank { width: 100%; min-width: 1200px; border-collapse: separate; border-spacing: 0; font-variant-numeric: tabular-nums; }
.page-shop .ts-rank th, .page-shop .ts-rank td { padding: 11px 10px; border-bottom: 1px solid rgba(21,20,27,.09); text-align: center; vertical-align: middle; }
.page-shop .ts-rank tbody th[scope="row"] { text-align: left; font-weight: 800; font-size: 14px; line-height: 1.3; padding-left: 20px; width: 22%; }
/* The perk column stays put while a phone scrolls the ranks under it. */
.page-shop .ts-rank tbody th[scope="row"], .page-shop .rk-corner { position: sticky; left: 0; z-index: 2; background: var(--ts-paper); }
.page-shop .ts-rank thead th { padding: 0 5px 14px; border-bottom: 0; vertical-align: bottom; }
/* Each head is the kit's own colour block on the lean, the plate on it like a sticker, the kit and price below. */
.page-shop .rk-head { position: relative; isolation: isolate; display: grid; justify-items: center; gap: 8px; padding: 18px 8px 12px; color: #fff; text-decoration: none; }
.page-shop .rk-head::before { content: ''; position: absolute; inset: 0 2px; z-index: -1; border-radius: 0 0 8px 8px; background: var(--kp); box-shadow: inset 0 -5px 0 var(--ks); }
.page-shop .rk-head:hover::before, .page-shop .rk-head:focus-visible::before { box-shadow: inset 0 -5px 0 var(--ks), 0 0 0 3px var(--ts-y); }
.page-shop .rk-head:focus-visible { outline: none; }
.page-shop .kp-rank { font-size: 13px; }
.page-shop .rk-name { font-weight: 800; font-size: 12px; line-height: 1.15; letter-spacing: .02em; opacity: .9; }
.page-shop .rk-price { font-weight: 900; font-size: 19px; line-height: 1; font-stretch: 118%; }
.page-shop .rk-group th { padding: 18px 20px 8px; text-align: left; border-bottom: 2px solid rgba(21,20,27,.16); background: var(--ts-paper);
  font-weight: 900; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--ts-muted); position: sticky; left: 0; }
.page-shop .rk-yes { font-weight: 900; font-size: 17px; color: #1f8a4c; }
.page-shop .rk-no { color: rgba(21,20,27,.3); font-weight: 700; }
.page-shop .rk-txt { display: block; margin-top: 2px; font-weight: 700; font-size: 12px; line-height: 1.25; color: var(--ts-muted); }
.page-shop .ts-rank .ts-soon { margin-left: 5px; vertical-align: 2px; }
.page-shop .ts-rank tbody tr:last-child > * { border-bottom: 0; }
/* Patron's column, the top rank, sits on a faint brass wash down the whole table. */
.page-shop .ts-rank tbody td:nth-child(2) { background: rgba(214,169,44,.12); }
@media (max-width: 600px) { .page-shop .ts-rank tbody th[scope="row"] { width: 150px; min-width: 150px; font-size: 13px; padding-left: 14px; } }
/* Equal rank columns whatever the kit's name length; the head band is one colour, corner included. */
.page-shop .ts-rank { table-layout: fixed; }
.page-shop .ts-rank .rk-corner { width: 22%; }
.page-shop .ts-rank thead th { background: var(--ts-off); }
@media (max-width: 600px) { .page-shop .ts-rank .rk-corner { width: 150px; } }
/* The rank tag in a column: a touch tighter than the shop sample so "FIRST TRACKS" fits a 1280 column whole. */
.page-shop .kp-rank { font-size: 12px; padding-right: .7em; letter-spacing: min(var(--kp-ls), .04em); }
.page-shop .ts-rank .rk-corner { width: 19%; }
.page-shop .ts-rank { min-width: 1280px; }
.page-shop .ts-rank thead th { padding-inline: 3px; }
.page-shop .rk-head { padding-inline: 4px; }
/* Fit a 1280 screen without a sideways scroll: a narrower perk column (its labels wrap to two lines) leaves each rank
   column room for "FIRST TRACKS" whole. A phone scrolls the table in its box, at a width where the tags still fit. */
.page-shop .ts-rank { min-width: 0; }
.page-shop .ts-rank .rk-corner { width: 15%; }
@media (max-width: 1100px) { .page-shop .ts-rank { min-width: 1240px; } .page-shop .ts-rank .rk-corner { width: 150px; } }
@media (max-width: 1360px) { .page-shop .kp-rank { font-size: 11px; } }
/* A jump to a section (How to buy, Ranks, Free gear) stops below the sticky site header (76 px at 1440), not under it:
   the "How to buy" label used to land 6 px under the header's edge. */
.page-shop :is(#ranks, #how-to-buy, #free-gear) { scroll-margin-top: 84px; }

/* The nameplate line: the label, then the real plate on ONE line, at the game's shop-list size (kitWall.js has-plate,
   11.5u): a long name shortens with an ellipsis rather than wrapping the list into the price sticker. */
.page-shop .ts-extras li.has-plate { flex-wrap: nowrap; }
.page-shop .ts-extras li.has-plate > span:not(.kplate) { flex: none; white-space: nowrap; }
.page-shop .kp-line { flex: 0 1 auto; min-width: 0; font-size: 11px; padding-top: .16em; padding-bottom: .16em; }
/* Every head holds two lines of kit name ("Sugarpine Supporter" wraps), so the plates and prices sit on one line across. */
.page-shop .rk-name { min-height: 2.3em; display: flex; align-items: center; text-align: center; }
