/* hecho por r3k1 */
*, *::before, *::after { box-sizing: border-box; }

html {
  height: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overscroll-behavior: none;
  background: var(--fondo);
}

body {
  height: 100%;
  margin: 0;
  overflow: hidden;
  overscroll-behavior: none;
  background: var(--fondo);
  color: var(--texto);
  font-family: var(--f-ui);
  font-weight: var(--peso-ui);
  font-size: var(--t-m);
  line-height: var(--interlineado);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }

button {
  font: inherit;
  color: inherit;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

button:disabled, [aria-disabled="true"] { cursor: default; }

img, canvas, video { display: block; max-width: 100%; }

:where(svg:not([width])) { width: 1.5em; height: 1.5em; }
svg { flex: none; }

:focus { outline: none; }
:focus-visible { outline: 3px solid var(--acento); outline-offset: 3px; border-radius: 12px; }

.sr {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.ico { display: block; width: var(--ico, 28px); height: var(--ico, 28px); }
.pj:not(svg *) { display: block; width: var(--pj, 120px); height: auto; aspect-ratio: 224 / 250; }
.pj[data-pose="asoma"] { aspect-ratio: 224 / 218; }
.pj-melody[viewBox^="-9 -4 218"] { aspect-ratio: 218 / 208; }
.pj-kitty[viewBox^="-11 12 222"] { aspect-ratio: 222 / 182; }
.pj-kuromi[viewBox^="-12 2 224"] { aspect-ratio: 224 / 204; }
.rotulo { display: block; height: var(--alto-rotulo, 34px); width: auto; max-width: 100%; overflow: visible; }
.logo { display: block; width: 100%; height: auto; aspect-ratio: 370 / 216; overflow: visible; }
.decor:not(svg *) { display: block; width: var(--decor, 48px); height: auto; aspect-ratio: 1; }
.decor.nube { aspect-ratio: 2; }
.decor.mariposa { aspect-ratio: 64 / 54; }
.decor.lazo { aspect-ratio: 5 / 3; }
.decor.caja-musica { width: var(--decor, 320px); aspect-ratio: 400 / 250; }
.decor.marco-foto { width: var(--decor, 96px); aspect-ratio: 112 / 124; }
.fondo-mundo { display: block; width: 100%; height: 100%; }

.titulo { font-family: var(--f-titulo); font-weight: 400; color: var(--texto-titulo); font-size: var(--t-xl); line-height: 1.2; letter-spacing: .01em; word-spacing: .12em; }
.cifra { font-family: var(--f-titulo); font-weight: 400; font-variant-numeric: tabular-nums; }
.texto-mano { font-family: var(--f-mano); font-weight: 700; font-size: var(--t-mano-m); line-height: 1.1; color: var(--acento-texto); display: inline-block; rotate: -3deg; }
.texto-suave { color: var(--texto-suave); }
.enfasis { font-weight: var(--peso-ui-fuerte); }

.contenido {
  width: 100%;
  max-width: var(--ancho-max);
  margin-inline: auto;
  padding-inline: max(var(--margen-lateral), var(--seguro-izq)) max(var(--margen-lateral), var(--seguro-der));
}

.desplazable {
  position: absolute;
  inset: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-top: var(--hueco-arriba, 0px);
  padding-bottom: calc(var(--hueco-abajo, 0px) + 16px);
  scrollbar-width: none;
}
.desplazable::-webkit-scrollbar { display: none; }

.boton-caramelo {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 60px;
  padding: 0 30px;
  border-radius: var(--r-pastilla);
  background:
    repeating-linear-gradient(115deg, rgba(255, 255, 255, .12) 0 12px, rgba(255, 255, 255, 0) 12px 26px),
    linear-gradient(180deg, #ff8db5 0%, #e8508a 30%, #d93a74 60%, #c42a62 100%);
  box-shadow: var(--sombra-boton), var(--brillo-interior);
  color: #fff;
  font-family: var(--f-titulo);
  font-size: var(--t-l);
  line-height: 1.1;
  word-spacing: .14em;
  text-shadow: 0 2px 0 rgba(111, 35, 80, .38);
  overflow: hidden;
  white-space: nowrap;
  transition: translate var(--d-rapida) var(--c-muelle), box-shadow var(--d-rapida) ease;
}
.boton-caramelo::before {
  content: '';
  position: absolute;
  z-index: -1;
  left: 9%; right: 9%; top: 4px;
  height: 42%;
  border-radius: var(--r-pastilla);
  background: linear-gradient(180deg, rgba(255, 255, 255, .85), rgba(255, 255, 255, .1));
  pointer-events: none;
}
.boton-caramelo::after {
  content: '';
  position: absolute;
  top: -10%; bottom: -10%;
  left: 0;
  width: 34%;
  background: linear-gradient(100deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, .55), rgba(255, 255, 255, 0));
  transform: translateX(-140%) skewX(-18deg);
  animation: barrido-caramelo 3.4s var(--c-entrar-salir) infinite;
  pointer-events: none;
}
.boton-caramelo .ico { --ico: 30px; }
.boton-caramelo.grande { min-height: 72px; font-size: var(--t-xl); padding: 0 38px; }
.boton-caramelo:active, .boton-secundario:active, .boton-redondo:active {
  translate: 0 3px;
  box-shadow: var(--sombra-boton-pulsado), var(--brillo-interior);
  transition-duration: 60ms;
}
.boton-caramelo:disabled { filter: saturate(.35); opacity: .7; }
.boton-caramelo:disabled::after { animation: none; }

@keyframes barrido-caramelo {
  0%, 62% { transform: translateX(-140%) skewX(-18deg); }
  100% { transform: translateX(420%) skewX(-18deg); }
}

.boton-secundario {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: var(--r-pastilla);
  background: var(--superficie);
  color: var(--texto);
  font-weight: var(--peso-ui-fuerte);
  font-size: var(--t-m);
  box-shadow: var(--sombra-boton), var(--brillo-interior);
  white-space: nowrap;
  transition: translate var(--d-rapida) var(--c-muelle), box-shadow var(--d-rapida) ease;
}
.boton-secundario .ico { --ico: 26px; }

.boton-redondo {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 28%, #fff 0 30%, #ffe6f0 60%, #ffc9dd 100%);
  box-shadow: var(--sombra-boton);
  transition: translate var(--d-rapida) var(--c-muelle), box-shadow var(--d-rapida) ease;
  flex: none;
}
.boton-redondo .ico { --ico: 30px; }
.boton-redondo.pequeno { width: 44px; height: 44px; }
.boton-redondo.pequeno .ico { --ico: 26px; }

.tarjeta {
  position: relative;
  background: var(--superficie);
  border-radius: var(--r-xl);
  box-shadow: var(--sombra-tarjeta);
  padding: 18px;
}
.tarjeta.sobre-escena { box-shadow: var(--sombra-tarjeta), inset 0 0 0 3px #fff; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 0 12px;
  border-radius: var(--r-pastilla);
  background: var(--superficie-2);
  box-shadow: 0 0 0 2px var(--linea-suave);
  font-weight: var(--peso-ui-fuerte);
  font-size: var(--t-xs);
  color: var(--texto-suave);
}

.bocadillo {
  position: relative;
  display: inline-block;
  max-width: 100%;
  padding: 10px 18px 12px;
  background: #fff;
  border: 2.5px solid var(--trazo);
  border-radius: 24px;
  box-shadow: 0 4px 0 rgba(111, 35, 80, .16), 0 10px 18px rgba(111, 35, 80, .14);
  color: var(--ciruela);
  font-family: var(--f-mano);
  font-weight: 700;
  font-size: var(--t-mano-m);
  line-height: 1.1;
  text-align: center;
  text-wrap: balance;
}
.bocadillo > span { display: inline-block; rotate: -2deg; }
.bocadillo::after {
  content: '';
  position: absolute;
  left: calc(var(--cola-x, 50%) - 9px);
  bottom: -10.5px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-right: 2.5px solid var(--trazo);
  border-bottom: 2.5px solid var(--trazo);
  border-bottom-right-radius: 4px;
  transform: rotate(45deg) skew(8deg, 8deg);
}
.bocadillo.cola-arriba::after { bottom: auto; top: -10.5px; transform: rotate(-135deg) skew(8deg, 8deg); }

.entra {
  animation: entra var(--d-entrada) var(--c-muelle) both;
  animation-delay: calc(min(var(--i, 0), 8) * var(--escalonado));
}
@keyframes entra {
  from { opacity: 0; transform: translateY(var(--desplazamiento-entrada)) scale(.9); }
  to { opacity: 1; transform: none; }
}

:root[data-reducir-movimiento] .boton-caramelo::after { animation: none; opacity: 0; }
:root[data-reducir-movimiento] .entra { animation: aparece 200ms var(--c-salir) both; animation-delay: 0ms; }
:root[data-reducir-movimiento] .boton-caramelo:active,
:root[data-reducir-movimiento] .boton-secundario:active,
:root[data-reducir-movimiento] .boton-redondo:active { translate: none; }
@media (prefers-reduced-motion: reduce) {
  .boton-caramelo::after { animation: none; opacity: 0; }
  .entra { animation: aparece 200ms var(--c-salir) both; animation-delay: 0ms; }
}
@keyframes aparece { from { opacity: 0; } to { opacity: 1; } }
