/* Intro del panel abierto como app instalada: la misma de la página (copiada de styles.css: logo, animación y
   cortina). Solo se ve con html.pwa-intro (lo pone index.html al abrir la app, una vez por apertura).
   Si se cambia la intro de la página, copiar los cambios acá */
/* Logo (el cartel del local en vector, ver .np-defs en index.html): disco negro, luz cálida atrás y todo en blanco */
.np-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.np-disc { fill: #121010; }
.np-badge { fill: #fff; }
.np-ring { fill: none; stroke: #fff; stroke-width: 21; stroke-linecap: round; stroke-dasharray: 1400; }
.np-tri { fill: none; stroke: #f5de5f; stroke-width: 21; stroke-linejoin: miter; }
.splash__slice, .bite, .crumbs circle, .np-arc { transform-box: fill-box; transform-origin: center; }
.bite { fill: #000; transform: scale(0); }
.crumbs circle { fill: #e9c54b; opacity: 0; }
@keyframes logo-in { from { opacity: 0; transform: scale(.85); } to { opacity: 1; transform: none; } }
@keyframes slice {
  0% { transform: rotate(0); }
  35% { transform: rotate(360deg); }
  75% { transform: rotate(360deg) scale(1); opacity: 1; }
  100% { transform: rotate(360deg) scale(.6); opacity: 0; }
}
@keyframes bite { from { transform: scale(0); } to { transform: scale(1); } }
@keyframes crumb-a { 0% { opacity: 0; transform: none; } 1% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translate(-120px, 140px); } }
@keyframes crumb-b { 0% { opacity: 0; transform: none; } 1% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translate(105px, 160px); } }
@keyframes crumb-c { 0% { opacity: 0; transform: none; } 1% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translate(14px, 200px); } }
/* el cartel se prende como un tubo de luz: un par de parpadeos y queda fijo */
@keyframes sign-on { 0% { opacity: 0; } 8% { opacity: .85; } 12% { opacity: .1; } 20% { opacity: .95; } 24% { opacity: .25; } 34%, 100% { opacity: 1; } }
@keyframes ring-draw { from { stroke-dashoffset: 1400; } to { stroke-dashoffset: 0; } }
@keyframes arc-in { from { opacity: 0; transform: scale(.92); } to { opacity: 1; transform: none; } }
@keyframes word-out { to { opacity: 0; transform: translateY(-6px); } }
html.is-loading, html.is-loading body { overflow: hidden; }
.loader {
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  background: #0b0908;
  animation: loaderOpen .8s cubic-bezier(.76, 0, .24, 1) 3.55s forwards;
}
.loader__inner { display: flex; flex-direction: column; align-items: center; gap: clamp(30px, 4vw, 44px); }
.loader__mask { overflow: hidden; padding: 0 6px; }
/* Misma animación que la intro del celular de Redes (mismos tiempos, arrancando 2 s antes) */
.loader__logo { display: block; width: clamp(210px, 28vw, 330px); height: auto; overflow: visible; animation: logo-in .6s cubic-bezier(.2, .8, .2, 1) .1s both, word-out .4s ease 3.25s forwards; }
.loader .np-halo { animation: sign-on 1.2s linear .15s both; }
.loader .np-ring { animation: ring-draw 1s cubic-bezier(.65, 0, .35, 1) .3s both; }
.loader .np-arc--top { animation: arc-in .6s cubic-bezier(.2, .8, .2, 1) .65s both; }
.loader .np-arc--bot { animation: arc-in .6s cubic-bezier(.2, .8, .2, 1) .8s both; }
.loader .bite { animation: bite .22s cubic-bezier(.2, 1.5, .4, 1) both; }
.loader .splash__slice { animation: slice 3.4s cubic-bezier(.65, 0, .35, 1) .5s both; }
.loader .bite--1 { animation-delay: 1.9s; }
.loader .bite--1b { animation-delay: 1.98s; }
.loader .bite--2 { animation-delay: 2.3s; }
.loader .bite--2b { animation-delay: 2.38s; }
.loader .bite--3 { animation-delay: 2.7s; }
.loader .bite--3b { animation-delay: 2.78s; }
.loader .crumbs circle { animation: crumb-a .7s cubic-bezier(.2, .7, .4, 1) both; }
.loader .crumbs circle:nth-child(3n+2) { animation-name: crumb-b; }
.loader .crumbs circle:nth-child(3n) { animation-name: crumb-c; }
.loader .crumbs circle:nth-child(-n+3) { animation-delay: 1.92s; }
.loader .crumbs circle:nth-child(n+4):nth-child(-n+6) { animation-delay: 2.32s; }
.loader .crumbs circle:nth-child(n+7) { animation-delay: 2.72s; }
/* La frase sube desde abajo y se va junto con el nombre */
.loader__tag {
  display: block;
  font-family: "Barlow", var(--sans);
  font-weight: 600;
  font-size: clamp(11px, 3.2vw, 13px);
  letter-spacing: .32em;
  white-space: nowrap;
  color: rgba(255, 255, 255, .7);
  animation: loaderRise .8s cubic-bezier(.2, .8, .2, 1) .7s both, word-out .4s ease 3.25s forwards;
}
@keyframes loaderRise { from { transform: translateY(110%); } to { transform: none; } }
@keyframes loaderOpen { to { transform: translateY(-100%); visibility: hidden; } }

@media (prefers-reduced-motion: reduce) {
  .loader, .loader * { animation-duration: .01s !important; animation-delay: 0s !important; }
  .loader { animation: loaderFade .3s ease .4s forwards !important; }
  @keyframes loaderFade { to { opacity: 0; visibility: hidden; } }
}
html.pwa-intro .loader { display: flex; }

/* Abierta como app instalada, Android muestra antes su pantalla de inicio con el ícono (el logo blanco sobre negro).
   La intro arranca desde ese mismo logo, ya dibujado, del mismo tamaño y centrado, y solo se le prende la luz:
   así se ve un solo logo que se enciende, sin que se apague y vuelva a aparecer (igual en styles.css con html.app-launch) */
html.pwa-intro .loader__inner { position: relative; }
html.pwa-intro .loader__mask { position: absolute; top: 100%; left: 50%; margin-top: clamp(30px, 4vw, 44px); transform: translateX(-50%); }
html.pwa-intro .loader__logo { animation: word-out .4s ease 3.25s forwards; }
html.pwa-intro .loader .np-ring, html.pwa-intro .loader .np-arc { animation: none; }
html.pwa-intro .loader .np-disc { animation: sign-on 1.2s linear .15s both; }
@media (pointer: coarse) { html.pwa-intro .loader__logo { width: 220px; } }
