/* Fried Games — Continuum archive chrome
   Tokens from Living to Die: Continuum (index.css / ContinuumChrome). */

:root {
  --bg: #070608;
  --bg-elevated: #100e12;
  --bg-subtle: #18151c;
  --fg: #ebe6e8;
  --fg-muted: #9a9098;
  --fg-subtle: #6a6268;
  --border: #2a2430;
  --border-strong: #3e3648;
  --bone: #c4b8b0;
  --bone-ink: #0a080a;
  --danger: #a84848;
  --watch: #a88858;
  --font-serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --font-sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --max: 70rem;
  --gutter: clamp(1.15rem, 4.2vw, 2.4rem);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--bone);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--fg);
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--bone);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 100;
  padding: 0.45rem 0.8rem;
  background: var(--bg-subtle);
  color: var(--fg);
  border: 1px solid var(--border-strong);
}

.skip:focus {
  top: 0.75rem;
}

/* ── Atmosphere chrome (matches ContinuumChrome) ── */

.chrome-washes,
.chrome-photo,
.chrome-paper,
.continuum-grain,
.archive-grid,
.red-string,
.chrome-vignette {
  pointer-events: none;
  position: fixed;
  inset: 0;
}

.chrome-washes {
  z-index: 0;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(42, 18, 24, 0.55), transparent 50%),
    radial-gradient(ellipse at 90% 90%, rgba(18, 24, 32, 0.45), transparent 45%),
    #070608;
}

.chrome-photo {
  z-index: 1;
  background-image: url("../ui/continuum-bg.jpg");
  background-size: cover;
  background-position: center;
  opacity: 0.4;
}

.chrome-paper {
  z-index: 2;
  background-image: url("../ui/panel-texture.jpg");
  opacity: 0.12;
  mix-blend-mode: soft-light;
}

.red-string {
  z-index: 6;
  width: 100%;
  height: 100%;
}

.archive-grid {
  z-index: 7;
  background-image:
    linear-gradient(rgba(196, 184, 176, 0.016) 1px, transparent 1px),
    linear-gradient(90deg, rgba(196, 184, 176, 0.016) 1px, transparent 1px);
  background-size: 56px 56px;
}

.continuum-grain {
  z-index: 8;
  opacity: 0.35;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.chrome-vignette {
  z-index: 9;
  background: radial-gradient(ellipse at center, transparent 42%, rgba(0, 0, 0, 0.55) 100%);
}

.site {
  position: relative;
  z-index: 10;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.wrap {
  width: min(100% - var(--gutter) * 2, var(--max));
  margin-inline: auto;
}

/* ── Type ── */

.eyebrow {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

.hub-title {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(2.75rem, 8vw, 4.25rem);
  line-height: 0.95;
  letter-spacing: -0.02em;
  color: var(--fg);
  text-shadow: 0 0 28px rgba(196, 184, 176, 0.28), 0 2px 0 #000;
}

/* ── Mast ── */

.mast {
  border-bottom: 1px solid var(--border);
  background: rgba(16, 14, 18, 0.72);
  backdrop-filter: blur(12px);
}

.mast::after {
  content: "";
  display: block;
  height: 1px;
  background: var(--watch);
  opacity: 0.45;
}

.mast-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.4rem;
  padding-block: 0.55rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--fg);
  text-decoration: none;
}

.wordmark:hover {
  color: var(--bone);
}

.wordmark-mark {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.wordmark-fried {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: 0.04em;
}

.wordmark-games {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.15rem;
}

.nav a {
  color: var(--fg-muted);
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--bone);
}

/* ── Page ── */

.page {
  flex: 1;
  padding-block: clamp(2rem, 6vw, 4.5rem) 3.5rem;
}

.hero {
  padding-top: clamp(0.55rem, 2vw, 1.1rem);
  padding-bottom: clamp(2rem, 5vw, 3.4rem);
  margin-bottom: clamp(1.6rem, 4vw, 2.6rem);
  border-bottom: 1px solid var(--border);
}

.hero-lockup {
  display: grid;
  gap: 0;
  max-width: 38rem;
}

.ca-line {
  margin: 0.85rem 0 0;
  display: grid;
  gap: 0.28rem;
}

.ca-ticker {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-muted);
}

.ca-addr {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.75rem;
  color: var(--fg-subtle);
  word-break: break-all;
  text-decoration: none;
}

.ca-addr:hover {
  color: var(--bone);
}

.ca-foot a {
  color: var(--fg-subtle);
  text-decoration: none;
  word-break: break-all;
}

.ca-foot a:hover {
  color: var(--bone);
}

.lede {
  margin: 0;
  max-width: 28rem;
  color: var(--fg-muted);
  font-size: 1.05rem;
}

/* ── Case-file cards ── */

.shelf-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin: 0 0 1.1rem;
}

.shelf-head h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 600;
}

.shelf-note {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}

.shelf {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.15rem;
}

@media (min-width: 760px) {
  .shelf {
    grid-template-columns: 1fr 1fr;
    gap: 1.35rem;
  }
}

.panel-chrome {
  position: relative;
  border-radius: 1rem;
  border: 1px solid rgba(62, 54, 72, 0.8);
  background: rgba(16, 14, 18, 0.75);
  backdrop-filter: blur(12px);
}

.panel-chrome::before,
.panel-chrome::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border-color: rgba(196, 184, 176, 0.35);
  border-style: solid;
  pointer-events: none;
}

.panel-chrome::before {
  top: 8px;
  left: 8px;
  border-width: 1px 0 0 1px;
}

.panel-chrome::after {
  bottom: 8px;
  right: 8px;
  border-width: 0 1px 1px 0;
}

.card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  padding: 1.5rem 1.45rem 1.3rem 1.7rem;
  color: inherit;
  text-decoration: none;
  overflow: hidden;
}

.card:hover {
  color: inherit;
  border-color: rgba(196, 184, 176, 0.45);
}

.card:focus-visible {
  outline-offset: 4px;
}

.watch-rail {
  position: absolute;
  left: 10px;
  top: 28%;
  width: 2.5px;
  height: 38%;
  border-radius: 2px;
  background: var(--watch);
  box-shadow: 0 0 8px var(--watch);
}

.card h3 {
  margin: 0.45rem 0 0.55rem;
  font-family: var(--font-serif);
  font-size: clamp(1.55rem, 3vw, 1.95rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.card p {
  margin: 0 0 1.2rem;
  color: var(--fg-muted);
  flex: 1;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: auto;
}

.stamp {
  display: inline-block;
  padding: 0.28rem 0.55rem 0.24rem;
  border: 1px solid rgba(62, 54, 72, 0.8);
  color: var(--bone);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

/* ── Title pages ── */

.title-hero {
  display: grid;
  gap: 1.5rem;
  padding-bottom: 2rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

@media (min-width: 860px) {
  .title-hero {
    grid-template-columns: minmax(0, 1.4fr) minmax(14rem, 0.7fr);
    align-items: end;
  }
}

.page-title {
  margin: 0.35rem 0 0.7rem;
}

.status-panel {
  padding: 1.15rem 1.2rem 1.2rem;
}

.status-panel h2 {
  margin: 0 0 0.55rem;
}

.status-panel p {
  margin: 0;
  color: var(--fg-muted);
  font-size: 0.95rem;
}

.prose {
  display: grid;
  gap: 1.7rem;
  max-width: 40rem;
}

.prose h2 {
  margin: 0 0 0.45rem;
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 600;
}

.prose p {
  margin: 0;
  color: var(--fg-muted);
}

.back {
  display: inline-block;
  margin-bottom: 1.4rem;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--fg-subtle);
}

.back:hover {
  color: var(--bone);
}

/* ── Footer ── */

.colophon {
  margin-top: auto;
  padding-block: 1.25rem 1.45rem;
  border-top: 1px solid var(--border);
  background: rgba(7, 6, 8, 0.72);
}

.colophon-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem 1.5rem;
}

.lockup {
  margin: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--fg);
}

.fine {
  margin: 0;
  font-size: 0.78rem;
  color: var(--fg-subtle);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .card,
  a {
    transition: none;
  }
}

@media (max-width: 389px) {
  .hub-title {
    font-size: 2.4rem;
  }

  .nav {
    gap: 0.3rem 0.75rem;
  }

  .wordmark-games {
    display: none;
  }
}
