*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --cream: #f9f1eb;
  --blush: #e8c4b0;
  --rose: #c98b6e;
  --dark: #2c1f1a;
  --muted: #8a7060;
  --light-bg: #f2f6fc;
  --details-bg: #f8f2ed;
  --card-bg: #eae5e1;
  --white: #ffffff;
  --accent: #b07055;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--white);
  color: var(--dark);
  overflow-x: hidden;
  width: 100%;
}

img {
  border: 0;
  -webkit-user-drag: none;
}

/* ===================== NAVBAR ===================== */
nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 60px;
  background: var(--cream);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.nav-left { 
  display: flex; 
  align-items: center; 
  gap: 12px; 
  cursor: pointer; 
  color: var(--muted); 
  font-size: 14px; 
  user-select: none;
  transition: color 0.25s ease;
}
.nav-left:hover {
  color: var(--dark);
}
.nav-left svg { 
  width: 22px; 
  height: 22px; 
  stroke: currentColor; 
}

.nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  letter-spacing: 2px;
  color: var(--dark);
  text-align: center;
}
.nav-logo span { 
  display: block; 
  font-size: 9px; 
  letter-spacing: 4px; 
  font-family: 'DM Sans', sans-serif; 
  color: var(--muted); 
  text-transform: uppercase; 
}

.nav-right { 
  display: flex; 
  align-items: center; 
  gap: 20px; 
}
.nav-right svg { 
  width: 20px; 
  height: 20px; 
  color: var(--dark); 
  cursor: pointer; 
  transition: transform 0.2s ease, color 0.2s ease;
}
.nav-right svg:hover {
  transform: scale(1.1);
  color: var(--accent);
}

/* ── استایل دراپ‌داون سبد خرید ── */
.cart-menu-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.cart-trigger-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--dark);
}

.cart-trigger-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  transition: transform 0.2s ease, color 0.2s ease;
}

.cart-trigger-btn:hover svg {
  color: var(--accent);
  transform: scale(1.1);
}

/* کادر بازشونده مینی کارت */
.mini-cart-dropdown {
  position: absolute;
  top: calc(100% + 18px);
  right: 0;
  width: 310px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 16px 36px rgba(44, 31, 26, 0.14), 0 2px 8px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(44, 31, 26, 0.08);
  padding: 22px 20px;
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(0.97);
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.3s;
}

/* وضعیت باز بودن */
.mini-cart-dropdown.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

/* پیکان کوچک بالای کادر متصل به آیکون */
.mini-cart-dropdown::before {
  content: "";
  position: absolute;
  top: -7px;
  right: 6px;
  width: 14px;
  height: 14px;
  background: #ffffff;
  transform: rotate(45deg);
  border-top: 1px solid rgba(44, 31, 26, 0.08);
  border-left: 1px solid rgba(44, 31, 26, 0.08);
}

.mini-cart-header {
  border-bottom: 1px solid #f0ebe7;
  padding-bottom: 10px;
  margin-bottom: 18px;
}

.mini-cart-header h4 {
  font-family: 'Playfair Display', serif;
  font-size: 16px;
  font-weight: 600;
  color: #2C1F1A;
}

.mini-cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 8px 0;
}

.empty-icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #F6E2C7;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.empty-icon-wrap svg {
  width: 24px;
  height: 24px;
  stroke: #2C1F1A;
  opacity: 0.85;
}

.empty-title {
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #2C1F1A;
  margin-bottom: 6px;
}

.empty-subtitle {
  font-family: 'DM Sans', sans-serif;
  font-size: 12.5px;
  color: #8a7060;
  line-height: 1.5;
  margin-bottom: 18px;
}

.btn-start-shopping {
  display: inline-block;
  width: 100%;
  padding: 10px 0;
  background: #2C1F1A;
  color: #ffffff;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  letter-spacing: 0.4px;
  transition: background 0.25s ease, transform 0.15s ease;
}

.btn-start-shopping:hover {
  background: #523930;
  transform: translateY(-1px);
}

/* ===================== SIDEBAR MODAL ===================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.modal-backdrop.open {
  opacity: 1;
  visibility: visible;
}

.side-modal {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  max-width: 410px;
  height: 100%;
  background: #ffffff;
  box-shadow: 8px 0 35px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.modal-backdrop.open .side-modal {
  transform: translateX(0);
}

.modal-header {
  padding: 24px 28px 12px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.close-modal-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1a1a1a;
  border-radius: 50%;
  transition: background-color 0.2s, transform 0.2s;
}
.close-modal-btn svg { width: 22px; height: 22px; }
.close-modal-btn:hover {
  background-color: #f3f3f3;
  transform: rotate(90deg);
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0 24px;
}

.modal-nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.modal-nav-links li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  color: #2b2b2b;
  text-decoration: none;
  font-size: 16.5px;
  font-weight: 400;
  transition: background-color 0.2s, color 0.2s, padding-left 0.25s;
}

.modal-nav-links li a:hover {
  background-color: #faf7f5;
  color: #000000;
  padding-left: 38px;
}

.chevron-right {
  width: 17px;
  height: 17px;
  stroke: #9e9e9e;
  transition: transform 0.2s, stroke 0.2s;
}

.modal-nav-links li a:hover .chevron-right {
  transform: translateX(4px);
  stroke: var(--dark);
}

.modal-account-section {
  margin-top: 24px;
  padding: 24px 28px 0;
  border-top: 1px solid #f0ebe7;
}

.account-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.2px;
  color: #8c827c;
  margin-bottom: 16px;
  text-transform: uppercase;
}

.account-auth-btn {
  width: 100%;
  height: 52px;
  background-color: #2C1F1A;
  color: #ffffff;
  border: 1px solid #2C1F1A;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 14px rgba(44, 31, 26, 0.16);
  transition: all 0.25s ease;
}

.auth-icon { width: 19px; height: 19px; stroke: currentColor; }
.account-auth-btn:hover {
  background-color: #432f27;
  border-color: #432f27;
  box-shadow: 0 6px 18px rgba(44, 31, 26, 0.24);
  transform: translateY(-1px);
}

/* ===================== HERO SECTION ===================== */
.hero {
  background: var(--light-bg);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 80px;
  padding: 60px 80px 80px;
  width: 100%;
}

.gallery-wrap {
  display: flex;
  gap: 28px;
  align-items: flex-start;
}

.thumbnails {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 72px;
}

.thumb-frame {
  position: relative;
  background: #eae4e0;
  height: 86px;
  width: 72px;
  border-radius: 8px;
  cursor: pointer;
  overflow: hidden;
  border: 2px solid transparent;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), 
              border-color 0.3s ease, 
              box-shadow 0.3s ease;
}

.thumb-frame:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 6px 16px rgba(44, 31, 26, 0.15);
  border-color: var(--accent) 0.2px;
}

.thumb-frame.active {
  border-color: var(--dark);
  box-shadow: 0 4px 14px rgba(44, 31, 26, 0.2);
}

.thumb {
  position: absolute;
  inset: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: transform 0.3s ease;
}
.thumb-frame:hover .thumb img {
  transform: scale(1.05);
}

.main-image {
  background: #eae4e0;
  width: 480px;
  height: 520px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
}

.main-image-inner {
  width: 80%;
  height: 80%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.main-image-inner img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: opacity 0.35s ease, transform 0.6s ease;
}

.main-image-inner img.fade-out {
  opacity: 0;
  transform: scale(0.96);
}

.product-info {
  max-width: 520px;
  width: 100%;
}

.product-info-inner {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.product-heading-block {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.eyebrow {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #a8734c;
}

.product-title {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 42px;
  line-height: 1.15;
  color: var(--dark);
}

.product-desc {
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
}

.product-purchase-block {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.rating-price-block {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rating-price {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.rating {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 15px;
  color: #f0a500;
}

.price {
  font-size: 32px;
  font-weight: 600;
  color: var(--dark);
}

.divider {
  background: #c4bbb7;
  height: 1px;
  width: 100%;
}

.options-block {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.color-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.label-caps {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--dark);
}

/* ── Color Swatches با هاور برجسته و استروک ضخیم‌تر ── */
.color-swatches {
  display: flex;
  align-items: center;
  gap: 12px;
}

.color-swatch-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid #ffffff;
  outline: 1.5px solid #2d1f1a;
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), outline-width 0.2s ease, outline-color 0.2s ease, box-shadow 0.25s ease;
}

.color-swatch-circle:hover {
  transform: scale(1.18);
  outline-width: 3.5px;
  outline-color: var(--dark);
  box-shadow: 0 4px 10px rgba(44, 31, 26, 0.25);
}

.color-swatch-circle.active {
  outline-width: 3.5px;
  outline-color: var(--dark);
  transform: scale(1.15);
}

.qty-cart-block {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.qty-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.qty-stepper {
  background: #f2f6fc;
  border: 1px solid #2d1f1a;
  border-radius: 6px;
  height: 38px;
  width: 110px;
  display: flex;
  overflow: hidden;
  align-items: center;
}

.qty-btn {
  width: 36px;
  height: 100%;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 16px;
  color: var(--dark);
  transition: background 0.2s;
}
.qty-btn:hover { background: rgba(44, 31, 26, 0.08); }

.qty-value {
  flex: 1;
  text-align: center;
  font-size: 15px;
  font-weight: 500;
  color: var(--dark);
}

.cart-block {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.add-to-cart {
  background: #523930;
  color: var(--white);
  height: 48px;
  width: 100%;
  max-width: 340px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.5s ease;
}
.add-to-cart:hover {
  background: #77594e;
}
.add-to-cart:active { transform: translateY(0); }
.add-to-cart span {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.shipping-note {
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
}

/* ===================== PRODUCT DETAILS ===================== */
.details {
  background: var(--details-bg);
  padding: 80px 80px;
  width: 100%;
  display: flex;
  justify-content: center;
}

.details-inner {
  max-width: 1280px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 60px;
}

.details-row {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 80px;
}

.details-left {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.details-left-heading {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-bottom: 30px;
}

.eyebrow-lg { font-size: 12px; letter-spacing: 1.8px; }

.details-title {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 44px;
  line-height: 1.2;
  color: var(--dark);
}

.details-desc {
  font-size: 16px;
  line-height: 1.75;
  color: var(--muted);
}

.how-to-use {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.how-to-text {
  font-size: 15px;
  line-height: 1.7;
  color: #4f4f4f;
}

.details-right {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.specs {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.spec-line {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
}
.spec-label {
  font-weight: 500;
  font-size: 14px;
  color: var(--dark);
  width: 40%;
}
.spec-value {
  font-size: 14px;
  color: var(--muted);
  width: 60%;
}
.spec-divider {
  background: #c4bbb7;
  height: 1px;
  width: 100%;
}

/* ── ۱. حل مشکل شکست خط در RETURNS BOX ── */
.returns-box {
  background: #eae4e0;
  padding: 20px 28px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 60px;
  width: 100%;
  white-space: nowrap;          /* جلوگیری از شکست خط متن */
  overflow-x: auto;             /* اسکرول تمیز در صورت کوچک شدن صفحه */
}

.returns-box::-webkit-scrollbar {
  display: none;                /* پنهان‌سازی اسکرول‌بار اضافه */
}

.returns-title {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 1.2px;
  color: #523930;
  flex-shrink: 0;
}

.returns-text {
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  color: #8a7060;
  flex-shrink: 0;
  white-space: nowrap;
}

/* ===================== RELATED PRODUCTS ===================== */
.related {
  padding: 80px 80px 100px;
  background: var(--light-bg);
  width: 100%;
  overflow: hidden;
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 48px;
}

.related-title {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 38px;
  color: var(--dark);
  margin-top: 6px;
}

.nav-arrows {
  display: flex;
  gap: 16px;
}

.arrow-btn {
  width: 40px;
  height: 40px;
  border: 1px solid var(--dark);
  border-radius: 8px;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease;
}
.arrow-btn:hover {
  background: #E5DCD7;
  transform: translateY(-2px);
}
.arrow-btn svg {
  width: 12px;
  height: 20px;
}

.products-scroll {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  align-items: start;
}

/* Product Card - بر اساس معماری پایدار فایل ۱ */
.product-card {
  background: transparent;
  border-radius: 16px;
  cursor: pointer;
  width: 100%;
  max-width: 270px;
  margin: 0 auto;
  position: relative;
  transition: transform 0.3s ease;
}

.product-card:nth-child(even) {
  margin-top: 24px;
}

.product-img {
  width: 100%;
  height: 290px;
  background: var(--card-bg);
  border-radius: 14px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  box-shadow: 0 4px 18px rgba(0,0,0,0.03);
}

.product-img img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  transition: transform 1.5s ease; /* انیمیشن نرم ۱.۵ ثانیه‌ای زوم */
}

.product-card:hover .product-img img {
  transform: scale(1.1);
}

.product-name {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 300;
  color: var(--dark);
  margin-bottom: 14px;
  margin-left: 6px;
}

.color-dots {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
  margin-left: 6px;
}

.dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  transition: transform 0.2s ease;
}
.dot:hover {
  transform: scale(1.25);
}

.product-price {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: 'DM Sans', sans-serif;
  font-size: 24px;
  font-weight: 500;
  color: #2C1F1A;
  margin-left: 8px;
}

/* نماد دلار، عدد و سنت کاملاً چسبیده به هم */
.price-val {
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
}

.price-val sup {
  font-size: 16px;
  vertical-align: super;
  margin-right: 1px;
}

.price-val sub {
  font-size: 10px;
  font-weight: 400;
  color: #2C1F1A;
  margin-left: 2px;
}

/* ===================== FOOTER ===================== */
footer {
  background-color: #3d3d3d;
  color: #ffffff;
  width: 100%;
  padding: 70px 80px 40px;
  text-align: center;
}

.footer__logo {
  font-family: 'Playfair Display', serif;
  font-size: 2.8rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #ffffff;
  margin-bottom: 40px;
  display: block;
}

.footer__top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 60px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding: 20px 0;
  margin-bottom: 48px;
}
.footer__top a {
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.2s;
}
.footer__top a:hover { color: #ffffff; }

.footer__main {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px 48px;
  margin-bottom: 48px;
}
.footer__main a {
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.2s;
}
.footer__main a:hover { color: #ffffff; }

.footer__socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  margin-bottom: 48px;
}
.footer__socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.85;
  transition: opacity 0.2s, transform 0.2s;
}
.footer__socials a:hover {
  opacity: 1;
  transform: translateY(-3px);
}
.footer__socials img { width: 34px; height: 34px; object-fit: contain; }

.footer__legal {
  font-size: 0.78rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.8;
}
.footer__legal a { color: rgba(255, 255, 255, 0.6); text-decoration: none; }
.footer__legal a:hover { color: rgba(255, 255, 255, 0.9); }

.mo30 {
  font-size: 22px;
  font-weight: 400;
  color: #F9F1EB;
  font-style: italic;
  font-family: serif;
  letter-spacing: 2px;
  margin-top: 14px;
}

/* ===================== RESPONSIVE (MEDIA QUERIES) ===================== */
@media (max-width: 1100px) {
  nav { padding: 16px 36px; }
  .hero { gap: 40px; padding: 40px 36px; }
  .main-image { width: 380px; height: 440px; }
  .details { padding: 60px 36px; }
  .details-row { grid-template-columns: 1fr; gap: 40px; }
  .related { padding: 60px 36px; }
  .products-scroll { grid-template-columns: repeat(2, 1fr); gap: 32px; }
  .product-card:nth-child(even) { margin-top: 0; }
  footer { padding: 50px 36px 30px; }
}

@media (max-width: 820px) {
  .hero {
    flex-direction: column;
    align-items: center;
    padding: 30px 20px;
  }
  .gallery-wrap {
    flex-direction: column-reverse;
    align-items: center;
    width: 100%;
    gap: 16px;
  }
  .thumbnails {
    flex-direction: row;
    width: 100%;
    justify-content: center;
    gap: 12px;
  }
  .thumb-frame {
    width: 64px;
    height: 76px;
  }
  .main-image {
    width: 100%;
    max-width: 440px;
    height: 380px;
  }
  .product-info {
    max-width: 100%;
  }
  .returns-box {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 20px;
  }
}

@media (max-width: 680px) {
  nav { padding: 14px 18px; }
  .nav-left span { display: none; }
  .nav-logo { font-size: 19px; }
  
  .details { padding: 40px 18px; }
  .details-title { font-size: 32px; }
  
  .related { padding: 40px 18px; }
  .nav-arrows { display: none; }
  
  /* کارت‌های محصولات در موبایل به صورت اسکرول افقی لمسی */
  .products-scroll {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding-bottom: 16px;
    scroll-snap-type: x mandatory;
  }
  .products-scroll::-webkit-scrollbar { display: none; }
  
  .product-card {
    min-width: 75%;
    max-width: 75%;
    flex-shrink: 0;
    scroll-snap-align: start;
  }
  
  
  .side-modal {
    max-width: 86%;
  }
  
  .footer__top {
    gap: 24px;
  }
  .footer__main {
    gap: 16px 24px;
  }
}

/* ===================== LINEAR SEARCH INPUT ===================== */
.menu-toggle-btn {
  display: flex;
  align-items: center;
  cursor: pointer;
  color: var(--muted);
  transition: color 0.2s ease;
}
.menu-toggle-btn:hover {
  color: var(--dark);
}

.nav-search-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.search-trigger-text {
  cursor: pointer;
  color: var(--muted);
  font-size: 14px;
  user-select: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}
.search-trigger-text:hover {
  color: var(--dark);
}

.search-inline-field {
  display: none;
  align-items: center;
  position: relative;
  width: 0;
  overflow: hidden;
  opacity: 0;
  border-bottom: 1.5px solid var(--dark);
  transition: width 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
}

.nav-search-wrapper.is-searching .search-trigger-text {
  display: none;
}

.nav-search-wrapper.is-searching .search-inline-field {
  display: flex;
  width: 175px;
  opacity: 1;
}

.search-line-input {
  width: 100%;
  background: transparent;
  border: none;
  outline: none;
  font-family: 'DM Sans', sans-serif;
  font-size: 13.5px;
  color: var(--dark);
  padding: 3px 26px 3px 2px;
}
.search-line-input::placeholder {
  color: var(--muted);
  font-size: 12.5px;
}

.search-action-btn {
  position: absolute;
  right: 0;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: var(--dark);
}
.search-action-btn svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  transition: transform 0.2s ease;
}
.search-action-btn:hover svg {
  transform: scale(1.15);
}

/* ===================== WISHLIST & CART DROPDOWNS ===================== */
.wishlist-menu-wrapper,
.cart-menu-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.wishlist-trigger-btn,
.cart-trigger-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--dark);
}

.wishlist-trigger-btn svg,
.cart-trigger-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  transition: transform 0.2s ease, color 0.2s ease;
}

.wishlist-trigger-btn:hover svg,
.cart-trigger-btn:hover svg {
  color: var(--accent);
  transform: scale(1.12);
}

.mini-wishlist-dropdown,
.mini-cart-dropdown {
  position: absolute;
  top: calc(100% + 18px);
  right: 0;
  width: 310px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 16px 36px rgba(44, 31, 26, 0.14), 0 2px 8px rgba(0, 0, 0, 0.04);
  border: 1px solid rgba(44, 31, 26, 0.08);
  padding: 22px 20px;
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(0.97);
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.3s;
}

.mini-wishlist-dropdown.is-open,
.mini-cart-dropdown.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.mini-wishlist-dropdown::before,
.mini-cart-dropdown::before {
  content: "";
  position: absolute;
  top: -7px;
  right: 6px;
  width: 14px;
  height: 14px;
  background: #ffffff;
  transform: rotate(45deg);
  border-top: 1px solid rgba(44, 31, 26, 0.08);
  border-left: 1px solid rgba(44, 31, 26, 0.08);
}

.mini-dropdown-header {
  border-bottom: 1px solid #f0ebe7;
  padding-bottom: 10px;
  margin-bottom: 18px;
}

.mini-dropdown-header h4 {
  font-family: 'Playfair Display', serif;
  font-size: 16px;
  font-weight: 600;
  color: #2C1F1A;
}

.mini-dropdown-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 8px 0;
}

.empty-icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #F6E2C7;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.empty-icon-wrap.empty-heart {
  background: #f8ded7;
}

.empty-icon-wrap svg {
  width: 24px;
  height: 24px;
  stroke: #2C1F1A;
  opacity: 0.85;
}

.empty-title {
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #2C1F1A;
  margin-bottom: 6px;
}

.empty-subtitle {
  font-family: 'DM Sans', sans-serif;
  font-size: 12.5px;
  color: #8a7060;
  line-height: 1.5;
  margin-bottom: 18px;
}

.btn-start-shopping {
  display: inline-block;
  width: 100%;
  padding: 10px 0;
  background: #2C1F1A;
  color: #ffffff;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  letter-spacing: 0.4px;
  transition: background 0.25s ease, transform 0.15s ease;
}

.btn-start-shopping:hover {
  background: #523930;
  transform: translateY(-1px);
}


/* Related product cards: persistent actions, original image zoom retained. */
.product-card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
.product-card-heading .product-name { margin-bottom: 0; min-width: 0; font-family: 'DM Sans', sans-serif; }
.product-card .product-price { gap: 22px; }
.product-card .price-val { flex-shrink: 0; }
.btn-buy, .btn-buyy {
  position: relative;
  z-index: 2;
  flex: 1;
  min-width: 0;
  margin: 0;
  padding: 10px 0px;
  border: 1px solid #563c32;
  border-radius: 8px;
  background: #614034;
  color: #F9F1EB;
  font: 500 12px 'DM Sans', sans-serif;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .2s ease, border-color .2s ease;
}
.btn-buy:hover, .btn-buyy:hover { background: #77594e; border-color: #38261f; }
.btn-save {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #77594e;
  cursor: pointer;
}
.btn-save svg { grid-area: 1 / 1; transition: opacity .18s ease; pointer-events: none; }
.save-icon-hover { opacity: 0; }
.btn-save:is(:hover, :focus-visible, [aria-pressed="true"]) .save-icon-default { opacity: 0; }
.btn-save:is(:hover, :focus-visible, [aria-pressed="true"]) .save-icon-hover { opacity: 1; }
.btn-save:focus-visible, .btn-buy:focus-visible, .btn-buyy:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.btn-buy::after, .btn-buyy::after {
  content: "";
  display: inline-block;
  width: 0;
  height: 14px;
  margin-left: 0;
  vertical-align: -2px;
  background-color: currentColor;
  --buy-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2220%22%20height%3D%2220%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22none%22%3E%3Cpath%20d%3D%22M5%201.66669L2.5%205.00002V16.6667C2.5%2017.1087%202.67559%2017.5326%202.98816%2017.8452C3.30072%2018.1578%203.72464%2018.3334%204.16667%2018.3334H15.8333C16.2754%2018.3334%2016.6993%2018.1578%2017.0118%2017.8452C17.3244%2017.5326%2017.5%2017.1087%2017.5%2016.6667V5.00002L15%201.66669H5Z%22%20stroke%3D%22%232C1F1A%22%20stroke-width%3D%221.66667%22%2F%3E%3Cpath%20d%3D%22M2.5%205H17.5%22%20stroke%3D%22%232C1F1A%22%20stroke-width%3D%221.66667%22%2F%3E%3Cpath%20d%3D%22M13.3346%208.33331C13.3346%209.21737%2012.9834%2010.0652%2012.3583%2010.6903C11.7332%2011.3155%2010.8854%2011.6666%2010.0013%2011.6666C9.11725%2011.6666%208.2694%2011.3155%207.64428%2010.6903C7.01916%2010.0652%206.66797%209.21737%206.66797%208.33331%22%20stroke%3D%22%232C1F1A%22%20stroke-width%3D%221.66667%22%2F%3E%3C%2Fsvg%3E");
  -webkit-mask: var(--buy-icon) center / contain no-repeat;
  mask: var(--buy-icon) center / contain no-repeat;
  opacity: 0;
  pointer-events: none;
  transition: width .2s ease, margin-left .2s ease, opacity .2s ease;
}
.btn-buy:hover::after, .btn-buyy:hover::after { width: 14px; margin-left: 5px; opacity: 1; }
