/* ============================================
   DEEPLY ROOTED HAIR ESSENTIALS — DESIGN SYSTEM
   ============================================ */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=Inter:wght@300;400;500;600;700&display=swap');

/* ---- Design Tokens ---- */
:root {
  /* Colors */
  --color-sage: #7A8B6F;
  --color-sage-light: #9BAF8E;
  --color-sage-dark: #5C6B4F;
  --color-olive: #4A5A3C;
  --color-gold: #C5A55A;
  --color-gold-bright: #D4AF37;
  --color-gold-light: #E8D5A0;
  --color-white: #FFFFFF;
  --color-cream: #FAFAF5;
  --color-cream-warm: #F5F0E8;
  --color-charcoal: #2C2C2C;
  --color-black: #1A1A1A;
  --color-gray-100: #F7F7F7;
  --color-gray-200: #E8E8E8;
  --color-gray-300: #D1D1D1;
  --color-gray-500: #888888;
  --color-gray-700: #555555;
  --color-error: #C0392B;
  --color-success: #27AE60;

  /* Typography */
  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, sans-serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  /* Layout */
  --max-width: 1200px;
  --nav-height: 80px;

  /* Borders & Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 50%;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
  --shadow-xl: 0 16px 48px rgba(0,0,0,0.16);
  --shadow-gold: 0 4px 20px rgba(197,165,90,0.3);

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
  --transition-spring: 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font-body);
  color: var(--color-charcoal);
  background: var(--color-white);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; transition: color var(--transition-fast); }
ul, ol { list-style: none; }
button, input, textarea, select {
  font-family: inherit; font-size: inherit; border: none; outline: none; background: none;
}
button { cursor: pointer; }

/* ---- Typography ---- */
h1, h2, h3, h4, h5 { font-family: var(--font-heading); font-weight: 600; line-height: 1.2; color: var(--color-black); }
h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 3vw, 1.8rem); }
h4 { font-size: clamp(1.1rem, 2vw, 1.3rem); }
p { margin-bottom: var(--space-md); color: var(--color-gray-700); }
.text-gold { color: var(--color-gold); }
.text-sage { color: var(--color-sage); }
.text-center { text-align: center; }
.subtitle {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--color-gold);
}

/* ---- Layout ---- */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 var(--space-xl); }
.section { padding: var(--space-4xl) 0; }
.section-header { text-align: center; max-width: 700px; margin: 0 auto var(--space-2xl); }
.section-header h2 { margin-bottom: var(--space-md); }
.section-header p { font-size: 1.1rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-2xl); align-items: center; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-xl); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-xl); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-sm);
  padding: 0.9rem 2.2rem; border-radius: var(--radius-md); font-weight: 600;
  font-size: 0.95rem; letter-spacing: 0.5px; transition: all var(--transition-base);
  position: relative; overflow: hidden;
}
.btn-primary {
  background: linear-gradient(135deg, var(--color-gold), var(--color-gold-bright));
  color: var(--color-black); box-shadow: var(--shadow-gold);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 28px rgba(197,165,90,0.45); }
.btn-secondary {
  background: transparent; color: var(--color-white);
  border: 2px solid rgba(255,255,255,0.6);
}
.btn-secondary:hover { background: rgba(255,255,255,0.1); border-color: var(--color-white); }
.btn-outline {
  background: transparent; color: var(--color-sage-dark);
  border: 2px solid var(--color-sage);
}
.btn-outline:hover { background: var(--color-sage); color: var(--color-white); }
.btn-dark {
  background: var(--color-charcoal); color: var(--color-white);
}
.btn-dark:hover { background: var(--color-black); transform: translateY(-2px); }

/* ============================================
   HOVER EFFECTS — Glow · Scale · Rotate & More
   ============================================ */

/* ---- Glow Effects ---- */
.hover-glow-gold {
  transition: box-shadow var(--transition-base), transform var(--transition-base);
}
.hover-glow-gold:hover {
  box-shadow: 0 0 20px rgba(197,165,90,0.45),
              0 0 60px rgba(197,165,90,0.2),
              inset 0 0 12px rgba(197,165,90,0.08);
  transform: translateY(-2px);
}

.hover-glow-sage {
  transition: box-shadow var(--transition-base), transform var(--transition-base);
}
.hover-glow-sage:hover {
  box-shadow: 0 0 18px rgba(122,139,111,0.4),
              0 0 50px rgba(122,139,111,0.15),
              inset 0 0 10px rgba(122,139,111,0.06);
  transform: translateY(-2px);
}

.hover-glow-white {
  transition: box-shadow var(--transition-base), transform var(--transition-base);
}
.hover-glow-white:hover {
  box-shadow: 0 0 20px rgba(255,255,255,0.35),
              0 0 50px rgba(255,255,255,0.12);
  transform: translateY(-2px);
}

/* Soft halo glow — spreads wider, more ambient */
.hover-glow-halo {
  transition: box-shadow 0.4s ease, transform var(--transition-base);
}
.hover-glow-halo:hover {
  box-shadow: 0 4px 24px rgba(197,165,90,0.25),
              0 8px 80px rgba(197,165,90,0.12);
  transform: translateY(-3px);
}

/* ---- Scale Effects ---- */
.hover-scale {
  transition: transform var(--transition-base);
}
.hover-scale:hover {
  transform: scale(1.05);
}

.hover-scale-subtle {
  transition: transform var(--transition-base);
}
.hover-scale-subtle:hover {
  transform: scale(1.02);
}

.hover-scale-pop {
  transition: transform var(--transition-spring);
}
.hover-scale-pop:hover {
  transform: scale(1.1);
}

/* Scale down on press — mimics a physical button */
.hover-press {
  transition: transform 0.15s ease, box-shadow var(--transition-fast);
}
.hover-press:hover {
  transform: scale(0.97);
  box-shadow: var(--shadow-sm);
}
.hover-press:active {
  transform: scale(0.93);
  box-shadow: none;
}

/* ---- Rotate Effects ---- */
.hover-rotate-tilt {
  transition: transform var(--transition-base);
}
.hover-rotate-tilt:hover {
  transform: rotate(-3deg) scale(1.03);
}

.hover-rotate-tilt-right {
  transition: transform var(--transition-base);
}
.hover-rotate-tilt-right:hover {
  transform: rotate(3deg) scale(1.03);
}

.hover-rotate-spin {
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.hover-rotate-spin:hover {
  transform: rotate(360deg);
}

.hover-rotate-flip {
  transition: transform 0.5s ease;
  transform-style: preserve-3d;
}
.hover-rotate-flip:hover {
  transform: rotateY(180deg);
}

/* ---- Lift Effect (rise + shadow deepen) ---- */
.hover-lift {
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}
.hover-lift:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 36px rgba(0,0,0,0.15), 0 4px 12px rgba(0,0,0,0.08);
}

.hover-lift-sm {
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}
.hover-lift-sm:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}

/* ---- Shimmer Sweep (light sweep across surface) ---- */
.hover-shimmer {
  position: relative;
  overflow: hidden;
}
.hover-shimmer::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    120deg,
    transparent 0%,
    rgba(255,255,255,0.25) 50%,
    transparent 100%
  );
  transition: left 0.6s ease;
  pointer-events: none;
  z-index: 1;
}
.hover-shimmer:hover::before {
  left: 130%;
}

/* ---- Neon Outline Pulse ---- */
.hover-neon {
  transition: box-shadow var(--transition-base), border-color var(--transition-base);
  border: 2px solid transparent;
}
.hover-neon:hover {
  border-color: var(--color-gold);
  box-shadow: 0 0 8px rgba(197,165,90,0.4),
              0 0 24px rgba(197,165,90,0.15),
              inset 0 0 8px rgba(197,165,90,0.06);
}

.hover-neon-sage {
  transition: box-shadow var(--transition-base), border-color var(--transition-base);
  border: 2px solid transparent;
}
.hover-neon-sage:hover {
  border-color: var(--color-sage);
  box-shadow: 0 0 8px rgba(122,139,111,0.4),
              0 0 24px rgba(122,139,111,0.15),
              inset 0 0 8px rgba(122,139,111,0.06);
}

/* ---- Wobble / Shake ---- */
@keyframes hoverWobble {
  0%   { transform: rotate(0deg); }
  15%  { transform: rotate(-4deg); }
  30%  { transform: rotate(3deg); }
  45%  { transform: rotate(-2deg); }
  60%  { transform: rotate(1.5deg); }
  75%  { transform: rotate(-1deg); }
  100% { transform: rotate(0deg); }
}
.hover-wobble {
  transition: transform var(--transition-base);
}
.hover-wobble:hover {
  animation: hoverWobble 0.6s ease;
}

/* ---- Icon Slide (arrow/icon slides right on hover) ---- */
.hover-icon-slide {
  transition: gap var(--transition-base);
}
.hover-icon-slide:hover {
  gap: var(--space-md);
}
.hover-icon-slide .btn-icon,
.hover-icon-slide svg:last-child,
.hover-icon-slide span:last-child {
  transition: transform var(--transition-base);
}
.hover-icon-slide:hover .btn-icon,
.hover-icon-slide:hover svg:last-child,
.hover-icon-slide:hover span:last-child {
  transform: translateX(4px);
}

/* ---- Composable: combine multiple effects ---- */
/* Example: class="btn btn-primary hover-glow-gold hover-scale hover-shimmer" */

/* ---- Reduced Motion: disable all hover transforms ---- */
@media (prefers-reduced-motion: reduce) {
  .hover-glow-gold:hover, .hover-glow-sage:hover, .hover-glow-white:hover,
  .hover-glow-halo:hover,
  .hover-scale:hover, .hover-scale-subtle:hover, .hover-scale-pop:hover,
  .hover-press:hover, .hover-press:active,
  .hover-rotate-tilt:hover, .hover-rotate-tilt-right:hover,
  .hover-rotate-spin:hover, .hover-rotate-flip:hover,
  .hover-lift:hover, .hover-lift-sm:hover,
  .hover-wobble:hover {
    transform: none !important;
    animation: none !important;
  }
}

/* ---- Navigation ---- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-height); display: flex; align-items: center;
  transition: all var(--transition-base);
  background: transparent;
}
.navbar.scrolled {
  background: rgba(74, 90, 60, 0.88); backdrop-filter: blur(20px) saturate(1.4); -webkit-backdrop-filter: blur(20px) saturate(1.4);
  box-shadow: 0 4px 24px rgba(0,0,0,0.12), inset 0 1px 0 rgba(255,255,255,0.06);
}
.navbar .container { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.nav-logo {
  display: flex; align-items: center; gap: 0.5rem;
  font-family: var(--font-heading); font-size: 1.4rem; font-weight: 700;
  color: var(--color-white); transition: color var(--transition-base);
  text-decoration: none;
}
.nav-logo span { color: var(--color-gold); }
.navbar.scrolled .nav-logo { color: var(--color-white); }
.navbar.scrolled .nav-logo-text { color: var(--color-white) !important; text-shadow: 0 1px 4px rgba(0,0,0,0.2); }
.navbar.scrolled .nav-logo-text em,
.navbar.scrolled .nav-logo-text span { color: var(--color-gold) !important; }
.nav-links { display: flex; align-items: center; gap: var(--space-2xl); }
.nav-links a {
  font-size: 0.9rem; font-weight: 500; color: rgba(255,255,255,0.85);
  position: relative; padding: var(--space-xs) 0;
  transition: color var(--transition-fast);
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px;
  background: var(--color-gold); transition: width var(--transition-base);
}
.nav-links a:hover, .nav-links a.active { color: var(--color-white); }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.navbar.scrolled .nav-links a { color: rgba(255,255,255,0.9); font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,0.15); }
.navbar.scrolled .nav-links a:hover, .navbar.scrolled .nav-links a.active { color: var(--color-gold); }
.nav-cta {
  padding: 0.6rem 1.6rem; border-radius: var(--radius-md); font-weight: 600; font-size: 0.85rem;
  background: var(--color-gold); color: var(--color-black);
  transition: all var(--transition-base);
}
.nav-cta:hover { background: var(--color-gold-bright); transform: translateY(-1px); }
.nav-cta::after { display: none !important; }

/* Hamburger */
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; z-index: 1001; }
.hamburger span {
  width: 26px; height: 2.5px; background: var(--color-white); border-radius: 2px;
  transition: all var(--transition-base);
}
.navbar.scrolled .hamburger span { background: var(--color-white); }
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* Mobile Menu */
.mobile-menu {
  display: none; position: fixed; top: 0; right: -100%; width: 80%; max-width: 360px; height: 100vh;
  background: var(--color-white); z-index: 999; padding: 100px var(--space-2xl) var(--space-2xl);
  box-shadow: var(--shadow-xl); transition: right var(--transition-slow);
  flex-direction: column; gap: var(--space-lg);
}
.mobile-menu.open { right: 0; }
.mobile-menu a {
  font-size: 1.1rem; font-weight: 500; color: var(--color-charcoal);
  padding: var(--space-md) 0; border-bottom: 1px solid var(--color-gray-200);
  display: block;
}
.mobile-menu a:hover { color: var(--color-sage-dark); }
.mobile-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 998;
  opacity: 0; transition: opacity var(--transition-base);
}
.mobile-overlay.open { opacity: 1; }

/* ---- Cards ---- */
.card {
  background: var(--color-white); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card-image { width: 100%; aspect-ratio: 1; overflow: hidden; background: var(--color-cream); }
.card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--transition-slow); }
.card:hover .card-image img { transform: scale(1.05); }
.card-body { padding: var(--space-lg); }
.card-body h3 { margin-bottom: var(--space-sm); }
.card-body p { font-size: 0.95rem; }

/* ---- Badges ---- */
.badge {
  display: inline-flex; align-items: center; gap: var(--space-xs);
  padding: 0.35rem 0.9rem; border-radius: var(--radius-xl); font-size: 0.75rem;
  font-weight: 600; text-transform: uppercase; letter-spacing: 1px;
}
.badge-gold { background: var(--color-gold-light); color: var(--color-olive); }
.badge-sage { background: rgba(122,139,111,0.15); color: var(--color-sage-dark); }
.badge-pro { background: var(--color-charcoal); color: var(--color-gold); }

/* ---- Forms ---- */
.form-group { margin-bottom: var(--space-lg); }
.form-group label {
  display: block; font-weight: 600; font-size: 0.9rem;
  margin-bottom: var(--space-sm); color: var(--color-charcoal);
}
.form-group label .required { color: var(--color-error); }
.form-input, .form-textarea, .form-select {
  width: 100%; padding: 0.85rem 1rem; border: 2px solid var(--color-gray-200);
  border-radius: var(--radius-md); font-size: 0.95rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  background: var(--color-white);
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  border-color: var(--color-sage); box-shadow: 0 0 0 3px rgba(122,139,111,0.15);
}
.form-input.error, .form-textarea.error { border-color: var(--color-error); }
.form-textarea { min-height: 140px; resize: vertical; }
.form-error { color: var(--color-error); font-size: 0.8rem; margin-top: var(--space-xs); display: none; }
.form-success {
  background: rgba(39,174,96,0.1); border: 1px solid var(--color-success);
  color: var(--color-success); padding: var(--space-lg); border-radius: var(--radius-md);
  text-align: center; display: none;
}

/* ---- Page Hero ---- */
.page-hero {
  padding: calc(var(--nav-height) + var(--space-4xl)) 0 var(--space-4xl);
  background: linear-gradient(135deg, var(--color-sage-dark) 0%, var(--color-sage) 50%, var(--color-olive) 100%);
  color: var(--color-white); text-align: center; position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 70%, rgba(197,165,90,0.15) 0%, transparent 60%);
}
.page-hero h1 { color: var(--color-white); margin-bottom: var(--space-md); position: relative; }
.page-hero p { color: rgba(255,255,255,0.85); font-size: 1.15rem; max-width: 600px; margin: 0 auto; position: relative; }

/* ---- Footer ---- */
.footer {
  background: var(--color-black); color: rgba(255,255,255,0.7); padding: var(--space-4xl) 0 var(--space-xl);
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: var(--space-2xl);
  padding-bottom: var(--space-3xl); border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand .nav-logo { color: var(--color-white); font-size: 1.3rem; display: inline-block; margin-bottom: var(--space-md); }
.footer-brand p { font-size: 0.9rem; line-height: 1.8; color: rgba(255,255,255,0.6); }
.footer h4 { color: var(--color-white); font-size: 1rem; margin-bottom: var(--space-lg); font-family: var(--font-body); font-weight: 600; }
.footer-links a { display: block; padding: var(--space-xs) 0; color: rgba(255,255,255,0.6); font-size: 0.9rem; }
.footer-links a:hover { color: var(--color-gold); }
.footer-contact p { font-size: 0.9rem; margin-bottom: var(--space-sm); display: flex; align-items: flex-start; gap: var(--space-sm); }
.footer-contact p span { color: var(--color-gold); flex-shrink: 0; }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: var(--space-xl); margin-top: var(--space-xl);
}
.footer-bottom p { font-size: 0.85rem; color: rgba(255,255,255,0.4); margin: 0; }
.footer-scripture { font-family: var(--font-heading); font-style: italic; font-size: 0.9rem; color: rgba(255,255,255,0.5); }
.footer-social { display: flex; gap: var(--space-md); align-items: center; }
.footer-social a {
  width: 36px; height: 36px; border-radius: var(--radius-full);
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition-base);
}
.footer-social a:hover { transform: translateY(-3px); filter: brightness(1.2); }
.footer-social a svg { width: 28px; height: 28px; }

/* ---- Scroll Reveal (Blur In/Out) ---- */
.reveal {
  opacity: 0; transform: translateY(30px); filter: blur(8px);
  transition: opacity 0.7s cubic-bezier(0.5, 0, 0, 1),
              transform 0.7s cubic-bezier(0.5, 0, 0, 1),
              filter 0.6s cubic-bezier(0.5, 0, 0, 1);
  will-change: opacity, transform, filter;
}
.reveal.visible {
  opacity: 1; transform: translateY(0) translateX(0) scale(1) rotate(0deg); filter: blur(0);
}
.reveal-left { opacity: 0; transform: translateX(-60px); filter: blur(8px); }
.reveal-right { opacity: 0; transform: translateX(60px); filter: blur(8px); }
.reveal-scale { opacity: 0; transform: scale(0.82); filter: blur(10px); }
.reveal-rotate { opacity: 0; transform: rotate(-4deg) translateY(20px); filter: blur(8px); }
.reveal-blur { opacity: 0; filter: blur(16px); transform: translateY(15px); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }
.reveal-delay-6 { transition-delay: 0.6s; }

/* ============================================
   FADE-UP ON SCROLL — Keyframe Animations
   ============================================ */

/* ---- Fade Up: Clean vertical rise ---- */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---- Fade Up Blur: Rise with focus effect ---- */
@keyframes fadeUpBlur {
  from {
    opacity: 0;
    transform: translateY(35px);
    filter: blur(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

/* ---- Fade Up Scale: Rise with subtle zoom ---- */
@keyframes fadeUpScale {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ---- Fade Up Left: Diagonal from bottom-left ---- */
@keyframes fadeUpLeft {
  from {
    opacity: 0;
    transform: translate(-40px, 30px);
  }
  to {
    opacity: 1;
    transform: translate(0, 0);
  }
}

/* ---- Fade Up Right: Diagonal from bottom-right ---- */
@keyframes fadeUpRight {
  from {
    opacity: 0;
    transform: translate(40px, 30px);
  }
  to {
    opacity: 1;
    transform: translate(0, 0);
  }
}

/* ---- Fade-Up Utility Classes ---- */
/* Base state: hidden until triggered */
.fade-up,
.fade-up-blur,
.fade-up-scale,
.fade-up-left,
.fade-up-right {
  opacity: 0;
  will-change: opacity, transform;
}

/* Triggered state: run animation */
.fade-up.visible         { animation: fadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.fade-up-blur.visible    { animation: fadeUpBlur 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.fade-up-scale.visible   { animation: fadeUpScale 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.fade-up-left.visible    { animation: fadeUpLeft 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.fade-up-right.visible   { animation: fadeUpRight 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards; }

/* Speed modifiers */
.fade-up-fast.visible,
.fade-up-blur.fade-up-fast.visible,
.fade-up-scale.fade-up-fast.visible  { animation-duration: 0.5s; }
.fade-up-slow.visible,
.fade-up-blur.fade-up-slow.visible,
.fade-up-scale.fade-up-slow.visible  { animation-duration: 1.2s; }

/* Stagger delays for child elements */
.fade-stagger-1 { animation-delay: 0.08s !important; }
.fade-stagger-2 { animation-delay: 0.16s !important; }
.fade-stagger-3 { animation-delay: 0.24s !important; }
.fade-stagger-4 { animation-delay: 0.32s !important; }
.fade-stagger-5 { animation-delay: 0.40s !important; }
.fade-stagger-6 { animation-delay: 0.48s !important; }
.fade-stagger-7 { animation-delay: 0.56s !important; }
.fade-stagger-8 { animation-delay: 0.64s !important; }

/* ============================================
   WORD-BY-WORD TEXT ANIMATION
   ============================================ */

/* Container: hides overflow during animation */
.text-animate {
  overflow: hidden;
}

/* Each word wrapper generated by JS */
.word-animate {
  display: inline-block;
  opacity: 0;
  will-change: opacity, transform, filter;
  /* Preserve spaces between words */
  margin-right: 0.28em;
}

/* ---- Style: Fade Up (default) ---- */
@keyframes wordFadeUp {
  from {
    opacity: 0;
    transform: translateY(100%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---- Style: Blur In ---- */
@keyframes wordBlurIn {
  from {
    opacity: 0;
    filter: blur(12px);
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
  }
}

/* ---- Style: Slide Left ---- */
@keyframes wordSlideLeft {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ---- Style: Scale In ---- */
@keyframes wordScaleIn {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ---- Style: Drop In (with bounce) ---- */
@keyframes wordDropIn {
  0% {
    opacity: 0;
    transform: translateY(-40px);
  }
  60% {
    opacity: 1;
    transform: translateY(6px);
  }
  80% {
    transform: translateY(-3px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---- Style: Type Reveal (clip mask) ---- */
@keyframes wordTypeReveal {
  from {
    opacity: 1;
    clip-path: inset(0 100% 0 0);
  }
  to {
    opacity: 1;
    clip-path: inset(0 0 0 0);
  }
}

/* Triggered state — JS adds .word-visible to each word */
.word-animate.word-visible {
  animation-fill-mode: forwards;
}

/* Style class mappings (JS reads data-text-style, CSS plays animation) */
.text-animate--fade-up .word-animate.word-visible    { animation-name: wordFadeUp; }
.text-animate--blur-in .word-animate.word-visible     { animation-name: wordBlurIn; }
.text-animate--slide-left .word-animate.word-visible  { animation-name: wordSlideLeft; }
.text-animate--scale-in .word-animate.word-visible    { animation-name: wordScaleIn; }
.text-animate--drop-in .word-animate.word-visible     { animation-name: wordDropIn; }
.text-animate--type-reveal .word-animate.word-visible { animation-name: wordTypeReveal; }

/* Default style (when no modifier is set) */
.text-animate .word-animate.word-visible {
  animation-name: wordFadeUp;
}

/* Duration presets */
.text-animate .word-animate.word-visible              { animation-duration: 0.5s; }
.text-animate--slow .word-animate.word-visible        { animation-duration: 0.8s; }
.text-animate--fast .word-animate.word-visible        { animation-duration: 0.3s; }

/* Easing */
.text-animate .word-animate.word-visible {
  animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}
.text-animate--drop-in .word-animate.word-visible {
  animation-timing-function: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Safety fallback: show text after 4s if JS fails */
.word-animate {
  animation: revealFallback 0s 4s forwards;
}

/* Reduced motion: show all words immediately */
@media (prefers-reduced-motion: reduce) {
  .word-animate {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    animation: none !important;
  }
}

/* ---- Safety Fallback: show content if JS hasn't initialized after 4s ---- */
/* This ensures images/content aren't permanently hidden on mobile phones
   where IntersectionObserver may not fire correctly */
@keyframes revealFallback {
  to {
    opacity: 1;
    transform: none;
    filter: none;
  }
}
.reveal, .reveal-left, .reveal-right, .reveal-scale, .reveal-rotate, .reveal-blur,
.fade-up, .fade-up-blur, .fade-up-scale, .fade-up-left, .fade-up-right {
  animation: revealFallback 0s 4s forwards;
}

/* ============================================
   PARALLAX BACKGROUNDS
   ============================================ */

/* ---- Pure CSS Parallax (GPU-accelerated, no JS) ---- */
/* Wrap sections in .parallax-wrapper, use .parallax-bg inside */

.parallax-wrapper {
  position: relative;
  overflow: hidden;
  /* Creates a new perspective context */
  perspective: 1px;
  perspective-origin: center center;
  height: auto;
}

/* Scrollable container approach (for full-page parallax) */
.parallax-scroll-container {
  height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
  perspective: 8px;
  perspective-origin: 50% 50%;
}

.parallax-scroll-container .parallax-bg {
  position: absolute;
  inset: -20% 0;
  transform: translateZ(-4px) scale(1.5);
}

/* ---- Background Layer ---- */
.parallax-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: -1;
  will-change: transform;
}

/* Fixed attachment approach (simplest — works without JS) */
.parallax-fixed {
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Speed variants — controls how much the bg shifts on scroll (JS-driven) */
.parallax-bg--slow   { --parallax-speed: 0.15; }
.parallax-bg--medium { --parallax-speed: 0.3; }
.parallax-bg--fast   { --parallax-speed: 0.5; }
.parallax-bg--reverse { --parallax-speed: -0.2; } /* Moves opposite to scroll */

/* ---- Overlay Tints ---- */
.parallax-overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.parallax-overlay--dark    { background: rgba(0, 0, 0, 0.45); }
.parallax-overlay--darker  { background: rgba(0, 0, 0, 0.65); }
.parallax-overlay--light   { background: rgba(255, 255, 255, 0.3); }
.parallax-overlay--sage    { background: rgba(74, 90, 60, 0.55); }
.parallax-overlay--gold    { background: linear-gradient(135deg, rgba(197,165,90,0.2) 0%, transparent 60%); }
.parallax-overlay--gradient {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.6) 0%,
    rgba(0, 0, 0, 0.1) 40%,
    rgba(0, 0, 0, 0.4) 100%
  );
}

/* ---- Parallax Content (sits above bg + overlay) ---- */
.parallax-content {
  position: relative;
  z-index: 1;
}

/* ---- Multi-Layer Depth Stack ---- */
/* Use data-depth="0.1" to "0.9" for JS-driven layer speeds */
.parallax-layer {
  position: absolute;
  inset: 0;
  will-change: transform;
  transition: transform 0.08s linear;
  pointer-events: none;
}

/* ---- Parallax Section Presets ---- */
/* Drop-in section with parallax bg, overlay, and content area */
.parallax-section {
  position: relative;
  overflow: hidden;
  padding: var(--space-5xl) 0;
  color: var(--color-white);
}

.parallax-section .parallax-bg {
  /* Extra height so we have room to shift */
  top: -30%;
  bottom: -30%;
  height: 160%;
}

/* ---- Parallax Hero Variant ---- */
.parallax-hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--color-white);
  text-align: center;
}

.parallax-hero .parallax-bg {
  top: -20%;
  bottom: -20%;
  height: 140%;
}

/* ---- Zoom-on-Scroll Effect ---- */
/* Subtle bg scale that increases as user scrolls past */
.parallax-zoom .parallax-bg {
  transition: transform 0.1s linear;
  /* JS will update --parallax-scale */
  transform: scale(var(--parallax-scale, 1));
}

/* Disable parallax on mobile (performance + iOS fixed-bg bug) */
@media (max-width: 768px) {
  .parallax-fixed {
    background-attachment: scroll;
  }
  .parallax-section .parallax-bg,
  .parallax-hero .parallax-bg {
    top: 0;
    bottom: 0;
    height: 100%;
    transform: none !important;
  }
}

/* ---- Button Ripple ---- */
.btn-ripple { position: relative; overflow: hidden; }
.btn-ripple .ripple-wave {
  position: absolute; border-radius: 50%;
  background: rgba(255,255,255,0.35);
  transform: scale(0); animation: rippleAnim 0.6s ease-out forwards;
  pointer-events: none;
}
@keyframes rippleAnim {
  to { transform: scale(4); opacity: 0; }
}

/* ---- 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, .reveal-left, .reveal-right, .reveal-scale, .reveal-rotate, .reveal-blur,
  .fade-up, .fade-up-blur, .fade-up-scale, .fade-up-left, .fade-up-right {
    opacity: 1; transform: none; filter: none;
  }
}

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .mobile-menu { display: flex; }
  .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: 1fr; }
  .section { padding: var(--space-2xl) 0; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: var(--space-md); text-align: center; }
  .container { padding: 0 var(--space-md); }
  .floating-leaves-container .leaf { opacity: 0.06; }
}

/* ---- Floating Leaves ---- */
.floating-leaves-container {
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.floating-leaves-container .leaf {
  position: absolute;
  opacity: 0.1;
  will-change: transform;
  filter: blur(0.5px);
}

.floating-leaves-container .leaf svg {
  width: 100%;
  height: 100%;
}

/* Leaf sizes */
.leaf--sm { width: 18px; height: 18px; }
.leaf--md { width: 26px; height: 26px; }
.leaf--lg { width: 34px; height: 34px; }

/* Fall animation — gentle drift down + sway */
@keyframes leafFall {
  0%   { transform: translateY(-60px) translateX(0) rotate(0deg) scale(1); }
  25%  { transform: translateY(25vh)  translateX(30px) rotate(45deg) scale(0.95); }
  50%  { transform: translateY(50vh)  translateX(-20px) rotate(120deg) scale(1.05); }
  75%  { transform: translateY(75vh)  translateX(40px) rotate(200deg) scale(0.9); }
  100% { transform: translateY(110vh) translateX(10px) rotate(340deg) scale(1); }
}

@keyframes leafSway {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  25% { transform: translateX(15px) rotate(8deg); }
  50% { transform: translateX(-10px) rotate(-5deg); }
  75% { transform: translateX(20px) rotate(12deg); }
}

/* Gentle floating for non-falling leaves */
@keyframes leafFloat {
  0%   { transform: translateY(0) translateX(0) rotate(0deg); }
  33%  { transform: translateY(-15px) translateX(12px) rotate(6deg); }
  66%  { transform: translateY(8px) translateX(-8px) rotate(-4deg); }
  100% { transform: translateY(0) translateX(0) rotate(0deg); }
}

.leaf--fall { animation: leafFall linear forwards; }
.leaf--float { animation: leafFloat ease-in-out infinite; }

/* ============================================
   FLOATING & BOUNCE EFFECTS
   ============================================ */

/* ---- Float: Gentle vertical hover ---- */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

/* ---- Float X: Horizontal drift ---- */
@keyframes floatX {
  0%, 100% { transform: translateX(0); }
  50%      { transform: translateX(10px); }
}

/* ---- Float Rotate: Hover with subtle tilt ---- */
@keyframes floatRotate {
  0%   { transform: translateY(0) rotate(0deg); }
  25%  { transform: translateY(-8px) rotate(2deg); }
  50%  { transform: translateY(-14px) rotate(0deg); }
  75%  { transform: translateY(-8px) rotate(-2deg); }
  100% { transform: translateY(0) rotate(0deg); }
}

/* ---- Float Glow: Float + pulsing shadow ---- */
@keyframes floatGlow {
  0%, 100% {
    transform: translateY(0);
    box-shadow: 0 4px 16px rgba(197,165,90,0.15);
  }
  50% {
    transform: translateY(-10px);
    box-shadow: 0 12px 36px rgba(197,165,90,0.35);
  }
}

/* ---- Bounce: Classic elastic bounce ---- */
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  20%      { transform: translateY(-18px); }
  40%      { transform: translateY(0); }
  60%      { transform: translateY(-8px); }
  80%      { transform: translateY(0); }
}

/* ---- Bounce In: Entrance with overshoot ---- */
@keyframes bounceIn {
  0%   { opacity: 0; transform: scale(0.3); }
  50%  { opacity: 1; transform: scale(1.08); }
  70%  { transform: scale(0.95); }
  100% { opacity: 1; transform: scale(1); }
}

/* ---- Bounce Pulse: Rhythmic scale pop ---- */
@keyframes bouncePulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.06); }
}

/* ---- Bounce Elastic: Spring-like vertical bounce ---- */
@keyframes bounceElastic {
  0%   { transform: translateY(0); }
  30%  { transform: translateY(-20px); }
  50%  { transform: translateY(4px); }
  65%  { transform: translateY(-10px); }
  80%  { transform: translateY(2px); }
  90%  { transform: translateY(-4px); }
  100% { transform: translateY(0); }
}

/* ---- Utility Classes ---- */
.anim-float         { animation: float 3s ease-in-out infinite; }
.anim-float-slow    { animation: float 5s ease-in-out infinite; }
.anim-float-fast    { animation: float 2s ease-in-out infinite; }
.anim-float-x       { animation: floatX 4s ease-in-out infinite; }
.anim-float-rotate  { animation: floatRotate 4s ease-in-out infinite; }
.anim-float-glow    { animation: floatGlow 3.5s ease-in-out infinite; }

.anim-bounce        { animation: bounce 2s ease infinite; }
.anim-bounce-in     { animation: bounceIn 0.6s cubic-bezier(0.215, 0.61, 0.355, 1) both; }
.anim-bounce-pulse  { animation: bouncePulse 2s ease-in-out infinite; }
.anim-bounce-elastic { animation: bounceElastic 1.5s ease infinite; }

/* Staggered animation delays */
.anim-delay-100 { animation-delay: 0.1s; }
.anim-delay-200 { animation-delay: 0.2s; }
.anim-delay-300 { animation-delay: 0.3s; }
.anim-delay-400 { animation-delay: 0.4s; }
.anim-delay-500 { animation-delay: 0.5s; }
.anim-delay-700 { animation-delay: 0.7s; }
.anim-delay-1000 { animation-delay: 1s; }

/* Hover-triggered variants */
.hover-float:hover   { animation: float 2s ease-in-out infinite; }
.hover-bounce:hover  { animation: bounce 1s ease; }
.hover-pulse:hover   { animation: bouncePulse 0.6s ease; }

@media (prefers-reduced-motion: reduce) {
  .floating-leaves-container { display: none; }
  .anim-float, .anim-float-slow, .anim-float-fast,
  .anim-float-x, .anim-float-rotate, .anim-float-glow,
  .anim-bounce, .anim-bounce-in, .anim-bounce-pulse,
  .anim-bounce-elastic,
  .hover-float:hover, .hover-bounce:hover, .hover-pulse:hover {
    animation: none !important;
  }
}
