/* ==========================================================================
   Design layer (layer.css) — loaded after the core CSS, before butcher.css.
   Values below were measured from the reference storefront the design was
   modelled on: container padding, header, topbar,
   stories rings, category tiles, flash-deals wave, rail titles and grids.
   Colours stay on the theme tokens (--primary, --accent, --bg, --ink ...), so
   the palette is edited from the theme settings only; the shades below derive
   from those tokens.
   ========================================================================== */

/* ── Container: 16 / 48 / 96px side padding, 1440px max (content 1248px) ── */
:root {
  --gutter: 1rem;
  /* shades derived from the settings palette */
  --primary-deep: color-mix(in srgb, var(--primary) 72%, #000);
  --gold-light: color-mix(in srgb, var(--accent) 55%, #fff);
  --gold-dark: color-mix(in srgb, var(--accent) 78%, #000);
  --gold-gradient: linear-gradient(180deg, var(--gold-light) 0%, var(--accent) 50%, var(--gold-dark) 100%);
}
@media (min-width: 768px)  { :root { --gutter: 3rem; } }
@media (min-width: 1024px) { :root { --gutter: 6rem; } }

/* ══ Topbar ════════════════════════════════════════════════════════════
   Slim deep-green strip: phone · store message · location + language, the
   two controls on the end side share one pill style. */
.announce {
  position: relative;
  z-index: 60;
  background: var(--topbar-bg);
  color: var(--topbar-text);
  font-size: 0.8125rem;
  font-weight: 500;
}
.announce__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  min-height: 2.25rem;
}
.announce__side { display: flex; align-items: center; gap: 0.5rem; min-width: 0; }
.announce__side--end { justify-content: flex-end; }
.announce__item {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: inherit;
  opacity: 0.92;
  white-space: nowrap;
}
.announce__item:hover { opacity: 1; }
.announce__item .icon, .announce__pill .icon { color: var(--accent); flex: none; }
.announce__text { margin: 0; text-align: center; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.announce__text a { color: inherit; }

/* one pill style for location and language */
.announce__pill,
.announce .lang-switch__item {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  height: 1.625rem;
  padding-inline: 0.625rem;
  border: 1px solid color-mix(in srgb, currentColor 28%, transparent);
  border-radius: 9999px;
  background: none;
  color: inherit;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.announce__pill:hover,
.announce .lang-switch__item:hover { background: color-mix(in srgb, currentColor 12%, transparent); border-color: color-mix(in srgb, currentColor 45%, transparent); }
.announce__pill--static { cursor: default; }
.announce__pill--static:hover { background: none; border-color: color-mix(in srgb, currentColor 28%, transparent); }
.announce .lang-switch { display: inline-flex; gap: 0; }
.announce .lang-switch__item[aria-current] { display: none; } /* only the other language */

.announce__loc { position: relative; }
.announce__loc-menu {
  position: absolute;
  inset-block-start: calc(100% + 0.375rem);
  inset-inline-end: 0;
  z-index: 70;
  min-width: 11rem;
  max-height: 18rem;
  overflow-y: auto;
  margin: 0;
  padding: 0.375rem;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 0.875rem;
  background: var(--card-bg);
  color: var(--ink);
  box-shadow: 0 18px 40px -16px rgb(15 31 23 / 0.35);
}
.announce__loc-menu button {
  display: block;
  width: 100%;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  background: none;
  color: inherit;
  font: inherit;
  font-size: 0.875rem;
  text-align: start;
  cursor: pointer;
}
.announce__loc-menu button:hover,
.announce__loc-menu button:focus-visible { background: color-mix(in srgb, var(--primary) 8%, var(--card-bg)); color: var(--primary); outline: none; }

@media (max-width: 767px) {
  .announce__inner { grid-template-columns: minmax(0, 1fr) auto; }
  .announce__side:first-child { display: none; }
  .announce__text { text-align: start; }
  .announce__pill--static span { display: none; }
}

/* ══ Header ════════════════════════════════════════════════════════════
   White main row (every control 44px tall) over a green nav band with
   rounded bottom corners. 64px row on phones, 84px from 1024px. */
.header.hdr { background: none; color: var(--ink); border-radius: 0; overflow: visible; }
.header.hdr.is-stuck { box-shadow: none; }

.hdr__main {
  position: relative;
  z-index: 3;
  background: var(--card-bg);
  border-block-end: 1px solid var(--line);
}
.hdr__main-inner {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  grid-template-areas:
    "burger brand . actions"
    "search search search search";
  align-items: center;
  column-gap: 0.5rem;
  row-gap: 0.75rem;
  padding-block: 0.75rem;
}
.hdr__burger  { grid-area: burger; }
.hdr__brand   { grid-area: brand; display: flex; align-items: center; min-width: 0; }
.hdr__search  { grid-area: search; display: block; position: relative; max-width: none; min-width: 0; }
.hdr__actions { grid-area: actions; justify-self: end; display: flex; align-items: center; gap: 0.5rem; }
@media (min-width: 1024px) {
  .hdr__main-inner {
    grid-template-columns: auto minmax(16rem, 1fr) auto;
    grid-template-areas: "brand search actions";
    column-gap: 1.25rem;
    min-height: 5.25rem;
  }
  .hdr__action.hdr__burger { display: none; }
}
@media (min-width: 1280px) { .hdr__main-inner { column-gap: 1.75rem; } }
@media (max-width: 1023px) {
  .hdr__main { border-block-end: 0; border-end-start-radius: 1.25rem; border-end-end-radius: 1.25rem; box-shadow: 0 6px 20px -12px rgb(15 31 23 / 0.25); }
}

/* logo: the store's own, else the Arabshop mark + name; size and spacing follow the logo settings (layout.css, as in Duha) */

/* search: soft sand field, white with a green ring on focus */
.hdr .search__form {
  height: 2.75rem;
  padding: 0 0.25rem;
  border: 1px solid var(--line);
  border-radius: 0.875rem;
  background: color-mix(in srgb, var(--bg) 70%, var(--card-bg));
  box-shadow: none;
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.hdr .search__form:hover { border-color: color-mix(in srgb, var(--primary) 30%, var(--line)); }
.hdr .search__form:focus-within { background: var(--card-bg); border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 14%, transparent); }
.hdr .search__submit { order: -1; width: 2.5rem; height: 2.5rem; border-radius: 0.625rem; color: var(--muted); background: none; }
.hdr .search__submit:hover { color: var(--primary); background: none; }
.hdr .search__input { padding-inline: 0.25rem 0.75rem; font-size: 0.9375rem; color: var(--ink); text-overflow: ellipsis; }
.hdr .search__input::placeholder { color: color-mix(in srgb, var(--muted) 85%, transparent); }
.hdr .search__form:focus-within .search__input { color: var(--ink); }

/* wallet (signed-in customers only) */
.hdr__wallet {
  display: none;
  align-items: center;
  gap: 0.5rem;
  height: 2.75rem;
  padding-inline: 0.5rem 0.875rem;
  border-radius: 0.875rem;
  background: color-mix(in srgb, var(--accent) 14%, var(--card-bg));
  color: var(--ink);
  transition: background-color var(--t-fast) var(--ease);
}
.hdr__wallet:hover { background: color-mix(in srgb, var(--accent) 24%, var(--card-bg)); }
@media (min-width: 1280px) { .hdr__wallet { display: inline-flex; } }
.hdr__wallet-coin { width: 1.5rem; height: 1.5rem; flex: none; object-fit: contain; }
.hdr__wallet-text { display: flex; flex-direction: column; line-height: 1.2; }
.hdr__wallet-label { font-size: 0.6875rem; font-weight: 500; color: var(--muted); }
.hdr__wallet-value { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 0.9375rem; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hdr__riyal { width: 0.8125rem; height: 0.8125rem; color: var(--muted); }

/* icon buttons: all 44px; account and cart grow a label from 1280px */
.hdr__action {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex: none;
  min-width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 0.875rem;
  background: color-mix(in srgb, var(--bg) 60%, var(--card-bg));
  color: var(--ink);
  font-size: 0.875rem;
  font-weight: 700;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.hdr__action:hover { color: var(--primary); border-color: color-mix(in srgb, var(--primary) 35%, var(--line)); background: color-mix(in srgb, var(--primary) 6%, var(--card-bg)); }
.hdr__action-label { display: none; }
@media (min-width: 1280px) {
  .hdr__action--cart, .hdr__action--login { padding-inline: 0.875rem 1rem; }
  .hdr__action-label { display: inline; }
}
.hdr__action--cart { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.hdr__action--cart:hover { background: var(--primary-deep); border-color: var(--primary-deep); color: var(--on-primary); }
.hdr__action .count-dot {
  position: absolute;
  inset-block-start: -0.375rem;
  inset-inline-end: -0.375rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding-inline: 0.3rem;
  border: 2px solid var(--card-bg);
  border-radius: 9999px;
  background: var(--sale);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  line-height: 1;
}
.hdr__action .count-dot[hidden] { display: none; }
.hdr__action--signed .header__signed-dot { inset-block-start: 0.5rem; inset-inline-end: 0.5rem; border-color: var(--card-bg); }
@media (max-width: 1023px) { .hdr__burger { background: none; border-color: transparent; } }

/* ── green nav band ── */
.hdr__nav {
  display: none;
  position: relative;
  z-index: 2;
  background: linear-gradient(180deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: var(--on-primary);
  border-end-start-radius: 1.5rem;
  border-end-end-radius: 1.5rem;
}
@media (min-width: 1024px) { .hdr__nav { display: block; } }
.header.hdr.is-stuck .hdr__nav { box-shadow: 0 10px 24px -14px rgb(15 31 23 / 0.45); }
.hdr__nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 3.25rem; }
/* the links never spill past the container: on a tight screen the row scrolls sideways (no scrollbar shown) */
.hdr__links {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.hdr__links::-webkit-scrollbar { display: none; }
.hdr__link {
  position: relative;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  height: 3.25rem;
  padding-inline: 0.875rem;
  border: 0;
  border-radius: 0;
  background: none;
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--on-primary) 86%, transparent);
  white-space: nowrap;
  cursor: pointer;
  transition: color var(--t-fast) var(--ease);
}
.hdr__link::after {
  content: "";
  position: absolute;
  inset-inline: 0.875rem;
  inset-block-end: 0.5rem;
  height: 3px;
  border-radius: 3px;
  background: var(--accent);
  transform: scaleX(0);
  transition: transform var(--t-base) var(--ease-out);
}
.hdr__link:hover { color: var(--on-primary); }
.hdr__link:hover::after { transform: scaleX(0.5); }
.hdr__link.is-active { color: var(--on-primary); font-weight: 700; }
.hdr__link.is-active::after { transform: scaleX(1); }
.hdr__link:focus-visible { outline: 2px solid var(--accent); outline-offset: -4px; border-radius: 0.5rem; }
.hdr__caret { transition: transform var(--t-fast) var(--ease); }
.hdr__nav.is-cats-open .hdr__caret,
.hdr__nav:has(.hdr__cats-btn:hover) .hdr__caret { transform: rotate(180deg); }
.hdr__cats-btn { color: var(--on-primary); }
.hdr__nav.is-cats-open .hdr__cats-btn::after { transform: scaleX(1); }

.hdr__offers {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  flex: none;
  height: 2.25rem;
  padding-inline: 0.875rem 1rem;
  border-radius: 9999px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.875rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.hdr__offers:hover { background: var(--gold-light); color: var(--on-accent); transform: translateY(-1px); }
.hdr__offers .icon { color: var(--sale); }

/* "الأقسام" panel: a white card under the band, every category with its first six sub-links */
.hdr__mega {
  position: absolute;
  inset-inline: 0;
  inset-block-start: 100%;
  padding-block-start: 0.5rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 180ms var(--ease), transform 180ms var(--ease), visibility 0s linear 180ms;
}
.hdr__nav.is-cats-open .hdr__mega,
.hdr__nav:has(.hdr__cats-btn:hover) .hdr__mega,
.hdr__mega:hover {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 180ms var(--ease), transform 180ms var(--ease), visibility 0s;
}
.hdr__mega-card {
  padding: 1.5rem 1.75rem;
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  background: var(--card-bg);
  color: var(--ink);
  box-shadow: 0 28px 60px -24px rgb(15 31 23 / 0.4);
}
.hdr__mega-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 1.5rem 2rem; }
.hdr__mega-col { display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; min-width: 0; }
.hdr__mega-title {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 800;
  color: var(--ink);
}
.hdr__mega-title .menu-icon, .hdr__mega-title .icon { color: var(--primary); }
.hdr__mega-title:hover, .hdr__mega-title.is-active { color: var(--primary); }
.hdr__mega-list { display: flex; flex-direction: column; gap: 0.125rem; margin: 0; padding: 0; list-style: none; }
.hdr__mega-link { display: block; padding-block: 0.25rem; font-size: 0.875rem; color: var(--muted); transition: color var(--t-fast) var(--ease); }
.hdr__mega-link:hover, .hdr__mega-link.is-active { color: var(--primary); }
.hdr__mega-all { display: inline-flex; align-items: center; gap: 0.25rem; margin-block-start: 0.125rem; font-size: 0.8125rem; font-weight: 700; color: var(--primary); }
.hdr__mega-all:hover { gap: 0.4rem; }

@media (prefers-reduced-motion: reduce) {
  .hdr__link::after, .hdr__caret, .hdr__offers, .hdr__mega { transition: none; }
}

/* ── Section titles: 24px semibold, underlined "view all" ─────────────── */
.section-head { margin-block-end: 1.5rem; }
.section-head__title {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
}
@media (min-width: 768px)  { .section-head__title { font-size: 1.375rem; } }
@media (min-width: 1024px) { .section-head__title { font-size: 1.5rem; } }
.section-head__eyebrow { color: var(--primary); }
.section-head__link {
  gap: 0.25rem;
  font-size: 1rem;
  font-weight: 400;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.section-head__link:hover { gap: 0.25rem; }

/* ══ Stories rail ══════════════════════════════════════════════════════
   Round category pictures in a green → gold ring, name underneath. Scrolls
   sideways with snap; arrows (desktop) appear only when there is more. */
.section--stories { padding-block: 1.75rem 0.5rem; }
@media (min-width: 1024px) { .section--stories { padding-block: 2.5rem 1rem; } }
.section--stories .section-head { margin-block-end: 1rem; }
@media (min-width: 1024px) { .section--stories .section-head { margin-block-end: 1.25rem; } }

.story-strip {
  display: flex;
  gap: 0.875rem;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  scrollbar-width: none;
  margin-inline: calc(var(--gutter) * -1);
  padding: 0.25rem var(--gutter) 0.5rem;
}
.story-strip::-webkit-scrollbar { display: none; }
@media (min-width: 768px)  { .story-strip { gap: 1rem; } }
@media (min-width: 1024px) { .story-strip { gap: 1.375rem; margin-inline: 0; padding-inline: 0.25rem; scroll-padding-inline: 0.25rem; } }

.story {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.375rem;
  width: 4rem;
  scroll-snap-align: start;
  text-align: center;
  color: var(--ink);
}
@media (min-width: 768px)  { .story { width: 4.5rem; } }
@media (min-width: 1024px) { .story { width: 5.25rem; gap: 0.5rem; } }

.story__ring {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  padding: 2px;
  border-radius: 50%;
  background: conic-gradient(from 200deg, var(--primary), var(--accent), var(--primary));
  transition: transform var(--t-base) var(--ease-out), box-shadow var(--t-base) var(--ease-out);
}
.story__img {
  display: block;
  width: 100%;
  height: 100%;
  border: 3px solid var(--bg);
  border-radius: 50%;
  object-fit: cover;
  background: var(--card-bg);
}
.story__img--empty {
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--primary) 10%, var(--card-bg));
  color: var(--primary);
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 800;
}
.story__name {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 100%;
  font-size: 0.6875rem;
  font-weight: 600;
  line-height: 1.35;
  transition: color var(--t-fast) var(--ease);
}
@media (min-width: 768px) { .story__name { font-size: 0.8125rem; } }
.story__count { font-size: 0.6875rem; color: var(--muted); }
a.story:hover .story__ring { transform: translateY(-3px); box-shadow: 0 10px 20px -12px color-mix(in srgb, var(--primary) 70%, transparent); }
a.story:hover .story__name { color: var(--primary); }
a.story:focus-visible { outline: none; }
a.story:focus-visible .story__ring { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--primary); }

/* arrows sit on the picture's centre line, just outside the strip */
.story-rail .rail-btn { top: calc(2.625rem + 0.25rem); transform: translateY(-50%); }
.story-rail .rail-btn--prev { inset-inline-start: -1.25rem; }
.story-rail .rail-btn--next { inset-inline-end: -1.25rem; }
@media (prefers-reduced-motion: reduce) { .story__ring { transition: none; } }

/* ── Categories: 16:9 tiles, 5 columns, soft bottom gradient, gold title ── */
.cat-strip { gap: 0.75rem; }
@media (min-width: 640px)  { .cat-strip { gap: 1rem; grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 900px)  { .cat-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .cat-strip { gap: 1.25rem; } }
@media (min-width: 1100px) { .cat-strip { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1280px) { .cat-strip { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.category-card {
  aspect-ratio: 16 / 9;
  border-radius: 1rem;
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  transition: transform 500ms var(--ease-out), box-shadow 500ms var(--ease-out);
}
.category-card:hover { transform: translateY(-0.5rem); box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25); }
.category-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgb(0 0 0 / 0.6), rgb(0 0 0 / 0.2), transparent);
  opacity: 0.6;
  transition: opacity 500ms var(--ease-out);
}
.category-card:hover .category-card__media::after { opacity: 0.8; }
.category-card__media img { transition: transform 700ms var(--ease-out); }
.category-card:hover .category-card__media img { transform: scale(1.1); }
.category-card__name {
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  font-weight: 900;
  font-size: 0.875rem;
  filter: drop-shadow(0 10px 8px rgb(0 0 0 / 0.04)) drop-shadow(0 4px 3px rgb(0 0 0 / 0.1));
}
@media (min-width: 768px)  { .category-card__name { font-size: 1rem; } }
@media (min-width: 1024px) { .category-card__name { font-size: 1.25rem; } }
@media (min-width: 1280px) { .category-card__name { font-size: 1.5rem; } }
@media (min-width: 1536px) { .category-card__name { font-size: 1.875rem; } }

/* the small arc at the top corner of the categories title, on its ending side (left in Arabic) */
.section--collection-list .section-head__title { position: relative; justify-self: start; padding-inline-end: 0.875rem; }
.section--collection-list .section-head__title::before {
  content: "";
  position: absolute;
  inset-block-start: -0.125rem;
  inset-inline-end: -0.125rem;
  width: 15px;
  height: 15px;
  background: url("../images/shape-ellipse.svg") no-repeat center / contain;
}
[dir="ltr"] .section--collection-list .section-head__title::before { transform: scaleX(-1); }

/* ── Flash deals: peach wave behind the title, orange title, purple timer ─ */
.section--flash {
  position: relative;
  padding-block: 0;
  background: none;
  overflow-x: clip;
}
.section--flash::before {
  content: "";
  position: absolute;
  inset-inline: 0;
  top: 0;
  height: 4rem;
  background: url("../images/shape-subtract.svg") no-repeat top center / 100% auto;
  pointer-events: none;
}
@media (min-width: 768px)  { .section--flash::before { height: 6rem; } }
@media (min-width: 1024px) { .section--flash::before { height: 8rem; } }
.section--flash > .container { position: relative; z-index: 1; padding-block: 1.25rem 0; }
@media (min-width: 768px)  { .section--flash > .container { padding-block-start: 1.5rem; } }
@media (min-width: 1024px) { .section--flash > .container { padding-block-start: 2rem; } }
.section--flash .section-head { margin-block-end: 1rem; }
@media (min-width: 1024px) { .section--flash .section-head { margin-block-end: 2rem; } }
.section--flash .section-head__title {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--sale);
  white-space: nowrap;
}
@media (min-width: 768px)  { .section--flash .section-head__title { font-size: 1.5rem; } }
@media (min-width: 1024px) { .section--flash .section-head__title { font-size: 1.875rem; } }
@media (min-width: 1280px) { .section--flash .section-head__title { font-size: 2.25rem; } }
.section-head__zap { display: inline-flex; color: var(--accent); }
.section--flash .section-head__zap .icon { width: 1.75rem; height: 1.75rem; }

.section--flash .countdown { gap: 0.375rem; }
@media (min-width: 768px) { .section--flash .countdown { gap: 0.5rem; } }
.section--flash .countdown__sep { display: none; }
.section--flash .countdown__cell {
  width: auto;
  min-height: 0;
  padding: 0;
  gap: 0.25rem;
  background: none;
  box-shadow: none;
  border: 0;
}
.section--flash .countdown__cell b {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 0.375rem;
  background: var(--primary);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.1);
  font-variant-numeric: tabular-nums;
}
.section--flash .countdown__cell small {
  font-size: 0.5625rem;
  font-weight: 500;
  color: color-mix(in srgb, var(--primary) 80%, transparent);
}
@media (min-width: 768px) {
  .section--flash .countdown__cell b { width: 2.25rem; height: 2.25rem; border-radius: 0.5rem; font-size: 0.875rem; }
  .section--flash .countdown__cell small { font-size: 0.625rem; }
}

/* ── Product rails: grid mode and banner header ────────────────────────── */
.product-rail--grid {
  display: grid;
  grid-auto-flow: row;
  grid-auto-columns: auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  overflow: visible;
  margin-inline: 0;
  padding-inline: 0;
  scroll-snap-type: none;
}
@media (min-width: 768px)  { .product-rail--grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .product-rail--grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.product-rail--grid:not(:has(> :nth-child(3))) { grid-auto-columns: auto; }
.rail-wrap--grid .rail-btn { display: none; }

/* fixed 194px cards in scrolling rails on desktop, like the reference carousels */
@media (min-width: 1024px) {
  .product-rail--fixed { grid-auto-columns: 12.125rem; justify-content: start; }
}

/* ══ Category banner rail ("قسم الذبائح") ══════════════════════════════
   A green banner with the category title in gold; the product cards sit on
   its lower half. Optional background photo, washed in the brand green. */
.rail-banner {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  height: 11rem;
  margin-block-end: -5.5rem;
  padding: 1.25rem 1rem 0;
  border-radius: 1.5rem;
  background:
    radial-gradient(90% 120% at 50% 0%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 60%),
    linear-gradient(120deg, var(--primary-deep) 0%, var(--primary) 55%, var(--primary-deep) 100%);
  text-align: center;
}
@media (min-width: 768px)  { .rail-banner { height: 14rem; margin-block-end: -7.5rem; padding-block-start: 1.75rem; border-radius: 1.75rem; } }
@media (min-width: 1024px) { .rail-banner { height: 17rem; margin-block-end: -9.5rem; padding-block-start: 2.25rem; border-radius: 2rem; } }
.rail-banner__img {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.38;
  mix-blend-mode: luminosity;
}
.rail-banner--photo::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to bottom, transparent 40%, color-mix(in srgb, var(--primary-deep) 70%, transparent));
}
.rail-banner__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 1.2rem + 2.6vw, 3.25rem);
  font-weight: 900;
  line-height: 1.1;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 6px rgb(0 0 0 / 0.35));
}
.rail-banner__all {
  position: absolute;
  inset-block-start: 1rem;
  inset-inline-end: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.375rem 0.75rem;
  border-radius: 9999px;
  background: rgb(255 255 255 / 0.14);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 600;
  backdrop-filter: blur(6px);
  transition: background-color var(--t-fast) var(--ease);
}
.rail-banner__all:hover { background: rgb(255 255 255 / 0.26); }
@media (min-width: 1024px) { .rail-banner__all { inset-block-start: 1.5rem; inset-inline-end: 1.75rem; font-size: 0.875rem; } }

.rail-wrap--banner { position: relative; z-index: 1; padding: 0 0.75rem; }
@media (min-width: 768px)  { .rail-wrap--banner { padding-inline: 1.25rem; } }
@media (min-width: 1024px) { .rail-wrap--banner { padding-inline: 1.75rem; } }
.rail-wrap--banner .product-card--overlay-tall .product-card__media { aspect-ratio: 3 / 4; }
.rail-wrap--banner .product-card--overlay-tall { box-shadow: 0 14px 28px -14px rgb(0 0 0 / 0.55); }
/* phones: the banner cards scroll sideways, three-ish in view */
@media (max-width: 767px) {
  .rail-wrap--banner .product-rail--grid {
    display: grid;
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: 42%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    margin-inline: -0.75rem;
    padding-inline: 0.75rem;
  }
  .rail-wrap--banner .product-rail--grid > * { scroll-snap-align: start; }
}

/* ── Banners: rounded 32px on desktop ──────────────────────────────────── */
.s-banner { border-radius: 1rem; }
@media (min-width: 1280px) { .s-banner { border-radius: 2rem; } }


/* ── Rails sit inside the container from tablet up (they bleed only on phones) ── */
@media (min-width: 768px) {
  .product-rail { margin-inline: 0; padding-inline: 0; }
}

/* ── Flash timer shows hours / minutes / seconds only ──────────────────── */
.section--flash [data-cd-days] { display: none !important; }

/* ── Footer: white sheet, 48px top radius, three columns ───────────────── */
.footer--cols {
  background: #fff;
  color: var(--ink);
  padding-block: 2rem;
  border-start-start-radius: 3rem;
  border-start-end-radius: 3rem;
}
.footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
}
@media (min-width: 768px)  { .footer__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); padding-block: 3rem; } }
@media (min-width: 1024px) { .footer__grid { padding-block: 6rem; } }

.footer__lists { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem; align-content: start; }
.footer--cols .footer__col { display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; }
.footer--cols .footer__col-title { margin: 0; font-size: 1.25rem; font-weight: 700; color: var(--primary); }
.footer--cols .footer__links { gap: 0.5rem; }
.footer--cols .footer__link { font-size: 0.875rem; color: var(--muted); }
.footer--cols .footer__link:hover { color: #111827; }

.footer__mid { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 1.5rem; }
.footer__block { width: 100%; }
.footer__block-title { margin: 0 0 1rem; font-size: 1.125rem; font-weight: 700; }
.footer__block-title--lg { font-size: 1.5rem; }
.footer--cols .footer__socials { justify-content: center; gap: 0.75rem; }
.footer--cols .footer__social {
  width: 2.5rem; height: 2.5rem;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
}
.footer--cols .footer__social:hover { background: var(--primary-deep); color: #fff; }
.footer--cols .pay-methods { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; justify-items: center; }
.footer--cols .pay-methods__item--logo img { height: 1.75rem; max-width: 100%; }

.footer__info { display: flex; flex-direction: column; gap: 1rem; }
.footer__contact { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; }
@media (min-width: 1024px) { .footer__contact { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.footer__contact-item { display: flex; align-items: flex-start; gap: 0.75rem; margin-bottom: 0.75rem; }
.footer__contact-icon {
  display: grid; place-items: center; flex: none;
  width: 2.5rem; height: 2.5rem; border-radius: 50%;
  background: var(--primary); color: #fff;
}
.footer__contact-label { margin: 0 0 0.25rem; font-size: 0.875rem; font-weight: 600; }
.footer__contact-value { margin: 0; font-size: 0.875rem; color: var(--ink); overflow-wrap: anywhere; }
.footer__rule { width: 100%; height: 1px; margin: 0; border: 0; background: var(--line); }
.footer__biz { display: flex; flex-direction: column; gap: 0; font-size: 0.875rem; }
.footer__biz p { margin: 0; }
.footer__biz-name { font-weight: 600; }
.footer__biz-line { color: var(--muted); }
.footer__biz-line--strong { color: var(--ink); font-weight: 700; }

.footer__copy {
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 0.875rem;
}
.footer__copy p { margin: 0; }

/* ══ Hero stage carousel ═══════════════════════════════════════════════
   The active banner in the centre, the previous / next ones peeking on both
   sides (slightly smaller and dimmed), clipped by the container edges.
   Geometry per breakpoint: --hs-w centre width, --hs-gap space between,
   --hs-scale side size; the track's aspect-ratio = 1 / (w / banner ratio). */
.hero--stage {
  --dir: 1;
  --hs-w: 84%;
  --hs-gap: 0.625rem;
  --hs-scale: 0.92;
  --hs-radius: 1.125rem;
  padding-block: 0.75rem 1.25rem;
}
[dir="rtl"] .hero--stage { --dir: -1; }
@media (min-width: 768px)  { .hero--stage { --hs-w: 80%; --hs-gap: 1rem; --hs-scale: 0.94; --hs-radius: 1.5rem; } }
@media (min-width: 1024px) { .hero--stage { --hs-w: 76%; --hs-gap: 1.25rem; --hs-scale: 0.96; --hs-radius: 1.75rem; padding-block: 1.5rem 2rem; } }

.hero--stage .hero__wrap { position: relative; }
.hero--stage .hero__viewport {
  position: relative;
  overflow: hidden;
  border-radius: var(--hs-radius);
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.hero--stage .hero__viewport:focus-visible { outline: 2px solid var(--primary); outline-offset: 4px; }
.hero--stage .hero__track {
  position: relative;
  display: block;
  margin: 0;
  padding: 0;
  aspect-ratio: 100 / 47.25;   /* 16:9 banners at 84% */
  transform: none !important;
  transition: none;
  overflow: visible;
}
@media (min-width: 768px)  { .hero--stage .hero__track { aspect-ratio: 100 / 40; } }   /* 2:1 at 80% */
@media (min-width: 1024px) { .hero--stage .hero__track { aspect-ratio: 100 / 38; } }   /* 2:1 at 76% */
.hero--stage .hero__viewport[data-count="1"] .hero__track { aspect-ratio: 100 / 47.25; }
@media (min-width: 768px) { .hero--stage .hero__viewport[data-count="1"] .hero__track { aspect-ratio: 100 / 40; } }

.hero--stage .hero__slide {
  position: absolute;
  inset-block: 0;
  left: 50%;
  width: var(--hs-w);
  padding: 0;
  opacity: 0;
  transform: translateX(-50%);
  transition:
    transform 700ms cubic-bezier(0.22, 0.8, 0.25, 1),
    opacity 450ms var(--ease),
    filter 450ms var(--ease);
  will-change: transform;
}
.hero--stage .hero__viewport[data-count="1"] .hero__slide { width: 100%; }
.hero--stage .hero__slide.is-active { opacity: 1; z-index: 2; }
.hero--stage .hero__slide.pos-0 {
  transform: translateX(calc(-50% + var(--drag, 0px))) scale(1);
}
.hero--stage .hero__slide.pos-next,
.hero--stage .hero__slide.pos-prev {
  z-index: 1;
  opacity: 1;
  cursor: pointer;
  filter: brightness(0.78) saturate(0.9);
}
.hero--stage .hero__slide.pos-next {
  transform: translateX(calc(-50% + var(--dir) * (100% + var(--hs-gap)) + var(--drag, 0px))) scale(var(--hs-scale));
}
.hero--stage .hero__slide.pos-prev {
  transform: translateX(calc(-50% - var(--dir) * (100% + var(--hs-gap)) + var(--drag, 0px))) scale(var(--hs-scale));
}
.hero--stage .hero__slide.pos-far-next,
.hero--stage .hero__slide.pos-far-prev { z-index: 0; opacity: 0; pointer-events: none; }
.hero--stage .hero__slide.pos-far-next { transform: translateX(calc(-50% + var(--dir) * 2 * (100% + var(--hs-gap)))) scale(var(--hs-scale)); }
.hero--stage .hero__slide.pos-far-prev { transform: translateX(calc(-50% - var(--dir) * 2 * (100% + var(--hs-gap)))) scale(var(--hs-scale)); }
.hero--stage .hero__slide.pos-next:hover,
.hero--stage .hero__slide.pos-prev:hover { filter: brightness(0.9) saturate(1); }
.hero--stage .hero__slide.is-jump { transition: none !important; opacity: 0 !important; }
.hero--stage .hero__viewport[style*="--drag"] .hero__slide { transition-duration: 120ms, 450ms, 450ms; }
/* the viewport clip stays square so the side banners keep their own rounded corners */
.hero--stage .hero__viewport { border-radius: 0; }

.hero--stage .hero__frame {
  height: 100%;
  aspect-ratio: auto;
  max-height: none;
  border-radius: var(--hs-radius);
  background: var(--primary-deep);
  isolation: isolate;
}
.hero--stage .hero__slide:not(.is-active) .hero__copy,
.hero--stage .hero__slide:not(.is-active) .hero__badge { opacity: 0; }
.hero--stage .hero__copy { transition: opacity 400ms var(--ease) 150ms; }

/* slow settle-in zoom on the centre picture */
.hero--stage .hero__slide.is-active .hero__img { animation: hero-settle 9s var(--ease-out) both; }
@keyframes hero-settle { from { transform: scale(1.06); } to { transform: scale(1); } }

/* legible text on any photo: a soft dark wash from the text side (the old rule used invalid CSS) */
.hero--stage .hero__slide:not(.hero__slide--image-only):not(.hero__slide--no-image) .hero__media::after {
  background: linear-gradient(to right,
    color-mix(in srgb, var(--shadow-color) 78%, transparent) 0%,
    color-mix(in srgb, var(--shadow-color) 42%, transparent) 40%,
    transparent 75%);
}
[dir="rtl"] .hero--stage .hero__slide:not(.hero__slide--image-only):not(.hero__slide--no-image) .hero__media::after {
  background: linear-gradient(to left,
    color-mix(in srgb, var(--shadow-color) 78%, transparent) 0%,
    color-mix(in srgb, var(--shadow-color) 42%, transparent) 40%,
    transparent 75%);
}

.hero--stage .hero__copy {
  max-width: min(34rem, 80%);
  gap: 0.375rem;
  padding: 1rem 1.25rem;
  justify-content: center;
}
@media (min-width: 768px)  { .hero--stage .hero__copy { gap: 0.625rem; padding: 2rem 2.5rem; } }
@media (min-width: 1024px) { .hero--stage .hero__copy { gap: 0.875rem; padding: 2.5rem 3.5rem; max-width: 36rem; } }
.hero--stage .hero__eyebrow {
  padding: 0.25rem 0.75rem;
  border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent);
  background: color-mix(in srgb, var(--accent) 20%, transparent);
  color: var(--gold-light);
  font-size: 0.75rem;
  font-weight: 700;
}
.hero--stage .hero__title {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 0.8rem + 2.4vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  text-shadow: 0 2px 16px rgb(0 0 0 / 0.25);
}
.hero--stage .hero__body {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 28rem;
  font-size: clamp(0.75rem, 0.68rem + 0.45vw, 1.0625rem);
  line-height: 1.6;
  opacity: 0.9;
}
.hero--stage .hero__actions { margin-block-start: 0.25rem; }
.hero--stage .hero__cta {
  height: 2.25rem;
  padding-inline: 1rem 0.875rem;
  gap: 0.375rem;
  border: 0;
  border-radius: 0.75rem;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.8125rem;
  font-weight: 700;
  box-shadow: 0 10px 24px -10px rgb(0 0 0 / 0.5);
  transition: background-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.hero--stage .hero__cta:hover { background: var(--gold-light); color: var(--on-accent); transform: translateY(-1px); }
@media (min-width: 768px) { .hero--stage .hero__cta { height: 3rem; padding-inline: 1.5rem 1.25rem; border-radius: 0.875rem; font-size: 1rem; } }

/* arrows: frosted circles centred over the side banners (desktop) */
.hero--stage .hero__nav {
  display: none;
  top: 50%;
  z-index: 3;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid rgb(255 255 255 / 0.4);
  background: rgb(255 255 255 / 0.2);
  color: #fff;
  box-shadow: 0 8px 20px -10px rgb(0 0 0 / 0.5);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transform: translateY(-50%);
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.hero--stage .hero__nav--prev { inset-inline-start: calc((100% - var(--hs-w)) / 4 - 1.375rem); }
.hero--stage .hero__nav--next { inset-inline-end: calc((100% - var(--hs-w)) / 4 - 1.375rem); }
.hero--stage .hero__nav:hover { background: #fff; color: var(--primary); transform: translateY(-50%) scale(1.06); }
@media (min-width: 1024px) { .hero--stage .hero__nav { display: flex; } }

/* dots under the stage, the active one fills while autoplay runs */
.hero--stage .hero__dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.375rem;
  margin-block-start: 0.875rem;
}
@media (min-width: 1024px) { .hero--stage .hero__dots { margin-block-start: 1.125rem; } }
.hero--stage .hero__dot {
  position: relative;
  overflow: hidden;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 9999px;
  background: color-mix(in srgb, var(--primary) 20%, transparent);
  transition: width var(--t-base) var(--ease-out), background-color var(--t-base) var(--ease);
}
.hero--stage .hero__dot:hover { background: color-mix(in srgb, var(--primary) 40%, transparent); }
.hero--stage .hero__dot.is-active { width: 2rem; background: color-mix(in srgb, var(--primary) 20%, transparent); }
.hero--stage .hero__dot-fill {
  position: absolute;
  inset-block: 0;
  inset-inline-start: 0;
  width: 0;
  border-radius: inherit;
  background: var(--primary);
}
.hero--stage .hero__dot.is-active .hero__dot-fill { animation: hero-progress var(--hero-ms, 6s) linear forwards; }
.hero--stage.is-paused .hero__dot.is-active .hero__dot-fill { animation-play-state: paused; }
.hero--stage[style*="--hero-ms: 0s"] .hero__dot.is-active .hero__dot-fill { animation: none; width: 100%; }
@keyframes hero-progress { from { width: 0; } to { width: 100%; } }

@media (prefers-reduced-motion: reduce) {
  .hero--stage .hero__slide { transition: opacity 200ms linear; }
  .hero--stage .hero__slide.is-active .hero__img { animation: none; }
  .hero--stage .hero__dot.is-active .hero__dot-fill { animation: none; width: 100%; }
}

/* ══ Home page rhythm ══════════════════════════════════════════════════
   One spacing scale for the whole home page, instead of each section's own
   padding (which added up to ~128px between some sections on desktop):
   a smaller gap under the header, then the same gap between every section.
   Sections with their own background band keep an inner padding. */
.page--tpl-index { --home-gap: 2rem; --home-first: 1.25rem; }
@media (min-width: 768px)  { .page--tpl-index { --home-gap: 2.5rem; --home-first: 1.5rem; } }
@media (min-width: 1024px) { .page--tpl-index { --home-gap: 3rem; --home-first: 2rem; } }
.page--tpl-index .page__main > * { padding-block: 0; margin-block: var(--home-gap) 0; }
.page--tpl-index .page__main > :first-child { margin-block-start: var(--home-first); }
.page--tpl-index .page__main > :last-child { margin-block-end: var(--home-gap); }
.page--tpl-index .page__main > .color-scheme--soft,
.page--tpl-index .page__main > .color-scheme--brand,
.page--tpl-index .page__main > .color-scheme--dark { padding-block: var(--home-gap); }
.page--tpl-index .page__main > .section--flash { padding-block: 0; }

/* ══ Stories: tappable circles + story viewer ═══════════════════════════ */
button.story { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
button.story:focus-visible { outline: none; }
button.story:focus-visible .story__ring { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--primary); }
button.story:hover .story__ring { transform: translateY(-3px); box-shadow: 0 10px 20px -12px color-mix(in srgb, var(--primary) 70%, transparent); }
button.story:hover .story__name { color: var(--primary); }
.story .story__ring { position: relative; }
.story.is-seen .story__ring { background: var(--line); }
.story__play {
  position: absolute;
  inset-block-end: 2px;
  inset-inline-end: 2px;
  display: grid;
  place-items: center;
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid var(--bg);
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
}
.story__play .icon { width: 0.625rem; height: 0.625rem; fill: currentColor; margin-inline-start: 1px; }
@media (min-width: 1024px) { .story__play { width: 1.5rem; height: 1.5rem; } }

html.story-open { overflow: hidden; }
.story-viewer {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
}
.story-viewer[hidden] { display: none; }
.story-viewer__backdrop {
  position: absolute;
  inset: 0;
  background: rgb(8 14 11 / 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.story-viewer__frame {
  position: relative;
  width: 100vw;
  height: 100dvh;
  overflow: hidden;
  background: #0b0f0d;
  color: #fff;
  animation: story-in 260ms var(--ease-out);
}
@media (min-width: 640px) {
  .story-viewer__frame {
    width: min(26.5rem, calc((100dvh - 3rem) * 9 / 16));
    height: auto;
    aspect-ratio: 9 / 16;
    border-radius: 1.25rem;
    box-shadow: 0 30px 80px -20px rgb(0 0 0 / 0.6);
  }
}
@keyframes story-in { from { opacity: 0; transform: scale(0.96); } to { opacity: 1; transform: none; } }

.story-viewer__media { position: absolute; inset: 0; }
.story-viewer__video,
.story-viewer__img { width: 100%; height: 100%; object-fit: cover; display: block; }
.story-viewer__media { overflow: hidden; }
/* the player is taller than the frame so YouTube's own title / control bars sit outside the visible area */
.story-viewer__embed { position: absolute; inset-inline: 0; inset-block-start: -4.5rem; width: 100%; height: calc(100% + 9rem); border: 0; pointer-events: none; }
.story-viewer__media::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 8rem;
  z-index: 1;
  background: linear-gradient(to bottom, rgb(0 0 0 / 0.55), transparent);
  pointer-events: none;
}

.story-viewer__top { position: absolute; inset: 0 0 auto; z-index: 3; padding: 0.75rem 0.875rem 0; }
.story-viewer__bars { display: flex; gap: 4px; }
.story-viewer__bar { position: relative; flex: 1; height: 3px; overflow: hidden; border-radius: 3px; background: rgb(255 255 255 / 0.35); }
.story-viewer__bar i { position: absolute; inset-block: 0; inset-inline-start: 0; width: 0; border-radius: inherit; background: #fff; }
.story-viewer__head { display: flex; align-items: center; gap: 0.625rem; margin-block-start: 0.75rem; }
.story-viewer__avatar { width: 2.5rem; height: 2.5rem; flex: none; border: 2px solid #fff; border-radius: 50%; object-fit: cover; }
.story-viewer__who { flex: 1; min-width: 0; line-height: 1.25; text-shadow: 0 1px 4px rgb(0 0 0 / 0.4); }
.story-viewer__name { margin: 0; font-size: 0.9375rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-viewer__time { margin: 0; font-size: 0.75rem; opacity: 0.8; }
.story-viewer__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: rgb(0 0 0 / 0.28);
  color: #fff;
  transition: background-color var(--t-fast) var(--ease);
}
.story-viewer__icon:hover { background: rgb(0 0 0 / 0.5); }
.story-viewer__vol-off { display: none; }
.story-viewer.is-muted .story-viewer__vol-on { display: none; }
.story-viewer.is-muted .story-viewer__vol-off { display: inline-flex; }

/* tap zones: next on the reading side's end (left in Arabic) */
.story-viewer__tap {
  position: absolute;
  z-index: 2;
  inset-block: 5rem 10.5rem;
  width: 45%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.story-viewer__tap--prev { inset-inline-start: 0; }
.story-viewer__tap--next { inset-inline-end: 0; width: 55%; }

/* bottom card */
.story-viewer__card {
  position: absolute;
  z-index: 3;
  inset-inline: 0.75rem;
  inset-block-end: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0.875rem;
  border-radius: 1.125rem;
  background: var(--card-bg);
  color: var(--ink);
  box-shadow: 0 12px 30px -12px rgb(0 0 0 / 0.5);
}
.story-viewer__card::before {
  content: "";
  position: absolute;
  inset-block-start: -0.875rem;
  inset-inline: 0;
  margin-inline: auto;
  width: 2.5rem;
  height: 4px;
  border-radius: 4px;
  background: rgb(255 255 255 / 0.5);
}
.story-viewer__card-head { display: flex; align-items: center; gap: 0.75rem; }
.story-viewer__card-img { width: 2.75rem; height: 2.75rem; flex: none; border-radius: 50%; object-fit: cover; background: var(--bg); }
.story-viewer__card-text { flex: 1; min-width: 0; }
.story-viewer__card-title { margin: 0; font-family: var(--font-display); font-size: 1rem; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-viewer__card-price { margin: 0.125rem 0 0; font-size: 0.875rem; font-weight: 700; color: var(--primary); }
.story-viewer__cart {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--primary) 9%, var(--card-bg));
  color: var(--primary);
}
.story-viewer__actions { display: grid; grid-template-columns: 1fr 1fr; gap: 0.625rem; }
.story-viewer__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 2.75rem;
  padding-inline: 0.75rem;
  border-radius: 0.875rem;
  font-size: 0.875rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.story-viewer__btn--primary { background: var(--primary); color: var(--on-primary); }
.story-viewer__btn--primary:hover { background: var(--primary-deep); color: var(--on-primary); }
.story-viewer__btn--ghost { border: 1.5px solid var(--primary); color: var(--primary); }
.story-viewer__btn--ghost:hover { background: color-mix(in srgb, var(--primary) 8%, var(--card-bg)); }

/* desktop arrows beside the frame */
.story-viewer__nav {
  position: relative;
  z-index: 2;
  display: none;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border: 1px solid rgb(255 255 255 / 0.3);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.12);
  color: #fff;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.story-viewer__nav:hover { background: #fff; color: var(--primary); }
@media (min-width: 768px) { .story-viewer__nav { display: grid; } }
.story-viewer.is-paused .story-viewer__bars { opacity: 0.6; }
@media (prefers-reduced-motion: reduce) { .story-viewer__frame { animation: none; } }
.story-viewer__empty {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding-block-end: 8rem;
  background:
    radial-gradient(120% 80% at 50% 0%, color-mix(in srgb, var(--accent) 35%, transparent), transparent 60%),
    linear-gradient(160deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #fff;
  text-align: center;
}
.story-viewer__empty-mark {
  display: grid;
  place-items: center;
  width: 6rem;
  height: 6rem;
  border: 3px solid var(--accent);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.1);
  font-family: var(--font-display);
  font-size: 2.75rem;
  font-weight: 800;
}
.story-viewer__empty-name { font-family: var(--font-display); font-size: 1.375rem; font-weight: 800; }

/* stories: pictures only under the ring — the name stays in the viewer header and as the button's label */
.story--viewer .story__name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ══ "Most requested" cards (overlay-tall) ═════════════════════════════
   Tall photo card: 194:266, rounded, soft shadow, dark fade at the bottom
   with the name centred in bold white, gold "+" circle in the top corner. */
.product-card--overlay-tall {
  position: relative;
  overflow: hidden;
  border-radius: 1.125rem;
  background: var(--primary-deep);
  box-shadow: 0 8px 20px -10px rgb(15 31 23 / 0.45);
  transition: transform 300ms var(--ease-out), box-shadow 300ms var(--ease-out);
}
.product-card--overlay-tall:hover { transform: translateY(-4px); box-shadow: 0 16px 30px -14px rgb(15 31 23 / 0.55); }
.product-card--overlay-tall .product-card__media { aspect-ratio: 194 / 266; border-radius: inherit; }
.product-card--overlay-tall .product-card__img { transition: transform 600ms var(--ease-out); }
.product-card--overlay-tall:hover .product-card__img { transform: scale(1.05); }
.product-card--overlay-tall .product-card__media::after {
  background: linear-gradient(to top, rgb(0 0 0 / 0.82) 0%, rgb(0 0 0 / 0.35) 22%, transparent 42%);
}
.product-card--overlay-tall .product-card__title {
  inset-inline: 0.75rem;
  inset-block-end: 0.875rem;
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 800;
  line-height: 1.3;
  text-shadow: 0 2px 6px rgb(0 0 0 / 0.6);
}
@media (min-width: 1024px) { .product-card--overlay-tall .product-card__title { font-size: 1.125rem; inset-block-end: 1rem; } }
.product-card--overlay-tall .product-card__add {
  inset-block: 0.625rem auto;
  inset-inline: auto 0.625rem;   /* top corner on the end side (left in Arabic) */
  width: 2.375rem;
  height: 2.375rem;
  background: var(--accent);
  color: var(--primary-deep);
  font-size: 1.375rem;
  font-weight: 600;
  box-shadow: 0 4px 10px -4px rgb(0 0 0 / 0.4);
  transition: transform var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.product-card--overlay-tall .product-card__add:hover { background: var(--gold-light); transform: scale(1.08); }
@media (min-width: 1024px) { .product-card--overlay-tall .product-card__add { width: 2.75rem; height: 2.75rem; inset-block-start: 0.75rem; inset-inline-end: 0.75rem; } }
.product-card--overlay-tall .product-card__flags { inset-block-start: 0.625rem; inset-inline-start: 0.625rem; }
.product-rail--grid { gap: 0.75rem; }
@media (min-width: 1024px) { .product-rail--grid { gap: 1.25rem; } }

/* ══ Compact product cards (الحاشي · العجل · سوبر ماركت · الخضار والفواكه) ═
   White card: photo on top, then the name (2 lines) and price on one side and
   the round add button on the other — in a grid, so the button can never sit
   on top of the text (the old version floated it over the title). */
.product-card--compact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "media media" "body foot";
  align-items: end;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1.125rem;
  background: var(--card-bg);
  box-shadow: 0 2px 10px -6px rgb(15 31 23 / 0.2);
  transition: transform 300ms var(--ease-out), box-shadow 300ms var(--ease-out), border-color 300ms var(--ease-out);
}
.product-card--compact:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--primary) 30%, var(--line)); box-shadow: 0 14px 26px -14px rgb(15 31 23 / 0.35); }
.product-card--compact .product-card__media { grid-area: media; aspect-ratio: 4 / 3; border-radius: 0; }
.product-card--compact .product-card__body {
  grid-area: body;
  align-self: stretch;
  min-width: 0;
  padding: 0.75rem 0.25rem 0.75rem 0.75rem;
  padding-inline: 0.875rem 0.25rem;
  gap: 0.25rem;
}
.product-card--compact .product-card__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.6em;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.3;
  white-space: normal;
  text-overflow: clip;
}
.product-card--compact .product-card__prices { margin-block-start: auto; }
.product-card--compact .product-card__prices .price { font-size: 1rem; font-weight: 800; color: var(--primary); }
.product-card--compact .price-was { font-size: 0.75rem; }
.product-card--compact .product-card__foot {
  grid-area: foot;
  position: static;
  align-self: end;
  padding: 0 0.75rem 0.75rem 0.25rem;
  padding-inline: 0.25rem 0.75rem;
}
.product-card--compact .product-card__foot .btn,
.product-card--compact .product-card__add {
  flex: none;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border-radius: 50%;
  background: var(--primary);
  color: var(--on-primary);
  font-size: 0;
  box-shadow: 0 6px 12px -6px color-mix(in srgb, var(--primary) 70%, transparent);
  transition: background-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.product-card--compact .product-card__foot .btn:hover,
.product-card--compact .product-card__add:hover { background: var(--primary-deep); transform: scale(1.08); }
.product-card--compact .product-card__foot .btn .icon { margin: 0; width: 1.125rem; height: 1.125rem; }
.product-card--compact .product-card__fav { inset-block-start: 0.5rem; inset-inline-start: 0.5rem; }
.product-card--compact .product-card__flags { inset-block-start: 0.5rem; inset-inline-end: 0.5rem; }
@media (max-width: 639px) {
  .product-card--compact .product-card__title { font-size: 0.8125rem; }
  .product-card--compact .product-card__foot .btn,
  .product-card--compact .product-card__add { width: 2.25rem; height: 2.25rem; }
}

/* ══ "Market" product card — simple version ═════════════════════════════
   Photo on top, name, then one row: price on one side, a small "+" add
   button on the other (grid areas, so the button never covers the text).
   Calm at rest; the card lifts and the button turns solid on hover. */
.product-card--market {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "media media" "body foot";
  align-items: end;
  overflow: hidden;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--card-bg);
  box-shadow: none;
  transition: transform 250ms var(--ease-out), box-shadow 250ms var(--ease-out);
}
.product-card--market:hover { transform: translateY(-3px); box-shadow: 0 14px 28px -18px rgb(15 31 23 / 0.4); }
.product-card--market .product-card__media {
  grid-area: media;
  aspect-ratio: 1;
  border-radius: 0;
  background: color-mix(in srgb, var(--primary) 5%, var(--bg));
}
.product-card--market .product-card__img { transition: transform 450ms var(--ease-out); }
.product-card--market:hover .product-card__img { transform: scale(1.04); }
.product-card--market .product-card__quick { display: none; }
.product-card--market .product-card__fav {
  inset-block-start: 0.5rem;
  inset-inline-start: 0.5rem;
  width: 2rem;
  height: 2rem;
  background: rgb(255 255 255 / 0.95);
  box-shadow: 0 1px 4px rgb(0 0 0 / 0.1);
}
.product-card--market .product-card__flags { inset-block-start: 0.5rem; inset-inline-end: 0.5rem; }

.product-card--market .product-card__body {
  grid-area: body;
  align-self: stretch;
  min-width: 0;
  gap: 0.375rem;
  padding: 0.75rem 0.875rem 0.875rem;
  padding-inline-end: 0.25rem;
}
.product-card--market .product-card__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.7em;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--ink);
}
.product-card--market .product-card__title a { color: inherit; }
.product-card--market .product-card__prices { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.125rem 0.5rem; margin: 0; }
.product-card--market .product-card__prices .price { font-size: 1.0625rem; font-weight: 800; color: var(--ink); }
.product-card--market .price-was { font-size: 0.75rem; color: var(--muted); }

.product-card--market .product-card__foot {
  grid-area: foot;
  margin: 0;
  padding: 0 0.875rem 0.875rem 0;
  padding-inline: 0 0.875rem;
}
/* the add button: a 40px rounded square with just the icon (its text stays for screen readers) */
.product-card--market .product-card__foot .btn {
  position: relative;
  width: 2.5rem;
  height: 2.5rem;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0.75rem;
  background: color-mix(in srgb, var(--primary) 10%, var(--card-bg));
  color: var(--primary);
  font-size: 0;
  box-shadow: none;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.product-card--market .product-card__foot .btn .icon { width: 1.25rem; height: 1.25rem; margin: 0; }
.product-card--market .product-card__foot .btn:hover,
.product-card--market:hover .product-card__foot .btn { background: var(--primary); color: var(--on-primary); }
.product-card--market .product-card__foot .btn:active { transform: scale(0.94); }
.product-card--market .product-card__foot .btn:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.product-card--market .product-card__foot .btn[disabled] { background: var(--bg); color: var(--muted); }
.product-card--market.is-out .product-card__media { opacity: 0.6; }
@media (max-width: 639px) {
  .product-card--market .product-card__body { padding: 0.625rem 0.625rem 0.75rem; padding-inline-end: 0.25rem; }
  .product-card--market .product-card__foot { padding-inline-end: 0.625rem; padding-block-end: 0.75rem; }
  .product-card--market .product-card__foot .btn { width: 2.25rem; height: 2.25rem; }
  .product-card--market .product-card__title { font-size: 0.8125rem; }
}
/* buttons without an icon (products with options → "choose", unavailable) show a "+" so the square is never empty */
.product-card--market .product-card__foot .btn:not(:has(svg))::before { content: "+"; font-size: 1.5rem; font-weight: 500; line-height: 1; }
.product-card--market .product-card__foot .btn[disabled]:not(:has(svg))::before { content: "–"; }
/* heart and discount badge on opposite top corners: badge at the start (right in Arabic), heart at the end */
.product-card--market .product-card__flags { inset-inline-start: 0.5rem; inset-inline-end: auto; }
.product-card--market .product-card__fav { inset-inline-start: auto; inset-inline-end: 0.5rem; }

/* market card add button v2: a solid green circle with a crisp drawn "+" (no thin cart outline) */
.product-card--market .product-card__foot .btn {
  width: 2.375rem;
  height: 2.375rem;
  border-radius: 50%;
  background: var(--primary);
  color: var(--on-primary);
  box-shadow: 0 6px 14px -6px color-mix(in srgb, var(--primary) 75%, transparent);
}
.product-card--market .product-card__foot .btn svg { display: none; }
.product-card--market .product-card__foot .btn::before,
.product-card--market .product-card__foot .btn:not(:has(svg))::before {
  content: "";
  width: 1rem;
  height: 1rem;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 2.5px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2.5px 100% no-repeat;
  border-radius: 2px;
}
.product-card--market .product-card__foot .btn:hover,
.product-card--market:hover .product-card__foot .btn { background: var(--primary-deep); color: var(--on-primary); transform: scale(1.06); }
.product-card--market .product-card__foot .btn[disabled] { background: var(--line); color: var(--muted); box-shadow: none; }
.product-card--market .product-card__foot .btn[disabled]::before { background: linear-gradient(currentColor, currentColor) center / 100% 2.5px no-repeat; }
.product-card--market .product-card__form .is-added,
.product-card--market .product-card__foot .btn.is-added { background: var(--success); }
@media (max-width: 639px) { .product-card--market .product-card__foot .btn { width: 2.125rem; height: 2.125rem; } }
/* centre the "+" exactly: pinned in the middle, independent of the hidden button label */
.product-card--market .product-card__foot .btn { position: relative; display: block; line-height: 0; color: var(--on-primary); }
.product-card--market .product-card__foot .btn::before,
.product-card--market .product-card__foot .btn:not(:has(svg))::before {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 0.9375rem;
  height: 0.9375rem;
}

/* ══ Trust badges: four light cards instead of a coloured strip ═════════ */
.page--tpl-index .page__main > .services--section { padding-block: 0; background: none; }
.services--section .services__inner {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}
@media (min-width: 1024px) { .services--section .services__inner { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; } }
.services--section .service {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  min-width: 0;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--card-bg);
  color: var(--ink);
  transition: transform 250ms var(--ease-out), box-shadow 250ms var(--ease-out), border-color 250ms var(--ease-out);
}
.services--section .service:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--primary) 25%, var(--line)); box-shadow: 0 12px 24px -16px rgb(15 31 23 / 0.35); }
@media (min-width: 1024px) { .services--section .service { padding: 1.25rem 1.375rem; gap: 1rem; } }
.services--section .service > .icon {
  flex: none;
  box-sizing: content-box;
  width: 1.375rem;
  height: 1.375rem;
  padding: 0.75rem;
  border-radius: 0.875rem;
  background: color-mix(in srgb, var(--primary) 9%, var(--card-bg));
  color: var(--primary);
}
@media (min-width: 1024px) { .services--section .service > .icon { width: 1.5rem; height: 1.5rem; padding: 0.875rem; } }
.services--section .service > span { display: flex; flex-direction: column; gap: 0.125rem; min-width: 0; }
.services--section .service__title { font-family: var(--font-display); font-size: 0.9375rem; font-weight: 800; color: var(--ink); line-height: 1.3; }
.services--section .service__note { font-size: 0.8125rem; color: var(--muted); line-height: 1.45; }
@media (max-width: 639px) {
  .services--section .service { flex-direction: column; align-items: flex-start; gap: 0.625rem; padding: 0.875rem; }
  .services--section .service__title { font-size: 0.875rem; }
  .services--section .service__note { font-size: 0.75rem; }
}

/* ══ Promo cards (delivery / pickup) ═══════════════════════════════════ */
.promo-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.75rem; }
@media (min-width: 768px) { .promo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; } }
.promo-grid .promo {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  min-height: 11rem;
  overflow: hidden;
  padding: 1.5rem;
  border-radius: 1.5rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #fff;
  box-shadow: none;
  transition: transform 300ms var(--ease-out), box-shadow 300ms var(--ease-out);
}
@media (min-width: 1024px) { .promo-grid .promo { min-height: 13rem; padding: 2rem 2.25rem; } }
.promo-grid .promo:hover { transform: translateY(-3px); box-shadow: 0 20px 36px -22px rgb(15 31 23 / 0.6); }
/* second card: warm sand with green text, so the pair isn't two identical blocks */
.promo-grid .promo:nth-child(2) {
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 30%, var(--card-bg)) 0%, color-mix(in srgb, var(--accent) 52%, var(--card-bg)) 100%);
  color: var(--ink);
}
/* big faint watermark icon (truck / store) on the end side */
.promo-grid .promo::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset-block: 0;
  inset-inline-end: -1.5rem;
  margin-block: auto;
  width: 9rem;
  height: 9rem;
  opacity: 0.14;
  background: currentColor;
  -webkit-mask: var(--promo-icon) center / contain no-repeat;
          mask: var(--promo-icon) center / contain no-repeat;
  --promo-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 18V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v11a1 1 0 0 0 1 1h2'/%3E%3Cpath d='M15 18H9'/%3E%3Cpath d='M19 18h2a1 1 0 0 0 1-1v-3.65a1 1 0 0 0-.22-.624l-3.48-4.35A1 1 0 0 0 17.52 8H14'/%3E%3Ccircle cx='17' cy='18' r='2'/%3E%3Ccircle cx='7' cy='18' r='2'/%3E%3C/svg%3E");
}
.promo-grid .promo:nth-child(2)::after {
  --promo-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m2 7 4.41-4.41A2 2 0 0 1 7.83 2h8.34a2 2 0 0 1 1.42.59L22 7'/%3E%3Cpath d='M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8'/%3E%3Cpath d='M15 22v-4a2 2 0 0 0-2-2h-2a2 2 0 0 0-2 2v4'/%3E%3Cpath d='M2 7h20'/%3E%3Cpath d='M22 7v3a2 2 0 0 1-2 2a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 16 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 12 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 8 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 4 12a2 2 0 0 1-2-2V7'/%3E%3C/svg%3E");
  opacity: 0.12;
}
@media (min-width: 1024px) { .promo-grid .promo::after { width: 12rem; height: 12rem; inset-inline-end: -1rem; } }
.promo-grid .promo__copy { position: static; max-width: 22rem; display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; padding: 0; background: none; }
.promo-grid .promo__title { margin: 0; font-family: var(--font-display); font-size: 1.375rem; font-weight: 900; line-height: 1.2; color: inherit; }
@media (min-width: 1024px) { .promo-grid .promo__title { font-size: 1.75rem; } }
.promo-grid .promo__body { margin: 0; font-size: 0.9375rem; line-height: 1.6; opacity: 0.85; color: inherit; }
.promo-grid .promo .btn {
  margin-block-start: 0.5rem;
  height: 2.75rem;
  padding-inline: 1.25rem;
  border: 0;
  border-radius: 0.875rem;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 0.9375rem;
  font-weight: 700;
  box-shadow: none;
}
.promo-grid .promo .btn:hover { background: var(--gold-light); color: var(--on-accent); }
.promo-grid .promo:nth-child(2) .btn { background: var(--primary); color: var(--on-primary); }
.promo-grid .promo:nth-child(2) .btn:hover { background: var(--primary-deep); }

/* ══ App band (v2): split card — store about | download the app ════════ */
.appx__card {
  position: relative;
  isolation: isolate;
  display: grid;
  gap: 1.25rem;
  overflow: hidden;
  padding: 1.5rem;
  border-radius: 1.75rem;
  background:
    radial-gradient(60% 90% at 0% 0%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 70%),
    linear-gradient(140deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #fff;
}
/* soft geometric texture */
.appx__card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.07;
  background: url("../images/pattern.svg") repeat;
  background-size: 120px;
}
@media (min-width: 900px) {
  .appx__card {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    align-items: stretch;
    gap: 2rem;
    padding: 2.25rem;
    border-radius: 2rem;
  }
  .appx--solo .appx__card { grid-template-columns: minmax(0, 1fr); }
}

.appx__about { display: flex; flex-direction: column; justify-content: center; gap: 1rem; min-width: 0; padding-inline-end: 2.5rem; }
@media (min-width: 900px) { .appx__about { padding-inline-end: 0; padding-block: 0.5rem; } }
.appx__brand { display: flex; align-items: center; gap: 0.875rem; }
.appx__logo { width: 3.5rem; height: 3.5rem; object-fit: contain; }
.appx__mark {
  display: grid;
  place-items: center;
  flex: none;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 1rem;
  background: var(--accent);
  color: var(--primary-deep);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 900;
}
.appx__brand-text { display: flex; flex-direction: column; gap: 0.125rem; line-height: 1.25; }
.appx__name { font-family: var(--font-display); font-size: 1.25rem; font-weight: 800; }
.appx__tagline { font-size: 0.8125rem; color: var(--gold-light); letter-spacing: 0.02em; }
.appx__text { margin: 0; max-width: 38rem; font-size: 0.9375rem; line-height: 1.85; color: rgb(255 255 255 / 0.82); }

/* inner card: download the app */
.appx__apps {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.375rem;
  padding: 1.25rem;
  border: 1px solid rgb(255 255 255 / 0.14);
  border-radius: 1.25rem;
  background: rgb(255 255 255 / 0.08);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
@media (min-width: 900px) { .appx__apps { justify-content: center; padding: 1.5rem 1.75rem; } }
.appx__apps-icon {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  margin-block-end: 0.375rem;
  border-radius: 0.875rem;
  background: rgb(255 255 255 / 0.12);
  color: var(--accent);
}
.appx__title { margin: 0; font-family: var(--font-display); font-size: 1.25rem; font-weight: 800; color: #fff; }
.appx__note { margin: 0 0 0.75rem; font-size: 0.875rem; color: rgb(255 255 255 / 0.75); }
.appx__badges { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.appx__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  height: 2.75rem;
  padding-inline: 0.75rem 1rem;
  border-radius: 0.75rem;
  background: #fff;
  color: #111;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.appx__badge:hover { transform: translateY(-2px); box-shadow: 0 10px 20px -10px rgb(0 0 0 / 0.45); color: #111; }
.appx__badge .icon { flex: none; color: var(--primary); }
.appx__badge span { display: flex; flex-direction: column; line-height: 1.1; font-family: var(--font-body); font-size: 0.9375rem; font-weight: 700; text-align: start; }
.appx__badge small { font-size: 0.5625rem; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; color: #555; }

/* back to top: a small round button in the card's top corner */
.appx__top {
  position: absolute;
  inset-block-start: 1rem;
  inset-inline-end: 1rem;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid rgb(255 255 255 / 0.25);
  border-radius: 50%;
  background: rgb(255 255 255 / 0.1);
  color: #fff;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.appx__top:hover { background: #fff; color: var(--primary); transform: translateY(-2px); }
@media (min-width: 900px) { .appx__top { inset-block-start: 1.25rem; inset-inline-end: 1.25rem; } .appx__apps { margin-inline-end: 3.25rem; } }

/* trust badges: no band lines or fill behind the four cards */
.services.services--section { border: 0; background: none; box-shadow: none; }

/* a right-to-left scroll strip can widen the page in Chrome: clip sideways overflow at the section edge
   (the rail arrows sit inside the section, so they stay visible) */
.section--stories,
.page--tpl-index .page__main > section:has(.product-rail),
.page--tpl-index .page__main > .hero { overflow-x: clip; }

/* ══ Bundle cards (product.bundle_items) ════════════════════════════════
   A frosted "حزمة · N منتجات" tag on the photo, and the contents as one row
   of overlapping round avatars (quantity as a tiny badge) instead of a
   block of square thumbnails. */
.product-card__bundle-tag {
  position: absolute;
  z-index: 3;
  inset-block-end: 0.5rem;
  inset-inline-start: 0.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  height: 1.625rem;
  padding-inline: 0.5rem 0.625rem;
  border-radius: 9999px;
  background: rgb(15 31 23 / 0.62);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  white-space: nowrap;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  pointer-events: none;
}
.product-card__bundle-tag .icon { color: var(--accent); flex: none; }
.product-card--overlay .product-card__bundle-tag { inset-block: 0.625rem auto; }

.product-card .bundle-peek { flex-direction: row; align-items: center; gap: 0.5rem; margin-block: 0.125rem 0.25rem; }
.product-card .bundle-peek__thumbs { flex-wrap: nowrap; gap: 0; padding-inline-start: 0.125rem; }
.product-card .bundle-peek__thumb,
.product-card .bundle-peek__more {
  position: relative;
  display: grid;
  place-items: center;
  flex: none;
  width: 1.875rem;
  height: 1.875rem;
  margin-inline-start: -0.5rem;
  padding: 0;
  overflow: visible;
  border: 2px solid var(--card-bg);
  border-radius: 50%;
  background: color-mix(in srgb, var(--primary) 6%, var(--bg));
  box-shadow: 0 1px 3px rgb(15 31 23 / 0.15);
}
.product-card .bundle-peek__thumb:first-child { margin-inline-start: 0; }
.product-card .bundle-peek__thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.product-card .bundle-peek__initial { font-size: 0.75rem; font-weight: 700; color: var(--primary); }
.product-card .bundle-peek__qty {
  position: absolute;
  inset-block-end: -0.3rem;
  inset-inline-end: -0.3rem;
  min-width: 1rem;
  height: 1rem;
  padding-inline: 0.2rem;
  border: 1.5px solid var(--card-bg);
  border-radius: 9999px;
  background: var(--primary);
  color: #fff;
  font-size: 0.5625rem;
  font-weight: 700;
  line-height: calc(1rem - 3px);
  text-align: center;
}
.product-card .bundle-peek__more { background: color-mix(in srgb, var(--primary) 12%, var(--card-bg)); color: var(--primary); font-size: 0.6875rem; font-weight: 800; }
.product-card .bundle-peek__names { font-size: 0.75rem; color: var(--muted); }
@media (max-width: 639px) {
  .product-card .bundle-peek__thumb, .product-card .bundle-peek__more { width: 1.625rem; height: 1.625rem; }
}
/* bundle avatars: earlier ones sit on top, the quantity badge centred under its own avatar */
.product-card .bundle-peek__thumbs > :nth-child(1) { z-index: 5; }
.product-card .bundle-peek__thumbs > :nth-child(2) { z-index: 4; }
.product-card .bundle-peek__thumbs > :nth-child(3) { z-index: 3; }
.product-card .bundle-peek__thumbs > :nth-child(4) { z-index: 2; }
.product-card .bundle-peek__thumbs > :nth-child(n+5) { z-index: 1; }
.product-card .bundle-peek__qty { inset-inline: 0; inset-block-end: -0.45rem; margin-inline: auto; width: max-content; }
.product-card .bundle-peek { margin-block-end: 0.5rem; }

/* ══ Collection page ═══════════════════════════════════════════════════
   Hero card (category banner under a deep-green wash, breadcrumb, title,
   description) → subcategory chips → filters sidebar + toolbar + grid of
   "market" cards → pagination. */
.col-head { padding-block-start: 1.25rem; }
@media (min-width: 1024px) { .col-head { padding-block-start: 1.75rem; } }

.col-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  align-items: center;
  min-height: 9.5rem;
  padding: 1.5rem 1.25rem;
  border-radius: 1.5rem;
  background:
    radial-gradient(70% 120% at 100% 0%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 60%),
    linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
  color: #fff;
}
@media (min-width: 768px)  { .col-hero { min-height: 12rem; padding: 2rem 2.5rem; border-radius: 1.75rem; } }
@media (min-width: 1024px) { .col-hero { min-height: 14rem; padding: 2.5rem 3rem; border-radius: 2rem; } }
.col-hero__img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.col-hero--photo::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to right,
    color-mix(in srgb, var(--primary-deep) 92%, transparent) 0%,
    color-mix(in srgb, var(--primary-deep) 70%, transparent) 40%,
    color-mix(in srgb, var(--primary-deep) 20%, transparent) 100%);
}
[dir="rtl"] .col-hero--photo::after {
  background: linear-gradient(to left,
    color-mix(in srgb, var(--primary-deep) 92%, transparent) 0%,
    color-mix(in srgb, var(--primary-deep) 70%, transparent) 40%,
    color-mix(in srgb, var(--primary-deep) 20%, transparent) 100%);
}
.col-hero__body { display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; max-width: 40rem; }
.col-hero__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 1.25rem + 2vw, 2.75rem);
  font-weight: 900;
  line-height: 1.15;
  color: #fff;
}
.col-hero__sub { margin: 0; max-width: 36rem; font-size: 0.9375rem; line-height: 1.75; color: rgb(255 255 255 / 0.85); }
@media (min-width: 1024px) { .col-hero__sub { font-size: 1rem; } }
.col-hero .brand-hero { display: flex; align-items: center; gap: 1rem; }
.col-hero .brand-hero__logo { height: 3rem; width: auto; padding: 0.375rem 0.625rem; border-radius: 0.75rem; background: #fff; }

/* breadcrumb on the dark hero */
.col-hero .breadcrumb { font-size: 0.8125rem; color: rgb(255 255 255 / 0.7); }
.col-hero .breadcrumb a { color: rgb(255 255 255 / 0.75); }
.col-hero .breadcrumb a:hover { color: var(--accent); }
.col-hero .breadcrumb__sep { color: rgb(255 255 255 / 0.4); }
.col-hero .breadcrumb [aria-current="page"] { color: #fff; font-weight: 600; }

/* ══ Chips (subcategories, active filters) — shared ══════════════════════ */
.subcats {
  display: flex;
  gap: 0.5rem;
  margin-block-start: 1rem;
  overflow-x: auto;
  scrollbar-width: none;
  padding-block-end: 0.125rem;
}
.subcats::-webkit-scrollbar { display: none; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  flex: none;
  height: 2.5rem;
  padding-inline: 1rem;
  border: 1px solid var(--line);
  border-radius: 9999px;
  background: var(--card-bg);
  box-shadow: none;
  color: var(--ink);
  font-size: 0.875rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.chip:hover { box-shadow: none; border-color: color-mix(in srgb, var(--primary) 40%, var(--line)); color: var(--primary); }
.chip .num {
  display: inline-grid;
  place-items: center;
  min-width: 1.375rem;
  height: 1.375rem;
  padding-inline: 0.375rem;
  border-radius: 9999px;
  background: color-mix(in srgb, var(--primary) 9%, var(--card-bg));
  color: var(--primary);
  font-size: 0.6875rem;
  font-weight: 700;
}
.chip.is-active, .chip[aria-pressed="true"], .chip[aria-current="page"] { border-color: var(--primary); background: var(--primary); color: var(--on-primary); }
.chip.is-active .num, .chip[aria-current="page"] .num { background: rgb(255 255 255 / 0.2); color: #fff; }
.chip--clear { height: 2.5rem; border-color: transparent; background: none; color: var(--sale); text-decoration: none; }
.chip--removable { background: color-mix(in srgb, var(--primary) 7%, var(--card-bg)); border-color: color-mix(in srgb, var(--primary) 25%, var(--line)); color: var(--primary); }

/* ══ Listing: layout, filters sidebar, toolbar ══════════════════════════ */
.col-main { padding-block: 1.5rem 3rem; }
@media (min-width: 1024px) { .col-main { padding-block: 2rem 4rem; } }
@media (min-width: 1024px) {
  .shop-layout:not(.shop-layout--full) { grid-template-columns: 16.5rem minmax(0, 1fr); gap: 1.75rem; }
  .shop-layout > aside, .shop-layout > .filters { position: sticky; inset-block-start: 11.5rem; }
}
.filters.card {
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  background: var(--card-bg);
  box-shadow: none;
}
.filters__title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.25rem;
  font-family: var(--font-display);
  font-size: 1.0625rem;
  font-weight: 800;
  color: var(--ink);
}
.filters__title::before {
  content: "";
  width: 1.125rem;
  height: 1.125rem;
  background: var(--primary);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 3H2l8 9.46V19l4 2v-8.54L22 3z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 3H2l8 9.46V19l4 2v-8.54L22 3z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.facets .filter-block { padding-block: 1rem; border-block-end: 1px solid var(--line); }
.facets .filter-block:last-of-type { border-block-end: 0; }
.filter-block__title { margin-block-end: 0.625rem; font-size: 0.875rem; font-weight: 700; color: var(--ink); }
.filter-list { display: flex; flex-direction: column; gap: 0.125rem; }
.filter-opt {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.375rem 0.5rem;
  margin-inline: -0.5rem;
  border-radius: 0.625rem;
  font-size: 0.875rem;
  color: var(--ink);
  cursor: pointer;
  transition: background-color var(--t-fast) var(--ease);
}
.filter-opt:hover { background: color-mix(in srgb, var(--primary) 6%, var(--card-bg)); }
.filter-opt input[type="checkbox"], .filter-opt input[type="radio"] { width: 1.125rem; height: 1.125rem; margin: 0; flex: none; accent-color: var(--primary); }
.filter-opt__count {
  margin-inline-start: auto;
  min-width: 1.5rem;
  padding: 0.0625rem 0.4rem;
  border-radius: 9999px;
  background: var(--bg);
  color: var(--muted);
  font-size: 0.6875rem;
  font-weight: 600;
  text-align: center;
}
.filter-opt:has(input:disabled) { opacity: 0.45; cursor: default; }
.price-range { gap: 0.5rem; }
.price-range .input, .facets .input {
  height: 2.75rem;
  padding-inline: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: color-mix(in srgb, var(--bg) 70%, var(--card-bg));
  font-size: 0.875rem;
  box-shadow: none;
}
.facets .input:focus { border-color: var(--primary); background: var(--card-bg); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 14%, transparent); outline: none; }
.filter-block__hint { font-size: 0.75rem; color: var(--muted); }
.facets [data-facets-apply], .facets .btn--primary {
  height: 2.875rem;
  border-radius: 0.875rem;
  background: var(--primary);
  font-size: 0.9375rem;
  font-weight: 700;
}
.facets .btn--primary:hover { background: var(--primary-deep); }

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-block-end: 1rem;
  padding: 0.5rem 0.5rem 0.5rem 1rem;
  padding-inline: 1rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--card-bg);
}
.toolbar__count { font-size: 0.875rem; color: var(--muted); }
.toolbar__count strong { color: var(--ink); font-weight: 800; }
.toolbar .select-native, .toolbar select {
  height: 2.5rem;
  padding-inline: 0.875rem 2.25rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background-color: color-mix(in srgb, var(--bg) 70%, var(--card-bg));
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
}
.toolbar .btn--outline {
  height: 2.5rem;
  border-color: var(--line);
  border-radius: 0.75rem;
  color: var(--ink);
  font-weight: 700;
}
.active-filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-block-end: 1rem; }

/* listing grid */
.col-main .product-grid { gap: 0.75rem; }
@media (min-width: 768px) { .col-main .product-grid { gap: 1rem; } }
@media (min-width: 1280px) { .col-main .product-grid { gap: 1.25rem; } }

/* ══ Pagination — shared ════════════════════════════════════════════════ */
.pagination { gap: 0.375rem; margin-block-start: 2rem; }
.pagination__btn {
  display: inline-grid;
  place-items: center;
  min-width: 2.75rem;
  height: 2.75rem;
  padding-inline: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.875rem;
  background: var(--card-bg);
  color: var(--ink);
  font-weight: 700;
  transition: border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
a.pagination__btn:hover { border-color: var(--primary); color: var(--primary); }
.pagination__btn[aria-current="page"] { border-color: var(--primary); background: var(--primary); color: var(--on-primary); }
.pagination__gap { color: var(--muted); }

/* ══ Generic page header (search, pages, brands, …) — shared ════════════ */
.page-hero { background: none; border-block-end: 0; }
.page-hero__inner { padding-block: 1.75rem 0.5rem; }
.page-hero__title { margin-block-start: 0.5rem; font-family: var(--font-display); font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.25rem); font-weight: 900; color: var(--ink); }
.page-hero__sub { color: var(--muted); }
.breadcrumb { font-size: 0.8125rem; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb [aria-current="page"] { color: var(--ink); }

/* ══ Page headers with a title (cart, search, categories, brands, wishlist, pages) ═
   The same green card as the collection hero, compact: drawn behind the
   container's content (inset by the page gutter), breadcrumb and title in white. */
.page-hero:has(.page-hero__title) .page-hero__inner {
  position: relative;
  isolation: isolate;
  padding-block: 2.75rem 2rem;
  padding-inline: calc(var(--gutter) + 1.25rem);
  color: #fff;
}
@media (min-width: 1024px) {
  .page-hero:has(.page-hero__title) .page-hero__inner { padding-block: 3.25rem 2.5rem; padding-inline: calc(var(--gutter) + 2.75rem); }
}
.page-hero:has(.page-hero__title) .page-hero__inner::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset-block: 1.25rem 0;
  inset-inline: var(--gutter);
  border-radius: 1.5rem;
  background:
    radial-gradient(60% 140% at 100% 0%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 60%),
    linear-gradient(135deg, var(--primary) 0%, var(--primary-deep) 100%);
}
@media (min-width: 1024px) { .page-hero:has(.page-hero__title) .page-hero__inner::before { inset-block-start: 1.75rem; border-radius: 1.75rem; } }
.page-hero:has(.page-hero__title) .page-hero__title { color: #fff; }
.page-hero:has(.page-hero__title) .page-hero__sub { color: rgb(255 255 255 / 0.85); }
.page-hero:has(.page-hero__title) .breadcrumb { color: rgb(255 255 255 / 0.7); }
.page-hero:has(.page-hero__title) .breadcrumb a { color: rgb(255 255 255 / 0.75); }
.page-hero:has(.page-hero__title) .breadcrumb a:hover { color: var(--accent); }
.page-hero:has(.page-hero__title) .breadcrumb__sep { color: rgb(255 255 255 / 0.4); }
.page-hero:has(.page-hero__title) .breadcrumb [aria-current="page"] { color: #fff; }
.page-hero:has(.page-hero__title) .page-hero__title .num,
.page-hero:has(.page-hero__title) .page-hero__title .muted { color: rgb(255 255 255 / 0.7); }
/* the search page's own field sits on the green card */
.page-hero:has(.page-hero__title) .search__form { margin-block-start: 1rem; max-width: 36rem; background: var(--card-bg); border: 0; }
.page-hero:has(.page-hero__title) .search__input { color: var(--ink); }

/* content pages (من نحن, policies …): the text in a readable white card */
.prose:not(:empty) {
  max-width: 52rem;
  margin-inline: auto;
  padding: 1.75rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: 1.5rem;
  background: var(--card-bg);
  font-size: 1rem;
  line-height: 1.95;
  color: var(--ink);
}
@media (min-width: 1024px) { .prose:not(:empty) { padding: 2.5rem 3rem; } }
.prose h2, .prose h3 { font-family: var(--font-display); font-weight: 800; color: var(--ink); }
.prose a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }

/* ══ Product page polish ═══════════════════════════════════════════════ */
.pdp__title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.1rem + 1.5vw, 2.25rem);
  font-weight: 900;
  line-height: 1.25;
  color: var(--ink);
}
.pdp__sku { color: var(--muted); }
.pdp__box {
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 1.5rem;
  background: var(--card-bg);
  box-shadow: 0 18px 40px -32px rgb(15 31 23 / 0.45);
}
@media (min-width: 1024px) { .pdp__box { padding: 1.75rem; } }
.pdp__price-row .price { font-family: var(--font-display); font-size: 2rem; font-weight: 900; color: var(--primary); }
.pdp__price-row .price-was { font-size: 1rem; color: var(--muted); }
.pdp__stock {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  background: color-mix(in srgb, var(--success) 10%, var(--card-bg));
  color: var(--success);
  font-size: 0.8125rem;
  font-weight: 700;
}
.pdp__actions .btn, .pdp__actions-row .btn, .pdp__buy .btn {
  min-height: 3.25rem;
  border-radius: 1rem;
  font-size: 1rem;
  font-weight: 800;
}
.pdp__actions .btn--primary, .pdp__buy .btn--primary { background: var(--primary); border-color: var(--primary); box-shadow: 0 10px 22px -12px color-mix(in srgb, var(--primary) 80%, transparent); }
.pdp__actions .btn--primary:hover, .pdp__buy .btn--primary:hover { background: var(--primary-deep); }
.pdp__actions .btn--outline, .pdp__buy .btn--outline { border: 1.5px solid var(--accent); background: color-mix(in srgb, var(--accent) 12%, var(--card-bg)); color: var(--ink); }
.pdp__actions .btn--outline:hover, .pdp__buy .btn--outline:hover { background: var(--accent); color: var(--on-accent); }
.pdp .qty { height: 3.25rem; border: 1px solid var(--line); border-radius: 1rem; background: color-mix(in srgb, var(--bg) 60%, var(--card-bg)); }
.pdp .qty__btn { width: 3rem; color: var(--primary); }
.pdp .qty__value { font-weight: 800; }
.pdp__perks { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.pdp__perk {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  border-radius: 9999px;
  background: color-mix(in srgb, var(--primary) 6%, var(--card-bg));
  color: var(--ink);
  font-size: 0.8125rem;
  font-weight: 600;
}
.pdp__perk .icon { color: var(--primary); }
/* gallery */
.gallery__main { border: 1px solid var(--line); border-radius: 1.5rem; background: var(--card-bg); overflow: hidden; }
.gallery__thumb { border-radius: 0.875rem; }
.gallery__thumb[aria-current="true"], .gallery__thumb.is-active { box-shadow: 0 0 0 2px var(--primary); }
/* description / reviews tabs */
.tabs__list { gap: 0.25rem; border-block-end: 1px solid var(--line); }
.tabs__tab { padding: 0.875rem 1.125rem; font-weight: 700; color: var(--muted); border-block-end: 3px solid transparent; }
.tabs__tab[aria-selected="true"] { color: var(--primary); border-block-end-color: var(--primary); }
.tabs__panel { line-height: 1.9; }
.pdp__stock { align-self: flex-start; width: max-content; max-width: 100%; }
/* text inside product tabs / cards stays plain — the white card is for standalone content pages */
.tabs__panel .prose, .pdp .prose, .card .prose { max-width: none; margin: 0; padding: 0; border: 0; border-radius: 0; background: none; }

/* favourites button in the header: heart beside account and cart */
.hdr__action--wish.is-active { color: var(--sale); border-color: color-mix(in srgb, var(--sale) 35%, var(--line)); background: color-mix(in srgb, var(--sale) 7%, var(--card-bg)); }
.hdr__action--wish:hover { color: var(--sale); border-color: color-mix(in srgb, var(--sale) 35%, var(--line)); background: color-mix(in srgb, var(--sale) 7%, var(--card-bg)); }
.hdr__action--wish .count-dot { background: var(--primary); }
@media (max-width: 479px) { .hdr__action--wish { display: none; } } /* phones already have it in the bottom tab bar */

/* ══ Quick view (choose options dialog) ════════════════════════════════
   Options as radio tiles: a visible radio circle that fills green when
   chosen, the value beside it, two tiles per row; the group label shows the
   current choice. Unavailable values are faded and struck through. */
.quick-view { border-radius: 1.75rem; }
.quick-view .modal__title { font-family: var(--font-display); font-size: 1.25rem; font-weight: 900; }
.quick-view .quick-view__img { border-radius: 1.25rem; }
.quick-view .price--xl { font-family: var(--font-display); font-size: 1.875rem; font-weight: 900; color: var(--primary); }
.quick-view [data-qv-options] { gap: 1.25rem !important; }
.quick-view .opt-group { margin: 0; padding: 0; border: 0; min-width: 0; }
.quick-view .opt-group > .field__label { margin-block-end: 0.625rem; font-size: 0.875rem; font-weight: 700; color: var(--ink); }
.quick-view .opt-group__chosen { color: var(--primary); }

.quick-view .opt-chips--radio { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; }
.quick-view .opt-chips--radio .opt-chip {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  min-height: 3rem;
  padding: 0.625rem 0.875rem;
  border: 1.5px solid var(--line);
  border-radius: 0.875rem;
  background: var(--card-bg);
  cursor: pointer;
  transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.quick-view .opt-chips--radio .opt-chip:hover { border-color: color-mix(in srgb, var(--primary) 45%, var(--line)); }
.quick-view .opt-chips--radio .opt-chip__text {
  padding: 0;
  border: 0 !important;
  border-radius: 0;
  background: none;
  box-shadow: none !important;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.35;
}
.quick-view .opt-chip__radio {
  position: relative;
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid color-mix(in srgb, var(--muted) 55%, var(--line));
  border-radius: 50%;
  background: var(--card-bg);
  transition: border-color var(--t-fast) var(--ease);
}
.quick-view .opt-chip__radio::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 0.625rem;
  height: 0.625rem;
  border-radius: 50%;
  background: var(--primary);
  transform: scale(0);
  transition: transform 160ms var(--ease-out);
}
/* chosen */
.quick-view .opt-chips--radio .opt-chip:has(input:checked) {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 6%, var(--card-bg));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 10%, transparent);
}
.quick-view .opt-chip:has(input:checked) .opt-chip__radio { border-color: var(--primary); }
.quick-view .opt-chip:has(input:checked) .opt-chip__radio::after { transform: scale(1); }
.quick-view .opt-chip:has(input:checked) .opt-chip__text { color: var(--primary); font-weight: 700; }
/* keyboard focus */
.quick-view .opt-chips--radio .opt-chip:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: 2px; }
/* unavailable combination */
.quick-view .opt-chips--radio .opt-chip.is-out { background: color-mix(in srgb, var(--bg) 60%, var(--card-bg)); border-style: dashed; }
.quick-view .opt-chips--radio .opt-chip.is-out .opt-chip__text { color: var(--muted); text-decoration: line-through; }
.quick-view .opt-chips--radio .opt-chip.is-out .opt-chip__radio { border-style: dashed; }

/* quantity + actions */
.quick-view .qty { height: 3rem; border: 1px solid var(--line); border-radius: 0.875rem; background: color-mix(in srgb, var(--bg) 60%, var(--card-bg)); }
.quick-view .qty__btn { width: 3rem; color: var(--primary); }
.quick-view .qty__value { font-weight: 800; }
.quick-view [data-qv-add] { min-height: 3.25rem; border-radius: 1rem; font-size: 1rem; font-weight: 800; }
.quick-view [data-qv-link] { color: var(--primary); font-weight: 700; }
@media (max-width: 479px) { .quick-view .opt-chips--radio { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .quick-view .opt-chip__radio::after { transition: none; } }