/* =============================================
   AHANARA — MAIN STYLESHEET
   فونت: Vazirmatn | جهت: RTL
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;600;700&display=swap');

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --clr-steel:     #1a1a1a;
  --clr-steel-mid: #2e2e2e;
  --clr-accent:    #c8a96e;
  --clr-accent-dk: #a8893e;
  --clr-bg:        #f8f7f4;
  --clr-bg-alt:    #f0efe9;
  --clr-surface:   #ffffff;
  --clr-border:    #e2e0db;
  --clr-border-dk: #c8c6c0;
  --clr-text:      #1a1a1a;
  --clr-text-mid:  #555550;
  --clr-text-muted:#888882;
  --clr-green:     #2d7d4f;
  --clr-red:       #c0392b;
  --radius-sm:     6px;
  --radius-md:     10px;
  --radius-lg:     16px;
  --shadow-sm:     0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md:     0 4px 12px rgba(0,0,0,.08);
  --shadow-lg:     0 8px 32px rgba(0,0,0,.10);
  --transition:    0.2s ease;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Vazirmatn', sans-serif;
  background: var(--clr-bg);
  color: var(--clr-text);
  direction: rtl;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .65rem 1.4rem;
  border-radius: var(--radius-md);
  font-size: .9rem;
  font-weight: 500;
  transition: var(--transition);
  cursor: pointer;
  white-space: nowrap;
}
.btn-primary {
  background: var(--clr-accent-dk);
  color: #fff;
  border: 1.5px solid var(--clr-steel);
}
.btn-primary:hover { background: var(--clr-steel-mid); }

.btn-ghost {
  background: transparent;
  color: var(--clr-steel);
  border: 1.5px solid var(--clr-border-dk);
}
.btn-ghost:hover { border-color: var(--clr-steel); background: rgba(0,0,0,.04); }

.btn-outline {
  background: transparent;
  color: var(--clr-steel);
  border: 1.5px solid var(--clr-border-dk);
}
.btn-outline:hover { border-color: var(--clr-steel); }

.btn-full { width: 100%; justify-content: center; }
.btn-sm { padding: .45rem 1rem; font-size: .82rem; }

.btn-white {
  background: #fff;
  color: var(--clr-steel);
  border: 1.5px solid #fff;
}
.btn-white:hover { background: #f0efe9; }

.btn-outline-white {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255,255,255,.5);
}
.btn-outline-white:hover { border-color: #fff; background: rgba(255,255,255,.1); }

.btn-text-link {
  display: block;
  text-align: center;
  font-size: .82rem;
  color: var(--clr-text-muted);
  margin-top: .5rem;
}
.btn-text-link:hover { color: var(--clr-text); }

/* ===== HEADER ===== */
.site-header {
  background: var(--clr-surface);
  border-bottom: 1px solid var(--clr-border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 2rem;
  height: 64px;
}
.logo {
  display: flex;
  align-items: center;
  gap: .6rem;
  flex-shrink: 0;
}
.logo-text {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--clr-steel);
}
.main-nav {
  display: flex;
  gap: 1.5rem;
  flex: 1;
  justify-content: center;
}
.main-nav a {
  font-size: .88rem;
  font-weight: 500;
  color: var(--clr-text-mid);
  transition: color var(--transition);
  position: relative;
}
.main-nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  right: 0;
  width: 0;
  height: 2px;
  background: var(--clr-steel);
  transition: width var(--transition);
}
.main-nav a:hover { color: var(--clr-steel); }
.main-nav a:hover::after { width: 100%; }

.header-actions {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-shrink: 0;
}
.action-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  color: var(--clr-text-mid);
  transition: var(--transition);
}
.action-btn:hover { background: var(--clr-bg); color: var(--clr-steel); }
.cart-count {
  position: absolute;
  top: 4px;
  left: 4px;
  background: var(--clr-steel);
  color: #fff;
  font-size: .65rem;
  font-weight: 700;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.mobile-menu-toggle { display: none; padding: .4rem; color: var(--clr-text-mid); }

.mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--clr-surface);
  border-top: 1px solid var(--clr-border);
  padding: .5rem 0;
}
.mobile-nav.open { display: flex; }
.mobile-nav a {
  padding: .75rem 1.5rem;
  font-size: .9rem;
  color: var(--clr-text-mid);
  border-bottom: 1px solid var(--clr-bg-alt);
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav .mobile-login {
  margin: .5rem 1rem;
  text-align: center;
  background: var(--clr-steel);
  color: #fff;
  border-radius: var(--radius-md);
  padding: .7rem;
}

/* ===== SECTIONS ===== */
.section { padding: 4rem 0; }
.section.bg-alt { background: var(--clr-bg-alt); }

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}
.section-head h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--clr-steel);
}
.section-head.center { justify-content: center; }

.link-more {
  font-size: .85rem;
  font-weight: 500;
  color: var(--clr-text-muted);
  transition: color var(--transition);
}
.link-more:hover { color: var(--clr-steel); }

/* ===== HERO ===== */
.hero {
  background: var(--clr-steel);
  color: #fff;
  padding: 5rem 0 4rem;
  position: relative;
  overflow: hidden;
}
.hero-bg-pattern {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 40px 40px;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 4rem;
  align-items: center;
  position: relative;
}
.hero-badge {
  display: inline-block;
  background: rgba(200,169,110,.15);
  border: 1px solid rgba(200,169,110,.3);
  color: var(--clr-accent);
  font-size: .78rem;
  font-weight: 500;
  padding: .35rem .9rem;
  border-radius: 100px;
  margin-bottom: 1.2rem;
  letter-spacing: .02em;
}
.hero-title {
  font-size: 3rem;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 1.2rem;
  color: #fff;
}
.hero-accent { color: var(--clr-accent); }
.hero-desc {
  font-size: 1rem;
  color: rgba(255,255,255,.65);
  max-width: 480px;
  line-height: 1.8;
  margin-bottom: 2rem;
}
.hero-actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 2.5rem;
}
.hero-stats {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 2rem;
}
.stat { text-align: center; }
.stat strong { display: block; font-size: 1.4rem; font-weight: 700; color: #fff; }
.stat span { font-size: .78rem; color: rgba(255,255,255,.5); }
.stat-sep { width: 1px; height: 40px; background: rgba(255,255,255,.12); }

/* hero visual */
.hero-visual { display: flex; flex-direction: column; gap: 1rem; }
.hero-card-main {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  backdrop-filter: blur(4px);
}
.hc-tag {
  display: inline-block;
  background: var(--clr-accent);
  color: var(--clr-steel);
  font-size: .72rem;
  font-weight: 700;
  padding: .25rem .7rem;
  border-radius: 100px;
  margin-bottom: .75rem;
}
.hc-img-wrap { border-radius: var(--radius-md); overflow: hidden; background: rgba(255,255,255,.04); }
.product-svg { width: 100%; height: auto; }
.hc-info { margin-top: .75rem; }
.hc-name { font-size: .88rem; color: rgba(255,255,255,.85); margin-bottom: .3rem; }
.hc-price { font-size: 1.1rem; font-weight: 700; color: var(--clr-accent); }

.hero-card-side {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.hcs-row {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .85rem;
  color: rgba(255,255,255,.7);
}
.dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dot-green { background: #4caf7d; }
.dot-blue  { background: #5b9bd5; }
.dot-amber { background: var(--clr-accent); }

/* ===== USP BAR ===== */
.usp-bar { background: var(--clr-surface); border-bottom: 1px solid var(--clr-border); }
.usp-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  padding-bottom: 1rem;
  flex-wrap: wrap;
  gap: 1rem;
}
.usp-item {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .85rem;
  font-weight: 500;
  color: var(--clr-text-mid);
}
.usp-item svg { color: var(--clr-accent); flex-shrink: 0; }

/* ===== CAT GRID ===== */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1rem;
}
.cat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .6rem;
  padding: 1.5rem 1rem;
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius-lg);
  text-align: center;
  transition: var(--transition);
}
.cat-card:hover {
  border-color: var(--clr-steel);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.cat-icon {
  width: 60px;
  height: 60px;
  background: var(--clr-bg);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--clr-text-mid);
}
.cat-card:hover .cat-icon { background: var(--clr-steel); color: #fff; }
.cat-name { font-size: .88rem; font-weight: 600; color: var(--clr-text); }
.cat-count { font-size: .75rem; color: var(--clr-text-muted); }

/* ===== PRODUCT CARD ===== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
.product-card {
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.product-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--clr-border-dk);
  transform: translateY(-2px);
}
.product-card.out-of-stock { opacity: .75; }

.pc-img-wrap {
  display: block;
  position: relative;
  background: var(--clr-bg);
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.pc-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}
.product-card:hover .pc-img-wrap img { transform: scale(1.04); }

.pc-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--clr-bg-alt);
}

.pc-badge {
  position: absolute;
  top: .75rem;
  right: .75rem;
  background: var(--clr-steel);
  color: #fff;
  font-size: .72rem;
  font-weight: 600;
  padding: .25rem .65rem;
  border-radius: 100px;
}

.pc-sold-out {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,.7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .88rem;
  font-weight: 600;
  color: var(--clr-text-mid);
}

.pc-wishlist {
  position: absolute;
  top: .75rem;
  left: .75rem;
  width: 32px;
  height: 32px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--clr-text-muted);
  box-shadow: var(--shadow-sm);
  opacity: 0;
  transition: var(--transition);
}
.product-card:hover .pc-wishlist { opacity: 1; }
.pc-wishlist:hover, .pc-wishlist.liked { color: #e74c3c; }

.pc-body {
  padding: 1rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: .3rem;
}
.pc-cat {
  font-size: .75rem;
  color: var(--clr-text-muted);
  font-weight: 500;
}
.pc-name {
  font-size: .9rem;
  font-weight: 600;
  line-height: 1.4;
  flex: 1;
}
.pc-name a:hover { color: var(--clr-text-mid); }
.pc-sku { font-size: .72rem; color: var(--clr-text-muted); }

.pc-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: .5rem;
  padding-top: .75rem;
  border-top: 1px solid var(--clr-border);
}
.pc-price-wrap { display: flex; flex-direction: column; gap: .1rem; }
.pc-old-price {
  font-size: .75rem;
  color: var(--clr-text-muted);
  text-decoration: line-through;
}
.pc-price {
  font-size: 1rem;
  font-weight: 700;
  color: var(--clr-steel);
}
.pc-price small { font-size: .72rem; font-weight: 400; color: var(--clr-text-muted); }

.btn-add-cart {
  width: 38px;
  height: 38px;
  background: var(--clr-steel);
  color: #fff;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
}
.btn-add-cart:hover { background: var(--clr-steel-mid); }
.btn-add-cart:disabled { background: var(--clr-green); }

.btn-unavail {
  font-size: .75rem;
  color: var(--clr-text-muted);
}

.pc-stock {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .73rem;
}
.pc-stock.in { color: var(--clr-green); }
.pc-stock.out { color: var(--clr-red); }
.stock-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}

/* list view */
.products-grid.list-view {
  grid-template-columns: 1fr;
}
.products-grid.list-view .product-card {
  flex-direction: row;
  align-items: stretch;
}
.products-grid.list-view .pc-img-wrap {
  width: 160px;
  aspect-ratio: unset;
  flex-shrink: 0;
}
.products-grid.list-view .pc-body { flex-direction: column; }
.products-grid.list-view .pc-footer { margin-top: auto; }

/* ===== WHY GRID ===== */
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.why-card {
  padding: 2rem 1.5rem;
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}
.why-card:hover { border-color: var(--clr-steel); box-shadow: var(--shadow-md); }
.why-num {
  font-size: 2rem;
  font-weight: 700;
  color: var(--clr-border-dk);
  margin-bottom: 1rem;
  font-variant-numeric: tabular-nums;
}
.why-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: .6rem; }
.why-card p { font-size: .86rem; color: var(--clr-text-mid); line-height: 1.7; }

/* ===== CTA ===== */
.cta-section {
  background: var(--clr-steel);
  padding: 4rem 0;
}
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.cta-inner h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: .5rem;
}
.cta-inner p { color: rgba(255,255,255,.65); font-size: .92rem; }
.cta-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ===== FOOTER ===== */
.site-footer {
  background: var(--clr-steel);
  color: rgba(255,255,255,.7);
  padding: 4rem 0 0;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.4fr;
  gap: 3rem;
  padding-bottom: 3rem;
}
.logo-light .logo-text { color: #fff; }
.footer-desc {
  font-size: .85rem;
  line-height: 1.8;
  color: rgba(255,255,255,.55);
  margin: 1rem 0;
}
.footer-socials { display: flex; gap: .6rem; }
.footer-socials a {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.6);
  transition: var(--transition);
}
.footer-socials a:hover { border-color: rgba(255,255,255,.4); color: #fff; }

.footer-col h4 {
  font-size: .88rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 1.2rem;
}
.footer-col ul { display: flex; flex-direction: column; gap: .6rem; }
.footer-col ul a {
  font-size: .84rem;
  color: rgba(255,255,255,.55);
  transition: color var(--transition);
}
.footer-col ul a:hover { color: #fff; }

.footer-contact li {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .84rem;
  color: rgba(255,255,255,.55);
}
.footer-contact li svg { flex-shrink: 0; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 1.25rem 0;
}
.footer-bottom .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .75rem;
}
.footer-bottom span { font-size: .82rem; color: rgba(255,255,255,.4); }
.footer-trust { display: flex; gap: .6rem; }
.trust-badge {
  font-size: .72rem;
  padding: .25rem .7rem;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 100px;
  color: rgba(255,255,255,.4);
}

/* ===== TOAST ===== */
.toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--clr-steel);
  color: #fff;
  padding: .75rem 1.5rem;
  border-radius: 100px;
  font-size: .88rem;
  font-weight: 500;
  opacity: 0;
  transition: opacity .25s, transform .25s;
  pointer-events: none;
  z-index: 9999;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* =============================================
   PRODUCTS PAGE
   ============================================= */

/* page bar */
.page-bar {
  background: var(--clr-surface);
  border-bottom: 1px solid var(--clr-border);
}
.page-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: .85rem;
  padding-bottom: .85rem;
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .82rem;
  color: var(--clr-text-muted);
}
.breadcrumb a { color: var(--clr-text-muted); }
.breadcrumb a:hover { color: var(--clr-text); }
.breadcrumb span { color: var(--clr-border-dk); }
.result-count { font-size: .82rem; color: var(--clr-text-muted); }

/* search bar */
.search-bar-wrap {
  background: var(--clr-surface);
  border-bottom: 1px solid var(--clr-border);
  padding: .75rem 0;
}
.search-form {
  display: flex;
  gap: .75rem;
  align-items: center;
}
.search-input-wrap {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
}
.search-icon {
  position: absolute;
  right: .9rem;
  color: var(--clr-text-muted);
  pointer-events: none;
}
.search-input-wrap input {
  width: 100%;
  padding: .6rem 2.8rem .6rem .9rem;
  border: 1.5px solid var(--clr-border);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: .9rem;
  background: var(--clr-bg);
  color: var(--clr-text);
  direction: rtl;
  transition: border-color var(--transition);
}
.search-input-wrap input:focus { outline: none; border-color: var(--clr-steel); }
.search-clear {
  position: absolute;
  left: .75rem;
  color: var(--clr-text-muted);
  font-size: 1.1rem;
  line-height: 1;
}

/* layout */
.products-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 2rem;
  padding-top: 2rem;
  padding-bottom: 3rem;
  align-items: start;
}

/* sidebar */
.sidebar { display: flex; flex-direction: column; gap: 1.25rem; }
.sidebar-box {
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
}
.sidebar-title {
  font-size: .88rem;
  font-weight: 700;
  color: var(--clr-text);
  margin-bottom: 1rem;
  padding-bottom: .6rem;
  border-bottom: 1px solid var(--clr-border);
}
.cat-list { display: flex; flex-direction: column; gap: .15rem; }
.cat-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .5rem .6rem;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  color: var(--clr-text-mid);
  transition: var(--transition);
}
.cat-link:hover { background: var(--clr-bg); color: var(--clr-text); }
.cat-link.active {
  background: var(--clr-steel);
  color: #fff;
}
.cat-cnt {
  font-size: .75rem;
  background: var(--clr-bg-alt);
  padding: .1rem .4rem;
  border-radius: 100px;
}
.cat-link.active .cat-cnt { background: rgba(255,255,255,.15); color: rgba(255,255,255,.8); }

.price-inputs { display: flex; flex-direction: column; gap: .6rem; margin-bottom: .85rem; }
.price-field { display: flex; flex-direction: column; gap: .25rem; }
.price-field label { font-size: .78rem; color: var(--clr-text-muted); }
.price-field input {
  padding: .5rem .7rem;
  border: 1.5px solid var(--clr-border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: .88rem;
  background: var(--clr-bg);
  color: var(--clr-text);
  direction: ltr;
  text-align: right;
}
.price-field input:focus { outline: none; border-color: var(--clr-steel); }

.quick-filters { display: flex; flex-wrap: wrap; gap: .4rem; }
.qf-chip {
  display: inline-block;
  padding: .35rem .75rem;
  font-size: .78rem;
  font-weight: 500;
  border: 1.5px solid var(--clr-border);
  border-radius: 100px;
  color: var(--clr-text-mid);
  transition: var(--transition);
}
.qf-chip:hover { border-color: var(--clr-steel); color: var(--clr-steel); }
.qf-chip.active { background: var(--clr-steel); color: #fff; border-color: var(--clr-steel); }

/* sort bar */
.sort-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .75rem;
  margin-bottom: 1.25rem;
}
.active-filters { display: flex; align-items: center; flex-wrap: wrap; gap: .4rem; }
.filter-tag {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  background: var(--clr-bg-alt);
  border: 1px solid var(--clr-border);
  padding: .3rem .7rem;
  border-radius: 100px;
  font-size: .78rem;
  color: var(--clr-text-mid);
}
.filter-tag a { color: var(--clr-text-muted); font-size: .9rem; }
.filter-tag a:hover { color: var(--clr-red); }

.sort-controls { display: flex; align-items: center; gap: .75rem; }
.sort-controls label { font-size: .82rem; color: var(--clr-text-muted); white-space: nowrap; }
.sort-controls select {
  padding: .4rem .7rem;
  border: 1.5px solid var(--clr-border);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: .85rem;
  color: var(--clr-text);
  background: var(--clr-surface);
  direction: rtl;
  cursor: pointer;
}
.sort-controls select:focus { outline: none; border-color: var(--clr-steel); }

.view-toggle { display: flex; gap: .25rem; }
.vt-btn {
  width: 34px;
  height: 34px;
  border: 1.5px solid var(--clr-border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--clr-text-muted);
  transition: var(--transition);
}
.vt-btn.active { background: var(--clr-steel); border-color: var(--clr-steel); color: #fff; }
.vt-btn:hover:not(.active) { border-color: var(--clr-steel); color: var(--clr-steel); }

/* empty state */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5rem 2rem;
  text-align: center;
  gap: 1rem;
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius-lg);
}
.empty-state h3 { font-size: 1.1rem; font-weight: 700; }
.empty-state p { font-size: .88rem; color: var(--clr-text-muted); max-width: 320px; }

/* pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: .4rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}
.pg-btn {
  min-width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--clr-border);
  border-radius: var(--radius-md);
  font-size: .88rem;
  font-weight: 500;
  color: var(--clr-text-mid);
  background: var(--clr-surface);
  transition: var(--transition);
  padding: 0 .5rem;
}
.pg-btn:hover { border-color: var(--clr-steel); color: var(--clr-steel); }
.pg-btn.active { background: var(--clr-steel); border-color: var(--clr-steel); color: #fff; }
.pg-dots { color: var(--clr-text-muted); padding: 0 .25rem; }

/* mobile filter fab */
.filter-fab {
  display: none;
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  background: var(--clr-steel);
  color: #fff;
  padding: .75rem 1.5rem;
  border-radius: 100px;
  font-size: .88rem;
  font-weight: 600;
  align-items: center;
  gap: .5rem;
  box-shadow: var(--shadow-lg);
  z-index: 50;
  cursor: pointer;
}

.filter-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.4);
  z-index: 200;
}
.filter-overlay.open { display: block; }

.filter-drawer {
  position: fixed;
  bottom: 0;
  right: 0;
  left: 0;
  background: var(--clr-surface);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  padding: 1.25rem;
  z-index: 300;
  transform: translateY(100%);
  transition: transform .3s ease;
  max-height: 80vh;
  overflow-y: auto;
}
.filter-drawer.open { transform: translateY(0); }
.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--clr-border);
}
.drawer-head h3 { font-size: 1rem; font-weight: 700; }
.drawer-head button { font-size: 1.4rem; color: var(--clr-text-muted); }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1024px) {
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .products-grid { grid-template-columns: repeat(3, 1fr); }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { display: none; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .main-nav { display: none; }
  .mobile-menu-toggle { display: flex; }

  .hero-title { font-size: 2rem; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: 1fr; }
  .usp-inner { justify-content: flex-start; }
  .cta-inner { flex-direction: column; align-items: flex-start; }

  .products-layout { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .filter-fab { display: flex; }

  .footer-inner { grid-template-columns: 1fr; gap: 2rem; }
  .products-grid.list-view .pc-img-wrap { width: 120px; }
}

@media (max-width: 480px) {
  .products-grid { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-stats { justify-content: space-between; }
  .sort-bar { flex-direction: column; align-items: flex-start; }
  .sort-controls { flex-wrap: wrap; }
}

/* ============================================================
   صفحه ورود (Login)
   ============================================================ */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f4f5f7;
  padding: 40px 16px;
}
.auth-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(0,0,0,.10);
  padding: 40px 36px;
  width: 100%;
  max-width: 420px;
}
.auth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 28px;
  justify-content: center;
}
.auth-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
  text-align: right;
}
.auth-desc {
  font-size: 13.5px;
  color: #6b7280;
  margin-bottom: 24px;
  line-height: 1.7;
}
.auth-note {
  font-size: 12px;
  color: #9ca3af;
  margin-top: 16px;
  text-align: center;
}
.auth-note a { color: #1a1a1a; }
.auth-back {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  font-size: 13px;
  color: #6b7280;
  cursor: pointer;
  margin-bottom: 20px;
  font-family: inherit;
  padding: 0;
}
.auth-back:hover { color: #1a1a1a; }

/* مراحل — فقط active نمایش داده می‌شود */
.auth-step {
  display: none;
}
.auth-step.active {
  display: block;
}

/* ورودی شماره */
.phone-input-wrap {
  display: flex;
  align-items: center;
  border: 1px solid #e2e4e9;
  border-radius: 8px;
  overflow: hidden;
}
.phone-prefix {
  padding: 10px 12px;
  background: #f4f5f7;
  border-left: 1px solid #e2e4e9;
  font-size: 13px;
  color: #6b7280;
  white-space: nowrap;
}
.phone-input-wrap input {
  flex: 1;
  border: none !important;
  border-radius: 0 !important;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
  direction: ltr;
  text-align: left;
}
.phone-input-wrap input:focus { outline: none; }

/* باکس‌های OTP */
.otp-inputs {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 8px 0 16px;
  direction: ltr;
}
.otp-box {
  width: 52px;
  height: 56px;
  border: 2px solid #e2e4e9;
  border-radius: 10px;
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  font-family: inherit;
  transition: border .15s;
  color: #1a1a1a;
}
.otp-box:focus  { outline: none; border-color: #1a1a1a; }
.otp-box.otp-error { border-color: #dc2626; background: #fff5f5; }

/* تایمر */
.otp-timer {
  font-size: 13px;
  color: #6b7280;
  text-align: center;
  margin-bottom: 8px;
}
.otp-timer span { font-weight: 700; color: #1a1a1a; }
.otp-resend {
  display: block;
  width: 100%;
  background: none;
  border: none;
  font-size: 13px;
  color: #2563eb;
  cursor: pointer;
  text-align: center;
  margin-bottom: 12px;
  font-family: inherit;
}
.otp-resend.hidden { display: none; }

/* دکمه تمام‌عرض */
.btn-block {
  width: 100%;
  justify-content: center;
  padding: 12px;
  font-size: 15px;
  margin-top: 8px;
}

/* ============================================================
   صفحه نتیجه پرداخت
   ============================================================ */
.result-page {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 16px;
}
.result-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(0,0,0,.10);
  padding: 48px 40px;
  max-width: 480px;
  width: 100%;
  text-align: center;
}
.result-icon { margin-bottom: 20px; }
.result-card h1 { font-size: 24px; font-weight: 700; margin-bottom: 8px; }
.result-card p  { color: #6b7280; font-size: 14px; margin-bottom: 24px; }
.result-details {
  background: #f4f5f7;
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 28px;
  text-align: right;
}
.rd-row {
  display: flex;
  justify-content: space-between;
  font-size: 13.5px;
  padding: 6px 0;
  border-bottom: 1px solid #e2e4e9;
}
.rd-row:last-child { border: none; }
.rd-row span   { color: #6b7280; }
.rd-row strong { font-weight: 700; }
.result-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.result-success { border-top: 4px solid #16a34a; }
.result-fail    { border-top: 4px solid #dc2626; }

/* ============================================================
   فرم عمومی — field-err و req
   ============================================================ */
.field-err { font-size: 11.5px; color: #dc2626; margin-top: 3px; display: block; }
.req       { color: #dc2626; }
.form-group { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; }
.form-group label { font-size: 13px; font-weight: 600; color: #374151; }
.form-group input,
.form-group select,
.form-group textarea {
  padding: 10px 13px;
  border: 1px solid #e2e4e9;
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  color: #1a1a1a;
  transition: border .15s;
  background: #fff;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #1a1a1a;
}
.input-error { border-color: #dc2626 !important; }

/* ===== auth extras ===== */
.auth-error   { background:#fee2e2; color:#b91c1c; border:1px solid #fecaca; border-radius:8px; padding:10px 14px; font-size:13px; margin-bottom:16px; }
.auth-success { background:#dcfce7; color:#15803d; border:1px solid #bbf7d0; border-radius:8px; padding:10px 14px; font-size:13px; margin-bottom:16px; }
.auth-links   { display:flex; align-items:center; justify-content:center; gap:10px; margin-top:16px; font-size:13px; color:#6b7280; }
.auth-links a { color:#1a1a1a; font-weight:600; }
.password-wrap { position:relative; }
.password-wrap input { width:100%; padding-left:44px !important; }
.toggle-pass  { position:absolute; left:12px; top:50%; transform:translateY(-50%); background:none; border:none; cursor:pointer; color:#9ca3af; padding:0; display:flex; }
.toggle-pass:hover { color:#1a1a1a; }
.form-grid-2  { display:grid; grid-template-columns:1fr 1fr; gap:12px; }

/* ===== سوئیچ روش ورود ===== */
.login-method-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  background: #f4f5f7;
  padding: 4px;
  border-radius: 10px;
}
.lmt-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px;
  border: none;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  background: transparent;
  color: #6b7280;
  transition: all .2s;
}
.lmt-btn.active {
  background: #fff;
  color: #1a1a1a;
  box-shadow: 0 1px 4px rgba(0,0,0,.10);
}
.login-method { display: none; }
.login-method.active { display: block; }

/* ===== تب‌های لوگین ===== */
.login-tabs {
  display: flex;
  border: 1px solid #e2e4e9;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 24px;
}
.ltab {
  flex: 1;
  text-align: center;
  padding: 10px;
  font-size: 13.5px;
  font-weight: 500;
  color: #6b7280;
  cursor: pointer;
  transition: all .2s;
  background: #f9fafb;
}
.ltab.active {
  background: #1a1a1a;
  color: #fff;
  font-weight: 600;
}
.login-tab-content { display: none; }
.login-tab-content.active { display: block; }
.form-row-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-size: 13px;
}
.remember-me { display: flex; align-items: center; gap: 6px; cursor: pointer; color: #6b7280; }
.remember-me input { cursor: pointer; }
.forgot-link { color: #2563eb; font-size: 12.5px; }

/* ===== سبد خرید ===== */
.cart-page { padding: 40px 0 80px; min-height: 60vh; }
.page-title {
  font-size: 26px; font-weight: 700;
  margin-bottom: 28px;
  display: flex; align-items: center; gap: 12px;
}
.cart-items-badge {
  font-size: 14px; font-weight: 500; color: #6b7280;
  background: #f3f4f6; padding: 3px 12px; border-radius: 99px;
}

/* سبد خالی */
.cart-empty {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 80px 20px; text-align: center;
  background: #fff; border-radius: 16px;
  border: 1px solid #e2e4e9;
}
.cart-empty h2 { font-size: 20px; font-weight: 700; margin: 20px 0 8px; }
.cart-empty p  { color: #6b7280; margin-bottom: 24px; }

/* لایه‌بندی سبد */
.cart-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}
.cart-items {
  background: #fff; border-radius: 12px;
  border: 1px solid #e2e4e9; overflow: hidden;
}
.cart-items-head {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 40px;
  gap: 12px; padding: 12px 20px;
  background: #f9fafb;
  border-bottom: 1px solid #e2e4e9;
  font-size: 12px; font-weight: 600; color: #6b7280;
}

/* آیتم سبد */
.cart-item {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 40px;
  gap: 12px; padding: 16px 20px;
  border-bottom: 1px solid #f3f4f6;
  align-items: center;
  transition: opacity .28s, transform .28s;
}
.cart-item:last-child { border: none; }
.ci-product { display: flex; align-items: center; gap: 12px; }
.ci-img-link { flex-shrink: 0; }
.ci-img    { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 1px solid #e2e4e9; }
.ci-img-ph { width: 64px; height: 64px; border-radius: 8px; background: #f3f4f6; display: flex; align-items: center; justify-content: center; }
.ci-name   { font-size: 13.5px; font-weight: 600; color: #1a1a1a; display: block; margin-bottom: 4px; }
.ci-sku    { font-size: 11px; color: #9ca3af; }
.ci-stock-warn { font-size: 11px; color: #d97706; display: block; margin-top: 3px; }
.ci-unit-price { font-size: 13px; }
.ci-old-price  { display: block; font-size: 11px; color: #9ca3af; text-decoration: line-through; }

/* تعداد */
.ci-qty-wrap { display: flex; align-items: center; gap: 8px; }
.qty-btn {
  width: 28px; height: 28px; border-radius: 6px;
  border: 1px solid #e2e4e9; background: #f9fafb;
  font-size: 16px; cursor: pointer; display: flex;
  align-items: center; justify-content: center;
  transition: all .15s; line-height: 1;
}
.qty-btn:hover:not(:disabled) { background: #1a1a1a; color: #fff; border-color: #1a1a1a; }
.qty-btn:disabled { opacity: .3; cursor: not-allowed; }
.ci-qty-val { font-size: 14px; font-weight: 600; min-width: 20px; text-align: center; }

.ci-subtotal { font-size: 13.5px; font-weight: 700; }
.remove-btn {
  width: 32px; height: 32px; border-radius: 6px;
  border: 1px solid #fee2e2; background: #fff5f5;
  color: #dc2626; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .15s;
}
.remove-btn:hover { background: #dc2626; color: #fff; }

/* پایین سبد */
.cart-footer-actions {
  display: flex; justify-content: space-between;
  padding: 14px 20px; border-top: 1px solid #f3f4f6;
}

/* خلاصه سفارش */
.cart-summary {
  background: #fff; border-radius: 12px;
  border: 1px solid #e2e4e9; padding: 24px;
  position: sticky; top: 80px;
}
.summary-title { font-size: 16px; font-weight: 700; margin-bottom: 20px; }
.coupon-wrap { margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px solid #f3f4f6; }
.coupon-input-wrap { display: flex; gap: 8px; }
.coupon-input {
  flex: 1; padding: 9px 12px;
  border: 1px solid #e2e4e9; border-radius: 7px;
  font-size: 13px; font-family: inherit;
}
.coupon-ok  { font-size: 12px; color: #16a34a; margin-top: 6px; }
.coupon-err { font-size: 12px; color: #dc2626; margin-top: 6px; }
.summary-rows { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.sum-row { display: flex; justify-content: space-between; font-size: 13.5px; }
.sum-row span:first-child { color: #6b7280; }
.sum-discount span:last-child { color: #16a34a; font-weight: 600; }
.sum-total { padding-top: 12px; border-top: 2px solid #1a1a1a; font-size: 15px; font-weight: 700; }
.free-ship { color: #16a34a; font-weight: 600; }
.free-ship-note {
  display: flex; align-items: center; gap: 5px;
  font-size: 11.5px; color: #16a34a; margin-top: -4px;
}
.free-ship-progress { font-size: 11.5px; color: #6b7280; margin-top: -4px; }
.progress-bar { height: 4px; background: #f3f4f6; border-radius: 99px; margin-top: 5px; overflow: hidden; }
.progress-fill { height: 100%; background: #16a34a; border-radius: 99px; transition: width .3s; }
.btn-checkout {
  width: 100%; justify-content: center;
  padding: 13px; font-size: 15px; margin-bottom: 14px;
}
.summary-trust { display: flex; flex-direction: column; gap: 8px; }
.trust-item { display: flex; align-items: center; gap: 7px; font-size: 12px; color: #6b7280; }

/* انیمیشن حذف */
@keyframes fadeOut { to { opacity:0; transform: translateX(20px); } }
.ci-animate { animation: fadeIn .3s ease both; }
@keyframes fadeIn { from { opacity:0; transform: translateY(8px); } }

/* موبایل */
@media (max-width: 768px) {
  .cart-layout { grid-template-columns: 1fr; }
  .cart-items-head { display: none; }
  .cart-item {
    grid-template-columns: 1fr;
    gap: 8px; padding: 14px 16px;
  }
  .ci-unit-price::before { content: attr(data-label) ': '; color: #9ca3af; }
  .ci-qty-wrap::before   { content: 'تعداد: '; color: #9ca3af; }
  .ci-subtotal::before   { content: attr(data-label) ': '; color: #9ca3af; }
  .cart-summary { position: static; }
}

/* ============================================================
   صفحه پروفایل
   ============================================================ */
.profile-page { padding: 40px 0 80px; min-height: 70vh; }

.profile-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  align-items: start;
}

/* ===== سایدبار پروفایل ===== */
.profile-sidebar {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e2e4e9;
  overflow: hidden;
  position: sticky;
  top: 80px;
}
.profile-avatar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px;
  border-bottom: 1px solid #f3f4f6;
}
.avatar-circle {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: #1a1a1a;
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 700;
  flex-shrink: 0;
}
.profile-name  { font-size: 14px; font-weight: 700; }
.profile-phone { font-size: 12px; color: #6b7280; margin-top: 2px; direction: ltr; text-align: right; }

.profile-nav { padding: 8px; }
.pnav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 8px;
  font-size: 13.5px; color: #374151;
  transition: all .15s; cursor: pointer;
  text-decoration: none; position: relative;
}
.pnav-item:hover  { background: #f3f4f6; }
.pnav-item.active { background: #1a1a1a; color: #fff; font-weight: 600; }
.pnav-badge {
  margin-right: auto;
  background: #e2e4e9;
  color: #374151;
  font-size: 11px;
  padding: 1px 7px;
  border-radius: 99px;
  font-weight: 700;
}
.pnav-item.active .pnav-badge { background: #ffffff30; color: #fff; }
.pnav-logout { color: #dc2626 !important; margin-top: 4px; }
.pnav-logout:hover { background: #fee2e2 !important; }

/* ===== محتوای اصلی پروفایل ===== */
.profile-main { display: flex; flex-direction: column; gap: 20px; }
.profile-section {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e2e4e9;
  padding: 24px;
}
.section-title { font-size: 18px; font-weight: 700; margin-bottom: 20px; }
.section-head-row {
  display: flex; justify-content: space-between;
  align-items: center; margin-bottom: 20px;
}

/* ===== سفارش‌ها ===== */
.orders-list { display: flex; flex-direction: column; gap: 14px; }
.order-card {
  border: 1px solid #e2e4e9;
  border-radius: 10px;
  overflow: hidden;
}
.order-head {
  display: flex; justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: #f9fafb;
  border-bottom: 1px solid #f3f4f6;
}
.order-id-wrap { display: flex; align-items: center; gap: 6px; }
.order-id-label { font-size: 12px; color: #9ca3af; }
.order-id { font-size: 15px; font-weight: 700; }
.order-meta {
  display: flex; flex-wrap: wrap; gap: 16px;
  padding: 12px 16px;
  font-size: 12.5px; color: #6b7280;
}
.om-item { display: flex; align-items: center; gap: 5px; }
.om-ref  { color: #1a1a1a; font-weight: 600; }
.order-addr {
  display: flex; align-items: flex-start; gap: 5px;
  padding: 0 16px 10px;
  font-size: 12px; color: #6b7280;
}
.order-actions {
  display: flex; gap: 8px; align-items: center;
  padding: 10px 16px;
  border-top: 1px solid #f3f4f6;
}
.tracking-info { font-size: 12px; color: #2563eb; }

/* جزئیات آیتم‌های سفارش */
.order-items-detail {
  border-top: 1px solid #f3f4f6;
  padding: 12px 16px;
  display: flex; flex-direction: column; gap: 10px;
}
.order-items-detail.hidden { display: none; }
.oi-row { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.oi-img { width: 40px; height: 40px; border-radius: 6px; overflow: hidden; flex-shrink: 0; }
.oi-img img { width: 100%; height: 100%; object-fit: cover; }
.oi-img-ph { width: 40px; height: 40px; background: #f3f4f6; border-radius: 6px; display: flex; align-items: center; justify-content: center; }
.oi-name  { flex: 1; font-weight: 500; }
.oi-qty   { color: #6b7280; }
.oi-price { font-weight: 700; margin-right: auto; }

/* وضعیت سفارش badge */
.order-status { font-size: 11.5px; font-weight: 600; padding: 4px 10px; border-radius: 99px; }
.status-pending    { background: #fef3c7; color: #92400e; }
.status-processing { background: #dbeafe; color: #1d4ed8; }
.status-shipped    { background: #e0e7ff; color: #4338ca; }
.status-delivered  { background: #dcfce7; color: #15803d; }
.status-cancelled  { background: #fee2e2; color: #b91c1c; }

/* ===== آدرس‌ها ===== */
.addresses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}
.addr-block {
  border: 1px solid #e2e4e9;
  border-radius: 10px;
  padding: 16px;
  position: relative;
}
.addr-default      { border-color: #1a1a1a; }
.addr-default-badge {
  position: absolute; top: -10px; right: 12px;
  background: #1a1a1a; color: #fff;
  font-size: 11px; padding: 2px 8px; border-radius: 99px;
}
.addr-block-title  { font-size: 13.5px; font-weight: 700; margin-bottom: 6px; }
.addr-block-text   { font-size: 12.5px; color: #374151; line-height: 1.6; margin-bottom: 4px; }
.addr-block-postal { font-size: 11.5px; color: #9ca3af; margin-bottom: 12px; }
.addr-block-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* ===== مودال ===== */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.modal-overlay.hidden { display: none; }
.modal-box {
  background: #fff;
  border-radius: 14px;
  width: 100%; max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.2);
}
.modal-head {
  display: flex; justify-content: space-between;
  align-items: center;
  padding: 18px 22px;
  border-bottom: 1px solid #f3f4f6;
}
.modal-head h3 { font-size: 16px; font-weight: 700; }
.modal-close {
  width: 32px; height: 32px; border-radius: 50%;
  border: none; background: #f3f4f6;
  font-size: 20px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: #6b7280; line-height: 1;
}
.modal-close:hover { background: #e2e4e9; }
.modal-body { padding: 20px 22px; }
.modal-body .form-group { margin-bottom: 14px; }
.modal-body .form-grid  { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 0; }
.modal-body .form-full  { grid-column: span 2; }
.modal-foot {
  display: flex; gap: 10px;
  padding: 16px 22px;
  border-top: 1px solid #f3f4f6;
}

/* ===== ویرایش پروفایل ===== */
.form-feedback { font-size: 13px; margin-top: 10px; padding: 10px 14px; border-radius: 8px; }
.feedback-ok  { background: #dcfce7; color: #15803d; }
.feedback-err { background: #fee2e2; color: #b91c1c; }
.input-disabled { background: #f9fafb !important; color: #9ca3af; cursor: not-allowed; }

/* ===== empty state ===== */
.empty-state {
  display: flex; flex-direction: column;
  align-items: center; padding: 48px 20px;
  text-align: center; color: #9ca3af;
}
.empty-state p { margin: 12px 0 20px; font-size: 14px; }

/* ===== responsive ===== */
@media (max-width: 768px) {
  .profile-layout { grid-template-columns: 1fr; }
  .profile-sidebar { position: static; }
  .addresses-grid { grid-template-columns: 1fr; }
  .modal-body .form-grid { grid-template-columns: 1fr; }
  .modal-body .form-full { grid-column: span 1; }
}

/* ============================================================
   صفحه checkout
   ============================================================ */
.checkout-steps-bar {
  background: #fff;
  border-bottom: 1px solid #e2e4e9;
  padding: 14px 0;
  margin-bottom: 32px;
}
.steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}
.step {
  display: flex; flex-direction: column;
  align-items: center; gap: 6px;
  font-size: 12px; color: #9ca3af;
}
.step.active { color: #1a1a1a; font-weight: 600; }
.step.done   { color: #16a34a; }
.step-circle {
  width: 32px; height: 32px; border-radius: 50%;
  border: 2px solid #e2e4e9;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700;
  background: #fff;
}
.step.active .step-circle { border-color: #1a1a1a; background: #1a1a1a; color: #fff; }
.step.done   .step-circle { border-color: #16a34a; background: #16a34a; color: #fff; }
.step-line {
  width: 60px; height: 2px;
  background: #e2e4e9; margin-bottom: 18px;
}
.step-line.done { background: #16a34a; }

.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 24px;
  align-items: start;
  padding-bottom: 60px;
}
.checkout-main { display: flex; flex-direction: column; gap: 16px; }

.co-section {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e2e4e9;
  overflow: hidden;
}
.co-section-head {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid #f3f4f6;
}
.co-section-head h2 { font-size: 15px; font-weight: 700; }
.co-step-num {
  width: 28px; height: 28px; border-radius: 50%;
  background: #1a1a1a; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; flex-shrink: 0;
}
.co-section .form-grid { padding: 20px; gap: 14px; }
.co-section .form-full { grid-column: span 2; }

/* آدرس‌های ذخیره‌شده */
.saved-addresses { padding: 16px 20px 0; }
.saved-label { font-size: 12.5px; color: #6b7280; margin-bottom: 10px; font-weight: 600; }
.addr-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px,1fr));
  gap: 10px; margin-bottom: 16px;
}
.addr-card {
  border: 2px solid #e2e4e9; border-radius: 8px;
  padding: 12px; cursor: pointer;
  transition: border .15s;
  display: block;
}
.addr-card input[type=radio] { display: none; }
.addr-card.selected { border-color: #1a1a1a; }
.addr-card-new { display: flex; align-items: center; justify-content: center; color: #6b7280; min-height: 80px; }
.addr-card-new:hover { border-color: #1a1a1a; color: #1a1a1a; }
.addr-title { font-size: 13px; font-weight: 700; margin-bottom: 4px; }
.addr-text  { font-size: 11.5px; color: #6b7280; line-height: 1.5; margin-bottom: 3px; }
.addr-postal{ font-size: 11px; color: #9ca3af; }
.addr-form  { padding: 0 20px 20px; }

/* روش ارسال */
.shipping-options { display: flex; flex-direction: column; gap: 10px; padding: 16px 20px; }
.shipping-opt {
  border: 2px solid #e2e4e9; border-radius: 8px;
  cursor: pointer; transition: border .15s; display: block;
}
.shipping-opt input[type=radio] { display: none; }
.shipping-opt.selected { border-color: #1a1a1a; }
.so-body {
  display: flex; justify-content: space-between;
  align-items: center; padding: 14px 16px;
}
.so-name { font-size: 13.5px; font-weight: 600; }
.so-desc { font-size: 11.5px; color: #9ca3af; margin-top: 2px; }
.so-price { font-size: 13.5px; font-weight: 700; }

/* خلاصه checkout */
.co-summary {
  background: #fff; border-radius: 12px;
  border: 1px solid #e2e4e9; padding: 22px;
  position: sticky; top: 80px;
}
.co-items-list {
  display: flex; flex-direction: column; gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f3f4f6;
}
.co-item { display: flex; align-items: center; gap: 10px; }
.co-item-img { position: relative; flex-shrink: 0; }
.co-item-img img { width: 48px; height: 48px; border-radius: 6px; object-fit: cover; border: 1px solid #e2e4e9; }
.co-item-img-ph { width: 48px; height: 48px; background: #f3f4f6; border-radius: 6px; display: flex; align-items: center; justify-content: center; }
.co-item-qty {
  position: absolute; top: -6px; right: -6px;
  width: 18px; height: 18px; border-radius: 50%;
  background: #1a1a1a; color: #fff;
  font-size: 10px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.co-item-meta { flex: 1; min-width: 0; }
.co-item-name { font-size: 12.5px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.co-item-price { font-size: 12.5px; font-weight: 700; white-space: nowrap; }

/* درگاه پرداخت */
.payment-method { margin: 16px 0; padding: 14px; background: #f9fafb; border-radius: 8px; }
.pm-label { font-size: 12px; color: #6b7280; margin-bottom: 10px; font-weight: 600; }
.pm-zarinpal { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.pm-desc { font-size: 12px; color: #6b7280; }
.pm-logos { display: flex; gap: 6px; }
.bank-chip { font-size: 11px; background: #e2e4e9; color: #374151; padding: 2px 8px; border-radius: 99px; }
.pay-note { font-size: 11px; color: #9ca3af; text-align: center; margin-top: 8px; }
.btn-success { background: #16a34a !important; }

/* checkbox */
.checkbox-row {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: #374151; cursor: pointer;
  padding: 0 20px 16px;
}
.checkbox-row input { width: 16px; height: 16px; cursor: pointer; }

@media (max-width: 900px) {
  .checkout-layout { grid-template-columns: 1fr; }
  .co-summary { position: static; }
}

/* ===== Breadcrumb ===== */
.breadcrumb-bar {
  background: #f9fafb;
  border-bottom: 1px solid #f3f4f6;
  padding: 10px 0;
}
.breadcrumb-inner {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: #9ca3af;
  flex-wrap: wrap;
}
.breadcrumb-inner a { color: #6b7280; }
.breadcrumb-inner a:hover { color: #1a1a1a; }
.breadcrumb-inner span:last-child { color: #1a1a1a; font-weight: 500; }
.bc-sep { color: #d1d5db; }
.inline-bc { background: transparent; border: none; padding: 0 0 12px; }

/* ===== checkout steps ===== */
.checkout-steps-bar { background: #f9fafb; border-bottom: 1px solid #e2e4e9; padding: 16px 0; }
.steps { display: flex; align-items: center; justify-content: center; gap: 0; }
.step {
  display: flex; flex-direction: column; align-items: center;
  gap: 6px; font-size: 12px; color: #9ca3af;
}
.step.active { color: #1a1a1a; font-weight: 600; }
.step.done   { color: #16a34a; }
.step-circle {
  width: 32px; height: 32px; border-radius: 50%;
  border: 2px solid #e2e4e9;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; background: #fff;
}
.step.active .step-circle { border-color: #1a1a1a; background: #1a1a1a; color: #fff; }
.step.done   .step-circle { border-color: #16a34a; background: #16a34a; color: #fff; }
.step-line { width: 60px; height: 2px; background: #e2e4e9; margin: 0 4px 18px; }
.step-line.done { background: #16a34a; }

/* ===== checkout layout ===== */
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 28px;
  align-items: start;
  padding: 32px 0 80px;
}
.checkout-main { display: flex; flex-direction: column; gap: 20px; }
.co-section {
  background: #fff; border-radius: 12px;
  border: 1px solid #e2e4e9; overflow: hidden;
}
.co-section-head {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px; border-bottom: 1px solid #f3f4f6;
}
.co-section-head h2 { font-size: 15px; font-weight: 700; }
.co-step-num {
  width: 28px; height: 28px; border-radius: 50%;
  background: #1a1a1a; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; flex-shrink: 0;
}
.co-summary {
  background: #fff; border-radius: 12px;
  border: 1px solid #e2e4e9; padding: 24px;
  position: sticky; top: 80px;
}

/* آدرس‌های ذخیره‌شده */
.saved-addresses { padding: 16px 20px; border-bottom: 1px solid #f3f4f6; }
.saved-label { font-size: 12.5px; color: #6b7280; margin-bottom: 10px; font-weight: 600; }
.addr-cards { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.addr-card {
  border: 1px solid #e2e4e9; border-radius: 8px;
  padding: 12px; cursor: pointer; flex: 1; min-width: 180px;
  transition: border .15s;
}
.addr-card input[type=radio] { display: none; }
.addr-card.selected { border-color: #1a1a1a; background: #f9fafb; }
.addr-card-new { border-style: dashed; color: #6b7280; text-align: center; }
.addr-title  { font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.addr-text   { font-size: 12px; color: #6b7280; line-height: 1.5; }
.addr-postal { font-size: 11px; color: #9ca3af; margin-top: 4px; }
.addr-form   { padding: 16px 20px; }

/* shipping options */
.shipping-options { padding: 14px 20px; display: flex; flex-direction: column; gap: 10px; }
.shipping-opt {
  border: 1px solid #e2e4e9; border-radius: 8px;
  cursor: pointer; transition: border .15s;
}
.shipping-opt input[type=radio] { display: none; }
.shipping-opt.selected { border-color: #1a1a1a; }
.so-body { display: flex; align-items: center; justify-content: space-between; padding: 14px; }
.so-name { font-size: 13.5px; font-weight: 600; }
.so-desc { font-size: 12px; color: #9ca3af; }
.so-price { font-size: 13.5px; font-weight: 700; color: #1a1a1a; }

/* checkout summary items */
.co-items-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px solid #f3f4f6; }
.co-item { display: flex; align-items: center; gap: 10px; }
.co-item-img { position: relative; flex-shrink: 0; }
.co-item-img img { width: 48px; height: 48px; border-radius: 6px; object-fit: cover; border: 1px solid #e2e4e9; }
.co-item-img-ph { width: 48px; height: 48px; border-radius: 6px; background: #f3f4f6; display: flex; align-items: center; justify-content: center; }
.co-item-qty { position: absolute; top: -6px; left: -6px; width: 18px; height: 18px; background: #1a1a1a; color: #fff; border-radius: 50%; font-size: 10px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.co-item-meta { flex: 1; }
.co-item-name { font-size: 12.5px; font-weight: 500; }
.co-item-price { font-size: 12.5px; font-weight: 700; white-space: nowrap; }

/* payment method */
.payment-method { margin-bottom: 16px; padding: 14px; background: #f9fafb; border-radius: 8px; }
.pm-label { font-size: 12px; color: #6b7280; margin-bottom: 8px; font-weight: 600; }
.pm-zarinpal { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.pm-desc { font-size: 11.5px; color: #6b7280; }
.pm-logos { display: flex; gap: 6px; flex-wrap: wrap; }
.bank-chip { background: #fff; border: 1px solid #e2e4e9; padding: 2px 8px; border-radius: 4px; font-size: 11px; color: #6b7280; }
.pay-note { font-size: 11px; color: #9ca3af; text-align: center; margin-top: 8px; }
.btn-spinner { width: 16px; height: 16px; border: 2px solid #ffffff60; border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; }

@media (max-width: 900px) {
  .checkout-layout { grid-template-columns: 1fr; }
  .co-summary { position: static; }
}

/* ============================================================
   صفحه جزئیات محصول (product-detail)
   ============================================================ */

/* breadcrumb */
.breadcrumb-bar { background: var(--clr-bg-alt); border-bottom: 1px solid var(--clr-border); padding: 10px 0; }
.breadcrumb-inner { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; font-size: 12.5px; color: var(--clr-text-muted); }
.breadcrumb-inner a { color: var(--clr-text-muted); transition: color .15s; }
.breadcrumb-inner a:hover { color: var(--clr-text); }
.bc-sep { color: var(--clr-border-dk); margin: 0 2px; }

/* layout دو ستونه */
.pd-section { padding: 40px 0 48px; }
.pd-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

/* گالری */
.pd-gallery { position: sticky; top: 80px; }
.pd-main-img-wrap {
  position: relative;
  background: var(--clr-bg-alt);
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--clr-border);
}
.pd-main-img { width: 100%; height: 100%; object-fit: contain; display: block; }
.pd-img-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; }
.pd-badge {
  position: absolute; top: 12px; right: 12px;
  background: var(--clr-steel); color: #fff;
  font-size: 11px; font-weight: 700;
  padding: 4px 10px; border-radius: 20px;
}
.pd-discount-badge {
  position: absolute; top: 12px; left: 12px;
  background: #dc2626; color: #fff;
  font-size: 12px; font-weight: 700;
  padding: 4px 10px; border-radius: 20px;
}
.pd-thumbs {
  display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap;
}
.pd-thumb {
  width: 64px; height: 64px;
  border: 2px solid var(--clr-border);
  border-radius: 8px; overflow: hidden;
  background: var(--clr-bg-alt);
  cursor: pointer; padding: 0;
  transition: border-color .15s;
}
.pd-thumb img { width: 100%; height: 100%; object-fit: contain; }
.pd-thumb.active, .pd-thumb:hover { border-color: var(--clr-steel); }

/* اطلاعات محصول */
.pd-cat-label { font-size: 12px; color: var(--clr-text-muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .04em; }
.pd-title { font-size: 26px; font-weight: 800; line-height: 1.35; margin-bottom: 8px; color: var(--clr-text); }
.pd-sku { font-size: 12px; color: var(--clr-text-muted); margin-bottom: 12px; }
.pd-sku span { color: var(--clr-text-mid); font-weight: 600; }

/* رتبه‌بندی */
.pd-rating { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.stars { display: flex; gap: 2px; }
.pd-rating-val { font-size: 14px; font-weight: 700; }
.pd-rating-count { font-size: 12px; color: var(--clr-text-muted); }

/* قیمت */
.pd-price-wrap { display: flex; flex-direction: column; gap: 4px; margin-bottom: 16px; }
.pd-old-price { font-size: 14px; color: var(--clr-text-muted); text-decoration: line-through; }
.pd-price { font-size: 28px; font-weight: 800; color: var(--clr-text); }
.pd-price small { font-size: 15px; font-weight: 500; }

/* موجودی */
.pd-stock-status { margin-bottom: 16px; }
.stock-chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; padding: 5px 12px;
  border-radius: 20px;
}
.stock-dot { width: 8px; height: 8px; border-radius: 50%; }
.stock-chip.stock-ok  { background: #dcfce7; color: #15803d; }
.stock-chip.stock-ok  .stock-dot { background: #16a34a; }
.stock-chip.stock-low { background: #fef9c3; color: #a16207; }
.stock-chip.stock-low .stock-dot { background: #ca8a04; }
.stock-chip.stock-none{ background: #fee2e2; color: #b91c1c; }
.stock-chip.stock-none .stock-dot { background: #dc2626; }

/* توضیح کوتاه */
.pd-short-desc { font-size: 14px; color: var(--clr-text-mid); line-height: 1.7; margin-bottom: 16px; }

/* مشخصات سریع */
.pd-quick-specs {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 8px; margin-bottom: 24px;
  background: var(--clr-bg-alt);
  border-radius: 10px; padding: 14px 16px;
  border: 1px solid var(--clr-border);
}
.qs-item { display: flex; flex-direction: column; gap: 2px; }
.qs-key  { font-size: 11px; color: var(--clr-text-muted); }
.qs-val  { font-size: 13px; font-weight: 600; color: var(--clr-text); }

/* اکشن‌ها */
.pd-actions { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.pd-qty-wrap {
  display: flex; align-items: center;
  border: 1.5px solid var(--clr-border-dk);
  border-radius: 8px; overflow: hidden;
  height: 46px;
}
.qty-btn {
  width: 40px; height: 100%;
  background: var(--clr-bg-alt); border: none;
  cursor: pointer; font-size: 20px; font-weight: 300;
  color: var(--clr-text); display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.qty-btn:hover:not(:disabled) { background: var(--clr-steel); color: #fff; }
.qty-btn:disabled { opacity: .3; cursor: not-allowed; }
.qty-input {
  width: 48px; text-align: center; border: none;
  border-right: 1.5px solid var(--clr-border-dk);
  border-left:  1.5px solid var(--clr-border-dk);
  font-size: 15px; font-weight: 700;
  font-family: inherit; background: #fff;
  -moz-appearance: textfield;
}
.qty-input::-webkit-inner-spin-button { display: none; }
.btn-add-main {
  flex: 1; height: 46px; display: flex; align-items: center;
  justify-content: center; gap: 8px; font-size: 14.5px;
  border-radius: 8px !important;
}
.btn-add-main.disabled { opacity: .5; cursor: not-allowed; pointer-events: none; }
.btn-add-main.btn-success { background: #16a34a !important; }

/* اعتمادسازی */
.pd-trust-row {
  display: flex; gap: 20px; flex-wrap: wrap;
  padding-top: 16px;
  border-top: 1px solid var(--clr-border);
}
.trust-item {
  display: flex; align-items: center; gap: 6px;
  font-size: 12.5px; color: var(--clr-text-mid);
}

/* ===== تب‌های محصول ===== */
.pd-tabs-section { padding: 0 0 48px; }
.tabs-nav {
  display: flex;
  border-bottom: 2px solid var(--clr-border);
  margin-bottom: 28px;
  gap: 0;
}
.tab-btn {
  padding: 12px 24px;
  background: none; border: none;
  font-family: inherit; font-size: 14px;
  cursor: pointer; color: var(--clr-text-muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -2px; transition: all .15s;
}
.tab-btn:hover  { color: var(--clr-text); }
.tab-btn.active { color: var(--clr-text); font-weight: 700; border-bottom-color: var(--clr-steel); }

/* پنل‌های تب */
.tab-pane { display: none; }
.tab-pane.active { display: block; }

/* توضیحات */
.pd-description { font-size: 14.5px; line-height: 1.9; color: var(--clr-text-mid); max-width: 720px; }
.pd-description p { margin-bottom: 14px; }
.pd-description ul { padding-right: 22px; margin-bottom: 14px; }
.pd-description li { margin-bottom: 6px; }
.pd-description h2, .pd-description h3 { font-weight: 700; margin: 20px 0 10px; color: var(--clr-text); }

/* جدول مشخصات */
.specs-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.specs-table tr { border-bottom: 1px solid var(--clr-border); }
.specs-table tr:last-child { border-bottom: none; }
.specs-table th {
  text-align: right; padding: 12px 16px;
  background: var(--clr-bg-alt);
  font-weight: 700; color: var(--clr-text);
  width: 35%; white-space: nowrap;
}
.specs-table td { padding: 12px 16px; color: var(--clr-text-mid); }

/* ===== نظرات ===== */
.reviews-layout { display: grid; grid-template-columns: 340px 1fr; gap: 32px; align-items: start; }
.review-form-wrap { background: var(--clr-bg-alt); border-radius: 12px; padding: 24px; border: 1px solid var(--clr-border); }
.review-form-wrap h3 { font-size: 15px; font-weight: 700; margin-bottom: 16px; }
.rating-picker { display: flex; align-items: center; gap: 6px; margin-bottom: 14px; font-size: 13px; }
.star-pick { background: none; border: none; cursor: pointer; padding: 2px; transition: transform .1s; }
.star-pick:hover { transform: scale(1.2); }
.review-textarea {
  width: 100%; padding: 10px 12px;
  border: 1.5px solid var(--clr-border-dk); border-radius: 8px;
  font-family: inherit; font-size: 13.5px; line-height: 1.6;
  resize: vertical; min-height: 100px; margin-bottom: 12px;
  background: #fff;
}
.review-textarea:focus { outline: none; border-color: var(--clr-steel); }
.review-login-notice {
  text-align: center; padding: 24px;
  color: var(--clr-text-muted); font-size: 13.5px;
}
.review-login-notice a { color: var(--clr-steel); font-weight: 600; text-decoration: underline; }

/* لیست نظرات */
.reviews-list { display: flex; flex-direction: column; gap: 16px; }
.review-item { background: var(--clr-surface); border: 1px solid var(--clr-border); border-radius: 10px; padding: 18px; }
.rv-header { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.rv-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--clr-steel); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 15px; flex-shrink: 0;
}
.rv-name { font-size: 13.5px; font-weight: 700; }
.rv-date { font-size: 11.5px; color: var(--clr-text-muted); }
.rv-stars { display: flex; gap: 2px; margin-right: auto; }
.rv-text  { font-size: 13.5px; color: var(--clr-text-mid); line-height: 1.7; }
.reviews-empty { text-align: center; padding: 40px; color: var(--clr-text-muted); font-size: 14px; }

/* ===== محصولات مشابه ===== */
.pd-related { padding-top: 0; }
.link-more { font-size: 13px; color: var(--clr-text-mid); border-bottom: 1px solid; }
.link-more:hover { color: var(--clr-text); }

/* ===== toast ===== */
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: #1a1a1a; color: #fff;
  padding: 12px 24px; border-radius: 8px;
  font-size: 14px; font-weight: 500;
  opacity: 0; pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 9999; white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ===== ریسپانسیو ===== */
@media (max-width: 900px) {
  .pd-layout { grid-template-columns: 1fr; gap: 24px; }
  .pd-gallery { position: static; }
  .pd-title { font-size: 20px; }
  .pd-price { font-size: 22px; }
  .reviews-layout { grid-template-columns: 1fr; }
  .tabs-nav { overflow-x: auto; }
  .tab-btn { padding: 10px 16px; font-size: 13px; white-space: nowrap; }
}
@media (max-width: 600px) {
  .pd-actions { flex-wrap: wrap; }
  .btn-add-main { width: 100%; flex: none; }
  .pd-quick-specs { grid-template-columns: 1fr 1fr; }
  .pd-trust-row { gap: 12px; }
}

/* ===== ویژگی‌های قیمتی (variants) ===== */
.pd-variants { margin-bottom: 20px; }
.pd-variants-label { font-size: 13px; font-weight: 700; color: var(--clr-text-muted); margin-bottom: 8px; }
.variants-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.variant-btn {
  display: flex; flex-direction: column; align-items: flex-start;
  gap: 3px; padding: 10px 14px;
  border: 1.5px solid var(--clr-border-dk);
  border-radius: 8px; background: var(--clr-surface);
  cursor: pointer; font-family: inherit;
  font-size: 13px; font-weight: 600; color: var(--clr-text);
  transition: border-color .15s, background .15s;
  min-width: 110px;
}
.variant-btn:hover  { border-color: var(--clr-steel); background: var(--clr-bg-alt); }
.variant-btn.active { border-color: var(--clr-steel); background: var(--clr-steel); color: #fff; }
.variant-btn.active .vb-price { color: #ffffff99; }
.vb-price { font-size: 11.5px; font-weight: 500; color: var(--clr-text-muted); }

/* shipping note در checkout */
.shipping-note {
  display: flex; align-items: center; gap: 6px;
  font-size: 12px; color: var(--clr-text-muted);
  margin-top: 10px; padding: 8px 12px;
  background: var(--clr-bg-alt); border-radius: 6px;
}

/* ===== GALLERY THUMBNAILS — IMPROVED ===== */
.pd-thumbs {
  display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap;
}
.pd-thumb {
  width: 72px; height: 72px;
  border: 2px solid var(--clr-border);
  border-radius: 8px; overflow: hidden;
  background: var(--clr-bg-alt);
  cursor: pointer; padding: 0;
  transition: border-color .15s, transform .15s;
  flex-shrink: 0;
}
.pd-thumb img { width: 100%; height: 100%; object-fit: contain; }
.pd-thumb.active { border-color: var(--clr-steel); box-shadow: 0 0 0 2px rgba(29,78,140,.15); }
.pd-thumb:hover:not(.active) { border-color: #94a3b8; transform: translateY(-1px); }

/* انیمیشن عوض‌شدن عکس اصلی */
.pd-main-img { transition: opacity .18s ease; }
.pd-main-img.fading { opacity: 0; }

/* ===================================================
   BOTTOM TAB BAR — موبایل
   =================================================== */
.bottom-tab-bar {
  display: none;
}

@media (max-width: 768px) {
  .bottom-tab-bar {
    display: flex;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: 62px;
    background: var(--clr-surface);
    border-top: 1px solid var(--clr-border);
    box-shadow: 0 -4px 20px rgba(0,0,0,.08);
    z-index: 1000;
    align-items: stretch;
  }

  /* فضای کافی پایین صفحه تا محتوا زیر بار نره */
  body { padding-bottom: 62px; }

  .btb-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    color: var(--clr-text-muted);
    font-size: 10px;
    font-weight: 500;
    text-decoration: none;
    transition: color .15s;
    padding: 6px 0 8px;
    position: relative;
  }

  .btb-item.active {
    color: var(--clr-steel);
  }

  .btb-item.active svg {
    stroke: var(--clr-steel);
  }

  .btb-item:active {
    background: var(--clr-bg-alt);
  }

  /* نشانگر خط بالای آیتم فعال */
  .btb-item.active::before {
    content: '';
    position: absolute;
    top: 0; left: 20%; right: 20%;
    height: 2px;
    background: var(--clr-steel);
    border-radius: 0 0 2px 2px;
  }

  /* badge سبد خرید */
  .btb-cart-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .btb-badge {
    position: absolute;
    top: -6px; left: -8px;
    min-width: 16px; height: 16px;
    background: #dc2626;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    border: 1.5px solid var(--clr-surface);
  }
}
