/* =====================================================================
   PÁGINAS CON PROPÓSITO — capa premium (se carga después de styles.css)
   ===================================================================== */

/* ---------- 1. Cursor propio (solo mouse) ---------- */
.cur { position: fixed; left: 0; top: 0; z-index: 9999; pointer-events: none; transition: opacity .25s; }
.cur.is-off, .cur.is-text, html:not(.has-cur) .cur { opacity: 0; }
.cur__dot { position: fixed; left: -4px; top: -4px; width: 8px; height: 8px; border-radius: 50%; background: var(--acc); box-shadow: 0 0 0 1.5px rgb(var(--bg-rgb) / .7); }
.cur__ring { position: fixed; left: -20px; top: -20px; width: 40px; height: 40px; }
.cur__ring::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid rgb(var(--ink-rgb) / .55); transition: transform .4s var(--ease), background-color .3s, border-color .3s; }
.cur.is-link .cur__ring::before { transform: scale(1.55); border-color: rgb(var(--acc-rgb) / .85); background: rgb(var(--acc-rgb) / .1); }
.cur.is-label .cur__ring::before { transform: scale(2.5); border-color: var(--acc); background: var(--acc); }
.cur.is-down .cur__ring::before { transform: scale(.8); }
.cur.is-label.is-down .cur__ring::before { transform: scale(2.2); }
.cur__lbl { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(.5); opacity: 0; white-space: nowrap; font-size: .7rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--on-acc); transition: opacity .25s, transform .4s var(--ease); }
.cur.is-label .cur__lbl { opacity: 1; transform: translate(-50%, -50%); }
.cur.is-label .cur__dot { opacity: 0; }
html.has-cur, html.has-cur * { cursor: none !important; }
html.has-cur :is(input[type="text"], input[type="search"], input[type="email"], input:not([type]), textarea) { cursor: text !important; }
html.has-cur dialog[open], html.has-cur dialog[open] * { cursor: auto !important; }
html.has-cur dialog[open] :is(a, button, [role="option"], summary) { cursor: pointer !important; }
html.has-cur dialog[open] input[type="text"] { cursor: text !important; }
.has-cur .card__img::after { display: none; } /* la etiqueta ahora la lleva el cursor */

/* ---------- 3. Barra de avance y navegación flotante ---------- */
.prog { position: fixed; left: 0; right: 0; top: 0; z-index: 60; height: 2px; pointer-events: none; }
.prog i { display: block; height: 100%; transform-origin: 0 50%; transform: scaleX(0); background: linear-gradient(90deg, var(--acc2), var(--acc) 60%, var(--pos)); box-shadow: 0 0 12px rgb(var(--acc-rgb) / .55); }

.nav { transition: transform .5s var(--ease), background-color .35s, border-color .35s, box-shadow .35s; }
.nav.is-tucked { transform: translateY(calc(-100% - 16px)); }
/* Sin desenfoque detrás del menú ni de los botones del inicio: era lo que más pesaba al hacer scroll */
.nav.is-scrolled { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgb(var(--bg-rgb) / .95); }
.btn--glass, .slides__arrow { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
.btn--glass { background: rgb(var(--deep-rgb) / .55); }
.slides__arrow { background: rgb(var(--deep-rgb) / .6); }
.nav__in { border: 1px solid transparent; border-radius: 999px; transition: height .45s var(--ease), margin .45s var(--ease), padding .45s var(--ease), background-color .45s, border-color .45s, box-shadow .45s; }
@media (min-width: 761px) {
  .nav.is-scrolled { background: transparent; border-bottom-color: transparent; box-shadow: none; }
  .nav.is-scrolled .nav__in { height: 60px; margin-top: 10px; padding: 0 8px 0 20px; background: rgb(var(--surface-rgb) / .95); border-color: var(--line-2); box-shadow: 0 22px 50px -22px rgba(0, 0, 0, .8), inset 0 1px 0 rgba(255, 255, 255, .05); }
}

/* Botón Buscar */
.nav__search { display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 8px 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, .04); color: var(--text); font-weight: 600; font-size: .88rem; transition: border-color .2s, background-color .2s, color .2s; }
.nav__search[hidden] { display: none; }
.nav__search:hover { border-color: rgb(var(--acc-rgb) / .6); color: var(--ink); background: rgb(var(--acc-rgb) / .07); }
.nav__search .ico { width: 18px; height: 18px; color: var(--acc); }
.nav__search kbd { padding: 4px 7px; border-radius: 7px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .25); color: var(--mute); font: 700 .68rem/1 var(--body); }
@media (max-width: 1280px) { .nav__search span, .nav__search kbd { display: none; } .nav__search { width: 42px; padding: 0; justify-content: center; } }
@media (max-width: 1060px) { .nav__search { width: 44px; height: 44px; border-radius: 12px; } }

/* ---------- 4. Hora de Guatemala en el inicio ---------- */
.live { position: absolute; z-index: 6; top: calc(var(--nav-h) + 18px); right: max(16px, calc((100% - 1200px) / 2)); margin: 0; display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .18); background: rgb(var(--bg-rgb) / .72); color: rgba(255, 255, 255, .8); font-size: .76rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.live i { width: 8px; height: 8px; border-radius: 50%; background: var(--pos); animation: livePulse 2.2s ease-out infinite; }
.live b { color: #fff; font-weight: 800; letter-spacing: .02em; text-transform: none; font-variant-numeric: tabular-nums; }
@keyframes livePulse { 0% { box-shadow: 0 0 0 0 rgb(var(--pos-rgb) / .6); } 80%, 100% { box-shadow: 0 0 0 10px rgb(var(--pos-rgb) / 0); } }
@media (max-width: 760px) { .live { display: none; } }

/* ---------- 5. Números grandes de sección ---------- */
.ghost { position: absolute; z-index: -1; top: clamp(10px, 3vw, 40px); right: max(4px, calc((100% - 1260px) / 2)); font-family: var(--display); font-weight: 400; font-size: clamp(7rem, 21vw, 18rem); line-height: .8; letter-spacing: -.05em; color: transparent; -webkit-text-stroke: 1px rgb(var(--tint-rgb) / .12); pointer-events: none; user-select: none; }
html[data-tone="oro"] .ghost { -webkit-text-stroke-color: rgb(var(--acc-rgb) / .15); }
html[data-tone="menta"] .ghost { -webkit-text-stroke-color: rgb(var(--pos-rgb) / .13); }
@media (max-width: 640px) { .ghost { font-size: 9rem; top: 6px; right: 6px; -webkit-text-stroke-width: .8px; } }

/* ---------- 7. Proceso: tarjetas apiladas ---------- */
.steps.is-stack { gap: clamp(28px, 7vh, 70px); max-width: 1000px; margin-inline: auto; padding-bottom: 2vh; }
.steps.is-stack::before, .steps.is-stack::after { display: none; }
.steps.is-stack .step {
  position: sticky; top: calc(var(--nav-h) + 28px + var(--i, 0) * 16px);
  grid-template-columns: clamp(64px, 9vw, 120px) 1fr; gap: clamp(18px, 3.4vw, 40px); align-items: center;
  min-height: clamp(220px, 30vh, 300px); padding: clamp(26px, 4.5vw, 54px);
  border-radius: 30px; border: 1px solid var(--line-2);
  background: radial-gradient(120% 120% at 0% 0%, rgb(var(--acc2-rgb) / .16), transparent 50%), linear-gradient(160deg, var(--surface), var(--bg-2) 70%);
  box-shadow: 0 -24px 60px -34px rgba(0, 0, 0, .9), 0 30px 80px -40px rgba(0, 0, 0, .8);
  overflow: hidden; transform-origin: 50% 0;
  scale: calc(1 - var(--sp, 0) * .07);
}
.steps.is-stack .step:nth-child(2) { background: radial-gradient(120% 120% at 100% 0%, rgb(var(--pos-rgb) / .14), transparent 50%), linear-gradient(160deg, var(--surface), var(--bg-2) 70%); }
.steps.is-stack .step:nth-child(3) { background: radial-gradient(120% 120% at 0% 100%, rgb(var(--acc-rgb) / .15), transparent 50%), linear-gradient(160deg, var(--surface), var(--bg-2) 70%); }
.steps.is-stack .step:nth-child(4) { background: radial-gradient(120% 120% at 100% 100%, rgb(var(--acc2-rgb) / .2), transparent 55%), linear-gradient(160deg, var(--surface), var(--bg-2) 70%); }
.steps.is-stack .step::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: var(--deep); opacity: calc(var(--sp, 0) * .55); pointer-events: none; }
.steps.is-stack .step::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--acc2), var(--acc), var(--pos)); opacity: .8; }
.steps.is-stack .step__n,
.steps.is-stack .step.is-lit .step__n { width: auto; height: auto; border: 0; border-radius: 0; background: none; box-shadow: none; font-size: clamp(4.2rem, 10vw, 8.5rem); line-height: .8; letter-spacing: -.04em; color: transparent; -webkit-text-stroke: 1.5px rgb(var(--acc-rgb) / .75); }
.steps.is-stack .step.is-lit .step__n { -webkit-text-stroke-color: var(--pos); }
.steps.is-stack .step__t { font-size: clamp(1.7rem, 3.2vw, 2.6rem); line-height: 1.1; margin-top: 0; }
.steps.is-stack .step__d { font-size: clamp(1rem, 1.3vw, 1.12rem); }
@media (max-width: 640px) {
  .steps.is-stack .step { grid-template-columns: 1fr; gap: 10px; min-height: 0; top: calc(var(--nav-h) + 12px + var(--i, 0) * 12px); border-radius: 24px; }
  .steps.is-stack .step__n, .steps.is-stack .step.is-lit .step__n { font-size: 3.6rem; }
}

/* ---------- 8. Muro de demostraciones ---------- */
.work__bar { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px 24px; margin-bottom: 26px; }
.work__bar .filters { margin-bottom: 0; }
.work__views[hidden] { display: none; }
.work__views button .ico { width: 16px; height: 16px; }
#proyectos.is-wall [data-work], #proyectos.is-wall .work__more, #proyectos.is-wall .swipe-hint { display: none !important; }

.wall { position: relative; width: 100vw; margin-left: calc(50% - 50vw); }
.wall[hidden] { display: none; }
/* Sin máscaras ni 3D: los bordes se funden con dos degradados fijos (mucho más liviano) */
.wall__view {
  position: relative; height: min(74svh, 700px); overflow: hidden; contain: layout paint;
  touch-action: pan-y; user-select: none; -webkit-user-select: none; outline: none;
}
.wall__view::before, .wall__view::after { content: ""; position: absolute; z-index: 2; top: 0; bottom: 0; width: 7%; pointer-events: none; }
.wall__view::before { left: 0; background: linear-gradient(90deg, var(--bg), transparent); }
.wall__view::after { right: 0; background: linear-gradient(270deg, var(--bg), transparent); }
.wall__plane { position: absolute; inset: 0; }
.wall__plane::before, .wall__plane::after { content: ""; position: absolute; z-index: 2; left: 0; right: 0; height: 9%; pointer-events: none; }
.wall__plane::before { top: 0; background: linear-gradient(180deg, var(--bg), transparent); }
.wall__plane::after { bottom: 0; background: linear-gradient(0deg, var(--bg), transparent); }
.wall.is-touch .wall__plane::before, .wall.is-touch .wall__plane::after { display: none; }
.tile { position: absolute; left: 0; top: 0; width: var(--tw, 280px); display: block; text-decoration: none; color: inherit; will-change: transform; -webkit-user-drag: none; -webkit-tap-highlight-color: transparent; }
.tile__card { display: block; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: var(--surface); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .85); transition: transform .55s var(--ease), border-color .3s, box-shadow .45s var(--ease), opacity .45s, filter .45s; }
.tile:hover .tile__card, .tile:focus-visible .tile__card { transform: translateY(-8px) scale(1.045); border-color: rgb(var(--acc-rgb) / .6); box-shadow: 0 40px 70px -30px rgba(0, 0, 0, .9), 0 0 60px -18px rgb(var(--acc2-rgb) / .65); }
.tile:focus-visible { outline: none; }
.tile:focus-visible .tile__card { outline: 2px solid var(--acc); outline-offset: 3px; }
.tile__img { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-2); }
.tile__img img { width: 100%; height: 100%; object-fit: cover; object-position: left top; transform-origin: 0 0; transform: scale(1.06); transition: transform .8s var(--ease); pointer-events: none; }
.tile:hover .tile__img img { transform: scale(1.13); }
.tile__meta { display: grid; gap: 2px; padding: 10px 14px 12px; }
.tile__tag { font-size: .6rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--acc); }
.tile__t { font-family: var(--display); font-size: 1.06rem; line-height: 1.2; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile.is-dim { pointer-events: none; }
.tile.is-dim .tile__card { opacity: .13; filter: grayscale(1); }
.wall.is-drag .tile { pointer-events: none; }
.wall.is-drag .wall__plane { transition: none; }
.wall__hint { position: absolute; left: 50%; bottom: 22px; z-index: 5; display: inline-flex; align-items: center; gap: 12px; margin: 0; padding: 10px 18px 10px 12px; border-radius: 999px; border: 1px solid var(--line-2); background: rgb(var(--bg-rgb) / .82); color: var(--ink); font-size: .86rem; font-weight: 600; white-space: nowrap; pointer-events: none; transform: translateX(-50%); transition: opacity .6s, transform .6s var(--ease); box-shadow: var(--shadow); }
.wall__drag { position: relative; width: 30px; height: 30px; border-radius: 50%; background: var(--acc); }
.wall__drag::before, .wall__drag::after { content: ""; position: absolute; top: 50%; width: 6px; height: 6px; margin-top: -3px; border: solid var(--on-acc); border-width: 0 0 2px 2px; }
.wall__drag::before { left: 7px; transform: rotate(45deg); }
.wall__drag::after { right: 7px; transform: rotate(-135deg); }
.wall__drag { animation: dragNudge 2.4s var(--ease) infinite; }
@keyframes dragNudge { 0%, 100% { transform: translateX(0); } 30% { transform: translateX(-6px); } 60% { transform: translateX(6px); } }
.wall.has-dragged .wall__hint { opacity: 0; transform: translate(-50%, 12px); }
.wall.is-touch .wall__hint { bottom: auto; top: calc(100% + 6px); position: relative; left: auto; transform: none; display: flex; width: max-content; margin: 8px auto 0; box-shadow: none; }
.wall.is-touch.has-dragged .wall__hint { opacity: .0; transform: none; }

/* ---------- 9. Visor: anterior / siguiente ---------- */
.vnav { display: inline-flex; align-items: center; gap: 6px; margin-right: 4px; }
.vnav__prev .ico { transform: rotate(180deg); }
.vnav__n { min-width: 52px; text-align: center; font-size: .82rem; font-weight: 700; color: var(--mute); font-variant-numeric: tabular-nums; }
@media (max-width: 700px) { .vnav__n { display: none; } }

/* ---------- 10. Buscador rápido ---------- */
.pal { width: min(660px, 100vw - 24px); max-height: min(580px, 100dvh - 24px); margin: 11vh auto auto; padding: 0; border-radius: 22px; border: 1px solid var(--line-2); background: rgb(var(--surface-rgb) / .97); color: var(--text); box-shadow: 0 40px 120px rgba(0, 0, 0, .7), 0 0 0 1px rgb(var(--acc2-rgb) / .14), 0 0 80px -20px rgb(var(--acc2-rgb) / .4); overflow: hidden; }
.pal[open] { display: flex; flex-direction: column; animation: palIn .32s var(--ease); }
.pal::backdrop { background: rgb(var(--deep-rgb) / .62); }
@supports (backdrop-filter: blur(4px)) { .pal::backdrop { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); } }
@keyframes palIn { from { opacity: 0; transform: translateY(-14px) scale(.98); } to { opacity: 1; transform: none; } }
.pal__in { display: flex; align-items: center; gap: 12px; padding: 14px 14px 14px 20px; border-bottom: 1px solid var(--line); }
.pal__in > .ico { width: 22px; height: 22px; color: var(--acc); }
.pal__in input { flex: 1; min-width: 0; height: 44px; border: 0; background: none; outline: none; font-size: 1.12rem; color: var(--ink); }
.pal__in input::placeholder { color: var(--mute); }
.pal__x { padding: 6px 10px; border-radius: 8px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .25); color: var(--mute); font: 700 .74rem/1 var(--body); }
.pal__x:hover { color: var(--ink); border-color: var(--acc); }
.pal__head { margin: 0; padding: 12px 20px 4px; font-size: .7rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--mute); }
.pal__list { list-style: none; margin: 0; padding: 4px 8px 10px; overflow: auto; flex: 1; overscroll-behavior: contain; }
.pal__item { display: grid; grid-template-columns: 38px 1fr auto; gap: 12px; align-items: center; padding: 9px 12px; border-radius: 13px; cursor: pointer; transition: background-color .15s; }
.pal__item[aria-selected="true"] { background: rgb(var(--acc-rgb) / .1); box-shadow: inset 0 0 0 1px rgb(var(--acc-rgb) / .35); }
.pal__ico { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: rgba(255, 255, 255, .05); color: var(--acc); }
.pal__item[aria-selected="true"] .pal__ico { background: var(--acc); color: var(--on-acc); }
.pal__txt { display: grid; min-width: 0; }
.pal__t { color: var(--ink); font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal__d { font-size: .82rem; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal__k { font-size: .62rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.pal__empty { padding: 28px 16px; text-align: center; color: var(--mute); }
.pal__empty a { color: var(--acc); font-weight: 700; }
.pal__foot { display: flex; gap: 18px; margin: 0; padding: 10px 18px; border-top: 1px solid var(--line); font-size: .76rem; color: var(--mute); }
.pal kbd { display: inline-block; min-width: 20px; margin-right: 4px; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .25); font: 700 .7rem/1.4 var(--body); text-align: center; color: var(--text); }
@media (max-width: 600px) { .pal { margin-top: 10px; } .pal__foot { display: none; } .pal__k { display: none; } }

/* ---------- 11. Firma final ---------- */
.sign { padding: clamp(10px, 3vw, 30px) 0 clamp(40px, 6vw, 70px); margin-bottom: clamp(30px, 5vw, 56px); border-bottom: 1px solid var(--line); }
.sign__k { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 18px; font-size: .78rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--acc); }
.sign__row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 28px 40px; }
.bigword { margin: 0; font-family: var(--display); font-weight: 400; font-variation-settings: "opsz" 144; font-size: clamp(3.1rem, 12.6vw, 12rem); line-height: .88; letter-spacing: -.035em; color: var(--ink); user-select: none; -webkit-user-select: none; }
.bigword > [aria-hidden] { display: block; white-space: nowrap; }
.bigword > em { font-style: italic; color: var(--acc); padding-left: .55em; }
.bw { --k: 0; display: inline-block; color: color-mix(in oklab, var(--acc) calc(var(--k) * 100%), var(--ink)); }
.bigword > em .bw { color: color-mix(in oklab, var(--acc-xl) calc(var(--k) * 100%), var(--acc)); }
.sign__side { display: grid; justify-items: start; gap: 18px; max-width: 360px; padding-bottom: 10px; }
.sign__note { margin: 0; color: var(--text); font-size: .98rem; }
.sign__cta { --mx: 0px; --my: 0px; display: grid; place-content: center; justify-items: center; gap: 6px; width: 168px; height: 168px; border-radius: 50%; text-decoration: none; text-align: center; background: linear-gradient(135deg, var(--acc-l), var(--acc) 45%, var(--acc-d)); color: var(--on-acc); font-weight: 800; font-size: 1.02rem; box-shadow: 0 24px 60px -16px rgb(var(--acc-rgb) / .55), inset 0 1px 0 rgba(255, 255, 255, .5); transform: translate3d(var(--mx), var(--my), 0); transition: transform .4s var(--ease), box-shadow .4s var(--ease); }
.sign__cta .ico { width: 26px; height: 26px; transition: transform .4s var(--ease); }
.sign__cta:hover { box-shadow: 0 30px 70px -14px rgb(var(--acc-rgb) / .75), inset 0 1px 0 rgba(255, 255, 255, .5); }
.sign__cta:hover .ico { transform: rotate(-45deg); }
@media (max-width: 760px) { .sign__cta { width: 132px; height: 132px; font-size: .92rem; } .bigword > em { padding-left: .3em; } }

/* ---------- 12. Detalles: brillo en botones dorados y fotos que se descubren ---------- */
.btn--gold { position: relative; overflow: hidden; isolation: isolate; }
.btn--gold::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .6) 48%, transparent 66%); transform: translateX(-130%); transition: transform 1s var(--ease); }
.btn--gold:hover::after { transform: translateX(130%); }
.js-ok :is(.quiz__photo, .about__photo)[data-reveal] img { clip-path: inset(0 0 100% 0); transition: clip-path 1.4s cubic-bezier(.77, 0, .18, 1) .15s, transform 1.4s var(--ease); }
.js-ok :is(.quiz__photo, .about__photo)[data-reveal].is-in img { clip-path: inset(0 0 0 0); }

/* ---------- Reducir movimiento ---------- */
@media (prefers-reduced-motion: reduce) {
  .wall__drag, .live i { animation: none; }
  .steps.is-stack .step { scale: none; }
  .btn--gold::after { display: none; }
}
