/* Kernel Bender splash / entry page (index.html).
   Neutral dark base: left half hints at the 1990s bevel look, right half at the Modern HUD look.
   Independent of style.css so the saved theme never restyles the splash itself. */
@font-face {
  font-family: "Press Start 2P";
  src: url("fonts/PressStart2P-Regular.ttf") format("truetype");
  font-display: swap;
}
:root {
  --bg: #07090c; --fg: #e3e9ef; --muted: #9aa7b4;
  --cyan: #39c6ff; --amber: #ffb43a;
  --steel: #b9b9b0; --steel-hi: #f2f2e6; --steel-d: #4b4b44; --olive: #5d6a3a; --olive-d: #48532c;
  --sans: "Bahnschrift", "Roboto Condensed", "Arial Narrow", "Helvetica Neue", system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --pixel: "Press Start 2P", "Courier New", monospace;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body.splash {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--fg); font: 17px/1.55 var(--sans);
}
a { color: var(--cyan); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }

.splash-main { position: relative; flex: 1; display: grid; place-items: center; padding: 2.5rem 1.25rem; overflow: hidden; }
.splash-halves { position: absolute; inset: 0; display: grid; grid-template-columns: 1fr 1fr; pointer-events: none; }
.half-modern {
  background:
    linear-gradient(rgba(57,198,255,.07) 1px, transparent 1px) 0 0 / 32px 32px,
    linear-gradient(90deg, rgba(57,198,255,.07) 1px, transparent 1px) 0 0 / 32px 32px,
    radial-gradient(ellipse at 30% 40%, rgba(57,198,255,.12), transparent 60%),
    #05080b;
  -webkit-mask-image: linear-gradient(270deg, #000 60%, transparent);
          mask-image: linear-gradient(270deg, #000 60%, transparent);
}
.half-retro {
  background-color: var(--olive);
  background-image:
    linear-gradient(45deg, var(--olive-d) 25%, transparent 25%, transparent 75%, var(--olive-d) 75%),
    linear-gradient(45deg, var(--olive-d) 25%, transparent 25%, transparent 75%, var(--olive-d) 75%);
  background-size: 24px 24px; background-position: 0 0, 12px 12px;
  opacity: .32;
  -webkit-mask-image: linear-gradient(90deg, #000 60%, transparent);
          mask-image: linear-gradient(90deg, #000 60%, transparent);
}

.splash-card {
  position: relative; width: min(760px, 100%); text-align: center;
  background: rgba(10,14,19,.88); border: 1px solid #23303d; border-radius: 6px;
  padding: clamp(1.5rem, 4vw, 3rem); box-shadow: 0 20px 60px rgba(0,0,0,.55);
}
.splash-brand { margin: 0 0 .6rem; display: flex; justify-content: center; }
/* Logo: both copies are in the markup; the saved theme (data-theme from theme-init.js) picks one. */
.logo-modern, .logo-modern img { display: block; }
.logo-retro { display: none; }
.splash-logo { width: clamp(150px, 36vw, 230px); height: auto; filter: drop-shadow(0 10px 24px rgba(0,0,0,.6)); }
html[data-theme="retro"] .logo-modern { display: none; }
html[data-theme="retro"] .logo-retro { display: block; image-rendering: pixelated; image-rendering: crisp-edges; filter: none; }
.splash-presents { margin: 0 0 1.75rem; color: var(--muted); font-size: .95rem; }
.splash-presents strong { color: var(--fg); font-weight: 600; }
.splash-presents span { font: .78rem/1.8 var(--mono); text-transform: uppercase; letter-spacing: .12em; }
.splash-q { margin: 0 0 1.25rem; font: 600 1.05rem/1.3 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }

.splash-choices { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.choice {
  display: flex; flex-direction: column; justify-content: center; gap: .55rem;
  min-height: 8.5rem; padding: 1.25rem 1rem; text-decoration: none; position: relative;
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
}
.choice:hover { transform: translateY(-2px); }
.choice-label { font-size: 1.2rem; font-weight: 700; line-height: 1.3; }
.choice-sub { font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; opacity: .85; }

/* Retro button: chunky bevel, pixel font, amber plate */
.choice-retro {
  background: var(--steel); color: #111;
  border: 4px solid; border-color: var(--steel-hi) var(--steel-d) var(--steel-d) var(--steel-hi);
  box-shadow: 4px 4px 0 #000;
  background-image: repeating-linear-gradient(0deg, rgba(0,0,0,.06) 0 2px, transparent 2px 4px);
}
.choice-retro .choice-label { font-family: var(--pixel); font-size: clamp(.8rem, 2.2vw, 1rem); line-height: 1.6; color: #1d2410; text-shadow: 1px 1px 0 var(--steel-hi); }
.choice-retro .choice-sub { font-family: "Courier New", Courier, monospace; font-weight: 700; color: #3a2a00; }
.choice-retro:hover { background-color: #d2d2c6; }
.choice-retro:active { border-color: var(--steel-d) var(--steel-hi) var(--steel-hi) var(--steel-d); box-shadow: 1px 1px 0 #000; transform: translate(3px,3px); }

/* Modern button: thin HUD frame, cyan glow, corner ticks */
.choice-modern {
  background: linear-gradient(180deg, rgba(57,198,255,.10), rgba(57,198,255,.02));
  color: var(--fg); border: 1px solid rgba(57,198,255,.55); border-radius: 4px;
  box-shadow: inset 0 0 0 1px rgba(57,198,255,.08), 0 0 24px rgba(57,198,255,.12);
}
.choice-modern::before, .choice-modern::after {
  content: ""; position: absolute; width: 14px; height: 14px; border: 2px solid var(--cyan);
}
.choice-modern::before { top: -2px; left: -2px; border-right: 0; border-bottom: 0; }
.choice-modern::after { bottom: -2px; right: -2px; border-left: 0; border-top: 0; }
.choice-modern .choice-label { letter-spacing: .02em; }
.choice-modern .choice-sub { font-family: var(--mono); color: var(--cyan); }
.choice-modern:hover { box-shadow: inset 0 0 0 1px rgba(57,198,255,.2), 0 0 32px rgba(57,198,255,.28); }

/* Saved choice highlight (set by script.js) */
.choice.is-saved { outline: 3px solid var(--amber); outline-offset: 5px; }
.choice.is-saved .choice-sub::after { content: "\A Your last pick"; white-space: pre; color: var(--amber); }
.choice-retro.is-saved .choice-sub::after { color: #7a4a00; }

.splash-saved { margin: 1.4rem 0 0; color: var(--muted); font-size: .95rem; }
.splash-saved strong { color: var(--fg); }
.splash-skip { margin-left: .35rem; font-weight: 600; }
.splash-note { margin: 1rem 0 0; color: var(--muted); font-size: .85rem; }

.splash-footer { position: relative; text-align: center; padding: 1rem; font: .8rem/1.4 var(--mono); color: var(--muted); border-top: 1px solid #1a242e; }

@media (max-width: 560px) {
  .splash-choices { grid-template-columns: 1fr; }
  .choice { min-height: 6.5rem; }
  .splash-halves { grid-template-columns: 1fr; grid-template-rows: 1fr 1fr; }
  .half-modern { -webkit-mask-image: linear-gradient(0deg, #000 60%, transparent); mask-image: linear-gradient(0deg, #000 60%, transparent); }
  .half-retro { -webkit-mask-image: linear-gradient(180deg, #000 60%, transparent); mask-image: linear-gradient(180deg, #000 60%, transparent); }
}
@media (prefers-reduced-motion: reduce) {
  .choice { transition: none; }
  .choice:hover, .choice-retro:active { transform: none; }
}
