/* ========== BASE & RESET ========== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
body { margin: 0; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }

/* ========== ANIMATIONS ========== */
@keyframes bubble {
  0%, 100% { transform: translateY(0) scale(1); opacity: 0.6; }
  50% { transform: translateY(-20px) scale(1.1); opacity: 1; }
}
.animate-bubble { animation: bubble 3s ease-in-out infinite; }

/* ========== SCROLL REVEAL ========== */
/* Default state: fully visible (progressive enhancement — works without JS) */
.reveal {
  opacity: 1;
  transform: none;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

/* When JS is active and user prefers motion, apply animations */
@media (prefers-reduced-motion: no-preference) {
  .js-active .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  }
  .js-active .reveal.revealed {
    opacity: 1;
    transform: translateY(0);
  }
  /* Stagger children */
  .js-active .reveal:nth-child(1) { transition-delay: 0.05s; }
  .js-active .reveal:nth-child(2) { transition-delay: 0.12s; }
  .js-active .reveal:nth-child(3) { transition-delay: 0.19s; }
  .js-active .reveal:nth-child(4) { transition-delay: 0.26s; }
  .js-active .reveal:nth-child(5) { transition-delay: 0.33s; }
  .js-active .reveal:nth-child(6) { transition-delay: 0.40s; }
}

/* ========== NAV ========== */
#site-header.scrolled {
  box-shadow: 0 1px 20px rgba(0,0,0,0.08);
}

/* ========== FAQ ========== */
.faq-item { transition: box-shadow 0.3s ease; }
.faq-item:hover { box-shadow: 0 4px 20px rgba(194, 94, 56, 0.08); }
.faq-icon { transition: transform 0.3s ease; }
.faq-item[open] .faq-icon,
.faq-item.active .faq-icon { transform: rotate(45deg); }
.faq-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
}
.faq-content.open {
  max-height: 300px;
}

/* ========== FOCUS ========== */
a:focus-visible, button:focus-visible {
  outline: 2px solid #c25e38;
  outline-offset: 2px;
  border-radius: 0.5rem;
}

/* ========== MOBILE ========== */
@media (max-width: 767px) {
  #mobile-menu { animation: slideDown 0.25s ease; }
  @keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

/* ========== SELECTION ========== */
::selection { background: #f5c0b0; color: #5c2d1d; }
