:root {
  color-scheme: light;
  --ink: #151514;
  --ink-soft: #34312d;
  --muted: #6d665e;
  --paper: #f7f2e8;
  --paper-strong: #fffaf1;
  --glass: rgba(255, 250, 241, 0.68);
  --line: rgba(21, 21, 20, 0.13);
  --line-strong: rgba(21, 21, 20, 0.2);
  --blue: #1d5e78;
  --blue-dark: #123d4e;
  --coral: #cf6549;
  --acid: #b7c95c;
  --violet: #6d5bd0;
  --shadow: 0 24px 70px rgba(46, 38, 29, 0.13);
  --radius: 8px;
  --max: 1160px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(rgba(21, 21, 20, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(21, 21, 20, 0.035) 1px, transparent 1px),
    radial-gradient(circle at 14% 8%, rgba(207, 101, 73, 0.2), transparent 24rem),
    radial-gradient(circle at 84% 12%, rgba(29, 94, 120, 0.2), transparent 28rem),
    radial-gradient(circle at 78% 72%, rgba(183, 201, 92, 0.16), transparent 22rem),
    linear-gradient(180deg, var(--paper), #f3eadc 62%, #faf6ed);
  background-size:
    42px 42px,
    42px 42px,
    auto,
    auto,
    auto,
    auto;
  color: var(--ink);
  font-family:
    ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(115deg, transparent 0 47%, rgba(21, 21, 20, 0.07) 47.15% 47.35%, transparent 47.5%),
    linear-gradient(78deg, transparent 0 61%, rgba(29, 94, 120, 0.08) 61.1% 61.35%, transparent 61.5%);
  mask-image: linear-gradient(180deg, #000, transparent 76%);
}

a {
  color: inherit;
}

a:focus-visible,
button:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(109, 91, 208, 0.55);
  outline-offset: 4px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: 1rem;
  z-index: 10;
  transform: translateY(-160%);
  background: var(--ink);
  color: white;
  padding: 0.6rem 0.8rem;
  border-radius: var(--radius);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  border-bottom: 1px solid var(--line);
  background: rgba(247, 242, 232, 0.78);
  backdrop-filter: blur(18px);
}

.nav,
.section,
.site-footer {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

.nav {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand,
.nav-actions,
.hero-actions,
.footer-links {
  display: flex;
  align-items: center;
}

.brand {
  gap: 0.75rem;
  font-weight: 780;
  text-decoration: none;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 2.65rem;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  background:
    linear-gradient(135deg, var(--ink), var(--blue-dark)),
    var(--ink);
  color: var(--paper);
  font-size: 0.76rem;
  letter-spacing: 0;
  box-shadow: 0 10px 28px rgba(18, 61, 78, 0.22);
}

.brand-text {
  white-space: nowrap;
}

.nav-actions {
  gap: clamp(0.55rem, 2vw, 1.15rem);
  color: var(--muted);
  font-size: 0.94rem;
}

.nav-actions a,
.text-link,
.footer-links a,
.project-link {
  text-decoration: none;
  background-image: linear-gradient(currentColor, currentColor);
  background-position: 0 100%;
  background-repeat: no-repeat;
  background-size: 0 1px;
  transition:
    background-size 180ms ease,
    color 180ms ease,
    transform 180ms ease;
}

.nav-actions a:hover,
.text-link:hover,
.footer-links a:hover,
.project-link:hover {
  color: var(--blue-dark);
  background-size: 100% 1px;
}

.language-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.language-select {
  min-height: 2.35rem;
  max-width: 8.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 250, 241, 0.82);
  color: var(--ink);
  padding: 0 0.65rem;
  font: inherit;
}

.section {
  padding: clamp(4rem, 8vw, 7rem) 0;
}

.hero {
  min-height: calc(100vh - 74px);
  display: grid;
  align-items: center;
  padding-top: 3.25rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.74fr);
  gap: clamp(2rem, 6vw, 5.75rem);
  align-items: center;
}

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

.eyebrow {
  margin: 0 0 0.9rem;
  color: var(--blue-dark);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: normal;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink);
  letter-spacing: 0;
  text-wrap: balance;
}

h1 {
  max-width: 9.6ch;
  font-size: clamp(3.1rem, 9.4vw, 6.65rem);
  line-height: 0.92;
}

h1 span {
  display: block;
}

.highlight {
  color: transparent;
  background:
    linear-gradient(90deg, var(--blue-dark), var(--violet) 48%, var(--coral)),
    var(--ink);
  background-clip: text;
}

h2 {
  max-width: 13.5ch;
  font-size: clamp(2rem, 5vw, 4.35rem);
  line-height: 0.98;
}

h3 {
  font-size: clamp(1.05rem, 2vw, 1.24rem);
  line-height: 1.12;
}

.hero-text {
  max-width: 42rem;
  margin: 1.3rem 0 0;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.8vw, 1.24rem);
  text-wrap: pretty;
}

.hero-actions {
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  border-radius: var(--radius);
  padding: 0 1.05rem;
  font-weight: 780;
  text-decoration: none;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease,
    border-color 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--ink);
  color: var(--paper);
  box-shadow: var(--shadow);
}

.button-secondary {
  border: 1px solid var(--line-strong);
  background: var(--glass);
  backdrop-filter: blur(16px);
}

.lab-panel,
.project-card,
.principle-card,
.rules-list li {
  border: 1px solid rgba(255, 255, 255, 0.62);
  background:
    linear-gradient(145deg, rgba(255, 250, 241, 0.82), rgba(255, 250, 241, 0.44)),
    rgba(255, 250, 241, 0.54);
  box-shadow:
    inset 0 0 0 1px rgba(21, 21, 20, 0.08),
    0 16px 42px rgba(46, 38, 29, 0.08);
  backdrop-filter: blur(18px);
}

.lab-panel {
  position: relative;
  min-height: 29rem;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.lab-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent 0 18%, rgba(21, 21, 20, 0.08) 18.2% 18.5%, transparent 18.7%),
    linear-gradient(0deg, transparent 0 58%, rgba(21, 21, 20, 0.08) 58.2% 58.5%, transparent 58.7%);
}

.panel-topline {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  padding: 1rem;
  color: var(--blue-dark);
  font-size: 0.8rem;
  font-weight: 850;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.signal-stack {
  position: relative;
  z-index: 1;
  margin: 0.25rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(255, 250, 241, 0.52);
}

.signal-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.95rem;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.signal-row:last-child {
  border-bottom: 0;
}

.signal-row strong {
  color: var(--ink);
}

.lab-geometry {
  position: absolute;
  inset: 32% 10% 8%;
}

.lab-geometry::before,
.lab-geometry::after {
  content: "";
  position: absolute;
  inset: 4%;
  border: 1px solid rgba(21, 21, 20, 0.18);
  transform: rotate(-10deg);
}

.lab-geometry::after {
  inset: 19% 14%;
  border-color: rgba(29, 94, 120, 0.3);
  transform: rotate(12deg);
}

.lab-geometry span {
  position: absolute;
  display: block;
  border-radius: 999px;
}

.lab-geometry span:nth-child(1) {
  width: 42%;
  height: 1px;
  left: 5%;
  top: 28%;
  background: var(--coral);
}

.lab-geometry span:nth-child(2) {
  width: 1px;
  height: 52%;
  left: 62%;
  top: 13%;
  background: var(--blue);
}

.lab-geometry span:nth-child(3) {
  width: 0.7rem;
  aspect-ratio: 1;
  right: 14%;
  top: 18%;
  background: var(--acid);
  box-shadow: 0 0 0 0.8rem rgba(183, 201, 92, 0.12);
}

.lab-geometry span:nth-child(4) {
  width: 0.85rem;
  aspect-ratio: 1;
  left: 26%;
  bottom: 22%;
  background: var(--ink);
  box-shadow: 0 0 0 1rem rgba(21, 21, 20, 0.08);
}

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 5vw, 4rem);
  align-items: end;
  border-top: 1px solid var(--line);
}

.split-section > p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.08rem, 2vw, 1.46rem);
  text-wrap: pretty;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.text-link {
  color: var(--blue-dark);
  font-weight: 780;
  white-space: nowrap;
}

.project-grid,
.principle-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.project-card,
.principle-card {
  position: relative;
  min-height: 16rem;
  border-radius: var(--radius);
  padding: 1.15rem;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease;
}

.project-card::before,
.principle-card::before {
  content: "";
  position: absolute;
  inset: 0.7rem 0.7rem auto auto;
  width: 2.4rem;
  height: 1px;
  background: var(--coral);
}

.project-card:hover,
.principle-card:hover {
  transform: translateY(-4px);
  border-color: rgba(29, 94, 120, 0.24);
  box-shadow: 0 24px 54px rgba(46, 38, 29, 0.12);
}

.project-meta {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.project-card h3 {
  margin-top: 2rem;
}

.project-card p,
.principle-card p {
  margin: 0.7rem 0 0;
  color: var(--muted);
  text-wrap: pretty;
}

.project-link {
  position: absolute;
  left: 1.15rem;
  bottom: 1.15rem;
  color: var(--blue-dark);
  font-weight: 800;
}

.muted-link {
  color: var(--muted);
  background-image: none;
}

.status {
  color: var(--blue-dark);
  font-weight: 780;
}

.project-section,
.philosophy,
.rules {
  border-top: 1px solid var(--line);
}

.principle-card span {
  display: inline-block;
  margin-bottom: 2rem;
  color: var(--coral);
  font-weight: 850;
}

.rules-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
  padding: 0;
  margin: 0;
  list-style: none;
}

.rules-list li {
  border-left: 3px solid var(--blue);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 2rem 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer p {
  margin: 0;
}

.site-footer p:first-child {
  color: var(--ink);
  font-weight: 780;
}

.footer-links {
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.9rem;
}

.footer-links a {
  color: var(--ink);
  font-weight: 760;
}

[data-animate] {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 520ms ease,
    transform 520ms ease;
}

[data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

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

  [data-animate] {
    opacity: 1;
    transform: none;
  }
}

@supports not (text-wrap: balance) {
  h1,
  h2,
  h3 {
    max-width: 14ch;
  }
}

@media (max-width: 900px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 1rem 0;
  }

  .nav-actions {
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.7rem 1rem;
  }

  .hero {
    min-height: auto;
  }

  .hero-grid,
  .split-section,
  .project-grid,
  .principle-grid,
  .rules-list {
    grid-template-columns: 1fr;
  }

  h1 {
    max-width: 9ch;
    font-size: clamp(3rem, 13vw, 5.4rem);
  }

  h2 {
    max-width: 16ch;
  }

  .lab-panel {
    min-height: 24rem;
  }

  .project-card,
  .principle-card {
    min-height: 13.5rem;
  }
}

@media (max-width: 560px) {
  .nav,
  .section,
  .site-footer {
    width: min(var(--max), calc(100% - 1.25rem));
  }

  .brand-text {
    white-space: normal;
  }

  .nav-actions a {
    min-height: 2.3rem;
    display: inline-flex;
    align-items: center;
  }

  .language-select {
    width: 100%;
    max-width: none;
  }

  .hero {
    padding-top: 2.4rem;
  }

  h1 {
    max-width: 8.8ch;
    font-size: clamp(2.75rem, 16vw, 4.55rem);
    line-height: 0.96;
  }

  .hero-actions,
  .button,
  .site-footer,
  .footer-links {
    width: 100%;
  }

  .button,
  .site-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .footer-links {
    align-items: flex-start;
    justify-content: flex-start;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }
}
