/* Native short-height layout: keep controls readable; do not scale the page. */
@media (min-width: 480px) and (max-height: 480px) {
  .header {
    position: absolute;
    top: 8px;
    right: 12px;
    z-index: 2;
    height: 44px;
    padding: 0;
  }
  .header .wordmark,
  .header-note {
    display: none;
  }
  .icon-button {
    min-height: 44px;
    min-width: 44px;
    font-size: 18px;
  }
  .workspace {
    display: grid;
    width: 100%;
    max-width: none;
    grid-template-columns: minmax(140px, 1fr) auto minmax(140px, 1fr);
    align-items: center;
    height: 100svh;
    padding: 4px 12px;
    gap: 12px;
    box-sizing: border-box;
  }
  .left-panel {
    padding: 0;
  }
  .edition,
  .left-panel h1,
  .intro,
  .desktop-tip,
  .discovery,
  .collection,
  footer {
    display: none;
  }
  .scoreboard {
    display: block;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: white;
    max-width: 200px;
    margin: 0 auto;
    padding: 10px 12px;
  }
  .score-label {
    font-size: 14px;
  }
  .scoreboard > strong {
    font-size: 32px;
  }
  .best-line {
    margin-top: 6px;
    padding-top: 6px;
    font-size: 13px;
  }
  .game-panel {
    width: min(calc((100svh - 80px) * 0.7541), calc(100vw - 328px));
    min-width: 0;
    max-width: none;
    height: calc(100svh - 8px);
    margin: 0;
  }
  .game-top {
    height: 44px;
    padding: 0;
    gap: 6px;
  }
  .live-label {
    position: fixed;
    left: 20px;
    bottom: 12px;
    max-width: 140px;
    font-size: 14px;
  }
  .live-label > span:first-child {
    display: none;
  }
  .next {
    font-size: 12px;
    gap: 3px;
  }
  .next canvas {
    width: 28px;
    height: 28px;
  }
  .small-button {
    flex: 0 0 44px;
    min-width: 44px;
    width: 44px;
    height: 44px;
    font-size: 18px;
  }
  .arena {
    border-radius: 14px;
  }
  .game-bottom {
    padding: 4px 0;
    font-size: 11px;
    line-height: 1.2;
  }
  .keyboard-hint {
    display: none;
  }
  .right-panel {
    display: block;
    width: auto;
    padding: 40px 0 0;
  }
  .shake-card {
    display: block;
    padding: 0;
    background: none;
    border: 0;
  }
  .shake-card > .eyebrow,
  .shake-card > h2,
  .shake-card > p {
    display: none;
  }
  .shake-button {
    min-width: 140px;
    max-width: 200px;
    min-height: 44px;
    padding: 8px 12px;
    font-size: 16px;
    margin: auto;
  }
  .charge {
    max-width: 200px;
    margin: 10px auto 0;
  }
  .charge > div {
    font-size: 12px;
    white-space: normal;
  }
  .restart {
    min-height: 44px;
    min-width: 140px;
    margin: 6px auto 0;
    padding: 8px 12px;
    font-size: 14px;
  }
  .overlay {
    position: fixed;
    inset: 6px;
    z-index: 10;
    padding: 6px;
    overflow: auto;
  }
  .overlay-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 10px;
    width: min(460px, 100%);
    max-width: none;
    max-height: 100%;
    overflow: auto;
    padding: 12px 16px;
    border-radius: 16px;
  }
  .overlay-card > .eyebrow,
  .overlay-card h2,
  .overlay-card p {
    grid-column: 1 / -1;
  }
  .overlay-card h2 {
    margin: 0;
    font-size: 22px;
  }
  .overlay-card p {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
  }
  .overlay-card .primary,
  .overlay-card .text-button {
    min-height: 44px;
    margin: 0;
    padding: 8px 12px;
    font-size: 14px;
  }
  .overlay-card .primary:has(+ [hidden]) {
    grid-column: 1 / -1;
  }
}
