/* ==========================================================================
   Rehobot — site styles
   Ink + brass identity (shared with LegalFlow). Motion follows
   emil-design-eng: custom ease-out curves, transform/opacity only,
   hover gated to fine pointers, reduced-motion = opacity only.
   ========================================================================== */

:root {
  --ink: #0a1220;
  --ink-2: #111b2d;
  --ink-3: #1a2740;
  --paper: #f6f3ee;
  --paper-2: #ece7df;
  --white: #ffffff;
  --brass: #b8956c;
  --brass-light: #e2c9a0;
  --brass-dark: #8a6d48;
  --text: #0a1220;
  --muted: #5d6878;
  --muted-on-dark: rgba(255, 255, 255, 0.64);
  --line: rgba(10, 18, 32, 0.12);
  --line-on-dark: rgba(255, 255, 255, 0.12);

  --font-sans: "Outfit", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --font-display: "Fraunces", Georgia, serif;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

  --gutter: clamp(1rem, 4vw, 2.5rem);
  --max: 1200px;
  --header-h: 72px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: var(--header-h);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

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

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

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

.container {
  width: 100%;
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

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

/* --------------------------------------------------------------------------
   Type
   -------------------------------------------------------------------------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brass-dark);
}

.eyebrow__num {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

.eyebrow__num::after {
  content: "";
  display: inline-block;
  width: 1.5rem;
  height: 1px;
  margin-left: 0.75rem;
  vertical-align: middle;
  background: currentColor;
  opacity: 0.5;
}

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

.on-dark .eyebrow__num {
  color: var(--muted-on-dark);
}

.display {
  font-family: var(--font-display);
  font-weight: 500;
  font-optical-sizing: auto;
  letter-spacing: -0.02em;
  line-height: 1.08;
  text-wrap: balance;
}

.display em {
  font-style: italic;
  font-weight: 400;
  color: var(--brass-dark);
}

.on-dark .display em {
  color: var(--brass-light);
}

.h2 {
  font-size: clamp(2rem, 4.4vw, 3.5rem);
}

.lead {
  font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
  line-height: 1.65;
  color: var(--muted);
  text-wrap: pretty;
}

.on-dark .lead {
  color: var(--muted-on-dark);
}

/* --------------------------------------------------------------------------
   Buttons & links
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0 1.4rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font: 500 0.975rem/1 var(--font-sans);
  cursor: pointer;
  user-select: none;
  transition:
    transform 160ms var(--ease-out),
    background-color 200ms ease,
    border-color 200ms ease,
    color 200ms ease;
}

.btn:active {
  transform: scale(0.97);
}

.btn svg {
  width: 1rem;
  height: 1rem;
  transition: transform 200ms var(--ease-out);
}

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

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

.btn--ghost {
  border-color: var(--line);
  color: var(--text);
}

.on-dark .btn--ghost {
  border-color: rgba(255, 255, 255, 0.24);
  color: var(--white);
}

@media (hover: hover) and (pointer: fine) {
  .btn--brass:hover {
    background: var(--brass-light);
  }
  .btn--ink:hover {
    background: var(--ink-3);
  }
  .btn--ghost:hover {
    border-color: var(--text);
  }
  .on-dark .btn--ghost:hover {
    border-color: rgba(255, 255, 255, 0.6);
  }
  .btn:hover svg {
    transform: translate(2px, -2px);
  }
}

/* Underline that wipes in from the left and out to the right */
.link-line {
  position: relative;
  display: inline-block;
}

.link-line::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 300ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .link-line:hover::after {
    transform: scaleX(1);
    transform-origin: left;
  }
}

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

.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  color: var(--white);
  transition:
    background-color 240ms ease,
    color 240ms ease,
    box-shadow 240ms ease;
}

.header.is-solid {
  color: var(--text);
  background: rgba(246, 243, 238, 0.94);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  box-shadow: 0 1px 0 var(--line);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.brand img {
  width: 34px;
  height: 34px;
  filter: invert(1);
  transition: filter 240ms ease;
}

.header.is-solid .brand img {
  filter: none;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav__links {
  display: flex;
  gap: 1.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.95rem;
}

.nav__links a {
  opacity: 0.72;
  transition: opacity 200ms ease;
}

.nav__links a[aria-current="true"] {
  opacity: 1;
}

@media (hover: hover) and (pointer: fine) {
  .nav__links a:hover {
    opacity: 1;
  }
}

.header .btn--ghost {
  min-height: 40px;
  padding: 0 1.1rem;
  border-color: rgba(255, 255, 255, 0.28);
  color: inherit;
}

.header.is-solid .btn--ghost {
  border-color: var(--line);
}

.menu-toggle {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}

.menu-toggle span,
.menu-toggle span::before {
  position: absolute;
  left: 12px;
  width: 20px;
  height: 1.5px;
  background: currentColor;
  transition: transform 240ms var(--ease-out);
}

.menu-toggle span {
  top: 18px;
}

.menu-toggle span::before {
  content: "";
  left: 0;
  top: 7px;
}

.menu-open .menu-toggle span {
  transform: translateY(3.5px) rotate(45deg);
}

.menu-open .menu-toggle span::before {
  transform: translateY(-7px) rotate(-90deg);
}

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

  .nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 1.5rem;
    padding: 1.5rem var(--gutter) calc(2rem + env(safe-area-inset-bottom));
    background: var(--paper);
    color: var(--text);
    box-shadow: 0 1px 0 var(--line), 0 24px 48px -24px rgba(10, 18, 32, 0.25);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition:
      opacity 200ms var(--ease-out),
      transform 200ms var(--ease-out),
      visibility 0s linear 200ms;
  }

  .menu-open .nav {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition:
      opacity 240ms var(--ease-out),
      transform 240ms var(--ease-out),
      visibility 0s;
  }

  .menu-open .header {
    color: var(--text);
    background: var(--paper);
  }

  .menu-open .header .brand img {
    filter: none;
  }

  .nav__links {
    flex-direction: column;
    gap: 0;
    font-family: var(--font-display);
    font-size: 1.5rem;
  }

  .nav__links a {
    display: block;
    padding: 0.6rem 0;
    opacity: 1;
    border-bottom: 1px solid var(--line);
  }

  .nav .btn--ghost {
    min-height: 48px;
    border-color: var(--line);
  }
}

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

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(var(--header-h) + 3rem) 0 5rem;
  overflow: hidden;
  background:
    radial-gradient(ellipse 60% 55% at 12% 0%, rgba(184, 149, 108, 0.16), transparent 60%),
    radial-gradient(ellipse 50% 60% at 100% 100%, rgba(26, 51, 82, 0.55), transparent 60%),
    var(--ink);
  color: var(--white);
}

.hero__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--line-on-dark) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-on-dark) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 70% 70% at 70% 50%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 70% 50%, #000 0%, transparent 75%);
  opacity: 0.35;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.hero__title {
  margin-top: 1.5rem;
  font-size: clamp(2.6rem, 8vw, 6rem);
  line-height: 1.02;
}

/* Masked line reveal: each line slides up from behind its own edge */
.line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.08em;
  margin-bottom: -0.08em;
}

.line__inner {
  display: block;
}

.hero__lead {
  max-width: 34rem;
  margin-top: 1.75rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.5rem;
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 3.5rem 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.875rem;
  color: var(--muted-on-dark);
}

.hero__meta li {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.hero__meta li::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--brass);
}

.hero__circuit {
  position: absolute;
  right: max(-4vw, -60px);
  top: 50%;
  width: min(46vw, 620px);
  transform: translateY(-50%);
  color: var(--brass);
  pointer-events: none;
}

.hero__circuit .trace {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  opacity: 0.55;
}

.hero__circuit .node {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

.hero__circuit .block {
  fill: currentColor;
  opacity: 0.12;
}

.hero__circuit .letter {
  fill: none;
  stroke: rgba(255, 255, 255, 0.18);
  stroke-width: 1.5;
}

@media (max-width: 860px) {
  .hero__circuit {
    right: -38vw;
    top: 2%;
    width: 84vw;
    transform: none;
    opacity: 0.22;
  }
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 1.75rem;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-left: -22px;
  border: 1px solid var(--line-on-dark);
  border-radius: 50%;
  color: var(--muted-on-dark);
  transition: color 200ms ease, border-color 200ms ease;
}

.scroll-cue svg {
  width: 16px;
  height: 16px;
}

@media (hover: hover) and (pointer: fine) {
  .scroll-cue:hover {
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.4);
  }
}

@media (max-height: 700px) {
  .scroll-cue {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.section {
  padding: clamp(5rem, 11vw, 9rem) 0;
}

.section--alt {
  background: var(--paper-2);
}

.section--dark {
  background: var(--ink);
  color: var(--white);
}

.section-head {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 1.5rem 4rem;
  align-items: end;
  margin-bottom: clamp(3rem, 6vw, 5rem);
}

.section-head .eyebrow {
  grid-column: 1 / -1;
}

@media (max-width: 860px) {
  .section-head {
    grid-template-columns: 1fr;
  }
}

/* Process */

.process {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.process__item {
  padding: 2rem 1.75rem 0 0;
}

.process__num {
  font-family: var(--font-display);
  font-size: 2.75rem;
  font-weight: 400;
  line-height: 1;
  color: var(--brass);
}

.process__item h3 {
  margin-top: 1.5rem;
  font-size: 1.2rem;
  font-weight: 600;
}

.process__item p {
  margin-top: 0.6rem;
  font-size: 0.975rem;
  color: var(--muted);
  text-wrap: pretty;
}

@media (max-width: 960px) {
  .process {
    grid-template-columns: repeat(2, 1fr);
    row-gap: 2.5rem;
  }
}

@media (max-width: 560px) {
  .process {
    grid-template-columns: 1fr;
  }
}

/* Services */

.services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
}

.service {
  padding: clamp(1.75rem, 3vw, 2.5rem);
  background: var(--paper-2);
  transition: background-color 200ms ease;
}

.service__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--brass-light);
  transition: transform 300ms var(--ease-out);
}

.service__icon svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.service h3 {
  margin-top: 1.5rem;
  font-size: 1.2rem;
  font-weight: 600;
}

.service p {
  margin-top: 0.6rem;
  font-size: 0.975rem;
  color: var(--muted);
  text-wrap: pretty;
}

@media (hover: hover) and (pointer: fine) {
  .service:hover {
    background: var(--paper);
  }
  .service:hover .service__icon {
    transform: translateY(-3px);
  }
}

@media (max-width: 960px) {
  .services {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .services {
    grid-template-columns: 1fr;
  }
}

/* --------------------------------------------------------------------------
   Projects
   -------------------------------------------------------------------------- */

.project {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.project__tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.8rem;
  border: 1px solid var(--line-on-dark);
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--muted-on-dark);
}

.project__tag i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #34c08a;
  box-shadow: 0 0 0 3px rgba(52, 192, 138, 0.2);
}

.project__title {
  margin-top: 1.5rem;
  font-size: clamp(2.4rem, 5vw, 4rem);
}

.project__lead {
  margin-top: 1.25rem;
}

.project__features {
  display: grid;
  gap: 0.9rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.project__features li {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 0.75rem;
  font-size: 0.975rem;
  color: var(--muted-on-dark);
}

.project__features strong {
  color: var(--white);
  font-weight: 500;
}

.project__features svg {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  color: var(--brass);
}

.stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}

.stack li {
  padding: 0.3rem 0.7rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.8rem;
  color: var(--muted-on-dark);
}

.project__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

/* Browser frame */

.browser {
  position: relative;
  border-radius: 14px;
  background: var(--ink-2);
  box-shadow:
    0 0 0 1px var(--line-on-dark),
    0 30px 80px -20px rgba(0, 0, 0, 0.6),
    0 0 120px -30px rgba(184, 149, 108, 0.25);
  overflow: hidden;
}

.browser__bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  height: 38px;
  padding: 0 0.9rem;
  border-bottom: 1px solid var(--line-on-dark);
}

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

.browser__dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
}

.browser__url {
  flex: 1;
  max-width: 280px;
  margin-inline: auto;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.75rem;
  text-align: center;
  color: var(--muted-on-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.browser__shot {
  display: block;
  overflow: hidden;
  aspect-ratio: 2880 / 1466;
}

.browser__shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .browser__shot:hover img {
    transform: scale(1.02);
  }
}

.metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.5rem;
}

.metric {
  padding: 1.1rem 1.2rem;
  border: 1px solid var(--line-on-dark);
  border-radius: 14px;
}

.metric b {
  display: block;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 500;
  line-height: 1;
  color: var(--brass-light);
}

.metric span {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.8rem;
  line-height: 1.4;
  color: var(--muted-on-dark);
}

@media (max-width: 960px) {
  .project {
    grid-template-columns: 1fr;
  }
  .project__media {
    order: -1;
  }
}

@media (max-width: 480px) {
  .metrics {
    gap: 0.5rem;
  }
  .metric {
    padding: 0.9rem 0.8rem;
  }
  .metric b {
    font-size: 1.35rem;
  }
  .metric span {
    font-size: 0.75rem;
  }
}

.divider {
  height: 1px;
  margin: clamp(4rem, 8vw, 6rem) 0;
  background: var(--line-on-dark);
}

.project-card {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 2rem;
  align-items: center;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border: 1px solid var(--line-on-dark);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.03);
}

.project-card__logo {
  display: grid;
  place-items: center;
  padding: 2rem;
  border-radius: 14px;
  background: var(--white);
}

.project-card__logo img {
  width: 100%;
  max-width: 280px;
  height: auto;
}

.project-card h3 {
  margin-top: 1rem;
  font-size: clamp(1.6rem, 3vw, 2.1rem);
}

.project-card p {
  margin-top: 0.75rem;
  color: var(--muted-on-dark);
}

@media (max-width: 760px) {
  .project-card {
    grid-template-columns: 1fr;
  }
}

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */

.contact {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 3rem 5rem;
  align-items: end;
}

.contact__title {
  margin-top: 1.5rem;
  font-size: clamp(2.4rem, 6vw, 4.75rem);
}

.contact__email {
  display: inline-block;
  margin-top: 2rem;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--brass-dark);
  overflow-wrap: anywhere;
}

.contact__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.contact__info {
  display: grid;
  gap: 1.75rem;
  margin: 0;
}

.contact__info dt {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

.contact__info dd {
  margin: 0.4rem 0 0;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
  font-size: 1.05rem;
}

@media (max-width: 860px) {
  .contact {
    grid-template-columns: 1fr;
  }
}

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

.footer {
  padding: 2.5rem 0 calc(2.5rem + env(safe-area-inset-bottom));
  background: var(--ink);
  color: var(--muted-on-dark);
  font-size: 0.9rem;
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem 2rem;
}

.footer .brand {
  color: var(--white);
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer__links a {
  transition: color 200ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .footer__links a:hover {
    color: var(--white);
  }
}

/* --------------------------------------------------------------------------
   Motion
   Only active when JS runs (html.js). Without JS everything is visible.
   -------------------------------------------------------------------------- */

/* Scroll reveal: each group fades and rises once, children staggered (--d set in JS) */
.js [data-reveal] > [data-item],
.js [data-reveal-self] {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 600ms var(--ease-out),
    transform 800ms var(--ease-out);
  transition-delay: var(--d, 0ms);
}

.js [data-reveal].is-in > [data-item],
.js [data-reveal-self].is-in {
  opacity: 1;
  transform: none;
}

/* Hero: masked line reveal, then supporting content */
.js .hero .line__inner {
  transform: translateY(105%);
  transition: transform 1000ms var(--ease-out);
  transition-delay: var(--d, 0ms);
}

.js .hero.is-in .line__inner {
  transform: none;
}

.js .hero [data-hero-fade] {
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 700ms var(--ease-out),
    transform 900ms var(--ease-out);
  transition-delay: var(--d, 0ms);
}

.js .hero.is-in [data-hero-fade] {
  opacity: 1;
  transform: none;
}

/* Circuit draws itself in, echoing the logo's traces */
.js .hero__circuit .trace,
.js .hero__circuit .letter {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 1600ms var(--ease-in-out);
  transition-delay: var(--d, 0ms);
}

.js .hero.is-in .hero__circuit .trace,
.js .hero.is-in .hero__circuit .letter {
  stroke-dashoffset: 0;
}

.js .hero__circuit .node,
.js .hero__circuit .block {
  opacity: 0;
  transform: scale(0.9);
  transform-box: fill-box;
  transform-origin: center;
  transition:
    opacity 500ms var(--ease-out),
    transform 500ms var(--ease-out);
  transition-delay: var(--d, 0ms);
}

.js .hero.is-in .hero__circuit .node {
  opacity: 1;
  transform: none;
}

.js .hero.is-in .hero__circuit .block {
  opacity: 0.12;
  transform: none;
}

/* Project screenshot: wipes up into view */
.js [data-wipe] {
  clip-path: inset(100% 0 0 0 round 14px);
  transition: clip-path 1100ms var(--ease-in-out);
}

.js [data-wipe] img {
  transform: scale(1.08);
  transition: transform 1400ms var(--ease-out);
}

.js [data-wipe].is-in {
  clip-path: inset(0 0 0 0 round 14px);
}

.js [data-wipe].is-in img {
  transform: none;
}

/* Status dot: one gentle pulse to say "this is live" */
@keyframes ping {
  0% {
    box-shadow: 0 0 0 0 rgba(52, 192, 138, 0.45);
  }
  100% {
    box-shadow: 0 0 0 10px rgba(52, 192, 138, 0);
  }
}

.js .is-in .project__tag i {
  animation: ping 1600ms var(--ease-out) 600ms 3;
}

/* Reduced motion: keep the fades (they aid comprehension), drop all movement */
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] > [data-item],
  .js [data-reveal-self],
  .js .hero [data-hero-fade],
  .js .hero__circuit .node,
  .js .hero__circuit .block {
    transform: none !important;
    transition: opacity 300ms ease !important;
    transition-delay: 0ms !important;
  }

  .js .hero .line__inner,
  .js [data-wipe] img {
    transform: none !important;
    transition: none !important;
  }

  .js [data-wipe] {
    clip-path: none !important;
  }

  .js .hero__circuit .trace,
  .js .hero__circuit .letter {
    stroke-dashoffset: 0 !important;
    transition: none !important;
  }

  .js .is-in .project__tag i {
    animation: none;
  }

  .btn:active {
    transform: none;
  }
}
