/* Ponto Alto Capital — V8 motion layer
   Esta folha não estiliza o HERO nem #jornada. */

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

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

.lenis.lenis-stopped {
  overflow: clip;
}

.motion-about,
.motion-process,
.motion-credit,
.motion-simulator,
.motion-guarantees {
  position: relative;
  overflow: clip;
}

/* Sobre */
.about-shell {
  position: relative;
  isolation: isolate;
}

.about-copy,
.about-steps {
  position: relative;
  z-index: 2;
}

.about-title {
  transform-origin: left center;
}

.about-step {
  position: relative;
  padding: 12px 0;
  transition: opacity .35s ease, transform .45s cubic-bezier(.2,.8,.2,1);
}

.about-step > span:first-child {
  transition: color .35s ease, transform .45s cubic-bezier(.2,.8,.2,1);
  transform-origin: right center;
}

.about-step:not(.is-active) {
  opacity: .46;
}

.about-step.is-active {
  opacity: 1;
  transform: translate3d(14px,0,0);
}

.about-step.is-active > span:first-child {
  color: #B08A3C !important;
  transform: scale(1.08);
}

.about-structure {
  position: absolute;
  z-index: 0;
  right: -4%;
  top: 8%;
  width: min(52%, 620px);
  height: 84%;
  pointer-events: none;
  opacity: .42;
}

.about-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(11,31,51,.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(11,31,51,.055) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(90deg,transparent 0,#000 24%,#000 100%);
}

.about-column {
  position: absolute;
  bottom: 10%;
  width: 16%;
  border: 1px solid rgba(176,138,60,.22);
  background: rgba(176,138,60,.07);
  transform-origin: bottom center;
}

.about-column-a { left: 31%; height: 25%; }
.about-column-b { left: 53%; height: 48%; }
.about-column-c { left: 75%; height: 76%; }

.about-marker {
  position: absolute;
  width: 12px;
  height: 12px;
  right: 6%;
  top: 14%;
  border: 2px solid #B08A3C;
  transform: rotate(45deg);
}

/* Como funciona */
.process-shell {
  position: relative;
  isolation: isolate;
}

.process-header,
.process-steps {
  position: relative;
  z-index: 2;
}

.process-steps {
  padding-left: clamp(82px,9vw,126px);
}

.process-row {
  position: relative;
  transition: transform .45s cubic-bezier(.2,.8,.2,1), background .35s ease, opacity .35s ease;
}

.process-row:not(.is-scroll-active) {
  opacity: .56;
}

.process-row.is-scroll-active {
  opacity: 1;
  transform: translate3d(18px,0,0);
  background: rgba(216,178,106,.11) !important;
}

.process-trajectory {
  position: absolute;
  z-index: 1;
  left: 6px;
  top: clamp(230px,27vw,330px);
  bottom: 0;
  width: clamp(62px,7vw,92px);
  pointer-events: none;
}

.process-trajectory svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.process-path-base,
.process-path-progress {
  fill: none;
  vector-effect: non-scaling-stroke;
}

.process-path-base {
  stroke: rgba(216,178,106,.18);
  stroke-width: 1.25;
}

.process-path-progress {
  stroke: #D8B26A;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: var(--process-path-offset, 1);
}

.process-node {
  position: absolute;
  left: 50%;
  width: 42px;
  height: 42px;
  margin-left: -21px;
  border-radius: 50%;
  border: 1px solid rgba(216,178,106,.34);
  background: #071320;
  color: rgba(245,241,232,.56);
  display: grid;
  place-items: center;
  font-family: Archivo, sans-serif;
  font-size: 13px;
  font-weight: 600;
  transition: color .3s ease, border-color .3s ease, background .3s ease, transform .35s ease;
}

.process-node-0 { top: 0; }
.process-node-1 { top: 31%; }
.process-node-2 { top: 62%; }
.process-node-3 { bottom: 0; }

.process-node.is-active,
.process-node.is-complete {
  color: #071320;
  border-color: #D8B26A;
  background: #D8B26A;
}

.process-node.is-active {
  transform: scale(1.12);
}

/* Linhas de crédito */
.credit-shell,
.credit-horizontal-stage {
  position: relative;
}

.credit-progress {
  display: none;
  align-items: baseline;
  gap: 6px;
  color: #0A1722;
  font-family: Archivo, sans-serif;
  font-size: 13px;
  letter-spacing: .12em;
}

.credit-progress-current {
  font-family: 'Archivo Black', Archivo, sans-serif;
  font-size: 24px;
  color: #B08A3C;
}

/* Simulador */
.sim-dashboard {
  position: relative;
  isolation: isolate;
  border: 1px solid rgba(198,161,91,.18);
  box-shadow: 0 32px 80px rgba(11,31,51,.12);
  transform-origin: center top;
}

.sim-dashboard::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: linear-gradient(110deg,rgba(198,161,91,.045),transparent 36%);
  pointer-events: none;
}

.sim-form > div,
.sim-form sc-if > div {
  transition: transform .28s ease;
}

.sim-form label {
  transition: color .25s ease, letter-spacing .25s ease;
}

.sim-form div:focus-within > label {
  color: #F0DDB4 !important;
  letter-spacing: .23em !important;
}

.sim-form input,
.sim-form select {
  transition: border-color .25s ease, background-color .25s ease, box-shadow .25s ease;
}

.sim-form input:focus,
.sim-form select:focus {
  border-color: #D8B26A !important;
  background: #1A2D3D !important;
  box-shadow: 0 0 0 4px rgba(216,178,106,.09);
}

.sim-result-panel {
  position: relative;
  overflow: hidden;
  min-height: 260px;
}

.sim-result-panel::after {
  content: '';
  position: absolute;
  right: -70px;
  bottom: -90px;
  width: 220px;
  height: 220px;
  border: 1px solid rgba(216,178,106,.13);
  border-radius: 50%;
  pointer-events: none;
}

.sim-result-content {
  position: relative;
  z-index: 1;
  animation: none !important;
}

.sim-primary-value {
  display: inline-block;
  font-variant-numeric: tabular-nums;
}

.sim-gauges {
  display: grid;
  gap: 16px;
}

.sim-gauge {
  display: grid;
  gap: 8px;
}

.sim-gauge > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: rgba(255,255,255,.78);
  font-size: 13px;
  line-height: 1.4;
}

.sim-gauge strong {
  color: #F0DDB4;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.sim-gauge-track {
  display: block;
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
}

.sim-gauge-fill {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: #D8B26A;
  transform-origin: left center;
  transform: scaleX(0);
}

/* Garantias */
.guarantee-layout {
  display: grid;
  grid-template-columns: minmax(290px,360px) minmax(0,1fr);
  gap: clamp(28px,5vw,72px);
  align-items: start;
}

.guarantee-content {
  display: flex;
  flex-direction: column;
  gap: clamp(24px,3vw,40px);
  min-width: 0;
}

.guarantee-map {
  position: sticky;
  top: 14vh;
  height: min(72vh,680px);
  min-height: 590px;
  border: 1px solid rgba(216,178,106,.15);
  border-radius: 28px;
  background: #091722;
  overflow: hidden;
}

.guarantee-connections {
  position: absolute;
  inset: 24px;
  width: calc(100% - 48px);
  height: calc(100% - 48px);
}

.guarantee-path-base,
.guarantee-path-progress {
  fill: none;
  vector-effect: non-scaling-stroke;
}

.guarantee-path-base {
  stroke: rgba(216,178,106,.16);
  stroke-width: 1.2;
}

.guarantee-path-progress {
  stroke: #D8B26A;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}

.guarantee-node {
  position: absolute;
  z-index: 2;
  min-width: 108px;
  max-width: 154px;
  padding: 11px 12px;
  border: 1px solid rgba(216,178,106,.2);
  border-radius: 12px;
  background: #0D1D2A;
  color: rgba(245,241,232,.66);
  font-family: Archivo, sans-serif;
  font-size: 13px;
  line-height: 1.25;
  text-align: center;
  transform: translate3d(-50%,-50%,0) scale(.96);
  transition: color .3s ease, border-color .3s ease, background .3s ease, transform .35s ease;
}

.guarantee-node span {
  display: block;
  margin-top: 4px;
  color: rgba(245,241,232,.48);
  font-size: 13px;
}

.guarantee-node.is-active,
.guarantee-node.is-complete {
  color: #F7F4EC;
  border-color: rgba(216,178,106,.76);
  background: #122638;
  transform: translate3d(-50%,-50%,0) scale(1);
}

.guarantee-node-origin { left:50%; top:8%; }
.guarantee-node-small { left:23%; top:37%; }
.guarantee-node-large { left:77%; top:37%; }
.guarantee-node-property { left:61%; top:72%; }
.guarantee-node-vehicle { left:89%; top:72%; }
.guarantee-node-fund { left:50%; top:91%; }

.guarantee-card,
.guarantee-fund {
  transition: transform .45s cubic-bezier(.2,.8,.2,1), border-color .35s ease, opacity .35s ease;
}

.guarantee-card:not(.is-active),
.guarantee-fund:not(.is-active) {
  opacity: .68;
}

.guarantee-card.is-active,
.guarantee-fund.is-active {
  opacity: 1;
  transform: translate3d(-8px,0,0);
  border-color: rgba(216,178,106,.42) !important;
}

@media (min-width: 1051px) {
  .motion-about {
    min-height: 118svh;
  }

  .about-shell {
    min-height: 92svh;
    display: grid !important;
    grid-template-columns: minmax(0,1.08fr) minmax(360px,.72fr);
    align-items: center !important;
  }

  .about-copy {
    position: sticky;
    top: 18vh;
    align-self: start;
  }

  .about-steps {
    align-self: center;
  }

  .motion-ready .credit-horizontal-stage {
    /* O palco precisa comportar título, cards e contador, mas não ocupar
       uma tela inteira depois que o último card chega ao fim. */
    min-height: min(82svh, 820px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: clamp(24px,3.5vh,40px);
  }

  .motion-credit {
    padding-bottom: clamp(44px,5vw,68px) !important;
  }

  .motion-credit .credit-shell {
    gap: clamp(22px,2.5vw,34px) !important;
  }

  .motion-ready .credit-track {
    display: flex !important;
    grid-template-columns: none !important;
    width: max-content;
    gap: clamp(18px,2vw,28px) !important;
    will-change: transform;
  }

  .motion-ready .credit-track .credit-card {
    width: clamp(360px,38vw,500px);
    min-height: 470px;
    flex: 0 0 auto;
    animation: none !important;
  }

  .motion-ready .credit-progress {
    display: flex;
  }

  .credit-disclaimer {
    padding-top: 0;
  }

  .motion-simulator {
    padding-top: clamp(54px,6vw,76px) !important;
  }
}

@media (max-width: 1050px) {
  .about-structure {
    right: -12%;
    width: 66%;
    opacity: .24;
  }

  .process-steps {
    padding-left: 72px;
  }

  .process-trajectory {
    width: 56px;
  }

  .guarantee-layout {
    grid-template-columns: 1fr;
  }

  .guarantee-map {
    position: relative;
    top: auto;
    height: auto;
    min-height: 0;
    padding: 24px;
    display: grid;
    gap: 12px;
  }

  .guarantee-connections {
    display: none;
  }

  .guarantee-node {
    position: relative;
    inset: auto;
    min-width: 0;
    max-width: none;
    transform: none !important;
    text-align: left;
    padding: 14px 16px 14px 42px;
  }

  .guarantee-node::before {
    content: '';
    position: absolute;
    left: 18px;
    top: 50%;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #D8B26A;
    transform: translateY(-50%);
  }
}

@media (max-width: 720px) {
  .motion-about,
  .motion-process,
  .motion-simulator,
  .motion-guarantees {
    overflow: hidden;
  }

  .about-structure {
    top: 15%;
    right: -30%;
    width: 100%;
    height: 58%;
    opacity: .18;
  }

  .about-step.is-active {
    transform: translate3d(6px,0,0);
  }

  .process-steps {
    padding-left: 52px;
  }

  .process-trajectory {
    left: -5px;
    top: 250px;
    width: 46px;
  }

  .process-node {
    width: 34px;
    height: 34px;
    margin-left: -17px;
  }

  .process-row.is-scroll-active {
    transform: translate3d(5px,0,0);
  }

  .credit-progress {
    display: none !important;
  }

  .sim-dashboard {
    box-shadow: 0 20px 50px rgba(11,31,51,.1);
  }

  .sim-result-panel {
    min-height: 220px;
  }

  .guarantee-card.is-active,
  .guarantee-fund.is-active {
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .about-step,
  .about-step > span:first-child,
  .process-row,
  .process-node,
  .sim-form label,
  .sim-form input,
  .sim-form select,
  .guarantee-node,
  .guarantee-card,
  .guarantee-fund {
    transition: none !important;
  }

  .about-step,
  .process-row,
  .guarantee-card,
  .guarantee-fund {
    opacity: 1 !important;
    transform: none !important;
  }

  .process-path-progress,
  .guarantee-path-progress {
    stroke-dashoffset: 0 !important;
  }

  .sim-gauge-fill {
    transition: none !important;
  }

  .motion-ready .credit-horizontal-stage {
    min-height: 0;
    display: block;
  }

  .motion-ready .credit-track {
    display: grid !important;
    grid-template-columns: repeat(3,minmax(0,1fr)) !important;
    width: auto;
    transform: none !important;
  }

  .motion-ready .credit-track .credit-card {
    width: auto;
    min-height: 0;
  }

  .motion-ready .credit-progress {
    display: none;
  }
}

@media (max-width: 1050px) and (prefers-reduced-motion: reduce) {
  .motion-ready .credit-track {
    grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  }
}

@media (max-width: 720px) and (prefers-reduced-motion: reduce) {
  .motion-ready .credit-track {
    grid-template-columns: 1fr !important;
  }
}
