/* ==========================================================================
   OtherMinds — monochrome system
   Black field, white type, hairline rules. Gradients are reserved for the
   hero shade and the faint glow behind the particle scene.
   ========================================================================== */

:root {
  --bg: #000;
  --bg-raised: #0a0a0a;
  --panel: #161616;
  --panel-hover: #1e1e1e;
  --panel-line: rgba(255, 255, 255, 0.07);
  --fg: #fff;
  --fg-2: rgba(255, 255, 255, 0.72);
  --fg-3: rgba(255, 255, 255, 0.48);
  --fg-4: rgba(255, 255, 255, 0.3);
  --line: rgba(255, 255, 255, 0.14);
  --line-strong: rgba(255, 255, 255, 0.32);

  /* Accent — sampled from the hero footage: desert ochre and high-desert sky.
     Used only for hairlines, orbs, and a handful of particles. */
  --amber: #e8a15c;
  --blue: #6f8dff;
  --grad: linear-gradient(90deg, var(--amber), var(--blue) 55%, rgba(111, 141, 255, 0));

  --display: "Space Grotesk", "Inter Tight", "Helvetica Neue", Arial, sans-serif;
  --sans: "Inter Tight", "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1440px;
  --section-y: clamp(96px, 14vw, 200px);
  --nav-h: 72px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: var(--nav-h);
}
html:not(.lenis) { scroll-behavior: smooth; }
/* Lenis */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video, canvas { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }

::selection { background: var(--fg); color: var(--bg); }

:focus-visible {
  outline: 1px solid var(--fg);
  outline-offset: 4px;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 16px; top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--fg);
  color: var(--bg);
  font-family: var(--mono);
  font-size: 12px;
  text-transform: uppercase;
}
.skip-link:focus { top: 16px; }

/* ---------- type primitives ---------- */

.label {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-3);
}
.label__num { color: var(--fg); margin-right: 1.2em; }

.display {
  font-family: var(--display);
  font-size: clamp(40px, 6vw, 88px);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.04em;
}
.display--xl { font-size: clamp(48px, 9vw, 152px); }

.lede.lede--sm { font-size: clamp(20px, 1.8vw, 26px); color: var(--fg-2); }
.lede {
  font-size: clamp(22px, 2.4vw, 34px);
  font-weight: 300;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.prose { max-width: 62ch; color: var(--fg-2); }
.prose p + p { margin-top: 1.1em; }
.prose--muted { color: var(--fg-3); }

.mono { font-family: var(--mono); font-size: 0.9em; letter-spacing: 0.02em; }

/* ---------- buttons ---------- */

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

.btn {
  --h: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: var(--h);
  padding: 0 28px;
  border: 1px solid var(--fg);
  background: transparent;
  color: var(--fg);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.4s var(--ease-out);
}
.btn::before {
  content: "";
  position: absolute; inset: 0;
  background: var(--fg);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.4s var(--ease-out);
  z-index: -1;
}
.btn:hover { color: var(--bg); }
.btn:hover::before { transform: scaleY(1); }

.btn--solid { background: var(--fg); color: var(--bg); }
.btn--solid::before { background: var(--bg); }
.btn--solid:hover { color: var(--fg); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 4px;
  transition: border-color 0.3s;
}
.link-arrow::after { content: "→"; transition: transform 0.3s var(--ease-out); }
.link-arrow:hover { border-color: var(--fg); }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------- reveal ---------- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1.1s var(--ease-out), transform 1.1s var(--ease-out);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

/* ==========================================================================
   NAV
   ========================================================================== */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--nav-h);
  transition: background-color 0.5s, border-color 0.5s, transform 0.5s var(--ease-out);
  border-bottom: 1px solid transparent;
}
.site-header[data-scrolled="true"] {
  background: rgba(0, 0, 0, 0.72);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-color: var(--line);
}
.site-header[data-hidden="true"] { transform: translateY(-100%); }

.nav {
  height: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--display);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.38em;
  text-decoration: none;
  position: relative;
  z-index: 2;
}

.wordmark__logo {
  display: block;
  height: 19px;
  width: auto;
  aspect-ratio: 1220 / 135;
  transition: opacity 0.3s;
}
.wordmark:hover .wordmark__logo { opacity: 0.75; }
@media (max-width: 600px) { .wordmark__logo { height: 16px; } }

.nav-links { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 36px); }
.nav-links a {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--fg-2);
  transition: color 0.3s;
  position: relative;
}
.nav-links a:hover { color: var(--fg); }
.nav-links a:not(.nav-links__cta)::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -6px;
  height: 1px; background: linear-gradient(90deg, var(--amber), var(--blue));
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.4s var(--ease-out);
}
.nav-links a:not(.nav-links__cta):hover::after { transform: scaleX(1); }
.nav-links__cta {
  color: var(--fg) !important;
  border: 1px solid var(--line-strong);
  padding: 9px 16px;
  transition: background-color 0.3s, color 0.3s !important;
}
.nav-links__cta:hover { background: var(--fg); color: var(--bg) !important; }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 12px;
  background: none;
  border: 0;
  color: var(--fg);
  cursor: pointer;
  padding: 8px 0;
  position: relative;
  z-index: 2;
}
.nav-toggle__label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.nav-toggle__bars { display: grid; gap: 5px; width: 22px; }
.nav-toggle__bars span {
  height: 1px; background: currentColor;
  transition: transform 0.4s var(--ease-out);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:first-child { transform: translateY(3px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:last-child { transform: translateY(-3px) rotate(-45deg); }

@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }

  /* backdrop-filter and transform on the header would turn it into the
     containing block for the fixed overlay below, so both are dropped
     while the menu is open. */
  .site-header[data-menu="open"] {
    transform: none;
    background: transparent;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border-color: transparent;
    transition: none;
  }

  .nav-links {
    position: fixed;
    inset: 0;
    height: 100vh;
    height: 100dvh;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: calc(var(--nav-h) + 3vh) var(--gutter) 40px;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--bg);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s var(--ease-out), visibility 0s linear 0.35s;
  }
  .nav-links::before {
    content: "";
    position: absolute; left: 0; right: 0; top: var(--nav-h);
    height: 1px;
    background: var(--grad);
    opacity: 0.6;
  }
  .nav-links[data-open="true"] {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.35s var(--ease-out), visibility 0s;
  }
  .nav-links li {
    border-bottom: 1px solid var(--line);
    overflow: hidden;
  }
  .nav-links a {
    display: block;
    padding: 1.4dvh 0;
    font-family: var(--display);
    font-size: clamp(24px, min(8.5vw, 5.2dvh), 48px);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -0.04em;
    text-transform: none;
    color: var(--fg);
    transform: translateY(105%);
    transition: transform 0.6s var(--ease-out);
  }
  .nav-links[data-open="true"] a { transform: none; }
  .nav-links li:nth-child(2) a { transition-delay: 0.04s; }
  .nav-links li:nth-child(3) a { transition-delay: 0.08s; }
  .nav-links li:nth-child(4) a { transition-delay: 0.12s; }
  .nav-links li:nth-child(5) a { transition-delay: 0.16s; }
  .nav-links li:nth-child(6) a { transition-delay: 0.2s; }
  .nav-links li:nth-child(7) a { transition-delay: 0.24s; }
  .nav-links a::after { display: none; }
  .nav-links__cta { border: 0 !important; padding: 1.4dvh 0 !important; transition: transform 0.6s var(--ease-out) !important; }
  .nav-links__cta:hover { background: none; color: var(--fg) !important; }
  body[data-menu-open="true"] { overflow: hidden; }
}

/* ==========================================================================
   HERO
   ========================================================================== */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  isolation: isolate;
}

.hero__media {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: -2;
}

/* one of the two places a gradient is used */
.hero__shade {
  position: absolute; inset: 0;
  z-index: -1;
  /* Darkens where the type sits (lower left) and leaves the rest of the
     footage bright. */
  background:
    linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0) 22%),
    linear-gradient(to right, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.3) 45%, rgba(0,0,0,0) 75%),
    linear-gradient(to top, #000 0%, rgba(0,0,0,0.8) 30%, rgba(0,0,0,0.45) 55%, rgba(0,0,0,0.1) 80%);
}

.hero__inner {
  padding-top: calc(var(--nav-h) + 48px);
  padding-bottom: clamp(88px, 12vh, 140px);
}

.hero__title {
  font-family: var(--display);
  font-size: clamp(44px, 8.4vw, 136px);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: -0.05em;
  text-shadow: 0 2px 40px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.25);
  margin-bottom: clamp(36px, 5vw, 64px);
}
/* Line masks clip at the line box; pad them so descenders survive. */
.hero__title > [class$="-mask"], [data-split] > [class$="-mask"] {
  padding-bottom: 0.26em;
  margin-bottom: -0.26em;
}
.hero__title-dim { color: rgba(255, 255, 255, 0.62); font-weight: 300; }

.hero__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px 64px;
}
.hero__lede { max-width: 52ch; color: rgba(255, 255, 255, 0.82); font-size: 16px; text-shadow: 0 1px 12px rgba(0, 0, 0, 0.5); }

.hero__meta {
  position: absolute;
  left: 0; right: 0; bottom: 28px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 16px;
}
.hero__scrollline {
  flex: 0 0 64px;
  height: 1px;
  background: var(--line-strong);
  position: relative;
  overflow: hidden;
}
.hero__scrollline::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--amber), var(--blue));
  animation: scrollline 2.4s var(--ease-out) infinite;
}
@keyframes scrollline {
  0% { transform: translateX(-100%); }
  60%, 100% { transform: translateX(100%); }
}

.js .hero [data-reveal] { transition-delay: 0.5s; }

/* Split headings stay hidden until GSAP has split them. The delayed
   animation is a safety net in case the GSAP scripts never load. */
.js .hero__title, .js [data-split] { visibility: hidden; animation: show-anyway 0s 2.5s forwards; }
.js .is-split { visibility: visible; animation: none; }
@keyframes show-anyway { to { visibility: visible; } }

/* ==========================================================================
   RESEARCH — scroll scene
   Default (no JS / no WebGL): panels stack as a normal section.
   .is-live: tall track + sticky full-viewport stage.
   ========================================================================== */

.scrolly { position: relative; }

.scrolly__stage { position: relative; }
.scrolly__canvas, .scrolly__glow, .scrolly__hud, .scrolly__fade { display: none; }

.scrolly__panels {
  display: grid;
  gap: 96px;
  padding-block: var(--section-y);
}

.panel { max-width: 560px; }
.panel .label { margin-bottom: 24px; }
.panel .display { margin-bottom: 24px; }
.panel__lead {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.panel__body { color: var(--fg-2); max-width: 50ch; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.chips li {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg-2);
  border: 1px solid var(--line-strong);
  padding: 7px 12px;
}

/* live mode */
.scrolly.is-live { height: 560vh; }
.scrolly.is-live .scrolly__stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
}
.scrolly.is-live .scrolly__canvas {
  display: block;
  position: absolute; inset: 0;
  width: 100%; height: 100%;
}
.scrolly.is-live .scrolly__glow {
  display: block;
  position: absolute;
  width: 70vmax; height: 70vmax;
  right: -10vmax; top: 50%;
  transform: translateY(-50%);
  background:
    radial-gradient(closest-side at 40% 40%, rgba(111,141,255,0.12), rgba(111,141,255,0) 70%),
    radial-gradient(closest-side at 65% 70%, rgba(232,161,92,0.06), rgba(232,161,92,0) 70%);
  pointer-events: none;
}
.scrolly.is-live .scrolly__hud { display: block; }
.scrolly.is-live .scrolly__fade {
  display: block;
  position: absolute; inset: 0;
  pointer-events: none;
  background:
    linear-gradient(to bottom, #000 0%, rgba(0,0,0,0) 16%, rgba(0,0,0,0) 78%, #000 100%),
    linear-gradient(to right, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0) 40%);
}
.scrolly.is-live .scrolly__panels {
  position: absolute; inset: 0;
  display: block;
  padding: 0;
  margin-inline: auto;
  left: 0; right: 0;
  pointer-events: none;
}
.scrolly.is-live .panel {
  position: absolute;
  left: var(--gutter);
  top: 50%;
  width: min(520px, 42vw);
  opacity: 0;
  transform: translateY(-50%);
  will-change: opacity, transform;
}
.scrolly.is-live .panel[data-active="true"] { pointer-events: auto; }
/* Headings break only where the markup says (<br>); size tracks the
   viewport so the widest line stays clear of the figure on the right. */
.scrolly.is-live .panel .display {
  white-space: nowrap;
  font-size: clamp(40px, 4.8vw, 84px);
}

.hud {
  position: absolute;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.hud--tl { top: calc(var(--nav-h) + 24px); right: var(--gutter); text-align: right; }
.hud__fig { color: var(--fg); }
.hud--br { bottom: 32px; right: var(--gutter); align-items: flex-end; }
.hud__bar {
  display: block;
  width: 160px; height: 1px;
  background: var(--line);
  position: relative;
}
.hud__bar span {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--amber), var(--blue));
  transform-origin: left;
  transform: scaleX(0);
}

@media (max-width: 900px) {
  .scrolly.is-live .panel {
    top: auto;
    bottom: 0;
    left: 0; right: 0;
    width: auto;
    transform: none;
    padding: 96px var(--gutter) 40px;
    background: linear-gradient(to top, #000 55%, rgba(0,0,0,0));
  }
  .scrolly.is-live .panel .display { font-size: 40px; }
  .scrolly.is-live .panel__body { font-size: 15px; }
  .scrolly.is-live .scrolly__glow { right: auto; left: 50%; top: 32%; transform: translate(-50%, -50%); }
  .hud--br { display: none; }
  .hud--tl { display: none; }
}

/* ==========================================================================
   SECTIONS
   ========================================================================== */

.section { padding-block: var(--section-y); position: relative; }
.section > .wrap, .footer > .wrap, .hero__inner { position: relative; z-index: 1; }
/* Mission and Team read as one run — collapse the double gap between them. */
#team { padding-top: clamp(24px, 3vw, 48px); }

.section--rule::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 1px;
  background: var(--grad);
  opacity: 0.45;
}

/* ---------- accent orbs ---------- */
.orbs {
  position: absolute; inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.hero .orbs { z-index: -1; mix-blend-mode: screen; }
.orb {
  position: absolute;
  left: var(--x); top: var(--y);
  width: var(--s); aspect-ratio: 1;
  border-radius: 50%;
  translate: -50% -50%;
  filter: blur(120px);
  opacity: 0.1;
  animation: orb-drift 26s ease-in-out infinite alternate;
}
.orb--blue { background: radial-gradient(circle, var(--blue), rgba(111,141,255,0) 68%); }
.orb--amber { background: radial-gradient(circle, var(--amber), rgba(232,161,92,0) 68%); opacity: 0.065; animation-duration: 32s; }
@keyframes orb-drift {
  from { transform: translate(-4%, -3%) scale(1); }
  to { transform: translate(5%, 4%) scale(1.12); }
}

.section-head { margin-bottom: clamp(56px, 8vw, 112px); }
.section-head .label { margin-bottom: 24px; }
.section-head__sub {
  margin-top: 24px;
  max-width: 48ch;
  color: var(--fg-3);
  font-size: 18px;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr);
  gap: 24px 48px;
  align-items: start;
}
.split__aside { padding-top: 0.5em; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; } }

/* ---------- mission ---------- */

.statement {
  font-family: var(--display);
  font-size: clamp(32px, 5.2vw, 80px);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.035em;
  max-width: 21ch;
  margin-bottom: clamp(80px, 10vw, 160px);
}

.alignment { margin-top: clamp(80px, 10vw, 144px); }

.org-grid {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  background: var(--panel);
  color: var(--fg);
}
.org-grid li {
  border-right: 1px solid var(--panel-line);
  border-bottom: 1px solid var(--panel-line);
  padding: clamp(24px, 3vw, 40px);
  min-height: 140px;
  display: flex;
  align-items: flex-end;
  font-size: clamp(17px, 1.6vw, 22px);
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--fg-2);
  transition: color 0.3s, background-color 0.3s;
}
.org-grid li:nth-child(3n) { border-right: 0; }
.org-grid li:nth-last-child(-n + 3) { border-bottom: 0; }
.org-grid li:hover { color: var(--fg); background: var(--panel-hover); }
@media (max-width: 760px) {
  .org-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .org-grid li { min-height: 110px; border-right: 1px solid var(--panel-line) !important; border-bottom: 1px solid var(--panel-line) !important; }
  .org-grid li:nth-child(2n) { border-right: 0 !important; }
  .org-grid li:nth-last-child(-n + 2) { border-bottom: 0 !important; }
}

/* ---------- team ---------- */

.people { border-top: 1px solid var(--line); }
.person {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 32px 64px;
  padding-block: clamp(40px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
}
.person__index { display: block; margin-bottom: 28px; }
.person__name {
  font-family: var(--display);
  font-size: clamp(32px, 4vw, 56px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}
.person__role { color: var(--fg-2); }
.person__bio { color: var(--fg-2); max-width: 62ch; }
@media (max-width: 760px) { .person { grid-template-columns: 1fr; } }

/* ---------- laboratory ---------- */

.lab__hero {
  position: relative;
  height: clamp(520px, 92vh, 1000px);
  overflow: hidden;
}
.lab__hero img {
  position: absolute;
  inset: -12% 0;
  width: 100%;
  height: 124%;
  object-fit: cover;
  filter: brightness(0.82);
  will-change: transform;
}
.lab__hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, #000 0%, rgba(0,0,0,0.2) 22%, rgba(0,0,0,0.15) 50%, #000 100%);
}
.lab__hero-cap {
  position: absolute;
  left: 0; right: 0; bottom: clamp(40px, 6vw, 88px);
  z-index: 1;
}
.lab__hero-cap .label { margin-bottom: 24px; color: var(--fg-2); }

.location {
  margin-top: clamp(80px, 10vw, 144px);
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 0;
}
.location__img {
  overflow: hidden;
  min-height: 360px;
}
.location__img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 1.6s var(--ease-out);
}
.location:hover .location__img img { transform: scale(1.03); }

.spec {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: var(--panel);
  color: var(--fg);
}
.spec__row {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  padding: 22px 28px;
  border-top: 1px solid var(--panel-line);
}
.spec__row:first-child { border-top: 0; }
.spec dt {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-3);
  padding-top: 4px;
}
.spec dd { font-size: 17px; }
@media (max-width: 860px) {
  .location { grid-template-columns: 1fr; }
  .location__img {
    aspect-ratio: 3 / 2;
    min-height: 0;
  }
  .spec__row { grid-template-columns: 110px 1fr; padding: 18px 20px; }
}

.pillars {
  margin-top: clamp(80px, 10vw, 144px);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
}
.pillar {
  padding: 32px 28px 8px 0;
  border-right: 1px solid var(--line);
  padding-left: 28px;
}
.pillar:first-child { padding-left: 0; }
.pillar:last-child { border-right: 0; }
.pillar__num { display: block; margin-bottom: 64px; color: var(--fg); }
.pillar h3 {
  font-family: var(--display);
  font-size: 26px;
  font-weight: 400;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}
.pillar p { color: var(--fg-3); font-size: 15px; }
.js .pillar[data-reveal]:nth-child(2) { transition-delay: 0.08s; }
.js .pillar[data-reveal]:nth-child(3) { transition-delay: 0.16s; }
.js .pillar[data-reveal]:nth-child(4) { transition-delay: 0.24s; }
@media (max-width: 1000px) {
  .pillars { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pillar { padding: 32px 24px 40px !important; border-bottom: 1px solid var(--line); }
  .pillar:nth-child(2n) { border-right: 0; }
  .pillar:nth-child(2n+1) { padding-left: 0 !important; }
  .pillar__num { margin-bottom: 36px; }
}
@media (max-width: 600px) {
  .pillars { grid-template-columns: 1fr; }
  .pillar { border-right: 0; padding-left: 0 !important; padding-right: 0 !important; }
}

/* ---------- membership ---------- */

.membership {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
.membership__img {
  position: relative;
  overflow: hidden;
  min-height: 640px;
  -webkit-mask-image: linear-gradient(to right, #000 50%, transparent 100%), linear-gradient(to bottom, transparent 0%, #000 12%, #000 88%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, #000 50%, transparent 100%), linear-gradient(to bottom, transparent 0%, #000 12%, #000 88%, transparent 100%);
  mask-composite: intersect;
}
.membership__img img {
  position: absolute;
  inset: -10% 0;
  width: 100%; height: 120%;
  object-fit: cover;
  object-position: 50% 40%;
  will-change: transform;
}
.membership__body {
  padding: clamp(48px, 7vw, 120px) var(--gutter) clamp(48px, 7vw, 120px) clamp(32px, 6vw, 96px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.membership__body > .label { margin-bottom: 24px; }
.membership__body .display { font-size: clamp(36px, 4.4vw, 64px); margin-bottom: 28px; max-width: 14ch; }
.membership__body .btn-row { margin-top: 40px; }

.checklist { margin-top: 28px; border-top: 1px solid var(--line); }
.checklist li {
  position: relative;
  padding: 14px 0 14px 28px;
  border-bottom: 1px solid var(--line);
  font-size: 16px;
  color: var(--fg-2);
}
.checklist li::before {
  content: "+";
  position: absolute;
  left: 0;
  font-family: var(--mono);
  color: var(--fg);
}
@media (max-width: 860px) {
  .membership { grid-template-columns: 1fr; }
  .membership__img {
    min-height: 0;
    aspect-ratio: 4 / 3;
    -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 60%, transparent 100%);
  }
  .membership__body { padding: 64px var(--gutter); }
}

/* ---------- equipment ---------- */

.equipment {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 72px clamp(32px, 5vw, 80px);
}
.equipment__col--wide { grid-column: 1 / -1; }
.equipment__head {
  position: relative;
  padding-top: 24px;
  margin-bottom: 24px;
}
.equipment__head::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 1px;
  background: var(--grad);
}
.equipment__head .label { display: block; margin-bottom: 14px; }
.equipment__head h3 {
  font-family: var(--display);
  font-size: clamp(30px, 3vw, 44px);
  font-weight: 300;
  letter-spacing: -0.03em;
}
.eq-list { counter-reset: eq; }
.eq-list li {
  counter-increment: eq;
  position: relative;
  padding: 16px 0 16px 44px;
  border-bottom: 1px solid var(--line);
  color: var(--fg-2);
  font-size: 15px;
  line-height: 1.55;
}
.eq-list li::before {
  content: counter(eq, decimal-leading-zero);
  position: absolute;
  left: 0; top: 16px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--fg-4);
  padding-top: 4px;
}
.eq-list strong { color: var(--fg); font-weight: 500; }
.eq-list .status,
.eq-note .status { display: inline-block; vertical-align: 1px; white-space: nowrap; }
.eq-list .status { margin-left: 8px; }
.eq-note { margin-top: 40px; color: var(--fg-3); font-size: 14px; }
.eq-note .status { margin-right: 12px; }
@media (max-width: 860px) {
  .equipment { grid-template-columns: 1fr; gap: 72px; }
}

/* ---------- events ---------- */

.events {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: start;
}
.events__img { position: sticky; top: calc(var(--nav-h) + 32px); }
.events__img img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
}
.events__img figcaption { margin-top: -28px; position: relative; }


.event-list { margin-top: 48px; border-top: 1px solid var(--line); }
.event {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 16px 32px;
  padding-block: 36px;
  border-bottom: 1px solid var(--line);
}
.event__meta { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.event h3 {
  font-family: var(--display);
  font-size: clamp(22px, 2vw, 28px);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}
.event p { color: var(--fg-3); font-size: 15px; }

.status {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  color: var(--fg-3);
}
.status--live {
  color: var(--bg);
  background: var(--fg);
  border-color: var(--fg);
}
@media (max-width: 860px) {
  .events { grid-template-columns: 1fr; }
  .events__img { position: static; }
  .events__img img { aspect-ratio: 16 / 11; }
}
@media (max-width: 560px) { .event { grid-template-columns: 1fr; } }

/* ---------- contact ---------- */

.contact {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 64px clamp(48px, 8vw, 140px);
  align-items: end;
}
.contact .label { margin-bottom: 24px; }
.contact .display { margin-bottom: 24px; }

.subscribe { margin-top: 48px; max-width: 560px; }
.subscribe .label { display: block; margin-bottom: 12px; }
.subscribe__row { display: flex; gap: 0; }
.subscribe input {
  flex: 1;
  min-width: 0;
  height: 52px;
  padding: 0 18px;
  background: transparent;
  border: 1px solid var(--line-strong);
  border-right: 0;
  color: var(--fg);
  font: 400 16px var(--sans);
  border-radius: 0;
  transition: border-color 0.3s;
}
.subscribe input::placeholder { color: var(--fg-4); }
.subscribe input:focus { outline: none; border-color: var(--fg); }
.subscribe__status { min-height: 1.6em; margin-top: 12px; font-size: 14px; }
.subscribe__note { color: var(--fg-4); font-size: 13px; }
.contact__direct .label { margin-bottom: 16px; }
.contact__email {
  display: inline-block;
  font-family: var(--display);
  font-size: clamp(24px, 3vw, 44px);
  letter-spacing: -0.03em;
  line-height: 1.2;
  text-decoration: none;
  background: linear-gradient(90deg, var(--amber), var(--blue)) left bottom / 0% 1px no-repeat;
  padding-bottom: 6px;
  transition: background-size 0.6s var(--ease-out);
  word-break: break-all;
}
.contact__email:hover { background-size: 100% 1px; }

@media (max-width: 860px) { .contact { grid-template-columns: 1fr; } }
@media (max-width: 480px) {
  .subscribe__row { flex-direction: column; gap: 10px; }
  .subscribe input { border-right: 1px solid var(--line-strong); }
}

/* ---------- footer ---------- */

.footer {
  position: relative;
  padding-top: 48px;
  overflow: hidden;
  background: linear-gradient(to bottom, #000 0%, #05070d 100%);
}
.footer::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 1px;
  background: var(--grad);
  opacity: 0.5;
}
.footer__top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 24px;
}
.footer__links { display: flex; flex-wrap: wrap; gap: 12px 28px; }
.footer__links a {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--fg-2);
}
.footer__links a:hover { color: var(--fg); }
.footer__mark {
  margin-top: clamp(48px, 8vw, 120px);
  font-size: clamp(44px, 13.4vw, 210px);
  font-weight: 600;
  line-height: 0.74;
  letter-spacing: -0.02em;
  text-align: center;
  font-family: var(--display);
  white-space: nowrap;
  background: linear-gradient(180deg, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0.1) 45%, rgba(255,255,255,0.015) 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  user-select: none;
  transform: translateY(8%);
}

/* ---------- motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}
