.home-page .home-hero {
  isolation: isolate;
  padding-block: clamp(56px, 8vw, 104px);
  background:
    radial-gradient(ellipse at 82% 32%, rgb(191 224 255 / 54%), transparent 35%),
    linear-gradient(90deg, rgb(243 248 255 / 96%) 0%, rgb(255 255 255 / 91%) 38%, rgb(255 255 255 / 74%) 66%, rgb(240 248 255 / 54%) 100%),
    url("assets/relay-home-story.svg") center right / cover no-repeat;
}

.home-page .home-hero::after {
  width: 52%;
  background: radial-gradient(ellipse at 70% 50%, rgb(2 132 199 / 10%), transparent 68%);
  animation: none;
}

.home-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  align-items: center;
  gap: clamp(36px, 6vw, 76px);
  grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr);
}

.home-hero-copy { max-width: 560px; }
.home-hero-copy h1 {
  max-width: 620px;
  margin: 16px 0 18px;
  color: #102a43;
  font-size: clamp(44px, 5.2vw, 66px);
  line-height: 1.03;
  letter-spacing: -.055em;
  text-wrap: balance;
}
.home-hero-copy .hero-description {
  max-width: 520px;
  margin: 0;
  color: #526579;
  font-size: clamp(16px, 1.4vw, 18px);
  line-height: 1.7;
}
.home-hero-copy .hero-actions { align-items: center; margin-top: 26px; }
.home-hero-copy .button { min-height: 52px; }
.home-secondary-link {
  color: #225d82;
  font-size: 14px;
  font-weight: 750;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.home-sample-note { margin: 14px 0 0; color: #718196; font-size: 12px; }

.home-circuit-preview {
  position: relative;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid #244554;
  border-radius: 20px;
  padding: clamp(17px, 2vw, 25px);
  background:
    radial-gradient(ellipse at 42% 0%, rgb(34 109 129 / 28%), transparent 48%),
    linear-gradient(145deg, #0b2431, #102d3a 55%, #0b2633);
  box-shadow: 0 34px 80px -48px rgb(16 42 67 / 55%), 0 6px 20px -16px rgb(16 42 67 / 38%);
  color: #e6f4f6;
  animation: home-preview-arrive .7s .08s both;
}
.home-circuit-preview::before {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, transparent 49.6%, rgb(119 202 218 / 5%) 50%, transparent 50.4%),
    linear-gradient(transparent 49.6%, rgb(119 202 218 / 5%) 50%, transparent 50.4%);
  background-size: 30px 30px;
  content: "";
  mask-image: radial-gradient(ellipse at 50% 40%, #000, transparent 88%);
  pointer-events: none;
}
.home-circuit-preview > * { position: relative; z-index: 1; }
.circuit-preview-topline,
.circuit-preview-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.circuit-preview-topline {
  padding-bottom: 14px;
  border-bottom: 1px solid rgb(198 225 233 / 13%);
  color: #a4c3cf;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .09em;
}
.circuit-preview-topline > span:first-child { display: inline-flex; align-items: center; gap: 8px; }
.circuit-preview-topline i { width: 7px; height: 7px; border-radius: 50%; background: #58d5a3; box-shadow: 0 0 10px rgb(88 213 163 / 55%); }
.circuit-fictional-label {
  border: 1px solid rgb(154 190 202 / 24%);
  border-radius: 99px;
  padding: 5px 8px;
  color: #a4c3cf;
  font-size: 9px;
  letter-spacing: .04em;
  white-space: nowrap;
}
.circuit-preview-heading { align-items: flex-end; margin: 18px 0 16px; }
.circuit-preview-heading p { margin: 0 0 5px; color: #8eacb8; font-size: 8px; font-weight: 800; letter-spacing: .09em; }
.circuit-preview-heading h2 { color: #f0fbfc; font-size: clamp(19px, 2vw, 24px); }
.circuit-state-pill {
  border: 1px solid rgb(235 177 80 / 34%);
  border-radius: 99px;
  padding: 6px 9px;
  background: rgb(153 95 25 / 15%);
  color: #f5c46f;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: .03em;
  white-space: nowrap;
}
.circuit-flow {
  display: grid;
  align-items: stretch;
  gap: 0;
  grid-template-columns: minmax(110px, .78fr) 12px minmax(190px, 1.45fr) 12px minmax(115px, .82fr) 12px minmax(122px, .82fr);
  min-width: 0;
}
.circuit-stage {
  min-width: 0;
  border: 1px solid rgb(152 192 205 / 18%);
  border-radius: 13px;
  padding: 13px 11px;
  background: linear-gradient(155deg, rgb(255 255 255 / 6%), rgb(255 255 255 / 2%));
}
.circuit-stage-label {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 5px;
  min-height: 23px;
  margin: 0 0 12px;
  color: #6fd2c2;
  font-size: 9px;
  font-weight: 850;
  letter-spacing: .07em;
}
.circuit-stage-label span { color: #9db8c2; font-size: 8px; }
.circuit-stage h3 { margin: 10px 0 4px; color: #eef9fa; font-size: 13px; }
.circuit-stage > p:not(.circuit-stage-label) { margin: 0; color: #93adb8; font-size: 10px; line-height: 1.55; }
.circuit-stage-state {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  color: #a8c0c8;
  font-size: 9px;
  line-height: 1.4;
}
.circuit-stage-state i { width: 6px; height: 6px; flex: 0 0 auto; border-radius: 50%; background: #53d0a1; box-shadow: 0 0 8px rgb(83 208 161 / 48%); }
.circuit-coil-icon { display: grid; width: 48px; height: 48px; place-items: center; border: 1px solid rgb(90 210 197 / 35%); border-radius: 12px; background: rgb(34 136 139 / 13%); }
.circuit-coil-icon svg { width: 40px; fill: none; stroke: #77dfcc; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.circuit-stage-hint { margin-bottom: 8px !important; }
.circuit-contact-list { display: grid; gap: 5px; margin: 0; padding: 0; list-style: none; }
.circuit-contact {
  display: grid;
  width: 100%;
  min-width: 0;
  align-items: center;
  gap: 7px;
  grid-template-columns: 27px minmax(0, 1fr) auto;
  border: 1px solid rgb(157 191 202 / 18%);
  border-radius: 8px;
  padding: 7px 6px;
  background: rgb(255 255 255 / 3%);
  color: #e6f4f6;
  cursor: pointer;
  text-align: left;
  transition: border-color .2s, background .2s, transform .2s;
}
.circuit-contact:hover:not(:disabled) { transform: translateY(-1px); border-color: rgb(104 216 199 / 52%); background: rgb(255 255 255 / 7%); }
.circuit-contact:focus-visible,
.circuit-reset:focus-visible,
.circuit-route-picker input:focus-visible + span { outline: 2px solid #65dfca; outline-offset: 3px; }
.circuit-contact-symbol { display: grid; width: 25px; height: 25px; place-items: center; border: 1px solid rgb(231 173 83 / 36%); border-radius: 7px; background: rgb(158 99 23 / 14%); }
.circuit-contact-symbol svg { width: 21px; fill: #102d3a; stroke: #f1bd62; stroke-width: 1.6; stroke-linecap: round; }
.circuit-contact-symbol .contact-arm { transform-origin: 7px 10px; transition: transform .3s cubic-bezier(.2,.75,.25,1); }
.circuit-contact.is-open .contact-arm { transform: rotate(-29deg); }
.circuit-contact.is-closed .circuit-contact-symbol { border-color: rgb(91 216 163 / 35%); background: rgb(37 150 107 / 16%); }
.circuit-contact.is-closed .circuit-contact-symbol svg { stroke: #66e1b1; }
.circuit-contact-copy { min-width: 0; }
.circuit-contact-copy strong,
.circuit-contact-copy small { display: block; overflow: hidden; text-overflow: ellipsis; }
.circuit-contact-copy strong { color: #e6f4f6; font-size: 9px; }
.circuit-contact-copy small { margin-top: 3px; color: #91aab5; font-size: 8px; }
.circuit-contact-state { color: #f1bd62; font-size: 8px; font-weight: 800; }
.circuit-contact.is-closed .circuit-contact-state { color: #6de0af; }
.circuit-contact.is-bypassed { border-style: dashed; opacity: .56; cursor: not-allowed; }
.circuit-contact.is-bypassed .circuit-contact-symbol { border-color: rgb(157 191 202 / 25%); background: transparent; }
.circuit-contact.is-bypassed .circuit-contact-symbol svg { stroke: #91aab5; }
.circuit-contact.is-bypassed .circuit-contact-state { color: #9eb3bd; }
.circuit-wire {
  position: relative;
  align-self: center;
  height: 12px;
}
.circuit-wire::before {
  position: absolute;
  top: 5px;
  right: 0;
  left: 0;
  height: 2px;
  background: repeating-linear-gradient(90deg, #db9f43 0 4px, transparent 4px 8px);
  content: "";
  transition: background .25s ease, box-shadow .25s ease;
}
.circuit-wire.is-live::before { background: #58d9ad; box-shadow: 0 0 8px rgb(88 217 173 / 55%); }
.circuit-wire span { position: absolute; top: 2px; left: 0; width: 7px; height: 7px; transform: scale(0); border-radius: 50%; background: #d5fff0; box-shadow: 0 0 10px #63efc2; }
.home-circuit-preview.is-pulsing .circuit-wire.is-live span { animation: circuit-signal-pulse .62s cubic-bezier(.2,.75,.25,1) both; }
.home-circuit-preview.is-pulsing .circuit-wire:nth-of-type(2) span { animation-delay: .22s; }
.home-circuit-preview.is-pulsing .circuit-wire:nth-of-type(3) span { animation-delay: .44s; }
.circuit-route-picker { display: grid; gap: 5px; margin: 12px 0 8px; border: 0; padding: 0; }
.circuit-route-picker legend { margin-bottom: 6px; color: #94adb8; font-size: 9px; }
.circuit-route-picker label { display: flex; align-items: center; gap: 7px; color: #e3f0f2; font-size: 9px; cursor: pointer; }
.circuit-route-picker input { width: 12px; height: 12px; margin: 0; accent-color: #5bd2b0; }
.circuit-route-detail { min-height: 28px; color: #a6c2cb !important; font-size: 9px !important; }
.circuit-output { display: flex; flex-direction: column; align-items: flex-start; }
.circuit-led { display: grid; width: 48px; height: 48px; margin-top: 3px; place-items: center; border: 1px solid rgb(236 177 79 / 36%); border-radius: 50%; background: radial-gradient(circle, rgb(228 165 61 / 18%), rgb(255 255 255 / 3%) 70%); }
.circuit-led span { width: 18px; height: 18px; border: 1px solid #d49b43; border-radius: 50%; background: #996823; box-shadow: 0 0 0 5px rgb(214 156 61 / 8%); transition: background .25s, box-shadow .25s; }
.home-circuit-preview[data-circuit-state="ready"] .circuit-led { border-color: rgb(97 227 171 / 48%); background: radial-gradient(circle, rgb(63 220 157 / 22%), rgb(255 255 255 / 3%) 70%); }
.home-circuit-preview[data-circuit-state="ready"] .circuit-led span { border-color: #78f0bd; background: #55e1a3; box-shadow: 0 0 0 5px rgb(69 218 153 / 12%), 0 0 20px rgb(69 218 153 / 72%); }
.circuit-output-state { min-height: 33px; margin-top: 9px !important; color: #f0bd67 !important; font-size: 9px !important; font-weight: 750; }
.home-circuit-preview[data-circuit-state="ready"] .circuit-output-state { color: #77e7b5 !important; }
.circuit-output small { margin-top: auto; padding-top: 9px; color: #91aab5; font-size: 8px; line-height: 1.5; }
.circuit-preview-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; border-top: 1px solid rgb(198 225 233 / 13%); padding-top: 11px; }
.circuit-preview-footer > span { display: flex; align-items: center; gap: 6px; color: #90abb6; font-size: 9px; }
.circuit-preview-footer > span i { width: 6px; height: 6px; border-radius: 50%; background: #75b8da; }
.circuit-reset { border: 0; padding: 4px; background: transparent; color: #80d8cf; cursor: pointer; font: inherit; font-size: 9px; }
.home-circuit-preview figcaption { margin-top: 8px; color: #8da7b2; font-size: 9px; text-align: center; }
.home-circuit-preview[data-circuit-state="ready"] .circuit-state-pill { border-color: rgb(97 227 171 / 38%); background: rgb(37 145 100 / 16%); color: #79e7b6; }

.home-process-section { padding-block: clamp(60px, 8vw, 92px); }
.home-process-heading { max-width: 740px; margin: 0 auto 38px; text-align: center; }
.home-process-heading h2 { margin-top: 10px; color: #102a43; letter-spacing: -.05em; text-wrap: balance; }
.home-process-heading > p:last-child { color: #64788b; }
.home-process-path {
  position: relative;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
  padding: 0;
  list-style: none;
}
.home-process-path::before {
  position: absolute;
  top: 21px;
  right: 12.5%;
  left: 12.5%;
  height: 2px;
  transform: scaleX(0);
  transform-origin: left;
  background: linear-gradient(90deg, #85c7b1, #8bc7dc);
  content: "";
  animation: home-route-arrive .9s .25s cubic-bezier(.2,.75,.25,1) forwards;
}
.home-path-step {
  position: relative;
  z-index: 1;
  min-width: 0;
  border: 1px solid #e4ebf0;
  border-radius: 15px;
  padding: 20px;
  background: #fff;
  box-shadow: 0 12px 30px rgb(16 42 67 / 4%);
  transition: transform .24s ease, border-color .24s ease, box-shadow .24s ease;
}
.home-path-step:hover { transform: translateY(-4px); border-color: #b7dbe9; box-shadow: 0 18px 34px -24px rgb(16 93 130 / 25%); }
.home-path-number {
  display: grid;
  width: 34px;
  height: 34px;
  margin-bottom: 20px;
  place-items: center;
  border: 1px solid #d7e8ef;
  border-radius: 50%;
  background: #f3f9fc;
  color: #287ba2;
  font-size: 10px;
  font-weight: 850;
}
.home-path-step h3 { color: #183752; font-size: 16px; }
.home-path-step p { margin: 8px 0 0; color: #687d90; font-size: 13px; line-height: 1.6; }
.motion-ready .home-path-step.motion-reveal {
  transform: translateY(14px);
  transition: opacity .55s cubic-bezier(.2,.75,.25,1), transform .55s cubic-bezier(.2,.75,.25,1), border-color .24s ease, box-shadow .24s ease;
  transition-delay: var(--reveal-delay, 0ms);
}
.motion-ready .home-path-step.motion-reveal.is-visible { transform: translateY(0); }
.motion-ready .home-path-step.motion-reveal.is-visible:hover { transform: translateY(-4px); }

.home-next-section { padding-top: 12px; padding-bottom: clamp(60px, 8vw, 92px); background: linear-gradient(180deg, #fff, #f6f9fc); }
.home-next-card {
  display: grid;
  align-items: center;
  gap: 28px;
  grid-template-columns: minmax(0, 1fr) auto;
  border: 1px solid #dce6ee;
  border-radius: 20px;
  padding: clamp(24px, 4vw, 42px);
  background: linear-gradient(120deg, #f7fbff, #fff 58%, #f4faf8);
}
.home-next-card h2 { max-width: 650px; margin-top: 9px; color: #102a43; font-size: clamp(27px, 3.5vw, 38px); text-wrap: balance; }
.home-next-card > div:first-child > p:last-child { max-width: 620px; margin: 10px 0 0; color: #62778b; }
.home-next-actions { display: grid; justify-items: start; gap: 12px; }
.home-next-actions .button { white-space: nowrap; }
.home-next-actions .text-link { color: #286481; font-size: 13px; font-weight: 750; text-underline-offset: 3px; }

@keyframes home-preview-arrive { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes home-route-arrive { to { transform: scaleX(1); } }
@keyframes circuit-signal-pulse { 0% { transform: translateX(0) scale(.8); opacity: 0; } 16% { opacity: 1; } 100% { transform: translateX(14px) scale(1); opacity: 0; } }

@media (max-width: 920px) {
  .home-process-path { gap: 10px; }
  .home-path-step { padding: 16px; }
}

@media (max-width: 1248px) {
  .home-hero-grid { gap: 34px; grid-template-columns: 1fr; }
  .home-hero-copy { max-width: 740px; }
  .home-circuit-preview { width: min(100%, 800px); margin-inline: auto; }
}

@media (max-width: 760px) {
  .home-page .home-hero {
    padding-block: 48px;
    background:
      linear-gradient(90deg, rgb(247 249 255 / 95%), rgb(247 249 255 / 82%)),
      url("assets/relay-home-story.svg") 66% center / cover no-repeat;
  }
  .home-hero-grid { grid-template-columns: 1fr; }
  .home-hero-copy { max-width: 680px; }
  .home-circuit-preview { width: min(100%, 680px); margin-inline: auto; }
  .circuit-flow { grid-template-columns: minmax(110px, .78fr) 18px minmax(190px, 1.45fr) 18px minmax(115px, .82fr) 18px minmax(122px, .82fr); }
  .home-process-path { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-process-path::before { display: none; }
  .home-next-card { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  .home-page .home-hero { padding-block: 38px; }
  .home-hero-copy h1 { font-size: clamp(39px, 10vw, 50px); }
  .home-hero-copy .hero-actions { align-items: flex-start; flex-direction: column; }
  .home-circuit-preview { border-radius: 15px; padding: 14px; }
  .circuit-preview-heading { align-items: flex-start; flex-direction: column; }
  .circuit-flow { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .circuit-stage { padding: 14px; }
  .circuit-stage-label { font-size: 9px; }
  .circuit-stage-label span { font-size: 8px; }
  .circuit-stage h3 { font-size: 14px; }
  .circuit-stage > p:not(.circuit-stage-label) { font-size: 10px; }
  .circuit-stage-state { font-size: 9px; }
  .circuit-wire { justify-self: center; width: 14px; height: 22px; }
  .circuit-wire::before { top: 0; bottom: 0; left: 6px; width: 2px; height: auto; background: repeating-linear-gradient(180deg, #db9f43 0 4px, transparent 4px 8px); }
  .circuit-wire.is-live::before { background: #58d9ad; }
  .circuit-wire span { top: 0; left: 3px; }
  .home-circuit-preview.is-pulsing .circuit-wire.is-live span { animation-name: circuit-signal-pulse-vertical; }
  .home-circuit-preview.is-pulsing .circuit-wire:nth-of-type(2) span { animation-delay: .22s; }
  .home-circuit-preview.is-pulsing .circuit-wire:nth-of-type(3) span { animation-delay: .44s; }
  .circuit-contact-copy strong { font-size: 10px; }
  .circuit-contact-copy small { font-size: 9px; }
  .circuit-contact-state { font-size: 9px; }
  .circuit-route-picker { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .circuit-route-picker legend { grid-column: 1 / -1; font-size: 9px; }
  .circuit-route-picker label,
  .circuit-route-detail { font-size: 9px !important; }
  .circuit-output-state { font-size: 10px !important; }
  .circuit-output small,
  .home-circuit-preview figcaption { font-size: 8px; }
  .circuit-preview-footer { align-items: flex-start; flex-direction: column; }
  .home-process-path { grid-template-columns: 1fr; }
  .home-path-step { padding: 18px; }
  .home-path-number { margin-bottom: 13px; }
  .home-next-actions { width: 100%; }
  .home-next-actions .button { width: 100%; white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  .home-page .home-hero::after,
  .home-circuit-preview,
  .circuit-contact,
  .circuit-contact-symbol .contact-arm,
  .circuit-wire span,
  .circuit-led span,
  .home-process-path::before,
  .home-path-step { animation: none; transition: none; }
  .home-process-path::before { transform: none; }
  .motion-ready .home-path-step.motion-reveal,
  .motion-ready .home-path-step.motion-reveal.is-visible { opacity: 1; transform: none; }
}

.founding-offer-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 20px max(20px, calc((100vw - 1180px) / 2));
  color: #12355b;
  background: #eaf3ff;
  font-size: 0.94rem;
}
.founding-offer-copy { max-width: 900px; }
.founding-offer-copy .eyebrow { margin: 0 0 5px; color: #0756a5; font-size: 0.76rem; font-weight: 800; letter-spacing: 0.08em; }
.founding-offer-copy h2 { margin: 0 0 6px; font-size: clamp(1.15rem, 2.2vw, 1.65rem); line-height: 1.25; }
.founding-offer-copy p { margin: 4px 0; }
.founding-offer-copy .founding-offer-note { color: #435b76; font-size: 0.86rem; }
.founding-offer-banner .founding-offer-link { flex: 0 0 auto; padding: 10px 14px; border: 1px solid #8cb8e6; border-radius: 8px; background: #fff; color: #0756a5; font-weight: 700; text-decoration: none; white-space: nowrap; }
.founding-offer-banner .founding-offer-link:focus-visible { outline: 3px solid #0756a5; outline-offset: 3px; }
.founding-offer-banner .founding-offer-link:hover { background: #f5f9ff; }
@media (max-width: 760px) {
  .founding-offer-banner { align-items: flex-start; flex-direction: column; gap: 12px; padding: 18px 20px; }
}

@keyframes circuit-signal-pulse-vertical { 0% { transform: translateY(0) scale(.8); opacity: 0; } 16% { opacity: 1; } 100% { transform: translateY(17px) scale(1); opacity: 0; } }
