/* Gyren Store website. Clean neutral surfaces and product art first; the logo's raspberry
   is the one accent (main actions, the selected filter, the headline highlight). Logical properties (inline-start/end) keep Arabic right-to-left. */

:root {
  --bg: #f6f6f8;
  --surface: #ffffff;
  --surface-2: #f0f0f3;
  --border: #e6e6eb;
  --border-strong: #d3d3db;
  --text: #0f0f13;
  --muted: #686874;
  --accent: #e7145d;
  --accent-hover: #c90f50;
  --on-accent: #ffffff;
  --accent-soft: #fdebf2;
  --accent-text: #c50f4f;
  --success: #17703a;
  --success-soft: #e8f5ec;
  --warning: #8a5a00;
  --warning-soft: #fdf3dc;
  --danger: #b42318;
  --danger-soft: #fdecea;
  --info: #1f55c4;
  --info-soft: #eaf0fc;
  --star: #e8a317;
  --focus: 0 0 0 3px rgba(231, 20, 93, 0.25);
  --shadow: 0 1px 2px rgba(15, 15, 19, 0.04), 0 6px 18px -8px rgba(15, 15, 19, 0.10);
  --shadow-hover: 0 18px 36px -14px rgba(15, 15, 19, 0.28);
  --ring: 0 0 0 1px rgba(231, 20, 93, 0.35);
  --hero-1: #fff0f5;
  --hero-2: #f6f3ff;
  --highlight: linear-gradient(90deg, #e7145d, #ff7a59 55%, #b04dff);
  --radius: 16px;
  --radius-sm: 10px;
  --header-h: 64px;
  --gutter: 24px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #08080b;
    --surface: #121217;
    --surface-2: #1a1a21;
    --border: #22222a;
    --border-strong: #33333d;
    --text: #f5f5f7;
    --muted: #9b9ba7;
    --accent: #e7145d;  /* the logo's raspberry: white text on it passes AA */
    --accent-hover: #f0216a;
    --on-accent: #ffffff;
    --accent-soft: rgba(255, 43, 108, 0.12);
    --accent-text: #ff5a8c;
    --success: #6fd38f;
    --success-soft: #16291d;
    --warning: #e8b84f;
    --warning-soft: #2e2512;
    --danger: #ff8f84;
    --danger-soft: #34191a;
    --info: #8fb2ff;
    --info-soft: #182238;
    --focus: 0 0 0 3px rgba(255, 43, 108, 0.35);
    --shadow: none;
    --shadow-hover: 0 22px 44px -18px rgba(0, 0, 0, 0.9);
    --ring: 0 0 0 1px rgba(255, 43, 108, 0.55);
    --hero-1: #1a0a11;
    --hero-2: #0e0b1a;
    --highlight: linear-gradient(90deg, #ff2b6c, #ff7a59 55%, #b04dff);
    color-scheme: dark;
  }
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
        "Noto Sans Arabic", Tahoma, Arial, sans-serif;
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
  overflow-wrap: break-word;
  display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh;
}
main { flex: 1; }
img { max-width: 100%; display: block; }
a { color: var(--accent-text); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0; line-height: 1.25; letter-spacing: -0.01em; }
h1 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 700; }
h2 { font-size: 18px; font-weight: 650; }
h3 { font-size: 15px; font-weight: 600; }
p { margin: 0; }
code, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 6px; }
[hidden] { display: none !important; }

.icon { width: 18px; height: 18px; flex: none; vertical-align: -3px; }
.icon-sm { width: 15px; height: 15px; }
.icon-lg { width: 22px; height: 22px; }
html[dir="rtl"] .flip { transform: scaleX(-1); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; inset-inline-start: 12px; top: -48px; z-index: 50; }
.skip-link:focus { top: 12px; }

.muted { color: var(--muted); }
.small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.ltr { direction: ltr; unicode-bidi: isolate; white-space: nowrap; }
.break { overflow-wrap: anywhere; }
.stack > * + * { margin-top: 16px; }
.stack > input[type="hidden"] + :not(input) { margin-top: 0; }
.stack-sm > * + * { margin-top: 8px; }
.row { display: flex; align-items: center; gap: 12px; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }

/* ---------- Layout ---------- */

/* The side gutter also clears the iPhone's rounded corners and notch in landscape. */
.container { width: 100%; max-width: 1200px; margin: 0 auto;
             padding-left: max(var(--gutter), env(safe-area-inset-left));
             padding-right: max(var(--gutter), env(safe-area-inset-right)); }
.container.narrow { max-width: 680px; }
.container.medium { max-width: 960px; }
.page { padding: 28px 0 56px; }
@media (max-width: 640px) {
  :root { --gutter: 16px; }
  .page { padding: 18px 0 40px; }
}

/* ---------- Header ---------- */

.site-header {
  position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-row { display: flex; align-items: center; gap: 16px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 40px; color: var(--text); font-weight: 700;
         font-size: 17px; letter-spacing: -0.02em; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand img { width: 30px; height: 30px; border-radius: 8px; }
.header-search { flex: 1; max-width: 520px; margin-inline: auto; }
.header-actions { display: flex; align-items: center; gap: 6px; margin-inline-start: auto; }
.header-search + .header-actions { margin-inline-start: 0; }
.currency-menu { position: relative; }
.currency-menu > summary { list-style: none; display: inline-flex; align-items: center; gap: 4px; min-height: 36px;
                           padding: 0 10px 0 12px; border-radius: 999px; border: 1px solid var(--border-strong);
                           background: var(--surface); font-size: 13px; font-weight: 700; cursor: pointer; }
.currency-menu > summary::-webkit-details-marker { display: none; }
.currency-menu > summary .chev { width: 15px; height: 15px; color: var(--muted); transition: transform .15s; }
.currency-menu[open] > summary .chev { transform: rotate(180deg); }
.currency-menu > summary:focus-visible { box-shadow: var(--focus); outline: none; }
.currency-menu ul { position: absolute; top: calc(100% + 6px); inset-inline-end: 0; z-index: 30; min-width: 200px;
                    margin: 0; padding: 6px; list-style: none; background: var(--surface); border: 1px solid var(--border);
                    border-radius: var(--radius-sm); box-shadow: 0 12px 32px rgba(0, 0, 0, .14); }
.currency-menu a { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 0 10px;
                   border-radius: 8px; color: var(--text); font-size: 14px; }
.currency-menu a:hover { background: var(--surface-2); text-decoration: none; }
.currency-menu a b { min-width: 34px; }
.currency-menu a span { color: var(--muted); flex: 1; }
.currency-menu a .icon { width: 16px; height: 16px; color: var(--accent-text); }
.currency-menu a[aria-current] { background: var(--accent-soft); }
@media (max-width: 760px) {  /* the header wraps: open full width, just under the button */
  .currency-menu ul { position: fixed; top: auto; inset-inline: 16px; min-width: 0; margin-top: 6px; }
}
.summary-other { text-align: end; margin-top: 2px; }
@media (max-width: 760px) {
  .header-row { flex-wrap: wrap; gap: 10px; padding-block: 10px; min-height: 0; }
  .header-search { order: 3; flex-basis: 100%; max-width: none; }
  .hide-sm { display: none !important; }
}

.search { position: relative; display: block; }
.search .icon { position: absolute; inset-inline-start: 13px; top: 50%; transform: translateY(-50%);
                color: var(--muted); pointer-events: none; }
.search input {
  width: 100%; height: 42px; padding-block: 0; padding-inline: 40px 14px; font: inherit; font-size: 16px;
  color: var(--text); background: var(--surface-2); border: 1px solid transparent; border-radius: 999px;
  outline: none; -webkit-appearance: none; appearance: none;
}
.search input:focus { background: var(--surface); border-color: var(--accent); box-shadow: var(--focus); }
.search input::-webkit-search-cancel-button { -webkit-appearance: none; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px;
  padding: 0 18px; border: 1px solid transparent; border-radius: 12px; font: inherit;
  font-weight: 700; font-size: 15px; line-height: 1.2; text-align: center; cursor: pointer;
  background: var(--accent); color: var(--on-accent); white-space: nowrap;
  transition: background-color .15s, border-color .15s, color .15s, box-shadow .15s, transform .15s;
}
.btn:hover { background: var(--accent-hover); text-decoration: none; }
.btn-lg:not(.btn-secondary):not(.btn-ghost) { box-shadow: 0 10px 24px -12px var(--accent); }
@media (hover: hover) { .btn-lg:not(:disabled):hover { transform: translateY(-1px); } }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-secondary:hover { background: var(--surface-2); }
.btn-soft { background: var(--accent-soft); color: var(--accent-text); }
.btn-soft:hover { background: color-mix(in srgb, var(--accent-soft) 70%, var(--accent) 12%); }
.btn-ghost { background: transparent; color: var(--text); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-danger-ghost { background: transparent; color: var(--muted); }
.btn-danger-ghost:hover { background: var(--danger-soft); color: var(--danger); }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 14px; }
.btn-lg { min-height: 50px; font-size: 16px; padding: 0 22px; }
.btn-block { display: flex; width: 100%; }
.btn-pill { border-radius: 999px; }

/* ---------- Cards, sections ---------- */

.card { background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
        padding: 20px; box-shadow: var(--shadow); }
.card-tight { padding: 0; overflow: hidden; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; margin-bottom: 14px;
             flex-wrap: wrap; }
.card-head h2 { display: flex; align-items: center; gap: 8px; font-size: 16px; }
.card-head h2 .icon { color: var(--muted); }
.section { margin-top: 36px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.section-head h2 { font-size: 24px; font-weight: 800; letter-spacing: -0.02em; }
.section-head .count { color: var(--muted); font-weight: 600; font-size: 14px; margin-inline-start: 8px; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head > * { min-width: 0; }
/* Side-by-side buttons that stack when there's no room for both. */
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.actions > * { flex: 1 1 200px; }
.actions > form > .btn { width: 100%; }
@media (max-width: 640px) { .page-head { flex-direction: column; gap: 10px; } }
.page-head .lead { margin-top: 6px; }
.eyebrow { font-size: 13px; color: var(--muted); font-weight: 500; margin-bottom: 4px; }
.lead { color: var(--muted); font-size: 16px; }
.back-link { display: inline-flex; align-items: center; gap: 4px; min-height: 40px; color: var(--muted); font-size: 14px;
             font-weight: 500; margin: -8px 0 4px; }
.back-link:hover { color: var(--text); text-decoration: none; }

.breadcrumb { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px;
              color: var(--muted); margin-bottom: 18px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb .icon { width: 14px; height: 14px; }
.breadcrumb [aria-current] { color: var(--text); font-weight: 500; }

/* ---------- Alerts, badges ---------- */

.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-sm);
         font-size: 14px; background: var(--info-soft); color: var(--text); border: 1px solid transparent; }
.alert + .alert { margin-top: 8px; }
.alert .icon { margin-top: 1px; color: var(--info); }
.alert-success { background: var(--success-soft); }
.alert-success .icon { color: var(--success); }
.alert-error { background: var(--danger-soft); }
.alert-error .icon { color: var(--danger); }
.alert-warning { background: var(--warning-soft); }
.alert-warning .icon { color: var(--warning); }
.alerts { margin-bottom: 18px; }

.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px;
         font-size: 13px; font-weight: 600; line-height: 1.5; white-space: nowrap;
         background: var(--surface-2); color: var(--muted); }
.badge .icon { width: 14px; height: 14px; }
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-accent { background: var(--accent-soft); color: var(--accent-text); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }

/* ---------- Forms ---------- */

.field { display: block; }
.field + .field, .field + .alert, .alert + .field { margin-top: 16px; }
.label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--text); }
.hint { display: block; font-size: 13px; color: var(--muted); margin-top: 6px; }
.input, .select, .textarea {
  width: 100%; min-width: 0; max-width: 100%; font: inherit; font-size: 16px; color: var(--text); background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 11px 13px;
  outline: none; -webkit-appearance: none; appearance: none; transition: border-color .15s, box-shadow .15s;
}
.input:focus, .select:focus, .textarea:focus { border-color: var(--accent); box-shadow: var(--focus); }
.textarea { min-height: 120px; resize: vertical; }
.select { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
                            linear-gradient(135deg, var(--muted) 50%, transparent 50%);
          background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
          background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-inline-end: 36px; }
html[dir="rtl"] .select { background-position: 18px 50%, 13px 50%; }
.code-input { letter-spacing: .45em; text-align: center; font-size: 26px; font-weight: 700; }

/* Choices drawn as cards (delivery, payment, product options). */
.choices { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.choice {
  position: relative; display: flex; align-items: center; gap: 12px; padding: 13px 14px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface);
  cursor: pointer; transition: border-color .15s, background-color .15s, box-shadow .15s;
}
.choice:hover { border-color: var(--muted); }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice .dot { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--border-strong); flex: none;
               display: grid; place-items: center; }
.choice .dot::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: transparent; }
.choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent); }
.choice:has(input:checked) .dot { border-color: var(--accent); }
.choice:has(input:checked) .dot::after { background: var(--accent); }
.choice:has(input:focus-visible) { box-shadow: var(--focus); }
.choice:has(input:disabled) { opacity: .55; cursor: not-allowed; }
.choice-icon { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center;
               background: var(--surface-2); color: var(--text); flex: none; }
.choice-title { font-weight: 600; }
.choice-detail { display: block; font-size: 13px; color: var(--muted); }
.choice-end { margin-inline-start: auto; text-align: end; }
.choice-end b { display: block; }

.file {
  display: flex; align-items: center; gap: 12px; padding: 14px; border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-sm); cursor: pointer; background: var(--surface); color: var(--muted);
  transition: border-color .15s, background-color .15s;
}
.file:hover, .file:focus-within { border-color: var(--accent); background: var(--accent-soft); color: var(--text); }
.file input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.file .choice-icon { background: var(--surface-2); }
.file.has-file { border-style: solid; color: var(--text); }

/* ---------- Store: intro, categories, product grid ---------- */

.showcase { position: relative; overflow: hidden; display: grid; grid-template-columns: 1.15fr 1fr; gap: 32px;
            align-items: center; min-height: 340px; padding: 48px 52px; margin-bottom: 18px; border-radius: 24px;
            border: 1px solid var(--border); background: linear-gradient(120deg, var(--hero-1), var(--hero-2)); }
.showcase::before { content: ""; position: absolute; inset-inline-end: -10%; bottom: -60%; width: 520px; height: 520px;
                    border-radius: 50%; pointer-events: none;
                    background: radial-gradient(circle, color-mix(in srgb, var(--accent) 28%, transparent), transparent 65%); }
.showcase-copy { position: relative; min-width: 0; }
.kicker { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 18px; padding: 5px 12px; border-radius: 999px;
          background: var(--accent-soft); color: var(--accent-text); font-size: 13px; font-weight: 600; }
.kicker i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent);
            box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 25%, transparent); }
.showcase h1 { font-size: clamp(30px, 4.2vw, 50px); line-height: 1.08; letter-spacing: -0.035em; font-weight: 800; }
.accent-text { background: var(--highlight); -webkit-background-clip: text; background-clip: text; color: transparent; }
.showcase .lead { margin-top: 14px; font-size: 17px; max-width: 470px; }
.showcase .cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.showcase .cta .btn { min-height: 50px; padding: 0 24px; border-radius: 14px; font-size: 16px; }
.paywith { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; margin-top: 26px; color: var(--muted); font-size: 13px; }
.paywith .logos { display: flex; gap: 8px; }
.paywith img { width: 30px; height: 30px; padding: 4px; border-radius: 9px; border: 1px solid var(--border);
               background: var(--surface); object-fit: contain; }
/* The top three covers, fanned out; they spread a little on hover. */
.covers { position: relative; height: 290px; }
.cover { position: absolute; width: 62%; aspect-ratio: 16 / 10; border-radius: 18px; background: var(--surface-2) center / cover;
         box-shadow: 0 30px 60px -24px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .06); transition: transform .4s; }
.covers { --dir: 1; }
html[dir="rtl"] .covers { --dir: -1; }  /* mirrored in Arabic */
.cover.c1 { top: 8%; inset-inline-start: 2%; transform: rotate(calc(-7deg * var(--dir))); }
.cover.c2 { top: 26%; inset-inline-end: 0; transform: rotate(calc(6deg * var(--dir))); }
.cover.c3 { top: 0; inset-inline-start: 22%; width: 66%; z-index: 1;
            transform: rotate(calc(-1deg * var(--dir))) translateY(30px); }
@media (hover: hover) {
  .showcase:hover .cover.c1 { transform: rotate(calc(-9deg * var(--dir))) translateX(calc(-6px * var(--dir))); }
  .showcase:hover .cover.c2 { transform: rotate(calc(8deg * var(--dir))) translateX(calc(6px * var(--dir))); }
}

.features { list-style: none; margin: 0 0 40px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.feature { display: flex; gap: 12px; align-items: center; padding: 16px 18px; background: var(--surface);
           border: 1px solid var(--border); border-radius: 16px; }
.feature .choice-icon { width: 40px; height: 40px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-text); }
.feature b { display: block; font-size: 14px; }
.feature div span { display: block; font-size: 13px; color: var(--muted); }
@media (max-width: 860px) {
  .showcase { grid-template-columns: minmax(0, 1fr); gap: 6px; min-height: 0; padding: 28px 22px 0; border-radius: 20px; }
  .showcase .cta .btn { flex: 1; }
  .covers { height: 190px; }
  .features { grid-template-columns: minmax(0, 1fr); gap: 8px; margin-bottom: 28px; }
  .feature { padding: 12px 14px; }
}
@media (prefers-reduced-motion: reduce) { .cover, .btn { transition: none; } }

.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px; margin: -2px; }
.chips::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border-radius: 999px;
        border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: 14px;
        font-weight: 600; white-space: nowrap; }
.chip:hover { border-color: var(--border-strong); text-decoration: none; }
.chip[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent);
                            box-shadow: 0 8px 20px -10px var(--accent); }

.product-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px 18px;
                grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
@media (max-width: 480px) { .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; } }
/* The cover is the card: no box around it, the name and price underneath. */
.product-card .media { border-radius: 18px; box-shadow: var(--shadow); transition: transform .25s, box-shadow .25s; }
.product-card .media img { transition: transform .45s; }
@media (hover: hover) {
  .product-card:hover .media { transform: translateY(-4px); box-shadow: var(--shadow-hover), var(--ring); }
  .product-card:hover .media img { transform: scale(1.06); }
  .product-card:hover .product-name { color: var(--accent-text); }
}
.product-card:active .media { transform: scale(.985); }
.product-card a { display: flex; flex-direction: column; height: 100%; color: inherit; }
.product-card a:hover { text-decoration: none; }
.media { position: relative; aspect-ratio: 16 / 10.5; background: var(--surface-2); display: grid;
         place-items: center; overflow: hidden; }
.media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 14%; }
.media img.is-wide { object-fit: cover; padding: 0; }
.media .initials { font-size: 28px; font-weight: 700; color: var(--accent-text); letter-spacing: -0.02em; }
.media .badge { position: absolute; top: 10px; inset-inline-start: 10px; z-index: 1; font-size: 12px; font-weight: 700;
                padding: 2px 9px; background: rgba(0, 0, 0, .6); color: #fff; }
.media .badge-accent { background: var(--accent); color: var(--on-accent); }
.product-body { padding: 12px 4px 0; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.product-name { font-size: 15.5px; font-weight: 700; transition: color .15s; display: -webkit-box; -webkit-line-clamp: 2;
                -webkit-box-orient: vertical; overflow: hidden; }
.product-meta { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.price { font-weight: 800; font-size: 16px; }
.price .from { font-weight: 400; color: var(--muted); font-size: 13px; margin-inline-end: 3px; }
.rating { display: inline-flex; align-items: center; gap: 3px; font-size: 13px; color: var(--muted); }
.rating .icon, .stars .icon { width: 14px; height: 14px; color: var(--star); fill: var(--star); }
.stars { display: inline-flex; gap: 1px; }
.stars .icon.off { fill: none; color: var(--border-strong); }
.is-sold-out .media img, .is-sold-out .media .initials { opacity: .45; }

.callout { display: flex; align-items: center; gap: 18px; margin-top: 40px; padding: 26px 28px; border-radius: 20px;
           border: 1px solid transparent;
           background: linear-gradient(var(--surface), var(--surface)) padding-box,
                       linear-gradient(120deg, color-mix(in srgb, var(--accent) 60%, transparent), transparent 40%,
                                       color-mix(in srgb, #b04dff 50%, transparent)) border-box; }
.callout .choice-icon { width: 46px; height: 46px; background: var(--accent-soft); color: var(--accent-text); }
.callout p { color: var(--muted); margin-top: 2px; }
@media (max-width: 640px) { .callout { flex-direction: column; align-items: flex-start; } .callout .btn { width: 100%; } }

.empty { text-align: center; padding: 48px 20px; color: var(--muted); }
.empty .choice-icon { margin: 0 auto 12px; width: 48px; height: 48px; border-radius: 50%; }
.empty h2 { color: var(--text); margin-bottom: 6px; }
.empty .btn { margin-top: 16px; }

/* ---------- Product page ---------- */

.product-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.product-layout .media { border-radius: var(--radius); border: 1px solid var(--border); }
.product-layout .media img { padding: 18%; }
.product-layout .media img.is-wide { padding: 0; }
.product-info h1 { margin-bottom: 8px; }
.product-stats { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; color: var(--muted); font-size: 14px; }
.facts { list-style: none; margin: 18px 0 0; padding: 16px 0 0; border-top: 1px solid var(--border); display: grid; gap: 10px; }
.facts li { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.facts .icon { color: var(--muted); margin-top: 1px; }
.prose { white-space: pre-line; color: var(--text); }
.review + .review { border-top: 1px solid var(--border); padding-top: 14px; margin-top: 14px; }
.review-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; }
.review p { margin-top: 6px; }
.reply { margin-top: 8px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 14px; }
@media (max-width: 860px) { .product-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; } }

/* Rating an order: five radio buttons drawn as stars, filled up to the chosen one. */
.rate-form { display: grid; gap: 14px; }
.star-field { border: 0; margin: 0; padding: 0; min-width: 0; }
.star-field legend { padding: 0; margin-bottom: 6px; }
.star-picker { display: flex; gap: 2px; }
.star-picker label { display: grid; place-items: center; width: 44px; height: 44px; border-radius: var(--radius-sm);
                     cursor: pointer; color: var(--border-strong); transition: color .1s, transform .1s; }
.star-picker .icon { width: 32px; height: 32px; fill: currentColor; }
.star-picker:has(input:checked) label { color: var(--star); }
.star-picker input:checked ~ input + label { color: var(--border-strong); }
.star-picker input:focus-visible + label { box-shadow: var(--focus); }
.star-picker label:active { transform: scale(.9); }
@media (hover: hover) {
  .star-picker:has(label:hover) input + label { color: var(--star); }
  .star-picker:has(label:hover) label:hover ~ input + label { color: var(--border-strong); }
}
.low-note { display: none; margin-top: 6px; }
.star-field:has(input[value="1"]:checked, input[value="2"]:checked, input[value="3"]:checked) .low-note { display: block; }
.rate-form .btn { justify-self: start; }
@media (max-width: 480px) { .rate-form .btn { justify-self: stretch; } }
.rate-hint { display: inline-flex; align-items: center; gap: 3px; color: var(--accent-text); font-weight: 600; }
.rate-hint .icon { fill: currentColor; }
.rate-reward { display: flex; gap: 8px; align-items: center; margin: 10px 0 16px; color: var(--accent-text); font-size: 14px; }
.card > .muted + .rate-form { margin-top: 14px; }
.stars-lg .icon { width: 22px; height: 22px; }
.my-review p { margin-top: 8px; }
.rate-change { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); }
.rate-change > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; min-height: 40px;
                         font-weight: 600; color: var(--accent-text); }
.rate-change > summary::-webkit-details-marker { display: none; }
.rate-change > summary .chev { margin-inline-start: auto; color: var(--muted); transition: transform .15s; }
.rate-change[open] > summary .chev { transform: rotate(180deg); }
.rate-change[open] > .muted { margin: 4px 0 12px; }

/* ---------- Checkout ---------- */

.checkout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.summary { position: sticky; top: calc(var(--header-h) + 16px); }
.summary-item { display: flex; gap: 12px; align-items: center; }
.summary-item .media { width: 72px; flex: none; border-radius: var(--radius-sm); aspect-ratio: 1; }
.summary-item .media img { padding: 12%; }
.networks { display: none; margin: 4px 0 2px; padding: 0; padding-inline-start: 48px; border: 0; min-width: 0; }
.networks legend { padding: 0; margin-bottom: 8px; }
.choices:has(input[value="crypto"]:checked) .networks { display: block; }
@media (max-width: 480px) { .networks { padding-inline-start: 0; } }
.network-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); gap: 8px; }
.choice.network { padding: 10px 12px; gap: 10px; }

/* Payment logos (SuperQi, Binance, coins) in place of line icons. */
.choice-icon.logo { background: none; }
.choice-icon.logo img { display: block; width: 32px; height: 32px; object-fit: contain; }
.coin-pile { position: relative; }
.coin-pile img { position: absolute; border-radius: 50%; box-shadow: 0 0 0 2px var(--surface); }
.choice-icon.coin-pile img { width: 22px; height: 22px; }
.coin-pile.n2 img:nth-child(1) { top: 1px; left: 1px; }
.coin-pile.n2 img:nth-child(2) { top: 13px; left: 13px; }
.coin-pile.n3 img:nth-child(1) { top: 0; left: 7px; }
.coin-pile.n3 img:nth-child(2) { top: 14px; left: 0; }
.coin-pile.n3 img:nth-child(3) { top: 14px; left: 14px; }
.coin { position: relative; width: 28px; height: 28px; flex: none; }
.coin img { display: block; width: 28px; height: 28px; }
.coin .coin-chain { position: absolute; width: 14px; height: 14px; inset-inline-end: -3px; bottom: -3px;
                    border-radius: 50%; box-shadow: 0 0 0 2px var(--surface); }
.pay-method { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.summary-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 16px;
                 padding-top: 14px; border-top: 1px solid var(--border); font-weight: 600; }
.summary-total .amount { font-size: 22px; }
@media (max-width: 900px) { .checkout { grid-template-columns: minmax(0, 1fr); } .summary { position: static; order: -1; } }

/* ---------- Orders ---------- */

.amount { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; direction: ltr; unicode-bidi: isolate; }
.stepper { list-style: none; margin: 0 0 22px; padding: 0; display: flex; }
.step { flex: 1; position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px;
        font-size: 13px; color: var(--muted); text-align: center; }
.step::before { content: ""; position: absolute; top: 14px; inset-inline-end: 50%; width: 100%; height: 2px; background: var(--border); }
.step:first-child::before { display: none; }
.step .dot { position: relative; z-index: 1; width: 30px; height: 30px; border-radius: 50%; display: grid;
             place-items: center; background: var(--surface); border: 2px solid var(--border-strong); color: var(--muted); }
.step .dot .icon { width: 15px; height: 15px; }
.step.done::before, .step.current::before { background: var(--accent); }
.step.done .dot { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.step.current .dot { border-color: var(--accent); color: var(--accent-text); box-shadow: var(--focus); }
.step.done, .step.current { color: var(--text); font-weight: 600; }

.pay-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: start; }
@media (max-width: 640px) { .pay-grid { grid-template-columns: 1fr; } }
.qr { width: 180px; border-radius: var(--radius-sm); background: #fff; padding: 6px; border: 1px solid var(--border); }
@media (max-width: 640px) { .qr { margin: 4px auto 0; } }
.copy-field { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding: 6px 6px 6px 14px;
              border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface-2); }
html[dir="rtl"] .copy-field { padding: 6px 14px 6px 6px; }
.copy-field code { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 15px; direction: ltr; text-align: start; }
.payload { white-space: pre-wrap; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 14px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }

/* Lists of orders, requests and conversations. */
.list { list-style: none; margin: 0; padding: 0; }
.list-row { display: flex; align-items: center; gap: 12px; padding: 13px 0; color: var(--text); }
.list li + li .list-row, .list > .list-row + .list-row { border-top: 1px solid var(--border); }
a.list-row:hover { text-decoration: none; }
a.list-row:hover .list-title { color: var(--accent-text); }
.list-title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-sub { font-size: 13px; color: var(--muted); }
.list-row > .icon { color: var(--muted); }
.list-empty { color: var(--muted); font-size: 14px; padding: 4px 0; }

.account { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; align-items: start; }
@media (max-width: 900px) { .account { grid-template-columns: minmax(0, 1fr); } }

details.card > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px; font-weight: 600;
                         min-height: 44px; margin-block: -10px; }
details.card > summary::-webkit-details-marker { display: none; }
details.card > summary .chev { margin-inline-start: auto; color: var(--muted); transition: transform .15s; }
details.card[open] > summary .chev { transform: rotate(180deg); }
details.card[open] > summary { margin-bottom: 16px; }

/* ---------- Conversations ---------- */

.thread { display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 82%; padding: 10px 14px; border-radius: 16px; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg-mine { align-self: flex-end; background: var(--accent-soft); border-end-end-radius: 6px; }
.msg-theirs { align-self: flex-start; background: var(--surface); border: 1px solid var(--border); border-end-start-radius: 6px; }
.msg-author { display: block; font-size: 13px; font-weight: 600; margin-bottom: 2px; }
/* Each message's own direction (an English reply on an Arabic page, and the other way). */
.msg-text { display: block; text-align: start; }
.msg-text a { overflow-wrap: anywhere; }
.msg-meta { display: block; font-size: 12px; color: var(--muted); margin-top: 4px; }
.attachment { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; max-width: 100%; }
.attachment span { min-width: 0; overflow-wrap: anywhere; }

/* ---------- Sign-in, small centred pages ---------- */

.auth { max-width: 420px; margin: 24px auto 0; }
.auth .card { padding: 28px; }
.auth-icon { width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
             background: var(--accent-soft); color: var(--accent-text); margin-bottom: 16px; }
.auth h1 { font-size: 24px; }
.auth .lead { font-size: 15px; margin-top: 6px; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; counter-reset: step; }
.steps li { display: flex; gap: 12px; font-size: 14px; counter-increment: step; }
.steps li::before { content: counter(step); flex: none; width: 26px; height: 26px; border-radius: 50%;
                    display: grid; place-items: center; font-size: 13px; font-weight: 700;
                    background: var(--accent-soft); color: var(--accent-text); }
.steps b { display: block; }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--border); background: var(--surface); font-size: 14px; }
.footer-row { display: flex; gap: 32px; justify-content: space-between; flex-wrap: wrap; padding-top: 32px; padding-bottom: 24px; }
.footer-brand { max-width: 320px; }
.footer-brand p { margin-top: 10px; color: var(--muted); }
.footer-col h2 { font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 10px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; }
.footer-col a { color: var(--text); display: inline-flex; align-items: center; gap: 8px; min-height: 40px; }
.footer-col a[aria-current] { font-weight: 600; }
.footer-col .icon { color: var(--muted); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 16px; padding-bottom: 24px; color: var(--muted); font-size: 13px; }

/* ---------- Touch screens ---------- */

@media (pointer: coarse) {
  .btn-sm { min-height: 40px; }
  .chip { height: 40px; }
  .btn:active { filter: brightness(.94); }
  .choice:active, .file:active { background: var(--surface-2); }
}
@media (max-width: 760px) {
  .search input { height: 40px; }
  h1 { overflow-wrap: anywhere; }
}

/* Narrow phones: amounts under the payment name, list badges under the title. */
.show-narrow { display: none; }
@media (max-width: 420px) {
  .hide-narrow { display: none !important; }
  .show-narrow { display: block; }
  .choice-amount { font-weight: 600; color: var(--text); }
}
@media (max-width: 480px) {
  .list-row { flex-wrap: wrap; row-gap: 6px; }
  .list-row > .grow { flex-basis: 100%; }
  .list-row > .icon:last-child { margin-inline-start: auto; }
  .list-title { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
}

/* Wallet */
.wrap-chips { flex-wrap: wrap; overflow: visible; }
.inline-form { display: flex; gap: 8px; align-items: stretch; }
.inline-form .btn { flex: none; }
.money-in { color: var(--success); }
.list-row > .choice-icon { width: 34px; height: 34px; }
.history .list-row { flex-wrap: nowrap; align-items: flex-start; }
.history .list-row > b { margin-top: 2px; }
.history .list-row > .grow { flex-basis: auto; min-width: 0; }
.invite-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.invite-stats .list-sub { display: flex; align-items: center; gap: 5px; }
.invite-stats .amount { font-size: 24px; margin-top: 2px; }
.steps-list { margin: 0; padding-inline-start: 20px; display: grid; gap: 8px; font-size: 14px; color: var(--muted); }
.steps-list li::marker { color: var(--accent-text); font-weight: 700; }
.invite-card .choice-icon { background: var(--accent-soft); color: var(--accent-text); }
.entry-message { display: flex; gap: 6px; align-items: flex-start; margin-top: 6px; padding: 7px 10px;
                 border-radius: var(--radius-sm); background: var(--surface-2); font-size: 13px; overflow-wrap: anywhere; }
.entry-message .icon { flex: none; margin-top: 2px; color: var(--muted); }

/* ---------- Cart ---------- */

.cart-link { position: relative; padding-inline: 10px; }
.cart-count { position: absolute; top: 1px; inset-inline-end: 0; min-width: 18px; height: 18px; padding: 0 5px;
              border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 11px;
              font-weight: 800; line-height: 18px; text-align: center; box-shadow: 0 0 0 2px var(--surface); }
.buy-row { display: flex; gap: 10px; margin-top: 16px; }
@media (max-width: 480px) { .buy-row { flex-direction: column; } }

/* "Add 1 more item to get 10% off": a bar that fills as the cart grows. */
.unlock { padding: 14px 16px; border-radius: var(--radius); background: var(--accent-soft); color: var(--accent-text); }
.unlock .icon { flex: none; }
.unlock.is-on { display: flex; align-items: center; gap: 10px; background: var(--success-soft); color: var(--success); }
.meter { height: 8px; margin-top: 10px; border-radius: 999px; background: var(--surface); overflow: hidden; }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--accent); transition: width .3s; }

.cart-lines { padding-block: 4px; }
.cart-line { display: flex; align-items: center; gap: 14px; padding: 14px 0; }
.cart-line + .cart-line { border-top: 1px solid var(--border); }
.cart-line .media { width: 64px; flex: none; aspect-ratio: 1; border-radius: var(--radius-sm); }
.cart-line .media img { padding: 12%; }
.cart-line.is-out .media, .cart-line.is-out .cart-about > :not(.badge) { opacity: .5; }
.cart-about { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; }
.cart-name { color: var(--text); font-weight: 600; }
.cart-qty { display: flex; align-items: center; gap: 4px; padding: 3px; border: 1px solid var(--border-strong);
            border-radius: 999px; }
.cart-line.is-out .cart-qty { border: 0; padding: 0; }
.qty-btn { display: grid; place-items: center; width: 30px; height: 30px; border: 0; border-radius: 50%;
           background: transparent; color: var(--text); cursor: pointer; }
.qty-btn:hover:not(:disabled) { background: var(--surface-2); }
.qty-btn:disabled { opacity: .35; cursor: default; }
.qty-btn .icon { width: 16px; height: 16px; }
.qty { min-width: 18px; text-align: center; font-weight: 700; }
.cart-price { display: flex; flex-direction: column; align-items: flex-end; min-width: 104px; text-align: end;
              white-space: nowrap; }
@media (max-width: 560px) {
  .cart-line { flex-wrap: wrap; }
  .cart-about { flex-basis: calc(100% - 78px); }
  .cart-qty { margin-inline-start: 78px; }
  .cart-price { margin-inline-start: auto; }
}
.summary-line { display: flex; justify-content: space-between; gap: 12px; margin-top: 6px; font-size: 14px; }
.summary-line.is-saving { color: var(--success); font-weight: 600; }
.summary-items { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.summary-items .media { width: 52px; position: relative; overflow: visible; }
.qty-pill { position: absolute; top: -6px; inset-inline-end: -6px; padding: 0 6px; border-radius: 999px;
            background: var(--text); color: var(--surface); font-size: 11px; font-weight: 800; line-height: 18px; }
.empty-state { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 40px 20px; text-align: center; }
.empty-icon { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%;
              background: var(--accent-soft); color: var(--accent-text); }
.empty-icon .icon { width: 30px; height: 30px; }
@media (max-width: 900px) { .cart-page .summary { order: 0; } }

/* My orders: numbered pages */
.pager { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 4px; }
.pager .btn { min-width: 40px; justify-content: center; }
