:root {
  --night: #17264f;
  --night-light: #263c74;
  --cream: #fff8e8;
  --yellow: #ffd75e;
  --mint: #86ddd0;
  --pink: #ff9aa8;
  --blue: #9bcdf5;
  --ink: #20304f;
}

* { box-sizing: border-box; }
body {
  min-height: 100vh;
  margin: 0;
  color: var(--cream);
  background:
    radial-gradient(circle at 12% 18%, rgba(255,255,255,.75) 0 2px, transparent 3px),
    radial-gradient(circle at 82% 12%, rgba(255,215,94,.9) 0 3px, transparent 4px),
    radial-gradient(circle at 72% 68%, rgba(255,255,255,.55) 0 2px, transparent 3px),
    linear-gradient(155deg, var(--night) 0%, #213568 62%, #344b7f 100%);
  background-size: 145px 145px, 190px 190px, 120px 120px, auto;
  font-family: Arial, "Noto Sans Hebrew", sans-serif;
}
button, a { font: inherit; }
.game-header { min-height: 86px; padding: 9px clamp(16px,5vw,62px); display: flex; align-items: center; justify-content: space-between; }
.brand img { display: block; border-radius: 18px; box-shadow: 0 8px 24px rgba(0,0,0,.22); }
.back-link { color: var(--cream); font-weight: 800; text-decoration: none; }
.back-link:hover { color: var(--yellow); }
main { padding: 8px 16px 52px; }
.game-shell { position: relative; width: min(940px,100%); margin: auto; text-align: center; }
.stars { position: absolute; inset: 0 0 auto; display: flex; justify-content: space-between; color: var(--yellow); font-size: clamp(1.2rem,3vw,2.1rem); pointer-events: none; }
.stars span:nth-child(2), .stars span:nth-child(4) { color: white; transform: translateY(28px); }
.eyebrow { margin: 0 0 7px; color: var(--mint); font-weight: 900; letter-spacing: .14em; direction: ltr; }
h1 { position: relative; margin: 0; font-size: clamp(2rem,6vw,4.2rem); line-height: 1.04; }
h1 span { color: var(--yellow); }
.intro { margin: 13px 0 21px; color: #e6ecff; font-size: 1.08rem; }
.progress-wrap { width: min(700px,100%); margin: 0 auto 14px; display: flex; align-items: center; gap: 12px; direction: ltr; }
.progress-track { flex: 1; height: 13px; overflow: hidden; border-radius: 999px; background: rgba(255,255,255,.2); }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg,var(--mint),var(--yellow),var(--pink)); transition: width .35s ease; }
.progress-wrap strong { min-width: 44px; color: white; }
.round-card, .finish-card {
  position: relative;
  overflow: hidden;
  padding: clamp(21px,4vw,38px);
  border: 3px solid var(--cream);
  border-radius: 34px;
  color: var(--ink);
  background: rgba(255,248,232,.98);
  box-shadow: 11px 13px 0 rgba(5,13,38,.3);
}
.round-card::before { content: ""; position: absolute; top: -55px; right: -35px; width: 130px; height: 130px; border-radius: 50%; background: rgba(255,215,94,.3); }
.prompt { margin: 0; direction: ltr; color: #69738a; font-weight: 900; }
.word-row { position: relative; display: flex; align-items: center; justify-content: center; gap: 12px; direction: ltr; }
#targetWord { margin: 2px 0 5px; color: var(--night-light); font-size: clamp(2.5rem,8vw,5rem); line-height: 1; }
.sound-button { width: 48px; height: 48px; border: 0; border-radius: 50%; background: var(--yellow); cursor: pointer; box-shadow: 0 5px 0 #cfaa25; }
.sound-button:active { transform: translateY(3px); box-shadow: 0 2px 0 #cfaa25; }
.instruction { margin: 6px 0 18px; color: #69738a; }
.choices { position: relative; display: grid; grid-template-columns: repeat(3,1fr); gap: 13px; direction: ltr; }
.choice {
  min-height: 142px;
  display: grid;
  place-items: center;
  border: 3px solid var(--ink);
  border-radius: 23px;
  background: var(--card-color,var(--blue));
  cursor: pointer;
  box-shadow: 0 7px 0 rgba(32,48,79,.25);
  transition: transform .16s ease, box-shadow .16s ease;
}
.choice:hover, .choice:focus-visible { transform: translateY(-4px) rotate(-1deg); box-shadow: 0 11px 0 rgba(32,48,79,.18); outline: 4px solid rgba(134,221,208,.4); }
.art-emoji { font-size: clamp(3.1rem,8vw,4.9rem); line-height: 1; filter: drop-shadow(0 6px 3px rgba(32,48,79,.18)); }
.good-night-art { display: grid; place-items: center; gap: 2px; font-size: 2.75rem; line-height: 1; }
.good-night-art small { padding: 3px 8px; border-radius: 999px; background: var(--night); color: white; font-size: .65rem; font-weight: 900; letter-spacing: .04em; }
.comb-art { position: relative; width: 92px; height: 56px; display: block; border-top: 13px solid #e96377; border-radius: 14px 14px 3px 3px; filter: drop-shadow(0 5px 3px rgba(32,48,79,.16)); }
.comb-art i { position: absolute; top: 2px; width: 6px; height: 37px; border: 2px solid var(--ink); border-top: 0; border-radius: 0 0 4px 4px; background: #ff8293; }
.comb-art i:nth-child(1){left:4px}.comb-art i:nth-child(2){left:17px}.comb-art i:nth-child(3){left:30px}.comb-art i:nth-child(4){left:43px}.comb-art i:nth-child(5){left:56px}.comb-art i:nth-child(6){left:69px}.comb-art i:nth-child(7){left:82px}
.brush-art { position: relative; width: 95px; height: 44px; display: block; border: 3px solid var(--ink); border-radius: 50% 18px 18px 50%; background: #f18445; transform: rotate(-8deg); filter: drop-shadow(0 5px 3px rgba(32,48,79,.16)); }
.brush-art::before { content: ""; position: absolute; top: 10px; right: -42px; width: 48px; height: 18px; border: 3px solid var(--ink); border-left: 0; border-radius: 0 12px 12px 0; background: #f18445; }
.brush-art i { position: absolute; width: 5px; height: 16px; border-radius: 4px; background: var(--cream); border: 1px solid var(--ink); }
.brush-art i:nth-child(1){left:15px;top:5px}.brush-art i:nth-child(2){left:28px;top:18px}.brush-art i:nth-child(3){left:43px;top:5px}.brush-art i:nth-child(4){left:57px;top:18px}.brush-art i:nth-child(5){left:70px;top:5px}
.choice.correct { background: #a7e6b9; animation: pop .42s ease; }
.choice.wrong { background: #ffaaa7; animation: shake .35s ease; }
.feedback { min-height: 28px; margin: 18px 0 0; color: #176f72; font-size: 1.17rem; font-weight: 900; }
.finish-card { padding-block: clamp(38px,8vw,72px); background: linear-gradient(145deg,#fff8e8 55%,#dff7f2); }
.finish-moon { font-size: clamp(4rem,10vw,7rem); }
.finish-card h2 { margin: 4px 0; color: var(--night-light); font-size: clamp(2.5rem,7vw,4.8rem); }
.finish-card p { font-size: 1.15rem; }
.word-cloud { margin: 22px auto; display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; direction: ltr; }
.word-cloud span { padding: 8px 14px; border-radius: 999px; background: var(--yellow); font-weight: 900; }
.word-cloud span:nth-child(2n) { background: var(--mint); }
.word-cloud span:nth-child(3n) { background: var(--pink); }
.play-again { padding: 14px 26px; border: 0; border-radius: 999px; background: var(--night-light); color: white; font-weight: 900; cursor: pointer; box-shadow: 0 7px 0 var(--night); }
.play-again:active { transform: translateY(4px); box-shadow: 0 3px 0 var(--night); }
footer { padding: 0 18px 28px; text-align: center; color: #dfe7ff; font-size: .9rem; }
@keyframes pop { 50% { transform: scale(1.08) rotate(2deg); } }
@keyframes shake { 25% { transform: translateX(-7px); } 50% { transform: translateX(7px); } 75% { transform: translateX(-4px); } }
@media (max-width: 720px) { .choices { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 520px) {
  .game-header { min-height: 74px; padding: 7px 13px; }
  .brand img { width: 58px; height: 58px; }
  .back-link { font-size: .92rem; }
  main { padding: 4px 11px 38px; }
  .round-card, .finish-card { border-radius: 25px; box-shadow: 6px 8px 0 rgba(5,13,38,.3); }
  .choice { min-height: 112px; border-radius: 18px; }
  .comb-art { transform: scale(.82); }
  .brush-art { transform: scale(.8) rotate(-8deg); }
}
@media (prefers-reduced-motion: reduce) { *,*::before,*::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
