:root {
  color-scheme: dark;
  --page-max: 900px;
  --hero-overlap: 12rem;
  --sky: #80c8f8;
  --paper: #121212;
  --ink: #e8e4dc;
  --muted: #b8b4ac;
  --accent: #e8e4dc;
  --term: #7dca82;
  --rule: #2c2a26;
}

* { box-sizing: border-box; }

@font-face {
  font-family: "ComputerFont";
  src: url("fonts/dos.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "ComputerFont", monospace;
  background: var(--paper);
  color: var(--ink);
  word-spacing: 0.12em;
  letter-spacing: 0.01em;
  white-space: normal;
  overflow-x: clip;
}

.hero-hold {
  position: relative;
  padding-bottom: var(--hero-overlap);
  overflow: hidden;
}

.hero {
  position: relative;
  z-index: 0;
  background: var(--sky);
}

.hero-hold + .section {
  position: relative;
  z-index: 1;
  margin-top: calc(0px - var(--hero-overlap));
}

@media (prefers-reduced-motion: no-preference) {
  .hero {
    will-change: transform;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-hold {
    padding-bottom: 0;
  }

  .hero-hold + .section {
    margin-top: 0;
  }
}

.hero-crt {
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 0 36px rgba(0, 0, 0, 0.12);
  filter: contrast(1.35) brightness(1.08) saturate(1.1);
}

.hero-art {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  user-select: none;
}

.hero-crt-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* Scanlines — same as live root .screen-area::before */
.hero-crt::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.15),
    rgba(0, 0, 0, 0.15) 1px,
    transparent 1px,
    transparent 2px
  );
  pointer-events: none;
  z-index: 2;
}

/* Vignette — same as live root .screen-area::after */
.hero-crt::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 115% 110% at 50% 50%, transparent 62%, rgba(0, 0, 0, 0.12) 82%, rgba(0, 0, 0, 0.28) 100%),
    linear-gradient(to right, rgba(0, 0, 0, 0.08) 0%, transparent 12%, transparent 88%, rgba(0, 0, 0, 0.08) 100%),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.06) 0%, transparent 12%, transparent 88%, rgba(0, 0, 0, 0.06) 100%);
  pointer-events: none;
  z-index: 1;
}

.hero-fade {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4.5rem;
  background: linear-gradient(to bottom, transparent, var(--paper));
  pointer-events: none;
  z-index: 3;
}

.page {
  position: relative;
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
}

.section {
  padding: 1.75rem 1.25rem;
}

.section--lead {
  padding: 1.75rem 1.25rem 1.35rem;
}

.section + .section {
  border-top: 2px solid var(--rule);
}

.section:last-child {
  padding-bottom: 3.5rem;
}

/* Static wash + thin pixel strip. No parallax. Real backdrops later. */
.section--still {
  background-color: #141414;
  background-image: repeating-linear-gradient(
    90deg,
    #1d1d1d 0 2px,
    #151515 2px 4px
  );
  background-size: 100% 6px;
  background-repeat: no-repeat;
  background-position: top;
}

.panel {
  width: 100%;
  max-width: 48rem;
  margin: 0 auto;
  padding: 1.75rem 1.35rem;
  background: var(--paper);
}

.eyebrow {
  margin: 0 0 0.35rem;
  font-family: "ComputerFont", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  word-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

h1, h2, h3, .panel p, .links a {
  word-spacing: 0.12em;
  letter-spacing: 0.01em;
  white-space: normal;
}

h1, h2, h3 {
  font-weight: normal;
  font-synthesis: none;
  letter-spacing: 0;
  word-spacing: 0.04em;
}

h1 {
  margin: 0 0 0.7rem;
  font-size: 1.25rem;
  line-height: 1.35;
}

h2 {
  margin: 0 0 0.65rem;
  font-size: 1.12rem;
  line-height: 1.35;
}

h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  line-height: 1.4;
  font-family: "ComputerFont", monospace;
}

h1::before, h1::after,
h2::before, h2::after,
h3::before, h3::after,
.section::before, .section::after {
  content: none;
}

.welcome {
  text-align: center;
  font-size: 1rem;
  line-height: 1.5;
  margin: 0 0 0.45rem;
}

.jump {
  display: flex;
  justify-content: center;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  margin: 0 0 1.35rem;
  font-family: "ComputerFont", monospace;
  font-size: 1rem;
  word-spacing: 0.12em;
}

.jump-sep {
  color: var(--muted);
  user-select: none;
}

.whoami-copy {
  overflow: auto;
}

.whoami-photo {
  float: left;
  width: clamp(8.5rem, 30vw, 11rem);
  height: auto;
  margin: 0.15rem 1.15rem 0.7rem 0;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  user-select: none;
}

.panel p {
  margin: 0 0 1rem;
  line-height: 1.6;
}

.panel p:last-child {
  margin-bottom: 0;
}

.links {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: "ComputerFont", monospace;
}

.links li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 0.75rem;
  align-items: baseline;
}

.jump a,
.links a,
.back-top a {
  color: var(--accent);
  text-decoration: none;
}

.jump a:hover,
.links a:hover,
.back-top a:hover {
  color: var(--term);
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

.jump a:focus-visible,
.links a:focus-visible,
.back-top a:focus-visible {
  color: var(--term);
  outline: 1px dotted var(--term);
  outline-offset: 2px;
}

.back-top {
  margin: 0;
  padding: 0 1.25rem 2.5rem;
  text-align: center;
  font-family: "ComputerFont", monospace;
  font-size: 1rem;
  word-spacing: 0.12em;
}

.link-note {
  color: var(--muted);
}

.gallery-cat {
  margin: 0 0 1.5rem;
}

.gallery-cat:last-child {
  margin-bottom: 0;
}

.gallery-cat-desc {
  margin: -0.15rem 0 0.75rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
  word-spacing: 0.12em;
  letter-spacing: 0.01em;
  white-space: pre-wrap;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.4rem;
}

.gallery-item {
  margin: 0;
  min-width: 0;
  aspect-ratio: 1 / 1;
  position: relative;
}

.gallery-thumb {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 2px solid var(--rule);
  background: #0c0c0c;
  cursor: pointer;
}

.gallery-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-empty {
  margin: 0;
  color: var(--muted);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(0, 0, 0, 0.86);
  cursor: pointer;
}

.lightbox[hidden] {
  display: none;
}

.lightbox-frame {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
  max-height: 100%;
}

.lightbox img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 10rem);
  width: auto;
  height: auto;
}

.lightbox-caption {
  margin: 0.85rem 0 0;
  max-width: min(42rem, 100%);
  color: var(--ink);
  font-family: "ComputerFont", monospace;
  font-size: 1rem;
  line-height: 1.6;
  word-spacing: 0.12em;
  letter-spacing: 0.01em;
  text-align: left;
}

.lightbox-caption[hidden] {
  display: none;
}

@media (max-width: 720px) {
  :root { --hero-overlap: 6rem; }
  .section { padding: 1.5rem 1rem; }
  .section--lead { padding: 1.25rem 1rem 1.1rem; }
  .section:last-child { padding-bottom: 2.75rem; }
  .panel { padding: 1.35rem 1.1rem; }
  .back-top { padding: 0 1rem 2rem; }
}
