:root {
  --bg: #f8f7fc;
  --ink: #242038;
  --muted: #605b72;
  --line: #e1ddeb;
  --green: #5026aa;
  --lime: #ffce79;
  color-scheme: light;
}

.header-inner { min-height: 72px; }
.header nav a { min-height: 44px; }
.brandmark { background: #3d236d; }
.brand-dot { color: #7652c0; }
a:hover { color: #5835a4; }
.primary, .secondary, .quiet { min-height: 48px; }
.primary:hover { color: white; background: #3c188c; }
.primary:focus-visible, .choice:focus-visible { outline-color: #7459b9; }

.launch {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: clamp(22px, 5vw, 76px);
  padding: clamp(28px, 5vw, 68px);
  border-radius: 28px;
  background: radial-gradient(ellipse at 14% 20%, #6a439a 0, transparent 60%), #271a43;
  color: white;
}
.kicker { font-size: .875rem; font-weight: 700; margin: 0 0 10px; color: #6842b6; }
.launch .kicker { color: #e4d4fb; }
.launch h1 { font-size: clamp(2.5rem, 5vw, 5rem); line-height: 1.08; margin: 0 0 17px; }
.launch-guide { max-width: 410px; color: #eee6f8; }
.launch .actions { align-items: center; }
.launch .primary { background: var(--lime); color: #2b1c36; }
.launch .quiet { color: white; text-decoration: underline; text-underline-offset: 4px; }
.launch-meta { margin: 13px 0 0; font-size: .9rem; color: #e4d4fb; }
.preview-scene { position: relative; min-width: 0; padding: 16px 0 16px 12px; }
.preview-scene::before {
  content: ''; position: absolute; inset: 8% 3% 4% 0;
  border-radius: 24px; background: #b490e5; transform: rotate(-6deg);
}
.preview-card {
  position: relative; padding: clamp(22px, 4vw, 38px); border-radius: 23px;
  background: #f7efff; color: var(--ink); box-shadow: 0 18px 48px #150b2c54;
}
.preview-card .kicker { color: #6842b6; }
.preview-card h2 { font-size: 1.6rem; margin-bottom: 14px; }
.preview-card blockquote {
  margin: 0 0 16px; padding: 12px 16px; background: white; border-radius: 12px;
  border-inline-start: 3px solid #aa88e8; font-size: 1.12rem; font-weight: 700;
}
.preview-card a { display: inline-flex; align-items: center; min-height: 44px; color: #542bad; font-weight: 700; text-decoration: underline; text-underline-offset: 4px; }

.library { scroll-margin-top: 18px; }
.library .section-heading { margin-bottom: 16px; }
.library .section-heading > span { display: block; white-space: nowrap; }
.library .category-list { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.library .category-button {
  min-width: 0; padding: 9px 12px; border-radius: 12px; border: 1px solid var(--line); background: white;
}
.library .category-button[aria-pressed=true] { background: #eee6fc; border-color: #9674cf; color: #43228b; }
.library .category-button svg { color: #6842b6; }
.library-tools { display: flex; align-items: center; gap: 14px; margin: 17px 0; flex-wrap: wrap; }
.library-tools .search-box { margin: 0; flex: 1 1 240px; }
.library-tools .controls { display: flex; margin: 0; flex-wrap: wrap; }
.library .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card-footer a { color: #5026aa; }

.play { max-width: 860px; margin-inline: auto; }
.play-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 16px; }
.play-top .back { margin: 0; text-decoration: underline; text-underline-offset: 4px; }
.play-top button[aria-pressed=true] { background: #eee6fc; color: #43228b; }
.play-steps { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; list-style: none; padding: 0; margin: 0 0 14px; }
.play-steps li { border-bottom: 3px solid #e1ddeb; padding: 7px 5px; color: var(--muted); font-size: .93rem; }
.play-steps [aria-current=step] { color: #5026aa; border-color: #7b50ce; font-weight: 700; }
.play-card { background: white; border: 1px solid var(--line); border-radius: 24px; overflow: hidden; }
.play-scene, .play-body { padding: clamp(19px, 4vw, 36px); }
.play-scene { background: linear-gradient(126deg, #fff6e7, #f4ebff 70%); border-bottom: 1px solid var(--line); }
.play-scene h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); margin: 12px 0 9px; }
.play-scene p { margin: 0; max-width: 64ch; font-size: 1.08rem; }
.play-body { scroll-margin-top: 10px; }
.play-body h2 { font-size: clamp(1.35rem, 3vw, 1.85rem); margin-bottom: 8px; }
.hint { color: var(--muted); margin-bottom: 15px; }
.play .choice { border-color: #cfc4e1; min-height: 54px; }
.play .choice:hover { background: #f3edfd; border-color: #9674cf; }
.play .letter { background: #eee6fc; color: #5026aa; border: 0; }
.response-heading { display: flex; flex-wrap: wrap; gap: 10px 22px; align-items: flex-start; justify-content: space-between; margin-bottom: 17px; }
.response-heading .kicker { margin-bottom: 4px; }
.response-heading svg { width: 18px; }
.your-choice { background: #f8f5ff; border-radius: 12px; padding: 12px 15px; }
.your-choice strong { display: block; color: #593598; font-size: .87rem; }
.feedback-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 15px 0; }
.feedback-grid > div, .takeaway { padding: 15px 18px; border-radius: 14px; border: 1px solid var(--line); }
.feedback-grid > div { background: #fcfbff; }
.feedback-grid h3, .takeaway h3 { font-size: 1rem; margin: 0 0 5px; }
.feedback-grid p, .takeaway p { margin: 0; }
.takeaway { background: #fff4dd; border-color: #efdbb5; }
.compare { margin-top: 24px; }
.compare h3 { margin-bottom: 10px; }
.note-drawer .reflection { margin: 0; padding: 0 16px 16px; }

@media (max-width: 1000px) {
  .library .category-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .launch { grid-template-columns: 1fr; gap: 12px; }
  .launch h1 br { display: none; }
  .launch .actions { margin-top: 14px; gap: 6px; }
  .launch .primary { flex: initial; }
  .preview-scene { padding: 12px 3px 7px; }
  .preview-scene::before { transform: rotate(-3deg); }
  .library .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .library .category-list, .library .cards, .feedback-grid { grid-template-columns: 1fr 1fr; }
  .library .cards, .feedback-grid { grid-template-columns: 1fr; }
  .library .category-button { padding-inline: 9px; gap: 6px; }
  .library .category-button span { font-size: .85rem; }
  .play-top .secondary { padding-inline: 12px; }
  .response-heading .primary { width: 100%; }
}
