:root {
  --bg: #06080a;
  --fg: #e8edf0;
  --dim: #8c969e;
  --line: rgba(232, 237, 240, 0.12);
  --accent: #7cc8ff;
  --gutter: clamp(20px, 5vw, 72px);
  --display: "Michroma", "Eurostile", "Segoe UI", sans-serif;
  --text: "Saira", "Segoe UI", system-ui, sans-serif;
  --mono: "Share Tech Mono", ui-monospace, "Consolas", monospace;
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--text);
  font-weight: 300;
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.2rem);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 1px solid var(--accent); outline-offset: 6px; }

h1, h2 {
  font-family: var(--display);
  font-weight: 400;
  margin: 0;
  letter-spacing: 0.01em;
}

h1 { font-size: clamp(1.75rem, 4.4vw, 3.9rem); line-height: 1.18; max-width: 17ch; }
h2 { font-size: clamp(1.3rem, 2.6vw, 2.3rem); line-height: 1.25; }
p { margin: 0; }

.label {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--dim);
}

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

/* Background visual */
#field {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
}

.veil {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(6, 8, 10, 0.92) 0%, rgba(6, 8, 10, 0.55) 45%, rgba(6, 8, 10, 0) 75%),
    linear-gradient(180deg, rgba(6, 8, 10, 0.6) 0%, rgba(6, 8, 10, 0) 18%, rgba(6, 8, 10, 0) 82%, rgba(6, 8, 10, 0.7) 100%);
}

main, .top { position: relative; z-index: 1; }

/* Scroll progress hairline */
.progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 1px;
  z-index: 3;
  background: transparent;
}
.progress span {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: 0 50%;
}

/* Header */
.top {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px var(--gutter);
  background: linear-gradient(180deg, rgba(6, 8, 10, 0.9) 0%, rgba(6, 8, 10, 0.6) 70%, rgba(6, 8, 10, 0) 100%);
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--display);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.emblem { display: block; height: 1.5em; width: auto; }
.motion .emblem { animation: emblemIn 0.7s ease both; }
@keyframes emblemIn { from { opacity: 0; } to { opacity: 1; } }
.nav { display: flex; gap: clamp(16px, 3vw, 40px); }
.nav a {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--dim);
  transition: color 0.25s;
}
.nav a:hover { color: var(--fg); }
.nav a.is-current { color: var(--accent); }

/* Hero */
.hero {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  position: relative;
  padding: 120px 0 96px;
}
.hero .label { margin-bottom: 28px; color: var(--accent); }
.lede { margin-top: 32px; max-width: 46ch; color: var(--dim); }
.cue {
  position: absolute;
  left: var(--gutter);
  bottom: 32px;
  padding-left: 56px;
}
.cue::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 40px;
  height: 1px;
  background: var(--dim);
}

/* Statement */
.statement {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 120px 0;
  border-top: 1px solid var(--line);
}
.statement .label { margin-bottom: 28px; color: var(--accent); }
.statement h2 { max-width: 40rem; }
.statement__body { max-width: 38rem; margin-top: 28px; color: var(--dim); }

/* Research focus: plain stacked list by default */
.focus { padding: 96px 0; border-top: 1px solid var(--line); }
.focus__head { display: flex; justify-content: space-between; margin-bottom: 48px; }
.focus__count { display: none; }
.focus__items { display: grid; gap: 56px; }
.focus__item { max-width: 40ch; }
.focus__item .num { color: var(--accent); margin-bottom: 16px; }
.focus__item h2 { margin-bottom: 18px; }
.focus__item p:last-child { color: var(--dim); }

/* Panels */
.panel {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 120px 0;
  border-top: 1px solid var(--line);
}
.panel__cols {
  display: grid;
  grid-template-columns: minmax(0, 30rem);
  gap: clamp(56px, 9vh, 96px);
}
.panel .label { margin-bottom: 22px; color: var(--accent); }
.panel h2 { margin-bottom: 22px; }
.panel p:last-child { color: var(--dim); max-width: 44ch; }

/* Contact */
.contact {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  padding: 120px 0 0;
  border-top: 1px solid var(--line);
}
.contact .wrap:first-child { margin-top: auto; margin-bottom: auto; }
.contact .label { margin-bottom: 22px; }
.contact h2 { font-size: clamp(1rem, 3.4vw, 2.6rem); overflow-wrap: anywhere; }
.contact h2 a {
  background: linear-gradient(var(--accent), var(--accent)) 0 100% / 0 1px no-repeat;
  padding-bottom: 8px;
  transition: background-size 0.4s ease;
}
.contact h2 a:hover { background-size: 100% 1px; }
.foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 28px;
  padding-bottom: 28px;
  border-top: 1px solid var(--line);
}

/* Motion layer: only when JavaScript runs and the visitor has not asked for reduced motion */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Type-on text: characters wait hidden, then appear in order. The newest
   ones carry a highlight that fades out behind the typing front. */
.type .c { opacity: 0; }
.type.done .c { opacity: 1; }
.type.typing .c {
  animation: typeIn calc(var(--step, 10ms) * 12 + 60ms) linear both;
  animation-delay: calc(var(--i) * var(--step, 10ms));
}
@keyframes typeIn {
  0% { opacity: 0; color: #ffffff; background-color: rgba(124, 200, 255, 0.42); }
  12% { opacity: 1; color: #ffffff; background-color: rgba(124, 200, 255, 0.42); }
  55% { opacity: 1; background-color: rgba(124, 200, 255, 0.14); }
  100% { opacity: 1; background-color: rgba(124, 200, 255, 0); }
}

.motion .focus { height: 400vh; padding: 0; }
.motion .focus__stick {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  display: flex;
  align-items: center;
}
.motion .focus__grid { width: 100%; }
.motion .focus__count { display: block; }
.motion .focus__items { gap: 0; }
.motion .focus__item {
  grid-area: 1 / 1;
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.6s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
  pointer-events: none;
}
.motion .focus__item.is-past { transform: translateY(-34px); }
.motion .focus__item.is-active { opacity: 1; transform: none; pointer-events: auto; }

.motion .cue::before { animation: cue 2.4s ease-in-out infinite; transform-origin: 0 50%; }
@keyframes cue {
  0%, 100% { transform: scaleX(0.35); }
  50% { transform: scaleX(1); }
}

@media (max-width: 760px) {
  .top { flex-direction: column; align-items: flex-start; gap: 12px; padding-top: 18px; padding-bottom: 22px; }
  .nav { width: 100%; justify-content: space-between; gap: 8px; }
  .nav a { font-size: 0.64rem; letter-spacing: 0.12em; }
  .veil {
    background:
      linear-gradient(180deg, rgba(6, 8, 10, 0.75) 0%, rgba(6, 8, 10, 0.45) 40%, rgba(6, 8, 10, 0.45) 60%, rgba(6, 8, 10, 0.8) 100%);
  }
  .foot { flex-direction: column; }
}

