/* HyperSync site — shared styles for auth/download/legal pages.
   Tokens mirror index.html's inline system. */
:root {
  --bg: #070b14;
  --bg-2: #0a0f1c;
  --panel-solid: #101624;
  --line: rgba(148, 163, 184, .12);
  --line-2: rgba(148, 163, 184, .22);
  --ink: #eef2f9;
  --muted: #94a3b8;
  --faint: #5b6b83;
  --cyan: #38bdf8;
  --green: #34d399;
  --red: #f87171;
  --grad: linear-gradient(94deg, #38bdf8, #34d399);
  --disp: 'Bricolage Grotesque', 'Inter', system-ui, sans-serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  --r: 20px;
}
* { margin: 0; box-sizing: border-box; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: inherit; }
::selection { background: rgba(56, 189, 248, .32); }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 6px; }

.aurora { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.aurora i { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .5; }
.aurora .a1 { width: 620px; height: 620px; left: -180px; top: -260px; background: radial-gradient(circle, rgba(56,189,248,.26), transparent 65%); }
.aurora .a2 { width: 540px; height: 540px; right: -160px; bottom: -220px; background: radial-gradient(circle, rgba(52,211,153,.16), transparent 65%); }

.topbar {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1140px; margin: 0 auto; padding: 22px 24px;
}
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; }
.brand-mark {
  width: 28px; height: 28px; border-radius: 8px; overflow: hidden; flex-shrink: 0;
  box-shadow: 0 0 20px -4px rgba(56, 189, 248, .5);
}
.brand-mark img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brand-name { font-family: var(--disp); font-size: 16px; font-weight: 700; letter-spacing: -.02em; color: #fff; }
.topbar .aux { font-size: 13px; color: var(--muted); }
.topbar .aux a { color: var(--cyan); text-decoration: none; font-weight: 600; }
.topbar .aux a:hover { text-decoration: underline; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer;
  padding: 12px 22px; border-radius: 999px; border: 0; font-family: inherit;
  transition: transform .12s, box-shadow .2s, opacity .15s, background .15s;
}
.btn:active { transform: translateY(1px); }
.btn.grad { background: var(--grad); color: #041018; box-shadow: 0 10px 30px -8px rgba(56, 189, 248, .55); }
.btn.grad:hover { transform: translateY(-1px); box-shadow: 0 16px 40px -10px rgba(56, 189, 248, .7); }
.btn.glass { background: rgba(148, 163, 184, .08); color: var(--ink); border: 1px solid var(--line-2); }
.btn.glass:hover { background: rgba(148, 163, 184, .14); }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .45; pointer-events: none; }

/* Auth card */
.auth-wrap {
  position: relative; z-index: 1;
  display: grid; place-items: center;
  padding: 24px 24px 64px; min-height: calc(100vh - 80px);
}
.card {
  width: 100%; max-width: 460px;
  border: 1px solid var(--line-2); border-radius: 24px;
  background: linear-gradient(165deg, rgba(23, 32, 51, .82), rgba(13, 18, 32, .96));
  box-shadow: 0 40px 100px -40px rgba(0, 0, 0, .9);
  padding: 36px 34px;
}
.card.wide { max-width: 560px; }
.card h1 { font-family: var(--disp); font-size: 26px; font-weight: 800; letter-spacing: -.02em; color: #fff; }
.card .sub { margin-top: 8px; font-size: 13.5px; color: var(--muted); line-height: 1.6; }
.card .sub a { color: var(--cyan); font-weight: 600; text-decoration: none; }
.card .sub a:hover { text-decoration: underline; }

form { margin-top: 26px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .row { grid-template-columns: 1fr; } }
.field { margin-bottom: 14px; }
.field label {
  display: block; font-size: 11px; font-weight: 600; letter-spacing: .08em;
  text-transform: uppercase; color: var(--faint); margin-bottom: 7px;
}
.field input, .field select {
  width: 100%; font: inherit; font-size: 14px; color: var(--ink);
  background: rgba(7, 11, 20, .7); border: 1px solid var(--line-2);
  border-radius: 12px; padding: 11px 14px; outline: none;
  transition: border-color .15s;
}
.field input::placeholder { color: var(--faint); }
.field input:focus, .field select:focus { border-color: var(--cyan); }
.field select { appearance: none; -webkit-appearance: none; }
.field.err input { border-color: rgba(248, 113, 113, .6); }

.rules { list-style: none; padding: 0; margin: 4px 0 14px; display: grid; grid-template-columns: 1fr 1fr; gap: 5px 14px; }
@media (max-width: 520px) { .rules { grid-template-columns: 1fr; } }
.rules li { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: var(--faint); transition: color .15s; }
.rules li::before { content: '○'; font-size: 10px; }
.rules li.ok { color: var(--green); }
.rules li.ok::before { content: '●'; }

.terms { display: flex; gap: 10px; align-items: flex-start; margin: 6px 0 20px; font-size: 12.5px; color: var(--muted); line-height: 1.55; }
.terms input { margin-top: 3px; accent-color: #38bdf8; width: 15px; height: 15px; flex-shrink: 0; }
.terms a { color: var(--cyan); text-decoration: none; }
.terms a:hover { text-decoration: underline; }

.form-err {
  display: none; margin-bottom: 14px;
  border: 1px solid rgba(248, 113, 113, .35); background: rgba(248, 113, 113, .08);
  color: var(--red); border-radius: 12px; padding: 10px 14px; font-size: 13px;
}
.form-err.show { display: block; }
.fine { margin-top: 16px; text-align: center; font-family: var(--mono); font-size: 11px; color: var(--faint); }

/* Download page */
.dl-hero { text-align: center; max-width: 560px; margin: 0 auto; }
.dl-hero h1 { font-family: var(--disp); font-size: clamp(30px, 5vw, 44px); font-weight: 800; letter-spacing: -.03em; color: #fff; text-wrap: balance; }
.dl-hero .g { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.dl-hero p { margin-top: 14px; color: var(--muted); font-size: 15.5px; line-height: 1.7; }
.dl-ctas { margin-top: 30px; display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; }
.dl-meta { margin-top: 16px; font-family: var(--mono); font-size: 11.5px; color: var(--faint); text-align: center; }
.next-steps { margin: 44px auto 0; max-width: 560px; text-align: left; }
.next-steps .step {
  display: flex; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line);
}
.next-steps .n {
  font-family: var(--disp); font-weight: 800; font-size: 20px;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  flex-shrink: 0; width: 34px;
}
.next-steps h3 { font-size: 14.5px; font-weight: 700; color: #fff; }
.next-steps p { margin-top: 4px; font-size: 13px; color: var(--muted); line-height: 1.6; }

/* Legal pages */
.doc { position: relative; z-index: 1; max-width: 720px; margin: 0 auto; padding: 24px 24px 80px; }
.doc h1 { font-family: var(--disp); font-size: 32px; font-weight: 800; letter-spacing: -.02em; color: #fff; }
.doc .updated { margin-top: 8px; font-family: var(--mono); font-size: 11.5px; color: var(--faint); }
.doc h2 { font-family: var(--disp); font-size: 18px; font-weight: 700; color: #fff; margin: 36px 0 10px; }
.doc p, .doc li { font-size: 14px; color: var(--muted); line-height: 1.75; }
.doc ul { padding-left: 20px; margin-top: 8px; }
.doc strong { color: var(--ink); }

footer.mini {
  position: relative; z-index: 1;
  border-top: 1px solid var(--line); padding: 28px 24px;
  display: flex; justify-content: center; gap: 24px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--faint);
}
footer.mini a { color: var(--muted); text-decoration: none; }
footer.mini a:hover { color: var(--ink); }

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