:root {
  --bg: #111214;
  --surface: #17181a;
  --surface-soft: #1c1d1f;
  --line: #333436;
  --gold: #c89a32;
  --cream: #f2f2f2;
  --muted: #b3b1ad;
  --ink: #111214;
  --max: 1120px;
}

* { box-sizing: border-box; }

html {
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--cream);
  font-family: "Montserrat", Arial, sans-serif;
  line-height: 1.55;
}

a { color: inherit; }
button { font: inherit; }

[hidden] {
  display: none !important;
}

.prototype-bar {
  min-height: 42px;
  padding: .55rem 1rem;
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  background: var(--gold);
  color: var(--ink);
  font-size: .7rem;
  text-align: center;
}

.prototype-bar strong { letter-spacing: .1em; }

.review-shell {
  min-height: 112px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #292a2c;
}

.review-shell img {
  width: 64px;
  height: auto;
}

.review-shell span {
  color: var(--muted);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .12em;
}

main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.5rem 3rem;
}

.event-intro {
  padding: 2rem 0 1.75rem;
}

.return-link { margin-bottom: 1.35rem; }

.event-intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2rem;
  align-items: end;
}

.eyebrow,
.card-kicker,
.mini-label {
  margin: 0 0 .6rem;
  color: var(--gold);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .14em;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  margin-bottom: .8rem;
  font-size: clamp(2.35rem, 5vw, 4rem);
  line-height: 1.02;
  letter-spacing: -.04em;
}

h2 {
  margin-bottom: .5rem;
  font-size: clamp(1.8rem, 3vw, 2.55rem);
  line-height: 1.08;
  letter-spacing: -.03em;
}

h3 {
  margin-bottom: 0;
  font-size: clamp(1.75rem, 3.6vw, 3rem);
  line-height: 1.08;
  letter-spacing: -.035em;
}

.event-summary {
  margin: .2rem 0;
  color: #c9c7c3;
  font-size: .9rem;
}

.event-actions {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.button {
  min-height: 48px;
  padding: 16px 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--gold);
  border-radius: 0;
  background: transparent;
  color: var(--cream);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .8px;
  line-height: 1;
  text-decoration: none;
  transition: .3s;
  cursor: pointer;
}

.button-gold {
  background: var(--gold);
  color: var(--ink);
}

.button:hover,
.button:focus-visible {
  background: var(--gold);
  color: var(--ink);
}

.button-gold:hover,
.button-gold:focus-visible {
  background: transparent;
  color: var(--cream);
}

.button:focus-visible,
.text-link:focus-visible,
.game-tab:focus-visible,
summary:focus-visible,
.review-check input:focus-visible + span {
  outline: 2px solid var(--cream);
  outline-offset: 3px;
}

.text-link {
  display: inline-block;
  color: var(--gold);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-decoration: underline;
  text-underline-offset: .3rem;
}

.text-link:hover { color: var(--cream); }

.event-details-panel {
  margin-top: 1.5rem;
  padding: 1.25rem;
  background: var(--surface);
  border-top: 2px solid var(--gold);
}

.event-details-panel dl {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .75rem 1.5rem;
  margin: 0;
}

.event-details-panel dt {
  color: var(--gold);
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
}

.event-details-panel dd {
  margin: .15rem 0 0;
  color: var(--cream);
  font-size: .82rem;
}

.event-details-panel ul {
  margin: 1rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: .8rem;
}

.source-note,
.accuracy-note {
  color: #8f8d89;
  font-size: .72rem;
}

.game-prep {
  padding-top: 1.75rem;
  border-top: 1px solid var(--line);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.25rem;
}

.progress-wrap {
  width: min(260px, 100%);
  color: var(--gold);
  font-size: .74rem;
  font-weight: 700;
  text-align: right;
}

.progress-track {
  height: 3px;
  margin-top: .45rem;
  background: #333436;
}

.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--gold);
  transition: width .2s ease;
}

.game-tabs {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  border: 1px solid var(--line);
}

.game-tab {
  min-height: 68px;
  padding: .75rem .55rem;
  border: 0;
  border-right: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  font-size: .74rem;
  font-weight: 700;
  cursor: pointer;
}

.game-tab:last-child { border-right: 0; }

.game-tab span {
  display: block;
  margin-bottom: .15rem;
  color: #727171;
  font-size: .6rem;
}

.game-tab[aria-selected="true"] {
  background: var(--gold);
  color: var(--ink);
}

.game-tab[aria-selected="true"] span { color: #564115; }

.game-panel {
  padding: clamp(1.35rem, 3vw, 2.25rem);
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 0;
}

.game-heading {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.4rem;
}

.quick-refresher {
  margin-bottom: 1.3rem;
  padding: 1rem 1.1rem;
  background: #1d1e20;
  border-left: 3px solid var(--gold);
}

.quick-facts {
  max-width: 930px;
  margin: .65rem 0 0;
  padding: 0;
  display: grid;
  gap: .5rem;
  list-style: none;
  color: #dfddd9;
  font-size: .9rem;
}

.quick-facts li {
  padding-left: 1rem;
  position: relative;
  line-height: 1.55;
}

.quick-facts li::before {
  content: "";
  width: 4px;
  height: 4px;
  position: absolute;
  left: 0;
  top: .68em;
  background: var(--gold);
}

.game-tags {
  display: flex;
  gap: .45rem;
  flex-wrap: wrap;
}

.game-tags span {
  padding: .4rem .65rem;
  border: 1px solid #5a554b;
  color: var(--gold);
  font-size: .65rem;
  font-weight: 700;
  text-transform: uppercase;
}

.quick-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr 1.15fr;
  border-block: 1px solid var(--line);
}

.quick-grid section {
  padding: 1.15rem 1.25rem 1.15rem 0;
}

.quick-grid section + section {
  padding-left: 1.25rem;
  border-left: 1px solid var(--line);
}

.quick-grid p:last-child {
  margin-bottom: 0;
  color: #ceccc8;
  font-size: .86rem;
}

.quick-grid .remember p:last-child {
  color: var(--cream);
  font-weight: 600;
}

.more-detail {
  margin-top: 1.2rem;
  border-bottom: 1px solid var(--line);
}

.more-detail summary,
.prototype-notes summary {
  padding: .9rem 0;
  color: var(--gold);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .08em;
  cursor: pointer;
}

.detail-content {
  padding: .35rem 0 1.3rem;
}

.detail-list {
  max-width: 850px;
  margin: 0;
  padding-left: 1.15rem;
  color: #c7c5c1;
  font-size: .86rem;
}

.detail-list li + li { margin-top: .55rem; }

.detail-list li::marker { color: var(--gold); }

.resource-columns {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 2rem;
  margin-top: 1.2rem;
}

.resource-links {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem .7rem;
}

.resource-links a {
  color: var(--cream);
  font-size: .72rem;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: .3rem;
}

.resource-links a:hover { color: var(--gold); }

.accuracy-note {
  margin: -.25rem 0 .75rem;
}

.game-footer {
  padding-top: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.game-footer-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
}

.game-footer-actions .button {
  min-height: 42px;
  padding: 13px 16px;
  font-size: 12px;
}

.quiz-entry {
  display: grid;
  gap: .4rem;
}

.quiz-entry p {
  max-width: 290px;
  margin: 0;
  color: #a7a49f;
  font-size: .7rem;
  line-height: 1.35;
}


.practice-section,
.history-section {
  margin-top: 1.75rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--surface);
  border-top: 2px solid var(--gold);
}

.practice-topline {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
}

.practice-source,
.history-empty {
  color: var(--muted);
  font-size: .78rem;
}

.text-button {
  padding: .25rem 0;
  border: 0;
  border-bottom: 1px solid var(--gold);
  border-radius: 0;
  background: transparent;
  color: var(--gold);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .06em;
  cursor: pointer;
}

.text-button:hover,
.text-button:focus-visible {
  color: var(--cream);
  outline: 2px solid var(--cream);
  outline-offset: 3px;
}

.quiz-progress {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 1.25rem 0 .35rem;
  color: var(--gold);
  font-size: .74rem;
  font-weight: 700;
}

.quiz-fieldset {
  min-width: 0;
  margin: 1.4rem 0 0;
  padding: 0;
  border: 0;
}

.quiz-fieldset legend {
  max-width: 900px;
  margin-bottom: 1rem;
  color: var(--cream);
  font-size: clamp(1.15rem, 2.4vw, 1.6rem);
  font-weight: 700;
  line-height: 1.3;
}

.quiz-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .65rem;
}

.quiz-option {
  min-height: 58px;
  padding: .75rem;
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  gap: .7rem;
  border: 1px solid #454648;
  background: #1c1d1f;
  color: #d8d6d2;
  cursor: pointer;
}

.quiz-option:hover,
.quiz-option:focus-within {
  border-color: var(--gold);
}

.quiz-option input {
  position: absolute;
  opacity: 0;
}

.quiz-option span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: .72rem;
  font-weight: 700;
}

.quiz-option input:checked + span {
  background: var(--gold);
  color: var(--ink);
}

.quiz-option[data-correct="true"] {
  border-color: #6ca56c;
  background: #18231a;
}

.quiz-option[data-incorrect="true"] {
  border-color: #a45f5f;
  background: #281a1a;
}

.quiz-actions {
  margin-top: 1rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .75rem;
}

.answer-feedback {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.answer-feedback strong { color: var(--gold); }
.answer-feedback p {
  max-width: 880px;
  margin: .35rem 0 0;
  color: #ceccc8;
  font-size: .88rem;
}

.result-score {
  margin: .5rem 0 0;
  color: var(--gold);
  font-size: clamp(2.8rem, 8vw, 5.2rem);
  font-weight: 700;
  line-height: 1;
}

.result-breakdown {
  max-width: 680px;
  margin-top: 1rem;
  border-top: 1px solid var(--line);
}

.result-breakdown div {
  padding: .55rem 0;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: .8rem;
}

.result-breakdown strong { color: var(--cream); }

.history-section {
  border-top-color: var(--line);
}

.compact-heading {
  margin-bottom: .5rem;
}

.compact-heading h2 { font-size: 1.55rem; }

.history-list {
  margin: .75rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.history-list li {
  padding: .7rem 0;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 1rem;
  border-bottom: 1px solid var(--line);
  font-size: .78rem;
}

.history-list span { color: var(--gold); font-weight: 700; }
.history-list time { color: var(--muted); }

.review-check {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  color: #d4d2ce;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
}

.review-check input {
  position: absolute;
  opacity: 0;
}

.review-check span {
  width: 20px;
  height: 20px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--gold);
}

.review-check input:checked + span {
  background: var(--gold);
}

.review-check input:checked + span::after {
  content: "✓";
  color: var(--ink);
  font-size: .8rem;
  font-weight: 700;
}

.foundations-section {
  margin-top: 1.75rem;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  background: var(--surface-soft);
  border-top: 2px solid var(--gold);
}

.foundations-section h2 { font-size: 1.55rem; }

.foundations-section p:not(.eyebrow) {
  max-width: 680px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: .82rem;
}

.foundations-action {
  min-width: min(100%, 250px);
}

.navigation-notice {
  max-width: 250px;
  margin: .65rem 0 0;
  color: var(--gold) !important;
  font-size: .7rem !important;
}

.prototype-notes {
  margin-top: 1.25rem;
  color: var(--muted);
  font-size: .75rem;
}

.prototype-notes ul {
  padding-left: 1.1rem;
}

footer {
  min-height: 90px;
  padding: 1.5rem max(1.5rem, calc((100vw - var(--max)) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  background: #0b0c0d;
  border-top: 1px solid #28292b;
  color: #7f7d79;
  font-size: .7rem;
}

footer strong {
  color: var(--gold);
  letter-spacing: .1em;
}

.events-review main {
  padding-top: 2rem;
}

.events-review .review-note {
  max-width: 760px;
  color: var(--muted);
}

.simulated-events {
  display: grid;
  gap: 1rem;
  margin: 2rem 0;
}

.simulated-event {
  padding: 1.25rem;
  background: var(--surface);
  border: 1px solid var(--line);
}

.simulated-event:target {
  border: 2px solid var(--gold);
}

.simulated-event h2 {
  margin: .2rem 0;
  font-size: 1.35rem;
}

.simulated-event p {
  margin: .15rem 0;
  color: var(--muted);
  font-size: .8rem;
}

@media (max-width: 850px) {
  .event-intro-grid { grid-template-columns: 1fr; }
  .event-actions { justify-content: flex-start; }
  .game-tabs { grid-template-columns: repeat(3, 1fr); }
  .game-tab:nth-child(3) { border-right: 0; }
  .game-tab:nth-child(-n+3) { border-bottom: 1px solid var(--line); }
  .quick-grid { grid-template-columns: 1fr; }
  .quick-grid section { padding: 1rem 0; }
  .quick-grid section + section {
    padding-left: 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }
  .resource-columns { grid-template-columns: 1fr; }
  .quiz-options { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .prototype-bar {
    align-items: center;
    flex-direction: column;
    gap: .1rem;
  }
  .review-shell {
    min-height: 86px;
    padding-inline: 1rem;
  }
  .review-shell img { width: 48px; }
  main { padding-inline: 1rem; }
  .event-intro { padding-top: 1.4rem; }
  .event-actions,
  .event-actions .button { width: 100%; }
  .button { font-size: 12px; }
  .section-heading,
  .game-heading,
  .game-footer,
  .game-footer-actions,
  .practice-topline,
  .foundations-section,
  footer {
    align-items: flex-start;
    flex-direction: column;
  }
  .progress-wrap { width: 100%; text-align: left; }
  .game-tabs { grid-template-columns: 1fr 1fr; }
  .game-tab {
    min-height: 76px;
    padding: .8rem .65rem;
    border-bottom: 1px solid var(--line);
    font-size: .72rem;
    line-height: 1.3;
  }
  .game-tab:nth-child(odd) { border-right: 1px solid var(--line); }
  .game-tab:nth-child(even) { border-right: 0; }
  .event-details-panel dl { grid-template-columns: 1fr; }
  .foundations-action,
  .foundations-section .button { width: 100%; }
  .game-footer-actions,
  .game-footer-actions .button,
  .quiz-actions,
  .quiz-actions .button { width: 100%; }
  .history-list li { grid-template-columns: 1fr auto; }
  .history-list time { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
