/* =========================================================
   YIZEN — storefront styles
   Light theme, one bright accent. Uses CSS logical properties
   (inline-start / inline-end) so dir="rtl" mirrors everything.
   ========================================================= */
:root {
  --accent: #F0641E;
  --accent-600: #D9530F;
  --accent-50: #FFF3EC;
  --accent-100: #FFE3D3;
  --ink: #14161F;
  --ink-2: #474C59;
  --muted: #8A8F9C;
  --line: #ECEDF1;
  --bg: #F6F7F9;
  --card: #FFFFFF;
  --surface: #FFFFFF;
  --surface-2: #FCFCFD;
  --hover: #FAFAFB;
  --img-bg: #F6F7F9;
  --border-strong: #D3D5DC;
  --danger-bg: #FFF5F5;
  --danger-line: #FBD5D6;
  --success-bg: #E8F7EE;
  --glass: rgba(255, 255, 255, .96);
  --glass-bg: rgba(246, 247, 249, .9);
  --inv: #14161F;      /* "inverse" chips, toasts, dark buttons */
  --on-inv: #FFFFFF;
  --green: #16A34A;
  --red: #E5484D;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(20, 22, 31, .05);
  --shadow: 0 2px 6px rgba(20, 22, 31, .04), 0 8px 24px rgba(20, 22, 31, .06);
  --shadow-lg: 0 6px 16px rgba(20, 22, 31, .06), 0 18px 40px rgba(20, 22, 31, .12);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --head-h: 0px;
}
html[lang="ar"] { --font: 'Cairo', 'Tajawal', system-ui, sans-serif; }

/* ---------- dark mode (toggled with the moon button; light is the default) ---------- */
html[data-theme="dark"] {
  color-scheme: dark;
  --accent-50: rgba(240, 100, 30, .14);
  --accent-100: rgba(240, 100, 30, .24);
  --ink: #ECEEF3;
  --ink-2: #B3B8C4;
  --muted: #7F8595;
  --line: #262A35;
  --bg: #0D0F14;
  --card: #161922;
  --surface: #161922;
  --surface-2: #1A1D27;
  --hover: #1C2029;
  --img-bg: #1E222C;
  --border-strong: #3A3F4C;
  --danger-bg: rgba(229, 72, 77, .12);
  --danger-line: rgba(229, 72, 77, .35);
  --success-bg: rgba(22, 163, 74, .16);
  --glass: rgba(22, 25, 34, .94);
  --glass-bg: rgba(13, 15, 20, .88);
  --inv: #ECEEF3;
  --on-inv: #14161F;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow: 0 2px 6px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
  --shadow-lg: 0 6px 16px rgba(0, 0, 0, .35), 0 18px 40px rgba(0, 0, 0, .5);
}
html { transition: background-color .3s; }
body, .sticky-head, .topbar, .footer, .card, .perk, .cat-card, .pinfo, .summary, .panel { transition: background-color .3s, border-color .3s, color .3s; }
html[data-theme="dark"] .card-img img { mix-blend-mode: normal; }
html[data-theme="dark"] .card:hover { border-color: var(--line); }
html[data-theme="dark"] .pay-logo.cod { background: var(--surface); }
html[data-theme="dark"] .status { filter: saturate(1.1); }
.theme-btn { width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--bg); color: var(--ink-2); transition: background .2s, color .2s, transform .3s var(--ease); }
.theme-btn:hover { color: var(--accent); transform: rotate(-20deg); }
.theme-btn .i { width: 16px; height: 16px; }
.seg button .i { width: 14px; height: 14px; vertical-align: -2px; }

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg);
  font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased;
  overflow-x: clip; /* never scroll sideways (clip keeps position:sticky working) */
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; letter-spacing: -.01em; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3 { letter-spacing: 0; }
.i { width: 20px; height: 20px; flex: none; }
[dir="rtl"] .flip { transform: scaleX(-1); }
.container { width: 100%; max-width: 1280px; margin-inline: auto; padding-inline: 20px; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding-inline: 20px; border-radius: var(--radius-sm);
  background: var(--accent); color: #fff; font-weight: 600; white-space: nowrap;
  transition: background .2s, transform .15s, box-shadow .2s;
}
.btn:hover { background: var(--accent-600); box-shadow: 0 6px 16px rgba(240, 100, 30, .28); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .55; pointer-events: none; }
.btn-lg { height: 52px; padding-inline: 28px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-soft { background: var(--accent-50); color: var(--accent-600); }
.btn-soft:hover { background: var(--accent-100); box-shadow: none; }
.btn-ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { background: var(--bg); box-shadow: none; }
.btn-dark { background: var(--inv); color: var(--on-inv); }
.btn-dark:hover { background: var(--inv); filter: brightness(1.15); box-shadow: 0 6px 16px rgba(0, 0, 0, .2); }
.icon-btn {
  width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center;
  transition: background .2s, color .2s;
}
.icon-btn:hover { background: var(--bg); }

/* ---------- top bar ---------- */
.topbar { background: var(--surface); border-bottom: 1px solid var(--line); font-size: 13px; color: var(--ink-2); }
.topbar .container { display: flex; align-items: center; justify-content: space-between; height: 40px; gap: 16px; }
.topbar .info { display: flex; gap: 22px; align-items: center; }
.topbar .info a, .topbar .info span { display: inline-flex; align-items: center; gap: 6px; }
.topbar .info .i { width: 15px; height: 15px; color: var(--accent); }
.topbar .info a:hover { color: var(--accent); }
.topbar .switches { display: flex; gap: 10px; align-items: center; }
.signin-btn { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line); font-size: 12px; font-weight: 600; color: var(--ink-2); white-space: nowrap; transition: color .2s, border-color .2s; }
.signin-btn:hover { color: var(--accent); border-color: var(--accent); }
.signin-btn .i { width: 13px; height: 13px; }
.seg { display: inline-flex; background: var(--bg); border-radius: 999px; padding: 3px; }
.seg button { padding: 3px 11px; border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--ink-2); transition: all .2s; }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.seg button:not(.on):hover { color: var(--accent); }

/* ---------- header ---------- */
.sticky-head { position: sticky; top: 0; z-index: 50; background: var(--surface); box-shadow: 0 1px 0 var(--line); transition: box-shadow .2s; }
.sticky-head.scrolled { box-shadow: 0 6px 24px rgba(20, 22, 31, .06); }
.header .container { display: flex; align-items: center; gap: 18px; height: 76px; }
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); flex: none; }
.logo-text { display: flex; flex-direction: column; line-height: 1; }
.logo-text b { font-family: 'Inter', sans-serif; font-size: 24px; font-weight: 800; letter-spacing: .04em; }
.logo-text small { font-size: 10px; font-weight: 600; letter-spacing: .18em; color: var(--muted); margin-top: 4px; text-transform: uppercase; }
html[lang="ar"] .logo-text small { letter-spacing: 0; font-size: 11px; }
.catalog-btn { height: 48px; padding-inline: 22px; font-size: 15px; }
.catalog-btn .i-x { display: none; }
.catalog-btn.open .i-grid { display: none; }
.catalog-btn.open .i-x { display: block; }
.search { position: relative; flex: 1; min-width: 0; }
.search form { display: flex; align-items: center; height: 48px; background: var(--bg); border: 1.5px solid transparent; border-radius: var(--radius-sm); transition: border-color .2s, background .2s; }
.search form:focus-within { border-color: var(--accent); background: var(--surface); }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; padding-inline: 16px; height: 100%; }
.search button[type="submit"] { height: 40px; width: 52px; margin-inline-end: 4px; border-radius: 10px; background: var(--accent); color: #fff; display: grid; place-items: center; transition: background .2s; }
.search button[type="submit"]:hover { background: var(--accent-600); }
.suggest {
  position: absolute; inset-inline: 0; top: calc(100% + 8px); background: var(--surface); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); padding: 8px; z-index: 60; animation: pop .18s var(--ease);
}
.suggest a { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 10px; }
.suggest a:hover, .suggest a.hl { background: var(--bg); }
.suggest .thumb { width: 44px; height: 44px; border-radius: 10px; background: var(--bg); display: grid; place-items: center; overflow: hidden; flex: none; }
.suggest .thumb svg, .suggest .thumb img { width: 100%; height: 100%; object-fit: contain; }
.suggest .s-name { flex: 1; min-width: 0; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.suggest .s-price { font-weight: 700; }
.suggest .all { justify-content: center; color: var(--accent); font-weight: 600; }
.suggest .none { padding: 16px; text-align: center; color: var(--muted); }
.head-icons { display: flex; gap: 4px; flex: none; }
.head-icon { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 10px; border-radius: var(--radius-sm); font-size: 12px; color: var(--ink-2); transition: color .2s, background .2s; }
.head-icon .i { width: 24px; height: 24px; color: var(--ink); transition: color .2s; }
.head-icon:hover, .head-icon:hover .i { color: var(--accent); }
.badge {
  position: absolute; top: 0; inset-inline-end: 6px; min-width: 19px; height: 19px; padding-inline: 5px;
  border-radius: 999px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700;
  display: grid; place-items: center; border: 2px solid var(--surface); line-height: 1;
}
.badge[hidden] { display: none; }
.badge.bump { animation: bump .45s var(--ease); }

/* category menu */
.catmenu { border-top: 1px solid var(--line); }
.catmenu .container { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; height: 50px; align-items: center; }
.catmenu .container::-webkit-scrollbar { display: none; }
.catmenu a { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; font-weight: 500; font-size: 14px; color: var(--ink-2); white-space: nowrap; transition: all .2s; }
.catmenu a .i { width: 18px; height: 18px; }
.catmenu a:hover { color: var(--accent); background: var(--accent-50); }
.catmenu a.on { color: var(--accent-600); background: var(--accent-50); }

/* mega catalog menu */
.mega { position: absolute; inset-inline: 0; top: 100%; background: var(--surface); border-top: 1px solid var(--line); box-shadow: var(--shadow-lg); animation: drop .22s var(--ease); }
.mega .container { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding-block: 24px; }
.mega a { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: var(--radius); transition: background .2s; }
.mega a:hover { background: var(--bg); }
.mega .ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--accent-50); color: var(--accent); flex: none; }
.mega .ic .i { width: 24px; height: 24px; }
.mega b { display: block; font-weight: 600; }
.mega small { color: var(--muted); }
.backdrop { position: fixed; inset: 0; background: rgba(20, 22, 31, .35); z-index: 40; animation: fade .2s; }
.backdrop.over { z-index: 90; }

/* ---------- view & sections ---------- */
.view { padding-block: 24px 56px; min-height: 60vh; }
.view.enter { animation: fadeUp .4s var(--ease); }
.section { margin-top: 44px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.section-head h2 { font-size: 24px; font-weight: 700; }
.link-more { display: inline-flex; align-items: center; gap: 4px; color: var(--accent); font-weight: 600; font-size: 14px; }
.link-more .i { width: 16px; height: 16px; transition: transform .2s; }
.link-more:hover .i { transform: translateX(3px); }
[dir="rtl"] .link-more:hover .i { transform: scaleX(-1) translateX(3px); }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; color: var(--muted); margin-bottom: 14px; }
.crumbs a:hover { color: var(--accent); }
.crumbs .i { width: 14px; height: 14px; }
.page-title { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.page-title h1 { font-size: 30px; font-weight: 800; }

/* ---------- hero slider ---------- */
.hero { position: relative; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow); }
.hero-track { display: flex; transition: transform .7s var(--ease); }
.slide { flex: 0 0 100%; min-height: 400px; display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; padding: 48px 64px; gap: 24px; position: relative; overflow: hidden; }
.slide::before { content: ''; position: absolute; width: 520px; height: 520px; border-radius: 50%; background: rgba(255, 255, 255, .08); inset-inline-end: -120px; top: -160px; }
.slide.dark { color: #fff; }
.slide .txt { position: relative; z-index: 1; }
.slide .eyebrow { display: inline-block; padding: 5px 12px; border-radius: 999px; background: rgba(255, 255, 255, .16); backdrop-filter: blur(6px); font-size: 12px; font-weight: 600; margin-bottom: 16px; }
.slide:not(.dark) .eyebrow { background: rgba(20, 22, 31, .07); }
.slide h2 { font-size: clamp(28px, 4vw, 48px); font-weight: 800; letter-spacing: -.02em; }
.slide p { font-size: 17px; opacity: .85; margin: 14px 0 28px; max-width: 460px; }
.slide .btn { background: #fff; color: #14161F; }
.slide .btn:hover { background: var(--accent); color: #fff; }
.slide:not(.dark) .btn { background: #14161F; color: #fff; }
.slide:not(.dark) .btn:hover { background: var(--accent); }
.slide .pic { position: relative; z-index: 1; height: 320px; display: grid; place-items: center; }
.slide .pic svg, .slide .pic img { height: 100%; width: auto; max-width: 100%; object-fit: contain; filter: drop-shadow(0 20px 30px rgba(0, 0, 0, .25)); }
.slide.is-active .pic { animation: floatIn .9s var(--ease); }
.hero-dots { position: absolute; bottom: 18px; inset-inline-start: 64px; display: flex; gap: 8px; }
.hero-dots button { width: 8px; height: 8px; border-radius: 999px; background: rgba(255, 255, 255, .5); transition: all .3s; box-shadow: 0 0 0 1px rgba(0, 0, 0, .06); }
.hero-dots button.on { width: 28px; background: var(--accent); }
.hero-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .9); display: grid; place-items: center; box-shadow: var(--shadow); opacity: 0; transition: opacity .25s, background .2s; color: #14161F; }
.hero:hover .hero-arrow { opacity: 1; }
.hero-arrow:hover { background: var(--surface); color: var(--accent); }
.hero-arrow.prev { inset-inline-start: 14px; }
.hero-arrow.next { inset-inline-end: 14px; }

/* perks */
.perks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 18px; }
.perk { display: flex; align-items: center; gap: 14px; background: var(--surface); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow-sm); }
.perk .ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-50); color: var(--accent); flex: none; }
.perk b { display: block; font-size: 14px; }
.perk small { color: var(--muted); font-size: 12.5px; }

/* category cards */
.cats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.cat-card { position: relative; background: var(--surface); border-radius: var(--radius); padding: 20px 14px 18px; text-align: center; box-shadow: var(--shadow-sm); transition: transform .25s var(--ease), box-shadow .25s; overflow: hidden; }
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.cat-card .ic { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 20px; display: grid; place-items: center; background: var(--tint, var(--accent-50)); color: var(--tone, var(--accent)); transition: transform .3s var(--ease); }
.cat-card:hover .ic { transform: scale(1.08) rotate(-4deg); }
.cat-card .ic .i { width: 30px; height: 30px; stroke-width: 1.8; }
.cat-card b { display: block; font-weight: 600; font-size: 14.5px; }
.cat-card small { color: var(--muted); font-size: 12.5px; }

/* ---------- product grid & card ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.grid.cols-5 { grid-template-columns: repeat(5, 1fr); }
.card {
  position: relative; background: var(--card); border-radius: var(--radius); border: 1px solid var(--line);
  display: flex; flex-direction: column; overflow: hidden;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.card-img { position: relative; display: block; margin: 8px; border-radius: var(--radius-sm); background: var(--img-bg); aspect-ratio: 1; overflow: hidden; }
.card-img svg, .card-img img { width: 100%; height: 100%; object-fit: contain; transition: transform .5s var(--ease); }
.card-img img { padding: 8%; mix-blend-mode: multiply; }
.card:hover .card-img svg, .card:hover .card-img img { transform: scale(1.05); }
.tags { position: absolute; top: 10px; inset-inline-start: 10px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; z-index: 1; }
.tag { padding: 3px 9px; border-radius: 8px; font-size: 12px; font-weight: 700; color: #fff; background: var(--accent); line-height: 1.4; }
.tag.new { background: var(--inv); color: var(--on-inv); }
.tag.hit { background: #7C5CFF; }
.wish-btn {
  position: absolute; top: 16px; inset-inline-end: 16px; z-index: 2; width: 38px; height: 38px; border-radius: 50%;
  background: var(--surface); display: grid; place-items: center; box-shadow: var(--shadow-sm); color: var(--ink-2);
  transition: transform .2s, color .2s;
}
.wish-btn:hover { transform: scale(1.1); color: var(--accent); }
.wish-btn.on { color: var(--red); }
.wish-btn.on .i { fill: currentColor; }
.wish-btn.on { animation: heart .45s var(--ease); }
.card-body { padding: 4px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.card .brand { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
html[lang="ar"] .card .brand { letter-spacing: 0; }
.card .name { font-weight: 500; margin: 4px 0 10px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.8em; }
.card .name:hover { color: var(--accent); }
.prices { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; margin-top: auto; }
.price { font-size: 19px; font-weight: 800; letter-spacing: -.01em; }
.old { color: var(--muted); text-decoration: line-through; font-size: 13.5px; }
.price.sale { color: var(--accent-600); }
.card .btn { margin-top: 12px; height: 42px; width: 100%; }
.card .btn.in { background: var(--accent-50); color: var(--accent-600); box-shadow: none; }
.swatches { display: flex; gap: 5px; margin-bottom: 8px; }
.swatches i { width: 12px; height: 12px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12); }

/* ---------- catalog ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; margin-bottom: 20px; }
.chips::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 500; font-size: 14px; white-space: nowrap; transition: all .2s; }
.chip .i { width: 16px; height: 16px; }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.on { background: var(--inv); color: var(--on-inv); border-color: var(--inv); }
.catalog { display: grid; grid-template-columns: 270px 1fr; gap: 24px; align-items: start; }
.filters { background: var(--surface); border-radius: var(--radius); padding: 8px 20px 20px; box-shadow: var(--shadow-sm); position: sticky; top: calc(var(--head-h) + 16px); max-height: calc(100vh - var(--head-h) - 32px); overflow: auto; }
.filters-head { display: none; }
.fgroup { padding-block: 16px; border-bottom: 1px solid var(--line); }
.fgroup:last-of-type { border-bottom: 0; }
.fgroup h4 { font-size: 14px; font-weight: 700; margin-bottom: 12px; }
.check { display: flex; align-items: center; gap: 10px; padding: 5px 0; cursor: pointer; font-size: 14px; }
.check input { appearance: none; width: 20px; height: 20px; border-radius: 6px; border: 1.5px solid var(--border-strong); display: grid; place-items: center; transition: all .15s; margin: 0; flex: none; }
.check input:checked { background: var(--accent); border-color: var(--accent); }
.check input:checked::after { content: ''; width: 10px; height: 6px; border: 2px solid #fff; border-top: 0; border-inline-end: 0; transform: rotate(-45deg) translate(1px, -1px); }
[dir="rtl"] .check input:checked::after { border-inline-end: 2px solid #fff; border-inline-start: 0; transform: rotate(45deg) translate(-1px, -1px); }
.check .cnt { margin-inline-start: auto; color: var(--muted); font-size: 12px; }
.range-inputs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.field-mini { position: relative; }
.field-mini span { position: absolute; top: 50%; transform: translateY(-50%); inset-inline-start: 12px; font-size: 12px; color: var(--muted); pointer-events: none; }
.field-mini input { width: 100%; height: 42px; border-radius: 10px; border: 1.5px solid var(--line); padding-inline: 50px 10px; outline: 0; background: var(--bg); transition: border-color .2s; }
html[lang="ar"] .field-mini input { padding-inline: 34px 10px; }
.field-mini input:focus { border-color: var(--accent); background: var(--surface); }
.dual { position: relative; height: 28px; margin-top: 10px; }
.dual .rail { position: absolute; top: 12px; inset-inline: 0; height: 4px; border-radius: 4px; background: var(--line); }
.dual .fill { position: absolute; top: 12px; height: 4px; border-radius: 4px; background: var(--accent); }
.dual input[type=range] { position: absolute; inset: 0; width: 100%; margin: 0; appearance: none; background: none; pointer-events: none; }
.dual input[type=range]::-webkit-slider-thumb { appearance: none; pointer-events: auto; width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 2px solid var(--accent); box-shadow: var(--shadow); cursor: grab; }
.dual input[type=range]::-moz-range-thumb { pointer-events: auto; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 2px solid var(--accent); box-shadow: var(--shadow); cursor: grab; }
.opt-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.opt-chips button { padding: 6px 12px; border-radius: 10px; border: 1.5px solid var(--line); font-size: 13px; font-weight: 500; transition: all .15s; }
.opt-chips button:hover { border-color: var(--accent); }
.opt-chips button.on { border-color: var(--accent); background: var(--accent-50); color: var(--accent-600); }
.filters .btn-ghost { width: 100%; margin-top: 8px; }
.filters .apply { display: none; }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.toolbar .filter-toggle { display: none; }
.select { position: relative; }
.select select { appearance: none; height: 42px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); padding-inline: 14px 38px; font-weight: 500; cursor: pointer; outline: 0; }
.select select:focus { border-color: var(--accent); }
.select .i { position: absolute; inset-inline-end: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; pointer-events: none; color: var(--muted); }

/* ---------- empty state ---------- */
.empty { text-align: center; padding: 64px 20px; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.empty .ic { width: 84px; height: 84px; margin: 0 auto 18px; border-radius: 50%; background: var(--accent-50); color: var(--accent); display: grid; place-items: center; }
.empty .ic .i { width: 38px; height: 38px; stroke-width: 1.6; }
.empty h2 { font-size: 22px; margin-bottom: 6px; }
.empty p { color: var(--muted); margin: 0 0 22px; }

/* ---------- product page ---------- */
.pd { display: grid; grid-template-columns: 1.05fr 1fr; gap: 32px; align-items: start; }
.gallery { position: sticky; top: calc(var(--head-h) + 16px); }
.g-main { position: relative; background: var(--surface); border-radius: 20px; aspect-ratio: 1; display: grid; place-items: center; overflow: hidden; box-shadow: var(--shadow-sm); }
.g-main > svg, .g-main > img { width: 88%; height: 88%; object-fit: contain; animation: fade .35s; }
.g-thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; scrollbar-width: none; }
.g-thumbs button { width: 76px; height: 76px; border-radius: 14px; background: var(--surface); border: 2px solid transparent; padding: 6px; flex: none; transition: border-color .2s; box-shadow: var(--shadow-sm); }
.g-thumbs button.on { border-color: var(--accent); }
.g-thumbs svg, .g-thumbs img { width: 100%; height: 100%; object-fit: contain; }
.g-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 40px; height: 40px; border-radius: 50%; background: var(--surface); box-shadow: var(--shadow); display: grid; place-items: center; opacity: 0; transition: opacity .2s; }
.g-main:hover .g-nav { opacity: 1; }
.g-nav.prev { inset-inline-start: 12px; } .g-nav.next { inset-inline-end: 12px; }
.pinfo { background: var(--surface); border-radius: 20px; padding: 28px; box-shadow: var(--shadow-sm); }
.pinfo .brand-line { display: flex; align-items: center; gap: 10px; color: var(--muted); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
html[lang="ar"] .pinfo .brand-line { letter-spacing: 0; }
.pinfo h1 { font-size: 28px; font-weight: 800; margin: 8px 0 16px; }
.stock { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--green); }
.stock::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.stock.low { color: #D97706; } .stock.out { color: var(--red); }
.p-price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; padding: 18px 0; border-block: 1px solid var(--line); margin-bottom: 20px; }
.p-price .price { font-size: 34px; }
.p-price .old { font-size: 17px; }
.save-pill { padding: 4px 10px; border-radius: 8px; background: var(--accent-50); color: var(--accent-600); font-weight: 700; font-size: 13px; }
.opt { margin-bottom: 20px; }
.opt-label { font-size: 14px; color: var(--muted); margin-bottom: 10px; }
.opt-label b { color: var(--ink); font-weight: 600; }
.colors { display: flex; flex-wrap: wrap; gap: 10px; }
.colors button { width: 38px; height: 38px; border-radius: 50%; padding: 3px; border: 2px solid transparent; transition: border-color .2s, transform .2s; }
.colors button:hover { transform: scale(1.08); }
.colors button.on { border-color: var(--accent); }
.colors button span { display: block; width: 100%; height: 100%; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .12); }
.storages { display: flex; flex-wrap: wrap; gap: 8px; }
.storages button { min-width: 92px; padding: 9px 14px; border-radius: 12px; border: 1.5px solid var(--line); text-align: center; transition: all .2s; }
.storages button b { display: block; font-weight: 600; font-size: 14px; }
.storages button small { color: var(--muted); font-size: 12px; }
.storages button:hover { border-color: var(--accent); }
.storages button.on { border-color: var(--accent); background: var(--accent-50); }
.buy-row { display: flex; gap: 10px; margin-top: 8px; }
.buy-row .btn { flex: 1; }
.buy-row .wish-lg { width: 52px; height: 52px; border-radius: var(--radius-sm); border: 1px solid var(--line); display: grid; place-items: center; flex: none; transition: all .2s; }
.buy-row .wish-lg:hover { color: var(--accent); border-color: var(--accent); }
.buy-row .wish-lg.on { color: var(--red); border-color: var(--danger-line); background: var(--danger-bg); }
.buy-row .wish-lg.on .i { fill: currentColor; }
.qty { display: inline-flex; align-items: center; height: 52px; border-radius: var(--radius-sm); border: 1px solid var(--line); flex: none; }
.qty button { width: 40px; height: 100%; display: grid; place-items: center; color: var(--ink-2); }
.qty button:hover { color: var(--accent); }
.qty button .i { width: 16px; height: 16px; }
.qty span { min-width: 28px; text-align: center; font-weight: 600; }
.qty.sm { height: 38px; } .qty.sm button { width: 34px; }
.mini-perks { display: grid; gap: 10px; margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--line); }
.mini-perks div { display: flex; gap: 12px; align-items: center; font-size: 14px; }
.mini-perks .i { color: var(--accent); }
.mini-perks small { color: var(--muted); display: block; font-size: 12.5px; }
.ptabs { margin-top: 40px; background: var(--surface); border-radius: 20px; padding: 8px 28px 28px; box-shadow: var(--shadow-sm); }
.tabs { display: flex; gap: 28px; border-bottom: 1px solid var(--line); margin-bottom: 22px; }
.tabs button { padding: 16px 0; font-weight: 600; color: var(--muted); position: relative; transition: color .2s; }
.tabs button.on { color: var(--ink); }
.tabs button.on::after { content: ''; position: absolute; inset-inline: 0; bottom: -1px; height: 2.5px; border-radius: 2px; background: var(--accent); }
.desc { max-width: 760px; color: var(--ink-2); line-height: 1.75; white-space: pre-line; margin: 0; }
.specs { width: 100%; max-width: 760px; border-collapse: collapse; }
.specs tr:nth-child(odd) td { background: var(--bg); }
.specs td { padding: 12px 16px; font-size: 14px; }
.specs td:first-child { color: var(--muted); width: 40%; border-start-start-radius: 10px; border-end-start-radius: 10px; }
.specs td:last-child { font-weight: 500; border-start-end-radius: 10px; border-end-end-radius: 10px; }

/* ---------- cart & checkout ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 24px; align-items: start; }
.cart-list { background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-sm); padding: 8px 24px; }
.cart-item { display: grid; grid-template-columns: 96px 1fr auto; gap: 18px; align-items: center; padding-block: 18px; border-bottom: 1px solid var(--line); animation: fadeUp .3s var(--ease); }
.cart-item:last-child { border-bottom: 0; }
.cart-item .ci-img { width: 96px; height: 96px; border-radius: 14px; background: var(--bg); display: grid; place-items: center; overflow: hidden; }
.cart-item .ci-img svg, .cart-item .ci-img img { width: 100%; height: 100%; object-fit: contain; }
.ci-name { font-weight: 600; }
.ci-name:hover { color: var(--accent); }
.ci-meta { color: var(--muted); font-size: 13px; margin: 2px 0 10px; display: flex; gap: 6px 12px; flex-wrap: wrap; align-items: center; }
.ci-meta i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; vertical-align: middle; margin-inline-end: 4px; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); }
.ci-actions { display: flex; align-items: center; gap: 12px; }
.ci-remove { color: var(--muted); display: inline-flex; gap: 4px; align-items: center; font-size: 13px; }
.ci-remove:hover { color: var(--red); }
.ci-remove .i { width: 16px; height: 16px; }
.ci-price { text-align: end; }
.ci-price .price { font-size: 18px; }
.ci-price .old { display: block; }
.summary { background: var(--surface); border-radius: 20px; padding: 24px; box-shadow: var(--shadow-sm); position: sticky; top: calc(var(--head-h) + 16px); }
.summary h3 { font-size: 18px; margin-bottom: 16px; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; color: var(--ink-2); font-size: 14.5px; }
.sum-row .green { color: var(--green); font-weight: 600; }
.sum-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: 14px; margin-top: 8px; border-top: 1px dashed var(--line); font-weight: 700; }
.sum-total .price { font-size: 24px; }
.summary .btn { margin-top: 18px; }
.summary .note { font-size: 13px; color: var(--muted); margin-top: 12px; display: flex; gap: 8px; }
.summary .note .i { width: 18px; height: 18px; color: var(--accent); }
.sum-items { display: grid; gap: 12px; margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--line); max-height: 300px; overflow: auto; }
.sum-item { display: grid; grid-template-columns: 52px 1fr auto; gap: 12px; align-items: center; font-size: 13.5px; }
.sum-item .ci-img { width: 52px; height: 52px; border-radius: 10px; background: var(--bg); overflow: hidden; display: grid; place-items: center; position: relative; }
.sum-item .ci-img svg, .sum-item .ci-img img { width: 100%; height: 100%; object-fit: contain; }
.sum-item .q { position: absolute; top: -2px; inset-inline-end: -2px; background: var(--inv); color: var(--on-inv); font-size: 10px; font-weight: 700; border-radius: 999px; min-width: 18px; height: 18px; display: grid; place-items: center; }
.sum-item small { color: var(--muted); display: block; }
.form-card { background: var(--surface); border-radius: 20px; padding: 28px; box-shadow: var(--shadow-sm); }
.form-card h3 { font-size: 18px; margin-bottom: 18px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 13.5px; font-weight: 600; margin-bottom: 7px; }
.field label small { font-weight: 400; color: var(--muted); }
.field input, .field textarea, .field select {
  width: 100%; border-radius: var(--radius-sm); border: 1.5px solid var(--line); background: var(--bg); padding: 12px 14px; outline: 0;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.field textarea { resize: vertical; min-height: 96px; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); background: var(--surface); box-shadow: 0 0 0 4px var(--accent-50); }
.field.err input, .field.err textarea { border-color: var(--red); background: var(--danger-bg); }
.field .msg { display: none; color: var(--red); font-size: 12.5px; margin-top: 5px; }
.field.err .msg { display: block; }
input[type="tel"] { direction: ltr; }
[dir="rtl"] input[type="tel"] { text-align: right; }
.alert { padding: 12px 16px; border-radius: var(--radius-sm); background: var(--danger-bg); color: var(--red); font-size: 14px; margin-top: 14px; }
.success { max-width: 560px; margin: 24px auto; text-align: center; background: var(--surface); border-radius: 24px; padding: 48px 32px; box-shadow: var(--shadow); }
.success .ic { width: 92px; height: 92px; margin: 0 auto 20px; border-radius: 50%; background: var(--success-bg); color: var(--green); display: grid; place-items: center; animation: pop .5s var(--ease); }
.success .ic .i { width: 46px; height: 46px; }
.success h1 { font-size: 26px; margin-bottom: 10px; }
.success p { color: var(--ink-2); margin: 0 0 26px; }

/* ---------- profile ---------- */
.profile { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.panel { background: var(--surface); border-radius: 20px; padding: 24px; box-shadow: var(--shadow-sm); }
.panel h3 { font-size: 17px; margin-bottom: 16px; }
.pref { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; }
.pref .seg button { padding: 7px 16px; font-size: 13px; }
.order-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.order-row:last-child { border-bottom: 0; }
.order-row small { color: var(--muted); display: block; }
.contact-list a, .contact-list span { display: flex; gap: 12px; align-items: center; padding: 8px 0; }
.contact-list .i { color: var(--accent); }

/* ---------- footer ---------- */
.footer { background: var(--surface); border-top: 1px solid var(--line); padding-top: 52px; }
.footer .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 32px; }
.footer h4 { font-size: 15px; margin-bottom: 16px; }
.footer p { color: var(--ink-2); font-size: 14px; margin: 14px 0 18px; max-width: 320px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer li a, .footer li span { color: var(--ink-2); font-size: 14px; display: inline-flex; gap: 10px; align-items: center; transition: color .2s; }
.footer li a:hover { color: var(--accent); }
.footer li .i { width: 17px; height: 17px; color: var(--accent); }
.socials { display: flex; gap: 8px; }
.socials a { width: 40px; height: 40px; border-radius: 12px; background: var(--bg); display: grid; place-items: center; color: var(--ink-2); transition: all .2s; }
.socials a:hover { background: var(--accent); color: #fff; transform: translateY(-2px); }
.pays { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.pay-logo { height: 38px; min-width: 62px; padding-inline: 10px; border-radius: 10px; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; }
.pay-logo.cod { font-size: 12px; font-weight: 600; color: var(--ink-2); gap: 6px; display: inline-flex; align-items: center; }
.pay-logo.cod .i { width: 16px; height: 16px; color: var(--accent); }
.footer-bottom { margin-top: 40px; border-top: 1px solid var(--line); padding-block: 20px; color: var(--muted); font-size: 13px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- bottom nav (mobile) ---------- */
.bottomnav { display: none; }

/* ---------- toasts ---------- */
.toasts { position: fixed; bottom: 24px; inset-inline-start: 50%; transform: translateX(-50%); z-index: 100; display: grid; gap: 8px; pointer-events: none; }
[dir="rtl"] .toasts { transform: translateX(50%); }
.toast { display: flex; align-items: center; gap: 10px; background: var(--inv); color: var(--on-inv); padding: 12px 18px; border-radius: 14px; box-shadow: var(--shadow-lg); font-size: 14px; font-weight: 500; animation: toastIn .3s var(--ease); white-space: nowrap; }
.toast .i { width: 18px; height: 18px; color: #4ADE80; }
.toast.out { animation: toastOut .25s forwards; }

/* ---------- loader / skeleton ---------- */
.loader { width: 36px; height: 36px; margin: 120px auto; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; }

/* ---------- animations ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: none; } }
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
@keyframes floatIn { from { opacity: 0; transform: translateY(24px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.35); } 100% { transform: scale(1); } }
@keyframes heart { 0% { transform: scale(1); } 35% { transform: scale(1.3); } 100% { transform: scale(1); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(8px); } }
@keyframes slideIn { from { transform: translateX(-100%); } to { transform: none; } }
@keyframes slideInR { from { transform: translateX(100%); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; } }

/* =================== responsive =================== */
@media (max-width: 1180px) {
  .grid.cols-5 { grid-template-columns: repeat(4, 1fr); }
  .cats { grid-template-columns: repeat(3, 1fr); }
  .perks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1024px) {
  .catalog { grid-template-columns: 1fr; }
  .filters {
    position: fixed; top: 0; bottom: 0; inset-inline-start: 0; width: min(360px, 88vw); max-height: none; z-index: 95;
    border-radius: 0; padding-top: 0; transform: translateX(-105%); transition: transform .3s var(--ease); box-shadow: var(--shadow-lg);
  }
  [dir="rtl"] .filters { transform: translateX(105%); }
  .filters { visibility: hidden; transition: transform .3s var(--ease), visibility 0s .3s; }
  .filters.open, [dir="rtl"] .filters.open { transform: none; visibility: visible; transition: transform .3s var(--ease); }
  .filters-head { display: flex; justify-content: space-between; align-items: center; position: sticky; top: 0; background: var(--surface); padding-block: 16px 8px; z-index: 1; }
  .filters-head b { font-size: 18px; }
  .filters .apply { display: flex; width: 100%; margin-top: 12px; }
  .toolbar .filter-toggle { display: inline-flex; }
  .pd { grid-template-columns: minmax(0, 1fr); }
  .pd > * { min-width: 0; }
  .gallery { position: static; }
  .cart-layout { grid-template-columns: 1fr; }
  .summary { position: static; }
  .footer .cols { grid-template-columns: 1fr 1fr; }
  .mega .container { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .header .catalog-btn span, .head-icon span { display: none; }
  .catalog-btn { padding-inline: 14px; }
  .slide { grid-template-columns: 1fr; padding: 32px 28px 48px; min-height: 0; text-align: start; }
  .slide .pic { position: absolute; inset-inline-end: -20px; bottom: -10px; height: 220px; opacity: .95; z-index: 0; }
  .slide .txt { max-width: 62%; }
  .slide p { font-size: 15px; margin-bottom: 20px; }
  .hero-dots { inset-inline-start: 28px; }
  .hero-arrow { display: none; }
  .profile { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  body { font-size: 14.5px; padding-bottom: calc(68px + env(safe-area-inset-bottom)); }
  .container { padding-inline: 14px; }
  .topbar .info .hours, .topbar .info .call-label { display: none; }
  .header .container { flex-wrap: wrap; height: auto; padding-block: 10px; gap: 10px 12px; }
  .header .catalog-btn, .head-icons { display: none; }
  .logo { margin-inline-end: auto; }
  .logo-text b { font-size: 20px; }
  .search { order: 3; flex-basis: 100%; }
  .search form { height: 44px; }
  .catmenu .container { height: 46px; }
  .view { padding-block: 16px 40px; }
  .section { margin-top: 32px; }
  .section-head h2 { font-size: 20px; }
  .page-title h1 { font-size: 24px; }
  .hero { border-radius: 18px; }
  .slide h2 { font-size: 26px; }
  .slide .txt { max-width: 70%; }
  .slide .pic { height: 180px; }
  .perks { gap: 10px; }
  .perk { padding: 12px; gap: 10px; }
  .perk .ic { width: 38px; height: 38px; }
  .perk small { display: none; }
  .cats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .cat-card { padding: 14px 8px; }
  .cat-card .ic { width: 52px; height: 52px; border-radius: 16px; }
  .cat-card b { font-size: 13px; }
  .grid, .grid.cols-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card-img { margin: 6px; }
  .card-body { padding: 2px 12px 12px; }
  .card .name { font-size: 13.5px; }
  .price { font-size: 16px; }
  .old { font-size: 12px; }
  .card .btn { height: 38px; font-size: 13.5px; padding-inline: 10px; }
  .card .btn .i { display: none; }
  .wish-btn { width: 34px; height: 34px; top: 12px; inset-inline-end: 12px; }
  .wish-btn .i { width: 18px; height: 18px; }
  .toolbar { gap: 8px; }
  .toolbar #count { display: none; } /* the count is shown on the filter panel's button instead */
  .select { min-width: 0; }
  .select select { max-width: 58vw; text-overflow: ellipsis; }
  .pinfo { padding: 20px; }
  .buy-row { gap: 8px; }
  .buy-row .btn { min-width: 0; padding-inline: 12px; font-size: 15px; }
  .qty button { width: 34px; }
  .pinfo h1 { font-size: 22px; }
  .p-price .price { font-size: 28px; }
  .ptabs { padding: 4px 18px 20px; }
  .cart-list { padding: 4px 14px; }
  .cart-item { grid-template-columns: 76px 1fr; gap: 12px; }
  .cart-item .ci-img { width: 76px; height: 76px; }
  .ci-price { grid-column: 2; text-align: start; }
  .form-card { padding: 20px; }
  .form-grid { grid-template-columns: 1fr; }
  .footer { padding-top: 36px; }
  .footer .cols { grid-template-columns: 1fr; gap: 26px; }
  .toasts { bottom: calc(82px + env(safe-area-inset-bottom)); }
  .mega { display: none !important; }

  .bottomnav {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; inset-inline: 0; bottom: 0; z-index: 60;
    background: var(--glass); backdrop-filter: blur(12px); border-top: 1px solid var(--line);
    padding-bottom: env(safe-area-inset-bottom); box-shadow: 0 -4px 20px rgba(20, 22, 31, .05);
  }
  .bottomnav a { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 9px 0 8px; font-size: 11px; font-weight: 500; color: var(--muted); transition: color .2s; }
  .bottomnav a .i { width: 23px; height: 23px; }
  .bottomnav a.on { color: var(--accent); }
  .bottomnav a.on::before { content: ''; position: absolute; top: 0; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--accent); }
  .bottomnav .badge { top: 4px; inset-inline-end: calc(50% - 22px); }
}
@media (max-width: 420px) {
  .slide .txt { max-width: 100%; }
  .slide .pic { opacity: .35; }
  .topbar .seg button { padding: 3px 8px; }
  .signin-btn { padding: 0 8px; }
  .signin-btn span { display: none; }
}
