/* ==========================================================================
   Hero del home: "El viaje del talento a la tecnología".
   Escena por capas (.awk-capa) con parallax: js/awk-hero.js pone en el hero
   --mx / --my (mouse, de -1 a 1) y --sy (scroll, de 0 a 1), y en cada capa su
   profundidad --d (del atributo data-d). Más profundidad = se mueve más.
   Los paneles de cada paso (data-paso) se encienden con [data-activo] del hero.
   ========================================================================== */
.awk-hero {
    --hero-tinta: #121212;
    --hero-suave: #5c5c66;
    --hero-morado: #8f4ff0;
    --hero-lila: #f1eafd;
    --hero-menta: #e9fcf4;
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(560px, 54vw, 820px);
    overflow: hidden;
    background: #f7f5fc;
    font-family: 'Poppins', 'Poppins Fallback', sans-serif;
    color: var(--hero-tinta);
}

/* ---------- Escena ---------- */
.awk-hero__escena { position: absolute; inset: 0; font-size: clamp(8px, .78vw, 12px); pointer-events: none; }
/* Paneles: con el mouse van en sentido contrario al puntero y, al bajar, suben más rápido
   que la página (más --d = más cerca = más movimiento). */
.awk-capa {
    --d: 0;
    position: absolute;
    transform: translate3d(
        calc(var(--mx, 0) * var(--d) * -48px),
        calc(var(--my, 0) * var(--d) * -32px + var(--sy, 0) * var(--d) * -480px),
        0);
    transition: transform .2s ease-out, opacity .5s, filter .5s;
    will-change: transform;
}
/* Foto (fondo): se mueve a favor del mouse y, al bajar, se queda atrás con un ligero zoom. */
.awk-capa--foto {
    inset: -6%;
    transform: translate3d(
        calc(var(--mx, 0) * 16px),
        calc(var(--my, 0) * 10px + var(--sy, 0) * 380px),
        0) scale(calc(1 + var(--sy, 0) * .12));
}
/* El texto sube un poco más lento que la página y se desvanece al salir. */
.awk-hero__texto { transform: translate3d(0, calc(var(--sy, 0) * 120px), 0); opacity: calc(1 - var(--sy, 0) * .9); }
.awk-hero__imagen { width: 100%; height: 100%; object-fit: cover; object-position: right center; }

/* Puntos de luz */
.awk-capa--luces { inset: 0; }
.awk-capa--luces i { position: absolute; width: .7em; height: .7em; border-radius: 50%; background: #fff; box-shadow: 0 0 1.4em .4em rgb(172 100 253 / 45%); animation: awk-brillo 4s ease-in-out infinite; }
.awk-capa--luces i:nth-child(1) { left: 44%; top: 10%; }
.awk-capa--luces i:nth-child(2) { left: 60%; top: 44%; animation-delay: -1s; box-shadow: 0 0 1.4em .4em rgb(95 254 221 / 50%); }
.awk-capa--luces i:nth-child(3) { left: 82%; top: 16%; animation-delay: -2s; }
.awk-capa--luces i:nth-child(4) { left: 92%; top: 50%; animation-delay: -3s; box-shadow: 0 0 1.4em .4em rgb(95 254 221 / 50%); }
.awk-capa--luces i:nth-child(5) { left: 52%; top: 82%; animation-delay: -1.5s; }
.awk-capa--luces i:nth-child(6) { left: 39%; top: 46%; animation-delay: -2.5s; width: .5em; height: .5em; }

/* Paneles de vidrio */
.awk-panel__caja {
    padding: 1.1em 1.3em 1.2em;
    border: 1px solid rgb(255 255 255 / 85%);
    border-radius: 1.5em;
    background: rgb(255 255 255 / 74%);
    -webkit-backdrop-filter: blur(14px) saturate(1.2);
    backdrop-filter: blur(14px) saturate(1.2);
    box-shadow: 0 1.8em 3.4em rgb(70 40 140 / 16%), inset 0 1px 0 rgb(255 255 255 / 90%);
    /* Entrada desde el fondo (una vez) y luego flotan. */
    animation: awk-entrada 1s cubic-bezier(.2, .8, .2, 1) both, awk-flota 8s ease-in-out 1s infinite;
}
.awk-panel--meta .awk-panel__caja { animation-delay: .25s, 1.25s; }
.awk-panel--google .awk-panel__caja { animation-delay: .45s, -.5s; }
.awk-panel--adtech .awk-panel__caja { animation-delay: .65s, -1.5s; }
.awk-panel--performance .awk-panel__caja { animation-delay: .85s, -3s; }
.awk-panel--audiencias .awk-panel__caja { animation-delay: 1.05s, -4.5s; }
.awk-panel--mentoria .awk-panel__caja { animation-delay: 0s, -2s; }
.awk-panel--comunidad .awk-panel__caja { animation-delay: 0s, -5s; }

.awk-panel__marca { display: flex; align-items: center; gap: .5em; margin: 0 0 .8em; font-size: 1.25em; font-weight: 700; line-height: 1.2; }
.awk-panel__marca svg { width: 1.4em; height: 1.4em; flex: none; color: #0081fb; }
.awk-panel__fila { display: flex; align-items: center; gap: 1em; }
.awk-panel__linea { flex: 1; height: 5em; }
.awk-panel__datos { display: grid; gap: .45em; margin: 0; }
.awk-panel__datos dt { color: var(--hero-suave); font-size: .8em; }
.awk-panel__datos dd { margin: 0; font-size: 1.25em; font-weight: 700; }
.awk-panel__datos--fila { grid-template-columns: repeat(3, auto); justify-content: space-between; gap: 1em; margin-bottom: .8em; }

.awk-panel__barras { display: flex; align-items: flex-end; gap: .45em; height: 4em; }
.awk-panel__barras i { flex: 1; height: 50%; border-radius: .3em .3em .1em .1em; background: linear-gradient(180deg, #5ffedd, #ac64fd); opacity: .85; }
.awk-panel--google .awk-panel__barras i:nth-child(1) { height: 30%; }
.awk-panel--google .awk-panel__barras i:nth-child(2) { height: 42%; }
.awk-panel--google .awk-panel__barras i:nth-child(3) { height: 38%; }
.awk-panel--google .awk-panel__barras i:nth-child(4) { height: 55%; }
.awk-panel--google .awk-panel__barras i:nth-child(5) { height: 50%; }
.awk-panel--google .awk-panel__barras i:nth-child(6) { height: 68%; }
.awk-panel--google .awk-panel__barras i:nth-child(7) { height: 62%; }
.awk-panel--google .awk-panel__barras i:nth-child(8) { height: 80%; }
.awk-panel--google .awk-panel__barras i:nth-child(9) { height: 94%; }

.awk-panel__canales { display: flex; align-items: flex-end; gap: 1.2em; }
.awk-panel__canales ul { display: grid; gap: .55em; margin: 0; padding: 0; list-style: none; font-size: .95em; }
.awk-panel__barras--altas { flex: 1; height: 6.5em; gap: .7em; }
.awk-panel--performance .awk-panel__barras i:nth-child(1) { height: 52%; }
.awk-panel--performance .awk-panel__barras i:nth-child(2) { height: 78%; }
.awk-panel--performance .awk-panel__barras i:nth-child(3) { height: 60%; }
.awk-panel--performance .awk-panel__barras i:nth-child(4) { height: 96%; }

.awk-panel__checks { display: grid; gap: .55em; margin: 0; padding: 0; list-style: none; }
.awk-panel__checks li { display: flex; align-items: center; gap: .55em; font-size: 1em; }
.awk-panel__checks li::before { content: ""; width: 1.2em; height: 1.2em; flex: none; border-radius: 50%; background: #12b596 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 70% no-repeat; }

.awk-panel__dona { display: flex; align-items: center; gap: 1em; }
.awk-panel__dona svg { width: 6em; height: 6em; flex: none; transform: rotate(-90deg); }
.awk-panel__dona ul { display: grid; gap: .45em; margin: 0; padding: 0; list-style: none; font-size: .95em; }
.awk-panel__dona li { display: flex; align-items: center; gap: .45em; }
.awk-panel__dona li::before { content: ""; width: .6em; height: .6em; border-radius: 50%; background: var(--hero-morado); }
.awk-panel__dona li:nth-child(2)::before { background: #5ffedd; }
.awk-panel__dona li:nth-child(3)::before { background: #c9a6ff; }
.awk-panel__dona li:nth-child(4)::before { background: #12b596; }

.awk-panel__vivo { width: .7em; height: .7em; border-radius: 50%; background: #ff4d6d; box-shadow: 0 0 0 .3em rgb(255 77 109 / 20%); animation: awk-brillo 1.6s ease-in-out infinite; }
.awk-panel__mentor { display: flex; align-items: center; gap: .8em; margin-bottom: .9em; }
.awk-panel__mentor img { width: 3.4em; height: 3.4em; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 .25em var(--hero-lila); }
.awk-panel__mentor p { display: grid; margin: 0; }
.awk-panel__mentor b { font-size: 1.05em; }
.awk-panel__mentor small { color: var(--hero-suave); font-size: .85em; }
.awk-panel__chat { display: grid; gap: .5em; }
.awk-panel__chat span { max-width: 88%; padding: .55em .8em; border-radius: 1em 1em 1em .3em; background: var(--hero-lila); font-size: .9em; line-height: 1.35; }
.awk-panel__chat span:last-child { justify-self: end; border-radius: 1em 1em .3em 1em; background: var(--hero-menta); }

.awk-panel__caras { display: flex; align-items: center; margin-bottom: .7em; }
.awk-panel__caras img, .awk-panel__caras span { width: 3em; height: 3em; margin-left: -.6em; border: .2em solid #fff; border-radius: 50%; object-fit: cover; }
.awk-panel__caras img:first-child { margin-left: 0; }
.awk-panel__caras span { display: grid; place-items: center; background: var(--hero-menta); color: #12b596; font-weight: 700; }
.awk-panel__nota { margin: 0; color: var(--hero-suave); font-size: .9em; line-height: 1.4; }

/* Posición y tamaño de cada panel (escritorio) */
.awk-panel--meta { left: 43%; top: 15%; width: 20em; }
.awk-panel--google { left: 63%; top: 9%; width: 19em; }
.awk-panel--adtech { right: 2.5%; top: 27%; width: 13.5em; }
.awk-panel--performance { left: 48%; top: 54%; width: 18em; }
.awk-panel--audiencias { right: 2.5%; top: 60%; width: 16.5em; }
.awk-panel--mentoria { left: 48%; top: 58%; width: 20em; }
.awk-panel--comunidad { left: 48%; top: 64%; width: 19em; }

/* Paneles de cada paso: el 1 se ve de inicio; el 2 y el 3 aparecen con su paso. */
.awk-panel[data-paso="2"], .awk-panel[data-paso="3"] { opacity: 0; filter: blur(4px); }
.awk-hero[data-activo="2"] .awk-panel[data-paso="2"],
.awk-hero[data-activo="3"] .awk-panel[data-paso="3"] { opacity: 1; filter: none; }
.awk-hero[data-activo="2"] .awk-panel[data-paso="1"],
.awk-hero[data-activo="3"] .awk-panel[data-paso="1"] { opacity: .35; filter: saturate(.5); }
.awk-hero[data-activo="2"] .awk-panel--performance,
.awk-hero[data-activo="3"] .awk-panel--performance { opacity: 0; }

/* ---------- Texto y pasos ---------- */
.awk-hero__texto { position: relative; z-index: 1; width: min(41vw, 640px); margin-left: clamp(20px, 3.4vw, 64px); padding-block: 120px 56px; }
.awk-hero h1 { margin: 0; font-size: clamp(2rem, 3.4vw, 3.6rem); font-weight: 700; line-height: 1.12; letter-spacing: -.02em; color: var(--hero-tinta); }
.awk-viaje { display: flex; align-items: center; gap: 14px; margin: 28px 0 22px; font-size: clamp(15px, 1.25vw, 19px); font-weight: 500; color: var(--hero-tinta); }
.awk-viaje span { width: 44px; height: 2px; background: var(--hero-morado); }

.awk-pasos { position: relative; display: grid; gap: 14px; margin: 0 0 30px; padding: 0 0 0 58px; list-style: none; }
.awk-pasos::before { content: ""; position: absolute; left: 22px; top: 24px; bottom: 24px; width: 2px; background: linear-gradient(180deg, var(--hero-morado), #dcdde3 40%); }
.awk-paso {
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    border: 1.5px solid #ecebf3;
    border-radius: 18px;
    background: rgb(255 255 255 / 86%);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 22px rgb(40 30 80 / 6%);
    color: var(--hero-tinta);
    text-decoration: none;
    transition: border-color .3s, box-shadow .3s, transform .3s, background .3s;
}
.awk-paso:hover { color: var(--hero-tinta); transform: translateX(4px); }
.awk-paso.is-activo { border-color: #c9a6ff; background: rgb(255 255 255 / 96%); box-shadow: 0 14px 34px rgb(143 79 240 / 20%), 0 0 0 4px rgb(172 100 253 / 10%); }
.awk-paso:focus-visible { outline: 3px solid var(--hero-morado); outline-offset: 3px; }
.awk-paso__num { position: absolute; left: -58px; top: 50%; display: grid; place-items: center; width: 46px; height: 46px; border: 1.5px solid #dcdde3; border-radius: 50%; background: #fff; color: var(--hero-suave); font-size: 15px; font-weight: 700; transform: translateY(-50%); transition: background .3s, color .3s, border-color .3s, box-shadow .3s; }
.awk-paso.is-activo .awk-paso__num { border-color: transparent; background: var(--hero-morado); color: #fff; box-shadow: 0 0 0 6px rgb(143 79 240 / 16%); }
.awk-paso__icono { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: var(--hero-lila); color: var(--hero-morado); }
.awk-paso__icono--menta { background: var(--hero-menta); color: #12b596; }
.awk-paso__icono svg { width: 26px; height: 26px; }
.awk-paso__texto { display: grid; gap: 3px; }
.awk-paso__texto b { font-size: clamp(15px, 1.2vw, 18px); font-weight: 700; line-height: 1.25; }
.awk-paso__texto small { color: var(--hero-suave); font-size: clamp(12.5px, .95vw, 14px); line-height: 1.4; }
.awk-paso__flecha { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--hero-lila); color: var(--hero-morado); font-size: 20px; opacity: 0; transform: translateX(-6px); transition: opacity .3s, transform .3s; }
.awk-paso.is-activo .awk-paso__flecha, .awk-paso:hover .awk-paso__flecha { opacity: 1; transform: none; }
.awk-paso:has(.awk-paso__caras) { grid-template-columns: auto minmax(0, 1fr) auto auto; }
.awk-paso__caras { display: flex; align-items: center; }
.awk-paso__caras img, .awk-paso__caras i { width: 28px; height: 28px; margin-left: -8px; border: 2px solid #fff; border-radius: 50%; object-fit: cover; }
.awk-paso__caras img:first-child { margin-left: 0; }
.awk-paso__caras i { display: grid; place-items: center; background: var(--hero-menta); color: #12b596; font-size: 14px; font-style: normal; font-weight: 700; }

/* Alineado con las tarjetas: así el botón flotante de WhatsApp (abajo a la izquierda) no lo tapa. */
.awk-hero__cta { display: inline-block; margin-left: 58px; padding: 16px 36px; font-size: 17px; box-shadow: 0 6px 16px rgb(18 18 18 / 16%); }

@keyframes awk-entrada { from { opacity: 0; transform: translate3d(0, 3em, 0) scale(.86); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes awk-flota { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-.7em); } }
@keyframes awk-brillo { 0%, 100% { opacity: .5; transform: scale(.85); } 50% { opacity: 1; transform: scale(1.1); } }

/* ---------- Tableta y celular ---------- */
@media (max-width: 991.98px) {
    .awk-hero { flex-direction: column; align-items: stretch; min-height: 0; }
    .awk-hero__texto { order: 1; width: auto; max-width: 640px; margin: 0; padding: 100px 16px 8px; }
    .awk-hero h1 { font-size: clamp(2rem, 8.5vw, 3rem); line-height: 1.15; }
    .awk-hero__escena { position: relative; order: 2; height: 66vw; max-height: 520px; font-size: 1.9vw; }
    .awk-hero__imagen { object-position: 80% center; }
    /* En celular no hay parallax ni paneles: solo la foto (Mau: "no se ve padre"). */
    .awk-capa--luces, .awk-panel { display: none; }
    .awk-capa, .awk-capa--foto, .awk-hero__texto { transform: none; opacity: 1; transition: none; }
    .awk-capa--foto { inset: 0; }
}
@media (max-width: 575.98px) {
    .awk-pasos { padding-left: 48px; }
    .awk-pasos::before { left: 18px; }
    .awk-paso { grid-template-columns: auto minmax(0, 1fr); padding: 12px 14px; }
    .awk-paso__num { left: -48px; width: 38px; height: 38px; font-size: 13px; }
    .awk-paso__icono { width: 40px; height: 40px; }
    .awk-paso__flecha, .awk-paso__caras { display: none; }
    .awk-paso:has(.awk-paso__caras) { grid-template-columns: auto minmax(0, 1fr); }
    .awk-hero__cta { display: block; margin-left: 0; text-align: center; }
    .awk-hero__escena { height: 82vw; font-size: 2.3vw; }
}

@media (prefers-reduced-motion: reduce) {
    .awk-capa, .awk-capa--foto, .awk-hero__texto { transform: none; transition: opacity .2s; }
    .awk-hero__texto { opacity: 1; }
    .awk-panel__caja, .awk-capa--luces i, .awk-panel__vivo { animation: none; }
    .awk-paso, .awk-paso__flecha { transition: none; }
}
