/* ============================================================
   GEOQUEST — game screen, answers, feedback, results
   ============================================================ */

.game {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(900px 500px at 76% 0%, rgba(28, 96, 126, .16), transparent 64%),
    radial-gradient(700px 500px at 8% 100%, rgba(247, 184, 61, .05), transparent 60%);
  overflow-x: hidden;
  position: relative;
}
.game::before {
  content: "";
  position: absolute;
  inset: 64px 0 0;
  background: url("../assets/world-map.svg") center / 128% auto no-repeat;
  opacity: .035;
  pointer-events: none;
  z-index: 0;
}
.game-bar, .game-stage, .timer-bar { position: relative; z-index: 1; }
.game-bar {
  flex: 0 0 auto;
  height: 70px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(5, 13, 24, .62);
  backdrop-filter: blur(14px);
  position: relative;
  z-index: 20;
}
.game-bar-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.game-title { display: grid; gap: 2px; line-height: 1.1; min-width: 0; }
.game-title b { font-size: 13.5px; font-weight: 750; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.game-title span { font-size: 9.5px; letter-spacing: .16em; color: var(--muted); text-transform: uppercase; white-space: nowrap; }
.game-bar-center { display: flex; align-items: center; gap: 14px; flex: 1; max-width: 460px; margin: 0 auto; }
.q-progress { flex: 1; height: 5px; border-radius: 99px; background: rgba(255, 255, 255, .08); overflow: hidden; }
.q-progress > span {
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--gold-2));
  border-radius: inherit;
  transition: width .4s var(--ease);
  box-shadow: 0 0 10px rgba(247, 184, 61, .4);
}
.q-counter { font: 700 11px/1 var(--font-display); color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.q-counter b { color: var(--text); font-size: 14px; }
.mobile-time { display: none; font: 750 11px/1 var(--font-display); color: var(--gold-2); font-variant-numeric: tabular-nums; min-width: 30px; text-align: right; }
.game-bar-right { display: flex; align-items: center; gap: 10px; }
.hearts { display: flex; align-items: center; gap: 3px; margin-right: 4px; }
.hearts .ic { width: 19px; height: 19px; color: var(--red); fill: var(--red); filter: drop-shadow(0 0 5px rgba(255, 102, 125, .25)); transition: all .3s var(--ease); }
.hearts .ic.off { color: rgba(255, 255, 255, .16); fill: transparent; filter: none; transform: scale(.86); }
.hearts .ic.hit { animation: heart-hit .5s var(--ease); }
@keyframes heart-hit {
  0% { transform: scale(1); }
  30% { transform: scale(1.5) rotate(-12deg); }
  60% { transform: scale(.8) rotate(8deg); }
  100% { transform: scale(1); }
}
.timer-bar {
  flex: 0 0 auto;
  height: 3px;
  background: rgba(255, 255, 255, .05);
  position: relative;
  z-index: 19;
}
.timer-bar > span {
  display: block;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--teal), #8af3d8);
  transition: width .1s linear, background .3s;
  box-shadow: 0 0 10px rgba(59, 220, 180, .4);
}
.timer-bar.warn > span { background: linear-gradient(90deg, var(--gold), var(--gold-2)); box-shadow: 0 0 10px rgba(247, 184, 61, .5); }
.timer-bar.danger > span { background: linear-gradient(90deg, var(--red), #ff9aa8); box-shadow: 0 0 12px rgba(255, 102, 125, .55); }

.game-stage {
  flex: 1;
  width: min(1340px, 100%);
  margin: 0 auto;
  padding: 18px 28px 24px;
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) 210px;
  gap: 22px;
  align-items: center;
  position: relative;
}
.stage-left, .stage-right { align-self: center; display: grid; gap: 16px; }
.stage-center { min-width: 0; display: flex; flex-direction: column; justify-content: center; padding: 6px 0; }

/* mascot */
.mascot { position: relative; display: flex; flex-direction: column; align-items: center; gap: 10px; padding-top: 6px; }
.mascot-orb {
  width: 116px;
  height: 116px;
  position: relative;
  animation: mascot-idle 5s ease-in-out infinite;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .35));
}
.mascot-orb svg { width: 100%; height: 100%; }
.mascot-orb.happy { animation: mascot-happy .7s var(--ease); }
.mascot-orb.sad { animation: mascot-sad .7s var(--ease); }
@keyframes mascot-idle {
  0%, 100% { transform: translateY(0) rotate(-1.5deg); }
  50% { transform: translateY(-7px) rotate(1.5deg); }
}
@keyframes mascot-happy {
  0% { transform: translateY(0) scale(1); }
  30% { transform: translateY(-18px) scale(1.06) rotate(-5deg); }
  60% { transform: translateY(-4px) scale(.98) rotate(4deg); }
  100% { transform: translateY(0) scale(1); }
}
@keyframes mascot-sad {
  0%, 100% { transform: translateX(0) rotate(0); }
  25% { transform: translateX(-6px) rotate(-4deg); }
  65% { transform: translateX(6px) rotate(4deg); }
}
.mascot-bubble {
  position: relative;
  padding: 8px 11px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(10, 24, 39, .78);
  font-size: 10.5px;
  color: var(--text-2);
  line-height: 1.45;
  text-align: center;
  max-width: 168px;
  backdrop-filter: blur(8px);
}
.mascot-bubble::before {
  content: "";
  position: absolute;
  top: -5px; left: 50%;
  width: 8px; height: 8px;
  transform: translateX(-50%) rotate(45deg);
  background: rgba(10, 24, 39, .9);
  border-left: 1px solid var(--line);
  border-top: 1px solid var(--line);
}
.stage-left .run-score {
  display: grid;
  gap: 2px;
  text-align: center;
  padding: 12px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .025);
}
.stage-left .run-score span { font-size: 9px; letter-spacing: .14em; color: var(--muted); }
.stage-left .run-score b { font: 800 24px/1 var(--font-display); color: var(--gold-2); font-variant-numeric: tabular-nums; }

/* side cards */
.side-card {
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .025);
}
.side-card .sc-label { display: flex; align-items: center; gap: 6px; font-size: 9px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.side-card .sc-label .ic { width: 12px; height: 12px; }
.side-card .sc-big { font: 800 26px/1 var(--font-display); margin-top: 8px; font-variant-numeric: tabular-nums; }
.combo-card { display: flex; align-items: center; gap: 11px; }
.combo-card .flame {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 11px;
  background: rgba(255, 158, 94, .1);
  color: var(--orange);
  flex: 0 0 auto;
}
.combo-card .flame .ic { width: 20px; height: 20px; }
.combo-card b { display: block; font: 800 17px/1 var(--font-display); }
.combo-card span { font-size: 9px; color: var(--muted); letter-spacing: .08em; }
.combo-card.on { border-color: rgba(255, 158, 94, .3); background: rgba(255, 158, 94, .06); }
.combo-card.on .flame { animation: flame-pulse 1.2s ease-in-out infinite; }
@keyframes flame-pulse { 50% { transform: scale(1.08); filter: brightness(1.2); } }
.timer-dial { display: grid; place-items: center; padding: 10px; }
.timer-dial-inner {
  --p: 100;
  width: 92px; height: 92px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: conic-gradient(var(--teal) calc(var(--p) * 1%), rgba(255, 255, 255, .07) 0);
  position: relative;
  transition: background .2s;
}
.timer-dial-inner::before {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: #0a1a2c;
}
.timer-dial-inner span {
  position: relative;
  font: 800 26px/1 var(--font-display);
  font-variant-numeric: tabular-nums;
}
.timer-dial-inner small { position: relative; font-size: 8px; color: var(--muted); letter-spacing: .14em; display: block; text-align: center; margin-top: 3px; }
.timer-dial.warn .timer-dial-inner { background: conic-gradient(var(--gold) calc(var(--p) * 1%), rgba(255, 255, 255, .07) 0); }
.timer-dial.danger .timer-dial-inner { background: conic-gradient(var(--red) calc(var(--p) * 1%), rgba(255, 255, 255, .07) 0); animation: dial-pulse .8s ease-in-out infinite; }
@keyframes dial-pulse { 50% { transform: scale(1.04); } }
.hint-side {
  display: grid;
  gap: 8px;
}
.hint-mini {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 11px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .025);
  text-align: left;
  transition: all .2s;
}
.hint-mini:hover { border-color: rgba(247, 184, 61, .28); background: rgba(247, 184, 61, .05); }
.hint-mini .ic { width: 17px; height: 17px; color: var(--gold); flex: 0 0 auto; }
.hint-mini b { display: block; font-size: 10.5px; }
.hint-mini span { font-size: 9px; color: var(--muted); }
.hint-mini .cost { margin-left: auto; font-size: 10px; color: var(--gold-2); font-weight: 750; }
.hint-mini[disabled] { opacity: .4; pointer-events: none; }

/* question head */
.q-anim { animation: q-in .45s var(--ease-out) both; }
@keyframes q-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
.q-head { text-align: center; padding: 0 8px; }
.q-kicker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold-2);
  margin-bottom: 10px;
}
.q-kicker .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 7px var(--gold); }
.q-title {
  font: 800 clamp(30px, 4.1vw, 54px)/1.08 var(--font-display);
  letter-spacing: -.04em;
  word-break: break-word;
}
.q-title.small-title { font-size: clamp(25px, 3vw, 38px); }
.q-alt { margin-top: 8px; font: 600 12.5px/1.4 var(--font-display); letter-spacing: .08em; color: var(--muted); text-transform: uppercase; }
.q-ask { margin-top: 14px; color: var(--text-2); font-size: 13px; font-weight: 600; }
.q-ask .hl { color: var(--gold-2); }
.q-ask-sub { margin-top: 4px; color: var(--muted); font-size: 10.5px; }

/* country visual */
.country-visual { display: flex; gap: 14px; align-items: stretch; justify-content: center; margin: 18px auto 0; width: min(620px, 100%); }
.cv-flag {
  width: 230px;
  flex: 0 0 auto;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line-2);
  background: #0a1725;
  box-shadow: 0 14px 34px rgba(0, 0, 0, .3);
  display: grid;
  place-items: center;
  padding: 6px;
}
.cv-flag img { width: 100%; height: 100%; max-height: 130px; object-fit: contain; }
.map-card {
  position: relative;
  flex: 1;
  min-width: 0;
  aspect-ratio: 2 / 1;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #071726;
  box-shadow: inset 0 0 50px rgba(0, 0, 0, .4);
}
.map-card img { width: 100%; height: 100%; object-fit: fill; opacity: .78; }
.map-card .map-label {
  position: absolute;
  left: 8px; bottom: 7px;
  font-size: 8px;
  letter-spacing: .14em;
  color: rgba(255, 255, 255, .36);
  text-transform: uppercase;
}
.map-pin {
  position: absolute;
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--gold-2);
  border: 2px solid #3a2502;
  box-shadow: 0 0 0 3px rgba(247, 184, 61, .22), 0 0 18px rgba(247, 184, 61, .8);
  transform: translate(-50%, -50%);
  z-index: 2;
}
.map-pin::before {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  width: 34px; height: 34px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  border: 1px solid rgba(247, 184, 61, .7);
  animation: pin-pulse 2s ease-out infinite;
}
@keyframes pin-pulse {
  from { opacity: .9; transform: translate(-50%, -50%) scale(.3); }
  to { opacity: 0; transform: translate(-50%, -50%) scale(1.3); }
}
.map-pin.hidden-pin { display: none; }

/* answers */
.answers { margin-top: 24px; }
.flag-strip-wrap { position: relative; }
.flag-strip {
  display: flex;
  gap: 12px;
  padding: 8px 6px 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  justify-content: safe center;
}
.flag-strip::-webkit-scrollbar { display: none; }
.flag-card {
  position: relative;
  flex: 0 0 clamp(100px, 9.2vw, 128px);
  aspect-ratio: 1.48;
  border-radius: 11px;
  border: 2px solid rgba(255, 255, 255, .12);
  background: #0a1725;
  padding: 5px;
  overflow: hidden;
  scroll-snap-align: center;
  transition: transform .22s var(--ease), border-color .22s, box-shadow .22s, opacity .25s;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .22);
  -webkit-tap-highlight-color: transparent;
}
.flag-card img { width: 100%; height: 100%; object-fit: contain; border-radius: 6px; background: #0a1725; }
.flag-card::after {
  content: attr(data-key);
  position: absolute;
  left: 5px; top: 5px;
  width: 18px; height: 18px;
  display: grid; place-items: center;
  border-radius: 5px;
  background: rgba(3, 10, 18, .68);
  color: rgba(255, 255, 255, .66);
  font: 700 9px/1 var(--font-display);
  backdrop-filter: blur(4px);
}
.flag-card:hover:not([disabled]) { transform: translateY(-4px); border-color: rgba(255, 255, 255, .4); box-shadow: 0 16px 30px rgba(0, 0, 0, .35); }
.flag-card:active:not([disabled]) { transform: translateY(-1px) scale(.985); }
.flag-card.is-correct {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(64, 215, 143, .18), 0 12px 30px rgba(64, 215, 143, .18);
}
.flag-card.is-wrong {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(255, 102, 125, .14);
  animation: wrong-shake .45s var(--ease);
}
@keyframes wrong-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-5px) rotate(-1deg); }
  60% { transform: translateX(5px) rotate(1deg); }
  80% { transform: translateX(-2px); }
}
.flag-card.is-dim { opacity: .3; filter: saturate(.5); }
.flag-card.is-removed { opacity: .1; transform: scale(.9); pointer-events: none; filter: grayscale(1); }
.flag-card .answer-mark {
  position: absolute;
  right: 7px; top: 7px;
  width: 22px; height: 22px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: #04140c;
  background: var(--green);
  opacity: 0;
  transform: scale(.5);
  transition: all .25s var(--ease);
  z-index: 2;
}
.flag-card .answer-mark .ic { width: 13px; height: 13px; }
.flag-card.is-correct .answer-mark, .flag-card.is-wrong .answer-mark { opacity: 1; transform: scale(1); }
.flag-card.is-wrong .answer-mark { background: var(--red); color: #fff; }
.strip-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  width: 38px; height: 52px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: rgba(7, 18, 30, .8);
  border: 1px solid var(--line);
  color: var(--text-2);
  backdrop-filter: blur(8px);
  transition: all .2s;
}
.strip-arrow:hover { background: rgba(18, 40, 62, .95); color: #fff; }
.strip-arrow[disabled] { opacity: 0; pointer-events: none; }
.strip-arrow .ic { width: 18px; height: 18px; }
.strip-arrow.prev { left: -14px; }
.strip-arrow.next { right: -14px; }

.answer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.answer-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 66px;
  padding: 12px 15px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .03);
  text-align: left;
  font-size: 14.5px;
  font-weight: 650;
  transition: all .2s var(--ease);
  overflow: hidden;
}
.answer-btn:hover:not([disabled]) { border-color: var(--line-2); background: rgba(255, 255, 255, .06); transform: translateY(-2px); }
.answer-btn .key {
  width: 25px; height: 25px;
  flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: 7px;
  border: 1px solid var(--line-2);
  background: rgba(255, 255, 255, .04);
  font: 700 10.5px/1 var(--font-display);
  color: var(--muted);
}
.answer-btn .txt { flex: 1; min-width: 0; }
.answer-btn .txt small { display: block; font-size: 9.5px; color: var(--muted); font-weight: 500; margin-top: 2px; letter-spacing: .04em; }
.answer-btn .mark { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; opacity: 0; transform: scale(.5); transition: all .2s; flex: 0 0 auto; }
.answer-btn .mark .ic { width: 13px; height: 13px; }
.answer-btn.is-correct { border-color: var(--green); background: rgba(64, 215, 143, .08); }
.answer-btn.is-correct .mark { opacity: 1; transform: scale(1); background: var(--green); color: #04140c; }
.answer-btn.is-wrong { border-color: var(--red); background: rgba(255, 102, 125, .07); animation: wrong-shake .45s var(--ease); }
.answer-btn.is-wrong .mark { opacity: 1; transform: scale(1); background: var(--red); color: #fff; }
.answer-btn.is-dim { opacity: .34; }
.answer-btn.is-removed { opacity: .12; pointer-events: none; }
.answer-btn.is-correct .key { border-color: transparent; background: rgba(64, 215, 143, .2); color: var(--green); }

.country-answer { display: flex; align-items: center; gap: 11px; }
.country-answer img { width: 52px; height: 34px; object-fit: cover; border-radius: 5px; border: 1px solid var(--line); flex: 0 0 auto; }
.pop-grid .answer-btn { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: center; padding: 13px; }
.pop-grid .flag-thumb { width: 62px; height: 42px; border-radius: 7px; overflow: hidden; border: 1px solid var(--line); }
.pop-grid .flag-thumb img { width: 100%; height: 100%; object-fit: cover; }
.pop-grid .pop-name { font-size: 13.5px; }
.pop-grid .pop-value { font-size: 10px; color: var(--muted); margin-top: 3px; min-height: 14px; font-variant-numeric: tabular-nums; }
.pop-grid .pop-value b { color: var(--gold-2); }

.flag-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 11px; }
.flag-grid .flag-card { flex: none; width: 100%; aspect-ratio: 1.5; }

/* feedback */
.feedback-host { position: fixed; inset: auto 0 0 0; z-index: 90; display: flex; justify-content: center; padding: 0 20px 20px; pointer-events: none; }
.feedback-panel {
  width: min(1120px, 100%);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 16px 20px;
  border-radius: 18px;
  border: 1px solid var(--line-2);
  background: rgba(9, 23, 38, .95);
  box-shadow: 0 -10px 60px rgba(0, 0, 0, .5);
  backdrop-filter: blur(18px);
  pointer-events: auto;
  animation: fb-in .38s var(--ease-out) both;
  position: relative;
  overflow: hidden;
}
.feedback-panel::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--green);
}
.feedback-panel.bad::before { background: var(--red); }
.feedback-panel.warn::before { background: var(--gold); }
@keyframes fb-in {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: none; }
}
.fb-flag {
  width: 86px; height: 58px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--line-2);
  background: #0a1725;
  flex: 0 0 auto;
}
.fb-flag img { width: 100%; height: 100%; object-fit: contain; }
.fb-icon {
  width: 42px; height: 42px;
  flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(64, 215, 143, .14);
  color: var(--green);
}
.feedback-panel.bad .fb-icon { background: rgba(255, 102, 125, .14); color: var(--red); }
.feedback-panel.warn .fb-icon { background: rgba(247, 184, 61, .14); color: var(--gold); }
.fb-icon .ic { width: 22px; height: 22px; }
.fb-body { min-width: 0; }
.fb-title { font: 800 18px/1.2 var(--font-display); display: flex; align-items: baseline; gap: 9px; flex-wrap: wrap; }
.fb-title .pts { color: var(--green); font-size: 14px; }
.feedback-panel.bad .fb-title { color: #ffd5da; }
.fb-title .answer { color: var(--gold-2); }
.fb-fact { color: var(--text-2); font-size: 11.5px; margin-top: 4px; line-height: 1.5; }
.fb-fact b { color: #fff; }
.fb-meta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 6px; font-size: 9.5px; color: var(--muted); }
.fb-meta span { display: inline-flex; align-items: center; gap: 4px; }
.fb-meta .ic { width: 11px; height: 11px; }
.fb-actions { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.fb-actions .btn { min-width: 154px; }
.fb-actions kbd { opacity: .55; }
.fb-tip { font-size: 9.5px; color: var(--muted-2); text-align: right; margin-top: 5px; }

/* countdown */
.countdown {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: grid;
  place-items: center;
  background: rgba(3, 8, 15, .72);
  backdrop-filter: blur(10px);
  animation: fade-in .2s both;
}
.countdown-inner { text-align: center; }
.countdown-num {
  font: 900 150px/1 var(--font-display);
  letter-spacing: -.06em;
  color: var(--gold-2);
  text-shadow: 0 0 60px rgba(247, 184, 61, .35);
  animation: count-pop .5s var(--ease-out);
}
.countdown p { color: var(--muted); font-size: 11px; letter-spacing: .24em; text-transform: uppercase; margin-top: 10px; }
@keyframes count-pop {
  from { opacity: 0; transform: scale(.6); }
  to { opacity: 1; transform: scale(1); }
}
.countdown.done { animation: fade-out .3s both; }
@keyframes fade-out { to { opacity: 0; } }

/* pause */
.pause-panel { text-align: center; }
.pause-panel .pause-icon { width: 62px; height: 62px; margin: 4px auto 16px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-2); color: var(--gold); background: rgba(247, 184, 61, .07); }
.pause-panel .pause-icon .ic { width: 28px; height: 28px; }
.pause-panel h2 { font: 800 26px/1.1 var(--font-display); }
.pause-panel p { color: var(--muted); font-size: 12px; margin-top: 6px; }
.pause-stats { display: flex; justify-content: center; gap: 26px; margin: 22px 0; padding: 16px; border-radius: 12px; background: rgba(255, 255, 255, .03); border: 1px solid var(--line); }
.pause-stats div { display: grid; gap: 2px; }
.pause-stats b { font: 800 20px/1 var(--font-display); }
.pause-stats span { font-size: 9px; color: var(--muted); letter-spacing: .1em; }
.pause-actions { display: grid; gap: 9px; }

/* results */
.result-page { min-height: 100vh; min-height: 100dvh; display: flex; align-items: center; padding: 34px 0 60px; }
.result-shell { width: min(1040px, calc(100% - 40px)); margin: 0 auto; }
.result-hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 30px;
  padding: 32px 34px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line-2);
  background:
    radial-gradient(700px 300px at 20% -20%, rgba(247, 184, 61, .14), transparent 62%),
    linear-gradient(140deg, #183049, #07121f 72%);
  box-shadow: var(--shadow);
}
.result-hero.perfect { border-color: rgba(247, 184, 61, .4); }
.result-hero.zero { border-color: rgba(255, 102, 125, .26); }
.result-hero::after {
  content: "";
  position: absolute;
  right: -70px; top: -90px;
  width: 280px; height: 280px;
  border-radius: 50%;
  border: 1px solid rgba(247, 184, 61, .13);
  box-shadow: 0 0 0 40px rgba(247, 184, 61, .025), 0 0 0 80px rgba(247, 184, 61, .015);
  pointer-events: none;
}
.result-copy { min-width: 0; position: relative; z-index: 1; }
.result-copy .eyebrow { margin-bottom: 10px; }
.result-copy h1 { font: 800 clamp(30px, 4vw, 46px)/1.08 var(--font-display); letter-spacing: -.04em; }
.result-copy p { color: var(--text-2); font-size: 12.5px; margin-top: 8px; }
.result-stars { display: flex; gap: 7px; margin-top: 16px; }
.result-stars .ic { width: 28px; height: 28px; color: rgba(255, 255, 255, .12); }
.result-stars .ic.on { color: var(--gold); filter: drop-shadow(0 0 8px rgba(247, 184, 61, .45)); animation: star-pop .5s var(--ease-out) both; }
.result-stars .ic.on:nth-child(2) { animation-delay: .12s; }
.result-stars .ic.on:nth-child(3) { animation-delay: .24s; }
@keyframes star-pop {
  from { opacity: 0; transform: scale(.3) rotate(-20deg); }
  to { opacity: 1; transform: none; }
}
.result-score {
  text-align: center;
  position: relative;
  z-index: 1;
}
.score-ring { width: 148px; height: 148px; position: relative; display: grid; place-items: center; }
.score-ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.score-ring .ring-bg { stroke: rgba(255, 255, 255, .07); }
.score-ring .ring-fg { stroke: url(#ringGrad); stroke-linecap: round; transition: stroke-dashoffset 1s var(--ease-out); }
.score-ring .ring-copy { text-align: center; }
.score-ring .ring-copy b { display: block; font: 800 38px/1 var(--font-display); letter-spacing: -.04em; }
.score-ring .ring-copy span { font-size: 8.5px; letter-spacing: .16em; color: var(--muted); text-transform: uppercase; }
.result-rewards { display: grid; gap: 10px; position: relative; z-index: 1; }
.reward {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 120px;
  padding: 9px 13px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .04);
  border: 1px solid var(--line);
  font-size: 11px;
  color: var(--muted);
}
.reward b { margin-left: auto; font: 800 16px/1 var(--font-display); color: var(--gold-2); }
.reward .ic { width: 16px; height: 16px; color: var(--gold); }
.result-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 14px; }
.rs-card { padding: 15px 18px; border-radius: 13px; border: 1px solid var(--line); background: rgba(255, 255, 255, .025); display: flex; align-items: center; gap: 12px; }
.rs-card .ic { width: 18px; height: 18px; color: var(--teal); flex: 0 0 auto; }
.rs-card b { display: block; font: 800 20px/1 var(--font-display); }
.rs-card span { font-size: 9.5px; color: var(--muted); letter-spacing: .05em; }
.result-main { display: grid; grid-template-columns: 1.2fr .8fr; gap: 14px; margin-top: 14px; }
.result-panel { padding: 20px; background: rgba(10, 24, 40, .92); border: 1px solid var(--line); border-radius: var(--radius); }
.result-panel h3 { font: 750 14px/1.2 var(--font-display); display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.result-panel h3 .ic { width: 16px; height: 16px; color: var(--gold); }
.review-list { display: grid; gap: 8px; max-height: 326px; overflow: auto; padding-right: 4px; }
.review-item { display: flex; align-items: center; gap: 11px; padding: 9px; border-radius: 10px; border: 1px solid var(--line); background: rgba(255, 255, 255, .02); }
.review-item .ri-flag { width: 44px; height: 29px; border-radius: 4px; overflow: hidden; border: 1px solid var(--line); flex: 0 0 auto; }
.review-item .ri-flag img { width: 100%; height: 100%; object-fit: cover; }
.review-item .ri-body { min-width: 0; flex: 1; }
.review-item b { font-size: 12px; display: block; }
.review-item span { font-size: 9.5px; color: var(--muted); display: block; margin-top: 1px; }
.review-item .ri-timeout { font-size: 9px; color: var(--red); }
.review-empty { text-align: center; color: var(--muted); font-size: 11.5px; padding: 26px 10px; }
.review-empty .ic { width: 28px; height: 28px; margin: 0 auto 8px; color: var(--green); opacity: .7; }
.result-achievements { display: grid; gap: 8px; }
.ra-item { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 10px; background: rgba(247, 184, 61, .06); border: 1px solid rgba(247, 184, 61, .18); }
.ra-item .ic { width: 17px; height: 17px; color: var(--gold); }
.ra-item b { font-size: 11.5px; }
.ra-item span { font-size: 9px; color: var(--muted); display: block; }
.result-actions { display: flex; align-items: center; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.result-actions .btn-primary { min-width: 200px; }
.result-actions .spacer { flex: 1; }

/* leaderboard */
.leaderboard { display: grid; gap: 5px; }
.lb-row { display: grid; grid-template-columns: 26px 1fr auto auto; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 9px; font-size: 11.5px; color: var(--muted); }
.lb-row .rank { font: 800 12px/1 var(--font-display); color: var(--muted-2); }
.lb-row .lb-name { display: flex; align-items: center; gap: 7px; color: var(--text-2); }
.lb-row .lb-name .mini-av { width: 20px; height: 20px; border-radius: 50%; background: rgba(255, 255, 255, .08); display: grid; place-items: center; font-size: 8px; font-weight: 800; color: var(--text-2); }
.lb-row .lb-score { font: 700 12px/1 var(--font-display); color: var(--text-2); font-variant-numeric: tabular-nums; }
.lb-row .lb-tag { font-size: 8.5px; padding: 2px 6px; border-radius: 4px; background: rgba(255, 255, 255, .06); }
.lb-row.me { background: rgba(247, 184, 61, .1); border: 1px solid rgba(247, 184, 61, .24); color: var(--gold-2); }
.lb-row.me .lb-name, .lb-row.me .lb-score { color: var(--gold-2); }
.lb-row.top .rank { color: var(--gold); }

/* confetti */
.confetti-canvas { z-index: 100; }

/* responsive game */
@media (max-width: 1100px) {
  .game-stage { grid-template-columns: 150px minmax(0, 1fr) 180px; gap: 14px; padding: 16px 20px 22px; }
  .mascot-orb { width: 96px; height: 96px; }
  .mascot-bubble { font-size: 9.5px; }
  .timer-dial-inner { width: 80px; height: 80px; }
  .timer-dial-inner span { font-size: 22px; }
  .flag-card { flex-basis: clamp(96px, 11vw, 132px); }
}
@media (max-width: 900px) {
  .mobile-time { display: inline-block; }
  .game-stage { grid-template-columns: 1fr; padding: 14px 18px 22px; align-content: start; gap: 0; }
  .stage-left, .stage-right { display: none; }
  .stage-center { justify-content: flex-start; padding-top: 14px; }
  .game-bar { height: 62px; padding: 0 14px; gap: 10px; }
  .game-bar-center { max-width: none; margin: 0; flex: 1; }
  .game-title { display: none; }
  .game-bar-right .hearts .ic { width: 17px; height: 17px; }
  .q-title { font-size: clamp(29px, 7vw, 42px); }
  .q-head { padding-top: 6px; }
  .answers { margin-top: 18px; }
  .flag-card { flex-basis: clamp(98px, 24vw, 138px); }
  .result-hero { grid-template-columns: 1fr auto; gap: 18px; padding: 24px; }
  .result-copy { order: 2; grid-column: 1 / -1; }
  .result-score { order: 1; }
  .result-rewards { order: 3; grid-column: 1 / -1; grid-auto-flow: column; }
  .result-stats { grid-template-columns: repeat(2, 1fr); }
  .result-main { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .game-stage { padding: 10px 12px 16px; }
  .q-kicker { margin-bottom: 7px; }
  .q-alt { font-size: 11px; margin-top: 6px; }
  .q-ask { margin-top: 10px; font-size: 12px; }
  .country-visual { margin-top: 12px; gap: 8px; }
  .cv-flag { width: 124px; padding: 4px; }
  .cv-flag img { max-height: 84px; }
  .map-card { border-radius: 9px; }
  .answer-grid { gap: 8px; }
  .answer-btn { min-height: 58px; padding: 10px 11px; font-size: 13px; }
  .answer-btn .key { width: 22px; height: 22px; }
  .flag-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .flag-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 4px 0 10px; overflow: visible; }
  .flag-strip .flag-card { width: 100%; flex: none; aspect-ratio: 1.42; border-radius: 9px; }
  .strip-arrow { display: none; }
  .fb-actions kbd { display: none; }
  .fb-flag { display: none; }
  .feedback-host { padding: 0 0 calc(0px + var(--safe-b)); }
  .feedback-panel {
    grid-template-columns: auto 1fr;
    gap: 10px;
    border-radius: 18px 18px 0 0;
    border-left: 0; border-right: 0; border-bottom: 0;
    padding: 14px 16px calc(16px + var(--safe-b));
  }
  .fb-icon { width: 36px; height: 36px; }
  .feedback-panel .fb-actions { grid-column: 1 / -1; display: flex; }
  .fb-actions .btn { width: 100%; min-width: 0; }
  .fb-tip { display: none; }
  .fb-title { font-size: 16px; }
  .fb-fact { font-size: 10.5px; }
  .fb-meta { gap: 8px; }
  .score-ring { width: 112px; height: 112px; }
  .score-ring .ring-copy b { font-size: 30px; }
  .result-page { padding: 14px 0 30px; align-items: flex-start; }
  .result-hero { padding: 20px; }
  .result-actions .btn { flex: 1; min-width: 0; }
  .result-actions .spacer { display: none; }
  .result-actions .btn-primary { min-width: 100%; }
  .countdown-num { font-size: 110px; }
}
@media (max-width: 420px) {
  .game-bar-right .pill { display: none; }
  .answer-btn { font-size: 12px; }
  .detail-flag { max-height: 150px; }
  .pop-grid .country-answer img { width: 44px; height: 30px; }
}
@media (max-height: 620px) and (orientation: landscape) {
  .game-bar { height: 54px; }
  .game-stage { padding-top: 6px; padding-bottom: 10px; }
  .q-title { font-size: 30px; }
  .q-head { padding-top: 0; }
  .q-ask { margin-top: 6px; }
  .answers { margin-top: 10px; }
  .flag-card { flex-basis: 96px; }
  .feedback-panel { padding: 10px 16px; }
  .result-page { align-items: flex-start; }
}

.score-mobile { display: none; }
@media (max-width: 900px) {
  .score-mobile { display: inline-flex; }
}

.mobile-stats { display: none; }
@media (max-width: 900px) {
  .game-stage { align-content: safe center; }
  .mobile-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 16px;
  }
  .mobile-stats > div {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 6px;
    padding: 9px 11px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, .025);
  }
  .mobile-stats span { font-size: 8px; letter-spacing: .12em; color: var(--muted); }
  .mobile-stats b { font: 800 16px/1 var(--font-display); color: var(--text); font-variant-numeric: tabular-nums; }
  .mobile-stats > div:first-child b { color: var(--gold-2); }
  .mobile-stats > div:nth-child(2) b { color: var(--orange); }
}
@media (max-width: 420px) {
  .mobile-stats { gap: 6px; margin-top: 12px; }
  .mobile-stats > div { padding: 8px 9px; }
  .mobile-stats b { font-size: 14px; }
}

@media (max-width: 900px) {
  .result-hero {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    gap: 16px;
  }
  .result-score { order: 1; }
  .result-copy { order: 2; grid-column: auto; width: 100%; }
  .result-copy .eyebrow { justify-content: center; }
  .result-copy .result-stars { justify-content: center; }
  .result-copy .tag { margin-inline: auto; }
  .result-rewards {
    order: 3;
    grid-column: auto;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-flow: row;
    gap: 8px;
  }
  .reward { min-width: 0; padding: 9px 8px; gap: 6px; flex-wrap: wrap; justify-content: center; text-align: center; }
  .reward b { width: 100%; margin-left: 0; }
  .result-actions { justify-content: center; }
}

.fx-root { z-index: 50; }
.result-page { position: relative; z-index: 60; }

.flag-strip.many {
  display: grid;
  gap: 12px;
  padding: 8px 6px 16px;
  overflow: visible;
  justify-content: stretch;
}
.flag-strip.many-8 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.flag-strip.many-10 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.flag-strip.many .flag-card { width: 100%; flex: none; aspect-ratio: 1.48; }
@media (max-width: 720px) {
  .flag-strip.many-8, .flag-strip.many-10 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Short landscape phones: fit a full question without scrolling */
@media (max-width: 950px) and (max-height: 520px) and (orientation: landscape) {
  .game-bar { height: 48px; padding: 0 12px; }
  .game-bar-center { max-width: 360px; }
  .game-stage { padding: 2px 12px 8px; }
  .stage-center { padding-top: 4px; }
  .q-kicker { font-size: 8px; margin-bottom: 4px; }
  .q-title { font-size: 24px; }
  .q-title.small-title { font-size: 21px; }
  .q-alt { font-size: 9px; margin-top: 3px; }
  .q-ask { font-size: 10px; margin-top: 5px; }
  .q-ask-sub { display: none; }
  .answers { margin-top: 8px; }
  .mobile-stats { display: none; }
  .flag-strip { gap: 8px; padding: 2px 0 6px; }
  .flag-strip:not(.many) { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); overflow: visible; }
  .flag-strip:not(.many) .flag-card { width: 100%; flex: none; aspect-ratio: 1.65; }
  .flag-strip.many-8 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
  .flag-strip.many-10 { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 7px; }
  .flag-strip.many .flag-card { aspect-ratio: 1.7; }
  .country-visual { margin-top: 6px; max-width: 500px; }
  .cv-flag { width: 150px; }
  .cv-flag img { max-height: 76px; }
  .answer-btn { min-height: 46px; padding: 7px 10px; font-size: 12px; }
  .answer-grid { gap: 7px; }
  .feedback-panel { padding: 8px 14px; }
}
