/* ============================================
   Custom Animations
   ============================================ */

/* === Fade In === */
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

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

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInLeft {
  from { opacity: 0; transform: translateX(-30px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes fadeInRight {
  from { opacity: 0; transform: translateX(30px); }
  to   { opacity: 1; transform: translateX(0); }
}

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

/* === Gold Shimmer (for premium feel) === */
@keyframes goldShimmer {
  0%   { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.shimmer-gold {
  background: linear-gradient(
    90deg,
    var(--color-champagne-gold) 0%,
    var(--color-champagne-gold-light) 50%,
    var(--color-champagne-gold) 100%
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: goldShimmer 3s linear infinite;
}

/* === Reveal on Scroll (used with JS) === */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.reveal--left {
  transform: translateX(-30px);
}

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

.reveal--right {
  transform: translateX(30px);
}

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

/* === Stagger Delay (for grids) === */
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }
.stagger-7 { transition-delay: 0.7s; }
.stagger-8 { transition-delay: 0.8s; }

/* === Hero Text Reveal === */
.hero-text-reveal {
  animation: fadeInUp 0.8s ease forwards;
  opacity: 0;
}

.hero-text-reveal:nth-child(1) { animation-delay: 0.2s; }
.hero-text-reveal:nth-child(2) { animation-delay: 0.4s; }
.hero-text-reveal:nth-child(3) { animation-delay: 0.6s; }
.hero-text-reveal:nth-child(4) { animation-delay: 0.8s; }

/* === Reduced Motion === */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  html {
    scroll-behavior: auto;
  }
}

/* === High Contrast Support === */
@media (prefers-contrast: more) {
  :root {
    --color-text-secondary: #333333;
    --color-text-muted: #555555;
    --shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.15);
    --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.2);
  }

  a { text-decoration: underline; }

  .btn, .chatbot-toggle, .whatsapp-float__btn {
    border: 2px solid currentColor;
  }

  .nav__link::after {
    height: 3px;
  }
}

/* === Print Styles === */
@media print {
  .header,
  .mobile-nav,
  .mobile-nav__overlay,
  .whatsapp-float,
  #chatbot-widget,
  .cookie-consent,
  .menu-toggle,
  .theme-toggle,
  .lang-toggle,
  .hero__dots,
  .btn--whatsapp,
  .chatbot-toggle {
    display: none !important;
  }

  body {
    background: white !important;
    color: black !important;
    font-size: 12pt;
  }

  a {
    text-decoration: underline;
    color: #000;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
    color: #555;
  }

  a[href^="#"]::after,
  a[href^="javascript:"]::after,
  a[href^="tel:"]::after,
  a[href^="https://wa.me"]::after {
    content: "";
  }

  h1, h2, h3 {
    page-break-after: avoid;
    color: black !important;
  }

  img {
    max-width: 100% !important;
  }

  .footer {
    background: white !important;
    color: black !important;
  }

  .section-title::after {
    background: black;
  }
}
