/* Atlas Finance - styles for the homepage */

/* Anything with the hidden attribute stays hidden, even if another rule sets display */
[hidden] {
  display: none !important;
}

/* Whole page */
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #ffffff;
  color: #222222;
  line-height: 1.5;
}

/* Dark blue bar at the top */
header {
  background-color: #1f3a5f;
  color: #ffffff;
  text-align: center;
  padding: 20px;
}

header h1 {
  margin: 0 0 10px 0;
}

/* Menu links in the header */
nav a {
  color: #ffffff;
  margin: 0 10px;
  text-decoration: none;
}

nav a:hover {
  text-decoration: underline;
}

/* Keep the content in a column in the middle of the page */
main {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
}

section {
  margin-bottom: 40px;
}

/* Dashed box, shown if the chart cannot load */
.placeholder {
  border: 2px dashed #999999;
  padding: 40px 20px;
  text-align: center;
  color: #666666;
}

/* Main button: the link in the intro and the game buttons */
.button {
  display: inline-block;
  background-color: #1f3a5f;
  color: #ffffff;
  border: none;
  padding: 12px 20px;
  font-family: inherit;
  font-size: 16px;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  background-color: #2f5588;
}

/* Grey look while a button cannot be pressed, for example when the total is not 100% */
.button:disabled {
  background-color: #b8c0c9;
  color: #3d4752;
  cursor: not-allowed;
}

/* Note that says the scenario is fictional */
.sample-note {
  background-color: #eef2f7;
  border-left: 4px solid #1f3a5f;
  padding: 10px 15px;
}

/* Game rules */
.rules {
  padding-left: 20px;
}

/* Year, money and next step at the top of the game */
.game-status {
  background-color: #1f3a5f;
  color: #ffffff;
  padding: 10px 15px;
  margin: 25px 0;
}

.game-status p {
  margin: 0;
}

/* Places the game moves the keyboard focus to (headings, the status bar) don't need a focus outline */
[tabindex="-1"]:focus {
  outline: none;
}

/* News cards: as many columns as fit, one column on phones */
.news-cards {
  list-style: none;
  margin: 0 0 25px 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 15px;
}

.news-card {
  border: 1px solid #dddddd;
  border-top: 4px solid #1f3a5f;
  padding: 10px 15px;
}

.news-card h4 {
  margin: 0 0 5px 0;
}

.news-card p {
  margin: 0;
  color: #444444;
  font-size: 14px;
}

/* Portfolio Builder: controls on the left, chart on the right.
   flex-wrap moves the chart underneath when there is not enough room. */
.builder {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
}

.builder-controls {
  flex: 1 1 340px;
  min-width: 0;
}

.builder-chart {
  flex: 1 1 240px;
  min-width: 0;
}

.builder-chart h3 {
  margin-top: 0;
}

fieldset {
  border: 1px solid #dddddd;
  padding: 15px;
  margin: 0 0 15px 0;
  min-width: 0;
}

legend {
  font-weight: bold;
  padding: 0 5px;
}

.hint {
  color: #666666;
  font-size: 14px;
  margin: 0 0 10px 0;
}

/* Game example in Year 1, proposed allocation after that */
.allocation-note {
  font-size: 14px;
  margin: 0 0 10px 0;
}

/* One row for each asset */
.asset-row {
  border-top: 1px solid #eeeeee;
  padding: 10px 0;
}

.asset-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.asset-title input {
  width: 24px;
  height: 24px;
  margin: 0;
}

.asset-title label {
  font-weight: bold;
}

.asset-description {
  color: #666666;
  font-size: 14px;
  margin: 0 0 5px 0;
}

.asset-amount {
  display: flex;
  align-items: center;
  gap: 10px;
}

.asset-amount input[type="range"] {
  flex: 1;
  min-width: 0;
  height: 32px;
  margin: 0;
  accent-color: #1f3a5f;
}

.asset-amount input[type="number"] {
  width: 70px;
  padding: 8px;
  font-size: 16px;
  border: 1px solid #767676;
}

/* Greyed-out look for an asset that is not chosen */
.asset-off .asset-description,
.asset-off .asset-amount {
  opacity: 0.5;
}

/* Total and validation message */
.total {
  font-size: 20px;
  margin: 0 0 5px 0;
}

.message {
  border-left: 4px solid;
  padding: 10px 15px;
  margin: 0 0 15px 0;
}

.message-ok {
  background-color: #e6f4ea;
  border-color: #2e7d32;
}

.message-warning {
  background-color: #fdecea;
  border-color: #b3261e;
}

/* Pie chart and the list under it */
.chart-box {
  position: relative;
  max-width: 240px;
  margin: 0 auto 15px auto;
}

.chart-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.chart-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
}

.list-percent {
  margin-left: auto;
  font-weight: bold;
}

/* Small color square that matches the pie chart */
.swatch {
  display: inline-block;
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 3px;
}

/* A year's results and the final result */
.results {
  border-top: 4px solid #1f3a5f;
  margin-top: 30px;
  padding-top: 5px;
}

.result-summary {
  margin: 0 0 15px 0;
}

.result-summary div {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid #eeeeee;
  padding: 4px 0;
}

.result-summary dt {
  font-weight: bold;
}

.result-summary dd {
  margin: 0;
}

.final-value {
  font-size: 20px;
}

/* Tables scroll sideways inside their own box on narrow screens */
.table-wrap {
  overflow-x: auto;
  margin-bottom: 15px;
}

table {
  border-collapse: collapse;
  width: 100%;
  font-size: 14px;
}

th,
td {
  border-bottom: 1px solid #dddddd;
  padding: 6px 8px;
  text-align: right;
  white-space: nowrap;
}

thead th {
  background-color: #eef2f7;
  white-space: normal;
  vertical-align: bottom;
}

th:first-child {
  text-align: left;
}

/* Personal goal, chosen before Year 1 */
.goal-picker {
  margin: 0 0 25px 0;
}

.goal-picker label {
  display: block;
  padding: 6px 0;
}

/* News heading with the "Marked 3 of 5" counter beside it */
.news-top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}

.news-count {
  font-weight: bold;
  margin: 0;
}

/* Expected and actual numbers on a news card */
.news-card p.expectation {
  margin-top: 8px;
  color: #222222;
}

/* "Likely matters / Probably noise" choice on each news card */
.tag-choice {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 15px;
  margin-top: 10px;
}

.tag-choice label {
  font-size: 14px;
  padding: 4px 0;
}

.tag-choice input,
.goal-picker input {
  width: 18px;
  height: 18px;
  margin: 0 4px 0 0;
  vertical-align: middle;
  accent-color: #1f3a5f;
}

.hint-box {
  margin-top: 8px;
  font-size: 14px;
}

.hint-box summary,
.why summary {
  cursor: pointer;
  color: #1f3a5f;
  font-weight: bold;
}

/* Hold and rebalance buttons above the sliders */
.mix-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 10px 0;
}

.button-small {
  background-color: #ffffff;
  color: #1f3a5f;
  border: 1px solid #1f3a5f;
  padding: 8px 12px;
  font-family: inherit;
  font-size: 14px;
  cursor: pointer;
}

.button-small:hover {
  background-color: #eef2f7;
}

.button-small:disabled {
  color: #767676;
  border-color: #bbbbbb;
  cursor: not-allowed;
}

/* What is still missing before Confirm */
.confirm-help {
  font-size: 14px;
  margin: 0 0 10px 0;
}

/* A year's results: the counting balance and the reveal of what mattered */
.big-change {
  font-size: 24px;
  margin: 5px 0 15px 0;
}

.why {
  border: 1px solid #dddddd;
  padding: 10px 15px;
  margin: 0 0 20px 0;
}

.reveal-list {
  list-style: none;
  margin: 10px 0 0 0;
  padding: 0;
}

.reveal-item {
  border-top: 1px solid #eeeeee;
  padding: 10px 0;
}

.reveal-item p {
  margin: 0 0 5px 0;
}

/* Labels in the reveal: a story that mattered, or one with no assigned effect */
.badge {
  display: inline-block;
  font-size: 13px;
  font-weight: bold;
  padding: 2px 8px;
  border: 1px solid;
}

.badge-matters {
  color: #1f3a5f;
  border-color: #1f3a5f;
  background-color: #eef2f7;
}

.badge-noise {
  color: #555555;
  border-color: #999999;
  background-color: #f5f5f5;
}

/* "How do you want to play?": three big buttons, side by side when there is room */
.mode-picker {
  margin: 30px 0;
}

.mode-options {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 15px;
}

.mode-card {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  text-align: left;
  background-color: #ffffff;
  color: #222222;
  border: 2px solid #1f3a5f;
  padding: 15px;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.5;
  cursor: pointer;
}

.mode-card:hover {
  background-color: #eef2f7;
}

.mode-card strong {
  display: block;
  font-size: 18px;
  color: #1f3a5f;
  margin-bottom: 5px;
}

/* Learn and play: a tip under each asset and a surprise label on each story */
.asset-tip {
  font-size: 14px;
  color: #1f3a5f;
  margin: 0 0 5px 0;
}

.surprise {
  display: inline-block;
  font-size: 13px;
  font-weight: bold;
  color: #1f3a5f;
  background-color: #eef2f7;
  padding: 2px 8px;
  margin-top: 8px;
}

/* "What if?" comparison and "How was this calculated?" */
.what-if {
  border-left: 4px solid #1f3a5f;
  padding: 5px 15px;
}

.math-lines {
  margin: 10px 0 0 0;
  padding-left: 20px;
  font-size: 14px;
}

/* Learn and play: the idea of the year and its check question */
.lesson {
  border: 2px solid #1f3a5f;
  padding: 10px 15px;
  margin: 0 0 20px 0;
}

.lesson h4 {
  margin: 5px 0;
}

.check-question {
  border: none;
  padding: 0;
  margin: 10px 0 0 0;
}

.check-question legend {
  font-weight: bold;
  padding: 0;
  margin-bottom: 5px;
}

.check-question label {
  display: block;
  padding: 5px 0;
}

.check-question input {
  width: 18px;
  height: 18px;
  margin: 0 6px 0 0;
  vertical-align: middle;
  accent-color: #1f3a5f;
}

.check-feedback {
  margin: 10px 0 0 0;
}

.ideas-list {
  padding-left: 20px;
}

/* ===================================================================
   Game look (2026-11-29)
   These rules come last, so they restyle the plain rules above.
   Colors: ink #0e1a2b for dark areas, lime #c6f16d for the main
   buttons, a light grey page #f3f5f8 and white cards.
   =================================================================== */

body {
  background-color: #f3f5f8;
  color: #1b2433;
  font-family: "Avenir Next", "Segoe UI", system-ui, Arial, sans-serif;
}

h2,
h3 {
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h2 {
  font-size: 34px;
}

/* Numbers line up in columns, like on a trading screen */
.big-change,
.final-value strong,
.hero-facts dd,
.hero-card-value,
.status-grid dd,
.total strong,
td {
  font-variant-numeric: tabular-nums;
}

/* ---------- Header ---------- */

header {
  background-color: #0e1a2b;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 14px 20px;
  text-align: left;
}

.header-inner {
  max-width: 1040px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

header h1 {
  margin: 0;
  font-size: 20px;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
}

/* The logo: a lime square with a dark ring inside, drawn with CSS */
.logo-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background-color: #c6f16d;
  box-shadow: inset 0 0 0 5px #c6f16d, inset 0 0 0 8px #0e1a2b;
  margin-right: 10px;
}

nav a {
  display: inline-block;
  padding: 8px 14px;
  margin: 0 0 0 4px;
  border-radius: 999px;
  color: #ffffff;
}

nav a:hover {
  background-color: rgba(255, 255, 255, 0.12);
  text-decoration: none;
}

/* ---------- First screen ---------- */

/* A dark screen with a faint grid, like graph paper */
.hero {
  background-color: #0e1a2b;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  color: #ffffff;
  min-height: calc(100vh - 62px);
  display: flex;
  align-items: center;
  margin: 0;
  padding: 50px 20px;
  box-sizing: border-box;
}

.hero-inner {
  max-width: 1040px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 50px;
}

.hero-text {
  flex: 1 1 420px;
}

.hero-text > .eyebrow {
  color: #c6f16d;
  font-size: 14px;
  font-weight: bold;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 15px 0;
}

.hero h2 {
  font-size: 56px;
  letter-spacing: -0.035em;
  line-height: 1.05;
  margin: 0 0 20px 0;
}

.hero-text > p {
  color: #c3cad6;
  font-size: 18px;
  max-width: 540px;
  margin: 0 0 30px 0;
}

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  margin: 40px 0 0 0;
  padding-top: 25px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.hero-facts dt {
  color: #a3adbd;
  font-size: 13px;
}

.hero-facts dd {
  margin: 0;
  font-size: 26px;
  font-weight: bold;
}

/* The example card on the right */
.hero-card {
  flex: 1 1 300px;
  max-width: 420px;
  background-color: #16263d;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 25px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
}

.hero-card-title {
  color: #a3adbd;
  font-size: 14px;
  margin: 0;
}

.hero-card-value {
  font-size: 34px;
  font-weight: bold;
  margin: 0 0 20px 0;
}

.mix-bar {
  display: flex;
  height: 14px;
  border-radius: 999px;
  overflow: hidden;
  gap: 2px;
  margin-bottom: 20px;
}

.mix-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mix-list li {
  display: flex;
  align-items: center;
  padding: 8px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 15px;
}

.mix-list .swatch {
  margin-right: 10px;
}

.mix-list strong {
  margin-left: auto;
}

.hero-card-note {
  color: #a3adbd;
  font-size: 13px;
  margin: 15px 0 0 0;
}

/* The first screen slides in once when the page opens */
@media (prefers-reduced-motion: no-preference) {
  .hero-text,
  .hero-card {
    animation: rise 0.7s ease-out both;
  }

  .hero-card {
    animation-delay: 0.15s;
  }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}

/* ---------- The game area ---------- */

main {
  max-width: 1000px;
  padding: 60px 20px;
}

#game > p,
.rules {
  max-width: 720px;
}

/* ---------- Buttons ---------- */

/* Main button: lime with dark text, round, steps up on hover and presses on click */
.button {
  background-color: #c6f16d;
  color: #0e1a2b;
  border-radius: 999px;
  padding: 14px 28px;
  font-weight: bold;
}

.button:hover {
  background-color: #b4e64c;
}

.button:disabled {
  background-color: #d5dae2;
  color: #4a5568;
}

.button-small {
  border-radius: 999px;
  padding: 8px 16px;
  border-color: #0e1a2b;
  color: #0e1a2b;
}

@media (prefers-reduced-motion: no-preference) {
  .button,
  .button-small,
  .mode-card {
    transition: transform 0.12s, background-color 0.12s, box-shadow 0.12s;
  }

  .button:hover:not(:disabled),
  .mode-card:hover {
    transform: translateY(-2px);
  }

  .button:active:not(:disabled) {
    transform: translateY(1px);
  }
}

/* ---------- Cards and boxes: white, thin border, 12px corners ---------- */

.news-card,
.mode-card,
.results,
fieldset,
.builder-chart,
.lesson,
.why,
.table-wrap {
  border-radius: 12px;
}

.sample-note,
.message,
.what-if,
.placeholder {
  border-radius: 8px;
}

.badge,
.surprise {
  border-radius: 999px;
}

/* Mode cards: difficulty bars, the level, the name and what it means */
.mode-card {
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
  box-shadow: 0 1px 2px rgba(14, 26, 43, 0.06);
  padding: 20px;
}

.mode-card:hover {
  background-color: #ffffff;
  border-color: #0e1a2b;
  box-shadow: 0 10px 24px rgba(14, 26, 43, 0.12);
}

.mode-card strong {
  color: #0e1a2b;
  font-size: 20px;
}

.mode-level {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #5b6678;
  font-size: 13px;
  font-weight: bold;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.level-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
}

.level-bars span {
  width: 6px;
  background-color: #d5dae2;
  border-radius: 2px;
}

.level-bars span:nth-child(1) { height: 8px; }
.level-bars span:nth-child(2) { height: 12px; }
.level-bars span:nth-child(3) { height: 16px; }

.level-bars span.on {
  background-color: #0e1a2b;
}

/* ---------- Status panel ---------- */

.game-status {
  background-color: #0e1a2b;
  border-radius: 16px;
  padding: 20px 24px;
}

.year-dots {
  list-style: none;
  display: flex;
  gap: 6px;
  margin: 0 0 18px 0;
  padding: 0;
}

.step {
  flex: 1;
  border-top: 5px solid rgba(255, 255, 255, 0.18);
  padding-top: 6px;
  font-size: 12px;
  color: #a3adbd;
}

.step-done {
  border-top-color: #c6f16d;
  color: #ffffff;
}

.step-now {
  border-top-color: #ffffff;
  color: #ffffff;
  font-weight: bold;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 15px;
  margin: 0 0 15px 0;
}

.status-grid dt {
  color: #a3adbd;
  font-size: 13px;
}

.status-grid dd {
  margin: 0;
  font-size: 18px;
  font-weight: bold;
}

.game-status p.status-next {
  color: #c3cad6;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

/* ---------- News cards ---------- */

.news-card {
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
  border-top: 4px solid #2f6fdb;
  box-shadow: 0 1px 2px rgba(14, 26, 43, 0.06);
}

/* Each year has its own color on top of its news cards */
#game[data-year="2"] .news-card { border-top-color: #e8590c; }
#game[data-year="3"] .news-card { border-top-color: #0b7285; }
#game[data-year="4"] .news-card { border-top-color: #2b8a3e; }
#game[data-year="5"] .news-card { border-top-color: #c2255c; }

/* ---------- Builder ---------- */

#allocation,
.builder-chart {
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
}

.builder-chart {
  padding: 15px;
}

.builder-chart h3 {
  margin-top: 0;
}

/* ---------- Results ---------- */

.results {
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
  border-top: none;
  padding: 10px 24px 24px 24px;
  box-shadow: 0 10px 30px rgba(14, 26, 43, 0.08);
}

.big-change {
  font-size: 40px;
  font-weight: bold;
  letter-spacing: -0.02em;
  margin: 10px 0;
}

/* Gain or loss as a colored label with words */
.cheer {
  display: inline-block;
  font-size: 18px;
  font-weight: bold;
  padding: 6px 16px;
  border-radius: 999px;
  margin: 0 0 20px 0;
}

.cheer-good {
  background-color: #e3f6e5;
  color: #1b5e20;
}

.cheer-bad {
  background-color: #fdecea;
  color: #9b1c1c;
}

@media (prefers-reduced-motion: no-preference) {
  .cheer-good {
    animation: pop 0.5s ease-out;
  }
}

@keyframes pop {
  0% { transform: scale(0.7); opacity: 0; }
  70% { transform: scale(1.06); opacity: 1; }
  100% { transform: scale(1); }
}

.final-value strong {
  display: block;
  font-size: 44px;
  letter-spacing: -0.02em;
}

/* ---------- Phones ---------- */

@media (max-width: 600px) {
  .hero h2 {
    font-size: 40px;
  }

  .hero-facts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }

  .big-change {
    font-size: 28px;
  }

  .final-value strong {
    font-size: 34px;
  }
}

.goal-picker {
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
}

/* ---------- How to play: numbered cards ---------- */

.rules {
  max-width: none;
  list-style: none;
  padding: 0;
  margin: 0 0 30px 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
  counter-reset: rule;
}

.rules li {
  counter-increment: rule;
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
  border-radius: 12px;
  padding: 15px 18px;
  font-size: 15px;
}

/* The number in front of each rule: 01, 02, 03 ... */
.rules li::before {
  content: counter(rule, decimal-leading-zero);
  display: block;
  color: #5b6678;
  font-size: 13px;
  font-weight: bold;
  letter-spacing: 0.06em;
  margin-bottom: 4px;
}

/* ---------- Separate pages (2026-11-30) ---------- */

/* The menu link of the page you are on */
nav a[aria-current="page"] {
  background-color: rgba(255, 255, 255, 0.12);
  font-weight: bold;
}

/* Small label above a page heading, like "Before you start" */
.page-eyebrow {
  color: #5b6678;
  font-size: 13px;
  font-weight: bold;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 5px 0;
}

main h2 {
  margin-top: 0;
}

.page-intro > p {
  max-width: 720px;
}

/* Home: the main button and a quieter "How to play" link side by side */
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 25px;
}

.hero-link {
  color: #ffffff;
  font-weight: bold;
  text-underline-offset: 4px;
}

.hero-link:hover {
  color: #c6f16d;
}

/* Back on the left, Next or Confirm on the right */
.step-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 12px 15px;
  margin-top: 20px;
}

.step-nav .button-small {
  margin-right: auto;
}

.step-nav .confirm-help {
  margin: 0;
}

/* The steps of this year in the status panel: Goal, News, Allocation, Results */
.step-trail {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px 0;
  padding: 0;
  font-size: 13px;
}

.step-trail li {
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  padding: 3px 12px;
  color: #a3adbd;
}

.step-trail li.trail-done {
  color: #ffffff;
}

.step-trail li.trail-now {
  background-color: #c6f16d;
  border-color: #c6f16d;
  color: #0e1a2b;
  font-weight: bold;
}

/* ---------- Name and leaderboard (2026-11-30) ---------- */

/* Name box above the mode choice */
.name-box {
  background-color: #ffffff;
  border: 1px solid #e1e6ee;
  border-radius: 12px;
  padding: 18px 20px;
  margin-bottom: 25px;
  max-width: 480px;
}

.name-box label {
  display: block;
  font-weight: bold;
  margin-bottom: 6px;
}

.name-box input {
  width: 100%;
  box-sizing: border-box;
  font-family: inherit;
  font-size: 18px;
  padding: 10px 14px;
  border: 1px solid #767676;
  border-radius: 8px;
}

.name-box .hint {
  margin: 8px 0 0 0;
}

/* The leaderboard page can use the full width */
main.wide {
  max-width: 1040px;
}

.board-intro {
  max-width: 720px;
}

.boards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 15px;
  margin: 20px 0 30px 0;
}

/* Each board is a dark panel, so it reads well on a big screen at the booth */
.board {
  background-color: #0e1a2b;
  color: #ffffff;
  border-radius: 16px;
  padding: 20px;
}

.board h3 {
  margin: 0 0 12px 0;
}

.board-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.board-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.board-rank {
  width: 28px;
  height: 28px;
  flex: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: bold;
  background-color: rgba(0, 0, 0, 0.25);
  color: #ffffff;
}

/* First place gets the lime circle */
.board-first .board-rank {
  background-color: #c6f16d;
  color: #0e1a2b;
}

.board-name {
  flex: 1;
  min-width: 0;
  overflow-wrap: anywhere;
}

.board-value {
  text-align: right;
  font-weight: bold;
  font-variant-numeric: tabular-nums;
}

.board-value small {
  display: block;
  color: #a3adbd;
  font-weight: normal;
  font-size: 13px;
}

/* The row of the name used on this device */
.board-you .board-name {
  font-weight: bold;
}

.you-label {
  display: inline-block;
  background-color: #ffffff;
  color: #0e1a2b;
  border-radius: 999px;
  font-size: 12px;
  font-weight: bold;
  padding: 1px 8px;
  margin-left: 6px;
}

.board-empty {
  color: #a3adbd;
}

/* Final screen: where the score went */
.board-result {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin: 20px 0;
  padding: 15px 18px;
  background-color: #f3f5f8;
  border-radius: 12px;
}

.board-result p {
  margin: 0;
  flex: 1 1 260px;
  font-weight: bold;
}

/* Phones: the four menu links fit on one line */
@media (max-width: 600px) {
  nav {
    margin-left: -8px;
  }

  nav a {
    padding: 6px 8px;
    margin: 0;
    font-size: 15px;
  }
}
