/* ==========================================================================
   kiyra — little worlds for the terminal
   A hand-built midnight room. No frameworks, no external assets.
   ========================================================================== */

:root {
  --ink: #070810;
  --ink-soft: #0a0c18;
  --panel: #0e1120;
  --panel-2: #121629;
  --text: #ece8f7;
  --muted: #a49dbd;
  --dim: #8d86a8;
  --lav: #c9b8f4;
  --lav-soft: #a796d8;
  --pink: #efa7c8;
  --pink-soft: #d78bb0;
  --mint: #9fe6c4;
  --gold: #f1d6a4;
  --line: rgba(201, 184, 244, 0.14);
  --line-strong: rgba(201, 184, 244, 0.3);
  --mono: "JetBrains Mono", "Cascadia Code", "Cascadia Mono", "SFMono-Regular",
    ui-monospace, Menlo, Consolas, "DejaVu Sans Mono", monospace;
  --sans: "Inter", "Avenir Next", "Segoe UI", system-ui, -apple-system,
    BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino,
    Georgia, serif;
  --page: 1180px;
  --pad: clamp(20px, 4.2vw, 56px);
  --header-h: 64px;
}

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

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

body {
  margin: 0;
  min-width: 280px;
  overflow-x: clip;
  background-color: var(--ink);
  background-image:
    radial-gradient(ellipse 68% 46% at 14% -2%, rgba(140, 123, 217, 0.13), transparent 68%),
    radial-gradient(ellipse 42% 32% at 88% 15%, rgba(239, 167, 200, 0.055), transparent 72%),
    radial-gradient(ellipse 64% 44% at 50% 105%, rgba(159, 230, 196, 0.035), transparent 72%);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent 3px,
    rgba(255, 255, 255, 0.012) 3px,
    rgba(255, 255, 255, 0.012) 4px
  );
  opacity: 0.55;
}

::selection {
  background: var(--lav);
  color: var(--ink);
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

p,
h1,
h2,
h3,
blockquote,
figure {
  margin-top: 0;
}

h1,
h2,
h3 {
  text-wrap: balance;
}

button {
  font: inherit;
}

code,
pre,
.mono {
  font-family: var(--mono);
  font-variant-ligatures: none;
}

.mono {
  color: var(--lav);
  font-size: 0.92em;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 3px;
  border-radius: 1px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 11px 16px;
  border: 1px solid var(--mint);
  background: var(--ink);
  color: var(--mint);
  font-family: var(--mono);
  font-size: 12px;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.shell {
  width: min(100%, calc(var(--page) + (var(--pad) * 2)));
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 8, 16, 0.78);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(12px, 2vw, 28px);
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  flex: none;
  color: var(--text);
  font-family: var(--mono);
  text-decoration: none;
}

.brand-mark {
  color: var(--pink);
  font-size: 13px;
  transition: transform 320ms ease;
}

.brand:hover .brand-mark {
  transform: rotate(45deg) scale(1.2);
}

.brand-name {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.brand-path {
  color: var(--dim);
  font-size: 10px;
  letter-spacing: 0.03em;
}

.primary-nav {
  min-width: 0;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2.2vw, 28px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-list a {
  position: relative;
  display: inline-block;
  padding-block: 4px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11.5px;
  text-decoration: none;
  white-space: nowrap;
  transition: color 160ms ease;
}

.nav-list a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: var(--pink);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 220ms ease;
}

.nav-list a:hover,
.nav-list a.is-active {
  color: var(--text);
}

.nav-list a:hover::after,
.nav-list a.is-active::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav-num {
  margin-right: 3px;
  color: var(--dim);
  font-size: 8px;
  vertical-align: super;
}

.nav-list .nav-github {
  color: var(--mint);
}

.nav-list .nav-github::after {
  background: var(--mint);
}

.header-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex: none;
  margin: 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.status-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 8px rgba(159, 230, 196, 0.65);
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  isolation: isolate;
  overflow: clip;
  padding-block: clamp(56px, 8.5vh, 108px) clamp(68px, 9vw, 118px);
}

.hero::after {
  content: "";
  position: absolute;
  right: -10%;
  bottom: -38%;
  z-index: -1;
  width: 60vw;
  height: 60vw;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(140, 123, 217, 0.08), transparent 64%);
  pointer-events: none;
}

.hero-stars {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.hero-stars span {
  position: absolute;
  top: var(--y);
  left: var(--x);
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  background: var(--lav);
  opacity: 0.2;
  animation: twinkle 6.5s ease-in-out infinite;
  animation-delay: var(--delay);
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0.12;
    transform: scale(0.85);
  }
  50% {
    opacity: 0.72;
    transform: scale(1);
  }
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(300px, 0.84fr);
  align-items: center;
  gap: clamp(36px, 6.5vw, 88px);
}

.hero-copy {
  min-width: 0;
}

.eyebrow {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px;
  margin-bottom: clamp(22px, 3vw, 34px);
  color: var(--dim);
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.055em;
}

.prompt {
  margin-right: 8px;
  color: var(--mint);
}

.cursor {
  margin-left: 2px;
  color: var(--pink);
  animation: blink 1.15s steps(1, end) infinite;
}

@keyframes blink {
  0%,
  48% {
    opacity: 1;
  }
  49%,
  100% {
    opacity: 0;
  }
}

.hero h1 {
  margin-bottom: clamp(24px, 3.4vw, 38px);
  font-family: var(--mono);
  font-size: clamp(2.55rem, 4.55vw, 4rem);
  font-weight: 600;
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.h1-line {
  display: block;
}

.accent {
  color: var(--pink);
  text-decoration: underline;
  text-decoration-color: rgba(239, 167, 200, 0.55);
  text-decoration-style: wavy;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.14em;
}

.hero-lede {
  max-width: 54ch;
  margin-bottom: 26px;
  color: var(--muted);
  font-size: clamp(0.98rem, 1.1vw, 1.06rem);
  line-height: 1.75;
}

.hero-lede strong {
  color: var(--text);
  font-weight: 600;
}

.interest-line {
  display: flex;
  flex-wrap: wrap;
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
  color: var(--lav-soft);
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.025em;
}

.interest-line li {
  display: inline-flex;
  align-items: center;
}

.interest-line li:not(:last-child)::after {
  content: "·";
  margin-inline: 0.7em;
  color: var(--dim);
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px 24px;
  margin-bottom: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 17px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.2;
  text-decoration: none;
  transition:
    background-color 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    transform 180ms ease,
    box-shadow 180ms ease;
}

.button-primary {
  border-color: var(--lav);
  background: rgba(201, 184, 244, 0.06);
  color: var(--text);
  box-shadow: 3px 3px 0 rgba(201, 184, 244, 0.08);
}

.button-primary:hover {
  background: var(--lav);
  color: var(--ink);
  transform: translateY(-2px);
  box-shadow: 4px 6px 0 rgba(201, 184, 244, 0.12);
}

.text-link {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11.5px;
  text-decoration: none;
  border-bottom: 1px dashed var(--line-strong);
  padding-bottom: 3px;
  transition: color 160ms ease, border-color 160ms ease;
}

.text-link:hover {
  color: var(--pink);
  border-color: var(--pink);
}

.hero-footnote {
  margin: 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.025em;
}

.footnote-mark {
  margin-right: 5px;
  color: var(--gold);
}

.hero-footnote a {
  color: var(--lav-soft);
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
}

.hero-footnote a:hover {
  color: var(--lav);
}

/* Mascot window */

.mascot-stage {
  position: relative;
  min-width: 0;
}

.mascot-window {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background:
    radial-gradient(ellipse 70% 55% at 74% 10%, rgba(201, 184, 244, 0.08), transparent 60%),
    linear-gradient(170deg, var(--panel-2), #090b16 82%);
  box-shadow:
    0 28px 80px rgba(0, 0, 0, 0.34),
    9px 9px 0 rgba(201, 184, 244, 0.035);
}

.mascot-window::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(125deg, rgba(255, 255, 255, 0.035), transparent 26%);
}

.window-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 8, 16, 0.35);
  color: var(--dim);
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.045em;
}

.window-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--lav-soft);
}

.window-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 7px rgba(159, 230, 196, 0.7);
}

.window-body {
  position: relative;
  padding: clamp(16px, 3vw, 28px) clamp(12px, 2.4vw, 24px) 14px;
}

.mascot-art {
  width: max-content;
  max-width: 100%;
  margin: 0 auto;
  overflow-x: auto;
  color: var(--lav);
  font-family: var(--mono);
  font-size: clamp(8px, 1.15vw, 14px);
  line-height: 1.3;
  white-space: pre;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}

.art-stars {
  color: var(--dim);
}

.art-moon {
  color: var(--gold);
  text-shadow: 0 0 14px rgba(241, 214, 164, 0.24);
}

.art-star {
  color: var(--pink);
}

.art-cat {
  color: var(--lav);
  text-shadow: 0 0 16px rgba(201, 184, 244, 0.18);
}

.art-tail {
  color: var(--mint);
  animation: blink 1.6s steps(1, end) infinite;
}

.art-sill {
  color: var(--dim);
}

.mascot-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.mascot-status {
  margin: 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.025em;
}

.pet-button {
  flex: none;
  padding: 6px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: transparent;
  color: var(--lav);
  font-family: var(--mono);
  font-size: 9.5px;
  line-height: 1.2;
  cursor: pointer;
  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease;
}

.pet-button:hover {
  border-color: var(--pink);
  background: rgba(239, 167, 200, 0.08);
  color: var(--pink);
}

.pet-button:active {
  transform: translateY(1px);
}

.pet-sparks {
  position: absolute;
  inset: 22% 8% 28%;
  overflow: hidden;
  pointer-events: none;
}

.pet-sparks span {
  position: absolute;
  color: var(--pink);
  font-family: var(--mono);
  font-size: 12px;
  opacity: 0;
}

.pet-sparks span:nth-child(1) {
  top: 48%;
  left: 20%;
}

.pet-sparks span:nth-child(2) {
  top: 34%;
  right: 18%;
}

.pet-sparks span:nth-child(3) {
  top: 66%;
  left: 34%;
}

.pet-sparks span:nth-child(4) {
  top: 20%;
  left: 55%;
}

.is-petted .pet-sparks span {
  animation: sparkle 1.4s ease-out;
}

.is-petted .pet-sparks span:nth-child(2) {
  animation-delay: 90ms;
}

.is-petted .pet-sparks span:nth-child(3) {
  animation-delay: 170ms;
}

.is-petted .pet-sparks span:nth-child(4) {
  animation-delay: 260ms;
}

@keyframes sparkle {
  0% {
    opacity: 0;
    transform: translateY(6px) scale(0.7);
  }
  18% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateY(-24px) scale(1.1);
  }
}

.window-foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 12px;
  border-top: 1px dashed var(--line);
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
}

.window-foot span {
  color: var(--pink);
}

.stage-note {
  margin: 12px 0 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.12em;
  text-align: right;
}

/* --------------------------------------------------------------------------
   Shared section shell
   -------------------------------------------------------------------------- */

.section {
  padding-block: clamp(64px, 9vw, 112px);
  border-top: 1px solid var(--line);
  scroll-margin-top: calc(var(--header-h) + 18px);
}

.section-grid {
  display: grid;
  grid-template-columns: 146px minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
}

.section-label {
  position: sticky;
  top: calc(var(--header-h) + 30px);
}

.section-kicker {
  margin: 0;
  color: var(--lav);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.section-kicker span {
  margin-right: 4px;
  color: var(--pink);
}

.section-aside {
  max-width: 16ch;
  margin: 10px 0 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 9.5px;
  line-height: 1.55;
  letter-spacing: 0.02em;
}

.section-content {
  min-width: 0;
}

.section-intro {
  margin-bottom: clamp(34px, 4.5vw, 54px);
}

.section-intro h2,
.prose h2 {
  margin-bottom: 22px;
  font-family: var(--mono);
  font-size: clamp(2rem, 3.55vw, 3.15rem);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.section-intro > p {
  max-width: 62ch;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.8;
}

/* --------------------------------------------------------------------------
   About
   -------------------------------------------------------------------------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.32fr) minmax(225px, 0.62fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}

.prose p {
  max-width: 63ch;
  margin-bottom: 19px;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.82;
}

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

.pull-quote {
  max-width: 30ch;
  margin: clamp(30px, 4vw, 44px) 0 0;
  padding-left: clamp(18px, 2.5vw, 26px);
  border-left: 1px solid var(--pink);
}

.pull-quote p {
  margin: 0;
  color: var(--text);
  font-family: var(--serif);
  font-size: clamp(1.28rem, 1.9vw, 1.62rem);
  font-style: italic;
  line-height: 1.42;
  letter-spacing: -0.01em;
}

.why-note {
  position: sticky;
  top: calc(var(--header-h) + 32px);
  border: 1px solid var(--line);
  border-radius: 2px;
  background: linear-gradient(160deg, rgba(18, 22, 41, 0.85), rgba(10, 12, 24, 0.85));
  box-shadow: 5px 5px 0 rgba(201, 184, 244, 0.035);
  font-family: var(--mono);
}

.note-bar {
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  color: var(--dim);
  font-size: 9px;
  letter-spacing: 0.06em;
}

.note-bar span {
  margin-right: 5px;
  color: var(--pink);
}

.note-body {
  padding: 16px;
  color: var(--dim);
  font-size: 10px;
  line-height: 1.8;
}

.note-body p {
  margin: 0;
}

.note-output {
  margin: 12px 0 18px;
  color: var(--lav);
  font-size: 11.5px;
  line-height: 1.75;
}

.note-small {
  padding-top: 13px;
  border-top: 1px dashed var(--line);
  font-size: 9px;
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   Projects
   -------------------------------------------------------------------------- */

.project-list {
  min-width: 0;
}

.project {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(270px, 0.78fr);
  gap: clamp(30px, 5vw, 68px);
  align-items: center;
  padding-block: clamp(42px, 6vw, 72px);
}

.project + .project {
  border-top: 1px dashed var(--line);
}

.project:first-child {
  padding-top: 8px;
}

.project-flip .project-copy {
  order: 2;
}

.project-flip .project-visual {
  order: 1;
}

.project-copy {
  min-width: 0;
}

.project-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-bottom: 16px;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.project-index {
  padding: 2px 6px;
  border: 1px solid var(--line-strong);
  color: var(--pink);
  letter-spacing: 0.06em;
}

.project-status {
  margin-left: auto;
  color: var(--mint);
}

.project-status::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 4px;
  margin-right: 6px;
  border-radius: 50%;
  background: currentColor;
  vertical-align: 1px;
}

.project h3 {
  margin-bottom: 8px;
  font-family: var(--mono);
  font-size: clamp(1.9rem, 3.2vw, 2.7rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.045em;
}

.project-kicker {
  margin-bottom: 18px;
  color: var(--pink);
  font-family: var(--serif);
  font-size: 1.1rem;
  font-style: italic;
  line-height: 1.45;
}

.project-copy > p:not(.project-kicker) {
  max-width: 60ch;
  margin-bottom: 15px;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.78;
}

.detail-list {
  display: grid;
  gap: 9px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.detail-list li {
  display: flex;
  align-items: baseline;
  gap: 9px;
  max-width: 64ch;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 10.5px;
  line-height: 1.65;
}

.detail-list li span[aria-hidden] {
  flex: none;
  color: var(--lav-soft);
}

.project-foot {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px 20px;
  margin-top: 24px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.tech-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.tech-list li:not(:last-child)::after {
  content: "/";
  margin-inline: 0.65em;
  color: var(--line-strong);
}

.project-link {
  color: var(--lav);
  font-family: var(--mono);
  font-size: 10.5px;
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 2px;
  transition: color 160ms ease, border-color 160ms ease;
}

.project-link:hover {
  color: var(--pink);
  border-color: var(--pink);
}

.project-visual {
  min-width: 0;
}

.term {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: linear-gradient(165deg, rgba(18, 22, 41, 0.92), rgba(8, 10, 18, 0.96));
  box-shadow: 7px 7px 0 rgba(201, 184, 244, 0.035);
  transition: border-color 220ms ease, transform 220ms ease;
}

.term:hover {
  border-color: rgba(201, 184, 244, 0.45);
  transform: translateY(-2px);
}

.term-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 10px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 8, 16, 0.32);
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.045em;
}

.term-title {
  color: var(--lav-soft);
}

.term pre {
  margin: 0;
  padding: clamp(15px, 2.4vw, 22px) clamp(11px, 2vw, 20px);
  overflow-x: auto;
  color: var(--muted);
  font-family: var(--mono);
  font-size: clamp(7.5px, 1vw, 10.5px);
  line-height: 1.45;
  white-space: pre;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}

.term-accent {
  color: var(--lav);
}

.term-rule {
  color: var(--line-strong);
}

.term-mint {
  color: var(--mint);
}

.term-pink {
  color: var(--pink);
}

.term-dim {
  color: #615b7b;
}

.term-vynl pre {
  color: var(--lav-soft);
}

.term-vynl .term-mint {
  color: var(--mint);
}

.term-grimmoire pre {
  color: var(--muted);
  background: radial-gradient(ellipse at 50% 40%, rgba(140, 123, 217, 0.07), transparent 70%);
}

.figcaption {
  margin: 10px 0 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  line-height: 1.5;
  letter-spacing: 0.025em;
  text-align: right;
}

/* --------------------------------------------------------------------------
   Interests
   -------------------------------------------------------------------------- */

.interest-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: clamp(30px, 5vw, 64px);
  border-top: 1px solid var(--line);
}

.interest {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 12px;
  padding: 24px 0 25px;
  border-bottom: 1px dashed var(--line);
}

.interest-mark {
  padding-top: 1px;
  color: var(--lav);
  font-family: var(--mono);
  font-size: 15px;
  line-height: 1.4;
}

.interest h3 {
  margin-bottom: 7px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.interest p {
  max-width: 44ch;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.7;
}

.interest-ground {
  margin: 26px 0 0;
  padding-left: 14px;
  border-left: 1px solid var(--line-strong);
  color: var(--dim);
  font-family: var(--mono);
  font-size: 10px;
  line-height: 1.75;
}

.interest-ground span {
  margin-right: 6px;
  color: var(--pink);
}

/* --------------------------------------------------------------------------
   Notes
   -------------------------------------------------------------------------- */

.note-list {
  border-top: 1px solid var(--line);
  margin-bottom: clamp(38px, 5vw, 52px);
}

.note {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 18px;
  padding: 26px 0;
  border-bottom: 1px dashed var(--line);
}

.note-index {
  margin: 2px 0 0;
  color: var(--pink);
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.07em;
}

.note h3 {
  margin-bottom: 8px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.note p:not(.note-index) {
  max-width: 65ch;
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.78;
}

.desk {
  border: 1px solid var(--line);
  border-radius: 2px;
  background: linear-gradient(165deg, rgba(18, 22, 41, 0.72), rgba(9, 11, 22, 0.8));
  box-shadow: 5px 5px 0 rgba(201, 184, 244, 0.03);
}

.desk-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 16px;
  padding: 12px 16px;
  border-bottom: 1px dashed var(--line);
  font-family: var(--mono);
}

.desk-head p {
  margin: 0;
}

#desk-title {
  color: var(--lav);
  font-size: 11px;
}

.desk-note {
  color: var(--dim);
  font-size: 8.5px;
  letter-spacing: 0.03em;
}

.desk-list {
  margin: 0;
  padding: 0 16px;
  list-style: none;
}

.desk-list li {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.88rem;
  line-height: 1.65;
}

.desk-list li:last-child {
  border-bottom: 0;
}

.desk-list a {
  align-self: start;
  color: var(--lav);
  font-family: var(--mono);
  font-size: 10.5px;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 160ms ease, border-color 160ms ease;
}

.desk-list a:hover {
  color: var(--pink);
  border-color: var(--pink);
}

.desk-list span {
  color: var(--dim);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  position: relative;
  padding-block: clamp(54px, 7vw, 86px) 26px;
  border-top: 1px solid var(--line-strong);
  background: linear-gradient(to bottom, rgba(13, 16, 30, 0.35), rgba(7, 8, 16, 0.8));
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.05fr) auto;
  align-items: center;
  gap: clamp(28px, 5vw, 64px);
}

.footer-art {
  margin: 0;
  overflow: hidden;
  color: var(--lav);
  font-family: var(--mono);
  font-size: clamp(10px, 0.95vw, 13px);
  line-height: 1.35;
  white-space: pre;
}

.footer-kicker {
  margin-bottom: 10px;
  color: var(--pink);
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.footer-signoff {
  margin-bottom: 14px;
  font-family: var(--mono);
  font-size: clamp(1.65rem, 2.85vw, 2.55rem);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.footer-line {
  margin: 0;
  color: var(--dim);
  font-size: 0.9rem;
  line-height: 1.65;
}

.footer-nav {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 9px;
  font-family: var(--mono);
  font-size: 10px;
}

.footer-nav a {
  color: var(--dim);
  text-decoration: none;
  border-bottom: 1px dashed transparent;
  transition: color 160ms ease, border-color 160ms ease;
}

.footer-nav a:hover {
  color: var(--lav);
  border-color: var(--line-strong);
}

.footer-bottom {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin-top: clamp(38px, 5vw, 54px);
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--dim);
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.025em;
}

.footer-bottom p {
  margin: 0;
}

.footer-bottom a {
  color: var(--lav-soft);
  text-decoration: none;
  border-bottom: 1px dashed transparent;
  transition: color 160ms ease, border-color 160ms ease;
}

.footer-bottom a:hover {
  color: var(--lav);
  border-color: var(--line-strong);
}

.footer-note {
  color: var(--lav-soft);
  opacity: 0.7;
}

/* --------------------------------------------------------------------------
   404
   -------------------------------------------------------------------------- */

.not-found {
  display: flex;
  align-items: center;
  min-height: calc(100svh - var(--header-h) - 280px);
  padding-block: clamp(64px, 10vw, 120px);
}

.not-found-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.72fr);
  align-items: center;
  gap: clamp(32px, 6vw, 84px);
  width: 100%;
}

.not-found-code {
  margin: 0 0 16px;
  color: var(--lav);
  font-family: var(--mono);
  font-size: clamp(5rem, 14vw, 10rem);
  font-weight: 600;
  line-height: 0.82;
  letter-spacing: -0.09em;
}

.not-found-code span {
  color: var(--pink);
}

.not-found h1 {
  margin-bottom: 18px;
  font-family: var(--mono);
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.035em;
}

.not-found-copy {
  max-width: 46ch;
  margin-bottom: 26px;
  color: var(--muted);
  font-size: 0.96rem;
  line-height: 1.75;
}

.not-found-art {
  margin: 0;
  color: var(--lav);
  font-family: var(--mono);
  font-size: clamp(9px, 1.25vw, 12.5px);
  line-height: 1.45;
  white-space: pre;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1040px) {
  .header-status {
    display: none;
  }

  .section-grid {
    grid-template-columns: 126px minmax(0, 1fr);
    gap: 34px;
  }

  .project {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 0.72fr);
    gap: 34px;
  }
}

@media (max-width: 880px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 52px;
  }

  .hero-copy {
    max-width: 680px;
  }

  .mascot-stage {
    width: min(100%, 540px);
    margin-inline: auto;
  }

  .mascot-art {
    font-size: clamp(9px, 2.15vw, 14px);
  }

  .section-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .section-label {
    position: static;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
    padding-bottom: 11px;
    border-bottom: 1px dashed var(--line);
  }

  .section-aside {
    max-width: none;
    margin: 0;
    text-align: right;
  }

  .about-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 38px;
  }

  .why-note {
    position: static;
    max-width: 420px;
  }

  .project,
  .project-flip {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .project-flip .project-copy,
  .project-flip .project-visual {
    order: initial;
  }

  .project-visual {
    width: min(100%, 540px);
  }

  .project-flip .project-visual {
    margin-left: auto;
  }

  .term pre {
    font-size: clamp(8px, 1.5vw, 11.5px);
  }

  .not-found-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 38px;
  }

  .not-found-art {
    font-size: clamp(9px, 2vw, 12.5px);
  }
}

@media (max-width: 700px) {
  :root {
    --header-h: 58px;
  }

  .brand-path {
    display: none;
  }

  .nav-num {
    display: none;
  }

  .nav-list {
    gap: 14px;
  }

  .nav-list a {
    font-size: 10.5px;
  }

  .hero h1 {
    font-size: clamp(1.85rem, 9.2vw, 3rem);
  }

  .hero-lede {
    font-size: 0.96rem;
  }

  .interest-line {
    font-size: 9.5px;
  }

  .hero-actions {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }

  .project h3 {
    font-size: clamp(1.8rem, 7vw, 2.3rem);
  }

  .project-kicker {
    font-size: 1rem;
  }

  .interest-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .interest {
    grid-template-columns: 32px minmax(0, 1fr);
    padding-block: 20px;
  }

  .note {
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 12px;
  }

  .desk-list li {
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 12px;
  }

  .footer-top {
    grid-template-columns: minmax(0, 1fr);
    gap: 34px;
  }

  .footer-art {
    font-size: 12px;
  }

  .footer-nav {
    align-items: flex-start;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 6px;
  }
}

@media (max-width: 460px) {
  .shell {
    padding-inline: 18px;
  }

  .header-inner {
    gap: 10px;
  }

  .brand-name {
    font-size: 14px;
  }

  .nav-list {
    gap: 9px;
  }

  .nav-list a {
    font-size: 9.5px;
  }

  .hero h1 {
    font-size: clamp(1.72rem, 9.6vw, 2.5rem);
  }

  .mascot-art {
    font-size: 9px;
  }

  .window-bar {
    font-size: 8.5px;
  }

  .window-meta {
    display: none;
  }

  .term pre {
    font-size: 8px;
  }

  .section-intro h2,
  .prose h2 {
    font-size: clamp(1.8rem, 8.8vw, 2.45rem);
  }

  .project-meta {
    font-size: 8px;
  }

  .project-status {
    margin-left: 0;
  }

  .detail-list li {
    font-size: 10px;
  }

  .desk-list {
    padding-inline: 13px;
  }

  .desk-list li {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
  }

  .desk-list a {
    justify-self: start;
  }
}

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */

@media (max-width: 380px) {
  .brand {
    gap: 5px;
  }

  .brand-name {
    font-size: 13px;
  }

  .nav-list {
    gap: 6px;
  }

  .nav-list a {
    font-size: 8.5px;
  }
}

@media (max-width: 330px) {
  .brand-name {
    display: none;
  }

  .nav-list {
    gap: 5px;
  }

  .nav-list a {
    font-size: 8px;
  }

  .hero h1 {
    font-size: clamp(1.5rem, 8.8vw, 2.2rem);
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .hero-stars span {
    opacity: 0.35;
  }

  .cursor,
  .art-tail {
    opacity: 1;
  }
}

/* --------------------------------------------------------------------------
   Print
   -------------------------------------------------------------------------- */

@media print {
  body {
    background: #fff;
    color: #111;
  }

  body::before,
  .site-header,
  .hero-stars,
  .pet-sparks,
  .pet-button,
  .stage-note,
  .skip-link {
    display: none !important;
  }

  .shell {
    max-width: none;
  }

  a {
    text-decoration: underline;
  }
}
