/* =====================================================================
   Little Hanniel — Marketing Site (revamp)
   Warm cream & caramel palette, MODU-inspired editorial layout.
   ===================================================================== */

/* ---------- Tokens ---------- */
:root {
  /* surfaces / paper */
  --bg-page: #FDFAF6;
  --bg-subtle: #F5EFE6;
  --surface: #FFFFFF;
  --surface-inset: #F8F2EA;

  /* cocoa ink */
  --text-strong: #2B2118;
  --text-body: #3A3028;
  --text-secondary: #5C5046;
  --text-muted: #A89E94;
  --text-accent: #8B6540;

  /* caramel accent */
  --accent: #A67C52;
  --accent-hover: #8B6540;
  --accent-press: #6F4E2E;
  --accent-soft: #EFE0C9;
  --accent-300: #E0C9A0;
  --caramel-700: #6F4E2E;
  --caramel-300: #E0C9A0;

  /* fresh + channel */
  --sage: #8A9A6B;
  --sage-soft: #DDE3CE;
  --whatsapp: #25D366;
  --instagram: #E1306C;

  /* lines */
  --border: #E8DDD3;
  --border-strong: #DBCDBE;

  /* type */
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Lora', Georgia, serif;
  --font-sans: 'Inter', -apple-system, 'Segoe UI', sans-serif;
  --font-hand: 'Gochi Hand', 'Comic Sans MS', cursive;

  /* radii */
  --radius-xs: 4px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  /* shadows (warm) */
  --shadow-sm: 0 2px 8px rgba(58, 48, 40, 0.06);
  --shadow-md: 0 8px 24px rgba(58, 48, 40, 0.08);
  --shadow-lg: 0 16px 48px rgba(58, 48, 40, 0.10);
  --shadow-accent: 0 4px 14px rgba(166, 124, 82, 0.25);
  --shadow-accent-hover: 0 14px 28px rgba(166, 124, 82, 0.40);

  /* motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* layout */
  --max-width: 1180px;
  --header-height: 140px;            /* taller focal band for the larger logo */
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg-page);
  color: var(--text-body);
  font-family: var(--font-body);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }
p { margin: 0; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }

/* ---------- Shared type roles ---------- */
.eyebrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}
.display { font-family: var(--font-display); line-height: 1.14; color: var(--text-body); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 15px 34px;
  border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.3s var(--ease-spring),
              box-shadow 0.3s var(--ease-out),
              background-color 0.3s var(--ease-out),
              color 0.3s var(--ease-out);
}
.btn--primary { background: var(--accent); color: #fff; box-shadow: var(--shadow-accent); }
.btn--primary:hover { transform: translateY(-3px) scale(1.02); box-shadow: var(--shadow-accent-hover); }
.btn--primary:active { transform: scale(0.98); }
.btn--secondary { background: transparent; color: var(--accent-hover); border-color: var(--accent); }
.btn--secondary:hover { background: var(--accent-soft); }
.btn--ghost { background: transparent; color: var(--text-secondary); }
.btn--ghost:hover { color: var(--text-body); }

/* ---------- Announcement ---------- */
.announcement {
  background: var(--accent);
  color: #fff;
  text-align: center;
  padding: 9px 16px;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* ---------- Header ---------- */
.header {
  position: static;                /* scrolls away with the page (not sticky) */
  height: var(--header-height);
  display: flex;
  align-items: center;
  background: var(--bg-page);       /* solid — backdrop blur unnecessary when not overlapping scrolled content */
}
.header__inner {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: center;        /* modu-style: logo centered */
  position: relative;             /* allows hamburger to sit on right edge */
}
.logo img { height: 124px; width: auto; }          /* new refined illustration+wordmark logo (1563x2137, aspect 0.73) — bumped larger */
.nav { display: none; }            /* top-nav links moved to slide-out overlay */

/* (hamburger removed — modu-style header is logo only) */
.nav__link {
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color 0.25s var(--ease-out);
}
.nav__link:hover { color: var(--accent); }
.nav__order {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: var(--accent);
  padding: 9px 22px;
  border-radius: var(--radius-pill);
  transition: background 0.25s var(--ease-out), transform 0.25s var(--ease-out);
}
.nav__order:hover { background: var(--accent-hover); transform: translateY(-2px); }

/* (hamburger + slide-out overlay removed — modu-style header is logo only,
   navigation lives in the hero CTA row + footer nav) */

/* ---------- Section base ---------- */
.section { padding: 96px 0; }
.section--tight { padding: 64px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 56px; }
.section-head h2 { font-family: var(--font-display); font-size: clamp(1.9rem, 3.6vw, 2.7rem); margin-top: 14px; }
.section-head p { font-family: var(--font-body); color: var(--text-secondary); margin-top: 14px; }
em { font-style: italic; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 24px 0 56px; }     /* tight top padding so the 3-button CTA row sits clearly above the fold */
.hero__hand {
  position: absolute;
  top: 48px; right: 24px;
  writing-mode: vertical-rl;
  font-family: var(--font-hand);
  font-size: 2.2rem;
  color: var(--accent-soft);
  letter-spacing: 0.06em;
  pointer-events: none;
  user-select: none;
  display: none;
}
.hero__text { max-width: 760px; margin: 0 auto; text-align: center; }
.hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4rem);
  line-height: 1.1;
  margin: 16px 0 20px;
}
.hero__lead {
  font-family: var(--font-body);
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  line-height: 1.8;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 24px;             /* tightened from 32px to pull buttons up */
}
.hero__ctas { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Modu-style hero CTA row ----------
   Source: modu.sg hero — 3 equal-width bordered buttons, sentence case,
   hover inverts to dark fill. Replaces the pill-style .btn--primary/
   secondary/ghost trio for the hero only; .btn stays for menu + contact. */
.hero__ctas--modu {
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 16px;
  margin-top: 36px;
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}
.hero-btn {
  flex: 1 1 0;
  min-width: 200px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 18px 24px;
  background: transparent;
  color: var(--text-strong);
  border: 1.5px solid var(--text-strong);
  border-radius: 4px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-transform: none;            /* sentence case, not UPPERCASE */
  text-decoration: none;
  cursor: pointer;
  transition: background 0.25s var(--ease-out), color 0.25s var(--ease-out), border-color 0.25s var(--ease-out);
}
.hero-btn:hover {
  background: var(--text-strong);
  color: #fff;
  border-color: var(--text-strong);
}
.hero-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.hero__strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 56px;
}
.hero__strip figure { margin: 0; border-radius: var(--radius-md); overflow: hidden; border: 1px solid var(--border); aspect-ratio: 4 / 5; box-shadow: var(--shadow-sm); }
.hero__strip img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease-out); }
.hero__strip figure:hover img { transform: scale(1.04); }

/* ---------- Ingredients ---------- */
.ingredients { background: var(--bg-subtle); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.ingredients__grid { display: flex; gap: 16px; max-width: 980px; margin: 0 auto; }
.ingredient { flex: 1; text-align: center; padding: 0 6px; }
.ingredient__icon { width: 64px; height: 64px; margin: 0 auto 18px; display: block; }
.ingredient__icon img { width: 64px; height: 64px; display: block; }
.ingredient__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); margin: 0 auto 18px; }
.ingredient__name { font-family: var(--font-display); font-style: italic; font-size: 1.25rem; color: var(--text-body); line-height: 1.25; }
.ingredient__note { font-family: var(--font-sans); font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-muted); margin-top: 8px; }

/* ---------- Menu (sheet + 2-col grid, Menu_Section reference) ---------- */
#menu .menu__intro { max-width: 660px; margin-left: auto; margin-right: auto; }
.menu__hand {
  font-family: var(--font-hand);
  font-size: 1.6rem;
  color: var(--accent);
  margin-top: 14px;
  transform: rotate(-2deg);
}
.menu__image-wrap {
  max-width: 920px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: clamp(12px, 2vw, 20px);
  overflow: hidden;
}
.menu__image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: calc(var(--radius-lg) - 4px);
}
.menu__note { text-align: center; margin-top: 26px; font-family: var(--font-sans); font-size: 0.76rem; letter-spacing: 0.04em; color: var(--text-muted); }
.menu__order {
  margin-top: 56px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(36px, 5vw, 52px) 40px;
  text-align: center;
}
.menu__order-title {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--text-body);
  margin: 12px 0 14px;
}
.menu__order-lead {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text-secondary);
  margin: 0 auto 28px;
  max-width: 480px;
}
.menu__order-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background-color: var(--whatsapp);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 15px 30px;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.menu__order-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }

/* ---------- Journal ---------- */
.story {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  margin-bottom: 72px;
}
.story:last-child { margin-bottom: 0; }
.story__media { border-radius: var(--radius-md); overflow: hidden; border: 1px solid var(--border); background: var(--surface-inset); }
.story__media img { width: 100%; object-fit: contain; padding: 18px; }
.story--reverse .story__media { order: 2; }
.story__date { font-family: var(--font-sans); font-size: 0.7rem; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); }
.story__title { font-family: var(--font-display); font-style: italic; font-size: clamp(1.6rem, 3vw, 2rem); color: var(--text-body); margin: 10px 0 16px; }
.story__body { font-family: var(--font-body); font-size: 1rem; line-height: 1.85; color: var(--text-secondary); }

/* ---------- Full-bleed quote ---------- */
.fullbleed { position: relative; height: 460px; overflow: hidden; }
.fullbleed img { width: 100%; height: 100%; object-fit: cover; }
.fullbleed__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(43,33,24,0.58), rgba(43,33,24,0.18));
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 24px;
}
.fullbleed__quote {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  line-height: 1.35;
  color: #fff;
  max-width: 720px;
}

/* ---------- Contact ---------- */
.contact { background: var(--bg-subtle); text-align: center; }
.contact h2 { font-family: var(--font-display); font-style: italic; font-size: clamp(2rem, 4vw, 2.7rem); margin: 14px 0 16px; }
.contact p { font-family: var(--font-body); color: var(--text-secondary); max-width: 520px; margin: 0 auto 30px; line-height: 1.8; }
.contact__links { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.channel {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: #fff;
  padding: 14px 30px;
  border-radius: var(--radius-pill);
  transition: background 0.3s var(--ease-out), transform 0.3s var(--ease-out);
}
.channel--wa { background: var(--whatsapp); }
.channel--wa:hover { background: #1fb858; transform: translateY(-2px); }
.channel--ig { background: var(--text-body); }
.channel--ig:hover { background: var(--instagram); transform: translateY(-2px); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); padding: 40px 0; }
.footer__inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 18px; }
.footer__logo img { height: 34px; }
.footer__nav { display: flex; gap: 28px; }
.footer__nav a { font-family: var(--font-sans); font-size: 0.74rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); transition: color 0.25s var(--ease-out); }
.footer__nav a:hover { color: var(--accent); }
.footer__copy { font-family: var(--font-sans); font-size: 0.7rem; color: var(--text-muted); letter-spacing: 0.04em; }

/* ---------- Floating WhatsApp ---------- */
.floating-wa {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 80;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--whatsapp);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
  transition: transform 0.3s var(--ease-spring);
}
.floating-wa:hover { transform: scale(1.08) translateY(-2px); }

/* ---------- Reveal animation (progressive enhancement) ---------- */
/* Only hide reveals once JS has confirmed it can reveal them again. */
/* Only hide reveals that JS hasn't marked visible yet.
   The :not(.is-visible) keeps specificity equal to the visible rule so the
   state transition actually wins — without it the (0,2,1) hidden selector
   would beat the (0,2,0) .reveal.is-visible selector and the page stays blank. */
html.reveal-enabled .reveal:not(.is-visible) { opacity: 0; transform: translateY(32px); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.12s; }
.reveal-d2 { transition-delay: 0.24s; }

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

/* show decorative hand word only where it won't clip */
@media (min-width: 1080px) {
  .hero__hand { display: block; }
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .section { padding: 72px 0; }
  .hero__hand { display: none; }
  .ingredients__grid { flex-wrap: wrap; gap: 28px 12px; }
  .ingredient { flex: 0 0 30%; }
  .story { grid-template-columns: 1fr; gap: 28px; }
  .story--reverse .story__media { order: 0; }
  .fullbleed { height: 360px; }
  .hero__ctas--modu { flex-direction: column; }
  .hero-btn { min-width: 0; width: 100%; }
}
@media (max-width: 560px) {
  .hero__strip { grid-template-columns: 1fr; }
  .hero__strip figure { aspect-ratio: 16 / 11; }
  .ingredient { flex: 0 0 45%; }
  .footer__inner { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .btn, .floating-wa { transition: none !important; }
}

/* =====================================================================
   modu.sg shake-bottom animation (verbatim from modu.sg pagetify CSS)
   Source: https://modu.sg/cdn/shop/t/1/assets/pagetify-page-index.css
   Triggered on the .modu-shake class instead of modu's
   [data-element-animation=element-shake-bottom] attribute selector.
   Applied to the Rolled Oats ingredient icon.
   ===================================================================== */

.modu-shake {
  display: inline-block;
  transform-origin: 50% 100%;
  animation: element-shake-bottom 3s infinite !important;
}
.modu-shake:hover { animation-play-state: paused; }

@keyframes element-shake-bottom {
  0%, 50% { transform: rotate(0); transform-origin: 50% 100%; }
  5%      { transform: rotate(3deg); }
  10%, 25%{ transform: rotate(-5deg); }
  17.5%, 32.5% { transform: rotate(5deg); }
  40%     { transform: rotate(-3deg); }
  45%     { transform: rotate(3deg); }
}

@media (prefers-reduced-motion: reduce) {
  .modu-shake { animation: none !important; transform: none !important; }
}

/* =====================================================================
   Splide 4 — Hanniel theme overrides (hero overnight-oats carousel)
   Pattern source: modu.sg pagetify CSS uses Splide v2.4.21 from
   jsDelivr. We use Splide v4 (modern API) loaded from the same CDN.
   ===================================================================== */

/* The .hero__strip wrapper still uses display:grid by default; disable
   that when it contains a Splide so the carousel controls the layout. */
.hero__strip:has(.splide) {
  display: block;
  margin-top: 56px;
}

.hanniel-splide {
  position: relative;
  background: var(--bg-page);
}

.hanniel-splide .splide__track {
  border-radius: var(--radius-md);
  overflow: hidden;
}

.hanniel-splide .splide__list {
  align-items: center;
}

.hanniel-splide .splide__slide {
  display: flex;
  justify-content: center;
}

.hanniel-splide .hero__strip-figure {
  margin: 0;
  width: 100%;
  max-width: 520px;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  background: var(--bg-subtle);
}

.hanniel-splide .hero__strip-figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease-out);
}

.hanniel-splide .hero__strip-figure:hover img {
  transform: scale(1.04);
}

/* Arrows — Hanniel round buttons */
.hanniel-splide .splide__arrow {
  width: 44px;
  height: 44px;
  background: var(--accent-soft);
  opacity: 0.95;
  border: 1px solid var(--border);
  border-radius: 50%;
  transition: background 0.25s var(--ease-out), opacity 0.25s var(--ease-out);
}
.hanniel-splide .splide__arrow:hover {
  background: var(--accent);
  opacity: 1;
}
.hanniel-splide .splide__arrow svg {
  fill: var(--text-strong);
  width: 18px;
  height: 18px;
  transition: fill 0.25s var(--ease-out);
}
.hanniel-splide .splide__arrow:hover svg { fill: #fff; }
.hanniel-splide .splide__arrow--prev { left: 0.5rem; }
.hanniel-splide .splide__arrow--next { right: 0.5rem; }

/* Dots — caramel pips */
.hanniel-splide .splide__pagination {
  bottom: -2.2rem;
  gap: 8px;
}
.hanniel-splide .splide__pagination__page {
  width: 8px;
  height: 8px;
  background: var(--border-strong);
  border: none;
  border-radius: 50%;
  opacity: 1;
  transition: background 0.25s var(--ease-out), transform 0.25s var(--ease-out);
}
.hanniel-splide .splide__pagination__page.is-active {
  background: var(--accent);
  transform: scaleX(1.6);
  border-radius: 4px;
}

/* Mobile: tighter */
@media (max-width: 720px) {
  .hanniel-splide .splide__arrow { width: 38px; height: 38px; }
  .hanniel-splide .hero__strip-figure { max-width: 360px; aspect-ratio: 4 / 5; }
}

@media (prefers-reduced-motion: reduce) {
  .hanniel-splide .splide__track { overflow: visible; }
}
