/* Fracture. Black and red.
   Red is reserved for the primary action, active states and the crack motif.
   Fonts and colours live in tokens.css, shared with the admin. These are the store's own tokens. */

:root {
  --gutter: clamp(16px, 3.4vw, 40px);
  --wide: 1320px;
  --head-h: 68px;
  /* One measure for every single-column page: reading pages, a guide, an order. */
  --narrow: calc(60ch + 58px);
  --radius: 10px;
  --radius-lg: 16px;
  --surface-2: #1c1a1a;
  --glass: rgba(11, 10, 10, .78);
  --red-soft: rgba(208, 12, 56, .14);
  --red-line: rgba(208, 12, 56, .55);
  --shadow: 0 18px 50px -18px rgba(0, 0, 0, .8);
  --snap: cubic-bezier(.7, 0, 1, .6);   /* accelerates into the end and stops dead */
  --ease: cubic-bezier(.2, .8, .2, 1);  /* quick start, soft landing */
}

/* ---- Base ---- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--head-h) + 16px); }
body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font: 400 1.0625rem/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
}
/* Dust and dim light from ambient.js, behind everything. The page looks complete without it. */
.ambient { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
main { flex: 1 0 auto; }
img, svg, video { display: block; max-width: 100%; }
h1, h2, h3, h4 { margin: 0; font-family: var(--display); font-weight: 800; line-height: 1.05; letter-spacing: .005em; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 2rem + 2.4vw, 4rem); }
h2 { font-size: clamp(1.875rem, 1.5rem + 1.3vw, 2.625rem); }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
p { margin: 0; }
a { color: inherit; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: .18em; }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--red-text); outline-offset: 2px; border-radius: 4px; }
::selection { background: var(--red); color: var(--on-red); }
hr { height: 1px; border: 0; background: var(--line); margin: 32px 0; }
.icon { width: 20px; height: 20px; flex: none; }

.vh { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -64px; padding: 10px 16px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius); z-index: 60; }
.skip-link:focus { top: 8px; }

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

.page { width: 100%; max-width: var(--wide); margin-inline: auto; padding: 44px var(--gutter) 72px; }
/* 60ch of Hanken Grotesk at this size holds about 74 characters, because ch is the wide zero. */
.page-narrow { width: 100%; max-width: calc(var(--narrow) + 2 * var(--gutter)); margin-inline: auto; padding: 44px var(--gutter) 72px; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); font-size: max(1rem, .94em); overflow-wrap: anywhere; }
.hint { color: var(--muted); font-size: 1rem; line-height: 1.45; }
/* A link standing on its own line needs a full tap target. Links inside a sentence do not. */
.tap-link, .back-link a, .product-status a, .empty p > a { display: inline-flex; align-items: center; min-height: 44px; }
/* The small red label over a heading. */
.kicker { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font: 700 .875rem/1 var(--display); letter-spacing: .16em; text-transform: uppercase; color: var(--red-text); }
.kicker::before { content: ""; width: 22px; height: 2px; background: var(--red); }

.prose { max-width: 60ch; }
.prose strong { font-weight: 600; }
.prose > * + * { margin-top: 1em; }
.prose h2, .prose h3, .prose h4 { margin-top: 1.6em; }
.prose h1 { font-size: 2.25rem; }
.prose h2 { font-size: 1.75rem; }
.prose h3 { font-size: 1.375rem; }
.prose h4 { font-size: 1.1875rem; }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .35em; }
.prose li::marker { color: var(--red-text); }
.prose img { border-radius: var(--radius); height: auto; border: 1px solid var(--line); }
.prose blockquote { margin-inline: 0; padding: 4px 0 4px 16px; border-left: 3px solid var(--red); color: var(--muted); }
.prose code { font-family: var(--mono); font-size: max(1rem, .92em); background: var(--surface); border: 1px solid var(--line); border-radius: 5px; padding: .08em .32em; }
.prose pre { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; overflow-x: auto; }
.prose pre code { background: none; border: 0; padding: 0; }
.prose table { border-collapse: collapse; width: 100%; }
.prose th, .prose td { border-bottom: 1px solid var(--line); padding: 8px 12px 8px 0; text-align: left; vertical-align: top; }

.btn, .btn-quiet {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 10px 22px;
  border-radius: var(--radius);
  font: 650 1.0625rem/1.2 var(--font);
  font-variant-numeric: tabular-nums;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms var(--ease), box-shadow 160ms var(--ease), background-color 160ms, border-color 160ms;
}
.btn { background: var(--red); color: var(--on-red); border: 1px solid var(--red); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16); }
.btn:hover { background: var(--red-dark); border-color: var(--red-dark); transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 10px 26px -10px var(--red); }
.btn:active { transform: translateY(1px); box-shadow: none; }
.btn-quiet { background: rgba(244, 239, 233, .04); color: var(--text); border: 1px solid var(--line-strong); }
.btn-quiet:hover { border-color: var(--text); background: rgba(244, 239, 233, .08); transform: translateY(-1px); }
.btn-quiet:active { transform: translateY(1px); background: var(--surface); }
.btn[disabled], .btn-quiet[disabled] { background: transparent; color: var(--muted); border: 1px dashed var(--line-strong); cursor: not-allowed; transform: none; box-shadow: none; }
.btn .icon, .btn-quiet .icon { width: 18px; height: 18px; }

.field { display: grid; gap: 6px; }
.field > label, .field > .field-label { font-weight: 600; font-size: 1rem; }
input[type="text"], input[type="email"], input[type="search"], input[type="url"], input[type="number"], input[type="password"], textarea, select {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  font: 400 1rem/1.4 var(--font);
  transition: border-color 160ms, box-shadow 160ms;
}
input:hover, textarea:hover, select:hover { border-color: var(--muted); }
/* Text fields only. A checkbox, radio or slider keeps the plain outline every other control gets. */
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):focus-visible, textarea:focus-visible, select:focus-visible { outline: 2px solid var(--red-text); outline-offset: 1px; border-color: var(--red-text); box-shadow: 0 0 0 4px var(--red-soft); }
.field-error { color: var(--red-text); font-size: 1rem; line-height: 1.45; }
.field-error::before { content: "Error: "; font-weight: 600; }
.field.has-error input { border-color: var(--red); }

/* Search on guides, downloads and products. Matches are underlined in the logo red, never filled. */
.search { max-width: 44rem; margin: 0 0 20px; }
.search-label { display: block; font-weight: 600; font-size: 1rem; margin-bottom: 6px; }
.search-row { display: flex; gap: 8px; }
.search-row input { flex: 1 1 auto; min-width: 0; background: var(--surface); }
.search-go { flex: none; min-height: 48px; }
.search-hint { margin: 8px 0 0; color: var(--muted); font-size: 0.9375rem; line-height: 1.45; }
.search-status { margin: 10px 0 0; min-height: 1.45em; line-height: 1.45; }
.search-status a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
.search-snippet { color: var(--muted); }
mark { background: transparent; color: inherit; text-decoration: underline 2px var(--red); text-underline-offset: 3px; text-decoration-skip-ink: none; }
[data-search-id][hidden], [data-search-group][hidden], [data-search-empty][hidden], .search-snippet[hidden], .search-status a[hidden] { display: none !important; }

.notice, .notice-error { padding: 14px 16px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius); line-height: 1.45; }
.notice-error { border-color: var(--red); border-left-width: 4px; }

.empty { padding-block: 72px; }
.empty > * { max-width: 56ch; }
.empty > * + * { margin-top: 12px; }
.empty p { color: var(--muted); }
.empty a { color: var(--text); }

.table-plain { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.table-plain th { text-align: left; font-weight: 600; color: var(--muted); font-size: 1rem; }
.table-plain th, .table-plain td { padding: 10px 16px 10px 0; border-bottom: 1px solid var(--line); vertical-align: baseline; }

.list-rows { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--line); }
.list-row { position: relative; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 24px; padding: 16px 0; border-top: 1px solid var(--line); }
a.list-row { text-decoration: none; }

/* A line that wipes in from the left once and stays. The resting state is the full line, so it needs no JS. */
.line-wipe { transform-origin: left; animation: line-wipe 300ms var(--snap) 1 both; }
@keyframes line-wipe { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* One box style for the whole site. Dropdowns are a box whose heading folds it. */
.box { min-width: 0; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.box-title, .section-title { margin: 0 0 16px; font-size: 1.625rem; }
.fold > summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 44px; margin: -6px 0; list-style: none; cursor: pointer; font-weight: 600; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary h2 { margin: 0; font-size: 1.625rem; }
.fold > summary::after { content: ""; flex: none; width: 9px; height: 9px; margin-right: 4px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform 180ms var(--ease); }
.fold[open] > summary::after { transform: rotate(-135deg); }
.fold > summary:hover::after { border-color: var(--text); }
.fold[open] > summary { margin-bottom: 14px; }

/* ---- Status ---- */

.badge-status { display: inline-flex; align-items: center; gap: 6px; font-size: 1rem; line-height: 1.3; white-space: nowrap; }
.status-shape { width: 15px; height: 15px; flex: none; }
/* Colour for a quick scan. The word and the shape still carry the state without it. */
.s-operational { color: var(--status-ok); }
.s-updating { color: var(--status-updating); }
.s-degraded { color: var(--status-degraded); }
.s-offline { color: var(--status-offline); }
.badge-large { font-size: 1rem; font-weight: 600; }
.badge-large .status-shape { width: 18px; height: 18px; }

/* ---- Marks ---- */

.logo-mark { height: 32px; width: auto; flex: none; }
.wordmark { height: 19px; width: auto; flex: none; }
.logo-long { height: 30px; width: auto; flex: none; }
.mark-blank { width: auto; height: 56%; fill: var(--line); }

/* ---- Header: stays at the top of the window, on glass ---- */

.site-header { position: sticky; top: 0; z-index: 40; background: var(--glass); border-bottom: 1px solid var(--line); -webkit-backdrop-filter: blur(14px) saturate(140%); backdrop-filter: blur(14px) saturate(140%); }
.site-header-row { position: relative; max-width: var(--wide); min-height: var(--head-h); margin-inline: auto; padding: 0 var(--gutter); display: flex; align-items: center; gap: 12px 28px; }
.site-logo { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; color: var(--text); }
.site-logo .logo-mark { display: none; }
.nav-wide { display: flex; gap: 2px; margin-right: auto; }
.nav-wide a, .nav-small nav a { display: flex; align-items: center; min-height: 44px; padding: 0 14px; border-radius: 8px; color: var(--muted); font-weight: 500; text-decoration: none; transition: color 140ms, background-color 140ms; }
.nav-wide a:hover { color: var(--text); background: rgba(244, 239, 233, .06); }
.nav-wide a[aria-current="page"] { position: relative; color: var(--text); font-weight: 650; }
.nav-wide a[aria-current="page"]::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: -12px; height: 2px; background: var(--red); }
.header-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.header-discord, .cart-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: rgba(244, 239, 233, .03); color: var(--text); font-weight: 600; text-decoration: none; white-space: nowrap; transition: border-color 140ms, background-color 140ms; }
.header-discord { border-color: transparent; background: none; color: var(--muted); font-weight: 500; }
.header-discord:hover { color: var(--text); }
.cart-link:hover { border-color: var(--text); background: rgba(244, 239, 233, .07); }
.cart-link[aria-current="page"] { border-color: var(--red); }
.cart-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--red); color: var(--on-red); font-size: .875rem; font-variant-numeric: tabular-nums; }
.nav-small { display: none; }
.nav-small summary { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: var(--radius); cursor: pointer; list-style: none; font-weight: 600; font-size: 1rem; }
.nav-small summary::-webkit-details-marker { display: none; }
.nav-small[open] summary { background: var(--surface-2); border-color: var(--text); }

.site-notice { max-width: var(--wide); width: 100%; margin: 14px auto 0; padding: 0 var(--gutter); color: var(--muted); font-size: 1rem; }
.site-notice strong { color: var(--text); }

/* ---- Footer ---- */

.site-footer { flex: none; margin-top: 24px; border-top: 1px solid var(--line); background: linear-gradient(180deg, rgba(21, 20, 20, .7), var(--bg)); color: var(--muted); font-size: 1rem; }
.footer-row { max-width: var(--wide); margin-inline: auto; padding: 48px var(--gutter) 28px; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); gap: 32px 48px; }
.footer-brand p { margin-top: 12px; max-width: 34ch; }
.footer-col { display: grid; align-content: start; justify-items: start; gap: 0; }
.footer-col h2 { margin: 0 0 8px; font: 700 .875rem/1 var(--display); letter-spacing: .16em; text-transform: uppercase; color: var(--text); }
.footer-col a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); text-decoration: none; overflow-wrap: anywhere; }
.footer-col a:hover { color: var(--text); }
.footer-legal { max-width: var(--wide); margin-inline: auto; padding: 18px var(--gutter) 28px; border-top: 1px solid var(--line); font-size: .9375rem; }

/* ---- Hero ---- */

.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
/* A fine grid that fades out, and a low red light behind the break. Decoration only. */
.hero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(60% 90% at 78% 40%, rgba(208, 12, 56, .2), transparent 70%),
    linear-gradient(rgba(244, 239, 233, .035) 1px, transparent 1px) 0 0 / 56px 56px,
    linear-gradient(90deg, rgba(244, 239, 233, .035) 1px, transparent 1px) 0 0 / 56px 56px;
  -webkit-mask-image: linear-gradient(180deg, #000 30%, transparent); mask-image: linear-gradient(180deg, #000 30%, transparent); }
.hero-text { position: relative; max-width: var(--wide); margin-inline: auto; padding: clamp(40px, 6vh, 64px) var(--gutter) clamp(48px, 7vh, 72px); }
.hero h1 { max-width: 20em; font-size: clamp(2.5rem, 1.8rem + 1.8vw, 3.5rem); line-height: 1; }
.hero-fact { margin-top: 14px; max-width: 56ch; color: var(--muted); font-size: 1.0625rem; }
/* A fixed-shape break hung from the top edge of the band, at the right of the content column. It scales with
   the hero's height and is never stretched, so its angles match the logo's sliver at every width.
   The window slides down while the SVG inside slides up by the same amount, so the break is cut from the top
   without moving. Transform only. Without animation both rest at none: the finished break. */
.hero-crack { position: absolute; top: 0; bottom: 0; right: max(var(--gutter), calc((100% - var(--wide)) / 2 + var(--gutter))); aspect-ratio: 7 / 5; overflow: hidden; pointer-events: none; }
.hero-crack-window, .hero-crack svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-crack-window { overflow: hidden; animation: crack-window 300ms var(--snap) 1 both; }
.hero-crack svg { animation: crack-counter 300ms var(--snap) 1 both; }
.hero-crack polygon { fill: var(--red); }
@keyframes crack-window { from { transform: translateY(-100%); } }
@keyframes crack-counter { from { transform: translateY(100%); } }
/* On a visit that shows the loading screen, the cut lands as the screen clears, not behind it. */
html.fx-play .hero-crack-window, html.fx-play .hero-crack svg { animation-delay: 900ms; }

/* Home page hero: words on the left, the lead product standing in front of the break on the right. */
.hero-home .hero-text { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 40px clamp(32px, 5vw, 72px); align-items: center; padding-top: clamp(56px, 10vh, 112px); padding-bottom: clamp(64px, 11vh, 120px); }
.hero-home h1 { font-size: clamp(3rem, 1.6rem + 4.6vw, 5.75rem); line-height: .94; max-width: 9.5em; }
.hero-home h1 .accent { color: var(--red-text); }
.hero-home .hero-fact { margin-top: 20px; font-size: 1.1875rem; max-width: 44ch; }
.hero-live { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin: 0 0 22px; padding: 0 16px 0 14px; border: 1px solid var(--line); border-radius: 22px; background: rgba(21, 20, 20, .8); color: var(--text); font-size: .9375rem; font-weight: 500; text-decoration: none; }
.hero-live:hover { border-color: var(--line-strong); }
.hero-live.s-operational i { color: var(--status-ok); }
.hero-live.s-updating i { color: var(--status-updating); }
.hero-live.s-degraded i { color: var(--status-degraded); }
.hero-live.s-offline i { color: var(--status-offline); }
.hero-live i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 4px color-mix(in srgb, currentColor 22%, transparent); }
.hero-action { display: flex; flex-wrap: wrap; gap: 10px; margin: 30px 0 0; }
.hero-action .btn, .hero-action .btn-quiet { min-height: 54px; padding: 0 28px; font-size: 1.125rem; }
.hero-points { display: flex; flex-wrap: wrap; gap: 10px 26px; margin: 30px 0 0; padding: 0; list-style: none; color: var(--muted); font-size: 1rem; }
.hero-points li { display: inline-flex; align-items: center; gap: 8px; }
.hero-points .icon { color: var(--red-text); }
.hero-art { position: relative; display: block; color: inherit; text-decoration: none; }
.hero-art-frame { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius-lg); border: 1px solid rgba(244, 239, 233, .16); background: var(--surface); box-shadow: 0 40px 90px -30px #000, 0 0 90px -20px rgba(208, 12, 56, .55); transform: perspective(1400px) rotateY(-7deg) rotateX(2deg); transition: transform 500ms var(--ease); }
.hero-art:hover .hero-art-frame { transform: perspective(1400px) rotateY(-2deg) rotateX(0deg); }
.hero-art-frame img { width: 100%; height: 100%; object-fit: cover; }
.hero-art-tag { position: absolute; left: -14px; bottom: -18px; display: grid; gap: 2px; padding: 12px 16px; border-radius: var(--radius); border: 1px solid var(--line-strong); background: rgba(11, 10, 10, .92); box-shadow: var(--shadow); }
.hero-art-new { margin: 0; font-style: normal; }
.hero-art-tag strong { font: 800 1.375rem/1.1 var(--display); letter-spacing: .01em; }
.hero-art-tag span { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: .9375rem; font-variant-numeric: tabular-nums; }
.hero-home .hero-crack { right: auto; left: 46%; opacity: .9; }

/* ---- Sections ---- */

.home-band { padding-top: 0; padding-bottom: clamp(56px, 8vw, 96px); }
.home-first { padding-top: clamp(48px, 6vw, 72px); }
.home-section { margin-top: 48px; }
.home-section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 8px 24px; margin-bottom: 24px; }
.home-section-head h2, .home-band > h2 { margin: 0; }
.home-band > h2 { margin-bottom: 24px; }
.home-section-head > a, .more-link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--text); font-weight: 600; text-decoration: none; }
.home-section-head > a::after, .more-link::after { content: ""; width: 7px; height: 7px; border-top: 2px solid var(--red-text); border-right: 2px solid var(--red-text); transform: rotate(45deg); transition: transform 160ms var(--ease); }
.home-section-head > a:hover::after, .more-link:hover::after { transform: translateX(4px) rotate(45deg); }
.home-note { margin: 14px 0 0; }

/* ---- Shelf ---- */

.shelf { padding-top: 44px; }
.shelf h1 { margin: 0; }
.shelf-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 32px; margin-bottom: 24px; }
.filter { display: flex; flex-wrap: wrap; gap: 6px; }
.filter a { display: flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--line-strong); border-radius: 22px; color: var(--muted); font-weight: 500; text-decoration: none; transition: color 140ms, border-color 140ms, background-color 140ms; }
.filter a:hover { color: var(--text); border-color: var(--text); }
.filter a[aria-current="true"] { color: var(--on-red); background: var(--red); border-color: var(--red); font-weight: 650; }

.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
/* The home page shows four: one row of four, or two rows of two, never three and one. */
@media (min-width: 1080px) { .home-first .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 721px) and (max-width: 1079px) { .home-first .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* A short shelf shares the whole row instead of leaving empty columns. */
.grid-few { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.card-item { min-width: 0; display: flex; }
.card { position: relative; display: flex; flex-direction: column; width: 100%; overflow: hidden; color: inherit; text-decoration: none; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); transition: transform 220ms var(--ease), border-color 220ms, box-shadow 220ms; }
.card-frame { position: relative; aspect-ratio: 16 / 9; background: var(--bg); overflow: hidden; }
.card-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform 500ms var(--ease); }
/* Owner-requested: the shards fall while the pointer is on a product picture. Opacity only, and never with reduced motion. */
.hover-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; pointer-events: none; transition: opacity 150ms ease-out; }
.hover-video.is-on { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .hover-video { display: none; } }
.card-blank { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
/* A solid red line along the image's lower edge wipes across from the left. Transform only. */
.card-wipe { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform 220ms var(--snap); }
.card:hover { transform: translateY(-4px); border-color: var(--red-line); box-shadow: 0 24px 50px -24px #000, 0 0 40px -18px var(--red); }
.card:hover .card-frame img { transform: scale(1.03); }
.card:hover .card-wipe, .card:active .card-wipe { transform: scaleX(1); }
.card:active { transform: translateY(-1px); }

.card-line { display: flex; align-items: baseline; justify-content: space-between; gap: 4px 16px; padding: 16px 18px 0; }
.card-name { font-size: 1.625rem; min-width: 0; overflow-wrap: anywhere; }
.card-price { flex: none; font-weight: 650; font-variant-numeric: tabular-nums; }
.card-sub { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2px 16px; margin-top: auto; padding: 8px 18px 16px; color: var(--muted); font-size: 1rem; }
.card-stock { display: block; margin-top: -8px; padding: 0 18px 16px; font-size: 1rem; color: var(--status-degraded); font-variant-numeric: tabular-nums; }

/* Nothing for sale here, so no red line, and it says so in words. */
.card.is-cold { background: transparent; border-style: dashed; border-color: var(--line-strong); }
.card.is-cold:hover { box-shadow: none; border-color: var(--line-strong); }
.card.is-cold img { filter: grayscale(1) brightness(.55); }
.card.is-cold .card-wipe { display: none; }
.card.is-cold .card-name, .card.is-cold .card-price { color: var(--muted); }
.card-plate { position: absolute; left: 12px; top: 12px; padding: 4px 10px; background: var(--bg); border: 1px solid var(--line-strong); border-radius: 6px; color: var(--text); font-weight: 600; font-size: .9375rem; }

/* ---- Home: the Optimizer band ---- */

.app-show { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: center; }
.app-show-panel { padding: clamp(20px, 3vw, 40px); border: 1px solid var(--line); border-radius: 24px; background: radial-gradient(90% 120% at 0% 0%, rgba(208, 12, 56, .16), transparent 60%), var(--surface); }
.app-show-art { display: block; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid rgba(244, 239, 233, .14); box-shadow: var(--shadow); }
/* The frame clips the video's own outline, so the frame carries it. */
.app-show-art .showcase-video:focus-visible { outline-offset: -3px; }
.app-show-art:has(.showcase-video:focus-visible) { outline: 2px solid var(--red-text); outline-offset: 2px; }
.showcase-video { display: block; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: var(--radius-lg); }
.app-show-art .showcase-video { border-radius: 0; }
.app-show-kicker { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font: 700 .875rem/1 var(--display); letter-spacing: .16em; text-transform: uppercase; color: var(--red-text); }
.app-show-kicker::before { content: ""; width: 22px; height: 2px; background: var(--red); }
.app-show-text h2 { margin: 0; }
.app-show-lead { margin: 14px 0 0; color: var(--muted); max-width: 52ch; }
.app-show-points { margin: 20px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.app-show-points li { position: relative; padding-left: 28px; }
.app-show-points li::before { content: ""; position: absolute; left: 4px; top: .42em; width: 12px; height: 6px; border-left: 2px solid var(--red-text); border-bottom: 2px solid var(--red-text); transform: rotate(-45deg); }
.app-show-actions { margin: 26px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.app-show-actions a { min-height: 50px; }
.app-show-more { margin: 10px 0 0; }

/* ---- Home: games, compare, status, steps, resources, Discord ---- */

.game-links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.game-links li { max-width: 620px; }
.game-links a { display: flex; flex-direction: column; height: 100%; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); text-decoration: none; transition: transform 220ms var(--ease), border-color 220ms, box-shadow 220ms; }
.game-links a:hover { transform: translateY(-4px); border-color: var(--red-line); box-shadow: 0 24px 50px -24px #000; }
.game-links a:active { transform: translateY(-1px); }
.game-link-frame { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--bg); }
.game-link-frame img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 500ms var(--ease); }
.game-links a:hover img { transform: scale(1.04); }
.game-link-text { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 12px; padding: 14px 18px 16px; }
.game-link-name { font: 800 1.375rem/1.1 var(--display); color: var(--text); overflow-wrap: anywhere; }

.compare-band { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.9fr); gap: clamp(28px, 4vw, 56px); align-items: center; }
.compare-band-text p { margin-top: 14px; color: var(--muted); max-width: 40ch; }
.compare-band-text .more-link { margin-top: 12px; }

.status-strip { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.status-strip a { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; padding: 0 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); text-decoration: none; transition: border-color 160ms, background-color 160ms; }
.status-strip a:hover { border-color: var(--line-strong); background: var(--surface-2); }
.status-strip-name { font-weight: 600; color: var(--text); overflow-wrap: anywhere; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; counter-reset: step; }
.steps li { position: relative; padding: 26px 24px 24px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); counter-increment: step; overflow: hidden; }
.steps li::before { content: "0" counter(step); position: absolute; right: 18px; top: 8px; font: 800 4.5rem/1 var(--display); color: rgba(244, 239, 233, .06); }
.steps .icon { width: 26px; height: 26px; color: var(--red-text); }
.steps h3 { margin: 16px 0 8px; font-size: 1.625rem; }
.steps p { color: var(--muted); }
.home-how > .muted { margin-top: 18px; max-width: 70ch; }

.home-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; align-items: start; }
.home-columns > div { padding: 26px 26px 8px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.home-columns .home-section-head { margin-bottom: 12px; }
.home-columns h2 { font-size: 1.75rem; }
.home-columns .list-rows { border-bottom: 0; }

.home-discord { position: relative; overflow: hidden; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px; padding: clamp(28px, 4vw, 48px); border-radius: 24px; border-color: var(--red-line); background: radial-gradient(70% 160% at 100% 50%, rgba(208, 12, 56, .32), transparent 70%), var(--surface); }
.home-discord > div { flex: 1 1 320px; min-width: 0; }
.home-discord h2 { margin: 0 0 8px; }
.home-discord p:not(.kicker) { margin: 0; max-width: 56ch; color: var(--muted); }
.home-discord-link { min-height: 54px; padding: 0 30px; font-size: 1.125rem; }

.game-head { margin-bottom: 32px; }
.game-head h1 { margin: 0; }
.game-intro { margin: 12px 0 0; max-width: 62ch; color: var(--muted); }
.game-copy { max-width: 62ch; }
.product-game a { color: inherit; }
.plain-links { margin: 0; padding-left: 20px; }
.plain-links li { margin-bottom: 6px; }

/* ---- Product page: the detail scrolls on the left while the buy box stays in view on the right.
   The name and summary scroll away with the page, and the box only stays when the whole of it fits the window. ---- */

.product { display: grid; gap: 20px; padding-top: 24px; min-width: 0; }
.product-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 440px); gap: 32px; align-items: start; }
.product-main { grid-area: 1 / 1; display: grid; gap: 20px; min-width: 0; }
.product-side { grid-area: 1 / 2; align-self: stretch; align-content: start; display: grid; gap: 20px; min-width: 0; }
@media (min-width: 1001px) and (min-height: 760px) {
  .product-buy { position: sticky; top: calc(var(--head-h) + 20px); max-height: calc(100dvh - var(--head-h) - 40px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
  /* A notice or an error makes the box taller than a laptop window, so then it scrolls with the page. */
  .product-buy:has(.buy-added, .field-error) { position: static; max-height: none; overflow: visible; }
}
.no-gallery .product-top { grid-template-columns: minmax(0, 1fr) minmax(360px, 440px); }

/* Each link is a full tap target, and the row is pulled back so the page keeps its spacing. */
.crumbs { margin-block: -12px; }
.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 0 8px; margin: 0; padding: 0; list-style: none; color: var(--muted); font-size: 0.9375rem; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--line-strong); }
.crumbs li { display: inline-flex; align-items: center; min-height: 44px; }
.crumbs a { display: inline-flex; align-items: center; min-height: 44px; color: inherit; text-decoration: none; }
.crumbs a:hover { color: var(--text); text-decoration: underline; }
.crumbs [aria-current] { color: var(--text); overflow-wrap: anywhere; }

.buy-added { margin: 0 0 16px; padding: 10px 12px; border: 1px solid var(--status-ok); border-radius: var(--radius); }
.buy-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin: 0; font-variant-numeric: tabular-nums; }
.buy-price[hidden] { display: none; }
.buy-price strong { font: 800 2.75rem/1 var(--display); }
.buy-price s { color: var(--muted); font-size: 1.125rem; }
.buy-buttons { display: grid; grid-template-columns: 3fr 2fr; gap: 8px; }
.buy-buttons .btn, .buy-buttons .btn-quiet { min-height: 54px; padding-inline: 12px; }
.buy-action { display: grid; gap: 10px; }
.buy-action .hint { margin: 0; font-size: .9375rem; }
.buy-action > .btn { width: 100%; min-height: 54px; }
.product-head { display: grid; gap: 10px; }
.product-head h1 { font-size: clamp(2.5rem, 2rem + 1.6vw, 3.5rem); }
.product-game { color: var(--muted); }
.product-status { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 14px; }
.product-status a { text-decoration: none; padding: 0 14px 0 12px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); }
.product-status a:hover { border-color: var(--line-strong); }
.product-note { color: var(--muted); font-size: 1rem; flex-basis: 100%; }
.product-summary { max-width: 52ch; color: var(--muted); font-size: 1.125rem; }
.gallery { min-width: 0; }
.product-buy { min-width: 0; box-shadow: var(--shadow); }
.product-info { display: grid; gap: 20px; min-width: 0; }
/* A heading that stands outside a box starts a section, so it gets more room above than the gap between boxes. */
.product-info > section > .section-title { margin-top: 12px; }
.product-info > section:first-child > .section-title { margin-top: 0; }
.gallery .showcase-video { border: 1px solid var(--line); }
.product-blank { display: block; height: 144px; }
.product-blank .mark-blank { height: 100%; }

.gallery-main { position: relative; aspect-ratio: 16 / 9; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.g-i { display: none; }
.gallery-thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.g-t { position: relative; display: block; width: 104px; aspect-ratio: 16 / 9; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; cursor: pointer; opacity: .7; transition: opacity 140ms, border-color 140ms; }
.g-t:hover { border-color: var(--line-strong); opacity: 1; }
.g-t img { width: 100%; height: 100%; object-fit: contain; }
/* One rule per image. shop.tsx caps the gallery at 12. */
.g-r1:checked ~ .gallery-main .g-i1, .g-r2:checked ~ .gallery-main .g-i2, .g-r3:checked ~ .gallery-main .g-i3,
.g-r4:checked ~ .gallery-main .g-i4, .g-r5:checked ~ .gallery-main .g-i5, .g-r6:checked ~ .gallery-main .g-i6,
.g-r7:checked ~ .gallery-main .g-i7, .g-r8:checked ~ .gallery-main .g-i8, .g-r9:checked ~ .gallery-main .g-i9,
.g-r10:checked ~ .gallery-main .g-i10, .g-r11:checked ~ .gallery-main .g-i11, .g-r12:checked ~ .gallery-main .g-i12 { display: block; }
.g-r1:checked ~ .gallery-thumbs .g-t1, .g-r2:checked ~ .gallery-thumbs .g-t2, .g-r3:checked ~ .gallery-thumbs .g-t3,
.g-r4:checked ~ .gallery-thumbs .g-t4, .g-r5:checked ~ .gallery-thumbs .g-t5, .g-r6:checked ~ .gallery-thumbs .g-t6,
.g-r7:checked ~ .gallery-thumbs .g-t7, .g-r8:checked ~ .gallery-thumbs .g-t8, .g-r9:checked ~ .gallery-thumbs .g-t9,
.g-r10:checked ~ .gallery-thumbs .g-t10, .g-r11:checked ~ .gallery-thumbs .g-t11, .g-r12:checked ~ .gallery-thumbs .g-t12 { border: 2px solid var(--red); opacity: 1; }
.g-r1:focus-visible ~ .gallery-thumbs .g-t1, .g-r2:focus-visible ~ .gallery-thumbs .g-t2, .g-r3:focus-visible ~ .gallery-thumbs .g-t3,
.g-r4:focus-visible ~ .gallery-thumbs .g-t4, .g-r5:focus-visible ~ .gallery-thumbs .g-t5, .g-r6:focus-visible ~ .gallery-thumbs .g-t6,
.g-r7:focus-visible ~ .gallery-thumbs .g-t7, .g-r8:focus-visible ~ .gallery-thumbs .g-t8, .g-r9:focus-visible ~ .gallery-thumbs .g-t9,
.g-r10:focus-visible ~ .gallery-thumbs .g-t10, .g-r11:focus-visible ~ .gallery-thumbs .g-t11, .g-r12:focus-visible ~ .gallery-thumbs .g-t12 { outline: 2px solid var(--red-text); outline-offset: 2px; }

.specs { margin: 0; }
.specs > div:first-child { border-top: 0; }
.specs > div { display: grid; grid-template-columns: minmax(110px, 1fr) 3fr; gap: 4px 16px; padding: 12px 0; border-top: 1px solid var(--line); }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; overflow-wrap: anywhere; }

/* Buy box. */
.buy { display: grid; gap: 20px; }
.opts { margin: 0; padding: 0; border: 0; min-width: 0; display: grid; gap: 8px; }
.opts legend { padding: 0; margin-bottom: 10px; font-weight: 600; font-size: 1rem; }
.opt { position: relative; display: block; cursor: pointer; }
.opt-body { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 2px 12px; min-height: 56px; padding: 10px 14px; background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--radius); transition: border-color 140ms, background-color 140ms; }
.opt:hover .opt-body { border-color: var(--text); }
.opt-tick { width: 18px; height: 18px; border: 1px solid var(--line-strong); border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.opt-tick::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--red); transform: scale(0); transition: transform 180ms var(--ease); }
.opt-name { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-weight: 600; overflow-wrap: anywhere; }
.opt-price { font-weight: 650; font-variant-numeric: tabular-nums; }
.opt-money { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: baseline; gap: 2px 8px; }
.opt-was { color: var(--muted); font-size: 0.9375rem; font-weight: 400; font-variant-numeric: tabular-nums; }
.opt-per { grid-column: 3; justify-self: end; color: var(--muted); font-size: 0.875rem; line-height: 1.3; font-variant-numeric: tabular-nums; }
.opt-badge { padding: 1px 7px; border: 1px solid var(--line-strong); border-radius: 5px; color: var(--text); font-size: 0.875rem; font-weight: 700; line-height: 1.4; text-transform: uppercase; letter-spacing: 0.03em; }
.opt-badge.is-red { background: var(--red); border-color: var(--red); color: var(--on-red); }
.opt-badge.is-gold { background: var(--status-degraded); border-color: var(--status-degraded); color: #0B0A0A; }
.opt input:disabled + .opt-body .opt-badge { background: transparent; border-color: var(--line-strong); color: var(--muted); }
.opt-state, .opt-note { grid-column: 2 / -1; color: var(--muted); font-size: 1rem; line-height: 1.3; }
.opt input:checked + .opt-body { border: 2px solid var(--red); padding: 9px 13px; background: var(--red-soft); }
.opt input:checked + .opt-body .opt-tick { border-color: var(--red); }
.opt input:checked + .opt-body .opt-tick::after { transform: scale(1); }
.opt input:focus-visible + .opt-body { outline: 2px solid var(--red-text); outline-offset: 2px; }
.opt input:disabled + .opt-body { border-style: dashed; cursor: not-allowed; color: var(--muted); background: transparent; }
.opt:hover input:disabled + .opt-body { border-color: var(--line-strong); }
.opt.is-out .opt-tick { visibility: hidden; }
.opt.is-out .opt-state { color: var(--text); font-weight: 600; }

.prose .md-button { margin: 4px 8px 4px 0; }
.prose .md-button, .setup-buttons a { min-height: 48px; padding: 8px 20px; text-decoration: none; }
.setup-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.setup-note { margin: 12px 0 0; color: var(--muted); }

.compare-wrap { margin: 0; }
.compare { --pos: 50%; position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--surface); border: 1px solid rgba(244, 239, 233, .14); border-radius: var(--radius-lg); box-shadow: var(--shadow); cursor: ew-resize; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.compare-img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.compare-top { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
/* Each label keeps to its own half, clear of the handle, and wraps when the picture is narrow. */
.compare-label { position: absolute; top: 12px; max-width: calc(50% - 36px); padding: 5px 11px; background: rgba(11, 10, 10, .88); border-radius: 6px; color: var(--text); font-size: 0.875rem; font-weight: 600; line-height: 1.25; pointer-events: none; }
.compare-label.is-with { left: 12px; }
.compare-label.is-without { right: 12px; }
.compare-line { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px; background: var(--text); pointer-events: none; }
.compare-handle { position: absolute; top: 50%; left: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; background: var(--red); border: 2px solid var(--text); border-radius: 50%; box-shadow: 0 6px 20px rgba(0, 0, 0, .5); }
.compare-handle::before, .compare-handle::after { content: ""; position: absolute; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-left: 2px solid var(--text); border-bottom: 2px solid var(--text); }
.compare-handle::before { left: 9px; transform: rotate(45deg); }
.compare-handle::after { right: 9px; transform: rotate(-135deg); }
/* Invisible, and the size of the picture, so focus from either direction brings the whole slider into view. */
.compare-range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; pointer-events: none; }
.compare:has(.compare-range:focus-visible) .compare-handle { outline: 2px solid var(--red-text); outline-offset: 2px; }
.compare-note { margin-top: 10px; color: var(--muted); font-size: 0.875rem; }

.included { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px 24px; }
.included li { position: relative; padding-left: 28px; overflow-wrap: anywhere; }
.included li::before { content: ""; position: absolute; left: 4px; top: 0.38em; width: 12px; height: 6px; border-left: 2px solid var(--red-text); border-bottom: 2px solid var(--red-text); transform: rotate(-45deg); }
.features { margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; }
.features .box { padding: 20px; }
.features dt { font-weight: 650; margin-bottom: 6px; }
.features dd { margin: 0; color: var(--muted); }
.faq { padding: 6px 24px; }
.faq details + details { border-top: 1px solid var(--line); }
.faq .fold > summary { min-height: 56px; margin: 0; padding: 8px 0; }
.faq details p { margin: 0 0 18px; color: var(--muted); max-width: 70ch; }
.faq-more { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 14px 0 0; color: var(--muted); }
.faq-more a { min-height: 44px; padding: 0 16px; text-decoration: none; }

.coupon summary { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; list-style: none; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: .22em; }
.coupon summary::-webkit-details-marker { display: none; }
.coupon[open] summary { margin-bottom: 6px; }

.check { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 10px; align-items: start; min-height: 44px; font-size: 1rem; line-height: 1.45; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--red); cursor: pointer; }
.check-links { display: flex; flex-wrap: wrap; gap: 0 14px; margin-top: -14px; padding-left: 34px; font-size: .9375rem; }
.check-links a { display: inline-flex; align-items: center; min-height: 44px; }

/* The in-page download panel: the page fetches the file itself and shows how far along it is. */
.dl-panel { position: fixed; right: 20px; bottom: 20px; z-index: 50; width: min(380px, calc(100vw - 40px)); padding: 18px 20px; background: var(--surface-2); border: 1px solid var(--line-strong); border-left: 4px solid var(--red); border-radius: var(--radius); box-shadow: 0 18px 50px rgba(0, 0, 0, .6); }
.dl-panel.is-done { border-left-color: var(--status-ok); }
.dl-title { margin: 0 0 10px; font-weight: 700; }
.dl-note { margin: 8px 0 0; color: var(--muted); font-size: .875rem; overflow-wrap: anywhere; }
.dl-bar { display: block; width: 100%; height: 6px; border: 0; border-radius: 3px; overflow: hidden; background: var(--line); appearance: none; -webkit-appearance: none; }
.dl-bar::-webkit-progress-bar { background: var(--line); }
.dl-bar::-webkit-progress-value { background: var(--red); transition: width 120ms linear; }
.dl-bar::-moz-progress-bar { background: var(--red); }
.dl-panel.is-done .dl-bar::-webkit-progress-value { background: var(--status-ok); }
.dl-panel.is-done .dl-bar::-moz-progress-bar { background: var(--status-ok); }
.dl-close { margin-top: 12px; padding: 6px 14px; background: transparent; color: var(--text); border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; cursor: pointer; }
.dl-close:hover { border-color: var(--text); }

/* ---- Narrower screens ---- */

@media (max-width: 1060px) {
  .hero-home .hero-text { grid-template-columns: minmax(0, 1fr); }
  .hero-home .hero-crack { left: auto; right: var(--gutter); opacity: .5; }
  .hero-art { max-width: 640px; margin: 8px 14px 18px; }
  .hero-art-frame, .hero-art:hover .hero-art-frame { transform: none; }
  .compare-band { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 1000px) {
  .hero:not(.hero-home) .hero-crack { opacity: .35; }
  /* The product page reads top to bottom: what it is, what it looks like, buy it, the detail. */
  .product-top, .no-gallery .product-top { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .product-main, .product-side { display: contents; }
  .product-head { order: 1; }
  .gallery { order: 2; }
  .product-buy { order: 3; }
  .product-info { order: 4; }
}
@media (max-width: 1200px) {
  .app-show { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; }
  .app-show-actions a { padding-inline: 16px; }
}
@media (max-width: 900px) {
  .app-show { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .header-discord { display: none; }
}

/* ---- Small screens: rethought, not shrunk ---- */

/* The long logo stops fitting beside the buttons here, so the mark stands alone. */
@media (max-width: 400px) {
  .site-header .site-logo { min-width: 44px; }
  .site-header .site-logo .logo-long { display: none; }
  .site-header .site-logo .logo-mark { display: block; }
  /* Label over value, so the value gets the whole line. */
  .specs > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .specs dt { font-size: .9375rem; }
}
@media (max-width: 380px) {
  .buy-buttons { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 820px) {
  .nav-wide { display: none; }
  .nav-small { display: block; }
  /* The menu drops down as a sheet under the header, the full width of the screen. */
  .nav-small nav { position: absolute; left: 0; right: 0; top: 100%; display: grid; padding: 8px var(--gutter) 16px; background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: 0 30px 40px -20px #000; }
  .nav-small nav a { min-height: 52px; padding: 0 4px; border-radius: 0; border-bottom: 1px solid var(--line); color: var(--text); font-size: 1.0625rem; }
  .nav-small nav a:last-child { border-bottom: 0; }
  .nav-small nav a[aria-current="page"] { box-shadow: inset 3px 0 0 var(--red); padding-left: 14px; font-weight: 650; }
}

@media (max-width: 720px) {
  :root { --head-h: 60px; }
  body { font-size: 1rem; }
  .page, .page-narrow { padding-top: 28px; padding-bottom: 56px; }
  .cart-link { padding: 0 12px; }
  .cart-word { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .nav-small summary span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .nav-small summary { padding: 0 12px; }

  .hero-text { padding-top: 28px; padding-bottom: 40px; }
  .hero h1 { max-width: none; }
  .hero-home .hero-text { padding-top: 36px; padding-bottom: 48px; gap: 32px; }
  .hero-home .hero-fact { font-size: 1.0625rem; }
  .hero-action .btn, .hero-action .btn-quiet { flex: 1 1 auto; }
  .hero-points { gap: 8px 20px; }
  .hero-art { margin-inline: 0; }
  .hero-art-tag { left: 10px; bottom: -14px; }

  .home-band, .home-first { padding-top: 0; }
  .home-first { padding-top: 40px; }
  .shelf { padding-top: 28px; }
  .shelf-head { display: block; }
  .filter { margin-top: 14px; }

  /* Cards become rows. A thumbnail beside the facts, so a phone shows several products at once. */
  .grid { gap: 10px; grid-template-columns: minmax(0, 1fr); }
  .card { display: grid; grid-template-columns: 128px minmax(0, 1fr); grid-template-areas: "frame line" "frame sub" "frame stock"; grid-template-rows: auto auto 1fr; gap: 2px 14px; padding: 10px; border-radius: var(--radius); min-height: 92px; }
  .card:hover { transform: none; }
  .card:active { background: var(--surface-2); }
  .card-frame { grid-area: frame; align-self: start; border-radius: 6px; }
  .card-line { grid-area: line; display: block; padding: 2px 0 0; }
  .card-price { display: block; margin-top: 2px; }
  .card-name { font-size: 1.375rem; }
  .card-sub { grid-area: sub; margin-top: 0; padding: 0; justify-content: flex-start; }
  .card-stock { grid-area: stock; margin-top: 0; padding: 0; }
  /* The word moves out of the small thumbnail and into the facts, at full size. */
  .card-plate { grid-area: stock; position: static; padding: 0; background: none; border: 0; border-radius: 0; }

  .game-links { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .game-link-text { padding: 10px 12px 12px; }
  .game-link-name { font-size: 1.1875rem; }
  .home-columns { grid-template-columns: minmax(0, 1fr); }
  .home-columns > div { padding: 20px 18px 4px; }
  .home-discord-link { width: 100%; }

  .product { padding-top: 16px; }
  .box { padding: 18px; }
  .faq { padding: 4px 18px; }
  .product-blank { display: none; }
  .buy-action .btn { min-height: 56px; }
  .g-t { width: calc((100% - 24px) / 4); min-height: 44px; }

  .footer-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); padding-top: 36px; }
  .footer-brand { grid-column: 1 / -1; }

  input[type="text"], input[type="email"], input[type="search"], input[type="url"], input[type="number"], input[type="password"], textarea, select { font-size: 16px; }
}

/* ---- Motion off ---- */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; animation: none !important; }
  .card:hover, .game-links a:hover, .btn:hover, .btn-quiet:hover { transform: none; }
  .card:hover .card-frame img, .game-links a:hover img { transform: none; }
  .home-section-head > a:hover::after, .more-link:hover::after { transform: rotate(45deg); }
}
@media (prefers-reduced-motion: reduce) and (min-width: 1061px) {
  /* The hero picture keeps its resting tilt. */
  .hero-art:hover .hero-art-frame { transform: perspective(1400px) rotateY(-7deg) rotateX(2deg); }
}

/* ---- Print ---- */

@media print {
  .site-header { position: static; }
  .hero-crack, .site-footer nav, .nav-small, .nav-wide, .header-actions { display: none; }
}
