/* ═══════════════════════════════════════════════════════════════
   EFFECTS.CSS - EFECTOS ESPECIALES PREMIUM
   Partículas, glassmorphism, animaciones avanzadas, pétalos
   ═══════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════
   PARTÍCULAS FLOTANTES — Pétalos y destellos
   ═══════════════════════════════════════════════════════════════ */
.particle {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: particleFloat 18s infinite linear;
  opacity: 0;
}

/* Partículas tipo pétalo */
.particle:nth-child(3n) {
  width: 10px;
  height: 10px;
  background: var(--rose-soft);
  border-radius: 50% 0 50% 50%;
  transform: rotate(45deg);
}

.particle:nth-child(3n+1) {
  width: 8px;
  height: 8px;
  background: var(--gold);
  box-shadow: 0 0 8px var(--glow);
}

.particle:nth-child(3n+2) {
  width: 6px;
  height: 6px;
  background: var(--rose-petal);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-30deg);
}

.particle:nth-child(5n) {
  width: 12px;
  height: 12px;
  background: var(--gold-light);
  opacity: 0;
  box-shadow: 0 0 10px var(--gold-light);
}

@keyframes particleFloat {
  0% {
    opacity: 0;
    transform: translateY(100vh) rotate(0deg);
  }
  10% {
    opacity: 0.8;
  }
  50% {
    transform: translateY(50vh) rotate(180deg);
  }
  90% {
    opacity: 0.8;
  }
  100% {
    opacity: 0;
    transform: translateY(-100px) rotate(360deg);
  }
}

/* ═══════════════════════════════════════════════════════════════
   GLASSMORPHISM — Tarjetas de cristal
   ═══════════════════════════════════════════════════════════════ */
.glass {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 24px;
  box-shadow: 0 8px 32px rgba(155, 62, 107, 0.08);
}

/* ═══════════════════════════════════════════════════════════════
   SCROLL REVEAL ANIMATIONS — Entradas elegantes
   ═══════════════════════════════════════════════════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.9s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.reveal-left {
  opacity: 0;
  transform: translateX(-60px);
  transition: all 0.9s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.reveal-right {
  opacity: 0;
  transform: translateX(60px);
  transition: all 0.9s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.reveal-scale {
  opacity: 0;
  transform: scale(0.75) rotate(-3deg);
  transition: all 0.9s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-scale.visible {
  opacity: 1;
  transform: scale(1) rotate(0);
}

/* Stagger delay for grid items */
.service-card:nth-child(1) { transition-delay: 0.1s; }
.service-card:nth-child(2) { transition-delay: 0.2s; }
.service-card:nth-child(3) { transition-delay: 0.3s; }
.service-card:nth-child(4) { transition-delay: 0.4s; }
.service-card:nth-child(5) { transition-delay: 0.5s; }
.service-card:nth-child(6) { transition-delay: 0.6s; }

.gallery-item:nth-child(1) { transition-delay: 0.1s; }
.gallery-item:nth-child(2) { transition-delay: 0.2s; }
.gallery-item:nth-child(3) { transition-delay: 0.3s; }
.gallery-item:nth-child(4) { transition-delay: 0.4s; }
.gallery-item:nth-child(5) { transition-delay: 0.5s; }
.gallery-item:nth-child(6) { transition-delay: 0.6s; }

.testimonial-card:nth-child(1) { transition-delay: 0.1s; }
.testimonial-card:nth-child(2) { transition-delay: 0.25s; }
.testimonial-card:nth-child(3) { transition-delay: 0.4s; }

/* ═══════════════════════════════════════════════════════════════
   HOVER EFFECTS — Efectos de cursor
   ═══════════════════════════════════════════════════════════════ */
.hover-lift {
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.hover-lift:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 45px var(--shadow);
}

.hover-glow {
  transition: box-shadow 0.35s ease;
}

.hover-glow:hover {
  box-shadow: 0 0 35px var(--rose-glow);
}

/* ═══════════════════════════════════════════════════════════════
   TEXT ANIMATIONS — Texto con brillo
   ═══════════════════════════════════════════════════════════════ */
@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.text-shimmer {
  background: var(--gradient-shimmer);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 4s linear infinite;
}

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

.typing-effect {
  overflow: hidden;
  white-space: nowrap;
  animation: typing 2.5s steps(40) forwards;
}

/* ═══════════════════════════════════════════════════════════════
   GRADIENT BORDERS — Bordes con degradado
   ═══════════════════════════════════════════════════════════════ */
.gradient-border {
  position: relative;
  background: white;
  border-radius: 24px;
}

.gradient-border::before {
  content: '';
  position: absolute;
  inset: -3px;
  background: linear-gradient(135deg, var(--rose), var(--gold), var(--rose-soft));
  border-radius: 26px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.gradient-border:hover::before {
  opacity: 1;
}

/* ═══════════════════════════════════════════════════════════════
   SCROLL INDICATOR — Barra de progreso elegante
   ═══════════════════════════════════════════════════════════════ */
.scroll-indicator {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--rose), var(--gold), var(--rose-soft));
  z-index: 1000;
  transition: width 0.1s ease;
  box-shadow: 0 0 10px var(--rose-glow);
}

/* ═══════════════════════════════════════════════════════════════
   CURSOR TRAIL — Estela de cursor con flor
   ═══════════════════════════════════════════════════════════════ */
.cursor-trail {
  position: fixed;
  width: 24px;
  height: 24px;
  border: 2px solid var(--rose-soft);
  border-radius: 50% 50% 50% 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.5;
  transition: transform 0.15s ease, opacity 0.3s ease;
  transform: rotate(-45deg);
}

/* ═══════════════════════════════════════════════════════════════
   LOADING ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(35px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes rotateIn {
  from {
    opacity: 0;
    transform: rotate(-12deg) scale(0.85);
  }
  to {
    opacity: 1;
    transform: rotate(0) scale(1);
  }
}

/* ═══════════════════════════════════════════════════════════════
   DECORATIVE ELEMENTS — Puntos y círculos
   ═══════════════════════════════════════════════════════════════ */
.decorative-dots {
  position: absolute;
  width: 100px;
  height: 100px;
  background-image: radial-gradient(var(--gold) 2px, transparent 2px);
  background-size: 15px 15px;
  opacity: 0.25;
}

.decorative-circle {
  position: absolute;
  border: 2px solid var(--rose-soft);
  border-radius: 50%;
  opacity: 0.15;
  animation: ringPulse 6s ease-in-out infinite;
}

/* ═══════════════════════════════════════════════════════════════
   INTERACTIVE BUTTONS — Efecto magnético
   ═══════════════════════════════════════════════════════════════ */
.btn-magnetic {
  position: relative;
  overflow: hidden;
}

.btn-magnetic::before {
  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.7s ease, height 0.7s ease;
  z-index: 0;
}

.btn-magnetic:hover::before {
  width: 350px;
  height: 350px;
}

/* ═══════════════════════════════════════════════════════════════
   SPARKLE EFFECT — Destellos en hover
   ═══════════════════════════════════════════════════════════════ */
@keyframes sparkle {
  0%, 100% { opacity: 0; transform: scale(0); }
  50% { opacity: 1; transform: scale(1); }
}

.sparkle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--gold);
  border-radius: 50%;
  pointer-events: none;
  box-shadow: 0 0 6px var(--gold);
  animation: sparkle 1s ease-in-out;
}

/* ═══════════════════════════════════════════════════════════════
   HEART FLOAT — Corazones flotantes (easter egg)
   ═══════════════════════════════════════════════════════════════ */
@keyframes heartFloat {
  0% {
    opacity: 0;
    transform: translateY(0) scale(0.5);
  }
  20% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateY(-100px) scale(1.2);
  }
}

.heart-particle {
  position: fixed;
  pointer-events: none;
  z-index: 9998;
  animation: heartFloat 2s ease-out forwards;
  color: var(--rose-soft);
}

/* ═══════════════════════════════════════════════════════════════
   RIPPLE EFFECT — Ondas al hacer click
   ═══════════════════════════════════════════════════════════════ */
@keyframes ripple {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: scale(0);
  animation: ripple 0.6s ease-out;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════
   GLOW PULSE — Pulsación suave
   ═══════════════════════════════════════════════════════════════ */
@keyframes glowPulse {
  0%, 100% {
    box-shadow: 0 0 20px var(--rose-glow);
  }
  50% {
    box-shadow: 0 0 40px var(--rose-glow), 0 0 60px var(--glow);
  }
}

.glow-pulse {
  animation: glowPulse 3s ease-in-out infinite;
}

/* ═══════════════════════════════════════════════════════════════
   FLOATING ANIMATION — Para elementos decorativos
   ═══════════════════════════════════════════════════════════════ */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

.float {
  animation: float 4s ease-in-out infinite;
}

/* ═══════════════════════════════════════════════════════════════
   SHIMMER BORDER — Borde que brilla
   ═══════════════════════════════════════════════════════════════ */
@keyframes borderShimmer {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

.shimmer-border {
  position: relative;
  background: white;
  border-radius: 24px;
}

.shimmer-border::after {
  content: '';
  position: absolute;
  inset: -2px;
  background: linear-gradient(90deg, var(--rose), var(--gold), var(--rose-soft), var(--gold), var(--rose));
  background-size: 200% 100%;
  border-radius: 26px;
  z-index: -1;
  animation: borderShimmer 4s linear infinite;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.shimmer-border:hover::after {
  opacity: 1;
}

/* ═══════════════════════════════════════════════════════════════
   TILT EFFECT — Inclinación 3D al hover
   ═══════════════════════════════════════════════════════════════ */
.tilt-card {
  transition: transform 0.3s ease;
  transform-style: preserve-3d;
}

.tilt-card:hover {
  transform: perspective(800px) rotateY(-5deg) rotateX(5deg) translateY(-5px);
}

/* ═══════════════════════════════════════════════════════════════
   REDUCED MOTION — Respetar preferencias del usuario
   ═══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .particle,
  .cursor-trail,
  .scroll-indicator,
  .heart-particle,
  .orb {
    display: none;
  }
}
