/* =========================================================================
   Ying-Li Tea — US store
   Design system + components, ported from "Ying-Li Tea.dc.html" (warm theme).
   ========================================================================= */

:root {
  --bg: #f6f1e7;
  --surface: #fffdf8;
  --ink: #2b251f;
  --muted: #6f6358;
  --soft: #6f6052;        /* darkened for WCAG AA on cream/surface */
  --accent: #3c5440;
  --accent-ink: #fffdf8;
  --clay: #985426;        /* darkened for WCAG AA at small eyebrow sizes */
  --line: #e7dfce;
  --display: 'Spectral', Georgia, serif;
  --body: 'DM Sans', system-ui, sans-serif;
  --maxw: 1200px;
  --pad: 28px;
}

/* Optional alternate palette from the design (kept available, warm is default). */
[data-theme="editorial"] {
  --bg: #ffffff;
  --surface: #f7f6f3;
  --ink: #15140f;
  --muted: #76726a;
  --soft: #9a958a;
  --accent: #1f6f54;
  --accent-ink: #ffffff;
  --clay: #1f6f54;
  --line: #e8e6df;
  --display: 'Newsreader', Georgia, serif;
  --body: 'Hanken Grotesk', system-ui, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
/* Snappier taps on touch devices: no 300ms delay, no grey flash. */
a, button, label, summary, input, textarea, .chip, .mode { touch-action: manipulation; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

::selection { background: var(--accent); color: var(--bg); }

h1, h2, h3 { font-family: var(--display); font-weight: 400; margin: 0; }
p { margin: 0; }
img { display: block; max-width: 100%; }
button { font-family: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* Accessibility utilities */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 0 0 8px 0;
  text-decoration: none;
}
.skip-link:focus { left: 0; }
.noscript-banner {
  background: var(--accent); color: var(--accent-ink); padding: 14px 20px;
  text-align: center; font-size: 14px;
}
.noscript-banner a { color: inherit; }
.link-btn {
  background: none; border: 0; padding: 0; margin-left: 6px;
  color: inherit; font: inherit; text-decoration: underline; cursor: pointer; opacity: .85;
}

/* Reset for elements that became links/buttons but keep their card/control look */
.brand-mark, .card-link, .related-card, .cat-card { text-decoration: none; color: inherit; }
.card-link, .related-card { display: block; }
.mode { font: inherit; color: inherit; }

.serif { font-family: var(--display); }
.wrap { max-width: var(--maxw); margin: 0 auto; padding-left: var(--pad); padding-right: var(--pad); }
.eyebrow {
  font-size: 12px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--clay); margin-bottom: 10px;
}

@keyframes ylFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes ylSlide { from { transform: translateX(100%); } to { transform: none; } }
@keyframes ylDim { from { opacity: 0; } to { opacity: 1; } }

/* ---- Buttons --------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px; font-size: 14px; letter-spacing: .02em; text-decoration: none;
  cursor: pointer; border: 1px solid transparent; padding: 15px 30px;
  transition: background .2s, color .2s, border-color .2s, opacity .2s;
}
.btn-solid { background: var(--ink); color: var(--bg); }
.btn-solid:hover { opacity: .88; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-block { width: 100%; }
.btn-add { padding: 11px; font-size: 13px; letter-spacing: .03em; }
.btn-buy { padding: 16px; font-size: 15px; }

/* ---- Image placeholders (tone gradient + serif monogram) ------------- */
.photo {
  position: relative; overflow: hidden; border-radius: 14px;
  background: var(--tone, linear-gradient(150deg, #efe9da, #ded3bd));
}
.photo.r3 { border-radius: 12px; }
.photo.r4 { border-radius: 16px; }
.photo::after {
  content: attr(data-mono);
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-size: clamp(48px, 9vw, 104px);
  color: rgba(43, 37, 31, .14); letter-spacing: .02em; user-select: none;
}
.photo.has-img::after { display: none; }
.photo-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-fill { position: absolute; inset: 0; width: 100%; height: 100%; }
.ratio-45 { aspect-ratio: 4/5; }
.ratio-11 { aspect-ratio: 1/1; }
.photo-tag {
  position: absolute; left: 12px; bottom: 10px; pointer-events: none;
  font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: #fff;
  background: rgba(20, 16, 12, .55); padding: 4px 9px; border-radius: 999px;
}
.photo-tag.lg { left: 16px; bottom: 14px; font-size: 11px; letter-spacing: .14em; padding: 5px 11px; }

/* ---- Promo banner ---------------------------------------------------- */
.promo {
  background: var(--accent); color: var(--accent-ink); text-align: center;
  padding: 9px 16px; font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase;
}

/* ---- Header ---------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: var(--bg); border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding-top: 16px; padding-bottom: 16px;
}
.nav { display: flex; gap: 26px; align-items: center; flex: 1; font-size: 14px; }
.nav-end { justify-content: flex-end; gap: 22px; }
.nav a, .navlink {
  cursor: pointer; color: var(--muted); text-decoration: none;
  transition: color .2s;
}
.nav a:hover, .navlink:hover { color: var(--ink); }
.brand-mark { cursor: pointer; text-align: center; flex: 0 0 auto; background: none; border: 0; padding: 0; }
.brand-name { font-family: var(--display); font-size: 26px; font-weight: 500; letter-spacing: .01em; line-height: 1; color: var(--ink); }
.brand-sub { font-size: 9.5px; letter-spacing: .42em; text-transform: uppercase; color: var(--soft); margin-top: 3px; padding-left: .42em; }
.cart-btn { cursor: pointer; position: relative; display: inline-flex; align-items: center; gap: 6px; color: var(--muted); background: none; border: 0; font-size: 14px; transition: color .2s; }
.cart-btn:hover { color: var(--ink); }
.cart-count {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink); font-size: 11px;
  display: inline-flex; align-items: center; justify-content: center;
}
.header-left { display: flex; align-items: center; flex: 1; min-width: 0; }
.menu-btn { display: none; cursor: pointer; background: none; border: 0; color: var(--ink); padding: 0; align-items: center; justify-content: center; }
.cart-icon { display: none; }
.cart-btn .cart-label { transition: color .2s; }

/* ---- Hero ------------------------------------------------------------ */
.hero { padding-top: 8px; }
.hero-grid {
  display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center;
  min-height: 78vh;
}
.hero-copy { animation: ylFade .7s ease both; }
.hero-eyebrow { font-size: 12px; letter-spacing: .22em; text-transform: uppercase; color: var(--clay); margin-bottom: 22px; }
.hero h1 { font-size: clamp(42px, 5.4vw, 72px); line-height: 1.04; margin: 0 0 24px; letter-spacing: -.01em; }
.hero p { font-size: 17px; color: var(--muted); max-width: 30em; margin: 0 0 34px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-media { aspect-ratio: 4/5; position: relative; animation: ylFade .9s ease both; }

/* ---- Trust bar ------------------------------------------------------- */
.trust { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 24px; }
.trust-grid { display: grid; grid-template-columns: repeat(2, 1fr); }
.trust-cell { padding: 26px 8px; text-align: center; }
.trust-cell + .trust-cell { border-left: 1px solid var(--line); }
.trust-cell .t { font-family: var(--display); font-size: 15px; }
.trust-cell .d { font-size: 12.5px; color: var(--soft); margin-top: 4px; }

/* ---- Section headers ------------------------------------------------- */
.section { padding-top: 84px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 34px; }
.section-head h2 { font-size: clamp(28px, 3.4vw, 40px); }
.section-head-center { text-align: center; margin-bottom: 40px; }
.section-head-center h2 { font-size: clamp(26px, 3.2vw, 38px); }
.viewall { cursor: pointer; font-size: 14px; color: var(--muted); border-bottom: 1px solid var(--line); padding-bottom: 3px; transition: color .2s, border-color .2s; text-decoration: none; flex: 0 0 auto; }
.viewall:hover { color: var(--ink); border-color: var(--ink); }

/* ---- Product cards / grids ------------------------------------------ */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px 26px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.card { }
.card-link { cursor: pointer; }
.card-body { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-top: 16px; }
.card-cat { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--soft); margin-bottom: 5px; }
.card-name { font-family: var(--display); font-size: 19px; line-height: 1.2; }
.card-notes { font-size: 13px; color: var(--muted); margin-top: 5px; }
.card-price { font-family: var(--display); font-size: 18px; white-space: nowrap; }

/* ---- Category cards -------------------------------------------------- */
.cat-card {
  cursor: pointer; border: 1px solid var(--line); border-radius: 4px; padding: 28px 24px;
  min-height: 170px; display: flex; flex-direction: column; justify-content: space-between;
  background: var(--surface); transition: border-color .2s, transform .2s;
}
.cat-card:hover { border-color: var(--ink); transform: translateY(-2px); }
.cat-initial { font-family: var(--display); font-size: 30px; color: var(--clay); }
.cat-label { font-family: var(--display); font-size: 20px; }
.cat-desc { font-size: 13px; color: var(--soft); margin-top: 4px; }

/* ---- Heritage story -------------------------------------------------- */
.story { margin-top: 96px; background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.story-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 64px; align-items: center; padding-top: 80px; padding-bottom: 80px; }
.story h2 { font-size: clamp(28px, 3.6vw, 42px); line-height: 1.12; margin: 0 0 20px; }
.story p { font-size: 16px; color: var(--muted); margin: 0 0 16px; max-width: 40em; }
.story-stats { display: flex; gap: 40px; margin-top: 12px; }
.stat .n { font-family: var(--display); font-size: 30px; }
.stat .l { font-size: 12.5px; color: var(--soft); }

/* ---- Brewing steps --------------------------------------------------- */
.brew-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; max-width: 880px; margin: 0 auto; }
.brew-step { text-align: center; padding: 30px 20px; border: 1px solid var(--line); border-radius: 4px; }
.brew-num { font-family: var(--display); font-size: 24px; color: var(--clay); margin-bottom: 10px; }
.brew-title { font-family: var(--display); font-size: 18px; margin-bottom: 6px; }
.brew-text { font-size: 13.5px; color: var(--muted); }

/* ---- Newsletter ------------------------------------------------------ */
.news { padding-top: 90px; padding-bottom: 30px; }
.news-card { background: var(--ink); color: var(--bg); border-radius: 6px; padding: 64px 40px; text-align: center; }
.news-card.has-photo {
  background-image: linear-gradient(rgba(20, 16, 12, .84), rgba(20, 16, 12, .84)), url('../img/teahouse-night.webp');
  background-size: cover; background-position: center;
}
.news-card h2 { font-size: clamp(26px, 3.2vw, 38px); margin: 0 0 12px; }
.news-card p { font-size: 15px; opacity: .78; margin: 0 auto 28px; max-width: 34em; }
.news-form { display: flex; gap: 10px; max-width: 440px; margin: 0 auto; flex-wrap: wrap; justify-content: center; }
.news-form input {
  flex: 1; min-width: 220px; padding: 14px 18px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.25); background: transparent; color: inherit;
  font-size: 16px; font-family: inherit;
}
.news-form input::placeholder { color: rgba(246,241,231,.55); }
.news-form button { padding: 14px 26px; border-radius: 999px; border: none; background: var(--bg); color: var(--ink); font-size: 14px; cursor: pointer; }
.news-done { font-family: var(--display); font-size: 18px; }

/* ---- Shop ------------------------------------------------------------ */
.shop { padding-top: 48px; animation: ylFade .4s ease both; }
.crumb { font-size: 13px; color: var(--soft); margin-bottom: 8px; }
.crumb .navlink { color: var(--soft); }
.crumb .navlink:hover { color: var(--ink); }
.shop h1 { font-size: clamp(34px, 4.4vw, 52px); margin: 0 0 6px; }
.shop-count { font-size: 13.5px; color: var(--muted); margin-bottom: 28px; }
.chips { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 40px; }
.chip {
  padding: 9px 18px; border-radius: 999px; cursor: pointer; white-space: nowrap;
  font-size: 13px; letter-spacing: .02em; transition: all .2s;
  border: 1px solid var(--line); background: transparent; color: var(--muted);
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.active { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.shop-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 34px 26px; padding-bottom: 20px; }

/* ---- Product detail -------------------------------------------------- */
.product { padding-top: 40px; animation: ylFade .4s ease both; }
.product-crumb { margin-bottom: 26px; font-size: 13px; color: var(--soft); }
.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: start; }
.product-media { aspect-ratio: 1/1; position: sticky; top: 90px; }
.product-cat { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--clay); margin-bottom: 12px; }
.product h1 { font-size: clamp(32px, 4vw, 46px); line-height: 1.08; margin: 0 0 14px; }
.product-notes { font-size: 15px; color: var(--muted); margin-bottom: 18px; }
.product-meta { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--soft); padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.modes { display: flex; gap: 12px; margin: 26px 0 18px; }
.mode {
  flex: 1; text-align: left; padding: 14px 16px; border-radius: 12px; cursor: pointer;
  transition: all .2s; background: transparent; border: 1.5px solid var(--line);
}
.mode.active { background: var(--surface); border-color: var(--accent); box-shadow: 0 1px 0 var(--accent); }
.mode-label { font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.mode-price { display: block; font-family: var(--display); font-size: 22px; margin-top: 2px; }
.mode-price small { font-size: 12px; color: var(--soft); }
.pill {
  font-size: 10px; background: var(--accent); color: var(--accent-ink);
  padding: 2px 7px; border-radius: 999px; letter-spacing: .04em;
}
.sub-freq { margin: 0 0 18px; }
.sub-freq-label { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--soft); margin-bottom: 9px; }
.sub-freq-opts { display: flex; gap: 8px; flex-wrap: wrap; }
.freq-opt {
  font-family: inherit; font-size: 13px; cursor: pointer; white-space: nowrap;
  padding: 9px 15px; border-radius: 999px; border: 1px solid var(--line);
  background: transparent; color: var(--muted); transition: border-color .2s, background .2s, color .2s;
}
.freq-opt:hover { border-color: var(--ink); color: var(--ink); }
.freq-opt.active { border-color: var(--accent); background: var(--accent); color: var(--accent-ink); }
.trace { display: flex; align-items: center; gap: 12px; margin-top: 18px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.trace-mark { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--accent); color: var(--accent); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 16px; flex: 0 0 auto; }
.trace-text { font-size: 13px; color: var(--muted); }
.trace-text strong { color: var(--ink); }
.product-block { margin-top: 30px; }
.product-block h3 { font-family: var(--display); font-size: 18px; margin-bottom: 8px; font-weight: 400; }
.product-block p { font-size: 14.5px; color: var(--muted); }
.brew-table { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin-top: 6px; }
.brew-cell { background: var(--surface); padding: 16px; }
.brew-cell .k { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--soft); }
.brew-cell .v { font-family: var(--display); font-size: 18px; margin-top: 4px; }
.related { padding-top: 80px; }
.related h2 { font-size: 28px; margin: 0 0 28px; }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.related .card-body { justify-content: space-between; margin-top: 14px; }
.related .card-name { font-size: 18px; }
.related .card-price { font-size: 17px; }

/* ---- Footer ---------------------------------------------------------- */
.site-footer { margin-top: 96px; border-top: 1px solid var(--line); background: var(--surface); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; padding-top: 64px; padding-bottom: 30px; }
.footer-brand .n { font-family: var(--display); font-size: 24px; margin-bottom: 8px; }
.footer-brand .d { font-size: 13.5px; color: var(--muted); max-width: 24em; }
.footer-col { font-size: 13.5px; }
.footer-col .h { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--soft); margin-bottom: 14px; }
.footer-col .links { display: flex; flex-direction: column; gap: 9px; color: var(--muted); }
.footer-col .links a, .footer-col .links span { cursor: pointer; color: var(--muted); text-decoration: none; transition: color .2s; }
.footer-col .links a:hover, .footer-col .links span:hover { color: var(--ink); }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 22px; padding-bottom: 40px; }
.copyright { font-size: 12.5px; color: var(--soft); }
.pay { display: flex; gap: 8px; align-items: center; }
.pay .lbl { font-size: 11px; color: var(--soft); margin-right: 4px; }
.pay-badge { border: 1px solid var(--line); border-radius: 4px; padding: 5px 9px; font-size: 11px; font-weight: 700; letter-spacing: .02em; color: var(--muted); }

/* ---- Cart drawer ----------------------------------------------------- */
.cart-overlay { position: fixed; inset: 0; z-index: 60; display: flex; justify-content: flex-end; }
.cart-scrim { position: absolute; inset: 0; background: rgba(20,16,12,.4); animation: ylDim .25s ease both; border: 0; cursor: pointer; }
.cart-panel {
  position: relative; width: min(440px, 100%); height: 100%; background: var(--bg);
  border-left: 1px solid var(--line); display: flex; flex-direction: column;
  animation: ylSlide .3s cubic-bezier(.2,.8,.2,1) both;
}
.cart-head { padding: 22px 24px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.cart-head h2 { font-family: var(--display); font-size: 22px; }
.cart-close { cursor: pointer; font-size: 22px; color: var(--muted); line-height: 1; background: none; border: 0; }
.cart-lines { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 8px 24px; overscroll-behavior: contain; }
.cart-line { display: flex; gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.cart-line .photo { width: 64px; height: 80px; flex: 0 0 auto; border-radius: 12px; }
.cart-line .photo::after { font-size: 30px; }
.cart-line-main { flex: 1; min-width: 0; }
.cart-line-top { display: flex; justify-content: space-between; gap: 10px; }
.cart-line-name { font-family: var(--display); font-size: 16px; line-height: 1.2; }
.cart-line-total { font-family: var(--display); font-size: 15px; white-space: nowrap; }
.cart-line-mode { font-size: 11.5px; color: var(--soft); margin: 4px 0 10px; }
.cart-line-controls { display: flex; align-items: center; justify-content: space-between; }
.stepper { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; }
.stepper button { cursor: pointer; width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; color: var(--muted); background: none; border: 0; font-size: 15px; }
.stepper button:hover { color: var(--ink); }
.stepper .qty { min-width: 24px; text-align: center; font-size: 13px; }
.cart-remove { cursor: pointer; font-size: 12px; color: var(--soft); text-decoration: underline; background: none; border: 0; }
.cart-remove:hover { color: var(--ink); }
.cart-foot { padding: 20px 24px; border-top: 1px solid var(--line); }
.cart-freeship { font-size: 12.5px; color: var(--clay); margin-bottom: 14px; text-align: center; }
.cart-error { font-size: 13px; color: #a23a2f; background: #fbeae6; border: 1px solid #f0cfc6; border-radius: 10px; padding: 10px 12px; margin-bottom: 12px; text-align: center; }
.cart-row { display: flex; justify-content: space-between; font-size: 13.5px; color: var(--muted); margin-bottom: 8px; }
.cart-total { display: flex; justify-content: space-between; font-family: var(--display); font-size: 20px; padding-top: 12px; border-top: 1px solid var(--line); margin: 12px 0 18px; }
.cart-pay { display: flex; gap: 6px; justify-content: center; margin-top: 14px; }
.cart-pay .pay-badge { padding: 4px 8px; font-size: 10px; color: var(--soft); }
.cart-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 40px; text-align: center; }
.cart-empty .t { font-family: var(--display); font-size: 20px; }
.cart-empty .d { font-size: 13.5px; color: var(--muted); }

.no-scroll { overflow: hidden; }

/* ---- Mobile menu drawer ---------------------------------------------- */
@keyframes ylSlideLeft { from { transform: translateX(-100%); } to { transform: none; } }
.menu-overlay { position: fixed; inset: 0; z-index: 60; display: flex; }
.menu-scrim { position: absolute; inset: 0; background: rgba(20, 16, 12, .4); animation: ylDim .25s ease both; border: 0; cursor: pointer; }
.menu-panel {
  position: relative; width: min(320px, 86%); height: 100%; background: var(--bg);
  border-right: 1px solid var(--line); display: flex; flex-direction: column;
  animation: ylSlideLeft .3s cubic-bezier(.2, .8, .2, 1) both;
}
.menu-head { padding: 22px 24px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.menu-title { font-family: var(--display); font-size: 22px; }
.menu-close { cursor: pointer; font-size: 26px; line-height: 1; color: var(--muted); background: none; border: 0; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; margin-right: -8px; }
.menu-links { display: flex; flex-direction: column; padding: 14px 12px; gap: 2px; }
.menu-links a { padding: 14px 12px; font-size: 17px; color: var(--ink); text-decoration: none; border-radius: 10px; transition: background .15s; }
.menu-links a:hover { background: var(--surface); }
.menu-divider { height: 1px; background: var(--line); margin: 10px 12px; }

/* ---- Info / content pages -------------------------------------------- */
.info { max-width: 760px; padding-top: 48px; animation: ylFade .4s ease both; }
.info h1 { font-size: clamp(30px, 4vw, 46px); margin: 6px 0 18px; }
.info h3 { font-family: var(--display); font-weight: 400; font-size: 20px; margin: 28px 0 10px; }
.info p { color: var(--muted); margin-bottom: 14px; }
.info-lead { font-size: 18px; color: var(--muted); margin-bottom: 20px; }
.info-list { color: var(--muted); padding-left: 20px; line-height: 1.85; margin: 0 0 14px; }
.info-list li { margin-bottom: 4px; }
.info .navlink { color: var(--clay); text-decoration: underline; }
.info .navlink:hover { color: var(--ink); }
.info .brew-cell .v { font-size: 16px; }
.faq-q { font-family: var(--display); font-size: 18px; margin-top: 22px; }
.faq-a { color: var(--muted); margin-top: 6px; }
.faq-a .navlink { color: var(--clay); text-decoration: underline; }

/* Order confirmation */
.order-check { width: 48px; height: 48px; font-size: 22px; }

/* Contact form */
.contact-form { display: flex; flex-direction: column; gap: 16px; max-width: 480px; margin-top: 8px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field span { font-size: 13px; color: var(--soft); }
.field input, .field textarea {
  font-family: inherit; font-size: 16px; color: var(--ink); width: 100%;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface);
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 2px rgba(60, 84, 64, .15); }
.contact-form .btn-solid { align-self: flex-start; }
.contact-alt { margin-top: 18px; font-size: 14px; color: var(--muted); }
.contact-alt .navlink { color: var(--clay); text-decoration: underline; }
.contact-done { margin-top: 8px; }
.contact-done .order-check { margin-bottom: 14px; }
.contact-done .btn { margin-top: 6px; }

/* ---- Tea quiz -------------------------------------------------------- */
.quiz { max-width: 680px; padding-top: 56px; text-align: center; animation: ylFade .4s ease both; }
.quiz .eyebrow { text-align: center; }
.quiz-intro h1, .quiz-result h1 { font-size: clamp(30px, 4.4vw, 48px); margin: 6px 0 16px; }
.quiz-lead { font-size: 17px; color: var(--muted); margin: 0 auto 28px; max-width: 32em; }
.quiz-note { margin-top: 16px; font-size: 13px; color: var(--soft); }
.quiz-progress { height: 5px; background: var(--line); border-radius: 999px; overflow: hidden; margin: 0 auto 26px; max-width: 420px; }
.quiz-progress-bar { height: 100%; background: var(--accent); border-radius: 999px; transition: width .35s ease; }
.quiz-step { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--clay); margin-bottom: 12px; }
.quiz-question { font-family: var(--display); font-weight: 400; font-size: clamp(26px, 3.6vw, 40px); line-height: 1.15; margin: 0 0 30px; }
.quiz-options { display: flex; flex-direction: column; gap: 12px; max-width: 420px; margin: 0 auto; }
.quiz-option {
  font-family: inherit; font-size: 16px; color: var(--ink); cursor: pointer; text-align: left;
  padding: 17px 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface);
  transition: border-color .2s, transform .1s;
}
.quiz-option:hover { border-color: var(--ink); }
.quiz-option:active { transform: translateY(1px); }
.quiz-back { margin-top: 26px; background: none; border: 0; cursor: pointer; color: var(--muted); font-family: inherit; font-size: 14px; padding: 8px 12px; }
.quiz-back:hover { color: var(--ink); }
.quiz-card {
  display: flex; gap: 26px; align-items: center; text-align: left;
  border: 1px solid var(--line); border-radius: 16px; background: var(--surface);
  padding: 22px; margin: 6px auto 0; max-width: 560px;
}
.quiz-card-media { flex: 0 0 190px; display: block; text-decoration: none; }
.quiz-card-media .ratio-45 { width: 190px; }
.quiz-card-body { flex: 1; min-width: 0; }
.quiz-card-name { font-family: var(--display); font-weight: 400; font-size: 24px; line-height: 1.15; margin: 6px 0 8px; }
.quiz-card-notes { font-size: 14px; color: var(--muted); margin-bottom: 12px; }
.quiz-card-price { font-family: var(--display); font-size: 20px; margin-bottom: 16px; }
.quiz-card-actions { display: flex; flex-direction: column; gap: 10px; }
.quiz-card-actions .btn { width: 100%; }

/* Home quiz CTA band */
.quiz-cta { border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 50px 28px; text-align: center; }
.quiz-cta .eyebrow { text-align: center; }
.quiz-cta h2 { font-family: var(--display); font-weight: 400; font-size: clamp(26px, 3.2vw, 38px); margin: 0 0 12px; }
.quiz-cta p { font-size: 15px; color: var(--muted); margin: 0 auto 24px; max-width: 30em; }

/* Touch feedback (devices without hover) */
@media (hover: none) {
  .btn:active { transform: translateY(1px); opacity: .9; }
  .card-link:active, .related-card:active, .cat-card:active { opacity: .82; }
  .chip:active, .mode:active, .navlink:active, .cart-btn:active, .menu-btn:active, .brand-mark:active { opacity: .65; }
  .stepper button:active, .cart-remove:active, .cart-close:active, .menu-close:active, .viewall:active { opacity: .55; }
  .menu-links a:active { background: var(--surface); }
}

/* =========================================================================
   Responsive
   ========================================================================= */
@media (max-width: 960px) {
  :root { --pad: 22px; }
  .hero-grid { grid-template-columns: 1fr; gap: 32px; min-height: 0; padding-top: 16px; }
  .hero-media { max-width: 460px; }
  .story-grid { grid-template-columns: 1fr; gap: 36px; padding-top: 60px; padding-bottom: 60px; }
  .product-grid { grid-template-columns: 1fr; gap: 36px; }
  .product-media { position: relative; top: 0; max-width: 480px; }
  .grid-3, .shop-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .section { padding-top: 64px; }
}

@media (max-width: 600px) {
  :root { --pad: 16px; }
  .header-inner { gap: 10px; padding-top: 14px; padding-bottom: 14px; position: relative; }
  .menu-btn { display: flex; width: 40px; height: 40px; margin-left: -8px; }
  .header-left { flex: 0 0 auto; }
  .nav-left { display: none; }             /* Shop / Gifts move into the menu */
  .nav { gap: 18px; font-size: 14px; flex: 0 0 auto; }
  .nav-end { flex: 0 0 auto; }
  .nav-end .navlink { display: none; }     /* Story is in the menu */
  .brand-sub { display: none; }
  .brand-name { font-size: 20px; }
  .brand-mark { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
  /* Cart becomes an icon with a corner badge */
  .cart-label { display: none; }
  .cart-icon { display: block; }
  .cart-btn { width: 44px; height: 44px; padding: 0; justify-content: center; margin-right: -8px; }
  .cart-count { position: absolute; top: 2px; right: 0; min-width: 16px; height: 16px; padding: 0 4px; font-size: 10px; }
  .promo { font-size: 11.5px; letter-spacing: .04em; }

  /* Shoppable 2-up product grids */
  .grid-3, .shop-grid, .grid-4, .related-grid { grid-template-columns: repeat(2, 1fr); gap: 22px 12px; }
  .brew-grid, .trust-grid { grid-template-columns: 1fr; }
  .brew-grid { max-width: 360px; }
  .trust-cell + .trust-cell { border-left: 0; border-top: 1px solid var(--line); }

  /* Compact cards for the narrow 2-up layout */
  .card-cat, .card-notes { display: none; }
  .card-body { flex-direction: column; gap: 3px; margin-top: 10px; }
  .card-name { font-size: 15px; line-height: 1.25; }
  .card-price { font-size: 15px; }
  .btn-add { padding: 12px 8px; font-size: 12.5px; }
  .cat-card { padding: 22px 18px; min-height: 148px; }

  /* Touch targets ~44px */
  .chip { padding: 12px 18px; }
  .stepper button { width: 42px; height: 42px; font-size: 17px; }
  .cart-remove { padding: 8px 0; }
  .cart-close { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; margin-right: -8px; }
  .viewall { padding: 6px 0; }
  .footer-col .links { gap: 2px; }
  .footer-col .links a, .footer-col .links span { display: inline-block; padding: 8px 0; }

  .section-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .modes { flex-direction: column; }
  .mode { padding: 16px; }
  .news-card { padding: 44px 22px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .hero h1 { font-size: clamp(34px, 11vw, 52px); }
  .quiz { padding-top: 40px; }
  .quiz-card { flex-direction: column; align-items: stretch; gap: 18px; padding: 16px; }
  .quiz-card-media, .quiz-card-media .ratio-45 { flex: none; width: 100%; }
  .quiz-cta { padding: 40px 22px; }
}

/* Very small phones (iPhone SE and down) */
@media (max-width: 360px) {
  .nav { gap: 14px; }
  .brand-name { font-size: 18px; }
  .grid-3, .shop-grid, .grid-4, .related-grid { gap: 18px 10px; }
}
