/* CONQRR web. Tokens mirror src/theme.ts so the site and the app read as one product. */
:root {
  --bg: #06070a;
  --bg-elevated: #0b0d12;
  --surface: #11141b;
  --surface-2: #181c25;
  --border: rgba(255, 255, 255, 0.07);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #f4f6f8;
  --text-muted: #8c93a3;
  --text-dim: #596072;
  --accent: #34e0a1;
  --accent-2: #22b8f0;
  --accent-ink: #04140e;
  --gold: #f5c451;
  --danger: #ff4d5e;
  --danger-2: #ff7a45;
  --violet: #8b7cff;
  --signal: linear-gradient(135deg, var(--accent), var(--accent-2));
  --danger-grad: linear-gradient(135deg, var(--danger), var(--danger-2));
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --r-xl: 28px;
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Inter', 'Segoe UI', Roboto, sans-serif;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

img,
svg {
  display: block;
}

.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Top glow, like the app's Screen component */
.glow {
  position: absolute;
  inset: 0 0 auto 0;
  height: 620px;
  background: radial-gradient(60% 70% at 50% 0%, rgba(52, 224, 161, 0.16), transparent 70%),
    radial-gradient(40% 50% at 85% 10%, rgba(34, 184, 240, 0.1), transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  background: rgba(6, 7, 10, 0.72);
  border-bottom: 1px solid var(--border);
}
.nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
}
.nav-links a {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
}
.nav-links a:hover,
.nav-links a[aria-current='page'] {
  color: var(--text);
  text-decoration: none;
}
.nav-links a.btn-primary {
  color: var(--accent-ink);
}
@media (max-width: 640px) {
  .nav-links .hide-sm {
    display: none;
  }
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  font-weight: 900;
  font-size: 19px;
  letter-spacing: 2.4px;
}
.logo:hover {
  text-decoration: none;
}
.logo-mark {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--signal);
  display: grid;
  place-items: center;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 56px;
  padding: 0 26px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.2px;
  border: 0;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}
.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}
.btn-primary {
  background: var(--signal);
  color: var(--accent-ink);
  box-shadow: 0 8px 30px rgba(52, 224, 161, 0.35);
}
.btn-primary:hover {
  box-shadow: 0 10px 40px rgba(52, 224, 161, 0.5);
}
.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
}
.btn-danger {
  background: var(--danger-grad);
  color: #fff;
  box-shadow: 0 8px 30px rgba(255, 77, 94, 0.45);
}
.btn-sm {
  height: 40px;
  padding: 0 18px;
  font-size: 14px;
}

/* ---------- Type ---------- */
.label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--text-dim);
}
.label.accent {
  color: var(--accent);
}
h1,
h2,
h3 {
  margin: 0;
  color: var(--text);
}
.display {
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1.02;
  font-weight: 800;
  letter-spacing: -0.035em;
}
.h-section {
  font-size: clamp(30px, 4.6vw, 48px);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.lede {
  font-size: clamp(17px, 2vw, 20px);
  color: var(--text-muted);
  line-height: 1.55;
}
.grad-text {
  background: var(--signal);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.muted {
  color: var(--text-muted);
}
.dim {
  color: var(--text-dim);
}

/* ---------- Orb (CSS port of components/Orb.tsx) ---------- */
.orb {
  --c1: #d7fff0;
  --c2: #34e0a1;
  --c3: #0b5e4a;
  --size: 260px;
  position: relative;
  width: calc(var(--size) * 1.5);
  height: calc(var(--size) * 1.5);
  display: grid;
  place-items: center;
}
.orb-halo {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--c2) 55%, transparent) 30%, transparent 68%);
  animation: halo 6.4s ease-in-out infinite;
  transition: background 1.2s ease;
}
.orb-core {
  position: relative;
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  background: radial-gradient(circle at 38% 32%, var(--c1) 0%, var(--c2) 42%, var(--c3) 100%);
  animation: breathe 6.4s ease-in-out infinite, spin 24s linear infinite;
  overflow: hidden;
  transition: background 1.2s ease;
}
.orb-core::before,
.orb-core::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 55%, color-mix(in srgb, var(--c1) 40%, transparent));
}
.orb-core::before {
  width: 75%;
  height: 32%;
  left: 10%;
  top: 30%;
  transform: rotate(-35deg);
}
.orb-core::after {
  width: 60%;
  height: 18%;
  left: 30%;
  top: 52%;
  transform: rotate(25deg);
}
.orb-spec {
  position: absolute;
  width: 16%;
  height: 16%;
  left: 27%;
  top: 22%;
  border-radius: 50%;
  background: #fff;
  opacity: 0.35;
  filter: blur(1px);
}
@keyframes breathe {
  0%,
  100% {
    scale: 0.97;
  }
  50% {
    scale: 1.03;
  }
}
@keyframes spin {
  to {
    rotate: 360deg;
  }
}
@keyframes halo {
  0%,
  100% {
    opacity: 0.35;
  }
  50% {
    opacity: 0.65;
  }
}
@media (prefers-reduced-motion: reduce) {
  .orb-core,
  .orb-halo {
    animation: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* ---------- Cards ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px;
}
.icon-tile {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(52, 224, 161, 0.1);
  border: 1px solid rgba(52, 224, 161, 0.25);
  color: var(--accent);
}
.icon-tile svg {
  width: 22px;
  height: 22px;
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  margin-top: 40px;
  padding: 40px 0 48px;
  color: var(--text-dim);
  font-size: 14px;
}
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 28px;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
}
.footer-links a {
  color: var(--text-muted);
}
.footer .crisis {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  line-height: 1.6;
}

/* ---------- Legal pages ---------- */
.legal-hero {
  position: relative;
  padding: 72px 0 36px;
}
.legal-hero h1 {
  font-size: clamp(36px, 6vw, 56px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-top: 10px;
}
.legal-hero .meta {
  margin-top: 14px;
  color: var(--text-muted);
  font-size: 15px;
}
.legal-layout {
  position: relative;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}
.toc {
  position: sticky;
  top: 88px;
  font-size: 14px;
}
.toc ol {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  border-left: 1px solid var(--border);
}
.toc a {
  display: block;
  padding: 6px 0 6px 14px;
  margin-left: -1px;
  border-left: 2px solid transparent;
  color: var(--text-muted);
}
.toc a:hover {
  color: var(--text);
  text-decoration: none;
  border-left-color: var(--accent);
}
.prose {
  max-width: 720px;
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1.7;
}
.prose section {
  scroll-margin-top: 88px;
  padding-bottom: 12px;
}
.prose h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 40px 0 12px;
  color: var(--text);
}
.prose h2 .num {
  color: var(--accent);
  margin-right: 8px;
}
.prose h3 {
  font-size: 16px;
  font-weight: 700;
  margin: 24px 0 8px;
}
.prose p,
.prose ul {
  margin: 0 0 14px;
}
.prose ul {
  padding-left: 20px;
}
.prose li {
  margin-bottom: 8px;
}
.prose li::marker {
  color: var(--accent);
}
.prose strong {
  color: var(--text);
}
.prose .caps {
  font-size: 14px;
  letter-spacing: 0.01em;
}
.callout {
  background: linear-gradient(135deg, rgba(52, 224, 161, 0.08), rgba(34, 184, 240, 0.05));
  border: 1px solid rgba(52, 224, 161, 0.22);
  border-radius: var(--r-md);
  padding: 18px 20px;
  margin: 0 0 28px;
  color: var(--text);
}
.callout.danger {
  background: linear-gradient(135deg, rgba(255, 77, 94, 0.1), rgba(255, 122, 69, 0.05));
  border-color: rgba(255, 77, 94, 0.3);
}
.callout p:last-child {
  margin-bottom: 0;
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0 18px;
  font-size: 14px;
}
.data-table th,
.data-table td {
  text-align: left;
  vertical-align: top;
  padding: 12px 12px 12px 0;
  border-bottom: 1px solid var(--border);
}
.data-table th {
  color: var(--text-dim);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}
.data-table td:first-child {
  color: var(--text);
  font-weight: 600;
  width: 32%;
}
.where {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
}
.where.device {
  color: var(--accent);
  background: rgba(52, 224, 161, 0.12);
}
.where.server {
  color: var(--accent-2);
  background: rgba(34, 184, 240, 0.12);
}
.where.third {
  color: var(--violet);
  background: rgba(139, 124, 255, 0.14);
}

/* Fill-in placeholders: highlighted so they can't ship unnoticed. */
.fill {
  color: var(--gold);
  background: rgba(245, 196, 81, 0.12);
  border-radius: 4px;
  padding: 0 4px;
}

@media (max-width: 900px) {
  .legal-layout {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .toc {
    position: static;
  }
  .toc ol {
    columns: 2;
    column-gap: 20px;
  }
}
@media (max-width: 520px) {
  .toc ol {
    columns: 1;
  }
  .data-table td:first-child {
    width: 40%;
  }
}
