/* Jenmond African Market - Storefront & customer account */
:root {
  --green-900: #072e21;
  --green-800: #0b3d2c;
  --green-700: #0b4f35;
  --green-600: #16794f;
  --green-100: #e3f2ea;
  --gold-500: #e2a022;
  --gold-600: #c98a12;
  --gold-100: #fbf0d9;
  --terra-500: #c4532d;
  --terra-100: #f8e3da;

  --bg: #fbf8f2;
  --surface: #ffffff;
  --surface-2: #f6f1e7;
  --border: #e9e2d4;
  --border-strong: #d8cfbd;
  --text: #1d1b16;
  --text-2: #57534a;
  --muted: #8a8478;
  --danger: #b3261e;
  --danger-bg: #fbe5e3;

  --font-display: 'Bricolage Grotesque', 'DM Sans', system-ui, sans-serif;
  --font-body: 'DM Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 1px 2px rgba(29,27,22,.05), 0 2px 8px rgba(29,27,22,.04);
  --shadow-lg: 0 18px 40px rgba(29,27,22,.14);
  --wrap: 1240px;
  --kente: repeating-linear-gradient(90deg, var(--gold-500) 0 18px, var(--terra-500) 18px 26px, var(--green-600) 26px 40px, #1d1b16 40px 44px);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--font-body); font-size: 15px; line-height: 1.55; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--green-600); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; margin: 0; letter-spacing: -.015em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.text-2 { color: var(--text-2); }
.small { font-size: 13px; }
.strong { font-weight: 700; }
.num { font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mt { margin-top: 24px; }
.mb { margin-bottom: 24px; }

/* ---------- Header ---------- */
.announce { background: var(--green-800); color: #d9eadf; font-size: 14.5px; text-align: center; padding: 8px 16px; }
.announce strong { color: var(--gold-500); }
.announce a { color: inherit; font-weight: 600; white-space: nowrap; }
.site-header { background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 40; }
.site-header::after { content: ""; display: block; height: 3px; background: var(--kente); }
.header-main { display: flex; align-items: center; gap: 24px; padding: 14px 20px; }
.brand:hover { text-decoration: none; }
.brand-lockup { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-lockup img { height: 84px; width: 84px; flex-shrink: 0; }
.brand-words { display: flex; flex-direction: column; line-height: 1; }
.brand-words strong { font-family: var(--font-display); font-size: 34px; font-weight: 800; letter-spacing: .01em; text-transform: uppercase; }
.brand-words small { font-size: 14px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; margin-top: 4px; white-space: nowrap; }
.brand-dark .brand-words strong { color: #0f4a2f; }
.brand-dark .brand-words small { color: #c96a1b; }
.brand-light .brand-words strong { color: #fff; }
.brand-light .brand-words small { color: var(--gold-500); }
.brand-lg img { height: 104px; width: 104px; }
.brand-lg .brand-words strong { font-size: 38px; }
.brand-lg .brand-words small { font-size: 15px; }
.search-bar { flex: 1; max-width: 560px; position: relative; }
.search-bar input { width: 100%; padding: 11px 46px 11px 16px; border: 1px solid var(--border-strong); border-radius: 999px; font: inherit; background: var(--bg); }
.search-bar input:focus { outline: none; border-color: var(--green-600); box-shadow: 0 0 0 3px rgba(22,121,79,.12); background: #fff; }
.search-bar button { position: absolute; right: 5px; top: 50%; transform: translateY(-50%); border: 0; background: var(--green-600); color: #fff; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; }
.header-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.icon-link { position: relative; display: inline-flex; align-items: center; gap: 7px; padding: 8px 10px; border-radius: 10px; color: var(--text); font-weight: 600; font-size: 14px; }
.icon-link:hover { background: var(--surface-2); text-decoration: none; }
.icon-link i { font-size: 20px; }
.icon-link .count { position: absolute; top: 2px; left: 22px; background: var(--terra-500); color: #fff; font-size: 10.5px; font-weight: 800; min-width: 18px; height: 18px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; border: 2px solid #fff; }
.cat-nav { border-top: 1px solid var(--border); }
.cat-nav .wrap { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.cat-nav a { padding: 10px 12px; color: var(--text-2); font-weight: 600; font-size: 14px; white-space: nowrap; border-bottom: 2px solid transparent; }
.cat-nav a:hover, .cat-nav a.active { color: var(--green-700); border-bottom-color: var(--gold-500); text-decoration: none; }
.cat-nav a.sell { margin-left: auto; color: var(--terra-500); }
.menu-btn { display: none; background: none; border: 0; font-size: 24px; cursor: pointer; padding: 4px; color: var(--text); }

/* ---------- Buttons & forms ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 20px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: inherit; font-weight: 700; cursor: pointer; white-space: nowrap; line-height: 1.2; transition: background .15s, border-color .15s, transform .05s; }
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--green-600); border-color: var(--green-600); color: #fff; }
.btn-primary:hover { background: var(--green-700); }
.btn-gold { background: var(--gold-500); border-color: var(--gold-500); color: var(--green-900); }
.btn-gold:hover { background: var(--gold-600); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-danger { color: var(--danger); border-color: #efc2be; }
.btn-lg { padding: 14px 26px; font-size: 16px; border-radius: 12px; }
.btn-sm { padding: 7px 12px; font-size: 13px; border-radius: 8px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn:focus-visible, .input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid rgba(226,160,34,.5); outline-offset: 2px; }
.field { margin-bottom: 16px; }
.field label, .label { display: block; font-weight: 700; font-size: 13.5px; margin-bottom: 6px; }
.hint { font-size: 12.5px; color: var(--muted); margin-top: 5px; }
.req { color: var(--terra-500); }
.input, select, textarea { width: 100%; font: inherit; color: var(--text); padding: 11px 13px; border: 1px solid var(--border-strong); border-radius: 10px; background: #fff; }
.input:focus, select:focus, textarea:focus { outline: none; border-color: var(--green-600); box-shadow: 0 0 0 3px rgba(22,121,79,.12); }
textarea { min-height: 110px; resize: vertical; }
.form-row { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-row.three { grid-template-columns: 2fr 1fr 1fr; }
.check { display: flex; align-items: center; gap: 9px; cursor: pointer; font-weight: 500; }
.check input { width: 18px; height: 18px; accent-color: var(--green-600); }
.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 44px; }
.pw-toggle { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: none; border: 0; cursor: pointer; color: var(--muted); font-size: 17px; padding: 4px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--border-strong); border-radius: 10px; overflow: hidden; background: #fff; }
.qty button { border: 0; background: none; width: 38px; height: 42px; font-size: 18px; cursor: pointer; color: var(--text-2); }
.qty button:hover { background: var(--surface-2); }
.qty input { width: 46px; border: 0; text-align: center; font: inherit; font-weight: 700; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; }

/* ---------- Alerts / badges ---------- */
.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-sm); margin-bottom: 16px; border: 1px solid; font-weight: 500; }
.alert-success { background: var(--green-100); border-color: #bfe0cd; color: #0f5a3a; }
.alert-error { background: var(--danger-bg); border-color: #f1c4bf; color: #8c1d17; }
.alert-info { background: #e2edf9; border-color: #c4d8f0; color: #174d88; }
.alert-warning { background: #fdf1d6; border-color: #f2dba5; color: #7a4e00; }
.alert .close { margin-left: auto; background: none; border: 0; cursor: pointer; color: inherit; opacity: .6; }
.flash-wrap { padding-top: 18px; }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-success { background: var(--green-100); color: var(--green-600); }
.badge-warning { background: #fdf1d6; color: #9a6200; }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-info { background: #e2edf9; color: #1d5fa8; }
.badge-neutral { background: #efece6; color: #5c5850; }
.stars { color: var(--gold-500); letter-spacing: 1px; white-space: nowrap; }
.stars .off { color: var(--border-strong); }

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 800; }
.section-head p { margin: 6px 0 0; color: var(--text-2); }

/* ---------- Product grid & cards ---------- */
.grid-products { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.grid-products.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.p-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; position: relative; transition: box-shadow .15s, transform .15s; }
.p-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.p-card .img { aspect-ratio: 1; background: var(--surface-2); overflow: hidden; display: block; }
.p-card .img img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.p-card:hover .img img { transform: scale(1.04); }
.p-card .body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.p-card .origin { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.p-card .name { font-weight: 700; color: var(--text); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.p-card .name:hover { color: var(--green-700); text-decoration: none; }
.p-card .price { margin-top: auto; padding-top: 8px; display: flex; align-items: baseline; gap: 8px; }
.p-card .price strong { font-family: var(--font-display); font-size: 19px; }
.p-card .price s { color: var(--muted); font-size: 14px; }
.p-card .tags { position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; flex-direction: column; align-items: flex-start; }
.tag { background: var(--surface); color: var(--text); font-size: 11.5px; font-weight: 800; padding: 4px 9px; border-radius: 999px; box-shadow: var(--shadow); }
.tag-sale { background: var(--terra-500); color: #fff; }
.tag-origin { background: rgba(7,46,33,.85); color: #fff; }
.tag-low { background: var(--gold-500); color: var(--green-900); }
.wish-btn { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(255,255,255,.95); box-shadow: var(--shadow); cursor: pointer; display: flex; align-items: center; justify-content: center; font-size: 17px; color: var(--text-2); }
.wish-btn.on, .wish-btn:hover { color: var(--terra-500); }
.wish-form { display: contents; }

/* ---------- Shop page ---------- */
.page-title { padding: 32px 0 8px; }
.page-title h1 { font-size: clamp(28px, 4vw, 40px); font-weight: 800; }
.page-title p { color: var(--text-2); margin: 6px 0 0; }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--text-2); }
.shop-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 32px; padding: 20px 0 64px; align-items: start; }
.filters-panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; position: sticky; top: 140px; }
.filters-panel h3 { font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 18px 0 10px; font-family: var(--font-body); }
.filters-panel h3:first-child { margin-top: 0; }
.filter-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.filter-list a { display: flex; justify-content: space-between; padding: 6px 8px; border-radius: 8px; color: var(--text-2); font-size: 14px; }
.filter-list a:hover { background: var(--surface-2); text-decoration: none; }
.filter-list a.active { background: var(--green-100); color: var(--green-700); font-weight: 700; }
.filter-list .sub a { padding-left: 22px; }
.price-inputs { display: flex; gap: 8px; align-items: center; }
.price-inputs .input { padding: 8px 10px; }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.toolbar select { width: auto; padding: 8px 12px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--border-strong); padding: 5px 12px; border-radius: 999px; font-size: 13px; color: var(--text); font-weight: 600; }
.chip:hover { border-color: var(--terra-500); text-decoration: none; }
.filter-toggle { display: none; }
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 32px; flex-wrap: wrap; align-items: center; }
.pagination > .muted { width: 100%; text-align: center; }
.pagination nav { display: flex; gap: 6px; }
.pagination a, .pagination span.current, .pagination span.disabled { padding: 8px 14px; border-radius: 9px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font-weight: 700; }
.pagination .current { background: var(--green-600); color: #fff !important; border-color: var(--green-600) !important; }
.pagination .disabled { opacity: .45; }
.empty-state { text-align: center; padding: 64px 20px; background: var(--surface); border: 1px dashed var(--border-strong); border-radius: var(--radius); }
.empty-state i { font-size: 42px; color: var(--border-strong); }
.empty-state h3 { font-size: 22px; margin: 12px 0 6px; }
.empty-state p { color: var(--text-2); margin: 0 0 18px; }

/* ---------- Product page ---------- */
.product-layout { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 48px; padding: 12px 0 48px; align-items: start; }
.gallery-main { aspect-ratio: 1; border-radius: 18px; overflow: hidden; background: var(--surface-2); border: 1px solid var(--border); }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-top: 12px; }
.gallery-thumbs button { padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; cursor: pointer; aspect-ratio: 1; background: var(--surface-2); }
.gallery-thumbs button.active { border-color: var(--green-600); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.p-info h1 { font-size: clamp(26px, 3vw, 36px); font-weight: 800; margin: 6px 0 10px; }
.p-info .by { color: var(--text-2); }
.p-price { display: flex; align-items: baseline; gap: 12px; margin: 18px 0; }
.p-price strong { font-family: var(--font-display); font-size: 34px; }
.p-price s { color: var(--muted); font-size: 18px; }
.p-price .save { background: var(--terra-100); color: var(--terra-500); font-weight: 800; font-size: 13px; padding: 4px 10px; border-radius: 999px; }
.buy-box { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 20px 0; }
.buy-box .btn-primary { flex: 1; min-width: 200px; }
.facts { display: grid; gap: 10px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; margin-top: 18px; }
.facts > div { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; }
.facts i { color: var(--green-600); font-size: 18px; margin-top: 1px; }
.stock { font-weight: 700; font-size: 14px; }
.stock.in { color: var(--green-600); }
.stock.low { color: #9a6200; }
.stock.out { color: var(--danger); }
.avatar { width: 46px; height: 46px; border-radius: 50%; background: var(--gold-500); color: var(--green-900); font-family: var(--font-display); font-weight: 800; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.tabs-block { border-top: 1px solid var(--border); padding-top: 32px; }
.prose { color: var(--text-2); max-width: 760px; white-space: pre-line; }
.reviews-layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 40px; }
.rating-summary .big { font-family: var(--font-display); font-size: 52px; font-weight: 800; line-height: 1; }
.bar-row { display: grid; grid-template-columns: 34px 1fr 30px; gap: 8px; align-items: center; font-size: 13px; color: var(--text-2); margin-top: 6px; }
.bar-row .bar { height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.bar-row .bar span { display: block; height: 100%; background: var(--gold-500); border-radius: 999px; }
.review { border-bottom: 1px solid var(--border); padding: 18px 0; }
.review:first-child { padding-top: 0; }
.review h4 { font-family: var(--font-body); font-size: 15.5px; margin: 6px 0 4px; }
.review .reply { background: var(--surface-2); border-radius: 10px; padding: 10px 14px; margin-top: 10px; font-size: 14px; border-left: 3px solid var(--gold-500); }
.star-input { display: inline-flex; flex-direction: row-reverse; gap: 2px; }
.star-input input { position: absolute; opacity: 0; width: 0; }
.star-input label { font-size: 28px; color: var(--border-strong); cursor: pointer; line-height: 1; }
.star-input input:checked ~ label, .star-input label:hover, .star-input label:hover ~ label { color: var(--gold-500); }
.star-input input:focus-visible + label { outline: 2px solid var(--gold-500); border-radius: 4px; }

/* ---------- Cart & checkout ---------- */
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 32px; padding: 12px 0 64px; align-items: start; }
.success-layout { grid-template-columns: minmax(0, 1fr) 320px; padding-top: 0; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.panel-head { padding: 16px 20px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.panel-head h2, .panel-head h3 { font-size: 17px; font-weight: 700; }
.panel-body { padding: 20px; }
.cart-item { display: grid; grid-template-columns: 88px minmax(0, 1fr) auto; gap: 16px; padding: 18px 20px; border-bottom: 1px solid var(--border); align-items: center; }
.cart-item:last-child { border-bottom: 0; }
.cart-item img { width: 88px; height: 88px; border-radius: 10px; object-fit: cover; background: var(--surface-2); }
.cart-item .title { font-weight: 700; color: var(--text); }
.cart-item .controls { display: flex; gap: 10px; align-items: center; margin-top: 10px; flex-wrap: wrap; }
.cart-item .line { font-family: var(--font-display); font-size: 18px; font-weight: 700; text-align: right; }
.summary-row { display: flex; justify-content: space-between; padding: 6px 0; color: var(--text-2); }
.summary-row.total { color: var(--text); font-weight: 800; font-size: 19px; border-top: 1px solid var(--border); margin-top: 8px; padding-top: 14px; font-family: var(--font-display); }
.summary-row.discount { color: var(--green-600); font-weight: 700; }
.coupon-form { display: flex; gap: 8px; margin: 14px 0; }
.coupon-form .input { text-transform: uppercase; }
.trust { display: grid; gap: 8px; margin-top: 16px; font-size: 13px; color: var(--text-2); }
.trust div { display: flex; gap: 8px; align-items: center; }
.trust i { color: var(--green-600); }
.ship-options { display: grid; gap: 10px; }
.ship-option { display: flex; gap: 12px; align-items: center; border: 1px solid var(--border-strong); border-radius: 10px; padding: 12px 14px; cursor: pointer; }
.ship-option:has(input:checked) { border-color: var(--green-600); background: var(--green-100); }
.ship-option input { accent-color: var(--green-600); width: 18px; height: 18px; }
.delivery-choice { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-bottom: 16px; }
.delivery-opt { display: flex; gap: 12px; align-items: flex-start; border: 1.5px solid var(--border-strong); border-radius: 12px; padding: 14px; cursor: pointer; }
.delivery-opt .grow { flex: 1; line-height: 1.35; }
.delivery-opt .bi { color: var(--green-600); margin-right: 4px; }
.delivery-opt .price { color: var(--green-700); font-size: 14px; white-space: nowrap; }
.delivery-opt input { accent-color: var(--green-600); width: 18px; height: 18px; margin-top: 2px; }
.delivery-opt.on, .delivery-opt:has(input:checked) { border-color: var(--green-600); background: var(--green-100); }
.pickup-info { display: flex; gap: 12px; padding: 14px 16px; margin-bottom: 16px; border-radius: 12px; background: #fff8e8; border: 1px solid #f1dfb0; }
.pickup-info > .bi { color: var(--terra-500); font-size: 20px; }
.pickup-info[hidden], #shipFields[hidden], #shipAddress[hidden], #shipMethod[hidden] { display: none; }
@media (max-width: 640px) { .delivery-choice { grid-template-columns: 1fr; } }
.ship-option .grow { flex: 1; }
.mini-item { display: grid; grid-template-columns: 54px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; }
.mini-item img { width: 54px; height: 54px; border-radius: 8px; object-fit: cover; background: var(--surface-2); }
.mini-item .q { position: relative; }
.mini-item .q span { position: absolute; top: -6px; right: -6px; background: var(--text-2); color: #fff; font-size: 11px; font-weight: 800; border-radius: 999px; min-width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; }
.step-title { display: flex; align-items: center; gap: 10px; font-size: 17px; margin-bottom: 14px; }
.step-title b { width: 26px; height: 26px; border-radius: 50%; background: var(--green-600); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; }

/* ---------- Order success / tracking ---------- */
.success-hero { text-align: center; padding: 48px 20px 24px; }
.success-hero .tick { width: 76px; height: 76px; border-radius: 50%; background: var(--green-100); color: var(--green-600); display: inline-flex; align-items: center; justify-content: center; font-size: 40px; }
.success-hero h1 { font-size: clamp(28px, 4vw, 40px); margin: 18px 0 8px; }
.timeline { display: grid; grid-template-columns: repeat(4, 1fr); position: relative; margin: 8px 0 4px; }
.timeline::before { content: ""; position: absolute; top: 15px; left: 12.5%; right: 12.5%; height: 3px; background: var(--border); }
.timeline .fill { position: absolute; top: 15px; left: 12.5%; height: 3px; background: var(--green-600); }
.timeline .step { text-align: center; position: relative; font-size: 13px; color: var(--muted); font-weight: 600; }
.timeline .dot { width: 32px; height: 32px; border-radius: 50%; background: var(--surface); border: 3px solid var(--border); margin: 0 auto 8px; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.timeline .step.done { color: var(--text); }
.timeline .step.done .dot { background: var(--green-600); border-color: var(--green-600); color: #fff; }
.shipment { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px 16px; margin-top: 12px; }
.shipment-head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 8px; }

/* ---------- Auth pages ---------- */
.auth-wrap { min-height: calc(100vh - 220px); display: flex; align-items: center; justify-content: center; padding: 48px 20px; }
.auth-card { width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 32px; box-shadow: var(--shadow); }
.auth-card h1 { font-size: 28px; font-weight: 800; }
.auth-card .lead { color: var(--text-2); margin: 6px 0 22px; }
.auth-card .foot { text-align: center; margin-top: 20px; color: var(--text-2); font-size: 14px; }

/* ---------- Account ---------- */
.account-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 32px; padding: 24px 0 64px; align-items: start; }
.account-nav { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px; position: sticky; top: 140px; }
.account-nav .who { padding: 12px 12px 14px; border-bottom: 1px solid var(--border); margin-bottom: 8px; display: flex; gap: 12px; align-items: center; }
.account-nav a, .account-nav button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 9px; color: var(--text-2); font-weight: 600; width: 100%; background: none; border: 0; font: inherit; cursor: pointer; text-align: left; }
.account-nav a:hover, .account-nav button:hover { background: var(--surface-2); text-decoration: none; }
.account-nav a.active { background: var(--green-100); color: var(--green-700); }
.stat-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; }
.stat-card span { color: var(--text-2); font-size: 13.5px; font-weight: 600; }
.stat-card strong { display: block; font-family: var(--font-display); font-size: 28px; margin-top: 6px; }
table.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 10px 16px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.table td { padding: 14px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table-wrap { overflow-x: auto; }
.address-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.address-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; position: relative; }
.address-card.default { border-color: var(--green-600); box-shadow: 0 0 0 1px var(--green-600); }
.address-card .actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.address-card form { display: inline; }

/* ---------- Footer ---------- */
.site-footer { background: var(--green-900); color: #b9d2c4; padding: 56px 0 24px; margin-top: 40px; position: relative; }
.site-footer::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: var(--kente); }
.footer-grid { display: grid; grid-template-columns: 1.4fr .8fr .8fr 1.6fr; gap: 32px; }
.site-footer h4 { color: #fff; font-size: 18px; margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: #b9d2c4; font-size: 16px; overflow-wrap: break-word; }
.site-footer a:hover { color: #fff; }
.site-footer li .bi { color: var(--gold-500); margin-right: 4px; }
.footer-about { max-width: 340px; margin: 0; font-size: 16px; line-height: 1.6; }
.footer-social { display: flex; gap: 10px; margin-top: 18px; }
.footer-social a { width: 42px; height: 42px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 19px; background: rgba(255,255,255,.08); color: #fff; transition: background .15s, color .15s; }
.footer-social a:hover { background: var(--gold-500); color: var(--green-900); text-decoration: none; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 40px; padding-top: 20px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 14.5px; }
.pay-icons { display: flex; gap: 10px; font-size: 22px; color: #fff; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .grid-products { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .shop-layout, .product-layout, .cart-layout, .account-layout, .reviews-layout { grid-template-columns: 1fr; }
  .filters-panel { position: static; display: none; }
  .filters-panel.open { display: block; }
  .filter-toggle { display: inline-flex; }
  .account-nav { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .search-bar { display: none; }
  .header-main { gap: 12px; }
  .icon-link .label { display: none; }
  .product-layout { gap: 24px; }
}
@media (max-width: 640px) {
  body { font-size: 14.5px; }
  .wrap { padding: 0 16px; }
  .header-main { padding: 10px 16px; }
  .brand-lockup img { height: 60px; width: 60px; }
  .brand-words strong { font-size: 24px; }
  .brand-words small { font-size: 10.5px; letter-spacing: .08em; }
  .grid-products, .grid-products.three { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .p-card .body { padding: 10px 12px 12px; }
  .p-card .price strong { font-size: 16px; }
  .stat-cards, .address-grid { grid-template-columns: 1fr; }
  .form-row, .form-row.three { grid-template-columns: 1fr; gap: 0; }
  .cart-item { grid-template-columns: 64px minmax(0, 1fr); }
  .cart-item img { width: 64px; height: 64px; }
  .cart-item .line { grid-column: 2; text-align: left; }
  .footer-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 24px; }
  .section { padding: 40px 0; }
  .timeline .step { font-size: 11.5px; }
}

/* ---------- WhatsApp ordering ---------- */
.btn-whatsapp { background: #25d366; border-color: #25d366; color: #fff; }
.btn-whatsapp:hover { background: #1ebe5b; border-color: #1ebe5b; color: #fff; text-decoration: none; }
.buy-box + .btn-whatsapp, .btn-whatsapp.btn-lg { margin-top: 10px; }
.wa-float { position: fixed; right: 20px; bottom: 20px; z-index: 60; width: 56px; height: 56px; border-radius: 50%; background: #25d366; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 28px; box-shadow: var(--shadow-lg); transition: transform .15s; }
.wa-float:hover { color: #fff; transform: scale(1.06); text-decoration: none; }
@media (max-width: 640px) { .wa-float { right: 14px; bottom: 14px; width: 50px; height: 50px; font-size: 25px; } }

/* ---------- Product card: add to cart / stepper ---------- */
.card-buy { margin-top: 12px; position: relative; }
.card-buy form { margin: 0; }
.card-buy .buy-qty { display: none; }
.card-buy.in-cart .buy-add { display: none; }
.card-buy.in-cart .buy-qty { display: flex; }
.add-btn { width: 100%; height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 999px; border: 1.5px solid var(--green-600); background: var(--green-100); color: var(--green-700); font: inherit; font-weight: 700; font-size: 14px; cursor: pointer; transition: background .15s, color .15s, transform .1s, box-shadow .15s; }
.add-btn i { font-size: 16px; }
.add-btn:hover { background: var(--green-600); color: #fff; box-shadow: 0 6px 16px rgba(22,121,79,.28); }
.add-btn:active { transform: scale(.97); }
.add-btn:disabled { border-color: var(--border); background: var(--surface-2); color: var(--muted); cursor: not-allowed; box-shadow: none; }
.buy-qty { height: 42px; align-items: center; justify-content: space-between; gap: 6px; padding: 4px; border-radius: 999px; background: var(--green-600); color: #fff; box-shadow: 0 6px 16px rgba(22,121,79,.25); animation: qty-in .2s ease-out; }
.buy-qty .step { width: 34px; height: 34px; flex: none; border: 0; border-radius: 50%; background: rgba(255,255,255,.16); color: #fff; font-size: 15px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; transition: background .15s; }
.buy-qty .step:hover { background: rgba(255,255,255,.3); }
.buy-qty .step:disabled { opacity: .35; cursor: not-allowed; }
.buy-qty .n { font-size: 13.5px; font-weight: 600; white-space: nowrap; }
.buy-qty .n b { font-family: var(--font-display); font-size: 16px; font-weight: 800; }
.card-buy.busy { pointer-events: none; }
.card-buy.busy .add-btn, .card-buy.busy .buy-qty { opacity: .7; }
@keyframes qty-in { from { transform: scale(.92); opacity: .4; } to { transform: none; opacity: 1; } }
.icon-link .count.bump { animation: bump .4s ease-out; }
@keyframes bump { 40% { transform: scale(1.45); } }
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 80; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; display: flex; align-items: center; gap: 10px; max-width: calc(100% - 32px); background: var(--green-900); color: #fff; padding: 12px 14px 12px 16px; border-radius: 14px; box-shadow: var(--shadow-lg); font-size: 14px; transition: opacity .2s, transform .2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast i { color: #4ade80; font-size: 18px; }
.toast.error i { color: #fca5a5; }
.toast a { color: var(--gold-500); font-weight: 700; white-space: nowrap; margin-left: 6px; }

/* ---------- Home page ---------- */
.h-hero { position: relative; overflow: hidden; background: radial-gradient(circle at 0% 0%, var(--gold-100), transparent 40%), var(--bg); }
.h-hero > .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; padding-top: 56px; padding-bottom: 64px; }
.h-pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font-size: 13.5px; font-weight: 600; color: var(--green-700); box-shadow: var(--shadow); }
.h-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 4px rgba(34,197,94,.18); }
.h-hero h1 { font-size: clamp(40px, 5.6vw, 68px); line-height: 1.02; letter-spacing: -.02em; font-weight: 800; color: var(--green-900); margin: 22px 0 18px; }
.h-hero h1 em { font-style: normal; color: var(--green-600); position: relative; white-space: nowrap; z-index: 0; }
.h-hero h1 em::after { content: ""; position: absolute; left: -2%; right: -2%; bottom: .04em; height: .26em; background: var(--gold-500); opacity: .45; border-radius: 6px; z-index: -1; }
.h-hero h1 .typed-cursor { color: var(--gold-500); font-weight: 400; margin-left: 2px; }
.h-hero-copy > p { font-size: 18px; color: var(--text-2); max-width: 520px; margin: 0 0 28px; }
.h-ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.h-ctas .btn-primary { box-shadow: 0 10px 24px rgba(22,121,79,.28); }
.h-btn-wa { background: var(--surface); border-color: #25d366; color: #128c4b; }
.h-btn-wa:hover { background: #effcf4; color: #128c4b; }
.h-btn-wa.solid { background: #25d366; color: #fff; }
.h-btn-wa.solid:hover { background: #1ebe5b; color: #fff; }
.h-proof { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.h-proof > div { display: flex; align-items: center; gap: 10px; padding: 10px 14px 10px 10px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); font-size: 14px; color: var(--text-2); }
.h-proof i { width: 34px; height: 34px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: var(--green-100); color: var(--green-600); font-size: 17px; }
.h-proof strong { color: var(--text); }
.h-hero-art { position: relative; aspect-ratio: 1 / .92; max-width: 560px; width: 100%; justify-self: end; }
.h-blob { position: absolute; inset: 6% 4% 4% 8%; border-radius: 44% 56% 52% 48% / 48% 42% 58% 52%; background: radial-gradient(circle at 30% 25%, var(--green-600), var(--green-800) 70%); box-shadow: inset 0 0 0 10px rgba(255,255,255,.06); }
.h-blob::after { content: ""; position: absolute; inset: 14%; border-radius: inherit; border: 2px dashed rgba(255,255,255,.18); }
.h-float { position: absolute; display: block; background: #fff; border-radius: 26px; box-shadow: 0 24px 48px rgba(7,46,33,.28); padding: 16px; transition: transform .2s; }
.h-float:hover { transform: translateY(-4px) rotate(0deg) !important; text-decoration: none; }
.h-float img { width: 100%; height: 100%; object-fit: contain; }
.h-float .tag { position: absolute; left: 50%; bottom: -14px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--green-900); color: #fff; font-size: 14px; white-space: nowrap; box-shadow: var(--shadow); }
.h-float .tag strong { font-family: var(--font-display); }
.h-float .tag em { font-style: normal; font-size: 11.5px; font-weight: 800; background: var(--terra-500); padding: 2px 7px; border-radius: 999px; }
.h-float-0 { width: 46%; height: 52%; left: 27%; top: 18%; transform: rotate(-3deg); z-index: 2; }
.h-float-1 { width: 28%; height: 32%; left: 2%; top: 52%; transform: rotate(-8deg); }
.h-float-2 { width: 28%; height: 32%; right: 0; top: 46%; transform: rotate(7deg); }
.h-sticker { position: absolute; top: 2%; right: 6%; width: 118px; height: 118px; z-index: 3; animation: spin 18s linear infinite; filter: drop-shadow(0 8px 16px rgba(0,0,0,.2)); }
.h-sticker circle { fill: var(--gold-500); }
.h-sticker text { font: 800 9.6px var(--font-body); letter-spacing: .14em; fill: var(--green-900); }
.h-sticker .mid { font: 800 19px var(--font-display); letter-spacing: 0; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .h-sticker { animation: none; } }

.h-cats { padding: 8px 0 0; }
.h-cat-row { display: flex; gap: 18px; overflow-x: auto; padding: 8px 2px 12px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.h-cat-row::-webkit-scrollbar { display: none; }
.h-cat { flex: none; width: 112px; scroll-snap-align: start; text-align: center; color: var(--text); display: flex; flex-direction: column; align-items: center; gap: 4px; }
.h-cat:hover { text-decoration: none; }
.h-cat .bubble { width: 96px; height: 96px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; overflow: hidden; margin-bottom: 6px; transition: transform .15s, box-shadow .15s, border-color .15s; font-size: 32px; color: var(--green-600); }
.h-cat .bubble img { width: 74%; height: 74%; object-fit: contain; }
.h-cat:hover .bubble { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--green-600); }
.h-cat.all .bubble { background: var(--green-700); color: #fff; border-color: var(--green-700); }
.h-cat strong { font-size: 14px; line-height: 1.25; }
.h-cat small { font-size: 12px; color: var(--muted); }
.h-cat.soon .bubble { background: var(--surface-2); color: var(--muted); }
.h-cat.soon strong { color: var(--text-2); }

.h-section { padding: 36px 0; }
.h-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.h-head h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 800; color: var(--green-900); }
.h-head h2 i { color: var(--terra-500); font-size: .8em; }
.h-head p { margin: 4px 0 0; color: var(--text-2); }
.h-head-actions { display: flex; align-items: center; gap: 14px; }
.h-link { font-weight: 700; color: var(--green-700); white-space: nowrap; }
.rail-nav { display: flex; gap: 8px; }
.rail-nav[hidden] { display: none; }
.rail-nav button { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); cursor: pointer; font-size: 16px; display: inline-flex; align-items: center; justify-content: center; transition: background .15s, border-color .15s; }
.rail-nav button:hover { background: var(--green-700); border-color: var(--green-700); color: #fff; }
.rail { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 20px) / 4); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 18px; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }

.h-promos-wrap { padding-top: 20px; }
.h-promos { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.h-promo { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 200px; padding: 30px; border-radius: 24px; color: var(--green-900); transition: transform .15s, box-shadow .15s; }
.h-promo:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); text-decoration: none; color: var(--green-900); }
.h-promo > div { position: relative; z-index: 1; max-width: 62%; }
.h-promo .kicker { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; opacity: .75; }
.h-promo h3 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 800; margin: 8px 0 6px; line-height: 1.1; }
.h-promo p { margin: 0 0 16px; font-size: 14.5px; opacity: .85; }
.h-promo .go { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; padding: 9px 16px; border-radius: 999px; background: var(--green-900); color: #fff; font-size: 14px; }
.h-promo.deal { background: linear-gradient(135deg, #fde7b0, var(--gold-500)); }
.h-promo.deal img { width: 38%; max-height: 180px; object-fit: contain; transform: rotate(8deg); filter: drop-shadow(0 16px 20px rgba(0,0,0,.2)); }
.h-promo.wa { background: linear-gradient(135deg, #0f5132, #128c4b); color: #fff; }
.h-promo.wa:hover { color: #fff; }
.h-promo.wa .go { background: #25d366; color: #06301b; }
.h-promo .big-ic { font-size: 130px; line-height: 1; color: rgba(255,255,255,.16); position: absolute; right: -10px; bottom: -22px; }

.h-steps { display: grid; grid-template-columns: 1fr 2.6fr; gap: 32px; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: 24px; padding: 36px; }
.h-steps h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 800; color: var(--green-900); }
.h-steps-head p { color: var(--text-2); margin: 8px 0 0; }
.h-steps ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.h-steps li { position: relative; padding: 22px 20px; border-radius: 18px; background: var(--bg); display: flex; flex-direction: column; gap: 6px; }
.h-steps li > i { font-size: 28px; color: var(--green-600); }
.h-steps li .num { position: absolute; top: 16px; right: 18px; font: 800 40px/1 var(--font-display); color: var(--gold-500); opacity: .35; }
.h-steps li strong { font-family: var(--font-display); font-size: 17px; }
.h-steps li span:last-child { font-size: 14px; color: var(--text-2); }

.h-contact { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding: 40px; border-radius: 24px; background: radial-gradient(circle at 100% 0%, rgba(226,160,34,.25), transparent 45%), var(--green-800); color: #d9eadf; }
.h-contact::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 6px; background: var(--kente); }
.h-contact h2 { color: #fff; font-size: clamp(22px, 2.8vw, 30px); font-weight: 800; }
.h-contact p { margin: 8px 0 0; color: #b9d3c5; max-width: 480px; }
.h-contact-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.h-btn-call { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.25); color: #fff; }
.h-btn-call:hover { background: rgba(255,255,255,.16); color: #fff; }

@media (max-width: 1100px) {
  .rail { grid-auto-columns: calc((100% - 2 * 20px) / 3); }
  .h-steps { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .h-hero > .wrap { grid-template-columns: 1fr; gap: 28px; padding-top: 36px; padding-bottom: 48px; }
  .h-hero-art { justify-self: center; max-width: 460px; }
}
@media (max-width: 640px) {
  .h-hero h1 { font-size: 40px; }
  .h-hero-copy > p { font-size: 16px; }
  .h-ctas .btn { flex: 1 1 100%; justify-content: center; }
  .h-proof { gap: 8px; margin-top: 24px; }
  .h-proof > div { flex: 1; padding: 8px; gap: 6px; font-size: 12.5px; flex-direction: column; text-align: center; }
  .h-sticker { width: 90px; height: 90px; }
  .h-cat { width: 84px; }
  .h-cat .bubble { width: 76px; height: 76px; font-size: 26px; }
  .h-cat strong { font-size: 12.5px; }
  .h-section { padding: 26px 0; }
  .h-head-actions .rail-nav { display: none; }
  .rail { grid-auto-columns: 46%; gap: 12px; }
  .h-promo { padding: 22px; min-height: 170px; }
  .h-steps { padding: 22px; }
  .h-steps ol { grid-template-columns: 1fr; }
  .h-contact { padding: 26px 22px 32px; }
  .h-contact-actions .btn { flex: 1 1 100%; justify-content: center; }
  .add-btn, .buy-qty { height: 38px; font-size: 13px; }
  .buy-qty .step { width: 30px; height: 30px; }
  .buy-qty .n { font-size: 12px; }
}
@media (max-width: 400px) {
  .header-main .brand-lockup { gap: 8px; }
  .header-main .brand-lockup img { height: 52px; width: 52px; }
  .header-main .brand-words strong { font-size: 21px; }
  .header-main .brand-words small { font-size: 9px; letter-spacing: .05em; }
}

/* ---------- Mobile menu drawer ---------- */
.search-toggle { display: none; border: 0; background: none; cursor: pointer; font: inherit; }
.m-drawer { position: fixed; inset: 0; z-index: 1000; }
.m-drawer[hidden] { display: none; }
.m-drawer-backdrop { position: absolute; inset: 0; background: rgba(7, 46, 33, .45); opacity: 0; transition: opacity .2s ease; }
.m-drawer-panel { position: absolute; top: 0; left: 0; bottom: 0; width: min(88vw, 360px); background: var(--surface); box-shadow: 8px 0 32px rgba(0,0,0,.18); display: flex; flex-direction: column; overflow-y: auto; transform: translateX(-100%); transition: transform .22s ease; }
.m-drawer.open .m-drawer-backdrop { opacity: 1; }
.m-drawer.open .m-drawer-panel { transform: none; }
.m-drawer-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 14px 14px 12px 16px; border-bottom: 1px solid var(--border); }
.m-drawer-head .brand-sm img { height: 46px; width: 46px; }
.m-drawer-head .brand-sm .brand-words strong { font-size: 20px; }
.m-drawer-head .brand-sm .brand-words small { font-size: 9px; letter-spacing: .06em; }
.m-drawer-x { border: 0; background: var(--surface-2); width: 40px; height: 40px; border-radius: 50%; font-size: 17px; cursor: pointer; color: var(--text); flex-shrink: 0; }
.m-search { display: block !important; max-width: none; margin: 14px 16px 6px; }
.m-drawer-nav { display: flex; flex-direction: column; padding: 4px 8px 12px; }
.m-drawer-nav a { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 10px; color: var(--text); font-weight: 600; font-size: 15.5px; }
.m-drawer-nav a .bi { color: var(--green-600); font-size: 17px; width: 20px; text-align: center; }
.m-drawer-nav a:hover, .m-drawer-nav a.active { background: var(--green-100); color: var(--green-700); text-decoration: none; }
.m-label { font-size: 11.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 14px 12px 4px; }
.m-count { margin-left: auto; background: var(--terra-500); color: #fff; font-size: 12px; font-weight: 800; min-width: 22px; height: 22px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; }
.m-drawer-contact { margin-top: auto; padding: 16px; border-top: 1px solid var(--border); display: grid; gap: 10px; }
.m-drawer-contact a:not(.btn) { color: var(--text-2); font-weight: 600; }
body.drawer-open { overflow: hidden; }
@media (max-width: 900px) {
  .menu-btn { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; margin-left: -6px; flex-shrink: 0; }
  .search-toggle { display: inline-flex; }
  .header-actions .icon-link[href*="login.php"], .header-actions .icon-link[href*="account/"] { display: none; }
}
@media (max-width: 400px) {
  .header-main { gap: 6px; }
  .header-actions { gap: 0; }
  .header-actions .icon-link { padding: 8px 7px; }
}
@media (prefers-reduced-motion: reduce) { .m-drawer-panel, .m-drawer-backdrop { transition: none; } }

/* ---------- App-style mobile UI (bottom tab bar, install banner) ---------- */
.tabbar { display: none; }
.install-banner, .install-sheet { display: none; }
@media (max-width: 900px) {
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
    background: rgba(255,255,255,.97); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid var(--border); box-shadow: 0 -6px 20px rgba(29,27,22,.07); padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); }
  .tabbar a, .tabbar button { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 4px 0; border: 0; background: none;
    color: var(--muted); font: inherit; font-size: 11.5px; font-weight: 700; cursor: pointer; -webkit-tap-highlight-color: transparent; }
  .tabbar i { font-size: 22px; line-height: 1; }
  .tabbar a:hover { text-decoration: none; }
  .tabbar .on { color: var(--green-700); }
  .tabbar .on::before { content: ""; position: absolute; top: -6px; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--gold-500); }
  .tab-count { position: absolute; top: 0; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--terra-500);
    color: #fff; font-size: 10.5px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; border: 2px solid #fff; }
  .tab-count[hidden] { display: none; }
  body { padding-bottom: calc(66px + env(safe-area-inset-bottom)); }
  .wa-float { bottom: calc(80px + env(safe-area-inset-bottom)); }
  .toast { bottom: calc(84px + env(safe-area-inset-bottom)); }
  /* The tab bar already has cart + account, so the header keeps only menu, logo and search. */
  .header-actions #cartLink { display: none; }

  .install-banner { display: flex; align-items: center; gap: 12px; position: fixed; left: 10px; right: 10px; z-index: 75;
    bottom: calc(74px + env(safe-area-inset-bottom)); padding: 10px 10px 10px 12px; border-radius: 16px;
    background: var(--green-900); color: #fff; box-shadow: var(--shadow-lg); animation: install-in .25s ease-out; }
  .install-banner[hidden] { display: none; }
  .install-banner img { width: 44px; height: 44px; border-radius: 11px; flex-shrink: 0; }
  .install-banner .grow { flex: 1; min-width: 0; line-height: 1.25; }
  .install-banner strong { display: block; font-size: 14.5px; }
  .install-banner span { font-size: 12.5px; color: #b9d2c4; }
  .install-banner .btn { background: var(--gold-500); border-color: var(--gold-500); color: var(--green-900); }
  .install-x { border: 0; background: none; color: #b9d2c4; font-size: 15px; padding: 6px; cursor: pointer; }
  body.has-install-banner .wa-float { bottom: calc(150px + env(safe-area-inset-bottom)); }
}
.install-sheet:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 1100; }
.install-sheet-backdrop { position: absolute; inset: 0; background: rgba(7,46,33,.5); }
.install-sheet-panel { position: absolute; left: 0; right: 0; bottom: 0; max-width: 520px; margin: 0 auto; background: var(--surface); border-radius: 22px 22px 0 0;
  padding: 24px 22px calc(22px + env(safe-area-inset-bottom)); text-align: center; animation: install-in .25s ease-out; }
.install-sheet-panel img { width: 64px; height: 64px; border-radius: 16px; margin: 0 auto 10px; box-shadow: var(--shadow); }
.install-sheet-panel h3 { font-size: 20px; margin-bottom: 12px; }
.install-sheet-panel ol { text-align: left; margin: 0 0 18px; padding-left: 22px; line-height: 1.7; color: var(--text-2); }
.install-sheet-panel ol .bi { color: var(--green-600); }
@keyframes install-in { from { transform: translateY(16px); opacity: 0; } to { transform: none; opacity: 1; } }

/* When opened from the home screen (installed app): feel native, no browser chrome. */
.is-app body { overscroll-behavior-y: none; }
.is-app .announce { display: none; }
.is-app .site-header { padding-top: env(safe-area-inset-top); }
@media (prefers-reduced-motion: reduce) { .install-banner, .install-sheet-panel { animation: none; } }

/* ---------- Layout safety + account pages (mobile polish) ---------- */
/* Grid columns may shrink below their content (stops tables/long words pushing the page wider than the screen). */
.account-layout > *, .cart-layout > *, .shop-layout > *, .product-layout > *, .reviews-layout > *, .account-split > * { min-width: 0; }
.stack { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; align-content: start; }
.stack-sm { gap: 16px; }
.account-split { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.order-rows { display: grid; }
.order-row { display: flex; align-items: center; gap: 14px; padding: 14px 20px; border-bottom: 1px solid var(--border); color: var(--text); }
.order-row:last-child { border-bottom: 0; }
.order-row:hover { background: var(--surface-2); text-decoration: none; }
.order-row .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.order-row .amt { font-family: var(--font-display); font-size: 17px; white-space: nowrap; }

@media (max-width: 900px) {
  .account-split { grid-template-columns: minmax(0, 1fr); }
  .shop-layout, .product-layout, .cart-layout, .account-layout, .reviews-layout, .success-layout { grid-template-columns: minmax(0, 1fr); }
  /* Account menu becomes a swipeable row of tabs, like an app. */
  .account-layout { gap: 18px; padding-top: 16px; }
  .account-nav { display: flex; gap: 8px; overflow-x: auto; padding: 0; background: none; border: 0; border-radius: 0; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 2px; }
  .account-nav::-webkit-scrollbar { display: none; }
  .account-nav .who { display: none; }
  .account-nav a, .account-nav button { flex: none; width: auto; padding: 9px 14px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--surface); font-size: 14px; white-space: nowrap; }
  .account-nav a.active { background: var(--green-600); border-color: var(--green-600); color: #fff; }
  .account-nav form { flex: none; display: flex; }
}
@media (max-width: 640px) {
  .stack { gap: 16px; }
  .account-layout h1 { font-size: 24px !important; }
  .stat-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .stat-card { padding: 12px; }
  .stat-card span { font-size: 12px; }
  .stat-card strong { font-size: 20px; overflow-wrap: anywhere; }
  .order-row { padding: 12px 14px; gap: 10px; flex-wrap: wrap; }
  .order-row .grow { flex-basis: 100%; }
  .order-row .amt { margin-left: auto; }
  .order-row > .bi { display: none; }
  .panel-head { padding: 14px 16px; }
  .panel-body { padding: 16px; }
  .page-title { padding-top: 20px; }
  .auth-wrap { padding: 24px 16px; min-height: 0; }
  .empty-state { padding: 40px 16px; }
}

/* ---------- Compact footer on phones ---------- */
@media (max-width: 640px) {
  .site-footer { padding: 36px 0 20px; margin-top: 28px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px 16px; }
  .footer-grid > div:first-child, .footer-grid > div:last-child { grid-column: 1 / -1; }
  .site-footer .brand-lg img { height: 64px; width: 64px; }
  .site-footer .brand-lg .brand-words strong { font-size: 26px; }
  .site-footer .brand-lg .brand-words small { font-size: 11px; letter-spacing: .1em; }
  .footer-about { font-size: 15px; }
  .site-footer h4 { font-size: 16px; margin-bottom: 10px; }
  .site-footer ul { gap: 8px; }
  .site-footer a { font-size: 15px; }
  .footer-bottom { margin-top: 26px; flex-direction: column; align-items: flex-start; }
}

/* ---------- App-style page loader (phones only) ---------- */
.page-loader { display: none; }
@media (max-width: 900px) {
  .page-loader { display: flex; position: fixed; inset: 0; z-index: 2000; align-items: center; justify-content: center;
    background: rgba(251, 248, 242, .94); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
    transition: opacity .25s ease, visibility .25s ease;
    /* Safety net: never stays up more than 6s, even if JavaScript fails. */
    animation: pl-failsafe 0s linear 6s forwards; }
  .page-loader.done { opacity: 0; visibility: hidden; pointer-events: none; }
  .page-loader.show { opacity: 1; visibility: visible; pointer-events: auto; animation: none; }
}
.pl-badge { position: relative; width: 104px; height: 104px; display: flex; align-items: center; justify-content: center; }
.pl-badge img { width: 84px; height: 84px; border-radius: 50%; animation: pl-pulse 1.4s ease-in-out infinite; position: relative; z-index: 1; }
.pl-ring { position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(var(--green-600) 0 30%, var(--gold-500) 30% 55%, var(--terra-500) 55% 72%, transparent 72%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
          mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
  animation: pl-spin .9s linear infinite; }
@keyframes pl-spin { to { transform: rotate(360deg); } }
@keyframes pl-pulse { 50% { transform: scale(.93); } }
@keyframes pl-failsafe { to { opacity: 0; visibility: hidden; pointer-events: none; } }
@media (prefers-reduced-motion: reduce) { .pl-ring { animation-duration: 2.4s; } .pl-badge img { animation: none; } }

/* ---------- Add-to-cart animation ---------- */
.fly-ghost { position: fixed; z-index: 3000; pointer-events: none; object-fit: contain; background: #fff; border-radius: 18px;
  padding: 6px; box-shadow: 0 14px 34px rgba(7, 46, 33, .32); will-change: transform, opacity; }
.cart-pop i { display: inline-block; animation: cart-pop .55s cubic-bezier(.3, 1.6, .5, 1); color: var(--green-600); }
@keyframes cart-pop { 0% { transform: scale(1); } 35% { transform: scale(1.4) rotate(-10deg); } 65% { transform: scale(.9) rotate(4deg); } 100% { transform: scale(1); } }
.tab-count.bump { animation: bump .45s ease-out; }
.btn.is-adding { opacity: .75; }
.btn.is-adding .bi { animation: pl-spin .8s linear infinite; display: inline-block; }
@media (prefers-reduced-motion: reduce) { .cart-pop i, .tab-count.bump { animation: none; } }
