@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@300;400;600;700&family=Courier+Prime:wght@400;700&display=swap');

/* ═══════════════════════════════════════════════════
   RINGLET — scoped entirely under #ringlet-app
   CSS variables live on the wrapper, not on body,
   so they never clash with perkinsmaine.com globals.
   ═══════════════════════════════════════════════════ */

/* ═══ DARK THEME (default) ═══ */
#ringlet-app {
  --bg:#0e0e0f; --surface:#161618; --surface2:#1c1c1f;
  --ring-track:rgba(255,255,255,0.07);
  --gold:#e8c96a; --gold-dim:rgba(232,201,106,0.18); --gold-glow:rgba(232,201,106,0.55);
  --cream:#f5ede0; --text-dim:rgba(245,237,224,0.38); --text-mid:rgba(245,237,224,0.65);
  --success:#6ed8a0; --fail:#e86a6a; --reveal:#b888f0;
  --tile-bg:#ffffff; --tile-border:rgba(0,0,0,0.18); --tile-text:#1a1008;
  --modal-bg:rgba(20,20,22,0.97); --modal-border:rgba(232,201,106,0.14);
  --ctrl-bg:#1e1e21;
  --overlay-bg:rgba(14,14,15,0.92); --backdrop-bg:rgba(0,0,0,0.52);
  --center-word:#ffffff;
}

/* ═══ LIGHT THEME ═══ */
#ringlet-app.light {
  --bg:#f2ece0; --surface:#fffcf5; --surface2:#ede8dc;
  --ring-track:rgba(0,0,0,0.09);
  --gold:#b8890a; --gold-dim:rgba(184,137,10,0.12); --gold-glow:rgba(184,137,10,0.4);
  --cream:#2c2010; --text-dim:rgba(44,32,16,0.60); --text-mid:rgba(44,32,16,0.82);
  --success:#2a9158; --fail:#c0392b; --reveal:#7c3cb0;
  --tile-bg:#f2ece0; --tile-border:rgba(0,0,0,0.15); --tile-text:#1a1008;
  --modal-bg:rgba(242,236,224,0.98); --modal-border:rgba(184,137,10,0.18);
  --ctrl-bg:#ede8dc;
  --overlay-bg:rgba(220,210,195,0.94); --backdrop-bg:rgba(0,0,0,0.35);
  --center-word:#1a1008;
  /* Explicit values for Firefox on iOS which can miss var() overrides */
  background: #f2ece0;
  color: #2c2010;
}

/* ═══ WRAPPER — replaces body layout ═══ */
#ringlet-app {
  position: relative;
  width: 100%;
  /* No min-height needed — screens flow naturally */
  background: var(--bg);
  color: var(--cream);
  font-family: 'Courier Prime', monospace;
  display: flex;
  flex-direction: column;
  align-items: center;
  /* Let the page grow naturally — footer pushes down */
  overflow: visible;
  user-select: none;
  -webkit-user-select: none;
  transition: background 0.3s, color 0.3s;
  box-sizing: border-box;
}

/* Ambient radial glow — scoped to wrapper, not body */
#ringlet-app::before {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(232,201,106,0.055) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

/* ═══ SCREENS ═══
   Start/end screens are position:absolute (overlay the wrapper).
   The game screen uses position:relative so it actually pushes the
   wrapper — and therefore the footer — down.                        */
#ringlet-app .screen {
  /* Flow in-document — no absolute centering causing phantom top space */
  position: relative;
  display: none;
  flex-direction: column;
  align-items: center; justify-content: flex-start; gap: 20px;
  z-index: 10; padding: 40px 20px 32px;
  width: 100%;
}
#ringlet-app .screen.active {
  display: flex;
  pointer-events: all;
}

/* ──────────── START SCREEN ──────────── */
#ringlet-app .brand-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 3.125rem; font-weight: 300; letter-spacing: 0.35em;
  color: var(--gold); line-height: 1; text-align: center;
  /* Cormorant Garamond has tall line metrics; pull in the whitespace above the caps */
  margin-top: -0.25em;
  text-shadow: 0 0 50px var(--gold-glow), 0 0 100px rgba(232,201,106,0.08);
}
#ringlet-app .brand-sub  { font-size: 0.57rem; letter-spacing: 0.5em;  color: var(--text-dim); text-align: center; margin-top: 7px; }
#ringlet-app .dict-info  { font-size: 0.50rem; letter-spacing: 0.18em; color: var(--text-dim); text-align: center; margin-top: 5px; }

#ringlet-app .splash-ring {
  width: 220px; height: 220px; object-fit: contain;
  margin-bottom: -10px;
  filter: drop-shadow(0 0 32px rgba(232,201,106,0.35));
}
#ringlet-app .start-row  { display: flex; gap: 10px; align-items: center; margin-top: 4px; }
#ringlet-app .start-btn {
  font-family: 'Cormorant Garamond', serif; font-size: 1.05rem; font-weight: 600;
  letter-spacing: 0.3em; padding: 13px 40px;
  border: 1px solid var(--gold); background: transparent; color: var(--gold);
  border-radius: 8px; cursor: pointer; transition: all 0.2s; text-transform: uppercase;
}
#ringlet-app .start-btn:hover { background: var(--gold-dim); box-shadow: 0 0 22px var(--gold-glow); }

#ringlet-app .icon-btn {
  width: 44px; height: 44px; border-radius: 8px; border: 1px solid var(--tile-border);
  background: var(--ctrl-bg); color: var(--text-mid); font-size: 1.05rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all 0.18s; flex-shrink: 0;
}
#ringlet-app .icon-btn:hover { border-color: var(--gold); color: var(--gold); }

/* ──────────── GAME SCREEN ──────────── */
#ringlet-app #game-screen {
  gap: 0;
  justify-content: flex-start;
  padding: 16px 18px 24px;
}

/* Three-column arena: [buttons] [ring + submit] [words] */
#ringlet-app .game-arena {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: 100%;
  flex: 1;
  padding: 8px 0;
}

/* Left column — Clear / Back / Hint / Give Up */
#ringlet-app .game-side {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex: 0 0 33%;
  min-width: 0;
  padding: 0 8px;
  box-sizing: border-box;
}
#ringlet-app .game-side--right {
  align-items: flex-start;
  overflow: hidden;
}

/* Side-column section label */
#ringlet-app .side-label {
  font-size: 0.72rem;
  letter-spacing: 0.45em;
  color: var(--text-dim);
  text-transform: uppercase;
  margin-bottom: 2px;
  white-space: nowrap;
}

/* Ring column — the actual ring + submit button */
#ringlet-app .ring-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex: 0 0 34%;
  min-width: 0;
  box-sizing: border-box;
}

#ringlet-app .game-header {
  display: flex; align-items: flex-start; justify-content: space-between; width: 100%; gap: 8px;
}
#ringlet-app .game-header .spacer { width: 34px; flex-shrink: 0; }
#ringlet-app .game-title-wrap     { text-align: center; flex: 1; }
#ringlet-app .game-title {
  font-family: 'Cormorant Garamond', serif; font-size: 1.15rem; font-weight: 300;
  letter-spacing: 0.5em; color: var(--gold); opacity: 0.7;
}
#ringlet-app.light .game-title { opacity: 1; }
#ringlet-app .level-row       { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 5px; }
#ringlet-app .level-label     { font-size: 0.60rem; letter-spacing: 0.4em; color: var(--text-dim); text-transform: uppercase; }
#ringlet-app .level-dots      { display: flex; gap: 4px; }
#ringlet-app .level-dot       { width: 5px; height: 5px; border-radius: 50%; background: var(--tile-border); transition: all 0.35s; }
#ringlet-app .level-dot.filled{ background: var(--gold); box-shadow: 0 0 5px var(--gold-glow); }

#ringlet-app .icon-btn-sm {
  width: 34px; height: 34px; border-radius: 7px; border: 1px solid var(--tile-border);
  background: transparent; color: var(--text-dim); font-size: 0.95rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all 0.18s; flex-shrink: 0;
}
#ringlet-app .icon-btn-sm:hover { border-color: var(--gold); color: var(--gold); }

/* ──────────── THE GOLDEN RING ──────────── */
#ringlet-app .ring-area {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  background: var(--bg);
  /* No flex:1 — size is driven by the ring image itself */
}
#ringlet-app #ring-img { display: block; }

#ringlet-app .ring-track-circle { fill: none; stroke: var(--ring-track); stroke-width: 2; }

#ringlet-app .ring-progress {
  fill: none; stroke-width: 5; stroke-linecap: round;
  stroke-dasharray: 0 1000;
  opacity: 0; transition: stroke-dasharray 0.22s ease, opacity 0.2s;
}
#ringlet-app .ring-progress.active       { opacity: 1; }
#ringlet-app .ring-progress.reveal-color {
  stroke: var(--reveal) !important;
  filter: drop-shadow(0 0 5px rgba(184,136,240,0.5));
}

/* ──────────── LETTER TILES ──────────── */
#ringlet-app .letter-tiles { position: relative; }
#ringlet-app .letter-tile {
  position: absolute; border-radius: 50%;
  background: var(--tile-bg); border: 1.5px solid var(--tile-border);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-family: 'Cormorant Garamond', serif; font-weight: 600; color: var(--tile-text);
  z-index: 5; -webkit-tap-highlight-color: transparent;
  transition: background 0.14s, border-color 0.14s, box-shadow 0.14s,
              color 0.14s, opacity 0.2s,
              transform 0.18s cubic-bezier(0.34,1.56,0.64,1);
}
#ringlet-app .letter-tile:not(.used-seq):not(.selected):hover {
  border-color: rgba(232,201,106,0.5); background: rgba(232,201,106,0.07);
}
#ringlet-app .letter-tile.selected {
  background: var(--gold-dim); border-color: var(--gold); color: var(--gold);
  box-shadow: 0 0 16px rgba(232,201,106,0.30), inset 0 1px 0 rgba(255,255,255,0.1);
  transform: translate(-50%,-50%) scale(1.13) !important;
}
#ringlet-app .letter-tile.used-seq {
  background: var(--gold-dim); border-color: rgba(232,201,106,0.45);
  color: rgba(232,201,106,0.65); transform: translate(-50%,-50%) scale(0.95) !important;
  cursor: default;
}
#ringlet-app .letter-tile.used-seq:hover {
  border-color: rgba(232,201,106,0.45); color: rgba(232,201,106,0.65);
}
#ringlet-app .letter-tile.reveal-tile {
  background: rgba(184,136,240,0.13); border-color: var(--reveal); color: var(--reveal);
  box-shadow: 0 0 14px rgba(184,136,240,0.25);
}

@keyframes ringlet-tileIn {
  from { opacity: 0; transform: translate(-50%,-50%) scale(0) rotate(25deg); }
  to   { opacity: 1; transform: translate(-50%,-50%) scale(1) rotate(0deg); }
}
@keyframes ringlet-tileSuccess {
  0%   { transform: translate(-50%,-50%) scale(1); }
  35%  { transform: translate(-50%,-50%) scale(1.22); border-color: var(--success); background: rgba(110,216,160,0.2); color: var(--success); }
  100% { transform: translate(-50%,-50%) scale(0); opacity: 0; }
}
@keyframes ringlet-tileFail {
  0%,100% { transform: translate(-50%,-50%) translateX(0); }
  20%     { transform: translate(calc(-50% - 7px),-50%); }
  40%     { transform: translate(calc(-50% + 7px),-50%); }
  60%     { transform: translate(calc(-50% - 4px),-50%); }
  80%     { transform: translate(calc(-50% + 4px),-50%); }
}
#ringlet-app .letter-tile.anim-in      { animation: ringlet-tileIn      0.45s cubic-bezier(0.34,1.56,0.64,1) both; }
#ringlet-app .letter-tile.anim-success { animation: ringlet-tileSuccess  0.5s  ease forwards; }
#ringlet-app .letter-tile.anim-fail    { animation: ringlet-tileFail     0.38s ease; }

/* ──────────── CENTER DISPLAY ──────────── */
#ringlet-app .ring-center {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  text-align: center; pointer-events: none; z-index: 3;
  width: 52%; padding: 0 4px; overflow: visible;
}
#ringlet-app .center-word {
  font-family: 'Cormorant Garamond', serif; font-weight: 700; letter-spacing: 0.12em;
  color: var(--center-word); line-height: 1.1; transition: color 0.2s;
  white-space: nowrap; overflow: visible;
}
#ringlet-app .center-word.success { color: var(--success); }
#ringlet-app .center-word.fail    { color: var(--fail); }
#ringlet-app .center-word.empty   {
  color: var(--text-mid); font-style: italic; letter-spacing: 0.07em;
  font-size: 0.75rem; line-height: 1.5;
}
#ringlet-app .center-count { font-size: 0.60rem; letter-spacing: 0.3em; color: var(--text-dim); margin-top: 5px; text-transform: uppercase; white-space: nowrap; }

/* ──────────── WORD TRAIL — right column, vertical stack ──────────── */
#ringlet-app .word-trail {
  display: flex;
  flex-direction: column;
  gap: 5px;
  align-items: stretch;   /* chips fill full column width */
  width: 100%;
  padding: 0;
  overflow-y: auto;
  overflow-x: hidden;     /* never show horizontal scrollbar */
  max-height: 340px;
}
#ringlet-app .trail-chip {
  font-family: 'Cormorant Garamond', serif; font-size: 1.20rem; letter-spacing: 0.1em;
  padding: 3px 11px; border-radius: 20px;
  border: 1px solid rgba(110,216,160,0.28); color: var(--success); background: rgba(110,216,160,0.07);
  animation: ringlet-chipIn 0.35s cubic-bezier(0.34,1.56,0.64,1);
  white-space: nowrap;   /* keep each word on one line */
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
  max-width: 100%;       /* never wider than the column */
}
@keyframes ringlet-chipIn { from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* ──────────── CONTROLS — now in left column via .game-side ──────────── */
#ringlet-app .controls {
  /* Only holds the submit button now — centered under the ring */
  display: flex;
  gap: 10px;
  justify-content: center;
  align-items: center;
  min-height: 40px;
}
#ringlet-app .ctrl-btn {
  font-family: 'Courier Prime', monospace; font-size: 0.90rem; letter-spacing: 0.18em;
  padding: 9px 18px; border-radius: 6px; border: 1px solid var(--tile-border);
  background: var(--ctrl-bg); color: var(--text-mid); cursor: pointer;
  transition: all 0.18s; text-transform: uppercase;
}
#ringlet-app .ctrl-btn:hover  { border-color: rgba(255,255,255,0.22); color: var(--cream); }
#ringlet-app .ctrl-btn:active { transform: scale(0.96); }


/* ──────────── REVEAL OVERLAY ──────────── */
/* position:fixed is correct here — it should cover the full viewport on Give Up */
#ringlet-app #reveal-overlay {
  position: fixed; inset: 0; background: var(--overlay-bg);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  z-index: 1050; opacity: 0; pointer-events: none; transition: opacity 0.3s; backdrop-filter: blur(6px);
}
#ringlet-app #reveal-overlay.visible { opacity: 1; pointer-events: all; }
#ringlet-app .reveal-label {
  font-size: 0.57rem; letter-spacing: 0.45em; color: var(--text-dim); text-transform: uppercase;
}
#ringlet-app .reveal-word {
  font-family: 'Cormorant Garamond', serif; font-size: clamp(2.5rem,10vw,4rem);
  font-weight: 600; letter-spacing: 0.25em; color: var(--reveal);
  text-shadow: 0 0 40px rgba(184,136,240,0.4);
}
#ringlet-app .reveal-sub  { font-size: 0.60rem; letter-spacing: 0.2em; color: var(--text-dim); text-align: center; line-height: 2; }
#ringlet-app .reveal-btn {
  font-family: 'Cormorant Garamond', serif; font-size: 0.92rem; font-weight: 600;
  letter-spacing: 0.25em; padding: 11px 34px;
  border: 1px solid var(--reveal); background: rgba(184,136,240,0.1); color: var(--reveal);
  border-radius: 8px; cursor: pointer; transition: all 0.2s; text-transform: uppercase;
}
#ringlet-app .reveal-btn:hover { background: rgba(184,136,240,0.18); }

/* ──────────── SETTINGS MODAL ──────────── */
/* Also position:fixed — should overlay the full page */
#ringlet-app .modal-backdrop {
  position: fixed; inset: 0; background: var(--backdrop-bg);
  z-index: 1060; display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.22s; backdrop-filter: blur(5px);
}
#ringlet-app .modal-backdrop.open { opacity: 1; pointer-events: all; }
#ringlet-app .modal {
  background: var(--modal-bg); border: 1px solid var(--modal-border); border-radius: 14px;
  padding: 26px 26px 22px; width: 100%; max-width: 310px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.55);
  transform: translateY(14px) scale(0.97);
  transition: transform 0.28s cubic-bezier(0.34,1.56,0.64,1);
}
#ringlet-app .modal-backdrop.open .modal { transform: translateY(0) scale(1); }
#ringlet-app .modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
#ringlet-app .modal-title {
  font-family: 'Cormorant Garamond', serif; font-size: 1.3rem; font-weight: 600;
  letter-spacing: 0.22em; color: var(--gold);
}
#ringlet-app .modal-x {
  background: none; border: none; color: var(--text-dim); font-size: 1rem;
  cursor: pointer; padding: 4px 6px; line-height: 1; transition: color 0.15s; border-radius: 4px;
}
#ringlet-app .modal-x:hover    { color: var(--cream); }
#ringlet-app .modal-section    { margin-bottom: 18px; }
#ringlet-app .modal-section:last-child { margin-bottom: 0; }
#ringlet-app .modal-section-label {
  font-size: 0.49rem; letter-spacing: 0.45em; color: var(--text-dim);
  text-transform: uppercase; margin-bottom: 9px;
}

#ringlet-app .seg {
  display: flex; background: var(--surface2); border-radius: 8px; padding: 3px; gap: 3px;
  border: 1px solid var(--tile-border);
}
#ringlet-app .seg-opt {
  flex: 1; text-align: center; padding: 9px 6px; border-radius: 6px;
  cursor: pointer; transition: all 0.17s; border: 1px solid transparent;
  font-family: 'Courier Prime', monospace;
}
#ringlet-app .seg-opt-name { font-size: 0.62rem; letter-spacing: 0.15em; color: var(--text-mid); text-transform: uppercase; }
#ringlet-app .seg-opt-desc { font-size: 0.49rem; color: var(--text-dim); margin-top: 3px; letter-spacing: 0.04em; line-height: 1.4; }
#ringlet-app .seg-opt:hover .seg-opt-name { color: var(--cream); }
#ringlet-app .seg-opt.on                  { background: var(--gold-dim); border-color: var(--gold); }
#ringlet-app .seg-opt.on .seg-opt-name    { color: var(--gold); }
#ringlet-app .seg-opt.on .seg-opt-desc    { color: rgba(232,201,106,0.48); }

/* ──────────── END SCREEN ──────────── */
#ringlet-app .end-title {
  font-family: 'Cormorant Garamond', serif; font-size: clamp(2.2rem,9vw,4rem);
  font-weight: 300; letter-spacing: 0.3em; color: var(--gold);
  text-shadow: 0 0 40px var(--gold-glow); text-align: center;
}
#ringlet-app .end-card {
  background: var(--surface); border: 1px solid rgba(255,255,255,0.07); border-radius: 12px;
  padding: 20px 28px; text-align: center; min-width: 220px;
}
#ringlet-app .end-stat-label  { font-size: 0.68rem; letter-spacing: 0.4em; color: var(--text-mid); text-transform: uppercase; margin-bottom: 4px; }
#ringlet-app .end-score-label  { font-size: 0.68rem; letter-spacing: 0.4em; color: var(--text-mid); text-transform: uppercase; margin-top: 2px; margin-bottom: 10px; }
#ringlet-app .end-hints        { font-size: 0.68rem; letter-spacing: 0.25em; color: var(--text-mid); text-transform: uppercase; margin-top: 14px; font-style: italic; }
#ringlet-app .end-stat-val    { font-family: 'Cormorant Garamond', serif; font-size: 2.6rem; font-weight: 600; color: var(--cream); line-height: 1; }
#ringlet-app .end-best-word   { font-family: 'Cormorant Garamond', serif; font-size: 1.6rem; font-weight: 600; color: var(--gold); letter-spacing: 0.2em; margin-top: 10px; }
#ringlet-app .end-word-label  { font-size: 0.68rem; letter-spacing: 0.4em; color: var(--text-mid); text-transform: uppercase; margin-top: 3px; }
#ringlet-app .end-trail       { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; max-width: 320px; }
#ringlet-app .end-trail-chip {
  font-family: 'Cormorant Garamond', serif; font-size: 0.75rem; letter-spacing: 0.1em;
  padding: 2px 9px; border-radius: 20px;
  border: 1px solid rgba(110,216,160,0.2); color: var(--success); opacity: 0.7;
}
#ringlet-app .play-again-btn {
  font-family: 'Cormorant Garamond', serif; font-size: 1rem; font-weight: 600;
  letter-spacing: 0.28em; padding: 12px 36px;
  border: 1px solid var(--gold); background: transparent; color: var(--gold);
  border-radius: 8px; cursor: pointer; transition: all 0.2s; text-transform: uppercase;
}
#ringlet-app .play-again-btn:hover { background: var(--gold-dim); box-shadow: 0 0 22px var(--gold-glow); }

/* ──────────── HINT BUTTON ──────────── */
#ringlet-app .hint-btn {
  font-family: 'Courier Prime', monospace; font-size: 0.90rem; letter-spacing: 0.18em;
  padding: 9px 18px; border-radius: 6px;
  border: 1px solid var(--gold); background: transparent; color: var(--gold);
  cursor: pointer; transition: all 0.18s; text-transform: uppercase;
  opacity: 0.75;
}
#ringlet-app .hint-btn:hover  { background: var(--gold-dim); opacity: 1; }
#ringlet-app .hint-btn:active { transform: scale(0.96); }

/* ═══════════════════════════════════════════════════
   MOBILE — portrait phones (≤ 600px)
   Stack: buttons row above ring, words row below ring.
   ═══════════════════════════════════════════════════ */
@media (max-width: 600px) {

  #ringlet-app #game-screen {
    padding: 10px 10px 16px;
  }

  /* Switch arena from horizontal three-col to vertical single-col */
  #ringlet-app .game-arena {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  /* Buttons go horizontal above the ring */
  #ringlet-app .game-side--left {
    flex-direction: row;
    width: 100%;
    justify-content: center;
    gap: 8px;
    padding: 0;
    order: -1; /* above ring */
  }

  /* Solved words go horizontal below the ring, wrapping */
  #ringlet-app .game-side--right {
    flex-direction: column;
    width: 100%;
    align-items: center;
    padding: 0;
    order: 1; /* below ring */
  }

  #ringlet-app .game-side--right .word-trail {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    max-height: none;
    gap: 5px;
  }

  /* Ring column fills available width */
  #ringlet-app .ring-column {
    width: 100%;
    order: 0;
  }

  /* Side columns no longer need a fixed width */
  #ringlet-app .game-side {
    width: auto;
  }

  /* Tighten button padding on small screens */
  #ringlet-app .ctrl-btn {
    padding: 8px 12px;
    font-size: 0.80rem;
  }
  #ringlet-app .hint-btn {
    padding: 8px 12px;
    font-size: 0.80rem;
  }

  /* Shrink game title slightly */
  #ringlet-app .game-title {
    font-size: 1rem;
  }
}
