/* ============================================================
 * oddly Developer / Substrate archetypes. Design impl Phase 4
 * (design-handoff-2026-07-03-v2, "Archetype Family 1").
 *
 * The reusable component layer behind the substrate surface:
 * /platform, /platform/verifier, /platform/playbooks,
 * /platform/benchmarks, /developers. Audience shifts technical; the
 * brand does not. Cream ground, Newsreader display, teal is the one
 * action colour, gold is earned. No dark-terminal cliche: ink appears
 * only as inset panels and code surfaces.
 *
 * Built on the locked spine v2 tokens (/_shared/oddly-tokens.css) and
 * composed from the landing primitives where one already exists
 * (/_shared/oddly-archetypes.css: .o-band, .o-wrap, .o-kicker, .o-h2,
 * .o-btn). This file adds only what the substrate surface needs and
 * the landing does not have. Load order on a page:
 *   oddly-chrome.css, oddly-tokens.css, oddly-broadsheet.css,
 *   oddly-titan.css, oddly-archetypes.css, then this.
 *
 * DEVIATIONS from the handoff, deliberate and recorded:
 *
 * 1. Mono is --oddly-text-mono (the token layer's system stack), not
 *    IBM Plex Mono. The spine self-hosts every webfont it ships and
 *    links no third-party font host; adding Plex means adding a woff2
 *    to /_shared/fonts, which is an asset row, not a CSS row. Every
 *    mono rule below reads the token, so swapping the family in
 *    oddly-tokens.css is the only change that surface will need.
 *
 * 2. The handoff gives the substrate surface its own top nav, because
 *    it assumes developers.myoddly.com. These pages are paths on
 *    myoddly.com and already carry the site chrome (.oc-nav). A second
 *    top nav would be two navs. .dv-subnav is the surface's own
 *    wayfinding row, sitting under the site nav rather than replacing
 *    it, and it carries the handoff's version badge and Talk-to-us CTA.
 *
 * 3. The handoff's Docs, MCP and Quickstart screens are NOT built, so the
 *    components that only they would use (code block, endpoint and parameter
 *    rows, tool table, governance strip, corpus stats band) are not shipped
 *    either, rather than shipped dead. There is no @oddly/mcp server in this
 *    repo, so an MCP page would document a product that does not exist; the
 *    docs content does not exist either; and the corpus band's figures are
 *    marked "representative for design" in the handoff, which the honesty
 *    rule will not let onto a live page. The endpoint reference stays the
 *    Stoplight element rendering developers/openapi.json, which is real.
 * ============================================================ */

/* ---- Sub-nav: the substrate surface's own wayfinding row ---- */
.dv-subnav {
  border-bottom: 1px solid var(--oddly-border-subtle, rgba(26, 26, 46, 0.09));
  background: var(--oddly-canvas, #FAFAF7);
}
.dv-subnav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  min-height: 60px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.dv-subnav-mark {
  font-family: var(--oddly-font-serif, "Newsreader", Georgia, serif);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: var(--oddly-tracking-serif, -0.02em);
  color: var(--oddly-ink, #1A1A2E);
  text-decoration: none;
  white-space: nowrap;
}
.dv-subnav-mark .dv-dot { color: var(--oddly-teal, #2C7873); }
.dv-subnav-mark .dv-suffix {
  font-family: var(--oddly-text-mono);
  font-size: 13px;
  color: var(--oddly-text-tertiary, rgba(26, 26, 46, 0.5));
  margin-left: 6px;
}
.dv-subnav-tabs { display: flex; align-items: center; gap: 2px; }
.dv-subnav-tabs a {
  padding: 8px 12px;
  border-radius: var(--oddly-radius-sm, 6px);
  font-size: 14px;
  font-weight: 500;
  color: var(--oddly-text-secondary, rgba(26, 26, 46, 0.7));
  text-decoration: none;
}
.dv-subnav-tabs a:hover { color: var(--oddly-ink, #1A1A2E); }
.dv-subnav-tabs a[aria-current="page"] {
  color: var(--oddly-teal, #2C7873);
  background: var(--oddly-teal-tint, rgba(44, 120, 115, 0.08));
  font-weight: 600;
}
.dv-subnav-end { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.dv-subnav-end .dv-chip { white-space: nowrap; }
.dv-subnav-talk {
  font-size: 14px;
  font-weight: 600;
  color: var(--oddly-teal, #2C7873);
  text-decoration: none;
  white-space: nowrap;
}
.dv-subnav-talk:hover { text-decoration: underline; }

/* ---- Mono chip: version badges, constants, inline identifiers ---- */
.dv-chip {
  display: inline-block;
  font-family: var(--oddly-text-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--oddly-teal, #2C7873);
  border: 1px solid var(--oddly-teal-tint-strong, rgba(44, 120, 115, 0.12));
  background: var(--oddly-teal-tint-faint, rgba(44, 120, 115, 0.04));
  border-radius: var(--oddly-radius-sm, 6px);
  padding: 4px 8px;
}
.dv-inline-code {
  font-family: var(--oddly-text-mono);
  font-size: 0.92em;
  background: rgba(26, 26, 46, 0.05);
  border-radius: 4px;
  padding: 2px 6px;
}

/* ---- Ink inset band: the one place ink is a surface ---- */
.dv-band {
  max-width: 1200px;
  margin: 0 auto;
  background: var(--oddly-ink, #1A1A2E);
  color: var(--oddly-canvas, #FAFAF7);
  border-radius: 26px;
  padding: 64px 56px;
}
.dv-band .dv-band-kicker {
  display: block;
  font-size: var(--oddly-kicker-size, 12px);
  letter-spacing: var(--oddly-tracking-kicker-wide, 0.2em);
  text-transform: uppercase;
  color: var(--oddly-gold, #B08D57);
  font-weight: 600;
  margin-bottom: 10px;
}
.dv-band h2 {
  text-wrap: balance;
  font-family: var(--oddly-font-serif, "Newsreader", Georgia, serif);
  font-weight: var(--oddly-serif-weight-display, 400);
  font-size: clamp(26px, 3vw, 38px);
  letter-spacing: var(--oddly-tracking-serif-loose, -0.015em);
  line-height: var(--oddly-leading-display-max, 1.16);
  margin: 0 0 36px;
}

/* ---- Engine diagram: signals -> engine -> language layer ---- */
.dv-diagram {
  display: grid;
  grid-template-columns: 1fr auto 1.2fr auto 1fr;
  gap: 20px;
  align-items: stretch;
}
.dv-node {
  background: rgba(250, 250, 247, 0.06);
  border: 1px solid rgba(250, 250, 247, 0.14);
  border-radius: 14px;
  padding: 22px;
}
.dv-node--engine {
  background: rgba(44, 120, 115, 0.14);
  border-color: rgba(44, 120, 115, 0.5);
}
.dv-node-step {
  font-family: var(--oddly-text-mono);
  font-size: 11px;
  color: rgba(250, 250, 247, 0.5);
  margin-bottom: 10px;
}
.dv-node--engine .dv-node-step { color: #7FBFB9; }
.dv-node-t { font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.dv-node p { font-size: 13px; line-height: 1.55; color: rgba(250, 250, 247, 0.6); margin: 0; }
.dv-node--engine p { color: rgba(250, 250, 247, 0.65); }
.dv-diagram-arrow {
  align-self: center;
  color: var(--oddly-teal, #2C7873);
  font-size: 24px;
  line-height: 1;
}

/* ---- The guarantees: 2x2 contract cards, serif ghost numerals ---- */
.dv-guar { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.dv-guar-card {
  background: var(--oddly-surface, #FFFFFF);
  border: 1px solid var(--oddly-border-subtle, rgba(26, 26, 46, 0.09));
  border-radius: var(--oddly-radius-card, 16px);
  padding: 28px;
  border-top: 2px solid var(--oddly-gold, #B08D57);
}
.dv-guar-card:nth-child(even) { border-top-color: var(--oddly-teal, #2C7873); }
.dv-guar-num {
  font-family: var(--oddly-font-serif, "Newsreader", Georgia, serif);
  font-size: 30px;
  line-height: 1;
  color: rgba(26, 26, 46, 0.25);
  margin-bottom: 12px;
}
.dv-guar-t { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.dv-guar-card p { font-size: 14px; line-height: 1.6; color: var(--oddly-text-secondary-soft, rgba(26, 26, 46, 0.6)); margin: 0; }
.dv-guar-card p a { color: var(--oddly-teal, #2C7873); font-weight: 600; }

/* ---- Callouts: teal states a rule, gold states the flagship claim ---- */
.dv-callout {
  border-radius: var(--oddly-radius-card-sm, 14px);
  padding: 20px 24px;
  border: 1px solid transparent;
}
.dv-callout--teal {
  background: var(--oddly-teal-tint, rgba(44, 120, 115, 0.08));
  border-color: var(--oddly-teal-tint-strong, rgba(44, 120, 115, 0.12));
}
.dv-callout--gold {
  background: var(--oddly-gold-tint, rgba(176, 141, 87, 0.1));
  border-color: var(--oddly-gold-tint-strong, rgba(176, 141, 87, 0.16));
}
.dv-callout .dv-callout-t { font-size: 15px; font-weight: 700; color: var(--oddly-ink, #1A1A2E); margin: 0 0 6px; }
.dv-callout--gold .dv-callout-t.dv-callout-t {
  font-family: var(--oddly-font-serif, "Newsreader", Georgia, serif);
  font-weight: var(--oddly-serif-weight-display, 400);
  font-size: 24px;
  letter-spacing: var(--oddly-tracking-serif-loose, -0.015em);
}
.dv-callout p { font-size: 14px; line-height: 1.6; color: var(--oddly-text-secondary, rgba(26, 26, 46, 0.7)); margin: 0; }

/* ---- Quality floor ---- */
.dv-subnav a:focus-visible,
.dv-guar-card a:focus-visible {
  outline: 2px solid var(--oddly-teal, #2C7873);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ---- Mobile collapse (handoff: <=960px structure, <=700px chrome) ---- */
@media (max-width: 960px) {
  .dv-diagram { grid-template-columns: 1fr; }
  .dv-diagram-arrow { transform: rotate(90deg); justify-self: center; }
  .dv-guar { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .dv-subnav-inner { flex-wrap: wrap; padding: 10px 20px; row-gap: 8px; }
  .dv-subnav-tabs { order: 3; width: 100%; overflow-x: auto; }
  .dv-band { padding: 36px 24px; border-radius: 20px; }
}
