* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: #111827;
  color: #f9fafb;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.container {
  width: 100%;
  max-width: 480px;
}

.screen { display: none; }
.screen.active { display: block; }

/* ── Landing ──────────────────────────────────── */
.landing-title {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 6px;
}

.landing-sub {
  text-align: center;
  color: #6b7280;
  margin-bottom: 40px;
  font-size: 1rem;
}

/* ── Progress dots ────────────────────────────── */
.progress-row {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #374151;
  flex-shrink: 0;
}
.dot-active  { background: #6366f1; }
.dot-green   { background: #22c55e; }
.dot-yellow  { background: #eab308; }
.dot-red     { background: #ef4444; }

/* ── Round counter ────────────────────────────── */
.round-counter {
  text-align: center;
  color: #6b7280;
  font-size: 0.875rem;
  margin-bottom: 10px;
}

/* ── Card ─────────────────────────────────────── */
.card {
  background: #1f2937;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 14px;
}

/* ── Category chip ────────────────────────────── */
.category-chip {
  display: inline-block;
  background: #374151;
  color: #9ca3af;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 14px;
}

/* ── Buttons ──────────────────────────────────── */
.btn {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
}
.btn:hover    { opacity: 0.88; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.btn-primary   { background: #6366f1; color: #fff; }
.btn-secondary { background: #374151; color: #f9fafb; }
.btn + .btn    { margin-top: 10px; }

/* ── Sport intro ──────────────────────────────── */
.intro-sport-label {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #6b7280;
  margin-bottom: 12px;
}

.intro-player-card {
  border-top: 1px solid #374151;
  padding-top: 12px;
  margin-bottom: 4px;
}

.intro-position-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6366f1;
  margin-bottom: 2px;
}

.intro-player-name {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.intro-stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0 12px;
}

.intro-stat-label {
  color: #9ca3af;
  font-size: 0.875rem;
}

.intro-stat-value {
  font-weight: 700;
  font-size: 1.1rem;
}

/* ── Guess screen ─────────────────────────────── */
.guess-sport-label {
  text-align: center;
  color: #6b7280;
  font-size: 0.875rem;
  margin-bottom: 6px;
}

.guess-player-context {
  text-align: center;
  font-size: 0.875rem;
  color: #9ca3af;
  margin-bottom: 16px;
}

.guess-cat-label {
  text-align: center;
  font-size: 1rem;
  font-weight: 600;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.guess-target-value {
  text-align: center;
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.guess-prompt {
  text-align: center;
  color: #6b7280;
  font-size: 0.85rem;
  margin-bottom: 18px;
}

/* ── Autocomplete ─────────────────────────────── */
.autocomplete-wrap {
  position: relative;
  margin-bottom: 10px;
}

.guess-input {
  width: 100%;
  background: #111827;
  border: 2px solid #374151;
  border-radius: 10px;
  color: #f9fafb;
  font-size: 1rem;
  padding: 12px 16px;
  outline: none;
}
.guess-input:focus { border-color: #6366f1; }
.guess-input::placeholder { color: #4b5563; }

.autocomplete-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #1f2937;
  border: 1px solid #374151;
  border-radius: 10px;
  overflow: hidden;
  z-index: 100;
  max-height: 240px;
  overflow-y: auto;
}

.ac-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  cursor: pointer;
  font-size: 0.9rem;
  border-bottom: 1px solid #374151;
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover { background: #374151; }

.ac-name { flex: 1; }
.ac-pos  { color: #6b7280; font-size: 0.78rem; flex-shrink: 0; }
.ac-val  { color: #6366f1; font-weight: 600; font-size: 0.85rem; flex-shrink: 0; }

.selected-player-display {
  background: #374151;
  border-radius: 8px;
  padding: 8px 14px;
  font-size: 0.875rem;
  color: #d1d5db;
  margin-bottom: 10px;
  display: none;
}

/* ── Score colors ─────────────────────────────── */
.score-green  { color: #22c55e; }
.score-yellow { color: #eab308; }
.score-red    { color: #ef4444; }

/* ── Category result ──────────────────────────── */
.result-score {
  font-size: 3rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 6px;
}

.result-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #374151;
}
.result-row:last-child { border-bottom: none; }
.result-label { color: #9ca3af; font-size: 0.875rem; flex-shrink: 0; }
.result-value { font-weight: 600; text-align: right; }
.result-sub   { color: #6b7280; font-size: 0.8rem; }

/* ── Sport summary / final ────────────────────── */
.final-sport-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  font-size: 0.875rem;
  color: #9ca3af;
  border-bottom: 1px solid #374151;
}

.final-title {
  text-align: center;
  color: #9ca3af;
  font-size: 0.875rem;
  margin-bottom: 4px;
}

.final-total-score {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 22px;
}

.rounds-list { margin-bottom: 4px; }

.round-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid #374151;
  font-size: 0.8rem;
}
.round-row:last-child { border-bottom: none; }
.round-emoji    { font-size: 1rem; flex-shrink: 0; }
.round-category { flex-shrink: 0; color: #9ca3af; white-space: nowrap; }
.round-guesses  { flex: 1; color: #6b7280; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.round-score    { font-weight: 600; flex-shrink: 0; }

.summary-player-header {
  font-size: 0.78rem;
  font-weight: 600;
  color: #6366f1;
  padding: 10px 0 2px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ── Error screen ─────────────────────────────── */
.error-text {
  text-align: center;
  color: #9ca3af;
  margin-bottom: 16px;
  font-size: 0.95rem;
}
