:root {
  color-scheme: light;
  --ink: #2d251f;
  --muted: #76695c;
  --line: #ead8b9;
  --surface: rgb(255 253 244 / 96%);
  --page: #fff6d9;
  --accent: #7d3fc6;
  --accent-dark: #62309e;
  --accent-soft: #f2e7ff;
  --sunny: #ffd53f;
  --success: #27765a;
  --success-soft: #e9f6ef;
  --danger: #a54b4b;
  --danger-soft: #fff0ed;
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--page);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
a {
  font: inherit;
}

button {
  cursor: pointer;
}

.page-glow {
  position: fixed;
  z-index: -1;
  border-radius: 50%;
  filter: blur(2px);
  opacity: 0.55;
  pointer-events: none;
}

.page-glow-one {
  top: -180px;
  right: -120px;
  width: 480px;
  height: 480px;
  background: #e5cfff;
}

.page-glow-two {
  bottom: -220px;
  left: -160px;
  width: 520px;
  height: 520px;
  background: #ffc96b;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1120px, calc(100% - 40px));
  height: 76px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: -0.04em;
  text-decoration: none;
}

.brand strong {
  font-weight: 900;
}

.brand-mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  transform: rotate(-7deg);
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: var(--sunny);
  font-size: 1.08rem;
}

.text-button {
  padding: 9px 14px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 750;
}

.text-button:hover {
  border-color: var(--line);
  background: rgb(255 255 255 / 45%);
  color: var(--ink);
}

.quiz-shell {
  display: flex;
  min-height: 0;
  flex-direction: column;
  align-items: center;
  padding: 34px 20px 72px;
}

.page-intro {
  width: min(940px, 100%);
  margin: 0 auto 34px;
  text-align: center;
}

.page-intro h1 {
  max-width: 780px;
  margin-inline: auto;
  font-size: clamp(2.15rem, 6vw, 3.6rem);
}

.page-intro > p:last-child {
  max-width: 640px;
  margin: 14px auto 0;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.65;
}

.intro-kicker {
  margin: 0 0 10px;
  color: var(--accent-dark);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.quiz-stage {
  position: relative;
  display: grid;
  width: min(940px, 100%);
  grid-template-columns: minmax(200px, 290px) minmax(0, 700px);
  align-items: end;
}

.mascot-wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 290px;
  aspect-ratio: 2 / 3;
  align-self: end;
  margin-right: -40px;
  pointer-events: none;
}

.mascot-wrap picture {
  display: block;
  width: 100%;
  height: 100%;
}

.mascot {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 470px;
  object-fit: contain;
  object-position: bottom center;
  filter: drop-shadow(0 18px 18px rgb(71 44 24 / 16%));
}

.banana-doodle {
  position: absolute;
  z-index: 3;
  font-weight: 900;
}

.banana-one {
  top: 8%;
  left: 3%;
  transform: rotate(-22deg);
  font-size: 2.1rem;
}

.banana-two {
  top: 4%;
  right: 6%;
  transform: rotate(10deg);
  color: var(--accent);
  font-size: 2.2rem;
}

.quiz-card {
  position: relative;
  z-index: 1;
  width: min(700px, 100%);
  padding: clamp(30px, 6vw, 58px);
  border: 2px solid rgb(75 54 36 / 10%);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 24px 70px rgb(92 73 46 / 14%);
}

.quiz-intro {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 38px;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 700;
}

.quiz-intro p {
  margin: 0;
}

.spark {
  color: #ef9b15;
  font-size: 1rem;
}

.category {
  display: inline-block;
  margin: 0 0 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #ffe7a0;
  color: #68430a;
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2 {
  max-width: 610px;
  margin: 0;
  font-size: clamp(1.9rem, 5vw, 2.65rem);
  line-height: 1.14;
  letter-spacing: -0.05em;
}

.instruction {
  margin: 16px 0 26px;
  color: var(--muted);
  font-size: 0.95rem;
}

.answers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.answer {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 68px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgb(255 255 255 / 70%);
  color: var(--ink);
  font-weight: 650;
  text-align: left;
  transition: border-color 140ms ease, background 140ms ease, transform 140ms ease, box-shadow 140ms ease;
}

.answer:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: #c294dc;
  box-shadow: 0 8px 18px rgb(76 59 125 / 8%);
}

.answer:focus-visible,
.primary-button:focus-visible,
.secondary-button:focus-visible,
.text-button:focus-visible,
.feedback:focus-visible {
  outline: 3px solid rgb(115 87 232 / 24%);
  outline-offset: 3px;
}

.answer.selected {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.answer.correct {
  border-color: var(--success);
  background: var(--success-soft);
}

.answer.incorrect {
  border-color: var(--danger);
  background: var(--danger-soft);
}

.answer-key {
  display: grid;
  flex: 0 0 32px;
  height: 32px;
  margin-right: 12px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgb(255 255 255 / 70%);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.feedback {
  display: flex;
  gap: 14px;
  margin-top: 20px;
  padding: 18px;
  border: 1px solid #cce5d8;
  border-radius: 15px;
  background: var(--success-soft);
  color: var(--success);
}

.feedback.is-wrong {
  border-color: #f0d1cc;
  background: var(--danger-soft);
  color: var(--danger);
}

.feedback-icon {
  display: grid;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: rgb(255 255 255 / 72%);
  font-size: 1rem;
  font-weight: 900;
}

.feedback strong {
  display: block;
  margin-top: 1px;
  font-size: 1rem;
}

.feedback p {
  margin: 5px 0 0;
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.55;
}

.quiz-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 30px;
}

.primary-button,
.secondary-button {
  min-height: 50px;
  padding: 0 22px;
  border-radius: 12px;
  font-weight: 800;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 2px solid var(--ink);
  background: var(--sunny);
  color: var(--ink);
}

.primary-button:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: var(--ink);
  background: #ffc823;
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.35;
}

.secondary-button {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
}

.secondary-button:hover:not(:disabled) {
  background: rgb(255 255 255 / 65%);
  color: var(--ink);
}

.secondary-button:disabled {
  visibility: hidden;
}

.keyboard-hint {
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
}

.empty-state {
  padding: 28px 0;
  text-align: center;
}

.empty-state > span {
  display: block;
  margin-bottom: 18px;
  font-size: 2.4rem;
}

.empty-state p {
  color: var(--muted);
}

.about-section {
  display: grid;
  width: min(940px, calc(100% - 40px));
  margin: 0 auto 32px;
  padding: clamp(30px, 5vw, 52px);
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(28px, 6vw, 70px);
  border: 2px solid rgb(75 54 36 / 10%);
  border-radius: var(--radius);
  background: rgb(255 253 244 / 70%);
  content-visibility: auto;
  contain-intrinsic-size: auto 360px;
}

.about-section h2 {
  font-size: clamp(1.65rem, 4vw, 2.35rem);
}

.about-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.about-copy p + p {
  margin-top: 16px;
}

.site-footer {
  width: min(940px, calc(100% - 40px));
  margin: 0 auto;
  padding: 18px 0 34px;
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
}

[hidden] {
  display: none !important;
}

@media (max-width: 620px) {
  .site-header {
    width: calc(100% - 32px);
    height: 66px;
  }

  .quiz-shell {
    min-height: 0;
    padding: 14px 12px 38px;
  }

  .page-intro {
    margin-bottom: 28px;
  }

  .quiz-card {
    padding: 28px 20px;
    border-radius: 19px;
  }

  .quiz-stage {
    display: block;
  }

  .mascot-wrap {
    width: 170px;
    height: 135px;
    aspect-ratio: auto;
    margin: 0 auto -28px;
    overflow: hidden;
  }

  .mascot {
    width: 170px;
    height: auto;
    max-height: none;
    filter: none;
  }

  .banana-doodle {
    display: none;
  }

  .quiz-intro {
    margin-bottom: 30px;
  }

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

  .answer {
    min-height: 58px;
  }

  .keyboard-hint {
    display: none;
  }

  .about-section {
    grid-template-columns: 1fr;
    gap: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
