/* ===========================================================================
   RJLA Creative Coins
   ---------------------------------------------------------------------------
   POV: a coin is a STRUCK DOCUMENT. This reads as the certificate of
   authenticity and the mint floor - not a storefront, and not the shiny
   gold-gradient coin site that every competitor ships.

   v2 inverts the page. v1 was bone paper with ink type - correct for a
   document, wrong for metal. Metal needs darkness to read: relief is only
   visible because of the shadow sitting in it. So the page is now struck
   from the dark, and the bone sections are the paperwork that comes with it.

   TYPE - unchanged from v1 and still the whole argument:
     Bodoni Moda   the engraving-era Didone cut for currency, share
                   certificates and medals. Variable, so optical size is real.
     Public Sans   the US Web Design System face. Institutional by provenance.
     IBM Plex Mono specs, figures, legends.

   COLOUR - measured, not vibed. See the contrast notes against each token.
   =========================================================================== */

@import url("assets/fonts.css");

:root {
  /* --- surfaces ------------------------------------------------------ */
  --void: #0a0c10;        /* near-black with a blue cast. never #000     */
  --panel: #12161f;       /* raised card on the dark                     */
  --panel-2: #181d28;     /* hover / inset                               */
  --bone: #f2ede3;        /* the paper sections. never #fff             */
  --bone-2: #e8e1d3;

  /* --- ink ----------------------------------------------------------- */
  --on-dark: #f2ede3;     /* bone on void   = 15.8:1  AAA               */
  --on-dark-dim: #a8a496; /* muted on void  =  7.4:1  AAA               */
  --on-light: #15120c;    /* warm near-black on bone = 15.4:1 AAA       */
  --on-light-dim: #4d4639;/* on bone        =  7.9:1  AAA               */

  /* --- brass --------------------------------------------------------- */
  /* TWO tokens on purpose. --brass on void measures 8.9:1 and is safe at
     any size. --brass-ink is the ONLY brass allowed on bone, where plain
     brass falls to ~3.4:1 and is large-text-only.                        */
  --brass: #c9a227;
  --brass-lite: #e7ce8e;  /* on void = 12.6:1, for display type         */
  --brass-ink: #6e5526;   /* on bone =  6.6:1, body-safe                */
  --patina: #2e4a43;
  --oxblood: #7a2b22;

  --rule: rgba(242, 237, 227, 0.14);
  --rule-light: rgba(21, 18, 12, 0.14);

  --display: "Bodoni Moda", Georgia, "Times New Roman", serif;
  --body: "Public Sans", system-ui, -apple-system, Segoe UI, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;

  --gutter: clamp(1.25rem, 4vw, 5rem);
  --maxw: 1440px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--void);
  color: var(--on-dark);
  font-family: var(--body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  font-weight: 350;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, picture { max-width: 100%; display: block; }

/* A link reset that forgets :where() will eat every button on the page.
   Scoped low so .btn and .navlinks a keep their own colour.              */
:where(a) { color: var(--brass-lite); text-underline-offset: 0.18em; }
:where(a):hover { color: var(--brass); }

.wrap { width: min(100% - (var(--gutter) * 2), var(--maxw)); margin-inline: auto; }

section { padding-block: clamp(4rem, 9vw, 9rem); position: relative; }

/* Paper sections. The order paperwork, set on bone so it reads as a
   document sitting on the bench rather than more of the mint floor.      */
.paper { background: var(--bone); color: var(--on-light); }
.paper :where(a) { color: var(--brass-ink); }
.paper .eyebrow { color: var(--brass-ink); }
.paper .rule, .paper hr { border-color: var(--rule-light); }

/* ------------------------------------------------------------ eyebrow --- */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.eyebrow::after {
  content: "";
  flex: 1 1 auto;
  max-width: 14rem;
  height: 1px;
  background: currentColor;
  opacity: 0.45;
}

/* ------------------------------------------------------------- topbar --- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 12, 16, 0.86);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--rule);
}
.topbar__in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  min-height: 74px;
}
.brandline { display: flex; align-items: center; gap: 0.75rem; text-decoration: none; }
.brandline img { width: 34px; height: 34px; }
.brandline span {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: 0.01em;
  color: var(--on-dark);
}
.navlinks { display: flex; gap: clamp(1rem, 2.4vw, 2.25rem); list-style: none; margin: 0; padding: 0; }
.navlinks a {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  text-decoration: none;
}
.navlinks a:hover { color: var(--brass-lite); }
@media (max-width: 860px) { .navlinks { display: none; } }

/* ---------------------------------------------------------------- btn --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.95rem 1.5rem;
  border: 1px solid var(--brass);
  background: var(--brass);
  color: #15120c;            /* literal: this sits ON brass, not on a surface */
  text-decoration: none;
  transition: background 0.18s ease, color 0.18s ease;
}
.btn:hover { background: var(--brass-lite); border-color: var(--brass-lite); color: #15120c; }
.btn--ghost { background: transparent; color: var(--brass-lite); }
.btn--ghost:hover { background: rgba(201, 162, 39, 0.14); color: var(--brass-lite); }
.paper .btn { color: #15120c; }
.paper .btn--ghost { color: var(--brass-ink); border-color: var(--brass-ink); }

/* --------------------------------------------------------------- hero --- */
.hero { padding-top: clamp(3rem, 7vw, 6rem); padding-bottom: clamp(3rem, 7vw, 6rem); }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

/* HEIGHT IS A BREAKPOINT AXIS. A 1440x900 laptop is ~617-685px of real
   viewport once Chrome's own chrome is subtracted - the ordinary case, not
   an edge case. min() caps the display type against viewport HEIGHT as well
   as width, which is what stops the lede being guillotined by the fold.   */
.hero h1 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(2.6rem, min(1.6rem + 7.4vw, 17vh), 8rem);
  line-height: 0.94;
  letter-spacing: -0.02em;
  margin: 0 0 1.5rem;
}
.hero h1 em { font-style: italic; font-weight: 500; color: var(--brass-lite); }
.lede {
  font-size: clamp(1.02rem, 0.96rem + 0.4vw, 1.2rem);
  color: var(--on-dark-dim);
  max-width: 46ch;
  margin: 0;
}
.tagline {
  font-family: var(--display);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.35rem);
  color: var(--brass-lite);
  margin: 1.4rem 0 0;
  letter-spacing: -0.01em;
}
.hero__cta { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-top: 2rem; }
.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  margin-top: 2.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
}

/* The hero stack: his own medallion over a bed of real struck metal.     */
.hero__coin { position: relative; min-width: 0; }
.hero__coin svg, .hero__coin img { width: 100%; height: auto; }
.hero__coin figure {
  margin: 0;
  position: relative;
  filter: drop-shadow(0 1px 0 rgba(242, 237, 227, 0.12)) drop-shadow(0 22px 44px rgba(0, 0, 0, 0.6));
}
.hero__plate {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}
/* The hero strip DOES crop to a band on purpose - it is a texture rule under
   the medallion, not a gallery. Square keeps the three consistent. */
.hero__plate img {
  width: 100%;
  aspect-ratio: 1 / 1;
  height: auto;
  object-fit: cover;
  border: 1px solid var(--rule);
  filter: saturate(0.9) contrast(1.04);
}

@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__coin { max-width: 340px; }
}

/* Short viewports: buy back vertical space everywhere, not just on type. */
@media (min-width: 901px) and (max-height: 780px) {
  .hero { padding-top: 2.25rem; padding-bottom: 2.5rem; }
  /* 17vh still guillotines the lede at 685px and 617px - the two heights
     Chrome actually leaves on a 1440x900 and a 1536x864 laptop. The
     headline runs four lines, so each 1vh shaved is worth ~4x in saved
     column height. Measured by pressure_test.py, not guessed.            */
  .hero h1 { font-size: clamp(2.6rem, min(1.6rem + 7.4vw, 15.5vh), 8rem); margin-bottom: 1rem; }
  .lede { font-size: 1.05rem; line-height: 1.45; }
  .hero__cta { margin-top: 1.4rem; }
  .hero__meta { margin-top: 1.4rem; padding-top: 0.9rem; gap: 0.35rem 1.5rem; }
  .eyebrow { margin-bottom: 0.9rem; }
  .topbar__in { min-height: 60px; }
  .hero__plate img { aspect-ratio: 4 / 3; }
}
@media (min-width: 901px) and (max-height: 660px) {
  .hero { padding-top: 1.5rem; padding-bottom: 1.75rem; }
  .hero__grid { gap: 2.5rem; }
  .lede { font-size: 1rem; }
  .hero__plate { display: none; }
}

/* -------------------------------------------------------------- specs --- */
h2 {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(1.9rem, 1.1rem + 3.2vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
}
h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.22rem;
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
}
.section__intro { max-width: 52ch; color: var(--on-dark-dim); }
.paper .section__intro { color: var(--on-light-dim); }

.specs { margin-top: 3rem; border-top: 1px solid var(--rule); }
.paper .specs { border-color: var(--rule-light); }
.spec {
  display: grid;
  grid-template-columns: 3rem minmax(0, 14rem) minmax(0, 1fr);
  gap: clamp(0.75rem, 2.5vw, 2.5rem);
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
}
.paper .spec { border-color: var(--rule-light); }
.spec__i { font-family: var(--mono); font-size: 0.72rem; color: var(--brass); letter-spacing: 0.1em; padding-top: 0.3rem; }
.paper .spec__i { color: var(--brass-ink); }
.spec__v { color: var(--on-dark-dim); margin: 0; }
.paper .spec__v { color: var(--on-light-dim); }
@media (max-width: 720px) {
  .spec { grid-template-columns: 2.2rem minmax(0, 1fr); }
  .spec__v { grid-column: 2; }
}

/* ------------------------------------------------------------ gallery --- */
/* THE HONEST GALLERY. These are macro details of real struck work - relief
   depth, enamel fill, bevels. They are deliberately NOT presented as
   "our portfolio" of finished client coins, because the marks on those
   belong to other people and this site shows capability, never borrowed
   badges.                                                                 */
/* MASONRY, NOT A FIXED-HEIGHT GRID. These crops are deliberately different
   shapes - 590x120 next to 320x370 - because each one is cut to whatever
   region of the source art is free of third-party marks. An earlier version
   forced them all into a 240px tile with object-fit:cover, which CROPPED THE
   CROPS: the wide ones lost everything but their middle quarter.
   CSS columns let every image show at its true aspect ratio, uncut. */
.gallery {
  margin-top: 3rem;
  columns: 3;
  column-gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
@media (max-width: 1100px) { .gallery { columns: 2; } }
@media (max-width: 620px)  { .gallery { columns: 1; } }

.tile {
  position: relative;
  background: var(--void);
  overflow: hidden;
  break-inside: avoid;
  margin: 0 0 1px;
  display: block;
}
.tile img {
  width: 100%;
  height: auto;          /* width+height attrs give the true aspect ratio */
  display: block;
  transition: transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.4s ease;
  filter: saturate(0.92) contrast(1.05);
}
.tile:hover img { transform: scale(1.045); filter: saturate(1) contrast(1.08); }
@media (prefers-reduced-motion: reduce) {
  .tile img, .tile:hover img { transition: none; transform: none; }
}
/* Caption sits UNDER the image, not over it. Absolutely-positioned captions
   worked on a fixed-height grid; in a masonry column they land on top of the
   NEXT image and read as if they label it. Static also means the type never
   fights a busy photograph for contrast. */
.tile figcaption {
  padding: 0.7rem 0.85rem 0.95rem;
  background: var(--void);
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
}
.tile figcaption b { color: var(--brass-lite); font-weight: 500; }

/* --------------------------------------------------------------- flow --- */
.flow {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: clamp(1.25rem, 3vw, 2.5rem);
  counter-reset: step;
}
.step { position: relative; padding-top: 2.6rem; }
.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  position: absolute;
  top: 0;
  left: 0;
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  color: var(--brass);
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--brass);
  width: 100%;
}
.paper .step::before { color: var(--brass-ink); border-color: var(--brass-ink); }
.step p { color: var(--on-dark-dim); margin: 0; font-size: 0.95rem; }
.paper .step p { color: var(--on-light-dim); }

/* --------------------------------------------------------------- card --- */
.card {
  background: var(--panel);
  border: 1px solid var(--rule);
  padding: clamp(1.5rem, 3vw, 2.25rem);
}
.paper .card { background: rgba(21, 18, 12, 0.035); border-color: var(--rule-light); }
.kv { display: grid; grid-template-columns: minmax(0, 8rem) minmax(0, 1fr); gap: 0.55rem 1.25rem; margin: 1.25rem 0 0; }
.kv dt {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  padding-top: 0.15rem;
}
.paper .kv dt { color: var(--on-light-dim); }
/* An email address is one unbreakable token. Without this it pushes the card
   wider than its grid cell and the whole page gains a horizontal scrollbar -
   caught by pressure_test.py at 768 and 390.                              */
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* Below this the 8rem label column plus an address cannot both fit inside a
   card, so the list stacks instead of fighting for width.                  */
@media (max-width: 620px) {
  .kv { grid-template-columns: 1fr; gap: 0.15rem; }
  .kv dt { padding-top: 0.7rem; }
  .kv dt:first-child { padding-top: 0; }
}

/* -------------------------------------------------------------- edict --- */
/* The standing production rule, set as a legend. Mono because it is a
   condition of sale, not marketing copy.                                  */
.edict {
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.65;
  color: var(--on-dark-dim);
  border-left: 2px solid var(--brass);
  padding-left: 1.1rem;
  margin: 2rem 0 0;
  max-width: 54ch;
}
.paper .edict { color: var(--on-light-dim); border-color: var(--brass-ink); }

/* ----------------------------------------------------------------- pay --- */
.pay__grid {
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(1rem, 2.5vw, 1.75rem);
}
.pay__amt {
  font-family: var(--display);
  font-size: clamp(2rem, 1.2rem + 3vw, 3rem);
  font-weight: 500;
  line-height: 1;
  margin: 0.5rem 0 0;
  letter-spacing: -0.02em;
}
.pay__note {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  margin: 0.75rem 0 0;
}
.paper .pay__note { color: var(--on-light-dim); }

/* ------------------------------------------------------------- contact --- */
.contact__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

/* ---------------------------------------------------------------- foot --- */
footer { border-top: 1px solid var(--rule); padding-block: 3rem; }
.foot__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 2rem; }
.caption {
  font-family: var(--mono);
  font-size: 0.7rem;
  line-height: 1.7;
  color: var(--on-dark-dim);
  margin: 0;
}

/* --------------------------------------------------------------- band --- */
.band { display: block; width: 100%; height: 14px; opacity: 0.5; }

/* -------------------------------------------------------------- a11y --- */
:focus-visible { outline: 2px solid var(--brass-lite); outline-offset: 3px; }
.skip {
  position: absolute;
  left: -9999px;
  background: var(--brass);
  color: #15120c;
  padding: 0.75rem 1rem;
  font-family: var(--mono);
  font-size: 0.8rem;
}
.skip:focus { left: 1rem; top: 1rem; z-index: 100; }

/* ===========================================================================
   SHOP  —  shop.html, custom.html, order-received.html
   ---------------------------------------------------------------------------
   ZERO new colour tokens. --patina and --oxblood were already declared and
   unused; they become the in-stock / sold-out dots. Everything else reuses
   what the brochure page already proved.

   THE LAYOUT IS DECIDED BY THE ARTWORK. These product renders are 1457x991
   and 1774x887 - both faces of a coin side by side. There is no honest way to
   put that in a 3-up card grid: any fixed tile crops it, and the whole brief
   is that the full design is visible. So one product per full-width row, the
   image at its true aspect ratio, and the page scrolls. That is also the
   restrained, one-idea-per-screen answer rather than a dense storefront wall.
   =========================================================================== */

.plates { margin-top: 3.5rem; }

.plate {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);  /* echoes .hero__grid */
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  padding-block: clamp(2.5rem, 6vw, 5rem);
  border-top: 1px solid var(--rule);
}
.paper .plate { border-color: var(--rule-light); }
.plate:first-child { border-top: 0; }
@media (max-width: 900px) {
  .plate { grid-template-columns: 1fr; gap: 1.75rem; }
}

/* NO object-fit, NO fixed height, NO overflow:hidden, NO hover scale.
   Every one of those crops, and pressure_test.py's NOCROP check fails the
   build if any of them creep back in. */
.plate__shot {
  margin: 0;
  border: 1px solid var(--rule);
  background: var(--void);
  filter: drop-shadow(0 1px 0 rgba(242, 237, 227, 0.1)) drop-shadow(0 20px 40px rgba(0, 0, 0, 0.55));
}
.paper .plate__shot { border-color: var(--rule-light); }
.plate__shot img { width: 100%; height: auto; display: block; }

.plate h3 { font-size: clamp(1.35rem, 1rem + 1.2vw, 2rem); margin-bottom: 0.75rem; }
.plate__blurb { color: var(--on-dark-dim); margin: 0 0 1.5rem; }
.paper .plate__blurb { color: var(--on-light-dim); }

.price {
  font-family: var(--display);
  font-size: clamp(1.9rem, 1.2rem + 2.4vw, 2.75rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
  margin: 1.5rem 0 0;
}
.price__note {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  margin: 0.5rem 0 0;
}
.paper .price__note { color: var(--on-light-dim); }

/* The dot is decoration; the words carry the meaning. A colour-only state
   would fail both colour-blindness and the contrast test. */
.stock {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-dark-dim);
  margin: 0.9rem 0 0;
}
.paper .stock { color: var(--on-light-dim); }
.stock::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--patina);
  flex: none;
}
.stock[data-state="out"]::before { background: var(--oxblood); }

/* quantity stepper */
.qty { display: flex; align-items: center; gap: 0; margin: 1.4rem 0 0; }
.qty button {
  font-family: var(--mono);
  font-size: 1rem;
  width: 2.6rem; height: 2.6rem;
  background: transparent;
  color: var(--on-dark);
  border: 1px solid var(--rule);
  cursor: pointer;
}
.paper .qty button { color: var(--on-light); border-color: var(--rule-light); }
.qty button:hover:not(:disabled) { border-color: var(--brass); color: var(--brass-lite); }
.paper .qty button:hover:not(:disabled) { color: var(--brass-ink); border-color: var(--brass-ink); }
.qty button:disabled { opacity: 0.35; cursor: not-allowed; }
.qty output {
  font-family: var(--mono);
  font-size: 0.9rem;
  min-width: 3.2rem;
  text-align: center;
  padding: 0.65rem 0;
  border-block: 1px solid var(--rule);
  color: var(--on-dark);
}
.paper .qty output { border-color: var(--rule-light); color: var(--on-light); }
.plate__actions { display: flex; flex-wrap: wrap; gap: 0.85rem; align-items: center; margin-top: 1.4rem; }

/* ------------------------------------------------------------------ cart --- */
/* A section at the bottom of the page. Deliberately NOT a sticky drawer or a
   floating badge - those are the tell of every templated storefront, and this
   page is meant to read as a mint, not a mall. */
.cart__lines { margin: 1.5rem 0 0; border-top: 1px solid var(--rule); }
.paper .cart__lines { border-color: var(--rule-light); }
.cartline {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 1rem;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--rule);
}
.paper .cartline { border-color: var(--rule-light); }
.cartline b { font-weight: 500; color: var(--on-dark); }
.paper .cartline b { color: var(--on-light); }
.cartline span { font-family: var(--mono); font-size: 0.8rem; color: var(--on-dark-dim); }
.paper .cartline span { color: var(--on-light-dim); }
.cartline button {
  background: none; border: 0; cursor: pointer; padding: 0.35rem;
  font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--on-dark-dim);
}
.paper .cartline button { color: var(--on-light-dim); }
.cartline button:hover { color: var(--brass-lite); }
.paper .cartline button:hover { color: var(--brass-ink); }

.cart__total {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 1rem; margin-top: 1.5rem;
  font-family: var(--display); font-size: 1.5rem; font-weight: 500;
}
.cart__note {
  font-family: var(--mono); font-size: 0.72rem; line-height: 1.7;
  color: var(--on-dark-dim); margin: 1rem 0 0;
}
.paper .cart__note { color: var(--on-light-dim); }
.cart__empty { color: var(--on-dark-dim); margin: 1.25rem 0 0; }
.paper .cart__empty { color: var(--on-light-dim); }

/* ------------------------------------------------------- configurator --- */
.config {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: clamp(1.25rem, 3vw, 2.25rem);
}
.field { display: flex; flex-direction: column; gap: 0.45rem; min-width: 0; }
.field > label,
.fieldset__legend {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--brass);
}
.paper .field > label,
.paper .fieldset__legend { color: var(--brass-ink); }
.field input[type="file"] { max-width: 100%; }
.field input,
.field select,
.field textarea {
  font-family: var(--body);
  font-size: 0.95rem;
  color: var(--on-dark);
  background: var(--panel);
  border: 1px solid var(--rule);
  padding: 0.7rem 0.8rem;
  width: 100%;
  min-width: 0;
}
.paper .field input,
.paper .field select,
.paper .field textarea {
  color: var(--on-light);
  background: rgba(21, 18, 12, 0.03);
  border-color: var(--rule-light);
}
.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible { outline: 2px solid var(--brass-lite); outline-offset: 2px; }
.field .hint {
  font-family: var(--mono); font-size: 0.68rem; line-height: 1.6;
  color: var(--on-dark-dim);
}
.paper .field .hint { color: var(--on-light-dim); }

/* A checkbox row needs the whole grid row. Keeping the labels on one line
   (so "3D relief" doesn't break in half) means they cannot also be squeezed
   into a 236px column - that combination overflowed the page by 81px. */
.field--full { grid-column: 1 / -1; }
/* A GRID, not a flex row. Flex items shrink below their content and the
   label's text (an anonymous flex item) then spills instead of wrapping.
   Grid tracks with min-width:0 wrap cleanly, and the checkbox keeps its
   native metrics without pushing the track wider. */
.checks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.6rem 1.25rem;
}
.checks label {
  /* The checkbox is taken OUT of the content flow and the text is indented
     past it. An in-flow checkbox - inline, flex item, whatever - keeps adding
     its own intrinsic box plus UA margin to the label's min-content width,
     which pushed the grid track 7px past its box at every viewport and
     survived four attempted fixes. Positioned absolutely it contributes
     nothing to width, so the label can never exceed its track. */
  position: relative;
  display: block;
  padding-left: 1.55rem;
  min-width: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--on-dark);
  overflow-wrap: break-word;
}
.checks label input {
  position: absolute;
  left: 0;
  top: 0.28em;
  margin: 0;
}
.paper .checks label { color: var(--on-light); }

/* The live spec line. Rendered in the EXACT format invoice.json uses for its
   `detail` field, so Chad's quote drops straight into build_invoice.py. */
.spec__out {
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--on-dark);
  background: var(--panel);
  border-left: 2px solid var(--brass);
  padding: 1rem 1.1rem;
  margin: 2rem 0 0;
  /* It is a <pre> so the qty/spec line break is preserved - but `pre` does
     NOT wrap, so a long spec string overflowed its own box and pushed the
     whole document's scroll width by 23px. The element's own rect looked
     fine, which is why nothing showed up as an offender. pre-wrap keeps the
     newline AND wraps. */
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.paper .spec__out {
  color: var(--on-light);
  background: rgba(21, 18, 12, 0.04);
  border-color: var(--brass-ink);
}
.quote__note {
  font-family: var(--mono); font-size: 0.72rem; line-height: 1.7;
  color: var(--on-dark-dim); margin: 1rem 0 0;
}
.paper .quote__note { color: var(--on-light-dim); }

/* ------------------------------------------------------------ lightbox --- */
/* GLightbox is themed to the page rather than left on its stock chrome. */
.glightbox-clean .gdesc-inner { background: var(--void); }
.glightbox-clean .gslide-description { background: var(--void); }
.glightbox-clean .gslide-title {
  font-family: var(--display); color: var(--on-dark); font-weight: 500;
}
.glightbox-clean .gslide-desc {
  font-family: var(--mono); font-size: 0.78rem; color: var(--on-dark-dim);
}

/* A handful of spacing helpers so no page needs an inline style= attribute.
   That is what lets the Content-Security-Policy drop 'unsafe-inline'. */
.card__p   { margin: .5rem 0 0; }
.card__cta { margin: 1.1rem 0 0; }
.mt-1 { margin-top: 1.25rem; }
.mt-2 { margin-top: 1.75rem; }
.mt-3 { margin-top: 2.5rem; }
.mt-4 { margin-top: 3rem; }
.stack-sm { margin-top: 1.5rem; }
.rights { display: flex; gap: .6rem; align-items: flex-start; cursor: pointer; }
.rights input { margin-top: .25rem; flex: none; }
 /* Honeypot. left:-9999px is the old trick and it can widen the scroll box;
    the 1px clip pattern provably cannot affect layout at any width. */
.hp {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.card--narrow { max-width: 46rem; }

@media print {
  .topbar, .hero__plate, .gallery, .qty, .plate__actions, #cart { display: none; }
  body { background: #fff; color: #000; }
}
