@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Playfair+Display:wght@700&display=swap');

:root {
  --navy: #102A43;
  --navy-deep: #0D1B2A;
  --forest: #1F3A2E;
  --copper: #B87333;
  --warm-white: #F7F3EA;
  --panel: #ffffff;
  --border: rgba(16, 42, 67, 0.14);
  --text: #1A1A1A;
  --muted: #637381;
  --bad: #B54B3F;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(160deg, var(--navy), var(--navy-deep));
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.app {
  width: 100%;
  max-width: 620px;
}

.screen {
  background: var(--panel);
  border-radius: 16px;
  padding: 44px 40px;
  text-align: center;
  box-shadow: 0 24px 60px rgba(0,0,0,0.35);
}

.screen.hidden {
  display: none;
}

.logo {
  height: 44px;
  margin-bottom: 20px;
}

h1 {
  font-family: "Playfair Display", Georgia, serif;
  color: var(--navy);
  margin: 0 0 10px;
  font-size: 27px;
  line-height: 1.25;
}

.subtitle {
  color: var(--muted);
  margin: 0 0 24px;
  font-size: 15px;
}

.high-score {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 22px;
}

.audience-choice {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.audience-btn {
  text-align: left;
  padding: 18px 20px;
  border-radius: 12px;
  border: 2px solid var(--border);
  background: white;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.audience-btn:hover {
  border-color: var(--copper);
}

.audience-title {
  font-weight: 700;
  font-size: 16px;
  color: var(--navy);
}

.audience-desc {
  font-size: 13px;
  color: var(--muted);
}

button {
  cursor: pointer;
  border: 1px solid var(--border);
  background: white;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text);
  font-family: inherit;
}

button.primary, a.primary {
  background: var(--copper);
  color: white;
  border-color: var(--copper);
}

button.primary:hover, a.primary:hover {
  filter: brightness(1.05);
}

button.big, a.big {
  padding: 14px 36px;
  font-size: 16px;
  font-weight: 700;
  border-radius: 10px;
}

a.cta {
  display: inline-block;
  text-decoration: none;
  margin: 6px 0 18px;
}

.link-btn {
  border: none;
  background: none;
  color: var(--muted);
  font-size: 13px;
  text-decoration: underline;
  margin-top: 14px;
}

.game-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.stat {
  display: flex;
  flex-direction: column;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  min-width: 70px;
}

.stat span {
  font-size: 24px;
  font-weight: 700;
  color: var(--navy);
}

.timer {
  font-size: 40px;
  font-weight: 800;
  color: var(--copper);
  min-width: 90px;
}

.timer.urgent {
  color: var(--bad);
}

.question-text {
  font-size: 18px;
  font-weight: 600;
  color: var(--navy);
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 0 22px;
}

.options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.options button {
  padding: 14px 12px;
  font-size: 14px;
  border-radius: 10px;
  border: 2px solid var(--border);
  transition: all 0.15s ease;
}

.options button:hover:not(:disabled) {
  border-color: var(--copper);
}

.options button:disabled {
  cursor: default;
}

.options button.correct {
  background: var(--forest);
  border-color: var(--forest);
  color: white;
}

.options button.wrong {
  background: var(--bad);
  border-color: var(--bad);
  color: white;
}

.insight-text {
  margin: 18px 0 0;
  padding: 14px 16px;
  background: var(--warm-white);
  border-left: 3px solid var(--copper);
  border-radius: 8px;
  font-size: 13px;
  color: var(--text);
  text-align: left;
}

.insight-text.hidden {
  display: none;
}

.grade-label {
  color: var(--muted);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 4px;
}

.grade-letter {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 64px;
  font-weight: 700;
  line-height: 1;
  margin: 0 0 8px;
  color: var(--navy);
}

.grade-letter.grade-A, .grade-letter.grade-B {
  color: var(--forest);
}

.grade-letter.grade-C {
  color: var(--copper);
}

.grade-letter.grade-D, .grade-letter.grade-F {
  color: var(--bad);
}

.grade-detail {
  font-size: 14px;
  color: var(--muted);
  margin: 0 0 10px;
}

.new-high {
  color: var(--copper);
  font-weight: 700;
  margin: 0 0 12px;
}

.new-high.hidden {
  display: none;
}

.result-message {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 22px;
  line-height: 1.5;
}

.end-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}
