/* Tanto site styles.
   Order: tokens, base, type, buttons, header, hero, product mockups,
   sections, page components, footer, motion.
   Colors are defined once in :root. scripts/check_site.py fails on any
   color that is not in the brand palette, so add new ones there too. */

:root {
  /* Surfaces */
  --canvas: #F6F4F1;
  --panel: #EFECE7;
  --card: #FFFFFF;

  /* Text */
  --ink: #1A1916;
  --ink-2: #3F3D39;
  --ink-3: #6E6A64;
  --hairline: rgba(26, 25, 22, 0.12);
  --hairline-strong: rgba(26, 25, 22, 0.22);

  /* Tanto orange range */
  --orange: #C4511A;
  --orange-hover: #9C3F12;
  --coral: #E27E57;
  --apricot: #ECB07E;
  --cream: #F6DDA6;
  --orange-wash: rgba(196, 81, 26, 0.1);

  /* Blue range */
  --blue: #2F62D8;
  --blue-deep: #17349A;
  --sky: #3C73C6;
  --violet: #8C74B8;
  --blue-wash: rgba(47, 98, 216, 0.1);

  /* Night: dark sections and shadow tint */
  --night: #0E1430;
  --night-2: #18214A;
  --on-dark: #FFFFFF;
  --on-dark-2: rgba(255, 255, 255, 0.76);
  --on-dark-3: rgba(255, 255, 255, 0.56);
  --hairline-dark: rgba(255, 255, 255, 0.14);

  /* Depth */
  --shadow-1: 0 1px 2px rgba(14, 20, 48, 0.06), 0 4px 14px rgba(14, 20, 48, 0.05);
  --shadow-2: 0 2px 6px rgba(14, 20, 48, 0.06), 0 24px 60px rgba(14, 20, 48, 0.16);
  --shadow-3: 0 40px 100px rgba(14, 20, 48, 0.34);

  /* Shape */
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-pill: 999px;

  /* Type */
  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: "Newsreader", Georgia, "Times New Roman", serif;
  --font-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  /* Layout */
  --wrap: 1200px;
  --gutter: clamp(20px, 4vw, 40px);
  --section: clamp(96px, 11vw, 168px);
  --header-h: 72px;
  /* Height of the tanto-tip cut on the hero and closing band */
  --cut: clamp(56px, 9vw, 150px);

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

/* Base */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

img,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

h1,
h2,
h3,
h4,
p,
ul,
ol,
dl,
dd,
figure,
blockquote {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

strong {
  font-weight: 500;
}

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection {
  background: var(--cream);
  color: var(--ink);
}

.skip-link {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: var(--r-pill);
  background: var(--ink);
  color: var(--canvas);
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.2s var(--ease-out);
}

.skip-link:focus {
  transform: none;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.wrap {
  width: min(100% - 2 * var(--gutter), var(--wrap));
  margin-inline: auto;
}

/* Lenis (smooth scroll) base rules, copied from lenis@1.3.26/dist/lenis.css.
   Update them together with the Lenis version in the pages. */

html.lenis,
html.lenis body {
  height: auto;
}

.lenis:not(.lenis-autoToggle).lenis-stopped {
  overflow: clip;
}

.lenis [data-lenis-prevent],
.lenis [data-lenis-prevent-wheel],
.lenis [data-lenis-prevent-touch],
.lenis [data-lenis-prevent-vertical],
.lenis [data-lenis-prevent-horizontal] {
  overscroll-behavior: contain;
}

.lenis.lenis-smooth iframe {
  pointer-events: none;
}

.lenis.lenis-autoToggle {
  transition-property: overflow;
  transition-duration: 1ms;
  transition-behavior: allow-discrete;
}

/* Type */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--ink-3);
}

.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: var(--orange);
}

.display {
  font-size: clamp(46px, 6.6vw, 92px);
  font-weight: 300;
  line-height: 0.98;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.h2 {
  font-size: clamp(36px, 4.6vw, 64px);
  font-weight: 300;
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.h3 {
  font-size: clamp(24px, 2.2vw, 30px);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.h4 {
  font-size: 19px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.display em,
.h2 em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  letter-spacing: -0.02em;
}

.lede {
  font-size: clamp(18px, 1.5vw, 21px);
  line-height: 1.55;
  color: var(--ink-2);
  text-wrap: pretty;
}

.prose > * + * {
  margin-top: 1em;
}

.prose p {
  color: var(--ink-2);
  text-wrap: pretty;
}

.list {
  display: grid;
  gap: 10px;
}

.list li {
  position: relative;
  padding-left: 26px;
  color: var(--ink-2);
}

.list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.8em;
  width: 12px;
  height: 2px;
  background: var(--orange);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-weight: 500;
  text-decoration: none;
}

.text-link .arrow {
  transition: transform 0.3s var(--ease-out);
}

.text-link:hover .arrow {
  transform: translateX(4px);
}

.text-link:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font: 500 15px/1 var(--font-sans);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.btn .arrow {
  transition: transform 0.3s var(--ease-out);
}

.btn:hover .arrow {
  transform: translateX(4px);
}

.btn--ink {
  background: var(--ink);
  color: var(--canvas);
}

.btn--ink:hover {
  background: var(--night-2);
}

.btn--accent {
  background: var(--orange);
  color: var(--on-dark);
}

.btn--accent:hover {
  background: var(--orange-hover);
}

.btn--light {
  background: var(--card);
  color: var(--ink);
}

.btn--light:hover {
  background: var(--cream);
}

.btn--ghost-light {
  border-color: rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.06);
  color: var(--on-dark);
  backdrop-filter: blur(8px);
}

.btn--ghost-light:hover {
  border-color: var(--on-dark);
  background: rgba(255, 255, 255, 0.14);
}

.btn--ghost {
  border-color: var(--hairline-strong);
  color: var(--ink);
}

.btn--ghost:hover {
  border-color: var(--ink);
}

/* Header */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  color: var(--on-dark);
  transition: background-color 0.35s ease, color 0.35s ease, box-shadow 0.35s ease;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 100%;
}

.site-header.is-solid,
.site-header.menu-open {
  background: rgba(246, 244, 241, 0.84);
  color: var(--ink);
  box-shadow: 0 1px 0 var(--hairline);
  backdrop-filter: saturate(1.4) blur(16px);
  -webkit-backdrop-filter: saturate(1.4) blur(16px);
}

/* The logo: "Tanto" over a tanto blade (assets/logo.svg). The link keeps
   its text for search and its aria-label for screen readers; the drawing
   is a mask filled with currentColor, so it can be white over the hero
   gradient and Tanto orange everywhere else. */
.wordmark {
  display: inline-flex;
  flex: none;
  font-size: 0;
  line-height: 0;
  text-decoration: none;
  color: var(--orange);
}

.wordmark::before {
  content: "";
  width: 87px;
  height: 36px;
  background: currentColor;
  -webkit-mask: url("logo.svg") center / contain no-repeat;
  mask: url("logo.svg") center / contain no-repeat;
}

/* Over the hero gradient the header is transparent and its text white. */
.site-header .wordmark {
  color: inherit;
}

.site-header.is-solid .wordmark,
.site-header.menu-open .wordmark {
  color: var(--orange);
}

.footer-brand .wordmark::before {
  width: 102px;
  height: 42px;
}

.site-nav {
  margin-left: auto;
}

.site-nav ul {
  display: flex;
  gap: 32px;
}

.site-nav a {
  position: relative;
  font-size: 15px;
  text-decoration: none;
  opacity: 0.86;
  transition: opacity 0.2s ease;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  opacity: 1;
}

.site-nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 2px;
  background: var(--orange);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn--nav {
  min-height: 38px;
  padding: 0 16px;
  font-size: 14px;
  background: var(--card);
  color: var(--ink);
}

.site-header.is-solid .btn--nav,
.site-header.menu-open .btn--nav {
  background: var(--ink);
  color: var(--canvas);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid currentColor;
  border-radius: var(--r-pill);
  background: none;
  color: inherit;
  cursor: pointer;
}

.menu-toggle__bars,
.menu-toggle__bars::before {
  display: block;
  width: 16px;
  height: 1.5px;
  margin: 0 auto;
  background: currentColor;
  transition: transform 0.3s var(--ease-out);
}

.menu-toggle__bars {
  transform: translateY(-3px);
}

.menu-toggle__bars::before {
  content: "";
  transform: translateY(6px);
}

.menu-toggle[aria-expanded="true"] .menu-toggle__bars {
  transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle__bars::before {
  transform: translateY(0) rotate(-90deg);
}

@media (max-width: 860px) {
  .js .menu-toggle {
    display: block;
  }

  .js .site-nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    padding: 8px var(--gutter) 28px;
    background: var(--canvas);
    color: var(--ink);
    box-shadow: 0 1px 0 var(--hairline), var(--shadow-2);
    visibility: hidden;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.35s var(--ease-out), visibility 0s linear 0.35s;
  }

  .js .menu-open .site-nav {
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: opacity 0.25s ease, transform 0.35s var(--ease-out);
  }

  .js .site-nav ul {
    display: grid;
    gap: 0;
  }

  .js .site-nav a {
    display: block;
    padding: 14px 0;
    border-bottom: 1px solid var(--hairline);
    font-size: 22px;
    letter-spacing: -0.02em;
    opacity: 1;
  }

  .js .site-nav a[aria-current="page"]::after {
    display: none;
  }

  .js .site-nav a[aria-current="page"] {
    color: var(--orange);
  }

  .site-header .wrap {
    gap: 16px;
  }

  .js .header-actions {
    margin-left: auto;
  }

  .site-nav ul {
    gap: 18px;
  }
}

@media (max-width: 520px) {
  .btn--nav {
    display: none;
  }
}

/* Hero: the animated gradient, cut along the bottom like a tanto blade tip.
   The left run of the edge is shallow, then it breaks to a steeper angle. */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--on-dark);
  padding: calc(var(--header-h) + clamp(64px, 9vw, 128px)) 0 calc(var(--cut) + clamp(150px, 17vw, 260px));
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - var(--cut)), 62% calc(100% - var(--cut) * 0.3), 0 100%);
}

.hero--page {
  padding-bottom: calc(var(--cut) + clamp(64px, 8vw, 112px));
}

.hero__bg {
  position: absolute;
  inset: 0 0 -20% 0;
  z-index: -1;
  /* Shown until the WebGL canvas is ready, and in place of it without WebGL. */
  background:
    radial-gradient(60% 70% at 18% 8%, rgba(246, 221, 166, 0.9) 0%, rgba(236, 176, 126, 0) 60%),
    radial-gradient(40% 60% at 88% 20%, rgba(226, 126, 87, 0.85) 0%, rgba(226, 126, 87, 0) 70%),
    linear-gradient(160deg, var(--violet) 0%, var(--sky) 38%, var(--blue) 62%, var(--blue-deep) 100%);
}

.hero__bg canvas {
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.4s ease;
}

.hero__bg canvas.is-ready {
  opacity: 1;
}

/* Legibility scrim behind the copy on the left. */
.hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(14, 20, 48, 0.5) 0%, rgba(14, 20, 48, 0.26) 42%, rgba(14, 20, 48, 0) 72%);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.hero--page .hero__grid {
  grid-template-columns: minmax(0, 1fr);
}

.hero .eyebrow {
  color: var(--on-dark-2);
}

.hero .eyebrow::before {
  background: var(--cream);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 14px 5px 5px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.12);
  color: var(--on-dark);
  font-size: 13px;
  line-height: 1.3;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.pill__tag {
  padding: 4px 9px;
  border-radius: var(--r-pill);
  background: var(--orange);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero .display {
  max-width: 11ch;
  margin-top: 28px;
}

.hero--page .display {
  max-width: 15ch;
  font-size: clamp(42px, 5.6vw, 76px);
  margin-top: 22px;
}

.hero .display em {
  color: var(--cream);
}

.hero .lede {
  max-width: 34em;
  margin-top: 26px;
  color: rgba(255, 255, 255, 0.86);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.hero__visual {
  position: relative;
  height: 540px;
}

.hero__layer {
  position: absolute;
}

.hero__layer--a {
  top: 0;
  right: 0;
  width: 90%;
}

.hero__layer--b {
  bottom: 0;
  left: -6%;
  width: 56%;
}

.hero__layer--c {
  bottom: 56px;
  right: -2%;
  width: 44%;
}

@media (max-width: 960px) {
  .hero__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero__visual {
    height: auto;
    margin-top: 16px;
  }

  .hero__layer {
    position: relative;
    inset: auto;
  }

  .hero__layer--a {
    width: 100%;
  }

  .hero__layer--b,
  .hero__layer--c {
    display: none;
  }
}

/* Hero brand video (feature/hero-video). The frame keeps a 16:9 box before
   the video loads, so nothing below it moves. It overlaps the hero's cut. */

.film {
  position: relative;
  z-index: 2;
  margin-top: calc(-1 * clamp(150px, 17vw, 260px));
}

.hero-video {
  display: grid;
  justify-items: center;
  gap: 28px;
}

.hero-video__frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--r-xl);
  background: var(--night);
  box-shadow: var(--shadow-3);
  transform-origin: 50% 0;
}

.hero-video__media {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-video__toggle {
  position: absolute;
  right: 16px;
  bottom: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--hairline-dark);
  border-radius: var(--r-pill);
  background: rgba(14, 20, 48, 0.6);
  color: var(--on-dark);
  opacity: 0.8;
  cursor: pointer;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: opacity 0.2s ease;
}

.hero-video__toggle[hidden] {
  display: none;
}

.hero-video__toggle:hover,
.hero-video__toggle:focus-visible {
  opacity: 1;
}

.hero-video__icon {
  width: 14px;
  height: 14px;
}

.hero-video__toggle .hero-video__icon--play,
.hero-video__toggle[aria-pressed="true"] .hero-video__icon--pause {
  display: none;
}

.hero-video__toggle[aria-pressed="true"] .hero-video__icon--play {
  display: block;
}

.film__caption {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px 24px;
  text-align: center;
}

.film__caption p {
  color: var(--ink-2);
  font-size: 17px;
}

/* Product mockups: small, faithful-looking UI panels that show the work. */

.mock {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: var(--r-lg);
  background: rgba(255, 255, 255, 0.97);
  color: var(--ink);
  box-shadow: var(--shadow-2);
  font-size: 14px;
  line-height: 1.45;
  font-variant-numeric: tabular-nums;
}

.mock__bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--hairline);
  font-size: 13px;
  color: var(--ink-2);
}

.mock__dots {
  display: flex;
  gap: 6px;
}

.mock__dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--hairline-strong);
}

.mock__title {
  font-weight: 500;
  color: var(--ink);
}

.mock__bar .tag {
  margin-left: auto;
}

.mock__body {
  padding: 6px 16px 14px;
}

.mock table {
  width: 100%;
  border-collapse: collapse;
}

.mock th {
  padding: 10px 0;
  border-bottom: 1px solid var(--hairline);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-align: left;
  text-transform: uppercase;
  color: var(--ink-3);
}

.mock td {
  padding: 11px 0;
  border-bottom: 1px solid var(--hairline);
}

.mock tr:last-child td {
  border-bottom: 0;
}

.mock td:nth-child(2),
.mock th:nth-child(2) {
  text-align: right;
  padding-right: 18px;
}

.mock td:last-child,
.mock th:last-child {
  text-align: right;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: var(--r-pill);
  background: var(--panel);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}

.tag::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.tag--orange {
  background: var(--orange-wash);
  color: var(--orange-hover);
}

.tag--blue {
  background: var(--blue-wash);
  color: var(--blue-deep);
}

.settings li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--hairline);
}

.settings li:last-child {
  border-bottom: 0;
}

.settings__value {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-2);
}

.switch {
  position: relative;
  flex: none;
  width: 34px;
  height: 20px;
  border-radius: var(--r-pill);
  background: var(--hairline-strong);
}

.switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--card);
  box-shadow: var(--shadow-1);
}

.switch.is-on {
  background: var(--blue);
}

.switch.is-on::after {
  transform: translateX(14px);
}

.flow {
  display: grid;
  padding: 10px 0 4px;
}

.flow li {
  position: relative;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 14px;
  padding-bottom: 18px;
}

.flow li:last-child {
  padding-bottom: 0;
}

.flow li:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 30px;
  bottom: 0;
  width: 2px;
  background: var(--hairline);
}

.flow__icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--hairline-strong);
  border-radius: 50%;
  background: var(--card);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-2);
}

.flow li.is-live .flow__icon {
  border-color: var(--orange);
  background: var(--orange);
  color: var(--on-dark);
}

.flow b {
  display: block;
  font-weight: 500;
}

.flow small {
  display: block;
  font-size: 12.5px;
  color: var(--ink-3);
}

.checklist li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--hairline);
}

.checklist li:last-child {
  border-bottom: 0;
}

.checklist__box {
  display: grid;
  place-items: center;
  flex: none;
  width: 18px;
  height: 18px;
  border: 1px solid var(--hairline-strong);
  border-radius: 5px;
}

.checklist li.is-done .checklist__box {
  border-color: var(--blue);
  background: var(--blue);
  color: var(--on-dark);
}

.checklist li.is-done span:last-child {
  color: var(--ink-3);
}

.checklist svg {
  width: 11px;
  height: 11px;
}

.meter {
  height: 6px;
  margin: 12px 0 4px;
  overflow: hidden;
  border-radius: var(--r-pill);
  background: var(--panel);
}

.meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--orange), var(--coral) 60%, var(--apricot));
}

.meter-label {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--ink-3);
}

.log li {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--hairline);
}

.log li:last-child {
  border-bottom: 0;
}

.log time {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-3);
  padding-top: 2px;
}

.log b {
  display: block;
  font-weight: 500;
}

.log small {
  display: block;
  font-size: 12.5px;
  color: var(--ink-3);
}

.badge {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
}

.badge__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--blue-wash);
  color: var(--blue);
}

.badge__icon svg {
  width: 18px;
  height: 18px;
}

.badge b {
  display: block;
  font-weight: 500;
}

.badge small {
  display: block;
  font-size: 12.5px;
  color: var(--ink-3);
}

/* A tinted surface that holds a mockup. */
.stage {
  position: relative;
  overflow: hidden;
  padding: clamp(24px, 4vw, 48px);
  border-radius: var(--r-xl);
  background:
    radial-gradient(80% 90% at 0% 0%, rgba(236, 176, 126, 0.55) 0%, rgba(236, 176, 126, 0) 60%),
    radial-gradient(70% 80% at 100% 100%, rgba(60, 115, 198, 0.4) 0%, rgba(60, 115, 198, 0) 65%),
    var(--panel);
}

.stage--blue {
  background:
    radial-gradient(80% 90% at 100% 0%, rgba(140, 116, 184, 0.45) 0%, rgba(140, 116, 184, 0) 60%),
    radial-gradient(70% 80% at 0% 100%, rgba(47, 98, 216, 0.35) 0%, rgba(47, 98, 216, 0) 65%),
    var(--panel);
}

/* Sections */

.section {
  padding: var(--section) 0;
}

.section--tight {
  padding-top: calc(var(--section) * 0.5);
}

.section--panel {
  background: var(--panel);
}

.section-intro {
  max-width: 780px;
  margin-bottom: clamp(48px, 7vw, 96px);
}

.section-intro .h2 {
  margin-top: 20px;
}

.section-intro .lede {
  margin-top: 22px;
}

.section-intro--split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 24px clamp(40px, 6vw, 96px);
  align-items: end;
  max-width: none;
}

.section-intro--split .lede {
  margin-top: 0;
}

@media (max-width: 860px) {
  .section-intro--split {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Editorial statement: large serif text that brightens word by word. */

.statement {
  padding: var(--section) 0 calc(var(--section) * 0.7);
}

.statement__text {
  max-width: 1040px;
  margin-top: 28px;
  font-family: var(--font-serif);
  font-size: clamp(30px, 3.9vw, 56px);
  font-weight: 300;
  line-height: 1.16;
  letter-spacing: -0.015em;
  text-wrap: pretty;
}

.statement__text em {
  color: var(--orange);
}

.statement__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 32px;
  margin-top: 40px;
}

/* Sticky storytelling: a pinned index on the left, panels scrolling past on the right. */

.story__grid {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: clamp(40px, 6vw, 96px);
}

.story__nav {
  position: sticky;
  top: calc(var(--header-h) + 56px);
  align-self: start;
}

.story__list {
  position: relative;
  padding-left: 22px;
}

.story__list ol {
  display: grid;
}

.story__track,
.story__progress {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--hairline);
}

.story__progress {
  background: linear-gradient(var(--orange), var(--coral) 50%, var(--blue));
  transform-origin: top;
}

.story__nav a {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 12px 0;
  color: var(--ink-3);
  font-size: 18px;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: color 0.3s ease;
}

.story__nav a:hover,
.story__nav a.is-active {
  color: var(--ink);
}

.story__nav .index {
  font-family: var(--font-mono);
  font-size: 12px;
  transition: color 0.3s ease;
}

.story__nav a.is-active .index {
  color: var(--orange);
}

.story__panels {
  display: grid;
  gap: clamp(72px, 10vw, 150px);
}

.story__panel {
  display: grid;
  gap: 28px;
  scroll-margin-top: calc(var(--header-h) + 40px);
}

.story__panel .index {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--orange);
}

.story__panel .h3 {
  margin-top: 12px;
}

.story__panel .prose {
  max-width: 36em;
  margin-top: 16px;
}

.story__panel .mock {
  max-width: 560px;
  margin-inline: auto;
}

@media (max-width: 960px) {
  .story__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .story__nav {
    display: none;
  }
}

/* Dark band */

.section--dark {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--night);
  color: var(--on-dark);
}

.section--dark::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(55% 60% at 90% 0%, rgba(47, 98, 216, 0.42) 0%, rgba(47, 98, 216, 0) 70%),
    radial-gradient(45% 55% at 0% 100%, rgba(196, 81, 26, 0.3) 0%, rgba(196, 81, 26, 0) 70%);
}

.section--dark .eyebrow {
  color: var(--on-dark-3);
}

.section--dark .lede,
.section--dark .prose p {
  color: var(--on-dark-2);
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--hairline-dark);
}

.stat {
  padding: 32px 24px 0 0;
}

.stat + .stat {
  padding-left: 24px;
  border-left: 1px solid var(--hairline-dark);
}

.stat__num {
  font-size: clamp(52px, 6.4vw, 92px);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.05em;
  font-variant-numeric: tabular-nums;
}

.stat__unit {
  margin-left: 6px;
  font-size: 0.34em;
  letter-spacing: -0.01em;
  color: var(--on-dark-2);
}

.stat__label {
  max-width: 22ch;
  margin-top: 16px;
  font-size: 15px;
  color: var(--on-dark-2);
}

@media (max-width: 860px) {
  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }

  .stat:nth-child(n + 3) {
    margin-top: 32px;
    border-top: 1px solid var(--hairline-dark);
  }
}

/* Cards */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.cards--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 760px) {
  .cards--2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

.card {
  padding: clamp(26px, 3vw, 36px);
  border: 1px solid var(--hairline);
  border-radius: var(--r-lg);
  background: var(--card);
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out), border-color 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-2);
}

.card .index {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--orange);
}

.card .h4 {
  margin-top: 18px;
}

.card p {
  margin-top: 10px;
  font-size: 16px;
  color: var(--ink-2);
}

.card .list {
  margin-top: 16px;
  font-size: 15.5px;
}

.stats + .cards {
  margin-top: clamp(64px, 8vw, 112px);
}

.card--dark {
  border-color: var(--hairline-dark);
  background: rgba(255, 255, 255, 0.04);
}

.card--dark:hover {
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: none;
}

.card--dark p {
  color: var(--on-dark-2);
}

.card--dark .index {
  color: var(--apricot);
}

/* Split: copy beside a visual */

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}

.split .h2 {
  margin-top: 20px;
}

.split .lede,
.split .prose {
  margin-top: 22px;
}

.split .text-link {
  margin-top: 28px;
}

.split .facts {
  margin-top: 36px;
}

@media (max-width: 900px) {
  .split {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Facts: short labelled values */

.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.facts > div {
  padding: 24px;
  border: 1px solid var(--hairline);
  border-radius: var(--r-lg);
  background: var(--card);
}

.facts dt {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.facts dd {
  margin-top: 10px;
  font-size: 18px;
  line-height: 1.4;
  letter-spacing: -0.01em;
}

/* Detail rows (services) */

.details {
  display: grid;
  gap: 20px;
}

.detail {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 24px clamp(32px, 5vw, 80px);
  padding: clamp(28px, 5vw, 64px);
  border: 1px solid var(--hairline);
  border-radius: var(--r-xl);
  background: var(--card);
  scroll-margin-top: calc(var(--header-h) + 24px);
}

.detail .index {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--orange);
}

.detail .h3 {
  margin-top: 14px;
}

.detail__get {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
}

.detail__get .eyebrow {
  margin-bottom: 14px;
}

@media (max-width: 860px) {
  .detail {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Timeline (approach): a rule that fills as you scroll. */

.timeline {
  position: relative;
  max-width: 880px;
  padding-left: 72px;
}

.timeline__track {
  position: absolute;
  left: 19px;
  top: 20px;
  bottom: 20px;
  width: 2px;
  background: var(--hairline);
}

.timeline__fill {
  position: absolute;
  inset: 0;
  background: linear-gradient(var(--orange), var(--coral) 45%, var(--blue));
  transform-origin: top;
}

.timeline__item {
  position: relative;
  padding-bottom: clamp(40px, 5vw, 64px);
}

.timeline__item:last-child {
  padding-bottom: 0;
}

.timeline__node {
  position: absolute;
  left: -72px;
  top: 0;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--hairline-strong);
  border-radius: 50%;
  background: var(--canvas);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-2);
  transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease;
}

.timeline__item.is-active .timeline__node {
  border-color: var(--orange);
  background: var(--orange);
  color: var(--on-dark);
}

.timeline__item .h3 {
  padding-top: 4px;
}

.timeline__item .prose {
  margin-top: 14px;
  max-width: 38em;
}

.timeline__item .list {
  margin-top: 14px;
}

@media (max-width: 600px) {
  .timeline {
    padding-left: 56px;
  }

  .timeline__node {
    left: -56px;
    width: 36px;
    height: 36px;
  }

  .timeline__track {
    left: 17px;
  }
}

/* Closing band: the gradient again, cut on its top edge (the hero cut turned around). */

.cta-band {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--on-dark);
  padding: calc(var(--cut) + clamp(72px, 9vw, 128px)) 0 clamp(96px, 11vw, 160px);
  clip-path: polygon(0 var(--cut), 38% calc(var(--cut) * 0.3), 100% 0, 100% 100%, 0 100%);
}

.cta-band .hero__bg {
  inset: 0;
}

.cta-band .hero__bg::after {
  background: linear-gradient(90deg, rgba(14, 20, 48, 0.46) 0%, rgba(14, 20, 48, 0.18) 55%, rgba(14, 20, 48, 0) 80%);
}

.cta-band .eyebrow {
  color: var(--on-dark-2);
}

.cta-band .eyebrow::before {
  background: var(--cream);
}

.cta-band .h2 {
  max-width: 14ch;
  margin-top: 20px;
}

.cta-band .lede {
  max-width: 34em;
  margin-top: 22px;
  color: rgba(255, 255, 255, 0.86);
}

.cta-band .hero__actions {
  margin-top: 36px;
}

/* Contact */

.contact-card {
  display: grid;
  gap: 18px;
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--r-xl);
  background: var(--night);
  color: var(--on-dark);
}

.contact-card .eyebrow {
  color: var(--on-dark-3);
}

.contact-card a.contact-card__email {
  font-size: clamp(28px, 3.4vw, 44px);
  font-weight: 300;
  letter-spacing: -0.03em;
  text-decoration: none;
}

.contact-card a.contact-card__email:hover {
  color: var(--apricot);
}

.contact-card p {
  color: var(--on-dark-2);
}

/* Inquiry form */

.split--start {
  align-items: start;
}

.inquiry-note {
  margin-top: 22px;
  max-width: 46ch;
  font-size: 15.5px;
  color: var(--ink-3);
}

.form-card {
  padding: clamp(24px, 3.4vw, 40px);
  border: 1px solid var(--hairline);
  border-radius: var(--r-xl);
  background: var(--card);
  box-shadow: var(--shadow-1);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px 18px;
}

.field {
  display: grid;
  gap: 8px;
  align-content: start;
}

.field--wide {
  grid-column: 1 / -1;
}

/* Paired optional fields with labels of different lengths: line up the boxes. */
.field--end {
  align-content: end;
}

.field label {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink);
}

.field__optional {
  font-weight: 400;
  color: var(--ink-3);
}

.field__hint {
  margin-top: -2px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--ink-3);
}

.field__input {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--hairline-strong);
  border-radius: var(--r-sm);
  background: var(--card);
  color: var(--ink);
  font: 400 16px/1.4 var(--font-sans);
  transition: border-color 0.2s ease;
}

textarea.field__input {
  min-height: 150px;
  resize: vertical;
}

.field__input:hover {
  border-color: var(--ink-3);
}

.field__input:focus {
  border-color: var(--ink);
}

.field__input[aria-invalid="true"] {
  border-color: var(--orange-hover);
}

.field__select {
  position: relative;
}

.field__select select {
  appearance: none;
  padding-right: 40px;
  cursor: pointer;
}

.field__select::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 16px;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid var(--ink-2);
  border-bottom: 1.5px solid var(--ink-2);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.field__error {
  font-size: 14px;
  font-weight: 500;
  color: var(--orange-hover);
}

.field--check {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  column-gap: 12px;
}

.field--check input {
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  accent-color: var(--orange);
}

.field--check label {
  font-weight: 400;
  color: var(--ink-2);
}

.field--check .field__error {
  grid-column: 2;
}

.field--trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 20px;
  margin-top: 30px;
}

.form-actions .btn[disabled] {
  opacity: 0.6;
  cursor: progress;
}

.form-status {
  flex: 1 1 220px;
  font-size: 15px;
  color: var(--ink-2);
}

.form-status a {
  color: var(--blue);
}

.form-success .h3 {
  margin-top: 16px;
}

.form-success p:last-child {
  margin-top: 12px;
  color: var(--ink-2);
}

.form-success:focus {
  outline: none;
}

@media (max-width: 600px) {
  .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .form-actions .btn {
    width: 100%;
  }
}

/* Footer */

.site-footer {
  padding: clamp(64px, 8vw, 96px) 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
  gap: 40px;
}

.footer-brand p {
  max-width: 26ch;
  margin-top: 16px;
  font-size: 15px;
  color: var(--ink-3);
}

.footer-col h2 {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.footer-col ul {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.footer-col a,
.footer-col li {
  font-size: 15px;
  color: var(--ink-2);
  text-decoration: none;
}

.footer-col a:hover {
  color: var(--ink);
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
  margin-top: clamp(48px, 7vw, 80px);
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
  font-size: 13px;
  color: var(--ink-3);
}

@media (max-width: 860px) {
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

/* Motion.
   The inline script in each page's <head> adds .motion unless the viewer
   prefers reduced motion. motion.js reveals these elements; if it never runs,
   the head script removes .motion after three seconds so nothing stays hidden. */

.motion [data-split],
.motion [data-reveal],
.motion [data-stagger] > * {
  visibility: hidden;
}

/* SplitText line masks: a little room below each line so descenders are not clipped. */
.split-line-mask {
  padding-bottom: 0.08em;
  margin-bottom: -0.08em;
}

[data-parallax],
[data-film] {
  will-change: transform;
}

@media (prefers-reduced-motion: no-preference) {
  @view-transition {
    navigation: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
