/* dubem.io
 * ==========================================================================
 * Art direction generated in Stitch, translated here into semantic CSS.
 *
 * WHY A TRANSLATION AND NOT THE EXPORT
 * Stitch emits Tailwind-from-CDN, Google-Fonts-from-CDN, Material Symbols and
 * inline styles. All four are blocked by this site's CSP (style-src 'self',
 * font-src 'self', no unsafe-inline), and utility-class markup is itself a
 * structural fingerprint — the sibling brand is a Tailwind app, and matching
 * its markup shape is the one thing this brand must not do.
 *
 * THE DESIGN
 * A quiet gallery. White ground, generous air, hairline rules, and type doing
 * the work instead of colour. The artwork is the only saturated thing on the
 * page; everything around it is white, near-white and grey.
 *
 * Manrope sets headings, Inter sets prose, JetBrains Mono sets every number,
 * key, address and reference so values align down a column.
 *
 * The vertical left rail is kept from the previous direction: it fixes the
 * page's primary axis as vertical and content flows down columns, which is the
 * deliberate inversion of the sibling brand's horizontal carousels.
 *
 * DELIBERATELY ABSENT: dark panels, gradients, glass/blur, glow, heavy
 * shadows, horizontal scrolling of content, entrance animation.
 *
 * THE ONE EXCEPTION: the collectible itself (`.inspect`). It is a physical
 * plate — thickness, varnish, a reverse — because that is the object the
 * gallery is built around. Nothing else on the page moves like it.
 * ========================================================================== */

/* ==========================================================================
   1. Fonts — self-hosted; font-src is 'self'
   ========================================================================== */

@font-face { font-family:"Manrope"; src:url("/static/fonts/manrope-400.woff2") format("woff2"); font-weight:400; font-display:swap; }
@font-face { font-family:"Manrope"; src:url("/static/fonts/manrope-500.woff2") format("woff2"); font-weight:500; font-display:swap; }
@font-face { font-family:"Manrope"; src:url("/static/fonts/manrope-600.woff2") format("woff2"); font-weight:600; font-display:swap; }
@font-face { font-family:"Manrope"; src:url("/static/fonts/manrope-700.woff2") format("woff2"); font-weight:700; font-display:swap; }
@font-face { font-family:"Manrope"; src:url("/static/fonts/manrope-800.woff2") format("woff2"); font-weight:800; font-display:swap; }
@font-face { font-family:"Inter"; src:url("/static/fonts/inter-400.woff2") format("woff2"); font-weight:400; font-display:swap; }
@font-face { font-family:"Inter"; src:url("/static/fonts/inter-500.woff2") format("woff2"); font-weight:500; font-display:swap; }
@font-face { font-family:"Inter"; src:url("/static/fonts/inter-600.woff2") format("woff2"); font-weight:600; font-display:swap; }
@font-face { font-family:"JetBrains Mono"; src:url("/static/fonts/jetbrains-400.woff2") format("woff2"); font-weight:400; font-display:swap; }
@font-face { font-family:"JetBrains Mono"; src:url("/static/fonts/jetbrains-500.woff2") format("woff2"); font-weight:500; font-display:swap; }

/* ==========================================================================
   2. Tokens
   Every value lives here so the sheet can be imported and re-themed without
   touching a component rule.
   ========================================================================== */

:root {
  /* -- Ground --------------------------------------------------------- */
  --page:        #ffffff;  /* the page and the rail */
  --surface:     #f9f9fb;  /* recessed bands, footer */
  --surface-2:   #f3f3f5;  /* hover */
  --surface-3:   #eeeef0;  /* media wells behind artwork */

  /* -- Line ----------------------------------------------------------- */
  --line:        #e5e5ea;
  --line-2:      #c6c5d2;

  /* -- Ink ------------------------------------------------------------ */
  --text:        #1a1c1d;
  --text-2:      #454650;
  --muted:       #767681;

  /* -- Accent --------------------------------------------------------- */
  --accent:      #1a2b6c;  /* the brand navy, carried over from the mark */
  --accent-hi:   #001455;
  --accent-ink:  #ffffff;

  /* -- Signal --------------------------------------------------------- */
  --tier:        #8a6d1f;
  --ok:          #2f7d4f;
  --danger:      #ba1a1a;

  /* -- Mark (fixed brand asset) --------------------------------------- */
  --mark-outer:  #1a2b6c;
  --mark-inner:  #78a8e8;

  /* -- Layout --------------------------------------------------------- */
  --rail-w:      15.5rem;
  --frame-max:   82rem;
  --measure:     60ch;
  --radius:      .5rem;
  --radius-sm:   .375rem;

  /* -- Space, 4px base ------------------------------------------------ */
  --s-1:.25rem; --s-2:.5rem; --s-3:.75rem; --s-4:1rem;
  --s-5:1.5rem; --s-6:2rem;  --s-7:3rem;   --s-8:4.5rem; --s-9:6rem;

  /* -- Type ----------------------------------------------------------- */
  --font-display:"Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --font:        "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --mono:        "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --t-micro:.6875rem; --t-fine:.75rem; --t-small:.875rem; --t-base:1rem;
  --t-h3:1.125rem;
  --t-h2:clamp(1.375rem, 2.2vw, 1.75rem);
  --t-h1:clamp(2rem, 4vw, 3rem);
  --t-price:clamp(1.75rem, 3.2vw, 2.25rem);
}

/* Interpolable pose for the inspect plate. Written from inspect.js via a
   stylesheet rule (not element.style) so CSP style-src 'self' holds. */
@property --rx    { syntax: "<angle>"; inherits: true; initial-value: 0deg; }
@property --ry    { syntax: "<angle>"; inherits: true; initial-value: 0deg; }
@property --flip  { syntax: "<angle>"; inherits: true; initial-value: 0deg; }
@property --mx    { syntax: "<percentage>"; inherits: true; initial-value: 50%; }
@property --my    { syntax: "<percentage>"; inherits: true; initial-value: 40%; }
@property --shine { syntax: "<number>"; inherits: true; initial-value: 0; }
@property --film  { syntax: "<number>"; inherits: true; initial-value: 0; }
@property --sx    { syntax: "<length>"; inherits: true; initial-value: 0px; }
@property --sy    { syntax: "<length>"; inherits: true; initial-value: 22px; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--t-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-hi); }

:where(a, button, input, select, textarea):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Every number, key and reference is mono with tabular figures so values line
   up down a column. It is the rule that makes the page read as a register
   rather than as generic marketing. */
.num, .mono {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.skip { position: absolute; left: -9999px; }
.skip:focus {
  left: var(--s-4); top: var(--s-4); z-index: 100;
  padding: var(--s-3) var(--s-4);
  background: var(--accent); color: var(--accent-ink);
  border-radius: var(--radius-sm);
}

/* ==========================================================================
   3. Vertical rail
   ========================================================================== */

.rail {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--rail-w);
  display: flex;
  flex-direction: column;
  padding: var(--s-6) 0 var(--s-5);
  background: var(--page);
  border-right: 1px solid var(--line);
  z-index: 10;
}

.rail__mark {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: 0 var(--s-5) var(--s-8);
  text-decoration: none;
  color: var(--text);
}

.rail__wordmark {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -.02em;
}

.rail__links { list-style: none; margin: 0; padding: 0 var(--s-3); display: flex; flex-direction: column; gap: 2px; }

.rail__links a {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-2) var(--s-3);
  border-radius: var(--radius-sm);
  color: var(--text-2);
  text-decoration: none;
  font-size: var(--t-small);
  font-weight: 500;
}

.rail__links a:hover { background: var(--surface-2); color: var(--text); }

.rail__links a[aria-current="page"] {
  background: var(--surface-2);
  color: var(--text);
  font-weight: 600;
}

.rail__foot { margin-top: auto; padding: 0 var(--s-5); }

.rail__account {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-sm);
  color: var(--text);
  text-decoration: none;
  font-size: var(--t-small);
  font-weight: 500;
}

.rail__account:hover { background: var(--surface-2); }
.rail__icon { flex: none; width: 1rem; height: 1rem; opacity: .7; }

/* ==========================================================================
   4. Frame
   ========================================================================== */

.frame { margin-left: var(--rail-w); min-height: 100vh; display: flex; flex-direction: column; }

.frame__main {
  flex: 1;
  width: 100%;
  max-width: var(--frame-max);
  padding: var(--s-8) clamp(var(--s-5), 4vw, var(--s-8));
}

/* ==========================================================================
   5. Lede — the page's one big statement, given real air
   ========================================================================== */

.lede { margin-bottom: var(--s-9); }
.lede--tight { margin-bottom: var(--s-6); }

/* Home only: the thesis sits next to one real item, as a gallery puts
   the piece on a plinth beside the wall text. */
.lede--split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(15rem, 20rem);
  gap: clamp(var(--s-6), 5vw, var(--s-8));
  align-items: center;
}

.lede__caption {
  margin: var(--s-4) 0 0;
  display: flex;
  flex-direction: column;
  gap: .15rem;
  font-size: var(--t-small);
}
.lede__caption a {
  color: var(--text);
  font-family: var(--font-display);
  font-weight: 600;
  text-decoration: none;
}
.lede__caption a:hover { color: var(--accent); }
.lede__caption span { color: var(--muted); font-size: var(--t-fine); }

.lede__eyebrow {
  margin: 0 0 var(--s-3);
  font-family: var(--mono);
  font-size: var(--t-fine);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

.lede__h {
  margin: 0 0 var(--s-4);
  font-family: var(--font-display);
  font-size: var(--t-h1);
  line-height: 1.05;
  letter-spacing: -.035em;
  font-weight: 800;
}

.lede__sub { margin: 0; max-width: var(--measure); color: var(--text-2); font-size: 1.0625rem; }

/* ==========================================================================
   6. Sections
   ========================================================================== */

.section { margin-bottom: var(--s-9); }

.section__h {
  margin: 0 0 var(--s-5);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: var(--t-fine);
  font-weight: 400;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ==========================================================================
   7. Cards
   ========================================================================== */

.columns { display: grid; grid-template-columns: repeat(auto-fill, minmax(17.5rem, 1fr)); gap: var(--s-5); }

.card {
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

/* One soft lift on hover — the only shadow in the design, so it reads as
   interaction rather than decoration. */
.card:hover { border-color: var(--line-2); box-shadow: 0 1px 2px rgba(26,28,29,.04), 0 8px 24px rgba(26,28,29,.06); }

.card__hit { display: flex; flex-direction: column; height: 100%; color: inherit; text-decoration: none; }

.card__media { aspect-ratio: 1 / 1; overflow: hidden; background: var(--surface-3); }
.card__media img { width: 100%; height: 100%; object-fit: cover; }

.card__body { padding: var(--s-4); display: flex; flex-direction: column; flex: 1; }

.card__title {
  margin: 0 0 var(--s-2);
  font-family: var(--font-display);
  font-size: var(--t-h3);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -.015em;
}

.card__desc { margin: 0 0 var(--s-4); font-size: var(--t-small); color: var(--muted); }

/* Pushed to the bottom so the data block bottom-aligns across a row whether or
   not a collection has a description. Ragged rows undercut the whole point of
   values that read down a column. */
.meta { margin: auto 0 0; display: flex; flex-direction: column; }

.meta__pair {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--s-4);
  padding: var(--s-2) 0;
  border-top: 1px solid var(--line);
}

.meta dt { font-family: var(--mono); font-size: var(--t-micro); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.meta dd { margin: 0; font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: var(--t-small); color: var(--text); }

/* ==========================================================================
   8. Vertical list
   ========================================================================== */

.stack { list-style: none; margin: 0; padding: 0; }
.row { border-bottom: 1px solid var(--line); }

.row__hit {
  display: grid;
  grid-template-columns: 2.5rem 1fr auto;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-3) var(--s-2);
  color: inherit;
  text-decoration: none;
}

.row__hit:hover { background: var(--surface); }

.row__thumb { width: 2.5rem; height: 2.5rem; overflow: hidden; background: var(--surface-3); border-radius: var(--radius-sm); }
.row__thumb img { width: 100%; height: 100%; object-fit: cover; }

.row__text { display: flex; flex-direction: column; min-width: 0; }
.row__name { font-weight: 600; font-size: var(--t-small); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row__sub { font-size: var(--t-fine); color: var(--muted); }
.row__price { font-weight: 500; font-size: var(--t-small); }
.row__meta { display: flex; align-items: center; gap: var(--s-4); }

/* ==========================================================================
   9. Item detail
   ========================================================================== */

.detail { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: clamp(var(--s-6), 5vw, var(--s-8)); align-items: start; }

.detail__media { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface-3); }
.detail__media--inspect { border: 0; background: transparent; overflow: visible; }
.detail__noimg { aspect-ratio: 1 / 1; }

/* ==========================================================================
   9a. Inspect — the collectible as a physical plate
   ========================================================================== */

.inspect {
  --rx: 0deg;
  --ry: 0deg;
  --flip: 0deg;
  --mx: 22%;
  --my: 18%;
  --shine: .28;
  --film: .1;
  --sx: 14px;
  --sy: 22px;
  margin: 0;
}

.inspect__space {
  position: relative;
  perspective: 760px;
  perspective-origin: 50% 42%;
  padding: 1.25rem 1rem 2rem;
}

.inspect__space::after {
  content: "";
  position: absolute;
  left: 18%;
  right: 18%;
  bottom: .55rem;
  height: 1.35rem;
  border-radius: 50%;
  background: radial-gradient(ellipse at 50% 50%, rgba(26,28,29,.18), rgba(26,28,29,0) 72%);
  transform: translate(var(--sx), 0);
  pointer-events: none;
  z-index: 0;
}

.inspect__stage {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: start;
  cursor: pointer;
  transform-style: preserve-3d;
  -webkit-tap-highlight-color: transparent;
}
div.inspect__stage { cursor: inherit; }

.inspect__stage:focus { outline: none; }
.inspect__stage:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 6px;
  border-radius: calc(var(--radius) + 2px);
}

.inspect__bob {
  transform-style: preserve-3d;
}

.inspect--hero .inspect__bob,
.inspect--detail .inspect__bob {
  animation: inspect-bob 7.5s ease-in-out infinite;
}

.inspect.is-held .inspect__bob,
.inspect.is-flipped .inspect__bob {
  animation-play-state: paused;
}

@keyframes inspect-bob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-9px); }
}

/* Resting three-quarter — the plate is an object on a plinth, not a flat
   thumbnail. Hover or flip squares it up so the pointer tilt / reverse can
   be read cleanly. */
.inspect__pose {
  transform-style: preserve-3d;
  transform: rotateY(-18deg) rotateX(7deg);
  transition: transform 560ms cubic-bezier(.2, .8, .2, 1);
}
.inspect--hero .inspect__pose,
.inspect--detail .inspect__pose {
  transform: rotateY(-18deg) rotateX(7deg);
}
.inspect.is-held .inspect__pose,
.inspect.is-flipped .inspect__pose {
  transform: rotateY(0deg) rotateX(0deg);
}

.inspect__card,
.inspect__gimbal {
  position: relative;
  transform-style: preserve-3d;
}

.inspect__card {
  aspect-ratio: 1 / 1;
  transform: rotateY(var(--flip));
  transition: transform 620ms cubic-bezier(.2, .8, .2, 1);
}

.inspect__gimbal {
  height: 100%;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  transition: transform 140ms ease-out;
}

.inspect__sides {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  pointer-events: none;
}

.inspect__side {
  position: absolute;
  background: #121a38;
}

.inspect__side--e,
.inspect__side--w {
  top: 0;
  bottom: 0;
  width: 8px;
}
.inspect__side--e {
  right: 0;
  transform-origin: right center;
  transform: rotateY(90deg);
  background: linear-gradient(#0e1630, #24366e, #0e1630);
}
.inspect__side--w {
  left: 0;
  transform-origin: left center;
  transform: rotateY(-90deg);
  background: linear-gradient(#0a1024, #162456, #0a1024);
}
.inspect__side--n,
.inspect__side--s {
  left: 0;
  right: 0;
  height: 8px;
}
.inspect__side--n {
  top: 0;
  transform-origin: top center;
  transform: rotateX(90deg);
  background: #2a3d78;
}
.inspect__side--s {
  bottom: 0;
  transform-origin: bottom center;
  transform: rotateX(-90deg);
  background: #0a1024;
}

.inspect__face {
  position: absolute;
  inset: 0;
  border-radius: .7rem;
}

.inspect__face {
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  background: var(--surface-3);
  transform: translateZ(0.6px);
  box-shadow:
    0 1px 0 rgba(255,255,255,.55) inset,
    0 0 0 1px rgba(26,28,29,.08);
}

.inspect__face--back {
  transform: rotateY(180deg) translateZ(0.6px);
  background:
    radial-gradient(120% 80% at 50% -10%, rgba(120,168,232,.18), transparent 55%),
    var(--accent);
  color: var(--accent-ink);
  box-shadow:
    0 1px 0 rgba(255,255,255,.08) inset,
    0 0 0 1px rgba(0,0,0,.25);
}

.inspect__art {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.inspect__rim {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.28),
    inset 0 0 0 2px rgba(26,28,29,.18);
}

.inspect__sheen,
.inspect__film {
  position: absolute;
  inset: -20%;
  pointer-events: none;
}

.inspect__sheen {
  background: radial-gradient(
    140% 80% at var(--mx) var(--my),
    rgba(255,255,255,.72) 0%,
    rgba(255,255,255,.14) 28%,
    rgba(255,255,255,0) 58%
  );
  mix-blend-mode: soft-light;
  opacity: var(--shine);
}

.inspect__film {
  background: conic-gradient(
    from 210deg at var(--mx) var(--my),
    rgba(120,168,232,0) 0deg,
    rgba(120,168,232,.4) 80deg,
    rgba(232,208,150,.22) 150deg,
    rgba(120,168,232,0) 230deg
  );
  mix-blend-mode: soft-light;
  opacity: var(--film);
}

.inspect__seal {
  position: absolute;
  right: .7rem;
  bottom: .7rem;
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .28rem .5rem .26rem .42rem;
  border-radius: 100px;
  background: linear-gradient(160deg, #d8c48a, var(--tier) 55%, #6d5416);
  color: #fff8e8;
  font-family: var(--mono);
  font-size: .625rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  box-shadow:
    0 1px 0 rgba(255,255,255,.35) inset,
    0 1px 2px rgba(26,28,29,.25);
}

.inspect__cert {
  position: relative;
  height: 100%;
  padding: 1.35rem 1.2rem 1.1rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-align: start;
}

.inspect__watermark {
  position: absolute;
  width: 68%;
  height: 68%;
  left: 16%;
  top: 16%;
  color: #fff;
  opacity: .07;
}

.inspect__stamp {
  margin: 0 0 .15rem;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 6vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: .95;
}

.inspect__coll {
  margin: 0;
  font-family: var(--mono);
  font-size: var(--t-micro);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(255,255,255,.55);
}

.inspect__name {
  margin: .35rem 0 0;
  font-size: var(--t-small);
  font-weight: 500;
  line-height: 1.35;
  color: rgba(255,255,255,.88);
}

.inspect__reg {
  margin: auto 0 0;
  padding-top: .7rem;
  border-top: 1px solid rgba(255,255,255,.14);
}

.inspect__reg div {
  display: flex;
  justify-content: space-between;
  gap: var(--s-3);
  padding: .28rem 0;
}

.inspect__reg dt {
  font-family: var(--mono);
  font-size: var(--t-micro);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.48);
}

.inspect__reg dd {
  margin: 0;
  font-family: var(--mono);
  font-size: var(--t-fine);
  color: #fff;
  text-align: right;
}

.inspect__vault {
  margin: .7rem 0 0;
  font-family: var(--mono);
  font-size: var(--t-micro);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
}

.inspect__hint {
  margin: -.4rem 0 0;
  text-align: center;
  font-family: var(--mono);
  font-size: var(--t-micro);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}

.inspect--hero .inspect__space { padding: 1rem .6rem 1.8rem; }

.detail__h { margin: 0 0 var(--s-1); font-family: var(--font-display); font-size: var(--t-h2); line-height: 1.15; letter-spacing: -.025em; font-weight: 700; }
.detail__coll { margin: 0 0 var(--s-5); font-size: var(--t-small); color: var(--muted); }
.detail__price { margin: 0 0 var(--s-5); font-family: var(--mono); font-size: var(--t-price); font-weight: 500; letter-spacing: -.02em; }
.detail__buy { margin: 0 0 var(--s-3); }
.detail__note { margin: 0 0 var(--s-6); font-size: var(--t-fine); color: var(--muted); }

.detail__gone { margin: 0 0 var(--s-4); padding: var(--s-3) var(--s-4); border-left: 2px solid var(--muted); background: var(--surface); color: var(--text-2); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }

/* ==========================================================================
   10. Buttons
   ========================================================================== */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2);
  padding: var(--s-3) var(--s-5);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-sm);
  background: var(--page);
  color: var(--text);
  font: inherit; font-size: var(--t-small); font-weight: 600;
  text-decoration: none; cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease;
}

.btn:hover { background: var(--surface-2); color: var(--text); }

.btn--primary {
  width: 100%;
  padding: var(--s-4) var(--s-5);
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.btn--primary:hover { background: var(--accent-hi); border-color: var(--accent-hi); color: var(--accent-ink); }

/* ==========================================================================
   11. Prose, spec table
   ========================================================================== */

.prose { max-width: var(--measure); color: var(--text-2); }
.prose--wide { max-width: 46rem; }
.prose h2 { margin: var(--s-6) 0 var(--s-2); font-family: var(--font-display); font-size: var(--t-base); color: var(--text); }
.prose p { margin: 0 0 var(--s-4); }

.spec { margin: var(--s-6) 0 0; border-top: 1px solid var(--line); }

.spec__pair { display: flex; justify-content: space-between; gap: var(--s-4); padding: var(--s-3) 0; border-bottom: 1px solid var(--line); }
.spec dt { font-family: var(--mono); font-size: var(--t-micro); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.spec dd { margin: 0; font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: var(--t-small); color: var(--text); text-align: right; }
.spec dd.is-tier { color: var(--tier); font-weight: 500; }

/* ==========================================================================
   12. Crumbs, pager, empty states
   ========================================================================== */

.crumbs { margin-bottom: var(--s-5); font-size: var(--t-fine); color: var(--muted); }
.crumbs a { color: var(--text-2); text-decoration: none; }
.crumbs a:hover { color: var(--text); text-decoration: underline; }
.crumbs span[aria-hidden] { margin: 0 var(--s-2); opacity: .6; }

.pager { display: flex; align-items: center; gap: var(--s-5); margin-top: var(--s-6); padding-top: var(--s-5); border-top: 1px solid var(--line); font-size: var(--t-small); }
.pager__pos { font-family: var(--mono); color: var(--muted); }

.empty { color: var(--muted); }
.blank { padding: var(--s-8) 0; max-width: var(--measure); }
.blank__h { margin: 0 0 var(--s-2); font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; color: var(--text); }
.blank__sub { margin: 0 0 var(--s-5); color: var(--muted); }

/* ==========================================================================
   13. Status pills
   ========================================================================== */

.pill {
  display: inline-block; margin: 0 0 var(--s-3);
  padding: .2rem .5rem;
  border: 1px solid var(--line-2); border-radius: 100px;
  font-family: var(--mono); font-size: var(--t-micro);
  letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}

.pill--delivered { border-color: var(--ok); color: var(--ok); }
.pill--paid, .pill--delivering { border-color: var(--tier); color: var(--tier); }
.pill--failed, .pill--cancelled, .pill--expired { border-color: var(--danger); color: var(--danger); }

/* ==========================================================================
   14. Checkout
   ========================================================================== */

.checkout { display: grid; grid-template-columns: minmax(0,20rem) minmax(0,1fr); gap: clamp(var(--s-5), 4vw, var(--s-7)); align-items: start; }

.checkout__summary { padding: var(--s-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.checkout__media { margin-bottom: var(--s-4); aspect-ratio: 1/1; overflow: hidden; background: var(--surface-3); border-radius: var(--radius-sm); }
.checkout__media img { width: 100%; height: 100%; object-fit: cover; }
.checkout__name { margin: 0 0 var(--s-1); font-family: var(--font-display); font-size: var(--t-base); font-weight: 600; }
.checkout__coll { margin: 0 0 var(--s-4); font-size: var(--t-fine); color: var(--muted); }
.checkout__total { margin: 0 0 var(--s-4); padding-bottom: var(--s-4); border-bottom: 1px solid var(--line); font-family: var(--mono); font-size: 1.75rem; font-weight: 500; }

.checkout__note { margin: var(--s-4) 0 0; font-size: var(--t-fine); color: var(--muted); }

/* --- Pay page -------------------------------------------------------------
   The provider's iframe mounts here. dubem renders NO card fields of its own —
   card data must never touch this origin.

   It needs real width and height: squeezed into one half of the two-column
   grid it renders as empty skeletons and the card fields never lay out. So
   the pay page stacks instead — the order summary collapses to a strip and
   the widget takes the full content width. */

.checkout--pay { grid-template-columns: 1fr; gap: var(--s-5); }

.checkout--pay .checkout__summary {
  display: grid;
  grid-template-columns: 4.5rem 1fr auto;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-4);
}
.checkout--pay .checkout__media { width: 4.5rem; margin: 0; }
.checkout--pay .checkout__name,
.checkout--pay .checkout__coll { margin: 0; }
.checkout--pay .checkout__total { margin: 0; padding: 0; border: 0; font-size: 1.5rem; }
.checkout--pay .checkout__summary .spec { display: none; }

/* Payment opens in its own window, so this panel is a launcher, not a frame. */
.pay {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  text-align: center;
}

.btn--wide { width: 100%; max-width: 26rem; }

.pay__note {
  margin: 1rem auto 0;
  max-width: 30rem;
  color: var(--text-2);
  font-size: 0.9rem;
  line-height: 1.5;
}

.pay__fallback {
  margin: 1.25rem auto 0;
  max-width: 30rem;
  font-size: 0.82rem;
  color: var(--muted);
}

/* Once payment is open the launcher recedes; the note carries the state. */
.pay.is-open #pay-open { opacity: 0.55; }
.pay.is-blocked .pay__fallback { font-size: 0.95rem; color: var(--text); }
.pay.is-blocked .pay__note { color: var(--danger); }

@media (max-width: 56.25rem) {
  .checkout--pay .checkout__summary { grid-template-columns: 3rem 1fr; }
  .checkout--pay .checkout__total { grid-column: 1 / -1; }
  .pay { height: clamp(34rem, 70vh, 48rem); }
}

/* ==========================================================================
   15. Forms
   ========================================================================== */

.narrow { max-width: 26rem; }
.form { margin: 0 0 var(--s-5); }
.field { margin-bottom: var(--s-5); }

.field__label { display: block; margin-bottom: var(--s-2); font-size: var(--t-small); font-weight: 500; color: var(--text-2); }

.field__input {
  width: 100%;
  padding: var(--s-3) var(--s-4);
  background: var(--page);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit; font-size: var(--t-small);
}

.field__input:focus { border-color: var(--accent); }
.field__input::placeholder { color: var(--muted); }
.field--bad .field__input { border-color: var(--danger); }

.field__hint, .field__error { margin: var(--s-2) 0 0; font-size: var(--t-fine); }
.field__hint { color: var(--muted); }
.field__error { color: var(--danger); }

.banner { margin: 0 0 var(--s-5); padding: var(--s-3) var(--s-4); border-left: 2px solid var(--accent); background: var(--surface); font-size: var(--t-small); color: var(--text-2); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.banner--bad { border-left-color: var(--danger); }
.banner--good { border-left-color: var(--ok); }

.notice { margin: 0 0 var(--s-6); padding: var(--s-4) var(--s-5); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.notice p { margin: 0 0 var(--s-3); }

.form__aside { margin: 0 0 var(--s-2); font-size: var(--t-small); color: var(--text-2); }
.form__legal { margin: var(--s-5) 0 0; font-size: var(--t-fine); color: var(--muted); }

.account__actions { display: flex; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-6); }
.account__logout { margin: 0; }

/* Honeypot: hidden from people, left reachable for automated submitters.
   Off-screen rather than display:none, since some bots skip hidden inputs. */
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Cloudflare Turnstile: the checkbox on /contact. Size is the widget's, not ours. */
.cf-turnstile { margin: 0; }
.field--bad .cf-turnstile { outline: 1px solid var(--danger); outline-offset: 4px; }

/* Legal/help pages carry real tables of processors and retention. */
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 var(--s-5); font-size: var(--t-small); }
.prose th, .prose td { text-align: left; padding: var(--s-2) var(--s-3); border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { font-weight: 600; color: var(--text); }
.prose td { color: var(--text-2); }
.prose ul { margin: 0 0 var(--s-4); padding-left: var(--s-5); }
.prose li { margin-bottom: var(--s-2); }
.prose code { font-family: var(--mono); font-size: .9em; background: var(--surface); padding: .1em .35em; border-radius: 3px; }

/* Wide tables must scroll inside themselves, never the page. */
.prose { overflow-x: auto; }

/* ==========================================================================
   16. Footer
   ========================================================================== */

.foot { border-top: 1px solid var(--line); padding: var(--s-7) clamp(var(--s-5), 4vw, var(--s-8)); background: var(--surface); }
.foot__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: var(--s-6); max-width: var(--frame-max); }

.foot__h { margin: 0 0 var(--s-3); font-size: var(--t-fine); font-weight: 600; color: var(--text); }
.foot__col ul { list-style: none; margin: 0; padding: 0; }
.foot__col li { margin-bottom: var(--s-2); }
.foot__col a { color: var(--muted); text-decoration: none; font-size: var(--t-small); }
.foot__col a:hover { color: var(--text); }

/* The expanded name, stated once and quietly. Mono and tracked-out so it reads
   as a mark rather than as a sentence competing with the copy above it. */
.foot__expansion {
  margin: var(--s-6) 0 0;
  padding-top: var(--s-5);
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: var(--t-micro);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}

/* No dotted underline — the expansion is spelled out right beside it, so the
   default abbr affordance would only add visual noise. */
.foot__expansion abbr { text-decoration: none; font-weight: 600; color: var(--text-2); }

/* The rule now belongs to the expansion line above it. */
.foot__legal { margin: var(--s-3) 0 0; max-width: var(--measure); font-size: var(--t-fine); color: var(--muted); }

/* ==========================================================================
   17. Narrow screens
   ========================================================================== */

@media (max-width: 56.25rem) {
  .rail {
    position: static; width: auto;
    flex-direction: row; align-items: center; gap: var(--s-3);
    padding: var(--s-3) var(--s-4);
    border-right: 0; border-bottom: 1px solid var(--line);
    overflow-x: auto;
  }
  .rail__mark { padding: 0 var(--s-3) 0 0; }
  .rail__links { flex-direction: row; padding: 0; }
  .rail__links a { white-space: nowrap; }
  .rail__foot { margin-top: 0; margin-left: auto; padding: 0; }

  .frame { margin-left: 0; }
  .frame__main { padding: var(--s-6) var(--s-4); }

  .detail, .checkout { grid-template-columns: 1fr; }
  .lede--split { grid-template-columns: 1fr; }
  .lede--split .lede__issue { max-width: 22rem; margin-inline: auto 0; }
  .inspect--hero .inspect__space,
  .inspect--detail .inspect__space { padding-left: 1.35rem; padding-right: 1.35rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration:.01ms !important; transition-duration:.01ms !important; }
  .inspect__hint-tilt { display: none; }
}
