/*
 * Quizzly Bear theme: pastel paper, thick ink outlines and hard "sticker" shadows.
 * Big interactive things (buttons, answers, cards, the speech bubble) get the hard shadow;
 * reading content (result cards, lists) gets a flat outline so it stays quiet.
 * Each quiz sets --accent (its color); tints are mixed from it.
 */

@font-face { font-family: "Fredoka"; font-weight: 600; font-display: swap; src: url("assets/fonts/fredoka-600.woff2") format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 400; font-display: swap; src: url("assets/fonts/nunito-400.woff2") format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 700; font-display: swap; src: url("assets/fonts/nunito-700.woff2") format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 800; font-display: swap; src: url("assets/fonts/nunito-800.woff2") format("woff2"); }

:root {
  --display: "Fredoka", "Nunito", ui-rounded, system-ui, sans-serif;
  --body: "Nunito", ui-rounded, system-ui, -apple-system, "Segoe UI", sans-serif;

  --ink: #2b2350;      /* fixed dark text on pastel fills, in both themes */
  --bg: #f2edff;       /* lilac paper */
  --dots: #e6ddff;
  --surface: #ffffff;
  --text: #2b2350;
  --muted: #6a6190;
  --line: #2b2350;     /* outlines and hard shadows */
  --soft-line: #d9d0f5;
  --honey: #ffc94d;
  --honey-2: #ffdb85;
  --pink: #ffc8dd;
  --mint: #bff0da;
  --sky: #c4e2ff;
  --butter: #fff0a6;
  --lilac: #dccfff;
  --focus: #6b4cff;

  --accent: #8b6cff;

  --pop: 5px 5px 0 var(--line);
  --pop-sm: 3px 3px 0 var(--line);
  color-scheme: light;
}

/* Recomputed wherever a quiz sets its own --accent inline (custom properties resolve where declared). */
:root, [style*="--accent"] {
  --tint: color-mix(in srgb, var(--accent) 22%, var(--surface));
  --tint-soft: color-mix(in srgb, var(--accent) 10%, var(--surface));
  --accent-text: color-mix(in srgb, var(--accent) 55%, var(--text));
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1636;
    --dots: #241e46;
    --surface: #2a2350;
    --text: #f5f1ff;
    --muted: #b7aedb;
    --line: #0c0920;
    --soft-line: #3d3470;
    --focus: #b9a8ff;
    color-scheme: dark;
  }
  :root, [style*="--accent"] {
    --tint: color-mix(in srgb, var(--accent) 30%, var(--surface));
    --tint-soft: color-mix(in srgb, var(--accent) 14%, var(--surface));
    --accent-text: color-mix(in srgb, var(--accent) 45%, var(--text));
  }
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.55;
  background-color: var(--bg);
  background-image: radial-gradient(var(--dots) 2px, transparent 2.5px);
  background-size: 26px 26px;
  color: var(--text);
}

main { flex: 1; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: 0; }

.container { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }

.kicker, .card-cat { font-size: 0.92rem; font-weight: 800; color: var(--accent-text); }

/* ---------- The bear ---------- */
.bear { display: block; width: 100%; height: auto; overflow: visible; }
.bear-eyes { transform-box: fill-box; transform-origin: center; animation: blink 6s infinite; }
.bear-wave { transform-box: fill-box; transform-origin: 20% 100%; animation: wave 1.4s ease-in-out 0.3s 2; }
.bear-dots circle { animation: think 1.2s ease-in-out infinite; }
.bear-dots circle:nth-child(2) { animation-delay: 0.2s; }
.bear-dots circle:nth-child(3) { animation-delay: 0.4s; }

/* Bear + speech bubble */
.stage { display: grid; grid-template-columns: 128px 1fr; align-items: end; gap: 18px; }
.stage-bear { padding-bottom: 4px; }
.bubble {
  position: relative;
  padding: 22px 26px;
  border: 3px solid var(--line);
  border-radius: 28px;
  background: var(--surface);
  box-shadow: var(--pop);
}
.bubble::before {
  content: "";
  position: absolute;
  left: -14px;
  bottom: 30px;
  width: 24px;
  height: 24px;
  border: solid var(--line);
  border-width: 0 0 3px 3px;
  background: var(--surface);
  transform: rotate(45deg);
  border-radius: 0 0 0 6px;
}
.bubble > :first-child { margin-top: 0; }
.bubble > :last-child { margin-bottom: 0; }

/* ---------- Header / footer ---------- */
.site-header { position: sticky; top: 0; z-index: 10; background: var(--surface); border-bottom: 3px solid var(--line); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.logo { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-size: 1.5rem; font-weight: 600; text-decoration: none; }
.logo .bear, .logo > span[aria-hidden] { width: 46px; flex: none; font-size: 2rem; line-height: 1; }
.site-header nav { display: flex; gap: 20px; }
.site-header nav a { color: var(--muted); font-weight: 800; text-decoration: none; }
.site-header nav a:hover { color: var(--text); }

.site-footer { margin-top: 32px; padding: 28px 0; border-top: 3px solid var(--line); background: var(--surface); color: var(--muted); font-size: 0.9rem; text-align: center; }
.site-footer p { margin: 6px 0 0; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 22px; margin-bottom: 12px; }
.footer-links a { color: var(--text); font-weight: 800; text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }

/* ---------- Home ---------- */
.hero { padding: 40px 0 24px; }
.stage-hero { grid-template-columns: 200px auto; justify-content: start; align-items: center; gap: 24px; margin-bottom: 28px; }
.stage-hero .bubble { padding: 26px 34px; }
.stage-hero .bubble::before { bottom: auto; top: 50%; margin-top: -12px; }
.stage-hero h1 { margin: 0; font-size: clamp(1.7rem, 5vw, 3rem); line-height: 1.1; }

.search {
  width: 100%;
  max-width: 460px;
  padding: 15px 24px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-weight: 700;
  box-shadow: var(--pop-sm);
}
.search::placeholder { color: var(--muted); }

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 8px 0 30px; }
.chip {
  padding: 8px 18px;
  border: 2.5px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-family: var(--display);
  font-weight: 600;
  cursor: pointer;
}
.chip:hover { background: var(--tint-soft); }
.chip[aria-pressed="true"] { background: var(--honey); color: var(--ink); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; padding-bottom: 64px; }

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 22px 20px;
  border: 3px solid var(--line);
  border-radius: 26px;
  background: var(--tint);
  box-shadow: var(--pop);
  text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.card:hover { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 var(--line); }
.card:active { transform: translate(3px, 3px); box-shadow: 2px 2px 0 var(--line); }
.card-emoji {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  margin-bottom: 8px;
  border: 3px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  font-size: 2rem;
  line-height: 1;
}
.card h2 { margin: 0; font-size: 1.4rem; line-height: 1.2; }
.card p { flex: 1; margin: 0; font-size: 0.98rem; }
.card-meta { margin-top: 8px; color: var(--muted); font-size: 0.88rem; font-weight: 800; }
.badge {
  align-self: flex-start;
  margin-top: 4px;
  padding: 4px 12px;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: 0.82rem;
  font-weight: 800;
}
.empty { grid-column: 1 / -1; padding: 40px 0; color: var(--muted); text-align: center; font-weight: 700; }

.home-about { max-width: 680px; margin: 0 auto; padding: 8px 0 48px; }
.home-about h2 { margin: 0 0 12px; font-size: 1.5rem; }
.home-about p { margin: 0 0 12px; line-height: 1.7; color: var(--muted); }

/* ---------- Info pages (About, Contact, Privacy, Terms, 404) ---------- */
.page { max-width: 720px; margin: 0 auto; padding: 32px 0 48px; }
.page > .link { display: inline-block; margin-bottom: 20px; }
.page h1 { margin: 0 0 20px; font-size: clamp(2.1rem, 6vw, 3rem); line-height: 1.08; }
.page-body h2 { margin: 36px 0 10px; font-size: 1.5rem; }
.page-body h3 { margin: 24px 0 8px; font-size: 1.15rem; }
.page-body p, .page-body li { font-size: 1.06rem; line-height: 1.7; }
.page-body p { margin: 0 0 14px; }
.page-body ul { padding-left: 22px; }
.page-body li { margin-bottom: 8px; }
.page-body a { color: var(--accent-text); font-weight: 700; }
.page-body code { padding: 1px 6px; border-radius: 6px; background: var(--soft-line); font-size: 0.92em; }
.lead { font-size: 1.2rem !important; line-height: 1.55 !important; }
.contact-email { font-size: 1.3rem !important; font-weight: 800; }
.not-found { text-align: center; }
.lost-bear { width: 170px; margin: 0 auto 12px; }
.not-found .grid { margin-top: 32px; text-align: left; }

/* ---------- Shared bits ---------- */
.muted { color: var(--muted); }
.prose p { margin: 0 0 14px; }
.prose p:last-child { margin-bottom: 0; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  box-shadow: 4px 4px 0 var(--line);
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.08s ease;
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--line); }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--line); }
.btn-primary { background: var(--honey); color: var(--ink); }
.btn-lg { padding: 16px 40px; font-size: 1.3rem; }

.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.support { margin: 18px 0 0; font-size: 0.95rem; }
.support a { font-weight: 800; }

.panel {
  margin-bottom: 24px;
  padding: 24px;
  border: 3px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  box-shadow: var(--pop);
  text-align: left;
}
.panel h2 { margin: 0 0 14px; font-size: 1.3rem; }

.traits { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 0; padding: 0; list-style: none; }
.traits li { padding: 6px 14px; border: 2px solid var(--line); border-radius: 999px; background: var(--tint); font-size: 0.92rem; font-weight: 800; }

.bar-row { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; margin-bottom: 14px; font-size: 0.98rem; font-weight: 700; text-decoration: none; }
.bar-row:last-child { margin-bottom: 0; }
.bar-row.top { font-weight: 800; }
a.bar-row:hover > span:first-child { text-decoration: underline; }
.bar { grid-column: 1 / -1; display: block; height: 16px; overflow: hidden; border: 2.5px solid var(--line); border-radius: 999px; background: var(--surface); }
.bar span { display: block; height: 100%; background: var(--accent); }

.cta { margin: 8px 0 0; padding: 24px; border: 3px solid var(--line); border-radius: 26px; background: var(--tint); box-shadow: var(--pop); text-align: center; }
.cta p { margin: 0 0 16px; font-family: var(--display); font-size: 1.25rem; }

/* ---------- Quiz intro ---------- */
.intro { max-width: 680px; margin: 0 auto; padding: 28px 0 56px; text-align: center; }
.intro > .link { display: inline-block; margin-bottom: 22px; }
.stage-intro { grid-template-columns: 150px 1fr; margin-bottom: 30px; text-align: left; }
.intro .kicker { margin: 0 0 6px; }
.intro-title { margin: 0 0 8px; font-size: clamp(1.8rem, 5vw, 2.6rem); line-height: 1.1; }
.intro-meta { margin: 0; color: var(--muted); font-weight: 800; }
.intro-text { max-width: 580px; margin: 0 auto 30px; font-size: 1.1rem; text-align: left; }
.intro-saved { margin: 18px 0 0; color: var(--muted); font-weight: 700; }
.intro-results { margin-top: 44px; }
.result-links { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.result-links a { display: flex; align-items: flex-start; gap: 12px; padding: 10px; border-radius: 14px; text-decoration: none; }
.result-links a:hover { background: var(--tint-soft); }
.rl-emoji { font-size: 1.6rem; line-height: 1.2; }
.rl-tag { display: block; color: var(--muted); font-size: 0.94rem; }
.question-list summary { font-family: var(--display); font-weight: 600; font-size: 1.1rem; cursor: pointer; }
.question-list ol { margin: 16px 0 0; padding-left: 22px; }
.question-list li { margin-bottom: 10px; }
.question-list ul { margin: 6px 0 0; padding-left: 18px; color: var(--muted); font-size: 0.94rem; }

/* ---------- Quiz ---------- */
.quiz { max-width: 680px; margin: 0 auto; padding: 32px 0 56px; }

.quiz-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-family: var(--display); font-weight: 600; }
.link { padding: 0; border: 0; background: none; color: var(--muted); font-weight: 800; text-decoration: none; cursor: pointer; }
.link:hover { color: var(--text); }

.progress { height: 20px; overflow: hidden; border: 3px solid var(--line); border-radius: 999px; background: var(--surface); }
.progress-fill {
  height: 100%;
  border-radius: inherit;
  background: repeating-linear-gradient(-45deg, var(--honey) 0 10px, var(--honey-2) 10px 20px);
  transition: width 0.35s ease;
}

.stage-question { margin: 30px 0 28px; }
.stage-question .stage-bear .bear { transform-origin: 50% 100%; animation: bob 0.45s ease-out; }
.question { margin: 0; font-size: clamp(1.3rem, 4vw, 1.75rem); line-height: 1.28; }
.question:focus { outline: none; }

.answers { display: grid; gap: 14px; }
.answer {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 18px;
  border: 3px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: 4px 4px 0 var(--line);
  font-size: 1.05rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.12s;
}
.answer:hover { background: var(--tint-soft); transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--line); }
.answer.selected { background: var(--tint); transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--line); }
.answer-key {
  flex: none;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 2.5px solid var(--line);
  border-radius: 50%;
  background: var(--pink);
  color: var(--ink);
  font-family: var(--display);
  font-weight: 600;
}
.answers > :nth-child(5n + 2) .answer-key { background: var(--mint); }
.answers > :nth-child(5n + 3) .answer-key { background: var(--sky); }
.answers > :nth-child(5n + 4) .answer-key { background: var(--butter); }
.answers > :nth-child(5n + 5) .answer-key { background: var(--lilac); }
.answer.selected .answer-key { background: var(--honey); }

/* Image / emoji grid */
.image-grid { grid-template-columns: 1fr 1fr; }
.image-answer { flex-direction: column; justify-content: center; gap: 10px; padding: 20px 14px; text-align: center; font-size: 1rem; }
.image-emoji { font-size: 2.8rem; line-height: 1; }
.image-answer img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border: 2px solid var(--line); border-radius: 12px; }

/* Likert statement: pink "disagree" side, mint "agree" side */
.likert-prompt { margin: 0 0 6px; color: var(--muted); font-size: 0.95rem; font-weight: 800; }
.likert { max-width: 500px; margin: 0 auto; }
.likert-options { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.likert-opt { display: grid; place-items: center; flex: 1; height: 70px; padding: 0; border: 0; background: none; cursor: pointer; }
.likert-opt .dot {
  display: block;
  border: 3px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  box-shadow: var(--pop-sm);
  transition: transform 0.1s, background 0.12s, box-shadow 0.1s;
}
.likert-opt.l0 .dot, .likert-opt.l4 .dot { width: 60px; height: 60px; }
.likert-opt.l1 .dot, .likert-opt.l3 .dot { width: 46px; height: 46px; }
.likert-opt.l2 .dot { width: 32px; height: 32px; }
.likert-opt.l0 .dot, .likert-opt.l1 .dot { background: color-mix(in srgb, var(--pink) 35%, var(--surface)); }
.likert-opt.l3 .dot, .likert-opt.l4 .dot { background: color-mix(in srgb, var(--mint) 35%, var(--surface)); }
.likert-opt:hover .dot { transform: scale(1.08); }
.likert-opt.selected .dot { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--line); }
.likert-opt.l0.selected .dot, .likert-opt.l1.selected .dot { background: var(--pink); }
.likert-opt.l2.selected .dot { background: var(--butter); }
.likert-opt.l3.selected .dot, .likert-opt.l4.selected .dot { background: var(--mint); }
.likert-ends { display: flex; justify-content: space-between; margin-top: 10px; font-family: var(--display); font-weight: 600; }

.hint { margin-top: 22px; color: var(--muted); font-size: 0.88rem; font-weight: 700; text-align: center; }
@media (hover: none) { .hint { display: none; } }

/* Thinking beat */
.calculating { display: grid; place-items: center; align-content: center; gap: 14px; min-height: 55vh; font-family: var(--display); font-size: 1.3rem; }
.calculating p { margin: 0; }
.calc-bear { width: 190px; }

/* ---------- Result ---------- */
.result { max-width: 720px; margin: 0 auto; padding: 32px 0 24px; }
.result-hero { text-align: center; padding-bottom: 8px; }
.result-hero .kicker { margin: 0 0 22px; }
.result-hero .kicker a { text-decoration: none; }
.result-hero .kicker a:hover { text-decoration: underline; }
.result-sticker { position: relative; width: 160px; margin: 0 auto 18px; }
.result-emoji {
  display: grid;
  place-items: center;
  width: 160px;
  height: 160px;
  border: 4px solid var(--line);
  border-radius: 50%;
  background: var(--tint);
  box-shadow: 6px 6px 0 var(--line);
  font-size: 5rem;
  line-height: 1;
  animation: pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.result-bear { position: absolute; right: -104px; bottom: -14px; width: 112px; }
.result-lead { margin: 0; color: var(--muted); font-family: var(--display); font-size: 1.25rem; }
.result h1 { margin: 0 0 12px; font-size: clamp(2.3rem, 8vw, 3.6rem); line-height: 1.04; }
.result-badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 0 14px; }
.result-badges span { padding: 3px 14px; border: 2px solid var(--line); border-radius: 999px; background: var(--surface); font-size: 0.88rem; font-weight: 800; }
.result-tagline { max-width: 540px; margin: 0 auto 16px; font-size: 1.25rem; font-weight: 700; line-height: 1.4; }
.result-match { margin: 0 0 20px; color: var(--muted); font-weight: 800; }
.result-match strong { color: var(--accent-text); font-family: var(--display); font-size: 1.7rem; }
.result-rarity { margin: -10px 0 20px; color: var(--muted); font-size: 0.92rem; }

.toc {
  position: sticky;
  top: 68px;
  z-index: 5;
  display: flex;
  gap: 8px;
  margin: 32px -16px 8px;
  padding: 10px 16px;
  overflow-x: auto;
  scrollbar-width: none;
  background: var(--bg);
  border-bottom: 2px dashed var(--soft-line);
}
.toc::-webkit-scrollbar { display: none; }
.toc a { flex: none; padding: 6px 14px; border: 2px solid var(--line); border-radius: 999px; background: var(--surface); font-size: 0.88rem; font-weight: 800; text-decoration: none; white-space: nowrap; }
.toc a:hover { background: var(--honey); color: var(--ink); }

.result-body { text-align: left; }
.result-section { padding: 30px 0; border-bottom: 2px dashed var(--soft-line); scroll-margin-top: 130px; }
.result-section:last-child { border-bottom: 0; }
.result-section h2 { margin: 0 0 14px; font-size: 1.7rem; line-height: 1.15; }
.result-section h3 { margin: 22px 0 8px; font-size: 1.2rem; }
.result-section h2 + h3 { margin-top: 0; }
.result-section p { margin: 0 0 14px; font-size: 1.06rem; line-height: 1.7; }
.result-section p:last-child { margin-bottom: 0; }

.dim { margin-bottom: 24px; }
.dim:last-child { margin-bottom: 0; }
.dim-label { margin: 0 0 4px !important; color: var(--muted); font-size: 0.92rem !important; font-weight: 800; }
.dim-head { display: grid; grid-template-columns: 1fr auto 1fr; align-items: baseline; gap: 8px; margin-bottom: 6px; font-size: 0.95rem; }
.dim-head strong { font-family: var(--display); font-weight: 600; font-size: 1.08rem; }
.dim-pole { color: var(--muted); font-weight: 700; }
.dim-pole:last-child { text-align: right; }
.dim-pole.on { color: var(--text); font-weight: 800; }
.dim-track { position: relative; height: 20px; overflow: hidden; border: 3px solid var(--line); border-radius: 999px; background: var(--surface); }
.dim-fill { position: absolute; top: 0; bottom: 0; background: var(--accent); }
.dim-mid { position: absolute; top: 0; bottom: 0; left: 50%; width: 3px; margin-left: -1.5px; background: var(--line); }
.dim-band { margin: 8px 0 0 !important; color: var(--muted); font-size: 0.97rem !important; line-height: 1.5 !important; }

.trait-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.trait-card { padding: 18px 20px; border: 2.5px solid var(--line); border-radius: 20px; background: var(--surface); }
.trait-card h3 { margin: 0 0 6px !important; font-size: 1.15rem; }
.trait-card p { font-size: 1rem !important; line-height: 1.6 !important; }
.trait-card .tip { margin-top: 10px !important; padding-top: 10px; border-top: 2px dashed var(--soft-line); color: var(--muted); }
.trait-card .tip strong { color: var(--text); }

.drives { display: grid; gap: 12px; margin: 0; }
.drives div { padding: 14px 18px; border: 2.5px solid var(--line); border-radius: 20px; background: var(--tint-soft); }
.drives dt { color: var(--accent-text); font-size: 0.92rem; font-weight: 800; }
.drives dd { margin: 2px 0 0; font-size: 1.04rem; }

.roles li { background: var(--surface); font-weight: 700; }

.two-col { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.two-col .col { padding: 18px 20px; border: 2.5px solid var(--line); border-radius: 20px; }
.two-col .col h3 { margin-top: 0; }
.two-col ul { margin: 0; padding-left: 18px; }
.two-col li { margin-bottom: 8px; line-height: 1.5; }
.two-col li:last-child { margin-bottom: 0; }
.col.best { background: color-mix(in srgb, var(--mint) 40%, var(--surface)); }
.col.stress { background: color-mix(in srgb, var(--pink) 40%, var(--surface)); }

.famous, .match-list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.famous li, .match-list li { padding: 12px 16px; border: 2.5px solid var(--line); border-radius: 18px; background: var(--surface); }
.famous li > span:last-child, .match-list li > span { display: block; margin-top: 2px; color: var(--muted); font-size: 0.96rem; line-height: 1.5; }
.match-list a { text-decoration: none; }
.match-list a:hover strong { text-decoration: underline; }
.match-list + p, .match-list + h3 { margin-top: 16px; }

.runner-up { padding: 12px 16px; border: 2.5px dashed var(--line); border-radius: 18px; background: var(--tint-soft); }

.result-next { padding: 32px 0 0; text-align: center; }
.result-next h2 { margin: 0 0 18px; font-size: 1.5rem; }

.more { padding-top: 28px; }
.more h2 { margin: 0 0 18px; font-size: 1.5rem; }

@media (max-width: 560px) {
  .hero { padding-top: 24px; }
  .stage, .stage-intro { grid-template-columns: 84px 1fr; gap: 14px; }
  .stage-hero { grid-template-columns: 110px 1fr; margin-bottom: 22px; }
  .bubble { padding: 16px 18px; border-radius: 22px; }
  .bubble::before { bottom: 22px; }
  .result-section h2 { font-size: 1.45rem; }
  .likert-opt { height: 60px; }
  .likert-opt.l0 .dot, .likert-opt.l4 .dot { width: 50px; height: 50px; }
  .likert-opt.l1 .dot, .likert-opt.l3 .dot { width: 38px; height: 38px; }
  .likert-opt.l2 .dot { width: 26px; height: 26px; }
  .image-answer { padding: 16px 10px; }
  .result-sticker, .result-emoji { width: 130px; }
  .result-emoji { height: 130px; font-size: 4rem; }
  .result-bear { right: -80px; width: 88px; }
  .logo { font-size: 1.25rem; }
  .logo .bear { width: 38px; }
  .site-header nav { gap: 14px; }
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 50;
  max-width: calc(100% - 32px);
  padding: 12px 22px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: var(--honey);
  color: var(--ink);
  font-family: var(--display);
  box-shadow: var(--pop-sm);
  transform: translateX(-50%);
  animation: toast-in 0.2s ease;
}

@keyframes pop { from { transform: scale(0.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes toast-in { from { transform: translate(-50%, 12px); opacity: 0; } }
@keyframes blink { 0%, 95%, 100% { transform: scaleY(1); } 97.5% { transform: scaleY(0.1); } }
@keyframes wave { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-18deg); } 75% { transform: rotate(14deg); } }
@keyframes bob { 0% { transform: translateY(8px) scale(0.96); } 60% { transform: translateY(-4px); } 100% { transform: none; } }
@keyframes think { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
