@import url("https://fonts.googleapis.com/css2?family=Grenze+Gotisch:wght@500;600&family=IBM+Plex+Mono:wght@400;500&family=Instrument+Sans:wdth,wght@75..100,400..700&display=swap");

:root {
  --charcoal: #282828;
  --black: #0f0f0f;
  --paper: #d3d2d1;
  --paper-light: #efefec;
  --mid: #5d595a;
  --red: #bf0000;
  --white: #ffffff;

  --font-sans: "Instrument Sans", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  --font-neo: "Grenze Gotisch", Georgia, serif;

  --line: 1px solid var(--mid);
  --header-h: 68px;
  --max: 1720px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--charcoal);
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--paper);
  color: var(--black);
  font-family: var(--font-sans);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
}

body.is-locked {
  overflow: hidden;
}

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

button,
a {
  color: inherit;
  font: inherit;
}

button {
  border-radius: 0;
}

a {
  text-decoration: none;
}

button,
a,
[tabindex] {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 5000;
  padding: 10px 12px;
  transform: translateY(-160%);
  border: 1px solid var(--black);
  background: var(--white);
  font: 12px/1 var(--font-mono);
}

.skip-link:focus {
  transform: none;
}

/* Header */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 1000;
  min-height: var(--header-h);
  display: grid;
  grid-template-columns: minmax(210px, 380px) 1fr;
  align-items: center;
  gap: 24px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--black);
  background: rgba(211, 210, 209, .96);
  backdrop-filter: blur(14px);
}

.brand {
  width: fit-content;
}

.brand img {
  width: min(340px, 42vw);
  height: 30px;
  object-fit: contain;
  object-position: left center;
}

.primary-nav {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
  font: 11px/1 var(--font-mono);
  text-transform: uppercase;
}

.primary-nav a,
.primary-nav button,
.menu-toggle {
  min-height: 42px;
  padding: 0 11px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
}

.primary-nav a:hover,
.primary-nav button:hover,
.primary-nav a:focus-visible,
.primary-nav button:focus-visible {
  border-color: var(--black);
  background: var(--paper-light);
}

.menu-toggle {
  display: none;
}

/* Intro */

.intro {
  position: relative;
  min-height: 86svh;
  max-width: var(--max);
  margin: 0 auto;
  padding: calc(var(--header-h) + 48px) 24px 48px;
  overflow: hidden;
  border-right: 1px solid var(--mid);
  border-left: 1px solid var(--mid);
  background: var(--paper);
}

.micro-label,
.section-number {
  margin: 0;
  font: 10px/1.2 var(--font-mono);
  letter-spacing: .04em;
  text-transform: uppercase;
}

.intro h1 {
  margin: clamp(90px, 14vh, 160px) 0 0;
  font-size: clamp(90px, 17vw, 300px);
  font-weight: 620;
  font-stretch: 82%;
  line-height: .67;
  letter-spacing: -.095em;
  text-transform: uppercase;
}

.intro h1 span {
  display: block;
}

.intro .neo-word {
  width: fit-content;
  margin-left: 21%;
  font-family: var(--font-neo);
  font-weight: 500;
  letter-spacing: -.045em;
  text-transform: none;
}

.intro-aside {
  position: absolute;
  right: 6%;
  bottom: 11%;
  width: min(300px, 27vw);
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  align-items: start;
}

.intro-aside p {
  margin: 0;
  font-size: 14px;
  line-height: 1.25;
}

.sigil-text {
  font-family: var(--font-neo);
  font-size: 38px;
  line-height: .8;
}

.intro-coordinate {
  position: absolute;
  top: 26%;
  right: 24px;
  writing-mode: vertical-rl;
  font: 10px/1.2 var(--font-mono);
  text-transform: uppercase;
}

.intro-coordinate span {
  color: var(--red);
}

.intro-sigil {
  position: absolute;
  right: 11%;
  top: 18%;
  width: clamp(80px, 10vw, 150px);
  opacity: .93;
}

/* Battle */

.battle-section {
  max-width: var(--max);
  margin: 0 auto;
  border-right: 1px solid var(--mid);
  border-left: 1px solid var(--mid);
  background: var(--charcoal);
  color: var(--paper-light);
}

.battle-header {
  min-height: 142px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 20px;
  padding: 24px;
  border-top: 1px solid var(--black);
  border-bottom: 1px solid var(--mid);
}

.battle-header h2 {
  margin: 16px 0 0;
  font-size: clamp(42px, 6vw, 92px);
  font-weight: 560;
  font-stretch: 80%;
  line-height: .8;
  letter-spacing: -.065em;
}

.battle-tools {
  display: flex;
  align-items: center;
  gap: 15px;
  font: 10px/1 var(--font-mono);
  text-transform: uppercase;
}

.battle-tools p {
  margin: 0;
}

.battle-tools button {
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--paper);
  background: transparent;
  color: var(--paper-light);
  cursor: pointer;
}

.battle-tools button:hover {
  background: var(--red);
}

.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--red);
}

.battle-ground {
  position: relative;
  height: clamp(1250px, 135vw, 2180px);
  min-height: 1250px;
  overflow: hidden;
  background: var(--charcoal);
  isolation: isolate;
}

.board-grid {
  position: absolute;
  inset: 0;
  opacity: .22;
  background-image:
    linear-gradient(to right, var(--mid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--mid) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(to bottom, black, transparent 88%);
}

.board-cross {
  position: absolute;
  z-index: 0;
  width: 40px;
  height: 40px;
  opacity: .7;
}

.board-cross::before,
.board-cross::after {
  content: "";
  position: absolute;
  background: var(--paper);
}

.board-cross::before {
  top: 19px;
  left: 0;
  width: 40px;
  height: 1px;
}

.board-cross::after {
  top: 0;
  left: 19px;
  width: 1px;
  height: 40px;
}

.cross-a {
  top: 6%;
  left: 48%;
}

.cross-b {
  right: 7%;
  bottom: 12%;
}

.board-instruction {
  position: sticky;
  top: calc(var(--header-h) + 10px);
  z-index: 60;
  width: fit-content;
  display: flex;
  gap: 18px;
  margin: 0;
  padding: 10px 12px;
  border-right: 1px solid var(--paper);
  border-bottom: 1px solid var(--paper);
  background: var(--red);
  color: var(--white);
  font: 10px/1 var(--font-mono);
  text-transform: uppercase;
}

.project-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
}

/* Cards */

.project-card {
  --accent: var(--red);
  position: absolute;
  z-index: var(--z, 2);
  left: var(--x);
  top: var(--y);
  width: var(--w);
  transform: rotate(var(--r));
  transform-origin: center center;
  transition:
    transform 220ms cubic-bezier(.2, .8, .2, 1),
    filter 220ms ease,
    box-shadow 220ms ease;
  will-change: transform;
}

.project-card:nth-child(3n) {
  mix-blend-mode: normal;
}

.project-card.is-moving {
  z-index: 900 !important;
  transition: none;
}

.project-surface {
  position: relative;
  width: 100%;
  padding: 0;
  overflow: visible;
  border: 1px solid var(--paper);
  background: var(--paper);
  color: var(--black);
  box-shadow: 12px 12px 0 rgba(0, 0, 0, .42);
}

.project-card:hover,
.project-card:focus-within {
  z-index: 850 !important;
  transform: rotate(0deg) scale(1.065);
  filter: saturate(1.05);
}

.project-card:hover .project-surface,
.project-card:focus-within .project-surface {
  box-shadow: 20px 20px 0 var(--red);
}

.project-open {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: zoom-in;
}

.project-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 9px;
  min-height: 38px;
  padding: 7px 8px;
  border-bottom: 1px solid var(--black);
  background: var(--paper);
  font: 9px/1 var(--font-mono);
  text-transform: uppercase;
}

.project-index {
  color: var(--red);
  font-weight: 500;
}

.drag-handle {
  position: relative;
  z-index: 4;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  margin: -7px -8px -7px 0;
  padding: 0;
  border: 0;
  border-left: 1px solid var(--black);
  background: transparent;
  cursor: grab;
  font: 16px/1 var(--font-mono);
}

.drag-handle:active {
  cursor: grabbing;
}

.project-image {
  position: relative;
  display: block;
  aspect-ratio: var(--ratio);
  overflow: hidden;
  background: var(--black);
}

.project-image::before,
.project-image::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.project-image::before {
  z-index: 1;
  opacity: 0;
  background:
    radial-gradient(120% 60% at 12% 16%, rgba(255,255,255,.88) 0%, rgba(255,255,255,0) 26%),
    radial-gradient(90% 52% at 78% 24%, rgba(242,242,242,.52) 0%, rgba(255,255,255,0) 22%),
    radial-gradient(95% 55% at 42% 68%, rgba(198,198,198,.45) 0%, rgba(255,255,255,0) 28%),
    linear-gradient(110deg, rgba(255,255,255,0) 18%, rgba(255,255,255,.58) 34%, rgba(213,213,213,.12) 47%, rgba(255,255,255,.64) 62%, rgba(255,255,255,0) 82%);
  mix-blend-mode: screen;
  filter: blur(10px) contrast(1.25);
  transform: translate3d(-7%, 0, 0) scale(1.08) rotate(-2.2deg);
  transition: opacity 260ms ease, transform 520ms cubic-bezier(.2,.8,.2,1), filter 260ms ease;
}

.project-image::after {
  z-index: 2;
  opacity: 0;
  background:
    linear-gradient(130deg, rgba(255,255,255,.18), rgba(255,255,255,0) 24%, rgba(255,255,255,.22) 48%, rgba(255,255,255,0) 72%),
    linear-gradient(180deg, rgba(0,0,0,0), rgba(255,255,255,.09));
  mix-blend-mode: soft-light;
  transition: opacity 220ms ease;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04) contrast(1.04);
  transition: transform 500ms cubic-bezier(.2, .8, .2, 1), filter 260ms ease;
}

.project-card:hover .project-image::before,
.project-card:focus-within .project-image::before {
  opacity: .92;
  transform: translate3d(8%, 0, 0) scale(1.12) rotate(1.15deg);
  animation: liquidSweep 1.45s ease-in-out infinite alternate;
}

.project-card:hover .project-image::after,
.project-card:focus-within .project-image::after {
  opacity: .68;
}

.project-card:hover .project-image img,
.project-card:focus-within .project-image img {
  transform: scale(1.04);
  filter: saturate(1.12) contrast(1.08) brightness(1.02);
}

.project-copy {
  display: block;
  padding: 11px 12px 13px;
  border-top: 1px solid var(--black);
}

.project-copy h3 {
  max-width: 95%;
  margin: 0;
  font-size: clamp(23px, 2.4vw, 48px);
  font-weight: 620;
  font-stretch: 80%;
  line-height: .86;
  letter-spacing: -.055em;
  text-transform: uppercase;
}

.project-copy p {
  margin: 11px 0 0;
  font: 10px/1.3 var(--font-mono);
  text-transform: uppercase;
}

.project-mark {
  position: absolute;
  right: -18px;
  bottom: 18%;
  z-index: 8;
  padding: 6px 8px;
  border: 1px solid var(--black);
  background: var(--red);
  color: var(--white);
  font: 9px/1 var(--font-mono);
  transform: rotate(90deg);
  transform-origin: center;
  text-transform: uppercase;
}

.project-card.shape-shield .project-image {
  clip-path: polygon(7% 0, 93% 0, 100% 9%, 100% 80%, 50% 100%, 0 80%, 0 9%);
}

.project-card.shape-codex .project-surface {
  border-radius: 48% 48% 0 0 / 6% 6% 0 0;
}

.project-card.shape-codex .project-head {
  padding-top: 14px;
}

.project-card.shape-slashed .project-image {
  clip-path: polygon(0 0, 100% 6%, 94% 100%, 5% 92%);
}

.project-card.text-relic .project-image {
  aspect-ratio: 1 / .38;
  background: var(--red);
}

.project-card.text-relic .project-image img {
  object-fit: contain;
  padding: 18%;
  filter: none;
}

/* About gateway */

.about-gateway {
  max-width: var(--max);
  margin: 0 auto;
  padding: 58px 24px 72px;
  border-right: 1px solid var(--mid);
  border-left: 1px solid var(--mid);
  background: var(--paper);
}

.about-gateway-grid {
  margin-top: 24px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(240px, .75fr) auto;
  gap: 28px;
  align-items: end;
  padding-top: 24px;
  border-top: 1px solid var(--black);
}

.about-gateway h2 {
  margin: 0;
  font-size: clamp(52px, 7vw, 112px);
  font-weight: 560;
  font-stretch: 80%;
  line-height: .8;
  letter-spacing: -.07em;
}

.about-gateway p {
  max-width: 420px;
  margin: 0;
  font-size: clamp(16px, 1.5vw, 22px);
  line-height: 1.12;
}

.about-scroll-link {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border: 1px solid var(--black);
  font: 10px/1 var(--font-mono);
  text-transform: uppercase;
}

.about-scroll-link:hover,
.about-scroll-link:focus-visible {
  background: var(--red);
  color: var(--white);
}

/* Footer */

.site-footer {
  max-width: var(--max);
  min-height: 220px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 100px 1fr 1fr auto;
  gap: 24px;
  align-items: end;
  padding: 40px 24px;
  border-right: 1px solid var(--mid);
  border-left: 1px solid var(--mid);
  background: var(--black);
  color: var(--paper);
  font: 11px/1.4 var(--font-mono);
  text-transform: uppercase;
}

.site-footer img {
  width: 66px;
  filter: invert(1);
}

.site-footer p {
  margin: 0;
}

.site-footer div {
  display: flex;
  gap: 20px;
}

.site-footer a {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.footer-time {
  text-align: right;
}

/* Dialogs */

dialog {
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  border: 1px solid var(--paper);
  background: var(--charcoal);
  color: var(--paper-light);
}

dialog::backdrop {
  background: rgba(15, 15, 15, .9);
  backdrop-filter: blur(8px);
}

.dialog-close {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 30;
  width: 48px;
  height: 48px;
  border: 1px solid var(--paper);
  background: var(--red);
  color: var(--white);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}

.project-dialog {
  width: min(1460px, calc(100vw - 24px));
  height: min(900px, calc(100svh - 24px));
  overflow: hidden;
}

.project-dialog[open] {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(360px, .65fr);
}

.dialog-stage {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  background: var(--black);
}

.dialog-figure {
  height: 100%;
  margin: 0;
  display: grid;
  grid-template-rows: 1fr auto;
}

.dialog-figure img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  background: var(--black);
}

.dialog-figure figcaption {
  min-height: 42px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 8px 12px;
  border-top: 1px solid var(--paper);
  background: var(--charcoal);
  font: 9px/1.2 var(--font-mono);
  text-transform: uppercase;
}

.gallery-arrow {
  position: absolute;
  top: 50%;
  z-index: 10;
  width: 50px;
  height: 50px;
  border: 1px solid var(--paper);
  background: var(--red);
  color: var(--white);
  cursor: pointer;
  transform: translateY(-50%);
}

.gallery-prev {
  left: 12px;
}

.gallery-next {
  right: 12px;
}

.dialog-content {
  position: relative;
  overflow: auto;
  padding: clamp(28px, 4vw, 64px);
  border-left: 1px solid var(--paper);
}

.dialog-seal {
  width: 48px;
  margin: 0 0 60px auto;
}

.dialog-seal img {
  filter: invert(1);
}

.dialog-kicker {
  margin: 0;
  color: var(--red);
  font: 10px/1.3 var(--font-mono);
  text-transform: uppercase;
}

.dialog-content h2 {
  margin: 16px 0 22px;
  font-size: clamp(50px, 6vw, 96px);
  font-weight: 600;
  font-stretch: 78%;
  line-height: .77;
  letter-spacing: -.07em;
  text-transform: uppercase;
}

.dialog-artist {
  margin: 0 0 46px;
  font: 12px/1.4 var(--font-mono);
  text-transform: uppercase;
}

.dialog-body {
  font-size: 17px;
  line-height: 1.38;
}

.dialog-body p {
  margin: 0 0 18px;
}

.dialog-body blockquote {
  margin: 34px 0;
  padding: 18px 0 18px 22px;
  border-left: 8px solid var(--red);
  font-family: var(--font-neo);
  font-size: 27px;
  line-height: 1.02;
}

.dialog-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 40px;
}

.dialog-tags span {
  padding: 6px 8px;
  border: 1px solid var(--paper);
  font: 9px/1 var(--font-mono);
  text-transform: uppercase;
}

.related-projects {
  margin-top: 50px;
  padding-top: 16px;
  border-top: 1px solid var(--mid);
}

.related-projects h3 {
  margin: 0 0 14px;
  font: 10px/1 var(--font-mono);
  text-transform: uppercase;
}

#related-list {
  display: grid;
  gap: 7px;
}

#related-list button {
  min-height: 46px;
  padding: 9px 10px;
  border: 1px solid var(--mid);
  background: transparent;
  color: var(--paper);
  cursor: pointer;
  text-align: left;
  font: 10px/1.3 var(--font-mono);
  text-transform: uppercase;
}

#related-list button:hover {
  border-color: var(--paper);
  background: var(--red);
}

.index-dialog,
.artists-dialog {
  width: min(900px, calc(100vw - 24px));
  height: min(820px, calc(100svh - 24px));
  overflow: auto;
  padding: 30px;
}

.index-dialog header,
.artists-dialog header {
  margin-bottom: 50px;
}

.index-dialog h2,
.artists-dialog h2 {
  margin: 16px 0 0;
  font-size: clamp(52px, 8vw, 100px);
  font-weight: 560;
  line-height: .8;
  letter-spacing: -.07em;
}

#project-index-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--paper);
}

#project-index-list li {
  border-bottom: 1px solid var(--mid);
}

#project-index-list button {
  width: 100%;
  min-height: 74px;
  display: grid;
  grid-template-columns: 58px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 12px 0;
  border: 0;
  background: transparent;
  color: var(--paper);
  cursor: pointer;
  text-align: left;
}

#project-index-list button:hover {
  color: var(--red);
}

#project-index-list strong {
  font-size: 21px;
  font-weight: 500;
}

#project-index-list small,
#project-index-list span {
  font: 9px/1.2 var(--font-mono);
  text-transform: uppercase;
}

#artists-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--paper);
}

.artist-entry {
  min-height: 180px;
  padding: 18px;
  border-right: 1px solid var(--mid);
  border-bottom: 1px solid var(--mid);
}

.artist-entry:nth-child(2n) {
  border-right: 0;
}

.artist-entry h3 {
  margin: 0 0 18px;
  font-size: 31px;
  font-weight: 560;
  line-height: .9;
  letter-spacing: -.045em;
}

.artist-entry p {
  margin: 0;
  font: 10px/1.4 var(--font-mono);
  text-transform: uppercase;
}

/* Responsive */

@media (max-width: 980px) {
  :root {
    --header-h: 62px;
  }

  .site-header {
    grid-template-columns: 1fr auto;
    padding: 8px 12px;
  }

  .brand img {
    width: min(290px, 68vw);
    height: 26px;
  }

  .menu-toggle {
    display: block;
    min-height: 44px;
    border: 1px solid var(--black);
    background: transparent;
    text-transform: uppercase;
    font: 10px/1 var(--font-mono);
  }

  .primary-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    border-bottom: 1px solid var(--black);
    background: var(--paper);
  }

  .primary-nav.is-open {
    display: flex;
  }

  .primary-nav a,
  .primary-nav button {
    min-height: 50px;
    border-top: 1px solid var(--mid);
    text-align: left;
  }

  .intro {
    min-height: 760px;
    padding: calc(var(--header-h) + 36px) 14px 40px;
  }

  .intro h1 {
    margin-top: 110px;
    font-size: clamp(78px, 21vw, 150px);
  }

  .intro .neo-word {
    margin-left: 8%;
  }

  .intro-aside {
    right: 14px;
    bottom: 52px;
    width: min(310px, 72vw);
  }

  .intro-coordinate {
    display: none;
  }

  .intro-sigil {
    top: 16%;
    right: 8%;
    width: 90px;
  }

  .battle-header {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .battle-tools {
    justify-content: space-between;
  }

  .battle-ground {
    height: auto;
    min-height: 0;
    padding: 48px 10px 110px;
  }

  .board-grid {
    opacity: .13;
  }

  .board-instruction {
    position: relative;
    top: auto;
    margin: -48px 0 26px -10px;
    overflow-x: auto;
    max-width: calc(100vw - 10px);
    white-space: nowrap;
  }

  .project-layer {
    position: relative;
    display: grid;
    gap: 0;
  }

  .project-card {
    position: relative !important;
    left: auto !important;
    top: auto !important;
    width: min(92vw, 620px) !important;
    margin-top: -26px;
    transform: rotate(var(--mobile-r)) !important;
  }

  .project-card:first-child {
    margin-top: 20px;
  }

  .project-card:nth-child(odd) {
    margin-left: 0;
  }

  .project-card:nth-child(even) {
    margin-left: auto;
  }

  .project-card:hover,
  .project-card:focus-within {
    transform: rotate(0deg) scale(1.01) !important;
  }

  .drag-handle {
    display: none;
  }

  .project-mark {
    right: 5px;
    transform: rotate(0deg);
  }

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

  .site-footer div,
  .footer-time {
    grid-column: 2;
    text-align: left;
  }

  .project-dialog {
    width: calc(100vw - 12px);
    height: calc(100svh - 12px);
  }

  .project-dialog[open] {
    display: block;
    overflow: auto;
  }

  .dialog-stage {
    height: min(56svh, 540px);
  }

  .dialog-content {
    border-top: 1px solid var(--paper);
    border-left: 0;
  }

  .dialog-seal {
    margin-bottom: 34px;
  }
}

@media (max-width: 620px) {
  .intro {
    min-height: 700px;
  }

  .battle-header {
    padding: 20px 14px;
  }

  .battle-tools {
    align-items: flex-start;
    flex-direction: column;
  }

  .battle-tools button {
    width: 100%;
  }

  .project-card {
    width: calc(100vw - 28px) !important;
    margin-top: -18px;
  }

  .project-copy h3 {
    font-size: clamp(30px, 11vw, 52px);
  }

  .project-head {
    grid-template-columns: auto 1fr;
  }

  .project-head .project-year {
    display: none;
  }

  .board-instruction span:nth-child(2) {
    display: none;
  }

  .site-footer {
    min-height: 290px;
    align-items: start;
  }

  .site-footer div {
    flex-direction: column;
    gap: 8px;
  }

  .dialog-stage {
    height: 48svh;
  }

  .dialog-content {
    padding: 28px 18px 50px;
  }

  .dialog-content h2 {
    font-size: clamp(49px, 16vw, 76px);
  }

  .index-dialog,
  .artists-dialog {
    padding: 20px 14px;
  }

  #artists-list {
    grid-template-columns: 1fr;
  }

  .artist-entry {
    border-right: 0;
  }

  #project-index-list button {
    grid-template-columns: 42px 1fr;
  }

  #project-index-list button > span:last-child {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }

  .project-card:hover,
  .project-card:focus-within {
    transform: none !important;
  }
}

@media (max-width: 980px) {
  .about-gateway {
    padding: 52px 14px 62px;
  }

  .about-gateway-grid {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .about-scroll-link {
    width: 100%;
  }
}

.language-link {
  min-width: 42px;
  border-color: var(--black) !important;
  font-weight: 500;
}


/* ================================================================
   V4 — High Culture / Blue Notes
   ================================================================ */

:root {
  --blue: #243cff;
  --blue-deep: #1729d8;
  --blue-soft: rgba(36, 60, 255, .14);
}

/* Direct entry: the project field is now the cover. */
.battle-section {
  margin-top: var(--header-h);
}

.battle-header {
  min-height: 214px;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, .62fr) auto;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border-top: 0;
}

.battle-title-block {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-width: 0;
  padding: 26px 24px 28px;
  border-right: 1px solid var(--mid);
}

.battle-title-block .section-number {
  color: var(--blue);
}

.battle-title-block h2 {
  margin: 18px 0 0;
}

.battle-subtitle {
  max-width: 640px;
  margin: 16px 0 0;
  color: rgba(239, 239, 236, .72);
  font-size: 14px;
  line-height: 1.25;
}

.battle-about {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px 20px;
  background: var(--blue);
  color: var(--white);
}

.battle-about .section-number {
  color: rgba(255,255,255,.7);
}

.battle-about > p:not(.section-number) {
  margin: 42px 0 30px;
  font-size: clamp(18px, 1.55vw, 25px);
  line-height: 1.05;
  letter-spacing: -.03em;
}

.battle-about a {
  width: fit-content;
  padding-bottom: 3px;
  border-bottom: 1px solid currentColor;
  font: 10px/1.2 var(--font-mono);
  text-transform: uppercase;
}

.battle-about a:hover,
.battle-about a:focus-visible {
  color: var(--black);
}

.battle-tools {
  width: 210px;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-end;
  padding: 20px;
  border-left: 1px solid var(--mid);
}

.battle-tools p {
  margin-bottom: 14px;
}

.status-dot {
  background: var(--blue);
  box-shadow: 0 0 0 5px var(--blue-soft);
}

.language-link {
  background: var(--blue);
  color: var(--white) !important;
  border-color: var(--blue) !important;
}

.language-link:hover,
.language-link:focus-visible {
  background: var(--black) !important;
  border-color: var(--black) !important;
}

/* Blue appears as a note, not as a complete recolouring. */
.project-card:nth-child(even) .project-mark {
  background: var(--blue);
}

.project-card:nth-child(even):hover .project-surface,
.project-card:nth-child(even):focus-within .project-surface {
  box-shadow: 20px 20px 0 var(--blue);
}

.project-card:nth-child(3n) .project-index {
  color: var(--blue);
}

.project-card:nth-child(3n) .project-surface {
  border-color: var(--blue);
}

.board-instruction {
  background: var(--blue);
}

.dialog-kicker {
  color: var(--blue);
}

.dialog-body blockquote {
  border-left-color: var(--blue);
}

.gallery-arrow {
  background: var(--blue);
}

#related-list button:hover {
  background: var(--blue);
}

@media (max-width: 1160px) {
  .battle-header {
    grid-template-columns: minmax(0, 1fr) minmax(250px, .55fr);
  }

  .battle-tools {
    width: auto;
    grid-column: 1 / -1;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--mid);
    border-left: 0;
  }

  .battle-tools p {
    margin-bottom: 0;
  }
}

@media (max-width: 720px) {
  .battle-section {
    margin-top: var(--header-h);
  }

  .battle-header {
    grid-template-columns: 1fr;
  }

  .battle-title-block {
    min-height: 210px;
    border-right: 0;
  }

  .battle-about {
    min-height: 220px;
  }

  .battle-tools {
    flex-direction: column;
    align-items: stretch;
  }

  .battle-tools p {
    margin-bottom: 12px;
  }
}


/* ================================================================
   V5 — expanded project cards
   The modal preserves the exact grammar of the board thumbnail.
   ================================================================ */

.project-dialog {
  width: min(1040px, calc(100vw - 36px));
  height: min(920px, calc(100svh - 30px));
  overflow: visible;
  border: 0;
  background: transparent;
  color: var(--black);
}

.project-dialog[open] {
  display: block;
}

.project-dialog .dialog-close {
  position: absolute;
  top: -12px;
  right: -12px;
  z-index: 50;
  width: 46px;
  height: 46px;
  border: 1px solid var(--black);
  background: var(--dialog-accent, var(--red));
  color: var(--white);
  box-shadow: 6px 6px 0 rgba(0, 0, 0, .35);
}

.expanded-project-card {
  --dialog-accent: var(--red);
  --dialog-mark-accent: var(--red);
  --dialog-visual: var(--black);

  position: relative;
  height: 100%;
  overflow-y: auto;
  border: 1px solid var(--dialog-accent);
  background: var(--paper);
  color: var(--black);
  box-shadow:
    18px 18px 0 var(--dialog-accent),
    30px 30px 0 rgba(0, 0, 0, .35);
  scrollbar-width: thin;
  scrollbar-color: var(--dialog-accent) var(--paper);
}

.expanded-project-head {
  min-height: 52px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--black);
  background: var(--paper);
  font: 10px/1 var(--font-mono);
  text-transform: uppercase;
}

.expanded-project-id {
  color: var(--dialog-accent);
  font-weight: 500;
}

.expanded-project-year {
  text-align: right;
}

.expanded-project-visual {
  position: relative;
  min-height: 360px;
  background: var(--dialog-visual);
  border-bottom: 1px solid var(--black);
}

.expanded-project-figure {
  height: min(52vh, 520px);
  margin: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  background: var(--dialog-visual);
}

.expanded-project-figure img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  background: var(--dialog-visual);
  filter: saturate(1.04) contrast(1.02);
}

.expanded-project-card.text-relic .expanded-project-figure img {
  width: min(44%, 330px);
  height: min(44%, 250px);
  align-self: center;
  justify-self: center;
  object-fit: contain;
  filter: none;
}

.expanded-project-figure figcaption {
  min-height: 40px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 8px 12px;
  border-top: 1px solid rgba(255, 255, 255, .45);
  background: var(--dialog-visual);
  color: var(--white);
  font: 9px/1.2 var(--font-mono);
  text-transform: uppercase;
}

.expanded-project-title {
  padding: 22px 22px 25px;
  border-bottom: 1px solid var(--black);
  background: var(--paper);
}

.expanded-project-title h2 {
  max-width: 96%;
  margin: 0;
  font-size: clamp(52px, 7.4vw, 108px);
  font-weight: 620;
  font-stretch: 76%;
  line-height: .78;
  letter-spacing: -.075em;
  text-transform: uppercase;
}

.expanded-project-title p {
  margin: 18px 0 0;
  font: 11px/1.35 var(--font-mono);
  text-transform: uppercase;
}

.expanded-project-info {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(250px, .65fr);
  gap: 0;
  border-bottom: 1px solid var(--black);
  background: var(--paper);
}

.expanded-project-info > .dialog-body {
  padding: 34px 30px 48px;
  border-right: 1px solid var(--black);
  color: var(--black);
  font-size: clamp(17px, 1.6vw, 22px);
  line-height: 1.3;
}

.expanded-project-info .dialog-body p {
  max-width: 720px;
  margin: 0 0 22px;
}

.expanded-project-info .dialog-body blockquote {
  margin: 38px 0 0;
  padding: 22px 0 22px 24px;
  border-left: 8px solid var(--dialog-accent);
  color: var(--black);
  font-family: var(--font-sans);
  font-size: clamp(25px, 3vw, 42px);
  font-weight: 560;
  line-height: .96;
  letter-spacing: -.045em;
}

.expanded-project-aside {
  padding: 26px 22px 42px;
}

.expanded-project-aside .dialog-tags {
  margin-top: 0;
}

.expanded-project-aside .dialog-tags span {
  border-color: var(--black);
  color: var(--black);
}

.expanded-project-aside .related-projects {
  margin-top: 42px;
  border-top-color: var(--black);
}

.expanded-project-aside #related-list button {
  border-color: var(--black);
  color: var(--black);
}

.expanded-project-aside #related-list button:hover {
  border-color: var(--dialog-accent);
  background: var(--dialog-accent);
  color: var(--white);
}

.expanded-project-mark {
  position: absolute;
  right: -19px;
  top: 28%;
  z-index: 20;
  padding: 8px 10px;
  border: 1px solid var(--black);
  background: var(--dialog-mark-accent);
  color: var(--white);
  font: 9px/1 var(--font-mono);
  text-transform: uppercase;
  transform: rotate(90deg);
  transform-origin: center;
}

.project-dialog .gallery-arrow {
  width: 48px;
  height: 48px;
  border-color: var(--black);
  background: var(--dialog-accent);
  box-shadow: 5px 5px 0 rgba(0,0,0,.3);
}

.project-dialog .gallery-prev {
  left: 14px;
}

.project-dialog .gallery-next {
  right: 14px;
}

@media (max-width: 760px) {
  .project-dialog {
    width: calc(100vw - 18px);
    height: calc(100svh - 18px);
  }

  .project-dialog .dialog-close {
    top: 6px;
    right: 6px;
    width: 42px;
    height: 42px;
    box-shadow: none;
  }

  .expanded-project-card {
    box-shadow: none;
  }

  .expanded-project-head {
    padding-right: 56px;
  }

  .expanded-project-figure {
    height: min(47vh, 410px);
  }

  .expanded-project-title {
    padding: 18px 14px 22px;
  }

  .expanded-project-title h2 {
    font-size: clamp(44px, 15vw, 76px);
  }

  .expanded-project-info {
    grid-template-columns: 1fr;
  }

  .expanded-project-info > .dialog-body {
    padding: 28px 14px 34px;
    border-right: 0;
    border-bottom: 1px solid var(--black);
  }

  .expanded-project-aside {
    padding: 24px 14px 36px;
  }

  .expanded-project-mark {
    display: none;
  }

  .project-dialog .gallery-arrow {
    width: 42px;
    height: 42px;
  }
}


@keyframes liquidSweep {
  0% {
    background-position: 0% 0%, 100% 0%, 40% 100%, 0% 50%;
    filter: blur(10px) contrast(1.2);
  }
  50% {
    background-position: 12% 22%, 84% 10%, 52% 76%, 55% 50%;
    filter: blur(14px) contrast(1.35);
  }
  100% {
    background-position: 18% 30%, 76% 18%, 58% 70%, 100% 50%;
    filter: blur(11px) contrast(1.22);
  }
}

@media (prefers-reduced-motion: reduce) {
  .project-card:hover .project-image::before,
  .project-card:focus-within .project-image::before {
    animation: none;
  }
}
