/* Valeo web app — groups, rides, chat and live maps. Same HUD look as the landing. */
:root {
  --bg: #0a0d12; --bg-2: #0e1218; --surface: #11161e; --surface-2: #151c26;
  --line: #1c242f; --line-2: #283341;
  --text: #eaf0f7; --dim: #9aa7b8;
  --amber: #ffb000; --ice: #7cc8ff; --red: #ef4444; --green: #4ade80;
  --display: "Bricolage Grotesque", Georgia, serif;
  --body: "Hanken Grotesk", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --r: 18px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--body); line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: var(--text); text-decoration: none; }
a:hover { color: var(--amber); }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; border-radius: 6px; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.dim { color: var(--dim); }
.kicker { font-size: 12px; font-weight: 800; letter-spacing: .14em; color: var(--dim); text-transform: uppercase; margin: 0; }
[hidden] { display: none !important; } /* .stack / .row set display and would override it */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* nav */
.w-nav { border-bottom: 1px solid var(--line); background: var(--bg-2); position: sticky; top: 0; z-index: 10; }
.w-nav__in { max-width: 1440px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.w-brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 800; font-size: 20px; }
.w-links { display: flex; gap: 20px; font-weight: 700; flex: 1; flex-wrap: wrap; }
.w-links a[aria-current="page"] { color: var(--amber); }
.w-main { max-width: 1440px; margin: 0 auto; padding: 24px; }
.w-main:focus { outline: none; }

/* bits */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--surface-2); font-weight: 800; cursor: pointer; }
.btn:hover { border-color: var(--dim); color: var(--text); }
.btn--primary { background: var(--amber); color: #1a1000; border-color: var(--amber); }
.btn--primary:hover { color: #1a1000; filter: brightness(1.06); }
.btn[disabled] { opacity: .5; cursor: default; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; }
.card--accent { border-color: var(--amber); }
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; align-items: center; gap: 12px; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.av { width: 36px; height: 36px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; flex: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line-2); font-weight: 800; font-size: 13px; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); display: inline-block; }
.h1 { font-family: var(--display); font-size: clamp(28px, 4vw, 40px); font-weight: 800; line-height: 1.05; margin: 0; }
.h2 { font-size: 13px; font-weight: 800; letter-spacing: .14em; color: var(--dim); margin: 0; text-transform: uppercase; }
.input { width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--bg); color: var(--text); font: inherit; font-size: 16px; }
.input::placeholder { color: var(--dim); }
.err { color: #ff6b6b; font-weight: 700; }
.split { display: flex; flex-wrap: wrap; gap: 24px; }
.split > .main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.split > .side { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stat b { display: block; font-family: var(--mono); font-size: 20px; }
.stat span { font-size: 12px; color: var(--dim); }
.bar { height: 6px; border-radius: 3px; background: var(--line); }
.bar > i { display: block; height: 6px; border-radius: 3px; }

/* hero for a group */
.g-hero { display: flex; align-items: flex-end; gap: 20px; flex-wrap: wrap; padding: 24px 0 8px; }
.g-icon { width: 84px; height: 84px; border-radius: 24px; display: flex; align-items: center; justify-content: center; font-size: 40px; }

/* chat */
.chat { display: flex; flex-direction: column; max-height: 560px; padding: 0; overflow: hidden; }
.chat__head { padding: 14px 18px; border-bottom: 1px solid var(--line); }
.chat__list { flex: 1; overflow-y: auto; padding: 14px 18px; display: flex; flex-direction: column; gap: 10px; min-height: 240px; }
.msg { display: flex; flex-direction: column; gap: 2px; max-width: 85%; }
.msg--me { align-self: flex-end; align-items: flex-end; }
.msg--me .msg__t { background: var(--amber); color: #1a1000; padding: 8px 12px; border-radius: 12px; font-weight: 600; }
.msg__who { font-size: 12px; font-weight: 800; }
.msg--sys { align-self: center; font-size: 13px; color: var(--dim); font-weight: 700; border: 1px solid var(--line-2); border-radius: 10px; padding: 4px 10px; }
.chat__form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); }

/* live map page */
.live { display: flex; flex-wrap: wrap; gap: 16px; }
.live__map { flex: 999 1 560px; min-width: 0; min-height: 560px; height: calc(100vh - 220px); border-radius: 20px; overflow: hidden; border: 1px solid var(--line); background: #0e1520; position: relative; }
.live__side { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.rider { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); cursor: pointer; text-align: left; width: 100%; }
.rider[aria-pressed="true"] { border-color: var(--amber); }
.rider--quiet { opacity: .65; }
.marker { width: 38px; height: 38px; border-radius: 50%; border: 3px solid var(--bg); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 13px; cursor: pointer; box-shadow: 0 2px 10px rgba(0,0,0,.5); }
.marker--sel { border-color: var(--text); }
.legend { position: absolute; left: 14px; bottom: 14px; padding: 8px 12px; border-radius: 12px; background: rgba(10,13,18,.88); font-size: 13px; font-weight: 700; }

.center { max-width: 440px; margin: 48px auto; }
.gsi { min-height: 44px; display: flex; justify-content: center; }
.or { display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: 13px; text-transform: uppercase; letter-spacing: .12em; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }
@media (max-width: 640px) {
  .w-main { padding: 16px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .live__map { height: 60vh; min-height: 360px; }
}
@media (prefers-reduced-motion: no-preference) {
  .pulse { animation: pulse 1.8s ease-out infinite; }
  @keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,176,0,.6); } 100% { box-shadow: 0 0 0 16px rgba(255,176,0,0); } }
}
