/* محلك أونلاين - the public shop page (templates/shop/page.html, static/js/shop-store.js).
   One idea carries the look: the shop's own colour as an awning over the page (scalloped edge, the shop sign under
   it). Everything else stays quiet so the products read first. Works the same with product pictures or without
   (every product without one gets a tile in its category's colour). Mobile first; wider screens get more columns. */
:root {
  --brand: #0E7C66;
  --brand-soft: color-mix(in srgb, var(--brand) 11%, #fff);
  --brand-deep: color-mix(in srgb, var(--brand) 82%, #000);
  --ink: #16181D; --bg: #F2F3F5; --card: #fff; --line: #E3E5E9; --mut: #6A7180; --sale: #D92D20; --ok: #12805C;
  --r-lg: 22px; --r-md: 16px; --r-sm: 11px;
  --shadow: 0 1px 0 rgba(22, 24, 29, .04), 0 6px 18px -10px rgba(22, 24, 29, .18);
}
* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html { background: var(--bg); scroll-padding-top: 130px; }
body { font-family: "Readex Pro", Almarai, Tahoma, sans-serif; color: var(--ink); background: var(--bg); min-height: 100vh;
  font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2.5px solid var(--brand); outline-offset: 2px; }
.sprite { position: absolute; }
svg { width: 1em; height: 1em; flex: none; }
#app { max-width: 1180px; margin: 0 auto; padding-bottom: 110px; }

/* ---------------------------------------------------------------- the awning (header) */
.aw { position: relative; color: #fff; background: var(--brand); padding: 26px 16px 34px; overflow: hidden; }
.aw::before { /* awning stripes when there is no cover picture */
  content: ""; position: absolute; inset: 0;
  background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .09) 0 28px, transparent 28px 56px); }
.aw-cover { position: absolute; inset: 0; }
.aw-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.aw.has-cover::before { background: linear-gradient(180deg, rgba(0, 0, 0, .15), rgba(0, 0, 0, .62)); z-index: 1; }
.aw-edge { /* the scalloped edge of a shop awning */
  position: absolute; left: 0; right: 0; bottom: -1px; height: 14px; z-index: 2;
  background: radial-gradient(circle at 14px 0, transparent 13px, var(--bg) 13.5px) 0 0 / 28px 14px repeat-x; }
.aw-in { position: relative; z-index: 3; display: flex; align-items: flex-end; gap: 14px; min-height: 92px; }
.aw.has-cover .aw-in { min-height: 150px; }
.aw-logo { flex: none; width: 74px; height: 74px; border-radius: 22px; background: #fff; color: var(--brand); display: grid;
  place-items: center; overflow: hidden; box-shadow: 0 8px 22px -8px rgba(0, 0, 0, .45); border: 3px solid rgba(255, 255, 255, .9); }
.aw-logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.aw-logo span { font-size: 34px; font-weight: 700; }
.aw-t { min-width: 0; flex: 1; }
.aw h1 { font-size: 23px; line-height: 1.25; font-weight: 700; overflow-wrap: anywhere; }
.aw h1 small { font-size: 14px; font-weight: 500; opacity: .85; margin-inline-start: 4px; }
.aw-tag { font-size: 13.5px; opacity: .9; margin-top: 2px; }
.aw-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 600; padding: 5px 11px;
  border-radius: 999px; background: rgba(255, 255, 255, .17); backdrop-filter: blur(4px); }
.pill i { width: 7px; height: 7px; border-radius: 50%; background: #5CF0A6; box-shadow: 0 0 0 3px rgba(92, 240, 166, .25); }
.pill.off i { background: #FFB4A0; box-shadow: 0 0 0 3px rgba(255, 180, 160, .25); }
.aw-info { display: inline-flex; align-items: center; gap: 6px; border: 1px solid rgba(255, 255, 255, .45); background: none;
  color: #fff; border-radius: 999px; padding: 4px 11px; font-size: 12.5px; font-weight: 600; }
.aw-info svg { width: 15px; height: 15px; }

/* ---------------------------------------------------------------- search + categories (sticky) */
.tools { position: sticky; top: 0; z-index: 8; background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(10px); padding: 10px 14px 6px; }
.srch { background: #fff; border: 1px solid var(--line); border-radius: var(--r-md); padding: 0 14px; display: flex; gap: 9px;
  align-items: center; color: var(--mut); box-shadow: var(--shadow); }
.srch:focus-within { border-color: var(--brand); }
.srch svg { width: 18px; height: 18px; }
.srch input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; padding: 12px 0; font-size: 15px; color: var(--ink); }
.chips { display: flex; gap: 7px; padding: 10px 0 4px; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; padding: 6px 13px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-size: 13.5px;
  font-weight: 500; display: flex; gap: 7px; align-items: center; }
.chip i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip.hot { color: var(--sale); border-color: color-mix(in srgb, var(--sale) 35%, #fff); }
.chip.hot.on { background: var(--sale); color: #fff; border-color: var(--sale); }
.chip svg { width: 14px; height: 14px; }

.notice { margin: 8px 14px 0; padding: 11px 14px; border-radius: var(--r-md); background: var(--brand-soft); color: var(--brand-deep);
  font-size: 13.5px; font-weight: 600; border: 1px solid color-mix(in srgb, var(--brand) 22%, #fff); }
.notice.closed-n { background: #FFF4EC; color: #8A3A12; border-color: #F6D4BF; }

/* ---------------------------------------------------------------- banners */
.bn { margin: 12px 14px 0; position: relative; }
.bn-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; gap: 10px; border-radius: var(--r-lg); }
.bn-track::-webkit-scrollbar { display: none; }
.bn-s { flex: 0 0 100%; scroll-snap-align: center; border-radius: var(--r-lg); overflow: hidden; position: relative; border: 0;
  aspect-ratio: 2.4 / 1; background: var(--brand); color: #fff; text-align: right; display: block; padding: 0; }
.bn-s img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bn-s.txt { padding: 18px 20px; display: flex; flex-direction: column; justify-content: center; gap: 4px; }
.bn-s.txt::after { content: ""; position: absolute; inset-inline-start: -30px; bottom: -40px; width: 160px; height: 160px; border-radius: 50%;
  border: 26px solid rgba(255, 255, 255, .12); }
.bn-s.txt b { font-size: clamp(19px, 5vw, 28px); line-height: 1.25; font-weight: 700; position: relative; z-index: 1; max-width: 85%; }
.bn-s.txt span { font-size: 14px; opacity: .92; position: relative; z-index: 1; max-width: 85%; }
.bn-s .cap { position: absolute; inset-inline: 0; bottom: 0; padding: 26px 16px 12px; background: linear-gradient(transparent, rgba(0, 0, 0, .6)); }
.bn-s .cap b { display: block; font-size: 17px; } .bn-s .cap span { font-size: 13px; opacity: .9; }
.bn-dots { display: flex; justify-content: center; gap: 6px; margin-top: 8px; }
.bn-dots i { width: 7px; height: 7px; border-radius: 4px; background: #C9CDD4; transition: width .2s; }
.bn-dots i.on { width: 20px; background: var(--brand); }

/* ---------------------------------------------------------------- home sections (horizontal rows) */
.sec { margin-top: 22px; }
.sec-h { display: flex; align-items: baseline; justify-content: space-between; padding: 0 16px; margin-bottom: 9px; }
.sec-h h2 { font-size: 17px; font-weight: 700; display: flex; align-items: center; gap: 7px; }
.sec-h h2 svg { width: 18px; height: 18px; color: var(--brand); }
.sec.offers .sec-h h2 svg { color: var(--sale); }
.sec-h button { border: 0; background: none; color: var(--brand); font-weight: 600; font-size: 13.5px; }
.row { display: flex; gap: 10px; overflow-x: auto; padding: 2px 16px 6px; scroll-snap-type: x proximity; scrollbar-width: none; }
.row::-webkit-scrollbar { display: none; }
.row > .pc { flex: 0 0 152px; scroll-snap-align: start; }
.cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(98px, 1fr)); gap: 9px; padding: 0 14px; }
.cat { border: 0; border-radius: var(--r-md); padding: 14px 8px 11px; background: var(--cb); color: var(--c); display: flex;
  flex-direction: column; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; line-height: 1.3; text-align: center; }
.cat svg { width: 28px; height: 28px; }
.cat small { font-weight: 400; opacity: .75; font-size: 11.5px; }
/* «صورة التصنيف» (2026-11-03b): the picture fills the top of the square */
.cat.has-pic { padding-top: 8px; }
.cat-pic { width: 100%; aspect-ratio: 1; border-radius: calc(var(--r-md) - 4px); overflow: hidden; background: #fff; display: block; }
.cat-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.chip-pic { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; margin-block: -3px; margin-inline-start: -6px; background: #fff; }

/* ---------------------------------------------------------------- all products */
.all { margin-top: 24px; }
.all-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 16px 10px; flex-wrap: wrap; }
.all-h h2 { font-size: 17px; font-weight: 700; } .all-h h2 small { font-size: 13px; font-weight: 400; color: var(--mut); }
.all-c { display: flex; gap: 8px; align-items: center; }
.all-c select { border: 1px solid var(--line); background: #fff; border-radius: var(--r-sm); padding: 7px 10px; font-size: 13px; outline: 0; }
.vt { display: flex; background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); padding: 3px; }
.vt button { border: 0; background: none; width: 32px; height: 28px; border-radius: 8px; color: var(--mut); display: grid; place-items: center; }
.vt button.on { background: var(--ink); color: #fff; }
.vt svg { width: 17px; height: 17px; }
.list { padding: 0 14px; }
.list.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.list.rows { display: flex; flex-direction: column; gap: 8px; }
.empty { text-align: center; color: var(--mut); padding: 46px 10px; font-weight: 500; grid-column: 1 / -1; }
.more { height: 1px; }

/* product card (grid + home rows) */
.pc { background: var(--card); border-radius: var(--r-lg); border: 1px solid var(--line); overflow: hidden; display: flex;
  flex-direction: column; min-width: 0; position: relative; }
.pc-img { display: block; width: 100%; aspect-ratio: 1 / 1; border: 0; padding: 0; background: #fff; position: relative; overflow: hidden; }
.pc-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.art { position: absolute; inset: 0; background: var(--cb); color: var(--c); display: grid; place-items: center; }
.art svg { width: 38%; height: 38%; opacity: .9; }
.art em { position: absolute; bottom: 9px; left: 8px; right: 8px; font-style: normal; font-size: 11.5px; font-weight: 600;
  text-align: center; opacity: .8; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.badge { position: absolute; top: 9px; inset-inline-start: 9px; z-index: 1; font-size: 11.5px; font-weight: 700; color: #fff;
  background: var(--sale); border-radius: 8px; padding: 1px 7px; }
.badge.nw { background: var(--ink); }
.badge.bs { background: #fff; color: var(--ink); box-shadow: 0 2px 8px rgba(0, 0, 0, .12); }
.pc-b { padding: 9px 11px 11px; display: flex; flex-direction: column; gap: 3px; flex: 1; }
.pc-n { font-size: 14px; font-weight: 600; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; min-height: 2.8em; border: 0; background: none; text-align: right; padding: 0; }
.pc-u { font-size: 12px; color: var(--mut); }
.pc-u.low { color: #B4421A; font-weight: 600; }
.pc-f { display: flex; align-items: flex-end; justify-content: space-between; gap: 6px; margin-top: auto; padding-top: 6px; }
.price { font-weight: 700; font-size: 15.5px; white-space: nowrap; line-height: 1.2; }
.price s { display: block; font-size: 12px; color: #9AA0AA; font-weight: 400; }
.price.sale { color: var(--sale); }
.price.q { color: var(--brand-deep, var(--brand)); font-size: 13.5px; }

/* controls */
.add { flex: none; min-width: 38px; height: 38px; border-radius: 13px; background: var(--brand); color: #fff; border: 0; font-size: 22px;
  font-weight: 500; display: grid; place-items: center; padding: 0 10px; }
.add.pick { font-size: 13px; font-weight: 600; }
.add .c { font-size: 11px; background: #fff; color: var(--brand); border-radius: 7px; padding: 0 5px; margin-inline-start: 5px; }
.add:disabled { opacity: .35; }
.step { flex: none; display: flex; align-items: center; border-radius: 13px; background: var(--brand); color: #fff; height: 38px; }
.step button { width: 31px; height: 38px; border: 0; background: none; color: #fff; font-size: 19px; font-weight: 600; }
.step span { min-width: 22px; text-align: center; font-weight: 700; font-size: 14px; direction: ltr; }
.wt { display: flex; gap: 5px; margin-top: 6px; flex-wrap: wrap; }
.wt button { white-space: nowrap; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 8px; background: var(--bg);
  border: 1px solid var(--line); }
.wt button.on { background: var(--brand-soft); border-color: var(--brand); color: var(--brand-deep); }

/* list rows (no pictures, or the customer's choice) */
.it { background: var(--card); border-radius: var(--r-md); padding: 9px; display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); }
.it .tile { flex: none; width: 60px; height: 60px; border-radius: 14px; overflow: hidden; position: relative; border: 0; padding: 0; background: #fff; }
.it .tile img { width: 100%; height: 100%; object-fit: contain; }
.it .art svg { width: 26px; height: 26px; margin-top: -10px; }
.it .art em { bottom: 5px; font-size: 9.5px; }
.nm { flex: 1; min-width: 0; }
.nm .pc-n { min-height: 0; font-size: 14.5px; }
.it .price { text-align: left; }

/* ---------------------------------------------------------------- the cart bar */
.bar { position: fixed; z-index: 9; bottom: 14px; left: 50%; transform: translateX(-50%); width: calc(100% - 24px); max-width: 560px; height: 60px;
  border-radius: 20px; background: var(--brand); color: #fff; border: 0; display: flex; align-items: center; padding: 0 16px; gap: 12px;
  box-shadow: 0 14px 30px -10px color-mix(in srgb, var(--brand) 70%, #000); }
.bar .n { width: 34px; height: 34px; border-radius: 11px; background: rgba(255, 255, 255, .22); display: grid; place-items: center; font-weight: 700; }
.bar b { flex: 1; font-size: 16px; font-weight: 600; text-align: right; } .bar span:last-child { font-weight: 700; font-size: 17px; }
.bar.empty { background: var(--ink); box-shadow: 0 10px 26px -8px rgba(22, 24, 29, .5); }
.bar.empty b { font-size: 14.5px; font-weight: 400; color: #D8DBE0; }
.bar.bump { animation: bump .32s ease; }
@keyframes bump { 40% { transform: translateX(-50%) scale(1.04); } }

/* ---------------------------------------------------------------- product + info sheets */
.ps { position: fixed; inset: 0; z-index: 20; display: flex; align-items: flex-end; justify-content: center; }
.ps-back { position: absolute; inset: 0; background: rgba(15, 17, 21, .5); animation: fade .18s ease; }
.ps-card { position: relative; background: #fff; width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; border-radius: 26px 26px 0 0;
  animation: up .24s cubic-bezier(.2, .8, .3, 1); padding-bottom: env(safe-area-inset-bottom); }
.ps-x { position: absolute; top: 12px; inset-inline-end: 12px; z-index: 2; width: 38px; height: 38px; border-radius: 50%; border: 0;
  background: rgba(255, 255, 255, .92); box-shadow: 0 2px 10px rgba(0, 0, 0, .15); display: grid; place-items: center; }
.ps-x svg { width: 18px; height: 18px; }
.ps-img { position: relative; aspect-ratio: 4 / 3; background: #fff; border-bottom: 1px solid var(--line); }
.ps-img img { width: 100%; height: 100%; object-fit: contain; }
.ps-img .art svg { width: 30%; height: 30%; }
.ps-img .art em { font-size: 14px; bottom: 14px; }
.ps-b { padding: 16px 18px 6px; }
.ps-b h3 { font-size: 20px; font-weight: 700; line-height: 1.35; padding-inline-end: 40px; }
.info .ps-b h3 { padding-top: 6px; }
.ps-p { display: flex; align-items: baseline; gap: 10px; margin-top: 6px; }
.ps-p .price { font-size: 21px; }
.ps-p .price s { display: inline; margin-inline-start: 8px; font-size: 14px; }
.ps-p small { color: var(--mut); font-size: 13px; }
.ps-d { color: #3E4450; font-size: 14px; margin-top: 10px; white-space: pre-line; }
.ps-bx { margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: rgba(0,0,0,.04); font-size: 14px; }
.ps-bx ul { list-style: none; margin: 6px 0 0; padding: 0; }
.ps-bx li { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; border-top: 1px dashed rgba(0,0,0,.1); }
.ps-bx li:first-child { border-top: 0; }
.pc-bx { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.ps-v { margin-top: 14px; }
.ps-v h4 { font-size: 14px; font-weight: 600; margin-bottom: 8px; }
.ps-v .opts { display: flex; flex-wrap: wrap; gap: 8px; }
.ps-v .opts button { border: 1.5px solid var(--line); background: #fff; border-radius: 12px; padding: 8px 14px; font-size: 14px; font-weight: 500; }
.ps-v .opts button small { color: var(--mut); font-size: 11.5px; margin-inline-start: 4px; }
.ps-v .opts button.on { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-deep); font-weight: 600; }
.ps-v .opts button:disabled { opacity: .4; text-decoration: line-through; }
.ps-v h4 b { color: var(--brand-deep); }
.ps-v .opts.clr button.pic { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 5px 6px 6px; min-width: 70px; }
.ps-v .opts.clr button img { width: 56px; height: 56px; border-radius: 9px; object-fit: cover; display: block; }
.ps-v .opts.clr button.pic small { margin: 0; }
.ps-v .opts.sz button { min-width: 52px; text-align: center; }
.ps-v .opts button:disabled small { text-decoration: none; }
.ps-f { position: sticky; bottom: 0; background: #fff; display: flex; gap: 10px; padding: 12px 18px 16px; border-top: 1px solid var(--line); margin-top: 10px; }
.ps-f .step { height: 52px; border-radius: 16px; background: var(--bg); color: var(--ink); }
.ps-f .step button { height: 52px; width: 42px; color: var(--ink); font-size: 22px; }
.ps-f .go { flex: 1; height: 52px; border-radius: 16px; border: 0; background: var(--brand); color: #fff; font-weight: 600; font-size: 16px;
  display: flex; align-items: center; justify-content: space-between; padding: 0 18px; }
.ps-f .go:disabled { background: #C9CDD4; }
.inf { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.inf:last-child { border-bottom: 0; }
.inf > svg { width: 20px; height: 20px; color: var(--brand); margin-top: 2px; }
.inf b { display: block; font-weight: 600; } .inf span { color: var(--mut); font-size: 13.5px; }
.inf a { color: var(--brand-deep); font-weight: 600; text-decoration: none; }
.soc { display: flex; gap: 10px; padding: 14px 0 18px; }
.soc a { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-deep); }
.soc svg { width: 20px; height: 20px; }
@keyframes up { from { transform: translateY(40px); opacity: .4; } }
@keyframes fade { from { opacity: 0; } }

/* ---------------------------------------------------------------- the customer's orders («طلباتك») */
.mine { margin: 12px 14px 0; display: flex; flex-direction: column; gap: 8px; }
.mine h3 { font-size: 14px; color: var(--mut); padding: 0 4px; font-weight: 600; }
.mine-o { display: block; background: #fff; border: 2px solid var(--brand); border-radius: var(--r-md); padding: 12px 14px; text-decoration: none; color: inherit; }
.mine-o.st-done { border-color: var(--ok); } .mine-o.st-cancelled { border-color: var(--line); opacity: .8; }
.mine-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.mine-s { font-weight: 700; color: var(--brand); font-size: 14px; }
.st-done .mine-s { color: var(--ok); } .st-cancelled .mine-s { color: var(--mut); }
.mine-steps { display: flex; gap: 5px; margin: 10px 0 8px; }
.mine-steps i { flex: 1; height: 6px; border-radius: 4px; background: var(--line); }
.mine-steps i.on { background: var(--brand); } .st-done .mine-steps i.on { background: var(--ok); }
.mine-f { display: flex; justify-content: space-between; font-size: 13px; color: var(--mut); font-weight: 600; }

/* ---------------------------------------------------------------- checkout */
.sheet { position: fixed; inset: 0; z-index: 30; background: var(--bg); display: flex; flex-direction: column; max-width: 560px; margin: 0 auto; }
.nav { padding: 14px 16px; display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; background: #fff; border-bottom: 1px solid var(--line); }
.bk { width: 36px; height: 36px; border-radius: 11px; background: var(--bg); border: 0; font-size: 18px; }
.sheet-b { flex: 1; overflow-y: auto; padding-bottom: 90px; }
.box { background: #fff; margin: 10px 12px; border-radius: 18px; border: 1px solid var(--line); padding: 12px 14px; }
.box h4 { font-size: 13.5px; color: var(--mut); margin-bottom: 8px; font-weight: 600; }
.cl { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.cl:last-child { border-bottom: 0; }
.cl .t { flex: 1; font-weight: 600; min-width: 0; } .cl .t small { display: block; color: var(--mut); font-weight: 400; font-size: 12px; }
.cl .p { font-weight: 700; white-space: nowrap; }
.cl .step { height: 32px; } .cl .step button { height: 32px; width: 28px; }
.seg { display: flex; background: var(--bg); border-radius: 12px; padding: 4px; gap: 4px; }
.seg button { flex: 1; text-align: center; padding: 9px 6px; border-radius: 9px; font-size: 13.5px; font-weight: 600; color: var(--mut); border: 0; background: none; }
.seg button.on { background: #fff; color: var(--ink); box-shadow: 0 2px 6px rgba(0, 0, 0, .08); }
.fld { display: block; margin-top: 10px; }
.fld span { display: block; font-size: 12.5px; color: var(--mut); margin-bottom: 4px; font-weight: 600; }
.fld input, .fld textarea, .fld select { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font-size: 15px; background: #fff; outline: 0; resize: vertical; }
.fld input:focus, .fld textarea:focus, .fld select:focus { border-color: var(--brand); }
.fld select { appearance: auto; font: inherit; font-size: 15px; height: 44px; }
.fld-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
.fld-row[hidden] { display: none; }
@media (max-width: 380px) { .fld-row { grid-template-columns: 1fr; } }
.fld.bad input, .fld.bad textarea, .fld.bad select { border-color: #d33; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.hint { margin-top: 8px; font-size: 13px; color: var(--mut); }
.tots { margin-top: 10px; }
.tot { display: flex; justify-content: space-between; font-size: 14px; padding: 3px 0; color: var(--mut); }
.tot.g { color: var(--ink); font-weight: 700; font-size: 17px; border-top: 1px solid var(--line); margin-top: 6px; padding-top: 8px; }
.warn { margin-top: 8px; font-size: 13px; color: #B4421A; font-weight: 600; }
.err { margin: 4px 14px; padding: 10px 14px; border-radius: 12px; background: #FDECEC; color: #A61B1B; font-weight: 600; font-size: 14px; }
.send { position: fixed; bottom: 14px; left: 50%; transform: translateX(-50%); width: calc(100% - 24px); max-width: 536px; height: 58px; border-radius: 18px;
  background: var(--brand); color: #fff; border: 0; font-weight: 700; font-size: 17px; }
.send:disabled { opacity: .5; }
.done { justify-content: center; }
.done-b { padding: 30px 22px; text-align: center; }
.ok { width: 84px; height: 84px; border-radius: 50%; background: #E4F5EC; color: var(--ok); display: grid; place-items: center; margin: 0 auto 14px; font-size: 42px; font-weight: 700; }
.done h2 { font-size: 22px; } .done p { color: var(--mut); font-size: 14px; margin-top: 4px; }
.btn-l, .wa, .btn-g { display: flex; align-items: center; justify-content: center; gap: 8px; height: 52px; border-radius: 16px; margin-top: 12px;
  font-weight: 700; font-size: 15.5px; text-decoration: none; border: 0; width: 100%; }
.btn-l { background: var(--brand); color: #fff; margin-top: 22px; }
.wa { background: #25D366; color: #08321a; } .wa svg { width: 22px; height: 22px; }
.btn-g { background: none; color: var(--mut); }
.credit { text-align: center; padding: 26px 12px 10px; font-size: 12px; color: #9AA0AA; }
.credit a { color: inherit; text-decoration: none; }

/* ---------------------------------------------------------------- wider screens */
@media (min-width: 640px) {
  .list.grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .row > .pc { flex-basis: 170px; }
  .bn-s { flex-basis: 100%; aspect-ratio: 3 / 1; }
  .bn-s.txt { aspect-ratio: auto; min-height: 150px; padding: 22px 28px; }
  .aw { padding: 34px 26px 40px; }
  .ps { align-items: center; }
  .ps-card { border-radius: 26px; }
}
@media (min-width: 960px) {
  .list.grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .list.rows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tools { padding-inline: 20px; }
  .list, .cats { padding-inline: 20px; } .row, .sec-h, .all-h { padding-inline: 22px; }
  .bn { margin-inline: 20px; } .bn-s { aspect-ratio: 3.6 / 1; }
  .bn-s.txt { aspect-ratio: auto; min-height: 170px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.ps-v .wfree { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 13.5px; color: var(--mut); }
.ps-v .wfree input { flex: 1; min-width: 0; max-width: 160px; border: 1.5px solid var(--line); border-radius: 12px; padding: 8px 12px; font: inherit; font-size: 15px; color: inherit; background: #fff; text-align: center; }
.ps-v .wfree input:focus { outline: none; border-color: var(--brand); }

/* 2026-11-17j قطع الغيار: the cars a part fits, its numbers, its alternatives; a part that ran out */
.ps-parts { margin: 8px 0 0; font-size: 13.5px; color: #3C4049; display: grid; gap: 6px; }
.ps-parts p { margin: 0; }
.ps-parts .ps-out { color: #B4421A; font-weight: 700; }
.ps-alts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ps-alts .chip { padding: 6px 12px; }
.ps-alts .chip small { color: var(--brand, #C2410C); font-weight: 700; margin-inline-start: 4px; }
.add.pick.alt { background: #FFF4EC; color: #B4421A; border-color: #F5C9A8; }

/* 2026-11-17m: the page by what it sells - «عربيتك» for parts, «بروشتة» for drugs, the service line for car centres */
.carf { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 9px; padding: 8px 10px; background: #fff;
  border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow); }
.carf b { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--brand-deep); }
.carf b svg { width: 17px; height: 17px; }
.carf select { flex: 1 1 110px; min-width: 0; border: 1px solid var(--line); background: var(--bg); border-radius: var(--r-sm);
  padding: 7px 9px; font-size: 13.5px; outline: 0; }
.carf select:disabled { opacity: .55; }
.carf button { border: 0; background: var(--bg); width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; color: var(--mut); }
.rx { display: inline-block; font-size: 10.5px; font-weight: 700; color: #fff; background: #B4421A; border-radius: 6px;
  padding: 0 6px; margin-inline-end: 5px; line-height: 1.6; }
.kit-n { display: flex; align-items: center; gap: 9px; text-decoration: none; }
.kit-n svg { width: 18px; height: 18px; flex: none; }
/* «الشحن والخدمات» (2026-11-24i): the top-up / bill box on the home page and its window */
.svc-sec .svc-row { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 8px; scrollbar-width: none; }
.svc-sec .svc-row::-webkit-scrollbar { display: none; }
.svc-t { flex: none; display: grid; justify-items: center; gap: 6px; min-width: 104px; padding: 12px 10px; border: 1px solid var(--line); border-radius: 16px; background: #fff; font: inherit; font-size: 13px; font-weight: 700; color: inherit; cursor: pointer; }
.svc-t i { width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; background: var(--svc-c, var(--brand)); color: #fff; font-style: normal; font-size: 18px; }
.svs-card { max-width: 440px; }
.svs-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.svs-chips button { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 6px 14px; font: inherit; font-weight: 700; cursor: pointer; }
.svs-p { margin: 12px 0 4px; font-size: 15px; font-weight: 700; }
.svs-add { position: static; transform: none; width: 100%; margin-top: 10px; border-radius: 14px; }
.cl.svc .t small { direction: ltr; text-align: right; }

/* «صور مقترحة» (2026-11-25c): the source of a picture from an open library, under the product's name */
.ps-gc{display:block;font-size:10px;opacity:.6;margin:2px 0 4px;text-align:start;overflow-wrap:anywhere}
