/* Vengeance Racing — shared UI tokens + base components.
   Used by the planner, login and connections pages. */

@font-face {
  font-family: 'Gotham VR';
  src: url('/ui/gotham-black-italic.woff2') format('woff2');
  font-weight: 900;
  font-style: italic;
  font-display: swap;
}

:root {
  /* Brand */
  --red: #B61F24;
  --red-hi: #D02A30;
  --red-lo: #8A1419;
  --red-tint: rgba(182, 31, 36, 0.14);
  --red-line: rgba(182, 31, 36, 0.55);

  /* Neutrals */
  --black: #000000;
  --bg: #070708;
  --surface: #101012;
  --surface2: #17171A;
  --surface3: #1F1F23;
  --border: #242428;
  --border2: #34343A;
  --text: #F2F2F3;
  --text-2: #B4B4BA;
  --text-muted: #8A8A92;
  --text-dim: #5C5C63;
  --white: #FFFFFF;
  --ok: #3FA66B;
  --ok-tint: rgba(63, 166, 107, 0.12);

  /* Type */
  --f-display: 'Gotham VR', 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --f-label: 'Barlow Condensed', 'Arial Narrow', sans-serif;
  --f-body: 'Barlow', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* Shape — the logo's cut angle */
  --slant: 10px;
  --radius: 6px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-body);
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--red); color: var(--white); }

:focus-visible { outline: 2px solid var(--white); outline-offset: 2px; }

/* Display type: Gotham Black Italic, uppercase — matches the rendered cards */
.display {
  font-family: var(--f-display);
  font-weight: 900;
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 1;
  color: var(--white);
}
.display em, .display .r { color: var(--red); font-style: inherit; }

.eyebrow {
  font-family: var(--f-label);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Slanted red bar — the signature accent */
.slash {
  display: inline-block;
  width: 14px;
  height: 18px;
  background: var(--red);
  transform: skewX(-24deg);
  flex: none;
}

/* ── Buttons ── */
.btn {
  --h: 44px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: var(--h);
  padding: 0 26px;
  border: 0;
  background: var(--red);
  color: var(--white);
  font-family: var(--f-label);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  clip-path: polygon(var(--slant) 0, 100% 0, calc(100% - var(--slant)) 100%, 0 100%);
  transition: background .15s var(--ease), color .15s var(--ease), transform .1s var(--ease);
}
.btn:hover { background: var(--red-hi); }
.btn:active { transform: translateY(1px); background: var(--red-lo); }
.btn:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--white); }
.btn:disabled, .btn[aria-disabled="true"] {
  background: var(--surface3);
  color: var(--text-dim);
  cursor: not-allowed;
  transform: none;
}
.btn svg { width: 16px; height: 16px; flex: none; }

.btn-ghost { background: var(--surface3); color: var(--text-2); }
.btn-ghost:hover { background: var(--border2); color: var(--white); }
.btn-ghost:active { background: var(--surface2); }

.btn-sm { --h: 34px; padding: 0 16px; font-size: 13px; }
.btn-block { display: flex; width: 100%; }

/* ── Form fields ── */
.field label, .label {
  display: block;
  font-family: var(--f-label);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.input, .field input, .field select, textarea.input {
  width: 100%;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--f-body);
  font-size: 14px;
  padding: 10px 12px;
  transition: border-color .15s var(--ease), background .15s var(--ease), box-shadow .15s var(--ease);
}
.input:hover, .field input:hover, .field select:hover { border-color: var(--border2); }
.input:focus, .field input:focus, .field select:focus, textarea.input:focus {
  outline: none;
  border-color: var(--red);
  background: var(--surface);
  box-shadow: 0 0 0 3px var(--red-tint);
}
.input::placeholder, .field input::placeholder, textarea::placeholder { color: var(--text-dim); }
select { color-scheme: dark; }

/* ── Cards / panels ── */
.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}

/* ── Status pill ── */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 28px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-family: var(--f-label);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--surface);
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text-dim); flex: none; }
.dot.on, .dot.done { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-tint); }
.dot.active { background: var(--red); box-shadow: 0 0 0 3px var(--red-tint); animation: vr-pulse 1s infinite; }
@keyframes vr-pulse { 0%, 100% { opacity: 1 } 50% { opacity: .35 } }

/* ── Notice / message ── */
.notice {
  padding: 12px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border2);
  border-left: 3px solid var(--text-dim);
  background: var(--surface2);
  font-size: 13px;
  color: var(--text-2);
}
.notice.ok { border-left-color: var(--ok); }
.notice.err { border-left-color: var(--red); }

/* ── Scrollbars ── */
* { scrollbar-width: thin; scrollbar-color: var(--border2) transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 4px; border: 2px solid var(--bg); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
