:root {
  /* Avishan — forest teal commerce, warm fashion accents */
  --bg: #eef5f2;
  --bg-soft: #f6faf8;
  --ink: #14201c;
  --muted: #5a6b64;
  --accent: #0b6b58;
  --accent-hover: #085445;
  --accent-deep: #064739;
  --accent-soft: #d8efe8;
  --accent-2: #e23d55;
  --accent-warm: #c46a3a;
  --accent-gold: #c9a227;
  --card: #ffffff;
  --line: #d5e3dd;
  --line-soft: #e8f1ed;
  --shadow: 0 2px 8px rgba(6, 55, 45, 0.06);
  --shadow-md: 0 10px 28px rgba(6, 55, 45, 0.1);
  --shadow-lg: 0 18px 48px rgba(6, 55, 45, 0.12);
  --radius: 14px;
  --header-h: 72px;
  --font: "Vazirmatn", Tahoma, sans-serif;
  --font-display: "Estedad Variable", "Estedad", "Vazirmatn", Tahoma, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html {
  max-width: 100%;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html, body {
  margin: 0;
  direction: rtl;
  text-align: right;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  min-height: 100%;
}
body {
  max-width: 100%;
  overflow-x: hidden;
  background:
    radial-gradient(ellipse 90% 55% at 100% -5%, rgba(11, 107, 88, 0.14) 0%, transparent 55%),
    radial-gradient(ellipse 70% 45% at -5% 15%, rgba(196, 106, 58, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse 50% 40% at 70% 100%, rgba(11, 107, 88, 0.06) 0%, transparent 45%),
    linear-gradient(180deg, #f4faf7 0%, var(--bg) 28%, #e9f2ee 100%);
  background-attachment: fixed;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}
body > * { position: relative; z-index: 1; }

a { color: inherit; text-decoration: none; }
button, input, textarea, select { font-family: inherit; }
img { max-width: 100%; display: block; }

@keyframes av-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes av-brand-sheen {
  0%, 100% { background-position: 100% 50%; }
  50% { background-position: 0% 50%; }
}
@keyframes av-pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.15); opacity: 0.85; }
}

.container {
  width: min(1280px, calc(100% - 2rem));
  max-width: 100%;
  margin-inline: auto;
  min-width: 0;
}

/* —— Top utility bar —— */
.topbar {
  background: linear-gradient(90deg, #064739 0%, #0b6b58 55%, #0a5f4f 100%);
  border-bottom: 0;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.82);
}
.topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.4rem 0;
  flex-wrap: wrap;
}
.topbar-links, .topbar-meta { display: flex; gap: 0.85rem; align-items: center; flex-wrap: wrap; }
.role-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.16);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
}
.account-role {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.7rem 0.55rem;
  border-bottom: 1px solid var(--line, #e5ebe8);
  margin-bottom: 0.25rem;
}
.footer-dyn {
  display: contents;
}
.footer-grid .footer-dyn > .footer-acc,
.footer-grid > .footer-acc {
  min-width: 0;
}
#catRoleLinks:not([hidden]) {
  display: inline-flex;
  gap: 0.85rem;
  align-items: center;
}
#catRoleLinks a {
  color: var(--accent-deep);
  font-weight: 700;
}
.role-banner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-bottom: 1rem;
}
body[data-role="GUEST"] .only-auth,
body[data-role="BUYER"] .only-seller,
body[data-role="BUYER"] .only-admin,
body[data-role="SELLER"] .only-admin,
body[data-role="GUEST"] .only-seller,
body[data-role="GUEST"] .only-admin {
  display: none !important;
}
.topbar a:hover, .topbar .linkish:hover { color: #fff; }
.linkish {
  background: none; border: 0; padding: 0; color: rgba(255, 255, 255, 0.82); cursor: pointer; font-size: inherit;
}
.dot { opacity: 0.5; }

/* —— Main header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--line-soft), var(--shadow);
  border-bottom: 1px solid rgba(213, 227, 221, 0.7);
}
.header-main {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1.25rem;
  padding: 0.9rem 0;
}
.brand {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  white-space: nowrap;
  line-height: 1;
}
.brand span {
  background: linear-gradient(105deg, var(--accent) 0%, #1a9a7e 45%, var(--accent-warm) 100%);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: av-brand-sheen 8s ease-in-out infinite;
}
.footer-brand { font-size: 1.45rem; margin-bottom: 0.5rem; }

.search-box {
  display: flex;
  position: relative;
  background: var(--bg-soft);
  border-radius: 12px;
  overflow: visible;
  border: 1px solid var(--line);
  transition: border-color 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out), background 0.2s;
}
.search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(11, 107, 88, 0.14);
  background: #fff;
}
.search-box input {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  outline: none;
  min-width: 0;
  border-radius: 12px 0 0 12px;
}
.search-box > button[type="submit"] {
  border: 0;
  background: linear-gradient(160deg, var(--accent) 0%, var(--accent-deep) 100%);
  color: #fff;
  padding: 0 1.2rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: filter 0.15s;
  border-radius: 0 12px 12px 0;
}
.search-box > button[type="submit"]:hover { filter: brightness(1.06); }
.suggest-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  left: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 14px 36px rgba(15, 40, 35, 0.14);
  z-index: 90;
  padding: 0.35rem;
  max-height: 320px;
  overflow: auto;
}
.suggest-panel[hidden] { display: none !important; }
.suggest-item {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  width: 100%;
  text-align: right;
  border: 0;
  background: transparent;
  padding: 0.55rem 0.7rem;
  border-radius: 8px;
  cursor: pointer;
}
.suggest-item:hover { background: var(--accent-soft); }
.suggest-item span { font-size: 0.75rem; color: var(--muted); }
.suggest-item b { font-size: 0.9rem; color: var(--ink); }
.search-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 1rem;
  align-items: start;
}
.search-facets .facet-cats { display: flex; flex-direction: column; align-items: flex-start; gap: 0.35rem; margin-top: 6px; }
@media (max-width: 860px) {
  .search-layout { grid-template-columns: 1fr; }
}

.header-actions { display: flex; gap: 0.35rem; align-items: center; }
.account-menu { position: relative; }
.account-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 200px;
  background: #fff;
  border: 1px solid var(--line, #e5ebe8);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(15, 40, 35, 0.12);
  padding: 0.45rem;
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}
.account-dropdown[hidden] { display: none !important; }
.account-dropdown a,
.account-dropdown .linkish {
  display: block;
  width: 100%;
  text-align: right;
  padding: 0.55rem 0.7rem;
  border-radius: 8px;
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 600;
  background: transparent;
  border: 0;
  cursor: pointer;
}
.account-dropdown a:hover,
.account-dropdown .linkish:hover {
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.h-action {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 600;
  position: relative;
  transition: background 0.15s, color 0.15s;
}
.h-action:hover { background: var(--accent-soft); color: var(--accent-deep); }
.h-ico { font-size: 1.05rem; line-height: 1; width: 18px; height: 18px; display: inline-block; position: relative; }
.login-ico::before {
  content: "";
  position: absolute; inset: 0;
  border: 2px solid currentColor; border-radius: 50%;
  width: 10px; height: 10px; margin: 0 auto; top: 0; left: 0; right: 0;
}
.login-ico::after {
  content: "";
  position: absolute; bottom: 0; left: 0; right: 0; margin: auto;
  width: 16px; height: 8px; border: 2px solid currentColor; border-bottom: 0; border-radius: 8px 8px 0 0;
}
.bag-ico::before {
  content: "";
  position: absolute; inset: 2px 1px 0;
  border: 2px solid currentColor; border-radius: 2px 2px 3px 3px;
}
.bag-ico::after {
  content: "";
  position: absolute; top: 0; left: 4px; right: 4px; height: 6px;
  border: 2px solid currentColor; border-bottom: 0; border-radius: 6px 6px 0 0;
}
.cart-badge {
  position: absolute;
  top: 2px;
  left: 4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--accent-2);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  display: grid;
  place-items: center;
  animation: av-pulse-dot 2.4s ease-in-out infinite;
}

/* —— Category nav —— */
.cat-nav {
  border-top: 1px solid var(--line-soft);
  position: relative;
}
.cat-nav-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 46px;
}
.mega-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  padding: 0.65rem 0;
  white-space: nowrap;
  transition: color 0.15s;
}
.mega-trigger:hover, .mega-trigger[aria-expanded="true"] { color: var(--accent); }
.burger {
  width: 18px; height: 14px;
  border-block: 2px solid currentColor;
  background: linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat;
}
.cat-links {
  display: flex;
  gap: 1.1rem;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 0.4rem 0;
  color: var(--muted);
  font-size: 0.88rem;
  min-width: 0;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}
.cat-links::-webkit-scrollbar { display: none; }
.cat-links a {
  white-space: nowrap;
  position: relative;
  padding-bottom: 2px;
  transition: color 0.15s;
}
.cat-links a::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: -2px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right center;
  transition: transform 0.25s var(--ease-out);
}
.cat-links a:hover { color: var(--accent); }
.cat-links a:hover::after { transform: scaleX(1); }

.mega-panel {
  position: absolute;
  inset-inline: 0;
  top: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 1rem 1.25rem 1.25rem;
  z-index: 50;
}
.mega-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.75rem;
}
.mega-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.7rem 0.85rem;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: linear-gradient(160deg, #fff 0%, var(--bg-soft) 100%);
  transition: border-color 0.18s, transform 0.18s var(--ease-out), box-shadow 0.18s;
}
.mega-item:hover {
  border-color: rgba(11, 107, 88, 0.45);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.mega-dot {
  width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center;
  font-size: 0.85rem; font-weight: 800; color: #fff;
  flex-shrink: 0;
}
.mega-item strong { display: block; font-size: 0.9rem; }
.mega-item span { font-size: 0.75rem; color: var(--muted); }

/* —— Page shell —— */
#app {
  width: min(1280px, calc(100% - 2rem));
  max-width: 100%;
  min-width: 0;
  margin: 1.15rem auto 0;
  min-height: 55vh;
  padding-bottom: 2.5rem;
}
img, video, canvas, svg {
  max-width: 100%;
  height: auto;
}
.panel, .card, .seller-layout, .wiz-form, .wiz-shell, .wiz-main, .home-wrap, .site-footer {
  max-width: 100%;
  min-width: 0;
}
#app:has(.home-wrap) {
  width: 100%;
  max-width: none;
  margin: 0;
  padding-bottom: 2.5rem;
}
.page-narrow { width: min(560px, 100%); margin: 1.5rem auto 0; }

/* —— Buttons / forms —— */
.btn {
  border: 0; border-radius: 10px; padding: 0.65rem 1.15rem;
  background: linear-gradient(160deg, var(--accent) 0%, var(--accent-deep) 100%);
  color: #fff; cursor: pointer; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.35rem;
  transition: filter 0.15s, transform 0.15s;
}
.btn:hover { filter: brightness(1.05); transform: translateY(-1px); }
.btn.secondary {
  background: #fff; color: var(--ink); border: 1px solid var(--line);
  filter: none;
}
.btn.secondary:hover { border-color: var(--accent); color: var(--accent); filter: none; }
.btn.warm { background: linear-gradient(160deg, #e84d62 0%, #c72f45 100%); }
.btn.warm:hover { filter: brightness(1.04); }

.field { display: grid; gap: 0.35rem; margin-bottom: 0.9rem; }
.field label { font-size: 0.9rem; color: var(--muted); }
.field input, .field textarea, .field select {
  border: 1px solid var(--line); border-radius: 10px; padding: 0.75rem 0.9rem; background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(11, 107, 88, 0.12);
}
.row { display: flex; gap: 0.7rem; flex-wrap: wrap; align-items: center; max-width: 100%; min-width: 0; }
.panel {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.1rem; margin: 1rem 0; box-shadow: var(--shadow);
}
.alert {
  background: linear-gradient(135deg, #fff8f0 0%, #fff4e8 100%);
  border: 1px solid #efd4b8; color: #7a3e16;
  border-radius: 10px; padding: 0.8rem 1rem; margin: 1rem 0;
}
.badge {
  display: inline-flex; border-radius: 6px; padding: 0.15rem 0.5rem;
  background: var(--accent-soft); color: var(--accent-deep); font-size: 0.72rem; font-weight: 700;
}
.badge.sale { background: #fde8eb; color: var(--accent-2); }
.meta { color: var(--muted); font-size: 0.85rem; }
.price { margin-top: 0.45rem; font-weight: 800; color: var(--ink); font-size: 0.98rem; }
.price .old {
  color: var(--muted); font-weight: 500; font-size: 0.8rem;
  text-decoration: line-through; margin-inline-start: 0.35rem;
}
.price .off {
  color: var(--accent-2); font-size: 0.78rem; margin-inline-start: 0.35rem;
}

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.8rem; }
.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem;
}
.stat b { display: block; font-size: 1.4rem; margin-bottom: 0.2rem; }
.stat span { color: var(--muted); font-size: 0.85rem; }

/* —— Home layout —— */
.home-wrap { padding-top: 1.1rem; }
.home-section {
  width: min(1280px, calc(100% - 2rem));
  margin: 1.5rem auto 0;
  animation: av-rise 0.55s var(--ease-out) both;
}
.home-section:nth-child(1) { animation-delay: 0.02s; }
.home-section:nth-child(2) { animation-delay: 0.08s; }
.home-section:nth-child(3) { animation-delay: 0.14s; }
.home-section:nth-child(4) { animation-delay: 0.2s; }
.home-section:nth-child(5) { animation-delay: 0.26s; }
.home-section:nth-child(6) { animation-delay: 0.32s; }
.home-section:nth-child(7) { animation-delay: 0.38s; }

.section-head {
  display: flex; justify-content: space-between; align-items: center;
  gap: 1rem; margin-bottom: 0.9rem;
}
.section-head h2 {
  margin: 0; font-size: 1.2rem; font-weight: 800;
  font-family: var(--font-display);
  display: flex; align-items: center; gap: 0.5rem;
  letter-spacing: -0.02em;
}
.section-head h2::before {
  content: "";
  width: 4px; height: 1.1em;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-warm) 100%);
  flex-shrink: 0;
}
.section-head a {
  color: var(--accent); font-size: 0.88rem; font-weight: 700;
  transition: color 0.15s;
}
.section-head a:hover { color: var(--accent-hover); }

/* Hero carousel — full-bleed energy within structure */
.carousel {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(135deg, #064739, #0b6b58);
  aspect-ratio: 21 / 8;
  min-height: 240px;
  box-shadow: var(--shadow-lg);
  direction: ltr;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}
.carousel::after {
  content: "";
  position: absolute; inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  border-radius: inherit;
  z-index: 3;
}
.carousel-track {
  display: flex;
  height: 100%;
  width: 100%;
  transition: transform 0.55s var(--ease-out);
  will-change: transform;
  touch-action: pan-y;
}
.carousel-slide {
  flex: 0 0 100%;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: 100%;
  position: relative;
  display: grid;
  align-content: end;
  align-items: end;
  padding: 1.75rem 2rem 2.4rem;
  color: #fff;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  text-decoration: none;
  direction: rtl;
  text-align: right;
  box-sizing: border-box;
}
.carousel-slide::before {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(105deg, rgba(4, 40, 32, 0.88) 0%, rgba(6, 55, 45, 0.35) 48%, rgba(4, 40, 32, 0.55) 100%),
    linear-gradient(0deg, rgba(4, 30, 25, 0.45) 0%, transparent 45%);
}
.carousel-slide > * { position: relative; z-index: 1; }
.carousel-slide .slide-kicker {
  display: inline-flex; margin-bottom: 0.55rem;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(6px);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px; padding: 0.22rem 0.65rem; font-size: 0.75rem; font-weight: 700;
  letter-spacing: 0.02em;
}
.carousel-slide strong {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 3vw, 2.15rem);
  display: block;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.25);
}
.carousel-slide p { margin: 0.5rem 0 0; opacity: 0.92; max-width: 38ch; line-height: 1.75; }
.carousel-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 42px; height: 42px; border-radius: 50%;
  border: 0; background: rgba(255, 255, 255, 0.95); color: var(--ink);
  cursor: pointer; font-size: 1.2rem; z-index: 2;
  box-shadow: var(--shadow-md);
  display: grid; place-items: center;
  transition: transform 0.15s, background 0.15s;
}
.carousel-btn:hover { transform: translateY(-50%) scale(1.06); background: #fff; }
.carousel-btn.prev { inset-inline-start: 14px; }
.carousel-btn.next { inset-inline-end: 14px; }
.carousel-dots {
  position: absolute; inset-inline: 0; bottom: 12px;
  display: flex; justify-content: center; gap: 6px; z-index: 2;
}
.carousel-dots button {
  width: 8px; height: 8px; border-radius: 50%; border: 0;
  background: rgba(255, 255, 255, 0.4); cursor: pointer; padding: 0;
  transition: width 0.25s var(--ease-out), background 0.2s;
}
.carousel-dots button.active { background: #fff; width: 22px; border-radius: 999px; }

/* Category chips */
.cat-chips {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 0.85rem;
}
.cat-chip {
  display: flex; flex-direction: column; align-items: center; gap: 0.55rem;
  text-align: center; padding: 0.35rem;
}
.cat-chip .ring {
  width: 74px; height: 74px; border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 800; color: #fff; font-size: 0.95rem;
  box-shadow:
    inset 0 0 0 3px #fff,
    0 0 0 1px var(--line),
    0 8px 20px rgba(6, 55, 45, 0.12);
  transition: transform 0.28s var(--ease-out), box-shadow 0.28s;
}
.cat-chip:hover .ring {
  transform: scale(1.08) translateY(-2px);
  box-shadow:
    inset 0 0 0 3px #fff,
    0 0 0 1px rgba(11, 107, 88, 0.35),
    0 12px 28px rgba(6, 55, 45, 0.18);
}
.cat-chip span { font-size: 0.82rem; font-weight: 700; color: var(--ink); }

/* Product rails & grids */
.rail-wrap {
  background: linear-gradient(180deg, #ffffff 0%, var(--bg-soft) 100%);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1rem 0.75rem 1rem 0.75rem;
  box-shadow: var(--shadow);
}
.rail-wrap.amazing {
  background:
    radial-gradient(ellipse 60% 80% at 100% 0%, rgba(226, 61, 85, 0.1) 0%, transparent 55%),
    linear-gradient(180deg, #fff6f7 0%, #fff 50%);
  border-color: #f3c5cc;
}
.rail-wrap.amazing .section-head h2 { color: var(--accent-2); }
.rail-wrap.amazing .section-head h2::before {
  background: linear-gradient(180deg, var(--accent-2) 0%, var(--accent-warm) 100%);
}
.rail {
  display: flex; gap: 0.75rem; overflow-x: auto;
  padding: 0.25rem 0.35rem 0.5rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  min-width: 0;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}
.rail .card { min-width: 180px; max-width: 180px; scroll-snap-align: start; flex-shrink: 0; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr));
  gap: 0.9rem;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  transition: box-shadow 0.25s var(--ease-out), transform 0.25s var(--ease-out), border-color 0.2s;
  display: flex;
  flex-direction: column;
}
.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
  border-color: rgba(11, 107, 88, 0.28);
}
.swatch {
  height: 168px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0,0,0,.25);
  background-size: cover;
  background-position: center;
  position: relative;
  transition: transform 0.4s var(--ease-out);
}
.card:hover .swatch { transform: scale(1.03); }
.card .body { padding: 0.8rem 0.9rem 1rem; flex: 1; display: flex; flex-direction: column; }
.card h3 {
  margin: 0 0 0.3rem; font-size: 0.9rem; font-weight: 700;
  line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-badge {
  position: absolute; top: 8px; inset-inline-start: 8px;
  background: var(--accent-2); color: #fff;
  font-size: 0.7rem; font-weight: 800;
  padding: 0.15rem 0.45rem; border-radius: 6px;
  box-shadow: 0 4px 12px rgba(226, 61, 85, 0.35);
}

.collection-card {
  display: block;
  border-radius: 16px;
  overflow: hidden;
  min-height: 132px;
  padding: 1.2rem;
  color: #fff;
  position: relative;
  background: linear-gradient(135deg, #064739, #0b6b58 50%, #c46a3a);
  box-shadow: var(--shadow);
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s;
}
.collection-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.collection-card h3 {
  margin: 0 0 0.35rem; font-size: 1.08rem;
  font-family: var(--font-display);
}
.collection-card .meta { color: rgba(255,255,255,.88); }

/* Hero (product detail etc.) */
.hero {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 1.25rem;
  align-items: stretch; padding: 0.5rem 0 1rem;
}
.hero-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.4rem); line-height: 1.25; margin: 0 0 0.7rem;
  letter-spacing: -0.02em;
}
.hero-copy p { color: var(--muted); font-size: 1rem; line-height: 1.8; }
.hero-panel {
  border-radius: 18px;
  background: linear-gradient(160deg, #0b6b58 0%, #064739 55%, #c46a3a 140%);
  color: #f4faf7; padding: 1.4rem; min-height: 280px;
  display: flex; flex-direction: column; justify-content: flex-end;
  background-size: cover; background-position: center;
  box-shadow: var(--shadow-md);
}

/* Chat / misc preserved */
.chat-log { max-height: 360px; overflow: auto; display: grid; gap: 0.7rem; margin-bottom: 1rem; }
.chat-bubble { padding: 0.75rem 1rem; border-radius: 14px; line-height: 1.7; max-width: 90%; }
.chat-bubble.me { background: var(--accent-soft); justify-self: start; }
.chat-bubble.bot { background: #fff; border: 1px solid var(--line); justify-self: end; }
.cam-wrap {
  position: relative; width: 100%; min-height: 200px; max-height: 320px; overflow: hidden;
  border-radius: 12px; background: #111;
}
.cam-wrap video { width: 100%; max-height: 320px; display: block; object-fit: cover; background: #111; }
.cam-placeholder {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.72); font-size: 0.9rem; text-align: center; padding: 1rem;
  pointer-events: none;
}
.cam-placeholder[hidden] { display: none; }
.cam-crosshair {
  position: absolute; inset: 50% auto auto 50%;
  width: 28px; height: 28px; margin: -14px 0 0 -14px;
  border: 2px solid rgba(255,255,255,.9); border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(0,0,0,.25);
  pointer-events: none;
}
.cam-crosshair[hidden] { display: none; }

/* Seller product image gallery + lightbox zoom */
.seller-media-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
  max-width: 100%;
  min-width: 0;
}
.seller-media-tools .btn,
.seller-media-tools > label.btn {
  max-width: 100%;
}
.seller-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(96px, 100%), 1fr));
  gap: 0.55rem;
  margin: 0.75rem 0 0.25rem;
  max-width: 100%;
  min-width: 0;
}
.seller-gallery:empty { display: none; }
.seller-thumb {
  position: relative;
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #eef5f2;
  cursor: zoom-in;
}
.seller-thumb img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform 0.2s ease;
}
.seller-thumb:hover img { transform: scale(1.04); }
.seller-thumb.is-primary { outline: 2px solid var(--accent); outline-offset: 1px; }
.seller-thumb .thumb-badge {
  position: absolute; top: 4px; right: 4px;
  background: rgba(11, 107, 88, 0.92); color: #fff;
  font-size: 0.65rem; padding: 2px 6px; border-radius: 6px;
}
.seller-thumb .thumb-remove {
  position: absolute; top: 4px; left: 4px;
  width: 24px; height: 24px; border: 0; border-radius: 50%;
  background: rgba(0,0,0,.55); color: #fff; cursor: pointer;
  font-size: 14px; line-height: 1;
}
.seller-thumb .thumb-primary-btn {
  position: absolute; bottom: 4px; right: 4px; left: 4px;
  border: 0; border-radius: 6px; padding: 3px 4px;
  font-size: 0.65rem; cursor: pointer;
  background: rgba(255,255,255,.9); color: #064739;
}
.seller-media-meta { font-size: 0.8rem; color: var(--muted); margin-top: 0.35rem; }
.seller-multi-cam-opt {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0.55rem 0 0.35rem;
  font-size: 0.85rem;
  color: var(--text);
  cursor: pointer;
  user-select: none;
}
.seller-multi-cam-opt input { width: 1rem; height: 1rem; accent-color: var(--accent); }
.cam-multi-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin: 0.55rem 0 0.25rem;
  padding: 0.65rem 0.75rem;
  border-radius: 12px;
  border: 1px dashed var(--line);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  max-width: 100%;
  min-width: 0;
}
.cam-multi-bar[hidden] { display: none !important; }
.cam-multi-bar > span { font-weight: 600; font-size: 0.9rem; margin-inline-end: auto; }
.gallery-approve-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin: 0.45rem 0 0.35rem;
  padding: 0.6rem 0.75rem;
  border-radius: 12px;
  border: 1px solid rgba(11, 107, 88, 0.28);
  background: rgba(11, 107, 88, 0.06);
  max-width: 100%;
  min-width: 0;
}
.gallery-approve-bar[hidden] { display: none !important; }
.gallery-approve-bar > span {
  font-weight: 700;
  font-size: 0.88rem;
  margin-inline-end: auto;
}
.seller-thumb.is-gallery {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.seller-thumb.is-rejected {
  opacity: 0.55;
  filter: grayscale(0.35);
}
.seller-thumb.is-rejected.is-gallery { opacity: 1; filter: none; }
.thumb-approve {
  position: absolute;
  top: 4px;
  right: 4px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  background: rgba(255, 255, 255, 0.94);
  border-radius: 8px;
  padding: 2px 6px;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent-deep);
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0,0,0,.18);
}
.thumb-approve input {
  width: 0.95rem;
  height: 0.95rem;
  accent-color: var(--accent);
  margin: 0;
}
.seller-thumb.is-primary .thumb-badge {
  top: 28px;
}
.seller-thumb .thumb-index {
  position: absolute;
  top: 28px;
  right: 4px;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 6px;
}
.seller-thumb.is-primary {
  outline-color: var(--accent-warm);
}
.cam-snap-flash {
  position: absolute; inset: 0;
  background: #fff;
  opacity: 0;
  pointer-events: none;
  z-index: 3;
}
.cam-snap-flash.is-flash {
  animation: camFlash 0.28s ease-out;
}
@keyframes camFlash {
  0% { opacity: 0.75; }
  100% { opacity: 0; }
}
.cam-live-count {
  position: absolute;
  top: 10px;
  left: 10px;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.45rem;
  border-radius: 999px;
  background: rgba(11, 107, 88, 0.92);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  display: grid;
  place-items: center;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
}
.cam-live-count[hidden] { display: none !important; }


.seller-desk-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  margin: 0.5rem 0 1rem;
  flex-wrap: wrap;
}
.seller-nav {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
  margin: 0 0 1rem;
}
.seller-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  text-align: right;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 14px;
  padding: 0.7rem 0.85rem;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}
.seller-nav-btn small {
  color: var(--muted);
  font-size: 0.72rem;
}
.seller-nav-ico {
  color: var(--accent-deep);
  font-size: 0.95rem;
  line-height: 1;
  margin-bottom: 0.1rem;
}
.seller-nav-btn:hover {
  border-color: rgba(11, 107, 88, 0.35);
  background: rgba(11, 107, 88, 0.04);
}
.seller-nav-btn.active {
  border-color: var(--accent);
  background: linear-gradient(160deg, rgba(11, 107, 88, 0.1), #fff 70%);
  box-shadow: 0 6px 18px rgba(15, 92, 76, 0.08);
  font-weight: 700;
}
.seller-pane { display: none; }
.seller-pane.is-active { display: block; }
.seller-pane-head {
  margin: 0 0 0.75rem;
}
.seller-pane-head h2 {
  margin: 0;
  font-size: 1.15rem;
}
.seller-settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}
.seller-setting-card {
  margin: 0;
}
.seller-setting-wide {
  grid-column: 1 / -1;
}
.seller-setting-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.55rem;
}
.seller-setting-head h3 {
  margin: 0;
  font-size: 1.02rem;
}
@media (max-width: 820px) {
  .seller-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .seller-settings-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .seller-nav { grid-template-columns: 1fr; }
}
.seller-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: start;
  margin-top: 0;
}
.product-form {
  max-width: 960px;
}
.pf-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem 0.85rem;
}
.pf-grid .field { margin: 0; }
.pf-span-2 { grid-column: span 2; }
.pf-grid-color {
  grid-template-columns: 1fr auto auto;
  align-items: end;
}
.icon-choice-grid {
  display: none;
  grid-template-columns: repeat(auto-fill, minmax(4.6rem, 1fr));
  gap: 0.45rem;
  margin-top: 0.45rem;
  max-width: 100%;
}
.icon-choice {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  min-height: 4.25rem;
  padding: 0.45rem 0.3rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
  transition: border-color 0.15s, background 0.15s, transform 0.12s, box-shadow 0.15s;
}
.icon-choice:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.icon-choice.is-selected {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 2px rgba(11, 107, 88, 0.22);
  font-weight: 700;
}
.icon-choice-ico {
  font-size: 1.35rem;
  line-height: 1;
}
.icon-choice-lbl {
  font-size: 0.72rem;
  text-align: center;
  line-height: 1.25;
  max-width: 100%;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.color-swatch-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.5rem;
  margin-top: 0.35rem;
  max-width: 100%;
}
.color-swatch-pick {
  position: relative;
  aspect-ratio: 1.15;
  min-height: 3.6rem;
  border: 2px solid rgba(0,0,0,.12);
  border-radius: 12px;
  background: var(--swatch, #ccc);
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0.35rem;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18);
}
.color-swatch-pick.is-selected {
  outline: 3px solid var(--accent);
  outline-offset: 1px;
  border-color: #fff;
}
.color-swatch-name {
  font-size: 0.85rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,.55);
  background: rgba(0,0,0,.28);
  padding: 0.2rem 0.45rem;
  border-radius: 8px;
}
.color-swatch-pick.is-light .color-swatch-name {
  color: #1a1a1a;
  text-shadow: none;
  background: rgba(255,255,255,.72);
}
@media (max-width: 820px) {
  .product-form .pf-select-native {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
  }
  .product-form .icon-choice-grid {
    display: grid;
  }
  .color-swatch-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
@media (max-width: 420px) {
  .icon-choice-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .color-swatch-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .color-swatch-pick {
    min-height: 4.2rem;
  }
}
@media (min-width: 821px) {
  .product-form .icon-choice-grid {
    display: grid;
  }
  .product-form .pf-select-native {
    margin-bottom: 0.25rem;
  }
}
@media (max-width: 820px) {
  .pf-grid { grid-template-columns: 1fr 1fr; }
  .pf-span-2 { grid-column: span 2; }
  .pf-grid-color { grid-template-columns: 1fr auto auto; }
}
@media (max-width: 560px) {
  .pf-grid { grid-template-columns: 1fr; }
  .pf-span-2 { grid-column: span 1; }
  .pf-grid-color { grid-template-columns: 1fr; }
}
.product-form-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
  min-width: 0;
}
.barcode-lookup-box {
  margin-bottom: 0.9rem;
  background: linear-gradient(160deg, rgba(11, 107, 88, 0.06), transparent 70%);
  border: 1px dashed rgba(11, 107, 88, 0.35);
}
.barcode-cam-wrap {
  position: relative;
  margin-top: 10px;
  border-radius: 12px;
  overflow: hidden;
  background: #111;
  max-width: 420px;
}
.barcode-cam-wrap video {
  display: block;
  width: 100%;
  max-height: 280px;
  object-fit: cover;
}
.barcode-cam-hint {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.45rem 0.7rem;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 0.82rem;
  text-align: center;
}
.barcode-suggestions {
  margin-top: 8px;
  display: grid;
  gap: 6px;
}
.barcode-suggestions button {
  text-align: right;
  width: 100%;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
}
.barcode-suggestions button:hover {
  border-color: var(--accent);
}
.pf-section {
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 0.75rem;
  background: var(--bg-soft, #f7faf8);
}
.pf-section summary {
  cursor: pointer;
  font-weight: 700;
  padding: 0.75rem 0.9rem;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.pf-section summary::-webkit-details-marker { display: none; }
.pf-section-sum-ico { font-size: 1.1rem; line-height: 1; }
.pf-section-chevron {
  margin-inline-start: auto;
  width: 0.55rem;
  height: 0.55rem;
  border-inline-end: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}
.pf-section[open] > summary .pf-section-chevron {
  transform: rotate(225deg);
}
.pf-body { padding: 0 0.9rem 0.9rem; }
.attr-field-ico {
  display: inline-block;
  margin-inline-end: 0.25rem;
  font-size: 1rem;
  line-height: 1;
}
.attr-icons-hint {
  margin: 0 0 0.65rem;
}
.pf-attr-section:not([open]) .icon-choice-grid {
  display: none !important;
}
.pf-attr-section[open] .icon-choice-grid,
.pf-attr-section.is-open-icons .icon-choice-grid {
  display: grid;
}
.pf-attr-section[open] .attr-field .pf-select-native {
  margin-bottom: 0.2rem;
}
@media (max-width: 820px) {
  .pf-attr-section[open] .attr-field .pf-select-native {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    border: 0 !important;
  }
}
.product-form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
}
.wiz-form { max-width: 1100px; }
.wiz-preview-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  color: var(--muted);
  cursor: pointer;
  user-select: none;
}
.wiz-shell {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}
.wiz-rail {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  position: sticky;
  top: 0.75rem;
}
.wiz-step-btn {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 0.55rem;
  text-align: right;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 12px;
  padding: 0.55rem 0.65rem;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
}
.wiz-step-btn span {
  grid-row: 1 / span 2;
  align-self: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 999px;
  background: var(--bg-deep);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
}
.wiz-step-btn b { font-size: 0.88rem; }
.wiz-step-btn small { grid-column: 2; color: var(--muted); font-size: 0.72rem; }
.wiz-step-btn.active {
  border-color: var(--accent);
  background: linear-gradient(160deg, rgba(11,107,88,.1), #fff 70%);
}
.wiz-step-btn.done span { background: var(--accent); color: #fff; }
.wiz-step-btn:disabled { opacity: 0.45; cursor: default; }
.wiz-main {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 0.9rem;
  background: #fff;
}
.wiz-progress {
  height: 6px;
  border-radius: 999px;
  background: var(--bg-deep);
  overflow: hidden;
  margin-bottom: 0.65rem;
}
.wiz-progress i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), #2f9e86);
  border-radius: inherit;
  transition: width .2s ease;
}
.wiz-step-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  font-size: 0.9rem;
  flex-wrap: wrap;
  min-width: 0;
}
.wiz-pane { display: none; }
.wiz-pane.is-active { display: block; }
.wiz-optional-banner {
  margin-bottom: 0.75rem;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  background: rgba(196, 140, 58, 0.1);
  color: #8a5a12;
  font-size: 0.86rem;
}
.wiz-opt-row { margin-top: 0.85rem; }
.wiz-nav {
  position: sticky;
  bottom: 0;
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.86), #fff 40%);
  z-index: 2;
}
.wiz-found-card {
  margin-top: 0.85rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(11, 107, 88, 0.04);
}
.wiz-found-inner {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 0.75rem;
  align-items: center;
}
.wiz-found-media {
  width: 88px;
  height: 88px;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
}
.wiz-preview-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(10, 24, 20, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.wiz-preview-modal[hidden] { display: none !important; }
.wiz-preview-card {
  width: min(720px, 100%);
  max-height: min(90vh, 860px);
  overflow: auto;
  margin: 0;
}
.wiz-preview-grid {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 1rem;
}
.wiz-preview-media {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 14px;
  background-size: cover;
  background-position: center;
}
.wiz-preview-kv {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem 0.75rem;
  margin-top: 0.75rem;
}
.wiz-preview-kv div {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.4rem 0.5rem;
  border-radius: 8px;
  background: var(--bg-deep);
  font-size: 0.86rem;
}
.wiz-preview-kv span { color: var(--muted); }
@media (max-width: 900px) {
  .wiz-shell {
    grid-template-columns: minmax(0, 1fr);
    min-width: 0;
  }
  .wiz-rail {
    position: static;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 0.25rem;
    gap: 0.35rem;
    min-width: 0;
    max-width: 100%;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
  }
  .wiz-step-btn {
    min-width: 7.5rem;
    flex: 0 0 auto;
  }
}
@media (max-width: 560px) {
  .wiz-found-inner,
  .wiz-preview-grid,
  .wiz-preview-kv { grid-template-columns: minmax(0, 1fr); }
  .wiz-step-btn {
    min-width: 5.75rem;
    padding: 0.45rem 0.55rem;
  }
  .wiz-step-btn small { display: none; }
  .wiz-nav .btn { flex: 1 1 auto; }
  .wiz-preview-toggle { width: 100%; }
}
.product-form select,
.seller-filters select,
.seller-filters input {
  width: 100%;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
}
.seller-filters {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem 0.75rem;
  margin-bottom: 1rem;
  padding: 0.85rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-soft, #f7faf8);
}
.seller-filters .field { margin: 0; }
.seller-filters label {
  display: block;
  font-size: 0.78rem;
  color: var(--muted);
  margin-bottom: 0.25rem;
}
.seller-filter-actions .btn { width: 100%; }
@media (max-width: 900px) {
  .seller-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .seller-filters { grid-template-columns: 1fr; }
}
.seller-catalog-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
}
.view-toggle {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.view-btn {
  border: 0;
  background: #fff;
  padding: 0.45rem 0.75rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--muted);
}
.view-btn.active {
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-weight: 700;
}
.seller-mine.is-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(230px, 100%), 1fr));
  gap: 0.9rem;
}
.seller-mine.is-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.seller-mine.is-list .seller-card-body {
  min-width: 0;
}
.seller-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--line);
}
.seller-pager-info {
  font-size: 0.85rem;
  color: var(--muted);
}
.seller-pager-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}
.pager-btn {
  min-width: 2.1rem;
  height: 2.1rem;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
}
.pager-btn:hover:not(:disabled) {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.pager-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 700;
}
.pager-btn:disabled {
  opacity: 0.4;
  cursor: default;
}
.pager-ellipsis {
  color: var(--muted);
  padding: 0 0.2rem;
}
.seller-page-size {
  margin: 0;
  min-width: 110px;
}
.seller-page-size select {
  width: 100%;
}
.seller-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
  transition: box-shadow .15s ease, transform .15s ease;
}
.seller-card:hover {
  box-shadow: 0 8px 24px rgba(15, 92, 76, 0.08);
  transform: translateY(-1px);
}
.seller-mine.is-list .seller-card {
  flex-direction: row;
  align-items: stretch;
}
.seller-mine.is-list .seller-card-media {
  width: 120px;
  min-height: 120px;
  flex-shrink: 0;
}
.seller-card.is-off { opacity: 0.72; }
.seller-card-media {
  height: 160px;
  background-size: cover;
  background-position: center;
  position: relative;
}
.card-chip {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(255,255,255,.92);
  color: #064739;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: 999px;
}
.badge-warn {
  background: #fff4e5;
  color: #9a5b00;
}
.seller-card-body {
  padding: 0.75rem 0.85rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}
.seller-card-body h3 {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.45;
}
.seller-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}
.seller-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: auto;
  padding-top: 0.45rem;
}
.seller-card-actions .btn {
  padding: 0.4rem 0.65rem;
  font-size: 0.8rem;
}
.existing-images { margin-bottom: 0.75rem; }
.base-attrs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.55rem 0.75rem;
}
.base-attrs div {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.45rem 0.55rem;
  border-radius: 10px;
  background: var(--bg-soft, #f7faf8);
  border: 1px solid var(--line);
}
.base-attrs span { font-size: 0.72rem; color: var(--muted); }
.base-attrs b { font-size: 0.88rem; font-weight: 700; }

body.lightbox-open { overflow: hidden; }
.media-lightbox {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(8, 16, 14, 0.88);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 1rem;
  touch-action: none;
}
.media-lightbox[hidden] { display: none !important; }
.media-lightbox-stage {
  flex: 1; width: 100%; max-width: 960px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.media-lightbox-img {
  max-width: 100%; max-height: min(82vh, 900px);
  object-fit: contain; border-radius: 8px;
  cursor: zoom-in; transform-origin: center center;
  transition: transform 0.15s ease; user-select: none;
  -webkit-user-drag: none;
}
.media-lightbox-img.zoomed { cursor: grab; transition: none; }
.media-lightbox-close {
  position: absolute; top: 12px; left: 12px;
  width: 40px; height: 40px; border: 0; border-radius: 50%;
  background: rgba(255,255,255,.15); color: #fff;
  font-size: 1.5rem; cursor: pointer; line-height: 1;
}
.media-lightbox-hint {
  color: rgba(255,255,255,.7); font-size: 0.8rem; margin-top: 0.5rem;
}
.funnel { display: grid; gap: 0.45rem; margin: 0.8rem 0 1rem; }
.funnel-bar {
  background: var(--accent); color: #fff; border-radius: 10px;
  padding: 0.45rem 0.75rem; font-size: 0.85rem; min-width: 28%;
}
.funnel-bar.cart { background: #2f7d6d; }
.funnel-bar.buy { background: var(--accent-warm); }
.nps-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1rem; }
.nps-btn {
  width: 42px; height: 42px; border-radius: 10px; border: 1px solid var(--line);
  background: #fff; cursor: pointer; font-weight: 700;
}
.nps-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Admin console */
.admin-shell {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 1.25rem;
  align-items: start;
  margin-bottom: 2rem;
}
.admin-aside {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem 0.65rem;
  position: sticky;
  top: calc(var(--header-h) + 12px);
}
.admin-aside-title {
  font-weight: 800;
  font-size: 0.95rem;
  padding: 0.35rem 0.65rem 0.75rem;
  color: var(--accent);
}
.admin-nav { display: grid; gap: 0.2rem; }
.admin-nav-item {
  display: block;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  color: var(--muted);
  font-size: 0.9rem;
  transition: background 0.15s, color 0.15s;
}
.admin-nav-item:hover { background: var(--accent-soft); color: var(--accent); }
.admin-nav-item.active {
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}
.base-tab.active {
  background: var(--accent) !important;
  color: #fff !important;
  border-color: var(--accent) !important;
}
.admin-main { min-width: 0; }
.admin-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.admin-head h1 { margin: 0; font-size: 1.45rem; font-family: var(--font-display); }
.admin-table-wrap { overflow-x: auto; }
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.admin-table th, .admin-table td {
  text-align: right;
  padding: 0.65rem 0.5rem;
  border-bottom: 1px solid var(--line-soft);
  vertical-align: middle;
}
.admin-table th { color: var(--muted); font-weight: 600; font-size: 0.82rem; }
.admin-actions { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.admin-table select {
  padding: 0.35rem 0.5rem;
  border-radius: 8px;
  border: 1px solid var(--line);
  margin-left: 0.35rem;
}
@media (max-width: 900px) {
  .admin-shell { grid-template-columns: 1fr; }
  .admin-aside { position: static; }
  .admin-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
  }
  .admin-nav-item { font-size: 0.82rem; padding: 0.45rem 0.65rem; }
}

/* Footer */
.site-footer {
  background:
    radial-gradient(ellipse 50% 80% at 0% 100%, rgba(11, 107, 88, 0.12) 0%, transparent 50%),
    linear-gradient(180deg, #ffffff 0%, #f0f7f4 100%);
  border-top: 1px solid var(--line);
  margin-top: 2.5rem;
  padding: 2.25rem 0 1.25rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 1.5rem;
  align-items: start;
}
.footer-dyn {
  display: contents;
}
.footer-grid .footer-dyn > div,
.footer-grid > div,
.footer-grid > .footer-acc {
  min-width: 0;
}
.footer-acc {
  border: 0;
  margin: 0;
  padding: 0;
  background: transparent;
}
.footer-acc-sum {
  list-style: none;
  cursor: default;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 0.65rem;
  font-size: 0.95rem;
  font-weight: 800;
  font-family: var(--font-display);
  color: var(--ink);
}
.footer-acc-sum::-webkit-details-marker { display: none; }
.footer-acc-chevron {
  display: none;
  width: 0.55rem;
  height: 0.55rem;
  border-inline-end: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}
.footer-acc[open] > .footer-acc-sum .footer-acc-chevron {
  transform: rotate(225deg);
}
.footer-acc-body a,
.footer-acc-body p,
.footer-grid a,
.footer-grid p {
  display: block; color: var(--muted); font-size: 0.88rem; line-height: 1.9; margin: 0;
}
.footer-acc-body a:hover,
.footer-grid a:hover { color: var(--accent); }
.footer-bottom {
  margin-top: 1.5rem; padding-top: 1rem;
  border-top: 1px solid var(--line-soft);
  color: var(--muted); font-size: 0.82rem;
}
@media (max-width: 720px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .footer-dyn {
    display: block;
  }
  .site-footer {
    padding: 1rem 0 1rem;
  }
  .footer-acc {
    border-bottom: 1px solid var(--line-soft);
  }
  .footer-acc-sum {
    cursor: pointer;
    margin: 0;
    padding: 0.85rem 0.15rem;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
  }
  .footer-acc-chevron {
    display: inline-block;
  }
  .footer-acc-body {
    padding: 0 0.15rem 0.85rem;
  }
  .footer-about .footer-brand {
    margin-top: 0.15rem;
  }
  .footer-bottom {
    margin-top: 0.75rem;
    padding-top: 0.85rem;
    text-align: center;
  }
}

/* Themes */
html[data-theme="editorial"] {
  --bg: #f0f4f2; --ink: #14201c; --muted: #5a6b64;
  --accent: #1a4d42; --accent-2: #c46a3a; --card: #fffcf9; --line: #d5e0db;
}
html[data-theme="soft"] {
  --bg: #eef6f3; --ink: #14201c; --muted: #5a6b64;
  --accent: #0b6b58; --accent-2: #c46a3a; --card: #ffffff; --line: #d5e3dd;
}
html[data-theme="soft"] body {
  background:
    radial-gradient(circle at 10% 0%, rgba(255, 248, 238, 0.9) 0%, transparent 40%),
    radial-gradient(circle at 90% 10%, rgba(216, 239, 232, 0.95) 0%, transparent 35%),
    var(--bg);
}

/* iShop denser commerce skin */
html[data-theme="ishop"] {
  --bg: #f3f5f7;
  --bg-soft: #fafbfc;
  --ink: #1a1d21;
  --muted: #667085;
  --accent: #0f766e;
  --accent-hover: #0d9488;
  --accent-deep: #115e59;
  --accent-soft: #ccfbf1;
  --accent-2: #e11d48;
  --accent-warm: #ea580c;
  --card: #ffffff;
  --line: #e4e7ec;
  --radius: 10px;
  --shadow: 0 1px 3px rgba(16, 24, 40, 0.06);
}
html[data-theme="ishop"] body {
  background: linear-gradient(180deg, #f8fafc 0%, #f3f5f7 40%, #eef2f6 100%);
}
html[data-theme="ishop"] .card .swatch { border-radius: 8px 8px 0 0; }
html[data-theme="ishop"] .announce-bar {
  background: linear-gradient(90deg, #0f766e, #134e4a);
}

/* Lebasino fashion boutique skin — crimson accent, clean boutique */
html[data-theme="lebasino"] {
  --bg: #f7f5f6;
  --bg-soft: #fbfafb;
  --ink: #1c1418;
  --muted: #6b5f66;
  --accent: #b42346;
  --accent-hover: #91203b;
  --accent-deep: #7a1832;
  --accent-soft: #fce7ee;
  --accent-2: #1c1418;
  --accent-warm: #9a3412;
  --accent-gold: #a16207;
  --card: #ffffff;
  --line: #e8e0e4;
  --radius: 8px;
  --shadow: 0 1px 2px rgba(28, 20, 24, 0.05);
  --shadow-md: 0 8px 24px rgba(28, 20, 24, 0.08);
  --font-display: "Estedad Variable", "Estedad", "Vazirmatn", Tahoma, sans-serif;
}
html[data-theme="lebasino"] body {
  background:
    linear-gradient(180deg, #fcfafb 0%, #f7f5f6 35%, #f2eef1 100%);
}
html[data-theme="lebasino"] .brand span { color: var(--accent); }
html[data-theme="lebasino"] .site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
}
html[data-theme="lebasino"] .card {
  border-radius: 8px;
  overflow: hidden;
}
html[data-theme="lebasino"] .card .swatch {
  border-radius: 0;
  aspect-ratio: 3 / 4;
}
html[data-theme="lebasino"] .card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
}
html[data-theme="lebasino"] .btn.warm,
html[data-theme="lebasino"] .btn:not(.secondary) {
  background: var(--accent);
}
html[data-theme="lebasino"] .btn:not(.secondary):hover {
  background: var(--accent-hover);
}
html[data-theme="lebasino"] .stories-rail .story-avatar {
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--accent);
}
html[data-theme="lebasino"] .cat-chip .ring {
  border-radius: 12px;
}

.theme-btn.active-skin {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--ink);
  font-weight: 600;
}
.skin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.75rem;
  margin-top: 0.75rem;
}
.skin-card {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.85rem;
  cursor: pointer;
  background: var(--card);
}
.skin-card.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-soft);
}
.skin-card input { margin-top: 0.2rem; }
.catalog-list {
  display: flex !important;
  flex-direction: column;
  gap: 0.65rem;
}
.catalog-list .card-wrap {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: 0.75rem;
  align-items: center;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.5rem;
}
.catalog-list .card {
  display: contents;
}
.catalog-list .card .swatch {
  width: 120px;
  height: 120px;
  border-radius: 8px;
  margin: 0;
}
.catalog-list .card .body { padding: 0; }
.catalog-list .card-actions { flex-direction: column; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

@media (max-width: 900px) {
  .header-main { grid-template-columns: auto 1fr; gap: 0.75rem; }
  .header-actions { grid-column: 1 / -1; justify-content: flex-end; }
  .search-box { order: 3; }
  .home-section {
    width: min(1280px, calc(100% - 1.25rem));
    max-width: 100%;
  }
  .home-section:has(.carousel) {
    width: min(1280px, calc(100% - 1rem));
    margin-top: 1rem;
  }
  .carousel {
    aspect-ratio: 16 / 9;
    min-height: 200px;
    max-height: min(420px, 56vw);
    border-radius: 16px;
    width: 100%;
  }
  .carousel-slide {
    padding: 1.15rem 1.15rem 2.1rem;
  }
  .carousel-slide strong {
    font-size: clamp(1.15rem, 4.6vw, 1.7rem);
  }
  .carousel-slide p {
    font-size: 0.88rem;
    max-width: 100%;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .carousel-btn {
    width: 36px;
    height: 36px;
    font-size: 1.05rem;
  }
  .carousel-btn.prev { inset-inline-start: 8px; }
  .carousel-btn.next { inset-inline-end: 8px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .brand { font-size: 1.45rem; }
  .h-action span:not(.h-ico):not(.cart-badge) { display: none; }
  .home-section:has(.carousel) {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
    padding-inline: 0.5rem;
    box-sizing: border-box;
  }
  .carousel {
    aspect-ratio: 5 / 4;
    min-height: 210px;
    max-height: min(360px, 72vw);
    border-radius: 14px;
    width: 100%;
    margin: 0;
  }
  .carousel-btn { display: none; }
  .carousel-slide {
    padding: 0.95rem 0.9rem 1.85rem;
  }
  .carousel-slide .slide-kicker {
    font-size: 0.68rem;
    padding: 0.15rem 0.5rem;
    margin-bottom: 0.4rem;
  }
  .carousel-slide strong {
    font-size: 1.12rem;
    line-height: 1.35;
  }
  .carousel-slide p {
    font-size: 0.8rem;
    line-height: 1.55;
    margin-top: 0.35rem;
    -webkit-line-clamp: 2;
  }
  .carousel-dots {
    bottom: 8px;
    gap: 5px;
  }
  .footer-grid { grid-template-columns: 1fr; }
  .rail .card { min-width: 150px; max-width: 150px; }
}

.insight-samples {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.65rem;
  max-height: 7.5rem;
  overflow: hidden;
}
.insight-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  max-width: 220px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.28rem 0.55rem 0.28rem 0.7rem;
  cursor: pointer;
  font: inherit;
  text-align: right;
}
.insight-chip:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.insight-chip-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.82rem;
  color: var(--ink);
}
.insight-chip-stock {
  flex-shrink: 0;
  min-width: 1.4rem;
  height: 1.4rem;
  border-radius: 999px;
  background: #f3e0d6;
  color: #8a3b1d;
  font-size: 0.72rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0.3rem;
}
.insight-more {
  align-self: center;
  padding-inline: 0.35rem;
}

/* iShop experience */
.announce-bar {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
  background: linear-gradient(90deg, #0b6b58, #14532d);
  color: #fff;
  border-radius: 14px;
  padding: 0.7rem 1rem;
  margin-bottom: 12px;
}
.announce-bar a { color: #ffe8c7; }
.stories-rail {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding: 0.25rem 0 0.5rem;
}
.story-ring {
  border: 0;
  background: transparent;
  cursor: pointer;
  width: 76px;
  text-align: center;
  font: inherit;
  color: inherit;
  flex: 0 0 auto;
}
.story-avatar {
  display: block;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  margin: 0 auto 0.35rem;
  background-size: cover;
  background-position: center;
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px #c46a3a;
}
.story-label { font-size: 0.72rem; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.story-viewer {
  position: fixed; inset: 0; z-index: 80; background: rgba(0,0,0,.88);
  display: flex; align-items: center; justify-content: center;
}
.story-viewer-inner {
  width: min(420px, 94vw); height: min(720px, 92vh); position: relative;
  border-radius: 18px; overflow: hidden; background: #111; color: #fff;
}
.story-media { position: absolute; inset: 0; background-size: cover; background-position: center; }
.story-meta { position: absolute; inset-inline: 0; bottom: 0; padding: 1rem; background: linear-gradient(transparent, rgba(0,0,0,.75)); }
.story-progress { position: absolute; inset-inline: 10px; top: 10px; display: flex; gap: 4px; z-index: 2; }
.story-progress i { flex: 1; height: 3px; background: rgba(255,255,255,.3); border-radius: 2px; }
.story-progress i.on { background: #fff; }
.story-x { position: absolute; top: 18px; inset-inline-start: 12px; z-index: 3; border: 0; background: transparent; color: #fff; font-size: 1.6rem; cursor: pointer; }
.card-wrap { position: relative; }
.card-actions {
  display: flex; gap: 0.35rem; margin-top: 0.35rem; flex-wrap: wrap;
}
.card-act {
  border: 1px solid var(--line); background: #fff; border-radius: 999px;
  padding: 0.25rem 0.55rem; font: inherit; font-size: 0.75rem; cursor: pointer; color: var(--muted);
}
.card-act:hover { border-color: var(--accent); color: var(--ink); }
.qv-modal[hidden] { display: none !important; }
.qv-modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; }
.qv-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.45); }
.qv-panel { position: relative; z-index: 1; width: min(860px, 94vw); max-height: 90vh; overflow: auto; }
.qv-close { position: absolute; top: 8px; inset-inline-start: 10px; border: 0; background: transparent; font-size: 1.5rem; cursor: pointer; }
.qv-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 1rem; }
.qv-media { min-height: 260px; border-radius: 14px; background-size: cover; background-position: center; }
@media (max-width: 720px) { .qv-grid { grid-template-columns: 1fr; } }
.compare-bar {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 60;
  background: rgba(255,255,255,.96); border-top: 1px solid var(--line);
  padding: 0.55rem 0.75rem; backdrop-filter: blur(8px);
}
.compare-bar-inner { max-width: 1100px; margin: 0 auto; display: flex; gap: 0.5rem; align-items: center; flex-wrap: wrap; }
.compare-chip { font-size: 0.78rem; background: var(--accent-soft); padding: 0.25rem 0.55rem; border-radius: 999px; }
.av-toast {
  position: fixed; bottom: 5.5rem; inset-inline: 50%; transform: translateX(50%);
  background: #0b6b58; color: #fff; padding: 0.65rem 1rem; border-radius: 999px;
  opacity: 0; pointer-events: none; transition: .2s; z-index: 90;
  max-width: calc(100vw - 2rem);
  white-space: normal;
  text-align: center;
}
.av-toast.show { opacity: 1; transform: translateX(50%) translateY(-4px); }
html[dir="rtl"] .av-toast { transform: translateX(-50%); }
html[dir="rtl"] .av-toast.show { transform: translateX(-50%) translateY(-4px); }
.review-ai-summary { background: var(--accent-soft); border-radius: 12px; padding: 0.75rem 0.9rem; margin-bottom: 10px; }
.review-card { border-bottom: 1px solid var(--line); padding: 0.65rem 0; }
.price-chart { color: var(--accent); margin-top: 6px; }
.brand-card { text-decoration: none; color: inherit; transition: .15s; }
.brand-card:hover { border-color: var(--accent); }
.faq-item summary { cursor: pointer; }
.invoice-print { max-width: 760px; margin: 0 auto; }
.table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  min-width: 0;
}
.table {
  width: 100%;
  border-collapse: collapse;
}
.compare-table {
  min-width: 480px;
}
.row {
  max-width: 100%;
  min-width: 0;
}
.field input,
.field textarea,
.field select,
.product-form input,
.product-form textarea,
.product-form select {
  max-width: 100%;
}
.wiz-step-meta {
  flex-wrap: wrap;
  min-width: 0;
}

/* —— Mobile overflow containment —— */
@media (max-width: 900px) {
  .container,
  #app {
    width: min(1280px, calc(100% - 1.25rem));
  }
  .header-main {
    min-width: 0;
  }
  .search-box,
  .header-actions {
    min-width: 0;
    max-width: 100%;
  }
  .brand {
    font-size: 1.45rem;
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .cam-multi-bar .btn {
    flex: 1 1 auto;
  }
  .barcode-lookup-box .row {
    flex-wrap: wrap;
  }
  .barcode-lookup-box input {
    min-width: 0 !important;
    width: 100%;
    flex: 1 1 100%;
  }
  .site-footer,
  .footer-grid {
    max-width: 100%;
    overflow-wrap: anywhere;
  }
}
@media (max-width: 560px) {
  .container,
  #app {
    width: calc(100% - 1rem);
    margin-inline: auto;
  }
  .topbar-inner {
    gap: 0.45rem;
  }
  .topbar-links,
  .topbar-meta {
    gap: 0.45rem;
    font-size: 0.72rem;
  }
  .seller-media-tools .btn,
  .seller-media-tools > label.btn {
    flex: 1 1 calc(50% - 0.35rem);
    justify-content: center;
    text-align: center;
    padding-inline: 0.55rem;
    font-size: 0.82rem;
  }
  .seller-card-actions {
    flex-wrap: wrap;
  }
  .seller-card-actions .btn {
    flex: 1 1 auto;
  }
  .compare-bar-inner {
    max-width: 100%;
  }
  .panel {
    padding-inline: 0.85rem;
  }
  input, textarea, select, button {
    max-width: 100%;
  }
}

@media print {
  .topbar, .site-header, .site-footer, .compare-bar, .av-toast, .admin-aside { display: none !important; }
  .invoice-print { box-shadow: none; border: 0; }
}
