/* Les liens — a 4x4 word grid; select four, submit to lock a group. Solved
   groups rise into coloured bands. Four colour tiers, easiest to trickiest.
   On the design-system paper. */

.ll-root { padding: clamp(6px, 2vw, 16px); max-inline-size: 480px; margin: 0 auto; color: var(--color-text); display: flex; flex-direction: column; gap: var(--space-3); }

.ll-solved { display: flex; flex-direction: column; gap: 6px; }
.ll-band { border-radius: var(--radius-sm); padding: 8px 10px; text-align: center; color: #2a2622; }
.ll-band-name { display: block; font-family: var(--font-heading, var(--font-body)); font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; font-size: 13px; }
.ll-band-words { display: block; font-family: var(--font-body); font-size: 13px; text-transform: uppercase; letter-spacing: 0.02em; }
.ll-band.missed { opacity: 0.85; outline: 1px dashed rgba(0,0,0,0.25); }

/* four tiers, easiest to trickiest: muted tones tuned to sit on the warm paper
   palette rather than bright NYT pastels (straw, sage, slate, mauve). */
.g0 { background: #d9bf72; }
.g1 { background: #a1ac74; }
.g2 { background: #8ea6b4; }
.g3 { background: #b298a6; }

.ll-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ll-tile {
  aspect-ratio: 1.35; display: flex; align-items: center; justify-content: center; text-align: center;
  border: none; border-radius: var(--radius-sm); background: var(--color-neutral-200); color: var(--color-text);
  font-family: var(--font-body); font-weight: 600; font-size: clamp(11px, 2.9vw, 15px); text-transform: uppercase; letter-spacing: 0.01em;
  cursor: pointer; padding: 2px; overflow: hidden; word-break: break-word; line-height: 1.05;
}
.ll-tile:hover { background: var(--color-neutral-300); }
.ll-tile.sel { background: var(--color-neutral-700); color: var(--color-neutral-100); }

.ll-lives { display: flex; align-items: center; gap: 6px; justify-content: center; min-block-size: 20px; }
.ll-lives-label { font-family: var(--font-body); font-size: 13px; color: var(--color-neutral-600); margin-inline-end: 4px; }
.ll-dot { inline-size: 12px; block-size: 12px; border-radius: 50%; background: var(--color-neutral-600); }
.ll-dot.used { background: var(--color-neutral-300); }

.ll-msg { min-block-size: 20px; text-align: center; font-family: var(--font-body); font-size: 14px; color: var(--color-neutral-600); }
.ll-msg.good { color: var(--color-accent-700, #4a6a2a); font-weight: 600; }

.ll-actions { display: flex; gap: 8px; justify-content: center; }
.ll-btn { padding: 9px 16px; border: 1px solid var(--color-neutral-400); border-radius: 999px; background: var(--color-neutral-100); color: var(--color-text); font-family: var(--font-body); font-size: 14px; cursor: pointer; }
.ll-btn:hover:not(:disabled) { background: var(--color-neutral-200); }
.ll-btn:disabled { opacity: 0.5; cursor: default; }
.ll-btn--go { background: var(--color-accent); color: var(--color-accent-900); border-color: transparent; font-weight: 600; }
.ll-btn--go:hover:not(:disabled) { background: var(--color-accent-400); }

/* colour-blind: add a tier glyph to each band */
.ll-root.cb .g0 .ll-band-name::before { content: "1 · "; }
.ll-root.cb .g1 .ll-band-name::before { content: "2 · "; }
.ll-root.cb .g2 .ll-band-name::before { content: "3 · "; }
.ll-root.cb .g3 .ll-band-name::before { content: "4 · "; }

/* Dark page */
.ll-root.mode-dark { color: #ece8e2; }
.ll-root.mode-dark .ll-tile { background: #322f2a; color: #ece8e2; }
.ll-root.mode-dark .ll-tile:hover { background: #403c38; }
.ll-root.mode-dark .ll-tile.sel { background: #ece8e2; color: #1a1a17; }
.ll-root.mode-dark .ll-lives-label, .ll-root.mode-dark .ll-msg { color: #9a948c; }
.ll-root.mode-dark .ll-dot { background: #cfc9c0; }
.ll-root.mode-dark .ll-dot.used { background: #403c38; }
.ll-root.mode-dark .ll-btn { background: #262421; color: #ece8e2; border-color: #403c38; }
.ll-root.mode-dark .ll-btn:hover:not(:disabled) { background: #322f2a; }
.ll-root.mode-dark .ll-btn--go { background: var(--color-accent-500); color: #1a1a17; }
.ll-root.mode-dark .ll-msg.good { color: var(--color-accent-400); }
