/* console.css — Console, Lucian Labs look A — waveloop-ds v0.1.0
   GENERATED by ds/build.mjs. Edit ds/src/, never this file.
   Tokens: ds/src/tokens.css — the single definition for both stylesheets. */

/* ── Fonts ──────────────────────────────────────────────────────────────────
   Three faces, three roles, per brand-design.md and the Lucian Labs brand kit:

     Micro 5      display — wordmarks, headings, silkscreen telemetry.
                  A pixel face: it needs size to read. Never below 1.4rem.
     Finlandica   body — paragraphs, labels, any sentence-length UI text.
     Inconsolata  mono — dense readouts, code, tabular figures.

   Absolute URLs on purpose: this stylesheet is served from ds.lucianlabs.ca to
   twelve other origins AND vendored into lucianlabs.ca/branding/, where a
   relative ./fonts/ would resolve against the wrong directory. The fonts
   location sends Access-Control-Allow-Origin: *. To vendor for offline use,
   rewrite these four URLs and copy dist/fonts/ alongside the stylesheet.
   ────────────────────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Micro 5';
  src: url('https://ds.lucianlabs.ca/fonts/Micro5-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Finlandica';
  src: url('https://ds.lucianlabs.ca/fonts/Finlandica.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Inconsolata';
  src: url('https://ds.lucianlabs.ca/fonts/Inconsolata-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Inconsolata';
  src: url('https://ds.lucianlabs.ca/fonts/Inconsolata-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
/* ── Tokens ─────────────────────────────────────────────────────────────────
   THE single place any WaveLoop-family web colour, face or metric is defined.
   Both stylesheets this repo emits are built from this file:

     waveloop.css  — tokens + the custom elements (the device face)
     console.css   — tokens + Console's components, generated for
                     lucianlabs.ca/branding/console.css

   The brand kit's rule is "load, don't reimplement". That only holds if there
   is exactly one definition to load, so add values here and nowhere else.
   ────────────────────────────────────────────────────────────────────────── */

:root {
  /* ── WaveLoop surfaces — teal-tinted near-black (LZ.bg / LZ.surface). ──── */
  --wl-bg: rgb(13 17 17);
  --wl-bg-deep: rgb(8 11 11);
  --wl-surface: rgb(23 29 29);
  --wl-surface-lift: rgb(31 39 39);
  --wl-line: rgb(48 60 60);
  --wl-line-soft: rgb(36 45 45);

  /* Ink — never darker than muted (LZ rule: muted is readable-dim, not faint). */
  --wl-text: rgb(242 242 242);
  --wl-muted: rgb(148 148 148);
  --wl-foam: rgb(235 235 235);

  /* Accent families. A page picks ONE and only overrides --wl-accent.
     --wl-accent-hi is the lighter partner used for metal gradients. */
  --wl-teal: rgb(46 199 184);
  --wl-cyan: rgb(107 230 224);
  --wl-gold: rgb(230 153 51);
  --wl-gold-hi: rgb(255 196 92);
  --wl-blue: rgb(57 127 217);
  --wl-blue-hi: rgb(126 183 255);
  --wl-violet: rgb(140 46 191);
  --wl-violet-hi: rgb(191 122 230);
  --wl-orange: rgb(242 140 56);
  --wl-rec: rgb(235 66 77);

  --wl-accent: var(--wl-teal);
  --wl-accent-hi: var(--wl-cyan);

  /* ── Type — Micro 5 display, Finlandica body, Inconsolata mono. ────────── */
  --wl-font-head: 'Micro 5', ui-monospace, monospace;
  --wl-font-body: 'Finlandica', system-ui, -apple-system, sans-serif;
  --wl-font-mono: 'Inconsolata', 'IBM Plex Mono', ui-monospace, monospace;

  /* ── Geometry. The 2pt bezel from brand-design.md is --wl-bezel. ───────── */
  --wl-bezel: 2px;
  --wl-hair: 1px;
  --wl-gap: 0.75rem;
  --wl-pad: 1rem;
  --wl-page: 1100px;

  /* Motion — spring in, slip out. */
  --wl-in: 180ms cubic-bezier(0.22, 1.2, 0.36, 1);
  --wl-out: 140ms ease-in;

  color-scheme: dark;
}

/* ── Console — Lucian Labs look A ───────────────────────────────────────────
   The instrument panel, shipped in WaveLoop. Its public token names are
   unprefixed and are used directly by every page that links console.css, so
   they are a stable API: pages in the wild write var(--bg), var(--accent) and
   so on. Values are held at Console's shipped values deliberately — this
   consolidation moves where they are DEFINED, not what they are, so nothing
   already using the brand kit shifts.

   Console's blue is waveloop.app's own --accent (rgb(57 127 217)) and its
   second accent is the Choppa gold, which is why Console reads as the
   WaveLoop look rather than a separate identity.
   ────────────────────────────────────────────────────────────────────────── */

:root {
  /* surfaces — Console's neutral near-black, a shade cooler than WaveLoop's */
  --bg: #101014;
  --bg-deep: #07080d;
  --panel: rgb(17 20 30 / 88%);
  --panel-solid: #111420;

  /* ink */
  --ink: #eaecf2;
  --muted: #aaafbd;
  --faint: #6b7185;

  /* boundaries — every edge in this look is one of these at 1px */
  --line: #383c4a;
  --line-soft: rgb(56 60 74 / 55%);

  /* accents — see "accent budget" in console.md before using these */
  --accent: var(--wl-blue); /* identical to Console's shipped #397fd9 */
  --accent-2: #ffa40a;
  --good: #4db378;
  /* Held at Console's shipped #e6404d rather than aliased to --wl-rec
     (#eb424d). The two reds are three points apart — near-duplicates that
     should be reconciled deliberately, not merged as a side effect of moving
     where tokens are defined. */
  --bad: #e6404d;

  /* form */
  --radius: 0;
  --gap: 1rem;

  /* type — the three faces above, under Console's names */
  --font-display: var(--wl-font-head);
  --font-body: var(--wl-font-body);
  --font-mono: var(--wl-font-mono);
}
/* ── Console components ─────────────────────────────────────────────────────
   Look A's base components. Tokens live in tokens.css — this file only
   consumes them, so Console and the WaveLoop device face cannot drift apart.
   Moved here from lucianlabs.ca/web/branding/console.css, which is now
   generated from these sources.
   ────────────────────────────────────────────────────────────────────────── */

/* Square corners are load-bearing. This wins over any framework default. */
*,
*::before,
*::after {
  box-sizing: border-box;
  border-radius: var(--radius);
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background:
    radial-gradient(circle at 10% 0%, rgb(63 95 145 / 32%), transparent 42%),
    radial-gradient(circle at 90% 0%, rgb(131 77 22 / 24%), transparent 36%),
    linear-gradient(165deg, var(--bg-deep), var(--bg) 55%, #08080b);
  background-attachment: fixed;
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.55;
}

/* ── layout ──────────────────────────────────────────────────────────────── */

.page {
  width: min(1200px, calc(100% - 2.4rem));
  margin: 0 auto;
  padding: 1.2rem 0 4rem;
}

.section { margin-top: 2.5rem; }
.section:first-of-type { margin-top: 2rem; }

.section-copy {
  color: var(--muted);
  margin: 0.4rem 0 1.25rem;
  line-height: 1.55;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: var(--gap);
}

/* ── type ────────────────────────────────────────────────────────────────── */

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0;
  line-height: 1.05;
}

/* Micro 5 is a pixel face — it needs size to read. Do not set it below 1.4rem. */
h1 { font-size: 4rem; }
h2 { font-size: 2.4rem; }
h3 { font-size: 1.6rem; }

.overline,
.label {
  font-family: var(--font-display);
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.tagline { margin: 0.4rem 0 0; color: var(--muted); }
.small { font-size: 0.9rem; color: var(--muted); }
.faint { color: var(--faint); }

code,
kbd,
.mono {
  font-family: var(--font-mono);
  font-size: 0.92em;
}

/* Numbers that change on screen. Tabular so they don't jitter. */
.readout {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--ink);
}

/* ── links ───────────────────────────────────────────────────────────────── */

a { color: var(--accent); }

.text-link {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color 150ms ease;
}
.text-link:hover { color: var(--ink); }
.text-link--muted { color: var(--muted); }
.text-link--muted:hover { color: var(--ink); }

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}
.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.82rem;
  transition: color 150ms ease;
}
.nav a:hover { color: var(--ink); }

/* ── panels ──────────────────────────────────────────────────────────────── */

.card {
  border: 1px solid var(--line);
  padding: 1.125rem 1.25rem;
  background: var(--panel);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.card > h3 { margin-bottom: 0.5rem; }
.card > p { margin: 0.5rem 0 0; }

/* Rail: a card that carries state. The accent edge is the state indicator. */
.card--armed { border-left: 2px solid var(--accent); }
.card--live { border-left: 2px solid var(--accent-2); }

.divider {
  height: 1px;
  border: 0;
  background: var(--line-soft);
  margin: 1.5rem 0;
}

/* ── buttons ─────────────────────────────────────────────────────────────── */

.button {
  display: inline-block;
  padding: 0.55rem 1.1rem;
  font-family: var(--font-display);
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  cursor: pointer;
  border: 1px solid var(--line);
  background: rgb(255 255 255 / 5%);
  color: var(--ink);
  text-decoration: none;
  transition: background 150ms ease, border-color 150ms ease, color 150ms ease;
}
.button:hover {
  background: rgb(255 255 255 / 10%);
  border-color: color-mix(in oklab, var(--line) 70%, var(--accent));
}
.button:disabled { opacity: 0.4; cursor: default; }

/* One primary per view. */
.button.primary {
  background: color-mix(in oklab, var(--accent) 28%, rgb(8 10 18));
  border-color: var(--accent);
}
.button.primary:hover {
  background: color-mix(in oklab, var(--accent) 42%, rgb(8 10 18));
}

/* Gold = armed / recording / irreversible-and-live. Not "secondary". */
.button.armed {
  background: color-mix(in oklab, var(--accent-2) 22%, rgb(8 10 18));
  border-color: var(--accent-2);
}

.button.ghost { background: transparent; color: var(--muted); }
.button.ghost:hover { color: var(--ink); }

.button-row { display: flex; flex-wrap: wrap; gap: 0.5rem; }

/* ── forms ───────────────────────────────────────────────────────────────── */

.input-field,
input[type='text'],
input[type='number'],
input[type='email'],
input[type='password'],
select,
textarea {
  width: 100%;
  padding: 0.55rem 0.7rem;
  background: rgb(8 11 19 / 88%);
  border: 1px solid var(--line);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem; /* ≥16px keeps iOS from zooming on focus */
  transition: border-color 150ms ease;
}
.input-field:focus,
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
}
::placeholder { color: var(--faint); }

.field-label {
  display: block;
  margin-bottom: 0.3rem;
  font-family: var(--font-display);
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

/* ── status ──────────────────────────────────────────────────────────────── */

.badge {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.tag {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}
.tag.good { color: var(--good); border-color: color-mix(in oklab, var(--good) 45%, var(--line)); }
.tag.bad { color: var(--bad); border-color: color-mix(in oklab, var(--bad) 45%, var(--line)); }

/* ── tables ──────────────────────────────────────────────────────────────── */

table { width: 100%; border-collapse: collapse; }
th, td {
  padding: 0.5rem 0.7rem;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
}
th {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}
td { font-variant-numeric: tabular-nums; }

/* ── footer ──────────────────────────────────────────────────────────────── */

.site-footer {
  margin-top: 3rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
