/* ==========================================================================
   Mellow Crumb: mobile-first styles. Desktop layout from 900px.
   ========================================================================== */
/* Self-hosted fonts (latin subset, trimmed to the axes we use). Regenerate with tools/fetch-fonts.sh.
   Fraunces: SOFT 100, WONK 0, optical size pinned to display (144). DM Sans: optical size 14. */
@font-face {
  font-family: 'Fraunces'; font-style: normal; font-weight: 700 900; font-display: swap;
  src: url('assets/fonts/fraunces-soft-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Fraunces'; font-style: italic; font-weight: 700; font-display: swap;
  src: url('assets/fonts/fraunces-soft-italic.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans'; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url('assets/fonts/dm-sans.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --cocoa: #43251F;
  --cocoa-2: #5B342A;
  --cream: #FFF5E8;
  --cream-2: #FBE8D2;
  --pink: #F5A4C7;
  --pink-soft: #FCD6E6;
  --coral: #FF705B;
  --caramel: #E8AC53;
  --pistachio: #A9C98C;
  --velvet: #B83D54;
  --velvet-ink: #8E2338;   /* velvet text on pink (4.5:1) */
  --coral-ink: #D9432C;    /* coral text on cream, large type only */
  --kraft: #D9A066;

  --display: 'Fraunces', 'Cooper Black', Georgia, serif;
  --body: 'DM Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --pad: clamp(20px, 5vw, 72px);
  --radius: 28px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --ease-back: cubic-bezier(.34, 1.4, .64, 1);
  --shadow: 0 24px 50px -18px rgba(67, 37, 31, .45);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--cream); color: var(--cocoa);
  font: 400 17px/1.55 var(--body); overflow-x: hidden;
  padding-bottom: calc(72px + env(safe-area-inset-bottom));
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
svg { width: 1em; height: 1em; fill: currentColor; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
h1, h2, h3 {
  font-family: var(--display); font-weight: 800; line-height: .98; margin: 0;
  font-variation-settings: 'SOFT' 100, 'WONK' 0; letter-spacing: -.02em;
}
h2 { font-size: clamp(40px, 8vw, 96px); }
h2 em, h1 em, .sizes-title em, .hungry em { font-style: italic; font-weight: 700; }
p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--cocoa); color: var(--cream); padding: 10px 16px; border-radius: 99px; }
.skip:focus { top: 12px; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.fine { font-size: 13px; opacity: .8; }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid var(--cocoa); outline-offset: 3px; box-shadow: 0 0 0 3px var(--cream); }

/* Fraunces is pinned to its display cut, which runs tight at small sizes: open those up. */
.card h3, .step h3, .packed b { letter-spacing: 0; }
.card-price, .sc-price, .box-total strong, .box-lid, .co-sum .grand, .sc-index, .hero-sticker, .g-cap { letter-spacing: .02em; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 26px; border-radius: 99px; border: 2px solid transparent;
  font-weight: 700; font-size: 16px; text-decoration: none; white-space: nowrap;
  transition: transform .2s var(--ease), background-color .2s, box-shadow .2s, color .2s;
}
.btn svg { width: 20px; height: 20px; transition: transform .2s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn:hover svg { transform: translateX(3px); }
.btn:active { transform: translateY(0) scale(.97); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.btn-cocoa { background: var(--cocoa); color: var(--cream); box-shadow: 0 10px 22px -10px rgba(67,37,31,.7); }
.btn-coral { background: var(--coral); color: var(--cocoa); box-shadow: 0 10px 22px -10px rgba(255,112,91,.9); }
.btn-pink { background: var(--pink); color: var(--cocoa); }
.btn-ghost { background: transparent; border-color: currentColor; }
.btn-ghost:hover { background: rgba(255,255,255,.35); }
.btn-full { width: 100%; }
.round-btn {
  width: 54px; height: 54px; border-radius: 50%; border: 2px solid currentColor; background: transparent;
  display: grid; place-items: center; transition: transform .2s var(--ease), background-color .2s;
}
.round-btn svg { width: 22px; height: 22px; }
.round-btn:hover { transform: scale(1.06); background: rgba(255,255,255,.25); }
.round-btn:active { transform: scale(.94); }
.link-btn { background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; padding: 10px; font-size: 14px; font-weight: 600; }

/* ---------- Header ---------- */
.header {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 10px var(--pad); background: var(--pink);
  transition: background-color .3s, box-shadow .3s;
}
.header.scrolled { background: rgba(255,245,232,.94); box-shadow: 0 8px 24px -16px rgba(67,37,31,.5); backdrop-filter: blur(10px); }
.brand { display: block; background: var(--cream); border-radius: 18px; padding: 4px 10px; }
.brand img { height: 54px; width: auto; }
.nav { display: none; gap: 30px; font-weight: 600; }
.nav a { text-decoration: none; position: relative; padding: 6px 0; }
.nav a::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
.nav a:hover::after { transform: scaleX(1); }
.cart-btn {
  display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 8px 0 16px;
  border-radius: 99px; border: 0; background: var(--cocoa); color: var(--cream); font-weight: 700;
  transition: transform .2s var(--ease);
}
.cart-btn > svg { width: 22px; height: 22px; }
.cart-btn:hover { transform: translateY(-2px); }
.cart-label { display: none; }
.cart-count { min-width: 32px; height: 32px; padding: 0 8px; border-radius: 99px; display: grid; place-items: center; background: var(--pink); color: var(--cocoa); font-size: 15px; }
.cart-btn.bump { animation: bump .45s var(--ease-back); }
@keyframes bump { 40% { transform: scale(1.12); } }

/* ---------- Hero ---------- */
.hero {
  position: relative; display: grid; gap: 8px; overflow: hidden;
  padding: 8px var(--pad) 56px; background: var(--pink);
}
.hero-copy { position: relative; z-index: 2; }
.hero-title { font-size: clamp(48px, 13vw, 132px); margin: 14px 0 18px; }
.hero-title .w { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: .08em; margin-bottom: -.08em; }
.hero-title .w > * { display: inline-block; }
.hero-title em { color: var(--velvet-ink); }
.hero-lede { font-size: clamp(17px, 2vw, 21px); max-width: 30ch; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-art { position: relative; width: min(82vw, 640px); aspect-ratio: 1; margin: 0 auto; order: -1; --px: 0; --py: 0; }
.hero-blob {
  position: absolute; inset: 9%; background: var(--coral);
  border-radius: 58% 42% 55% 45% / 47% 58% 42% 53%;
  animation: blob 14s ease-in-out infinite alternate;
  translate: calc(var(--px) * -10px) calc(var(--py) * -10px);
}
@keyframes blob { to { border-radius: 44% 56% 41% 59% / 57% 45% 55% 43%; transform: rotate(14deg) scale(1.03); } }
.hero-plate, .hero-mini { position: absolute; border-radius: 50%; overflow: hidden; box-shadow: var(--shadow); }
.hero-plate img, .hero-mini img { width: 100%; height: 100%; object-fit: cover; }
.hero-plate { inset: 15%; border: 10px solid var(--cream); translate: calc(var(--px) * 16px) calc(var(--py) * 16px); }
.hero-mini { width: 30%; aspect-ratio: 1; border: 6px solid var(--cream); }
.hero-mini-a { left: 0; bottom: 4%; translate: calc(var(--px) * 30px) calc(var(--py) * 30px); }
.hero-mini-b { right: 0; top: 6%; width: 26%; translate: calc(var(--px) * 26px) calc(var(--py) * 26px); }
.deco { position: absolute; color: var(--caramel); }
.deco-1 { width: 13%; height: 13%; left: 6%; top: 10%; color: var(--cream); }
.deco-2 { width: 8%; height: 8%; right: 10%; bottom: 14%; }
.deco-3 { width: 6%; height: 6%; left: 46%; top: 0; color: var(--velvet); }
.deco-wheat { position: absolute; width: 14%; height: 40%; right: 2%; bottom: 22%; color: var(--caramel); rotate: 18deg; }
.hero-sticker {
  position: absolute; right: 2%; bottom: -1%; width: 34%; aspect-ratio: 1; border-radius: 50%;
  display: grid; place-content: center; text-align: center; padding: 8px;
  background: var(--cocoa); color: var(--cream); font: 700 clamp(12px, 2.4vw, 17px)/1.15 var(--display);
  font-variation-settings: 'SOFT' 100; rotate: -10deg; box-shadow: var(--shadow);
}
.hero-sticker b { color: var(--pink); font-style: italic; }

/* Entrance choreography (JS on, motion allowed) */
.js .hero-title .w > * { transform: translateY(110%); animation: rise .9s var(--ease) forwards; animation-delay: calc(var(--d) * 70ms + 150ms); }
.js .hero-in { opacity: 0; animation: fadeUp .8s var(--ease) forwards; animation-delay: calc(var(--d) * 70ms + 150ms); }
.js .hero-plate { animation: plateIn 1.1s var(--ease) .2s backwards, float 6s ease-in-out 1.4s infinite alternate; }
.js .hero-mini, .js .hero-sticker, .js .deco, .js .deco-wheat { animation: popIn .7s var(--ease-back) backwards; }
.js .hero-mini-a { animation-delay: .7s; }
.js .hero-mini-b { animation-delay: .8s; }
.js .deco-1 { animation: popIn .6s var(--ease-back) .9s backwards, twinkle 3.2s ease-in-out 1.6s infinite; }
.js .deco-2 { animation: popIn .6s var(--ease-back) 1s backwards, twinkle 3.8s ease-in-out 2s infinite; }
.js .deco-3 { animation: popIn .6s var(--ease-back) 1.05s backwards, twinkle 2.8s ease-in-out 1.8s infinite; }
.js .deco-wheat { animation-delay: .95s; }
.js .hero-sticker { animation-delay: 1.1s; }
@keyframes rise { to { transform: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes plateIn { from { opacity: 0; transform: scale(.82) rotate(-14deg); } }
@keyframes popIn { from { opacity: 0; transform: scale(.4); } }
@keyframes float { from { transform: translateY(0) rotate(0); } to { transform: translateY(-12px) rotate(2deg); } }
@keyframes twinkle { 50% { transform: scale(.7) rotate(20deg); opacity: .7; } }

/* ---------- Box sizes strip ---------- */
.sizes { padding: 56px var(--pad); text-align: center; }
.sizes-title { font: 800 clamp(30px, 5vw, 56px)/1.05 var(--display); font-variation-settings: 'SOFT' 100; letter-spacing: -.02em; }
.sizes-title em { color: var(--coral-ink); }
.sizes-row { display: flex; justify-content: center; flex-wrap: wrap; gap: 16px; margin-top: 30px; }
.size-card {
  position: relative; flex: 1 1 150px; max-width: 260px; min-height: 190px; padding: 22px 16px 18px;
  border: 0; border-radius: var(--radius); background: var(--c, var(--pink));
  display: grid; place-content: center; gap: 2px; text-align: center;
  transition: transform .3s var(--ease), box-shadow .3s;
}
.size-card:nth-child(3n+1) { --c: var(--pink); }
.size-card:nth-child(3n+2) { --c: var(--caramel); }
.size-card:nth-child(3n) { --c: var(--pistachio); }
.size-card:hover { transform: translateY(-6px) rotate(-1.5deg); box-shadow: var(--shadow); }
.size-num { font: 900 clamp(84px, 12vw, 130px)/.8 var(--display); font-variation-settings: 'SOFT' 100; letter-spacing: -.04em; }
.size-label { font-weight: 700; font-size: 17px; }
.size-from { font-size: 14px; opacity: .85; }

/* ---------- Marquee ---------- */
.marquee { background: var(--cocoa); color: var(--pink); overflow: hidden; padding: 16px 0; }
.marquee-track { display: flex; align-items: center; gap: 28px; width: max-content; animation: marquee 40s linear infinite; font: 700 clamp(24px, 3.4vw, 40px)/1 var(--display); font-variation-settings: 'SOFT' 100; font-style: italic; }
.marquee-track svg { width: 22px; height: 22px; color: var(--caramel); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Flavour showcase ---------- */
.showcase {
  --bg: #F6DDB8; --ink: var(--cocoa); --accent: #C8843A;
  position: relative; overflow: clip; min-height: 100svh;
  display: grid; align-content: start; gap: 12px;
  grid-template-areas: 'copyhead' 'stage' 'dots' 'copy' 'thumbs';
  padding: 20px var(--pad) 40px; background: var(--bg); color: var(--ink);
  transition: background-color .6s var(--ease), color .6s var(--ease);
  touch-action: pan-y;
}
.sc-ghost {
  position: absolute; left: 50%; bottom: -.12em; translate: -50% 0; z-index: 0; white-space: nowrap; pointer-events: none;
  font: 900 clamp(110px, 24vw, 380px)/1 var(--display); font-variation-settings: 'SOFT' 100; letter-spacing: -.04em;
  color: transparent; -webkit-text-stroke: 2px var(--accent); opacity: .5;
}
.sc-copy { grid-area: copy; position: relative; z-index: 2; display: contents; }
.sc-copy > .eyebrow, .sc-index { grid-area: copyhead; }
.sc-copy > .eyebrow { align-self: start; }
.sc-index { justify-self: end; font: 700 18px/1 var(--display); font-variation-settings: 'SOFT' 100; }
.sc-index b { font-size: 34px; }
.sc-text { grid-area: copy; position: relative; z-index: 2; }
.sc-name { font-size: clamp(56px, 14vw, 150px); }
.sc-desc { margin-top: 12px; max-width: 36ch; font-size: 17px; }
/* Ingredient / allergen badges (config tags) */
.tags { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 99px; border: 1.5px solid currentColor; opacity: .85; }
.card .tags { margin-top: 4px; }
.sc-price { margin-top: 12px; font: 800 26px/1 var(--display); font-variation-settings: 'SOFT' 100; }
.sc-actions {
  grid-area: thumbs; position: sticky; bottom: calc(84px + env(safe-area-inset-bottom)); z-index: 3;
  display: flex; gap: 10px; align-items: center;
  /* opaque while stuck so content scrolls beneath instead of overlapping */
  background: var(--bg); margin: 0 calc(var(--pad) * -1); padding: 10px var(--pad);
  transition: background-color .6s var(--ease);
}
.sc-add { flex: 1; }
.showcase[data-dark] .btn-cocoa { background: var(--pink); color: var(--cocoa); }
.sc-stage { grid-area: stage; position: relative; z-index: 1; width: min(66vw, 42svh, 600px); aspect-ratio: 1; margin: 0 auto; }
.sc-ring { position: absolute; inset: 2%; border-radius: 50%; background: var(--accent); opacity: .35; transition: background-color .6s; }
.sc-photo { position: absolute; inset: 8%; border-radius: 50%; overflow: hidden; border: 10px solid rgba(255,255,255,.65); box-shadow: 0 40px 60px -24px rgba(0,0,0,.45); }
.sc-photo img { width: 100%; height: 100%; object-fit: cover; }
.sc-spark { position: absolute; color: var(--accent); }
.sc-spark-1 { width: 12%; height: 12%; right: 2%; top: 6%; }
.sc-spark-2 { width: 7%; height: 7%; left: 4%; bottom: 10%; }
.js .sc-spark { animation: twinkle 3.4s ease-in-out infinite; }
.sc-thumbs { display: flex; grid-area: dots; justify-content: center; position: relative; z-index: 2; gap: 10px; }
.thumb {
  display: grid; justify-items: center; gap: 6px; padding: 6px; border: 0; background: none;
  font-size: 13px; font-weight: 700; opacity: .65; transition: opacity .2s, transform .2s var(--ease);
}
.thumb img { width: 58px; height: 58px; border-radius: 50%; object-fit: cover; border: 3px solid transparent; transition: border-color .2s; }
.thumb:hover { opacity: 1; transform: translateY(-3px); }
.thumb[aria-pressed='true'] { opacity: 1; }
.thumb[aria-pressed='true'] img { border-color: currentColor; }
/* Phones: thumbnails collapse into swipe dots (28px tap targets) */
@media (max-width: 599px) {
  .sc-thumbs { gap: 2px; margin-top: -4px; }
  .thumb { width: 28px; height: 28px; padding: 0; place-items: center; opacity: 1; }
  .thumb img, .thumb span { display: none; }
  .thumb::before { content: ''; width: 9px; height: 9px; border-radius: 99px; background: currentColor; opacity: .35; transition: width .3s var(--ease), opacity .3s; }
  .thumb[aria-pressed='true']::before { width: 24px; opacity: 1; }
  .thumb:hover { transform: none; }
}

/* ---------- Box builder ---------- */
.builder { padding: 80px var(--pad); background: var(--cream); }
.builder-head { text-align: center; max-width: 720px; margin: 0 auto; }
.builder-head h2 em { color: var(--coral-ink); }
.builder-head p:last-child { margin-top: 14px; font-size: 18px; }
.size-pick { border: 0; padding: 0; margin: 28px auto 14px; display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.size-pick label { position: relative; }
.size-pick input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.size-pick span {
  display: inline-flex; align-items: center; min-height: 50px; padding: 0 clamp(14px, 4vw, 22px); border-radius: 99px; white-space: nowrap;
  border: 2px solid var(--cocoa); font-weight: 700; transition: background-color .2s, color .2s, transform .2s var(--ease);
}
.size-pick input:checked + span { background: var(--cocoa); color: var(--cream); }
.size-pick input:focus-visible + span { outline: 3px solid var(--coral); outline-offset: 3px; }
.size-pick label:hover span { transform: translateY(-2px); }
.builder-tools { display: flex; justify-content: center; margin-bottom: 34px; }
.builder-tools .btn { min-height: 46px; font-size: 15px; }
.builder-tools svg { color: var(--coral-ink); }
.builder-grid { display: grid; gap: 28px; max-width: 1280px; margin: 0 auto; }
.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
.card {
  --bg: var(--cream-2); --ink: var(--cocoa); --accent: var(--caramel);
  position: relative; display: grid; grid-template-columns: 112px 1fr; gap: 16px; align-items: center;
  padding: 18px; border-radius: 32px; background: var(--bg); color: var(--ink); overflow: hidden;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.card::before {
  content: ''; position: absolute; width: 180px; height: 180px; left: -60px; top: -60px; border-radius: 50%;
  background: var(--accent); opacity: .3; transition: transform .5s var(--ease);
}
.card-img { position: relative; width: 112px; aspect-ratio: 1; border-radius: 50%; overflow: hidden; border: 5px solid rgba(255,255,255,.7); box-shadow: 0 16px 28px -14px rgba(0,0,0,.5); }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.card-body { position: relative; display: grid; gap: 4px; }
.card h3 { font-size: 30px; }
.card-desc { font-size: 14px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; flex-wrap: wrap; }
.card-price { font: 800 20px/1 var(--display); font-variation-settings: 'SOFT' 100; white-space: nowrap; }
.add-btn {
  min-height: 46px; padding: 0 20px; border-radius: 99px; border: 0; background: var(--ink); color: var(--bg);
  font-weight: 700; transition: transform .2s var(--ease);
}
.add-btn:hover { transform: scale(1.05); }
.add-btn:active { transform: scale(.94); }
.add-btn:disabled { opacity: .4; cursor: not-allowed; transform: none; }
.stepper { display: inline-flex; align-items: center; gap: 4px; padding: 4px; border-radius: 99px; background: var(--ink); color: var(--bg); }
.stepper button { width: 38px; height: 38px; border-radius: 50%; border: 0; background: transparent; color: inherit; font-size: 22px; font-weight: 700; line-height: 1; transition: background-color .15s; }
.stepper button:hover { background: rgba(255,255,255,.18); }
.stepper button:disabled { opacity: .35; cursor: not-allowed; }
.stepper output { min-width: 26px; text-align: center; font-weight: 800; }
.card.soldout { opacity: .6; }
.card-flag { position: absolute; right: 14px; top: 14px; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 99px; background: var(--cocoa); color: var(--cream); }
@media (hover: hover) {
  .card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
  .card:hover .card-img img { transform: scale(1.08) rotate(4deg); }
  .card:hover::before { transform: scale(1.25); }
}

/* Box panel: bottom sheet on mobile, sticky sidebar on desktop */
.box-panel {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
  background: var(--cocoa); color: var(--cream); border-radius: 26px 26px 0 0;
  box-shadow: 0 -12px 30px -12px rgba(0,0,0,.4); padding-bottom: env(safe-area-inset-bottom);
  transition: transform .35s var(--ease);
}
.box-panel.tucked:not(.open) { transform: translateY(110%); }
.box-bar {
  width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px var(--pad);
  background: none; border: 0; color: inherit; text-align: left; min-height: 72px;
}
.bar-slots { display: flex; }
.bar-slots i { width: 30px; height: 30px; margin-right: -10px; border-radius: 50%; border: 2px solid var(--cocoa); background: var(--cocoa-2) center / cover; }
.bar-text { flex: 1; display: grid; line-height: 1.2; margin-left: 10px; }
.bar-text span { font-size: 14px; opacity: .85; }
.bar-cta { background: var(--coral); color: var(--cocoa); font-weight: 700; padding: 12px 18px; border-radius: 99px; white-space: nowrap; }
.box-panel.full .bar-cta { animation: bump .5s var(--ease-back); }
.box-body { display: none; padding: 4px var(--pad) 20px; max-height: 72svh; overflow-y: auto; }
.box-panel.open .box-body { display: block; animation: sheetUp .35s var(--ease); }
@keyframes sheetUp { from { transform: translateY(30px); opacity: 0; } }
.sheet-backdrop { position: fixed; inset: 0; z-index: 44; background: rgba(43,22,18,.5); }
.box-visual { position: relative; perspective: 900px; }
/* The lid swings shut over the box once it's full */
.box-cover {
  position: absolute; inset: 0; z-index: 2; border-radius: 18px; overflow: hidden;
  display: grid; place-content: center; justify-items: center; gap: 6px; text-align: center;
  background: var(--pink); color: var(--cocoa); box-shadow: 0 18px 30px -12px rgba(0,0,0,.5);
  transform-origin: top center; transform: rotateX(-110deg); opacity: 0; pointer-events: none;
  transition: transform .75s var(--ease-back), opacity .25s;
}
.box-cover b { position: relative; font: 800 30px/1 var(--display); font-variation-settings: 'SOFT' 100; }
.box-cover small { position: relative; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; font-size: 12px; }
.cover-ribbon { position: absolute; inset: 0 auto 0 50%; width: 26px; translate: -50% 0; background: var(--velvet); opacity: .85; }
.cover-ribbon::after { content: ''; position: absolute; left: -160px; right: -160px; top: 50%; height: 26px; translate: 0 -50%; background: inherit; }
.box-cover b, .box-cover small { background: var(--pink); padding: 4px 12px; border-radius: 99px; }
.box-panel.closed .box-cover { transform: none; opacity: 1; transition: transform .75s var(--ease-back), opacity .1s; }
.box-lid {
  display: flex; justify-content: space-between; align-items: center; padding: 12px 18px; border-radius: 18px 18px 6px 6px;
  background: var(--pink); color: var(--cocoa); font: 800 18px/1 var(--display); font-variation-settings: 'SOFT' 100;
}
.box-lid svg { width: 18px; height: 18px; }
.box-tray {
  --cols: 2; display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 92px)); justify-content: center; gap: 12px;
  margin-top: 6px; padding: 16px; border-radius: 6px 6px 18px 18px; background: var(--kraft);
  box-shadow: inset 0 6px 16px rgba(67,37,31,.35);
}
.slot { aspect-ratio: 1; border-radius: 50%; background: rgba(67,37,31,.28); box-shadow: inset 0 4px 10px rgba(0,0,0,.25); display: grid; place-items: center; color: rgba(255,245,232,.6); font-size: 22px; overflow: hidden; }
.slot img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; border: 3px solid var(--cream); }
.slot.pop img { animation: slotPop .45s var(--ease-back); }
@keyframes slotPop { from { transform: scale(.3) rotate(-30deg); opacity: 0; } }
.box-panel.shake .box-tray { animation: shake .4s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.box-caption { margin: 14px 0 6px; font-weight: 700; text-align: center; }
.box-lines { list-style: none; margin: 0; padding: 0; }
.box-lines li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed rgba(255,245,232,.25); font-size: 15px; }
.box-lines button { width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid currentColor; background: none; color: inherit; font-weight: 700; line-height: 1; }
.box-total { display: flex; justify-content: space-between; align-items: baseline; margin: 14px 0 6px; font-weight: 700; }
.box-total strong { font: 800 26px/1 var(--display); font-variation-settings: 'SOFT' 100; }
.box-body .fine { margin-bottom: 14px; }
.box-body .btn:disabled { background: transparent; color: var(--cream); border: 2px dashed rgba(255,245,232,.5); box-shadow: none; opacity: 1; }
.box-body .link-btn { display: block; margin: 6px auto 0; color: inherit; }
.btn-outline-cream { background: transparent; color: var(--cream); border-color: rgba(255,245,232,.6); margin-top: 10px; }
.btn-outline-cream:hover { background: rgba(255,245,232,.1); }
/* Packed (finished) boxes, stacked above the box being filled */
.packed { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.packed:empty { display: none; }
.packed li {
  display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 14px; background: var(--pink); color: var(--cocoa); font-size: 13px; line-height: 1.3;
  animation: slotPop .4s var(--ease-back);
}
.packed b { font-family: var(--display); font-variation-settings: 'SOFT' 100; font-size: 15px; }
.packed-price { font-weight: 700; white-space: nowrap; }
.packed button { width: 30px; height: 30px; border-radius: 50%; border: 0; background: var(--cocoa); color: var(--cream); font-size: 18px; line-height: 1; }
.box-panel :focus-visible, .story :focus-visible, .footer :focus-visible, .showcase[data-dark] :focus-visible { outline-color: var(--cream); box-shadow: 0 0 0 3px var(--cocoa); }

/* ---------- How it works ---------- */
.how { padding: 80px var(--pad); background: var(--coral); text-align: center; }
.how h2 em { color: var(--cocoa); }
.steps { list-style: none; padding: 0; margin: 40px auto 0; display: grid; gap: 18px; max-width: 1200px; counter-reset: s; }
.step { counter-increment: s; position: relative; background: var(--cream); border-radius: var(--radius); padding: 30px 24px; text-align: left; box-shadow: 0 18px 30px -20px rgba(67,37,31,.6); }
.step:nth-child(2) { background: var(--pink-soft); }
.step:nth-child(3) { background: #F9E2B8; }
.step::after { content: '0' counter(s); position: absolute; right: 24px; top: 20px; font: 900 44px/1 var(--display); font-variation-settings: 'SOFT' 100; opacity: .2; }
.step-icon { width: 64px; height: 64px; color: var(--cocoa); margin-bottom: 16px; }
.step h3 { font-size: 28px; margin-bottom: 8px; }
.js .step.in .step-icon { animation: bob 1s var(--ease-back) calc(var(--d, 0) * 120ms + 300ms) both; }
@keyframes bob { from { transform: translateY(14px) rotate(-12deg) scale(.7); opacity: 0; } }

/* ---------- Story ---------- */
.story { display: grid; gap: 40px; padding: 90px var(--pad); background: var(--cocoa); color: var(--cream); overflow: hidden; }
.story-art { position: relative; min-height: 420px; }
.story-photo { position: absolute; border-radius: var(--radius); overflow: hidden; box-shadow: 0 30px 50px -20px rgba(0,0,0,.6); }
.story-photo img { width: 100%; height: 100%; object-fit: cover; }
.story-photo-a { width: 62%; aspect-ratio: 3/4; left: 0; top: 0; rotate: -4deg; }
.story-photo-b { width: 50%; aspect-ratio: 3/4; right: 0; bottom: 0; rotate: 5deg; border: 8px solid var(--pink); }
.story-wheat { position: absolute; width: 70px; height: 210px; right: 8%; top: -10px; color: var(--caramel); rotate: 14deg; }
.story h2 em { color: var(--pink); display: block; }
.story-copy p:not(.eyebrow):not(.signature) { margin-top: 18px; font-size: 18px; max-width: 46ch; opacity: .92; }
.story-copy .eyebrow { color: var(--caramel); margin-bottom: 16px; }
.signature { margin-top: 26px; font: italic 700 26px/1 var(--display); font-variation-settings: 'SOFT' 100; color: var(--pink); }

/* ---------- Gallery ---------- */
.gallery { padding: 80px 0; background: var(--cream); }
.gallery-head { display: flex; justify-content: space-between; align-items: end; gap: 20px; padding: 0 var(--pad); }
.gallery-head h2 em { color: var(--velvet); }
.gallery-nav { display: none; gap: 10px; }
.gallery-track {
  list-style: none; margin: 34px 0 0; padding: 10px var(--pad) 24px; display: flex; gap: 18px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 var(--pad); scrollbar-width: thin;
}
.gallery-track li { flex: 0 0 72vw; max-width: 380px; scroll-snap-align: start; }
.gallery-track li:nth-child(even) { margin-top: 36px; }
.g-photo { position: relative; aspect-ratio: 3/4; border-radius: var(--radius); overflow: hidden; background: var(--cream-2); }
.g-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.gallery-track li:hover .g-photo img { transform: scale(1.05); }
.g-cap { margin-top: 12px; font: 700 22px/1.1 var(--display); font-variation-settings: 'SOFT' 100; }

/* ---------- Sweet moments ---------- */
.moments { position: relative; padding: 90px var(--pad); background: var(--pink); text-align: center; overflow: hidden; }
.moments h2 em { color: var(--velvet-ink); }
.moments p { max-width: 44ch; margin: 18px auto 26px; font-size: 18px; }
.moments-spark { position: absolute; width: 140px; height: 140px; right: -30px; top: 20px; color: var(--cream); opacity: .7; }

/* ---------- FAQ ---------- */
.faq { padding: 80px var(--pad); background: var(--cream); }
.faq h2 { text-align: center; }
.faq h2 em { color: var(--coral-ink); }
.faq-list { max-width: 820px; margin: 36px auto 0; display: grid; gap: 12px; }
.faq details { background: var(--cream-2); border-radius: 22px; padding: 0 22px; transition: background-color .2s; }
.faq details[open] { background: var(--pink-soft); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 64px; font-weight: 700; font-size: 18px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--cocoa); color: var(--cream); font-size: 22px; transition: transform .3s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 20px; max-width: 64ch; }

/* ---------- Footer ---------- */
.footer { background: var(--cocoa); color: var(--cream); padding: 70px var(--pad) 30px; overflow: hidden; }
.footer-hungry { display: grid; justify-items: start; gap: 24px; padding-bottom: 50px; border-bottom: 1px solid rgba(255,245,232,.2); }
.hungry { font: 900 clamp(72px, 17vw, 240px)/.85 var(--display); font-variation-settings: 'SOFT' 100; letter-spacing: -.04em; color: var(--pink); }
.hungry em { color: var(--caramel); }
.footer-grid { display: grid; gap: 30px; padding: 40px 0; }
.footer-logo { background: var(--cream); border-radius: var(--radius); padding: 14px; width: 210px; }
.footer h3 { font-size: 22px; margin-bottom: 12px; color: var(--pink); }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-links a { text-decoration: none; display: inline-flex; align-items: center; gap: 8px; min-height: 32px; }
.footer-links a:hover { text-decoration: underline; }
.footer-links svg { width: 18px; height: 18px; }
.copyright { font-size: 14px; opacity: .7; }

/* ---------- Reference-photo label (CONFIG.photosAreReference) ---------- */
.ref-photos .ph::after {
  content: 'Reference photo'; position: absolute; left: 50%; bottom: 7%; translate: -50% 0;
  font: 700 10px/1 var(--body); letter-spacing: .08em; text-transform: uppercase; white-space: nowrap;
  padding: 5px 9px; border-radius: 99px; background: rgba(67,37,31,.72); color: var(--cream); pointer-events: none;
}
.ref-photos .hero-mini::after, .ref-photos .card-img::after, .ref-photos .slot::after { content: none; }

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: calc(var(--d, 0) * 100ms); }
.js .reveal.in { opacity: 1; transform: none; }
.js .story-photo.reveal { transform: translateY(40px) scale(.96); }
.js .story-photo.reveal.in { transform: none; }

/* ---------- Fly-to-box ---------- */
.fly { position: fixed; z-index: 100; border-radius: 50%; object-fit: cover; pointer-events: none; box-shadow: var(--shadow); border: 4px solid var(--cream); }

/* ---------- Checkout dialog ---------- */
.checkout {
  width: 100%; max-width: 100%; max-height: 94svh; margin: auto 0 0; padding: 0; border: 0;
  border-radius: 28px 28px 0 0; background: var(--cream); color: var(--cocoa); overflow-y: auto;
}
.checkout[open] { animation: sheetUp .35s var(--ease); }
.checkout::backdrop { background: rgba(43,22,18,.6); backdrop-filter: blur(3px); }
.checkout form { padding: 20px 22px 28px; }
.co-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 20px; }
.co-steps { list-style: none; display: flex; gap: 6px; margin: 0; padding: 0; font-size: 12px; font-weight: 700; flex: 1; }
.co-steps li { flex: 1; padding-top: 8px; border-top: 4px solid rgba(67,37,31,.18); opacity: .55; }
.co-steps li.done, .co-steps li[aria-current] { border-color: var(--coral); opacity: 1; }
.close-btn { width: 44px; height: 44px; flex: none; border-radius: 50%; border: 0; background: var(--cream-2); font-size: 26px; line-height: 1; }
.checkout h2 { font-size: clamp(36px, 7vw, 52px); margin-bottom: 18px; }
.checkout h2 em { color: var(--coral-ink); }
.co-lines { list-style: none; margin: 0; padding: 0; }
.co-lines li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px dashed rgba(67,37,31,.25); }
.co-lines .co-box-head { margin-top: 10px; padding: 8px 12px; border: 0; border-radius: 12px; background: var(--pink-soft); font-weight: 700; }
.co-lines .co-box-head:first-child { margin-top: 0; }
.co-lines img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.co-lines span { flex: 1; font-weight: 600; }
.co-nav { display: flex; gap: 10px; justify-content: space-between; margin-top: 22px; }
.co-nav .btn { flex: 1; padding: 0 16px; }
.co-nav-stack { flex-direction: column; }
.fields { display: grid; gap: 14px; align-items: start; }
/* flex so "(optional)" stays beside the label text; controls and messages take full rows */
.field { display: flex; flex-wrap: wrap; align-content: start; gap: 6px 4px; font-weight: 700; font-size: 14px; }
.field > :is(input, select, textarea, .hint, .err) { flex-basis: 100%; }
.err:empty { display: none; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; border-radius: 14px; border: 2px solid rgba(67,37,31,.25);
  background: #fff; font-weight: 400; font-size: 16px; transition: border-color .2s;
}
.field textarea { resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--cocoa); outline: none; box-shadow: 0 0 0 3px var(--pink); }
.field [aria-invalid='true'] { border-color: var(--velvet); }
.err { color: var(--velvet); font-weight: 600; font-size: 13px; min-height: 0; }
.hint, .opt { font-weight: 400; font-size: 13px; opacity: .75; }
.co-sum { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin: 16px 0; }
.co-sum dt { opacity: .8; }
.co-sum dd { margin: 0; font-weight: 700; text-align: right; }
.co-sum .grand { font: 800 24px/1 var(--display); font-variation-settings: 'SOFT' 100; padding-top: 8px; }
.pay { border: 0; padding: 0; margin: 0 0 12px; }
.remember { display: flex; align-items: center; gap: 10px; font-size: 14px; min-height: 44px; cursor: pointer; }
.gift-fields { display: grid; gap: 14px; padding: 14px; border-radius: 16px; background: var(--pink-soft); }
.remember input { width: 20px; height: 20px; flex: none; accent-color: var(--cocoa); }
.pay legend { font-weight: 700; margin-bottom: 8px; }
.pay label { display: flex; align-items: center; gap: 10px; min-height: 44px; }
.pay input { width: 20px; height: 20px; accent-color: var(--cocoa); }
.co-who { font-size: 14px; background: var(--cream-2); border-radius: 16px; padding: 12px 14px; white-space: pre-line; }
.notice { margin-top: 12px; padding: 12px 14px; border-radius: 16px; background: var(--pink-soft); font-size: 14px; font-weight: 600; }
.co-done { text-align: center; }
.done-icon { width: 80px; height: 80px; margin: 0 auto 16px; color: var(--coral); }
.checkout h2:focus { outline: none; box-shadow: none; }
.co-ref { margin-top: 14px; font-size: 15px; }
.co-ref b { font-size: 18px; letter-spacing: .06em; }
.copy-fallback { width: 100%; margin-top: 14px; border-radius: 14px; padding: 12px; font-size: 13px; }

/* ==========================================================================
   Desktop
   ========================================================================== */
@media (min-width: 600px) {
  .card { grid-template-columns: 140px 1fr; }
  .card-img { width: 140px; }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-track li { flex-basis: 340px; }
  .sc-thumbs { grid-area: thumbs; }
  .showcase { grid-template-areas: 'copyhead' 'stage' 'copy' 'actions' 'thumbs'; }
  .sc-actions { grid-area: actions; }
}

@media (min-width: 900px) {
  body { padding-bottom: 0; }
  html { scroll-padding-top: 96px; }
  .nav { display: flex; }
  .cart-label { display: inline; }
  .brand img { height: 64px; }

  .hero { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: center; min-height: calc(100svh - 84px); padding-top: 0; padding-bottom: 40px; }
  .hero-title { font-size: clamp(56px, 7.2vw, 120px); }
  .hero-art { order: 0; width: min(100%, 72svh, 640px); }

  .showcase {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    grid-template-areas: 'copyhead stage' 'copy stage' 'actions stage' 'thumbs stage';
    grid-template-rows: auto auto auto 1fr;
    align-content: center; column-gap: 40px; padding: 70px var(--pad);
  }
  .sc-index { justify-self: start; margin-top: 44px; }
  .sc-copy > .eyebrow { margin-top: 0; }
  .sc-stage { width: min(48vw, 640px); align-self: center; }
  .sc-actions { max-width: 460px; position: relative; bottom: auto; margin: 0; padding: 0; background: none; }
  .sc-thumbs { justify-content: start; align-self: start; margin-top: 18px; }

  .builder-grid { grid-template-columns: minmax(0, 1fr) 380px; align-items: start; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card { grid-template-columns: 1fr; grid-template-rows: auto 1fr; align-items: stretch; text-align: left; padding: 24px; }
  .card-body { grid-template-rows: auto auto 1fr; }
  .card-foot { flex-wrap: nowrap; align-self: end; min-height: 48px; }
  .card-img { width: 62%; margin: 0 auto 8px; }
  .card h3 { font-size: 36px; }
  .box-panel, .box-panel.tucked:not(.open) { transform: none; }
  .box-panel { position: sticky; top: 104px; border-radius: 30px; padding: 22px; z-index: 1; box-shadow: var(--shadow); }
  .box-bar, .sheet-backdrop { display: none !important; }
  .box-body { display: block; padding: 0; max-height: none; overflow: visible; }
  .box-panel.open .box-body { animation: none; }

  .story { grid-template-columns: 1fr 1fr; align-items: center; gap: 70px; }
  .story-art { min-height: 620px; }
  .gallery-nav { display: flex; }
  .gallery-track li { flex-basis: 380px; }
  .footer-hungry { grid-template-columns: 1fr auto; align-items: end; }
  .footer-grid { grid-template-columns: 1.2fr 1fr 1fr 1fr; }

  .checkout { max-width: 580px; margin: auto; border-radius: 30px; }
  .checkout form { padding: 28px 34px 34px; }
  .fields { grid-template-columns: 1fr 1fr; }
  .field-wide { grid-column: 1 / -1; }
  .gift-fields { grid-template-columns: 1fr 1fr; }
  .gift-note { grid-column: 1 / -1; }
}

@media (min-width: 1200px) {
  .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .card h3 { font-size: 32px; }
}

/* ==========================================================================
   Reduced motion: keep everything visible, drop movement.
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important;
    transition-duration: .001ms !important; transition-delay: 0s !important;
  }
  .hero-art * { translate: none !important; }
}
