/* ============================================================
   OpenHouse — components.css
   Shared component anatomy (DESIGN.md §5). Clean & componentized
   for the _s theme handoff. Requires tokens.css.
   ============================================================ */

/* ---- layout helpers ---- */
.oh-wrap {
  max-width: var(--oh-maxw);
  margin-inline: auto;
  padding-inline: var(--oh-gutter);
}
.oh-rule { height: 1px; background: var(--oh-line); border: 0; margin: 0; }

/* ============================================================
   1 · GLOBAL NAV
   ============================================================ */
/* Sticky, NON-compacting nav (BRANCH §4) — ecosystem-consistent with Explore.
   Full height always; never shrinks. A subtle always-on translucent ground +
   blur keeps content from bleeding through on scroll. Only gentle color
   transitions (links/CTA), no geometry motion, no spring, no compaction. */
.oh-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(13,13,13,0.72);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
          backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid var(--oh-line);
}
.oh-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--oh-s6);
  padding: var(--oh-s5) var(--oh-gutter);
}
.oh-logo { display: inline-flex; align-items: center; flex: 0 0 auto; }
.oh-logo img { display: block; height: 19px; width: auto; opacity: 0.92; }
.oh-nav-right {
  display: flex;
  align-items: center;
  gap: clamp(var(--oh-s4), 2vw, var(--oh-s6));
}
.oh-nav-links {
  display: flex;
  align-items: center;
  gap: clamp(var(--oh-s4), 2vw, var(--oh-s6));
  list-style: none;
  margin: 0;
  padding: 0;
}
.oh-nav-links a {
  font-family: var(--oh-font-body);
  font-size: 0.95rem;
  font-weight: 500;
  color: rgba(255,255,255,0.86);
  letter-spacing: 0;
  transition: color 200ms var(--oh-ease);
  white-space: nowrap;
}
.oh-nav-links a:hover { color: var(--oh-text); }
.oh-nav-links a.is-active {
  color: var(--oh-text);
}
/* Subscribe — matches the live site button EXACTLY (captured a.framer-e1p6no,
   119×39px): translucent white "glass", soft hairline, 14px rounded-rect,
   Inter Display medium, tight 10px/24px padding + line-height 1 → compact 39px
   (the earlier version inherited line-height 1.6, which made it tall/"fat"). */
.oh-nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--oh-font-display);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1;
  color: var(--oh-text);
  background: rgba(255,255,255,0.19);
  border: 1px solid rgba(245,245,245,0.10);
  padding: 10px 24px;
  border-radius: 14px;
  white-space: nowrap;
  transition: background 200ms var(--oh-ease), border-color 200ms var(--oh-ease);
}
.oh-nav-cta:hover { background: rgba(255,255,255,0.26); border-color: rgba(245,245,245,0.18); }

/* ---- mobile burger (hidden on desktop; centered BELOW the logo ≤900px) ---- */
/* C4: ≥44×44 tappable area (the most-used mobile control) — negative
   block margin keeps the nav's visual geometry identical; the burger
   LINES keep their exact size */
.oh-nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 44px; height: 44px;
  margin-block: -11px;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
}
.oh-burger-line {
  display: block;
  width: 28px; height: 1.5px;
  margin-inline: auto;
  background: var(--oh-text);
}

/* ---- MOBILE NAV (≤900px): sticky, non-compacting, translucent (same decision
   as desktop). The desktop link row + Subscribe move into a full-screen overlay.
   Per the user's reference: logo home&decor centered, hamburger directly below. */
@media (max-width: 900px) {
  .oh-nav-inner {
    flex-direction: column;
    align-items: center;
    gap: var(--oh-s3);
    padding-block: var(--oh-s4);
  }
  .oh-nav-right { display: none; }
  .oh-nav-links { display: none; }
  .oh-nav-burger { display: flex; }
}

/* ============================================================
   1b · MOBILE MENU OVERLAY (full-screen, ≤900px)
   #0D0D0D ground, large stacked InterDisplay links, X to close,
   the Subscribe pill living INSIDE the menu (PREHANDOFF Task 2).
   ============================================================ */
.oh-menu {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: var(--oh-bg);
  display: flex;
  flex-direction: column;
  padding: var(--oh-s5) var(--oh-gutter) var(--oh-s8);
  /* Slow, fluid open/close — overlay fades; visibility flips instantly on open
     and is delayed on close so it can fade out. No transform/overshoot on the
     panel itself → smooth, never springy. The FROZEN-CLOCK FAILSAFE below
     (.oh-menu--instant, added by nav.js when the timeline is paused, e.g.
     screenshot/verifier) drops every transition so the menu can never be left
     invisible — same principle as the reveal probe + nav-pill decision. */
  opacity: 0;
  visibility: hidden;
  transition: opacity 640ms var(--oh-ease-fluid), visibility 0s linear 640ms;
}
.oh-menu.is-open {
  opacity: 1;
  visibility: visible;
  transition: opacity 640ms var(--oh-ease-fluid), visibility 0s;
}
/* content rises in on a gentle stagger; reverses together (no delay) on close */
.oh-menu-links a,
.oh-menu-cta {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms var(--oh-ease-fluid), transform 600ms var(--oh-ease-fluid);
}
.oh-menu.is-open .oh-menu-links a,
.oh-menu.is-open .oh-menu-cta {
  opacity: 1;
  transform: translateY(0);
}
.oh-menu.is-open .oh-menu-links a:nth-child(1) { transition-delay: 140ms; }
.oh-menu.is-open .oh-menu-links a:nth-child(2) { transition-delay: 200ms; }
.oh-menu.is-open .oh-menu-links a:nth-child(3) { transition-delay: 260ms; }
.oh-menu.is-open .oh-menu-links a:nth-child(4) { transition-delay: 320ms; }
.oh-menu.is-open .oh-menu-links a:nth-child(5) { transition-delay: 380ms; }
.oh-menu.is-open .oh-menu-links a:nth-child(6) { transition-delay: 440ms; }
.oh-menu.is-open .oh-menu-cta { transition-delay: 520ms; }
.oh-menu-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.oh-menu-bar .oh-logo img { height: 19px; opacity: 0.92; }
/* C4: ≥44×44 tappable area; the × glyph keeps its visual size, the box
   centers it — negative right margin keeps the glyph optically at the
   gutter edge as before */
.oh-menu-close {
  background: none;
  border: 0;
  cursor: pointer;
  color: var(--oh-text);
  font-family: var(--oh-font-body);
  font-size: 30px;
  line-height: 1;
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  margin-right: -14px;
}
.oh-menu-links {
  display: flex;
  flex-direction: column;
  gap: var(--oh-s4);
  margin-top: auto;
  margin-bottom: var(--oh-s7);
}
.oh-menu-links a {
  font-family: var(--oh-font-display);
  font-weight: 600;
  font-size: clamp(2.1rem, 9vw, 3rem);
  letter-spacing: -0.02em;
  line-height: 1.04;
  color: var(--oh-text-2);
  /* full transition lives here (this is the rule that wins on source order) —
     fluid opacity/transform for the staggered entrance + color for hover */
  transition: opacity 600ms var(--oh-ease-fluid), transform 600ms var(--oh-ease-fluid), color 200ms var(--oh-ease);
}
.oh-menu-links a:hover,
.oh-menu-links a.is-active { color: var(--oh-text); }
.oh-menu-cta {
  align-self: flex-start;
  font-size: 1.05rem;
  padding: 14px 32px;
  transition: opacity 600ms var(--oh-ease-fluid), transform 600ms var(--oh-ease-fluid), background 200ms var(--oh-ease), border-color 200ms var(--oh-ease);
}
/* FROZEN-CLOCK FAILSAFE: nav.js adds .oh-menu--instant when the document
   timeline is paused (screenshot/verifier) → kill every transition/delay so the
   open menu paints fully visible immediately, never stuck mid-fade. */
.oh-menu--instant,
.oh-menu--instant .oh-menu-links a,
.oh-menu--instant .oh-menu-cta {
  transition: none !important;
}
@media (prefers-reduced-motion: reduce) {
  .oh-menu,
  .oh-menu .oh-menu-links a,
  .oh-menu .oh-menu-cta {
    transition: none !important;
    transform: none !important;
  }
}

/* ============================================================
   PHOTOGRAPHIC PLACEHOLDERS
   Color enters ONLY through photography (DESIGN.md §2).
   These tonal slots mirror the source-of-truth mockups until
   licensed photography is dropped in at the code stage.
   ============================================================ */
.oh-photo {
  position: relative;
  overflow: hidden;
  background: #0a0a0a;
  isolation: isolate;
}
.oh-photo::after { /* subtle film grain so slots read as photography, not flat gradient */
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  opacity: 0.05;
  mix-blend-mode: overlay;
  pointer-events: none;
  z-index: 2;
}
.oh-photo > .oh-photo-hint {
  position: absolute;
  left: 12px; bottom: 10px;
  z-index: 3;
  font-family: var(--oh-font-body);
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  pointer-events: none;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5), 0 0 14px rgba(0,0,0,0.35);
}

/* tonal variants — evoke the mockup imagery */
.oh-photo--warm-window {
  background:
    radial-gradient(60% 70% at 38% 42%, rgba(255,206,128,0.55), rgba(180,120,40,0.18) 42%, rgba(20,12,4,0.9) 78%),
    linear-gradient(120deg, #1c130a, #0c0805);
}
.oh-photo--warm-window::before {
  content: "";
  position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(to right, transparent 32%, rgba(255,255,255,0.06) 32.3%, transparent 33%),
    linear-gradient(to bottom, transparent 49%, rgba(255,255,255,0.05) 49.3%, transparent 50%);
}
.oh-photo--concrete {
  background:
    linear-gradient(135deg, #34373c 0%, #25282d 46%, #1a1c20 100%);
}
.oh-photo--concrete::before {
  content: "";
  position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(118deg, transparent 60%, rgba(255,255,255,0.05) 61%, rgba(255,255,255,0.07) 66%, transparent 67%),
    linear-gradient(to right, transparent 49.6%, rgba(0,0,0,0.25) 50%, transparent 50.4%);
}
.oh-photo--doorway {
  background:
    radial-gradient(34% 46% at 62% 40%, rgba(255,224,160,0.85), rgba(190,140,60,0.25) 55%, rgba(12,9,5,0.95) 80%),
    linear-gradient(180deg, #140d06, #060403);
}
.oh-photo--doorway::before {
  content: "";
  position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(to bottom, transparent 49%, rgba(0,0,0,0.4) 49.5%, transparent 50%),
    linear-gradient(to right, transparent 61.5%, rgba(0,0,0,0.35) 62%, transparent 62.5%);
}
.oh-photo--masonry {
  background:
    linear-gradient(95deg, #b89263 0%, #caa477 38%, #b08a5b 70%, #8f6e44 100%);
}
.oh-photo--masonry::before {
  content: "";
  position: absolute; inset: 0; z-index: 1;
  background:
    repeating-linear-gradient(to bottom, transparent 0 13.5%, rgba(0,0,0,0.12) 13.5%, rgba(0,0,0,0.12) 14%),
    repeating-linear-gradient(to right, transparent 0 16%, rgba(0,0,0,0.10) 16%, rgba(0,0,0,0.10) 16.5%),
    linear-gradient(100deg, rgba(255,255,255,0.18), transparent 55%);
}
.oh-photo--dusk {
  background:
    radial-gradient(70% 80% at 50% 40%, rgba(214,108,42,0.85), rgba(120,46,14,0.4) 55%, rgba(20,8,4,0.95) 85%),
    linear-gradient(180deg, #2a1207, #080302);
}
.oh-photo--dusk::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(to right, transparent 32%, rgba(0,0,0,0.25) 33%, transparent 34%), linear-gradient(to right, transparent 65%, rgba(0,0,0,0.25) 66%, transparent 67%);
}
.oh-photo--table {
  background: linear-gradient(180deg, #d8cdb8 0%, #c7b696 55%, #6b5638 56%, #4a3c28 100%);
}
.oh-photo--table::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, transparent 60%, rgba(40,28,14,0.5) 72%, transparent 86%);
}
.oh-photo--marble {
  background: linear-gradient(160deg, #c9cdd4 0%, #aeb3bb 45%, #969aa3 100%);
}
.oh-photo--marble::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    radial-gradient(120% 90% at 20% 10%, transparent 60%, rgba(80,84,92,0.4)),
    repeating-linear-gradient(58deg, transparent 0 38px, rgba(90,94,102,0.18) 38px 40px);
}
.oh-photo--portrait {
  background:
    radial-gradient(48% 40% at 62% 30%, rgba(120,96,58,0.55), transparent 60%),
    radial-gradient(40% 36% at 55% 72%, rgba(90,72,44,0.4), transparent 62%),
    linear-gradient(160deg, #211a10, #0a0805);
}
/* editorial portrait — warm backlit silhouette (profile hero, ref image 4).
   Keeps a tonal floor at the bottom edge so the photo reads to its true
   rectangle edge against the #0D0D0D ground (no dissolve into black). */
.oh-photo--editorial-portrait {
  background:
    radial-gradient(42% 32% at 60% 28%, rgba(152,122,74,0.55), transparent 60%),
    radial-gradient(56% 48% at 54% 68%, rgba(78,62,42,0.62), transparent 72%),
    radial-gradient(120% 100% at 80% 12%, rgba(226,178,110,0.46), rgba(150,108,56,0.2) 42%, transparent 66%),
    linear-gradient(168deg, #2b2114 0%, #20180e 52%, #19130a 100%);
}

/* ============================================================
   3 · POST CARD (the shared unit)
   ============================================================ */
.oh-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  position: relative;
}
/* stretched link: covers the whole card without nesting anchors.
   The author chip sits above it (higher z-index) as its own link. */
.oh-card-link {
  position: absolute;
  inset: 0;
  z-index: 2;
}
.oh-card-link:focus-visible { outline: 2px solid var(--oh-text); outline-offset: 4px; }
.oh-card-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0a0a0a;
}
.oh-card-media .oh-photo {
  position: absolute;
  inset: 0;
  transform: scale(1);
  transition: transform var(--oh-dur-hover) var(--oh-ease);
}
/* media scale is hover-capable-pointer only (audit #14) — on touch the
   scale used to stick after tap-navigate-back */
@media (hover: hover) {
  .oh-card:hover .oh-card-media .oh-photo { transform: scale(1.03); }
}
.oh-card-media .oh-card-index {
  position: absolute;
  top: 14px; left: 14px;
  z-index: 4;
  font-family: var(--oh-font-body);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  /* legibility over photography (audit #7) — black-alpha only, not color */
  text-shadow: 0 1px 2px rgba(0,0,0,0.5), 0 0 14px rgba(0,0,0,0.35);
}
.oh-card-media .oh-card-date {
  position: absolute;
  top: 14px; right: 14px;
  z-index: 4;
  font-family: var(--oh-font-body);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  text-shadow: 0 1px 2px rgba(0,0,0,0.5), 0 0 14px rgba(0,0,0,0.35);
}

.oh-card-body { padding-top: var(--oh-s5); }
/* category raised to text-2 (~9:1) — owner decision on audit #11, ending the
   "text-3 never essential" contradiction; hover goes the rest of the way to
   white (reconciles audit #20, whose text-2 hover predated this raise) */
.oh-card-cat { color: var(--oh-text-2); display: block; margin-bottom: var(--oh-s3); transition: color 200ms var(--oh-ease); }
/* text-zone hover response (audit #20): color-only, reversible */
@media (hover: hover) {
  .oh-card:hover .oh-card-cat { color: var(--oh-text); }
}
.oh-card-title { margin: 0 0 var(--oh-s3); }
.oh-card-dek {
  color: var(--oh-text-2);
  font-size: 0.9rem;
  line-height: 1.55;
  margin: 0;
  max-width: 46ch;
}

/* author chip — sits above the stretched card link */
.oh-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--oh-s3);
  margin-top: var(--oh-s5);
  position: relative;
  z-index: 3;
}
.oh-chip-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  flex: 0 0 auto;
  overflow: hidden;
  background: var(--oh-raised);
}
.oh-chip-name {
  font-family: var(--oh-font-display);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.2;
  display: block;
}
.oh-chip-label { color: var(--oh-text-3); font-size: 0.62rem; letter-spacing: 0.14em; }

/* ============================================================
   3b · THEME CARD  (home index — variant of the post card)
   A sparse editorial "column spine": index + theme name + signature,
   on an elevation surface lit by a subtle abstract glow (NO photo,
   color stays out per DESIGN.md §2). Reuses .oh-card-link for the
   stretched-link nav → card goes to the columnist's profile.
   No nested anchors (no chip), so the single overlay link is valid.
   ============================================================ */
.oh-theme-card {
  position: relative;
  display: flex;
  flex-direction: column;
  /* explicit target height (NOT tied to width) so the cards grow into a tall
     poster footprint and fill the index band — FIX A round 2 */
  min-height: clamp(400px, 34vw, 540px);
  padding: var(--oh-s5) var(--oh-s5) var(--oh-s6);
  background: var(--oh-surface);
  border: 1px solid var(--oh-line-2);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform var(--oh-dur-spot) var(--oh-ease),
              border-color var(--oh-dur-spot) var(--oh-ease),
              opacity var(--oh-dur-spot) var(--oh-ease);
  will-change: transform, opacity;
}
/* abstract glow — elevation palette ONLY (white-alpha, never a hue).
   motion-refine: gradient alphas raised (.11→.16 / .035→.05) with base
   opacity compensated (.82→.56) so RESTING look is unchanged — hover’s
   opacity:1 now lands ~45% brighter ("this one is lit"). */
.oh-theme-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2; /* D64 Item 1: glow floats OVER the full-bleed photo+scrim (was 0). Authorized D60. */
  background:
    radial-gradient(76% 64% at var(--oh-glow-x, 30%) var(--oh-glow-y, 26%),
      rgba(255,255,255,0.16), rgba(255,255,255,0.05) 42%, transparent 75%);
  opacity: 0.56;
  transition: opacity var(--oh-dur-spot) var(--oh-ease);
}
/* faint top wash → reads as the highest elevation tone */
.oh-theme-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.025), transparent 42%);
  pointer-events: none;
}
.oh-theme-card > * { position: relative; z-index: 3; } /* D64 Item 1: content above the glow (was 1). Authorized D60. */
/* keep the stretched link ABSOLUTE (full-cover, clickable) — the
   `.oh-theme-card > *` rule above would otherwise flip it to relative (equal
   specificity, later source), turning it into a 0-height in-flow flex item
   that left the card unclickable. Higher specificity here re-pins it. */
.oh-theme-card .oh-card-link { position: absolute; inset: 0; z-index: 4; } /* D64 Item 1: stretched link on top (was 2). Authorized D60. */
/* subtle card-to-card variety (still within the elevation ladder) */
.oh-theme-grid .oh-theme-card:nth-child(3n) { background: var(--oh-raised); }

/* DETERMINISTIC vertical rhythm so every card aligns regardless of how many
   lines the theme name takes (1 vs 2): index anchored at a fixed offset from
   the top, signature block anchored to the bottom, name reserves 2 lines.
   Fixes the "No. 10 sits lower" drift (its name was 1 line, neighbours 2). */
.oh-theme-index { color: var(--oh-text-3); align-self: flex-start; margin-top: var(--oh-s11); }
.oh-theme-body { display: flex; flex-direction: column; gap: var(--oh-s5); margin-top: auto; }
.oh-theme-name {
  font-family: var(--oh-font-display);
  font-weight: 600;
  font-size: clamp(1.45rem, 0.9rem + 1.1vw, 2.15rem);
  letter-spacing: -0.025em;
  line-height: 1.0;
  margin: 0;
  min-height: 2.1em; /* reserve 2 lines so 1-line names align with 2-line ones */
  text-wrap: balance;
}
.oh-theme-sign { display: flex; flex-direction: column; gap: var(--oh-s2); }
.oh-theme-by { color: var(--oh-text-3); }
.oh-theme-author {
  font-family: var(--oh-font-serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.2rem;
  letter-spacing: -0.01em;
  line-height: 1.1;
  color: var(--oh-text);
}

/* SPOTLIGHT (group hover): hovered card lifts + brightens; siblings dim.
   One group interaction, no bounce (BRANCH §2). Dim is a single opacity
   channel (audit #13 — the old opacity×filter combo killed the names and
   transitioning filter is paint-expensive). Hover-capable pointers only
   (audit #14 — no ghost dim stuck after tap on touch). */
@media (hover: hover) {
  /* motion-refine: deeper recession (.55→.44 — spec floor .42, settled one
     notch up to keep the dimmed white names alive) + larger lift (-6→-8px) */
  .oh-theme-grid:hover .oh-theme-card:not(:hover) { opacity: 0.44; }
  .oh-theme-grid .oh-theme-card:hover {
    transform: translateY(-8px);
    border-color: var(--oh-line);
  }
  .oh-theme-grid .oh-theme-card:hover::before { opacity: 1; }
}
/* keyboard parity (audit #6 / PREHANDOFF T4): tabbing a card mirrors hover —
   the focused card lifts + brightens, siblings dim */
.oh-theme-grid:has(.oh-card-link:focus-visible)
  .oh-theme-card:not(:has(.oh-card-link:focus-visible)) { opacity: 0.44; }
.oh-theme-card:has(.oh-card-link:focus-visible) {
  transform: translateY(-8px);
  border-color: var(--oh-line);
}
.oh-theme-card:has(.oh-card-link:focus-visible)::before { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .oh-theme-card { transition: none; }
  .oh-theme-card:hover,
  .oh-theme-card:has(.oh-card-link:focus-visible) { transform: none; }
}

/* ============================================================
   PAGINATION (archive / feed paging)
   C1: controls are real <button>s in the prototype (keyboard-operable;
   Enter/Space for free) — reset below strips UA chrome. In _s they
   revert to server-rendered <a href>.
   ============================================================ */
button.oh-page,
button.oh-page-arrow {
  background: none;
  border: 1px solid transparent;
  padding: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
}
.oh-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--oh-s5);
  border-top: 1px solid var(--oh-line);
  margin-top: var(--oh-s4);
  padding-top: var(--oh-s6);
  padding-bottom: var(--oh-s10);
}
.oh-page-nums {
  display: flex;
  align-items: center;
  gap: var(--oh-s1);
}
.oh-page {
  font-family: var(--oh-font-display);
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--oh-text-3);
  min-width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  cursor: pointer;
  transition: color 200ms var(--oh-ease), border-color 200ms var(--oh-ease);
}
.oh-page:hover { color: var(--oh-text); }
.oh-page.is-active {
  color: var(--oh-text);
  border-color: var(--oh-line);
  cursor: default;
}
.oh-page-gap {
  color: var(--oh-text-3);
  font-family: var(--oh-font-body);
  letter-spacing: 0.1em;
  padding-inline: var(--oh-s2);
  user-select: none;
}
.oh-page-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--oh-s3);
  font-family: var(--oh-font-body);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--oh-text-2);
  cursor: pointer;
  white-space: nowrap;
  transition: color 200ms var(--oh-ease);
}
.oh-page-arrow .arr { transition: transform 300ms var(--oh-ease); }
.oh-page-arrow:hover { color: var(--oh-text); }
.oh-page-arrow.next:hover .arr { transform: translateX(5px); }
.oh-page-arrow.prev:hover .arr { transform: translateX(-5px); }
.oh-page-arrow.is-disabled {
  color: var(--oh-text-3);
  pointer-events: none;
  opacity: 0.55;
}
@media (max-width: 560px) {
  .oh-pagination { gap: var(--oh-s4); }
  .oh-page-arrow .lbl { display: none; }
  .oh-page { min-width: 40px; }
}

/* ============================================================
   FOOTER (Keep reading + Pages + Publisher)
   ============================================================ */
.oh-footer { background: var(--oh-bg); border-top: 1px solid var(--oh-line); }
.oh-footer-cols {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--oh-s6);
  padding-block: var(--oh-s9) var(--oh-s8);
}
.oh-footer-col h4 {
  margin: 0 0 var(--oh-s4);
  color: var(--oh-text-3);
  font-family: var(--oh-font-body);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.oh-footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--oh-s3); }
.oh-footer-col a { color: var(--oh-text-2); font-size: 0.9rem; transition: color 200ms var(--oh-ease); }
.oh-footer-col a:hover { color: var(--oh-text); }

.oh-keepreading {
  text-align: center;
  max-width: 480px;
  margin-inline: auto;
  padding-block: var(--oh-s8) var(--oh-s9);
}
.oh-keepreading h3 {
  font-family: var(--oh-font-display);
  font-weight: 700;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.02em;
  margin: 0 0 var(--oh-s3);
}
.oh-keepreading p { color: var(--oh-text-2); font-size: 0.92rem; margin: 0 0 var(--oh-s5); }
.oh-form { display: flex; flex-direction: column; gap: var(--oh-s3); }
.oh-form input {
  background: transparent;
  border: 1px solid var(--oh-line);
  color: var(--oh-text);
  font-family: var(--oh-font-body);
  font-size: 0.9rem;
  padding: var(--oh-s4) var(--oh-s4);
  border-radius: 0;
}
.oh-form input::placeholder { color: var(--oh-text-3); }
.oh-form input:focus { outline: none; border-color: var(--oh-text-2); }
.oh-form button {
  background: var(--oh-text);
  color: var(--oh-bg);
  border: 0;
  border-radius: 0;
  font-family: var(--oh-font-display);
  font-weight: 600;
  font-size: 0.9rem;
  padding: var(--oh-s4);
  cursor: pointer;
  transition: opacity 200ms var(--oh-ease);
}
.oh-form button:hover { opacity: 0.85; }

.oh-footer-base {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-block: var(--oh-s6);
  border-top: 1px solid var(--oh-line);
}
.oh-footer-base span { color: var(--oh-text-3); font-size: 0.78rem; }
.oh-footer-logo img { display: block; height: 17px; width: auto; opacity: 0.9; }
.oh-footer-legal {
  display: flex;
  justify-content: center;
  gap: var(--oh-s7);
  flex-wrap: wrap;
  padding-bottom: var(--oh-s7);
}
.oh-footer-legal a {
  color: var(--oh-text-3);
  font-size: 0.78rem;
  transition: color 200ms var(--oh-ease);
}
.oh-footer-legal a:hover { color: var(--oh-text-2); }
/* D4 (audit #18): tighter gap on small screens so the three legal links
   wrap cleanly (the fixed 48px orphaned "Refund Policy" at 390) */
@media (max-width: 560px) {
  .oh-footer-legal { gap: var(--oh-s3) var(--oh-s5); }
}
/* back-to-top — quiet, monochrome; gives the smooth scroll a real in-page
   use (Gate B / audit #19). Pure anchor (#top) → native smooth scroll,
   instant under reduced-motion, no JS. */
.oh-totop-row { display: flex; justify-content: center; padding-bottom: var(--oh-s7); }
.oh-totop {
  display: inline-flex;
  align-items: center;
  gap: var(--oh-s3);
  color: var(--oh-text-3);
  transition: color 200ms var(--oh-ease);
}
.oh-totop:hover { color: var(--oh-text); }

@media (max-width: 720px) {
  .oh-footer-cols { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   STAGGERED REVEAL (DESIGN.md §6)
   ============================================================ */
.oh-reveal {
  opacity: 0;
  transform: translateY(18px); /* motion-refine: more presence (was 12px) */
}
.oh-reveal.is-in {
  opacity: 1;
  transform: translateY(0);
  transition: opacity var(--oh-dur-reveal) var(--oh-ease-fluid), transform var(--oh-dur-reveal) var(--oh-ease-fluid);
}

/* A6(a) — theme-grid entrance: deterministic "chaotic" reveal. Each of the
   10 cards carries a FIXED per-card delay (lookup below — no Math.random();
   identical on every load, failsafe/screenshot-safe) + a longer, fluid
   duration, so the index surfaces softly out-of-sequence instead of marching
   in a row. Implemented as an ANIMATION (backwards fill, no forwards) so it
   never clobbers the card's spotlight transition list — hover/focus motion
   takes over cleanly the moment the entrance ends. Feed + related cards keep
   the ordered reveal (NC-2/NC-3). */
.oh-theme-grid .oh-theme-card.oh-reveal { transform: translateY(22px); }
.oh-theme-grid .oh-theme-card.oh-reveal.is-in {
  transform: translateY(0);
  animation: oh-card-surface 1360ms var(--oh-ease-fluid) var(--oh-reveal-delay, 0ms) backwards;
}
@keyframes oh-card-surface {
  from { opacity: 0; transform: translateY(22px); }
}
/* fine-tune pass: duration 1280→1360ms, spread widened ×1.15 again
   (≈×1.67 of the original lookup) — still deterministic, no random */
.oh-theme-grid .oh-theme-card:nth-child(1)  { --oh-reveal-delay: 0ms; }
.oh-theme-grid .oh-theme-card:nth-child(2)  { --oh-reveal-delay: 370ms; }
.oh-theme-grid .oh-theme-card:nth-child(3)  { --oh-reveal-delay: 185ms; }
.oh-theme-grid .oh-theme-card:nth-child(4)  { --oh-reveal-delay: 600ms; }
.oh-theme-grid .oh-theme-card:nth-child(5)  { --oh-reveal-delay: 290ms; }
.oh-theme-grid .oh-theme-card:nth-child(6)  { --oh-reveal-delay: 735ms; }
.oh-theme-grid .oh-theme-card:nth-child(7)  { --oh-reveal-delay: 115ms; }
.oh-theme-grid .oh-theme-card:nth-child(8)  { --oh-reveal-delay: 485ms; }
.oh-theme-grid .oh-theme-card:nth-child(9)  { --oh-reveal-delay: 860ms; }
.oh-theme-grid .oh-theme-card:nth-child(10) { --oh-reveal-delay: 415ms; }

/* failsafe: if the document timeline is frozen (throttled/background tab)
   the reveal transition stalls at opacity 0. JS detects this and adds
   this class to hard-apply the final state instantly. */
.oh-reveal.oh-reveal-instant {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
  animation: none !important;
}
@media (prefers-reduced-motion: reduce) {
  .oh-reveal,
  .oh-theme-grid .oh-theme-card.oh-reveal { opacity: 1; transform: none; }
  .oh-theme-grid .oh-theme-card.oh-reveal.is-in { animation: none; }
  .oh-card-media .oh-photo { transition: none; transform: none; }
  /* C5 — consolidated coverage: arrow nudges (pagination + .oh-enter, which
     lives in screens.css) are neutralized here in one pass */
  .oh-page-arrow .arr,
  .oh-enter .arr { transition: none; }
  .oh-page-arrow.next:hover .arr,
  .oh-page-arrow.prev:hover .arr,
  .oh-enter:hover .arr { transform: none; }
}
