:root {
  --green: #58cc02;
  --green-dark: #46a302;
  --blue: #1cb0f6;
  --orange: #ff9600;
  --red: #ff4b4b;
  --purple: #ce82ff;
  --gold: #ffc800;
  --bg: #131f24;
  --surface: #1a2c35;
  --surface2: #233845;
  --border: #2d4a58;
  --text: #ffffff;
  --muted: #8ba4b2;
  --font: "Nunito", system-ui, sans-serif;
  --radius: 16px;
  --radius-sm: 12px;
}

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 70px;
}

#app { max-width: 480px; margin: 0 auto; padding: 0 16px 32px; }

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

/* Bottom Nav */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  display: flex;
  background: var(--surface);
  border-top: 2px solid var(--border);
  z-index: 50;
  padding: 6px 0 env(safe-area-inset-bottom, 6px);
}
.nav-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  background: none;
  border: none;
  color: var(--muted);
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  padding: 6px;
  cursor: pointer;
}
.nav-btn .nav-icon { font-size: 20px; }
.nav-btn.active { color: var(--green); }

/* Page Header */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0 16px;
}
.page-header h1 { font-size: 22px; font-weight: 800; }
.page-header h2 { font-size: 20px; font-weight: 800; }


.back-btn {
  background: none;
  border: none;
  color: var(--blue);
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

/* ─── Task Cards ─── */
.tasks { display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; }

.task-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.15s;
}
.task-card.done { border-color: var(--green); }

.task-check {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 13px;
  transition: all 0.2s;
}
.task-card.done .task-check {
  background: var(--green);
  border-color: var(--green);
}
.task-card.done .task-check::after { content: "✓"; color: #fff; font-weight: 800; }

.task-info { flex: 1; }
.task-info h3 { font-size: 14px; font-weight: 700; }
.task-info p { font-size: 12px; color: var(--muted); margin-top: 2px; }

.task-start {
  padding: 8px 16px;
  background: var(--green);
  border: none;
  border-radius: 10px;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.1s;
  white-space: nowrap;
}
.task-start:active { transform: scale(0.95); }
.task-card.done .task-start { background: var(--surface2); color: var(--muted); }

/* ─── Calendar ─── */
.calendar-section {
  background: var(--surface);
  border-radius: var(--radius);
  border: 2px solid var(--border);
  padding: 16px;
}

.cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}
.cal-title { font-size: 16px; font-weight: 800; }
.cal-nav {
  background: none;
  border: none;
  color: var(--blue);
  font-size: 24px;
  cursor: pointer;
  padding: 4px 12px;
}

.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
  margin-bottom: 8px;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-day {
  position: relative;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
}
.cal-day.today {
  color: var(--text);
  background: var(--surface2);
}
.cal-day.has-check {
  color: var(--text);
}
.cal-day.empty { visibility: hidden; }

/* Apple ring style */
.cal-day .ring {
  position: absolute;
  inset: 2px;
  border-radius: 50%;
}
.cal-day .ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.cal-day .ring .ring-track {
  fill: none;
  stroke: var(--surface2);
  stroke-width: 3;
}
.cal-day .ring .ring-fill {
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.3s;
}
.cal-day .ring .ring-fill.green { stroke: var(--green); }
.cal-day .ring .ring-fill.blue { stroke: var(--blue); }
.cal-day .ring .ring-fill.orange { stroke: var(--orange); }
.cal-day .ring .ring-fill.red { stroke: var(--red); }
.cal-day .ring .ring-fill.partial { opacity: 0.5; }

.cal-day.all-done .ring .ring-fill { opacity: 1; }

/* ─── Timer Page ─── */
.timer-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
}
.timer-back { position: absolute; top: 20px; left: 16px; }
.timer-title { font-size: 20px; font-weight: 800; margin-bottom: 40px; color: var(--muted); }

.timer-circle-wrap {
  position: relative;
  width: 240px;
  height: 240px;
  margin-bottom: 32px;
}
.timer-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.timer-track { fill: none; stroke: var(--surface2); stroke-width: 10; }
.timer-arc {
  fill: none;
  stroke: var(--blue);
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 553;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1s linear;
}
.timer-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.timer-time { font-size: 48px; font-weight: 800; }
.timer-status { font-size: 14px; color: var(--muted); margin-top: 4px; }

.timer-custom { margin-bottom: 24px; text-align: center; }
.timer-custom label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.time-input {
  width: 100px;
  padding: 10px;
  font-size: 20px;
  font-weight: 800;
  text-align: center;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-family: inherit;
}
.time-input:focus { outline: none; border-color: var(--blue); }

.timer-actions { display: flex; gap: 12px; }
.btn-big {
  padding: 16px 40px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}
.btn-start { background: var(--green); color: #fff; }
.btn-pause { background: var(--orange); color: #fff; }
.btn-done { background: var(--blue); color: #fff; }

.hidden { display: none !important; }

/* ─── List Grid ─── */
.list-grid { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; padding-bottom: 80px; }

.list-item {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s;
}
.list-item:hover { border-color: var(--blue); }
.list-item.completed { border-color: var(--green); }
.list-item.current { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(255,200,0,0.15); }
.list-item.in-progress { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(255,150,0,0.15); }
.list-item.in-progress .list-num { background: var(--orange); color: #fff; }

.list-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  margin-right: 14px;
  flex-shrink: 0;
}
.list-item.completed .list-num { background: var(--green); }
.list-item.current .list-num { background: var(--gold); color: #000; }

.list-info { flex: 1; }
.list-info h4 { font-size: 14px; font-weight: 700; }
.list-info p { font-size: 12px; color: var(--muted); }

.list-score { font-size: 13px; font-weight: 700; color: var(--green); }
.list-score.resume { color: var(--orange); }

/* ─── Game Screen ─── */
.game-screen {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 100;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.game-screen.hidden { display: none; }

.game-topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  max-width: 480px;
  margin: 0 auto;
  width: 100%;
}
.game-close {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 20px;
  cursor: pointer;
}
.game-progress-bar {
  flex: 1;
  height: 12px;
  background: var(--surface2);
  border-radius: 6px;
  overflow: hidden;
}
.game-progress-fill {
  height: 100%;
  background: var(--green);
  border-radius: 6px;
  transition: width 0.3s ease;
  width: 0%;
}
.game-hearts { font-size: 16px; letter-spacing: 2px; }

.game-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  max-width: 480px;
  margin: 0 auto;
  width: 100%;
  position: relative;
}

.game-prompt { font-size: 14px; color: var(--muted); margin-bottom: 16px; font-weight: 600; }
.game-word { font-size: 36px; font-weight: 800; margin-bottom: 8px; text-align: center; }
.game-def-prompt { font-size: 20px; font-weight: 700; margin-bottom: 8px; text-align: center; line-height: 1.4; }
.game-notes { font-size: 12px; color: var(--muted); margin-bottom: 24px; text-align: center; max-width: 320px; line-height: 1.5; }

.game-options { width: 100%; display: flex; flex-direction: column; gap: 10px; }
.game-option {
  width: 100%;
  padding: 16px 20px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: all 0.15s;
}
.game-option:active { transform: scale(0.98); }
.game-option.correct { background: rgba(88,204,2,0.15); border-color: var(--green); color: var(--green); }
.game-option.wrong { background: rgba(255,75,75,0.15); border-color: var(--red); color: var(--red); }

.game-input-wrap { width: 100%; margin-bottom: 16px; }
.game-input {
  width: 100%;
  padding: 16px;
  font-size: 20px;
  font-family: inherit;
  font-weight: 700;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  text-align: center;
  outline: none;
}
.game-input:focus { border-color: var(--blue); }
.game-input.correct { border-color: var(--green); }
.game-input.wrong { border-color: var(--red); }

.game-submit {
  width: 100%;
  padding: 16px;
  background: var(--green);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}

.game-feedback {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px 24px;
  font-weight: 700;
  font-size: 16px;
  border-radius: 16px 16px 0 0;
}
.game-feedback.correct { background: rgba(88,204,2,0.15); color: var(--green); }
.game-feedback.wrong { background: rgba(255,75,75,0.15); color: var(--red); }
.game-feedback .answer { font-size: 13px; margin-top: 4px; opacity: 0.8; }


.game-tf-btns { display: flex; gap: 16px; width: 100%; }
.game-tf-btn {
  flex: 1;
  padding: 20px;
  border-radius: var(--radius);
  border: 3px solid var(--border);
  background: var(--surface);
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
  font-family: inherit;
  color: var(--text);
}
.game-tf-btn.correct { border-color: var(--green); background: rgba(88,204,2,0.15); }
.game-tf-btn.wrong { border-color: var(--red); background: rgba(255,75,75,0.15); }

.game-complete { text-align: center; padding: 32px; }
.game-complete-icon { font-size: 64px; margin-bottom: 16px; }
.game-complete h2 { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.game-complete .score-text { font-size: 18px; color: var(--green); font-weight: 700; margin-bottom: 4px; }
.game-complete .xp-text { color: var(--blue); font-weight: 700; margin-bottom: 24px; }
.game-complete-btn {
  padding: 16px 48px;
  background: var(--green);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}

/* Speak Button */
.game-word-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.speak-btn {
  background: var(--surface2);
  border: 2px solid var(--border);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 18px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  flex-shrink: 0;
}
.speak-btn:hover { border-color: var(--blue); transform: scale(1.1); }
.speak-btn:active { transform: scale(0.95); }

.speak-btn-inline {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  color: var(--blue);
  font-family: inherit;
  font-weight: 700;
}

.game-option .speak-btn {
  width: 28px;
  height: 28px;
  font-size: 14px;
  float: right;
  margin: -4px -4px -4px 8px;
}

/* ─── Wrong Word Page ─── */
.wrong-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}
.wrong-tab {
  padding: 8px 16px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 20px;
  color: var(--muted);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.wrong-tab.active { border-color: var(--orange); color: var(--orange); }

.wrong-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.wrong-word-entry {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.wwe-word { font-weight: 800; font-size: 14px; min-width: 100px; }
.wwe-def { flex: 1; font-size: 12px; color: var(--muted); line-height: 1.4; }
.wwe-count {
  font-size: 11px;
  color: var(--red);
  background: rgba(255,75,75,0.1);
  padding: 3px 8px;
  border-radius: 10px;
  font-weight: 700;
  white-space: nowrap;
}
.wwe-speak {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
}

.btn-retry-all {
  width: 100%;
  padding: 14px;
  background: var(--orange);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.wrong-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--muted);
  font-size: 14px;
}

/* ─── Report Page ─── */
.share-btn {
  background: var(--blue);
  border: none;
  color: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 10px;
  cursor: pointer;
}

.report-share-card { margin-bottom: 16px; }
.share-card-inner {
  background: linear-gradient(135deg, #1a2c35, #1e3a4a);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.share-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.share-logo { font-size: 28px; }
.share-header h3 { font-size: 16px; font-weight: 800; }
.share-header p { font-size: 12px; color: var(--muted); margin-top: 2px; }

.share-body { margin-bottom: 16px; }
.share-body .sb-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 14px;
}
.share-body .sb-icon { font-size: 18px; width: 28px; text-align: center; }
.share-body .sb-label { flex: 1; font-weight: 600; }
.share-body .sb-value { color: var(--blue); font-weight: 800; }
.share-body .sb-acc { color: var(--green); font-weight: 800; font-size: 13px; margin-left: 8px; }
.share-body .sb-section { border-top: 1px solid var(--border); margin-top: 4px; padding-top: 10px; }
.share-body .sb-sub { padding-left: 36px; font-size: 13px; }

.share-footer {
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.share-preview { text-align: center; margin-bottom: 20px; }
.share-tip { font-size: 13px; color: var(--green); margin-bottom: 12px; font-weight: 700; }
.share-img {
  width: 100%;
  max-width: 400px;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.4);
}

.report-history h3 { font-size: 15px; margin-bottom: 12px; }

.report-day-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 8px;
}
.report-day-card .rdc-date {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 8px;
}
.report-day-card .rdc-items { display: flex; flex-wrap: wrap; gap: 12px; }
.rdc-item {
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.rdc-item .rdc-time { color: var(--blue); font-weight: 700; }
.rdc-item .rdc-acc { color: var(--green); font-weight: 700; }

/* ─── List Actions ─── */
.list-actions { display: flex; gap: 8px; align-items: center; }
.list-btn {
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.list-start { background: var(--green); color: #fff; }
.list-start.resume { background: var(--orange); }
.list-test { background: var(--surface2); color: var(--blue); border: 1px solid var(--border); }

/* ─── Test Mode ─── */
.test-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
  max-height: 60vh;
  overflow-y: auto;
}
.test-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: var(--surface);
  border-radius: 10px;
  border: 1px solid var(--border);
}
.test-row.test-correct { border-color: var(--green); }
.test-row.test-wrong { border-color: var(--red); }
.test-num { font-size: 11px; color: var(--muted); width: 20px; text-align: center; }
.test-word { font-weight: 700; font-size: 13px; min-width: 100px; }
.test-input {
  flex: 1;
  padding: 6px 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-family: inherit;
  font-size: 13px;
}
.test-input:focus { outline: none; border-color: var(--blue); }
.test-input:disabled { opacity: 0.7; }
.test-mark { font-size: 16px; width: 24px; text-align: center; }
.test-mark.correct { color: var(--green); }
.test-mark.wrong { color: var(--red); }
.test-answer-hint {
  width: 100%;
  font-size: 11px;
  color: var(--green);
  padding: 4px 0 0 28px;
}

.test-submit-btn {
  width: 100%;
  padding: 14px;
  background: var(--blue);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  margin-bottom: 16px;
}

.test-result-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}
.test-result-card h3 { font-size: 20px; margin-bottom: 8px; }
.test-score { font-size: 18px; color: var(--blue); margin-bottom: 4px; }
.test-hint { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.test-wrong-count { font-size: 12px; color: var(--orange); }

/* ─── Daily Report ─── */
.report-section { margin-bottom: 16px; }
.report-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.report-card h3 { font-size: 15px; font-weight: 800; margin-bottom: 10px; }
.report-total {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.report-total strong { color: var(--green); }
.report-items { display: flex; flex-direction: column; gap: 8px; }
.report-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.ri-icon { font-size: 16px; }
.ri-label { font-weight: 700; min-width: 40px; }
.ri-time { color: var(--blue); font-weight: 600; }
.ri-acc { margin-left: auto; color: var(--green); font-weight: 700; font-size: 12px; }

/* ─── Game Feedback Button ─── */
.fb-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}
.fb-correct-answer {
  font-size: 14px;
  margin-top: 4px;
  opacity: 0.85;
}
.fb-continue {
  display: block;
  width: 100%;
  margin-top: 14px;
  padding: 14px;
  background: var(--green);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  text-align: center;
}
.game-feedback.wrong .fb-continue { background: var(--red); }
.speak-btn-sm {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
}

/* Context hint */
.game-context-hint {
  font-size: 13px;
  color: var(--blue);
  background: rgba(28,176,246,0.08);
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 20px;
  text-align: center;
  line-height: 1.5;
}

/* Reveal area */
.reveal-area {
  margin-top: 16px;
  padding: 12px 16px;
  background: var(--surface2);
  border-radius: 10px;
  text-align: center;
}
.reveal-area .game-shown-def {
  margin: 0;
  font-style: normal;
  color: var(--green);
}

/* Listen Mode */
.listen-play {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin: 24px 0;
}
.listen-btn {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--surface);
  border: 3px solid var(--blue);
  font-size: 36px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.listen-btn:hover { transform: scale(1.1); background: rgba(28,176,246,0.1); }
.listen-btn:active { transform: scale(0.95); }
.listen-hint { font-size: 12px; color: var(--muted); }

/* Match */
.match-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; width: 100%; }
.match-col { display: flex; flex-direction: column; gap: 8px; }
.match-item {
  padding: 12px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  transition: all 0.15s;
}
.match-item:hover { border-color: var(--blue); }
.match-item.selected { border-color: var(--blue); background: rgba(28,176,246,0.1); }
.match-item.matched { opacity: 0.3; pointer-events: none; border-color: var(--green); }
.match-item.shake { animation: shake 0.3s ease; }
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

/* Rapid Fire */
.rapid-timer-bar {
  width: 100%;
  height: 6px;
  background: var(--surface2);
  border-radius: 3px;
  margin-bottom: 20px;
  overflow: hidden;
}
.rapid-timer-fill {
  height: 100%;
  background: var(--orange);
  border-radius: 3px;
  width: 0%;
  transition: width 50ms linear;
}

.game-shown-def {
  font-size: 18px;
  font-weight: 700;
  text-align: center;
  margin: 16px 0 28px;
  color: var(--muted);
  font-style: italic;
}

/* Wrong Word List */
.wrong-word-list {
  text-align: left;
  width: 100%;
  max-height: 200px;
  overflow-y: auto;
  margin: 12px 0;
}
.wrong-word-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--surface2);
  border-radius: 10px;
  margin-bottom: 6px;
}
.ww-word { font-weight: 800; font-size: 14px; min-width: 100px; }
.ww-def { flex: 1; font-size: 12px; color: var(--muted); }
.wrong-word-item .speak-btn {
  width: 30px;
  height: 30px;
  font-size: 14px;
}

/* Toast */
.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface2);
  border: 2px solid var(--green);
  padding: 12px 24px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  z-index: 300;
  animation: slideDown 0.3s ease;
}
.toast.hidden { display: none; }
@keyframes slideDown { from { transform: translateX(-50%) translateY(-20px); opacity: 0; } }
