:root {
  --cocoa: #3a2418;
  --cocoa-2: #5a3a26;
  --dawn: #f28c38;
  --dawn-2: #ffb35c;
  --cream: #f7eedc;
  --salt: #6fa8c7;
  --ink: #241710;
  --muted: #7a6656;
  --card: #ffffff;
  --line: #ecdcc8;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(59, 36, 22, 0.12);
}
* { box-sizing: border-box; }
body { margin: 0; font-family: Inter, system-ui, -apple-system, Segoe UI, Arial, sans-serif; color: var(--ink); background: var(--cream); line-height: 1.55; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: Fredoka, Nunito, Arial, sans-serif; line-height: 1.12; margin: 0 0 0.4em; color: var(--cocoa); }
.muted { color: var(--muted); }

.demo-bar { background: var(--cocoa); color: #f8e6d2; text-align: center; font-size: 13px; padding: 6px 12px; }
.site-header { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px clamp(16px, 4vw, 48px); background: rgba(255, 246, 234, 0.95); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line); }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: Fredoka, Nunito, Arial, sans-serif; font-weight: 800; font-size: 22px; color: var(--cocoa); }
.logo-mark { width: 38px; height: 38px; }
.nav { display: flex; gap: 6px; flex-wrap: wrap; }
.nav a { text-decoration: none; padding: 8px 12px; border-radius: 999px; font-weight: 500; font-size: 15px; }
.nav a:hover, .nav a.active { background: #fbe3c9; }
.cart-link { background: var(--cocoa); color: #fff !important; }
.cart-link:hover, .cart-link.active { background: var(--cocoa-2) !important; }
.cart-count { display: inline-block; min-width: 22px; padding: 0 6px; margin-left: 4px; border-radius: 999px; background: var(--dawn); color: var(--cocoa); font-weight: 700; text-align: center; font-size: 13px; }

main { min-height: 60vh; outline: none; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 32px); }
section { padding: clamp(36px, 6vw, 72px) 0; }

.hero { background: linear-gradient(160deg, #ffe0b8 0%, #ffc58a 38%, #f28c38 100%); }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 36px; align-items: center; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--cocoa-2); background: rgba(255, 255, 255, 0.6); padding: 5px 10px; border-radius: 999px; margin-bottom: 14px; }
.hero h1 { font-size: clamp(36px, 5.4vw, 64px); }
.hero p.lead { font-size: clamp(17px, 2vw, 20px); max-width: 34em; color: var(--cocoa); }
.hero-art { display: flex; justify-content: center; }
.hero-art img { width: min(420px, 100%); filter: drop-shadow(0 22px 30px rgba(59, 36, 22, 0.35)); transform: rotate(-4deg); }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; cursor: pointer; text-decoration: none; font: inherit; font-weight: 600; padding: 13px 22px; border-radius: 999px; background: var(--cocoa); color: #fff; transition: transform 0.12s ease, background 0.12s ease; }
.btn:hover { background: var(--cocoa-2); transform: translateY(-1px); }
.btn.secondary { background: #fff; color: var(--cocoa); border: 2px solid var(--cocoa); }
.btn.small { padding: 9px 16px; font-size: 14px; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; transform: none; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.feature .icon { font-size: 28px; }
.feature h3 { font-size: 20px; margin-top: 8px; }

.grid-products { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; }
.product-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.product-card .media { background: linear-gradient(180deg, #fff1df, #ffd9ad); padding: 18px; display: flex; justify-content: center; }
.product-card .media img { height: 220px; width: auto; object-fit: contain; }
.product-card .body { padding: 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.product-card h3 { font-size: 21px; margin: 0; }
.price { font-weight: 700; font-size: 18px; color: var(--cocoa); }
.tag { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: #e7f2f8; color: #2c6a8a; margin-right: 6px; }
.card-actions { display: flex; gap: 8px; margin-top: auto; padding-top: 6px; flex-wrap: wrap; }

.detail { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 40px; align-items: start; }
.detail .media { background: linear-gradient(180deg, #fff1df, #ffd9ad); border-radius: var(--radius); padding: 28px; display: flex; justify-content: center; }
.detail .media img { max-height: 420px; width: auto; }
.qty { display: inline-flex; align-items: center; border: 2px solid var(--cocoa); border-radius: 999px; overflow: hidden; }
.qty button { border: 0; background: transparent; width: 40px; height: 40px; font-size: 20px; cursor: pointer; color: var(--cocoa); }
.qty span { min-width: 32px; text-align: center; font-weight: 700; }
.facts { width: 100%; border-collapse: collapse; margin-top: 18px; font-size: 15px; }
.facts td { border-bottom: 1px solid var(--line); padding: 8px 4px; }
.facts td:last-child { text-align: right; font-weight: 600; }
.note { font-size: 13px; color: var(--muted); }

.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.cart-row { display: grid; grid-template-columns: 72px 1fr auto auto; gap: 14px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.cart-row img { width: 72px; height: 72px; object-fit: contain; background: #fff1df; border-radius: 12px; padding: 6px; }
.link-btn { background: none; border: 0; color: #a33c1c; cursor: pointer; font: inherit; text-decoration: underline; padding: 0; }
.summary { display: grid; gap: 8px; margin-top: 16px; }
.summary div { display: flex; justify-content: space-between; }
.summary .total { font-size: 20px; font-weight: 700; border-top: 2px solid var(--cocoa); padding-top: 10px; }
.two-col { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 26px; align-items: start; }

form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: block; font-size: 14px; font-weight: 600; margin: 12px 0 5px; }
input, select { width: 100%; font: inherit; padding: 11px 12px; border: 1.5px solid #d9c3a8; border-radius: 10px; background: #fff; }
input:focus, select:focus { outline: 3px solid #ffd19c; border-color: var(--dawn); }
.error { color: #a33c1c; font-size: 13px; min-height: 18px; }
.steps { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.steps span { font-size: 13px; padding: 5px 11px; border-radius: 999px; background: #f3e4d2; color: var(--cocoa-2); }
.steps span.on { background: var(--cocoa); color: #fff; }

.confirm { text-align: center; max-width: 640px; margin: 0 auto; }
.confirm .big { font-size: 60px; }
.story { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; align-items: center; }

.site-footer { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 28px clamp(16px, 4vw, 48px); background: var(--cocoa); color: #f8e6d2; font-size: 14px; }
.footer-links { display: flex; gap: 16px; }
.footer-links a { color: #ffd9ad; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(160px); background: var(--cocoa); color: #fff; padding: 12px 18px; border-radius: 999px; box-shadow: var(--shadow); transition: transform 0.25s ease; z-index: 50; font-weight: 600; width: max-content; max-width: calc(100vw - 32px); text-align: center; }
.toast.show { transform: translateX(-50%) translateY(0); }

@media (max-width: 820px) {
  .hero-grid, .detail, .two-col, .story { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr; }
  .hero-art img { width: min(260px, 70%); }
  .detail .media img { max-height: 240px; }
  .cart-row { grid-template-columns: 56px 1fr auto; }
  .cart-row > div:nth-child(2) { grid-column: 2 / 4; }
  .cart-row .qty { grid-column: 2; justify-self: start; }
  form .row { grid-template-columns: 1fr; }
}

/* ---------- animation: popcorn that pops and flies ---------- */
.hero { position: relative; overflow: hidden; }
.popfield { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.hero .wrap { position: relative; z-index: 1; }
.kernel { position: absolute; bottom: -40px; width: 26px; height: 26px; opacity: 0; animation: pop-up var(--dur, 6s) ease-out var(--delay, 0s) infinite; }
.kernel svg { width: 100%; height: 100%; animation: spin var(--spin, 3s) linear infinite; }
@keyframes pop-up {
  0% { transform: translate(0, 0) scale(0.4); opacity: 0; }
  10% { opacity: 1; transform: translate(calc(var(--dx, 0px) * 0.2), -18vh) scale(1.15); }
  60% { opacity: 0.95; }
  100% { transform: translate(var(--dx, 0px), -105vh) scale(0.9); opacity: 0; }
}
@keyframes spin { to { transform: rotate(360deg); } }
.hero-art img { animation: float 4.5s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: rotate(-4deg) translateY(0); } 50% { transform: rotate(-1deg) translateY(-14px); } }
.hero h1 .word { display: inline-block; opacity: 0; transform: translateY(30px) scale(0.9); animation: word-in 0.6s cubic-bezier(.2,1.4,.4,1) forwards; animation-delay: calc(var(--i) * 90ms + 150ms); }
@keyframes word-in { to { opacity: 1; transform: none; } }

.reveal { opacity: 0; transform: translateY(28px) scale(0.98); transition: opacity 0.6s ease, transform 0.6s cubic-bezier(.2,1.2,.4,1); transition-delay: var(--rd, 0ms); }
.reveal.in { opacity: 1; transform: none; }

.btn { transition: transform 0.15s cubic-bezier(.2,1.6,.4,1), background 0.15s ease, box-shadow 0.15s ease; }
.btn:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 8px 18px rgba(58, 36, 24, 0.22); }
.btn:active { transform: scale(0.96); }
.product-card { transition: transform 0.25s cubic-bezier(.2,1.3,.4,1), box-shadow 0.25s ease; }
.product-card:hover { transform: translateY(-6px) rotate(-0.6deg); box-shadow: 0 18px 36px rgba(58, 36, 24, 0.18); }
.product-card:hover .media img { animation: wiggle 0.6s ease; }
@keyframes wiggle { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-4deg) scale(1.03); } 75% { transform: rotate(4deg) scale(1.03); } }
.feature .icon { display: inline-block; }
.feature:hover .icon { animation: bounce 0.6s ease; }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-12px) scale(1.2); } 70% { transform: translateY(2px); } }

.flyer { position: fixed; z-index: 60; width: 30px; height: 30px; pointer-events: none; transition: transform 0.75s cubic-bezier(.5,-0.4,.6,1), opacity 0.75s ease; }
.cart-count.bump { animation: bump 0.45s cubic-bezier(.2,1.8,.4,1); }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.7); } 100% { transform: scale(1); } }
.burst { position: fixed; z-index: 61; width: 18px; height: 18px; pointer-events: none; animation: burst 0.7s ease-out forwards; }
@keyframes burst { to { transform: translate(var(--bx), var(--by)) scale(0.3) rotate(220deg); opacity: 0; } }

.confetti { position: fixed; top: -30px; z-index: 70; width: 22px; height: 22px; pointer-events: none; animation: fall var(--fd, 2.6s) ease-in var(--fdl, 0s) forwards; }
@keyframes fall { to { transform: translate(var(--fx, 0px), 110vh) rotate(var(--fr, 540deg)); opacity: 0.2; } }
.page-enter { animation: page-in 0.35s ease; }
@keyframes page-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal, .hero h1 .word { opacity: 1 !important; transform: none !important; }
  .popfield, .flyer, .burst, .confetti { display: none !important; }
}

.site-footer .muted { color: #d9c3a8; }
.product-card.reveal { transition: opacity .6s ease var(--rd, 0ms), transform .25s cubic-bezier(.2,1.3,.4,1), box-shadow .25s ease; }
@media (max-width: 480px) {
  .site-header { padding: 10px 12px; gap: 8px; }
  .logo { font-size: 18px; white-space: nowrap; }
  .logo-mark { width: 30px; height: 30px; }
  .nav a { padding: 6px 8px; font-size: 14px; }
}

/* Photos (AI-generated concept images of the team's pouch design) */
.hero-art .photo-hero { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); filter: none; transform: none; animation: float-flat 5s ease-in-out infinite; }
@keyframes float-flat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.moments { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.moment { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.moment img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform 0.5s ease; }
.moment:hover img { transform: scale(1.04); }
.moment figcaption { padding: 16px 18px; }
.moment figcaption h3 { font-size: 20px; margin: 0 0 4px; }
.moment figcaption p { margin: 0; }
.story-photo img { aspect-ratio: 16 / 9; }
.hero h1 { text-wrap: balance; }
.grid-products { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.product-card .media { padding: 0; background: #f6e7cf; overflow: hidden; }
.product-card .media img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; transition: transform 0.4s ease; }
.product-card:hover .media img { animation: none; transform: scale(1.05); }
.detail .media { padding: 0; background: #f6e7cf; overflow: hidden; }
.detail .media img { display: block; width: 100%; max-height: none; aspect-ratio: 4 / 5; object-fit: cover; }
.detail-photo { display: block; width: 100%; margin-top: 18px; border-radius: var(--radius); box-shadow: var(--shadow); }
@media (max-width: 820px) {
  .moments { grid-template-columns: 1fr; }
  .hero-art .photo-hero { width: 100%; }
  .detail .media img { max-height: 460px; }
}

/* Phones: logo on its own row, the four nav links in one even row below it (no wrapping into the logo). */
@media (max-width: 600px) {
  .site-header { flex-wrap: wrap; row-gap: 6px; }
  .nav { width: 100%; flex-wrap: nowrap; justify-content: space-between; gap: 4px; }
  .nav a { padding: 7px 12px; font-size: 15px; white-space: nowrap; }
}
@media (max-width: 360px) {
  .nav a { padding: 6px 8px; font-size: 14px; }
}
