/* Kahf: black and white store. One memorable thing: the masthead wordmark. Everything else stays quiet. */

@font-face { font-family: "Plex"; font-weight: 400; font-display: swap; src: url("../fonts/ibm-plex-sans-arabic-arabic-400-normal.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: "Plex"; font-weight: 500; font-display: swap; src: url("../fonts/ibm-plex-sans-arabic-arabic-500-normal.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: "Plex"; font-weight: 700; font-display: swap; src: url("../fonts/ibm-plex-sans-arabic-arabic-700-normal.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: "Plex"; font-weight: 400; font-display: swap; src: url("../fonts/ibm-plex-sans-arabic-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plex"; font-weight: 500; font-display: swap; src: url("../fonts/ibm-plex-sans-arabic-latin-500-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plex"; font-weight: 700; font-display: swap; src: url("../fonts/ibm-plex-sans-arabic-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Kufi"; font-weight: 700; font-display: swap; src: url("../fonts/noto-kufi-arabic-arabic-700-normal.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: "Kufi"; font-weight: 800; font-display: swap; src: url("../fonts/noto-kufi-arabic-arabic-800-normal.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }

:root {
  --ink: #000;
  --paper: #fff;
  --mist: #f3f3f3;
  --stone: #e6e6e6;
  --line: #dcdcdc;
  --mute: #666;
  --danger: #b3261e;
  --ok: #1b6e3c;
  --body: "Plex", "Segoe UI", Tahoma, system-ui, sans-serif;
  --head: "Kufi", "Plex", "Segoe UI", Tahoma, sans-serif;
  --wrap: 1320px;
  --gap: clamp(12px, 2vw, 28px);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--body); font-size: 16px; line-height: 1.65; color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
h1, h2, h3, h4 { font-family: var(--head); font-weight: 700; line-height: 1.35; margin: 0; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.dark :focus-visible, .foot :focus-visible { outline-color: #fff; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: min(100% - 2 * var(--gap), var(--wrap)); margin-inline: auto; }
.skip { position: absolute; inset-inline-start: 8px; top: -60px; background: var(--ink); color: #fff; padding: 10px 16px; z-index: 100; }
.skip:focus { top: 8px; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 28px; border: 1px solid var(--ink); background: var(--ink); color: #fff; font-weight: 500; text-decoration: none; transition: background .2s, color .2s, opacity .2s; }
.btn:hover { background: #222; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .35; cursor: not-allowed; }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: var(--ink); color: #fff; }
.btn.block { width: 100%; }
.link { background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 4px; }

/* ---------- top bar and header ---------- */
.promo { background: var(--ink); color: #fff; text-align: center; font-size: 14px; padding: 9px var(--gap); }
.head { position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.head .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 62px; gap: 16px; }
.mark { font-family: var(--body); font-weight: 700; font-size: 24px; letter-spacing: .14em; text-decoration: none; line-height: 1; }
.mark img { height: 30px; width: auto; }
.nav { display: flex; align-items: center; gap: 6px; }
.nav a, .nav button { position: relative; display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 0 10px; background: none; border: 0; text-decoration: none; font-size: 15px; }
.nav a.text:hover { text-decoration: underline; text-underline-offset: 6px; }
.count { position: absolute; top: 4px; inset-inline-start: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--ink); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.fab .count { top: -6px; inset-inline-start: -6px; background: #fff; color: var(--ink); border: 1px solid var(--ink); }

.fab { position: fixed; z-index: 40; inset-block-end: 18px; inset-inline-start: 18px; width: 56px; height: 56px; border-radius: 50%; background: var(--ink); color: #fff; display: none; align-items: center; justify-content: center; box-shadow: 0 6px 20px rgba(0, 0, 0, .25); text-decoration: none; }
.fab.bump { animation: bump .5s var(--ease); }
@keyframes bump { 40% { transform: scale(1.18); } }
@media (max-width: 720px) { .fab { display: flex; } .head .cart-link { display: none; } }

/* ---------- masthead ---------- */
.masthead { border-bottom: 1px solid var(--line); overflow: hidden; }
.masthead .wrap { padding-block: clamp(28px, 6vw, 72px) clamp(20px, 3vw, 36px); }
.masthead .brand { font-family: var(--body); font-weight: 700; font-size: clamp(84px, 24vw, 250px); line-height: .8; letter-spacing: -.045em; margin: 0 0 clamp(18px, 3vw, 36px); text-align: start; }
.masthead .brand img { width: min(100%, 560px); height: auto; }
.masthead .row { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px 32px; }
.masthead .tag { font-family: var(--head); font-weight: 700; font-size: clamp(18px, 2.6vw, 28px); max-width: 28ch; }
.masthead .sub { color: var(--mute); max-width: 46ch; }
.masthead .go { font-weight: 500; text-decoration: underline; text-underline-offset: 6px; white-space: nowrap; }

/* ---------- catalog toolbar ---------- */
.catalog { padding-block: clamp(20px, 3vw, 40px) clamp(40px, 6vw, 88px); }
.bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; margin-bottom: clamp(18px, 2.4vw, 32px); }
.tabs { display: flex; gap: 4px 22px; overflow-x: auto; scrollbar-width: none; margin-inline: calc(var(--gap) * -1); padding-inline: var(--gap); max-width: 100vw; }
.tabs::-webkit-scrollbar { display: none; }
.tab { flex: none; background: none; border: 0; border-bottom: 2px solid transparent; padding: 8px 0; min-height: 44px; color: var(--mute); font-weight: 500; }
.tab:hover { color: var(--ink); }
.tab[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.field { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: #fff; min-height: 44px; padding: 0 12px; }
.field:focus-within { border-color: var(--ink); }
.field input, .field select { border: 0; background: transparent; outline: 0; min-height: 42px; min-width: 0; }
.field input { width: 170px; }
.field svg { flex: none; color: var(--mute); }
.found { color: var(--mute); font-size: 14px; }

.group + .group { margin-top: clamp(36px, 5vw, 72px); }
.group-head { margin-bottom: 18px; }
.group-head h2 { font-size: clamp(22px, 3vw, 34px); }
.group-head p { color: var(--mute); margin-top: 4px; max-width: 60ch; }

/* ---------- product grid and card ---------- */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(22px, 3vw, 44px) var(--gap); }
@media (min-width: 720px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.card { display: block; text-decoration: none; }
.card .media { position: relative; aspect-ratio: 3 / 4; background: var(--mist); overflow: hidden; }
.card .media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.card:hover .media img { transform: scale(1.03); }
.card .noimg { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; letter-spacing: .14em; color: #bbb; }
.badge { position: absolute; top: 10px; inset-inline-start: 10px; background: var(--ink); color: #fff; font-size: 12px; font-weight: 700; padding: 3px 9px; line-height: 1.5; }
.badge.note { inset-inline-start: auto; inset-inline-end: 10px; background: #fff; color: var(--ink); border: 1px solid var(--ink); border-radius: 50%; width: 24px; height: 24px; padding: 0; display: grid; place-items: center; font-family: var(--body); }
.badge.note.yellow, .noteico.yellow { background: #f5b700; color: #000; border-color: #f5b700; }
.badge.note.red, .noteico.red { background: var(--danger); color: #fff; border-color: var(--danger); }
.noteico { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font: 700 13px/1 var(--body); }
.card.out .media img { opacity: .45; filter: grayscale(1); }
.card .soldout { position: absolute; inset-inline: 0; bottom: 0; text-align: center; background: rgba(255, 255, 255, .92); font-weight: 500; font-size: 14px; padding: 7px; }
.card .meta { padding-top: 12px; }
.card .name { font-family: var(--body); font-weight: 500; font-size: 15px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prices { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; }
.prices b { font-weight: 700; }
.prices s { color: var(--mute); font-size: .92em; }
.dots { display: flex; align-items: center; gap: 6px; margin-top: 9px; min-height: 14px; }
.dots i { width: 14px; height: 14px; border-radius: 50%; border: 1px solid var(--line); box-shadow: 0 0 0 1px #fff inset; }
.dots i.off { opacity: .35; }
.dots span { font-size: 12px; color: var(--mute); }

.skeleton .media, .skeleton .l { background: linear-gradient(100deg, var(--mist) 30%, #fafafa 50%, var(--mist) 70%); background-size: 300% 100%; animation: shimmer 1.4s linear infinite; }
.skeleton .l { height: 12px; margin-top: 12px; width: 70%; }
.skeleton .l + .l { width: 35%; }
@keyframes shimmer { to { background-position: -100% 0; } }

.empty { text-align: center; padding: 60px 16px; color: var(--mute); }
.empty .btn { margin-top: 16px; }
.status { text-align: center; padding: 40px 16px; color: var(--mute); }
.status.error { color: var(--danger); }

/* ---------- footer ---------- */
.foot { background: var(--ink); color: #fff; margin-top: auto; }
.foot .wrap { display: grid; gap: 28px; padding-block: 44px 32px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .foot .wrap { grid-template-columns: 1.3fr 1fr 1fr; } }
.foot h3 { font-size: 15px; margin-bottom: 10px; color: #bdbdbd; font-family: var(--body); font-weight: 500; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.foot a { text-decoration: none; }
.foot a:hover { text-decoration: underline; text-underline-offset: 4px; }
.foot .big { font-family: var(--body); font-weight: 700; font-size: 30px; letter-spacing: .14em; direction: ltr; text-align: start; }
.foot .small { color: #9a9a9a; font-size: 13px; margin-top: 8px; }
.foot .legal { grid-column: 1 / -1; border-top: 1px solid #2a2a2a; padding-top: 18px; color: #8a8a8a; font-size: 13px; }

/* ---------- toast ---------- */
.toast { position: fixed; z-index: 60; inset-inline: 16px; inset-block-end: 22px; margin-inline: auto; width: fit-content; max-width: calc(100vw - 32px); background: var(--ink); color: #fff; padding: 13px 20px; display: flex; gap: 18px; align-items: center; opacity: 0; transform: translateY(16px); pointer-events: none; transition: opacity .25s, transform .25s var(--ease); }
.toast.show { opacity: 1; transform: none; pointer-events: auto; }
.toast a { font-weight: 700; text-underline-offset: 4px; white-space: nowrap; }
@media (max-width: 720px) { .toast { inset-block-end: 88px; } }

/* ---------- dialogs ---------- */
.modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, .55); opacity: 0; transition: opacity .25s; }
.modal.show { opacity: 1; }
.modal .box { position: relative; background: #fff; width: min(100%, 460px); max-height: calc(100vh - 32px); overflow: auto; padding: 32px 28px 26px; transform: translateY(14px); transition: transform .3s var(--ease); }
.modal.show .box { transform: none; }
.modal .box.wide { width: min(100%, 720px); }
.modal h2 { font-size: 22px; margin-bottom: 10px; }
.modal .body { color: #222; white-space: pre-line; }
.modal .x { position: absolute; top: 6px; inset-inline-end: 6px; width: 44px; height: 44px; background: none; border: 0; font-size: 26px; line-height: 1; }
.modal .acts { display: flex; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.modal .acts .btn { flex: 1; }
.modal img.guide { width: 100%; margin-top: 14px; }
.modal.warn .box { border-top: 5px solid var(--ink); }
.modal.warn.red .box { border-top-color: var(--danger); }

/* ---------- product page ---------- */
.crumbs { padding-block: 16px; font-size: 14px; color: var(--mute); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.pdp { display: grid; gap: 24px clamp(24px, 4vw, 64px); padding-bottom: clamp(36px, 5vw, 72px); }
@media (min-width: 900px) { .pdp { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; } .pdp .info { position: sticky; top: 90px; } }

.gallery { display: grid; gap: 10px; }
@media (min-width: 900px) { .gallery { grid-template-columns: 78px minmax(0, 1fr); } .gallery .thumbs { order: -1; } }
.stage { position: relative; }
.slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; background: var(--mist); aspect-ratio: 3 / 4; overscroll-behavior-x: contain; }
.slides::-webkit-scrollbar { display: none; }
.slides > div { flex: 0 0 100%; scroll-snap-align: center; position: relative; }
.slides img { width: 100%; height: 100%; object-fit: cover; cursor: zoom-in; }
.slides .noimg { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; letter-spacing: .14em; color: #bbb; }
.arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; background: rgba(255, 255, 255, .92); border: 1px solid var(--line); display: none; place-items: center; }
.arrow.prev { inset-inline-start: 10px; } .arrow.next { inset-inline-end: 10px; }
@media (min-width: 900px) { .stage:hover .arrow.on { display: grid; } }
.pager { position: absolute; inset-inline: 0; bottom: 12px; display: flex; justify-content: center; gap: 6px; pointer-events: none; }
.pager i { width: 7px; height: 7px; border-radius: 50%; background: rgba(255, 255, 255, .6); border: 1px solid rgba(0, 0, 0, .35); }
.pager i.on { background: var(--ink); border-color: var(--ink); }
@media (min-width: 900px) { .pager { display: none; } }
.thumbs { display: none; gap: 8px; }
.thumbs button { padding: 0; border: 1px solid transparent; background: var(--mist); aspect-ratio: 3 / 4; overflow: hidden; opacity: .6; }
.thumbs button[aria-current="true"] { border-color: var(--ink); opacity: 1; }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) { .thumbs { display: grid; align-content: start; } }

.info h1 { font-size: clamp(24px, 3.2vw, 34px); }
.info .cat { color: var(--mute); font-size: 14px; margin-bottom: 6px; }
.info .prices { margin-top: 12px; font-size: 22px; }
.info .prices s { font-size: 17px; }
.info .pct { font-size: 13px; background: var(--ink); color: #fff; padding: 1px 8px; font-weight: 700; }
.info .desc { margin-top: 18px; color: #222; white-space: pre-line; max-width: 60ch; }
.opt { margin-top: 24px; }
.opt .lab { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; font-weight: 500; }
.opt .lab span { color: var(--mute); font-weight: 400; }
.swatches, .sizes { display: flex; flex-wrap: wrap; gap: 10px; }
.sw { position: relative; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); padding: 0; background: var(--c); }
.sw::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid transparent; }
.sw[aria-pressed="true"]::after { border-color: var(--ink); }
.sz { min-width: 52px; min-height: 46px; padding: 0 14px; border: 1px solid var(--line); background: #fff; font-weight: 500; }
.sz:hover:not(:disabled) { border-color: var(--ink); }
.sz[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.sw:disabled, .sz:disabled { cursor: not-allowed; opacity: .35; }
.sz:disabled { text-decoration: line-through; background: var(--mist); }
.sw:disabled::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: linear-gradient(to top left, transparent calc(50% - 1px), #000 50%, transparent calc(50% + 1px)); }
.left { margin-top: 14px; font-weight: 500; }
.left.low { color: var(--danger); }
.buy { display: flex; gap: 12px; margin-top: 22px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); height: 52px; }
.qty button { width: 44px; height: 100%; background: none; border: 0; font-size: 20px; }
.qty button:disabled { opacity: .3; cursor: not-allowed; }
.qty output { min-width: 34px; text-align: center; font-weight: 500; }
.buy .btn { flex: 1; min-height: 52px; font-size: 16px; }
.hint { margin-top: 10px; color: var(--mute); font-size: 14px; min-height: 21px; }
.hint.error { color: var(--danger); }
.extras { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.extras .link { font-size: 15px; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; }
.related { border-top: 1px solid var(--line); padding-block: clamp(32px, 5vw, 64px); }
.related h2 { font-size: clamp(20px, 2.6vw, 28px); margin-bottom: 20px; }
.lightbox { background: rgba(0, 0, 0, .94); padding: 0; }
.lightbox img { max-width: 100vw; max-height: 100vh; object-fit: contain; }
.lightbox .x { color: #fff; }

@media (max-width: 899px) {
  body.pdp-page { padding-bottom: 0; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
