/* "Chi sono?" page: dark neon theme, self-contained (style.css would restyle h1 and body). */
:root {
    --cs-bg: #0e1020;
    --cs-surface: #1a1d38;
    --cs-text: #f2f4ff;
    --cs-muted: #b9bedc;
    --cs-neon: #5ef2d0;
    --cs-gold: #ffd54a;
    --cs-correct: #1f9d63;
    --cs-pass: #b8493c;
    --cs-radius: 14px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

.cs-body {
    min-height: 100vh;
    min-height: 100dvh;
    background: radial-gradient(circle at 20% 0%, #26204f 0%, var(--cs-bg) 55%);
    color: var(--cs-text);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.cs-main { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }

.cs-screen { width: 100%; max-width: 640px; margin: 0 auto; padding: 24px 16px; display: flex; flex-direction: column; gap: 14px; }
.cs-screen--center { flex: 1; justify-content: center; align-items: center; text-align: center; }

h1, h2 { color: var(--cs-neon); text-shadow: 0 0 14px rgba(94, 242, 208, 0.5); overflow-wrap: anywhere; }
h1 { font-size: clamp(2rem, 8vw, 3rem); text-align: center; }
h3 { font-size: 1.1rem; margin-top: 8px; }

.cs-lead { font-size: 1.15rem; text-align: center; }
.cs-note { color: var(--cs-muted); font-size: 0.95rem; }
.cs-warn { color: var(--cs-gold); }

.cs-fieldset { border: 1px solid #3a3f70; border-radius: var(--cs-radius); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
.cs-fieldset legend { padding: 0 8px; color: var(--cs-neon); }

.cs-choice { display: flex; align-items: center; gap: 12px; min-height: 44px; cursor: pointer; }
.cs-choice input { width: 24px; height: 24px; accent-color: var(--cs-neon); flex-shrink: 0; }

.cs-btn {
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 48px; padding: 10px 22px;
    background: var(--cs-surface); color: var(--cs-text);
    border: 1px solid #4a5090; border-radius: 10px;
    font: inherit; font-size: 1.05rem; text-decoration: none; cursor: pointer;
}
.cs-btn:hover { border-color: var(--cs-neon); }
.cs-btn--primary { background: var(--cs-neon); color: #08121a; border-color: var(--cs-neon); font-weight: 700; }
.cs-links { display: flex; flex-wrap: wrap; gap: 10px; }
.cs-links .cs-btn { flex: 1 1 140px; }

.cs-btn:focus-visible, .cs-action:focus-visible, .cs-choice input:focus-visible {
    outline: 3px solid var(--cs-gold);
    outline-offset: 3px;
}

.cs-count { font-size: clamp(6rem, 40vmin, 14rem); font-weight: 800; color: var(--cs-neon); line-height: 1; }

.cs-play { flex: 1; display: flex; flex-direction: column; padding: 8px 8px 8px; gap: 8px; }
.cs-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.cs-timer { font-size: 1.6rem; font-weight: 700; font-variant-numeric: tabular-nums; }

.cs-card {
    flex: 1; display: flex; align-items: center; justify-content: center;
    padding: 16px; text-align: center;
    background: var(--cs-surface); border: 2px solid var(--cs-neon); border-radius: var(--cs-radius);
    font-size: clamp(2.2rem, 13vmin, 8rem); font-weight: 800; line-height: 1.1;
    overflow-wrap: anywhere; hyphens: auto;
}
.cs-card.is-correct { border-color: var(--cs-correct); box-shadow: 0 0 30px var(--cs-correct); }
.cs-card.is-pass { border-color: var(--cs-pass); box-shadow: 0 0 30px var(--cs-pass); }

.cs-actions { display: flex; gap: 8px; min-height: 30vh; }
.cs-action {
    flex: 1; min-height: 96px; border: 0; border-radius: var(--cs-radius);
    color: #fff; font: inherit; font-size: clamp(1.4rem, 6vmin, 2.4rem); font-weight: 800; cursor: pointer;
}
.cs-action--correct { background: var(--cs-correct); }
.cs-action--pass { background: var(--cs-pass); }
.cs-action:active { transform: scale(0.98); }

.cs-score { font-size: 1.4rem; font-weight: 700; }
.cs-words { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.cs-words li { background: var(--cs-surface); border-radius: 8px; padding: 6px 12px; overflow-wrap: anywhere; }

.cs-modal { display: none; position: fixed; inset: 0; z-index: 400; overflow-y: auto; background: rgba(5, 6, 16, 0.92); }
.cs-modal-content {
    margin: 40px auto; width: 90%; max-width: 560px; padding: 24px;
    background: var(--cs-surface); border-radius: var(--cs-radius); display: flex; flex-direction: column; gap: 14px;
}
.cs-steps { padding-left: 1.3rem; display: flex; flex-direction: column; gap: 10px; line-height: 1.45; }

.cs-sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@media (orientation: landscape) and (max-height: 520px) {
    .cs-actions { min-height: 24vh; }
    .cs-action { min-height: 64px; }
}

@media (prefers-reduced-motion: reduce) {
    .cs-action:active { transform: none; }
}

/* The start button leads the setup and names the defaults, so a first game is one tap away. */
.cs-btn--start { width: 100%; min-height: 56px; margin-bottom: 4px; font-size: 1.15rem; }
