/* Animbench landing — dark editorial theme (concept A) */

:root {
  --bg: #0A0C0F;
  --surface: #0E1115;
  --line: #1C2229;
  --line-soft: #161B21;
  --text: #E9EEF2;
  --text-2: #B4BDC7;
  --muted: #8C97A4;
  --dim: #7A8592;
  --accent: #3ED0E8;
  --accent-2: #F2A33A;
  --on-accent: #061317;

  --font-display: "Unbounded", "Arial Black", sans-serif;
  --font-body: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 1280px;
  --gutter: clamp(20px, 4vw, 48px);
  --radius: 16px;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--text); }
a:hover { color: var(--accent); }

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

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.skip {
  position: absolute;
  left: -9999px;
  top: 8px;
  padding: 8px 14px;
  background: var(--accent);
  color: var(--on-accent);
  border-radius: 8px;
  z-index: 10;
}
.skip:focus { left: 8px; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, background-color 0.3s;
}
.site-header.is-scrolled {
  background: rgba(10, 12, 15, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--line-soft);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 16px;
  padding-bottom: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 8px; }
.brand span {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  letter-spacing: 0.02em;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 28px;
  font-size: 15px;
}
.nav a { text-decoration: none; }

.lang {
  display: flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid #262C33;
  border-radius: 999px;
}
.lang a, .lang span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  min-width: 44px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}
.lang span { background: #1A2027; color: var(--text); }
.lang a { color: var(--muted); }
.lang a:hover { color: var(--text); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  transition: transform 0.15s, background-color 0.15s, border-color 0.15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: #6BDDF0; color: var(--on-accent); }
.btn-ghost { border: 1px solid #2A313A; color: var(--text); font-weight: 500; }
.btn-ghost:hover { border-color: var(--accent); color: var(--text); }
.btn-lg { min-height: 56px; padding: 0 32px; font-size: 17px; }
.nav .btn { min-height: 44px; padding: 0 20px; }

/* ---------- Hero ---------- */

.hero {
  padding-top: clamp(48px, 8vw, 120px);
  padding-bottom: 56px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.eyebrow {
  margin: 0;
  font-size: 14px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero h1 {
  margin: 0;
  max-width: 13ch;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(42px, 7.2vw, 112px);
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.hero-row {
  display: flex;
  flex-wrap: wrap;
  gap: 32px 40px;
  align-items: flex-end;
  justify-content: space-between;
}

.lead {
  margin: 0;
  max-width: 54ch;
  font-size: clamp(17px, 1.4vw, 20px);
  line-height: 1.55;
  color: var(--text-2);
  text-wrap: pretty;
}

.actions { display: flex; flex-wrap: wrap; gap: 12px; }

.showreel {
  position: relative;
  margin: 0 auto;
}

.clip-toggle {
  position: absolute;
  right: 16px;
  bottom: 16px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid rgba(233, 238, 242, 0.18);
  border-radius: 999px;
  background: rgba(10, 12, 15, 0.7);
  backdrop-filter: blur(8px);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.clip-toggle:hover { border-color: var(--accent); }
.showreel video {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--surface);
  border-radius: 20px;
  border: 1px solid #1E242B;
}

/* ---------- Section headings ---------- */

.section { padding-top: clamp(96px, 12vw, 180px); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px 24px;
  margin-bottom: clamp(40px, 5vw, 64px);
}
.section-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(32px, 4vw, 56px);
  line-height: 1.05;
}
.section-head p {
  margin: 0;
  max-width: 44ch;
  color: var(--muted);
}

/* ---------- Demos ---------- */

.demos {
  display: flex;
  flex-direction: column;
  gap: clamp(64px, 8vw, 120px);
}

.demo {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
}
.demo:nth-child(even) { flex-direction: row-reverse; }

.demo-media { flex: 1 1 520px; min-width: 0; }
.demo-text {
  flex: 1 1 340px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.demo-num {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--accent-2);
}
.demo-text h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(26px, 3vw, 40px);
  line-height: 1.12;
  text-wrap: balance;
}
.demo-text p {
  margin: 0;
  max-width: 42ch;
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-2);
}
.demo-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
}
.demo-tags li {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--muted);
}

/* Media frame: holds a looping clip, or a placeholder until it is recorded */
.clip {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  border: 1px solid #1E242B;
  background: var(--surface);
  overflow: hidden;
}
.clip video, .clip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.clip-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  text-align: center;
  color: var(--dim);
  font-size: 14px;
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 40px 40px;
}
.clip-placeholder svg { width: 40px; height: 40px; color: var(--accent); }

/* ---------- Feature groups ---------- */

.groups {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.group {
  background: var(--bg);
  padding: clamp(24px, 3vw, 36px);
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: background-color 0.2s;
}
.group:hover { background: var(--surface); }
.group h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 600;
}
.group p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
}
.group .note { color: var(--accent-2); font-size: 14px; opacity: 0.85; }

/* ---------- Specs ---------- */

.specs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: 1px;
  margin: 0;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.spec {
  background: var(--surface);
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.spec dt {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.spec dd {
  margin: 0;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 500;
}

/* ---------- CTA ---------- */

.cta {
  padding-top: clamp(120px, 14vw, 200px);
  padding-bottom: clamp(96px, 12vw, 160px);
}
.cta-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 28px;
  padding-top: 64px;
  border-top: 1px solid var(--line);
}
.cta h2 {
  margin: 0;
  max-width: 16ch;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.05;
  text-wrap: balance;
}
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.cta-meta { color: var(--muted); font-size: 15px; }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line-soft); }
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  padding-top: 32px;
  padding-bottom: 48px;
  font-size: 14px;
  color: var(--dim);
}
.site-footer nav { display: flex; gap: 24px; }
.site-footer a { color: var(--dim); }
.site-footer a:hover { color: var(--text); }

/* ---------- Reveal on scroll ---------- */

/* Hidden states apply only when JS is running (html.js), so the page reads fine without it */
.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Motion ---------- */

:root { --ease: cubic-bezier(0.2, 0.7, 0.2, 1); }

/* Ambient glow behind the hero, slowly drifting */
main { position: relative; }
main > :not(.ambient) { position: relative; z-index: 1; }
.ambient {
  position: absolute;
  inset: 0 0 auto 0;
  height: 1200px;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.ambient::before, .ambient::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(30px);
}
.ambient::before {
  width: 900px; height: 900px;
  left: 52%; top: -340px;
  background: radial-gradient(closest-side, rgba(62, 208, 232, 0.16), transparent 72%);
  animation: drift-a 18s ease-in-out infinite alternate;
}
.ambient::after {
  width: 760px; height: 760px;
  left: -8%; top: 180px;
  background: radial-gradient(closest-side, rgba(242, 163, 58, 0.08), transparent 72%);
  animation: drift-b 24s ease-in-out infinite alternate;
}
@keyframes drift-a { to { transform: translate(-140px, 90px) scale(1.15); } }
@keyframes drift-b { to { transform: translate(160px, -60px) scale(0.9); } }

/* Film grain over everything, very faint */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 50;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Header slides away on scroll down, returns on scroll up */
.site-header { transition: transform 0.35s var(--ease), border-color 0.2s; }
.site-header.is-hidden { transform: translateY(-100%); }

/* Hero intro: headline words rise one by one, the rest fades up after */
.word {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  padding-bottom: 0.1em;
  margin-bottom: -0.1em;
}
.word > span { display: inline-block; }
.js [data-split]:not(.is-split) { opacity: 0; }

.js .hero h1 .word > span {
  animation: word-up 1.1s var(--ease) both;
  animation-delay: calc(0.15s + var(--i) * 0.08s);
}
.js .hero .eyebrow { animation: rise 0.9s var(--ease) 0.05s both; }
.js .hero .lead { animation: rise 0.9s var(--ease) 0.55s both; }
.js .hero .actions { animation: rise 0.9s var(--ease) 0.7s both; }

@keyframes word-up { from { transform: translateY(110%); } to { transform: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* CTA headline reveals word by word when scrolled into view */
.js .cta .word > span {
  transform: translateY(110%);
  transition: transform 1s var(--ease);
  transition-delay: calc(var(--i) * 0.07s);
}
.js .cta-inner.is-visible .word > span { transform: none; }

/* Showreel grows to full size as it scrolls in (scale set from JS) */

/* Demos: media scales in, text lines and tags follow in sequence */
.js .demo.reveal { opacity: 1; transform: none; }
.js .demo .demo-media {
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.9s var(--ease), transform 1.1s var(--ease);
}
.js .demo .demo-text > * {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.js .demo .demo-tags li {
  opacity: 0;
  transform: translateY(8px) scale(0.96);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.js .demo.is-visible .demo-media,
.js .demo.is-visible .demo-text > *,
.js .demo.is-visible .demo-tags li { opacity: 1; transform: none; }
.js .demo.is-visible .demo-text > :nth-child(2) { transition-delay: 0.1s; }
.js .demo.is-visible .demo-text > :nth-child(3) { transition-delay: 0.2s; }
.js .demo.is-visible .demo-text > :nth-child(4) { transition-delay: 0.3s; }
.js .demo.is-visible .demo-tags li:nth-child(1) { transition-delay: 0.4s; }
.js .demo.is-visible .demo-tags li:nth-child(2) { transition-delay: 0.46s; }
.js .demo.is-visible .demo-tags li:nth-child(3) { transition-delay: 0.52s; }
.js .demo.is-visible .demo-tags li:nth-child(4) { transition-delay: 0.58s; }
.js .demo.is-visible .demo-tags li:nth-child(5) { transition-delay: 0.64s; }

/* Placeholders feel alive: the grid drifts, the play mark breathes */
.clip-placeholder { animation: grid-pan 24s linear infinite; }
.clip-placeholder svg { animation: breathe 2.6s ease-in-out infinite; }
@keyframes grid-pan { to { background-position: 40px 40px, 40px 40px; } }
@keyframes breathe { 50% { transform: scale(1.12); opacity: 0.7; } }

/* Endless strip of tool names */
.marquee {
  margin-top: clamp(96px, 12vw, 180px);
  padding: 24px 0;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 70s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee span {
  display: flex;
  align-items: center;
  gap: 40px;
  padding-right: 40px;
  font-family: var(--font-display);
  font-size: clamp(20px, 2.2vw, 30px);
  white-space: nowrap;
  color: #4A5561;
  transition: color 0.2s;
}
.marquee span:hover { color: var(--accent); }
.marquee span::after {
  content: "";
  width: 8px;
  height: 8px;
  background: var(--accent-2);
  opacity: 0.7;
  transform: rotate(45deg);
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* Feature groups: staggered entrance and a soft spotlight under the cursor */
.js .groups.reveal { opacity: 1; transform: none; }
.js .groups .group {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease), background-color 0.2s;
}
.js .groups.is-visible .group { opacity: 1; transform: none; }
.js .groups.is-visible .group:nth-child(2) { transition-delay: 0.06s; }
.js .groups.is-visible .group:nth-child(3) { transition-delay: 0.12s; }
.js .groups.is-visible .group:nth-child(4) { transition-delay: 0.18s; }
.js .groups.is-visible .group:nth-child(5) { transition-delay: 0.24s; }
.js .groups.is-visible .group:nth-child(6) { transition-delay: 0.3s; }
.js .groups.is-visible .group:nth-child(7) { transition-delay: 0.36s; }

.group { position: relative; }
.group > * { position: relative; }
.group::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(62, 208, 232, 0.09), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}
.group:hover::before { opacity: 1; }

/* Primary buttons: a light sweep on hover */
.btn-primary { position: relative; overflow: hidden; }
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.5) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.7s var(--ease);
}
.btn-primary:hover::after { transform: translateX(120%); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal, .js .demo .demo-media, .js .demo .demo-text > *, .js .demo .demo-tags li,
  .js .groups .group { opacity: 1; transform: none; transition: none; }
  .js .hero h1 .word > span, .js .hero .eyebrow, .js .hero .lead, .js .hero .actions { animation: none; }
  .js .cta .word > span { transform: none; transition: none; }
  .ambient::before, .ambient::after, .clip-placeholder, .clip-placeholder svg,
  .marquee-track { animation: none; }
  .site-header.is-hidden { transform: none; }
  .btn:hover { transform: none; }
  .btn-primary::after { display: none; }
}

/* ---------- Small screens ---------- */

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

@media (max-width: 720px) {
  .nav { gap: 8px 18px; }
  .demo:nth-child(even) { flex-direction: row; }
  .showreel video { border-radius: 14px; }
}

@media (max-width: 480px) {
  .nav .btn { display: none; }
  .site-header .wrap { padding-top: 12px; padding-bottom: 12px; }
}

/* Warm accent on the last headline word */
.hero h1 .word:last-of-type > span { color: var(--accent-2); }

/* ---------- Full-screen video stage ----------
   The stage is taller than the screen; its inner layer sticks while you scroll.
   JS writes --p (0 → 1) as you scroll through it: the copy drifts up and fades,
   the video shrinks from full-bleed into a rounded card and dims, then the
   stage ends and the rest of the page follows. */

:root { --header-h: 76px; }

.hero-stage {
  --p: 0;
  position: relative;
  height: 210vh;
  margin-top: calc(var(--header-h) * -1);
}
.hero-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}

.hero-media {
  position: absolute;
  inset: 0;
  clip-path: inset(calc(var(--p) * 9vh) calc(var(--p) * 6vw) round calc(var(--p) * 28px));
  will-change: clip-path;
}
.hero-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(calc(1.08 - var(--p) * 0.08));
  filter: brightness(calc(0.92 - var(--p) * 0.35));
  will-change: transform;
}
.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(10, 12, 15, 0.95) 0%, rgba(10, 12, 15, 0.72) 30%, rgba(10, 12, 15, 0) 62%),
    linear-gradient(to bottom, rgba(10, 12, 15, 0.7) 0%, rgba(10, 12, 15, 0) 22%),
    linear-gradient(to right, rgba(10, 12, 15, 0.45) 0%, rgba(10, 12, 15, 0) 55%);
  opacity: calc(1 - var(--p) * 0.6);
}

.hero-stage .hero {
  position: relative;
  z-index: 2;
  width: 100%;
  padding-top: 0;
  padding-bottom: clamp(40px, 9vh, 110px);
  gap: 24px;
  opacity: calc(1 - var(--p) * 2.4);
  transform: translateY(calc(var(--p) * -90px));
}
.hero-stage .hero h1 { max-width: 14ch; text-shadow: 0 2px 30px rgba(0, 0, 0, 0.35); }
.hero-stage .eyebrow { color: #B4BDC7; }
.hero-stage .lead { color: #CDD5DD; }

.hero-stage .clip-toggle {
  top: calc(var(--header-h) + 16px);
  right: var(--gutter);
  bottom: auto;
  z-index: 3;
  opacity: calc(1 - var(--p) * 2);
}

@media (max-width: 720px) {
  :root { --header-h: 71px; }
  .hero-stage { height: 170vh; }
  .hero-media { clip-path: inset(calc(var(--p) * 7vh) calc(var(--p) * 4vw) round calc(var(--p) * 20px)); }
  .hero-shade {
    background:
      linear-gradient(to top, rgba(10, 12, 15, 0.97) 0%, rgba(10, 12, 15, 0.8) 45%, rgba(10, 12, 15, 0) 75%),
      linear-gradient(to bottom, rgba(10, 12, 15, 0.7) 0%, rgba(10, 12, 15, 0) 22%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-stage { height: auto; }
  .hero-sticky { position: relative; min-height: 100vh; min-height: 100svh; }
  .hero-media, .hero-media video, .hero-shade, .hero-stage .hero, .hero-stage .clip-toggle {
    clip-path: none; transform: none; opacity: 1;
  }
}

/* ---------- Tools page ---------- */

.site-header.is-solid {
  background: rgba(10, 12, 15, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.nav a[aria-current="page"] { color: var(--accent); }

.section-head .btn { flex: none; }

.tools-hero {
  padding-top: clamp(56px, 8vw, 112px);
  padding-bottom: clamp(32px, 4vw, 56px);
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.tools-hero h1 {
  margin: 0;
  max-width: 16ch;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(38px, 6vw, 88px);
  line-height: 1.04;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.js .tools-hero h1 .word > span {
  animation: word-up 1.1s var(--ease) both;
  animation-delay: calc(0.1s + var(--i) * 0.07s);
}
.js .tools-hero .lead, .js .tools-hero .tool-chips { animation: rise 0.9s var(--ease) 0.45s both; }

.tool-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
}
.tool-chips a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 14px;
  color: var(--text-2);
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s;
}
.tool-chips a:hover { border-color: var(--accent); color: var(--text); }

.tools-list { padding-bottom: clamp(96px, 12vw, 160px); }

.tool-group { padding-top: clamp(56px, 7vw, 96px); scroll-margin-top: 80px; }
.tool-group h2 {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 28px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(24px, 2.6vw, 34px);
}
.tool-group h2 span { font-size: 15px; color: var(--accent-2); }

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(360px, 100%), 1fr));
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.tool {
  position: relative;
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 24px;
  background: var(--bg);
  transition: background-color 0.2s;
}
.tool:hover { background: var(--surface); }
.tool-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 14px;
  background: #12171D;
  border: 1px solid #1E252D;
  transition: transform 0.3s var(--ease), border-color 0.3s;
}
.tool:hover .tool-icon { transform: translateY(-2px) scale(1.05); border-color: #2C3640; }
.tool-icon img { width: 40px; height: 40px; }
.tool-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.tool-body h3 { margin: 0; font-size: 17px; font-weight: 600; }
.tool-body p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--muted); }
.tool-body .tool-note { font-size: 13px; color: var(--accent-2); opacity: 0.85; }
.tool-badge {
  align-self: flex-start;
  padding: 3px 10px;
  border: 1px solid rgba(242, 163, 58, 0.45);
  border-radius: 999px;
  font-size: 12px;
  color: var(--accent-2);
}

/* Cards in a group arrive in a quick wave */
.js .tool-group.reveal { opacity: 1; transform: none; }
.js .tool-group .tool {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease), background-color 0.2s;
}
.js .tool-group.is-visible .tool { opacity: 1; transform: none; }
.js .tool-group.is-visible .tool:nth-child(2) { transition-delay: 0.05s; }
.js .tool-group.is-visible .tool:nth-child(3) { transition-delay: 0.1s; }
.js .tool-group.is-visible .tool:nth-child(4) { transition-delay: 0.15s; }
.js .tool-group.is-visible .tool:nth-child(5) { transition-delay: 0.2s; }
.js .tool-group.is-visible .tool:nth-child(6) { transition-delay: 0.25s; }
.js .tool-group.is-visible .tool:nth-child(7) { transition-delay: 0.3s; }
.js .tool-group.is-visible .tool:nth-child(8) { transition-delay: 0.35s; }
.js .tool-group.is-visible .tool:nth-child(9) { transition-delay: 0.4s; }

@media (prefers-reduced-motion: reduce) {
  .js .tool-group .tool { opacity: 1; transform: none; transition: none; }
  .js .tools-hero h1 .word > span, .js .tools-hero .lead, .js .tools-hero .tool-chips { animation: none; }
  .tool:hover .tool-icon { transform: none; }
}
