/* Tokens and the shared vocabulary, in Redline Studio's language: dark flat
   greys, 1px lines, small radii, IBM Plex, mono small-caps labels, one
   accent. The accent here is a warm rose instead of Redline's blue. */
@font-face { font-family: 'IBM Plex Sans'; font-style: normal; font-weight: 100 700; font-display: swap;
  src: url('/static/fonts/plexsans-var-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Sans'; font-style: normal; font-weight: 100 700; font-display: swap;
  src: url('/static/fonts/plexsans-var-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/static/fonts/plexmono-500-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/static/fonts/plexmono-500-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('/static/fonts/plexmono-600-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 600; font-display: swap;
  src: url('/static/fonts/plexmono-600-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  /* Redline's "spartan-dark" theme (spartan-ng / shadcn zinc), verbatim:
     zinc greys, white as the primary, its chart palette for series. */
  color-scheme: dark;
  --bg:          #09090b;
  --surface:     #09090b;
  --surface-2:   #18181b;
  --card:        #18181b;
  --hover:       #27272a;
  --pressed:     #3f3f46;
  --line:        #27272a;
  --line-soft:   #27272a;
  --line-strong: #3f3f46;

  --ink:         #fafafa;
  --ink-dim:     #a1a1aa;
  --ink-faint:   #71717a;
  --ink-bright:  #ffffff;
  --ink-on-accent: #18181b;

  --accent:      #fafafa;
  --accent-deep: #27272a;
  --accent-wash: rgba(250, 250, 250, .06);
  --blue:        #2662d9;
  --warn:        #e88c30;
  --danger:      #ef4444;
  --ok:          #2eb88a;

  --scrim:       rgba(9, 9, 11, .88);
  --shade:       rgba(9, 9, 11, .82);
  --shadow:      rgba(0, 0, 0, .55);
  --shadow-hard: rgba(0, 0, 0, .75);
  --scroll-thumb: rgba(161, 161, 170, .28);

  /* the series palette, in order */
  --s1: #2662d9; --s2: #e88c30; --s3: #2eb88a; --s4: #af57db;
  --s5: #e23670; --s6: #ef4444; --s7: #38bdf8; --s8: #a1a1aa;

  --mono: 'IBM Plex Mono', ui-monospace, monospace;
  --sans: 'IBM Plex Sans', system-ui, -apple-system, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { font: 14px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { display: block; }
.mono { font-family: var(--mono); }
[hidden] { display: none !important; }

/* the small-caps mono section label: "NOTIFY ME WHEN" */
.label {
  font: 600 10.5px/1.3 var(--mono); letter-spacing: .09em; text-transform: uppercase; color: var(--ink-dim);
}
.label.accent { color: var(--accent); }

.badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 0 6px; height: 18px;
  border: 1px solid var(--line); border-radius: 3px;
  font: 500 10px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--ink-dim); white-space: nowrap;
}
.badge[data-tone="accent"] { color: var(--accent); border-color: var(--accent); }
.badge[data-tone="ok"] { color: var(--ok); border-color: var(--ok); }

.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-faint); flex: none; }
.dot.live { background: var(--ok); box-shadow: 0 0 0 3px rgba(46, 184, 138, .18); }
.dot.blue { background: var(--blue); }
.dot.accent { background: var(--accent); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: 4px; background: var(--surface); color: var(--ink);
  font-size: 13px; cursor: pointer; white-space: nowrap; text-decoration: none; -webkit-tap-highlight-color: transparent;
}
.btn:hover { background: var(--hover); text-decoration: none; }
.btn:active { background: var(--pressed); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.accent { background: var(--accent); border-color: var(--accent); color: var(--ink-on-accent); font-weight: 600; }
.btn.accent:hover { background: #e4e4e7; border-color: #e4e4e7; }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--danger); }
.btn.danger:hover { border-color: var(--danger); }
.btn.sm { height: 26px; padding: 0 8px; font-size: 12px; }
.btn.lg { height: 46px; padding: 0 18px; font-size: 15px; border-radius: 5px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 6px; }
.tile { min-width: 0; padding: 7px 10px 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 5px; }
.tile > span { display: block; }
.tile > b { display: block; margin-top: 2px; font: 500 14px/1.35 var(--mono); color: var(--ink-bright); overflow-wrap: anywhere; }
.tile > small { display: block; margin-top: 2px; font-size: 12px; color: var(--ink-dim); }

.scroll-thin { scrollbar-width: thin; scrollbar-color: var(--scroll-thumb) transparent; }

/* confirm dialog + toast, shared */
.modal { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 16px; background: var(--scrim);
  animation: fade .16s ease; }
.modal-card { width: min(380px, 100%); background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 18px 50px var(--shadow-hard); animation: pop .2s var(--ease); }
.modal-card header { padding: 10px 14px; border-bottom: 1px solid var(--line); }
.modal-card .body { padding: 18px 16px 16px; font-size: 15px; line-height: 1.55; text-align: center; }
.modal-card .body b { color: var(--ink-bright); font-weight: 600; }
.modal-card footer { display: flex; gap: 8px; padding: 0 14px 14px; }
.modal-card footer .btn { flex: 1; height: 42px; font-size: 14px; }
.toast .btn { margin-left: 4px; }
.toast { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); z-index: 95; transform: translateX(-50%);
  display: flex; align-items: center; gap: 8px; max-width: calc(100% - 32px);
  padding: 6px 6px 6px 12px; min-height: 40px; background: var(--surface-2); border: 1px solid var(--line-strong); border-radius: 5px; font-size: 13px;
  box-shadow: 0 10px 30px var(--shadow); animation: rise .22s var(--ease); }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(6px) scale(.98); } }
@keyframes rise { from { opacity: 0; transform: translate(-50%, 8px); } }
