/* ==========================================================================
   Cooper Sizemore, classic view
   Phosphor green on true black. One loud moment (the hero), everything else quiet.
   ========================================================================== */

:root {
  --black: #000;
  --phosphor: #39ff6a;
  --text: #b9f2c7;
  --dim: #5f9a70;
  --rule: rgba(57, 255, 106, 0.2);

  --glow-sm: 0 0 2px rgba(57, 255, 106, 0.85), 0 0 8px rgba(57, 255, 106, 0.4);
  --glow: 0 0 2px #b6ffc8, 0 0 6px rgba(57, 255, 106, 0.9), 0 0 18px rgba(57, 255, 106, 0.55),
    0 0 42px rgba(57, 255, 106, 0.3);

  --crt: "VT323", ui-monospace, monospace;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* type scale, 1.25 ratio from a 16px base */
  --fs-sm: 0.8rem;
  --fs-base: 1rem;
  --fs-md: 1.25rem;
  --fs-lg: 1.95rem;
  --fs-xl: 2.45rem;

  --measure: 68ch;
  --max: 1040px;
  --nav-h: 60px;
  --gutter: clamp(20px, 6vw, 72px);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 24px);
}

body {
  margin: 0;
  background: var(--black);
  color: var(--text);
  font-family: var(--mono);
  font-size: var(--fs-base);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--phosphor);
  color: var(--black);
}

a {
  color: var(--phosphor);
  text-decoration: underline;
  text-decoration-color: rgba(57, 255, 106, 0.35);
  text-underline-offset: 3px;
}
a:hover {
  text-shadow: var(--glow-sm);
  text-decoration-color: var(--phosphor);
}
:focus-visible {
  outline: 2px solid var(--phosphor);
  outline-offset: 3px;
}

p {
  margin: 0;
}
ul,
ol,
dl,
dd {
  margin: 0;
  padding: 0;
  list-style: none;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  z-index: 100;
  padding: 6px 12px;
  background: var(--phosphor);
  color: var(--black);
}
.skip-link:focus {
  left: 8px;
}

/* CRT scanlines and vignette */
.crt {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  background: repeating-linear-gradient(to bottom, transparent 0, transparent 2px, rgba(0, 0, 0, 0.22) 3px),
    radial-gradient(ellipse at center, transparent 60%, rgba(0, 0, 0, 0.55) 100%);
}

.cursor {
  animation: blink 1.05s steps(1) infinite;
}
@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* --- Nav ----------------------------------------------------------------- */
.nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 0 var(--gutter);
  background: var(--black);
  border-bottom: 1px solid var(--rule);
}
.nav a {
  text-decoration: none;
}
.nav__logo {
  font-size: var(--fs-sm);
  font-weight: 500;
  text-shadow: var(--glow-sm);
  margin-right: auto;
}
.nav__links {
  display: flex;
  gap: 24px;
  font-size: var(--fs-sm);
}
.nav__links a {
  color: var(--text);
}
.nav__links a:hover,
.nav__links a.is-active {
  color: var(--phosphor);
}
.nav__links a.is-active::before {
  content: "> ";
}
.nav__term {
  padding: 6px 12px;
  border: 1px solid var(--phosphor);
  font-size: var(--fs-sm);
}
.nav__term:hover {
  background: var(--phosphor);
  color: var(--black);
  text-shadow: none;
}

/* --- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-block;
  padding: 10px 20px;
  border: 1px solid var(--phosphor);
  font-size: var(--fs-sm);
  font-weight: 500;
  text-decoration: none;
}
.btn:hover {
  text-shadow: none;
  background: rgba(57, 255, 106, 0.12);
}
.btn--solid {
  background: var(--phosphor);
  color: var(--black);
  box-shadow: 0 0 18px rgba(57, 255, 106, 0.45);
}
.btn--solid:hover {
  background: #8dffab;
  box-shadow: 0 0 28px rgba(57, 255, 106, 0.7);
}

/* --- Hero: the one loud moment ------------------------------------------ */
.hero {
  position: relative;
  min-height: 92vh;
  min-height: 92svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding: calc(var(--nav-h) + 40px) var(--gutter) 64px;
  border-bottom: 1px solid var(--rule);
}
.hero__rain {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.14;
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent);
  mask-image: linear-gradient(to bottom, #000 55%, transparent);
}
.hero__inner {
  position: relative;
  width: 100%;
  /* match the content width of .section so left edges line up */
  max-width: calc(var(--max) - 2 * var(--gutter));
  margin: 0 auto;
}
.hero__name {
  margin: 0;
  font-family: var(--crt);
  font-weight: 400;
  font-size: clamp(4rem, 13vw, 10rem);
  line-height: 0.85;
  color: var(--phosphor);
  text-shadow: var(--glow);
}
.hero__role {
  margin-top: 28px;
  font-size: var(--fs-md);
  color: var(--phosphor);
}
.hero__tagline {
  max-width: 52ch;
  margin-top: 12px;
}
.hero__status {
  margin-top: 20px;
  color: var(--phosphor);
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 24px;
  margin-top: 36px;
}
.hero__link {
  font-size: var(--fs-sm);
}

/* --- Sections ------------------------------------------------------------ */
.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 112px var(--gutter) 0;
}
.section__title {
  margin: 0 0 40px;
  font-family: var(--crt);
  font-weight: 400;
  font-size: var(--fs-xl);
  line-height: 1;
  color: var(--phosphor);
  text-shadow: var(--glow-sm);
}
.prompt {
  color: var(--dim);
  text-shadow: none;
}
.subhead {
  margin: 72px 0 24px;
  font-family: var(--crt);
  font-weight: 400;
  font-size: var(--fs-lg);
  line-height: 1;
  color: var(--phosphor);
}
.stack {
  margin-top: 12px;
  font-size: var(--fs-sm);
  color: var(--dim);
}

/* --- About --------------------------------------------------------------- */
.about {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}
.prose {
  max-width: var(--measure);
}
.prose p + p {
  margin-top: 1.1em;
}
.skills dt {
  color: var(--phosphor);
  font-weight: 500;
}
.skills dd {
  margin-bottom: 18px;
  font-size: 0.9rem;
}
.skills dd:last-child {
  margin-bottom: 0;
}

.lead-list {
  display: grid;
  gap: 22px;
  max-width: var(--measure);
}
.lead-list li {
  padding-left: 18px;
  border-left: 2px solid var(--phosphor);
}
.lead__role {
  color: var(--phosphor);
  font-weight: 500;
}

/* --- Experience: the timeline is a real sequence ------------------------- */
.timeline {
  display: grid;
  gap: 56px;
}
.job {
  display: grid;
  grid-template-columns: 9rem minmax(0, 1fr);
  gap: 32px;
}
.job__when {
  position: relative;
  color: var(--phosphor);
  font-size: 0.9rem;
}
.job__when span {
  display: block;
  color: var(--dim);
  font-size: var(--fs-sm);
}
.job__body {
  position: relative;
  max-width: var(--measure);
  padding-left: 32px;
  border-left: 1px solid var(--rule);
}
.job__body::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 0.5em;
  width: 9px;
  height: 9px;
  background: var(--phosphor);
  box-shadow: 0 0 10px var(--phosphor);
}
.job__title {
  margin: 0;
  font-size: var(--fs-md);
  font-weight: 500;
  line-height: 1.35;
  color: var(--text);
}
.job__org {
  color: var(--phosphor);
}
.bullets {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}
.bullets li {
  position: relative;
  padding-left: 22px;
}
.bullets li::before {
  content: ">";
  position: absolute;
  left: 0;
  color: var(--phosphor);
}

/* --- Projects ------------------------------------------------------------ */
.projects {
  display: grid;
  gap: 56px;
}
.project {
  max-width: var(--measure);
}
.project__title {
  margin: 0;
  font-family: var(--crt);
  font-weight: 400;
  font-size: var(--fs-xl);
  line-height: 1;
  color: var(--phosphor);
  text-shadow: var(--glow-sm);
}
.project__note {
  margin: 6px 0 12px;
  color: var(--dim);
  font-style: italic;
}
.project__link {
  display: inline-block;
  margin-top: 12px;
  margin-right: 24px;
  font-size: var(--fs-sm);
}
.more {
  margin-top: 56px;
}

/* --- Contact ------------------------------------------------------------- */
#contact {
  padding-bottom: 120px;
}
.contact__lead {
  max-width: 46ch;
  font-size: var(--fs-md);
  line-height: 1.5;
}
.contact .hero__actions {
  margin-top: 28px;
}

/* --- Footer -------------------------------------------------------------- */
.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 24px var(--gutter) 36px;
  border-top: 1px solid var(--rule);
  font-size: var(--fs-sm);
  color: var(--dim);
}

/* --- Responsive ---------------------------------------------------------- */
@media (max-width: 860px) {
  .nav {
    gap: 16px;
  }
  .nav__logo {
    display: none;
  }
  .nav__links {
    gap: 14px;
    margin-right: auto;
  }
  .about {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .job {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .job__when span {
    display: inline;
    margin-left: 10px;
  }
  .job__body {
    padding-left: 22px;
  }
}

@media (max-width: 520px) {
  .nav {
    padding: 0 14px;
    gap: 10px;
  }
  .nav__links {
    gap: 10px;
    font-size: 0.75rem;
  }
  .nav__term {
    padding: 5px 8px;
    font-size: 0.75rem;
  }
  .section {
    padding-top: 80px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  html {
    scroll-behavior: auto;
  }
}
