:root {
  --bg: #0B0B0C;
  --card: #141415;
  --card-hover: #1B1B1D;
  --border: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.28);
  --text: #F2F2F0;
  --muted: rgba(242, 242, 240, 0.58);
  --blue: #0038CC;
  --blue-hover: #1A4FE0;
  --blue-soft: rgba(26, 79, 224, 0.16);
  --danger: #FF6B5E;
  --font: "Helvetica Neue", "Inter Tight", Helvetica, Arial, sans-serif;
}

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

/* Top bar */
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px clamp(16px, 2.5vw, 40px);
}
.brand { font-weight: 700; font-size: 16px; letter-spacing: -0.01em; }
.close {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 22px; line-height: 1;
  color: var(--muted);
}
.close:hover { color: var(--text); border-color: var(--border-strong); }

/* Layout */
.shell {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(24px, 6vh, 72px) 16px 96px;
}

/* Progress */
.progress-meta {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 13px !important;
  display: flex;
  justify-content: space-between;
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 14px;
  font-variant-numeric: tabular-nums;
}
.progress-track {
  height: 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.10);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  width: 0;
  background: var(--blue-hover);
  border-radius: 4px;
}

/* Step */
.step { margin-top: clamp(40px, 7vh, 80px); }

.step-head { display: flex; gap: 18px; align-items: flex-start; }
.back {
  flex: none;
  width: 44px; height: 44px;
  margin-top: 6px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  font-size: 18px;
  cursor: pointer;
}
.back:hover { color: var(--text); border-color: var(--border-strong); }

.q {
  font-weight: 700;
  font-size: clamp(32px, 5vw, 52px);
  letter-spacing: -0.045em;
  line-height: 1.04;
}
.hint {
  margin-top: 14px;
  font-size: 18px;
  line-height: 1.45;
  color: var(--muted);
}
.step-body { margin-top: 36px; }

/* Inputs */
.field + .field { margin-top: 20px; }
.label { display: block; font-size: 15px; font-weight: 500; color: var(--muted); margin-bottom: 10px; }
.input, .textarea {
  width: 100%;
  font: inherit;
  font-size: 19px;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px 20px;
  outline: none;
}
.textarea { min-height: 170px; resize: vertical; line-height: 1.5; }
.input::placeholder, .textarea::placeholder { color: rgba(242, 242, 240, 0.32); }
.input:focus, .textarea:focus { border-color: var(--blue-hover); box-shadow: 0 0 0 4px var(--blue-soft); }
.input.invalid, .textarea.invalid { border-color: var(--danger); }
.error { margin-top: 10px; font-size: 15px; color: var(--danger); min-height: 1em; }

.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.row-2 .field + .field { margin-top: 0; }

/* Option cards */
.options { display: grid; gap: 12px; }
.options.cols-2 { grid-template-columns: 1fr 1fr; }
.opt {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  width: 100%;
  text-align: left;
  font: inherit;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px 22px;
  cursor: pointer;
}
.options.cols-2 .opt { padding: 18px 20px; }
.opt:hover { background: var(--card-hover); border-color: var(--border-strong); }
.opt:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--blue-soft); border-color: var(--blue-hover); }
.opt .dot {
  flex: none;
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 1.5px solid var(--border-strong);
  display: grid; place-items: center;
}
.opt.selected { border-color: var(--blue-hover); background: var(--blue-soft); }
.opt.selected .dot { border-color: var(--blue-hover); }
.opt.selected .dot::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--blue-hover); }
.opt-title { font-size: 19px; font-weight: 500; }
.opt-sub { display: block; margin-top: 6px; font-size: 16px; color: var(--muted); }

/* Multi-select pills */
.pills { display: flex; flex-wrap: wrap; gap: 10px; }
.pill {
  font: inherit;
  font-size: 17px;
  font-weight: 500;
  color: var(--text);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 20px;
  cursor: pointer;
}
.pill:hover { border-color: var(--border-strong); background: var(--card-hover); }
.pill:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--blue-soft); }
.pill.selected { background: var(--blue); border-color: var(--blue); color: #fff; }

/* Slider */
.slider-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 40px clamp(20px, 5vw, 48px) 34px;
}
.slider-value { text-align: center; font-weight: 700; font-size: clamp(48px, 8vw, 72px); letter-spacing: -0.05em; line-height: 1; }
.slider-unit { text-align: center; color: var(--muted); margin-top: 10px; font-size: 16px; }
.range-wrap { position: relative; margin-top: 44px; }
.ticks {
  height: 12px;
  margin: 0 11px 12px;
  background-image: repeating-linear-gradient(90deg, var(--border-strong) 0 1px, transparent 1px calc(100% / 30));
  background-size: calc(100% + 1px) 100%;
  opacity: .8;
}
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 22px;
  background: transparent;
  cursor: pointer;
  --pct: 33%;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--blue-hover) var(--pct), rgba(255,255,255,.14) var(--pct));
}
input[type="range"]::-moz-range-track { height: 4px; border-radius: 4px; background: rgba(255,255,255,.14); }
input[type="range"]::-moz-range-progress { height: 4px; border-radius: 4px; background: var(--blue-hover); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px; height: 24px;
  margin-top: -10px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid #fff;
}
input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--bg); border: 2px solid #fff; }
input[type="range"]:focus-visible { outline: none; }
input[type="range"]:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 6px var(--blue-soft); }
.range-labels { display: flex; justify-content: space-between; margin-top: 14px; font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Actions */
.actions { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 32px; }
.actions .note { font-size: 15px; color: var(--muted); }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  background: var(--blue);
  border: 0;
  border-radius: 8px;
  padding: 17px 32px;
  cursor: pointer;
}
.btn:hover { background: var(--blue-hover); }
.btn:disabled { opacity: .5; cursor: default; }
.btn-full { width: 100%; }
.kbd { font-size: 14px; color: var(--muted); }
.kbd b { font-weight: 600; color: var(--text); }

.legal { margin-top: 18px; font-size: 14px; line-height: 1.5; color: var(--muted); }

/* Done */
.done { text-align: left; }
.done .check {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--blue);
  display: grid; place-items: center;
  font-size: 26px;
  margin-bottom: 28px;
}
.done .btn { margin-top: 36px; }

@media (max-width: 640px) {
  .options.cols-2, .row-2 { grid-template-columns: 1fr; }
  .row-2 .field + .field { margin-top: 20px; }
  .step-head { gap: 12px; }
  .back { width: 38px; height: 38px; margin-top: 2px; }
  .actions { flex-direction: column-reverse; align-items: stretch; }
  .actions .btn { width: 100%; }
  .kbd { display: none; }
}

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
