:root {
  --bg: #e8eaf8;
  --ink: #1b1730;
  --muted: #5e5974;
  --card: #ffffff;
  --line: #e3e5f2;
  --soft: #f4f5fb;
  --accent: #4f46e5;
  --accent-2: #7c74f6;
  --shadow: 0 18px 50px rgba(48, 42, 92, 0.08);
  --radius: 22px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(900px 420px at 50% -10%, #f7f7ff 0%, transparent 60%),
    var(--bg);
  color: var(--ink);
  font-family: Outfit, system-ui, sans-serif;
}

.page {
  width: min(760px, calc(100% - 28px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.bolt {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(180deg, #5b54f0, #4338ca);
  color: white;
  box-shadow: 0 8px 16px rgba(67, 56, 202, 0.28);
}

.badge {
  border: 1.5px solid #c9c6f5;
  color: #5146d6;
  background: #f3f2ff;
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.progress-wrap { margin: 8px 0 16px; }

.progress-label {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #6d6886;
  margin-bottom: 8px;
}

.progress-track {
  height: 10px;
  background: #d9dced;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 8%;
  border-radius: inherit;
  background: linear-gradient(90deg, #312e81, #6366f1 55%, #8b84f8);
  transition: width 0.35s ease;
}

.profile-card {
  display: flex;
  gap: 18px;
  align-items: center;
  background: var(--card);
  border-radius: 28px;
  padding: 18px 20px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}

.ring {
  --pct: 8;
  width: 92px;
  height: 92px;
  flex: none;
  border-radius: 50%;
  background: conic-gradient(#4f46e5 calc(var(--pct) * 1%), #eceef8 0);
  display: grid;
  place-items: center;
}

.ring div {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: white;
  display: grid;
  place-items: center;
  align-content: center;
  text-align: center;
}

.ring strong {
  font-size: 18px;
  line-height: 1;
}

.ring span {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.profile-card h2 {
  margin: 0 0 10px;
  font-family: Fraunces, Georgia, serif;
  font-size: 28px;
  font-weight: 560;
  letter-spacing: -0.03em;
}

.pills { display: flex; flex-wrap: wrap; gap: 8px; }

.pill {
  border: 0;
  background: #eef0f7;
  color: #6a6580;
  border-radius: 999px;
  padding: 6px 10px;
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.pill.on {
  background: #ecebff;
  color: #4338ca;
}

.intro-pill {
  display: inline-flex;
  margin-bottom: 14px;
  border-radius: 999px;
  background: #ecebff;
  color: #4c43c7;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 10px 14px;
}

h1 {
  margin: 0 0 10px;
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(36px, 6vw, 58px);
  line-height: 0.98;
  letter-spacing: -0.04em;
  font-weight: 560;
}

.lede {
  margin: 0 0 22px;
  color: #3f3b55;
  font-size: 18px;
  line-height: 1.45;
}

.meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: #6d6884;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.question {
  margin: 0 0 8px;
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(28px, 4vw, 36px);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.hint {
  margin: 0 0 16px;
  color: var(--muted);
}

.options, .topics {
  display: grid;
  gap: 10px;
}

.topics { grid-template-columns: 1fr 1fr; }

.option, .topic, .continue, .text-btn {
  font: inherit;
  text-align: left;
  border: 1px solid var(--line);
  background: white;
  color: inherit;
  border-radius: 16px;
  cursor: pointer;
}

.option {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  box-shadow: 0 8px 20px rgba(40, 36, 80, 0.04);
}

.option:hover, .topic:hover, .continue:hover { border-color: #c9c6f2; }

.option:focus-visible, .topic:focus-visible, .continue:focus-visible, .text-btn:focus-visible {
  outline: 3px solid #c7c4ff;
  outline-offset: 2px;
}

.emoji {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--soft);
  font-size: 22px;
}

.option strong, .topic strong { display: block; font-size: 16px; }
.option span, .topic span { color: var(--muted); font-size: 14px; }

.topic {
  padding: 12px;
  display: flex;
  gap: 8px;
  align-items: center;
}

.topic.on {
  border-color: #4f46e5;
  background: #f5f4ff;
  box-shadow: inset 0 0 0 1px #4f46e5;
}

.continue {
  margin-top: 12px;
  width: 100%;
  text-align: center;
  background: #1b1730;
  color: white;
  font-weight: 700;
  padding: 14px 16px;
  border: 0;
}

.continue:disabled {
  background: #c9c7d6;
  cursor: not-allowed;
}

.row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
}

.text-btn {
  border: 0;
  background: transparent;
  color: #5146d6;
  font-weight: 650;
  padding: 8px 0;
}

.checks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.checks span {
  background: white;
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 650;
  color: #3d3958;
}

.panel {
  background: white;
  border-radius: var(--radius);
  padding: 28px 22px;
  box-shadow: var(--shadow);
  text-align: center;
}

.panel h1 { font-size: clamp(32px, 5vw, 46px); }

.score {
  font-family: Fraunces, Georgia, serif;
  font-size: 64px;
  margin: 0;
  letter-spacing: -0.04em;
}

.steps {
  text-align: left;
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.steps article {
  background: var(--soft);
  border-radius: 14px;
  padding: 12px 14px;
}

.steps strong { display: block; }
.steps p { margin: 4px 0 0; color: var(--muted); }

.again {
  border: 0;
  background: #1b1730;
  color: white;
  font: inherit;
  font-weight: 700;
  border-radius: 999px;
  padding: 12px 18px;
  cursor: pointer;
}

.foot {
  margin-top: 28px;
  color: #6d6884;
  font-size: 13px;
  text-align: center;
}

.foot a { color: #4338ca; }

.legal {
  width: min(720px, calc(100% - 32px));
  margin: 40px auto 64px;
}

.legal h1 { font-size: 42px; }
.legal p, .legal li { color: #3f3b55; line-height: 1.55; }

@media (max-width: 640px) {
  .topics { grid-template-columns: 1fr; }
  .profile-card { flex-direction: column; align-items: flex-start; }
  .profile-card h2 { font-size: 22px; }
}
