:root {
  --bg: #0D1117;
  --bg-2: #161B22;
  --bg-3: #1C2128;
  --fg: #E6EDF3;
  --fg-muted: #8B949E;
  --accent: #00D4A7;
  --accent-glow: rgba(0, 212, 167, 0.15);
  --amber: #F59E0B;
  --amber-glow: rgba(245, 158, 11, 0.2);
  --red: #F85149;
  --mid: #FFB347;
  --border: rgba(255,255,255,0.06);
  --font-display: 'Instrument Serif', Georgia, serif;
  --font-body: 'DM Sans', system-ui, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── NAV ────────────────────────────────────────────── */
.nav {
  padding: 1.25rem 2rem;
  border-bottom: 1px solid var(--border);
  background: rgba(13,17,23,0.8);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  color: var(--fg);
}
.nav-tagline {
  font-size: 0.8rem;
  color: var(--fg-muted);
  letter-spacing: 0.02em;
}

/* ── HERO ───────────────────────────────────────────── */
.hero {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem 4rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

/* Map visual */
.hero-map {
  position: relative;
}
.map-grid {
  width: 100%;
  aspect-ratio: 1;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}
.map-grid::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 60% 40%, rgba(0,212,167,0.05) 0%, transparent 70%);
}
.grid-line-h, .grid-line-v {
  position: absolute;
  background: rgba(255,255,255,0.04);
}
.grid-line-h { height: 1px; width: 100%; }
.grid-line-h:nth-child(1) { top: 20%; }
.grid-line-h:nth-child(2) { top: 40%; }
.grid-line-h:nth-child(3) { top: 60%; }
.grid-line-h:nth-child(4) { top: 80%; }
.grid-line-v { width: 1px; height: 100%; }
.grid-line-v:nth-child(6) { left: 20%; }
.grid-line-v:nth-child(7) { left: 40%; }
.grid-line-v:nth-child(8) { left: 60%; }
.grid-line-v:nth-child(9) { left: 80%; }

.pin {
  position: absolute;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  transform: translate(-50%, -50%);
  z-index: 2;
}
.pin::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  animation: pin-pulse 3s ease-in-out infinite;
}
.pin-high {
  background: var(--accent);
  color: #0D1117;
  box-shadow: 0 0 16px rgba(0,212,167,0.5);
}
.pin-high::before {
  box-shadow: 0 0 0 0 rgba(0,212,167,0.3);
  animation: pin-pulse 2.5s ease-in-out infinite;
}
.pin-mid {
  background: var(--amber);
  color: #0D1117;
  box-shadow: 0 0 12px rgba(245,158,11,0.4);
}
.pin-low {
  background: var(--bg-3);
  border: 1px solid rgba(248,81,73,0.4);
  color: var(--red);
  box-shadow: 0 0 8px rgba(248,81,73,0.2);
}
.pin-label { position: relative; z-index: 1; }

/* pin positions */
.pin-1 { left: 25%; top: 30%; }
.pin-2 { left: 65%; top: 25%; }
.pin-3 { left: 45%; top: 45%; }
.pin-4 { left: 75%; top: 55%; }
.pin-5 { left: 20%; top: 70%; }
.pin-6 { left: 55%; top: 75%; }
.pin-7 { left: 85%; top: 35%; }
.pin-8 { left: 35%; top: 55%; }
.pin-9 { left: 60%; top: 85%; }

@keyframes pin-pulse {
  0% { box-shadow: 0 0 0 0 rgba(0,212,167,0.4); }
  70% { box-shadow: 0 0 0 12px rgba(0,212,167,0); }
  100% { box-shadow: 0 0 0 0 rgba(0,212,167,0); }
}

.map-legend {
  display: flex;
  gap: 1.25rem;
  margin-top: 1rem;
  justify-content: center;
}
.legend-item {
  font-size: 0.72rem;
  font-family: var(--font-body);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.legend-item::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.legend-high::before { background: var(--accent); box-shadow: 0 0 6px var(--accent); }
.legend-mid::before { background: var(--amber); }
.legend-low::before { background: var(--bg-3); border: 1px solid rgba(248,81,73,0.5); }
.legend-high { color: var(--accent); }
.legend-mid { color: var(--amber); }
.legend-low { color: var(--fg-muted); }

/* Hero content */
.hero-content { display: flex; flex-direction: column; justify-content: center; gap: 1.5rem; }
.hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  font-family: var(--font-body);
}
.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 4.5vw, 4rem);
  line-height: 1.05;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--fg);
}
.hero-headline em { font-style: italic; color: var(--accent); }
.hero-body {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--fg-muted);
  max-width: 480px;
}
.hero-stats {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding-top: 0.5rem;
}
.stat { display: flex; flex-direction: column; gap: 0.2rem; }
.stat-value {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 400;
  color: var(--fg);
  line-height: 1;
}
.stat-label { font-size: 0.72rem; color: var(--fg-muted); line-height: 1.4; }
.stat-divider { width: 1px; height: 36px; background: var(--border); }

/* ── SECTION SHARED ───────────────────────────────── */
.section-label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.section-label::after {
  content: '';
  flex: 1;
  max-width: 48px;
  height: 1px;
  background: var(--border);
}
.section-heading {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 2.5vw, 2.4rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--fg);
}
.section-body {
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--fg-muted);
  margin-top: 1rem;
}

/* ── VISIBILITY SECTION ───────────────────────────── */
.visibility-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
  border-top: 1px solid var(--border);
}
.visibility-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
.feature-list {
  list-style: none;
  margin-top: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}
.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--fg-muted);
  line-height: 1.5;
}
.feature-list svg { flex-shrink: 0; margin-top: 0.1rem; }

/* Profile card */
.profile-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.profile-header { display: flex; align-items: center; gap: 0.875rem; }
.profile-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, #00A884 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: #0D1117;
  flex-shrink: 0;
}
.profile-name {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--fg);
}
.profile-stars { display: flex; align-items: center; gap: 0.25rem; margin-top: 0.2rem; }
.profile-review-count { font-size: 0.72rem; color: var(--fg-muted); margin-left: 0.25rem; }
.profile-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  padding: 0.3rem 0.65rem;
  border-radius: 20px;
  width: fit-content;
}
.badge-active { background: rgba(0,212,167,0.1); color: var(--accent); }
.badge-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.profile-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
.metric {
  background: var(--bg-3);
  border-radius: 10px;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.metric-num { font-size: 1.2rem; font-weight: 600; color: var(--fg); font-family: var(--font-display); }
.metric-label { font-size: 0.65rem; color: var(--fg-muted); }
.metric-trend { font-size: 0.65rem; font-weight: 500; }
.metric-trend.up { color: var(--accent); }
.profile-bar { display: flex; align-items: center; gap: 0.75rem; }
.profile-bar-label { font-size: 0.72rem; color: var(--fg-muted); white-space: nowrap; }
.profile-bar-track { flex: 1; height: 6px; background: var(--bg-3); border-radius: 3px; overflow: hidden; }
.profile-bar-fill { height: 100%; background: linear-gradient(90deg, var(--accent), #00A884); border-radius: 3px; }
.profile-bar-pct { font-size: 0.72rem; color: var(--accent); font-weight: 600; white-space: nowrap; }

/* ── RANKINGS SECTION ─────────────────────────────── */
.rankings-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
  border-top: 1px solid var(--border);
}
.rankings-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.rankings-headline-col .section-heading { max-width: 420px; }

/* Mini map */
.mini-map {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}
.mini-map-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
}
.cell {
  aspect-ratio: 1;
  border-radius: 4px;
}
.cell-high { background: var(--accent); box-shadow: 0 0 8px rgba(0,212,167,0.4); }
.cell-mid { background: var(--amber); }
.cell-low { background: var(--bg-3); border: 1px solid rgba(248,81,73,0.25); }
.mini-map-label { font-size: 0.65rem; color: var(--fg-muted); margin-top: 0.75rem; text-align: center; }

.rank-breakdown { display: flex; flex-direction: column; gap: 0.6rem; }
.breakdown-item { display: flex; align-items: center; gap: 0.75rem; }
.breakdown-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.breakdown-dot.high { background: var(--accent); }
.breakdown-dot.mid { background: var(--amber); }
.breakdown-dot.low { background: var(--bg-3); border: 1px solid rgba(248,81,73,0.4); }
.breakdown-label { flex: 1; font-size: 0.82rem; color: var(--fg-muted); }
.breakdown-pct { font-size: 0.82rem; font-weight: 600; color: var(--fg); font-family: var(--font-display); }

/* ── AI SECTION ───────────────────────────────────── */
.ai-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
  border-top: 1px solid var(--border);
}
.ai-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.ai-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.72rem;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid rgba(0,212,167,0.2);
  border-radius: 20px;
  padding: 0.3rem 0.75rem;
  width: fit-content;
  margin-bottom: 1rem;
}
.ai-headline-col .section-heading { max-width: 400px; }

.ai-platforms { display: flex; flex-direction: column; gap: 0.75rem; }
.platform-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.platform-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--bg-3);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.platform-name { font-size: 0.82rem; font-weight: 600; color: var(--fg); }
.platform-status { font-size: 0.72rem; margin-top: 0.15rem; }
.platform-status.cited { color: var(--accent); }
.platform-status.missing { color: var(--red); }

/* ── CLOSING ──────────────────────────────────────── */
.closing-section {
  border-top: 1px solid var(--border);
  padding: 6rem 2rem 5rem;
  position: relative;
  overflow: hidden;
}
.closing-inner {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}
.closing-grid-lines {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  pointer-events: none;
}
.closing-line {
  border-right: 1px solid var(--border);
  height: 100%;
  opacity: 0.5;
}
.closing-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 300px;
  background: radial-gradient(ellipse, rgba(0,212,167,0.06) 0%, transparent 70%);
  pointer-events: none;
}
.closing-pins { position: absolute; inset: 0; pointer-events: none; }
.closing-pin {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 20px var(--accent);
  animation: closing-pulse 4s ease-in-out infinite;
}
.cp-1 { top: 30%; left: 15%; animation-delay: 0s; }
.cp-2 { top: 50%; left: 45%; animation-delay: 1s; }
.cp-3 { top: 60%; right: 20%; animation-delay: 2s; }
@keyframes closing-pulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.3); }
}
.closing-text { position: relative; z-index: 1; }
.closing-headline {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 3.5vw, 3.5rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.025em;
  color: var(--fg);
  max-width: 680px;
}
.closing-headline em { font-style: italic; color: var(--accent); }
.closing-sub {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--fg-muted);
  max-width: 540px;
  margin-top: 1.25rem;
}

/* ── FOOTER ────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--fg-muted);
}
.footer-note { font-size: 0.72rem; color: var(--fg-muted); }

/* ── RESPONSIVE ────────────────────────────────────── */
@media (max-width: 768px) {
  .hero { grid-template-columns: 1fr; gap: 2.5rem; padding: 3rem 1.5rem 2.5rem; }
  .hero-map { order: -1; }
  .map-grid { max-width: 380px; margin: 0 auto; }
  .visibility-grid, .rankings-layout, .ai-layout { grid-template-columns: 1fr; }
  .profile-metrics { grid-template-columns: repeat(3, 1fr); }
  .visibility-section, .rankings-section, .ai-section { padding: 3.5rem 1.5rem; }
  .closing-section { padding: 4rem 1.5rem 3rem; }
  .nav-tagline { display: none; }
  .hero-stats { flex-wrap: wrap; gap: 1rem; }
}
