/* Doom Face website - same design tokens as the Android app (DoomColors/DoomType):
   near-black background, single warning-red accent, brutalist system-font display type. */
:root {
  --bg: #0A0A0A;
  --surface: #141414;
  --surface-raised: #1C1C1C;
  --hairline: #2A2A2A;
  --text-primary: #F5F5F5;
  --text-secondary: #9B9B9B;
  --text-tertiary: #6B6B6B;
  --accent: #FF3B30;
  --accent-dim: #7A1F1B;
  --success: #34C759;
  --sidebar-width: 400px;
  --measure: 640px;
  --font-display: -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-body: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin: 0 0 0.5em;
}
p { margin: 0 0 1em; }

/* ---------- header ---------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--hairline);
}
.wordmark {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--text-primary);
}
.wordmark-logo {
  height: 24px;
  width: auto;
  display: block;
}
.site-nav { display: flex; gap: 24px; }
.site-nav a {
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 600;
}
.site-nav a:hover { color: var(--text-primary); }

/* ---------- split layout ---------- */
.split {
  display: flex;
  min-height: calc(100vh - 64px);
}
.sidebar {
  width: var(--sidebar-width);
  flex-shrink: 0;
  padding: 40px 32px;
  border-right: 1px solid var(--hairline);
  overflow-y: auto;
}
.headline {
  font-size: 40px;
  color: var(--text-primary);
  margin-bottom: 16px;
}
.lede { color: var(--text-secondary); font-size: 16px; }
.mechanic { font-size: 20px; font-weight: 800; color: var(--text-primary); }
.mechanic .accent { color: var(--accent); }
.accent { color: var(--accent); }
.stat-line { color: var(--text-primary); font-size: 15px; }
.stat-line strong { color: var(--accent); }

.cta {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: 0.02em;
  font-size: 13px;
  text-decoration: none;
  padding: 16px 24px;
  border-radius: 50px;
  text-align: center;
  margin: 12px 0 32px;
}
.cta-disabled {
  background: var(--surface-raised);
  color: var(--text-tertiary);
  cursor: default;
}

.how-it-works-mini h2 {
  font-size: 13px;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
}
.how-it-works-mini ol {
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: 0 0 16px;
}
.how-it-works-mini li {
  counter-increment: step;
  padding: 6px 0;
  font-size: 15px;
  color: var(--text-primary);
}
.how-it-works-mini li::before {
  content: counter(step) ". ";
  color: var(--accent);
  font-weight: 800;
}
.text-link { color: var(--text-secondary); font-size: 14px; text-decoration: none; }
.text-link:hover { color: var(--text-primary); }

/* ---------- map ---------- */
.map-pane { flex: 1; position: relative; min-width: 0; }
.map-modes {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 2;
  display: flex;
  gap: 4px;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 50px;
  padding: 4px;
}
.map-mode {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.03em;
  padding: 8px 16px;
  border-radius: 50px;
  cursor: pointer;
}
.map-mode.active { background: var(--accent); color: #fff; }

.doom-map {
  width: 100%;
  height: 100%;
  min-height: 480px;
  background: #1a1d21; /* reserved space matches the dark basemap so there is no flash/CLS while it loads */
}
.map-noscript {
  padding: 24px;
  color: var(--text-secondary);
}
.map-error {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--bg);
  padding: 24px;
}
.map-error[hidden] { display: none; }
.map-error strong { font-family: var(--font-display); font-size: 20px; }

/* Doom Face marker + cluster styling drawn by map.js via CSS custom marker elements */
.doom-marker {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background-size: cover;
  background-position: center;
  background-color: var(--surface-raised);
  cursor: pointer;
  transition: width 0.15s ease, height 0.15s ease;
}
.doom-marker.you { border-color: #fff; border-width: 3px; box-shadow: 0 0 0 2px var(--accent); }
.doom-cluster {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--surface-raised);
  border: 2.5px solid var(--accent);
  color: var(--text-primary);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.doom-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 1.5px solid var(--text-primary);
  cursor: pointer;
}

/* ---------- face detail ---------- */
.face-detail {
  position: absolute;
  z-index: 3;
  background: var(--surface);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}
.face-detail .face-photo { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; background: var(--surface-raised); }
.face-detail .face-body { padding: 20px; }
.face-detail .face-app { color: var(--accent); font-family: var(--font-display); font-weight: 800; font-size: 12px; letter-spacing: 0.04em; }
.face-detail .face-caught { font-family: var(--font-display); font-size: 22px; font-weight: 800; margin: 6px 0; }
.face-detail .face-meta { color: var(--text-secondary); font-size: 13px; margin: 2px 0; }
.face-detail .face-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
}
.face-detail .doomed-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 11px;
  padding: 6px 12px;
  border-radius: 50px;
}

@media (min-width: 769px) {
  .face-detail { width: 320px; bottom: 24px; right: 24px; }
}
@media (max-width: 768px) {
  .face-detail { left: 0; right: 0; bottom: 0; width: 100%; border-radius: 20px 20px 0 0; }
}

/* ---------- SEO content ---------- */
.seo-content {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 64px 24px 96px;
}
.seo-content h2 {
  font-size: 22px;
  margin-top: 2em;
  color: var(--text-primary);
}
.seo-content p { color: var(--text-secondary); font-size: 16px; }
.faq { margin: 0; }
.faq dt { color: var(--text-primary); font-weight: 700; margin-top: 16px; }
.faq dd { color: var(--text-secondary); margin: 4px 0 0; }

/* ---------- generic page content (how-it-works, plus, legal, 404) ---------- */
.page-content {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 64px 24px 96px;
}
.page-content h1 { font-size: 32px; }
.page-content h2 { font-size: 20px; margin-top: 2em; }
.page-content p { color: var(--text-secondary); font-size: 16px; }
.page-content a { color: var(--accent); }

.plus-features {
  list-style: none;
  padding: 0;
  margin: 24px 0;
  display: grid;
  gap: 8px;
}
.plus-features li {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.02em;
  color: var(--text-primary);
  padding: 12px 16px;
  background: var(--surface);
  border-radius: 10px;
}
.plus-price { font-family: var(--font-display); font-size: 28px; font-weight: 900; color: var(--accent); margin: 24px 0 4px; }
.plus-note { color: var(--text-tertiary); font-size: 13px; }

.legal-page { max-width: 720px; }
.legal-updated { color: var(--text-tertiary); font-size: 13px; }
.legal-callout {
  background: var(--surface);
  border-left: 3px solid var(--accent);
  padding: 16px 20px;
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 15px;
}
.legal-page h2 { font-size: 17px; color: var(--text-primary); }
.legal-page p { font-size: 15px; }

.not-found { text-align: center; padding-top: 120px; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--hairline); padding: 24px; }
.site-footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  color: var(--text-tertiary);
  font-size: 13px;
  max-width: 1200px;
  margin: 0 auto;
}
.site-footer-inner a { color: var(--text-secondary); text-decoration: none; }
.site-footer-inner a:hover { color: var(--text-primary); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .split { flex-direction: column; }
  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--hairline);
    padding: 24px 20px;
  }
  .headline { font-size: 32px; }
  .map-pane { min-height: 70vh; }
  .doom-map { min-height: 70vh; }
}
@media (max-width: 400px) {
  .headline { font-size: 28px; }
  .site-header { padding: 14px 16px; }
}
