@font-face {
  font-family: Nunito;
  src: url("assets/nunito.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
}
:root {
  font-family: Nunito, Arial, sans-serif;
  color: #253654;
  background: #f7f9ff;
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-height: 100svh;
  background:
    radial-gradient(ellipse at 8% 20%, #e9eaff 0, transparent 48%),
    radial-gradient(ellipse at 95% 85%, #e4f6ed 0, transparent 46%), #f7f9ff;
}
button,
a,
summary {
  -webkit-tap-highlight-color: transparent;
}
button {
  font: inherit;
  cursor: pointer;
  touch-action: manipulation;
}
button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 4px solid #5260cb;
  outline-offset: 5px;
}
[hidden] {
  display: none !important;
}
.game-shell {
  width: min(1060px, 100%);
  min-height: 100svh;
  margin: auto;
  padding: 26px 34px 16px;
  display: flex;
  flex-direction: column;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.15;
}
.brand small {
  display: block;
  font-size: 11px;
  letter-spacing: 0.13em;
  font-weight: 800;
  margin-top: 6px;
  color: #66718a;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 51px;
  height: 51px;
  border-radius: 17px;
  background: #e2e5ff;
  color: #5159a9;
  font-size: 24px;
  transform: rotate(-7deg);
}
.score-box {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 9px 21px;
  border: 2px solid #dce0ef;
  border-radius: 21px;
  background: #fff;
  min-width: 143px;
  justify-content: space-between;
}
.score-box span {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.1em;
}
.score-box strong {
  font-size: 32px;
  color: #525cb0;
  font-variant-numeric: tabular-nums;
}
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 16px;
}
.question {
  text-align: center;
}
.instruction {
  font-size: clamp(18px, 2.4vw, 24px);
  font-weight: 700;
  color: #59667d;
  margin: 12px 0;
}
h1 {
  font-family: Nunito, Arial, sans-serif;
  font-weight: 900;
  font-size: clamp(54px, 8.5vw, 94px);
  line-height: 1.2;
  letter-spacing: 0.08em;
  margin: 8px 0;
  color: #273751;
  overflow-wrap: anywhere;
}
h1:focus {
  outline: none;
}
.round {
  margin: 12px 0 24px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.15em;
  color: #69758a;
}
.choices {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.choice {
  min-width: 0;
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid #fff;
  border-radius: 30px;
  height: clamp(150px, 18vw, 205px);
  min-height: 0;
  background: #fff;
  box-shadow:
    0 8px 0 #e1e5f0,
    0 12px 30px #34436408;
  transition:
    transform 0.16s,
    box-shadow 0.16s,
    border-color 0.16s;
  user-select: none;
}
.choice:nth-child(2) {
  background: #fffdf6;
}
.choice:nth-child(3) {
  background: #f5fcfa;
}
.choice img {
  width: 75%;
  height: 75%;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
  filter: drop-shadow(0 12px 9px #3041660d);
}
.choice:not(:disabled):hover {
  transform: translateY(-5px);
  box-shadow: 0 13px 0 #dce1f0;
}
.choice:not(:disabled):active {
  transform: translateY(4px);
  box-shadow: 0 3px 0 #dce1f0;
}
.choice:disabled {
  cursor: default;
  opacity: 1;
}
.choice.correct {
  border-color: #28906c;
  background: #e8f8ef;
  box-shadow: 0 8px 0 #b9dfcf;
}
.choice.incorrect {
  border-color: #c2735d;
  background: #fff0eb;
  box-shadow: 0 8px 0 #edcdbf;
}
.result-mark {
  display: none;
  position: absolute;
  top: 12px;
  right: 12px;
  border-radius: 50%;
  width: 38px;
  height: 38px;
  place-items: center;
  font-size: 25px;
  font-weight: 900;
  background: #278463;
  color: #fff;
}
.correct .result-mark,
.incorrect .result-mark {
  display: grid;
}
.incorrect .result-mark {
  background: #b66550;
}
.answer-label {
  display: none;
  font-weight: 900;
  font-size: 20px;
  letter-spacing: 0.09em;
  position: absolute;
  bottom: 12px;
  background: #ffffffea;
  border-radius: 10px;
  padding: 3px 12px;
}
.correct .answer-label {
  display: block;
}
.answered .choice:not(.correct):not(.incorrect) {
  opacity: 0.52;
}
.response-area {
  min-height: 132px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
}
#feedback {
  font-weight: 800;
  font-size: 19px;
  text-align: center;
  margin: 0;
  color: #66718a;
  min-height: 28px;
}
#feedback.success {
  color: #207557;
}
#feedback.try-again {
  color: #92503f;
}
.next {
  border: 0;
  border-radius: 18px;
  background: #5762ba;
  color: white;
  padding: 16px 30px;
  font-size: 16px;
  letter-spacing: 0.035em;
  font-weight: 900;
  box-shadow: 0 5px 0 #3f488f;
  min-height: 56px;
}
.next:hover {
  background: #4955ac;
}
.next:active {
  transform: translateY(2px);
  box-shadow: 0 3px 0 #3f488f;
}
footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 13px;
  color: #66718a;
  padding-top: 14px;
}
.quiet,
summary {
  border: 0;
  background: transparent;
  color: #5b6781;
  font-size: 14px;
  font-weight: 800;
  padding: 12px;
  min-height: 44px;
}
.quiet:hover,
summary:hover {
  color: #303e72;
}
.rule {
  font-weight: 900;
  letter-spacing: 0.045em;
}
details {
  position: relative;
}
summary {
  cursor: pointer;
}
.adult-info {
  position: absolute;
  bottom: 100%;
  right: 0;
  width: min(350px, 85vw);
  padding: 18px 22px;
  background: white;
  box-shadow: 0 8px 40px #22325526;
  border: 1px solid #dce0ef;
  border-radius: 20px;
  font-size: 15px;
  line-height: 1.6;
  z-index: 3;
}
.adult-info a {
  color: #4955ac;
}
dialog {
  border: 0;
  padding: 28px;
  border-radius: 26px;
  max-width: min(430px, 90vw);
  color: #253654;
  box-shadow: 0 20px 80px #25365433;
}
dialog::backdrop {
  background: #25365470;
}
dialog h2 {
  font-size: 26px;
  margin-top: 0;
}
.dialog-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.dialog-actions button:not(.next) {
  border: 2px solid #dce0ef;
  background: white;
  border-radius: 18px;
  padding: 12px 18px;
  font-weight: 800;
}
@media (max-width: 620px) {
  .game-shell {
    padding: 18px 16px 12px;
  }
  .brand {
    font-size: 20px;
    gap: 8px;
  }
  .brand-mark {
    width: 43px;
    height: 43px;
    font-size: 22px;
  }
  .brand small {
    font-size: 9px;
  }
  .score-box {
    min-width: 109px;
    padding: 7px 12px;
    gap: 10px;
    border-radius: 17px;
  }
  .score-box strong {
    font-size: 27px;
  }
  .score-box span {
    font-size: 10px;
  }
  .choices {
    gap: 11px;
  }
  .choice {
    border-radius: 21px;
    min-height: 0;
    height: clamp(88px, 28vw, 160px);
  }
  .choice img {
    width: 90%;
    height: 77%;
  }
  .result-mark {
    width: 27px;
    height: 27px;
    font-size: 19px;
    top: 6px;
    right: 6px;
  }
  .answer-label {
    font-size: 12px;
    bottom: 7px;
    padding: 3px 7px;
  }
  .instruction {
    font-size: 18px;
  }
  .round {
    margin-bottom: 22px;
  }
  .response-area {
    min-height: 120px;
  }
  #feedback {
    font-size: 17px;
  }
  .next {
    font-size: 15px;
  }
  footer {
    justify-content: center;
    gap: 4px 14px;
  }
  .rule {
    font-size: 11px;
  }
  .quiet,
  summary {
    font-size: 12px;
  }
  .adult-info {
    right: -20px;
  }
  h1 {
    font-size: clamp(46px, 13vw, 76px);
  }
}
@media (max-height: 900px) and (min-height: 601px) and (min-width: 621px) {
  .game-shell {
    padding-top: 20px;
    padding-bottom: 12px;
  }
  h1 {
    font-size: 68px;
  }
  .round {
    margin: 8px 0 16px;
  }
  .instruction {
    margin: 8px 0;
  }
  .choice {
    height: clamp(130px, 19vh, 170px);
  }
  .response-area {
    min-height: 95px;
    margin-top: 10px;
  }
}
@media (max-height: 600px) and (min-width: 621px) {
  .game-shell {
    padding-top: 12px;
  }
  main {
    padding-top: 0;
  }
  .brand {
    font-size: 20px;
  }
  .brand-mark {
    width: 40px;
    height: 40px;
  }
  .instruction {
    margin: 4px 0;
    font-size: 16px;
  }
  h1 {
    font-size: 40px;
    line-height: 1.1;
    margin: 0;
  }
  .round {
    margin: 2px 0 10px;
    font-size: 10px;
    line-height: 1.4;
  }
  .score-box {
    padding: 6px 12px;
  }
  .score-box strong {
    font-size: 24px;
    line-height: 1;
  }
  .choices {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    max-width: 1060px;
    width: 100%;
    margin: auto;
    gap: 10px;
  }
  .choice {
    min-height: 0;
    height: clamp(75px, 25vh, 125px);
  }
  .response-area {
    min-height: 70px;
    margin-top: 8px;
    gap: 4px;
  }
  .next {
    padding: 9px 24px;
    min-height: 42px;
    font-size: 14px;
  }
  footer {
    padding-top: 0;
  }
  .quiet,
  summary {
    min-height: 36px;
    padding: 8px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
