/* ===========================================================================
   COMPONENTS — vanilla-CSS ports of the Claude Design React primitives
   (Button, QuizOption, ProgressBar, Field, Card, Pill, Checklist, Testimonial,
   ResultIllustration). Hover/press/focus states use real CSS pseudo-classes
   instead of the originals' inline JS handlers.
   =========================================================================== */

/* ---------- Button ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  font-family: var(--font-body);
  font-weight: var(--fw-bold);
  letter-spacing: 0.01em;
  text-align: center;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  cursor: pointer;
  text-decoration: none;
  line-height: 1.1;
  transition: transform var(--dur-fast) var(--ease-soft), box-shadow var(--dur-med) var(--ease-soft),
    background var(--dur-med) var(--ease-soft), color var(--dur-med) var(--ease-soft);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(1px) scale(0.99); }

.btn--sm { font-size: 0.9rem; padding: 0.6rem 1.1rem; }
.btn--md { font-size: 1rem; padding: 0.85rem 1.6rem; }
.btn--lg { font-size: 1.0625rem; padding: 1.05rem 2rem; min-height: 56px; }
.btn--full { width: 100%; }

.btn--primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-cta); }
.btn--accent { background: var(--accent); color: #fff; box-shadow: 0 10px 26px rgba(191, 116, 199, 0.34); }
.btn--gold { background: var(--gradient-gold); color: #4a3410; box-shadow: 0 10px 26px rgba(201, 162, 75, 0.34); }
.btn--secondary { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn--ghost { background: transparent; color: var(--accent-strong); }

/* ---------- QuizOption ---------- */
.quiz-option {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  text-align: left;
  padding: 1.05rem 1.15rem;
  min-height: 64px;
  background: linear-gradient(135deg, var(--blush-100) 0%, var(--cream-50) 100%);
  border: 2px solid var(--border-blush);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  font: inherit;
  transition: border-color var(--dur-fast) var(--ease-soft), background var(--dur-med) var(--ease-soft),
    box-shadow var(--dur-med) var(--ease-soft), transform var(--dur-fast) var(--ease-soft);
}
.quiz-option:hover:not(.is-selected) {
  border-color: var(--orchid-300);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(191, 116, 199, 0.16);
}
.quiz-option.is-selected {
  background: linear-gradient(135deg, var(--blush-200) 0%, var(--blush-100) 55%, var(--cream-50) 100%);
  border-color: var(--accent);
  box-shadow: 0 12px 30px rgba(191, 116, 199, 0.24), 0 0 30px rgba(217, 185, 104, 0.38);
  animation: ic-select-pulse 620ms var(--ease-soft) 1;
}
.quiz-option__shimmer {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-lg);
  background: linear-gradient(100deg, transparent 30%, rgba(245, 228, 176, 0.55) 50%, transparent 70%);
  background-size: 200% 100%;
  animation: ic-gold-shimmer 1400ms var(--ease-soft) 1;
  pointer-events: none;
  mix-blend-mode: screen;
  display: none;
}
.quiz-option.is-selected .quiz-option__shimmer { display: block; }
.quiz-option__sparkle {
  position: absolute;
  color: var(--gold-400);
  pointer-events: none;
  display: none;
}
.quiz-option.is-selected .quiz-option__sparkle {
  display: block;
  animation: ic-sparkle-pop 720ms var(--ease-soft) both;
}
.quiz-option__letter {
  flex: 0 0 auto;
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: var(--fw-display-bold);
  background: var(--blush-200);
  color: var(--violet-600);
  transition: background var(--dur-fast) var(--ease-soft), color var(--dur-fast) var(--ease-soft), box-shadow var(--dur-med) var(--ease-soft);
}
.quiz-option.is-selected .quiz-option__letter {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 16px rgba(191, 116, 199, 0.55);
}
.quiz-option__text {
  flex: 1;
  position: relative;
  font-family: var(--font-body);
  font-size: 1.02rem;
  line-height: 1.4;
  color: var(--text-body);
  font-weight: var(--fw-body);
}
.quiz-option.is-selected .quiz-option__text { font-weight: var(--fw-semibold); }
.quiz-option__check {
  flex: 0 0 auto;
  position: relative;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity var(--dur-fast) var(--ease-soft), transform var(--dur-fast) var(--ease-soft);
  color: var(--gold-600);
}
.quiz-option.is-selected .quiz-option__check { opacity: 1; transform: scale(1); }

/* ---------- ProgressBar ---------- */
.progress__row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 0.5rem; }
.progress__label {
  font-family: var(--font-body);
  font-weight: var(--fw-bold);
  font-size: 0.8125rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--progress-label, var(--accent-strong));
  white-space: nowrap;
}
.progress__pct { font-family: var(--font-body); font-size: 0.8125rem; color: var(--progress-sub, var(--text-muted)); white-space: nowrap; padding-left: 0.75rem; }
.progress__track {
  height: 12px;
  width: 100%;
  border-radius: var(--radius-pill);
  background: var(--progress-track, var(--blush-200));
  box-shadow: inset 0 1px 3px rgba(74, 60, 130, 0.2);
}
.progress__fill {
  height: 100%;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, #b8893c 0%, #d9b968 45%, #f5e4b0 100%);
  transition: width var(--dur-slow) var(--ease-soft), box-shadow var(--dur-slow) var(--ease-soft);
}

/* ---------- Field ---------- */
.field { width: 100%; }
.field__label { display: block; font-family: var(--font-body); font-weight: var(--fw-semibold); font-size: 0.9rem; color: var(--ink-700); margin-bottom: 0.4rem; }
.field__input {
  width: 100%;
  min-height: 54px;
  padding: 0.9rem 1.1rem;
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: var(--text-body);
  background: var(--surface-card);
  border: 2px solid var(--border-blush);
  border-radius: var(--radius-md);
  outline: none;
  transition: border-color var(--dur-fast) var(--ease-soft), box-shadow var(--dur-fast) var(--ease-soft);
}
.field__input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--focus-ring); }

/* ---------- Card ---------- */
.card { border-radius: var(--radius-lg); padding: var(--space-6); box-shadow: var(--shadow-md); }
.card--paper { background: var(--surface-card); color: var(--text-body); border: 1px solid var(--border-blush); }
.card--blush { background: var(--blush-100); color: var(--text-body); border: 1px solid var(--border-blush); }
.card--cream { background: var(--cream-200); color: var(--text-body); border: 1px solid var(--sand-300); }
.card--night { background: var(--gradient-night); color: var(--text-on-dark); border: 1px solid rgba(214, 163, 219, 0.25); box-shadow: var(--shadow-lg); }

/* ---------- Pill ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  padding: 0.42em 0.95em;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
}
.pill--blush { background: var(--blush-100); color: var(--violet-600); border-color: var(--border-blush); }
.pill--gold { background: rgba(217, 185, 104, 0.18); color: var(--gold-600); border-color: var(--gold-400); }
.pill--violet { background: var(--violet-600); color: #fff; }
.pill--night { background: rgba(255, 255, 255, 0.1); color: var(--text-on-dark); border-color: rgba(214, 163, 219, 0.35); }

/* ---------- Checklist ---------- */
.checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--space-4); }
.checklist__item { display: flex; gap: 0.85rem; align-items: flex-start; }
.checklist__marker { flex: 0 0 auto; margin-top: 0.15rem; color: var(--checklist-marker, var(--gold-600)); }
.checklist__text { font-family: var(--font-body); font-size: 1.05rem; line-height: 1.55; color: var(--checklist-color, var(--text-body)); }

/* ---------- Testimonial ---------- */
.testimonial {
  margin: 0;
  padding: var(--space-7) var(--space-6);
  border-radius: var(--radius-xl);
  background: var(--blush-100);
  color: var(--text-body);
  border: 1px solid var(--border-blush);
  box-shadow: var(--shadow-md);
  text-align: center;
}
.testimonial--night { background: var(--gradient-night); color: var(--text-on-dark); border-color: rgba(214, 163, 219, 0.25); box-shadow: var(--shadow-lg); }
.testimonial__mark { font-family: var(--font-display); font-size: 3.5rem; line-height: 0.6; color: var(--orchid-500); display: block; margin-bottom: 0.5rem; }
.testimonial--night .testimonial__mark { color: var(--gold-400); }
.testimonial__quote { margin: 0 auto var(--space-5); max-width: 38ch; font-family: var(--font-display); font-size: clamp(1.4rem, 1rem + 1.6vw, 1.9rem); font-weight: var(--fw-display); font-style: italic; line-height: 1.35; color: var(--violet-700); }
.testimonial--night .testimonial__quote { color: #fff; }
.testimonial__name { display: block; font-family: var(--font-body); font-weight: var(--fw-bold); font-size: 1rem; color: var(--violet-600); }
.testimonial--night .testimonial__name { color: var(--gold-200); }
.testimonial__detail { display: block; font-family: var(--font-body); font-size: 0.9rem; color: var(--text-muted); margin-top: 0.2rem; }
.testimonial--night .testimonial__detail { color: var(--text-on-dark-muted); }

/* ---------- ResultIllustration ---------- */
.result-illustration {
  position: relative;
  border-radius: 50%;
  background: var(--gradient-night);
  box-shadow: var(--shadow-glow), var(--shadow-lg);
  overflow: hidden;
  display: grid;
  place-items: center;
}
.result-illustration::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-aura);
  mix-blend-mode: screen;
}
.result-illustration svg { position: relative; }
