/* =========================================================================
   The public deck page — /{lang}/archetypes (REQ-742, REQ-800, REQ-801).

   Moved out of the template's <style> block on 2026-10-26 (REQ-801 i): a
   fingerprinted file is kept by the browser across visits and served by the
   edge; 140 lines inline were re-sent with every page. Each vector is the
   homepage's cover-flow: the stage, the cards and the detail pane come from
   `cover-flow.css`, the component's own stylesheet, rather than from
   `home.css` — that one carries the whole landing page, and pulling it onto a
   v1.0 page is the cascade-reach mistake the design-system rules name. Every
   colour below is a `var()` out of `brand-tokens.css`, which
   `tarot-reading.css` already imports.
   ========================================================================= */

.atlas-hero {
  padding: 7rem 2rem 2.4rem;
  text-align: center;
  position: relative;
  max-width: 760px;
  margin: 0 auto;
}
.atlas-hero .glyph-row {
  font-size: 1.6rem;
  color: var(--gold-frame);
  letter-spacing: 0.4em;
  margin-bottom: 1.2rem;
}
.atlas-hero h1 {
  font-family: var(--f-display);
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--gold);
  line-height: 1.15;
  margin-bottom: 0.6rem;
}
.atlas-hero .meta {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  color: var(--text-dim);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1.6rem;
}
.atlas-hero p {
  font-size: var(--read-size);
  font-style: normal;
  color: var(--cream-warm);
  line-height: var(--read-lh);
}

/* ── The gender switch — the page's only control ──────────────────────── */
/* REQ-800: the vector glyph bar is gone, so the sticky bar holds the switch
   alone. `top` clears the header (72) and the breadcrumb (48). */
.deck-toolbar {
  position: sticky;
  top: 120px;
  z-index: 31;
  background: rgba(11,10,18,0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
}
.deck-switch {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.35rem 0 0.5rem;
}
.deck-switch-label {
  font-family: var(--f-mono);
  font-size: var(--label-min);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.deck-switch-options { display: flex; }
.deck-switch-options a {
  /* 44px is the iOS HIG touch floor and it is a hard minimum, not a target. */
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  padding: 0 1.5rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--cream-dim);
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color var(--t) var(--ease), background var(--t) var(--ease),
              border-color var(--t) var(--ease);
}
.deck-switch-options a:first-child { border-right: none; border-radius: 3px 0 0 3px; }
.deck-switch-options a:last-child  { border-radius: 0 3px 3px 0; }
.deck-switch-options a[aria-current="page"] {
  background: var(--line-soft);
  color: var(--gold);
  border-color: var(--gold-frame);
}
.deck-switch-options a:focus-visible {
  outline: 2px solid var(--gold-2);
  outline-offset: 2px;
}

/* ── One vector, one cover-flow ──────────────────────────────────────── */
/* `overflow: hidden` on the section, as the homepage's `.carousel-section`
   has: the fan's outer cards reach past the stage, and this is what keeps
   the document body free of horizontal scroll at 360px. */
.deck-vector {
  padding: 3rem 0 2rem;
  max-width: 1200px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}
.deck-vector + .deck-vector { border-top: 1px solid var(--line-soft); }
.deck-vector .vector-header { margin: 0 2rem 1rem; text-align: center; }
.deck-vector .vector-label {
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-dark);
}
.deck-vector .vector-title {
  font-family: var(--f-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--gold);
  line-height: 1.2;
}
.deck-vector .vector-count {
  font-family: var(--f-mono);
  font-size: var(--label-min);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.deck-vector .archetype-split { padding: 0 1rem; }
.deck-vector .cf-info { padding: 0 1rem; }

/* The hole. 29 of 392 combinations carry one gender only, and the vendor
   retired the model that drew the deck — so this is a state the page lives
   in, not a transient one. It is never filled with the other gender's art. */
.arc-card.is-missing .ac-card-img img { display: none; }
.arc-card.is-missing .ac-card-img {
  display: flex;
  align-items: center;
  justify-content: center;
}
.arc-card .ac-missing { display: none; }
.arc-card.is-missing .ac-missing {
  display: block;
  text-align: center;
  padding: 0 1.2rem;
}
/* The hole says WHICH card is missing. An empty frame reads as a broken page;
   the archetype's own name reads as a deck that is honest about its gaps. */
.ac-missing-name {
  font-family: var(--f-display);
  font-size: 1.15rem;
  line-height: 1.3;
  color: var(--gold-dark);
}
.ac-missing-note {
  display: block;
  margin-top: 0.7rem;
  font-family: var(--f-mono);
  font-size: var(--label-min);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.ac-missing-rule {
  display: block;
  width: 46px;
  height: 1px;
  margin: 0.9rem auto 0;
  background: linear-gradient(to right, transparent, var(--gold-frame), transparent);
  opacity: 0.6;
}

@media (max-width: 720px) {
  .atlas-hero { padding: 5.5rem 1.2rem 1.6rem; }
  .deck-switch { gap: 0.5rem; padding: 0.2rem 0 0.4rem; }
  .deck-switch-label { display: none; }
  .deck-switch-options a { padding: 0 0.9rem; font-size: 0.66rem; }
  .deck-vector { padding: 2.2rem 0 1.2rem; }
  .deck-vector .vector-header { margin: 0 1.2rem 0.6rem; }
}

/* ── A picture on its way (REQ-801 f-2) ────────────────────────────────── */
/* `is-loading` is set by `archetypes.js` when a card is given its source and
   cleared when the <img> fires `load`. A slow shimmer in the palette's own
   tokens over the frame; the picture stays hidden until it has pixels so a
   half-decoded image never shows. `::before` — the component's vignette is
   the `::after` of `.ac-card-img` (cover-flow.css). */
.arc-card.is-loading .ac-card-img::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(100deg, var(--bg-card) 25%, var(--line-soft) 50%, var(--bg-card) 75%);
  background-size: 220% 100%;
  animation: deck-shimmer 1.8s ease-in-out infinite;
}
.arc-card.is-loading .ac-card-img img { opacity: 0; }
@keyframes deck-shimmer {
  from { background-position: 120% 0; }
  to   { background-position: -120% 0; }
}
@media (prefers-reduced-motion: reduce) {
  .arc-card.is-loading .ac-card-img::before { animation: none; }
}
