/* ============================================================
   Exegete — Shared Animation & Micro-Interaction Stylesheet
   ============================================================ */

/* ── Page fade-in on load ── */
/* NOTE: Do NOT use transform in this animation — any transform on body
   (even translateY(0)) acts as the containing block for position:fixed
   children, which breaks modals, nav, and canvas positioning.
   Also: start from opacity 0.3 (not 0) so the page is never fully black
   during navigation — this eliminates the jarring black flash. */
@keyframes pageIn {
  from { opacity: 0.3; }
  to   { opacity: 1;   }
}
body {
  animation: pageIn 0.18s ease-out both;
}

/* ── Scroll reveal base state ── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity  0.55s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Stagger delays for child groups ── */
.reveal-group .reveal:nth-child(1)  { transition-delay: 0.03s; }
.reveal-group .reveal:nth-child(2)  { transition-delay: 0.08s; }
.reveal-group .reveal:nth-child(3)  { transition-delay: 0.13s; }
.reveal-group .reveal:nth-child(4)  { transition-delay: 0.18s; }
.reveal-group .reveal:nth-child(5)  { transition-delay: 0.23s; }
.reveal-group .reveal:nth-child(6)  { transition-delay: 0.28s; }
.reveal-group .reveal:nth-child(7)  { transition-delay: 0.33s; }
.reveal-group .reveal:nth-child(8)  { transition-delay: 0.38s; }

/* ── Ripple effect container ── */
.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  transform: scale(0);
  pointer-events: none;
  animation: rippleAnim 0.6s linear forwards;
}
@keyframes rippleAnim {
  to { transform: scale(4.5); opacity: 0; }
}

/* ── Button press scale ── */
button:not(.nav-hamburger):not(.mobile-nav-close):active,
a.btn-primary:active,
a.btn-secondary:active,
a.btn-outline:active,
.nav-research-btn:active,
.mv-btn:active {
  transform: scale(0.97) !important;
  transition: transform 0.08s ease !important;
}

/* ── Gold buttons get position:relative so ripple can attach ── */
button:not(.nav-hamburger):not(.mobile-nav-close):not(.faq-question),
.btn-primary, .btn-secondary, .btn-outline,
.nav-research-btn, .mv-btn, .nav-btn {
  position: relative;
  overflow: hidden;
}

/* ── Card hover lift ── */
.faq-item {
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.2s ease !important;
}
.faq-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.28) !important;
}

.plan-card {
  transition: transform 0.28s ease, box-shadow 0.28s ease !important;
}
.plan-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 56px rgba(0, 0, 0, 0.32) !important;
}

.history-card, .session-card {
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.2s ease !important;
}
.history-card:hover, .session-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.28) !important;
  border-color: rgba(201, 168, 76, 0.3) !important;
}

.contact-method {
  transition: transform 0.25s ease, border-color 0.2s ease, background 0.2s ease !important;
}
.contact-method:hover {
  transform: translateY(-2px);
}

/* ── Input focus gold glow ── */
input:focus,
textarea:focus,
select:focus {
  box-shadow: 0 0 0 2.5px rgba(201, 168, 76, 0.32) !important;
  transition: box-shadow 0.2s ease, border-color 0.2s ease !important;
}

/* ── Nav link animated underline ── */
.nav-links a:not(.nav-research-btn),
.nav-right .nav-link,
.nav-right .nav-inline-link {
  position: relative;
}
.nav-links a:not(.nav-research-btn)::after,
.nav-right .nav-link::after,
.nav-right .nav-inline-link::after {
  content: '';
  position: absolute;
  bottom: -3px; left: 0;
  width: 0; height: 1.5px;
  background: #e2c06e;
  border-radius: 2px;
  transition: width 0.25s ease;
}
.nav-links a:not(.nav-research-btn):hover::after,
.nav-right .nav-link:hover::after,
.nav-right .nav-inline-link:hover::after {
  width: 100%;
}
/* Don't underline the active link */
.nav-links a.active::after,
.nav-right .nav-link.active::after {
  display: none;
}

/* ── Denomination tags pop on hover ── */
.denom-tag:not(.coming-soon) {
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease !important;
  cursor: default;
}
.denom-tag:not(.coming-soon):hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 6px 20px rgba(201, 168, 76, 0.2) !important;
}

/* ── Nav Research button (gold pill — consistent across all pages) ── */
.nav-research-btn {
  background: #c9a84c !important;
  color: #0a1628 !important;
  padding: 8px 20px !important;
  border-radius: 8px !important;
  font-weight: 700 !important;
  font-size: 0.88rem !important;
  letter-spacing: 0.03em !important;
  text-decoration: none !important;
  transition: background 0.2s !important;
  display: inline-block;
}
.nav-research-btn:hover {
  background: #e8d08a !important;
  color: #0a1628 !important;
}

/* ── Respect reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  body                       { animation: none !important; }
  .reveal                    { opacity: 1 !important; transform: none !important; transition: none !important; }
  .ripple                    { display: none !important; }
  *                          { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
