.how-hero {
  position: relative;
  overflow: hidden;
  padding: 72px 0 48px;
  background: transparent;
}

.how-hero h1 {
  max-width: 16ch;
  font-size: clamp(2.4rem, 5.5vw, 4rem);
}

.flow {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 10px;
  align-items: center;
  margin-top: 40px;
}

.flow-node {
  background: #ffffff;
  border-radius: 18px;
  padding: 22px 18px;
  text-align: center;
  box-shadow:
    0 1px 2px rgba(15, 45, 79, 0.06),
    0 16px 36px rgba(15, 45, 79, 0.1);
}

.flow-node strong {
  display: block;
  color: var(--navy);
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.flow-node span {
  color: var(--muted);
  font-size: 0.9rem;
}

.flow-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 12px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #eef3f9;
}

.flow-arrow {
  width: 56px;
  height: 4px;
  border-radius: 99px;
  background: #c5d2e3;
  position: relative;
  overflow: hidden;
}

.flow-arrow::after {
  content: "";
  position: absolute;
  inset: 0;
  width: 40%;
  background: var(--blue);
  animation: dash 1.6s linear infinite;
}

@keyframes dash {
  from { transform: translateX(-120%); }
  to { transform: translateX(280%); }
}

.steps {
  display: grid;
  gap: 18px;
}

.how-step {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 22px;
  padding: 28px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow:
    0 1px 2px rgba(15, 45, 79, 0.05),
    0 18px 40px rgba(15, 45, 79, 0.09);
}

.how-step:hover {
  transform: translateY(-4px);
  box-shadow:
    0 10px 18px rgba(15, 45, 79, 0.07),
    0 28px 50px rgba(15, 45, 79, 0.14);
  transition: 0.3s ease;
}

.step-index {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: var(--navy);
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 1.6rem;
  box-shadow: 0 14px 28px rgba(15, 45, 79, 0.22);
}

.split-fee {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 36px;
  align-items: center;
  padding: 36px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 22px 48px rgba(15, 45, 79, 0.12);
}

.ring {
  width: 200px;
  height: 200px;
  margin: 0 auto;
  position: relative;
}

.ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring-track {
  fill: none;
  stroke: #e4ebf3;
  stroke-width: 16;
}

.ring-keep {
  fill: none;
  stroke: #c9a227;
  stroke-width: 16;
  stroke-dasharray: 17 548;
  stroke-linecap: round;
  animation: draw-keep 1.4s ease forwards;
}

.ring-send {
  fill: none;
  stroke: #1a4f8b;
  stroke-width: 16;
  stroke-dasharray: 548;
  stroke-dashoffset: 548;
  animation: draw-send 1.6s ease 0.2s forwards;
}

@keyframes draw-send {
  to { stroke-dashoffset: 17; }
}

@keyframes draw-keep {
  from { stroke-dasharray: 0 548; }
  to { stroke-dasharray: 17 548; }
}

.ring-label {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--navy);
}

.ring-label b {
  font-family: var(--font-display);
  font-size: 2.2rem;
  line-height: 1;
}

.fee-list {
  display: grid;
  gap: 14px;
}

.fee-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-radius: 14px;
  background: #f4f7fb;
}

.fee-row b {
  color: var(--navy);
}

.float-doc {
  position: absolute;
  right: 8%;
  top: 90px;
  width: 150px;
  animation: float-y 7s ease-in-out infinite;
  filter: drop-shadow(0 18px 28px rgba(15, 45, 79, 0.18));
}

.contract-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 20px;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(15, 45, 79, 0.1);
}

.seal {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #1a4f8b;
  color: #ffffff;
  font-weight: 700;
  animation: pulse-seal 2.6s ease-out infinite;
}

@keyframes pulse-seal {
  0% { box-shadow: 0 0 0 0 rgba(26, 79, 139, 0.35); }
  70% { box-shadow: 0 0 0 14px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

@media (max-width: 900px) {
  .flow,
  .split-fee,
  .how-step {
    grid-template-columns: 1fr;
  }

  .flow-arrow {
    width: 4px;
    height: 36px;
    justify-self: center;
  }

  .float-doc {
    display: none;
  }
}
