body {
  background: var(--c-navy);
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 31px, rgba(0,60,120,0.15) 31px, rgba(0,60,120,0.15) 32px),
    repeating-linear-gradient(90deg, transparent, transparent 31px, rgba(0,60,120,0.15) 31px, rgba(0,60,120,0.15) 32px);
  color: var(--c-white);
  font-family: var(--font-mono);
  font-size: 16px;    /* was 14px — base size for Courier Prime readability */
  min-height: 100vh;
  overflow-x: hidden;
}

/* ── SCANLINE OVERLAY ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,0.02) 2px, rgba(0,0,0,0.02) 4px);
  pointer-events: none;
  z-index: 9999;
}

/* ── PIXEL ART HELPERS ── */
.pixel-border {
  border: 3px solid var(--c-gray1);
  border-right-color: var(--c-gray4);
  border-bottom-color: var(--c-gray4);
  box-shadow: 1px 1px 0 var(--c-gray2);
}

.pixel-border-inset {
  border: 3px solid var(--c-gray4);
  border-right-color: var(--c-gray1);
  border-bottom-color: var(--c-gray1);
}

.pixel-panel {
  background: var(--c-darkblue);
  border: 2px solid var(--c-sky);
  box-shadow: 0 0 0 1px var(--c-midblue), 4px 4px 0 var(--c-navy);
  padding: 1rem;
}

/* ── SITE WRAPPER ── */
.site-wrapper {
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
  padding: 1rem;    /* was 0.5rem — panels were kissing viewport edge on mobile */
}

/* ── MARQUEE BANNER ── */
.top-marquee {
  background: var(--c-yellow);
  color: var(--c-navy);
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 8px — Press Start 2P min legible size is 10px */
  padding: 6px 0;
  overflow: hidden;
  white-space: nowrap;
  border-bottom: 3px solid var(--c-gold);
}

.marquee-inner {
  display: inline-block;
  animation: marquee 30s linear infinite;
}

@keyframes marquee {
  from { transform: translateX(100vw); }
  to   { transform: translateX(-100%); }
}

/* ── HEADER ── */
.site-header {
  background: linear-gradient(180deg, var(--c-midblue) 0%, var(--c-darkblue) 100%);
  border: 3px solid var(--c-sky);
  box-shadow: 0 0 0 1px var(--c-blue), 6px 6px 0 var(--c-navy);
  padding: 1.5rem 1rem 1rem;
  margin: 0.75rem 0;
  position: relative;
  overflow: hidden;
}

.site-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(45deg, transparent, transparent 10px, rgba(255,200,0,0.02) 10px, rgba(255,200,0,0.02) 20px);
  pointer-events: none;
}

.header-flag-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.flag-pixel {
  width: 80px;
  height: 54px;
  image-rendering: pixelated;
  border: 3px solid var(--c-gray2);
  box-shadow: 3px 3px 0 var(--c-navy);
  flex-shrink: 0;
}

.vs-badge {
  font-family: var(--font-pixel);
  font-size: 20px;
  color: var(--c-yellow);
  text-shadow: 3px 3px 0 var(--c-orange), -1px -1px 0 var(--c-navy);
  padding: 0.25rem 0.75rem;
  background: var(--c-navy);
  border: 2px solid var(--c-yellow);
  animation: pulse-border 2s infinite;
}

@keyframes pulse-border {
  0%, 100% { box-shadow: 0 0 0 2px var(--c-gold); }
  50%       { box-shadow: 0 0 0 4px var(--c-orange), 0 0 12px var(--c-yellow); }
}

.header-title {
  font-family: var(--font-pixel);
  font-size: clamp(10px, 2.5vw, 16px);    /* was clamp(8px…14px) — raised floor to 10px */
  color: var(--c-yellow);
  text-align: center;
  text-shadow: 2px 2px 0 var(--c-orange), 4px 4px 0 var(--c-navy);
  line-height: 1.8;
  margin-bottom: 0.5rem;
}

.header-subtitle {
  font-family: var(--font-vt);
  font-size: clamp(22px, 4vw, 30px);    /* was clamp(18px…26px) — VT323 needs 20px+ min */
  color: var(--c-sky);
  text-align: center;
  letter-spacing: 2px;
}

.header-edition {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 7px — unreadable below 10px */
  color: var(--c-gray2);
  text-align: center;
  margin-top: 0.5rem;
  letter-spacing: 1px;
  line-height: 1.8;    /* Press Start 2P lines overlapped when this text wrapped on mobile */
}

/* ── NAV BAR ── */
.nav-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 3px;
  margin-bottom: 1rem;    /* was 0.75rem */
  background: var(--c-gray4);
  padding: 4px;
  border: 2px solid var(--c-gray2);
}

.nav-bar a {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 7px — below legibility threshold */
  color: var(--c-white);
  background: var(--c-midblue);
  text-decoration: none;
  padding: 7px 12px;
  border: 2px solid;
  border-color: var(--c-sky) var(--c-navy) var(--c-navy) var(--c-sky);
  transition: all 0.1s;
}

.nav-bar a:hover {
  background: var(--c-blue);
  border-color: var(--c-yellow) var(--c-gold) var(--c-gold) var(--c-yellow);
  color: var(--c-yellow);
}

.nav-bar a:active {
  border-color: var(--c-navy) var(--c-sky) var(--c-sky) var(--c-navy);
}

/* ── MAIN LAYOUT ── */
.main-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  grid-template-rows: auto;
  gap: 1.25rem;    /* was 0.75rem — panels need breathing room */
  align-items: start;
}

@media (max-width: 720px) {
  .main-layout {
    /* minmax(0,1fr) lets the column shrink below its content's min-content width;
       a plain 1fr keeps min-width:auto and forces horizontal overflow on mobile */
    grid-template-columns: minmax(0, 1fr);
  }
  .sidebar { order: 2; }
  .content-area { order: 1; }
  /* allow grid/flex children to shrink instead of forcing the page wider than the screen */
  .content-area, .sidebar { min-width: 0; }
  .content-area > *, .sidebar > * { min-width: 0; max-width: 100%; }
}

/* ── SIDEBAR ── */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;    /* was 0.75rem */
}

.panel-title {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 8px — raised to minimum legible size */
  color: var(--c-navy);
  background: var(--c-yellow);
  padding: 6px 8px;
  margin: -1rem -1rem 0.75rem;
  border-bottom: 2px solid var(--c-gold);
  letter-spacing: 1px;
}

/* octopus box */
.octo-box {
  background: var(--c-darkblue);
  border: 3px solid var(--c-teal);
  box-shadow: 4px 4px 0 var(--c-navy);
  padding: 1rem;
  position: relative;
}

.octo-box::before {
  content: '';
  position: absolute;
  top: -1px; left: -1px; right: -1px; bottom: -1px;
  border: 1px solid rgba(0,153,136,0.3);
  pointer-events: none;
}

.octo-sprite {
  display: block;
  margin: 0 auto 0.75rem;
  image-rendering: pixelated;
}

.octo-speech {
  background: rgba(0,0,0,0.4);
  border: 2px solid var(--c-teal);
  padding: 0.4rem;
  font-family: var(--font-vt);
  font-size: 20px;    /* was 17px — VT323 needs 20px+ for comfortable reading */
  color: var(--c-gray1);
  line-height: 1.3;
  position: relative;
}

.octo-speech::before {
  content: '"';
  font-size: 40px;
  color: var(--c-teal);
  line-height: 0;
  position: absolute;
  top: 16px;
  left: 4px;
  font-family: Georgia, serif;
}

.octo-speech p { padding-left: 1.2rem; }

.octo-name {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 7px — unreadable; raised to minimum legible size */
  color: var(--c-teal);
  text-align: right;
  margin-top: 0.5rem;
  margin-bottom: 0.25rem;
  line-height: 1.8;
}

/* lore list */
.lore-panel {
  background: var(--c-darkblue);
  border: 3px solid var(--c-sky);
  box-shadow: 4px 4px 0 var(--c-navy);
  padding: 1rem;
  max-height: 400px;
  overflow-y: auto;
}

.lore-item {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-family: var(--font-vt);
  font-size: 20px;    /* was 16px — raised for VT323 legibility */
  color: var(--c-gray1);
  line-height: 1.3;
  border-bottom: 1px dashed var(--c-midblue);
  padding-bottom: 0.5rem;
}

.lore-item:last-child { border-bottom: none; margin-bottom: 0; }

.lore-icon {
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
  color: var(--c-yellow);
}

/* web ring widget */
.webring-box {
  background: var(--c-gray4);
  border: 2px inset var(--c-gray3);
  padding: 0.75rem;
  text-align: center;
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px — purely decorative; raised to minimum legible size */
  color: var(--c-gray2);
  line-height: 1.8;
}

.webring-box a {
  color: var(--c-sky);
  text-decoration: underline;
  cursor: pointer;
}

/* ── CONTENT AREA ── */
.content-area {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;    /* was 0.75rem — panels need breathing room */
}

/* section panels */
.section-panel {
  background: var(--c-darkblue);
  border: 3px solid var(--c-sky);
  box-shadow: 4px 4px 0 var(--c-navy);
  padding: 1.25rem;    /* was 1rem — a little more breathing room */
}

.section-panel.gold-border { border-color: var(--c-yellow); }
.section-panel.green-border { border-color: var(--c-green); }
.section-panel.red-border { border-color: var(--c-orange); }

.section-title {
  font-family: var(--font-pixel);
  font-size: 11px;    /* was 9px — below comfortable reading threshold */
  color: var(--c-yellow);
  text-shadow: 2px 2px 0 var(--c-orange);
  margin-bottom: 1.25rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--c-blue);    /* was --c-midblue which blends into --c-darkblue bg */
  letter-spacing: 1px;
}

/* ── TEAM OVERVIEW ── */
.team-overview {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: start;
}

@media (max-width: 500px) {
  .team-overview {
    grid-template-columns: 1fr;
  }
  .team-vs-divider { display: none; }
}

.team-card {
  background: rgba(0,0,0,0.3);
  border: 2px solid var(--c-midblue);
  padding: 0.75rem;
  text-align: center;
}

.team-card.brazil { border-color: #009c3b; }
.team-card.morocco { border-color: #c1272d; }

.team-name {
  font-family: var(--font-pixel);
  font-size: 11px;    /* was 9px */
  margin-bottom: 0.5rem;
  letter-spacing: 1px;
}

.team-card.brazil .team-name { color: #00c84e; }    /* was #009c3b — boosted for contrast */
.team-card.morocco .team-name { color: #e04040; }   /* was #c1272d — boosted for contrast */

.team-flag-large {
  display: block;
  margin: 0 auto 0.5rem;
  image-rendering: pixelated;
  border: 2px solid var(--c-gray3);
  box-shadow: 2px 2px 0 var(--c-navy);
}

.team-nickname {
  font-family: var(--font-vt);
  font-size: 21px;    /* was 18px — VT323 needs 20px+ */
  color: var(--c-gray2);
  margin-bottom: 0.25rem;
}

.team-founded {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px — entirely unreadable */
  color: var(--c-gray3);    /* using updated gray3 which is now #808080 ~4.5:1 */
}

.team-vs-divider {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-pixel);
}

.vs-text-sm {
  font-size: 10px;
  color: var(--c-gray2);
}

.head2head-score {
  font-family: var(--font-pixel);
  font-size: 14px;
  color: var(--c-yellow);
  text-shadow: 2px 2px 0 var(--c-orange);
  background: var(--c-navy);
  border: 2px solid var(--c-yellow);
  padding: 0.4rem 0.8rem;
  text-align: center;
  white-space: nowrap;
}

.h2h-label {
  font-size: 10px;    /* was 6px — unreadable; now at minimum for pixel font */
  font-family: var(--font-pixel);
  color: var(--c-gray2);    /* was --c-gray3 which was ~1.8:1 contrast */
  text-align: center;
}

/* ── PIXEL BAR CHARTS ── */
.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 500px) {
  .stats-grid { grid-template-columns: 1fr; }
}

.stat-section-label {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 7px — below legibility threshold */
  color: var(--c-sky);
  margin-bottom: 0.75rem;
  border-left: 4px solid var(--c-sky);
  padding-left: 0.5rem;
  letter-spacing: 1px;
}

.bar-row {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 1rem;    /* was 0.75rem */
}

.bar-label {
  font-family: var(--font-vt);
  font-size: 18px;    /* was 15px — VT323 needs 20px+ but 18px acceptable for labels */
  color: var(--c-gray2);
  display: flex;
  justify-content: space-between;
}

.bar-label span:last-child {
  color: var(--c-yellow);
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 9px — one pixel under threshold; raised */
}

.bar-track {
  height: 16px;
  background: var(--c-navy);
  border: 1px solid var(--c-gray3);
  position: relative;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  position: relative;
  transition: width 1s steps(20);
}

.bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent, transparent 3px, rgba(0,0,0,0.3) 3px, rgba(0,0,0,0.3) 4px);
}

.bar-fill.brazil { background: #009c3b; }
.bar-fill.morocco { background: #c1272d; }
.bar-fill.neutral { background: var(--c-sky); }
.bar-fill.gold { background: var(--c-yellow); }

.bar-track-dual {
  height: 16px;
  background: var(--c-navy);
  border: 1px solid var(--c-gray3);
  display: flex;
  overflow: hidden;
}

.bar-fill-left, .bar-fill-right {
  height: 100%;
  transition: width 1s steps(20);
}

.bar-fill-left { background: #009c3b; }
.bar-fill-right { background: #c1272d; }

.dual-bar-labels {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 7px — percentages were unreadable */
  margin-bottom: 3px;
}

.dual-bar-labels .br { color: #009c3b; }
.dual-bar-labels .ma { color: #c1272d; }

/* ── HISTORICAL TIDBITS ── */
.tidbits-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

@media (max-width: 500px) {
  .tidbits-grid { grid-template-columns: 1fr; }
}

.tidbit-card {
  background: rgba(0,0,0,0.35);
  border: 2px solid var(--c-midblue);
  padding: 0.6rem 0.75rem;
}

.tidbit-card.brazil-card { border-left: 4px solid #009c3b; }
.tidbit-card.morocco-card { border-left: 4px solid #c1272d; }

.tidbit-year {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 8px */
  color: var(--c-yellow);
  margin-bottom: 0.35rem;
}

.tidbit-text {
  font-family: var(--font-vt);
  font-size: 20px;    /* was 16px — raised to VT323 legibility threshold */
  color: var(--c-gray1);
  line-height: 1.65;    /* was 1.5 */
}

/* ── PIXEL SOCCER BALL ANIMATION ── */
.decoration-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.25rem 0;
  overflow: hidden;
}

.pixel-divider {
  flex: 1;
  height: 4px;
  background: repeating-linear-gradient(90deg, var(--c-midblue) 0px, var(--c-midblue) 8px, transparent 8px, transparent 12px);
}

.pixel-star {
  font-size: 12px;
  color: var(--c-yellow);
  animation: blink-star 1.5s step-end infinite;
}

@keyframes blink-star {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* ── FOOTER / HIT COUNTER ── */
.site-footer {
  margin-top: 1rem;
  background: var(--c-gray4);
  border: 3px solid var(--c-gray3);
  border-right-color: var(--c-gray2);
  border-bottom-color: var(--c-gray2);
  padding: 1.25rem 1rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.footer-left {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px — unreadable */
  color: var(--c-gray2);
  line-height: 2;
}

.footer-left a { color: var(--c-sky); text-decoration: none; }

.hit-counter {
  background: #000;
  border: 2px inset var(--c-gray3);
  padding: 4px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  align-self: center;
}

.hit-counter-label {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px */
  color: var(--c-green);
}

.hit-counter-digits {
  font-family: var(--font-vt);
  font-size: 22px;
  color: var(--c-green);
  letter-spacing: 2px;
  text-shadow: 0 0 4px var(--c-green);
  min-width: 80px;
}

.footer-right {
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px */
  color: var(--c-gray2);    /* was --c-gray3 which was ~1.8:1 contrast */
  text-align: right;
  line-height: 2;
}

.status-bar {
  display: flex;
  gap: 2px;
  margin-top: 0.25rem;
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px */
  color: var(--c-gray2);
}

/* Nokia-style mobile status strip — hidden on desktop, shown via @media below */
.status-bar-mobile { display: none; }

.status-segment {
  background: var(--c-gray4);
  border: 1px inset var(--c-gray3);
  padding: 6px 10px;
  flex: 1;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#status-msg {
  flex: 3;
}

@keyframes float-ball {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  33%       { transform: translateY(-8px) rotate(15deg); }
  66%       { transform: translateY(-4px) rotate(-10deg); }
}


/* ── TIMELINE ── */
/* moved from inline styles in timeline.njk — values unchanged */
.timeline-panel { border-color: var(--c-gold); margin-bottom: 0.75rem; }
/* horizontal padding gives the first/last year labels room so their outer digit
   is not clipped by the overflow-x edge (labels are centered on their node) */
#timeline-container { position: relative; padding: 1rem 1.25rem 0.5rem; overflow-x: auto; }
#timeline-track {
  position: relative; min-width: 700px; height: 4px;
  background: var(--c-midblue); margin: 40px 16px 40px;
}
.timeline-hint {
  font-family: var(--font-pixel); font-size: 10px; color: var(--c-gray2);
  text-align: center; margin-top: 0.25rem;
}
.timeline-node {
  position:absolute;top:50%;transform:translate(-50%,-50%);
  width:16px;height:16px;
  background:var(--c-yellow);border:2px solid var(--c-gold);
  box-shadow:2px 2px 0 var(--c-navy);
  cursor:pointer;transition:transform 0.1s;
}
.timeline-node:hover { transform:translate(-50%,-50%); }

.timeline-label-top {
  position:absolute;bottom:calc(100% + 14px);
  transform:translateX(-50%);
  font-family:var(--font-pixel);font-size:10px;
  color:var(--c-yellow);white-space:nowrap;
  text-align:center;line-height:1.8;
}

.timeline-label-bottom {
  position:absolute;top:calc(100% + 14px);
  transform:translateX(-50%);
  font-family:var(--font-pixel);font-size:10px;
  color:var(--c-yellow);white-space:nowrap;
  text-align:center;line-height:1.8;
}

.timeline-tooltip strong {
  display:block;font-family:var(--font-pixel);font-size:10px;    /* was 7px */
  color:var(--c-yellow);margin-bottom:4px;
}

.timeline-tooltip {
  position:fixed;z-index:2000;
  background:var(--c-darkblue);border:2px solid var(--c-sky);
  box-shadow:4px 4px 0 var(--c-navy);
  padding:0.5rem 0.75rem;
  font-family:var(--font-vt);font-size:18px;color:var(--c-gray1);
  max-width:220px;pointer-events:none;
  display:none;
}

.timeline-tooltip strong {
  display:block;font-family:var(--font-pixel);font-size:10px;
  color:var(--c-yellow);margin-bottom:4px;
}

/* ── TRIVIA ── */
.trivia-question {
  font-family:var(--font-vt);font-size:22px;color:var(--c-white);    /* was 20px */
  margin-bottom:0.75rem;line-height:1.6;    /* was 1.4 */
}

.trivia-options {
  display:grid;grid-template-columns:1fr 1fr;gap:0.5rem;
  margin-bottom:0.75rem;
}

@media (max-width:500px) { .trivia-options { grid-template-columns:1fr; } }

.trivia-btn {
  font-family:var(--font-vt);font-size:19px;    /* was 17px */
  color:var(--c-white);text-align:left;
  background:var(--c-navy);
  border:2px solid var(--c-midblue);
  padding:8px 12px;cursor:pointer;
  transition:border-color 0.1s,background 0.1s;
}
.trivia-btn:hover:not([disabled]) {
  border-color:var(--c-sky);background:rgba(68,153,221,0.12);
}
.trivia-btn.correct { border-color:var(--c-green)!important;background:rgba(0,170,68,0.18)!important;color:var(--c-green)!important; }
.trivia-btn.wrong   { border-color:var(--c-red)!important;background:rgba(204,34,0,0.15)!important;color:var(--c-red)!important; }

.trivia-result {
  font-family:var(--font-pixel);font-size:10px;    /* was 8px */
  padding:8px 10px;margin-bottom:0.6rem;letter-spacing:1px;
}
.trivia-result.pass { color:var(--c-green);border-left:4px solid var(--c-green); }
.trivia-result.fail { color:var(--c-red);border-left:4px solid var(--c-red); }

.trivia-next-btn {
  font-family:var(--font-pixel);font-size:10px;    /* was 7px */
  color:var(--c-navy);background:var(--c-teal);
  border:3px solid;border-color:var(--c-white) var(--c-gray3) var(--c-gray3) var(--c-white);
  padding:8px 16px;cursor:pointer;letter-spacing:1px;
  box-shadow:2px 2px 0 var(--c-navy);
}

.trivia-score {
  font-family:var(--font-pixel);font-size:10px;    /* was 7px; was also --c-gray3 invisible */
  color:var(--c-gray2);text-align:right;margin-bottom:0.6rem;
  padding-bottom:0.4rem;
  border-bottom:1px solid var(--c-midblue);
}

/* ── GUESTBOOK ENTRIES ── */
.gb-entry {
  border-top:1px dashed var(--c-midblue);padding:8px 0;
}
.gb-entry-name {
  font-family:var(--font-pixel);font-size:10px;    /* was 7px */
  color:var(--c-yellow);margin-bottom:3px;
}
.gb-entry-meta {
  font-family:var(--font-pixel);font-size:10px;    /* was 6px; was --c-gray3 invisible */
  color:var(--c-gray2);margin-bottom:5px;
}
.gb-entry-msg {
  font-family:var(--font-vt);font-size:19px;    /* was 16px */
  color:var(--c-gray1);line-height:1.6;
}

::-webkit-scrollbar { width: 16px; height: 16px; }
::-webkit-scrollbar-track { background: var(--c-gray4); }
::-webkit-scrollbar-thumb {
  background: var(--c-midblue);
  border: 2px solid var(--c-gray3);
  border-right-color: var(--c-gray1);
  border-bottom-color: var(--c-gray1);
}

/* ── BLINKING CURSOR ── */
.blink {
  animation: blink-cursor 1s step-end infinite;
}

@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* ── PIXEL TABLE ── */
.pixel-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-vt);
  font-size: 16px;
}

.pixel-table th {
  background: var(--c-navy);
  color: var(--c-yellow);
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 7px — huge inconsistency with 16px td; raised */
  padding: 8px 10px;
  text-align: left;
  border: 1px solid var(--c-midblue);
  letter-spacing: 1px;
}

.pixel-table td {
  padding: 7px 10px;
  border: 1px solid var(--c-navy);
  color: var(--c-gray1);
  font-size: 18px;    /* was 16px — VT323 raised */
}

.pixel-table tr:nth-child(even) td { background: rgba(255,255,255,0.04); }
.pixel-table tr:hover td { background: rgba(70,140,220,0.12); }
.pixel-table td:nth-child(3) { text-align: center; }

.td-br { color: #00cc44 !important; }
.td-ma { color: #ee3333 !important; }

/* ── MISC ── */
.inline-flag {
  display: inline-block;
  vertical-align: middle;
  image-rendering: pixelated;
  border: 1px solid var(--c-gray3);
  margin-right: 4px;
}

.badge {
  display: inline-block;
  font-family: var(--font-pixel);
  font-size: 10px;    /* was 6px — decorative but should be legible */
  padding: 3px 7px;
  letter-spacing: 1px;
}

.badge-new {
  background: var(--c-red);
  color: #fff;
  animation: blink-star 0.8s step-end infinite;
}

.badge-info {
  background: var(--c-sky);
  color: var(--c-navy);
}

.badge-gold {
  background: var(--c-yellow);
  color: var(--c-navy);
}

/* ── MOBILE TAP TARGETS ──
   Touch-only enlargement of interactive elements to meet minimum hit-area
   guidance (WCAG 2.5.5 / Apple HIG ≈ 44px). Scoped to the mobile breakpoint so
   the desktop layout is unchanged. Padding/min-height only — no color, font, or
   border changes (retro aesthetic preserved). */
@media (max-width: 500px) {
  /* footer links were ~10px tall — far below a usable tap target */
  .footer-left a {
    display: inline-block;
    padding: 7px 4px;
    min-height: 24px;
  }
  /* primary nav: ~28px tall → comfortable 44px touch height */
  .nav-bar a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
  /* trivia answer buttons: ~39px → 44px */
  .trivia-btn {
    min-height: 44px;
  }
  /* footer: stack and center its three columns on mobile (was left-aligned) */
  .site-footer {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  .footer-left,
  .footer-right {
    text-align: center;
  }

  /* ── Nokia-style status strip (replaces the cramped 3-segment Win95 bar) ── */
  .status-bar { display: none; }
  .status-bar-mobile {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 0.25rem;
    padding: 5px 9px;
    background: var(--c-gray4);
    border: 2px solid;
    border-color: var(--c-gray2) var(--c-gray1) var(--c-gray1) var(--c-gray2);
    font-family: var(--font-pixel);
    font-size: 10px;
    color: var(--c-gray1);
  }
  /* signal bars (▂▄▆ + one dim) */
  .status-bar-mobile .sig-bars {
    display: inline-flex;
    align-items: flex-end;
    gap: 1px;
    height: 9px;
  }
  .status-bar-mobile .sig-bars i { width: 2px; background: currentColor; }
  .status-bar-mobile .sig-bars i:nth-child(1) { height: 3px; }
  .status-bar-mobile .sig-bars i:nth-child(2) { height: 5px; }
  .status-bar-mobile .sig-bars i:nth-child(3) { height: 7px; }
  .status-bar-mobile .sig-bars i:nth-child(4) { height: 9px; opacity: 0.3; }
  .status-bar-mobile .sig-net { letter-spacing: 1px; }
  /* ink "battery" — pushed to the right with the clock */
  .status-bar-mobile .ink-batt {
    position: relative;
    display: inline-block;
    width: 22px;
    height: 11px;
    margin-left: auto;
    padding: 1px;
    border: 1px solid currentColor;
  }
  .status-bar-mobile .ink-batt::after {
    content: '';
    position: absolute;
    right: -3px;
    top: 3px;
    width: 2px;
    height: 5px;
    background: currentColor;
  }
  .status-bar-mobile .ink-fill {
    display: block;
    height: 100%;
    width: 87%;
    background: var(--c-teal);
    transition: width 0.6s linear;
  }
  .status-bar-mobile .ink-pct { color: var(--c-teal); }
  .status-bar-mobile .status-clock-m { min-width: 40px; text-align: right; }
}

/* ════════════════════════════════════════════════════════════
   HOMEPAGE
   Additive styles for the landing page only. No existing values
   above are changed — these are new selectors built from the same
   tokens, panels, and card patterns as the match page.
   ════════════════════════════════════════════════════════════ */

/* ── hero / masthead ── */
.home-hero {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.home-hero-octo { flex: 0 0 auto; }
.home-hero-octo .octo-sprite { margin: 0; }

.home-hero-text { flex: 1; min-width: 260px; }
.home-hero .header-title,
.home-hero .header-subtitle,
.home-hero .header-edition { text-align: left; }

.home-hero-speech { margin: 0.75rem 0 0.5rem; }

.home-cta {
  display: inline-block;
  margin-top: 0.75rem;
  font-family: var(--font-pixel);
  font-size: 11px;
  color: var(--c-navy);
  background: var(--c-yellow);
  border: 3px solid;
  border-color: var(--c-white) var(--c-gold) var(--c-gold) var(--c-white);
  padding: 10px 18px;
  text-decoration: none;
  letter-spacing: 1px;
  box-shadow: 3px 3px 0 var(--c-navy);
}
.home-cta:hover { background: var(--c-orange); color: #fff; }
.home-cta:active { border-color: var(--c-gold) var(--c-white) var(--c-white) var(--c-gold); }

@media (max-width: 600px) {
  .home-hero { justify-content: center; }
  .home-hero-text,
  .home-hero .header-title,
  .home-hero .header-subtitle,
  .home-hero .header-edition { text-align: center; }
}

/* ── featured match ── */
.home-featured {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
  text-decoration: none;
  color: inherit;
  background: rgba(0, 0, 0, 0.25);
  border: 2px solid var(--c-midblue);
  padding: 1rem;
  transition: border-color 0.1s, background 0.1s;
}
.home-featured:hover { border-color: var(--c-yellow); background: rgba(245, 200, 0, 0.06); }
.hf-side { text-align: center; }
.hf-flag svg {
  width: 90px;
  height: 60px;
  image-rendering: pixelated;
  border: 2px solid var(--c-gray3);
  box-shadow: 2px 2px 0 var(--c-navy);
}
.hf-name {
  font-family: var(--font-pixel);
  font-size: 11px;
  color: var(--c-white);
  margin-top: 0.5rem;
  letter-spacing: 1px;
}
.hf-vs {
  font-family: var(--font-pixel);
  font-size: 16px;
  color: var(--c-yellow);
  text-shadow: 2px 2px 0 var(--c-orange);
}
.home-featured-meta {
  margin-top: 0.5rem;
  font-family: var(--font-vt);
  font-size: 20px;
  color: var(--c-gray2);
  line-height: 1.4;
}

@media (max-width: 500px) {
  .home-featured { grid-template-columns: 1fr; }
}

/* ── archive card grid ── */
.home-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 0.75rem;
}
.home-card {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  background: rgba(0, 0, 0, 0.3);
  border: 2px solid var(--c-midblue);
  padding: 0.75rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.1s, transform 0.1s;
}
.home-card:hover { border-color: var(--c-sky); transform: translate(-1px, -1px); }
.hc-flags { display: flex; align-items: center; gap: 6px; }
.hc-flags svg {
  width: 40px;
  height: 27px;
  image-rendering: pixelated;
  border: 1px solid var(--c-gray3);
}
.hc-vs { font-family: var(--font-pixel); font-size: 10px; color: var(--c-yellow); }
.hc-title {
  font-family: var(--font-pixel);
  font-size: 10px;
  color: var(--c-white);
  line-height: 1.6;
}
.hc-meta { font-family: var(--font-vt); font-size: 18px; color: var(--c-gray2); line-height: 1.3; }

.home-card.ghost {
  align-items: center;
  justify-content: center;
  text-align: center;
  border-style: dashed;
  border-color: var(--c-gray3);
  color: var(--c-gray3);
  cursor: default;
  min-height: 110px;
}
.home-card.ghost:hover { transform: none; border-color: var(--c-gray3); }
.home-card.ghost span { font-family: var(--font-pixel); font-size: 10px; letter-spacing: 1px; }

.home-note {
  font-family: var(--font-vt);
  font-size: 18px;
  color: var(--c-gray2);
  margin-top: 0.75rem;
  text-align: center;
}

/* ── browse tiles ── */
.home-browse-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.75rem;
}
.home-browse-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  text-align: center;
  background: rgba(0, 0, 0, 0.3);
  border: 2px solid var(--c-midblue);
  padding: 1rem 0.75rem;
}
.home-browse-tile.soon { border-style: dashed; border-color: var(--c-gray3); }
.hb-icon { font-size: 26px; line-height: 1; }
.hb-title { font-family: var(--font-pixel); font-size: 10px; color: var(--c-yellow); letter-spacing: 1px; }
.hb-desc { font-family: var(--font-vt); font-size: 18px; color: var(--c-gray2); line-height: 1.4; }
