/* ==========================================================================
   Header · El mercado: un campo de teléfonos en perspectiva (vista aérea).
   Cada teléfono vive el funnel: tienda → registro → onboarding → verificación
   → primera compra → usuario activo. Los activos quedan encendidos en lima.
   El panel muestra el funnel completo de la app de ejemplo.
   ========================================================================== */

.amk {
  position: relative;
  overflow: clip;
  isolation: isolate;
  background: radial-gradient(120% 90% at 78% 40%, #1d2147 0%, #0d0f24 55%, #090a19 100%);
  color: #f4f4f6;
  padding-block: clamp(40px, 6vw, 88px) clamp(48px, 6vw, 72px);
}
.amk::before {
  /* shade behind the copy so the devices never compete with the text */
  content: '';
  position: absolute;
  z-index: 2;
  inset: 0 50% 0 0;
  background: linear-gradient(90deg, #090a19 0%, rgba(9, 10, 25, 0.85) 60%, transparent 100%);
  pointer-events: none;
}
.amk__grid {
  position: relative;
  z-index: 3;
}
.amk__copy {
  max-width: 560px;
}
.amk .ahero__eyebrow {
  color: var(--brand-lime);
  font: 600 0.9375rem/1 var(--f-display);
}
.amk .ahero__h1 {
  margin-top: 18px;
  font-size: clamp(2.4rem, 1.2rem + 4.2vw, 4.4rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  color: #fff;
  max-width: 13ch;
}
.amk .ahero__claim {
  margin-top: 22px;
  font: 600 clamp(1.25rem, 1.05rem + 0.7vw, 1.6rem) / 1.3 var(--f-display);
  color: #fff;
}
.amk .tachado::after {
  background: #ff5a61;
}
.amk .ahero__lede {
  margin-top: 16px;
  max-width: 50ch;
  color: #c9cbe0;
  font-size: clamp(1.0625rem, 1rem + 0.3vw, 1.1875rem);
}
.amk .ahero__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 26px;
  margin-top: 34px;
}
.amk .btn {
  background: var(--brand-lime);
  color: #1b1e3b;
}
.amk .ahero__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font: 500 1rem/1 var(--f-display);
  text-underline-offset: 6px;
  text-decoration-thickness: 1.5px;
  text-decoration-color: rgba(255, 255, 255, 0.35);
}

/* ----- Field of devices ---------------------------------------------------- */
.amk__field {
  position: absolute;
  z-index: 1;
  inset: 0 -14% 0 44%;
  perspective: 1500px;
  perspective-origin: 40% 30%;
  -webkit-mask-image:
    linear-gradient(90deg, transparent 0%, #000 22%, #000 80%, transparent 100%),
    linear-gradient(180deg, transparent 0%, #000 14%, #000 72%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(90deg, transparent 0%, #000 22%, #000 80%, transparent 100%),
    linear-gradient(180deg, transparent 0%, #000 14%, #000 72%, transparent 100%);
  mask-composite: intersect;
  pointer-events: none;
}
.amk__plane {
  position: absolute;
  top: 0;
  left: 2%;
  display: grid;
  grid-template-columns: repeat(7, 64px);
  gap: 34px 28px;
  transform: rotateX(56deg) rotateZ(-30deg);
  transform-style: preserve-3d;
}

/* A phone lying on a table: titanium frame, black bezel, glass and thickness. */
.dv {
  position: relative;
  width: 64px;
  aspect-ratio: 71.5 / 147;
  padding: 3px;
  border-radius: 13px;
  background: linear-gradient(140deg, #a3a6ae 0%, #4a4c53 9%, #1d1e23 26%, #34363d 52%, #15161a 76%, #7c7f88 100%);
  box-shadow:
    inset 0 0 0 0.6px rgba(255, 255, 255, 0.6),
    inset 0 0 0 1.8px #07080b,
    0 2px 0 -0.4px #5b5e66,
    0 3.5px 0 -0.6px #0b0c10,
    0 22px 24px -12px rgba(0, 0, 0, 0.9),
    0 6px 8px -3px rgba(0, 0, 0, 0.7);
}
.dv::before {
  /* side button */
  content: '';
  position: absolute;
  right: -1.6px;
  top: 27%;
  width: 1.6px;
  height: 13%;
  border-radius: 1px;
  background: linear-gradient(90deg, #2a2c31, #9a9da5);
}
.dv::after {
  /* light the screen spills on the table */
  content: '';
  position: absolute;
  inset: -34% -44%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--glow, transparent), transparent);
  opacity: 0.6;
  transition: background 600ms ease;
}
.dv__scr {
  position: relative;
  height: 100%;
  border-radius: 10.5px;
  overflow: hidden;
  background: #05060c;
}
.dv__scr::before {
  /* dynamic island */
  content: '';
  position: absolute;
  z-index: 4;
  top: 3%;
  left: 50%;
  width: 30%;
  height: 4%;
  border-radius: 99px;
  background: #000;
  transform: translateX(-50%);
}
.dv__scr::after {
  /* glass reflection */
  content: '';
  position: absolute;
  z-index: 5;
  inset: 0;
  background:
    linear-gradient(122deg, rgba(255, 255, 255, 0.32) 0%, rgba(255, 255, 255, 0.08) 24%, transparent 42%),
    linear-gradient(300deg, rgba(255, 255, 255, 0.1) 0%, transparent 18%);
  pointer-events: none;
}
.dv__scr > div {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 420ms ease;
}
.dv[data-s='0'] .s0,
.dv[data-s='1'] .s1,
.dv[data-s='2'] .s2,
.dv[data-s='3'] .s3,
.dv[data-s='4'] .s4,
.dv[data-s='5'] .s5,
.dv[data-s='6'] .s6 {
  opacity: 1;
}
.dv[data-s='1'] {
  --glow: rgba(61, 120, 255, 0.5);
}
.dv[data-s='2'],
.dv[data-s='3'],
.dv[data-s='4'] {
  --glow: rgba(220, 225, 255, 0.38);
}
.dv[data-s='5'] {
  --glow: rgba(52, 199, 89, 0.55);
}
.dv[data-s='6'] {
  --glow: rgba(232, 251, 140, 0.8);
}
.dv.pop {
  animation: dvPop 700ms var(--ease-out);
}
@keyframes dvPop {
  40% {
    transform: translateZ(14px);
  }
}

/* Screens (tiny, but real UI shapes) */
.s0 {
  background: linear-gradient(160deg, #1b2050, #07081a 70%);
}
.s0::before {
  content: '';
  position: absolute;
  top: 20%;
  left: 30%;
  right: 30%;
  height: 7%;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.55);
}
.s1,
.s2,
.s3,
.s5 {
  background: #fff;
}
.s1 i,
.s6 i {
  /* app icon */
  position: absolute;
  top: 16%;
  left: 14%;
  width: 30%;
  aspect-ratio: 1;
  border-radius: 24%;
  background: linear-gradient(150deg, #e8fb8c, #b9d84a);
}
.s1 b {
  position: absolute;
  top: 18%;
  left: 52%;
  right: 12%;
  height: 4%;
  border-radius: 2px;
  background: #1c1c1e;
  box-shadow: 0 6px 0 -0.5px #c7c7cc;
}
.s1 u {
  /* "Obtener" with a progress ring */
  position: absolute;
  top: 30%;
  left: 52%;
  width: 30%;
  height: 6.5%;
  border-radius: 99px;
  background: conic-gradient(#0a84ff var(--p, 0%), #e5e5ea 0);
}
.s1 s,
.s5 s {
  position: absolute;
  left: 12%;
  right: 12%;
  top: 48%;
  bottom: 10%;
  border-radius: 4px;
  background: linear-gradient(#f2f2f7, #e5e5ea);
}
/* Registro */
.s2::before {
  content: '';
  position: absolute;
  top: 16%;
  left: 12%;
  width: 55%;
  height: 5%;
  border-radius: 2px;
  background: #1c1c1e;
}
.s2 b {
  position: absolute;
  left: 12%;
  right: 12%;
  height: 9%;
  border-radius: 4px;
  background: #f2f2f7;
  box-shadow: inset 0 0 0 0.6px #d1d1d6;
}
.s2 b:nth-child(1) {
  top: 30%;
}
.s2 b:nth-child(2) {
  top: 43%;
}
.s2 u,
.s3 u {
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: 12%;
  height: 9%;
  border-radius: 5px;
  background: #0a84ff;
}
/* Onboarding: welcome card and page dots */
.s3 b {
  position: absolute;
  top: 14%;
  left: 10%;
  right: 10%;
  height: 40%;
  border-radius: 6px;
  background: linear-gradient(160deg, #2b3166, #1b1e3b);
}
.s3 em {
  position: absolute;
  top: 60%;
  left: 18%;
  right: 18%;
  height: 4%;
  border-radius: 2px;
  background: #1c1c1e;
}
.s3 s {
  position: absolute;
  top: 70%;
  left: 40%;
  width: 20%;
  height: 2.5%;
  background: radial-gradient(circle, #0a84ff 40%, transparent 45%) 0 0 / 33% 100%;
}
/* Verificación (KYC): ID card frame and shutter */
.s4 {
  background: #111216;
}
.s4 b {
  position: absolute;
  top: 22%;
  left: 12%;
  right: 12%;
  height: 26%;
  border-radius: 5px;
  border: 1px solid #fff;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.04));
}
.s4 b::before {
  content: '';
  position: absolute;
  left: 10%;
  top: 22%;
  width: 26%;
  height: 52%;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.45);
}
.s4 u {
  position: absolute;
  bottom: 12%;
  left: 50%;
  width: 22%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #fff;
  box-shadow:
    0 0 0 1.5px #111216,
    0 0 0 2.5px #fff;
  transform: translateX(-50%);
}
/* Primera compra */
.s5 em {
  position: absolute;
  top: 20%;
  left: 50%;
  width: 30%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #34c759;
  transform: translateX(-50%);
}
.s5 em::after {
  content: '';
  position: absolute;
  left: 30%;
  top: 26%;
  width: 26%;
  height: 40%;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(40deg);
}
.s5 b {
  position: absolute;
  top: 40%;
  left: 22%;
  right: 22%;
  height: 5%;
  border-radius: 2px;
  background: #1c1c1e;
}
.s5 s {
  top: 54%;
}
/* Usuario activo: app home with a lime "active" badge */
.s6 {
  background: #f4f4f6;
}
.s6::before {
  content: '';
  position: absolute;
  inset: 0 0 64% 0;
  background: #1b1e3b;
}
.s6 i {
  top: 10%;
  width: 18%;
}
.s6 b {
  position: absolute;
  width: 34%;
  height: 17%;
  border-radius: 4px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}
.s6 b:nth-child(2) {
  top: 42%;
  left: 12%;
}
.s6 b:nth-child(3) {
  top: 42%;
  right: 12%;
}
.s6 b:nth-child(4) {
  top: 64%;
  left: 12%;
}
.s6 b:nth-child(5) {
  top: 64%;
  right: 12%;
}
.s6 em {
  position: absolute;
  top: 12%;
  right: 12%;
  width: 34%;
  height: 7%;
  border-radius: 99px;
  background: var(--brand-lime);
}

/* ----- Funnel panel -------------------------------------------------------- */
.amk__panel {
  position: relative;
  z-index: 3;
  margin: clamp(48px, 7vw, 96px) 0 0;
  padding: 18px 22px;
  border-radius: 22px;
  background: rgba(17, 19, 44, 0.66);
  border: 1px solid rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8);
}
.amk__panel figcaption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px 12px;
  font-size: 0.8125rem;
  color: #9a9ec0;
}
.amk__app {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font: 600 0.875rem/1.2 var(--f-display);
}
.amk__app small {
  font: 400 0.8125rem var(--f-body);
  color: #9a9ec0;
}
.amk__app i {
  display: grid;
  place-items: center;
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  background: linear-gradient(150deg, #e8fb8c, #b9d84a);
  color: #1b1e3b;
  font: 800 0.75rem/1 var(--f-display);
  font-style: normal;
}
.amk__live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.amk__live b {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #34c759;
}
.amk__funnel {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 6px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}
.amk__funnel li {
  display: grid;
  gap: 6px;
  padding: 10px 14px 11px 18px;
  background: rgba(255, 255, 255, 0.05);
  clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 50%, calc(100% - 9px) 100%, 0 100%, 9px 50%);
  transition: background-color 300ms ease;
}
.amk__funnel li:first-child {
  padding-left: 14px;
  border-radius: 12px 0 0 12px;
  clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 50%, calc(100% - 9px) 100%, 0 100%);
}
.amk__funnel li.tick {
  background: rgba(255, 255, 255, 0.12);
}
.amk__funnel span {
  font-size: 0.75rem;
  color: #9a9ec0;
}
.amk__funnel b {
  font: 700 clamp(1rem, 0.8rem + 0.6vw, 1.375rem) / 1 var(--f-display);
  letter-spacing: -0.02em;
  color: #fff;
}
.amk__funnel .amk__active {
  background: rgba(232, 251, 140, 0.16);
}
.amk__funnel .amk__active span,
.amk__funnel .amk__active b {
  color: var(--brand-lime);
}
.amk__rev {
  display: flex;
  justify-content: flex-end;
  align-items: baseline;
  gap: 10px;
  margin-top: 12px;
  font-size: 0.8125rem;
  color: #9a9ec0;
}
.amk__rev b {
  font: 700 1.25rem/1 var(--f-display);
  color: #fff;
}
.amk .ahero__link .i {
  transition: transform 200ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .amk .ahero__link:hover {
    text-decoration-color: var(--brand-lime);
  }
  .amk .ahero__link:hover .i {
    transform: translateY(3px);
  }
}
@media (max-width: 767px) {
  .amk__field {
    inset: 40% -30% 22% -10%;
  }
  .amk::before {
    inset: 0 0 50% 0;
    background: linear-gradient(180deg, #090a19 40%, transparent);
  }
  .amk__copy {
    padding-bottom: clamp(240px, 60vw, 380px);
  }
  .amk__funnel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .amk__funnel li,
  .amk__funnel li:first-child {
    clip-path: none;
    border-radius: 10px;
    padding-left: 12px;
  }
}

.amk__funnel li {
  grid-template-rows: 1fr auto;
}
.amk__funnel b {
  align-self: end;
}
@media (min-width: 768px) and (max-width: 1180px) {
  .amk__copy {
    max-width: 54%;
  }
  .amk::before {
    inset: 0 36% 0 0;
  }
  .amk__field {
    inset: 0 -34% 0 58%;
  }
}
@media (min-width: 768px) and (max-width: 960px) {
  .amk__funnel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .amk__funnel li,
  .amk__funnel li:first-child {
    clip-path: none;
    border-radius: 10px;
    padding-left: 12px;
  }
}

/* Celular: el enlace "Ver cómo trabajamos" con área de toque de 40 px. */
@media (max-width: 760px) {
  .ahero__link {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
  }
}

/* Entrada al cargar, como la portada de la home: el titulo queda quieto (es el
   contenido principal que mide Google, LCP); el resto entra escalonado y el
   tachado se dibuja cuando la frase ya llego. */
@media (prefers-reduced-motion: no-preference) {
  .ahero__eyebrow,
  .ahero__claim,
  .ahero__lede,
  .ahero__cta {
    animation: ahero-entra 700ms cubic-bezier(0.22, 1, 0.36, 1) backwards;
  }
  .ahero__claim {
    animation-delay: 120ms;
  }
  .ahero__lede {
    animation-delay: 220ms;
  }
  .ahero__cta {
    animation-delay: 320ms;
  }
  .ahero__claim .tachado::after {
    transition-delay: 820ms;
  }
  /* El campo de celulares sube y aparece. Solo opacidad y traslado en el
     contenedor: es plano (el 3D vive en .amk__plane), asi que no se aplana. */
  .amk__field {
    animation: ahero-campo 1400ms cubic-bezier(0.22, 1, 0.36, 1) 150ms backwards;
  }
  .amk__panel {
    animation: ahero-panel 1000ms cubic-bezier(0.22, 1, 0.36, 1) 260ms backwards;
  }
  .amk__funnel > li {
    animation: ahero-entra 600ms cubic-bezier(0.22, 1, 0.36, 1) backwards;
  }
  .amk__funnel > li:nth-child(1) { animation-delay: 520ms; }
  .amk__funnel > li:nth-child(2) { animation-delay: 590ms; }
  .amk__funnel > li:nth-child(3) { animation-delay: 660ms; }
  .amk__funnel > li:nth-child(4) { animation-delay: 730ms; }
  .amk__funnel > li:nth-child(5) { animation-delay: 800ms; }
  .amk__funnel > li:nth-child(6) { animation-delay: 870ms; }
}
@keyframes ahero-entra {
  from {
    opacity: 0;
    transform: translate3d(0, 16px, 0);
    filter: blur(4px);
  }
}
@keyframes ahero-panel {
  from {
    opacity: 0;
    transform: translate3d(0, 28px, 0) scale(0.96);
    filter: blur(6px);
  }
}
@keyframes ahero-campo {
  from {
    opacity: 0;
    transform: translate3d(0, 24px, 0);
  }
}
