:root {
  --blue: #123a5a;
  --blue-deep: #0a2236;
  --silver: #d4dbe2;
  --silver-hover: #c5ced7;
  --silver-active: #bdc7d1;
  --plate-ink: #16212c;
  --cream: #e8dcc6;
  --verm: #db432e;
  --brass: #b88a3d;
  --brass-deep: #8e6a2a;
  --frost: #8fa0ad;
  --pad: 16px;
  --answer-h: clamp(48px, 7.3vh, 60px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { height: 100%; background: var(--blue-deep); }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background-color: var(--blue);
  color: var(--cream);
  font-family: "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background: url("assets/blue_room.jpg") center / cover no-repeat;
  opacity: 0.82;
  filter: saturate(0.92) brightness(0.9);
  pointer-events: none;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  background: radial-gradient(125% 95% at 50% 18%, rgba(6, 20, 33, 0) 32%, rgba(6, 20, 33, 0.34) 76%, rgba(3, 12, 21, 0.68) 100%);
  pointer-events: none;
}
.screen { position: relative; z-index: 1; }
[hidden] { display: none !important; }
button { font-family: inherit; }

.display {
  font-family: "Oswald", "Arial Narrow", sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 0.82;
  letter-spacing: -0.015em;
  color: var(--cream);
}
.display span { display: block; }

.eyebrow {
  margin: 0;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.55);
}
.label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.5);
}

.screen-start {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.start-wrap {
  flex: 1;
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: clamp(28px, 7vh, 72px) clamp(20px, 5vw, 56px) 20px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(28px, 5vw, 76px);
  align-items: center;
}
.start-copy { max-width: 560px; }
.start-copy .eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: clamp(16px, 2.4vh, 24px);
}
.start-copy .eyebrow::before {
  content: "";
  width: 20px;
  height: 1px;
  background: var(--brass);
  opacity: 0.9;
}
.display {
  font-size: clamp(54px, 15vw, 76px);
  margin: 0 0 clamp(18px, 2.6vh, 26px);
}
.lede {
  margin: 0 0 clamp(18px, 2.8vh, 28px);
  max-width: 44ch;
  font-size: clamp(15px, 1.55vw, 17.5px);
  line-height: 1.55;
  color: rgba(232, 220, 198, 0.72);
}


.veil-sample-wrap { display: none; }
.veil-sample { width: min(46vw, 178px); aspect-ratio: 4 / 5; border-radius: 8px; }
.veil-sample-cap {
  margin: 8px 0 0;
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.46);
}
@media (max-width: 820px) and (min-height: 780px) {
  .veil-sample-wrap { display: block; margin: 0 0 clamp(16px, 2.6vh, 24px); }
}

.facts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 10px;
  max-width: 440px;
  margin: 0 0 clamp(18px, 2.8vh, 28px);
  padding: 14px 0 0;
  border-top: 1px solid rgba(184, 138, 61, 0.45);
  list-style: none;
  font-size: 9.8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.62);
}
.facts li { display: flex; align-items: center; gap: 10px; }
.facts li + li::before {
  content: "";
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--brass);
  opacity: 0.7;
}

.start-actions { max-width: 332px; }
.start-btn {
  appearance: none;
  width: 100%;
  min-height: 58px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background-color: var(--silver);
  background-image: url("assets/paper_tooth.png");
  background-size: 240px auto;
  background-blend-mode: multiply;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.62), inset 0 -1px 0 rgba(18, 30, 42, 0.12);
  color: var(--plate-ink);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background-color 0.16s ease, transform 0.09s ease;
}
.start-btn:hover { background-color: var(--silver-hover); }
.start-btn:active { background-color: var(--silver-active); transform: translateY(1px); }
.start-btn .enter {
  flex: none;
  padding: 4px 7px;
  border: 1px solid rgba(18, 30, 42, 0.24);
  border-radius: 4px;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: rgba(18, 30, 42, 0.58);
}
.hint {
  margin: 9px 0 0;
  font-size: 10.5px;
  letter-spacing: 0.05em;
  color: rgba(232, 220, 198, 0.4);
}
.best {
  margin: 14px 0 0;
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.66);
}
.start-visual { display: flex; justify-content: center; }
.hero { width: min(34vw, 392px); aspect-ratio: 4 / 5; border-radius: 8px; }
.start-foot {
  flex: none;
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 56px) 16px;
}
.credits-link {
  appearance: none;
  border: 0;
  background: none;
  padding: 6px 0;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: rgba(232, 220, 198, 0.4);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.credits-link:hover { color: rgba(232, 220, 198, 0.72); }

.portrait {
  position: relative;
  margin: 0;
  overflow: hidden;
  isolation: isolate;
  background: #1a120c;
  --blur: 0px;
  --sat: 1;
  --bri: 1;
  --frost: 0.5;
  --tint: 0.35;
  --zoom: 1;
}
.portrait .photo,
.portrait .silhouette {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 5%;
  display: block;
}
.portrait .photo {
  opacity: 1;
  transform: scale(var(--zoom));
  filter: blur(var(--blur)) saturate(var(--sat)) brightness(var(--bri));
  transition: opacity 1s ease, filter 1.15s cubic-bezier(0.25, 0.6, 0.2, 1), transform 1.15s cubic-bezier(0.25, 0.6, 0.2, 1);
}
.portrait .silhouette {
  opacity: 0;
  transform: scale(1.004);
  transition: opacity 1s ease;
}
.portrait[data-step="0"] .photo { opacity: 0; }
.portrait[data-step="0"] .silhouette { opacity: 1; }
.portrait[data-step="1"] {
  --blur: 5px;
  --sat: 0.92;
  --bri: 0.99;
  --frost: 0.18;
  --tint: 0.16;
  --zoom: 1.03;
}
.portrait[data-step="2"] {
  --blur: 2px;
  --sat: 1;
  --bri: 1;
  --frost: 0.05;
  --tint: 0.06;
  --zoom: 1.015;
}
.portrait[data-step="3"] {
  --blur: 0px;
  --sat: 1.02;
  --bri: 1;
  --frost: 0;
  --tint: 0;
  --zoom: 1;
}
.portrait[data-step="4"] {
  --blur: 0px;
  --sat: 1.03;
  --bri: 1;
  --frost: 0;
  --tint: 0;
  --zoom: 1;
}
.portrait[data-step="4"] .photo { transition-duration: 0.4s, 0.45s, 0.45s; }
.portrait[data-step="4"] .frost,
.portrait[data-step="4"] .glass-tint,
.portrait[data-step="4"] .silhouette { transition-duration: 0.4s; }
.portrait.swap { animation: portraitIn 0.3s ease both; }
@keyframes portraitIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.portrait.no-fade .photo,
.portrait.no-fade .silhouette { transition: none !important; }
.portrait { transition: opacity 0.22s ease; }
.frost {
  position: absolute;
  inset: 0;
  background: url("assets/veil.jpg") center / cover no-repeat;
  mix-blend-mode: screen;
  opacity: var(--frost);
  transition: opacity 1.15s cubic-bezier(0.25, 0.6, 0.2, 1);
  pointer-events: none;
}
.glass-tint {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 38%, rgba(143, 160, 173, 0) 28%, rgba(113, 136, 154, 0.2) 64%, rgba(58, 82, 101, 0.6) 100%),
    linear-gradient(180deg, rgba(143, 160, 173, 0.1), rgba(143, 160, 173, 0.02));
  opacity: var(--tint);
  transition: opacity 1.15s ease;
  pointer-events: none;
}
.frame-line {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(232, 220, 198, 0.2);
  pointer-events: none;
  z-index: 3;
}

.screen-game { height: 100vh; height: 100dvh; overflow: hidden; }
.game-shell {
  height: 100%;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: max(10px, env(safe-area-inset-top)) var(--pad) max(12px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
}
.hud { flex: none; }
.ticks {
  display: flex;
  gap: 6px;
  height: 11px;
  align-items: flex-start;
}
.tick {
  position: relative;
  flex: 1;
  height: 2px;
  border-radius: 1px;
  background: rgba(232, 220, 198, 0.34);
  transition: background 0.3s ease;
}
.tick.passed { background: var(--verm); }
.tick.skipped { background: rgba(184, 138, 61, 0.72); }
.tick.lost { background: rgba(232, 220, 198, 0.2); }
.tick.now { background: rgba(232, 220, 198, 0.95); }
.tick.now::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 4px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--brass);
  transform: translateX(-50%);
}
.hud-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}
.score { display: flex; align-items: baseline; gap: 9px; }
.score-num {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.01em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.lives-alias, .feedback-alias { display: block; }
.lives { display: flex; gap: 9px; padding: 4px 0; }
.life {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--cream);
  border: 1px solid rgba(184, 138, 61, 0.7);
  transition: background 0.09s ease, border-color 0.09s ease, transform 0.12s ease;
}
.life.spent { background: transparent; border-color: rgba(232, 220, 198, 0.32); }
.life.pulse { animation: lifePulse 0.34s ease; }
@keyframes lifePulse {
  0% { transform: scale(1); }
  35% { transform: scale(0.55); }
  100% { transform: scale(1); }
}

.play {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(7px, 1.3vh, 12px);
  margin-top: clamp(8px, 1.7vh, 15px);
}
.portrait-col {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(8px, 1.3vh, 12px);
}
.portrait-col .portrait {
  flex: 1;
  min-height: 0;
  border-radius: 8px;
}
.response {
  flex: none;
  min-height: 44px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}
.resp-main {
  margin: 0;
  font-size: 16.5px;
  font-weight: 500;
  line-height: 1.25;
  color: rgba(232, 220, 198, 0.88);
}
.resp-sub {
  margin: 0;
  font-size: 13px;
  line-height: 1.35;
  letter-spacing: 0.015em;
  color: rgba(232, 220, 198, 0.52);
}
.resp-sub b {
  font-size: 16px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
  color: rgba(232, 220, 198, 0.97);
}
.response[data-tone="good"] .resp-sub b { color: var(--verm); }
.response[data-tone="bad"] .resp-main { color: rgba(232, 220, 198, 0.72); }

.answers-col {
  flex: none;
  display: flex;
  flex-direction: column;
  gap: clamp(6px, 1.05vh, 9px);
}
.answers {
  flex: none;
  display: flex;
  flex-direction: column;
  gap: clamp(6px, 1.05vh, 9px);
}
.round-actions {
  display: flex;
  gap: 8px;
}
.round-actions .skip-btn {
  flex: 1 1 0;
  width: auto;
  min-width: 0;
  margin: 0;
  padding: 0 8px;
  gap: 8px;
}
.answer {
  position: relative;
  width: 100%;
  height: var(--answer-h);
  padding: 0 16px 0 0;
  border: 0;
  border-radius: 8px;
  display: flex;
  align-items: stretch;
  gap: 14px;
  overflow: hidden;
  background-color: var(--silver);
  background-image: url("assets/paper_tooth.png");
  background-size: 240px auto;
  background-blend-mode: multiply;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6), inset 0 -1px 0 rgba(18, 30, 42, 0.1);
  color: var(--plate-ink);
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
  transition: background-color 0.16s ease, transform 0.09s ease, color 0.2s ease, opacity 0.25s ease;
}
.answer .letter {
  flex: none;
  width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid rgba(22, 33, 44, 0.18);
  font-family: "Oswald", "Arial Narrow", sans-serif;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--brass-deep);
}
.answer .name {
  flex: 1;
  display: flex;
  align-items: center;
  padding-left: 2px;
  padding-right: 24px;
  font-size: clamp(17px, 4.8vw, 20px);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.005em;
}
.answer .mark {
  position: absolute;
  right: 14px;
  top: 50%;
  width: 20px;
  height: 20px;
  margin-top: -10px;
  opacity: 0;
  transform: scale(0.55);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
}
.answer .mark::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 1px;
  width: 5px;
  height: 11px;
  border-right: 2px solid var(--cream);
  border-bottom: 2px solid var(--cream);
  transform: rotate(42deg);
}
.answer.is-correct .mark {
  opacity: 1;
  transform: scale(1);
}
@media (hover: hover) {
  .answer:hover { background-color: var(--silver-hover); }
}
.answer:active { background-color: var(--silver-active); transform: translateY(1px) scale(0.998); }
.answer:disabled { cursor: default; }
.answer.is-wrong {
  background-color: transparent;
  background-image: none;
  box-shadow: inset 0 0 0 1px rgba(216, 229, 240, 0.3);
  color: rgba(216, 229, 240, 0.46);
}
.answer.is-wrong .letter {
  color: rgba(216, 229, 240, 0.36);
  border-color: rgba(216, 229, 240, 0.16);
}
.answer.is-wrong .name { position: relative; }
.answer.is-wrong .name::after {
  content: "";
  position: absolute;
  left: -2px;
  right: 2px;
  top: 52%;
  height: 1px;
  background: var(--verm);
  transform-origin: left center;
  animation: strike 0.42s cubic-bezier(0.2, 0.7, 0.2, 1) 0.04s both;
}
@keyframes strike { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.answer.is-correct {
  background-color: var(--verm);
  background-image: none;
  box-shadow: none;
  color: var(--cream);
}
.answer.is-correct .letter {
  color: rgba(232, 220, 198, 0.85);
  border-color: rgba(232, 220, 198, 0.34);
}
.answer.is-answer { box-shadow: inset 0 0 0 2px var(--verm); }
.answer.is-answer .letter { color: var(--verm); }
.answer.is-answer .mark { opacity: 1; transform: scale(1); }
.answer.is-answer .mark::before { border-color: var(--verm); }
.answer.nudging { animation: nudge 0.44s ease; }
@keyframes nudge {
  0% { transform: translateX(0); }
  30% { transform: translateX(3px); }
  65% { transform: translateX(-1px); }
  100% { transform: translateX(0); }
}
.skip-btn {
  width: 100%;
  min-height: 46px;
  margin: 2px 0 0;
  padding: 0 16px;
  border: 1px solid rgba(184, 138, 61, 0.72);
  border-radius: 8px;
  background-color: rgba(6, 20, 33, 0.24);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.86);
  cursor: pointer;
  touch-action: manipulation;
  transition: color 0.16s ease, background-color 0.16s ease, border-color 0.16s ease, opacity 0.2s ease;
}
.skip-btn b {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.03em;
  font-variant-numeric: tabular-nums;
  color: var(--cream);
}
.skip-btn span { text-transform: none; letter-spacing: 0.04em; font-size: 13px; }
.next-btn {
  background-color: var(--verm);
  border-color: var(--verm);
  color: var(--cream);
}
.next-btn b { font-size: 10px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: rgba(232, 220, 198, 0.72); }
.next-btn:hover {
  background-color: #e04f38;
  border-color: #e04f38;
  color: #fff;
}
.next-btn:active { background-color: #c83a27; border-color: #c83a27; color: #fff; }
.skip-btn:not(.next-btn):hover {
  color: var(--cream);
  background-color: rgba(6, 20, 33, 0.34);
  border-color: rgba(232, 220, 198, 0.6);
}
.skip-btn:not(.next-btn):active {
  color: #fff;
  background-color: rgba(6, 20, 33, 0.42);
  transform: translateY(1px);
}
.skip-btn:disabled { opacity: 0.55; cursor: default; }
.skip-btn:disabled:active { transform: none; }
.skip-btn:disabled:hover {
  color: rgba(232, 220, 198, 0.86);
  background-color: rgba(6, 20, 33, 0.24);
  border-color: rgba(184, 138, 61, 0.72);
}
.float-score {
  position: fixed;
  z-index: 50;
  font-size: 21px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--cream);
  text-shadow: 0 1px 14px rgba(2, 10, 18, 0.45);
  pointer-events: none;
}

@media (min-width: 760px) and (min-height: 480px),
       (orientation: landscape) and (min-width: 560px) and (max-height: 560px) {
  :root { --pad: clamp(20px, 3.4vw, 42px); }
  .play {
    display: grid;
    grid-template-columns: minmax(300px, 468px) minmax(310px, 500px);
    gap: clamp(32px, 6vw, 88px);
    justify-content: center;
    align-items: stretch;
  }
  .portrait-col { height: 100%; }
  .response { min-height: 52px; }
  .resp-main { font-size: 18px; }
  .resp-sub { font-size: 13px; }
  .answers-col {
    justify-content: center;
    gap: 14px;
  }
  .answers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-content: center;
    gap: 14px;
  }
  .answer { height: clamp(104px, 19vh, 158px); padding-right: 18px; }
  .answer .letter { width: 46px; font-size: 13px; }
  .answer .name { font-size: 20px; }
  .start-wrap { grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); }
}

@media (min-width: 821px) {
  .display { font-size: clamp(84px, 8.4vw, 122px); }
}
@media (min-width: 821px) and (max-height: 790px) {
  .display { font-size: clamp(70px, 7.4vw, 98px); margin-bottom: 16px; }
  .start-wrap { padding-top: 28px; padding-bottom: 12px; }
  .lede { margin-bottom: 16px; }
  .facts { margin-bottom: 16px; }
}

@media (max-width: 820px) {
  .start-wrap {
    grid-template-columns: minmax(0, 1fr);
    padding: 26px 20px 10px;
    align-content: safe center;
  }
  .start-copy { max-width: none; }
  .start-visual { display: none; }
  .display { font-size: clamp(54px, 15.5vw, 76px); }
  .start-actions { max-width: none; }
  .start-btn { max-width: none; }
  .start-foot { padding: 0 20px 14px; }
  .screen-result { padding: 24px 20px 32px; }
}

@media (max-height: 700px) and (max-width: 820px) {
  :root { --answer-h: 46px; }
  .game-shell { padding-top: 8px; padding-bottom: 8px; }
  .hud-row { margin-top: 7px; }
  .score-num { font-size: 20px; }
  .play { margin-top: 7px; gap: 6px; }
  .portrait-col { gap: 6px; }
  .response { min-height: 38px; }
  .resp-main { font-size: 15.5px; }
  .resp-sub { font-size: 11.5px; }
  .answer .name { font-size: clamp(16px, 4.6vw, 19px); }
  .skip-btn { min-height: 42px; font-size: 10.5px; }
  .skip-btn b { font-size: 11.5px; }
  .start-wrap { padding-top: 18px; }
  .display { font-size: clamp(48px, 13.5vw, 64px); margin-bottom: 14px; }
  .lede { font-size: 14.5px; margin-bottom: 14px; }
  .facts { margin-bottom: 14px; padding-top: 10px; }
}

@media (max-width: 480px) and (max-height: 600px) {
  .answers { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
  .answer { height: clamp(62px, 12vh, 82px); padding-right: 10px; gap: 8px; }
  .answer .letter { width: 33px; font-size: 11px; }
  .answer .name { font-size: 16px; line-height: 1.12; }
  .skip-btn { min-height: 40px; }
}

@media (max-height: 560px) {
  .screen-result { padding: 16px 20px 20px; }
  .result-ticks { margin-bottom: 12px; }
  .result-title { font-size: clamp(30px, 5.4vw, 48px); margin: 4px 0 10px; }
  .final-score { padding: 8px 0; }
  .final-num { font-size: clamp(38px, 8vw, 64px); }
  .result-rating { margin: 10px 0; font-size: 14px; }
  .board { margin: 14px 0 12px; }
  .result-btn { margin-top: 14px; }
  .result-note { margin-top: 8px; }
}

@media (orientation: landscape) and (max-height: 560px) {
  .start-wrap {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0;
    padding: 14px 20px 8px;
  }
  .start-copy { max-width: 680px; }
  .start-copy .eyebrow { margin-bottom: 10px; }
  .start-visual { display: none; }
  .display { font-size: clamp(40px, 7.2vw, 62px); margin-bottom: 12px; }
  .lede { font-size: 13.5px; margin-bottom: 12px; max-width: 62ch; }
  .facts { margin-bottom: 12px; padding-top: 8px; }
  .start-actions { max-width: 300px; }
  .start-btn { min-height: 48px; font-size: 15px; }
  .start-foot { padding-bottom: 8px; }
}

@media (orientation: landscape) and (max-height: 460px) and (max-width: 780px) {
  .game-shell { padding: 8px 12px; }
  .play { grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); gap: 16px; }
  .answer { height: clamp(76px, 21vh, 104px); padding-right: 12px; }
  .answer .letter { width: 40px; font-size: 11px; }
  .answer .name { font-size: 16.5px; }
  .response { min-height: 36px; }
  .resp-main { font-size: 14.5px; }
  .resp-sub { font-size: 11px; }
  .hud-row { margin-top: 6px; }
  .score-num { font-size: 19px; }
}

.screen-result {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  overflow-y: auto;
  padding: clamp(24px, 6vh, 64px) clamp(20px, 5vw, 56px) 40px;
}
.result-wrap { width: 100%; max-width: 560px; margin-block: auto; }
.result-ticks { margin-bottom: 26px; }
.result-title {
  font-size: clamp(42px, 8vw, 72px);
  margin: 10px 0 20px;
}
.final-score {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding: 16px 0 14px;
  border-top: 1px solid rgba(184, 138, 61, 0.5);
  border-bottom: 1px solid rgba(184, 138, 61, 0.5);
}
.final-num {
  font-family: "Oswald", "Arial Narrow", sans-serif;
  font-weight: 700;
  font-size: clamp(54px, 11vw, 84px);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--cream);
}
.result-rating {
  margin: 18px 0;
  font-size: 15.5px;
  line-height: 1.55;
  color: rgba(232, 220, 198, 0.74);
}
.result-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.5);
}
.result-stats b {
  font-weight: 600;
  color: rgba(232, 220, 198, 0.9);
}
.board { margin: 28px 0 26px; }
.board-head {
  display: flex;
  justify-content: space-between;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(232, 220, 198, 0.16);
  font-size: 9.5px;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.42);
}
.board-list { margin: 0; padding: 0; list-style: none; }
.board-list li {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(232, 220, 198, 0.09);
  font-size: 14px;
}
.board-list .rank { width: 24px; color: rgba(232, 220, 198, 0.4); font-variant-numeric: tabular-nums; }
.board-list .who { flex: 1; color: rgba(232, 220, 198, 0.82); }
.board-list .who a { color: inherit; text-decoration: none; border-bottom: 1px solid rgba(232, 220, 198, 0.22); }
.board-list .val { font-variant-numeric: tabular-nums; color: var(--cream); }
.board-list li.mine .who { color: var(--verm); }
.result-btn { max-width: 320px; margin-top: 28px; }
.result-note {
  margin: 14px 0 0;
  min-height: 16px;
  font-size: 10.5px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: rgba(232, 220, 198, 0.6);
}

.credits {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--cream);
  max-width: min(580px, 92vw);
}
.credits::backdrop { background: rgba(3, 12, 21, 0.74); }
.credits-in {
  max-height: 82vh;
  overflow-y: auto;
  padding: 26px 24px 22px;
  border: 1px solid rgba(232, 220, 198, 0.2);
  border-radius: 12px;
  background: #103a5c;
  box-shadow: 0 18px 60px rgba(2, 10, 18, 0.45);
}
.credits-title {
  margin: 8px 0 8px;
  font-family: "Oswald", "Arial Narrow", sans-serif;
  font-weight: 700;
  font-size: 30px;
  text-transform: uppercase;
  letter-spacing: -0.01em;
}
.credits-note {
  margin: 0 0 16px;
  font-size: 13px;
  line-height: 1.5;
  color: rgba(232, 220, 198, 0.64);
}
.credits-list { margin: 0 0 20px; padding: 0; list-style: none; }
.credits-list li {
  padding: 7px 0;
  border-bottom: 1px solid rgba(232, 220, 198, 0.1);
  font-size: 12px;
  line-height: 1.45;
  color: rgba(232, 220, 198, 0.68);
}
.credits-list b { font-weight: 600; color: rgba(232, 220, 198, 0.9); }
.credits-list a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.credits-close { max-width: 200px; justify-content: center; }

:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.start-btn:focus-visible { outline-color: #fff; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (orientation: landscape) and (min-width: 800px) and (max-height: 560px) {
  .answers-col {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 86px;
    grid-template-rows: 1fr;
    align-items: center;
    justify-content: stretch;
    gap: 8px;
  }
  .answers {
    grid-column: 1 / 3;
    grid-row: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 1fr;
    align-content: center;
    gap: 8px;
  }
  .round-actions {
    grid-column: 3;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-self: center;
    gap: 8px;
  }
  .round-actions .skip-btn {
    flex: 0 0 auto;
    min-height: 64px;
    padding: 0 6px;
    flex-direction: column;
    gap: 1px;
    margin: 0;
    text-align: center;
  }
  .round-actions .skip-btn span { font-size: 11px; }
  .round-actions .skip-btn b { font-size: 10px; letter-spacing: 0.02em; }
  .answers .answer { gap: 8px; padding-right: 0; }
  .answers .answer .letter { width: 28px; font-size: 11px; }
  .answers .answer .name { min-width: 0; padding-left: 0; padding-right: 12px; font-size: 16px; }
}
