/* ============================================================
   فروشگاه حرفه‌ای اینم کار — Storefront Pro
   فونت Vazirmatn از utilities/font.css (محلی) لود می‌شود
   ============================================================ */

:root {
  --sf-primary: #f97316;
  --sf-primary-dark: #ea580c;
  --sf-primary-soft: #fff7ed;
  --sf-accent: #0ea5e9;
  --sf-bg: #f1f5f9;
  --sf-surface: #ffffff;
  --sf-text: #0f172a;
  --sf-muted: #64748b;
  --sf-border: #e2e8f0;
  --sf-radius: 18px;
  --sf-radius-sm: 12px;
  --sf-shadow: 0 8px 30px rgba(15, 23, 42, 0.08);
  --sf-shadow-sm: 0 2px 10px rgba(15, 23, 42, 0.05);
  --sf-max: 1240px;
  --sf-font: "Vazirmatn", Tahoma, system-ui, sans-serif;
  --sf-topbar-h: 40px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body.storefront {
  margin: 0; padding: 0;
  font-family: var(--sf-font);
  background: var(--sf-bg);
  color: var(--sf-text);
  min-height: 100vh;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select { font-family: inherit; }

/* ---------- Topbar ---------- */
.sf-topbar {
  background: linear-gradient(90deg, #0f172a, #1e293b);
  color: #cbd5e1;
  font-size: .8rem;
  position: sticky;
  top: 0;
  z-index: 100;
}
.sf-topbar-inner {
  max-width: var(--sf-max);
  margin: 0 auto;
  padding: 8px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.sf-top-link { color: #e2e8f0; transition: color .15s; }
.sf-top-link:hover { color: var(--sf-primary); }
.sf-top-sep { opacity: .35; margin: 0 6px; }
.sf-badge-verified {
  color: #34d399;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.sf-badge-owner {
  background: var(--sf-primary);
  color: #fff;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 700;
}

/* ---------- Header / Banner ---------- */
.sf-header { background: var(--sf-surface); box-shadow: var(--sf-shadow-sm); }
.sf-banner {
  height: clamp(150px, 30vw, 280px);
  background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 45%, #c2410c 130%);
  background-size: cover;
  background-position: center;
  position: relative;
}
.sf-banner.has-image { background-color: #1e293b; }
.sf-banner-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(15,23,42,.65) 0%, rgba(15,23,42,.15) 55%, transparent 100%);
}
.sf-banner-pattern {
  position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 15% 60%, rgba(249,115,22,.3), transparent 42%),
    radial-gradient(circle at 85% 25%, rgba(14,165,233,.22), transparent 40%);
}

.sf-brand-bar {
  position: relative;
  margin-top: -64px;
  padding: 0 18px 24px;
}
.sf-brand-bar-inner {
  max-width: var(--sf-max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: flex-end;
}
.sf-logo {
  width: 120px; height: 120px;
  border-radius: 24px;
  object-fit: cover;
  border: 4px solid #fff;
  box-shadow: var(--sf-shadow);
  background: #fff;
}
.sf-logo-placeholder {
  width: 120px; height: 120px;
  border-radius: 24px;
  border: 4px solid #fff;
  background: linear-gradient(145deg, #fff7ed, #ffedd5);
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem;
  box-shadow: var(--sf-shadow);
}
.sf-brand-info { flex: 1; min-width: 200px; padding-bottom: 4px; }
.sf-shop-name {
  margin: 0 0 6px;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--sf-text);
}
.sf-shop-tagline {
  margin: 0 0 10px;
  color: var(--sf-muted);
  font-size: .95rem;
  max-width: 520px;
  line-height: 1.5;
}
.sf-brand-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  font-size: .86rem;
  color: var(--sf-muted);
}
.sf-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.sf-meta-item i { color: var(--sf-primary); }
.sf-rating { color: #b45309; font-weight: 700; }
.sf-brand-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding-bottom: 6px;
}

/* ---------- Buttons ---------- */
.sf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: 14px;
  border: none;
  font-weight: 700;
  font-size: .9rem;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, background .15s, filter .15s;
}
.sf-btn:active { transform: scale(0.98); }
.sf-btn-primary {
  background: linear-gradient(135deg, var(--sf-primary), var(--sf-primary-dark));
  color: #fff;
  box-shadow: 0 6px 18px rgba(249,115,22,.35);
}
.sf-btn-primary:hover { filter: brightness(1.05); }
.sf-btn-outline {
  background: #fff;
  border: 1.5px solid var(--sf-border);
  color: var(--sf-text);
}
.sf-btn-outline:hover { border-color: var(--sf-primary); color: var(--sf-primary); }
.sf-btn-cart {
  background: var(--sf-text);
  color: #fff;
  position: relative;
  padding-inline-end: 16px;
}
.sf-btn-cart:hover { background: #1e293b; }
.sf-cart-count {
  background: var(--sf-primary);
  color: #fff;
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  font-size: .75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  padding: 0 6px;
}
.sf-btn-block { width: 100%; }
.sf-btn-sm { padding: 8px 12px; font-size: .82rem; border-radius: 10px; }

/* ---------- Sticky toolbar ---------- */
.sf-toolbar {
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--sf-border);
  position: sticky;
  top: var(--sf-topbar-h);
  z-index: 90;
}
.sf-toolbar-inner {
  max-width: var(--sf-max);
  margin: 0 auto;
  padding: 12px 18px;
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.sf-search {
  flex: 1;
  min-width: 200px;
  position: relative;
  display: flex;
  align-items: center;
}
.sf-search i {
  position: absolute;
  right: 14px;
  color: var(--sf-muted);
  pointer-events: none;
}
.sf-search input {
  width: 100%;
  padding: 12px 42px 12px 14px;
  border: 1.5px solid var(--sf-border);
  border-radius: 14px;
  background: #f8fafc;
  font-size: .92rem;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.sf-search input:focus {
  border-color: var(--sf-primary);
  box-shadow: 0 0 0 3px rgba(249,115,22,.15);
  background: #fff;
}
.sf-sort {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .85rem;
  color: var(--sf-muted);
}
.sf-sort select {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1.5px solid var(--sf-border);
  background: #fff;
  font-size: .88rem;
  cursor: pointer;
  outline: none;
}
.sf-sort select:focus { border-color: var(--sf-primary); }

/* ---------- Trust strip ---------- */
.sf-trust {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 0 0 20px;
}
.sf-trust-item {
  background: var(--sf-surface);
  border: 1px solid var(--sf-border);
  border-radius: 14px;
  padding: 12px 10px;
  text-align: center;
  font-size: .82rem;
  font-weight: 600;
  color: #334155;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  box-shadow: var(--sf-shadow-sm);
}
.sf-trust-item i {
  color: var(--sf-primary);
  font-size: 1.15rem;
}

/* ---------- Main / Products ---------- */
.sf-main { padding: 20px 0 100px; }
.sf-main-inner {
  max-width: var(--sf-max);
  margin: 0 auto;
  padding: 0 18px;
}
.sf-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  gap: 12px;
  flex-wrap: wrap;
}
.sf-section-head h2 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sf-section-head h2 i { color: var(--sf-primary); }
.sf-result-count {
  background: var(--sf-primary-soft);
  color: var(--sf-primary-dark);
  padding: 5px 12px;
  border-radius: 999px;
  font-size: .8rem;
  font-weight: 700;
}

.sf-product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.sf-product-card {
  background: var(--sf-surface);
  border-radius: var(--sf-radius);
  border: 1px solid var(--sf-border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s;
  box-shadow: var(--sf-shadow-sm);
}
.sf-product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--sf-shadow);
  border-color: #fdba74;
}
.sf-product-media {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #f8fafc;
  overflow: hidden;
}
.sf-product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.sf-product-card:hover .sf-product-media img { transform: scale(1.06); }
.sf-product-noimg {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: #94a3b8; font-size: 2.4rem;
  background: linear-gradient(145deg, #f8fafc, #e2e8f0);
}
.sf-product-noimg.large { min-height: 200px; font-size: 3.2rem; }
.sf-quick-view {
  position: absolute;
  left: 10px; top: 10px;
  width: 38px; height: 38px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.95);
  color: var(--sf-text);
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,.12);
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .2s, transform .2s;
  display: flex; align-items: center; justify-content: center;
}
.sf-product-card:hover .sf-quick-view,
.sf-product-card:focus-within .sf-quick-view {
  opacity: 1;
  transform: translateY(0);
}
.sf-badge-sale {
  position: absolute;
  right: 10px; top: 10px;
  background: #ef4444;
  color: #fff;
  font-size: .72rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
}
.sf-product-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.sf-product-title {
  margin: 0;
  font-size: .95rem;
  font-weight: 700;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.6em;
}
.sf-product-loc {
  font-size: .78rem;
  color: var(--sf-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}
.sf-product-price-row {
  margin-top: auto;
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.sf-price {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--sf-primary-dark);
  letter-spacing: -0.01em;
}
.sf-price small {
  font-size: .75rem;
  font-weight: 600;
  color: var(--sf-muted);
}
.sf-product-actions { margin-top: 4px; }
.sf-product-actions .sf-btn {
  padding: 10px 12px;
  font-size: .85rem;
}

/* Empty */
.sf-empty {
  text-align: center;
  padding: 60px 20px;
  background: var(--sf-surface);
  border-radius: var(--sf-radius);
  border: 1px dashed var(--sf-border);
  color: var(--sf-muted);
}
.sf-empty i { font-size: 3rem; margin-bottom: 12px; opacity: .5; }

/* ---------- Footer ---------- */
.sf-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 32px 18px 28px;
  margin-top: 20px;
}
.sf-footer-inner {
  max-width: var(--sf-max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
  justify-content: space-between;
}
.sf-footer-brand {
  display: flex;
  gap: 12px;
  align-items: center;
}
.sf-footer-logo {
  width: 48px; height: 48px;
  border-radius: 12px;
  object-fit: cover;
}
.sf-footer-brand strong { color: #fff; display: block; }
.sf-footer-brand p { margin: 4px 0 0; font-size: .85rem; max-width: 280px; }
.sf-footer-links {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.sf-footer-links a:hover { color: var(--sf-primary); }
.sf-footer-copy {
  width: 100%;
  text-align: center;
  font-size: .78rem;
  opacity: .7;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,.08);
  margin-top: 8px;
}
.sf-footer-inner--custom {
  align-items: flex-start;
  justify-content: flex-start;
  gap: 28px;
}
.sf-footer-inner--custom > section { min-width: 180px; flex: 1 1 180px; }
.sf-footer-inner--custom .sf-footer-brand { flex: 1.4 1 240px; align-items: flex-start; }
.sf-footer-column { display: flex; flex-direction: column; align-items: flex-start; gap: 9px; font-size: .86rem; }
.sf-footer-column h3 { color: #fff; font-size: .98rem; margin: 0 0 5px; }
.sf-footer-column a, .sf-footer-column p { color: #cbd5e1; margin: 0; line-height: 1.9; overflow-wrap: anywhere; }
.sf-footer-column a:hover { color: var(--sf-primary); }
.sf-footer-column i { width: 18px; text-align: center; margin-left: 5px; }
.sf-footer-social-links { display: flex; flex-wrap: wrap; gap: 10px; }
.sf-footer-social-links a { display: inline-flex; align-items: center; gap: 6px; }
.sf-footer-social-links i { font-size: 1.1rem; }
.sf-footer-inner--custom .sf-footer-links { width: 100%; padding-top: 8px; border-top: 1px solid rgba(255,255,255,.08); }

/* ---------- Cart drawer ---------- */
.sf-cart-backdrop {
  position: fixed; inset: 0;
  background: rgba(15,23,42,.45);
  opacity: 0;
  visibility: hidden;
  transition: opacity .25s, visibility .25s;
  z-index: 200;
}
.sf-cart-drawer {
  position: fixed;
  top: 0; left: 0;
  width: min(400px, 100vw);
  height: 100%;
  background: #fff;
  z-index: 210;
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform .3s cubic-bezier(.22,1,.36,1);
  box-shadow: 8px 0 40px rgba(0,0,0,.15);
}
body.sf-cart-open .sf-cart-drawer,
.sf-cart-drawer.open { transform: translateX(0); }
body.sf-cart-open .sf-cart-backdrop,
.sf-cart-backdrop.open { opacity: 1; visibility: visible; }
.sf-cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  border-bottom: 1px solid var(--sf-border);
}
.sf-cart-header h3 {
  margin: 0;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sf-cart-close {
  width: 36px; height: 36px;
  border: none;
  border-radius: 10px;
  background: #f1f5f9;
  font-size: 1.3rem;
  cursor: pointer;
  line-height: 1;
}
.sf-cart-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
}
.sf-cart-empty {
  text-align: center;
  padding: 48px 16px;
  color: var(--sf-muted);
}
.sf-cart-empty i { font-size: 2.5rem; display: block; margin-bottom: 10px; opacity: .4; }
.sf-cart-item {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--sf-border);
  margin-bottom: 10px;
  background: #fafbfc;
}
.sf-cart-item img {
  width: 64px; height: 64px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
}
.sf-cart-item-ph {
  width: 64px; height: 64px;
  border-radius: 12px;
  background: #e2e8f0;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}
.sf-cart-item-info { flex: 1; min-width: 0; }
.sf-cart-item-info strong {
  display: block;
  font-size: .88rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sf-cart-item-meta {
  font-size: .8rem;
  color: var(--sf-muted);
  margin-top: 4px;
}
.sf-cart-qty {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
}
.sf-cart-qty button {
  width: 28px; height: 28px;
  border-radius: 8px;
  border: 1px solid var(--sf-border);
  background: #fff;
  cursor: pointer;
  font-weight: 700;
}
.sf-cart-qty span { font-weight: 700; min-width: 20px; text-align: center; }
.sf-cart-item-remove {
  border: none;
  background: transparent;
  color: #94a3b8;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 4px 8px;
}
.sf-cart-item-remove:hover { color: #ef4444; }
.sf-cart-footer {
  padding: 16px 18px;
  border-top: 1px solid var(--sf-border);
  background: #fff;
  box-shadow: 0 -4px 20px rgba(0,0,0,.04);
}
.sf-cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  font-size: .95rem;
}
.sf-cart-total strong {
  font-size: 1.15rem;
  color: var(--sf-primary-dark);
}

/* Mobile FAB cart */
.sf-fab-cart {
  display: none;
  position: fixed;
  left: 16px;
  bottom: 20px;
  z-index: 150;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, var(--sf-primary), var(--sf-primary-dark));
  color: #fff;
  font-size: 1.25rem;
  box-shadow: 0 8px 24px rgba(249,115,22,.45);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.sf-fab-cart .sf-cart-count {
  position: absolute;
  top: -2px;
  right: -2px;
}

/* ---------- Modal ---------- */
.sf-modal {
  position: fixed; inset: 0;
  background: rgba(15,23,42,.5);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 300;
  opacity: 0;
  visibility: hidden;
  transition: opacity .2s, visibility .2s;
}
.sf-modal.open {
  opacity: 1;
  visibility: visible;
}
.sf-modal-dialog {
  background: #fff;
  border-radius: 20px;
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow: auto;
  padding: 24px;
  position: relative;
  box-shadow: 0 24px 60px rgba(0,0,0,.2);
  transform: translateY(12px);
  transition: transform .25s;
}
.sf-modal.open .sf-modal-dialog { transform: translateY(0); }
.sf-checkout-dialog { max-width: 560px; }
.sf-modal-close {
  position: absolute;
  left: 14px; top: 12px;
  width: 36px; height: 36px;
  border: none;
  border-radius: 10px;
  background: #f1f5f9;
  font-size: 1.3rem;
  cursor: pointer;
}
.sf-checkout-title {
  margin: 0 0 16px;
  font-size: 1.15rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sf-quick {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 18px;
  align-items: start;
}
.sf-quick img {
  width: 100%;
  border-radius: 16px;
  aspect-ratio: 1;
  object-fit: cover;
}
.sf-quick h3 { margin: 0 0 8px; font-size: 1.1rem; }
.sf-quick .sf-price { display: block; margin-bottom: 16px; }

/* Checkout form bits */
.sf-checkout-dialog .form-group { margin-bottom: 12px; }
.sf-checkout-dialog label {
  display: block;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: 6px;
}
.sf-checkout-dialog input,
.sf-checkout-dialog select,
.sf-checkout-dialog textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--sf-border);
  border-radius: 12px;
  font-size: .9rem;
}
.sf-checkout-dialog .pay-options {
  display: grid;
  gap: 8px;
}
.sf-checkout-dialog .pay-option {
  border: 1.5px solid var(--sf-border);
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
}
.sf-checkout-dialog .pay-option.selected {
  border-color: var(--sf-primary);
  background: var(--sf-primary-soft);
}

/* Themes */
body.theme-blue { --sf-primary: #3b82f6; --sf-primary-dark: #2563eb; --sf-primary-soft: #eff6ff; }
body.theme-green { --sf-primary: #10b981; --sf-primary-dark: #059669; --sf-primary-soft: #ecfdf5; }
body.theme-purple { --sf-primary: #8b5cf6; --sf-primary-dark: #7c3aed; --sf-primary-soft: #f5f3ff; }
body.theme-rose { --sf-primary: #f43f5e; --sf-primary-dark: #e11d48; --sf-primary-soft: #fff1f2; }

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .sf-logo, .sf-logo-placeholder { width: 88px; height: 88px; border-radius: 18px; }
  .sf-brand-bar { margin-top: -44px; }
  .sf-trust { grid-template-columns: repeat(2, 1fr); }
  .sf-product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .sf-product-body { padding: 10px; }
  .sf-product-title { font-size: .85rem; }
  .sf-price { font-size: .95rem; }
  .sf-quick-view { opacity: 1; transform: none; }
  .sf-brand-actions .sf-btn-cart span:not(.sf-cart-count) { display: none; }
  .sf-fab-cart { display: flex; }
  .sf-quick { grid-template-columns: 1fr; }
  .sf-cart-drawer { width: 100vw; }
  .sf-toolbar { top: 0; }
  body.sf-cart-open { overflow: hidden; }
}
@media (max-width: 420px) {
  .sf-product-grid { grid-template-columns: 1fr 1fr; }
  .sf-product-actions .sf-btn { font-size: .78rem; padding: 8px; }
}
@media (min-width: 769px) {
  .sf-fab-cart { display: none !important; }
}

/* SHOP-THEME-UX-2026-11-04 */
.shop-storefront {
  --shop-radius: 16px;
  --shop-gap: 14px;
}
.shop-storefront[data-theme="modern"] {
  --shop-accent: #0ea5e9;
  --shop-surface: #f0f9ff;
}
.shop-storefront[data-theme="minimal"] {
  --shop-accent: #64748b;
  --shop-surface: #f8fafc;
}
.shop-storefront[data-theme="bold"] {
  --shop-accent: #ea580c;
  --shop-surface: #fff7ed;
}
.shop-storefront[data-theme="classic"] {
  --shop-accent: #1e3a5f;
  --shop-surface: #f1f5f9;
}
.shop-storefront .shop-hero {
  border-radius: var(--shop-radius);
  overflow: hidden;
  background: var(--shop-surface, #f8fafc);
}
.shop-storefront .shop-product-card {
  border-radius: 14px;
  border: 1px solid #e2e8f0;
  transition: box-shadow .2s ease, transform .2s ease;
}
.shop-storefront .shop-product-card:hover {
  box-shadow: 0 8px 24px rgba(15,23,42,.08);
  transform: translateY(-2px);
}


/* Storefront polish — فروشگاه آنلاین واقعی و واکنش‌گرا */
.sf-header { overflow: visible; }
.sf-brand-bar-inner { align-items: center; }
.sf-brand-info { padding-block: 8px; }
.sf-shop-name { letter-spacing: -.035em; }
.sf-brand-meta { gap: 9px 18px; }
.sf-toolbar-inner { gap: 14px; }
.sf-search input { min-height: 48px; background: #fff; }
.sf-sort select { min-height: 46px; border: 1px solid var(--sf-border); border-radius: 12px; padding: 0 12px; background: #fff; color: var(--sf-text); }
.sf-main-inner { padding-top: 30px; padding-bottom: 52px; }
.sf-section-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:18px; }
.sf-section-head h2 { font-size:clamp(1.15rem,2vw,1.5rem); font-weight:850; letter-spacing:-.02em; }
.sf-trust { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin:0 0 22px; }
.sf-trust-item { display:flex; align-items:center; justify-content:center; gap:9px; min-height:54px; padding:10px; border:1px solid var(--sf-border); border-radius:14px; background:linear-gradient(180deg,#fff,#f8fafc); color:#334155; font-size:.86rem; font-weight:700; }
.sf-trust-item i { color:var(--sf-primary); font-size:1.05rem; }
.sf-product-grid { align-items:stretch; }
.sf-product-card { display:flex; flex-direction:column; overflow:hidden; border:1px solid #e8edf3; border-radius:19px; background:#fff; box-shadow:0 3px 14px rgba(15,23,42,.045); transition:transform .2s ease,box-shadow .2s ease,border-color .2s ease; }
.sf-product-card:hover { transform:translateY(-5px); border-color:#fed7aa; box-shadow:0 16px 34px rgba(15,23,42,.11); }
.sf-product-media { position:relative; overflow:hidden; background:#f8fafc; aspect-ratio:1/1; }
.sf-product-media img { width:100%; height:100%; object-fit:cover; transition:transform .35s ease; }
.sf-product-card:hover .sf-product-media img { transform:scale(1.045); }
.sf-product-body { display:flex; flex:1; flex-direction:column; padding:14px; gap:8px; }
.sf-product-title { min-height:2.8em; margin:0; font-size:.96rem; line-height:1.7; font-weight:800; }
.sf-product-title-link:hover { color:var(--sf-primary-dark); }
.sf-product-price-row { margin-top:auto; padding-top:5px; }
.sf-price { color:#0f172a; font-size:1.05rem; font-weight:900; }
.sf-product-actions { margin-top:10px; }
.sf-product-actions .sf-btn { min-height:43px; border-radius:12px; }
.sf-quick-view { opacity:0; transform:translateY(4px); transition:all .2s ease; }
.sf-product-card:hover .sf-quick-view,.sf-quick-view:focus-visible { opacity:1; transform:none; }
.sf-empty { border:1px dashed #cbd5e1; border-radius:20px; background:#fff; padding:42px 20px; text-align:center; }
.sf-search-empty[hidden] { display:none !important; }
.sf-footer { margin-top:30px; }
@media (max-width:760px) {
  .sf-trust { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .sf-brand-bar { margin-top:-42px; }
  .sf-logo,.sf-logo-placeholder { width:88px; height:88px; border-radius:18px; }
  .sf-brand-bar-inner { align-items:flex-start; gap:12px; }
  .sf-brand-info { min-width:calc(100% - 108px); padding-top:7px; }
  .sf-brand-actions { width:100%; padding:0; }
  .sf-brand-actions .sf-btn { width:100%; }
  .sf-toolbar { top:0; }
  .sf-toolbar-inner { padding:10px 14px; }
  .sf-search { min-width:100%; }
  .sf-sort { width:100%; display:flex; align-items:center; justify-content:space-between; gap:10px; }
  .sf-sort select { flex:1; }
  .sf-main-inner { padding:22px 14px 38px; }
}
@media (max-width:420px) {
  .sf-trust-item { font-size:.76rem; gap:6px; }
  .sf-product-body { padding:10px; }
  .sf-product-title { font-size:.87rem; }
  .sf-product-actions .sf-btn { font-size:.8rem; padding:9px 8px; }
}


/* ============================================================
   INAMKAR STOREFRONT THEMES v3 — themes are scoped to each shop
   ============================================================ */
.storefront {
  --sf-font: "Vazirmatn", Tahoma, system-ui, sans-serif;
  --sf-primary: #2563eb;
  --sf-primary-dark: #1d4ed8;
  --sf-primary-soft: #eff6ff;
  --sf-accent: #0ea5e9;
  --sf-bg: #f4f7fb;
  --sf-surface: #ffffff;
  --sf-text: #172033;
  --sf-muted: #64748b;
  --sf-border: #e2e8f0;
  --sf-radius: 18px;
  color: var(--sf-text);
  background: var(--sf-bg);
  font-family: var(--sf-font);
}
.storefront[data-theme="default"] {
  --sf-primary:#2563eb; --sf-primary-dark:#1d4ed8; --sf-primary-soft:#eff6ff;
  --sf-accent:#0ea5e9; --sf-bg:#f4f7fb; --sf-surface:#fff;
  --sf-text:#172033; --sf-muted:#64748b; --sf-border:#e2e8f0;
}
.storefront[data-theme="dark"] {
  --sf-primary:#38bdf8; --sf-primary-dark:#0ea5e9; --sf-primary-soft:#172b42;
  --sf-accent:#818cf8; --sf-bg:#0b1220; --sf-surface:#111c2e;
  --sf-text:#e5edf8; --sf-muted:#a6b4c8; --sf-border:#2b3b52;
  color-scheme:dark;
}
.storefront[data-theme="orange"] {
  --sf-primary:#ea580c; --sf-primary-dark:#c2410c; --sf-primary-soft:#fff1e7;
  --sf-accent:#f59e0b; --sf-bg:#fffaf5; --sf-surface:#fff;
  --sf-text:#292524; --sf-muted:#78716c; --sf-border:#fed7aa;
}
.storefront[data-theme="green"] {
  --sf-primary:#059669; --sf-primary-dark:#047857; --sf-primary-soft:#ecfdf5;
  --sf-accent:#14b8a6; --sf-bg:#f3fbf7; --sf-surface:#fff;
  --sf-text:#123329; --sf-muted:#557368; --sf-border:#cde9dc;
}

/* Theme inheritance: every storefront component and the checkout use the selected shop palette. */
.storefront .sf-topbar { background:var(--sf-surface); color:var(--sf-muted); border-bottom:1px solid var(--sf-border); }
.storefront .sf-top-link { color:var(--sf-muted); }
.storefront .sf-top-link:hover { color:var(--sf-primary); }
.storefront .sf-header,.storefront .sf-brand-bar,.storefront .sf-toolbar,
.storefront .sf-product-card,.storefront .sf-cart-drawer,.storefront .sf-modal-dialog,
.storefront .sf-footer,.storefront .sf-empty { background:var(--sf-surface); color:var(--sf-text); }
.storefront .sf-shop-name,.storefront .sf-section-head h2,.storefront .sf-checkout-title { color:var(--sf-text); }
.storefront .sf-shop-tagline,.storefront .sf-meta-item,.storefront .sf-muted { color:var(--sf-muted); }
.storefront .sf-product-card,.storefront .sf-trust-item,.storefront .sf-search input,
.storefront .sf-sort select,.storefront .sf-cart-item,.storefront .sf-checkout-summary,
.storefront .sf-checkout-line,.storefront .sf-radio-card,.storefront .sf-input {
  border-color:var(--sf-border);
}
.storefront .sf-trust-item { background:var(--sf-primary-soft); color:var(--sf-text); }
.storefront .sf-trust-item i,.storefront .sf-section-head h2 i { color:var(--sf-primary); }
.storefront .sf-search input,.storefront .sf-sort select,.storefront .sf-input {
  background:var(--sf-surface); color:var(--sf-text);
}
.storefront .sf-search input::placeholder,.storefront .sf-input::placeholder { color:var(--sf-muted); opacity:.8; }
.storefront .sf-product-title,.storefront .sf-product-title-link,.storefront .sf-price { color:var(--sf-text); }
.storefront .sf-product-title-link:hover { color:var(--sf-primary-dark); }
.storefront .sf-btn-primary,.storefront .sf-btn-cart,.storefront .sf-cart-fab { background:var(--sf-primary); border-color:var(--sf-primary); color:#fff; }
.storefront .sf-btn-primary:hover,.storefront .sf-btn-cart:hover { background:var(--sf-primary-dark); border-color:var(--sf-primary-dark); }
.storefront .sf-btn-outline { border-color:var(--sf-border); color:var(--sf-text); }
.storefront .sf-radio-card.selected,.storefront .sf-radio-card:has(input:checked) { border-color:var(--sf-primary); background:var(--sf-primary-soft); }
.storefront .sf-footer { border-top:1px solid var(--sf-border); }
.storefront .sf-footer a:hover { color:var(--sf-primary); }

/* Fixed media frames. contain scales both small and large images without distortion or crop. */
.storefront .sf-banner {
  height:clamp(150px, 28vw, 270px);
  background:var(--sf-primary-soft);
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
}
.storefront .sf-banner-image {
  position:absolute; inset:0; width:100%; height:100%;
  max-width:none; max-height:none; object-fit:contain; object-position:center;
  display:block; z-index:0;
}
.storefront .sf-banner.has-image { background:var(--sf-bg); }
.storefront .sf-banner-overlay { pointer-events:none; z-index:1; }
.storefront .sf-banner-pattern { z-index:0; }
.storefront .sf-logo-wrap { width:120px; height:120px; flex:0 0 120px; }
.storefront .sf-logo {
  width:100%; height:100%; max-width:none; max-height:none;
  object-fit:contain; object-position:center; padding:5px;
  background:#fff; border:4px solid var(--sf-surface);
}
.storefront .sf-logo-placeholder { width:100%; height:100%; }

/* Checkout: clearer hierarchy, readable fields and responsive controls. */
.storefront .sf-checkout-heading { display:flex; align-items:center; gap:12px; margin:0 42px 18px 0; }
.storefront .sf-checkout-heading-icon { width:42px; height:42px; flex:0 0 42px; display:grid; place-items:center; border-radius:14px; background:var(--sf-primary-soft); color:var(--sf-primary); font-size:1.05rem; }
.storefront .sf-checkout-title { margin:0 0 3px; font-size:1.12rem; font-weight:850; }
.storefront .sf-checkout-subtitle { margin:0; color:var(--sf-muted); font-size:.8rem; line-height:1.7; }
.storefront .sf-checkout { display:grid; gap:15px; }
.storefront .sf-checkout-items { border:1px solid var(--sf-border); border-radius:15px; overflow:hidden; background:var(--sf-bg); }
.storefront .sf-checkout-line { display:flex; justify-content:space-between; align-items:center; gap:12px; padding:11px 13px; border-bottom:1px solid var(--sf-border); color:var(--sf-text); }
.storefront .sf-checkout-line:last-child { border-bottom:0; }
.storefront .sf-checkout-summary { border:1px solid var(--sf-border); border-radius:15px; padding:13px; background:var(--sf-bg); }
.storefront .sf-sum-row { color:var(--sf-muted); }
.storefront .sf-sum-row strong { color:var(--sf-text); }
.storefront .sf-sum-total { border-top:1px solid var(--sf-border); color:var(--sf-text); }
.storefront .sf-field { margin:0 0 13px; }
.storefront .sf-label { display:block; color:var(--sf-text); font-weight:750; font-size:.86rem; margin:0 0 7px; }
.storefront .sf-input { width:100%; min-height:45px; border:1px solid var(--sf-border); border-radius:12px; padding:10px 12px; font:inherit; font-size:.9rem; outline:none; }
.storefront .sf-input:focus,.storefront .sf-search input:focus,.storefront .sf-sort select:focus { border-color:var(--sf-primary); box-shadow:0 0 0 3px color-mix(in srgb, var(--sf-primary) 16%, transparent); }
.storefront .sf-radio-group { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; }
.storefront .sf-radio-card { min-height:48px; border:1px solid var(--sf-border); border-radius:12px; padding:10px 12px; display:flex; align-items:center; gap:8px; color:var(--sf-text); background:var(--sf-surface); cursor:pointer; }
.storefront .sf-radio-card input,.storefront .sf-check input { accent-color:var(--sf-primary); }
.storefront .sf-check { color:var(--sf-text); }
.storefront .sf-checkout-result { color:var(--sf-text); line-height:1.8; overflow-wrap:anywhere; }
.storefront .sf-checkout-result a { color:var(--sf-primary); font-weight:800; }
.storefront .sf-checkout-dialog { background:var(--sf-surface); color:var(--sf-text); }
.storefront .sf-modal-close { background:var(--sf-primary-soft); color:var(--sf-text); }
.storefront[data-theme="dark"] .sf-banner-overlay { background:linear-gradient(to top,rgba(2,6,23,.62),rgba(2,6,23,.12)); }
.storefront[data-theme="dark"] .sf-product-media,.storefront[data-theme="dark"] .sf-cart-item-ph { background:#1b2a40; }
.storefront[data-theme="dark"] .sf-footer { color:var(--sf-text); }
.storefront[data-theme="dark"] .sf-footer-bottom { background:#080e19; color:#cbd5e1; }
@media(max-width:760px) {
  .storefront .sf-logo-wrap { width:88px; height:88px; flex-basis:88px; }
  .storefront .sf-checkout-heading { margin-right:0; }
  .storefront .sf-radio-group { grid-template-columns:1fr; }
  .storefront .sf-checkout-dialog { padding:20px 15px; }
}

/* Final theme refinements: footer contrast and fixed footer logo frame. */
.storefront[data-theme="default"] { --sf-footer-bg:#172554; --sf-footer-muted:#dbeafe; }
.storefront[data-theme="dark"] { --sf-footer-bg:#070d18; --sf-footer-muted:#b6c4d8; }
.storefront[data-theme="orange"] { --sf-footer-bg:#7c2d12; --sf-footer-muted:#ffedd5; }
.storefront[data-theme="green"] { --sf-footer-bg:#064e3b; --sf-footer-muted:#d1fae5; }
.storefront .sf-footer { background:var(--sf-footer-bg); color:var(--sf-footer-muted); }
.storefront .sf-footer-column a,.storefront .sf-footer-column p,
.storefront .sf-footer-links a,.storefront .sf-footer-brand p { color:var(--sf-footer-muted); }
.storefront .sf-footer-column h3,.storefront .sf-footer-brand strong { color:#fff; }
.storefront .sf-footer-logo { width:48px; height:48px; object-fit:contain; background:#fff; padding:3px; }
.storefront .sf-footer-copy { color:var(--sf-footer-muted); border-color:rgba(255,255,255,.18); }
.storefront .sf-checkout-heading { margin:0 0 18px; padding-left:42px; }

body.storefront-page[data-shop-theme="dark"] { background:#0b1220 !important; }
.storefront .sf-btn-primary { box-shadow:0 6px 18px color-mix(in srgb, var(--sf-primary) 28%, transparent); }
.storefront .sf-cart-item { background:var(--sf-bg); color:var(--sf-text); }
.storefront .sf-cart-qty button { background:var(--sf-surface); color:var(--sf-text); border-color:var(--sf-border); }
.storefront .sf-banner.has-image .sf-banner-overlay { background:linear-gradient(to top,rgba(15,23,42,.12),transparent 52%); }
