/* ── LETTER MATCH ── */
#letterMatchScreen{display:none;flex-direction:column;align-items:center;gap:20px;padding:64px 18px 80px;max-width:520px;width:100%;position:relative;z-index:1;height:100vh;height:100dvh;overflow:hidden;justify-content:center;background:url('../Images/GameAssets/LetterMatch/bg.webp') center/cover no-repeat;}

/* Jumbled letter board — every tile visible at once (no hidden/flip memory
   mechanic), tap two that share a letter to clear them. */
.lm-board{display:grid;grid-template-columns:repeat(var(--lm-cols,4),1fr);grid-auto-rows:1fr;gap:12px;width:100%;flex:1;max-height:520px;}
.lm-tile{
  background:rgba(255,255,255,.75);border:3px solid rgba(255,255,255,.65);border-radius:18px;
  display:flex;align-items:center;justify-content:center;
  font-family:'Baloo 2',cursive;font-weight:900;font-size:clamp(1.8rem,7vw,2.6rem);line-height:1;
  cursor:pointer;box-shadow:0 4px 14px rgba(0,0,0,.08);backdrop-filter:blur(6px);
  transition:transform .15s,background .2s,border-color .2s,opacity .3s;
  -webkit-tap-highlight-color:transparent;user-select:none;
}
.lm-tile.selected{border-color:#4d96ff;background:rgba(77,150,255,.18);transform:scale(1.06);box-shadow:0 0 14px rgba(77,150,255,.45);}
.lm-tile.matched{opacity:0;transform:scale(.5);pointer-events:none;}
.lm-tile.matchShake{animation:matchShake .4s ease;}

/* Capital I in a serif face reads with top/bottom serifs — distinct from a
   bare lowercase l stroke, which Baloo 2 (and most sans fonts) render
   identically to capital I. Lowercase i keeps its dot and stays in Baloo 2. */
.lm-tile-serif-i{font-family:Georgia,'Times New Roman',serif;font-weight:700;}

/* Idle nudge — after a few seconds with no taps, pulse a pair so it's
   obvious what to do next. Golden glow (not the blue .selected ring) so it
   never reads as an actual pick. */
.lm-tile.lm-hint{animation:lmHintPulse 1.3s ease-in-out;}
@keyframes lmHintPulse{
  0%,100%{transform:scale(1);box-shadow:0 4px 14px rgba(0,0,0,.08);}
  50%{transform:scale(1.08);box-shadow:0 0 18px rgba(255,196,64,.75);}
}
