/* ========================================================
   🎉 JUNIOR PARTY RENTALS - ANIMACIONES GLOBALES
   ======================================================== */

/* === KEYFRAMES BASE === */

/* Entrada con rebote festivo */
@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3) translateY(50px);
    }
    50% {
        opacity: 1;
        transform: scale(1.05) translateY(-10px);
    }
    70% {
        transform: scale(0.95) translateY(5px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Entrada desde abajo */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(60px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Entrada desde izquierda */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Entrada desde derecha */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Fade in con escala */
@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Flotación suave */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-15px);
    }
}

/* Brillo pasando */
@keyframes shimmer {
    0% {
        background-position: -200% center;
    }
    100% {
        background-position: 200% center;
    }
}

/* Pulso de color */
@keyframes colorPulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.7);
    }
    50% {
        box-shadow: 0 0 0 15px rgba(255, 215, 0, 0);
    }
}

/* Sacudida divertida */
@keyframes wiggle {
    0%, 100% {
        transform: rotate(0deg);
    }
    25% {
        transform: rotate(-5deg);
    }
    75% {
        transform: rotate(5deg);
    }
}

/* Balanceo suave */
@keyframes swing {
    0%, 100% {
        transform: rotate(0deg);
    }
    20% {
        transform: rotate(8deg);
    }
    40% {
        transform: rotate(-6deg);
    }
    60% {
        transform: rotate(4deg);
    }
    80% {
        transform: rotate(-2deg);
    }
}

/* Zoom in suave */
@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Rotación 3D */
@keyframes flip3D {
    from {
        opacity: 0;
        transform: perspective(400px) rotateY(90deg);
    }
    to {
        opacity: 1;
        transform: perspective(400px) rotateY(0);
    }
}

/* Confeti cayendo */
@keyframes confettiFall {
    0% {
        transform: translateY(-100%) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

/* Globo flotando */
@keyframes balloonFloat {
    0%, 100% {
        transform: translateY(0) rotate(-2deg);
    }
    25% {
        transform: translateY(-20px) rotate(2deg);
    }
    50% {
        transform: translateY(-10px) rotate(-1deg);
    }
    75% {
        transform: translateY(-25px) rotate(1deg);
    }
}

/* Estrella brillando */
@keyframes starTwinkle {
    0%, 100% {
        opacity: 0.5;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.3);
    }
}

/* Onda de agua */
@keyframes wave {
    0% {
        transform: translateX(0) translateY(0);
    }
    25% {
        transform: translateX(-5px) translateY(-10px);
    }
    50% {
        transform: translateX(0) translateY(-15px);
    }
    75% {
        transform: translateX(5px) translateY(-10px);
    }
    100% {
        transform: translateX(0) translateY(0);
    }
}

/* Rebote suave */
@keyframes gentleBounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-12px);
    }
    60% {
        transform: translateY(-6px);
    }
}

/* Parpadeo suave */
@keyframes softBlink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.6;
    }
}

/* Rotación continua */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Latido de corazón */
@keyframes heartbeat {
    0%, 100% {
        transform: scale(1);
    }
    14% {
        transform: scale(1.15);
    }
    28% {
        transform: scale(1);
    }
    42% {
        transform: scale(1.15);
    }
    70% {
        transform: scale(1);
    }
}

/* Pop elástico */
@keyframes elasticPop {
    0% {
        transform: scale(0);
    }
    55% {
        transform: scale(1.1);
    }
    75% {
        transform: scale(0.95);
    }
    100% {
        transform: scale(1);
    }
}

/* === CLASES DE ANIMACIÓN === */

/* Entrada con rebote */
.animate-bounce-in {
    animation: bounceIn 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

/* Entrada desde abajo */
.animate-slide-up {
    animation: slideInUp 0.6s ease-out forwards;
}

/* Entrada desde izquierda */
.animate-slide-left {
    animation: slideInLeft 0.6s ease-out forwards;
}

/* Entrada desde derecha */
.animate-slide-right {
    animation: slideInRight 0.6s ease-out forwards;
}

/* Fade con escala */
.animate-fade-scale {
    animation: fadeInScale 0.5s ease-out forwards;
}

/* Flotación continua */
.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* Brillo pasando */
.animate-shimmer {
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.4) 50%,
        transparent 100%
    );
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

/* Pulso de atención */
.animate-pulse-attention {
    animation: colorPulse 2s infinite;
}

/* Wiggle divertido */
.animate-wiggle {
    animation: wiggle 0.5s ease-in-out;
}

/* Wiggle infinito (hover) */
.animate-wiggle-infinite {
    animation: wiggle 0.8s ease-in-out infinite;
}

/* Balanceo */
.animate-swing {
    animation: swing 1s ease-in-out;
}

/* Zoom in */
.animate-zoom {
    animation: zoomIn 0.5s ease-out forwards;
}

/* Flip 3D */
.animate-flip {
    animation: flip3D 0.6s ease-out forwards;
}

/* Globo flotando */
.animate-balloon {
    animation: balloonFloat 4s ease-in-out infinite;
}

/* Estrella brillando */
.animate-star {
    animation: starTwinkle 1.5s ease-in-out infinite;
}

/* Onda */
.animate-wave {
    animation: wave 2s ease-in-out infinite;
}

/* Rebote suave */
.animate-gentle-bounce {
    animation: gentleBounce 2s ease-in-out infinite;
}

/* Latido */
.animate-heartbeat {
    animation: heartbeat 1.5s ease-in-out infinite;
}

/* Pop elástico */
.animate-elastic {
    animation: elasticPop 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55) forwards;
}

/* Rotación */
.animate-spin {
    animation: spin 1s linear infinite;
}

/* === DELAYS PARA ANIMACIONES ESCALONADAS === */

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }
.delay-600 { animation-delay: 0.6s; }
.delay-700 { animation-delay: 0.7s; }
.delay-800 { animation-delay: 0.8s; }
.delay-900 { animation-delay: 0.9s; }
.delay-1000 { animation-delay: 1s; }

/* === TRANSICIONES SUAVES === */

.transition-fast {
    transition: all 0.15s ease;
}

.transition-normal {
    transition: all 0.3s ease;
}

.transition-slow {
    transition: all 0.5s ease;
}

.transition-bounce {
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* === EFECTOS HOVER === */

/* Levantamiento con sombra */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Escala suave */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

/* Escala con rebote */
.hover-scale-bounce {
    transition: transform 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.hover-scale-bounce:hover {
    transform: scale(1.08);
}

/* Brillo en hover */
.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
}

/* Rotación suave */
.hover-rotate {
    transition: transform 0.4s ease;
}

.hover-rotate:hover {
    transform: rotate(5deg);
}

/* Shake en hover */
.hover-shake:hover {
    animation: wiggle 0.5s ease-in-out;
}

/* === PARTÍCULAS DECORATIVAS === */

/* Contenedor de confeti */
.confetti-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    overflow: hidden;
}

.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    top: -10px;
    animation: confettiFall 3s linear forwards;
}

.confetti:nth-child(odd) {
    background: var(--amarillo, #FFD700);
    border-radius: 50%;
}

.confetti:nth-child(even) {
    background: var(--azul-electrico, #144388);
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
}

/* Estrellas decorativas */
.star-decoration {
    position: absolute;
    color: var(--amarillo, #FFD700);
    animation: starTwinkle 2s ease-in-out infinite;
}

/* Globos decorativos */
.balloon-decoration {
    position: absolute;
    font-size: 2rem;
    animation: balloonFloat 4s ease-in-out infinite;
}

/* === TEXTOS ANIMADOS === */

/* Texto con gradiente animado */
.text-gradient-animate {
    background: linear-gradient(
        90deg,
        var(--azul-electrico, #144388),
        var(--amarillo, #FFD700),
        var(--azul-electrico, #144388)
    );
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shimmer 3s linear infinite;
}

/* Texto que aparece letra por letra */
.text-typing {
    overflow: hidden;
    border-right: 3px solid var(--amarillo, #FFD700);
    white-space: nowrap;
    animation: typing 3s steps(40, end), blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: var(--amarillo, #FFD700); }
}

/* === BOTONES ANIMADOS === */

/* Botón con efecto ripple */
.btn-ripple {
    position: relative;
    overflow: hidden;
}

.btn-ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-ripple:active::after {
    width: 300px;
    height: 300px;
}

/* Botón con brillo pasando */
.btn-shine {
    position: relative;
    overflow: hidden;
}

.btn-shine::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: left 0.5s ease;
}

.btn-shine:hover::before {
    left: 100%;
}

/* === TARJETAS ANIMADAS === */

/* Tarjeta con efecto 3D en hover */
.card-3d {
    transition: transform 0.3s ease;
    transform-style: preserve-3d;
}

.card-3d:hover {
    transform: perspective(1000px) rotateY(5deg) rotateX(-5deg);
}

/* Tarjeta con borde animado */
.card-border-animate {
    position: relative;
}

.card-border-animate::before {
    content: '';
    position: absolute;
    inset: -3px;
    background: linear-gradient(
        90deg,
        var(--amarillo, #FFD700),
        var(--azul-electrico, #144388),
        var(--amarillo, #FFD700)
    );
    background-size: 200% 100%;
    border-radius: inherit;
    z-index: -1;
    animation: shimmer 3s linear infinite;
}

/* === LOADERS FESTIVOS === */

/* Loader de globos */
.loader-balloons {
    display: flex;
    gap: 0.5rem;
}

.loader-balloons span {
    display: inline-block;
    width: 15px;
    height: 20px;
    background: var(--amarillo, #FFD700);
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    animation: balloonFloat 1s ease-in-out infinite;
}

.loader-balloons span:nth-child(2) {
    background: var(--azul-electrico, #144388);
    animation-delay: 0.2s;
}

.loader-balloons span:nth-child(3) {
    background: #FF6B6B;
    animation-delay: 0.4s;
}

/* Loader de estrellas */
.loader-stars {
    display: flex;
    gap: 0.3rem;
}

.loader-stars span {
    display: inline-block;
    font-size: 1.5rem;
    animation: starTwinkle 1s ease-in-out infinite;
}

.loader-stars span:nth-child(2) {
    animation-delay: 0.3s;
}

.loader-stars span:nth-child(3) {
    animation-delay: 0.6s;
}

/* === SCROLL ANIMATIONS (requiere JS) === */

/* Elementos que aparecen al hacer scroll */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-scale.active {
    opacity: 1;
    transform: scale(1);
}

/* === MEDIA QUERIES === */

/* Reducir animaciones si el usuario lo prefiere */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Ajustes para móvil */
@media (max-width: 768px) {
    .animate-float {
        animation: float 4s ease-in-out infinite;
    }
    
    .hover-lift:hover {
        transform: translateY(-4px);
    }
}








