@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@700;800;900&family=Pacifico&display=swap');

:root {
  --ed-ink: #1a1030;
  --ed-cream: #fff8f0;
  --ed-pink: #ff6b9d;
  --ed-coral: #ff8c42;
  --ed-sun: #ffe566;
  --ed-mint: #5dffb1;
  --ed-cyan: #7df9ff;
  --ed-violet: #a78bfa;
  --ed-panel: rgba(26, 16, 48, 0.78);
  --ed-panel-light: rgba(255, 248, 240, 0.94);
  --ed-radius: 22px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  min-height: 100%;
  font-family: Nunito, system-ui, sans-serif;
  color: var(--ed-cream);
  background: #12081f;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

.ed-scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse at 20% 10%, rgba(255, 107, 157, 0.35), transparent 45%),
    radial-gradient(ellipse at 90% 20%, rgba(125, 249, 255, 0.25), transparent 40%),
    radial-gradient(ellipse at 50% 100%, rgba(255, 229, 102, 0.2), transparent 45%),
    #12081f;
}
.ed-scene__art {
  position: absolute;
  inset: 0;
  background: url('../assets/lobby-bg.jpg') center/cover no-repeat;
  opacity: 0.55;
  filter: saturate(1.15);
}
.ed-scene__veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 8, 31, 0.35), rgba(18, 8, 31, 0.82));
}
.ed-float {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.ed-float span {
  position: absolute;
  font-size: clamp(1.4rem, 5vw, 2.2rem);
  opacity: 0.55;
  animation: ed-float-y 9s ease-in-out infinite;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.25));
}

@keyframes ed-float-y {
  0%, 100% { transform: translateY(0) rotate(-6deg); }
  50% { transform: translateY(-28px) rotate(8deg); }
}

#ed-app {
  position: relative;
  z-index: 2;
  max-width: 480px;
  margin: 0 auto;
  min-height: 100dvh;
  padding: 16px 16px calc(20px + var(--safe-b));
}

.ed-screen { display: none; animation: ed-in 0.35s ease both; }
.ed-screen.is-active { display: block; }
@keyframes ed-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

.ed-logo {
  font-family: Pacifico, cursive;
  font-size: clamp(2.4rem, 10vw, 3.4rem);
  line-height: 1.05;
  text-align: center;
  margin: 8px 0 4px;
  background: linear-gradient(120deg, var(--ed-sun), var(--ed-pink), var(--ed-cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 6px 0 rgba(255, 107, 157, 0.25));
  animation: ed-logo-bob 3s ease-in-out infinite;
}
@keyframes ed-logo-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}
.ed-eye {
  text-align: center;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ed-cyan);
  margin: 0;
}
.ed-tag {
  text-align: center;
  color: rgba(255,248,240,.85);
  font-weight: 800;
  margin: 0 0 16px;
}

.ed-mascots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 8px 0 18px;
}
.ed-mascots span {
  font-size: 2.4rem;
  animation: ed-wiggle 2.4s ease-in-out infinite;
  filter: drop-shadow(0 8px 12px rgba(0,0,0,.3));
}
.ed-mascots span:nth-child(2) { animation-delay: .2s; }
.ed-mascots span:nth-child(3) { animation-delay: .4s; }
@keyframes ed-wiggle {
  0%, 100% { transform: rotate(-8deg) scale(1); }
  50% { transform: rotate(8deg) scale(1.08); }
}

.ed-panel {
  background: var(--ed-panel);
  border: 2px solid rgba(255,255,255,.12);
  border-radius: var(--ed-radius);
  padding: 16px;
  backdrop-filter: blur(14px);
  box-shadow: 0 18px 40px rgba(0,0,0,.35);
  margin-bottom: 14px;
}
.ed-panel--light {
  background: var(--ed-panel-light);
  color: var(--ed-ink);
  border-color: rgba(255,255,255,.5);
}

.ed-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 8px;
  color: var(--ed-cyan);
}
.ed-panel--light .ed-label { color: #7c3aed; }

.ed-input {
  width: 100%;
  border: 2px solid rgba(167,139,250,.45);
  border-radius: 16px;
  padding: 14px 16px;
  font: inherit;
  font-weight: 800;
  font-size: 1.05rem;
  background: rgba(255,255,255,.95);
  color: var(--ed-ink);
  outline: none;
}
.ed-input:focus { border-color: var(--ed-pink); box-shadow: 0 0 0 4px rgba(255,107,157,.2); }

.ed-avatars {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-top: 10px;
}
.ed-avatar-btn {
  aspect-ratio: 1;
  border: 2px solid transparent;
  border-radius: 14px;
  background: rgba(255,255,255,.12);
  font-size: 1.45rem;
  cursor: pointer;
}
.ed-avatar-btn.is-on {
  border-color: var(--ed-sun);
  background: rgba(255,229,102,.25);
  transform: scale(1.06);
}

.ed-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  border: none;
  border-radius: 18px;
  padding: 16px 18px;
  font-family: Nunito, sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  cursor: pointer;
  transition: transform .15s ease, filter .15s ease;
}
.ed-btn:active { transform: scale(0.97); }
.ed-btn--primary {
  background: linear-gradient(135deg, var(--ed-pink), var(--ed-coral));
  color: #fff;
  box-shadow: 0 10px 0 #c44a70, 0 16px 28px rgba(255,107,157,.35);
}
.ed-btn--primary:hover { filter: brightness(1.05); }
.ed-btn--ghost {
  background: rgba(255,255,255,.1);
  color: var(--ed-cream);
  border: 2px solid rgba(255,255,255,.2);
}
.ed-btn--mint {
  background: linear-gradient(135deg, var(--ed-mint), var(--ed-cyan));
  color: #1a1030;
  box-shadow: 0 8px 0 #2db88a;
}
.ed-btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }

.ed-error {
  min-height: 1.2em;
  margin-top: 8px;
  color: #ff8fab;
  font-weight: 800;
  font-size: 0.9rem;
}

.ed-howto h3 {
  margin: 0 0 10px;
  font-family: Pacifico, cursive;
  font-size: 1.35rem;
  color: var(--ed-sun);
}
.ed-howto ol {
  margin: 0;
  padding-left: 1.2rem;
  font-weight: 800;
  color: rgba(255,248,240,.9);
}
.ed-howto li { margin-bottom: 6px; }

.ed-howto-screen.is-active {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100dvh - 32px);
  text-align: center;
}
.ed-howto-screen .ed-howto {
  width: min(100%, 420px);
  margin: 0 auto;
  text-align: left;
}

.ed-rankline {
  margin: 14px 0 0;
  text-align: center;
  font-weight: 800;
  font-size: 0.88rem;
  color: rgba(255, 248, 240, 0.78);
}

.ed-live-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(93,255,177,.15);
  border: 1px solid rgba(93,255,177,.35);
  font-weight: 900;
  font-size: 0.85rem;
  color: var(--ed-mint);
}
.ed-live-pill i {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--ed-mint);
  animation: ed-blink 1s infinite;
}
@keyframes ed-blink { 50% { opacity: .35; } }

/* Waiting */
.ed-wait-hero {
  text-align: center;
  padding: 20px 8px;
}
.ed-wait-hero .big {
  font-size: 4rem;
  margin: 8px 0;
  animation: ed-wiggle 2s ease-in-out infinite;
}
.ed-wait-msg {
  font-weight: 800;
  color: rgba(255,248,240,.9);
  min-height: 3em;
}
.ed-code-chip {
  display: inline-block;
  margin-top: 10px;
  padding: 8px 16px;
  border-radius: 12px;
  background: rgba(255,229,102,.2);
  border: 1px dashed var(--ed-sun);
  font-family: Pacifico, cursive;
  font-size: 1.4rem;
  letter-spacing: 0.2em;
  color: var(--ed-sun);
}

/* Gameplay */
.ed-topbar {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 12px;
}
.ed-stat {
  background: var(--ed-panel);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px;
  padding: 10px 8px;
  text-align: center;
}
.ed-stat b {
  display: block;
  font-size: 1.15rem;
  color: var(--ed-sun);
}
.ed-stat span {
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,248,240,.65);
}

.ed-timer {
  height: 10px;
  border-radius: 99px;
  background: rgba(255,255,255,.12);
  overflow: hidden;
  margin-bottom: 14px;
}
.ed-timer > i {
  display: block;
  height: 100%;
  width: 100%;
  transform-origin: left center;
  background: linear-gradient(90deg, var(--ed-mint), var(--ed-sun), var(--ed-pink));
  transition: transform .2s linear;
}

.ed-puzzle {
  text-align: center;
  padding: 22px 12px;
  margin-bottom: 14px;
  background: linear-gradient(160deg, rgba(255,107,157,.2), rgba(125,249,255,.12));
  border: 2px solid rgba(255,255,255,.15);
  border-radius: 28px;
  box-shadow: inset 0 0 40px rgba(255,229,102,.08);
}
.ed-puzzle__emojis {
  font-size: clamp(2.6rem, 12vw, 3.6rem);
  letter-spacing: 0.08em;
  line-height: 1.3;
  filter: drop-shadow(0 8px 16px rgba(0,0,0,.35));
}
.ed-puzzle__q {
  margin-top: 8px;
  font-family: Pacifico, cursive;
  font-size: 1.6rem;
  color: var(--ed-sun);
}
.ed-hint {
  margin-top: 8px;
  font-weight: 800;
  color: rgba(255,248,240,.75);
  font-size: 0.9rem;
}

.ed-choices {
  display: grid;
  gap: 10px;
}
.ed-choice {
  border: none;
  border-radius: 18px;
  padding: 16px;
  font: inherit;
  font-weight: 900;
  font-size: 1.02rem;
  text-align: left;
  cursor: pointer;
  color: var(--ed-ink);
  background: linear-gradient(135deg, #fff, #ffe8f2);
  box-shadow: 0 6px 0 rgba(255,107,157,.35);
  transition: transform .12s ease;
}
.ed-choice:nth-child(2) { box-shadow: 0 6px 0 rgba(125,249,255,.4); }
.ed-choice:nth-child(3) { box-shadow: 0 6px 0 rgba(255,229,102,.45); }
.ed-choice:nth-child(4) { box-shadow: 0 6px 0 rgba(93,255,177,.4); }
.ed-choice:active { transform: translateY(3px); box-shadow: 0 2px 0 rgba(0,0,0,.2); }
.ed-choice.is-picked { outline: 3px solid var(--ed-mint); }
.ed-choice.is-correct { background: linear-gradient(135deg, #b8ffd9, #5dffb1); }
.ed-choice.is-wrong { background: linear-gradient(135deg, #ffd0dc, #ff6b9d); opacity: .85; }
.ed-choice:disabled { cursor: default; }

.ed-type-row {
  display: flex;
  gap: 8px;
}
.ed-type-row .ed-input { flex: 1; }
.ed-type-row .ed-btn { width: auto; padding-inline: 18px; }

.ed-feedback {
  text-align: center;
  font-weight: 900;
  min-height: 1.2em;
  margin: 8px 0 0;
  color: var(--ed-sun);
  font-size: 0.92rem;
}
.ed-feedback--soft {
  opacity: 0.85;
  min-height: 0;
  margin-top: 4px;
  font-size: 0.8rem;
}

.ed-play__main {
  display: flex;
  flex-direction: column;
}
.ed-play__side {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

/* Results / board */
.ed-board {
  display: grid;
  gap: 8px;
}
.ed-board-row {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.1);
}
.ed-board-row.is-me {
  border-color: rgba(255,229,102,.5);
  background: rgba(255,229,102,.12);
}
.ed-board-rank {
  width: 32px; height: 32px;
  border-radius: 10px;
  display: grid; place-items: center;
  font-weight: 900;
  background: rgba(255,255,255,.1);
}
.ed-board-rank.is-1 { background: linear-gradient(135deg, #ffe566, #ff8c42); color: #1a1030; }
.ed-board-rank.is-2 { background: linear-gradient(135deg, #e8eef2, #94a3b8); color: #1a1030; }
.ed-board-rank.is-3 { background: linear-gradient(135deg, #fdba74, #d97706); color: #1a1030; }
.ed-board-name { font-weight: 900; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ed-board-score { font-weight: 900; color: var(--ed-sun); }

.ed-podium {
  display: grid;
  grid-template-columns: 1fr 1.15fr 1fr;
  gap: 8px;
  align-items: end;
  margin: 16px 0;
}
.ed-pod {
  text-align: center;
  padding: 14px 8px;
  border-radius: 18px;
  background: var(--ed-panel);
  border: 1px solid rgba(255,255,255,.12);
}
.ed-pod--1 {
  padding-top: 22px;
  border-color: rgba(255,229,102,.5);
  transform: translateY(-8px);
  box-shadow: 0 0 28px rgba(255,229,102,.2);
}
.ed-pod .face { font-size: 2.2rem; }
.ed-pod h3 { margin: 6px 0 2px; font-size: 0.9rem; }
.ed-pod b { color: var(--ed-sun); }

.ed-loading {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  place-items: center;
  background: rgba(18,8,31,.55);
}
.ed-loading.is-on { display: grid; }
.ed-spinner {
  width: 48px; height: 48px;
  border: 4px solid rgba(255,255,255,.2);
  border-top-color: var(--ed-pink);
  border-radius: 50%;
  animation: ed-spin .7s linear infinite;
}
@keyframes ed-spin { to { transform: rotate(360deg); } }

.ed-confetti {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 40;
  overflow: hidden;
}
.ed-confetti i {
  position: absolute;
  top: -12px;
  width: 10px; height: 14px;
  border-radius: 2px;
  animation: ed-fall 2.4s linear forwards;
}
@keyframes ed-fall {
  to { transform: translateY(110vh) rotate(520deg); opacity: 0; }
}

.ed-hidden { display: none !important; }

.ed-label--avatar { margin-top: 12px; }
.ed-lobby__actions {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ed-mute-inline {
  width: auto;
  align-self: center;
  padding: 10px 16px;
  font-size: 0.9rem;
}

@media (min-width: 720px) {
  #ed-app { max-width: 520px; padding-top: 28px; }
}

/* Mobile: center lobby / howto / play — no tall stretched buttons */
@media (max-width: 720px) {
  #ed-app {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px 12px calc(12px + var(--safe-b));
  }

  body:has(.ed-screen.is-active.ed-play),
  body:has(.ed-screen.is-active.ed-lobby),
  body:has(.ed-screen.is-active.ed-howto-screen) {
    overflow: hidden;
    height: 100%;
  }

  .ed-screen.is-active.ed-howto-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: calc(100dvh - 24px);
    margin: 0 auto;
  }

  .ed-screen.is-active.ed-play {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    min-height: calc(100dvh - 24px);
    max-height: calc(100dvh - 24px);
    overflow: hidden;
    gap: 10px;
  }

  .ed-play__hud {
    flex-shrink: 0;
    width: 100%;
  }

  .ed-play .ed-topbar {
    gap: 6px;
    margin-bottom: 4px;
  }

  .ed-play .ed-stat {
    padding: 6px 4px;
    border-radius: 10px;
  }

  .ed-play .ed-stat b {
    font-size: 0.95rem;
  }

  .ed-play .ed-stat span {
    font-size: 0.55rem;
  }

  .ed-play .ed-timer {
    height: 6px;
    margin-bottom: 0;
  }

  .ed-play__main {
    flex: 0 1 auto;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
  }

  .ed-play .ed-puzzle {
    flex-shrink: 0;
    padding: 12px 10px;
    margin-bottom: 0;
    border-radius: 16px;
  }

  .ed-play .ed-puzzle__emojis {
    font-size: clamp(1.7rem, 7vw, 2.3rem);
    letter-spacing: 0.04em;
    line-height: 1.15;
  }

  .ed-play .ed-puzzle__q {
    margin-top: 2px;
    font-size: 1.05rem;
  }

  .ed-play .ed-hint {
    margin-top: 4px;
    font-size: 0.72rem;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .ed-play__side {
    flex: 0 0 auto;
    width: 100%;
  }

  .ed-play .ed-choices {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    /* IMPORTANT: do not stretch rows to fill screen */
    grid-auto-rows: auto;
  }

  .ed-play .ed-choice {
    min-height: 44px;
    max-height: 56px;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 0.84rem;
    line-height: 1.2;
    box-shadow: 0 3px 0 rgba(255,107,157,.3);
    display: flex;
    align-items: center;
    justify-content: flex-start;
  }

  .ed-play .ed-choice:nth-child(2) { box-shadow: 0 3px 0 rgba(125,249,255,.35); }
  .ed-play .ed-choice:nth-child(3) { box-shadow: 0 3px 0 rgba(255,229,102,.4); }
  .ed-play .ed-choice:nth-child(4) { box-shadow: 0 3px 0 rgba(93,255,177,.35); }

  .ed-play .ed-feedback {
    margin: 6px 0 0;
    font-size: 0.78rem;
    min-height: 1em;
    text-align: center;
  }

  .ed-play .ed-rankline {
    display: none;
  }

  .ed-screen.is-active.ed-lobby {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    min-height: calc(100dvh - 24px);
    gap: 8px;
  }

  .ed-lobby__head {
    flex-shrink: 0;
  }

  .ed-eye {
    font-size: 0.62rem;
    letter-spacing: 0.14em;
  }

  .ed-logo {
    font-size: clamp(1.85rem, 8vw, 2.4rem);
    margin: 2px 0;
    animation: none;
  }

  .ed-tag {
    margin: 0 0 6px;
    font-size: 0.82rem;
    line-height: 1.3;
  }

  .ed-mascots {
    margin: 2px 0 8px;
    gap: 6px;
  }

  .ed-mascots span {
    font-size: 1.55rem;
  }

  .ed-panel {
    padding: 12px;
    margin-bottom: 0;
    border-radius: 16px;
  }

  .ed-label {
    margin-bottom: 4px;
    font-size: 0.68rem;
  }

  .ed-label--avatar {
    margin-top: 8px;
  }

  .ed-input {
    padding: 10px 12px;
    font-size: 0.95rem;
    border-radius: 12px;
  }

  .ed-avatars {
    gap: 6px;
    margin-top: 6px;
  }

  .ed-avatar-btn {
    border-radius: 10px;
    font-size: 1.2rem;
  }

  .ed-lobby__actions {
    margin-top: 10px;
    gap: 6px;
  }

  .ed-btn {
    padding: 12px 14px;
    font-size: 1rem;
    border-radius: 14px;
  }

  .ed-btn--primary {
    box-shadow: 0 6px 0 #c44a70, 0 10px 18px rgba(255,107,157,.3);
  }

  .ed-mute-inline {
    padding: 8px 12px;
    font-size: 0.8rem;
  }

  .ed-error {
    min-height: 0.9em;
    margin-top: 4px;
    font-size: 0.8rem;
  }

  .ed-howto h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    text-align: center;
  }

  .ed-howto ol {
    font-size: 0.88rem;
    text-align: left;
  }

  .ed-howto li {
    margin-bottom: 6px;
  }
}

/* Short phones: tighter but still vertically centered */
@media (max-height: 700px) {
  .ed-mascots { display: none; }

  .ed-logo {
    font-size: clamp(1.55rem, 6vh, 2rem);
    margin: 0;
  }

  .ed-tag {
    margin: 0 0 4px;
    font-size: 0.75rem;
  }

  .ed-screen.is-active.ed-lobby,
  .ed-screen.is-active.ed-howto-screen,
  .ed-screen.is-active.ed-play {
    justify-content: center;
  }

  .ed-panel {
    padding: 10px;
  }

  .ed-input {
    padding: 8px 10px;
  }

  .ed-btn {
    padding: 10px 12px;
  }

  .ed-play .ed-choice {
    min-height: 40px;
    max-height: 48px;
    padding: 8px 10px;
  }
}

@media (orientation: landscape) and (max-height: 520px) {
  #ed-app {
    max-width: 900px;
    padding: 4px 8px calc(6px + var(--safe-b));
  }

  .ed-screen.is-active.ed-lobby {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    align-items: center;
    gap: 10px;
    min-height: calc(100dvh - 12px);
  }

  .ed-lobby__head {
    text-align: left;
  }

  .ed-eye,
  .ed-logo,
  .ed-tag {
    text-align: left;
  }

  .ed-mascots {
    display: none;
  }

  .ed-lobby__card {
    margin: 0;
  }

  .ed-avatars {
    grid-template-columns: repeat(6, 1fr);
  }

  .ed-mute-inline {
    display: none;
  }

  /* Play landscape: centered side-by-side, compact choices */
  .ed-screen.is-active.ed-play {
    position: relative;
    max-width: 860px;
    min-height: calc(100dvh - 12px);
    max-height: calc(100dvh - 12px);
    justify-content: center;
    gap: 6px;
    overflow: hidden;
  }

  .ed-play .ed-topbar {
    grid-template-columns: repeat(3, minmax(0, 130px));
    justify-content: center;
    gap: 6px;
    margin-bottom: 2px;
  }

  .ed-play .ed-stat {
    padding: 4px 6px;
  }

  .ed-play .ed-stat b {
    font-size: 0.85rem;
    display: inline;
    margin-right: 4px;
  }

  .ed-play .ed-stat span {
    display: inline;
    font-size: 0.55rem;
  }

  .ed-play .ed-timer {
    height: 5px;
    max-width: 400px;
    margin-inline: auto;
  }

  .ed-play__main {
    flex: 0 1 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: 10px;
    align-items: center;
  }

  .ed-play .ed-puzzle {
    height: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10px 12px;
    border-radius: 14px;
  }

  .ed-play .ed-puzzle__emojis {
    font-size: clamp(1.35rem, 5.5vh, 1.9rem);
  }

  .ed-play .ed-puzzle__q {
    font-size: 0.95rem;
  }

  .ed-play .ed-hint {
    font-size: 0.68rem;
    -webkit-line-clamp: 1;
  }

  .ed-play__side {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: auto;
  }

  .ed-play .ed-choices {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: auto;
    gap: 6px;
  }

  .ed-play .ed-choice {
    min-height: 40px;
    max-height: 48px;
    padding: 8px 10px;
    font-size: 0.78rem;
    border-radius: 10px;
    box-shadow: 0 2px 0 rgba(0,0,0,.2);
  }

  .ed-play .ed-feedback,
  .ed-play .ed-feedback--soft {
    text-align: center;
  }

  .ed-screen.is-active.ed-howto-screen {
    min-height: calc(100dvh - 12px);
  }
}
