/* Shared structure for every theme. Themes set the tokens below and add their own section styles. */
@font-face { font-family: Marcellus; src: url(/fonts/marcellus.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Fraunces; font-style: italic; font-weight: 100 900; src: url(/fonts/fraunces-italic.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Fraunces; font-style: normal; font-weight: 100 900; src: url(/fonts/fraunces.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Jost; font-weight: 100 900; src: url(/fonts/jost.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "IBM Plex Sans Arabic"; font-weight: 400; src: url(/fonts/plex-arabic-400.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "IBM Plex Sans Arabic"; font-weight: 600; src: url(/fonts/plex-arabic-600.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Amiri; font-weight: 400; src: url(/fonts/amiri-400.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: Amiri; font-weight: 700; src: url(/fonts/amiri-700.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Markazi Text"; font-weight: 400 700; src: url(/fonts/markazi.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Noto Kufi Arabic"; font-weight: 100 900; src: url(/fonts/noto-kufi.woff2) format("woff2"); font-display: swap; }

:root {
  --ink: #0F2730;
  --deep: #0A1C23;
  --copper: #C4814F;
  --ivory: #F3EADA;
  --bg: var(--ivory);
  --fg: var(--ink);
  --muted: #5a6a6c;
  --line: rgba(15, 39, 48, .16);
  --surface: #fff;
  --accent: var(--copper);
  --accent-fg: var(--ink);
  --field-bg: #fff;
  --field-line: rgba(15, 39, 48, .3);
  --error: #b42318;
  --ok: #1f6f3f;
  --radius: 4px;
  --track: .2em;
  --font-body: Jost, "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --font-display: Marcellus, Amiri, Georgia, serif;
  --font-italic: Fraunces, Georgia, serif;
  --f: var(--copper);
  --f-on: var(--ink);
}
html[lang="ar"] { --track: 0; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 17px/1.6 var(--font-body); -webkit-font-smoothing: antialiased; overflow-x: clip; }
html[lang="ar"] body { line-height: 1.85; }
img, svg { max-width: 100%; display: block; }
svg { direction: ltr; }
.sprite { position: absolute; }
a { color: inherit; text-underline-offset: .2em; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: 1.1; margin: 0; text-wrap: balance; }
html[lang="ar"] :is(h1, h2, h3) { line-height: 1.4; }
p { margin: 0 0 1em; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.wrap { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: clamp(18px, 4vw, 44px); }
.page { padding-block: clamp(28px, 5vw, 64px) clamp(40px, 6vw, 80px); }
.page.narrow { max-width: 860px; }
.page > h1, .prose h1 { font-size: clamp(2rem, 5vw, 3.2rem); margin-bottom: .6em; }
.it { font-family: var(--font-italic); font-style: italic; }
html[lang="ar"] .it { font-style: normal; }
.eyebrow { font-size: .74rem; letter-spacing: var(--track); text-transform: uppercase; font-weight: 500; margin: 0 0 1.2em; }
html[lang="ar"] .eyebrow { font-size: .9rem; }
.muted { color: var(--muted); }
.lead { font-size: 1.15rem; }
.skip { position: absolute; inset-inline-start: 8px; top: -80px; background: var(--ink); color: var(--ivory); padding: 8px 12px; z-index: 20; }
.skip:focus { top: 8px; }
.price { font-variant-numeric: tabular-nums; white-space: nowrap; }
.price.big { font-size: 1.6rem; margin: 0; }
.text-link { text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.mark { width: auto; height: 100%; }
.wordmark, .beans-word { width: auto; height: 100%; }

/* Design-preview switcher (only in --preview builds) */
.preview-bar { background: #000; color: #fff; font: 500 12px/1.3 system-ui, sans-serif; display: flex; flex-wrap: wrap; gap: 4px 16px; justify-content: space-between; padding: 6px clamp(12px, 3vw, 24px); }
.preview-links { display: flex; gap: 14px; }
.preview-links a { color: #bbb; text-decoration: none; }
.preview-links a[aria-current] { color: #fff; text-decoration: underline; }
.preview-note { border: 1px dashed currentColor; padding: 8px 12px; font-size: .9rem; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 10; background: var(--header-bg, var(--bg)); color: var(--header-fg, var(--fg)); border-bottom: 1px solid var(--header-line, var(--line)); }
.header-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0 28px; min-height: 68px; }
.logo, .footer-logo { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--logo, inherit); height: 44px; }
.logo-en { display: grid; justify-items: center; gap: 5px; }
.logo-en .wordmark { height: 17px; }
.logo-en .beans-word { height: 5.5px; opacity: .9; }
.logo-ar { font-family: Amiri, serif; font-weight: 700; font-size: 1.7rem; line-height: 1; white-space: nowrap; }
.main-nav { order: 3; flex-basis: 100%; display: flex; gap: 22px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: none; }
.main-nav a, .lang-toggle, .cart-link { text-decoration: none; font-size: .8rem; letter-spacing: var(--track); text-transform: uppercase; font-weight: 500; white-space: nowrap; padding-block: 6px; }
html[lang="ar"] :is(.main-nav a, .cart-link) { font-size: 1rem; }
.main-nav a[aria-current="page"], .main-nav a:hover { box-shadow: inset 0 -1px currentColor; }
.header-actions { margin-inline-start: auto; display: flex; align-items: center; gap: 20px; }
.lang-toggle { letter-spacing: 0; text-transform: none; font-size: .9rem; opacity: .8; }
.cart-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding-inline: 6px; border-radius: 11px; background: var(--accent); color: var(--accent-fg); font-size: .75rem; letter-spacing: 0; }
@media (min-width: 860px) { .main-nav { order: 0; flex-basis: auto; padding-bottom: 0; } }

/* Buttons */
.button, .add { display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 12px 28px; border: 1px solid var(--accent); border-radius: var(--radius); background: var(--accent); color: var(--accent-fg);
  font-size: .82rem; font-weight: 500; letter-spacing: var(--track); text-transform: uppercase; text-decoration: none; cursor: pointer; transition: background .2s, color .2s, transform .2s; }
html[lang="ar"] :is(.button, .add) { font-size: 1rem; font-weight: 600; }
.button:hover { transform: translateY(-2px); }
.button.ghost { background: transparent; color: inherit; border-color: currentColor; }
.button.wide { width: 100%; }
.button[disabled] { opacity: .6; cursor: progress; transform: none; }
.add { min-height: 40px; padding: 8px 16px; background: transparent; color: inherit; border-color: currentColor; font-size: .72rem; }
.add:hover, .add.is-added { background: var(--f); color: var(--f-on); border-color: var(--f); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Section furniture shared by home pages */
.sec-head { margin-bottom: clamp(28px, 4vw, 52px); }
.sec-head h2 { font-size: clamp(2rem, 4.6vw, 3.4rem); }
.sec-head .sub { margin: .8em 0 0; max-width: 46ch; opacity: .8; }
.perks { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; }
.perks li { padding: 16px 14px; font-size: .8rem; letter-spacing: var(--track); text-transform: uppercase; text-align: center; }
html[lang="ar"] .perks li { font-size: .98rem; }
@media (min-width: 860px) { .perks { grid-template-columns: repeat(4, 1fr); } }
.pouch, .pouch-set { width: 100%; height: auto; filter: drop-shadow(0 14px 14px rgba(0, 0, 0, .28)); overflow: visible; }
.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 860px) { .grid { grid-template-columns: repeat(4, 1fr); gap: 22px; } .also .grid { grid-template-columns: repeat(3, 1fr); } .also .card-art { padding-inline: 26%; } }
.card { position: relative; display: flex; flex-direction: column; }
.card-link { display: flex; flex-direction: column; flex: 1; text-decoration: none; }
.card-art { display: block; padding: 8% 16% 4%; transition: transform .45s cubic-bezier(.2, .7, .2, 1); }
.card:hover .card-art { transform: translateY(-10px) rotate(-2deg); }
.card h3 { font-size: 1.5rem; }
.card-tag { font-size: .95rem; opacity: .75; }
.card-buy { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: 14px; }
.badge { position: absolute; top: 12px; inset-inline-start: 12px; font-size: .66rem; letter-spacing: var(--track); text-transform: uppercase; padding: 4px 10px; border: 1px solid currentColor; border-radius: 99px; }
html[lang="ar"] .badge { font-size: .8rem; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 28px; }
.steps h3 { font-size: 1.5rem; margin-bottom: .3em; }
.steps p { margin: 0; opacity: .85; }
.step-no { font-size: 3rem; line-height: 1; }
.ritual-grid, .set-grid, .story-grid { display: grid; gap: clamp(28px, 5vw, 72px); align-items: center; }
.kanaka { width: min(100%, 320px); margin-inline: auto; }
.seal { width: 100%; height: auto; }
.set-text h2, .story-text h2 { font-size: clamp(2rem, 4.4vw, 3.2rem); margin-bottom: .5em; }
.set-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; margin: 1.2em 0 0; }
.save { font-size: .9rem; opacity: .8; }
@media (min-width: 860px) {
  .ritual-grid { grid-template-columns: 1fr 1.5fr; }
  .set-grid { grid-template-columns: 1.15fr 1fr; }
  .story-grid { grid-template-columns: 260px 1fr; }
  .steps { grid-template-columns: repeat(3, 1fr); }
}
.footer-word { display: none; }
.assurances { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: .88rem; }
.assurances li { padding-inline-start: 18px; position: relative; }
.assurances li::before { content: ""; position: absolute; inset-inline-start: 0; top: .62em; width: 8px; height: 2px; background: var(--accent-text, currentColor); }
.save strong { font-weight: 600; opacity: 1; }
.faq { padding-block: clamp(56px, 8vw, 110px); }
.faq-list { border-top: 1px solid var(--fg); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 18px 0; font-family: var(--font-display); font-size: 1.3rem; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--font-body); font-weight: 300; flex: none; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 20px; max-width: 64ch; }
@media (min-width: 860px) { .faq-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 48px; align-items: start; } }
/* A buy bar pinned to the bottom of product pages on small screens */
.buy-bar { display: none; }
@media (max-width: 859px) {
  .buy-bar { position: fixed; z-index: 15; inset-inline: 0; bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; background: var(--ivory); color: var(--ink); border-top: 1px solid rgba(15, 39, 48, .25); box-shadow: 0 -8px 24px rgba(0, 0, 0, .12); }
  .buy-bar .button { min-height: 44px; padding: 8px 20px; background: var(--ink); border-color: var(--ink); color: var(--ivory); }
  .page-product .site-footer { padding-bottom: 72px; }
  .page-product .toast { bottom: 80px; }
}

/* Product page */
.crumbs { padding-block: 22px 8px; font-size: .85rem; opacity: .75; }
.crumbs a { text-decoration: none; }
.product { display: grid; gap: 28px; padding-bottom: clamp(40px, 6vw, 80px); }
.product-art { width: 100%; max-width: 480px; justify-self: center; display: grid; gap: 14px; }
.product-front { padding: 6% 14%; }
.product-front:has(.pouch-set) { padding: 12% 4%; }
.product-views { margin: 0; display: grid; gap: 14px; padding: 18px; }
.views-row { display: flex; align-items: flex-end; gap: 14px; }
.view { min-width: 0; }
.view-face { flex: 200 1 0; max-width: 46%; }
.view-side { flex: 76 1 0; }
.view-bottom { flex: 200 1 0; }
.view .pouch { filter: drop-shadow(0 5px 6px rgba(0, 0, 0, .2)); }
.product-views figcaption { font-size: .9rem; opacity: .85; }
.product-motif { width: 56px; margin-bottom: 10px; color: var(--f); }
.product-info h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); margin-bottom: .3em; }
.product-info h2 { font-size: 1.35rem; margin: 1.8em 0 .5em; }
.specs { list-style: none; padding: 0; margin: 1.4em 0; display: flex; flex-wrap: wrap; gap: 8px; }
.specs li { border: 1px solid var(--line); border-radius: 99px; padding: 4px 14px; font-size: .85rem; }
.add-form { display: grid; gap: 16px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.buy-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.qty-row { display: grid; gap: 4px; }
.qty-row label { font-size: .8rem; opacity: .75; }
.qty-row input { width: 92px; }
.status { margin: 0; min-height: 1.5em; color: var(--ok); font-weight: 500; }
.status:empty { display: none; }
.assure { margin: 0; font-size: .88rem; opacity: .8; }
.also { padding-block: clamp(40px, 6vw, 80px); border-top: 1px solid var(--line); }
@media (min-width: 860px) {
  .product { grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
  .product-art { position: sticky; top: 100px; max-width: none; }
}

/* Forms */
input, select, textarea { font: inherit; color: var(--field-fg, var(--ink)); background: var(--field-bg); border: 1px solid var(--field-line); border-radius: var(--radius); padding: 10px 12px; min-height: 48px; width: 100%; }
input[type="radio"], input[type="checkbox"] { width: auto; min-height: 0; accent-color: var(--accent); }
input:focus, select:focus, textarea:focus { border-color: var(--accent); }
[aria-invalid="true"] { border-color: var(--error); }
.field { display: grid; gap: 4px; margin-bottom: 16px; }
.field label { font-weight: 500; }
.hint { margin: 0; font-size: .85rem; opacity: .7; }
.field-error, .form-error { margin: 0; color: var(--error); font-size: .9rem; font-weight: 500; }
.form-error { background: #fdecea; border-radius: var(--radius); padding: 10px 12px; margin-bottom: 12px; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 16px 20px 6px; margin: 0 0 18px; min-width: 0; }
fieldset legend { font-family: var(--font-display); font-size: 1.25rem; padding-inline: 8px; }
.pay-option { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 10px; cursor: pointer; }
.pay-option input { margin-top: 6px; }
.pay-option.disabled { opacity: .55; cursor: not-allowed; }
.pill { display: inline-block; border: 1px solid currentColor; border-radius: 99px; font-size: .72rem; padding: 0 8px; margin-inline-start: 6px; }
.consent label { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.consent input { margin-top: 6px; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

/* Cart, checkout and confirmation */
.checkout { display: grid; gap: 24px; }
.checkout .summary { order: -1; }
.pay-total { font-family: var(--font-display); font-size: 1.4rem; margin: 0 0 12px; }
@media (min-width: 900px) { .checkout { grid-template-columns: 1.4fr 1fr; align-items: start; } .checkout .summary { order: 0; position: sticky; top: 100px; } }
.summary, .cart-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 20px 20px; }
.summary h2 { font-size: 1.3rem; margin: 14px 0 4px; }
.lines { list-style: none; padding: 0; margin: 0; }
.line { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center; padding-block: 14px; border-bottom: 1px solid var(--line); }
.line img { width: 64px; }
.line h3 { font-size: 1.15rem; }
.line p { margin: 0; font-size: .9rem; }
.line-total { font-weight: 500; white-space: nowrap; }
.stepper { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; }
.stepper button, .link-button { cursor: pointer; }
.stepper button:not(.link-button) { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--field-line); background: transparent; font-size: 1.1rem; }
.stepper output { min-width: 28px; text-align: center; font-weight: 500; }
.link-button { background: none; border: 0; text-decoration: underline; padding: 4px 6px; margin-inline-start: 8px; opacity: .75; }
.totals { margin: 14px 0; display: grid; grid-template-columns: 1fr auto; gap: 6px; }
.totals dt { opacity: .75; }
.totals dd { margin: 0; text-align: end; font-weight: 500; }
.totals .grand { font-family: var(--font-display); font-size: 1.35rem; opacity: 1; }
.order { text-align: center; }
.order-seal { width: 130px; margin: 0 auto 24px; color: var(--accent); }
.order-number { font-size: 1.2rem; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; display: inline-block; }
.order .summary { text-align: start; margin-bottom: 24px; }

/* Content pages */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.5rem; margin: 1.8em 0 .5em; }
.prose li { margin-bottom: 6px; }
.prose a { color: inherit; }
.facts { display: grid; gap: 4px 20px; }
.facts dt { font-weight: 600; margin-top: 12px; }
.facts dd { margin: 0; }
@media (min-width: 760px) { .facts { grid-template-columns: 220px 1fr; } .facts dt { margin-top: 0; } }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { text-align: start; padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }

/* Footer */
.site-footer { background: var(--footer-bg, var(--deep)); color: var(--footer-fg, #c9d2d0); font-size: .92rem; padding-top: clamp(36px, 5vw, 64px); }
.site-footer a { color: inherit; }
.site-footer h2 { font-family: var(--font-body); font-size: .76rem; letter-spacing: var(--track); text-transform: uppercase; font-weight: 500; margin: 0 0 14px; color: var(--footer-head, var(--copper)); }
html[lang="ar"] .site-footer h2 { font-size: 1rem; }
.site-footer p { margin: 0 0 6px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.footer-grid { display: grid; gap: 32px; }
@media (min-width: 860px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.site-footer .footer-logo { margin-bottom: 18px; color: var(--footer-head, var(--copper)); }
.site-footer .copyright { border-top: 1px solid rgba(255, 255, 255, .12); margin: 36px auto 0; padding-block: 18px; font-size: .82rem; opacity: .7; }

.toast { position: fixed; z-index: 30; inset-inline: 16px; bottom: 16px; margin-inline: auto; max-width: 460px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 18px;
  background: var(--ivory); color: var(--ink); border-radius: 6px; box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .55); border-inline-start: 4px solid var(--copper);
  opacity: 0; visibility: hidden; transform: translateY(16px); transition: opacity .3s, transform .3s, visibility .3s; }
.toast.is-open { opacity: 1; visibility: visible; transform: none; }
.toast a { font-weight: 600; white-space: nowrap; }

/* Scroll reveal and motion: progressive enhancement only */
@keyframes reveal { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes steam { 0% { opacity: 0; transform: translateY(8px); } 40% { opacity: .9; } 100% { opacity: 0; transform: translateY(-10px); } }
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    [data-reveal] { animation: reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 45%; }
  }
  .steam { animation: steam 3.2s ease-in-out infinite; }
  .steam.s2 { animation-delay: .9s; }
  .steam.s3 { animation-delay: 1.8s; }
}

/* Theme V5 — Jewel-Tone Heritage. Espresso, champagne gold and cream; each flavour is a jewel tone (colours in themes/v5-art.js).
   The bags are dark, so they are only ever shown inside a cream-lit recess, never straight on an espresso ground. */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 300 700; src: url(/fonts/cormorant-garamond.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 300 700; src: url(/fonts/cormorant-garamond-italic.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Playfair Display"; font-weight: 400 900; src: url(/fonts/playfair-display.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "DM Sans"; font-weight: 100 1000; src: url(/fonts/dm-sans.woff2) format("woff2"); font-display: swap; }

:root {
  --espresso: #22140D;
  --night: #170D08;
  --gold: #DFC084;
  --gold-deep: #86622A; /* gold darkened so small text passes contrast on cream */
  --cream: #F6EFE2;
  --sand: #EBDFCA;
  --bag-text: #F6E7C8;
  --bag-line: #EBCE98;
  --ink: var(--espresso);
  --ivory: var(--cream);
  --deep: var(--night);
  --copper: var(--gold);
  --bg: var(--cream);
  --fg: var(--espresso);
  --muted: #6A5848;
  --line: rgba(34, 20, 13, .16);
  --surface: #FCF8F0;
  --accent: var(--espresso);
  --accent-fg: var(--cream);
  --accent-text: var(--gold-deep);
  --field-bg: #FFFDF8;
  --field-line: rgba(34, 20, 13, .3);
  --radius: 3px;
  --track: .18em;
  --font-body: "DM Sans", "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --font-display: "Cormorant Garamond", Amiri, Georgia, serif;
  --font-italic: "Cormorant Garamond", Georgia, serif;
  --font-plate: "Playfair Display", Amiri, Georgia, serif;
  --header-bg: var(--espresso);
  --header-line: rgba(223, 192, 132, .28);
  --logo: var(--gold);
  --footer-bg: var(--night);
  --footer-fg: rgba(246, 239, 226, .78);
  --footer-head: var(--gold);
  --f: var(--gold);
  --f-on: var(--espresso);
}
/* Dark bands: header, first screen, ritual and footer. */
.site-header, .hero, .ritual, .site-footer, .arcade.cards .niche {
  --fg: var(--cream);
  --muted: #CDBFAC;
  --line: rgba(223, 192, 132, .28);
  --accent: var(--gold);
  --accent-fg: var(--espresso);
  --accent-text: var(--gold);
  color: var(--cream);
}
html[lang="ar"] { --track: 0; }
::selection { background: var(--gold); color: var(--espresso); }
h1, h2, h3 { font-weight: 600; }
fieldset legend, .pay-total, .totals .grand { font-weight: 600; }
html[lang="ar"] :is(h1, h2, h3, legend, .faq summary) { font-weight: 700; }
.it { font-weight: 500; }
html[lang="ar"] .it { font-family: Amiri, serif; font-weight: 400; }
.eyebrow { color: var(--accent-text); }
.text-link { color: var(--accent-text); }
.price.big { font-family: var(--font-display); font-weight: 600; font-size: 2.1rem; }

/* Header and buttons */
.cart-count { font-weight: 600; }
.button, .add { font-weight: 600; }
.button:hover { background: var(--gold); border-color: var(--gold); color: var(--espresso); }
.button.ghost:hover { background: transparent; border-color: var(--accent-text); color: var(--accent-text); }

/* ---------- The recess: a cream-lit panel in the espresso wall, with a gold hairline round it like the rule on the bags ---------- */
:root { --rule: #B89C6B; /* champagne gold as it reads on espresso */ }
/* The lit panel has a darker ledge along the bottom for the bag to stand on. The rings are wall, gold rule, wall. */
.stage, .product-front { border-radius: 2px; background: linear-gradient(to top, #D8C6A6, #E6D8BE 8%, transparent 8.2%), radial-gradient(90% 70% at 50% 36%, #FFFCF5, var(--cream) 68%, #EDE1CC); }
.stage { position: relative; display: block; margin: 7px; aspect-ratio: 1 / 1.2; box-shadow: 0 0 0 6px var(--espresso), 0 0 0 7px var(--rule); }
.stage-art { position: absolute; inset-inline: 16%; bottom: 4.6%; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.stage-art .pouch { filter: drop-shadow(0 10px 10px rgba(34, 20, 13, .3)); }
.niche:hover .stage-art { transform: translateY(-3.5%); }

.arcade { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px 14px; }
.niche { position: relative; display: flex; flex-direction: column; text-align: center; }
.niche-link { flex: 1; display: flex; flex-direction: column; text-decoration: none; }
.niche-name { margin-top: 20px; font-family: var(--font-plate); font-weight: 700; font-size: clamp(1.05rem, 1.7vw, 1.4rem); line-height: 1.2; letter-spacing: .16em; text-transform: uppercase; }
html[lang="ar"] .niche-name { font-family: Amiri, serif; font-size: clamp(1.5rem, 2.2vw, 1.9rem); letter-spacing: 0; }
.niche-tag { margin-top: 4px; font-size: 1.12rem; line-height: 1.3; color: var(--muted); text-wrap: balance; }
.niche-buy { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 16px; margin-top: 14px; }
.niche-buy .price { font-family: var(--font-display); font-weight: 600; font-size: 1.35rem; color: var(--gold); }
.niche .add { border-color: rgba(223, 192, 132, .6); }
.niche .add:hover, .niche .add.is-added { background: var(--gold); border-color: var(--gold); color: var(--espresso); }
/* The badge is a small plaque across the gold rule at the foot of the recess. */
.niche .badge { z-index: 2; top: auto; bottom: -19px; inset-inline-start: 50%; transform: translateX(-50%); padding: 3px 12px; white-space: nowrap; background: var(--espresso); color: var(--gold); border-color: var(--gold); font-weight: 600; }
[dir="rtl"] .niche .badge { transform: translateX(50%); }
@media (max-width: 559px) { .niche-tag { font-size: 1rem; } .niche .add { padding-inline: 12px; } }
@media (min-width: 860px) { .arcade { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2.6vw, 38px); } }
/* Listings on a light page: each card is its own piece of wall. */
.arcade.cards .niche { background: var(--espresso); border-radius: 4px; padding: 16px 16px 20px; }
@media (min-width: 860px) { .also .arcade { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 940px; margin-inline: auto; } }

/* ---------- First screen ---------- */
.hero { background: var(--espresso); padding-block: clamp(22px, 3vw, 44px) clamp(30px, 4vw, 56px); }
.hero-head { display: grid; justify-items: center; gap: 14px; text-align: center; margin-bottom: clamp(22px, 3vw, 36px); }
.hero-head .eyebrow { margin-bottom: 1em; }
.hero h1 { font-size: clamp(2.5rem, 4.6vw, 3.9rem); line-height: 1; }
html[lang="ar"] .hero h1 { font-size: clamp(2.3rem, 4.2vw, 3.5rem); line-height: 1.3; }
.hero .lead { margin: 0; max-width: 58ch; color: #DDD0BC; text-wrap: balance; }
@media (max-width: 559px) { .hero-head { gap: 10px; } .hero-head .eyebrow { font-size: .64rem; letter-spacing: .12em; margin-bottom: .6em; } html[lang="ar"] .hero-head .eyebrow { font-size: .9rem; letter-spacing: 0; } .hero .lead { font-size: 1rem; } }
/* On a wide screen the row shrinks with the window's height, so the four bags and their buttons share the first screen. */
@media (min-width: 860px) { .hero .arcade { max-width: max(700px, calc((100svh - 540px) * 3.3 + 170px)); margin-inline: auto; } }
@keyframes rise { from { opacity: 0; transform: translateY(26px); } }
@media (prefers-reduced-motion: no-preference) {
  .hero-head > * { animation: rise .9s cubic-bezier(.2, .7, .2, 1) both; }
  .hero .niche { animation: rise 1s cubic-bezier(.2, .7, .2, 1) both; }
  .hero .niche:nth-child(1) { animation-delay: .1s; } .hero .niche:nth-child(2) { animation-delay: .2s; }
  .hero .niche:nth-child(3) { animation-delay: .3s; } .hero .niche:nth-child(4) { animation-delay: .4s; }
}

/* Ribbon of perks */
.ribbon { background: var(--night); color: var(--gold); border-top: 1px solid rgba(223, 192, 132, .22); }
.ribbon .perks li { padding-block: 18px; font-weight: 500; font-size: .74rem; }
html[lang="ar"] .ribbon .perks li { font-size: .95rem; }
.ribbon .perks li + li { box-shadow: inset 1px 0 rgba(223, 192, 132, .18); }
[dir="rtl"] .ribbon .perks li + li { box-shadow: inset -1px 0 rgba(223, 192, 132, .18); }
@media (max-width: 859px) { .ribbon .perks li:nth-child(3) { box-shadow: none; } .ribbon .perks li:nth-child(n+3) { border-top: 1px solid rgba(223, 192, 132, .18); } }

/* ---------- Discovery Set (sand): the espresso box needs no stage on a light ground ---------- */
.set { background: var(--sand); padding-block: clamp(56px, 8vw, 112px); }
.set-text h2 { font-size: clamp(2.3rem, 5vw, 3.8rem); }
.set-text p { max-width: 46ch; }
.set .save { opacity: 1; color: var(--muted); }
.set .save strong { display: inline-block; margin-inline-end: 6px; padding: 3px 12px; border-radius: 99px; background: var(--espresso); color: var(--gold); }
.pouch-set { filter: drop-shadow(0 22px 22px rgba(34, 20, 13, .3)); }

/* ---------- Flavour plates: the face of each bag, as a card ---------- */
.plates { padding-block: clamp(56px, 8vw, 112px); }
.sec-head h2 { font-size: clamp(2.3rem, 5vw, 3.8rem); }
.plate-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.plate { display: flex; padding: 9px; border-radius: 5px; background: linear-gradient(165deg, var(--f-from), var(--f-to)); color: var(--bag-text); box-shadow: 0 18px 30px -18px rgba(34, 20, 13, .6); }
.plate-frame { flex: 1; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 30px 22px 22px; border: 1px solid rgba(235, 206, 152, .62); border-radius: 3px; outline: 1px solid rgba(235, 206, 152, .28); outline-offset: -5px; }
.plate-motif { width: 60px; height: 60px; color: var(--bag-line); }
.plate h3 { margin-top: 14px; font-family: var(--font-plate); font-weight: 700; font-size: 1.5rem; letter-spacing: .16em; text-transform: uppercase; color: #FFF8EB; }
html[lang="ar"] .plate h3 { font-family: Amiri, serif; font-size: 2.1rem; letter-spacing: 0; line-height: 1.3; }
.plate-alt { margin: .25em 0 0; font-family: Amiri, serif; font-weight: 700; font-size: 1.12rem; line-height: 1.5; }
html[lang="ar"] .plate-alt { font-family: var(--font-plate); font-size: .78rem; letter-spacing: .2em; text-transform: uppercase; }
.plate-tag { margin: .45em 0 .7em; font-size: 1.25rem; line-height: 1.25; }
.plate-tag::after { content: ""; display: block; width: 34px; height: 1px; margin: .7em auto 0; background: var(--bag-line); opacity: .7; }
.plate-body { margin: 0 0 22px; font-size: .95rem; opacity: .88; }
.plate-buy { margin-top: auto; width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 16px; border-top: 1px solid rgba(235, 206, 152, .3); }
.plate-buy .price { font-family: var(--font-display); font-weight: 600; font-size: 1.4rem; color: var(--bag-line); }
.plate .add { padding-inline: 13px; letter-spacing: .12em; white-space: nowrap; border-color: rgba(235, 206, 152, .65); }
html[lang="ar"] .plate .add { letter-spacing: 0; }
.plate .add:hover, .plate .add.is-added { background: var(--bag-line); border-color: var(--bag-line); color: var(--espresso); }
.plate-more { margin-top: 14px; font-size: .78rem; letter-spacing: var(--track); text-transform: uppercase; text-decoration: none; opacity: .85; }
html[lang="ar"] .plate-more { font-size: .95rem; }
.plate-more:hover { opacity: 1; text-decoration: underline; }
/* On a phone the plates are a row to swipe through, with the next one showing at the edge. */
@media (max-width: 639px) {
  .plate-list { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; margin-inline: calc(-1 * clamp(18px, 4vw, 44px)); padding: 0 clamp(18px, 4vw, 44px) 26px; scrollbar-width: none; }
  .plate-list::-webkit-scrollbar { display: none; }
  .plate { flex: 0 0 80%; scroll-snap-align: center; }
}
@media (min-width: 640px) { .plate-list { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .plate-list { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Ritual (espresso): the kanaka inside the double gold rule ---------- */
.ritual { background: var(--espresso); padding-block: clamp(56px, 8vw, 112px); }
.ritual-art { width: min(100%, 290px); aspect-ratio: 1 / 1.1; margin-inline: auto; display: grid; place-items: center; color: var(--gold); border: 1px solid rgba(223, 192, 132, .6); border-radius: 3px; outline: 1px solid rgba(223, 192, 132, .28); outline-offset: -6px; }
.ritual-art .kanaka { width: 64%; }
.steps li { border-top: 1px solid var(--line); padding-top: 16px; }
.step-no { display: block; margin-bottom: 8px; font-family: var(--font-display); font-style: normal; font-weight: 500; font-size: 3.4rem; color: var(--gold); }
.steps h3 { font-size: 1.7rem; }

/* ---------- Story (burnt orange, the signature flavour) ---------- */
.story { background: linear-gradient(165deg, #B24621, #883113); color: var(--bag-text); padding-block: clamp(56px, 8vw, 110px); }
.story-seal { width: min(220px, 56vw); margin-inline: auto; color: var(--bag-line); }
.story-text h2 { font-size: clamp(2.3rem, 5vw, 3.8rem); color: #FFF8EB; }
.story-text p { max-width: 54ch; font-size: 1.08rem; }
.story .text-link { color: #FFF8EB; font-weight: 600; }
@media (prefers-reduced-motion: no-preference) { .story-seal .seal { animation: spin 70s linear infinite; } }

/* ---------- Trust and questions ---------- */
.trust { padding-block: clamp(48px, 7vw, 96px); }
.trust-list { list-style: none; margin: 0; padding: 0; display: grid; }
.trust-list li { padding: 26px 0; border-top: 1px solid var(--line); }
.trust-mark { width: auto; height: 44px; margin-bottom: 14px; color: var(--gold-deep); }
.trust-list h3 { font-size: 1.7rem; margin-bottom: .3em; }
.trust-list p { margin: 0; color: var(--muted); }
@media (min-width: 860px) {
  .trust-list { grid-template-columns: repeat(3, 1fr); }
  .trust-list li { padding: 6px clamp(18px, 2.6vw, 36px); border-top: 0; }
  .trust-list li + li { border-inline-start: 1px solid var(--line); }
  .trust-list li:first-child { padding-inline-start: 0; }
}
.faq { background: var(--sand); }
.faq summary { font-size: 1.5rem; font-weight: 600; }
html[lang="ar"] .faq summary { font-size: 1.3rem; }

/* ---------- Product page and listings ---------- */
.shop-page { padding-bottom: clamp(48px, 6vw, 80px); }
.product-front { display: flex; align-items: flex-end; justify-content: center; margin: 22px; aspect-ratio: 1 / 1.05; padding: 0 0 4.4%; box-shadow: 0 0 0 6px var(--espresso), 0 0 0 7px var(--rule), 0 0 0 22px var(--espresso); }
.product-front .pouch { width: 56%; filter: drop-shadow(0 14px 14px rgba(34, 20, 13, .32)); }
/* The Discovery Set stands on sand, as on the home page, with no recess. */
.product-front:has(.pouch-set) { margin: 0; aspect-ratio: auto; padding: 12% 5%; background: var(--sand); box-shadow: none; }
.product-views { background: var(--surface); border: 1px solid var(--line); border-radius: 4px; }
.product-motif { width: 54px; height: 54px; color: var(--gold-deep); }
.product-info h1 { font-size: clamp(2.5rem, 5.4vw, 4rem); }
.product-info h2 { font-size: 1.6rem; }
.specs li { background: var(--surface); }
.add-form .assurances { color: var(--muted); }
.prose a, .assure a { color: var(--gold-deep); }
.table th { font-weight: 600; border-bottom-color: var(--espresso); }
.page-product .ritual { margin-top: 0; }
.also .sec-head { text-align: center; }

/* ---------- Footer ---------- */
.footer-word { display: block; max-width: 1240px; margin-inline: auto; padding: clamp(28px, 5vw, 56px) clamp(18px, 4vw, 44px) 0; color: var(--gold); opacity: .22; }
.footer-word .wordmark { width: 100%; height: auto; }
.site-footer .copyright { margin-top: 18px; border-top-color: rgba(223, 192, 132, .16); }

.toast { border-inline-start-color: var(--gold-deep); }
.order-seal { color: var(--gold-deep); }
.preview-bar { background: #000; }

/* Theme V7: V5 with an ivory pouch. Loaded after v5.css. The pouch is as light as the page, so it is only ever shown on
   a dark ground: the recesses are a lamp-lit espresso niche instead of a cream-lit one. */
.stage, .product-front { background: linear-gradient(to top, #120A06, #1B100A 8%, transparent 8.2%), radial-gradient(90% 70% at 50% 36%, #523523, #2C1A10 62%, #1A0F09); }
.stage-art .pouch, .product-front .pouch { filter: drop-shadow(0 12px 12px rgba(0, 0, 0, .55)); }
.product-views { background: var(--espresso); border-color: var(--espresso); color: var(--cream); }

/* Flavour colours from src/config.js */
.f-plain{--f:#4A2A1C;--f-on:#F3EADA}
.f-orange{--f:#D05A1E;--f-on:#0F2730}
.f-hazelnut{--f:#B98B56;--f-on:#0F2730}
.f-mint{--f:#2F8062;--f-on:#F3EADA}
.f-discovery{--f:#0F2730;--f-on:#F3EADA}
.f-plain{--f:#1D1917;--f-on:#F6E7C8;--f-from:#2B2523;--f-to:#151211}
.f-orange{--f:#A03D1A;--f-on:#F6E7C8;--f-from:#BC4D23;--f-to:#863012}
.f-hazelnut{--f:#613A20;--f-on:#F6E7C8;--f-from:#7A4A2A;--f-to:#4E2D17}
.f-mint{--f:#1B4534;--f-on:#F6E7C8;--f-from:#245844;--f-to:#143628}
