/*
 * Heyming OS Wordle Answer Finder — Tier-1 rebuild.
 *
 * Built on brand tokens + HOSDL primitives. The Wordle green / yellow /
 * gray tile semantics are preserved (muscle memory matters), but their
 * exact colors are now derived from brand tokens so they hold up against
 * the dark surface and meet WCAG 2.2 AA against tile text.
 *
 * All IDs, class names, ARIA roles, and data attributes the solver JS
 * binds to (.corrects, .maybecorrects, input#first..#fifth, #excludeLetters,
 * #results [role=tab], .play-letter.correct/maybecorrect/incorrect, etc.)
 * are intact.
 */

:root {
  /* Wordle tile palette — recognizable, AA-clear on tile text. Scoped
   * --wordle-* tokens carry the muscle-memory green/yellow/gray, plus
   * one dark text color for the yellow tile (white-on-yellow fails AA). */
  --wordle-green: #16a34a;
  --wordle-yellow: #d4a017;
  --wordle-gray: #3a3a44;
  --wordle-text-on-tile: var(--pure-white);
  --wordle-text-on-tile-dark: #1a1a1a;
  /* Match the 5-tile yellow/green grids: 5×44px tiles + 4×6px gaps = 244px */
  --tile-size: 44px;
  --tile-gap: 6px;
  --long-input-width: calc(5 * var(--tile-size) + 4 * var(--tile-gap));
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  width: 100%;
}

body {
  margin: 0;
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
  padding-top: env(safe-area-inset-top);
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--surface-0);
  color: var(--text-1);
  font-family: var(--font-ui);
  touch-action: manipulation;
  overscroll-behavior: none;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* ─── App header ───────────────────────────────────────────────────── */

.wordle-app-header {
  border-radius: 0;
  border-left: none;
  border-right: none;
  border-top: none;
  margin-bottom: 8px;
}

.wordle-app-header .hos-app-header-title {
  font-size: var(--text-h3);
  letter-spacing: -0.01em;
}

/* Help / info button — round token-aware variant of the legacy chip. */
.info {
  background-color: var(--accent-primary-bg);
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0;
  width: 28px;
  height: 28px;
  min-width: 28px;
  color: var(--text-on-accent);
  font-family: var(--font-ui);
  font-style: italic;
  font-weight: 700;
  font-size: 14px;
  line-height: 1;
  text-transform: lowercase;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background-color var(--motion-hover), transform var(--motion-hover);
}

.info:hover {
  background-color: var(--accent-primary-bg-hover);
}

.info:active {
  transform: scale(0.94);
}

/* ─── Base button reset ────────────────────────────────────────────── */

button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
  outline: 0;
  margin: 0;
  border: 0;
  cursor: pointer;
  user-select: none;
  vertical-align: middle;
  appearance: none;
  text-decoration: none;
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 14px;
  line-height: 1.5;
  letter-spacing: 0.01em;
  min-width: 64px;
  padding: 10px 16px;
  min-height: 44px;
  border-radius: var(--radius);
  background-color: var(--surface-2);
  color: var(--text-1);
  transition: background-color var(--motion-hover), border-color var(--motion-hover),
    color var(--motion-hover), transform 0.1s ease;
}

button:hover {
  background-color: var(--surface-1);
}

button:active {
  transform: scale(0.97);
}

.btn-txt {
  color: var(--text-1);
  background-color: transparent;
}

.btn-bordered {
  border: 1px solid var(--hairline-strong);
}

.btn-bordered:hover {
  border-color: var(--accent-primary);
}

.btn-primary {
  background-color: var(--accent-primary-bg);
  color: var(--text-on-accent);
  border-color: transparent;
}

.btn-primary:hover {
  background-color: var(--accent-primary-bg-hover);
}

/* ─── Tile inputs (correct/maybe/incorrect) ────────────────────────── */

input[type='text'] {
  text-transform: uppercase;
  font-family: var(--font-ui);
  font-weight: 700;
  text-align: center;
  color: var(--wordle-text-on-tile);
  font-size: 16px;
  caret-color: var(--accent-primary);
}

input.wordle-style {
  border: 2px solid transparent;
  border-radius: 6px;
  transition: border-color var(--motion-hover), box-shadow var(--motion-hover),
    background-color var(--motion-hover);
}

input.wordle-style:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-primary-soft);
}

/* Correct (green tile) — used for "include in position N" inputs and the
 * .corrects parent block. */
.corrects .form-input > input,
.maybecorrects .form-input > input {
  margin: 0;
  padding: 0;
}

.corrects input,
input.correct {
  background-color: var(--wordle-green);
}

/* The five letter-tiles render as 44×44 squares — discrete typing cells,
 * not styled inputs. brand.css applies a default 0.5em 0.75em padding to
 * every text-flavored input via a :where() rule at zero specificity; that
 * default is right for prose forms but wrong for these tiles, where it
 * inflates each cell's min-content width and pushes the grid past the
 * mobile viewport (the "yellow squares scrolling off-screen" bug).
 * Explicitly zero padding here so the tile shape stays. */
.corrects input {
  width: var(--tile-size);
  height: var(--tile-size);
  min-width: var(--tile-size);
  min-height: var(--tile-size);
  padding: 0;
}

input.correct {
  height: 44px;
  width: var(--long-input-width);
  min-height: 44px;
}

input.correct::placeholder,
input.incorrect::placeholder {
  color: color-mix(in srgb, var(--pure-white) 85%, transparent);
  opacity: 1;
}

input.incorrect {
  background-color: var(--wordle-gray);
  height: 44px;
  width: var(--long-input-width);
  min-height: 44px;
  color: var(--text-1);
}

.maybecorrects input {
  background-color: var(--wordle-yellow);
  color: var(--wordle-text-on-tile-dark, #1a1a1a);
  width: var(--tile-size);
  height: var(--tile-size);
  min-width: var(--tile-size);
  min-height: var(--tile-size);
  padding: 0;
}

.form-input.form-grid {
  display: grid;
  grid-gap: var(--tile-gap);
  grid-template-columns: repeat(5, 1fr);
}

/* ─── Stats panel tile glyphs ──────────────────────────────────────── */

.stat-letter {
  margin: 5px 0;
  display: inline-block;
  height: 100%;
  text-align: center;
  font-family: var(--font-mono);
  font-weight: 600;
  width: 30px;
}

.stat-letter-block {
  border: solid 1px var(--hairline-strong);
  width: 20px;
  margin-right: 5px;
}

.included-stat {
  color: var(--wordle-text-on-tile);
  background-color: var(--wordle-green);
}

.included-stat-wrong-spot {
  color: var(--wordle-text-on-tile);
  background-color: var(--wordle-yellow);
}

#randomWord {
  font-family: var(--font-mono);
  font-weight: 600;
  text-transform: uppercase;
  color: var(--accent-primary);
}

.block-input-control,
.fixed-input-control {
  width: 190px;
}

.fixed-input-control {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}

/* ─── Layout ───────────────────────────────────────────────────────── */

main {
  width: calc(100vw - 20px);
  margin-left: auto;
  margin-right: auto;
}

@media screen and (min-width: 480px) {
  main {
    width: 450px;
  }
}

/* Player mode needs more width for graph + word display */
#player {
  width: calc(100vw - 40px);
  max-width: 550px;
}

#playResultsContainer {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
  width: 100%;
}

#playResultsContainer > #playWordsResults {
  min-width: 200px;
}

#playResultsContainer > #wordDisplay {
  flex: 1;
  min-width: 200px;
}

hr {
  width: 100%;
  border: none;
  border-top: 1px solid var(--hairline);
  margin: 8px 0;
}

pre {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-1);
  text-transform: uppercase;
  background: var(--surface-1);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin: 0;
}

@media screen and (max-width: 480px) {
  pre {
    column-count: 2;
  }
}
@media screen and (min-width: 480px) {
  pre {
    column-count: 2;
  }
}
@media screen and (min-width: 600px) {
  pre {
    column-count: 3;
  }
}
@media screen and (min-width: 800px) {
  pre {
    column-count: 4;
  }
}
@media screen and (min-width: 1024px) {
  pre {
    column-count: 5;
  }
}

#results {
  margin-top: 12px;
  margin-left: 10px;
  margin-right: 10px;
}

@media screen and (min-width: 480px) {
  #results {
    width: calc(100vw - 20px);
  }
}

.panels {
  max-height: calc(100vh - 370px);
  overflow-y: auto;
  border: 1px solid var(--hairline);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  background: var(--surface-1);
  padding: 12px 14px;
}

/* Results tablist as a HOSDL-tinted tab strip. */
#results [role='tablist'] {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  border-bottom: 1px solid var(--hairline-strong);
  padding: 4px 4px 0;
  background: var(--surface-1);
  border-radius: var(--radius) var(--radius) 0 0;
  border: 1px solid var(--hairline);
  border-bottom-color: var(--hairline-strong);
}

@media screen and (max-width: 480px) {
  #results [role='tablist'] {
    justify-content: space-between;
  }
}

#results button[role='tab'] {
  border: none;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  background: transparent;
  color: var(--text-2);
  font-weight: 600;
  padding: 8px 12px;
  min-height: 36px;
  min-width: 0;
}

#results button[role='tab']:hover {
  background-color: var(--surface-2);
  color: var(--text-1);
}

#results button[role='tab'][aria-selected='true'] {
  background-color: var(--accent-primary-bg);
  color: var(--text-on-accent);
}

/* Override the generic transform-on-active because tab text shouldn't jump. */
#results button[role='tab']:active {
  transform: none;
}

/* ─── Focus + touch ────────────────────────────────────────────────── */

button:focus-visible {
  outline: 2px solid var(--focus-ring-inner);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px var(--focus-ring-outer);
}

input:focus {
  outline: none;
}

input:focus-visible {
  outline: 2px solid var(--focus-ring-inner);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px var(--focus-ring-outer);
}

@media (hover: none) and (pointer: coarse) {
  button:hover {
    background-color: var(--surface-2);
  }
  button:active {
    background-color: var(--surface-1);
  }
}

/* ─── Help modal ───────────────────────────────────────────────────── */

.modal-layer {
  z-index: 3;
  position: fixed;
  inset: 0;
  overflow: auto;
  background-color: var(--scrim);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.modal {
  display: block;
  background-color: var(--surface-1);
  border: 1px solid var(--hairline-strong);
  width: min(80vw, 720px);
  height: min(80vh, 640px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-modal);
  color: var(--text-1);
}

.modal-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--hairline);
}

.modal-title h2 {
  margin: 0;
  font-size: var(--text-h3);
  font-weight: 700;
  letter-spacing: -0.01em;
}

.modal-content {
  height: calc(100% - 64px);
  padding: 16px 20px 24px;
  overflow-y: auto;
}

.modal-content p {
  color: var(--text-2);
  line-height: 1.55;
}

.modal-content img {
  max-width: 100%;
  border-radius: var(--radius-sm);
  border: 1px solid var(--hairline);
  margin: 8px 0;
}

.close-modal {
  border: none;
  background: transparent;
  color: var(--text-2);
  min-width: 32px;
  min-height: 32px;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: var(--radius-sm);
  font-weight: 600;
}

.close-modal:hover {
  background: var(--surface-2);
  color: var(--text-1);
}

/* ─── Form rows ────────────────────────────────────────────────────── */

.content {
  display: flex;
  flex-direction: column;
  margin-left: 10px;
  margin-right: 10px;
}

.form-controls {
  width: 328px;
}

.form-row,
.form-controls {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

/* Class display:flex beats the UA [hidden] rule; keep source row gated. */
.form-row[hidden] {
  display: none !important;
}

label.form-input,
.form-label {
  font-family: var(--font-ui);
  font-weight: 500;
  color: var(--text-2);
  min-width: 240px;
}

.form-controls {
  line-height: 32px;
}

.form-input > input[type='checkbox'] {
  margin-left: 0;
  accent-color: var(--accent-primary);
}

.form-row#wordSelector {
  margin-top: 10px;
  margin-bottom: 10px;
}

.form-row#wordDisplay {
  margin-top: 10px;
  margin-bottom: 10px;
  display: grid;
  grid-gap: 6px;
  justify-content: space-around;
}

.play-letter {
  display: inline-block;
  width: 32px;
  height: 32px;
  line-height: 32px;
  text-align: center;
  text-transform: uppercase;
  vertical-align: middle;
  margin-left: 5px;
  border-radius: 4px;
  font-family: var(--font-ui);
  font-weight: 700;
  color: var(--wordle-text-on-tile);
}

.play-letter.correct {
  background-color: var(--wordle-green);
}

.play-letter.maybecorrect {
  background-color: var(--wordle-yellow);
  color: var(--wordle-text-on-tile-dark, #1a1a1a);
}

.play-letter.incorrect {
  background-color: var(--wordle-gray);
  color: var(--text-1);
}

.form-row#step1 {
  justify-content: space-around;
}

/* ─── Wordle clone (Play Wordle mode) ──────────────────────────────── */

#wordle-game {
  align-items: center;
  gap: 12px;
}

.wg-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  width: 100%;
  justify-content: space-between;
  min-height: 44px;
}

.wg-status {
  font-family: var(--font-ui);
  font-weight: 600;
  color: var(--text-2);
  text-align: right;
  flex: 1;
}

.wg-status-win {
  color: var(--wordle-green);
}

.wg-status-lose {
  color: var(--wordle-yellow);
}

.wg-board-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  width: 100%;
}

/* Floating toast — "Not in word list", "Need 5 letters", win banner. */
.wg-message {
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translate(-50%, -100%);
  background: var(--surface-2);
  color: var(--text-1);
  border: 1px solid var(--hairline-strong);
  border-radius: var(--radius);
  padding: 6px 12px;
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 13px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
  z-index: 2;
  box-shadow: var(--shadow-modal, 0 6px 18px rgba(0, 0, 0, 0.35));
}

.wg-message.visible {
  opacity: 1;
}

.wg-board {
  display: grid;
  grid-template-rows: repeat(6, 1fr);
  gap: 6px;
}

.wg-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}

.wg-tile {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 28px;
  text-transform: uppercase;
  color: var(--text-1);
  background-color: transparent;
  border: 2px solid var(--hairline-strong);
  border-radius: 6px;
  user-select: none;
  transition: transform 0.12s ease, background-color 0.2s ease, border-color 0.2s ease,
    color 0.2s ease;
}

.wg-tile.filled {
  border-color: var(--text-2);
  transform: scale(1.03);
}

.wg-tile.correct {
  background-color: var(--wordle-green);
  border-color: var(--wordle-green);
  color: var(--wordle-text-on-tile);
  animation: wg-flip 0.45s ease both;
}

.wg-tile.maybecorrect {
  background-color: var(--wordle-yellow);
  border-color: var(--wordle-yellow);
  color: var(--wordle-text-on-tile-dark);
  animation: wg-flip 0.45s ease both;
}

.wg-tile.incorrect {
  background-color: var(--wordle-gray);
  border-color: var(--wordle-gray);
  color: var(--wordle-text-on-tile);
  animation: wg-flip 0.45s ease both;
}

/* Stagger the reveal so it reads left-to-right. */
.wg-row .wg-tile:nth-child(1).correct,
.wg-row .wg-tile:nth-child(1).maybecorrect,
.wg-row .wg-tile:nth-child(1).incorrect {
  animation-delay: 0s;
}
.wg-row .wg-tile:nth-child(2).correct,
.wg-row .wg-tile:nth-child(2).maybecorrect,
.wg-row .wg-tile:nth-child(2).incorrect {
  animation-delay: 0.08s;
}
.wg-row .wg-tile:nth-child(3).correct,
.wg-row .wg-tile:nth-child(3).maybecorrect,
.wg-row .wg-tile:nth-child(3).incorrect {
  animation-delay: 0.16s;
}
.wg-row .wg-tile:nth-child(4).correct,
.wg-row .wg-tile:nth-child(4).maybecorrect,
.wg-row .wg-tile:nth-child(4).incorrect {
  animation-delay: 0.24s;
}
.wg-row .wg-tile:nth-child(5).correct,
.wg-row .wg-tile:nth-child(5).maybecorrect,
.wg-row .wg-tile:nth-child(5).incorrect {
  animation-delay: 0.32s;
}

@keyframes wg-flip {
  0% {
    transform: rotateX(0deg);
  }
  50% {
    transform: rotateX(90deg);
  }
  100% {
    transform: rotateX(0deg);
  }
}

.wg-shake {
  animation: wg-shake 0.4s ease;
}

@keyframes wg-shake {
  10%,
  90% {
    transform: translateX(-1px);
  }
  20%,
  80% {
    transform: translateX(2px);
  }
  30%,
  50%,
  70% {
    transform: translateX(-4px);
  }
  40%,
  60% {
    transform: translateX(4px);
  }
}

.wg-keyboard {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
  max-width: 500px;
  margin-top: 4px;
}

.wg-key-row {
  display: flex;
  justify-content: center;
  gap: 4px;
}

.wg-key {
  flex: 1 1 0;
  min-width: 0;
  min-height: 52px;
  padding: 0;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  background-color: var(--surface-2);
  color: var(--text-1);
  border: 1px solid var(--hairline-strong);
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.wg-key:hover {
  background-color: var(--surface-1);
}

.wg-key.wg-key-wide {
  flex: 1.7 1 0;
  font-size: 13px;
}

.wg-key.correct {
  background-color: var(--wordle-green);
  border-color: var(--wordle-green);
  color: var(--wordle-text-on-tile);
}

.wg-key.maybecorrect {
  background-color: var(--wordle-yellow);
  border-color: var(--wordle-yellow);
  color: var(--wordle-text-on-tile-dark);
}

.wg-key.incorrect {
  background-color: var(--wordle-gray);
  border-color: var(--wordle-gray);
  color: var(--wordle-text-on-tile);
}

@media screen and (max-width: 479px) {
  .wg-tile {
    width: 52px;
    height: 52px;
    font-size: 26px;
  }

  .wg-key {
    min-height: 48px;
    font-size: 13px;
  }

  .wg-key.wg-key-wide {
    font-size: 12px;
  }
}

@media screen and (max-width: 360px) {
  .wg-tile {
    width: 44px;
    height: 44px;
    font-size: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wg-tile,
  .wg-tile.correct,
  .wg-tile.maybecorrect,
  .wg-tile.incorrect,
  .wg-shake {
    animation: none !important;
    transition: none !important;
  }
}

input.wordle-date,
select {
  width: 190px;
  height: 44px;
  min-height: 44px;
  font-size: 16px; /* prevents iOS auto-zoom */
  font-family: var(--font-ui);
  font-weight: 500;
  background: var(--surface-2);
  color: var(--text-1);
  border: 1px solid var(--hairline-strong);
  border-radius: var(--radius);
  padding: 0 12px;
}

select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-2) 50%),
    linear-gradient(135deg, var(--text-2) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

input.wordle-date {
  color-scheme: dark;
}

input.wordle-date:focus,
select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-primary-soft);
}

/* ─── Accessibility helpers ────────────────────────────────────────── */

.screenreader-text {
  position: absolute;
  left: -999px;
  width: 1px;
  height: 1px;
  top: auto;
}
.screenreader-text:focus {
  color: var(--text-1);
  display: inline-block;
  height: auto;
  width: auto;
  position: static;
  margin: auto;
}

.solver-guide {
  width: min(100% - 24px, 760px);
  margin: 16px auto 32px;
  color: var(--text-2);
}

.solver-guide details {
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  background: var(--surface-1);
}

.solver-guide summary {
  padding: 14px 16px;
  color: var(--text-1);
  font-weight: 600;
  cursor: pointer;
}

.solver-guide-content {
  padding: 0 16px 16px;
  border-top: 1px solid var(--hairline);
  line-height: 1.6;
}

.solver-guide-content h2 {
  margin: 18px 0 4px;
  font-size: var(--text-body);
  color: var(--text-1);
}

.solver-guide-content p {
  margin: 8px 0;
}

.solver-guide-content nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-top: 18px;
}

#todays-wordle {
  margin: 4px 0 0;
  text-align: center;
  font-size: var(--text-caption);
  color: var(--text-3);
  font-weight: 500;
}

/* ─── Mobile ───────────────────────────────────────────────────────── */

@media screen and (max-width: 479px) {
  .form-row {
    flex-direction: column;
    align-items: stretch;
  }

  label.form-input,
  .form-label {
    min-width: unset;
    margin-bottom: 4px;
  }

  .form-input.form-grid {
    width: 100%;
  }

  /* min-width: 0 (not unset) is intentional. `unset` falls through to the
   * initial value of `min-width`, which is `auto`, and `min-width: auto`
   * on a grid item means "content's min-content size" — the tile would
   * refuse to shrink below the implicit width of `<input size="5">` on
   * iOS Safari and overflow the row. Forcing 0 lets `repeat(5, 1fr)`
   * actually distribute equally on narrow viewports. */
  .corrects input,
  .maybecorrects input {
    width: auto;
    min-width: 0;
  }

  input.incorrect,
  input.correct {
    width: 100%;
  }

  .form-controls {
    width: 100%;
  }

  .block-input-control,
  .fixed-input-control {
    width: 100%;
  }

  input.incorrect,
  input.correct {
    width: 100%;
    box-sizing: border-box;
  }

  #playResultsContainer {
    flex-direction: column;
  }

  #playResultsContainer > #playWordsResults,
  #playResultsContainer > #wordDisplay {
    min-width: unset;
    width: 100%;
  }
}

/* Play Wordle: share/related FAB sits over the on-screen keyboard on phones. */
@media screen and (max-width: 768px) {
  body.wordle-playing .related-projects-container {
    display: none !important;
  }
}
