/* ==========================================================================
   RHP SUPERFOOD — Premium Wellness Homepage
   Custom design layer (works alongside Tailwind Play CDN)
   Design direction: "Rooted in Nature, Refined by Science"
   ========================================================================== */

/* ---------- Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300..700;1,9..144,400..600&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

/* ---------- Design tokens ---------- */
:root {
  --pine:    #0E2A1E;   /* deepest green — footer / dark sections */
  --forest:  #14432F;   /* primary brand green */
  --fern:    #2F6B4F;   /* mid green */
  --sage:    #7FB99A;   /* soft accent green */
  --mint:    #DBEEE2;   /* pale green tint */
  --gold:    #C49A3A;   /* turmeric / amber accent */
  --gold-lt: #E0BC6B;   /* light gold */
  --cream:   #FBF8F1;   /* page background */
  --bone:    #F3EDE0;   /* warm panel */
  --sand:    #E8DCC6;   /* deeper warm tone */
  --ink:     #16241D;   /* near-black green text */
  --stone:   #5A6B61;   /* muted text */

  --shadow-soft: 0 18px 50px -24px rgba(20, 67, 47, 0.35);
  --shadow-card: 0 24px 60px -30px rgba(14, 42, 30, 0.45);
  --shadow-lift: 0 36px 80px -36px rgba(14, 42, 30, 0.55);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Base ---------- */
* { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--cream);
  overflow-x: hidden;
}

::selection { background: var(--gold); color: #fff; }

.font-display { font-family: 'Fraunces', Georgia, 'Times New Roman', serif; }

/* Headings get the editorial serif by default */
h1, h2, h3 { font-family: 'Fraunces', Georgia, serif; letter-spacing: -0.01em; }

/* ---------- Custom scrollbar ---------- */
::-webkit-scrollbar { width: 11px; }
::-webkit-scrollbar-track { background: var(--bone); }
::-webkit-scrollbar-thumb { background: var(--fern); border-radius: 99px; border: 3px solid var(--bone); }
::-webkit-scrollbar-thumb:hover { background: var(--forest); }

/* ==========================================================================
   Texture & decorative layers
   ========================================================================== */

/* Subtle film-grain for organic, premium paper feel */
.grain::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.55;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

/* Soft radial glow blobs */
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.5;
  pointer-events: none;
  z-index: 0;
}

/* Thin top hairline used on cards / sections */
.hairline { border-top: 1px solid rgba(20, 67, 47, 0.10); }

/* ==========================================================================
   Typography helpers
   ========================================================================== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fern);
}
.eyebrow::before {
  content: "";
  width: 26px; height: 2px;
  background: var(--gold);
  border-radius: 2px;
}
.eyebrow.center { justify-content: center; }

.text-gradient {
  background: linear-gradient(105deg, var(--fern) 0%, var(--gold) 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Decorative underline stroke under a word in headings */
.brush {
  position: relative;
  white-space: nowrap;
}
.brush::after {
  content: "";
  position: absolute;
  left: -2%;
  right: -2%;
  bottom: 0.06em;
  height: 0.34em;
  background: linear-gradient(90deg, rgba(196,154,58,.55), rgba(127,185,154,.55));
  border-radius: 99px;
  z-index: -1;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1;
  padding: 1rem 1.6rem;
  border-radius: 999px;
  cursor: pointer;
  transition: transform .4s var(--ease-out), box-shadow .4s var(--ease-out), background-color .3s ease, color .3s ease;
  white-space: nowrap;
}
.btn svg { width: 1.1em; height: 1.1em; }

.btn-primary {
  background: var(--forest);
  color: #fff;
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover { background: var(--pine); transform: translateY(-3px); box-shadow: var(--shadow-card); }

.btn-gold {
  background: linear-gradient(180deg, var(--gold-lt), var(--gold));
  color: #3a2c08;
  box-shadow: 0 16px 36px -16px rgba(196,154,58,.7);
}
.btn-gold:hover { transform: translateY(-3px); box-shadow: 0 24px 50px -18px rgba(196,154,58,.85); }

.btn-ghost {
  background: transparent;
  color: var(--forest);
  border: 1.5px solid rgba(20,67,47,.22);
}
.btn-ghost:hover { border-color: var(--forest); background: rgba(20,67,47,.04); transform: translateY(-2px); }

.btn-light {
  background: #fff;
  color: var(--forest);
  box-shadow: var(--shadow-soft);
}
.btn-light:hover { transform: translateY(-3px); box-shadow: var(--shadow-card); }

/* Arrow nudge inside buttons / links */
.btn:hover .arrow, .link-arrow:hover .arrow { transform: translateX(4px); }
.arrow { transition: transform .35s var(--ease-out); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-weight: 600;
  color: var(--fern);
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  transition: background-color .45s ease, box-shadow .45s ease, padding .45s ease, border-color .45s ease;
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(251, 248, 241, 0.85);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  box-shadow: 0 10px 30px -22px rgba(14,42,30,.5);
  border-color: rgba(20,67,47,.08);
}

.nav-link {
  position: relative;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--ink);
  transition: color .25s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  height: 2px; width: 0;
  background: var(--gold);
  border-radius: 2px;
  transition: width .3s var(--ease-out);
}
.nav-link:hover { color: var(--forest); }
.nav-link:hover::after { width: 100%; }

/* Mobile menu */
.mobile-menu {
  transition: opacity .4s ease, visibility .4s ease;
}
.mobile-menu.hidden-menu { opacity: 0; visibility: hidden; pointer-events: none; }
.mobile-panel { transition: transform .5s var(--ease-out); }
.mobile-menu.hidden-menu .mobile-panel { transform: translateX(105%); }

.burger span {
  display: block; height: 2px; width: 24px;
  background: var(--ink); border-radius: 2px;
  transition: transform .35s var(--ease-out), opacity .25s ease;
}
.burger span + span { margin-top: 6px; }

/* ==========================================================================
   Marquee (trust strip)
   ========================================================================== */
.marquee { display: flex; overflow: hidden; user-select: none; gap: 0; }
.marquee__track {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 3.5rem;
  padding-right: 3.5rem;
  animation: marquee 32s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-100%); } }

/* ==========================================================================
   Cards
   ========================================================================== */
.card {
  background: #fff;
  border-radius: 1.75rem;
  border: 1px solid rgba(20,67,47,.07);
  transition: transform .55s var(--ease-out), box-shadow .55s var(--ease-out), border-color .4s ease;
}

/* Product card */
.product-card { position: relative; overflow: hidden; }
.product-card .media {
  background: radial-gradient(120% 100% at 50% 0%, #fff 0%, var(--bone) 100%);
  transition: background .5s ease;
}
.product-card img {
  transition: transform .7s var(--ease-out);
}
.product-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-lift); border-color: rgba(127,185,154,.4); }
.product-card:hover img { transform: scale(1.07) rotate(-1.5deg); }

/* Slide-up add-to-cart action */
.product-card .quick-add {
  transform: translateY(130%);
  opacity: 0;
  transition: transform .5s var(--ease-out), opacity .4s ease;
}
.product-card:hover .quick-add { transform: translateY(0); opacity: 1; }

/* Benefit / feature card */
.feature-card { transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out), background-color .4s ease; }
.feature-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-card); }
.feature-card:hover .feature-ico { transform: rotate(-6deg) scale(1.08); }
.feature-ico { transition: transform .5s var(--ease-out); }

/* Category tile */
.cat-tile { position: relative; overflow: hidden; transition: transform .55s var(--ease-out), box-shadow .55s var(--ease-out); }
.cat-tile:hover { transform: translateY(-8px); box-shadow: var(--shadow-lift); }
.cat-tile .glow { transition: opacity .5s ease, transform .6s var(--ease-out); }
.cat-tile:hover .glow { opacity: .9; transform: scale(1.15); }

/* ==========================================================================
   Star rating
   ========================================================================== */
.stars { display: inline-flex; gap: 2px; color: var(--gold); }
.stars svg { width: 1rem; height: 1rem; }

/* ==========================================================================
   Testimonials slider
   ========================================================================== */
.testi-track {
  display: flex;
  transition: transform .7s var(--ease-out);
}
.testi-slide { flex: 0 0 100%; }
.testi-dot {
  width: 9px; height: 9px; border-radius: 99px;
  background: rgba(255,255,255,.3);
  transition: width .4s var(--ease-out), background-color .3s ease;
}
.testi-dot.active { width: 30px; background: var(--gold); }

/* ==========================================================================
   FAQ accordion
   ========================================================================== */
.faq-item { transition: border-color .3s ease, background-color .3s ease; }
.faq-q { cursor: pointer; }
.faq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .45s var(--ease-out);
}
.faq-a > div { overflow: hidden; }
.faq-item.open .faq-a { grid-template-rows: 1fr; }
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-icon { transition: transform .4s var(--ease-out); }

/* ==========================================================================
   Scroll reveal
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .9s var(--ease-out), transform .9s var(--ease-out);
  will-change: opacity, transform;
}
.reveal.in { opacity: 1; transform: none; }
.reveal.from-left  { transform: translateX(-40px); }
.reveal.from-right { transform: translateX(40px); }
.reveal.scale-in   { transform: scale(.94); }

.d-1 { transition-delay: .08s; }
.d-2 { transition-delay: .16s; }
.d-3 { transition-delay: .24s; }
.d-4 { transition-delay: .32s; }
.d-5 { transition-delay: .40s; }
.d-6 { transition-delay: .48s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none; }
  .float, .marquee__track, .spin-slow { animation: none !important; }
  html { scroll-behavior: auto; }
}

/* ==========================================================================
   Animations
   ========================================================================== */
.float { animation: float 6s ease-in-out infinite; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-16px); } }

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

.spin-slow { animation: spin 26s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.pulse-ring { animation: pulsering 2.6s ease-out infinite; }
@keyframes pulsering {
  0% { box-shadow: 0 0 0 0 rgba(196,154,58,.45); }
  70% { box-shadow: 0 0 0 16px rgba(196,154,58,0); }
  100% { box-shadow: 0 0 0 0 rgba(196,154,58,0); }
}

/* Back-to-top */
.to-top { transition: opacity .4s ease, transform .4s var(--ease-out); }
.to-top.hide { opacity: 0; transform: translateY(20px) scale(.8); pointer-events: none; }

/* Newsletter input */
.news-input {
  background: rgba(255,255,255,.08);
  border: 1.5px solid rgba(255,255,255,.18);
  transition: border-color .3s ease, background-color .3s ease;
}
.news-input:focus { outline: none; border-color: var(--gold-lt); background: rgba(255,255,255,.14); }

/* Footer links */
.foot-link { transition: color .25s ease, padding-left .3s var(--ease-out); }
.foot-link:hover { color: #fff; padding-left: 6px; }

/* Pill / badge */
.pill {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .78rem; font-weight: 600;
  padding: .4rem .85rem; border-radius: 99px;
}

/* Marquee divider dot */
.dot { width: 6px; height: 6px; border-radius: 99px; background: var(--gold); flex: none; }

/* Generic image zoom on hover for editorial blocks */
.zoom-img { transition: transform .9s var(--ease-out); }
.zoom-wrap:hover .zoom-img { transform: scale(1.06); }
