/* Swipe antes/depois: arrastando para a direita, a cena "depois" (com a marca) aparece sobre a "antes". */

.swipe {
  position: absolute;
  inset: 0;
  overflow: hidden;
  cursor: ew-resize;
  touch-action: pan-y;
}

.cena {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.cena svg {
  display: block;
  width: 100%;
  height: 100%;
}

.cena-depois {
  clip-path: inset(0 calc(100% - var(--x, 0px)) 0 0);
}

.estrelas circle {
  animation: piscar 2.4s ease-in-out infinite;
}

.estrelas circle:nth-child(2n) {
  animation-delay: 0.8s;
}

.estrelas circle:nth-child(3n) {
  animation-delay: 1.6s;
}

/* Logo fincado no topo da montanha, balançando como bandeira */
.bandeira {
  position: absolute;
  left: 150px;
  top: 25px;
  width: 30px;
  height: 30px;
  transform-origin: 0 50%;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
  animation: tremular 2.2s ease-in-out infinite alternate;
}

.rotulo {
  position: absolute;
  top: 44px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.1;
}

.rotulo-antes {
  right: 10px;
  color: #5d6766;
  background: rgba(255, 255, 255, 0.75);
}

.rotulo-depois {
  left: 10px;
  color: var(--floresta);
  background: var(--verde);
}

/* Alça: linha branca + círculo com setas */
.swipe-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--x, 0px);
  width: 3px;
  margin-left: -1.5px;
  background: var(--branco);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
  z-index: 3;
  pointer-events: none;
}

.swipe-knob {
  position: absolute;
  top: 46%;
  left: var(--knob-offset, 0px);
  width: 34px;
  height: 34px;
  margin: -17px 0 0 -16px;
  border: 3px solid var(--branco);
  border-radius: 50%;
  background: rgba(18, 49, 51, 0.75);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.seta-esq,
.seta-dir {
  position: absolute;
  top: 50%;
  width: 0;
  height: 0;
  margin-top: -5px;
  border: 5px solid transparent;
}

.seta-esq {
  left: 3px;
  border-right-color: var(--branco);
}

.seta-dir {
  right: 3px;
  border-left-color: var(--branco);
}

.deslize {
  position: absolute;
  left: 50%;
  top: 150px;
  translate: -50% 0;
  white-space: nowrap;
  z-index: 4;
  pointer-events: none;
}

/* Setinha que vai e volta, mostrando o movimento */
.deslize-seta {
  position: relative;
  width: 16px;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
  animation: vai-e-volta 1.2s ease-in-out infinite alternate;
}

.deslize-seta::after {
  content: "";
  position: absolute;
  right: -1px;
  top: -3px;
  width: 6px;
  height: 6px;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: rotate(45deg);
}

.topo {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 5;
}

/* Faixa de baixo: chamada + CTA (só o botão recebe clique) */
.rodape {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  padding: 26px 12px 12px;
  background: linear-gradient(to bottom, transparent, rgba(11, 34, 36, 0.92) 55%);
  z-index: 5;
  pointer-events: none;
}

.chamada {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.1;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.4);
}

.rodape .btn {
  pointer-events: auto;
}

/* Abertura: sobe depois de 2,6s (ou no clique) */
.intro {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-bottom: 20px;
  text-align: center;
  background:
    var(--montanhas) bottom / 100% 60px no-repeat,
    radial-gradient(circle at 50% 35%, var(--floresta-clara), var(--floresta) 70%);
  z-index: 10;
  cursor: pointer;
  animation: subir 0.6s cubic-bezier(0.6, 0, 0.3, 1) 2.6s forwards;
}

.intro.pular {
  animation-delay: 0s;
}

.intro > * {
  animation: surgir 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) backwards;
}

.intro-logo {
  width: 60px;
  height: 60px;
  animation-name: surgir-logo;
  animation-delay: 0.1s;
}

.intro-titulo {
  margin-top: 10px;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.1;
  animation-delay: 0.45s;
}

.intro-texto {
  margin-top: 4px;
  font-size: 12px;
  font-weight: 500;
  color: var(--verde-claro);
  animation-delay: 0.8s;
}

@keyframes subir {
  to {
    transform: translateY(-100%);
    visibility: hidden;
  }
}

@keyframes piscar {
  50% {
    opacity: 0.2;
  }
}

@keyframes tremular {
  from {
    transform: rotate(-6deg);
  }
  to {
    transform: rotate(6deg);
  }
}

@keyframes vai-e-volta {
  from {
    transform: translateX(-3px);
  }
  to {
    transform: translateX(3px);
  }
}
