/* production-additions.css — HAND-AUTHORED contract-v4 additions for v3 surfaces (master card P3,
 * re-tokened for the v4 port).
 *
 * The per-surface sheets in this directory are GENERATED verbatim from the contract oracles and
 * never edited. This file is the one hand-authored exception, loaded by BaseV3 after the surface
 * sheet, and it may contain ONLY styles for production components the contract has no counterpart
 * for — the certified authority mount above all: the references demonstrate page-JS math, and the
 * mount that replaces it (never-mock) needs the contract's own visual vocabulary. Judged by the
 * contract lint like everything in this directory: radius/shadow/gradient forms must be
 * constitution-declared — every form below is copied from reference/contract-v4/calculator.html.
 *
 * Class names here are provenance-registered (authority-*, refusal*, result-card) — no invented
 * vocabulary. Tokens are the contract-v4 token sheet's own (reference/contract-v4/tokens.css).
 */

/* ---- the certified engine mount, wearing the contract's card vocabulary ---------------------- */
/* THE MOUNT IS ONE INSTRUMENT ON EVERY SURFACE, so it does not inherit the surface's type scale.
 * The defect this exists to prevent, caught by route-sweep on the article flip: the mount declared
 * no font-size of its own, so on a lesson page it inherited the article oracle's larger READING
 * scale and every certified control and result card rendered at 18px, against 16px on the hub and
 * calculator surfaces — 42 findings, one cause. The engine's own figures are the last thing that
 * should change size with the page they happen to sit on. 16px is the shell's value, and matches
 * what /en/ has always rendered. */
/* The mount lays out as the v4 oracle's own vocabulary declares it — one grid, one 16px gap —
 * stated here as well so every surface (with or without a mount rule in its oracle sheet)
 * computes the identical layout; route-sweep asserts the mount renders the same everywhere. */
.authority-mount { display: grid; gap: 16px; font-size: 16px; margin-top: 0; }
.authority-mount label {
  display: grid;
  gap: 6px;
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-soft);
}
/* input AND select: the verified leaf renders a <select> for choice inputs, and a control nothing
 * gave a font to falls back to the OS UI font — the one typography leak route-sweep refuses.
 * Geometry and material are the v4 oracle's input treatment (calculator.html `.input-wrap input`):
 * 54px control on --surface-2 behind a --line-strong hairline at --radius-sm, 17px/650 figures. */
.authority-mount input,
.authority-mount select {
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 17px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  padding: 0 16px;
  transition: border-color .2s;
}
/* The oracle's focus treatment replaces the old 2px outline: accent hairline plus the declared
 * `0 0 0 4px var(--accent-soft)` ring, control lifting to --surface. The ring IS the visible
 * indicator, so the browser outline is retired with it, not in addition to it. */
.authority-mount input:focus-visible,
.authority-mount select:focus-visible {
  outline: none;
  border-color: var(--accent);
  background: var(--surface);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
/* The action wears the oracle's `.mount-action` treatment: gradient accent fill, --accent-ink
 * text (the token that exists so text on an accent fill passes contrast in BOTH themes), and the
 * oracle's own accent-tinted shadow form. */
.authority-mount .authority-trigger,
.authority-mount button {
  min-height: 56px;
  border: 0;
  border-radius: var(--radius-sm);
  background: linear-gradient(145deg, var(--accent), var(--accent-strong));
  color: var(--accent-ink);
  font-weight: 800;
  font-size: 17px;
  padding: 0 16px;
  cursor: pointer;
  box-shadow: 0 14px 28px color-mix(in srgb, var(--accent) 17%, transparent);
}
.authority-mount .result-card {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  padding: 12px 13px;
  margin: 8px 0 0;
}
/* The engine's figure: mono and tabular because it is the machine's value, in --teal — the token
 * sheet's "engine/verified secondary" ink, contrast-checked as TEXT in both themes. Never
 * --accent-fill: that token is graphics-only (bars, chart strokes) and fails as light-theme text. */
.authority-mount .result-card b {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--teal);
  font-size: 17px;
}
.authority-mount .authority-note,
.authority-mount .tiny {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.55;
  margin-top: 10px;
}

/* ---- THE REST OF THE LOADER'S VOCABULARY, which shipped unstyled ------------------------------
 * The defect this exists to prevent, which the owner saw on the home mount: the blocks below
 * carried NO rule on a v3 surface, so they rendered at 16px body prose — and because the exact
 * readout's label and figure are both inline by default, they collided into
 * "…— exact, m30.9467964460417291". Every control was styled and every gate was green: route-sweep
 * proves no user-agent default reaches an approved CONTROL, and these are text.
 *
 * They are the mount's own vocabulary, so they wear the mount's own treatment: labels muted and
 * small, engine figures mono and tabular. Tokens are the contract's. */
.authority-mount .authority-section {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 14px 0 8px;
}
.authority-mount .readout { display: grid; gap: 8px; margin-top: 12px; }
.authority-mount .readout > div { display: grid; gap: 2px; }
.authority-mount .readout > div > span {
  font-size: 12px;
  font-weight: 650;
  color: var(--text-muted);
}
/* The unrounded engine figure. Mono and tabular for the same reason the result card's is — it is
 * the machine's value — and it wraps rather than overflowing, because an exact double can be long.
 * Full --text ink rather than --teal: the strip's rounded figure is the headline, this is its
 * exact record. */
.authority-mount .readout > div > b {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  color: var(--text);
  overflow-wrap: anywhere;
}
.authority-mount .authority-notes { display: grid; gap: 8px; }
.authority-mount .authority-seeded,
.authority-mount .authority-provenance {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.55;
  margin-top: 10px;
}
/* An engine warning is the engine speaking, not a footnote: it wears --warn, the token sheet's
 * caution ink, so it cannot be skimmed past as prose. (Under Rev C it borrowed the refusal card's
 * ink; v4 separates the two — a warning cautions in --warn, a refusal refuses in --danger.) */
.authority-mount .authority-warning {
  color: var(--warn);
  font-size: 13px;
  line-height: 1.55;
  margin-top: 10px;
}
/* The refusal card, v4 treatment: a --danger spine on the card's leading edge, --surface material,
 * square against the spine and --radius-sm elsewhere. The second selector is the loader's engine-
 * refusal variant of the result card — it is appended to the `.result-strip`, which is a SIBLING of
 * the mount, so it cannot be reached through `.authority-mount` and is named at its own address. */
.authority-mount .refusal,
.result-card.authority-engine-refusal {
  border: 1px solid var(--line);
  border-inline-start: 4px solid var(--danger);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--surface);
  padding: 14px;
}

/* ---- category chips that ship as real links -------------------------------------------------- */
/* The contract's .cat-btn is a JS filter button; production chips LINK into the directory groups
 * (a control links or it is omitted — never dead), and an <a> needs the text-decoration reset a
 * <button> never declared. Chip geometry, colour and tokens are the contract's own, untouched. */
.cat-scroll .cat-btn { text-decoration: none; }

/* ---- real release identifiers inside the contract's authority card --------------------------- */
/* The contract's .authority cells carry short demonstration vocabulary ("Deterministic"); the
 * production calculator template binds them to REAL release facts — the signed pack id and the
 * pinned release id — which are long unbroken tokens. They wrap anywhere rather than overflowing
 * the card on narrow viewports; cell geometry, tokens and colour are the contract's own. */
.authority b { overflow-wrap: anywhere; }

/* ---- long canonical domain names: the last clamp of the round-1 defect class is GONE ---------- */
/* WHAT USED TO BE HERE, and why it is gone: an ellipsis clamp on `.domain-card b`. Round 1 removed
 * the same clamp from home's `.domain b` and kept this one, reasoning that "the domains surface's
 * cards carry a title line beside a count badge in a fixed row, and that row genuinely cannot
 * grow". That reasoning does not describe this surface and the owner overruled it in round 3: the
 * /en/domains card title sits in `.card-top` — an `align-items:flex-start` flex row whose height is
 * its content's — beside a 40px icon, not a count badge, and the row grows exactly as the home
 * tiles do. What the clamp actually did at 390px was truncate the only word that names the card:
 * "Water / Env…", "Computing …", "Process Eng…", "Manufactur…".
 *
 * Nothing replaces it. The domains oracle already declares the wrapping title itself, generated
 * verbatim into domains.css, so a rule here would be a second copy of a rule the contract owns —
 * which is how the two drift. Titles wrap to a second line and the card auto-heights; the grid
 * rows stretch, so a taller card cannot orphan its neighbour. */

/* ---- domains: the phone overflow is fixed IN THE REFERENCE now (owner decision, 2026-07-30) ----
 * This block used to carry a `@media(max-width:699.98px){.hero-grid>.finder{min-width:0}}` guard,
 * because domains.html ITSELF h-scrolled 53px at 390px: .finder-help's five chips have a 405px
 * intrinsic width and the grid item's automatic minimum propagated it into the single-column
 * .hero-grid. Production was correct and the reference was not, which is a divergence anyone
 * regenerating from the reference would re-inherit. The owner took the fix into the reference
 * verbatim, so the generated sheet now carries it and this guard is redundant. Deleted rather than
 * kept: two copies of one rule is how they drift.
 */

/* ---- domains: the primary feature card's map-nodes are real links ---------------------------- */
/* The contract wraps the whole primary feature card in ONE anchor with inert .map-node divs
 * inside; production links each map-node to its real route (the card's stated purpose), and
 * anchors cannot nest, so the wrapper is an <article> and the nodes are anchors — which need the
 * wrapper's text-decoration:none restated at node level. Nothing else is restyled. */
a.map-node { text-decoration: none; }

/* ---- calculator: the substance sections' onward links (P3 route swap) ------------------------ */
/* The route swap made the v3 calculator template the production Tier-A surface, and a production
 * Tier-A page answers to the index-value substance standard: the lower cards carry the record's
 * related list, browse line and learn handoff as provenance-registered .tier-a-onward links — a
 * production component the contract has no counterpart for. They wear the contract's own link
 * vocabulary (the v4 learn-cta card's declared form: no browser underline, accent ink, 700). */
a.tier-a-onward { text-decoration: none; color: var(--accent); font-weight: 700; }

/* ---- the More sheet is GONE with the v3 shell (contract-v4 port) ------------------------------
 * WHAT USED TO BE HERE, and why it is gone: the `.more-sheet` block — a :target-driven, no-script
 * bottom sheet whose every value was copied from the sheet the Rev C energy-pr.html declared,
 * carried here because the old shell's 5th bottom-nav slot was More and only one oracle declared
 * a sheet. The v4 shell has no More sheet to open: bottom-nav slot 5 is Search, and every
 * destination the old sheet listed is a first-class nav destination in the v4 shell. A rule for
 * markup no surface renders is dead weight and a drift trap, so nothing replaces it. */

/* ---- the accessibility floor is the CONTRACT'S OWN rule now -----------------------------------
 * WHAT USED TO BE HERE, and why it is gone: a `.skip-link` block, written when no oracle declared
 * skip-link styles and the shell would otherwise have shipped an unstyled (and never-hidden)
 * anchor. The v4 contract sheets declare `.skip-link` themselves — it is part of the canonical
 * shared shell, byte-identical across all eight oracles — so a copy here would be the second of
 * two copies, which is how they drift. The floor did not lower; its rule moved to the owner. */

/* ---- shell controls that are real links/spans in production (P4) ------------------------------
 * The v4 shell renders its search control as a <button> and its language chip as a <button>;
 * production routes the first (it leads to the search surface) and ships the second inert while
 * the build carries one locale (BaseV3). Different elements arrive with different user-agent
 * defaults — an anchor with the browser's underline, a span still promising a click through the
 * contract's cursor:pointer — visible drift from the oracle's own rendering. :where() keeps the
 * specificity at zero so any contract sheet that declares the property still wins.
 *
 * WHAT USED TO BE HERE, and why it is gone: this block shipped 70 lines of desktop-nav and footer
 * FALLBACKS, because when it was written the article oracles carried no desktop-nav and no footer
 * and BaseV3's shell arrived on the article surface with no rules at all — the 390px topbar
 * overflowed to 549px. That was the P4b defect, and it was fixed at the source instead: the shell
 * is byte-identical across all the oracles, so every surface sheet declares those rules itself
 * and the fallbacks were duplicating them. The v4 shell keeps that law (its shell block is
 * normalized from calculator.html and drift fails the css build), so they stay gone. */
:where(.brand) { text-decoration: none; }
/* The search control is an <a> in production and a <button> in the v4 references (it leads to the
 * search surface). Every visual property comes from the contract's own `.search-btn` rule — this
 * only removes the underline a button never had, so the two render identically. */
:where(a.search-btn) { text-decoration: none; }
/* The language control renders as a <span> while the build ships one locale (BaseV3). The
 * contract's `.tool-btn`/`.lang-chip` rule sets cursor:pointer, which on a non-control would still
 * promise a click. Every other property stays the contract's own, so the two render identically. */
:where(span.lang-chip) { cursor: default; }
/* Production's breadcrumb keeps its provenance-registered `.path` class (the v4 oracles name
 * theirs `.breadcrumb`); its ancestors are real Learn and domain routes, and an anchor needs the
 * underline reset. */
:where(.path a) { text-decoration: none; }

/* ---- the vendored visual runtime's token bridge (Wave V3, card atlas-visual-v3-and-studio-r4) --
 * The Atlas Visual v1.8 components style their shadow DOM from an `--atlas-*` custom-property
 * vocabulary and, when nothing defines it, fall back to a warm-paper/orange palette that belongs
 * to no theme this site has ever shipped — every calculator chart has rendered in that foreign
 * palette since Wave V1, and the loss-stack's fill (a color-mix over an undefined property)
 * rendered fully transparent. Custom properties inherit into shadow roots, so the bridge lives
 * here, on the host page, in the contract's own vocabulary.
 *
 * EVERY VALUE IS A REFERENCE to a ratified token from reference/contract-v4/tokens.css — the
 * bridge declares NO new constant, which is why it needs no constitution edit: the six series
 * hues are the constitution's own graphics-capable colors, and each mapping follows the theme
 * flip automatically because the referenced token does. Durations/easing state the same literal
 * forms this file already uses. */
:root {
  --atlas-paper: var(--surface);
  --atlas-paper2: var(--surface-2);
  --atlas-paper3: var(--surface-3);
  --atlas-ink: var(--text);
  --atlas-ink-soft: var(--text-soft);
  --atlas-muted: var(--text-muted);
  --atlas-faint: var(--surface-soft);
  --atlas-line: var(--line);
  --atlas-line-strong: var(--line-strong);
  --atlas-grid: var(--line);
  --atlas-accent: var(--accent-fill);
  --atlas-accent-soft: var(--accent-soft);
  --atlas-warn: var(--warn);
  --atlas-warn-soft: var(--surface-soft);
  --atlas-good: var(--teal);
  --atlas-good-soft: var(--accent-soft);
  --atlas-danger: var(--danger);
  --atlas-danger-soft: var(--surface-soft);
  --atlas-info: var(--blue);
  --atlas-info-soft: var(--surface-soft);
  --atlas-blue: var(--blue);
  --atlas-blue-soft: var(--surface-soft);
  --atlas-series-1: var(--accent-fill);
  --atlas-series-2: var(--teal);
  --atlas-series-3: var(--blue);
  --atlas-series-4: var(--violet);
  --atlas-series-5: var(--warn);
  --atlas-series-6: var(--danger);
  --atlas-shadow-xs: var(--shadow-soft);
  --atlas-shadow-sm: var(--shadow-soft);
  --atlas-shadow-md: var(--shadow);
  --atlas-radius: var(--radius-sm);
  --atlas-ring: var(--accent-soft);
  --atlas-fast: .2s;
  --atlas-normal: .3s;
  --atlas-ease: ease;
}
