:root {
  --bg: #050607;
  --bg-2: #0a0f0f;
  --surface: rgba(10, 15, 15, 0.76);
  --surface-strong: rgba(16, 24, 23, 0.92);
  --line: rgba(230, 246, 238, 0.15);
  --line-strong: rgba(230, 246, 238, 0.25);
  --text: #f4f0e7;
  --muted: #b7c1b9;
  --dim: #77847e;
  --teal: #19f28a;
  --ember: #ffb13b;
  --signal-right: #d8ffe9;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  font-family:
    Satoshi, Geist, "Avenir Next", ui-sans-serif, system-ui, -apple-system,
    BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
  background:
    radial-gradient(circle at 78% 12%, rgba(25, 242, 138, 0.13), transparent 28rem),
    radial-gradient(circle at 12% 58%, rgba(255, 177, 59, 0.09), transparent 24rem),
    linear-gradient(180deg, var(--bg), #070a0a 42%, var(--bg));
}

body::before {
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  content: "";
  opacity: 0.14;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(180deg, transparent, black 14%, black 82%, transparent);
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(100% - 36px, var(--max));
  min-height: 74px;
  margin: 0 auto;
  padding: 18px 0;
}

.brand,
.site-nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 12px;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 760;
}

.brand-mark {
  position: relative;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  background: rgba(5, 6, 7, 0.52);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.brand-mark span {
  position: absolute;
  width: 2px;
  height: 20px;
  border-radius: 1px;
  background: var(--teal);
  transform-origin: 50% 100%;
}

.brand-mark span:nth-child(1) {
  transform: translateY(1px) rotate(-34deg);
}

.brand-mark span:nth-child(2) {
  height: 23px;
  background: var(--ember);
}

.brand-mark span:nth-child(3) {
  transform: translateY(1px) rotate(34deg);
  background: var(--signal-right);
}

.site-nav {
  gap: 6px;
  padding: 6px;
  border: 1px solid var(--line);
  background: rgba(5, 6, 7, 0.58);
  backdrop-filter: blur(18px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.site-nav a {
  padding: 10px 14px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 720;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--text);
  outline: none;
}

.hero {
  position: relative;
  display: grid;
  align-items: end;
  min-height: 86svh;
  overflow: hidden;
  padding: 132px max(18px, calc((100vw - var(--max)) / 2)) 72px;
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-image {
  background-image: url("/assets/triune-hero-terminal-ember.png");
  background-position: 55% center;
  background-size: cover;
  filter: saturate(0.88) contrast(1.08);
  transform: scale(1.02);
}

.hero-shade {
  background:
    radial-gradient(circle at 72% 34%, rgba(25, 242, 138, 0.1), transparent 26rem),
    linear-gradient(90deg, rgba(5, 6, 7, 0.92) 0%, rgba(5, 6, 7, 0.62) 37%, rgba(5, 6, 7, 0.18) 69%, rgba(5, 6, 7, 0.58) 100%),
    linear-gradient(180deg, rgba(5, 6, 7, 0.18) 0%, rgba(5, 6, 7, 0.16) 54%, var(--bg) 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(100%, 1120px);
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  max-width: 10.8ch;
  color: var(--text);
  font-size: clamp(4rem, 9.6vw, 7.4rem);
  line-height: 0.86;
  font-weight: 820;
}

h1 span {
  display: inline;
}

.hero-content > p {
  max-width: 720px;
  margin-top: 28px;
  color: rgba(244, 240, 231, 0.78);
  font-size: clamp(1.1rem, 2vw, 1.46rem);
  line-height: 1.58;
}

.intro-band,
.section-grid,
.process-section,
.contact-section,
.site-footer {
  width: min(100% - 48px, var(--max));
  margin: 0 auto;
}

.section-grid,
.process-section,
.contact-section {
  scroll-margin-top: 104px;
}

.intro-band {
  display: grid;
  grid-template-columns: minmax(160px, 0.36fr) minmax(0, 1fr);
  gap: clamp(28px, 6vw, 84px);
  align-items: end;
  padding: 96px 0 120px;
}

.intro-number {
  color: var(--teal);
  font-size: clamp(5.8rem, 15vw, 11rem);
  font-weight: 820;
  line-height: 0.74;
}

.intro-band p {
  max-width: 840px;
  color: var(--muted);
  font-size: clamp(1.35rem, 3vw, 2.55rem);
  line-height: 1.22;
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.62fr) minmax(0, 1.5fr);
  gap: clamp(42px, 7vw, 92px);
  padding: 110px 0 128px;
  border-top: 1px solid var(--line);
}

.section-copy {
  position: sticky;
  top: 116px;
  align-self: start;
}

h2 {
  max-width: 9.5ch;
  color: var(--text);
  font-size: clamp(2.75rem, 6.2vw, 6rem);
  line-height: 0.9;
  font-weight: 800;
}

.section-copy p,
.contact-section p {
  margin-top: 26px;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.72;
}

.service-bento {
  display: grid;
  grid-auto-flow: dense;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(190px, auto));
  gap: 14px;
}

.service-card {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  padding: 24px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.02)),
    var(--surface);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform 700ms cubic-bezier(0.16, 1, 0.3, 1), border-color 700ms;
}

.service-card::after {
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(25, 242, 138, 0.46), transparent);
  opacity: 0;
  transition: opacity 700ms;
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: rgba(25, 242, 138, 0.34);
}

.service-card:hover::after {
  opacity: 1;
}

.service-card.primary {
  grid-column: span 3;
  grid-row: span 2;
  min-height: 434px;
  background:
    linear-gradient(180deg, rgba(5, 6, 7, 0.14), rgba(5, 6, 7, 0.78)),
    url("/assets/triune-hero-terminal-ember.png") center / cover;
}

.service-card.tall {
  grid-column: span 3;
  grid-row: span 1;
}

.service-card:not(.primary):not(.tall) {
  grid-column: span 3;
}

.service-card.quiet {
  grid-column: span 6;
}

.service-card h3 {
  position: relative;
  z-index: 1;
  max-width: 12ch;
  color: var(--text);
  overflow-wrap: break-word;
  font-size: clamp(1.1rem, 1.65vw, 1.5rem);
  line-height: 1.04;
}

.service-card.primary h3 {
  font-size: clamp(1.28rem, 2vw, 1.85rem);
}

.service-card p {
  position: relative;
  z-index: 1;
  max-width: 34ch;
  margin-top: 72px;
  color: var(--muted);
  font-size: 0.96rem;
  line-height: 1.62;
}

.service-card.primary p {
  margin-top: 118px;
  color: rgba(244, 240, 231, 0.82);
  font-size: 1.06rem;
}

.service-card.quiet {
  display: grid;
  grid-template-columns: minmax(0, 0.42fr) minmax(0, 1fr);
  gap: 28px;
  align-items: end;
  min-height: 190px;
  border-color: rgba(255, 177, 59, 0.24);
  background:
    radial-gradient(circle at 24px 28px, rgba(255, 177, 59, 0.18), transparent 12rem),
    var(--surface-strong);
}

.service-card.quiet p {
  margin-top: 0;
}

.service-card span {
  position: absolute;
  right: 24px;
  bottom: 22px;
  left: 24px;
  color: rgba(244, 240, 231, 0.44);
  font-size: 0.78rem;
  font-weight: 760;
  text-transform: uppercase;
}

.process-section {
  padding: 120px 0 136px;
  border-top: 1px solid var(--line);
}

.process-section h2 {
  max-width: 12ch;
}

.process-accordion {
  display: grid;
  grid-template-columns: 1.25fr 0.9fr 0.9fr;
  gap: 14px;
  margin-top: 54px;
}

.process-accordion article {
  min-height: 360px;
  padding: 28px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.018)),
    rgba(8, 12, 12, 0.82);
  transition:
    grid-column 700ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 700ms cubic-bezier(0.16, 1, 0.3, 1),
    border-color 700ms;
}

.process-accordion article:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
}

.process-accordion h3 {
  color: var(--text);
  font-size: clamp(2rem, 4vw, 4.4rem);
  line-height: 0.9;
}

.process-accordion p {
  max-width: 34ch;
  margin-top: 180px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.68;
}

.contact-section {
  padding: 104px 0 116px;
  border-top: 1px solid var(--line);
}

.contact-section p {
  max-width: 620px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 32px;
  border: 1px solid rgba(244, 240, 231, 0.54);
  padding: 0 18px;
  color: var(--text);
  background: transparent;
  font-size: 0.9rem;
  font-weight: 760;
  transition: border-color 240ms, background 240ms, transform 240ms;
}

.button:hover,
.button:focus-visible {
  border-color: var(--teal);
  background: rgba(25, 242, 138, 0.08);
  outline: none;
  transform: translateY(-1px);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 0 34px;
  border-top: 1px solid var(--line);
  color: var(--dim);
  font-size: 0.82rem;
}

[data-reveal] {
  opacity: 1;
  transform: translateY(0);
}

.reveal-ready [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 900ms cubic-bezier(0.16, 1, 0.3, 1), transform 900ms cubic-bezier(0.16, 1, 0.3, 1);
}

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

@media (max-width: 960px) {
  .site-header {
    position: absolute;
    align-items: flex-start;
    min-height: 0;
  }

  .site-nav {
    display: none;
  }

  .hero {
    min-height: 80svh;
    padding-top: 112px;
  }

  .hero-image {
    background-position: 60% center;
  }

  .hero-shade {
    background:
      linear-gradient(90deg, rgba(5, 6, 7, 0.95), rgba(5, 6, 7, 0.46)),
      linear-gradient(180deg, rgba(5, 6, 7, 0.14), var(--bg));
  }

  h1 {
    max-width: 9ch;
    font-size: clamp(3.8rem, 12vw, 6.2rem);
  }

  h1 span {
    display: block;
  }

  .intro-band,
  .section-grid {
    grid-template-columns: 1fr;
  }

  .section-copy {
    position: static;
  }

  .service-bento {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }

  .service-card.primary,
  .service-card.tall {
    grid-column: span 1;
    grid-row: span 1;
    min-height: 260px;
  }

  .service-card.primary {
    grid-column: span 2;
  }

  .service-card.quiet {
    display: block;
    grid-column: span 2;
  }

  .service-card p,
  .service-card.primary p,
  .process-accordion p {
    margin-top: 44px;
  }

  .process-accordion {
    grid-template-columns: 1fr;
  }

  .process-accordion article {
    min-height: 0;
  }
}

@media (max-width: 560px) {
  .site-header,
  .intro-band,
  .section-grid,
  .process-section,
  .contact-section,
  .site-footer {
    width: min(100% - 32px, var(--max));
  }

  .brand {
    font-size: 0.88rem;
  }

  .hero {
    min-height: 72svh;
    padding-inline: 16px;
    padding-bottom: 36px;
  }

  h1 {
    max-width: 9ch;
    font-size: clamp(3.15rem, 15vw, 4.4rem);
    line-height: 0.9;
  }

  .hero-content > p {
    margin-top: 22px;
  }

  .intro-band {
    padding: 72px 0 86px;
  }

  .section-grid,
  .process-section,
  .contact-section {
    padding-block: 72px;
  }

  .service-bento {
    grid-template-columns: 1fr;
  }

  .service-card.primary {
    grid-column: span 1;
  }

  .service-card.quiet {
    grid-column: span 1;
  }

  .service-card span {
    position: static;
    display: block;
    margin-top: 36px;
  }

  .button {
    width: 100%;
  }

  .site-footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
  }

  .reveal-ready [data-reveal],
  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
