:root {
  color-scheme: dark;
  --ink: #f4f4f1;
  --muted: rgba(244, 244, 241, 0.58);
  --line: rgba(244, 244, 241, 0.2);
  --panel: rgba(0, 0, 0, 0.72);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  width: 100%;
  height: 100%;
}

body {
  overflow: hidden;
  background: #000;
  color: var(--ink);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 12px;
  letter-spacing: 0.04em;
}

a {
  color: inherit;
  text-decoration: none;
}

#thermal-canvas {
  position: fixed;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.site-shell {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-rows: auto 1fr auto;
  width: 100%;
  min-height: 100dvh;
  pointer-events: none;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 58px;
  padding: 0 22px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0));
  pointer-events: auto;
}

.brand {
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.brand:focus-visible,
.project-link:focus-visible,
.site-nav a:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 6px;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 40px);
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-nav a {
  transition: color 180ms ease;
}

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

.site-nav a[aria-current="page"]::before {
  content: "●";
  margin-right: 8px;
  font-size: 6px;
  vertical-align: 1px;
}

.stage-notes {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 22px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.stage-notes p:last-child {
  text-align: right;
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(170px, 0.8fr) minmax(300px, 1.2fr);
  border-top: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(12px);
  pointer-events: auto;
}

.footer-meta {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  min-height: 104px;
  padding: 18px 22px;
  border-right: 1px solid var(--line);
  color: var(--muted);
  font-size: 9px;
  line-height: 1.55;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-meta span:last-child {
  text-align: right;
}

.project-link {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 22px;
  min-height: 104px;
  padding: 16px 22px;
  transition: background 200ms ease, color 200ms ease;
}

.project-link:hover {
  background: var(--ink);
  color: #050505;
}

.project-number,
.project-type {
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-name {
  display: block;
  margin-bottom: 5px;
  font-size: clamp(18px, 2vw, 30px);
  font-weight: 500;
  letter-spacing: -0.02em;
}

.project-type {
  display: block;
  color: var(--muted);
}

.project-link:hover .project-type {
  color: rgba(5, 5, 5, 0.58);
}

.project-arrow {
  font-size: 25px;
  transition: transform 200ms ease;
}

.project-link:hover .project-arrow {
  transform: translate(4px, -4px);
}

.noscript-note {
  position: fixed;
  inset: 50% auto auto 50%;
  z-index: 5;
  transform: translate(-50%, -50%);
  color: var(--ink);
}

@media (max-width: 700px) {
  .site-header {
    align-items: flex-start;
    min-height: 78px;
    padding: 16px;
  }

  .site-nav {
    align-items: flex-end;
    flex-direction: column;
    gap: 8px;
  }

  .stage-notes {
    padding: 16px;
  }

  .stage-notes p:last-child {
    display: none;
  }

  .site-footer {
    grid-template-columns: 1fr;
  }

  .footer-meta {
    display: none;
  }

  .project-link {
    min-height: 94px;
    padding: 14px 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
