/* Shared design tokens for the public site and the app.
   Direction: steel dark-grey frame, engineering blue for action, safety orange for emphasis and status. */
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 300 900; font-display: swap; src: url('../fonts/figtree.woff2') format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-style: normal; font-weight: 100 800; font-display: swap; src: url('../fonts/jetbrains-mono.woff2') format('woff2'); }
:root {
  --bg: #F3F5F8; --surface: #FFFFFF; --surface-2: #EEF1F5; --surface-3: #E4E9EF;
  --ink: #111A24; --ink-2: #2A3643; --muted: #5A6878; --line: #DCE2E9; --line-2: #C9D2DC;
  --steel-950: #0B1118; --steel-900: #111922; --steel-800: #19232E; --steel-700: #243140; --steel-600: #33445A;
  --on-dark: #F2F5F8; --on-dark-muted: #A9B6C4;
  --blue: #2563C9; --blue-strong: #1C4FA3; --blue-soft: #E5EEFB; --link: #1F58B8;
  --orange: #F07C1B; --orange-strong: #D2650C; --orange-soft: #FDEEDF; --on-orange: #1D0E00;
  --good: #137141; --good-bg: #DFF3E7; --warn: #8A5A00; --warn-bg: #FFF2D6; --bad: #A82A20; --bad-bg: #FBE3E0;
  --input: #FFF8DB; --input-edge: #E3BE3C; --input-ink: #111A24;
  --glass: rgba(255, 255, 255, .72); --glass-edge: rgba(255, 255, 255, .55);
  --shadow-sm: 0 1px 2px rgba(17, 26, 36, .07); --shadow: 0 1px 2px rgba(17, 26, 36, .06), 0 8px 24px rgba(17, 26, 36, .07); --shadow-lg: 0 24px 60px rgba(9, 16, 24, .28);
  --r: 14px; --r-sm: 9px;
  --font: 'Figtree', 'Segoe UI', system-ui, -apple-system, Roboto, 'Helvetica Neue', Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Consolas, monospace;
  --series-1: #2a78d6; --series-2: #eb6834; --series-3: #1baf7a; --series-4: #eda100;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0C1218; --surface: #141C25; --surface-2: #1A2430; --surface-3: #223040;
    --ink: #E7ECF2; --ink-2: #C7D1DC; --muted: #93A2B3; --line: #26323F; --line-2: #33424F;
    --blue: #4C8BEF; --blue-strong: #3A76D6; --blue-soft: #18283F; --link: #8DB6F5;
    --orange-soft: #3A2412; --good: #7ADBA0; --good-bg: #12331F; --warn: #F2C46B; --warn-bg: #3A2C0E; --bad: #FF9D93; --bad-bg: #431A16;
    --input: #2D2709; --input-edge: #B9952A; --input-ink: #FFF3C5;
    --glass: rgba(20, 28, 37, .72); --glass-edge: rgba(255, 255, 255, .08);
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px rgba(0, 0, 0, .3);
    --series-1: #3987e5; --series-2: #d95926; --series-3: #199e70; --series-4: #c98500;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0C1218; --surface: #141C25; --surface-2: #1A2430; --surface-3: #223040;
  --ink: #E7ECF2; --ink-2: #C7D1DC; --muted: #93A2B3; --line: #26323F; --line-2: #33424F;
  --blue: #4C8BEF; --blue-strong: #3A76D6; --blue-soft: #18283F; --link: #8DB6F5;
  --orange-soft: #3A2412; --good: #7ADBA0; --good-bg: #12331F; --warn: #F2C46B; --warn-bg: #3A2C0E; --bad: #FF9D93; --bad-bg: #431A16;
  --input: #2D2709; --input-edge: #B9952A; --input-ink: #FFF3C5;
  --glass: rgba(20, 28, 37, .72); --glass-edge: rgba(255, 255, 255, .08);
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 28px rgba(0, 0, 0, .3);
  --series-1: #3987e5; --series-2: #d95926; --series-3: #199e70; --series-4: #c98500;
  color-scheme: dark;
}
:root[data-theme="light"] { color-scheme: light; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; }
a { color: var(--link); text-underline-offset: 2px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
[hidden] { display: none !important; }
.ic { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.num, .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 8px 16px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font-weight: 650; font-size: 15px; text-decoration: none; white-space: nowrap; transition: background-color .15s, border-color .15s, transform .15s; }
.btn:hover { border-color: var(--muted); }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-strong); border-color: var(--blue-strong); }
.btn-accent { background: var(--orange); border-color: var(--orange); color: var(--on-orange); }
.btn-accent:hover { background: var(--orange-strong); border-color: var(--orange-strong); color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-ghost:hover { background: var(--surface-2); border-color: transparent; }
.btn-lg { min-height: 50px; padding: 12px 22px; font-size: 16.5px; border-radius: 12px; }
.btn-sm { min-height: 32px; padding: 5px 11px; font-size: 13.5px; border-radius: 8px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-danger { color: var(--bad); }

/* chips and pills */
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.pill.blue { background: var(--blue-soft); color: var(--link); }
.pill.orange { background: var(--orange-soft); color: var(--orange-strong); }
.pill.good { background: var(--good-bg); color: var(--good); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
:root[data-theme="dark"] .pill.orange { color: #F7A55E; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .pill.orange { color: #F7A55E; } }

/* forms */
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field > span, .field > label { font-size: 13.5px; font-weight: 650; color: var(--ink-2); }
.field small { color: var(--muted); font-size: 12.5px; }
.input, .field input, .field select, .field textarea { width: 100%; min-height: 42px; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); }
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, .input:focus { border-color: var(--blue); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 25%, transparent); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid .wide { grid-column: 1 / -1; }
.form-msg { margin: 0; font-weight: 600; font-size: 14.5px; }
.form-msg.err { color: var(--bad); } .form-msg.ok { color: var(--good); }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 640px) { .form-grid { grid-template-columns: minmax(0, 1fr); } }

/* cards */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-sm); }
.glass { background: var(--glass); border: 1px solid var(--glass-edge); backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%); }

/* scroll-in motion, visible at rest */
@media (prefers-reduced-motion: no-preference) {
  .rise { animation: rise .6s cubic-bezier(.2, .7, .2, 1) both; }
  @keyframes rise { from { transform: translateY(14px); opacity: .001; } to { transform: none; opacity: 1; } }
}
