:root {
  --primary: #d62828;
  --primary-dark: #c1271f;
  --bg-light: #f5f5f5;
  --white: #ffffff;
  --black: #000000;
  --dark: #1a1a1a;
  --dark-2: #292929;
  --text: #333333;
  --gray: #888888;
  --gray-light: #bbbbbb;
  --border: #dddddd;
  --overlay: rgba(0, 0, 0, 0.65);
  --overlay-soft: rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] {
  --primary: #ff4d4d;
  --primary-dark: #ff1f1f;
  --bg-light: #121212;
  --white: #1e1e1e;
  --black: #ffffff;
  --dark: #e4e4e4;
  --dark-2: #cccccc;
  --text: #e4e4e4;
  --gray: #aaaaaa;
  --gray-light: #888888;
  --border: #2a2a2a;
  --overlay: #ffffff14;
  --overlay-soft: rgba(255, 255, 255, 0.05);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(1.5vh);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(3vw);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-3vw);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes popIn {
  0% {
    opacity: 0;
    transform: scale(0.85);
  }
  70% {
    transform: scale(1.04);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% center;
  }
  100% {
    background-position: 200% center;
  }
}

@keyframes pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(214, 40, 40, 0.35);
  }
  50% {
    box-shadow: 0 0 0 0.6vh rgba(214, 40, 40, 0);
  }
}

@keyframes rowEnter {
  from {
    opacity: 0;
    transform: translateX(2vw);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes badgePop {
  0% {
    transform: scale(0.7);
    opacity: 0;
  }
  80% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.about-header {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  z-index: 100;
  padding: 2vh 4vh;
}

.about-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.about-header__logo img {
  height: 5.5vh;
  width: auto;
  object-fit: contain;
  filter: brightness(0) invert(1); /* لوگو روی تصویر تیره سفید بشه */
}

/* hero باید position: relative داشته باشه */
.hero-section {
  position: relative;
}

/* ─── دکمه تم روی hero (رنگ سفید چون پس‌زمینه تیره‌ست) ─── */
.about-header .theme-toggle {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.35);
  color: #ffffff;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.about-header .theme-toggle:hover {
  background: rgba(255, 255, 255, 0.28);
  border-color: rgba(255, 255, 255, 0.6);
  transform: scale(1.1) rotate(15deg);
}

.theme-toggle {
  position: relative;
  width: 5.2vh;
  height: 5.2vh;
  border-radius: 50%;
  border: 0.2vh solid var(--border);
  background: var(--white);
  color: var(--text);
  cursor: pointer !important;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.35s ease,
              border-color 0.35s ease,
              transform 0.3s ease,
              box-shadow 0.3s ease;
  overflow: hidden;
}

.theme-toggle:hover {
  background: var(--bg-light);
  /* border-color: var(--primary); */
  transform: scale(1.1) rotate(15deg);
  box-shadow: 0 0.5vh 2vh rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] .theme-toggle:hover {
  box-shadow: 0 0.5vh 2vh rgba(0, 0, 0, 0.4);
}

/* ─── آیکون‌ها ────────────────────────────────── */
.theme-toggle__icon {
  position: relative;
  width: 2.4vh;
  height: 2.4vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-toggle svg {
  position: absolute;
  width: 2.4vh;
  height: 2.4vh;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  transition: opacity 0.35s ease,
              transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* حالت روشن: خورشید نشان بده، ماه پنهان */
.icon-sun {
  opacity: 1;
  transform: rotate(0deg) scale(1);
  color: var(--accent, #ffb400);
}

.icon-moon {
  opacity: 0;
  transform: rotate(-90deg) scale(0.5);
  fill: none;
}

/* حالت دارک: ماه نشان بده، خورشید پنهان */
[data-theme="dark"] .icon-sun {
  opacity: 0;
  transform: rotate(90deg) scale(0.5);
}

[data-theme="dark"] .icon-moon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
  color: var(--accent, #ffc933);
}

/* ─── اگه داخل ناوبار هست ───────────────────── */
.nav-actions .theme-toggle,
.header-icons .theme-toggle {
  margin-inline-start: 1vh;
}

/* ─── نسخه فیکس گوشه صفحه (اختیاری) ─────────── */
.theme-toggle--fixed {
  position: fixed;
  bottom: 4vh;
  left: 2.6vh;
  z-index: 9999;
  width: 5.85vh;
  height: 5.85vh;
  box-shadow: 0 0.65vh 3vh rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .theme-toggle--fixed {
  box-shadow: 0 0.65vh 3vh rgba(0, 0, 0, 0.5);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb-bar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 1.2vh 4vw;
  animation: fadeIn 0.4s ease both;
}

.breadcrumb-inner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--gray);
  direction: rtl;
}

.breadcrumb-inner a {
  color: var(--text);
  text-decoration: none;
  transition:
    color 0.2s,
    opacity 0.2s;
}

.breadcrumb-inner a:hover {
  color: var(--primary);
  opacity: 0.85;
}

.bc-sep {
  color: var(--gray-light);
  font-size: 1rem;
}

.bc-current {
  color: var(--text);
  font-weight: 600;
}

/* ---------- Cart Wrapper ---------- */
.cart-wrapper {
  display: flex;
  flex-direction: row-reverse;
  align-items: flex-start;
  gap: 2vw;
  max-width: 1200px;
  margin: 3vh auto 5vh;
  padding: 0 2vw;
  direction: rtl;
}

/* ---------- Items Section ---------- */
.cart-items-section {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2vh;
  animation: slideInLeft 0.5s ease both;
}

.cart-section-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  animation: fadeUp 0.4s ease 0.1s both;
}

.cart-section-title h2 {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 700;
  color: var(--dark);
}

.cart-count {
  background: var(--primary);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.3vh 0.9rem;
  border-radius: 2rem;
  animation: badgePop 0.5s ease 0.3s both;
  transition: background 0.3s;
}

/* ---------- Table Wrap ---------- */
.cart-table-wrap {
  background: var(--white);
  border-radius: 1rem;
  box-shadow: 0 0.3vh 1.5vh rgba(0, 0, 0, 0.08);
  overflow: hidden;
  animation: fadeUp 0.5s ease 0.15s both;
  transition: box-shadow 0.3s;
}

.cart-table-wrap:hover {
  box-shadow: 0 0.6vh 2.5vh rgba(0, 0, 0, 0.12);
}

/* ---------- Table ---------- */
.cart-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  direction: rtl;
}

.cart-table thead tr {
  background: var(--bg-light);
  border-bottom: 2px solid var(--border);
}

.cart-table th {
  padding: 1.4vh 1rem;
  text-align: right;
  font-weight: 700;
  color: var(--gray);
  font-size: 0.8rem;
  white-space: nowrap;
  letter-spacing: 0.02em;
}

.cart-table td {
  padding: 1.8vh 1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  color: var(--text);
  transition: background 0.2s;
}

.cart-table tbody tr:last-child td {
  border-bottom: none;
}

.cart-table tbody tr {
  animation: rowEnter 0.4s ease both;
  transition: background 0.2s;
}

.cart-table tbody tr:nth-child(1) {
  animation-delay: 0.1s;
}
.cart-table tbody tr:nth-child(2) {
  animation-delay: 0.2s;
}
.cart-table tbody tr:nth-child(3) {
  animation-delay: 0.3s;
}
.cart-table tbody tr:nth-child(4) {
  animation-delay: 0.4s;
}

.cart-table tbody tr:hover {
  background: color-mix(in srgb, var(--primary) 4%, var(--white));
}

/* ---------- Product Cell ---------- */
.cart-product-cell {
  min-width: 200px;
}

.cart-product-info {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.cart-thumb {
  width: clamp(52px, 6vw, 72px);
  height: clamp(52px, 6vw, 72px);
  object-fit: cover;
  border-radius: 0.6rem;
  border: 1px solid var(--border);
  flex-shrink: 0;
  background: var(--bg-light);
  transition:
    transform 0.3s,
    box-shadow 0.3s;
}

.cart-thumb:hover {
  transform: scale(1.08);
  box-shadow: 0 0.4vh 1.2vh rgba(0, 0, 0, 0.15);
}

.cart-product-text {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.cart-product-name {
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--dark);
  line-height: 1.4;
  transition: color 0.2s;
}

.cart-product-name:hover {
  color: var(--primary);
}

.cart-product-brand,
.cart-product-code {
  font-size: 0.75rem;
  color: var(--gray);
}

/* ---------- Price ---------- */
.price-cell {
  white-space: nowrap;
  text-align: right;
}

.unit-price {
  font-weight: 600;
  color: var(--text);
  font-size: 0.95rem;
}

.price-unit {
  font-size: 0.7rem;
  color: var(--gray-light);
  margin-right: 2px;
}

.row-total-cell {
  text-align: right;
}

.row-total {
  font-weight: 700;
  color: var(--dark);
  font-size: 0.95rem;
  transition: color 0.3s;
}

/* ---------- Qty Control ---------- */
.qty-cell {
  text-align: center;
}

.qty-control {
  display: inline-flex;
  align-items: center;
  border: 1.5px solid var(--border);
  border-radius: 0.5rem;
  overflow: hidden;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}

.qty-control:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 0.3vh color-mix(in srgb, var(--primary) 20%, transparent);
}

.qty-btn {
  background: var(--bg-light);
  border: none;
  width: 2rem;
  height: 2.2rem;
  font-size: 1.1rem;
  cursor: pointer;
  color: var(--text);
  transition:
    background 0.2s,
    color 0.2s,
    transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qty-btn:hover {
  background: var(--primary);
  color: #fff;
}

.qty-btn:active {
  transform: scale(0.9);
}

.qty-input {
  width: 2.8rem;
  height: 2.2rem;
  border: none;
  border-right: 1.5px solid var(--border);
  border-left: 1.5px solid var(--border);
  text-align: center;
  font-size: 0.95rem;
  font-family: inherit;
  outline: none;
  color: var(--dark);
  background: var(--white);
}

.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
}

/* ---------- Remove Button ---------- */
.remove-cell {
  text-align: center;
}

.remove-btn {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--gray-light);
  transition:
    color 0.2s,
    transform 0.2s,
    background 0.2s;
  padding: 0.4vh 0.5rem;
  border-radius: 0.4rem;
}

.remove-btn:hover {
  color: var(--primary);
  transform: scale(1.25) rotate(-5deg);
  background: color-mix(in srgb, var(--primary) 10%, transparent);
}

/* ---------- Coupon Bar ---------- */
.coupon-bar {
  background: var(--white);
  border-radius: 0.9rem;
  box-shadow: 0 0.2vh 1vh rgba(0, 0, 0, 0.06);
  padding: 2vh 1.5rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  animation: fadeUp 0.5s ease 0.25s both;
  border: 1px solid var(--border);
  transition:
    border-color 0.3s,
    box-shadow 0.3s;
}

.coupon-bar:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0.3vh 1.5vh color-mix(in srgb, var(--primary) 12%, transparent);
}

.coupon-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--dark);
  white-space: nowrap;
}

.coupon-input-wrap {
  display: flex;
  flex: 1;
  min-width: 200px;
  max-width: 380px;
  border-radius: 0.5rem;
  overflow: hidden;
  border: 1.5px solid var(--border);
  transition: border-color 0.2s;
}

.coupon-input-wrap:focus-within {
  border-color: var(--primary);
}

.coupon-input {
  flex: 1;
  border: none;
  padding: 1vh 0.9rem;
  font-size: 0.875rem;
  font-family: inherit;
  outline: none;
  direction: rtl;
  color: var(--text);
  background: var(--bg-light);
}

.coupon-input::placeholder {
  color: var(--gray-light);
}

.coupon-btn {
  background: var(--dark);
  color: #fff;
  border: none;
  padding: 1vh 1.2rem;
  font-size: 0.875rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition:
    background 0.2s,
    transform 0.15s;
  white-space: nowrap;
}

.coupon-btn:hover {
  background: var(--primary);
}
.coupon-btn:active {
  transform: scale(0.97);
}

.coupon-msg {
  font-size: 0.8rem;
  font-weight: 500;
  flex-basis: 100%;
  animation: fadeIn 0.3s ease both;
}

.coupon-msg.success {
  color: #27ae60;
}
.coupon-msg.error {
  color: var(--primary);
}

/* ---------- Bottom Actions ---------- */
.cart-actions-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  animation: fadeUp 0.5s ease 0.3s both;
}

.btn-back-shop {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 1.1vh 1.4rem;
  background: var(--white);
  border: 2px solid var(--dark);
  color: var(--dark);
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: 0.6rem;
  text-decoration: none;
  transition:
    background 0.25s,
    color 0.25s,
    transform 0.2s;
}

.btn-back-shop:hover {
  background: var(--dark);
  color: #fff;
  transform: translateX(3px);
}

.btn-clear-cart {
  background: none;
  border: 2px solid var(--border);
  color: var(--gray);
  padding: 1.1vh 1.2rem;
  border-radius: 0.6rem;
  font-size: 0.8rem;
  cursor: pointer;
  font-family: inherit;
  transition:
    border-color 0.25s,
    color 0.25s,
    transform 0.2s;
}

.btn-clear-cart:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: scale(1.03);
}

/* ============================================================
   Summary Sidebar
   ============================================================ */
.cart-summary {
  width: clamp(260px, 26vw, 320px);
  flex-shrink: 0;
  background: var(--white);
  border-radius: 1rem;
  box-shadow: 0 0.4vh 2vh rgba(0, 0, 0, 0.09);
  padding: 2.8vh 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.4vh;
  position: sticky;
  top: 2.5vh;
  animation: slideInRight 0.5s ease 0.2s both;
  border: 1px solid var(--border);
  transition: box-shadow 0.3s;
}

.cart-summary:hover {
  box-shadow: 0 0.8vh 3vh rgba(0, 0, 0, 0.13);
}

.summary-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
  padding-bottom: 1.4vh;
  border-bottom: 2px solid var(--border);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.875rem;
  color: var(--gray);
  transition: color 0.2s;
}

.discount-value {
  color: #27ae60;
  font-weight: 600;
}
.shipping-value {
  color: #27ae60;
  font-weight: 600;
}

.summary-divider {
  height: 1px;
  background: var(--border);
  margin: 0.4vh 0;
}

.summary-total-row {
  font-size: 1rem;
  font-weight: 700;
  color: var(--dark);
}

.summary-total-price {
  color: var(--primary);
  font-size: 1.15rem;
  font-weight: 800;
  transition: transform 0.3s;
}

/* ---------- Badges ---------- */
.summary-badges {
  display: flex;
  flex-direction: column;
  gap: 0.6vh;
  background: color-mix(in srgb, var(--primary) 5%, var(--bg-light));
  border-radius: 0.7rem;
  padding: 1.4vh 1rem;
  border: 1px solid color-mix(in srgb, var(--primary) 15%, var(--border));
}

.badge-item {
  font-size: 0.8rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  animation: fadeUp 0.4s ease both;
}

.badge-item:nth-child(1) {
  animation-delay: 0.35s;
}
.badge-item:nth-child(2) {
  animation-delay: 0.45s;
}
.badge-item:nth-child(3) {
  animation-delay: 0.55s;
}

/* ---------- Checkout Button ---------- */
.btn-checkout {
  width: 100%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  background-size: 200% auto;
  color: #fff;
  border: none;
  padding: 1.6vh 1rem;
  border-radius: 0.7rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition:
    background-position 0.4s,
    transform 0.2s,
    box-shadow 0.3s;
  letter-spacing: 0.03em;
  box-shadow: 0 0.4vh 1.4vh rgba(214, 40, 40, 0.35);
  animation: pulse 2.5s ease-in-out 1s infinite;
}

.btn-checkout:hover {
  background-position: right center;
  transform: translateY(-2px);
  box-shadow: 0 0.7vh 2vh rgba(214, 40, 40, 0.45);
  animation: none;
}

.btn-checkout:active {
  transform: translateY(0);
}

/* ---------- Secure Pay ---------- */
.secure-pay {
  text-align: center;
  font-size: 0.75rem;
  color: var(--gray);
}

.payment-methods {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6vh;
  padding-top: 0.4vh;
}

.pm-label {
  font-size: 0.75rem;
  color: var(--gray-light);
}

.pm-icons {
  display: flex;
  gap: 0.5rem;
}

.pm-badge {
  background: var(--bg-light);
  color: var(--gray);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.4vh 0.75rem;
  border-radius: 0.4rem;
  border: 1px solid var(--border);
  transition:
    background 0.2s,
    color 0.2s,
    transform 0.2s;
}

.pm-badge:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-2px);
}

/* ============================================================
   Empty Cart
   ============================================================ */
.empty-cart {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8vh 2rem;
  text-align: center;
  gap: 1.6vh;
  max-width: 480px;
  margin: 4vh auto;
  background: var(--white);
  border-radius: 1rem;
  box-shadow: 0 0.2vh 1.4vh rgba(28, 28, 28, 0.07);
  animation: popIn 0.5s ease both;
  border: 1px solid var(--border);
}

.empty-cart-icon {
  font-size: clamp(3.5rem, 8vw, 5rem);
  line-height: 1;
  animation: popIn 0.6s ease 0.2s both;
}

.empty-cart h3 {
  font-size: clamp(1.1rem, 3vw, 1.4rem);
  font-weight: 700;
  color: var(--dark);
}

.empty-cart p {
  font-size: 0.875rem;
  color: var(--gray);
}

.btn-go-shop {
  display: inline-block;
  margin-top: 0.8vh;
  padding: 1.2vh 2rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  text-decoration: none;
  border-radius: 0.7rem;
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: 0 0.4vh 1.2vh rgba(214, 40, 40, 0.35);
  transition:
    opacity 0.2s,
    transform 0.2s;
}

.btn-go-shop:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

/* ============================================================
   Footer
   ============================================================ */
footer {
  background: #111;
  color: #fff;
  padding: 6vh 8% 3vh;
  cursor: default;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 4vh 2rem;
}

.footer-col h4 {
  margin-bottom: 1.5vh;
  font-size: 1.1rem;
}

.footer-col p,
.footer-col a {
  display: block;
  margin: 0.7vh 0;
  font-size: 0.875rem;
  color: #bbb;
  text-decoration: none;
  transition:
    color 0.3s,
    transform 0.3s;
}

.footer-col a:hover {
  color: var(--primary);
  cursor: pointer;
  transform: translateX(-5px);
}

.namad-box {
  width: 120px;
  height: 120px;
  background: #fff;
  border-radius: 10px;
}

.footer-divider {
  grid-column: 1 / -1;
  height: 1px;
  background: rgba(255, 255, 255, 0.15);
  margin-top: 2vh;
}

.footer-copy {
  grid-column: 1 / -1;
  text-align: center;
  font-size: 0.8rem;
  color: #aaa;
  margin-top: 1vh;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .cart-wrapper {
    flex-direction: column;
    padding: 0 4vw;
    gap: 2.5vh;
  }

  .cart-summary {
    width: 100%;
    position: static;
    animation: fadeUp 0.5s ease both;
  }
}

@media (max-width: 640px) {
  .cart-wrapper {
    padding: 0 3vw;
    margin: 2vh auto 4vh;
  }

  .cart-table th:nth-child(2),
  .cart-table td:nth-child(2) {
    display: none;
  }

  .cart-thumb {
    width: 48px;
    height: 48px;
  }

  .cart-product-name {
    font-size: 0.8rem;
  }

  .cart-table th,
  .cart-table td {
    padding: 1.2vh 0.6rem;
  }

  .coupon-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .coupon-input-wrap {
    width: 100%;
    max-width: 100%;
  }

  .breadcrumb-bar {
    padding: 1vh 4vw;
  }

  .cart-section-title h2 {
    font-size: 1rem;
  }

  .btn-checkout {
    font-size: 0.9rem;
    padding: 1.4vh 1rem;
  }
}

@media (max-width: 400px) {
  .cart-table th:nth-child(4),
  .cart-table td:nth-child(4) {
    display: none;
  }

  .qty-btn {
    width: 1.8rem;
  }
  .qty-input {
    width: 2.2rem;
  }
}

/* ============================================================
   استایل‌های اضافی برای دکمه‌های فرم
   ============================================================ */

/* دکمه‌های حذف در فرم */
.remove-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--gray-light);
    transition: color 0.2s, transform 0.2s, background 0.2s;
    padding: 0.4vh 0.5rem;
    border-radius: 0.4rem;
    font-family: pinar, sans-serif;
}

.remove-btn:hover {
    color: var(--primary);
    transform: scale(1.25) rotate(-5deg);
    background: rgba(214, 40, 40, 0.1);
}

/* دکمه‌های + و - */
.qty-btn {
    background: var(--bg-light);
    border: none;
    width: 2rem;
    height: 2.2rem;
    font-size: 1.1rem;
    cursor: pointer;
    color: var(--text);
    transition: background 0.2s, color 0.2s, transform 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: pinar, sans-serif;
}

.qty-btn:hover:not(:disabled) {
    background: var(--primary);
    color: #fff;
}

.qty-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* دکمه خالی کردن سبد */
.btn-clear-cart {
    background: none;
    border: 2px solid var(--border);
    color: var(--gray);
    padding: 1.1vh 1.2rem;
    border-radius: 0.6rem;
    font-size: 0.8rem;
    cursor: pointer;
    font-family: pinar, sans-serif;
    transition: border-color 0.25s, color 0.25s, transform 0.2s;
}

.btn-clear-cart:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: scale(1.03);
}

/* دکمه بازگشت به فروشگاه */
.btn-back-shop {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 1.1vh 1.4rem;
    background: var(--white);
    border: 2px solid var(--dark);
    color: var(--dark);
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 0.6rem;
    text-decoration: none;
    transition: background 0.25s, color 0.25s, transform 0.2s;
    font-family: pinar, sans-serif;
}

.btn-back-shop:hover {
    background: var(--dark);
    color: #fff;
    transform: translateX(3px);
}

/* دکمه اعمال کد تخفیف */
.coupon-btn {
    background: var(--dark);
    color: #fff;
    border: none;
    padding: 1vh 1.2rem;
    font-size: 0.875rem;
    font-weight: 700;
    cursor: pointer;
    font-family: pinar, sans-serif;
    transition: background 0.2s, transform 0.15s;
    white-space: nowrap;
}

.coupon-btn:hover {
    background: var(--primary);
}

.coupon-btn:active {
    transform: scale(0.97);
}

.coupon-btn.remove-coupon {
    background: #ef4444;
}

.coupon-btn.remove-coupon:hover {
    background: #dc2626;
}

/* دکمه ثبت سفارش */
.btn-checkout {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    background-size: 200% auto;
    color: #fff;
    border: none;
    padding: 1.6vh 1rem;
    border-radius: 0.7rem;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    font-family: pinar, sans-serif;
    transition: background-position 0.4s, transform 0.2s, box-shadow 0.3s;
    letter-spacing: 0.03em;
    box-shadow: 0 0.4vh 1.4vh rgba(214, 40, 40, 0.35);
    text-align: center;
    text-decoration: none;
    display: block;
}

.btn-checkout:hover {
    background-position: right center;
    transform: translateY(-2px);
    box-shadow: 0 0.7vh 2vh rgba(214, 40, 40, 0.45);
}

/* دکمه رفتن به فروشگاه در سبد خالی */
.btn-go-shop {
    display: inline-block;
    margin-top: 0.8vh;
    padding: 1.2vh 2rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    text-decoration: none;
    border-radius: 0.7rem;
    font-size: 0.95rem;
    font-weight: 600;
    box-shadow: 0 0.4vh 1.2vh rgba(214, 40, 40, 0.35);
    transition: opacity 0.2s, transform 0.2s;
    font-family: pinar, sans-serif;
}

.btn-go-shop:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* ============================================================
   استایل‌های مخصوص دارک مود
   ============================================================ */
body.dark .cart-table-wrap {
    background: var(--dark);
    border-color: var(--border);
}

body.dark .cart-table thead tr {
    background: var(--dark-2);
}

body.dark .coupon-bar {
    background: var(--dark);
}

body.dark .coupon-input {
    background: var(--dark-2);
    color: var(--text);
}

body.dark .coupon-input::placeholder {
    color: var(--gray);
}

body.dark .cart-summary {
    background: var(--dark);
}

body.dark .summary-badges {
    background: var(--dark-2);
}

body.dark .pm-badge {
    background: var(--dark-2);
}

body.dark .empty-cart {
    background: var(--dark);
}

body.dark .btn-back-shop {
    background: var(--dark);
    border-color: var(--border);
    color: var(--text);
}

body.dark .btn-back-shop:hover {
    background: var(--primary);
    color: #fff;
}

body.dark .btn-clear-cart {
    border-color: var(--border);
    color: var(--gray);
}

body.dark .btn-clear-cart:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* ============================================================
   استایل‌های ریسپانسیو
   ============================================================ */
@media (max-width: 640px) {
    .cart-table th:nth-child(2),
    .cart-table td:nth-child(2) {
        display: none;
    }
    
    .coupon-bar {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .coupon-input-wrap {
        width: 100%;
        max-width: 100%;
    }
    
    .cart-actions-bottom {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    
    .btn-back-shop,
    .btn-clear-cart {
        text-align: center;
        justify-content: center;
    }
}

@media (max-width: 400px) {
    .cart-table th:nth-child(4),
    .cart-table td:nth-child(4) {
        display: none;
    }
    
    .qty-btn {
        width: 1.8rem;
    }
    
    .qty-input {
        width: 2.2rem;
    }
}

/* ============================================================
   TOAST NOTIFICATION - استایل کامل
   ============================================================ */

/* Toast اصلی */
.toast-custom {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 20px;
    border-radius: 12px;
    color: white;
    font-size: 15px;
    font-weight: 500;
    z-index: 99999;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    max-width: 420px;
    min-width: 280px;
    display: none;
    align-items: center;
    gap: 12px;
    font-family: pinar, sans-serif;
    direction: rtl;
    transform: translateX(100px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

/* نمایش Toast */
.toast-custom.show {
    display: flex !important;
    transform: translateX(0);
    opacity: 1;
}

/* آیکون Toast */
.toast-custom .toast-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
    font-size: 18px;
    background: rgba(255, 255, 255, 0.2);
}

/* پیام Toast */
.toast-custom .toast-message {
    flex: 1;
    line-height: 1.6;
}

/* ============================================================
   انواع Toast
   ============================================================ */

/* موفقیت */
.toast-custom.success {
    background: linear-gradient(135deg, #10b981, #059669);
    border-color: rgba(16, 185, 129, 0.3);
}

.toast-custom.success .toast-icon {
    color: #10b981;
    background: rgba(255, 255, 255, 0.25);
}

/* خطا */
.toast-custom.error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-color: rgba(239, 68, 68, 0.3);
}

.toast-custom.error .toast-icon {
    color: #ef4444;
    background: rgba(255, 255, 255, 0.25);
}

/* اطلاع‌رسانی */
.toast-custom.info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: rgba(59, 130, 246, 0.3);
}

.toast-custom.info .toast-icon {
    color: #3b82f6;
    background: rgba(255, 255, 255, 0.25);
}

/* هشدار */
.toast-custom.warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-color: rgba(245, 158, 11, 0.3);
}

.toast-custom.warning .toast-icon {
    color: #f59e0b;
    background: rgba(255, 255, 255, 0.25);
}

/* ============================================================
   دکمه بستن Toast
   ============================================================ */
.toast-custom .toast-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 20px;
    cursor: pointer;
    padding: 0 4px;
    transition: all 0.3s ease;
    line-height: 1;
    flex-shrink: 0;
}

.toast-custom .toast-close:hover {
    color: white;
    transform: scale(1.2);
}

/* ============================================================
   انیمیشن ورود
   ============================================================ */
@keyframes toastSlideIn {
    from {
        transform: translateX(100px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
}

@keyframes toastSlideOut {
    from {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
    to {
        transform: translateX(50px) scale(0.95);
        opacity: 0;
    }
}

.toast-custom.show {
    animation: toastSlideIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.toast-custom.hide {
    animation: toastSlideOut 0.4s ease forwards;
}

/* ============================================================
   Toast در موبایل
   ============================================================ */
@media (max-width: 640px) {
    .toast-custom {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: unset;
        min-width: unset;
        padding: 14px 16px;
        font-size: 14px;
        border-radius: 10px;
    }
    
    .toast-custom .toast-icon {
        width: 28px;
        height: 28px;
        font-size: 16px;
    }
}

@media (max-width: 400px) {
    .toast-custom {
        top: 8px;
        right: 8px;
        left: 8px;
        padding: 12px 14px;
        font-size: 13px;
    }
    
    .toast-custom .toast-icon {
        width: 24px;
        height: 24px;
        font-size: 14px;
    }
}

/* ============================================================
   دارک مود Toast
   ============================================================ */
body.dark .toast-custom {
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

body.dark .toast-custom.success {
    background: linear-gradient(135deg, #065f46, #047857);
}

body.dark .toast-custom.error {
    background: linear-gradient(135deg, #7f1d1d, #991b1b);
}

body.dark .toast-custom.info {
    background: linear-gradient(135deg, #1e3a5f, #1e40af);
}

body.dark .toast-custom.warning {
    background: linear-gradient(135deg, #78350f, #92400e);
}

body.dark .toast-custom .toast-icon {
    background: rgba(255, 255, 255, 0.1);
}