/* کیامو — پالت رنگ نسخهٔ اولیه (نعناعی، سبز، زرد، نارنجی) */
:root {
  --mint: #8fb9ad;
  --mint2: #7eaea1;
  --mint-deep: #5e9588;
  --bg: #8fb9ad;
  --panel: #efefef;
  --yellow: #f1d156;
  --ink: #1f2d2a;
  --muted: #4e6660;
  --green: #1f8f69;
  --green-light: #2aa57b;
  --orange: #ff7a35;

  --brown: var(--green);
  --brown-2: #17805f;
  --brown-3: var(--ink);
  --brown-soft: var(--green-light);

  --page: #dbe8e4;
  --white: #fff;
  --line: rgba(31, 45, 42, 0.1);
  --shadow: 0 12px 28px rgba(0, 0, 0, 0.1);
  --shadow-sm: 0 4px 16px rgba(0, 0, 0, 0.06);
  --radius: 16px;
  --radius-sm: 12px;
  --chat: var(--orange);
  --footer-dark: #1a2c28;
  --footer-card: #243832;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-snap: cubic-bezier(0.34, 1.56, 0.64, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  overflow-x: hidden;
  font-family: "Vazirmatn", system-ui, sans-serif;
  background: var(--page);
  color: var(--ink);
  line-height: 1.55;
}

button,
input[type="submit"],
input[type="button"],
input[type="reset"],
.btn-brown,
.btn-outline,
.btn-cart {
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-synthesis: none;
}

@keyframes ambientDrift {
  0% {
    opacity: 0.42;
    transform: scale(1) translate(0, 0);
  }

  100% {
    opacity: 0.72;
    transform: scale(1.06) translate(-1.5%, 1.2%);
  }
}

@keyframes barShimmer {
  0%,
  15% {
    transform: translateX(-120%);
    opacity: 0;
  }

  35% {
    opacity: 0.55;
  }

  55%,
  100% {
    transform: translateX(120%);
    opacity: 0;
  }
}

@keyframes navLiPop {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes dotGlow {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(31, 143, 105, 0.35);
  }

  50% {
    box-shadow: 0 0 12px 2px rgba(31, 143, 105, 0.25);
  }
}

@media (prefers-reduced-motion: no-preference) {
  html.motion body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
      radial-gradient(ellipse 120% 70% at 50% -5%, rgba(255, 255, 255, 0.28) 0%, transparent 52%),
      radial-gradient(ellipse 80% 55% at 0% 100%, rgba(31, 143, 105, 0.09) 0%, transparent 48%),
      radial-gradient(ellipse 70% 50% at 100% 85%, rgba(241, 209, 86, 0.08) 0%, transparent 42%);
    animation: ambientDrift 22s ease-in-out infinite alternate;
  }
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.wrap {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 18px;
}

/* ——— sticky header ——— */
.site-head {
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
  max-width: 100vw;
  transition: box-shadow 0.35s var(--ease-out);
}

.site-head.site-head--lift {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
}

/* نوار بالا — گرادیان نعناعی / سبز دودی */
.bar-top {
  position: relative;
  overflow: visible;
  background: linear-gradient(180deg, var(--mint) 0%, var(--mint-deep) 48%, #3d6b60 100%);
  color: #fff;
  padding: 12px 0;
}

.bar-top::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 45%;
  height: 2px;
  border-radius: 99px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.65), transparent);
  opacity: 0;
  pointer-events: none;
}

@media (prefers-reduced-motion: no-preference) {
  html.motion .bar-top::after {
    animation: barShimmer 6.5s ease-in-out infinite;
  }
}

.bar-top__grid {
  display: flex;
  align-items: center;
  gap: 14px;
}

.bar-top__brand {
  flex-shrink: 0;
}

.bar-top__search {
  flex: 1;
  min-width: 0;
  display: flex;
  justify-content: flex-start;
  position: relative;
}

.bar-top__search-toggle {
  display: none !important;
}

.bar-top__icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.12);
  color: #fff;
  cursor: pointer;
}

.bar-top__icon-btn svg {
  display: block;
}

.bar-top__account-icon {
  display: none;
  line-height: 0;
}

.bar-top__account-icon svg {
  display: block;
}

.logo {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-align: center;
}

.search-field {
  width: 100%;
  max-width: 460px;
  height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.96);
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  transition:
    box-shadow 0.35s var(--ease-out),
    transform 0.35s var(--ease-out),
    border-color 0.25s ease;
}

.search-field:focus-within {
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.45), 0 10px 28px rgba(0, 0, 0, 0.12);
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.65);
}

.search-field input {
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
}

.search-field input::placeholder {
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  color: rgba(78, 102, 96, 0.72);
  opacity: 1;
}

.search-field svg {
  flex-shrink: 0;
  color: var(--brown);
  opacity: 0.75;
}

.search-suggest {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 1300;
  background: #fff;
  color: var(--ink);
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(20, 32, 28, 0.22);
  overflow: hidden;
  max-height: min(50dvh, 360px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.search-suggest__list {
  list-style: none;
  margin: 0;
  padding: 6px;
}

.search-suggest__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
}

.search-suggest__item:hover,
.search-suggest__item:focus {
  background: #f3f7f5;
  text-decoration: none;
}

.search-suggest__thumb {
  width: 52px;
  height: 52px;
  object-fit: cover;
  border-radius: 10px;
  background: #eee;
  flex-shrink: 0;
}

.search-suggest__meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.search-suggest__title {
  font-weight: 800;
  font-size: 0.92rem;
  line-height: 1.35;
}

.search-suggest__price {
  font-size: 0.82rem;
  color: var(--brown-3);
  font-weight: 700;
}

.search-suggest__oos {
  font-size: 0.75rem;
  color: #b42318;
}

.search-suggest__empty {
  margin: 0;
  padding: 16px;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
}

@media (min-width: 1101px) {
  .search-field svg {
    display: none;
  }
}

.logo:hover,
.logo:focus {
  text-decoration: none;
}

.logo:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.45);
  outline-offset: 4px;
  border-radius: 12px;
}

.logo__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.logo:hover .logo__mark,
.logo:focus .logo__mark {
  transform: none;
  box-shadow: none;
}

.logo__img {
  display: block;
  height: 40px;
  width: auto;
  max-width: min(220px, 46vw);
  object-fit: contain;
}

.logo:hover .logo__img,
.logo:focus .logo__img {
  transform: none;
}

.logo__sub {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  opacity: 0.88;
}

.bar-top__actions {
  direction: ltr;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px 16px;
  font-size: 13px;
}

.bar-top__actions a {
  opacity: 0.92;
  white-space: nowrap;
  transition: opacity 0.2s ease, transform 0.25s var(--ease-snap);
}

.bar-top__actions a:hover {
  text-decoration: underline;
  transform: translateY(-2px);
}

.cart-mini {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.12);
  font-weight: 800;
  font-size: 13px;
  transition: background 0.25s ease, transform 0.25s var(--ease-snap), border-color 0.25s ease;
}

.cart-mini:hover {
  background: rgba(0, 0, 0, 0.2);
  transform: translateY(-2px);
}

.cart-mini__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.32s var(--ease-snap), opacity 0.25s ease;
}

.cart-mini__img--empty,
.cart-mini__img--full {
  width: 28px;
  height: 28px;
  object-fit: contain;
  display: block;
  filter: brightness(0) invert(1);
  transition: transform 0.32s var(--ease-snap), opacity 0.25s ease;
}

.cart-mini:hover .cart-mini__img--empty,
.cart-mini:hover .cart-mini__img--full {
  transform: scale(1.06);
}

.cart-mini__icon--full {
  display: none;
}

.cart-mini--has-items .cart-mini__icon--empty {
  display: none;
}

.cart-mini--has-items .cart-mini__icon--full {
  display: inline-flex;
}

.cart-mini--has-items .cart-mini__img--full {
  animation: cartIconFill 0.45s var(--ease-out);
}

.cart-mini--has-items {
  border-color: rgba(42, 165, 123, 0.55);
  background: rgba(31, 143, 105, 0.22);
}

@keyframes cartIconFill {
  0% {
    opacity: 0;
    transform: scale(0.75) rotate(-8deg);
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(0);
  }
}

.cart-mini__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--green-light);
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.cart-mini__count.is-hidden {
  display: none;
}

@media (max-width: 960px) {
  .search-field {
    max-width: none;
  }
}

/* منوی سفید — یک ردیف؛ در صورت کمبود عرض اسکرول لمسی بدون نوار اسکرول */
.nav-main {
  background: var(--white);
  border-bottom: 1px solid var(--line);
  max-width: 100%;
}

.nav-main .wrap {
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  overflow-x: auto;
  overflow-y: visible;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.nav-main .wrap::-webkit-scrollbar {
  display: none;
  height: 0;
}

.nav-main__inner {
  padding: 4px 0 2px;
  min-width: 0;
}

.nav-main ul {
  list-style: none;
  margin: 0 auto;
  padding: 8px 4px 10px;
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: center;
  gap: 1px;
  width: max-content;
  max-width: none;
}

.nav-main li {
  position: relative;
  flex: 0 0 auto;
}

.nav-main > .nav-main__inner > ul > li > a,
.nav-main .nav-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: auto;
  min-height: 42px;
  padding: 8px 10px 6px;
  font-size: clamp(11px, 1.05vw, 13px);
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  line-height: 1.2;
  border-bottom: 3px solid transparent;
  background: none;
  border-top: 0;
  border-left: 0;
  border-right: 0;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.22s ease, border-color 0.28s var(--ease-out), transform 0.22s var(--ease-snap);
}

.nav-main li:hover > a,
.nav-main li:hover .nav-trigger {
  color: var(--brown);
  transform: translateY(-1px);
}

.nav-main li.is-active > a,
.nav-main li.is-active .nav-trigger,
.nav-main a[aria-current="page"] {
  border-bottom-color: var(--brown);
  color: var(--brown-3);
}

.nav-main li.is-open .nav-trigger {
  color: var(--brown);
  border-bottom-color: var(--brown-soft);
}

.nav-chev {
  font-size: 8px;
  opacity: 0.55;
  transition: transform 0.3s var(--ease-out), opacity 0.25s ease;
}

.nav-main li.is-open .nav-chev {
  transform: rotate(-180deg);
  opacity: 0.85;
}

@media (max-width: 1320px) {
  .nav-main .wrap {
    overflow-x: visible;
    overflow-y: visible;
  }

  .nav-main ul {
    flex-wrap: wrap;
    justify-content: center;
    align-content: flex-start;
    width: 100%;
    max-width: 100%;
    row-gap: 2px;
    column-gap: 1px;
  }

  .nav-main__inner {
    padding-bottom: 8px;
  }
}

@media (prefers-reduced-motion: no-preference) {
  html.motion .nav-main > .nav-main__inner > ul > li {
    animation: navLiPop 0.52s var(--ease-out) backwards;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(1) {
    animation-delay: 0.02s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(2) {
    animation-delay: 0.042s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(3) {
    animation-delay: 0.064s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(4) {
    animation-delay: 0.086s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(5) {
    animation-delay: 0.108s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(6) {
    animation-delay: 0.13s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(7) {
    animation-delay: 0.152s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(8) {
    animation-delay: 0.174s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(9) {
    animation-delay: 0.196s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(10) {
    animation-delay: 0.218s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(11) {
    animation-delay: 0.24s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(12) {
    animation-delay: 0.262s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(13) {
    animation-delay: 0.284s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(14) {
    animation-delay: 0.306s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(15) {
    animation-delay: 0.328s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(16) {
    animation-delay: 0.35s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(17) {
    animation-delay: 0.372s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(18) {
    animation-delay: 0.394s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(19) {
    animation-delay: 0.416s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(20) {
    animation-delay: 0.438s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(21) {
    animation-delay: 0.46s;
  }

  html.motion .nav-main > .nav-main__inner > ul > li:nth-child(22) {
    animation-delay: 0.482s;
  }
}

/* لایهٔ تمام‌صفحهٔ زیرمنو — باز شدن روان */
.nav-mega-root {
  position: fixed;
  inset: 0;
  z-index: 5000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 0;
}

.nav-mega-root[hidden] {
  display: none !important;
  pointer-events: none;
}

.nav-mega-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  padding: 0;
  margin: 0;
  background: rgba(31, 45, 42, 0);
  cursor: pointer;
  animation: navMegaBackdrop 0.3s ease forwards;
}

@keyframes navMegaBackdrop {
  to {
    background: rgba(31, 45, 42, 0.45);
  }
}

.nav-mega-sheet {
  position: relative;
  z-index: 2;
  width: min(720px, 100%);
  max-height: min(78vh, 640px);
  margin-top: max(12px, env(safe-area-inset-top, 0px));
  margin-inline: 12px;
  background: var(--white);
  border-radius: 16px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: navMegaIn 0.34s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes navMegaIn {
  from {
    opacity: 0;
    transform: translateY(-16px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.nav-mega-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(143, 185, 173, 0.35) 0%, #fff 100%);
}

.nav-mega-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--brown-3);
}

.nav-mega-x {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  color: var(--ink);
  transition: transform 0.25s var(--ease-snap), background 0.2s ease, border-color 0.2s ease;
}

.nav-mega-x:hover {
  background: rgba(31, 143, 105, 0.08);
  color: var(--brown);
  transform: rotate(90deg) scale(1.05);
}

.nav-mega-body {
  overflow-y: auto;
  padding: 12px 16px 18px;
  -webkit-overflow-scrolling: touch;
}

.nav-mega-panel[hidden] {
  display: none !important;
}

.nav-mega-cat {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
}

.nav-mega-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 8px;
}

.nav-mega-link {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  background: #fafafa;
  transition: background 0.22s ease, border-color 0.22s ease, transform 0.22s var(--ease-out), box-shadow 0.22s ease;
}

.nav-mega-link:hover {
  border-color: rgba(31, 143, 105, 0.35);
  background: rgba(31, 143, 105, 0.06);
  color: var(--brown-3);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(31, 45, 42, 0.08);
}

body.nav-mega-open {
  overflow: hidden;
}

/* ——— main spacing ——— */
main {
  padding-bottom: 48px;
}

.sec {
  margin-top: 26px;
}

.sec-divider {
  margin: 16px 0 20px;
  padding: 0;
  border: 0;
  height: 1px;
  background: rgba(31, 143, 105, 0.22);
}

.sec-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.sec-head h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sec-head .rule {
  flex: 1;
  height: 1px;
  background: rgba(31, 143, 105, 0.22);
}

.sec-head--between {
  justify-content: space-between;
}

.sec-head--between h2 {
  flex: 0 0 auto;
}

.link-more {
  font-weight: 800;
  font-size: 13px;
  color: var(--brown);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.22s ease, gap 0.3s var(--ease-out);
}

.link-more:hover {
  text-decoration: underline;
  gap: 10px;
}

.link-more span[aria-hidden="true"] {
  display: inline-block;
  transition: transform 0.35s var(--ease-out);
}

.link-more:hover span[aria-hidden="true"] {
  transform: translateX(-4px);
}

/* ——— هیرو: دو کارت در هر اسلاید ——— */
.hero {
  margin-top: 18px;
  position: relative;
  overflow: hidden;
}

.hero-view {
  overflow: hidden;
  border-radius: 18px;
  background: #cfe5dc;
  direction: ltr;
  touch-action: pan-y;
}

.hero-track {
  display: flex;
  width: 100%;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.hero-track.is-dragging {
  transition: none;
}

.hero-slide {
  flex: 0 0 100%;
  width: 100%;
  min-width: 100%;
  max-width: 100%;
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  padding: 14px;
  box-sizing: border-box;
}

@media (min-width: 1101px) {
  .hero-slide {
    flex: 0 0 50%;
    width: 50%;
    min-width: 50%;
    max-width: 50%;
    grid-template-columns: 1fr;
  }
}

.hero-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  min-height: 260px;
  background: linear-gradient(160deg, #9ec9bb 0%, #5d8f82 55%, #3d6b60 100%);
  box-shadow: var(--shadow-sm);
  transition: transform 0.45s var(--ease-out), box-shadow 0.45s ease;
}

.hero-card:hover {
  transform: translateY(-5px) scale(1.01);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.16);
}

.hero-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.65s var(--ease-out);
}

.hero-card:hover img {
  transform: scale(1.07);
}

.hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(31, 45, 42, 0.12) 0%, rgba(31, 45, 42, 0.55) 100%);
  z-index: 1;
}

.hero-card__body {
  position: relative;
  z-index: 2;
  height: 100%;
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px 18px;
  text-align: center;
  direction: rtl;
  color: #fff;
  transition: transform 0.45s var(--ease-out);
}

.hero-card:hover .hero-card__body {
  transform: translateY(-4px);
}

.hero-card__body h3 {
  margin: 0 0 16px;
  font-size: clamp(1.15rem, 2.4vw, 1.55rem);
  font-weight: 900;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.35);
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: var(--ink);
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  transition: transform 0.35s var(--ease-snap), box-shadow 0.35s ease, background 0.25s ease;
}

.hero-card:hover .hero-pill {
  transform: scale(1.05);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.92);
  color: #555;
  cursor: pointer;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease-snap), background 0.25s ease, color 0.2s ease, box-shadow 0.3s ease;
  direction: ltr;
  unicode-bidi: isolate;
}

.hero-arrow svg {
  display: block;
  flex-shrink: 0;
}

.hero-arrow:hover {
  color: var(--brown);
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
  background: #fff;
}

.hero-arrow--prev {
  right: 10px;
}

.hero-arrow--next {
  left: 10px;
}

.hero-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 12px;
  position: relative;
  inset-inline: 0;
}

.hero-dot {
  width: 28px;
  height: 3px;
  border-radius: 99px;
  border: 0;
  padding: 0;
  background: rgba(31, 143, 105, 0.2);
  cursor: pointer;
  transition: width 0.35s var(--ease-out), background 0.3s ease, transform 0.25s ease;
}

.hero-dot:hover {
  background: rgba(31, 143, 105, 0.45);
  transform: translateY(-1px);
}

.hero-dot.is-active {
  background: var(--brown);
  width: 36px;
}

@media (max-width: 820px) {
  .hero-card {
    min-height: 220px;
  }

  .hero-arrow {
    display: none;
  }
}

/* ——— پیشنهاد شگفت‌انگیز ——— */
.offers-board {
  display: grid;
  gap: 18px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  overflow: visible;
}

@media (max-width: 1080px) {
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .grid-4 {
    grid-template-columns: 1fr;
  }
}

.card-offer {
  position: relative;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  border: 2px solid transparent;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition-property: transform, box-shadow, border-color;
  transition-duration: 0.55s, 0.45s, 0.35s;
  transition-timing-function: var(--ease-out), ease, ease;
  transform-origin: center center;
}

.card-offer:hover {
  z-index: 2;
  transform: translateY(-3px);
  border-color: var(--green);
  box-shadow:
    0 10px 24px rgba(31, 143, 105, 0.14),
    0 4px 12px rgba(0, 0, 0, 0.05),
    0 0 0 1px rgba(31, 143, 105, 0.12);
}

.card-offer__media {
  position: relative;
  background: #f1f1f1;
  overflow: hidden;
}

.card-offer__media img {
  width: 100% !important;
  height: 100% !important;
  object-fit: fill !important;
  max-height: 1254px !important;
  max-width: 1254px !important;
}
.card-offer__media { max-height: 1254px !important; overflow: hidden !important; max-width: 1254px !important; }

.discount-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--yellow);
  color: #2a1a00;
  font-weight: 900;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 2;
  transition: transform 0.4s var(--ease-snap), box-shadow 0.3s ease;
}

.card-offer:hover .discount-badge {
  transform: rotate(-8deg) scale(1.06);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}

.card-offer__body {
  padding: 10px 12px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.card-offer__title {
  font-size: 12px;
  font-weight: 800;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

.card-offer__price del {
  display: block;
  font-size: 12px;
  color: #888;
}

.card-offer__price strong {
  font-size: 15px;
  font-weight: 900;
  color: #000 !important;
}

.btn-brown {
  margin-top: auto;
  display: block;
  text-align: center;
  padding: 11px 14px;
  border-radius: 11px;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-weight: 800;
  font-size: 0.9rem;
  line-height: 1.45;
  background: var(--brown);
  color: #fff;
  border: 0;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: background 0.25s ease, transform 0.22s var(--ease-snap), box-shadow 0.3s ease;
}

.btn-brown::before {
  content: "";
  position: absolute;
  inset: 0;
  left: -40%;
  width: 55%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.28), transparent);
  transform: skewX(-14deg) translateX(-180%);
  pointer-events: none;
  z-index: -1;
}

.btn-brown:hover::before {
  animation: btnShine 0.85s ease forwards;
}

.btn-brown:hover {
  background: var(--brown-2);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(31, 143, 105, 0.35);
}

.btn-brown:active {
  transform: translateY(0) scale(0.98);
}

/* ——— گرید دسته‌های عکس‌دار خانه ——— */
.grid-cats {
  margin-top: 34px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 16px;
}

.grid-cats[data-cols="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-cats[data-cols="5"] { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.grid-cats[data-cols="6"] { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.grid-cats[data-cols="7"] { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.grid-cats[data-cols="8"] { grid-template-columns: repeat(8, minmax(0, 1fr)); }

.grid-cats[data-cols="4"] .cat-blob { max-width: 140px; }
.grid-cats[data-cols="5"] .cat-blob { max-width: 128px; }
.grid-cats[data-cols="8"] .cat-blob { max-width: 98px; }

@media (max-width: 1100px) {
  .grid-cats,
  .grid-cats[data-cols="5"],
  .grid-cats[data-cols="6"],
  .grid-cats[data-cols="7"],
  .grid-cats[data-cols="8"] {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .grid-cats[data-cols="4"] {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .grid-cats[data-cols="8"] .cat-blob,
  .grid-cats[data-cols="5"] .cat-blob {
    max-width: 112px;
  }
}

@media (max-width: 520px) {
  .grid-cats,
  .grid-cats[data-cols] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-cats[data-cols="4"] .cat-blob,
  .grid-cats[data-cols="5"] .cat-blob,
  .grid-cats[data-cols="8"] .cat-blob {
    max-width: 112px;
  }
}

.cat-cell {
  background: rgba(255, 255, 255, 0.65);
  border-radius: 16px;
  padding: 16px 10px 14px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s ease, background 0.3s ease;
}

.cat-cell:hover {
  box-shadow: var(--shadow);
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.88);
}

.cat-blob {
  width: 100%;
  max-width: 112px;
  aspect-ratio: 1;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: linear-gradient(180deg, #d7ebe4 0%, #b7d4ca 100%);
  border: 0;
  display: block;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(31, 45, 42, 0.16);
  transition:
    transform 0.45s var(--ease-snap),
    box-shadow 0.35s ease,
    margin-bottom 0.45s var(--ease-snap);
}

.cat-cell:hover .cat-blob {
  transform: scale(1.06);
  margin-bottom: 16px;
  box-shadow: 0 16px 36px rgba(31, 45, 42, 0.2);
}

.cat-blob img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 0;
  display: block;
}

.cat-cell .lbl {
  display: inline-block;
  padding: 9px 12px;
  border-radius: 11px;
  background: var(--brown);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  transition: transform 0.28s var(--ease-snap), box-shadow 0.28s ease;
}

.cat-cell:hover .lbl {
  transform: translateY(1px);
  box-shadow: 0 6px 14px rgba(31, 143, 105, 0.35);
}

.home-stories {
  padding-top: 12px;
  padding-bottom: 2px;
}

.home-stories__track {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding: 4px 2px 10px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.home-stories__track::-webkit-scrollbar {
  display: none;
}

.story-orb {
  flex: 0 0 auto;
  width: 86px;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  display: grid;
  gap: 8px;
  justify-items: center;
  font: inherit;
  color: inherit;
}

.story-orb__ring {
  display: flex;
  width: 78px;
  height: 78px;
  padding: 3px;
  border-radius: 50%;
  background: conic-gradient(from 200deg, #f9ce34, #ee2a7b 40%, #6228d7 70%, #f9ce34);
}

.story-orb.is-seen .story-orb__ring {
  background: #cfd6d3;
}

.story-orb__photo {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  padding: 2px;
  background: var(--page);
  overflow: hidden;
}

.story-orb__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.story-orb__label {
  max-width: 86px;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.story-viewer {
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: grid;
  place-items: center;
  background: rgba(8, 12, 11, 0.94);
  padding: 12px;
}

.story-viewer[hidden] {
  display: none;
}

.story-viewer__frame {
  position: relative;
  width: min(420px, 100%);
  height: min(90vh, 760px);
  background: #111;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.story-viewer__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.story-viewer__bars {
  position: absolute;
  top: 10px;
  right: 10px;
  left: 10px;
  z-index: 3;
  display: flex;
  gap: 4px;
}

.story-viewer__bar {
  flex: 1;
  height: 3px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.32);
  overflow: hidden;
}

.story-viewer__bar-fill {
  display: block;
  height: 100%;
  width: 0;
  background: #fff;
}

.story-viewer__close {
  position: absolute;
  top: 22px;
  left: 10px;
  z-index: 4;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.story-viewer__name {
  position: absolute;
  top: 24px;
  right: 12px;
  left: 52px;
  z-index: 4;
  margin: 0;
  color: #fff;
  font-weight: 800;
  font-size: 0.92rem;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.story-viewer__cta {
  position: absolute;
  right: 50%;
  bottom: 16px;
  transform: translateX(50%);
  z-index: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: calc(100% - 28px);
  min-height: 52px;
  padding: 13px 18px;
  border-radius: 11px;
  background: var(--brown);
  color: #fff;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-weight: 800;
  font-size: 1.02rem;
  line-height: 1.35;
  text-decoration: none;
  text-align: center;
  box-shadow: 0 10px 24px rgba(31, 143, 105, 0.4);
  overflow: hidden;
  isolation: isolate;
  transition: background 0.25s ease, transform 0.22s var(--ease-snap), box-shadow 0.3s ease;
}

.story-viewer__cta::before {
  content: "";
  position: absolute;
  inset: 0;
  left: -40%;
  width: 55%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.28), transparent);
  transform: skewX(-14deg) translateX(-180%);
  pointer-events: none;
  z-index: -1;
}

.story-viewer__cta:hover {
  background: var(--brown-2);
  color: #fff;
  transform: translateX(50%) translateY(-2px);
  box-shadow: 0 12px 28px rgba(31, 143, 105, 0.45);
}

.story-viewer__cta:hover::before {
  animation: btnShine 0.85s ease forwards;
}

.story-viewer__cta:active {
  transform: translateX(50%) scale(0.98);
}

.story-viewer__cta[hidden] {
  display: none;
}

.story-viewer__nav {
  position: absolute;
  top: 52px;
  bottom: 88px;
  z-index: 2;
  width: 42%;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.story-viewer__nav--prev {
  right: 0;
}

.story-viewer__nav--next {
  left: 0;
}

body.is-story-open {
  overflow: hidden;
}

body.is-story-open .fab {
  display: none;
}

.admin-story-slides {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 14px;
}

.admin-story-slide {
  display: grid;
  gap: 8px;
  width: min(270px, 100%);
  font-size: 0.75rem;
  font-weight: 700;
}

.admin-story-slide .checkout-field {
  gap: 4px;
}

.admin-story-slide .checkout-field input[type="text"] {
  min-height: 38px;
  font-size: 0.78rem;
}

.admin-story-slide img {
  width: 90px;
  height: 160px;
  object-fit: cover;
  border-radius: 10px;
  background: #eee;
}

/* ——— جدیدترین محصولات + تب ——— */
.block-white {
  margin-top: 22px;
  background: var(--white);
  border-radius: 18px;
  padding: 16px 14px 18px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.4s ease, transform 0.4s var(--ease-out);
}

.block-white:hover {
  box-shadow: 0 12px 36px rgba(31, 45, 42, 0.08);
}

.block-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--brown-3);
}

.block-white__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
  min-width: 0;
}

.block-white__head .block-title {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
}

.category-count {
  margin: 0 0 1rem;
  font-size: 0.92rem;
  color: #4a5c57;
}

.category-empty {
  margin: 0 0 1rem;
  color: #4a5c57;
}

.product-sort {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 1 auto;
  min-width: 0;
  max-width: min(100%, 260px);
  margin-inline-end: 14px;
}

.product-sort__label {
  font-size: 12px;
  font-weight: 800;
  color: var(--brown);
  white-space: nowrap;
}

.product-sort__select {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  border: 1px solid rgba(31, 143, 105, 0.22);
  border-radius: 999px;
  background-color: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  padding-block: 8px;
  padding-inline-start: 14px;
  padding-inline-end: 36px;
  cursor: pointer;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--brown) 50%),
    linear-gradient(135deg, var(--brown) 50%, transparent 50%);
  background-position:
    left 11px top calc(50% + 1px),
    left 16px top calc(50% + 1px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.product-sort__select:hover {
  border-color: rgba(31, 143, 105, 0.4);
}

.product-sort__select:focus {
  outline: 0;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 143, 105, 0.16);
}

@media (max-width: 640px) {
  .block-white__head {
    flex-direction: column;
    align-items: stretch;
  }

  .block-white__head .block-title {
    text-align: center;
  }

  .product-sort {
    justify-content: center;
    flex-wrap: wrap;
    max-width: 100%;
    margin-inline-end: 0;
  }

  .product-sort__select {
    max-width: min(100%, 280px);
  }
}

.p-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  overflow: visible;
}

@media (max-width: 1020px) {
  .p-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .p-grid {
    grid-template-columns: 1fr;
  }
}

.p-card {
  position: relative;
  background: #fafafa;
  border-radius: var(--radius);
  overflow: hidden;
  border: 2px solid transparent;
  display: flex;
  flex-direction: column;
  transition-property: transform, box-shadow, border-color;
  transition-duration: 0.55s, 0.45s, 0.35s;
  transition-timing-function: var(--ease-out), ease, ease;
  transform-origin: center center;
}

.p-card:hover {
  z-index: 2;
  transform: translateY(-3px);
  border-color: var(--green);
  box-shadow:
    0 10px 22px rgba(31, 143, 105, 0.14),
    0 4px 12px rgba(0, 0, 0, 0.05),
    0 0 0 1px rgba(31, 143, 105, 0.1);
}

.p-card__tools {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 3;
  display: flex;
  gap: 6px;
}

.p-card__tool-form {
  margin: 0;
}

.p-card__tool {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  line-height: 1;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: background 0.2s, color 0.2s, transform 0.2s;
}

.p-card__tool:hover,
.p-card__tool.is-active {
  background: var(--green);
  color: #fff;
  transform: translateY(-1px);
}

.p-card__media {
  display: block;
}

a.p-card__title {
  color: inherit;
  text-decoration: none;
}

a.p-card__title:hover {
  color: var(--green);
}

.p-card img {
  width: 100% !important;
  height: 100% !important;
  object-fit: fill !important;
  max-height: 1254px !important;
  max-width: 1254px !important;
  background: #eaeaea !important;
}
.p-card__media { max-height: 1254px !important; overflow: hidden !important; max-width: 1254px !important; }

.p-card__body {
  padding: 10px 10px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  align-items: center;
}

.p-card__title {
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

.p-card__code {
  font-size: 11px;
  color: var(--muted);
}

.p-card__cat {
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}

.p-card__price {
  font-size: 13px;
  font-weight: 900;
}

.p-card__price del {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: #888;
}

.p-card__price strong {
  display: block;
  font-size: 14px;
  color: var(--green-light);
}

.p-card--sale .discount-badge {
  top: 10px;
  right: 10px;
}

/* ——— Out of stock / ناموجود ——— */
:root {
  --oos-ink: #2a3a36;
  --oos-muted: #5a6f68;
  --oos-soft: #e7efeb;
  --oos-panel: linear-gradient(145deg, #f4f8f6 0%, #e8f0ec 48%, #dfeae5 100%);
  --oos-line: rgba(42, 58, 54, 0.12);
}

@keyframes oosPulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.45;
  }
  50% {
    transform: scale(1.35);
    opacity: 0;
  }
}

@keyframes oosRise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes oosShimmer {
  0% {
    background-position: 120% 0;
  }
  100% {
    background-position: -40% 0;
  }
}

.p-card__media,
.card-offer__media,
.product-gallery__stage,
.cart-product__thumb {
  position: relative;
}

.oos-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(160deg, rgba(219, 232, 228, 0.15), rgba(42, 58, 54, 0.28)),
    rgba(219, 232, 228, 0.22);
  backdrop-filter: saturate(0.72);
}

.oos-veil--gallery {
  border-radius: inherit;
  background:
    linear-gradient(165deg, rgba(232, 240, 236, 0.2) 0%, rgba(31, 45, 42, 0.34) 100%);
}

.oos-veil--thumb {
  border-radius: 10px;
}

.p-card--oos .p-card__media img,
.card-offer--oos .card-offer__media img,
.product-gallery__stage--oos [data-gallery-main] img,
.cart-product__thumb--oos img {
  filter: grayscale(0.42) contrast(0.96) brightness(0.97);
  transition: filter 0.45s var(--ease-out);
}

.p-card--oos:hover .p-card__media img,
.card-offer--oos:hover .card-offer__media img {
  filter: grayscale(0.28) contrast(1) brightness(1);
}

.oos-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 92px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(26, 44, 40, 0.88);
  color: #f5faf8;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow: 0 10px 28px rgba(26, 44, 40, 0.28);
  pointer-events: none;
  animation: oosRise 0.55s var(--ease-out) both;
}

.oos-badge--lg {
  min-width: 120px;
  padding: 12px 22px;
  font-size: 14px;
}

.oos-badge__pulse {
  position: absolute;
  inset: -4px;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.35);
  animation: oosPulse 2.4s var(--ease-out) infinite;
}

/* روبان گوشه‌ای ناموجود روی کارت محصول */
.oos-ribbon {
  position: absolute;
  top: 14px;
  right: -34px;
  z-index: 4;
  width: 130px;
  padding: 7px 0;
  text-align: center;
  background: linear-gradient(180deg, #243832 0%, #1a2c28 100%);
  color: #f7fbf9;
  box-shadow: 0 8px 18px rgba(26, 44, 40, 0.28);
  transform: rotate(45deg);
  pointer-events: none;
  overflow: hidden;
}

.oos-ribbon::before,
.oos-ribbon::after {
  content: "";
  position: absolute;
  bottom: -6px;
  width: 8px;
  height: 6px;
  background: #101916;
}

.oos-ribbon::before {
  left: 0;
  clip-path: polygon(0 0, 100% 0, 100% 100%);
}

.oos-ribbon::after {
  right: 0;
  clip-path: polygon(0 0, 100% 0, 0 100%);
}

.oos-ribbon__text {
  display: block;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

.p-card--oos {
  overflow: hidden;
}

.oos-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  margin-top: auto;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px dashed rgba(42, 58, 54, 0.22);
  background:
    linear-gradient(110deg, rgba(255, 255, 255, 0.55) 25%, rgba(232, 240, 236, 0.95) 45%, rgba(255, 255, 255, 0.55) 65%),
    var(--oos-soft);
  background-size: 220% 100%, auto;
  color: var(--oos-ink);
  text-decoration: none;
  transition: border-color 0.25s ease, transform 0.25s var(--ease-out), background-position 0.8s ease;
}

.oos-cta span {
  font-size: 12px;
  font-weight: 800;
}

.oos-cta small {
  font-size: 10px;
  color: var(--oos-muted);
  font-weight: 600;
}

.oos-cta:hover {
  border-color: rgba(31, 143, 105, 0.35);
  transform: translateY(-1px);
  background-position: 0% 0, center;
  animation: oosShimmer 1.1s linear;
}

.p-card--oos {
  border-color: rgba(42, 58, 54, 0.1);
}

.p-card--oos:hover {
  border-color: rgba(42, 58, 54, 0.18);
  box-shadow: 0 10px 22px rgba(42, 58, 54, 0.1);
}

.card-offer--oos {
  overflow: hidden;
  position: relative;
}

.oos-ribbon--offer {
  top: 12px;
  right: -36px;
  z-index: 5;
}

.oos-panel {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px 16px;
  align-items: start;
  margin: 4px 0 18px;
  padding: 18px 18px 18px 16px;
  border-radius: 18px;
  border: 1px solid var(--oos-line);
  background: var(--oos-panel);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  animation: oosRise 0.6s var(--ease-out) both;
}

.oos-panel--soft {
  background: linear-gradient(145deg, #f7faf8, #eef5f1);
}

.oos-panel__glow {
  position: absolute;
  width: 160px;
  height: 160px;
  top: -60px;
  left: -40px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(31, 143, 105, 0.16), transparent 68%);
  pointer-events: none;
}

.oos-panel__icon {
  position: relative;
  z-index: 1;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--oos-ink);
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
}

.oos-panel__copy {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.oos-panel__eyebrow {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--green);
  text-transform: none;
}

.oos-panel__title {
  margin: 0 0 6px;
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--oos-ink);
  line-height: 1.35;
}

.oos-panel__text {
  margin: 0;
  font-size: 0.9rem;
  color: var(--oos-muted);
  line-height: 1.65;
}

.oos-panel__link {
  display: inline-flex;
  margin-top: 10px;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--green);
  text-decoration: none;
  border-bottom: 1px solid rgba(31, 143, 105, 0.35);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.oos-panel__link:hover {
  color: var(--brown-2);
  border-color: var(--brown-2);
}

.product-stock {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--green);
  background: rgba(31, 143, 105, 0.1);
  border: 1px solid rgba(31, 143, 105, 0.16);
}

.product-stock__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green-light);
  box-shadow: 0 0 0 4px rgba(42, 165, 123, 0.18);
}

.product-variations--muted {
  opacity: 0.72;
  margin-bottom: 8px;
}

.product-color-option.is-disabled {
  opacity: 0.55;
  pointer-events: none;
}

.oos-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #f4faf7;
  background: #1a2c28;
  max-width: 100%;
}

.oos-chip--sticky {
  margin: 0;
  padding: 10px 16px;
  font-size: 0.88rem;
  white-space: nowrap;
}

.oos-banner {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin: 0 0 18px;
  padding: 16px 18px;
  border-radius: 16px;
  border: 1px solid rgba(42, 58, 54, 0.14);
  background: var(--oos-panel);
  animation: oosRise 0.5s var(--ease-out) both;
}

.oos-banner__icon {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--oos-ink);
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.85);
}

.oos-banner__copy {
  min-width: 0;
}

.oos-banner__copy strong {
  display: block;
  margin-bottom: 4px;
  color: var(--oos-ink);
  font-size: 0.98rem;
}

.oos-banner__copy p {
  margin: 0;
  color: var(--oos-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

.cart-table__row--oos {
  background: linear-gradient(90deg, rgba(231, 239, 235, 0.65), transparent 70%);
}

.cart-product__thumb--oos {
  overflow: hidden;
  border-radius: 10px;
}

.cart-product__stock {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.85rem;
}

.btn-brown--disabled,
.btn-brown[disabled],
.product-purchase__submit[disabled],
.product-sticky__submit[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

@media (max-width: 640px) {
  .oos-panel {
    grid-template-columns: 1fr;
    padding: 16px;
  }

  .oos-panel__icon {
    width: 46px;
    height: 46px;
  }

  .oos-banner {
    padding: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .oos-badge,
  .oos-panel,
  .oos-banner,
  .oos-badge__pulse {
    animation: none;
  }
}

.discount-badge--inline {
  position: static;
  display: inline-flex;
  width: auto;
  min-width: 44px;
  height: auto;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 11px;
  margin-left: 6px;
  vertical-align: middle;
}

.product-layout__price--sale {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}

.product-layout__price--sale del {
  font-size: 14px;
  color: #888;
  font-weight: 600;
}

.product-layout__price--sale strong {
  font-size: 20px;
  font-weight: 900;
  color: var(--green-light);
}

/* ——— فوتر تیره ——— */
.footer {
  margin-top: 36px;
  background: var(--footer-dark);
  color: #e8e8e8;
  padding: 36px 0 0;
}

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

@media (max-width: 980px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-card {
  background: var(--footer-card);
  border-radius: 16px;
  padding: 22px 22px 20px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.footer-card .footer-logo {
  display: flex;
  justify-content: center;
  margin: 0 auto 14px;
  text-align: center;
}

.footer-logo:hover,
.footer-logo:focus {
  text-decoration: none;
}

.footer-logo:hover .footer-logo__mark,
.footer-logo:focus .footer-logo__mark {
  transform: none;
  box-shadow: none;
}

.footer-logo:hover .footer-logo__img,
.footer-logo:focus .footer-logo__img {
  transform: none;
}

.footer-card .footer-logo__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.footer-card .footer-logo__img {
  display: block;
  height: 42px;
  width: auto;
  max-width: min(220px, 85vw);
  margin: 0 auto;
  object-fit: contain;
}

.footer-card p {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.85;
  color: #cfcfcf;
}

.footer-card ul {
  margin: 0 0 16px;
  padding: 0 18px 0 0;
  font-size: 13px;
  color: #c8c8c8;
  list-style: disc;
}

.footer-card li {
  margin: 6px 0;
}

.footer-phone-row {
  line-height: 1.75;
}

.footer-address {
  line-height: 1.75;
}

.footer-address__label {
  font-weight: inherit;
}

.footer-address__row {
  display: block;
  line-height: 1.85;
}

.footer-address__label {
  font-weight: inherit;
  margin-inline-end: 0.25em;
}

.footer-map-btn {
  display: inline-flex;
  vertical-align: middle;
  margin-inline-start: 0.45em;
  white-space: nowrap;
}

.footer-store-map {
  margin-top: 12px;
  max-width: 560px;
}

.footer-store-map[hidden] {
  display: none !important;
}

.footer-store-map__frame {
  border-color: rgba(255, 255, 255, 0.18);
}

.footer-store-map__frame iframe,
.footer-store-map__canvas,
.contact-map__canvas {
  height: 260px;
  background: rgba(0, 0, 0, 0.15);
  width: 100%;
  border: 0;
  border-radius: inherit;
}

.contact-map__canvas {
  background: #eef2f0;
}

.footer-store-map__link a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-phone-row .footer-actions {
  display: inline-flex;
  vertical-align: middle;
  margin-top: 0;
  gap: 8px;
}

.footer-badges {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
  max-width: 320px;
  align-items: stretch;
}

.footer-badges .badge-box,
.footer-badges .enamad-badge {
  width: 100%;
  height: 100%;
  min-height: 168px;
  margin: 0;
  padding: 8px;
  border-radius: 12px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  text-decoration: none;
  transition: transform 0.32s var(--ease-out), box-shadow 0.3s ease;
}

.footer-badges .badge-box:hover,
.footer-badges .enamad-badge:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.footer-badges .badge-box__qr,
.footer-badges .enamad-badge img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: 152px;
  object-fit: contain;
}

.footer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: transparent;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1.4;
  color: #fff;
  cursor: pointer;
  text-decoration: none;
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.06);
}

.footer-aside {
  display: grid;
  gap: 12px;
}

.wholesale-list {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 14px;
  padding: 14px 14px 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.wholesale-list h3 {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 900;
}

.wholesale-list a {
  display: block;
  padding: 8px 0;
  font-size: 13px;
  color: #c9c9c9;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: color 0.22s ease, transform 0.28s var(--ease-out), padding 0.28s var(--ease-out);
}

.wholesale-list a:last-child {
  border-bottom: 0;
}

.wholesale-list a:hover {
  color: #fff;
  transform: translateX(4px);
  padding-inline-end: 6px;
}

.badges {
  display: grid;
  gap: 10px;
}

.badge-box {
  background: #fff;
  border-radius: 12px;
  padding: 12px;
  text-align: center;
  color: var(--ink);
  font-weight: 800;
  font-size: 12px;
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.32s var(--ease-out), box-shadow 0.3s ease;
  text-decoration: none;
}

.badge-box--instagram {
  padding: 8px;
  min-height: 0;
}

.badge-box__qr {
  display: block;
  width: 100%;
  max-width: 148px;
  height: auto;
}

.badge-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.enamad-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
  text-decoration: none;
}

.enamad-badge img {
  display: block;
  width: 100%;
  max-width: 125px;
  height: auto;
}

.footer-bar {
  margin-top: 28px;
  padding: 14px 0 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 12px;
  color: #9a9a9a;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  justify-content: space-between;
  align-items: center;
}

.footer-bar a {
  color: #bdbdbd;
  font-weight: 700;
  transition: color 0.22s ease, transform 0.22s ease;
}

.footer-bar a:hover {
  color: #fff;
  transform: translateY(-1px);
}

/* FAB */
.fab {
  position: fixed;
  bottom: 22px;
  right: 22px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 0;
  background: var(--chat);
  color: #fff;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(255, 122, 26, 0.45);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s var(--ease-snap), box-shadow 0.35s ease;
}

.fab:hover {
  animation-play-state: paused;
  transform: scale(1.08);
  box-shadow: 0 16px 40px rgba(255, 122, 26, 0.55);
  color: #fff;
}

.fab svg {
  position: absolute;
  transition: transform 0.35s var(--ease-out), opacity 0.2s ease;
}

.fab:hover svg {
  transform: rotate(-8deg) scale(1.05);
}

.fab.is-open,
.fab.is-open:hover {
  animation: none;
  transform: none;
}

.fab.is-open svg {
  opacity: 0;
  transform: scale(0.4);
}

.fab.is-open::after {
  content: "×";
  position: absolute;
  font-size: 28px;
  line-height: 1;
  font-weight: 400;
}

.fab__badge {
  position: absolute;
  top: -4px;
  left: -4px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: #1f2d2a;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 2px #fff;
}

.page-support .fab {
  display: none;
}

.support-dock {
  position: fixed;
  right: 22px;
  bottom: 90px;
  z-index: 1990;
  width: min(380px, calc(100vw - 28px));
}

.support-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  max-height: min(72vh, 560px);
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: 0 22px 50px rgba(31, 45, 42, 0.18);
}

.support-panel__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 12px;
  background: linear-gradient(180deg, rgba(255, 122, 53, 0.12), transparent);
  border-bottom: 1px solid var(--line);
}

.support-panel__head strong {
  display: block;
  font-size: 1rem;
}

.support-panel__head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.support-panel__close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(31, 45, 42, 0.06);
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.support-panel__body {
  overflow: auto;
  padding: 14px 16px 16px;
  display: grid;
  gap: 12px;
  align-content: start;
}

.support-panel__guest {
  margin: 8px 0 4px;
  color: var(--muted);
}

.support-panel__login {
  justify-self: stretch;
  width: 100%;
}

.support-form .btn-brown,
.support-reply .btn-brown {
  width: 100%;
  margin-top: 4px;
}

.support-panel__error {
  margin: 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(194, 65, 12, 0.08);
  color: #9a3412;
  font-size: 0.85rem;
}

.support-panel__note {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.support-form,
.support-reply {
  display: grid;
  gap: 8px;
}

.support-form label,
.support-reply label {
  display: grid;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--muted);
}

.support-form input,
.support-form textarea,
.support-reply textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
  color: var(--ink);
  resize: vertical;
}

.support-form input:focus,
.support-form textarea:focus,
.support-reply textarea:focus {
  outline: 2px solid rgba(255, 122, 53, 0.35);
  border-color: var(--orange);
}

.support-list {
  display: grid;
  gap: 8px;
}

.support-list button {
  display: grid;
  gap: 4px;
  text-align: right;
  width: 100%;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

.support-list button:hover,
.support-list button.is-unread {
  border-color: rgba(255, 122, 53, 0.4);
  background: rgba(255, 122, 53, 0.06);
}

.support-list strong {
  font-size: 0.92rem;
}

.support-list span {
  color: var(--muted);
  font-size: 0.78rem;
}

.support-thread__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.support-thread__back {
  border: 0;
  background: transparent;
  color: var(--green);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  padding: 0;
}

.support-thread h3 {
  margin: 0;
  font-size: 0.98rem;
}

.support-thread__status {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.support-msgs {
  display: grid;
  gap: 8px;
  max-height: 240px;
  overflow: auto;
  padding: 4px 2px;
}

.support-msg,
.account-ticket__msg {
  display: grid;
  gap: 4px;
  max-width: 92%;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(31, 45, 42, 0.05);
}

.support-msg strong,
.account-ticket__msg strong {
  font-size: 0.8rem;
}

.support-msg small,
.account-ticket__msg small {
  color: var(--muted);
  font-size: 0.72rem;
}

.support-msg span,
.account-ticket__msg span {
  white-space: pre-wrap;
  word-break: break-word;
}

.support-msg--user,
.account-ticket__msg--user {
  margin-inline-start: auto;
  background: rgba(255, 122, 53, 0.14);
}

.support-msg--staff,
.account-ticket__msg--staff {
  margin-inline-end: auto;
  background: rgba(31, 143, 105, 0.12);
}

.support-panel__account {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--green);
}

@media (max-width: 640px) {
  .support-dock {
    right: 10px;
    left: 10px;
    bottom: 86px;
    width: auto;
  }

  .support-panel {
    max-height: min(78vh, 620px);
  }
}

/* ——— موشن: ورود با اسکرول، تب، مگامنو ——— */
@keyframes fabBob {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-7px);
  }
}

@keyframes megaLinkPop {
  from {
    transform: translateY(12px);
  }

  to {
    transform: translateY(0);
  }
}

@keyframes headEnter {
  from {
    opacity: 0;
    transform: translateY(-12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes ruleGrow {
  from {
    transform: scaleX(0.15);
    opacity: 0.35;
  }

  to {
    transform: scaleX(1);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: no-preference) {
  html.motion .site-head {
    animation: headEnter 0.55s var(--ease-out) both;
  }

  html.motion .fab:not(.is-open) {
    animation: fabBob 3s ease-in-out infinite;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link {
    animation: megaLinkPop 0.4s var(--ease-out) backwards;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(1) {
    animation-delay: 0.02s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(2) {
    animation-delay: 0.05s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(3) {
    animation-delay: 0.08s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(4) {
    animation-delay: 0.11s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(5) {
    animation-delay: 0.14s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(6) {
    animation-delay: 0.17s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(7) {
    animation-delay: 0.2s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(8) {
    animation-delay: 0.23s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(9) {
    animation-delay: 0.26s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(10) {
    animation-delay: 0.29s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(11) {
    animation-delay: 0.32s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(12) {
    animation-delay: 0.35s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link:nth-child(n + 13) {
    animation-delay: 0.38s;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-head {
    animation: megaLinkPop 0.38s var(--ease-out) both;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-cat {
    animation: megaLinkPop 0.42s var(--ease-out) 0.06s both;
  }

  @keyframes cardPop {
    from {
      transform: translateY(22px) scale(0.97);
    }

    to {
      transform: translateY(0) scale(1);
    }
  }

  @keyframes heroFrameIn {
    from {
      transform: scale(0.985);
    }

    to {
      transform: scale(1);
    }
  }

  @keyframes badgeEntrance {
    0% {
      transform: scale(0.88) rotate(-12deg);
    }

    70% {
      transform: scale(1.08) rotate(4deg);
    }

    100% {
      transform: scale(1) rotate(0deg);
    }
  }

  @keyframes btnShine {
    to {
      transform: skewX(-14deg) translateX(420%);
    }
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-view {
    animation: heroFrameIn 0.72s var(--ease-out) backwards;
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-slide .hero-card {
    animation: cardPop 0.56s var(--ease-out) backwards;
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-slide .hero-card:nth-child(1) {
    animation-delay: 0.14s;
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-slide .hero-card:nth-child(2) {
    animation-delay: 0.26s;
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-slide .hero-card:nth-child(3) {
    animation-delay: 0.38s;
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-slide .hero-card:nth-child(4) {
    animation-delay: 0.5s;
  }

  html.motion.reveal-js .reveal.is-visible .discount-badge {
    animation: badgeEntrance 0.72s var(--ease-snap) 0.12s both;
  }

  html.motion.reveal-js .reveal.is-visible .block-title {
    animation: megaLinkPop 0.58s var(--ease-out) 0.06s both;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer {
    animation: cardPop 0.52s var(--ease-out) backwards;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:nth-child(1) {
    animation-delay: 0.05s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:nth-child(2) {
    animation-delay: 0.1s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:nth-child(3) {
    animation-delay: 0.15s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:nth-child(4) {
    animation-delay: 0.2s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:nth-child(5) {
    animation-delay: 0.25s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:nth-child(6) {
    animation-delay: 0.3s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell {
    animation: cardPop 0.48s var(--ease-out) backwards;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(1) {
    animation-delay: 0.02s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(2) {
    animation-delay: 0.05s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(3) {
    animation-delay: 0.08s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(4) {
    animation-delay: 0.11s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(5) {
    animation-delay: 0.14s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(6) {
    animation-delay: 0.17s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(7) {
    animation-delay: 0.2s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(8) {
    animation-delay: 0.23s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(9) {
    animation-delay: 0.26s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(10) {
    animation-delay: 0.29s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(11) {
    animation-delay: 0.32s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(12) {
    animation-delay: 0.35s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(13) {
    animation-delay: 0.38s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(14) {
    animation-delay: 0.41s;
  }

  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell:nth-child(15) {
    animation-delay: 0.44s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card {
    animation: cardPop 0.5s var(--ease-out) backwards;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(1) {
    animation-delay: 0.04s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(2) {
    animation-delay: 0.08s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(3) {
    animation-delay: 0.12s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(4) {
    animation-delay: 0.16s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(5) {
    animation-delay: 0.2s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(6) {
    animation-delay: 0.24s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(7) {
    animation-delay: 0.28s;
  }

  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:nth-child(8) {
    animation-delay: 0.32s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .footer-card {
    animation: cardPop 0.55s var(--ease-out) 0.08s backwards;
  }

  html.motion.reveal-js .footer.reveal.is-visible .footer-aside {
    animation: cardPop 0.55s var(--ease-out) 0.16s backwards;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a {
    animation: megaLinkPop 0.38s var(--ease-out) backwards;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(1) {
    animation-delay: 0.22s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(2) {
    animation-delay: 0.28s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(3) {
    animation-delay: 0.34s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(4) {
    animation-delay: 0.4s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(5) {
    animation-delay: 0.46s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(6) {
    animation-delay: 0.52s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(7) {
    animation-delay: 0.58s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(8) {
    animation-delay: 0.64s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(9) {
    animation-delay: 0.7s;
  }

  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a:nth-of-type(10) {
    animation-delay: 0.76s;
  }

  @keyframes floatSoft {
    0%,
    100% {
      transform: translateY(0);
    }

    50% {
      transform: translateY(-6px);
    }
  }

  html.motion.reveal-js .footer.reveal.is-visible .badge-box,
  html.motion.reveal-js .footer.reveal.is-visible .enamad-badge {
    animation: floatSoft 0.85s ease-in-out 0.35s 1 both;
  }

  html.motion.reveal-js .footer.reveal.is-visible .badge-box:nth-child(2),
  html.motion.reveal-js .footer.reveal.is-visible .enamad-badge:nth-child(2) {
    animation-delay: 0.5s;
  }
}

html.motion:not(.reveal-js) .reveal {
  opacity: 1;
  transform: none;
}

html:not(.motion) .reveal {
  opacity: 1;
  transform: none;
}

html.motion.reveal-js .reveal:not(.is-visible) {
  opacity: 0;
  transform: translateY(42px);
  transition:
    opacity 0.88s var(--ease-out),
    transform 0.88s var(--ease-out);
}

html.motion.reveal-js .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.88s var(--ease-out),
    transform 0.88s var(--ease-out);
}

@media (prefers-reduced-motion: no-preference) {
  html.motion.reveal-js .reveal.is-visible .sec-head .rule {
    animation: ruleGrow 0.75s var(--ease-out) 0.12s both;
    transform-origin: center;
  }

  html.motion.reveal-js .reveal.is-visible .sec-head h2 {
    animation: megaLinkPop 0.55s var(--ease-out) 0.05s both;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.motion.reveal-js .reveal,
  html.motion.reveal-js .reveal.is-visible {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
    animation: none !important;
  }

  html.motion .site-head {
    animation: none !important;
  }

  html.motion .fab {
    animation: none !important;
  }

  .nav-mega-panel:not([hidden]) .nav-mega-link {
    animation: none !important;
  }

  html.motion.reveal-js .reveal.is-visible .sec-head .rule,
  html.motion.reveal-js .reveal.is-visible .sec-head h2 {
    animation: none !important;
  }

  .hero-track {
    transition: none !important;
  }

  html.motion.reveal-js .hero.reveal.is-visible .hero-view,
  html.motion.reveal-js .reveal.is-visible .discount-badge,
  html.motion.reveal-js .reveal.is-visible .block-title,
  html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer,
  html.motion.reveal-js .reveal.is-visible .grid-cats > .cat-cell,
  html.motion.reveal-js .reveal.is-visible .p-grid > .p-card,
  html.motion.reveal-js .footer.reveal.is-visible .footer-card,
  html.motion.reveal-js .footer.reveal.is-visible .footer-aside,
  html.motion.reveal-js .footer.reveal.is-visible .wholesale-list a,
  html.motion.reveal-js .hero.reveal.is-visible .hero-slide .hero-card,
  .nav-mega-panel:not([hidden]) .nav-mega-head,
  .nav-mega-panel:not([hidden]) .nav-mega-cat {
    animation: none !important;
  }

  html.motion body::before,
  html.motion .bar-top::after,
  html.motion .hero-dot.is-active {
    animation: none !important;
  }

  html.motion .nav-main > .nav-main__inner > ul > li {
    animation: none !important;
  }

  .btn-brown:hover::before {
    animation: none !important;
  }

  html.motion.reveal-js .footer.reveal.is-visible .badge-box,
  html.motion.reveal-js .footer.reveal.is-visible .enamad-badge {
    animation: none !important;
  }
}

/* هاور یکسان — کارت محصول (پیشنهاد / گرید محصولات) */
.card-offer:hover,
.p-card:hover,
html.motion.reveal-js .reveal.is-visible .grid-4 > .card-offer:hover,
html.motion.reveal-js .reveal.is-visible .p-grid > .p-card:hover {
  opacity: 1;
  z-index: 2;
  transform: translateY(-3px) !important;
  transition-property: transform, box-shadow, border-color !important;
  transition-duration: 0.55s, 0.45s, 0.35s !important;
  transition-timing-function: var(--ease-out), ease, ease !important;
}

.visually-hidden,
.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ——— صفحه سبد خرید ——— */
.cart-page {
  padding: 20px 0 52px;
}

.cart-page.block-white,
.cart-page .block-white {
  margin-top: 0;
}

.cart-page__hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.cart-page__intro {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cart-page__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.65));
  color: var(--green);
  box-shadow: 0 8px 22px rgba(31, 45, 42, 0.1);
  transition: transform 0.35s var(--ease-snap), box-shadow 0.35s ease;
}

.cart-page.reveal.is-visible .cart-page__icon {
  animation: cartIconPop 0.55s var(--ease-out) 0.1s backwards;
}

.cart-page__title {
  margin: 0;
  font-size: clamp(1.2rem, 2.5vw, 1.45rem);
  font-weight: 900;
  color: var(--brown-3);
}

.cart-page__meta {
  margin: 4px 0 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}

.cart-page__toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cart-clear-form {
  margin: 0;
}

.btn-cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 12px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.2;
  cursor: pointer;
  text-decoration: none;
  border: 1px solid transparent;
  transition:
    transform 0.28s var(--ease-snap),
    box-shadow 0.3s ease,
    background 0.25s ease,
    border-color 0.25s ease,
    color 0.2s ease;
}

.btn-cart__icon {
  display: inline-flex;
  font-size: 16px;
  line-height: 1;
  transition: transform 0.3s var(--ease-out);
}

.btn-cart--back {
  background: rgba(255, 255, 255, 0.92);
  color: var(--brown-3);
  border-color: rgba(31, 143, 105, 0.28);
  box-shadow: 0 4px 14px rgba(31, 45, 42, 0.08);
}

.btn-cart--back:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(31, 143, 105, 0.18);
  border-color: rgba(31, 143, 105, 0.45);
  color: var(--green);
}

.btn-cart--back:hover .btn-cart__icon {
  transform: translateX(4px);
}

.btn-cart--danger {
  background: rgba(255, 255, 255, 0.88);
  color: #b53a3a;
  border-color: rgba(181, 58, 58, 0.35);
  box-shadow: 0 4px 14px rgba(120, 30, 30, 0.08);
}

.btn-cart--danger:hover {
  transform: translateY(-2px);
  background: #fff5f5;
  border-color: rgba(181, 58, 58, 0.55);
  box-shadow: 0 10px 22px rgba(181, 58, 58, 0.16);
  color: #922e2e;
}

.btn-cart--danger:hover .btn-cart__icon--trash {
  transform: scale(1.08) rotate(-6deg);
}

.btn-cart:active {
  transform: translateY(0) scale(0.98);
}

.cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 320px);
  gap: 20px;
  align-items: stretch;
}

.cart-panel {
  margin-top: 0;
  padding: 18px 16px 20px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 14px 40px rgba(31, 45, 42, 0.1);
  height: 100%;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.cart-panel--items .cart-form {
  margin: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.cart-panel--items .cart-table-wrap {
  flex: 1;
}

.cart-panel--summary {
  background: linear-gradient(180deg, #fff 0%, #f8fcfa 100%);
  border-top: 4px solid var(--green-light);
}

.cart-panel--summary .cart-summary__rows {
  flex: 1;
}

.cart-panel--summary .cart-summary__checkout {
  margin-top: auto;
}

.cart-panel--summary .cart-summary__note {
  margin-top: 10px;
}

.cart-empty {
  text-align: center;
  padding: 48px 24px 40px;
  max-width: 420px;
  margin: 0 auto;
}

.cart-empty__illus {
  font-size: 3rem;
  margin-bottom: 12px;
  opacity: 0.85;
  animation: cartEmptyBob 2.4s ease-in-out infinite;
}

.cart-empty__text {
  margin: 0 0 8px;
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--brown-3);
}

.cart-empty__hint {
  margin: 0 0 22px;
  font-size: 13px;
  color: var(--muted);
}

.cart-empty__cta {
  display: inline-block;
  width: auto;
  min-width: 200px;
  margin-top: 0;
}

.cart-table-wrap {
  overflow-x: auto;
  margin: 0 -4px;
  padding: 0 4px;
}

.cart-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px;
  font-size: 13px;
}

.cart-table thead th {
  padding: 10px 12px;
  font-weight: 900;
  font-size: 12px;
  color: var(--muted);
  text-align: right;
  border: 0;
  background: transparent;
}

.cart-table__row {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(31, 45, 42, 0.05);
  transition:
    transform 0.32s var(--ease-out),
    box-shadow 0.32s ease,
    background 0.25s ease;
}

.cart-page.reveal.is-visible .cart-table__row {
  animation: cartRowIn 0.5s var(--ease-out) backwards;
  animation-delay: calc(0.06s * var(--cart-row-i, 0) + 0.12s);
}

.cart-table__row:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(31, 143, 105, 0.12);
  background: #fff;
}

.cart-table__row td {
  padding: 14px 12px;
  border: 0;
  text-align: right;
  vertical-align: middle;
}

.cart-table__row td:first-child {
  border-radius: 0 14px 14px 0;
}

.cart-table__row td:last-child {
  border-radius: 14px 0 0 14px;
}

.cart-product {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cart-product__thumb {
  display: block;
  flex-shrink: 0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
  transition: transform 0.35s var(--ease-out);
}

.cart-table__row:hover .cart-product__thumb {
  transform: scale(1.04);
}

.cart-product__thumb img {
  display: block;
  width: 76px;
  height: 76px;
  object-fit: cover;
}

.cart-product strong {
  display: block;
  font-size: 13px;
  margin-bottom: 4px;
  line-height: 1.45;
}

.cart-product__code {
  display: block;
  font-size: 11px;
  color: var(--muted);
}

.cart-table__price {
  font-weight: 800;
  color: var(--brown-3);
  white-space: nowrap;
}

.cart-qty {
  display: inline-flex;
  align-items: center;
  gap: 0;
  background: #f4faf7;
  border: 1px solid rgba(31, 143, 105, 0.2);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.cart-qty:focus-within {
  border-color: rgba(31, 143, 105, 0.45);
  box-shadow: 0 0 0 3px rgba(42, 165, 123, 0.15);
}

.cart-qty__btn {
  width: 36px;
  height: 38px;
  border: 0;
  background: rgba(31, 143, 105, 0.1);
  color: var(--green);
  font-size: 18px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.22s var(--ease-snap), color 0.2s ease;
}

.cart-qty__btn:hover {
  background: rgba(31, 143, 105, 0.22);
  color: var(--brown-3);
}

.cart-qty__btn:active {
  transform: scale(0.92);
}

.cart-qty-input {
  width: 44px;
  padding: 8px 4px;
  border: 0;
  background: transparent;
  font-family: inherit;
  font-weight: 900;
  font-size: 14px;
  text-align: center;
  color: var(--ink);
  appearance: textfield;
  -moz-appearance: textfield;
}

.cart-qty-input::-webkit-outer-spin-button,
.cart-qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.cart-table__subtotal {
  font-weight: 900;
  color: var(--green-light);
  white-space: nowrap;
  transition: color 0.2s ease, transform 0.25s var(--ease-snap);
}

.cart-table__subtotal.is-pulse,
[data-cart-total].is-pulse {
  animation: cartPricePulse 0.45s var(--ease-out);
}

.cart-remove-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: rgba(181, 58, 58, 0.1);
  color: #b53a3a;
  text-decoration: none;
  transition:
    transform 0.28s var(--ease-snap),
    background 0.22s ease,
    color 0.2s ease,
    box-shadow 0.25s ease;
}

.cart-remove-btn:hover {
  background: #ffe8e8;
  color: #922e2e;
  transform: scale(1.06);
  box-shadow: 0 6px 16px rgba(181, 58, 58, 0.2);
}

.cart-remove-btn.is-removing {
  animation: cartRemoveOut 0.35s var(--ease-out) forwards;
}

.cart-summary__title {
  margin: 0 0 16px;
  font-size: 1.05rem;
  font-weight: 900;
  padding-bottom: 12px;
  border-bottom: 1px dashed rgba(31, 143, 105, 0.25);
}

.cart-summary__rows {
  margin: 0 0 20px;
}

.cart-summary__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.cart-summary__row dt,
.cart-summary__row dd {
  margin: 0;
  font-size: 13px;
  transition: transform 0.25s var(--ease-snap);
}

.cart-summary__row--total {
  padding-top: 14px;
  margin-top: 4px;
  border-bottom: 0;
  background: rgba(42, 165, 123, 0.08);
  margin-inline: -10px;
  padding-inline: 10px;
  border-radius: 12px;
}

.cart-summary__row--total dd {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--green-light);
}

.cart-summary__checkout {
  display: block;
  width: 100%;
  text-align: center;
  margin: 0;
}

.cart-summary__note {
  margin: 0;
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  line-height: 1.5;
}

@keyframes cartIconPop {
  from {
    opacity: 0;
    transform: scale(0.7) rotate(-8deg);
  }
  to {
    opacity: 1;
    transform: scale(1) rotate(0);
  }
}

@keyframes cartRowIn {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cartPricePulse {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.06);
    color: var(--green);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes cartEmptyBob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

@keyframes cartRemoveOut {
  to {
    opacity: 0;
    transform: translateX(12px) scale(0.96);
  }
}

@media (max-width: 900px) {
  .cart-layout {
    grid-template-columns: 1fr;
  }

  .cart-panel--summary {
    position: static;
  }

  .cart-page__toolbar {
    width: 100%;
    justify-content: stretch;
  }

  .btn-cart {
    flex: 1 1 auto;
    min-width: 140px;
  }
}

@media (max-width: 640px) {
  .cart-page__hero {
    flex-direction: column;
  }

  .cart-page__toolbar {
    flex-direction: column;
  }

  .btn-cart {
    width: 100%;
  }

  .cart-table thead {
    display: none;
  }

  .cart-table {
    border-spacing: 0 12px;
  }

  .cart-table__row {
    display: block;
    padding: 4px 0;
  }

  .cart-table__row td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    border-radius: 0;
  }

  .cart-table__row td:first-child,
  .cart-table__row td:last-child {
    border-radius: 0;
  }

  .cart-table__row td:first-child {
    padding-top: 14px;
    border-radius: 14px 14px 0 0;
  }

  .cart-table__row td:last-child {
    padding-bottom: 14px;
    border-radius: 0 0 14px 14px;
    justify-content: center;
  }

  .cart-table td::before {
    content: attr(data-label);
    font-weight: 800;
    font-size: 11px;
    color: var(--muted);
    flex-shrink: 0;
  }

  .cart-table__product {
    display: block;
  }

  .cart-table__product::before {
    content: none;
  }

  .cart-table__remove::before {
    content: none;
  }
}

/* ——— صفحه محصول ——— */
.product-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.55);
}

.product-breadcrumb a {
  color: var(--green-light);
  font-weight: 700;
}

.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: 28px;
  padding: 24px;
  margin-bottom: 20px;
  align-items: stretch;
  min-width: 0;
  overflow: hidden;
}

.product-layout__summary {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  min-width: 0;
  max-width: 100%;
}

.product-layout__desc {
  flex: 1;
  margin: 0 0 16px;
  font-size: 14px;
}

.product-layout__specs {
  margin: 0 0 16px;
}

.product-layout__specs-title {
  font-size: 15px;
  font-weight: 700;
  margin: 0 0 10px;
  color: rgba(0, 0, 0, 0.8);
}

.product-attrs-table--inline li {
  padding: 8px 0;
}

.product-attrs-table--inline .product-attrs-table__label {
  font-weight: 600;
  color: rgba(0, 0, 0, 0.5);
  font-size: 13px;
}

.product-attrs-table--inline .product-attrs-table__value {
  font-size: 13px;
}

.product-layout__gallery img {
  width: 100% !important;
  height: 100% !important;
  object-fit: fill !important;
  max-height: 520px !important;
  border-radius: 16px !important;
  background: #f6f8f7 !important;
}

.product-layout__title {
  margin: 0 0 10px;
  font-size: clamp(1.25rem, 2.5vw, 1.65rem);
  line-height: 1.45;
}

.product-layout__excerpt {
  margin: 0 0 14px;
  color: rgba(0, 0, 0, 0.68);
  line-height: 1.75;
}

.product-layout__sku {
  margin: 0 0 8px;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.55);
}

.product-layout__sku strong {
  color: var(--ink);
}

.product-layout__sku strong[data-product-code] {
  display: inline-block;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.product-layout__price {
  margin: 0 0 14px;
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--green-light);
}

.product-attrs-preview__title {
  margin: 0 0 8px;
  font-size: 15px;
}

.product-attrs-preview__list {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
}

.product-attrs-preview__list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(0, 0, 0, 0.08);
  font-size: 13px;
}

.product-layout__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product-layout__add {
  flex: 1 1 220px;
}

.product-tabs {
  padding: 0 24px 24px;
}

.product-page-digi-tabs .tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border-bottom: 2px solid rgba(0, 0, 0, 0.08);
  margin-bottom: 18px;
  padding-bottom: 4px;
}

.product-page-digi-tabs .tab-title {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 12px 18px;
  border-radius: 10px 10px 0 0;
  font-family: inherit;
  font-size: 14px;
  font-weight: 800;
  color: rgba(0, 0, 0, 0.55);
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
}

.product-page-digi-tabs .tab-title.active,
.product-page-digi-tabs .tab-title:hover {
  color: var(--green-light);
  background: rgba(31, 143, 105, 0.08);
}

.product-page-digi-tabs .wc-tab {
  display: none;
  animation: megaLinkPop 0.35s var(--ease-out) both;
}

.product-page-digi-tabs .wc-tab.is-active {
  display: block;
}

.product-desc {
  line-height: 1.85;
  color: rgba(0, 0, 0, 0.78);
  padding: 20px;
  max-height: 320px;
  overflow-y: auto;
}

.product-desc p {
  margin: 0 0 1em;
}

.product-desc br {
  display: block;
  margin: 0.5em 0;
}

.product-desc ul,
.product-desc ol {
  margin: 0 0 1em;
  padding-right: 1.25em;
}

.product-desc-list {
  list-style: disc;
  margin: 0 0 1em;
  padding-right: 1.35em;
  direction: rtl;
  text-align: right;
}

.product-desc-list li {
  margin-bottom: 0.5em;
  line-height: 1.85;
}

.product-desc-list li::marker {
  color: var(--green-light);
}

.product-desc p {
  margin: 0 0 0.85em;
  direction: rtl;
  text-align: right;
}

.product-purchase {
  margin-top: auto;
  padding-top: 18px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.product-variations {
  margin-bottom: 16px;
}

.product-variations__label {
  display: block;
  font-weight: 800;
  margin-bottom: 10px;
}

.product-variations__options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.product-color-option {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 2px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.product-color-option:has(input:checked) {
  border-color: var(--green-light);
  box-shadow: 0 0 0 2px rgba(31, 143, 105, 0.15);
}

.product-color-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.product-color-option__swatch {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  flex-shrink: 0;
}

.product-color-option__label {
  font-size: 13px;
  font-weight: 700;
}

.product-purchase__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 14px;
}

.product-qty__label {
  display: block;
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 6px;
}

.product-qty__control {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.product-qty__btn {
  width: 40px;
  height: 40px;
  border: 0;
  background: rgba(31, 143, 105, 0.08);
  font-size: 18px;
  font-weight: 900;
  cursor: pointer;
  color: var(--green-light);
}

.product-qty__input {
  width: 52px;
  height: 40px;
  border: 0;
  text-align: center;
  font-family: inherit;
  font-weight: 900;
  font-size: 15px;
  appearance: textfield;
  -moz-appearance: textfield;
}

.product-purchase__submit {
  flex: 1 1 200px;
  min-height: 44px;
}

.product-purchase__hint {
  margin: 10px 0 0;
  font-size: 12px;
  color: rgba(0, 0, 0, 0.5);
}

.product-alert {
  padding: 12px 14px;
  border-radius: 12px;
  margin-bottom: 14px;
  font-weight: 700;
}

.product-alert--error {
  background: #fdecea;
  color: #b42318;
}

.product-alert--ok {
  background: #e8f6ef;
  color: #1f6b4f;
}

.product-layout__rating {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.6);
}

.product-stars {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  direction: ltr;
}

.product-star {
  display: inline-block;
  font-size: 17px;
  line-height: 1;
  color: #d8dde3;
  transition: color 0.15s ease, transform 0.15s ease;
}

.product-star.is-on {
  color: #f5b301;
}

.product-stars--readonly .product-star.is-on {
  text-shadow: 0 0 0 #f5b301;
}

.product-rating-field__label {
  display: block;
  font-weight: 800;
  margin-bottom: 8px;
}

.product-stars--input {
  flex-direction: row-reverse;
  justify-content: flex-end;
  gap: 6px;
  padding: 4px 0;
}

.product-stars--input input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.product-stars--input label {
  display: inline-flex;
  cursor: pointer;
  padding: 2px;
  line-height: 1;
  border-radius: 4px;
  transition: transform 0.12s ease;
}

.product-stars--input label:hover {
  transform: scale(1.06);
}

.product-star-icon::before {
  content: "★";
  display: block;
  font-size: 30px;
  line-height: 1;
  color: #d8dde3;
  transition: color 0.15s ease;
}

.product-stars--input label:hover .product-star-icon::before,
.product-stars--input label:hover ~ label .product-star-icon::before,
.product-stars--input input:checked ~ label .product-star-icon::before {
  color: #f5b301;
}

.product-stars--input input:focus-visible + label {
  outline: 2px solid var(--green-light);
  outline-offset: 3px;
}

.woocommerce-Reviews-title {
  margin: 0 0 14px;
  font-size: 1.15rem;
}

.product-review-list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
}

.product-review-item {
  padding: 14px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.product-review-item__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.product-review-form .comment-form-author,
.product-review-form .comment-form-email,
.product-review-form .comment-form-comment,
.product-review-form .comment-form-rating {
  margin-bottom: 12px;
}

.product-review-form__note {
  margin: 0 0 14px;
  color: #667874;
  font-size: 0.88rem;
}

.review-board__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 16px;
}

.review-board__head .woocommerce-Reviews-title {
  margin: 0;
}

.review-board__summary {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: #667874;
  font-size: 0.88rem;
  font-weight: 700;
}

.review-board {
  list-style: none;
  margin: 0 0 24px;
  padding: 0;
  display: grid;
  gap: 14px;
}

.review-thread {
  background: #fff;
  border: 1px solid rgba(31, 45, 42, 0.08);
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 10px 24px rgba(31, 45, 42, 0.05);
}

.review-post,
.review-reply {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.review-reply {
  margin: 14px 28px 0 0;
  padding: 12px 14px;
  border-radius: 16px;
  background: linear-gradient(180deg, #f4fbf8 0%, #eef7f3 100%);
  border: 1px solid rgba(31, 143, 105, 0.16);
  position: relative;
}

.review-reply::before {
  content: "";
  position: absolute;
  top: -14px;
  right: 20px;
  width: 2px;
  height: 14px;
  background: rgba(31, 143, 105, 0.28);
}

.review-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #1f8f69;
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
}

.review-avatar--seller {
  background: #1f2d2a;
}

.review-post__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  margin-bottom: 6px;
}

.review-post__meta strong {
  font-size: 0.95rem;
}

.review-post__meta time {
  color: #7a8b86;
  font-size: 0.78rem;
}

.review-post__text {
  margin: 0;
  line-height: 1.85;
  color: #243330;
}

.review-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1.5;
}

.review-tag--buyer {
  background: #f7e7a3;
  color: #7a5b00;
}

.review-tag--seller {
  background: #1f8f69;
  color: #fff;
}

.review-stars {
  display: inline-flex;
  gap: 1px;
  color: #d8dde3;
  letter-spacing: 0;
  line-height: 1;
}

.review-stars__i {
  font-size: 0.92rem;
}

.review-stars__i.is-on {
  color: #f5b301;
}

.review-votes {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 10px 0 0;
}

.review-vote {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(31, 45, 42, 0.12);
  background: #fff;
  color: #4a5d58;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
}

.review-vote svg {
  flex-shrink: 0;
}

.review-vote.is-static {
  cursor: default;
}

.review-vote:not(.is-static):hover {
  border-color: rgba(31, 45, 42, 0.28);
  background: #f7faf8;
}

.review-vote--like.is-on {
  border-color: rgba(31, 143, 105, 0.38);
  background: #eef8f4;
  color: #187456;
}

.review-vote--dislike.is-on {
  border-color: rgba(185, 68, 68, 0.32);
  background: #fdf4f4;
  color: #b94444;
}

.review-votes__hint {
  color: #7a8b86;
  font-size: 0.75rem;
  text-decoration: none;
}

a.review-votes__hint:hover {
  color: #1f8f69;
}

.product-review-form .comment-form-author label,
.product-review-form .comment-form-email label,
.product-review-form .comment-form-comment label {
  display: block;
  font-weight: 800;
  margin-bottom: 6px;
}

.product-stars--input label {
  display: inline-flex;
  font-weight: 400;
  margin-bottom: 0;
}

.product-review-form input[type="text"],
.product-review-form input[type="email"],
.product-review-form textarea,
.product-review-form select {
  width: 100%;
  max-width: 420px;
  padding: 10px 12px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 10px;
  font-family: inherit;
}

.product-review-form .required {
  color: #c62828;
}

.product-attrs-table {
  list-style: none;
  margin: 0;
  padding: 0;
}

.product-attrs-table li {
  display: grid;
  grid-template-columns: minmax(120px, 0.9fr) 1fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.product-attrs-table__label {
  font-weight: 800;
  color: rgba(0, 0, 0, 0.55);
}

.product-tabs__empty {
  margin: 0;
  color: rgba(0, 0, 0, 0.55);
}

@media (max-width: 900px) {
  .product-layout {
    grid-template-columns: 1fr;
  }
}

/* ——— checkout & payment ——— */
.checkout-page__head,
.payment-result__panel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.checkout-page__title,
.payment-result h1 {
  margin: 0;
  font-size: 1.5rem;
}

.checkout-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 18px;
  align-items: start;
}

.checkout-panel {
  padding: 22px;
}

.checkout-panel__title {
  margin: 0 0 16px;
  font-size: 1.1rem;
}

.checkout-form {
  display: grid;
  gap: 14px;
}

.checkout-field {
  display: grid;
  gap: 6px;
}

.checkout-field .required {
  color: #b42318;
}

.checkout-field input,
.checkout-field textarea,
.checkout-field select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
}

.checkout-field select:disabled {
  color: var(--muted);
  background: #f7f7f7;
  cursor: not-allowed;
}

.location-picker {
  display: grid;
  gap: 14px;
}

.location-picker__row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 640px) {
  .location-picker__row {
    grid-template-columns: 1fr;
  }
}

.location-map {
  display: grid;
  gap: 8px;
}

.location-map__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.location-map__title {
  font-weight: 700;
  font-size: 0.95rem;
}

.location-map__locate {
  font-size: 0.82rem;
  padding: 6px 12px;
}

.location-map__canvas {
  width: 100%;
  height: 280px;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #eef2f0;
  z-index: 0;
}

.location-map__hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

.proforma-sheet__map a {
  color: var(--green);
  font-weight: 700;
  text-decoration: underline;
}

.proforma-sheet__shipping {
  margin: 10px 0 0;
  font-size: 0.9rem;
  line-height: 1.7;
}

.proforma-sheet__shipping span {
  color: var(--muted);
  font-weight: 500;
}

.checkout-gateway {
  padding: 14px;
  border-radius: 12px;
  background: rgba(31, 143, 105, 0.08);
  border: 1px solid rgba(31, 143, 105, 0.15);
  display: flex;
  align-items: center;
  gap: 14px;
}

.checkout-gateway__logo {
  flex: 0 0 auto;
  display: block;
  width: 95px;
  height: auto;
  object-fit: contain;
}

.checkout-gateway__desc {
  flex: 1;
  margin: 0;
  min-width: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.55;
}

.checkout-form__submit {
  width: 100%;
  margin-top: 4px;
  padding: 14px 18px;
  font-weight: 800;
  font-size: 0.94rem;
  white-space: nowrap;
}

.checkout-lines {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: grid;
  gap: 10px;
}

.checkout-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.92rem;
}

.checkout-line__title {
  display: grid;
  gap: 3px;
}

.checkout-line__code,
.admin-lines small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.checkout-total {
  margin: 0;
  display: grid;
  gap: 8px;
}

.checkout-total div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.checkout-total__grand {
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-weight: 800;
}

.checkout-total__discount dd {
  color: #1f8f69;
  font-weight: 700;
}

.checkout-coupon {
  margin-bottom: 14px;
}

.checkout-coupon__field {
  margin: 0;
}

.checkout-coupon__row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.checkout-coupon__row input {
  flex: 1;
  min-width: 0;
}

.checkout-coupon__row .btn-cart {
  flex: 0 0 auto;
  white-space: nowrap;
}

.checkout-coupon__applied {
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(31, 143, 105, 0.08);
  border: 1px solid rgba(31, 143, 105, 0.22);
  font-size: 0.9rem;
  line-height: 1.6;
}

.checkout-coupon__remove-btn {
  margin-right: 8px;
  padding: 0;
  border: 0;
  background: none;
  color: #8a1f17;
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
}

.checkout-alert {
  margin: 0 0 16px;
  padding: 12px 14px;
  border-radius: 12px;
}

.checkout-alert--error {
  background: #fdecea;
  color: #8a1f17;
  border: 1px solid #f5c2c0;
}

.checkout-alert--success {
  background: #e8f6ef;
  color: #145c43;
  border: 1px solid #b8e0cf;
}

.checkout-methods {
  margin: 0;
  padding: 0;
  border: 0;
  display: grid;
  gap: 10px;
}

.checkout-methods__legend {
  margin-bottom: 8px;
  font-weight: 700;
}

.checkout-methods__list {
  display: grid;
  gap: 10px;
}

.checkout-method {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
  background: #fff;
}

.checkout-method:has(input:checked) {
  border-color: rgba(31, 143, 105, 0.45);
  background: rgba(31, 143, 105, 0.06);
}

.checkout-method input {
  flex: 0 0 auto;
}

.checkout-method__body {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 4px;
}

.checkout-method__title {
  font-weight: 700;
}

.checkout-method__fee {
  display: block;
  margin-top: 2px;
  color: var(--brown, #5a3d2b);
  font-size: 0.9rem;
  font-weight: 700;
}

.checkout-method__note {
  display: block;
  margin-top: 6px;
  color: #b42318;
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.45;
}

.checkout-method--disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.checkout-method--disabled input {
  cursor: not-allowed;
}

.checkout-shipping__hint {
  margin: 10px 0 0;
  color: #b42318;
  font-size: 0.84rem;
  font-weight: 700;
}

.checkout-method__logo {
  flex: 0 0 auto;
  width: 95px;
  height: auto;
}

.checkout-method__logo--card {
  width: 72px;
  height: auto;
  object-fit: contain;
}

.card-payment__head-main {
  display: flex;
  align-items: center;
  gap: 12px;
}

.card-payment__logo {
  flex: 0 0 auto;
  width: 88px;
  height: auto;
  object-fit: contain;
}

.card-payment__intro {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.6;
}

.card-payment__dest {
  margin: 0 0 18px;
  padding: 14px;
  border-radius: 12px;
  background: rgba(241, 209, 86, 0.12);
  border: 1px solid rgba(241, 209, 86, 0.35);
  display: grid;
  gap: 10px;
}

.card-payment__dest div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.card-payment__dest dt {
  color: var(--muted);
}

.card-payment__card-number {
  font-weight: 800;
  letter-spacing: 0.04em;
}

.card-payment__amount-row dd {
  font-weight: 800;
  color: var(--green);
}

.card-payment__buyer {
  margin: 0 0 12px;
  color: var(--muted);
}

.card-payment__note {
  margin: 14px 0 0;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.55;
}

.payment-result__panel {
  max-width: 640px;
  margin: 24px auto;
  padding: 28px;
  text-align: center;
  flex-direction: column;
}

.payment-result__icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
  font-size: 1.6rem;
  font-weight: 800;
}

.payment-result__icon--ok {
  background: rgba(31, 143, 105, 0.15);
  color: var(--green);
}

.payment-result__icon--warn {
  background: rgba(241, 209, 86, 0.25);
  color: #8a6d00;
}

.payment-result__icon--fail {
  background: #fdecea;
  color: #b42318;
}

.payment-result__meta {
  margin: 18px 0;
  display: grid;
  gap: 8px;
  text-align: right;
}

.payment-result__meta div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.payment-result__reason {
  color: var(--muted);
  font-size: 0.92rem;
}

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

@media (prefers-reduced-motion: reduce) {
  .cart-mini--has-items .cart-mini__img--full {
    animation: none;
  }

  .cart-empty__illus,
  .cart-table__subtotal.is-pulse,
  [data-cart-total].is-pulse,
  .cart-page.reveal.is-visible .cart-table__row,
  .cart-page.reveal.is-visible .cart-page__icon {
    animation: none;
  }

  .cart-table__row:hover,
  .btn-cart:hover,
  .cart-remove-btn:hover {
    transform: none;
  }
}

/* ——— header account link ——— */
.bar-top__account {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-weight: 600;
  font-size: 0.88rem;
  line-height: 1.35;
  transition: background 0.25s var(--ease-out), transform 0.2s var(--ease-out);
  width: fit-content;
  max-width: 100%;
  flex-shrink: 0;
  white-space: nowrap;
}

.bar-top__account--in {
  direction: rtl;
  background: rgba(241, 209, 86, 0.22);
  border-color: rgba(241, 209, 86, 0.45);
}

.bar-top__account-name {
  display: inline-block;
  max-width: 100%;
}

.bar-top__account:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.bar-top__account--in:hover {
  background: rgba(241, 209, 86, 0.32);
}

.bar-top__account-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 0 0 0 3px rgba(241, 209, 86, 0.25);
  flex-shrink: 0;
}

/* ——— auth (login / register) ——— */
.auth-page {
  padding: 20px 0 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-shell {
  width: min(1100px, 100%);
  margin: 0 auto;
  padding: 0 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  align-items: stretch;
  border-radius: calc(var(--radius) + 4px);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.14);
}

.auth-shell .auth-card.block-white {
  margin-top: 0;
  border-radius: 0;
  border: none;
  box-shadow: none;
  height: 100%;
  min-height: 100%;
}

.auth-shell .auth-card.block-white:hover {
  box-shadow: none;
  transform: none;
}

.auth-hero {
  position: relative;
  background: linear-gradient(145deg, #1a2c28 0%, #243832 40%, #2d4a42 100%);
  color: #fff;
  padding: 36px 32px;
  display: flex;
  align-items: stretch;
  align-self: stretch;
  min-height: 100%;
  overflow: hidden;
}

.auth-hero__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
}

.auth-hero__badge {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  align-self: flex-start;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(241, 209, 86, 0.18);
  border: 1px solid rgba(241, 209, 86, 0.35);
  color: var(--yellow);
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 18px;
}

.auth-hero__title {
  margin: 0 0 12px;
  font-size: 1.65rem;
  line-height: 1.35;
  font-weight: 800;
}

.auth-hero__lead {
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.95rem;
  line-height: 1.7;
  max-width: 34ch;
}

.auth-hero__perks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.auth-hero__perks li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.9);
}

.auth-hero__icon {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.auth-hero__glow {
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(31, 143, 105, 0.35) 0%, transparent 70%);
  top: -80px;
  left: -60px;
  pointer-events: none;
}

.auth-card {
  padding: 22px 24px 18px;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.auth-card__head {
  margin-bottom: 12px;
}

.auth-card__title {
  margin: 0 0 6px;
  font-size: 1.45rem;
  font-weight: 800;
}

.auth-card__sub {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.auth-tabs {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  background: rgba(31, 45, 42, 0.06);
  border-radius: 14px;
  margin-bottom: 12px;
}

.auth-tabs__btn {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 10px 12px;
  border-radius: 11px;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  line-height: 1.4;
  color: var(--muted);
  min-width: 0;
  transition: color 0.25s var(--ease-out);
}

.auth-tabs__btn.is-active {
  color: var(--ink);
}

.auth-tabs__indicator {
  position: absolute;
  top: 4px;
  left: 0;
  height: calc(100% - 8px);
  border-radius: 11px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  transition: left 0.35s var(--ease-out), width 0.35s var(--ease-out);
  pointer-events: none;
}

.auth-panels {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  width: 100%;
  flex: 1;
}

.auth-form {
  grid-row: 1;
  grid-column: 1;
  width: 100%;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.auth-form > form {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  width: 100%;
  margin: 0;
}

.auth-form > .auth-otp__actions {
  grid-column: 1 / -1;
}

.auth-form:not(.is-active) {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  user-select: none;
}

.auth-form.is-active {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  animation: authFadeIn 0.35s var(--ease-out);
}

.auth-form--login.is-active {
  align-content: center;
}

.auth-form .auth-field,
.auth-form .auth-field--full,
.auth-form .auth-form__submit,
.auth-form .auth-form__hint,
.auth-form .auth-otp__lead {
  grid-column: 1 / -1;
}

.auth-form .auth-field input {
  padding: 9px 11px;
}

.auth-form__submit {
  margin-top: 2px;
  padding: 12px 16px;
}

.auth-form__hint {
  margin-top: -2px;
}

.auth-otp__lead {
  margin: 0 0 14px;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #4a4038;
}

.auth-otp__input {
  text-align: center;
  letter-spacing: 0.35em;
  font-size: 1.25rem;
  font-weight: 700;
}

.auth-otp__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  margin-top: 12px;
}

.auth-otp__actions form {
  margin: 0;
}

.auth-otp__resend,
.auth-otp__back {
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  color: #8b5a2b;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-otp__resend:disabled {
  color: #9a8f84;
  cursor: not-allowed;
  text-decoration: none;
}

@media (max-height: 820px) {
  .auth-page .auth-hero__perks {
    display: none;
  }

  .auth-page .auth-hero__lead {
    margin-bottom: 16px;
  }

  .auth-page .auth-hero {
    padding: 28px 24px;
  }
}

@keyframes authFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-field {
  display: grid;
  gap: 6px;
}

.auth-field__label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
}

.auth-field__optional {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.82rem;
}

.auth-field__hint {
  font-size: 0.8rem;
  color: var(--muted);
}

.auth-field input,
.auth-field textarea {
  width: 100%;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 11px 13px;
  font: inherit;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-field input:focus,
.auth-field textarea:focus {
  outline: none;
  border-color: rgba(31, 143, 105, 0.45);
  box-shadow: 0 0 0 3px rgba(31, 143, 105, 0.12);
}

.auth-field--readonly input {
  background: rgba(31, 45, 42, 0.04);
  color: var(--muted);
  cursor: default;
}

.auth-field__pw {
  position: relative;
  display: flex;
  width: 100%;
}

.auth-field__pw input {
  flex: 1;
  width: 100%;
  min-width: 0;
  padding-left: 64px;
}

.auth-pw-toggle {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: var(--green);
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1.3;
  cursor: pointer;
  padding: 4px 6px;
}

.auth-form__submit,
.account-form__submit {
  width: 100%;
  margin-top: 4px;
  padding: 12px 16px;
  font-weight: 800;
  font-size: 0.92rem;
  line-height: 1.45;
}

.auth-form__hint {
  margin: 0;
  text-align: center;
  font-size: 0.86rem;
  color: var(--muted);
}

.auth-form__hint a {
  color: var(--green);
  font-weight: 700;
}

.auth-alert {
  margin: 0 0 16px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 0.9rem;
}

.auth-alert--error {
  background: #fdecea;
  color: #8a1f17;
  border: 1px solid #f5c2c0;
}

.auth-alert--success {
  background: rgba(31, 143, 105, 0.1);
  color: #136b4f;
  border: 1px solid rgba(31, 143, 105, 0.22);
}

.auth-alert--info {
  background: rgba(241, 209, 86, 0.18);
  color: #6b5600;
  border: 1px solid rgba(241, 209, 86, 0.35);
}

/* ——— account panel ——— */
.account-page {
  padding: 28px 0 48px;
}

.account-layout {
  display: grid;
  grid-template-columns: minmax(240px, 280px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.account-sidebar {
  padding: 22px 18px;
  position: sticky;
  top: 120px;
}

.account-user {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 18px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.account-user__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green) 0%, var(--mint-deep) 100%);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  font-weight: 800;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(31, 143, 105, 0.3);
  margin-top: 2px;
}

.account-user__meta {
  display: grid;
  gap: 6px;
  width: fit-content;
  max-width: calc(100% - 60px);
  justify-items: start;
}

.account-user__name-box {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  padding: 7px 12px;
  border-radius: 10px;
  background: rgba(31, 143, 105, 0.08);
  border: 1px solid rgba(31, 143, 105, 0.16);
}

.account-user__name {
  display: inline;
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1.4;
  white-space: nowrap;
}

.account-user__phone {
  font-size: 0.82rem;
  color: var(--muted);
  direction: ltr;
  unicode-bidi: isolate;
  text-align: right;
}

.phone-ltr,
a[href^="tel"],
input[type="tel"],
.footer-phone-row a {
  direction: ltr;
  unicode-bidi: isolate;
}

.account-nav {
  display: grid;
  gap: 4px;
}

.account-nav__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
  transition: background 0.2s, color 0.2s, transform 0.2s;
}

.account-nav__link:hover {
  background: rgba(31, 143, 105, 0.08);
  color: var(--ink);
  transform: translateX(-2px);
}

.account-nav__link.is-active {
  background: rgba(31, 143, 105, 0.12);
  color: var(--green);
  font-weight: 800;
}

.account-nav__icon {
  font-size: 1.05rem;
  width: 1.4em;
  text-align: center;
}

.account-nav__badge {
  margin-right: auto;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--yellow);
  color: var(--ink);
  font-size: 0.75rem;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.account-logout {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.account-logout__btn {
  width: 100%;
  border: 1px solid rgba(180, 35, 24, 0.2);
  background: rgba(180, 35, 24, 0.06);
  color: #b42318;
  border-radius: 12px;
  padding: 10px 14px;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.4;
  cursor: pointer;
  transition: background 0.2s;
}

.account-logout__btn:hover {
  background: rgba(180, 35, 24, 0.12);
}

.account-main {
  padding: 28px;
  min-height: 420px;
}

.account-main__head {
  margin-bottom: 22px;
}

.account-main__title {
  margin: 0 0 6px;
  font-size: 1.4rem;
  font-weight: 800;
}

.account-main__sub {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.account-form {
  display: grid;
  gap: 14px;
  max-width: 480px;
}

.account-empty {
  text-align: center;
  padding: 36px 20px;
}

.account-empty__icon {
  font-size: 2.8rem;
  margin-bottom: 12px;
}

.account-empty h2 {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.account-empty p {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 0.92rem;
}

.account-orders {
  display: grid;
  gap: 14px;
}

.account-order {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.6);
  transition: box-shadow 0.25s, transform 0.25s;
}

.account-order:hover {
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}

.account-order__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}

.account-order__id {
  margin: 0 0 4px;
  font-size: 1rem;
  font-weight: 800;
  font-family: ui-monospace, monospace;
  direction: ltr;
  text-align: right;
}

.account-order__date {
  font-size: 0.82rem;
  color: var(--muted);
}

.account-order__status {
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

.account-order__status--paid {
  background: rgba(31, 143, 105, 0.12);
  color: var(--green);
}

.account-order__status--pending {
  background: rgba(241, 209, 86, 0.25);
  color: #7a6200;
}

.account-order__status--awaitingverification {
  background: rgba(59, 130, 246, 0.12);
  color: #1d4ed8;
}

.account-order__status--failed,
.account-order__status--cancelled {
  background: #fdecea;
  color: #b42318;
}

.account-order__lines {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  display: grid;
  gap: 4px;
  font-size: 0.88rem;
  color: var(--muted);
}

.account-order__more {
  font-style: italic;
}

.account-order__foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.account-order__total {
  font-weight: 800;
  font-size: 0.95rem;
  display: grid;
  gap: 2px;
}

.account-order__discount {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: #1f8f69;
}

.account-order__link {
  font-size: 0.85rem;
  padding: 8px 14px;
}

.account-order__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.account-user__days {
  font-size: 0.78rem;
  color: var(--green);
  font-weight: 700;
}

.account-main__head--row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}

.account-back {
  margin: 0 0 8px;
  font-size: 0.85rem;
}

.account-back a {
  color: var(--muted);
}

.account-back a:hover {
  color: var(--green);
}

.account-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.account-stat {
  padding: 16px 14px;
  border-radius: 14px;
  background: rgba(31, 143, 105, 0.06);
  border: 1px solid rgba(31, 143, 105, 0.12);
  display: grid;
  gap: 6px;
}

.account-stat__value {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--ink);
  line-height: 1.3;
}

.account-stat__label {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 600;
}

.account-dash-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 14px;
}

.account-dash-block {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
}

.account-dash-block__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.account-dash-block__head h2 {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
}

.account-dash-block__head a {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--green);
}

.account-dash-empty {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.account-dash-orders {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.account-dash-orders a {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--line);
}

.account-dash-orders a:hover {
  border-color: rgba(31, 143, 105, 0.35);
}

.account-dash-orders strong {
  font-family: ui-monospace, monospace;
  direction: ltr;
  text-align: right;
  font-size: 0.9rem;
}

.account-dash-orders span {
  grid-column: 1;
  font-size: 0.8rem;
  color: var(--muted);
}

.account-dash-orders em {
  grid-row: 1 / span 2;
  grid-column: 2;
  align-self: center;
  font-style: normal;
  font-weight: 800;
  font-size: 0.88rem;
}

.account-quick {
  display: grid;
  gap: 8px;
}

.account-quick a {
  display: block;
  padding: 11px 12px;
  border-radius: 12px;
  background: rgba(31, 143, 105, 0.06);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ink);
}

.account-quick a:hover {
  background: rgba(31, 143, 105, 0.12);
  color: var(--green);
}

.account-order-detail {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(240px, 0.9fr);
  gap: 14px;
  align-items: start;
}

.account-order-detail__block {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 0;
}

.account-order-detail__side {
  display: grid;
  gap: 12px;
}

.account-order-detail__block h2 {
  margin: 0 0 12px;
  font-size: 0.95rem;
  font-weight: 800;
}

.account-order-detail__lines {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.account-order-detail__lines > li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.account-order-detail__lines > li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.account-order-detail__line-main {
  display: flex;
  gap: 12px;
  align-items: center;
  min-width: 0;
}

.account-order-detail__line-main img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 10px;
  background: #f3f3f3;
}

.account-order-detail__line-main strong {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.account-order-detail__line-main span {
  font-size: 0.8rem;
  color: var(--muted);
}

.account-order-detail__lines em {
  font-style: normal;
  font-weight: 800;
  white-space: nowrap;
}

.account-order-detail__money {
  margin: 0;
  display: grid;
  gap: 8px;
}

.account-order-detail__money > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.9rem;
}

.account-order-detail__money dt {
  color: var(--muted);
}

.account-order-detail__money dd {
  margin: 0;
  font-weight: 700;
}

.account-order-detail__money .is-total {
  padding-top: 8px;
  border-top: 1px solid var(--line);
  font-size: 1rem;
}

.account-order-detail__money .is-total dd {
  color: var(--green);
  font-weight: 800;
}

.account-order-detail__address,
.account-order-detail__meta {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--muted);
}

.account-order-detail__shipping {
  margin: 10px 0 0;
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--ink);
}

.account-order-detail__meta {
  list-style: none;
  padding: 0;
}

.account-order-detail__pay {
  display: inline-flex;
  justify-content: center;
  width: 100%;
}

.account-wishlist {
  display: grid;
  gap: 12px;
}

.account-wish {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.account-wish__media img {
  width: 120px;
  height: 120px;
  object-fit: cover;
  border-radius: 12px;
  display: block;
  background: #f3f3f3;
}

.account-wish__body h2 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.account-wish__body h2 a:hover {
  color: var(--green);
}

.account-wish__price {
  margin: 0 0 14px;
  font-weight: 800;
}

.account-wish__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.account-coupons {
  display: grid;
  gap: 10px;
}

.account-coupon {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.account-coupon__code {
  margin: 0 0 4px;
  font-family: ui-monospace, monospace;
  direction: ltr;
  text-align: right;
  font-size: 1rem;
}

.account-coupon__label {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 0.85rem;
}

.account-coupon time {
  font-size: 0.8rem;
  color: var(--muted);
}

.account-coupon__side {
  display: grid;
  gap: 6px;
  justify-items: end;
  align-content: center;
}

.account-coupon__side strong {
  color: var(--green);
}

.account-coupon__side a {
  font-size: 0.8rem;
  font-family: ui-monospace, monospace;
  direction: ltr;
  color: var(--muted);
}

.account-tickets {
  display: grid;
  gap: 14px;
  margin: 22px 0;
}

.account-ticket {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.account-ticket.is-unread {
  border-color: rgba(255, 122, 53, 0.4);
  box-shadow: 0 0 0 3px rgba(255, 122, 53, 0.08);
}

.account-ticket > header {
  display: grid;
  gap: 4px;
}

.account-ticket > header span {
  color: var(--muted);
  font-size: 0.82rem;
}

.account-ticket__thread {
  display: grid;
  gap: 8px;
}

.account-ticket__reply {
  display: grid;
  gap: 8px;
}

.account-ticket__reply label {
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
}

.account-ticket__reply textarea,
.account-form .account-field input,
.account-form .account-field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
}

.account-field {
  display: grid;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 700;
}

.ticket-list {
  display: grid;
  gap: 10px;
}

.ticket-list__title {
  margin: 8px 0 0;
  font-size: 1.05rem;
}

.ticket-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px 16px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.ticket-row.is-unread {
  border-color: rgba(255, 122, 53, 0.4);
  box-shadow: 0 0 0 3px rgba(255, 122, 53, 0.08);
}

.ticket-row__main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.ticket-row__main strong {
  font-size: 0.98rem;
}

.ticket-row__main p {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ticket-row__main span {
  color: var(--muted);
  font-size: 0.78rem;
}

.ticket-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

.ticket-status--waiting {
  background: rgba(255, 122, 53, 0.16);
  color: #c2410c;
}

.ticket-status--answered {
  background: rgba(31, 143, 105, 0.14);
  color: #147556;
}

.ticket-status--closed {
  background: rgba(31, 45, 42, 0.08);
  color: #667874;
}

.ticket-row__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.ticket-row__form {
  margin: 0;
}

.ticket-row__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 800;
  font-size: 0.82rem;
  text-decoration: none;
  cursor: pointer;
}

.ticket-row__btn--primary {
  background: var(--green);
  border-color: transparent;
  color: #fff;
}

.ticket-row__btn--ghost {
  color: #9a3412;
}

.ticket-chat__toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.ticket-chat {
  display: grid;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  overflow: hidden;
}

.ticket-chat__msgs {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 16px;
  min-height: 280px;
  max-height: min(62vh, 560px);
  overflow: auto;
  background: #f4f7f6;
}

.ticket-msg {
  display: grid;
  gap: 6px;
  max-width: 78%;
  padding: 10px 12px;
  border-radius: 16px;
  background: rgba(31, 45, 42, 0.06);
}

.ticket-msg strong {
  font-size: 0.8rem;
}

.ticket-msg p {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
}

.ticket-msg time {
  font-size: 0.72rem;
  color: var(--muted);
}

.ticket-msg--user {
  margin-inline-start: auto;
  background: rgba(255, 122, 53, 0.14);
}

.ticket-msg--staff {
  margin-inline-end: auto;
  background: rgba(31, 143, 105, 0.12);
}

.ticket-chat__composer {
  display: grid;
  gap: 8px;
  padding: 12px 16px 16px;
  border-top: 1px solid var(--line);
}

.ticket-chat__composer label {
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
}

.ticket-chat__composer textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  resize: vertical;
}

.ticket-chat__composer .btn-brown,
.ticket-chat__composer .admin-media-btn {
  width: 100%;
}

.ticket-chat__closed {
  margin: 0;
  padding: 14px 16px;
  color: var(--muted);
  font-size: 0.9rem;
}

.ticket-new {
  margin-bottom: 8px;
}

.ticket-new .account-form__title {
  margin: 0;
  font-size: 1.05rem;
}

@media (max-width: 800px) {
  .ticket-row {
    grid-template-columns: 1fr;
  }

  .ticket-row__actions {
    justify-content: stretch;
  }

  .ticket-row__btn,
  .ticket-row__form {
    flex: 1 1 auto;
  }

  .ticket-row__btn {
    width: 100%;
  }
}

.account-support {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.account-support__card {
  display: grid;
  gap: 6px;
  padding: 18px 16px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(31, 143, 105, 0.04);
}

.account-support__card:hover {
  border-color: rgba(31, 143, 105, 0.35);
  transform: translateY(-2px);
}

.account-support__card strong {
  font-size: 1rem;
}

.account-support__card span {
  color: var(--muted);
  font-size: 0.88rem;
}

.product-wishlist-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  margin-top: 0;
  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid rgba(31, 143, 105, 0.28);
  background: #fff;
  color: var(--green);
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.4;
  white-space: normal;
  text-align: center;
  overflow-wrap: anywhere;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.product-wishlist-btn:hover {
  background: rgba(31, 143, 105, 0.08);
  transform: translateY(-1px);
}

.product-wishlist-btn.is-active {
  background: rgba(31, 143, 105, 0.12);
  border-color: rgba(31, 143, 105, 0.45);
}

@media (max-width: 900px) {
  .account-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-dash-grid,
  .account-order-detail,
  .account-support {
    grid-template-columns: 1fr;
  }

  .account-wish {
    grid-template-columns: 88px minmax(0, 1fr);
  }

  .account-wish__media img {
    width: 88px;
    height: 88px;
  }
}

@media (max-width: 900px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-hero {
    padding: 28px 24px;
  }

  .auth-hero__title {
    font-size: 1.35rem;
  }

  .account-layout {
    grid-template-columns: 1fr;
  }

  .account-sidebar {
    position: static;
  }

  .account-nav {
    grid-template-columns: repeat(2, 1fr);
  }

  .account-logout {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .auth-form {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .auth-card {
    padding: 24px 18px 20px;
  }

  .account-nav {
    grid-template-columns: 1fr;
  }

  .bar-top__account:not(.bar-top__account--in) {
    font-size: 0.82rem;
    padding: 6px 12px;
  }
}

/* پیش‌فاکتور */
.proforma-page {
  padding: 16px 0 28px;
  overflow-x: clip;
}

.proforma-page > .wrap {
  max-width: 760px;
}

.proforma-page__head,
.manage-page__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.proforma-page__eyebrow,
.manage-page__sub {
  color: var(--muted);
  margin: 0 0 4px;
  font-size: 0.9rem;
}

.proforma-page__title,
.manage-page__title {
  margin: 0;
  font-size: 1.35rem;
}

.proforma-sheet.block-white,
.manage-panel {
  margin-top: 0;
  padding: 16px 14px 18px;
  margin-bottom: 16px;
}

.proforma-sheet__meta,
.proforma-sheet__parties {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
  margin-bottom: 14px;
}

.proforma-sheet__parties p {
  margin: 4px 0 0;
  font-size: 0.92rem;
  line-height: 1.6;
  word-break: break-word;
}

.proforma-sheet__label,
.manage-form__subtitle {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  margin-bottom: 2px;
}

.proforma-sheet__note {
  background: #f8f8f8;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 0.92rem;
  line-height: 1.6;
}

.proforma-table-wrap,
.manage-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -4px;
  padding: 0 4px;
}

.proforma-table,
.manage-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 0.92rem;
}

.proforma-table th,
.proforma-table td,
.manage-table th,
.manage-table td {
  border-bottom: 1px solid #ececec;
  padding: 8px 6px;
  text-align: right;
  vertical-align: top;
  word-break: break-word;
}

.proforma-table th:nth-child(1),
.proforma-table td:nth-child(1) {
  width: 42px;
}

.proforma-table th:nth-child(3),
.proforma-table td:nth-child(3) {
  width: 52px;
}

.proforma-table th:nth-child(4),
.proforma-table td:nth-child(4),
.proforma-table th:nth-child(5),
.proforma-table td:nth-child(5) {
  width: 88px;
}

.proforma-table__title {
  line-height: 1.5;
}

.proforma-total {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #ececec;
  font-size: 1rem;
}

.proforma-total__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.proforma-total__row--discount strong {
  color: #1f8f69;
}

.proforma-total__row--grand {
  padding-top: 8px;
  border-top: 1px solid #ececec;
  font-weight: 800;
}

.proforma-total strong {
  font-size: 1.05rem;
  color: var(--brown-3);
}

.proforma-pay {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #ececec;
}

.proforma-pay__title {
  margin: 0 0 8px;
  font-size: 1rem;
}

.proforma-pay__method {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.92rem;
}

.proforma-pay__submit {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.proforma-sheet__result {
  margin-top: 20px;
  padding: 14px 16px;
  border-radius: 12px;
}

.proforma-sheet__result--success {
  background: #edf8ef;
  color: #1f6b31;
}

.proforma-sheet__result--info {
  background: #eef5ff;
  color: #1d4f91;
}

.proforma-sheet__result--error {
  background: #fdeeee;
  color: #9b1c1c;
}

.proforma-status--open { color: #b7791f; }
.proforma-status--paid { color: #1f6b31; }
.proforma-status--cancelled,
.proforma-status--expired { color: #9b1c1c; }

.manage-page__actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.manage-login {
  max-width: 420px;
  margin: 40px auto;
  padding: 28px;
}

.manage-login__title {
  margin: 0 0 16px;
}

.manage-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.manage-line-row {
  display: grid;
  grid-template-columns: 2fr 0.7fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.manage-line-row input {
  width: 100%;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 10px 12px;
}

.manage-form__actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.checkout-field--check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 10px 0;
  font-weight: 700;
}

.checkout-field--check input {
  width: auto;
  margin: 0;
}

.admin-coupon-expiry {
  margin: 8px 0 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.55);
}

.admin-coupon-expiry[hidden] {
  display: none;
}

.manage-copy-input {
  width: 100%;
  margin: 10px 0;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 10px;
  direction: ltr;
  text-align: left;
}

.manage-table__actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
}

.manage-inline-form {
  display: inline;
}

.manage-link-btn,
.manage-copy-btn {
  background: none;
  border: none;
  color: var(--brand);
  cursor: pointer;
  padding: 0;
  font: inherit;
}

.admin-confirm {
  border: 0;
  border-radius: 18px;
  padding: 0;
  max-width: 420px;
  width: calc(100% - 32px);
  background: #fff;
  box-shadow: 0 24px 48px rgba(31, 45, 42, 0.22);
  color: #1f2d2a;
}

.admin-confirm::backdrop {
  background: rgba(31, 45, 42, 0.46);
}

.admin-confirm__box {
  padding: 22px 20px 16px;
}

.admin-confirm__text {
  margin: 0 0 18px;
  font-weight: 800;
  line-height: 1.9;
  font-size: 0.98rem;
}

.admin-confirm__actions {
  display: flex;
  gap: 8px;
  justify-content: flex-start;
  flex-wrap: wrap;
}

@media print {
  .fab,
  .support-dock {
    display: none !important;
  }

  @page {
    margin: 12mm;
    size: A4;
  }

  body.page-proforma {
    background: #fff !important;
    color: #1f2d2a;
  }

  .page-proforma .site-head {
    position: static !important;
    box-shadow: none !important;
  }

  .page-proforma .bar-top {
    background: #fff !important;
    padding: 0 0 14px !important;
  }

  .page-proforma .bar-top__grid {
    display: block !important;
  }

  .page-proforma .bar-top__brand {
    display: flex !important;
    justify-content: center !important;
    width: 100% !important;
  }

  .page-proforma .bar-top__search,
  .page-proforma .bar-top__actions,
  .page-proforma .nav-main,
  .page-proforma .nav-mega-root,
  .page-proforma .footer,
  .page-proforma .fab,
  .page-proforma .support-dock,
  .page-proforma .proforma-page__head,
  .page-proforma .proforma-pay,
  .page-proforma .proforma-sheet__result,
  .page-proforma .auth-alert {
    display: none !important;
  }

  .page-proforma .logo {
    margin: 0 auto;
  }

  .page-proforma .proforma-page {
    padding: 0 !important;
    overflow: visible !important;
  }

  .page-proforma .proforma-page > .wrap {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .page-proforma .proforma-sheet.block-white {
    margin: 0 !important;
    padding: 16px !important;
    border: 1px solid #d8d8d8 !important;
    box-shadow: none !important;
    page-break-inside: avoid;
  }

  .page-proforma .proforma-table-wrap {
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .page-proforma .proforma-table {
    font-size: 0.85rem;
  }

  .page-proforma .proforma-table thead {
    display: table-header-group !important;
  }

  .page-proforma .proforma-table tbody tr {
    display: table-row !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
  }

  .page-proforma .proforma-table td,
  .page-proforma .proforma-table th {
    display: table-cell !important;
    padding: 8px 6px !important;
  }

  .page-proforma .proforma-table td::before {
    display: none !important;
    content: none !important;
  }

  .page-proforma .proforma-table td.proforma-table__title {
    display: table-cell !important;
    border-bottom: 1px solid #ececec !important;
    padding: 8px 6px !important;
    margin: 0 !important;
    font-weight: 400 !important;
  }
}

@media (max-width: 720px) {
  .manage-form__grid,
  .manage-line-row {
    grid-template-columns: 1fr;
  }

  .proforma-sheet__meta,
  .proforma-sheet__parties {
    grid-template-columns: 1fr;
  }

  .proforma-table thead {
    display: none;
  }

  .proforma-table tbody tr {
    display: block;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 10px 12px;
    margin-bottom: 10px;
    background: #fafafa;
  }

  .proforma-table td {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    border-bottom: none;
    padding: 5px 0;
    width: auto !important;
  }

  .proforma-table td::before {
    content: attr(data-label);
    color: var(--muted);
    flex: 0 0 auto;
    font-size: 0.82rem;
  }

  .proforma-table td.proforma-table__title {
    display: block;
    font-weight: 700;
    padding-bottom: 8px;
    margin-bottom: 4px;
    border-bottom: 1px dashed #e6e6e6;
  }

  .proforma-table td.proforma-table__title::before {
    display: none;
  }

  .proforma-pay__submit {
    font-size: 0.95rem;
    padding: 12px 10px;
  }
}
.shop-layout {
  display: grid;
  grid-template-columns: minmax(220px, 260px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.shop-sidebar {
  position: sticky;
  top: 120px;
}

.shop-filters {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.72);
  display: grid;
  gap: 10px;
}

.shop-filters__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.shop-filters__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
}

.shop-filters__clear {
  font-size: 0.8rem;
  font-weight: 700;
  color: #b42318;
}

.shop-filter {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 10px;
  background: #fff;
}

.shop-filter > summary {
  cursor: pointer;
  list-style: none;
  padding: 11px 2px;
  font-weight: 800;
  font-size: 0.9rem;
}

.shop-filter > summary::-webkit-details-marker {
  display: none;
}

.shop-filter__body {
  display: grid;
  gap: 8px;
  padding: 0 0 12px;
}

.shop-filter__price {
  grid-template-columns: 1fr 1fr;
}

.shop-filter__price label {
  display: grid;
  gap: 4px;
  font-size: 0.8rem;
  color: var(--muted);
}

.shop-filter__price input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  font-family: inherit;
}

.shop-filter__hint {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.75rem;
  color: var(--muted);
}

.shop-check {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.86rem;
  line-height: 1.5;
  cursor: pointer;
}

.shop-check em {
  font-style: normal;
  color: var(--muted);
  font-size: 0.78rem;
}

.shop-filters__submit {
  width: 100%;
  justify-content: center;
}

.shop-head-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.shop-compare-link,
.bar-top__compare {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(31, 143, 105, 0.12);
  color: var(--green);
  font-weight: 800;
  font-size: 0.85rem;
}

.product-secondary-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin-top: 10px;
}

.product-secondary-actions form {
  min-width: 0;
  max-width: 100%;
}

.product-compare-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid rgba(26, 44, 40, 0.18);
  background: #fff;
  color: var(--ink);
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.4;
  white-space: normal;
  text-align: center;
  overflow-wrap: anywhere;
  cursor: pointer;
}

.product-compare-btn.is-active,
.product-compare-btn:hover {
  background: rgba(26, 44, 40, 0.06);
}

@media (max-width: 720px) {
  .product-wishlist-btn,
  .product-compare-btn {
    font-size: 0.8rem;
    padding: 10px 10px;
  }
}

.compare-table-wrap {
  overflow-x: auto;
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.compare-table th,
.compare-table td {
  border: 1px solid var(--line);
  padding: 12px;
  vertical-align: top;
  text-align: center;
}

.compare-table th[scope="row"] {
  text-align: right;
  background: rgba(31, 143, 105, 0.05);
  font-weight: 800;
  white-space: nowrap;
}

.compare-product {
  display: grid;
  gap: 8px;
  justify-items: center;
}

.compare-product img {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
  background: #f3f3f3;
}

.compare-product strong {
  display: block;
  font-size: 0.88rem;
  line-height: 1.5;
}

.compare-remove {
  border: 0;
  background: transparent;
  color: #b42318;
  font-family: inherit;
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 900px) {
  .shop-layout {
    grid-template-columns: 1fr;
  }

  .shop-sidebar {
    position: static;
  }
}

.product-gallery {
  display: grid;
  gap: 12px;
}

.product-gallery__stage {
  position: relative;
}

.product-gallery__main {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.product-gallery__main img,
.product-layout__gallery img {
  width: 100% !important;
  height: 100% !important;
  object-fit: fill !important;
  max-height: 520px !important;
  border-radius: 16px !important;
  background: #f6f8f7 !important;
}

.product-gallery__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  color: #555;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
  direction: ltr;
  unicode-bidi: isolate;
}

.product-gallery__nav svg {
  display: block;
  flex-shrink: 0;
}

.product-gallery__nav:hover {
  color: var(--brown, #6b4f3a);
  background: #fff;
  transform: translateY(-50%) scale(1.06);
}

.product-gallery__nav--prev {
  right: 10px;
}

.product-gallery__nav--next {
  left: 10px;
}

.product-gallery__zoom {
  position: absolute;
  left: 12px;
  bottom: 12px;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  font-size: 0.9rem;
}

.product-gallery__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.product-gallery__thumb {
  width: 72px;
  height: 72px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 12px;
  overflow: hidden;
  background: #f3f3f3;
  cursor: pointer;
}

.product-gallery__thumb.is-active,
.product-gallery__thumb:hover {
  border-color: var(--green);
}

.product-gallery__thumb img {
  width: 100% !important;
  height: 100% !important;
  object-fit: fill !important;
  display: block !important;
}

.product-share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}

.product-share__label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--muted);
}

.product-share__btn {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 800;
}

.product-share__btn--wa {
  background: rgba(37, 211, 102, 0.14);
  color: #128c7e;
}

.product-share__btn--tg {
  background: rgba(36, 161, 222, 0.14);
  color: #229ed9;
}

.product-related {
  margin-top: 18px;
  padding: 22px;
}

.product-lightbox[hidden] {
  display: none !important;
}

.product-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
}

.product-lightbox__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(10, 18, 16, 0.72);
  cursor: pointer;
}

.product-lightbox__dialog {
  position: relative;
  z-index: 1;
  width: min(920px, calc(100vw - 28px));
  max-height: calc(100vh - 40px);
  display: grid;
  place-items: center;
}

.product-lightbox__img {
  max-width: 100%;
  max-height: calc(100vh - 80px);
  object-fit: contain;
  border-radius: 14px;
  background: #fff;
}

.product-lightbox__close,
.product-lightbox__nav {
  position: absolute;
  border: 0;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  width: 42px;
  height: 42px;
  border-radius: 999px;
  font-size: 1.4rem;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.16);
}

.product-lightbox__close {
  top: -8px;
  left: -8px;
}

.product-lightbox__nav--prev {
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.product-lightbox__nav--next {
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.product-lightbox__counter {
  position: absolute;
  bottom: -8px;
  margin: 0;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  font-size: 0.85rem;
  font-weight: 700;
}

.product-sticky[hidden] {
  display: none !important;
}

.product-sticky {
  position: fixed;
  right: 0;
  left: 0;
  bottom: 0;
  z-index: 900;
  background: rgba(255, 255, 255, 0.96);
  border-top: 1px solid var(--line);
  box-shadow: 0 -8px 28px rgba(0, 0, 0, 0.08);
  transform: translateY(110%);
  transition: transform 0.28s var(--ease-out);
}

.product-sticky.is-visible {
  transform: translateY(0);
}

.product-sticky__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-block: 10px;
}

.product-sticky__info {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.product-sticky__info img {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  background: #f3f3f3;
}

.product-sticky__title {
  display: block;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: min(42vw, 320px);
}

.product-sticky__price {
  display: block;
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--green);
}

.product-sticky__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.product-qty--sticky {
  display: flex;
  align-items: center;
  gap: 0;
}

.product-qty--sticky .product-qty__input {
  width: 48px;
  text-align: center;
}

body.has-product-sticky {
  padding-bottom: 84px;
}

body.has-lightbox {
  overflow: hidden;
}

@media (max-width: 720px) {
  .product-sticky__title {
    max-width: 36vw;
  }

  .product-sticky__actions {
    gap: 6px;
  }

  .product-qty--sticky {
    display: none;
  }
}

.content-page {
  padding-bottom: 40px;
}

.content-shell {
  padding: 28px 24px 32px;
}

.content-shell__head {
  margin-bottom: 22px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.content-shell__title {
  margin: 0 0 8px;
  font-size: clamp(1.35rem, 2.5vw, 1.8rem);
  font-weight: 800;
}

.content-shell__lead {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.content-shell__body {
  display: grid;
  gap: 18px;
  line-height: 1.9;
  font-size: 0.95rem;
}

.content-block h2 {
  margin: 0 0 10px;
  font-size: 1.1rem;
}

.content-block p,
.content-block ul,
.content-block ol {
  margin: 0 0 10px;
}

.content-block ul,
.steps-list {
  padding-inline-start: 1.2rem;
}

.steps-list li {
  margin-bottom: 10px;
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 14px;
  background: #fff;
}

.faq-item > summary {
  cursor: pointer;
  list-style: none;
  padding: 14px 0;
  font-weight: 800;
}

.faq-item > summary::-webkit-details-marker {
  display: none;
}

.faq-item p {
  margin: 0 0 14px;
  color: var(--muted);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 18px;
}

.contact-cards {
  display: grid;
  gap: 10px;
}

.contact-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 16px;
  background: rgba(31, 143, 105, 0.04);
}

.contact-card h2 {
  margin: 0 0 6px;
  font-size: 0.95rem;
}

.contact-card p {
  margin: 0;
  color: var(--muted);
}

.contact-map h2 {
  margin: 0 0 10px;
  font-size: 1rem;
}

.contact-map__frame {
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  min-height: 280px;
}

.contact-map__frame iframe,
.contact-map__canvas {
  width: 100%;
  height: 300px;
  border: 0;
  display: block;
}

.contact-map__link {
  margin: 8px 0 0;
  font-size: 0.85rem;
}

.track-form,
.jobs-form {
  max-width: 480px;
  margin-bottom: 18px;
}

.jobs-intro {
  display: grid;
  gap: 10px;
}

.jobs-intro > .auth-field__label {
  margin-bottom: 0;
}

.jobs-intro textarea {
  width: 100%;
}

.jobs-resume {
  display: grid;
  gap: 6px;
  margin-top: 4px;
}

.jobs-resume input[type="file"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  font-family: inherit;
  font-size: 0.9rem;
  background: #fff;
}

.auth-field select,
.auth-field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px 12px;
  font-family: inherit;
  font-size: 0.95rem;
  background: #fff;
}

.track-result {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  display: grid;
  gap: 8px;
}

.track-result__head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.track-result__head h2 {
  margin: 0;
  font-family: ui-monospace, monospace;
  direction: ltr;
  text-align: right;
}

.track-result__lines {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
}

.blog-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.brand-grid {
  display: grid;
  gap: 12px;
}

.blog-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: #fff;
  min-width: 0;
}

.brand-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  background: #fff;
}

.blog-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #ece7df;
}

.blog-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.blog-card:hover .blog-card__media img {
  transform: scale(1.04);
}

.blog-card__date {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1;
  margin: 0;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(20, 24, 22, 0.78);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.02em;
  direction: rtl;
  unicode-bidi: isolate;
}

.blog-card__body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 16px 16px;
  flex: 1;
}

.blog-card__title {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.45;
}

.blog-card__title a {
  color: inherit;
  text-decoration: none;
}

.blog-card__title a:hover {
  color: var(--brown, #6b4f3a);
}

.blog-card__excerpt {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.7;
  flex: 1;
}

.blog-card__more {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  margin-top: 4px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  color: inherit;
  font-weight: 700;
  font-size: 0.84rem;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.blog-card__more:hover {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.18);
}

.blog-hero {
  margin: 0 0 16px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
}

.blog-hero img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.blog-meta {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.82rem;
}

.blog-content {
  line-height: 1.9;
}

.brand-grid {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.brand-card {
  display: grid;
  gap: 6px;
  text-align: center;
  font-weight: 800;
}

.brand-card span {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.85rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 16px;
}

.footer-links a {
  color: #d7e3de;
  font-size: 0.82rem;
}

.footer-links a:hover {
  color: #fff;
}

@media (max-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .blog-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .blog-list {
    grid-template-columns: 1fr;
  }
}

/* ——— پنل مدیریت ——— */
body.page-admin {
  margin: 0;
  min-height: 100vh;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  background:
    radial-gradient(1200px 420px at 100% -10%, rgba(241, 209, 86, 0.18), transparent 55%),
    radial-gradient(900px 380px at -10% 110%, rgba(31, 143, 105, 0.1), transparent 50%),
    #e7efec;
  color: #1f2d2a;
}

.admin-login-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px 16px;
  background:
    radial-gradient(ellipse 80% 60% at 20% 0%, rgba(241, 209, 86, 0.28), transparent 50%),
    linear-gradient(165deg, #1f2d2a 0%, #2d4a43 42%, #6f9e92 100%);
}

.admin-login {
  width: min(420px, 100%);
  padding: 32px 28px 28px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow:
    0 24px 60px rgba(16, 32, 28, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.6);
}

.admin-login__mark {
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  width: 100%;
  max-width: 180px;
  padding: 0;
  background: none;
}

.admin-login__mark img {
  display: block;
  width: 100%;
  height: auto;
}

.admin-login__eyebrow {
  margin: 0 0 4px;
  text-align: center;
  color: #1f8f69;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.admin-login__brand {
  margin: 0 0 6px;
  color: var(--brown, #1f8f69);
  font-weight: 800;
}

.admin-login__title {
  margin: 0 0 20px;
  font-size: 1.45rem;
  text-align: center;
}

.admin-login__form {
  display: grid;
  gap: 12px;
}

.admin-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
}

.admin-side {
  background:
    linear-gradient(180deg, rgba(241, 209, 86, 0.08), transparent 18%),
    #182421;
  color: #eef6f3;
  display: flex;
  flex-direction: column;
  padding: 18px 14px 16px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
}

.admin-side__brand {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  margin: 0 6px 10px;
  padding: 4px 6px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-side__logo {
  width: 100%;
  height: 44px;
  object-fit: contain;
  object-position: right center;
  padding: 6px 10px;
  border-radius: 14px;
  background: rgba(241, 209, 86, 0.1);
}

.admin-side__brand-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.admin-side__brand strong {
  display: block;
  font-size: 1.02rem;
  font-style: normal;
}

.admin-side__brand em,
.admin-side__brand span {
  color: #9fb8b1;
  font-size: 0.78rem;
  font-style: normal;
  font-weight: 600;
}

.admin-side__nav {
  display: grid;
  gap: 4px;
  flex: 1;
  align-content: start;
}

.admin-side__label {
  margin: 12px 12px 4px;
  color: #7f9a93;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.admin-side__link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #d7e8e2;
  text-decoration: none;
  padding: 9px 12px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.92rem;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.admin-side__ico {
  flex-shrink: 0;
  opacity: 0.86;
}

.admin-side__link:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}

.admin-side__link.is-active {
  background: linear-gradient(90deg, rgba(31, 143, 105, 0.42), rgba(241, 209, 86, 0.16));
  color: #fff;
  box-shadow: inset 3px 0 0 #f1d156;
}

.admin-side__link.is-active .admin-side__ico {
  opacity: 1;
  color: #f1d156;
}

.admin-side__foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 14px 10px 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.85rem;
}

.admin-side__user {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.admin-side__user b {
  display: block;
  font-size: 0.84rem;
}

.admin-side__user small {
  display: block;
  opacity: 0.7;
  font-size: 0.74em;
}

.admin-side__avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: linear-gradient(135deg, #1f8f69, #f1d156);
  color: #1f2d2a;
  font-weight: 800;
}

.admin-side__logout {
  color: #1f2d2a;
  background: #f1d156;
  text-decoration: none;
  font-weight: 800;
  font-size: 0.78rem;
  padding: 6px 10px;
  border-radius: 999px;
  flex-shrink: 0;
}

.admin-side__logout:hover {
  filter: brightness(1.05);
}

.manage-form select[name="role"] {
  min-width: 0;
  width: 100%;
  border: 1px solid #d9e4e0;
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
}

.admin-main {
  padding: 28px 28px 48px;
  min-width: 0;
}

.admin-page__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 20px;
}

.admin-page__head h1 {
  margin: 0 0 4px;
  font-size: 1.55rem;
  letter-spacing: -0.02em;
}

.admin-page__head p {
  margin: 0;
  color: #667874;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(158px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.admin-stat {
  position: relative;
  overflow: hidden;
  background: #fff;
  border-radius: 18px;
  padding: 16px 16px 14px;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 10px 28px rgba(31, 45, 42, 0.06);
  border: 1px solid rgba(31, 45, 42, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-stat::after {
  content: "";
  position: absolute;
  inset: auto -12px -18px auto;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(31, 143, 105, 0.08);
}

.admin-stat:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(31, 45, 42, 0.1);
}

.admin-stat span {
  display: block;
  color: #667874;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.admin-stat strong {
  position: relative;
  z-index: 1;
  font-size: 1.4rem;
}

.admin-stat--paid::after { background: rgba(31, 143, 105, 0.16); }
.admin-stat--wait::after { background: rgba(255, 122, 53, 0.16); }
.admin-stat--products::after { background: rgba(143, 185, 173, 0.28); }
.admin-stat--media::after { background: rgba(241, 209, 86, 0.28); }
.admin-stat--user::after { background: rgba(31, 45, 42, 0.1); }
.admin-stat--paid strong { color: #136b4f; }
.admin-stat--wait strong { color: #c2410c; }

.admin-panel {
  background: rgba(255, 255, 255, 0.94);
  border-radius: 20px;
  padding: 18px 18px 20px;
  margin-bottom: 16px;
  box-shadow: 0 10px 30px rgba(31, 45, 42, 0.06);
  border: 1px solid rgba(31, 45, 42, 0.04);
}

.admin-panel__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.admin-panel h2 {
  margin: 0 0 12px;
  font-size: 1.05rem;
}

.admin-panel__head h2 {
  margin: 0;
}

.admin-panel__head a {
  color: #1f8f69;
  font-weight: 800;
  font-size: 0.86rem;
  text-decoration: none;
}

.admin-empty {
  margin: 8px 0 0;
  color: #667874;
  padding: 18px;
  text-align: center;
  background: #f5f9f7;
  border-radius: 14px;
}

.admin-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.admin-filters a {
  text-decoration: none;
  color: #1f2d2a;
  background: #fff;
  border: 1px solid rgba(31, 45, 42, 0.08);
  border-radius: 999px;
  padding: 7px 13px;
  font-size: 0.85rem;
  font-weight: 700;
}

.admin-filters a:hover {
  border-color: #1f8f69;
}

.admin-filters a.is-active {
  background: #1f8f69;
  border-color: #1f8f69;
  color: #fff;
}

.admin-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  background: #eef2f1;
  color: #445854;
  white-space: nowrap;
}

.admin-badge--paid {
  background: rgba(31, 143, 105, 0.14);
  color: #136b4f;
}

.admin-badge--wait {
  background: rgba(255, 122, 53, 0.16);
  color: #c2410c;
}

.admin-badge--pending {
  background: rgba(241, 209, 86, 0.32);
  color: #6b5600;
}

.admin-badge--bad {
  background: #fdecea;
  color: #8a1f17;
}

.admin-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
  margin: 0 0 14px;
}

.admin-meta dt {
  color: #667874;
  font-size: 0.8rem;
}

.admin-meta dd {
  margin: 2px 0 0;
  font-weight: 700;
}

.admin-lines {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
}

.admin-lines li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #eef2f1;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.admin-courier-form {
  margin: 10px 0 18px;
  max-width: 420px;
}

.admin-panel__subtitle {
  margin: 18px 0 8px;
  font-size: 1rem;
}

.admin-delivery-map {
  margin: 14px 0 18px;
  grid-column: 1 / -1;
}

.admin-delivery-map__canvas {
  width: 100%;
  height: 280px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line, #d5e0db);
  background: #eef2f0;
}

.admin-delivery-map__link {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  margin: 8px 0 0;
  font-size: 0.88rem;
}

.admin-delivery-map__link a {
  color: var(--green, #1f6b4f);
  font-weight: 700;
}

.page-admin .manage-table {
  border-collapse: separate;
  border-spacing: 0;
}

.page-admin .manage-table th {
  background: #f3f8f6;
  font-size: 0.78rem;
  font-weight: 800;
  color: #4e6660;
  padding: 11px 10px;
}

.page-admin .manage-table th:first-child {
  border-top-right-radius: 12px;
}

.page-admin .manage-table th:last-child {
  border-top-left-radius: 12px;
}

.page-admin .manage-table td {
  padding: 12px 10px;
  vertical-align: middle;
}

.page-admin .manage-table tbody tr:hover td {
  background: #f7fbf9;
}

.page-admin .manage-table a {
  color: #1f8f69;
  font-weight: 800;
  text-decoration: none;
}

.admin-table {
  table-layout: auto;
}

.admin-thumb,
.admin-preview {
  display: block;
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 12px;
  background: #f3f3f3;
}

.admin-preview {
  width: 120px;
  height: 120px;
  margin-bottom: 8px;
}

.admin-product-gallery {
  gap: 10px;
}

.admin-product-gallery__list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 4px 0 8px;
}

.admin-product-gallery__item {
  display: grid;
  gap: 6px;
  width: 96px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}

.admin-product-gallery__item img {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 10px;
  background: #eee;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.admin-product-gallery__keep {
  display: flex;
  align-items: center;
  gap: 4px;
  line-height: 1.3;
}

/* ===== Product gallery editor ===== */
.manage-form__subtitle--gallery {
  margin-top: 28px;
  margin-bottom: 6px;
  color: #27473e;
  font-size: 1rem;
}

.admin-custom-galleries__intro {
  max-width: 860px;
  margin: 0 0 14px;
}

.admin-gallery-section-label {
  max-width: 560px;
  margin-bottom: 18px;
}

.admin-custom-galleries {
  display: grid;
  gap: 16px;
  margin-bottom: 16px;
}

.admin-custom-gallery-item {
  position: relative;
  display: grid;
  gap: 16px;
  padding: 17px;
  border: 1px solid #d7e8e1;
  border-radius: 20px;
  background: linear-gradient(145deg, #ffffff 0%, #f5faf8 100%);
  box-shadow: 0 10px 28px rgba(31, 82, 68, 0.07);
  transition: opacity 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.admin-custom-gallery-item:hover {
  border-color: #b8d9cd;
  box-shadow: 0 14px 34px rgba(31, 82, 68, 0.1);
}

.admin-custom-gallery-item__head,
.admin-custom-gallery-item__identity,
.admin-gallery-upload-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-custom-gallery-item__head {
  padding-bottom: 13px;
  border-bottom: 1px solid #e3efeb;
}

.admin-custom-gallery-item__identity {
  justify-content: flex-start;
  min-width: 0;
}

.admin-custom-gallery-item__identity strong,
.admin-gallery-upload-card__head strong {
  display: block;
  color: #27473e;
  font-size: 0.92rem;
}

.admin-custom-gallery-item__identity small,
.admin-gallery-upload-card__head small {
  display: block;
  margin-top: 3px;
  color: #71847e;
  font-size: 0.74rem;
  font-weight: 500;
  line-height: 1.55;
}

.cg-drag-handle {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border: 1px solid #d5e6df;
  border-radius: 10px;
  color: #78928a;
  background: #f4faf7;
  cursor: grab;
  font-size: 1.35rem;
  line-height: 1;
  user-select: none;
}

.cg-drag-handle:active {
  cursor: grabbing;
}

.admin-gallery-remove {
  flex: 0 0 auto;
  border: 1px solid #f0c7c2;
  border-radius: 10px;
  padding: 7px 11px;
  color: #b42318;
  background: #fff8f7;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.admin-gallery-remove:hover {
  border-color: #df9a92;
  background: #fff0ee;
  transform: translateY(-1px);
}

.admin-custom-gallery-item__fields,
.admin-gallery-upload-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.admin-gallery-field {
  display: grid;
  gap: 6px;
}

.admin-gallery-field > span {
  color: #45645b;
  font-size: 0.79rem;
  font-weight: 800;
}

.admin-gallery-field input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d4e5df;
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  font: inherit;
}

.admin-gallery-field input[dir="ltr"] {
  direction: ltr;
  text-align: left;
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  letter-spacing: 0.02em;
}

.admin-gallery-field input:focus {
  outline: none;
  border-color: #1f8f69;
  box-shadow: 0 0 0 3px rgba(31, 143, 105, 0.14);
}

.admin-gallery-upload-card {
  display: grid;
  align-content: start;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border: 1px solid #e0ece8;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
}

.admin-gallery-upload-card__head {
  align-items: flex-start;
}

.admin-gallery-upload-card__badge {
  flex: 0 0 auto;
  padding: 4px 8px;
  border-radius: 999px;
  color: #1f6b4f;
  background: #e8f6ef;
  font-size: 0.68rem;
  font-weight: 800;
  white-space: nowrap;
}

.admin-upload-zone {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 126px;
  gap: 5px;
  padding: 17px 14px;
  border: 1.5px dashed #a9cfc1;
  border-radius: 15px;
  color: #37665a;
  background: linear-gradient(145deg, #f7fcfa 0%, #eef8f3 100%);
  text-align: center;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.admin-upload-zone input[type="file"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.admin-upload-zone:hover,
.admin-upload-zone:focus-within,
.admin-upload-zone.is-dragover {
  border-color: #1f8f69;
  background: #edf9f3;
  box-shadow: 0 0 0 4px rgba(31, 143, 105, 0.11);
  transform: translateY(-1px);
}

.admin-upload-zone.is-picked {
  border-style: solid;
  border-color: #58a98a;
  background: #f0fbf6;
}

.admin-upload-zone.is-invalid {
  border-color: #c0392b;
  background: #fff7f6;
  box-shadow: 0 0 0 4px rgba(192, 57, 43, 0.08);
}

.admin-upload-zone__icon {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #fff;
  background: #1f8f69;
  font-size: 1.35rem;
  font-weight: 400;
  line-height: 1;
}

.admin-upload-zone__title {
  max-width: 100%;
  overflow: hidden;
  color: #245848;
  font-size: 0.82rem;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-upload-zone__hint,
[data-upload-error] {
  display: block;
  color: #769089;
  font-size: 0.7rem;
  line-height: 1.5;
}

[data-upload-error] {
  position: relative;
  z-index: 1;
  color: #b42318;
  font-weight: 700;
}

.admin-current-image {
  display: inline-grid;
  justify-items: center;
  gap: 5px;
  margin-bottom: 8px;
  color: #71847e;
  font-size: 0.72rem;
  font-weight: 700;
}

.admin-product-image-field .admin-upload-zone--main {
  max-width: 560px;
}

.admin-gallery-existing-cover,
.admin-gallery-selected-cover {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  width: fit-content;
  max-width: 100%;
  padding: 7px;
  border: 1px solid #dcebe5;
  border-radius: 12px;
  color: #57736a;
  background: #fbfefd;
  font-size: 0.72rem;
  font-weight: 700;
}

.admin-gallery-existing-cover img,
.admin-gallery-selected-cover img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 9px;
  background: #edf3f1;
}

.admin-gallery-existing-grid,
.admin-gallery-selected-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 9px;
}

.admin-gallery-image {
  position: relative;
  min-width: 0;
  aspect-ratio: 1;
  margin: 0;
  overflow: hidden;
  border: 1px solid #dcebe5;
  border-radius: 12px;
  background: #edf3f1;
}

.admin-gallery-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.admin-gallery-image figcaption {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  overflow: hidden;
  padding: 14px 5px 5px;
  color: #fff;
  background: linear-gradient(transparent, rgba(20, 32, 28, 0.78));
  font-size: 0.62rem;
  text-overflow: ellipsis;
  white-space: nowrap;
  direction: ltr;
  text-align: left;
}

.admin-gallery-image__remove {
  position: absolute;
  top: 5px;
  right: 5px;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(180, 35, 24, 0.92);
  font: inherit;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease;
}

.admin-gallery-image__remove:hover {
  background: #a51d14;
  transform: scale(1.1);
}

.admin-gallery-file-count {
  margin: 0;
  padding: 7px 10px;
  border-radius: 10px;
  color: #1f6b4f;
  background: #eaf7f0;
  font-size: 0.74rem;
  font-weight: 800;
}

.admin-add-gallery-btn {
  width: auto;
  min-width: 220px;
}

.admin-custom-gallery-item.cg-dragging {
  opacity: 0.5;
  transform: scale(0.985);
  box-shadow: 0 8px 24px rgba(120, 90, 40, 0.25);
}

.admin-custom-gallery-item.cg-drag-over {
  border-color: #b98a4e;
  box-shadow: 0 0 0 3px rgba(185, 138, 78, 0.18);
}

@media (max-width: 720px) {
  .admin-custom-gallery-item__fields,
  .admin-gallery-upload-grid {
    grid-template-columns: 1fr;
  }

  .admin-custom-gallery-item {
    padding: 13px;
    border-radius: 16px;
  }

  .admin-custom-gallery-item__head {
    align-items: flex-start;
  }

  .admin-gallery-upload-card__head {
    align-items: flex-start;
  }
}

.admin-search {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 10px;
  background: #f6faf8;
  border-radius: 14px;
}

.admin-search input[type="search"] {
  flex: 1 1 180px;
  min-width: 140px;
  border: 1px solid #d9e4e0;
  border-radius: 12px;
  padding: 10px 12px;
  font: inherit;
  background: #fff;
}

.admin-search select {
  flex: 0 1 220px;
  min-width: 150px;
  border: 1px solid #d9e4e0;
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
}

.page-admin .checkout-field input,
.page-admin .checkout-field textarea,
.page-admin .checkout-field select {
  border: 1px solid #d9e4e0;
  border-radius: 12px;
  background: #fbfdfc;
}

.page-admin .checkout-field input:focus,
.page-admin .checkout-field textarea:focus,
.page-admin .checkout-field select:focus,
.admin-search input:focus,
.admin-search select:focus {
  outline: none;
  border-color: #1f8f69;
  box-shadow: 0 0 0 3px rgba(31, 143, 105, 0.14);
  background: #fff;
}

.admin-new-cat {
  border: 1px dashed #cfe0da;
  border-radius: 14px;
  padding: 12px;
  margin: 0 0 12px;
  background: #f8fbfa;
}

.admin-new-cat legend {
  padding: 0 6px;
  font-weight: 700;
}

.admin-place-form {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.admin-place-form select,
.admin-new-cat select,
.manage-form select[name="place"] {
  min-width: 220px;
  max-width: 340px;
  border: 1px solid #d9e4e0;
  border-radius: 10px;
  padding: 8px 10px;
  background: #fff;
}

.admin-media-order {
  display: grid;
  gap: 8px;
}

.admin-media-order .admin-place-form {
  display: grid;
  gap: 6px;
}

.admin-media-order .admin-place-form select {
  min-width: 0;
  max-width: none;
  width: 100%;
}

.admin-hero-add {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
  margin: 16px 0 8px;
  padding: 12px;
  background: #f6faf8;
  border-radius: 14px;
}

.admin-hero-add select {
  min-width: 220px;
  border: 1px solid #d9e4e0;
  border-radius: 10px;
  padding: 8px 10px;
  background: #fff;
}

.admin-hero-add select:disabled,
.admin-hero-add button:disabled {
  opacity: 0.55;
  cursor: default;
}

.admin-grid-cols__opt.is-disabled,
.admin-grid-cols__opt:has(input:disabled) {
  opacity: 0.45;
  cursor: default;
}

.admin-offers-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.admin-offers-card {
  position: relative;
  display: grid;
  gap: 8px;
  justify-items: stretch;
  padding: 12px;
  border: 1px solid #e6eeeb;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(31, 45, 42, 0.05);
}

.admin-offers-card img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 12px;
  background: #f4f4f4;
}

.admin-offers-card > strong {
  font-size: 0.88rem;
  line-height: 1.45;
}

.admin-offers-card__pos {
  position: absolute;
  top: 18px;
  left: 18px;
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  border-radius: 999px;
  background: #1f2d2a;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.admin-offers-swap {
  display: grid;
  gap: 8px;
}

.admin-offers-swap label {
  display: grid;
  gap: 4px;
  margin: 0;
}

.admin-offers-swap label span {
  font-size: 0.78rem;
  font-weight: 800;
  color: #3f5c55;
}

.admin-offers-swap select {
  width: 100%;
  border: 1px solid #d9e4e0;
  border-radius: 10px;
  padding: 8px 10px;
  background: #fff;
  font: inherit;
}

@media (max-width: 980px) {
  .admin-offers-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .admin-offers-grid {
    grid-template-columns: 1fr;
  }
}

.admin-grid-add {
  margin-top: 0;
}

.admin-grid-cols {
  display: grid;
  gap: 12px;
  margin: 0 0 18px;
  padding: 14px;
  background: #f6faf8;
  border-radius: 16px;
}

.admin-grid-cols__label {
  margin: 0;
  font-weight: 800;
  color: #1f2d2a;
}

.admin-grid-cols__opts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 8px;
}

.admin-grid-cols__opt {
  display: grid;
  justify-items: center;
  gap: 2px;
  margin: 0;
  padding: 10px 8px;
  border: 1px solid #d7e0de;
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
  text-align: center;
}

.admin-grid-cols__opt input {
  margin: 0 0 4px;
}

.admin-grid-cols__opt strong {
  font-size: 1.15rem;
  line-height: 1;
}

.admin-grid-cols__opt span {
  font-size: 0.72rem;
  color: #667874;
}

.admin-grid-cols__opt:has(input:checked) {
  border-color: #1f8f69;
  background: #f3faf7;
  box-shadow: 0 0 0 3px rgba(31, 143, 105, 0.14);
}

.admin-grid-cols__opt.is-recommended:has(input:checked),
.admin-grid-cols__opt.is-recommended {
  position: relative;
}

.admin-grid-cols button {
  justify-self: start;
  width: auto;
  min-width: 180px;
}

.admin-subhead {
  margin: 18px 0 10px;
  font-size: 1rem;
}

.admin-order-btns {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.admin-order-btns--row {
  flex-direction: row;
  justify-content: center;
  gap: 8px;
}

.admin-order-btn {
  width: 40px;
  height: 36px;
  border: 1px solid #d7e0de;
  border-radius: 10px;
  background: #fff;
  color: #1f2d2a;
  cursor: pointer;
  display: inline-grid;
  place-items: center;
  line-height: 1;
  padding: 0;
}

.admin-order-btn:hover:not(:disabled) {
  border-color: #1f8f69;
  color: #1f8f69;
  background: #f3faf7;
}

.admin-order-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.admin-spec-rows {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
}

.admin-spec-row {
  display: grid;
  grid-template-columns: 0.9fr 1.4fr;
  gap: 8px;
}

.admin-spec-row input {
  width: 100%;
  border: 1px solid #d9e4e0;
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  background: #fbfdfc;
}

#add-spec-btn {
  margin-bottom: 16px;
}

.admin-checks {
  border: 1px solid #e6eeeb;
  border-radius: 14px;
  padding: 12px;
  margin: 12px 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
  background: #f8fbfa;
}

.admin-checks legend {
  padding: 0 6px;
  font-weight: 700;
}

.admin-checks label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
}

.admin-hint {
  color: #667874;
  margin: 0 0 12px;
}

.admin-logo-box {
  display: grid;
  grid-template-columns: minmax(240px, 340px) minmax(240px, 1fr);
  gap: 18px;
  align-items: stretch;
}

.admin-logo-box__preview {
  display: grid;
  place-items: center;
  min-height: 140px;
  padding: 22px 28px;
  border-radius: 16px;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.06), transparent 45%),
    #1a2422;
}

.admin-logo-preview {
  max-width: min(280px, 100%);
  max-height: 84px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.admin-logo-box__form {
  display: grid;
  gap: 10px;
  align-content: center;
}

.admin-logo-box__form .admin-hint {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.6;
}

.admin-media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}

.admin-media-card {
  border: 1px solid #e6eeeb;
  border-radius: 20px;
  padding: 16px 14px 14px;
  display: grid;
  gap: 10px;
  justify-items: center;
  background: #fff;
  box-shadow: 0 8px 22px rgba(31, 45, 42, 0.05);
}

.admin-media-card img {
  width: 100%;
  height: 110px;
  object-fit: cover;
  border-radius: 12px;
  background: #f4f4f4;
}

.admin-media-card > strong {
  text-align: center;
  font-size: 0.92rem;
  line-height: 1.4;
}

.admin-media-card__head {
  width: 100%;
  text-align: center;
}

.admin-media-card__preview {
  position: relative;
  margin: 4px 0 2px;
}

.admin-media-card__round {
  width: 108px !important;
  height: 108px !important;
  border-radius: 50% !important;
  margin: 0 auto;
  box-shadow: 0 10px 18px rgba(31, 45, 42, 0.12);
}

.admin-media-card__pos {
  position: absolute;
  left: 0;
  bottom: 4px;
  min-width: 24px;
  height: 24px;
  padding: 0 6px;
  border-radius: 999px;
  background: #1f8f69;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.admin-media-card form {
  display: grid;
  gap: 8px;
  width: 100%;
}

.admin-media-card .admin-media-order {
  width: 100%;
}

.admin-media-upload {
  width: 100%;
}

.admin-hero-form {
  margin-top: 4px;
  padding-top: 10px;
  border-top: 1px dashed #d9e4e0;
}

.admin-hero-form .checkout-field {
  gap: 4px;
}

.admin-hero-form .checkout-field span {
  font-size: 0.78rem;
}

.admin-hero-form input[dir="ltr"] {
  text-align: left;
  font-family: ui-monospace, Consolas, monospace;
  font-size: 0.8rem;
}

.admin-file {
  position: relative;
  display: grid;
  cursor: pointer;
}

.admin-file input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.admin-file span {
  display: block;
  text-align: center;
  border: 1px dashed #c5d6d0;
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #3f5c55;
  background: #f6faf8;
}

.admin-file:hover span {
  border-color: #1f8f69;
  color: #1f8f69;
}

.admin-file.is-picked span {
  border-style: solid;
  border-color: #1f8f69;
  color: #136b4f;
  background: #f3faf7;
  overflow-wrap: anywhere;
}

.admin-media-btn {
  width: 100%;
  border: 0;
  border-radius: 12px;
  padding: 10px 12px;
  background: #eef4f2;
  color: #1f2d2a;
  font: inherit;
  font-weight: 800;
  font-size: 0.86rem;
  cursor: pointer;
}

.admin-media-btn:hover {
  background: #e2ece8;
}

.admin-media-btn--primary {
  background: #1f8f69;
  color: #fff;
}

.admin-media-btn--primary:hover {
  background: #17805f;
}

.page-admin .auth-alert {
  border-radius: 14px;
}

.admin-review-board {
  display: grid;
  gap: 16px;
}

.admin-review-card {
  background: #fff;
  border: 1px solid rgba(31, 45, 42, 0.07);
  border-radius: 22px;
  padding: 16px;
  box-shadow: 0 12px 30px rgba(31, 45, 42, 0.06);
  display: grid;
  gap: 14px;
}

.admin-review-card.is-open {
  box-shadow: 0 16px 32px rgba(194, 65, 12, 0.08);
  border-color: rgba(194, 65, 12, 0.16);
}

.admin-review-card__product {
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-review-card__product img {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 14px;
  background: #f4f4f4;
}

.admin-review-card__product a {
  font-weight: 800;
  color: #1f2d2a;
  text-decoration: none;
}

.admin-review-card__product a:hover {
  color: #1f8f69;
}

.admin-review-card__product p {
  margin: 4px 0 0;
  color: #7a8b86;
  font-size: 0.8rem;
}

.admin-review-reply {
  display: grid;
  gap: 8px;
}

.admin-review-reply label span {
  display: block;
  font-size: 0.8rem;
  font-weight: 800;
  margin-bottom: 6px;
  color: #3f5c55;
}

.admin-review-reply textarea {
  width: 100%;
  border: 1px solid #d9e4e0;
  border-radius: 14px;
  padding: 10px 12px;
  font: inherit;
  background: #fbfdfc;
  resize: vertical;
  min-height: 84px;
}

.admin-review-reply textarea:focus {
  outline: none;
  border-color: #1f8f69;
  box-shadow: 0 0 0 3px rgba(31, 143, 105, 0.14);
  background: #fff;
}

.admin-review-reply__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.admin-review-reply__actions .admin-media-btn {
  width: auto;
  min-width: 140px;
}

@media (max-width: 720px) {
  .review-reply {
    margin-right: 12px;
  }

  .admin-logo-box {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .admin-shell {
    grid-template-columns: 1fr;
  }

  .admin-side {
    position: sticky;
    top: 0;
    z-index: 40;
    height: auto;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
  }

  .admin-side__brand {
    margin: 0 4px 4px;
    padding: 0 0 8px;
  }

  .admin-side__nav {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    width: 100%;
    gap: 6px;
    padding-bottom: 4px;
  }

  .admin-side__label {
    display: none;
  }

  .admin-side__link {
    white-space: nowrap;
    flex-shrink: 0;
  }

  .admin-side__foot {
    width: 100%;
    border: 0;
    padding: 4px 4px 0;
  }

  .admin-main {
    padding: 18px 14px 36px;
  }

  .admin-meta {
    grid-template-columns: 1fr;
  }
}

/* ========== Responsive system (storefront) ========== */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.14);
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  font-size: 13px;
}

.nav-toggle__bars {
  width: 18px;
  height: 12px;
  display: inline-block;
  background:
    linear-gradient(#fff, #fff) 0 0 / 100% 2px no-repeat,
    linear-gradient(#fff, #fff) 0 5px / 100% 2px no-repeat,
    linear-gradient(#fff, #fff) 0 10px / 100% 2px no-repeat;
}

.nav-drawer {
  position: fixed;
  inset: 0;
  z-index: 2200;
  pointer-events: none;
}

.nav-drawer:not([hidden]) {
  pointer-events: auto;
}

.nav-drawer__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(20, 32, 28, 0.48);
  cursor: pointer;
}

.nav-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(360px, 78vw);
  max-width: calc(100vw - 56px);
  height: 100%;
  background: #fff;
  border-radius: 16px 0 0 16px;
  box-shadow: -12px 0 40px rgba(0, 0, 0, 0.18);
  display: flex;
  flex-direction: column;
  transform: translateX(104%);
  transition: transform 0.28s var(--ease-out);
  padding-top: env(safe-area-inset-top, 0);
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.nav-drawer.is-open .nav-drawer__panel {
  transform: translateX(0);
}

.nav-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 12px;
  border-bottom: 1px solid var(--line);
}

.nav-drawer__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 900;
}

.nav-drawer__close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: var(--panel);
  color: var(--ink);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.nav-drawer__nav {
  overflow: auto;
  flex: 1;
  padding: 8px 0 24px;
  -webkit-overflow-scrolling: touch;
}

.nav-drawer__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-drawer__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 18px;
  border: 0;
  border-bottom: 1px solid rgba(31, 45, 42, 0.06);
  background: transparent;
  color: var(--ink);
  text-decoration: none;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 800;
  text-align: right;
  cursor: pointer;
}

.nav-drawer__link.is-current,
.nav-drawer__link:hover {
  color: var(--green);
  background: rgba(31, 143, 105, 0.06);
}

.nav-drawer__extras {
  display: grid;
  gap: 4px;
  margin-top: 12px;
  padding: 12px 18px 0;
  border-top: 1px solid var(--line);
}

.nav-drawer__extras a {
  padding: 10px 0;
  color: var(--muted);
  font-weight: 700;
  text-decoration: none;
}

.nav-drawer__extras a:hover {
  color: var(--green);
}

body.nav-drawer-open,
html.search-open,
html.search-open body {
  overflow: hidden;
  overscroll-behavior: none;
}

@media (max-width: 1100px) {
  .grid-cats,
  .grid-cats[data-cols="5"],
  .grid-cats[data-cols="6"],
  .grid-cats[data-cols="7"],
  .grid-cats[data-cols="8"] {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .bar-top {
    padding: 14px 0;
  }

  .bar-top__grid {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px 12px;
  }

  .nav-toggle {
    display: inline-flex;
    width: 46px;
    height: 46px;
    padding: 0;
    justify-content: center;
    grid-column: 1;
    grid-row: 1;
  }

  .nav-toggle__label {
    display: none;
  }

  .bar-top__brand {
    grid-column: 2;
    grid-row: 1;
    justify-self: center;
  }

  .logo__sub {
    display: none;
  }

  .logo__img {
    width: auto;
    height: 56px;
  }

  .bar-top__actions {
    grid-column: 3;
    grid-row: 1;
    flex-wrap: nowrap;
    gap: 6px;
    justify-content: flex-start;
  }

  .bar-top__search {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    inset-inline: 0;
    z-index: 40;
    display: flex;
    align-items: center;
    width: auto;
    margin: 0;
    padding: 10px 12px 12px;
    background: linear-gradient(180deg, #3d6b60 0%, var(--mint-deep) 100%);
    box-shadow: 0 12px 24px rgba(20, 32, 28, 0.18);
    justify-content: stretch;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
  }

  .bar-top__search.is-open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
  }

  .bar-top__search .search-field {
    max-width: none;
  }

  .bar-top__search .search-field:focus-within {
    transform: none;
  }

  .bar-top__search-toggle {
    display: inline-flex !important;
    width: 46px;
    height: 46px;
  }

  .bar-top__icon-btn {
    width: 46px;
    height: 46px;
  }

  .nav-main[data-nav-desktop] {
    display: none;
  }

  .bar-top__link-secondary,
  .bar-top__compare,
  .cart-mini__total,
  .bar-top__account-text,
  .bar-top__account-name,
  .bar-top__account-dot {
    display: none;
  }

  .bar-top__account-icon {
    display: inline-flex;
  }

  .cart-mini,
  .bar-top__account,
  .bar-top__account--in {
    width: 46px;
    height: 46px;
    padding: 0;
    border-radius: 12px;
    justify-content: center;
    gap: 0;
  }

  .cart-mini__count {
    position: absolute;
    top: -4px;
    inset-inline-end: -4px;
    min-width: 16px;
    height: 16px;
    font-size: 10px;
    padding: 0 4px;
  }

  .cart-mini {
    position: relative;
  }

  .cart-mini__img--empty,
  .cart-mini__img--full {
    width: 24px;
    height: 24px;
  }
}

@media (max-width: 900px) {
  .cart-mini {
    padding: 0;
  }

  .grid-cats,
  .grid-cats[data-cols="4"],
  .grid-cats[data-cols="5"],
  .grid-cats[data-cols="6"],
  .grid-cats[data-cols="7"],
  .grid-cats[data-cols="8"] {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  .hero-arrow {
    width: 36px;
    height: 36px;
  }

  .product-purchase__row {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-end;
  }

  .product-purchase__submit,
  .product-purchase .btn-brown {
    width: auto;
    flex: 1 1 140px;
    min-height: 42px;
    padding: 10px 14px;
    font-size: 0.84rem;
  }

  .shop-sidebar {
    position: static;
  }

  .shop-filters {
    display: grid;
    gap: 10px;
  }
}

@media (max-width: 820px) {
  .hero-arrow {
    display: flex;
    opacity: 0.92;
  }

  .hero-card {
    min-height: 200px;
  }

  .hero-card__body h3 {
    font-size: 1.05rem;
  }
}

@media (max-width: 768px) {
  .wrap {
    padding-inline: 14px;
  }

  .p-grid,
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .oos-ribbon {
    width: 112px;
    top: 10px;
    right: -38px;
    padding: 6px 0;
  }

  .oos-ribbon__text {
    font-size: 10px;
  }

  .cart-layout {
    grid-template-columns: 1fr;
  }

  /* کارت‌شدن جدول سبد از تبلت */
  .cart-table thead {
    display: none;
  }

  .cart-table,
  .cart-table tbody,
  .cart-table tr,
  .cart-table td {
    display: block;
    width: 100%;
  }

  .cart-table__row {
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
  }

  .cart-table td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border: 0;
  }

  .cart-table td::before {
    content: attr(data-label);
    font-weight: 700;
    color: var(--muted);
    font-size: 0.82rem;
  }

  .cart-table__product {
    display: block;
  }

  .cart-table__product::before {
    display: none;
  }

  .fab {
    bottom: calc(18px + env(safe-area-inset-bottom, 0px));
    right: 14px;
    width: 52px;
    height: 52px;
  }

  body.has-product-sticky .fab {
    bottom: calc(86px + env(safe-area-inset-bottom, 0px));
  }

  body.has-product-sticky {
    padding-bottom: calc(92px + env(safe-area-inset-bottom, 0px));
  }

  .product-sticky {
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }

  .product-sticky__title {
    max-width: 42vw;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .bar-top {
    padding: 10px 0;
  }

  .bar-top__grid {
    gap: 10px;
  }

  .logo__img {
    height: 34px;
    max-width: min(160px, 42vw);
  }

  .logo__sub {
    display: none;
  }

  .search-field {
    height: 42px;
    padding: 0 12px;
  }

  .grid-cats,
  .grid-cats[data-cols="4"],
  .grid-cats[data-cols="5"],
  .grid-cats[data-cols="6"],
  .grid-cats[data-cols="7"],
  .grid-cats[data-cols="8"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 20px;
  }

  .cat-cell .lbl {
    font-size: 12px;
  }

  .hero-card {
    min-height: 180px;
  }

  .hero-pill {
    font-size: 12px;
    padding: 8px 12px;
  }

  .block-white {
    padding: 16px 12px;
  }

  .p-card__tools {
    top: 8px;
    left: 8px;
    gap: 4px;
  }

  .p-card__tool {
    width: 30px;
    height: 30px;
  }

  .btn-brown,
  .oos-cta {
    font-size: 11px;
    padding: 9px 8px;
  }

  .product-layout {
    padding: 14px;
  }

  .product-gallery__nav {
    width: 34px;
    height: 34px;
  }

  .checkout-form__submit {
    white-space: normal;
    line-height: 1.35;
  }
}

@media (max-width: 480px) {
  .wrap {
    padding-inline: 12px;
  }

  .bar-top__account-name {
    display: none;
  }

  .bar-top__account.bar-top__account--in {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: inline-grid;
    place-items: center;
    padding: 0;
    overflow: hidden;
  }

  .bar-top__account:not(.bar-top__account--in) {
    font-size: 12px;
    padding: 8px 10px;
  }

  .bar-top__account-dot {
    width: 10px;
    height: 10px;
  }

  .bar-top__compare {
    display: none;
  }

  .p-grid,
  .grid-4 {
    gap: 8px;
  }

  .card-offer__media img,
  .p-card img {
    max-height: 160px !important;
  }

  .card-offer__body {
    text-align: center !important;
  }

  .card-offer__price strong {
    color: #000 !important;
  }

  .oos-ribbon {
    width: 100px;
    top: 8px;
    right: -40px;
  }

  .product-sticky__info img {
    width: 40px;
    height: 40px;
  }

}

@media (max-width: 360px) {
  .p-grid,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .nav-toggle__label {
    display: none;
  }
}

/* Override older single-column jumps that fought tablet layouts */
@media (max-width: 520px) {
  .p-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 360px) {
  .p-grid,
  .grid-4 {
    grid-template-columns: 1fr;
  }
}

.app-tabbar {
  display: none;
}

@media (max-width: 1100px) {
  .app-tabbar {
    display: flex;
    position: fixed;
    right: 0;
    left: 0;
    bottom: 0;
    z-index: 1900;
    align-items: stretch;
    justify-content: space-around;
    gap: 2px;
    padding: 8px 6px calc(8px + env(safe-area-inset-bottom, 0px));
    background: linear-gradient(180deg, var(--mint) 0%, var(--mint-deep) 58%, #3d6b60 100%);
    color: #fff;
    border-radius: 22px 22px 0 0;
    box-shadow: 0 -10px 28px rgba(31, 45, 42, 0.22);
  }

  .app-tabbar__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    padding: 6px 2px 4px;
    border: 0;
    background: transparent;
    color: #fff;
    text-decoration: none;
    font: inherit;
    font-size: 11px;
    font-weight: 800;
    line-height: 1.2;
    cursor: pointer;
    border-radius: 14px;
  }

  .app-tabbar__item svg {
    display: block;
    width: 22px;
    height: 22px;
  }

  .app-tabbar__icon {
    position: relative;
    display: inline-flex;
  }

  .app-tabbar__badge {
    position: absolute;
    top: -6px;
    inset-inline-start: -8px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 99px;
    background: var(--orange);
    color: #fff;
    font-size: 10px;
    font-weight: 900;
    line-height: 16px;
    text-align: center;
  }

  .app-tabbar__badge.is-hidden {
    display: none;
  }

  .app-tabbar__item.is-active {
    background: rgba(255, 255, 255, 0.16);
    color: var(--yellow);
  }

  .app-tabbar__item.is-active svg {
    color: var(--yellow);
  }

  body {
    padding-bottom: calc(78px + env(safe-area-inset-bottom, 0px));
  }

  .fab {
    bottom: calc(86px + env(safe-area-inset-bottom, 0px)) !important;
  }

  body.has-product-sticky .fab {
    bottom: calc(158px + env(safe-area-inset-bottom, 0px)) !important;
  }

  body.has-product-sticky {
    padding-bottom: calc(150px + env(safe-area-inset-bottom, 0px));
  }

  .product-sticky__submit {
    width: auto;
    min-width: 0;
    margin-top: 0;
    padding: 8px 12px;
    font-size: 12px;
    line-height: 1.3;
    white-space: nowrap;
    flex: 0 1 auto;
  }

  body.is-story-open .app-tabbar,
  body.page-proforma .app-tabbar {
    display: none;
  }

  body.is-story-open,
  body.page-proforma {
    padding-bottom: 0;
  }
}

/* ——— PRODUCT IMAGE FIX ——— */
.product-layout__gallery[data-product-gallery], .product-gallery__stage, .product-gallery__main { width: 100% !important; }
.product-gallery__main[data-gallery-open] { width: 100% !important; overflow: hidden !important; position: relative !important; display: block !important; }
.product-gallery__main[data-gallery-open] img, .product-layout__gallery img[data-product-image], .p-card img, .card-offer__media img, .p-card__media img, .product-gallery__thumb img { width: 100% !important; height: 100% !important; object-fit: fill !important; display: block !important; }
/* ——— END FIX ——— */

/* ===== Custom galleries (admin-defined image sections) ===== */
.product-custom-galleries {
  margin: 16px 0 18px;
  padding: 14px 16px;
  border: 1px solid #c8e6dd;
  border-radius: 14px;
  background: linear-gradient(135deg, #f0faf6 0%, #e8f5ef 100%);
  box-shadow: 0 4px 18px rgba(31, 143, 105, 0.06);
  animation: cgFadeIn 0.45s ease both;
}
.product-custom-galleries__label {
  display: block;
  font-size: 0.86rem;
  font-weight: 800;
  color: #1f8f69;
  margin-bottom: 10px;
  letter-spacing: 0.2px;
}
.product-custom-galleries__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.product-gallery-switch-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #1f8f69;
  background: #fff;
  border: 1.5px solid #c8e6dd;
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.25s ease, background 0.25s ease, border-color 0.25s ease, transform 0.18s ease, box-shadow 0.25s ease;
  box-shadow: 0 1px 2px rgba(31, 143, 105, 0.05);
}
.product-gallery-switch-btn::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.4;
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.product-gallery-switch-btn:hover {
  color: #157c58;
  background: #f0faf6;
  border-color: #2aa57b;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(31, 143, 105, 0.14);
}
.product-gallery-switch-btn:hover::before {
  opacity: 0.7;
  transform: scale(1.3);
}
.product-gallery-switch-btn:active {
  transform: translateY(0) scale(0.97);
}
.product-gallery-switch-btn.is-active {
  color: #fff;
  background: linear-gradient(135deg, #2aa57b 0%, #1f8f69 100%);
  border-color: #1f8f69;
  box-shadow: 0 6px 16px rgba(31, 143, 105, 0.32);
}
.product-gallery-switch-btn.is-active::before {
  background: #fff;
  opacity: 1;
  animation: cgPulse 1.6s ease-in-out infinite;
}
/* fade transition for the main image when switching galleries */
.product-gallery__main img.is-switching {
  animation: cgImgSwap 0.34s ease;
}
@keyframes cgFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes cgImgSwap {
  0% { opacity: 0.25; transform: scale(0.985); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes cgPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.75; }
}
/* low-stock badge (only shown when stock <= 3) */
.product-stock--low {
  color: #c0392b;
  background: rgba(192, 57, 43, 0.10);
  border-color: rgba(192, 57, 43, 0.22);
  animation: cgFadeIn 0.4s ease both;
}
.product-stock--low .product-stock__dot {
  background: #e74c3c;
  box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.20);
  animation: cgPulse 1.4s ease-in-out infinite;
}

/* ===== Round 2: gallery button image counter + admin drag&drop ===== */
.product-gallery-switch-btn__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 18px;
  margin-inline-start: 6px;
  padding: 0 5px;
  border-radius: 9px;
  font-size: 0.68rem;
  font-weight: 800;
  background: rgba(255,255,255,0.55);
  color: inherit;
  transition: background 0.25s ease, color 0.25s ease;
}
.product-gallery-switch-btn:not(.is-active) .product-gallery-switch-btn__count {
  background: rgba(31,143,105,0.08);
  color: #1f8f69;
}
.product-gallery-switch-btn.is-active .product-gallery-switch-btn__count {
  background: rgba(255,255,255,0.25);
  color: #fff;
}

.product-gallery-switch-btn__code {
  display: inline-flex;
  align-items: center;
  margin-inline-start: 2px;
  padding: 2px 5px;
  border-radius: 6px;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  background: rgba(31,143,105,0.08);
  color: inherit;
}

.product-gallery-switch-btn.is-active .product-gallery-switch-btn__code {
  background: rgba(255,255,255,0.2);
}

/* admin: drag handle hover */
.cg-drag-handle {
  transition: color 0.2s ease, transform 0.2s ease;
}
.cg-drag-handle:hover {
  color: #b98a4e !important;
  transform: scale(1.15);
}
.admin-custom-gallery-item.cg-dragging {
  opacity: 0.5;
  transform: scale(0.98);
  box-shadow: 0 8px 24px rgba(120,90,40,0.25);
}
.admin-custom-gallery-item.cg-drag-over {
  border-color: #b98a4e !important;
  box-shadow: 0 0 0 3px rgba(185,138,78,0.18);
}
.admin-custom-gallery-item {
  transition: opacity 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

/* per-image remove button hover */
.cg-img-remove:hover {
  background: #c0392b !important;
  transform: scale(1.15);
}
.cg-img-remove {
  transition: transform 0.18s ease, background 0.18s ease;
}
.cg-existing-img {
  transition: transform 0.18s ease;
}
.cg-existing-img:hover {
  transform: translateY(-2px);
}

/* main image switch animation (keep in sync with product.php) */
.product-gallery__main img.is-switching {
  animation: cgImgSwap 0.34s ease;
}

/* ===== Round 3: keyboard hint + hover-zoom ===== */
.product-custom-galleries__hint {
  display: block;
  margin-top: 8px;
  font-size: 0.72rem;
  color: #2aa57b;
  opacity: 0.85;
  transition: opacity 0.25s ease;
}
.product-custom-galleries:hover .product-custom-galleries__hint { opacity: 1; }

/* ===== Round 5: quantity feedback ===== */
.product-qty-feedback {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 700;
  animation: cgFadeIn 0.3s ease both;
}
.product-qty-feedback--warn {
  color: #c0392b;
  background: rgba(192, 57, 43, 0.10);
  border: 1px solid rgba(192, 57, 43, 0.22);
}
.product-qty-feedback--ok {
  color: var(--green);
  background: rgba(31, 143, 105, 0.10);
  border: 1px solid rgba(31, 143, 105, 0.16);
}
.product-qty__input:invalid {
  border-color: #c0392b;
}
/* thumbnail focus ring for keyboard nav */
.product-gallery__thumb:focus-visible {
  outline: 3px solid #b98a4e;
  outline-offset: 2px;
}

/* ===== Round 6: wishlist heart animation + copy-link toast ===== */
.product-wishlist-btn__heart {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.25s ease;
  transform-origin: center;
}
.product-wishlist-btn:not(.is-active) .product-wishlist-btn__heart {
  color: #999;
  fill: transparent;
}
.product-wishlist-btn.is-active .product-wishlist-btn__heart {
  color: #e74c3c;
  fill: #e74c3c;
}
.product-wishlist-btn:hover .product-wishlist-btn__heart {
  transform: scale(1.2);
}
.product-wishlist-btn.is-pulsing .product-wishlist-btn__heart {
  animation: cgHeartPulse 0.5s ease;
}
@keyframes cgHeartPulse {
  0% { transform: scale(1); }
  35% { transform: scale(1.45); }
  65% { transform: scale(0.85); }
  100% { transform: scale(1); }
}

/* copy-link share button — same size as WhatsApp/Telegram */
.product-share__btn--copy {
  cursor: pointer;
  background: rgba(107, 122, 137, 0.14);
  color: #566573;
  border: none;
}
.product-share__btn--copy:hover {
  background: rgba(107, 122, 137, 0.22);
  transform: translateY(-1px);
}
.product-share__toast {
  display: none;
}
.product-share__toast:not([hidden]) {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(31, 143, 105, 0.12);
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 700;
  border: 1px solid rgba(31, 143, 105, 0.22);
  animation: cgFadeIn 0.3s ease both;
}

/* ===== Round 7: rating distribution + animated stars ===== */
.review-board__dist {
  display: flex;
  gap: 24px;
  padding: 16px;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #fffdf8 0%, #faf5ec 100%);
  border: 1px solid #ece7df;
  border-radius: 14px;
  align-items: center;
  flex-wrap: wrap;
}
.review-board__dist-score {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 90px;
}
.review-board__dist-num {
  font-size: 2rem;
  font-weight: 900;
  color: #b98a4e;
  line-height: 1;
}
.review-board__dist-count {
  font-size: 0.78rem;
  color: #9a8a6a;
}
.review-board__dist-bars {
  flex: 1;
  min-width: 200px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.review-board__dist-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
}
.review-board__dist-label {
  width: 14px;
  font-weight: 700;
  color: #6b5836;
}
.review-board__dist-star {
  color: #d4a64a;
  font-size: 0.85rem;
}
.review-board__dist-track {
  flex: 1;
  height: 8px;
  background: rgba(212, 166, 74, 0.15);
  border-radius: 4px;
  overflow: hidden;
}
.review-board__dist-fill {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #d4a64a, #b98a4e);
  border-radius: 4px;
  animation: cgBarGrow 0.9s ease-out both;
  transform-origin: right;
}
.review-board__dist-pct {
  width: 32px;
  text-align: left;
  color: #9a8a6a;
  font-weight: 600;
}
@keyframes cgBarGrow {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}
/* animated stars pop-in */
.product-stars--readonly span {
  animation: cgStarPop 0.4s ease both;
}
.product-stars--readonly span:nth-child(1) { animation-delay: 0s; }
.product-stars--readonly span:nth-child(2) { animation-delay: 0.08s; }
.product-stars--readonly span:nth-child(3) { animation-delay: 0.16s; }
.product-stars--readonly span:nth-child(4) { animation-delay: 0.24s; }
.product-stars--readonly span:nth-child(5) { animation-delay: 0.32s; }
@keyframes cgStarPop {
  0% { transform: scale(0); opacity: 0; }
  60% { transform: scale(1.25); }
  100% { transform: scale(1); opacity: 1; }
}

/* ===== Round 8: mini-cart badge ===== */
/* mini-cart floating badge (Round 8) */
.mini-cart-badge {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, #b98a4e 0%, #9c6f33 100%);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  box-shadow: 0 8px 24px rgba(156, 111, 51, 0.4);
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  animation: cgFadeIn 0.4s ease both;
}
.mini-cart-badge:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 12px 28px rgba(156, 111, 51, 0.5);
}
.mini-cart-badge__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #fff;
  color: #9c6f33;
  font-size: 0.72rem;
  font-weight: 800;
}
.mini-cart-badge__count.is-bump {
  animation: cgBump 0.4s ease;
}
@keyframes cgBump {
  0% { transform: scale(1); }
  50% { transform: scale(1.35); }
  100% { transform: scale(1); }
}

/* ===== Round 9: price animation + swipe hint ===== */
[data-product-price-current].is-animating {
  animation: cgPriceBlink 0.45s ease;
}
@keyframes cgPriceBlink {
  0% { transform: scale(1); color: inherit; }
  40% { transform: scale(1.06); color: #b98a4e; }
  100% { transform: scale(1); color: inherit; }
}
/* subtle swipe hint on touch devices */
@media (hover: none) and (pointer: coarse) {
  .product-gallery__main::after {
    content: '← بکشید →';
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 12px;
    border-radius: 999px;
    background: rgba(0,0,0,0.5);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    pointer-events: none;
    opacity: 0.7;
    animation: cgSwipeHint 2.5s ease-in-out infinite;
    z-index: 4;
  }
}
@keyframes cgSwipeHint {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 0.9; }
}

/* ===== Round 10: long-press feedback ===== */
/* long-press active state */
.product-qty__btn:active {
  transform: scale(0.92);
  background: rgba(185, 138, 78, 0.15);
}
