/* Adealia: one stylesheet. Tokens first. */

@font-face { font-family: "Space Grotesk"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/space-grotesk-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Space Grotesk"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/space-grotesk-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Sans"; font-weight: 600; font-style: normal; font-display: swap; src: url("fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/ibm-plex-mono-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2"); }

:root {
  --navy: #1A2547;
  --paper: #F6F4EF;
  --slate: #33475B;
  --copper: #D97A34;
  --green: #1F9D74;
  --blue: #2F6DF6;
  --copper-deep: #A85A22;
  --cta-hover: #94501E;
  --green-deep: #0F6B4F;
  --blue-deep: #1B54D0;
  --line: #DFD9CE;
  --line-soft: #EBE7DE;
  --line-strong: #CBC3B4;
  --card: #FFFFFF;
  --sunken: #EDEAE3;
  --navy-deep: #11173A;

  --display: "Space Grotesk", ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  --body: "IBM Plex Sans", ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --bar: 4rem;
}

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

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scrollbar-color: var(--line-strong) var(--paper); scroll-padding-top: var(--bar); }

body {
  margin: 0;
  background: var(--paper);
  color: var(--navy);
  font: 400 1.0625rem/1.6 var(--body);
  caret-color: var(--navy);
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--navy); color: var(--paper); }
.dark ::selection, .hero ::selection, .contact ::selection { background: var(--paper); color: var(--navy); }

img { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; }
.bar :focus-visible, .hero :focus-visible, .dark :focus-visible, .contact :focus-visible { outline-color: var(--paper); }

.wrap { width: min(100% - 2 * var(--gutter), 72rem); margin-inline: auto; }
.section { padding-block: clamp(4.5rem, 9vw, 8.5rem); }

.skip {
  position: absolute; left: var(--gutter); top: -4rem; z-index: 30;
  padding: 0.6rem 1rem; background: var(--paper); color: var(--navy); font-weight: 600;
}
.skip:focus { top: 0.75rem; }

/* Bar: fixed and translucent so the photograph runs under it */

.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  background: rgb(26 37 71 / 0.92);
  color: var(--paper);
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .bar {
    background: rgb(26 37 71 / 0.84);
    -webkit-backdrop-filter: blur(18px) saturate(1.15);
    backdrop-filter: blur(18px) saturate(1.15);
  }
}
.bar::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 1px;
  background: color-mix(in srgb, var(--paper) 16%, transparent);
}
.bar-sun {
  display: none; position: absolute; bottom: -3px; z-index: 1;
  left: calc(var(--p, 0) * (100% - 7px));
  width: 7px; height: 7px; border-radius: 50%; background: var(--copper);
}
.has-js .bar-sun { display: block; }

.bar-inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--bar); gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: 0.65rem; text-decoration: none; font: 500 1.5rem/1 var(--display); letter-spacing: -0.02em; }
.brand-mark { width: 2.5rem; height: 2.5rem; flex: none; }
.brand-sun { fill: var(--copper); }
.bar-right { display: flex; align-items: center; gap: clamp(0.75rem, 2.5vw, 1.75rem); }
.nav { display: flex; gap: clamp(1rem, 3.5vw, 1.75rem); }
.nav-link { text-decoration: none; font-weight: 500; font-size: 0.9375rem; padding-block: 0.8rem; border-bottom: 1px solid transparent; }
.nav-link:hover { border-bottom-color: currentColor; }

.btn {
  display: inline-block;
  padding: 0.85rem 1.6rem;
  border-radius: 0.25rem;
  background: var(--copper);
  color: var(--navy-deep);
  font: 600 1.0625rem/1.2 var(--body);
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.btn:hover { background: var(--copper-deep); color: var(--card); }

.bar-cta { padding: 0.55rem 1rem; font-size: 0.9375rem; }
.has-js .bar-cta {
  opacity: 0; visibility: hidden; transform: translateY(-4px);
  transition: opacity 0.3s ease, transform 0.4s var(--ease-out), visibility 0s linear 0.3s, background-color 0.2s ease, color 0.2s ease;
}
.has-js .bar.is-past-hero .bar-cta { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }

/* Hero */

.hero {
  position: relative;
  display: grid;
  align-items: end;
  min-height: max(36rem, 100svh);
  background: var(--navy-deep);
  color: var(--paper);
  isolation: isolate;
  overflow: hidden;
  overflow: clip;
}
.hero-media { position: absolute; inset: 0; z-index: -2; transform-origin: 50% 60%; }
.hero-media picture { display: block; height: 100%; }
.hero-img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 42%; }
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to top, rgb(17 23 58 / 0.88) 0%, rgb(17 23 58 / 0.6) 36%, rgb(17 23 58 / 0) 68%);
}
.hero-copy { padding-block: calc(var(--bar) + 2rem) clamp(1.75rem, 4vw, 2.75rem); }

.hero-title {
  margin: 0;
  font: 700 clamp(2.75rem, 1rem + 7vw, 6rem)/1.02 var(--display);
  letter-spacing: -0.035em;
  text-wrap: balance;
  animation: resolve 1.6s var(--ease-out) both;
}
.hero-desc { max-width: 38rem; margin: 1.25rem 0 0; color: color-mix(in srgb, var(--paper) 90%, transparent); font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem); }
.hero-actions { margin-top: 1.75rem; }
.hero-caption { margin: clamp(2rem, 5vw, 3.25rem) 0 0; color: color-mix(in srgb, var(--paper) 82%, transparent); font-size: 0.9375rem; font-weight: 500; }

@keyframes resolve {
  from { opacity: 0; filter: blur(14px); }
  to { opacity: 1; filter: blur(0); }
}

/* Statements resolve out of blur as they enter the viewport */

.statement {
  margin: 0;
  font: 700 clamp(2.5rem, 0.8rem + 6.2vw, 6rem)/1.02 var(--display);
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.has-js [data-resolve] { opacity: 0; filter: blur(14px); }
.has-js [data-resolve].is-in { opacity: 1; filter: blur(0); transition: opacity 1.1s var(--ease-out), filter 1.1s var(--ease-out); }

/* Section grammar */

.about-grid { display: grid; gap: 2rem 4rem; }
.about-title { margin: 0; font: 700 clamp(2rem, 0.9rem + 4.2vw, 4.5rem)/1.04 var(--display); letter-spacing: -0.035em; text-wrap: balance; }
.about-copy { max-width: 36rem; font-size: 1.1875rem; }
.about-copy p { margin: 0 0 1.25em; }
.about-copy p:last-child { margin-bottom: 0; }

.chapter { display: grid; align-content: center; min-height: min(80svh, 52rem); padding-block: clamp(5rem, 10vw, 9rem); }
.dark { background: var(--navy-deep); color: var(--paper); }
.chapter-support { max-width: 34rem; margin: clamp(1.5rem, 3vw, 2.25rem) 0 0; color: color-mix(in srgb, var(--paper) 82%, transparent); font-size: 1.25rem; }

.work-lede { margin: 1.5rem 0 0; color: var(--slate); font-size: 1.25rem; }

.figure-row { display: grid; gap: 1.5rem 4rem; align-items: end; margin-top: clamp(3rem, 6vw, 5rem); padding-bottom: clamp(2.5rem, 5vw, 4rem); border-bottom: 1px solid var(--line-strong); }
.figure { display: flex; align-items: baseline; gap: 0.75rem; }
.figure-num { color: var(--green-deep); font: 700 clamp(8.5rem, 3rem + 17vw, 16rem)/0.82 var(--display); letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.figure-hedge { color: var(--slate); font: 500 clamp(1.25rem, 1rem + 1vw, 1.75rem)/1 var(--display); }
.figure-unit { color: var(--slate); font: 500 clamp(1.5rem, 1rem + 1.4vw, 2.25rem)/1 var(--display); }

.built-list { margin: 0; padding: 0; list-style: none; }
.built-item { display: grid; gap: 0.75rem 4rem; padding-block: 1.75rem; border-bottom: 1px solid var(--line-strong); }
.built-name { margin: 0; font: 700 1.5rem/1.2 var(--display); letter-spacing: -0.02em; text-wrap: balance; }
.built-copy { max-width: 38rem; margin: 0.6rem 0 0; }
.built-item .built-copy { margin: 0; }

.team { background: var(--sunken); }
.team-title { margin: 0; font: 700 clamp(1.875rem, 1.2rem + 2.4vw, 3rem)/1.1 var(--display); letter-spacing: -0.03em; text-wrap: balance; }
.founder { display: grid; gap: 2rem 4rem; align-items: start; margin-top: clamp(2.5rem, 5vw, 4rem); }
.founder-photo { width: min(100%, 13rem); height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
.founder-name { margin: 0; font: 700 clamp(1.75rem, 1.2rem + 1.6vw, 2.5rem)/1.1 var(--display); letter-spacing: -0.03em; }
.founder-role { margin: 0.4rem 0 0; color: var(--slate); font-size: 1.0625rem; }
.founder-bio { max-width: 34rem; margin: 1.5rem 0 0; font-size: 1.1875rem; line-height: 1.6; }

/* Contact: the photograph returns */

.contact {
  position: relative; isolation: isolate; overflow: hidden; overflow: clip;
  background: var(--navy-deep); color: var(--paper);
  padding-block: clamp(6rem, 12vw, 10rem);
}
.contact-bg { position: absolute; inset: 0; z-index: -2; }
.contact-bg picture { display: block; height: 100%; }
.contact-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; }
.contact::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: rgb(17 23 58 / 0.86);
}
@media (min-width: 56rem) {
  .contact::after {
    background:
      linear-gradient(to top, rgb(17 23 58 / 0.7), rgb(17 23 58 / 0) 45%),
      linear-gradient(to right, rgb(17 23 58 / 0.92) 0%, rgb(17 23 58 / 0.7) 45%, rgb(17 23 58 / 0.28) 100%);
  }
}
.contact-lede { max-width: 30rem; margin: clamp(1.5rem, 3vw, 2.25rem) 0 0; color: color-mix(in srgb, var(--paper) 88%, transparent); font-size: 1.25rem; }
.contact-address { display: inline-block; margin-top: clamp(2rem, 4vw, 3rem); font: 500 clamp(1.75rem, 1rem + 3.4vw, 3.5rem)/1.1 var(--display); letter-spacing: -0.03em; overflow-wrap: anywhere; }
.place { margin: clamp(2.5rem, 5vw, 4rem) 0 0; color: color-mix(in srgb, var(--paper) 82%, transparent); }
.place-name { display: block; color: var(--paper); font-weight: 500; }

.foot { padding-block: 1.5rem; font-size: 0.9375rem; border-top: 1px solid color-mix(in srgb, var(--paper) 22%, transparent); }
.foot-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 2rem; color: color-mix(in srgb, var(--paper) 82%, transparent); }
.foot-inner p { margin: 0; }

@media (min-width: 56rem) {
  .about-grid { grid-template-columns: 6fr 5fr; align-items: end; }
  .figure-row { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .built-item { grid-template-columns: 5fr 7fr; }
  .founder { grid-template-columns: 13rem minmax(0, 1fr); gap: 2rem 3.5rem; }
}

@media (max-width: 40rem) {
  .bar-cta { display: none; }
  .has-js .bar.is-past-hero .bar-cta { display: inline-block; }
  .bar.is-past-hero .nav { display: none; }
}

/* Scroll-driven enhancement where supported; the IntersectionObserver path covers the rest */

@supports (animation-timeline: view()) {
  .has-js [data-resolve] {
    opacity: 1; filter: none;
    animation: resolve linear both;
    animation-timeline: view();
    animation-range: entry 8% entry 78%;
    transition: none;
  }
  .hero-media { animation: dolly linear both; animation-timeline: view(); animation-range: exit 0% exit 100%; }
  .contact-bg { animation: settle linear both; animation-timeline: view(); animation-range: entry 0% cover 55%; }
}
@keyframes dolly { to { transform: scale(1.08); } }
@keyframes settle { from { transform: scale(1.1); } to { transform: scale(1); } }

@media (prefers-reduced-motion: reduce) {
  .hero-title { animation: none; }
  .has-js [data-resolve], .has-js [data-resolve].is-in { opacity: 1; filter: none; animation: none; transition: none; }
  .hero-media, .contact-bg { animation: none; }
  .btn, .has-js .bar-cta { transition: none; }
}
