/* ========== Base ========== */

header {}

/* ========== Preloader (مدرن) ========== */
#preloder.c-preloader {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-body, #f8f9fa);
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#preloder.c-preloader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.c-header--shopex .c-content-start li:hover .sub-menu {
  transition: 0.4s;
  opacity: 1;
  visibility: visible;
}

.c-header--shopex .c-content-start .sub-menu {
  position: absolute;
  background: #fff;
  padding: 10px 5px;
  width: 265px;
  top: 40px;
  z-index: 99;
  opacity: 0;
  visibility: hidden;
  border-radius: 4px;
  box-shadow: 0 0 10px 4px #efefef3d;
  transition: 0.4s;
}

.c-preloader__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
}

/* ─── استایل dots: سه نقطه + نوار ─── */
.c-preloader--dots .c-preloader__spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.c-preloader--dots .c-preloader__spinner span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--first-color, #0057ff);
  animation: c-preloader-bounce 1.4s ease-in-out infinite both;
}

.c-preloader--dots .c-preloader__spinner span:nth-child(1) {
  animation-delay: -0.32s;
}

.c-preloader--dots .c-preloader__spinner span:nth-child(2) {
  animation-delay: -0.16s;
}

.c-preloader--dots .c-preloader__spinner span:nth-child(3) {
  animation-delay: 0s;
}

@keyframes c-preloader-bounce {

  0%,
  80%,
  100% {
    transform: scale(0.75);
    opacity: 0.6;
  }

  40% {
    transform: scale(1.1);
    opacity: 1;
  }
}

.c-preloader--dots .c-preloader__progress {
  width: 80px;
  height: 3px;
  border-radius: 2px;
  background: rgba(0, 87, 255, 0.15);
  overflow: hidden;
}

.c-preloader--dots .c-preloader__progress::after {
  content: "";
  display: block;
  width: 35%;
  height: 100%;
  background: var(--first-color, #0057ff);
  border-radius: 2px;
  animation: c-preloader-progress 1.2s ease-in-out infinite;
}

@keyframes c-preloader-progress {
  0% {
    transform: translateX(-100%);
  }

  50% {
    transform: translateX(180%);
  }

  100% {
    transform: translateX(-100%);
  }
}

/* ─── استایل ring: حلقه چرخان ─── */
.c-preloader__ring {
  width: 48px;
  height: 48px;
  border: 3px solid rgba(0, 87, 255, 0.2);
  border-top-color: var(--first-color, #0057ff);
  border-radius: 50%;
  animation: c-preloader-spin 0.9s linear infinite;
}

@keyframes c-preloader-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ─── استایل pulse: دایره پالس ─── */
.c-preloader__pulse {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--first-color, #0057ff);
  animation: c-preloader-pulse 1.4s ease-in-out infinite;
}

@keyframes c-preloader-pulse {

  0%,
  100% {
    transform: scale(0.85);
    opacity: 0.7;
  }

  50% {
    transform: scale(1.15);
    opacity: 1;
  }
}

/* ─── استایل bars: نوارهای عمودی ─── */
.c-preloader__bars {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 36px;
}

.c-preloader__bars span {
  width: 6px;
  min-height: 8px;
  border-radius: 3px;
  background: var(--first-color, #0057ff);
  animation: c-preloader-bars 1s ease-in-out infinite;
}

.c-preloader__bars span:nth-child(1) {
  animation-delay: -0.2s;
}

.c-preloader__bars span:nth-child(2) {
  animation-delay: -0.1s;
}

.c-preloader__bars span:nth-child(3) {
  animation-delay: 0s;
}

.c-preloader__bars span:nth-child(4) {
  animation-delay: 0.1s;
}

.c-preloader__bars span:nth-child(5) {
  animation-delay: 0.2s;
}

@keyframes c-preloader-bars {

  0%,
  100% {
    height: 8px;
  }

  50% {
    height: 36px;
  }
}

/* ─── استایل minimal: خط نازک بالا ─── */
.c-preloader--minimal .c-preloader__inner {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  align-items: stretch;
  gap: 0;
}

.c-preloader__minimal-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(0, 87, 255, 0.2);
  overflow: hidden;
}

.c-preloader__minimal-bar::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 30%;
  background: var(--first-color, #0057ff);
  border-radius: 0 2px 2px 0;
  animation: c-preloader-minimal 1.4s ease-in-out infinite;
}

@keyframes c-preloader-minimal {
  0% {
    transform: translateX(-100%);
  }

  50% {
    transform: translateX(330%);
  }

  100% {
    transform: translateX(-100%);
  }
}

/* ========== Header: Comma ========== */
/* استایل‌های پایه از کد دوم (با پویایی رنگی) */
.c-header--comma .header {
  position: relative;
  margin-bottom: 40px;
}

.c-header--comma {
  position: relative;
  z-index: 100;
}

.c-header--comma .c-top-header {
  display: flex;
  justify-content: space-between;
  padding: 0 137px;
  align-items: center;
  height: 40px;
  background-color: var(--bg-notice);
}

.c-header--comma .c-top-header h6 {
  color: var(--text-notice);
  font-size: 18px;
  font-weight: 600;
}

.c-header--comma .c-top-header i {
  color: var(--icon-notice);
  font-size: x-large;
  transition: all 0.3s ease;
}

.c-header--comma .c-top-header i:hover {
  text-shadow: 1px 2px 4px var(--icon-notice);
  transform: scale(1.5);
}

.c-header--comma .header .org-nav {
  display: flex;
  background: var(--header-bg);
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.1);
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding: 12px 5rem;
  position: relative;
  backdrop-filter: blur(10px);
  z-index: 101;
}

.c-header--comma .header .org-nav .logo {
  transition: transform 0.3s ease;
}

.c-header--comma .header .org-nav .logo:hover {
  transform: scale(1.05);
}

.c-header--comma .header .org-nav .logo img {
  width: 60px;
  height: auto;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.c-header--comma .header .org-nav .btns,
.c-header--comma .header .org-nav .links ul {
  display: flex;
  align-items: center;
  position: relative;
}

.c-header--comma .header .org-nav .btns {
  gap: 10px;
}

.c-header--comma .header .org-nav .links ul li {
  position: relative;
}

.c-header--comma .org-nav .links ul li a {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 0 25px;
  color: var(--header-text);
  line-height: 1;
  height: 35px;
  font-weight: 500;
  transition: all 0.3s ease;
  text-decoration: none;
  border-radius: 8px;
}

.c-header--comma .org-nav .links ul li a:hover {
  color: var(--header-text-hover);
}

.c-header--comma .org-nav .links ul li:not(:last-child) a::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 22px;
  background: linear-gradient(to bottom,
      transparent,
      rgba(0, 0, 0, 0.12),
      transparent);
  border-radius: 1px;
}

/* ساب‌منوی دسکتاپ */
.c-header--comma .header .org-nav .links ul li .sub-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 240px;
  background: var(--submenu-bg);
  border-radius: 16px;
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px) scale(0.95);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow:
    rgba(60, 64, 67, 0.3) 0px 1px 2px 0px,
    rgba(60, 64, 67, 0.15) 0px 2px 6px 2px;
  z-index: 102;
  display: flex;
  flex-direction: column;
}

.c-header--comma .header .org-nav .links ul li.menu-item-has-children:hover .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  transition-delay: 0.05s;
}

.c-header--comma .header .org-nav .links ul li .sub-menu li {
  display: block;
  width: 100%;
  padding: 4px 12px;
  background: transparent;
  transition: all 0.25s ease;
  border-radius: 10px;
}

.c-header--comma .header .org-nav .links ul li .sub-menu li:last-child {
  border-bottom: none;
}

.c-header--comma .header .org-nav .links ul li .sub-menu li:hover {
  background: var(--submenu-hover);
}

.c-header--comma .header .org-nav .links ul li .sub-menu li a {
  display: block;
  padding: 8px 8px;
  color: var(--header-text);
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  white-space: nowrap;
  border-radius: 8px;
}

.c-header--comma .header .org-nav .links ul li .sub-menu li a::after,
.c-header--comma .header .org-nav .links ul li .sub-menu li a::before {
  display: none;
}

/* سبد خرید */
.c-header--comma .org-nav .btns .sabad {
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
  background: var(--sabad-bg);
  flex-shrink: 0;
}

.c-header--comma .org-nav .btns .sabad:hover {
  background: var(--sabad-bg-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px var(--sabad-bg-hover);
}

.c-header--comma .org-nav .btns .sabad svg {
  transition: transform 0.3s ease;
  width: 32px;
  height: 32px;
}

.c-header--comma .org-nav .btns .sabad svg path {
  stroke: var(--sabad-icon);
}

.c-header--comma .org-nav .btns .sabad:hover svg {
  transform: scale(1.4);
}

.c-header--comma .sabad span,
.c-header--comma .comma-mini-cart__count {
  background: var(--sabad-sp-color);
  color: var(--sabad-sp-num-color);
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 50%;
  position: absolute;
  top: -10px;
  right: -10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: bold;
  line-height: 1;
  box-shadow: 0 3px 8px var(--sabad-sp-color);
  animation: pulse-badge 2s infinite;
  z-index: 2;
}

.c-header--comma .comma-mini-cart__count[data-count="0"],
.c-header--comma .comma-mini-cart__count:empty {
  opacity: 0.85;
}

@keyframes pulse-badge {

  0%,
  100% {
    box-shadow: 0 3px 8px var(--sabad-sp-color);
  }

  50% {
    box-shadow: 0 3px 15px var(--sabad-sp-color);
  }
}

/* بخش کاربری دسکتاپ */
.c-header--comma .user-section {
  display: flex;
  align-items: center;
  gap: 10px;
}

.c-header--comma .user-section .user {
  position: relative;
}

.c-header--comma .user-section .user-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--user-text);
  border-radius: 10px;
  transition: all 0.3s ease;
  background: var(--user-bg);
  overflow: hidden;
  height: 48px;
}

.c-header--comma .user-section .user-link .user-name {
  margin: 0 12px 0 6px;
}

.c-header--comma .user-section .user-link:hover {
  background: var(--user-bg-hover);
  transform: translateY(-1px);
}

.c-header--comma .user-section .icon-panel {
  display: flex;
  align-items: center;
  color: var(--user-icon);
  border-radius: 8px;
  background: var(--user-icon-bg);
}

.c-header--comma .user-section .c-user-dashboard {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  background: var(--user-submenu-bg);
  border-radius: 16px;
  box-shadow:
    rgba(60, 64, 67, 0.3) 0px 1px 2px 0px,
    rgba(60, 64, 67, 0.15) 0px 2px 6px 2px;
  min-width: 200px;
  z-index: 102;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease,
    transform 0.3s ease;
  /* این تاخیر کوچیک باعث می‌شه موس فرصت داشته باشه از لینک به منو بره */
  transition-delay: 0.1s;
}

.c-header--comma .user-section .user:hover .c-user-dashboard {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition-delay: 0s;
}

/* این کلاس رو اضافه کن که منو وقتی موس روشه باز بمونه */
.c-header--comma .user-section .c-user-dashboard:hover {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.c-header--comma .user-section .c-user-dashboard span {
  display: block;
}

.c-header--comma .user-section .c-user-dashboard span a {
  display: block;
  padding: 10px 24px;
  color: var(--user-text);
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.c-header--comma .user-section .c-user-dashboard span a:hover {
  background-color: var(--user-submenu-hover);
  padding-right: 28px;
}

/* همبرگری */
.c-header--comma .mobile-menu-toggle,
.c-header--shopex .mobile-menu-toggle,
.c-header--digikala .mobile-menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 30px;
  height: 30px;
  cursor: pointer;
  padding: 4px;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.c-header--comma .mobile-menu-toggle span,
.c-header--shopex .mobile-menu-toggle span,
.c-header--digikala .mobile-menu-toggle span {
  display: block;
  height: 2.5px;
  width: 100%;
  background-color: #333;
  border-radius: 3px;
  transition: all 0.3s ease;
  transform-origin: center;
}

/* دراور موبایل */
.mobile-drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(3px);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s ease;
}

.mobile-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 280px;
  height: 100%;
  background: var(--submenu-bg);
  z-index: 1000;
  transform: translateX(100%);
  transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 24px;
  /* box-shadow: -5px 0 30px var(--submenu-shadow); */
}

.mobile-drawer.open {
  transform: translateX(0);
}

.mobile-drawer-overlay.open {
  opacity: 1;
  visibility: visible;
}

.drawer-close {
  text-align: left;
  font-size: 2.5rem;
  cursor: pointer;
  margin-bottom: 24px;
  display: inline-block;
  color: #666;
  transition: all 0.3s ease;
  line-height: 1;
}

.drawer-close:hover {
  color: var(--search-icon);
  transform: rotate(90deg);
}

.drawer-menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.drawer-menu li {
  margin: 8px 0;
}

.drawer-menu a {
  text-decoration: none;
  color: var(--header-text);
  font-size: 16px;
  padding: 10px 12px;
  display: block;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.drawer-menu a:hover {
  background: var(--submenu-hover);
}

.drawer-menu .menu-item-has-children {
  position: relative;
}

.drawer-menu .menu-item-has-children>a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  color: var(--header-text);
  transition: color 0.3s;
}

.drawer-menu .menu-item-has-children>a::after {
  content: "▼";
  font-size: 10px;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  margin-right: 10px;
  opacity: 0.5;
}

.drawer-menu .menu-item-has-children.open>a::after {
  transform: rotate(180deg);
}

.drawer-menu .menu-item-has-children.open>a {
  color: var(--header-text);
  background: var(--header-bg);
}

.drawer-menu .sub-menu {
  height: 0;
  overflow: hidden;
  padding-right: 24px;
  list-style: none;
  transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.drawer-menu .sub-menu a {
  font-size: 15px;
  color: var(--header-text);
}

.drawer-menu .menu-item-has-children.open .sub-menu {
  height: auto;
}

/* کانتینر عمودی برای btns و header-message */
.c-header--comma .header-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.c-header--comma .header-message {
  text-align: left;
}

/* ========== بخش وسط: جستجو + منو ========== */
.c-header--comma .nav-center {
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex: 1;
  margin: 0 20px;
}

/* ========== جستجوی دسکتاپ ========== */
.c-header--comma .header-search {
  width: 100%;
  max-width: 400px;
  margin-right: 24px;
}

.c-header--comma .header-search form {
  min-width: 450px;
}

.c-header--comma .header-search-results .ajax-search-results,
.c-header--comma .header-search-results .search-results--empty {
  padding: 10px;
}

.header-search-results .search-results-header .results-title {
  font-size: 18px;
  margin-bottom: 10px;
}

.search-results-list h5.result-title {
  font-size: 17px;
  margin-bottom: 5px;
}

.search-results-list .result-details {
  font-size: 15px;
}

.c-header--comma .search-input-wrapper,
.c-header--shopex .search-input-wrapper,
.c-header--digikala .search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.c-header--comma .search-input-wrapper input,
.c-header--shopex .search-input-wrapper input,
.c-header--digikala .search-input-wrapper input {
  width: 100%;
  padding: 10px 20px 10px 16px;
  border: 1.5px solid var(--search-border);
  border-radius: 15px;
  font-size: 14px;
  color: #333;
  background: var(--search-bg);
  transition: all 0.3s ease;
  outline: none;
  font-family: inherit;
}

.c-header--comma .search-input-wrapper input::placeholder,
.c-header--shopex .search-input-wrapper input::placeholder,
.c-header--digikala .search-input-wrapper input::placeholder {
  color: var(--header-text-secondary);
}

.c-header--comma .search-input-wrapper input:focus,
.c-header--shopex .search-input-wrapper input:focus,
.c-header--digikala .search-input-wrapper input:focus {
  border-color: var(--search-border);
  background: var(--search-bg-active);
  box-shadow: 0 0 0 4px var(--search-border);
}

.c-header--comma .search-input-wrapper button,
.c-header--shopex .search-input-wrapper button,
.c-header--digikala .search-input-wrapper button {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--search-icon);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.c-header--comma .search-input-wrapper input:focus+button,
.c-header--comma .search-input-wrapper button:hover,
.c-header--shopex .search-input-wrapper input:focus+button,
.c-header--shopex .search-input-wrapper button:hover,
.c-header--digikala .search-input-wrapper input:focus+button,
.c-header--digikala .search-input-wrapper button:hover {
  color: var(--search-icon);
}

/* ========== منوی دسکتاپ ========== */
.c-header--comma .header .org-nav .links ul {
  display: flex;
  align-items: center;
  position: relative;
}

/* کانتینر btns و header-message */
.c-header--comma .header-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  flex-shrink: 0;
}

.c-header--comma .header-message {
  text-align: left;
}

.c-header--comma .header-message .off-num {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: var(--message-text);
  background: var(--message-bg);
  padding: 6px 14px;
  border-radius: 10px;
  height: 35px;
  text-decoration: none;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.c-header--comma .header-message .off-num:hover {
  background: var(--message-bg-hover);
  transform: translateY(-1px);
}

/* جستجوی موبایل در دراور */
.c-header--comma .mobile-search,
.c-header--shopex .mobile-search,
.c-header--digikala .mobile-search {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(5, 62, 194, 0.1);
}

.c-header--comma .mobile-search .search-input-wrapper input,
.c-header--shopex .mobile-search .search-input-wrapper input,
.c-header--digikala .mobile-search .search-input-wrapper input {
  width: 100%;
  padding: 10px 20px 10px 14px;
  font-size: 14px;
}

/* ========== RESPONSIVE ========== */

@media (max-width: 1340px) {
  .c-header--comma .org-nav .links ul li a {
    padding: 0 17px;
  }
}

@media (max-width: 1230px) {
  .c-header--comma .header .org-nav {
    padding: 12px 3rem;
  }

  .c-header--comma .org-nav .links ul li a {
    padding: 0 15px;
  }
}

@media (max-width: 1166.36px) {
  .c-header--comma .header .org-nav {
    padding: 12px 2rem;
  }

  .c-header--comma .header .org-nav .logo img {
    width: 66px;
  }

  .c-header--comma .org-nav .links ul li a {
    padding: 0 11px;
  }
}

@media (max-width: 1076.36px) {
  .c-header--comma .header .org-nav {
    padding: 12px 1.8rem;
  }
}

@media (max-width: 1070px) {
  .c-header--comma .header .org-nav {
    padding: 12px 1.5rem;
    gap: 10px;
  }
}

@media (max-width: 1060px) {
  .c-header--comma .header .org-nav .logo img {
    width: 37px;
  }

  .c-header--comma .org-nav .btns .sabad {
    margin-top: 4px;
  }
}

@media (max-width: 1049.09px) {
  .c-header--comma .header .org-nav {
    padding: 12px 1rem;
  }
}

/* ========== Mobile/Tablet: زیر 1024px ========== */
@media screen and (max-width: 1024px) {

  /* مخفی کردن nav-center */
  .c-header--comma .nav-center {
    display: none;
  }

  /* مخفی کردن links در org-nav */
  .c-header--comma .header .org-nav .links {
    display: none;
  }

  /* مخفی کردن user-section در دسکتاپ */
  .c-header--comma .user-section {
    display: none;
  }

  /* نمایش toggle منوی موبایل */
  .c-header--comma .mobile-menu-toggle {
    display: flex;
  }

  /* تنظیم مجدد org-nav برای موبایل */
  .c-header--comma .header .org-nav {
    justify-content: space-between;
    flex-wrap: nowrap;
    padding: 12px 1.5rem;
    border-radius: 16px;
  }

  /* لوگو در مرکز */
  .c-header--comma .header .org-nav .logo {
    order: 1;
    position: relative;
    left: auto;
    right: 5%;
  }

  /* btns در سمت چپ */
  .c-header--comma .header .org-nav .btns {
    order: 3;
    margin-right: 0;
  }

  /* header-actions */
  .c-header--comma .header-actions {
    order: 3;
  }

  /* مخفی کردن header-message در موبایل */
  .c-header--comma .header-message {
    display: none;
  }
}

@media (min-width: 1025px) {

  .mobile-drawer,
  .mobile-drawer-overlay {
    display: none;
  }
}

/* ========== Mega Menu & Icons (all headers) ========== */

/* آیکون‌های منو (فونت یا تصویر) */
.c-header--comma .menu .c-menu-icon,
.c-header--digikala .menu .c-menu-icon,
.c-header--shopex .menu .c-menu-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-inline-end: 6px;
}

.c-header--comma .menu .c-menu-icon--image img,
.c-header--digikala .menu .c-menu-icon--image img,
.c-header--shopex .menu .c-menu-icon--image img {
  display: block;
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.c-header--comma .menu .c-menu-icon--font i,
.c-header--digikala .menu .c-menu-icon--font i,
.c-header--shopex .menu .c-menu-icon--font i {
  font-size: 14px;
}

/* ریشه مگامنو در منوهای هدر (آیتم سطح اول با کلاس c-mega-root) */
.c-header--comma .menu>ul>li.c-mega-root,
.c-header--digikala .menu>ul>li.c-mega-root,
.c-header--shopex .menu>ul>li.c-mega-root {
  position: relative;
}

.c-header--comma .menu>ul>li.c-mega-root>.sub-menu,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu {
  position: absolute;
  top: 20px;
  right: 0;
  width: 240px;
  background: var(--mega-menu-bg, #ffffff);
  /* border: 1px solid var(--mega-menu-border, #e1e1e1); */
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
  padding: 15px;
  display: flex;
  flex-direction: column;
  /* grid-template-columns: repeat(3, minmax(0, 1fr)); */
  gap: 1rem;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px);
  transition:
    opacity 0.8s ease,
    transform 0.8s ease,
    visibility 0.8s ease;
  z-index: 102;
}

.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>a {
  font-weight: 500;
  font-size: 15px;
}

.c-header--comma .menu>ul>li.c-mega-root:hover>.sub-menu,
.c-header--comma .menu>ul>li.c-mega-root:focus-within>.sub-menu,
.c-header--digikala .menu>ul>li.c-mega-root:hover>.sub-menu,
.c-header--digikala .menu>ul>li.c-mega-root:focus-within>.sub-menu,
.c-header--shopex .menu>ul>li.c-mega-root:hover>.sub-menu,
.c-header--shopex .menu>ul>li.c-mega-root:focus-within>.sub-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

/* هر li سطح اول داخل sub-menu مگامنو یک ستون است */
.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li {
  list-style: none;
}

.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li>a,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li>a,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 700;
  color: var(--mega-menu-heading, #151515);
  margin-bottom: 0.25rem;
}

.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li>a:hover,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li>a:hover,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>a:hover {
  color: var(--mega-menu-link-hover, #0057ff);
}

/* لینک‌های سطح پایین‌تر داخل هر ستون */
.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu {
  margin-top: 0.35rem;
  padding: 0;
}

.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li {
  list-style: none;
  margin-bottom: 0.25rem;
}

.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li>a,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li>a,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li>a {
  font-weight: 400;
  color: var(--mega-menu-text, #555555);
  font-size: 0.9rem;
}

.c-header--comma .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li>a:hover,
.c-header--digikala .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li>a:hover,
.c-header--shopex .menu>ul>li.c-mega-root>.sub-menu>li>.sub-menu>li>a:hover {
  color: var(--mega-menu-link-hover, #0057ff);
}

@media (max-width: 992px) {

  .c-header--comma .menu>ul>li.c-mega-root>.sub-menu,
  .c-header--digikala .menu>ul>li.c-mega-root>.sub-menu,
  .c-header--shopex .menu>ul>li.c-mega-root>.sub-menu {
    position: static;
    width: 100%;
    box-shadow: none;
    border-radius: 0;
    padding: 1rem 0;
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .c-header--digikala .c-bottom-header-type-two .c-content-bottom {
    display: none !important;
  }
}

.c-header--comma .c-content-end {
  width: 50%;
}

.c-header--comma .c-content-end a {
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.c-header--comma .c-bottom-header .c-content-end .c-u-header .user {
  color: var(--header-accent-text) !important;
  background: var(--header-accent);
  transition: 0.3s;
  cursor: pointer;
  position: relative;
  border-radius: 12px;
  padding: 0 10px 0 0;
}

.c-header--comma .c-user-dashboard {
  z-index: 11;
  background: var(--header-accent);
  position: absolute;
  width: 100%;
  border-radius: 10px;
  top: 103%;
  left: 0;
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
}

.c-header--comma .c-user-dashboard ul li {
  display: flex;
}

.c-header--comma .c-user-dashboard a {
  justify-content: start !important;
  padding: 10px;
  color: var(--header-accent-text);
}

.c-header--comma .user:hover .c-user-dashboard {
  opacity: 1;
  visibility: visible;
  transition: 0.3s;
}

.c-header--comma .c-header-cart {
  position: relative;
  background: var(--header-accent);
  width: 50px;
  border-radius: 17px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
}

.c-header--comma .c-header-cart:hover .cart-popup {
  transition: 0.6s;
  opacity: 1;
  visibility: visible;
}

.c-header--comma .c-header-cart i {
  color: var(--header-accent-text);
}

.c-header--comma .c-header-cart .cart-popup {
  opacity: 0;
  visibility: hidden;
  transition: 0.6s;
  padding: 10px;
  background: var(--header-bg);
  position: absolute;
  left: 0;
  top: 110%;
  width: 300px;
  border-radius: 5px;
  box-shadow: 0 0 15px 3px rgba(0, 0, 0, 0.08);
}

.c-header--comma .c-header-cart .cart-popup ul li {
  margin: 5px 0;
}

.c-header--comma .c-header-cart .cart-popup ul li:after {
  content: "";
  margin-top: 8px;
  display: block;
  width: 25%;
  border-radius: 10px;
  height: 3px;
  background: var(--header-accent);
}

.c-header--comma .c-header-cart .cart-page {
  background: var(--header-accent);
  width: 100%;
  padding: 5px;
  border-radius: 4px;
  color: var(--header-accent-text);
  display: block;
  text-align: center;
  margin-top: 8px;
  transition: 0.3s;
}

.c-header--comma .c-header-cart .cart-page:hover {
  background: var(--secondary-color);
  transition: 0.3s;
}

.c-header--comma .c-header-cart .cart-popup img {
  width: 22%;
  height: 100%;
  object-fit: contain;
  margin-left: 10px;
}

.c-header--comma .c-header-cart .c-num-shop-cart {
  position: absolute;
  background: var(--header-accent);
  color: var(--header-accent-text);
  border-radius: 50%;
  padding: 1px;
  left: -5px;
  top: -5px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  font-size: 10px;
  height: 20px;
}

.c-header--comma .dark-mode {
  background: var(--sabad-bg-hover, rgba(170, 212, 238, 0.44));
  width: 50px;
  padding: 9px;
}

.c-header--comma .c-u-header {
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.c-header--comma .icon-panel {
  background: #ffffff00;
  padding: 14px;
  border-radius: 12px;
  display: inline-block;
}

.c-header--comma .menu {
  margin-top: 20px;
  margin-bottom: 15px;
}

.c-header--comma .menu .menu-cat {
  position: relative;
  margin-left: 10px;
}

.c-header--comma .menu .menu-cat a {
  color: var(--header-text-hover) !important;
}

.c-header--comma .menu .menu-cat a:hover {
  color: var(--header-text) !important;
}

.c-header--comma .menu .menu-cat:before {
  content: "";
  width: 1px;
  background-color: var(--header-border);
  height: 16px;
  -webkit-transform: translateY(-50%);
  transform: translateY(-50%);
  top: 50%;
  position: absolute;
  left: -15px;
}

.c-header--comma .off-num {
  background: var(--bg-warning);
  color: var(--text-warning);
  font-size: 15px;
  height: 48px;
  padding: 5px 5px;
  font-style: normal;
  font-weight: 500;
  line-height: normal;
}

/* ========== Header: Digikala (Type-two) ========== */
.c-header--digikala .c-top-header-type-two {
  height: 60px;
  background-color: var(--bg-notice);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-notice);
}

.c-header--digikala .c-search-box form {
  display: flex;
  border-radius: 10px;
  position: relative;
}

.c-header--digikala .c-b-search {
  padding: 10px 10px;
  background: #f0f0f1;
  color: #fff;
  border-radius: 0 15px 15px 0;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.c-header--digikala .c-search-box form input {
  min-width: 350px;
  border: 0;
  padding: 10px;
  border-radius: 10px 0 0 10px;
  background: #f0f0f1;
}

.c-header--digikala .c-content-end .line {
  height: 24px;
  width: 1px;
  margin-inline: 5px;
  background: #e0e0e2;
}

.c-header--digikala .c-bottom-header-type-two .c-content-end {
  width: 28%;
  display: flex;
  justify-content: end;
  align-items: center;
  margin-left: 25px;
  gap: 17px;
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom ul li {
  display: inline-block;
  margin-inline: 10px;
  color: var(--header-text);
  position: relative;
  cursor: pointer;
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom ul li:after {
  content: "";
  display: block;
  width: 0;
  height: 1.2px;
  background: var(--header-text-hover);
  position: absolute;
  bottom: -10px;
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom ul li:hover:after {
  opacity: 1;
  visibility: visible;
  transition: 0.3s;
  width: 100%;
}

.c-header--digikala .c-content-end a {
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.c-header--digikala .c-bottom-header-type-two .c-content-end .user {
  padding: 7px 15px;
  border: 1px solid var(--header-border);
  background: transparent;
  color: var(--header-text);
  margin-left: -15px;
  border-radius: 10px;
  position: relative;
}

.c-header--digikala .c-bottom-header-type-two .user svg {
  margin-left: 10px;
}

.c-header--digikala .c-content-end a .user-name {
  margin: 0 15px;
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom {
  border-bottom: 1px solid var(--header-border);
  align-items: center;
  padding-left: 55px;
  padding-right: 30px;
  padding-bottom: 5px;
}

/* استایل بخش شهر - مشابه دیجی کالا */
.city {
  display: flex;
  align-items: center;
  cursor: pointer;
  padding: 0 12px;
  transition: all 0.2s ease;
  position: relative;
}

.city .city-link {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #3f3f3f;
  text-decoration: none;
  padding: 4px 8px;
  border-radius: 8px;
  transition: background-color 0.2s ease;
  position: relative;
}

.city .city-link:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

.city .city-link .arrow-down {
  transition: transform 0.2s ease;
  margin-right: 2px;
  opacity: 0.6;
}

.city .city-link:hover .arrow-down {
  transform: rotate(180deg);
}

.city .city-link.has-city {
  font-weight: 500;
}

.city .city-link.has-city svg path {
  fill: #7e7e7e;
}

.city .city-link.has-city:hover {
  color: #4f4e4e;
}

.city .city-link span {
  font-size: 13px;
  white-space: nowrap;
  font-weight: 400;
}

/* ویجت کوچک برای انتخاب شهر (مثل دیجی کالا) */
.c-header--digikala .city-dropdown {
  display: none;
  position: absolute;
  top: 26px;
  left: 0;
  background: var(--header-bg, #fff);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  padding: 16px;
  min-width: 280px;
  z-index: 1000;
  margin-top: 8px;
  border: 1px solid #e0e0e0;
}

.c-header--digikala .city-dropdown.open {
  display: block;
}

.c-header--digikala .city-dropdown .city-title {
  font-size: 14px;
  font-weight: 500;
  color: #3f3f3f;
  margin-bottom: 12px;
}

.c-header--digikala .city-dropdown .city-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.c-header--digikala .city-dropdown .city-actions .btn {
  padding: 8px 16px;
  border-radius: 8px;
  text-align: center;
  text-decoration: none;
  font-size: 13px;
  transition: all 0.2s ease;
}

.c-header--digikala .city-dropdown .city-actions .btn-primary {
  background-color: var(--header-accent, #7e7e7e);
  border: unset;
  color: white;
}

.c-header--digikala .city-dropdown .city-actions .btn-primary:hover {
  background-color: var(--header-bg, #7e7e7e);
}

.c-header--digikala .city-dropdown .city-actions .btn-outline {
  border: 1px solid #e0e0e0;
  color: #3f3f3f;
}

.c-header--digikala .city-dropdown .city-actions .btn-outline:hover {
  background-color: #f5f5f5;
}

/* برای موبایل */
@media (max-width: 768px) {
  .city {
    display: none;
    /* یا استایل مخصوص موبایل */
  }
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom .menu {
  padding-top: 10px;
  margin-bottom: -8px;
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom .menu ul li a {
  font-size: 14px;
  color: var(--header-text);
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom .menu ul li a:hover {
  color: var(--header-text-hover);
}

.c-header--digikala .c-bottom-header-type-two .c-content-bottom .menu ul {
  margin-bottom: 1rem !important;
}

.c-header--digikala .c-bottom-header-type-two .c-content-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 25px;
}

.c-header--digikala .c-bottom-header-type-two .image {
  width: 20%;
  height: 60px;
  line-height: 0;
  margin-left: 15px;
  padding-right: 5px;
}

.c-header--digikala .c-bottom-header-type-two .image img {
  height: 100%;
  object-fit: contain;
}

.c-header--digikala .c-bottom-header-type-two .c-content-end .comma-mini-cart--digikala {
  position: relative;
  z-index: 999;
}

.c-header--digikala .c-bottom-header-type-two .c-content-end .comma-mini-cart--digikala .comma-mini-cart__toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ========== User Dropdown - Digikala Style ========== */
.c-header--digikala .user-dropdown-wrapper {
  position: relative;
  display: inline-block;
}

.c-header--digikala .user-dropdown-wrapper .c-user-dashboard {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 180px;
  background: var(--header-bg, #fff);
  border-radius: 12px;
  padding: 8px 0;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  border: 1px solid var(--header-border, #e0e0e0);
}

.c-header--digikala .user-dropdown-wrapper:hover .c-user-dashboard {
  display: block !important;
}

.c-header--digikala .user-dropdown-wrapper .c-user-dashboard .dropdown-link {
  display: block;
  padding: 10px 20px;
  color: var(--header-text, #3f3f3f);
  text-decoration: none;
  font-size: 14px;
  transition: all 0.2s ease;
}

.c-header--digikala .user-dropdown-wrapper .c-user-dashboard .dropdown-link:hover {
  background: var(--header-bg, #f5f5f5);
  color: var(--header-text-hover, #ef394e);
}

.c-header--digikala .user-dropdown-wrapper .c-user-dashboard .dropdown-divider {
  height: 1px;
  margin: 6px 16px;
  background: var(--header-border, #e0e0e0);
}

.c-header--digikala .user-dropdown-wrapper .c-user-dashboard .logout-link {
  color: #ef4444;
}

.c-header--digikala .user-dropdown-wrapper .c-user-dashboard .logout-link:hover {
  background: #fef2f2;
  color: #dc2626;
}

.c-header--digikala .c-content-end .user {
  cursor: pointer;
}

/* دارک مود */
body.dark .c-header--digikala .user-dropdown-wrapper .c-user-dashboard {
  background: var(--header-bg, #1a1a2e);
  border-color: rgba(255, 255, 255, 0.08);
}

body.dark .c-header--digikala .user-dropdown-wrapper .c-user-dashboard .dropdown-link {
  color: var(--header-text, #e0e0e0);
}

body.dark .c-header--digikala .user-dropdown-wrapper .c-user-dashboard .dropdown-link:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--header-text-hover, #4a8af4);
}

body.dark .c-header--digikala .user-dropdown-wrapper .c-user-dashboard .dropdown-divider {
  background: rgba(255, 255, 255, 0.08);
}

body.dark .c-header--digikala .user-dropdown-wrapper .c-user-dashboard .logout-link {
  color: #f87171;
}

body.dark .c-header--digikala .user-dropdown-wrapper .c-user-dashboard .logout-link:hover {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

/* Digikala BEM variant (.h--digikala) */
.c-header--digikala {
  background: var(--header-bg);
}

.c-header--digikala .h--digikala .h__logo img,
.h--digikala .h__logo img {
  height: auto;
  width: 47px;
  object-fit: cover;
}

.c-header--digikala .h--digikala .h__search form input,
.c-header--digikala .h--digikala .h__search-input,
.h--digikala .h__search form input,
.h--digikala .h__search-input {
  width: 600px;
  border: 0;
  padding: 10px;
  border-radius: 10px 0 0 10px;
  background: var(--bg-box);
}

.c-header--digikala .h--digikala .h__search-btn,
.h--digikala .h__search-btn {
  padding: 10px 10px;
  background: var(--bg-box);
  color: var(--header-accent-text);
  border-radius: 0 15px 15px 0;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.h--digikala .h__end {
  display: flex;
  justify-content: end;
  align-items: center;
  margin-left: 25px;
}

.h--digikala .h__end .h__dark-mode {
  margin-inline: 5px;
}

.h--digikala .h__actions {
  margin-left: 10px;
}

.h--digikala .h__end .h__line {
  height: 24px;
  width: 1px;
  margin-inline: 5px;
  background: var(--header-border);
}

@media screen and (max-width: 998px) {

  .c-header--digikala .c-search-box,
  .c-header--digikala .c-bottom-header-type-two .c-content-end .user,
  .c-header--digikala .c-content-end .line {
    display: none !important;
  }

  .c-header--digikala .c-content-top .mobile-menu-toggle {
    display: flex !important;
  }

  /* تنظیمات هدر در موبایل */
  .c-header--digikala .c-content-top {
    padding: 10px 15px;
    flex-wrap: nowrap;
    gap: 10px;
  }

  .c-header--digikala .c-content-top .d-flex.align-items-center {
    flex: 1;
    justify-content: space-between;
  }

  .c-header--digikala .c-bottom-header-type-two .image {
    margin-left: 40px;
  }

  .c-header--digikala .image img {
    max-height: 60px;
    width: auto;
  }
}

/* ========== Header: Shopex (ver2) ========== */
.c-header--shopex .c-top-header-shopex {
  padding: 15px 0;
  background: var(--shopex-top-header-bg);
  gap: 7px;
}

.c-header--shopex .c-top-header-shopex .menu #menu-menu-1 {
  gap: 10px;
}

.c-header--shopex .c-top-header-shopex .image {
  width: 60px;
  height: 60px;
  display: flex;
  justify-content: center;
  border-left: 1px solid var(--header-border);
}

.c-header--shopex .c-top-header-shopex .image img {
  height: 100%;
  object-fit: contain;
}

.c-header--shopex .c-top-header-shopex .menu ul li a {
  color: var(--header-text);
  font-size: 16px;
}

.c-header--shopex .c-top-header-shopex .menu ul li {
  display: inline-block;
  margin-inline: 5px;
  color: var(--header-text);
  font-weight: 500;
  cursor: pointer;
  position: relative;
  transition: 0.3s;
}

.c-header--shopex .c-content-end {
  gap: 5px;
}

.c-header--shopex .c-top-header-shopex .menu ul li:after {
  content: "";
  position: absolute;
  bottom: -10px;
  display: flex;
  width: 0;
  height: 2px;
  background: var(--header-text-hover);
  border-radius: 5px;
  transition: 0.3s;
  opacity: 0;
  visibility: hidden;
}

.c-header--shopex .c-top-header-shopex .menu ul li:hover:after {
  opacity: 1;
  visibility: visible;
  transition: 0.3s;
  width: 100%;
}

.c-header--shopex .c-top-header-shopex .c-search-box {
  background: var(--bg-box);
  border-radius: 14px;
  opacity: 1;
}

.c-header--shopex .c-top-header-shopex .c-search-box input {
  border: none;
  background: var(--bg-box);
  width: 100%;
  padding: 0 15px;
  border-radius: 14px 0 0 14px;
  height: 50px;
}

.c-header--shopex .c-top-header-shopex .c-b-search {
  background: var(--header-accent);
  height: 50px;
  align-items: center;
  width: 52px;
  justify-content: center;
  border-radius: 0 14px 14px 0 !important;
}

.c-header--shopex .header-search .ajax-search-form {
  position: relative;
}

.c-header--shopex .header-search .header-search-results {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
  border: 1px solid rgba(0, 0, 0, 0.06);
  z-index: 999;
  max-height: 400px;
  overflow-y: auto;
}

.c-header--shopex .header-search .header-search-results:not(:empty) {
  display: block;
}

.c-header--shopex .c-top-header-shopex .header-actions.d-flex.align-items-center {
  gap: 7px;
}

.c-header--shopex .c-top-header-shopex .comma-mini-cart--shopex {
  position: relative;
  z-index: 101;
}

.c-header--shopex .c-top-header-shopex .comma-mini-cart--shopex .c-header-cart {
  box-shadow: 0 4px 30px 0 rgba(0, 0, 0, 0.1);
  background: var(--header-accent);
  border-radius: 14px;
  /* width: 100px; */
  gap: 10px;
  padding: 10px;
  height: 50px;
  display: flex;
  align-items: center;
  /* justify-content: space-around; */
  position: relative;
  text-decoration: none;
}

.c-header--shopex .c-top-header-shopex .comma-mini-cart--shopex .comma-mini-cart__count {
  background: var(--header-accent-text);
  padding: 5px 1px 0 0;
  border-radius: 50%;
  height: 22px;
  color: var(--header-accent);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  min-width: 22px;
  text-align: center;
}

.c-header--shopex .user .user-link-wrapper {
  cursor: pointer;
  display: inline-block;
}

.c-header--shopex .c-top-header-shopex .user {
  background: var(--header-accent);
  border-radius: 10px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  height: 50px;
  gap: 5px;
}

.c-header--shopex .c-top-header-shopex .dark-mode {
  box-shadow: 0 4px 30px 0 rgba(0, 0, 0, 0.1);
  background: var(--header-accent);
  border-radius: 14px;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-around;
}

.c-header--shopex .c-top-header-shopex .user-name {
  margin-right: 1px;
  color: var(--header-accent-text);
}

.c-header--shopex .c-bottom-header-shopex {
  border: 2px solid var(--header-accent);
  background: var(--shopex-bottom-header-bg);
  padding: 10px 0;
  color: var(--header-accent-text);
}

.c-header--shopex .category {
  background: var(--header-bg);
  color: var(--header-text);
  padding: 5px 20px;
  border-radius: 12px;
  display: flex;
  align-items: center;
}

.c-header--shopex .c-content-start ul li:hover {
  background: var(--header-bg);
  color: var(--header-text);
  padding: 5px 20px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  transition: 0.4s;
}

.notif-badge {
  position: absolute;
  background: var(--header-accent, #ef394e);
  left: -5px;
  color: #fff;
  border-radius: 50%;
  padding: 3px 7px;
  font-size: 11px;
  top: -6px;
  animation: pulse 2s infinite;
  box-shadow: 0 0 0 rgba(255, 0, 0, 0.4);
}

/* تعریف انیمیشن پالس */
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 var(--header-accent);
    transform: scale(0.8);
  }

  70% {
    box-shadow: 0 0 0 10px rgba(255, 0, 0, 0);
    transform: scale(1);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(255, 0, 0, 0);
    transform: scale(0.8);
  }
}

.c-header--shopex .c-content-start ul li {
  margin: 0 10px;
  transition: 0.4s;
  position: relative;
  padding: 5px;
}

.c-header--shopex .c-content-start ul li a {
  display: flex;
  align-items: center;
  font-size: 16px;
  color: var(--header-text);
}

.c-header--shopex .c-content-start ul li a:hover {
  color: var(--header-text-hover);
}

.c-header--shopex .icon-menu {
  width: 40px;
  height: 40px;
  background: var(--bg-element);
  border-radius: 10px;
  margin-left: 5px;
}

.c-header--shopex .c-header-phone {
  text-align: center;
  position: relative;
}

.c-header--shopex .c-header-phone a,
.c-header--shopex .c-header-phone span {
  color: var(--header-text);
}

.c-header--shopex .c-header-phone span {
  font-size: 14px;
}

.c-header--shopex .c-header-phone span:before {
  content: "";
  display: inline-block;
  border-radius: 10px;
  width: 5px;
  height: 5px;
  background: var(--header-accent);
  margin-left: 5px;
}

.c-header--shopex .icon-phone {
  position: relative;
}

.c-header--shopex .icon-phone:after {
  content: "";
  width: 2.5px;
  height: 50px;
  display: flex;
  top: -10px;
  right: -10px;
  transform: rotate(6deg);
  position: absolute;
  background: radial-gradient(50% 50% at 50% 50%,
      var(--header-accent) 0%,
      transparent 100%);
}

.c-header--shopex .icon-phone:before {
  content: "";
  width: 2.5px;
  height: 50px;
  display: flex;
  top: -10px;
  left: -10px;
  transform: rotate(6deg);
  position: absolute;
  background: radial-gradient(50% 50% at 50% 50%,
      var(--header-accent) 0%,
      transparent 100%);
}

.c-header--shopex .category span {
  background: var(--header-accent);
}

/* Shopex BEM variant (.h--shopex) */
.h--shopex .h__top {
  padding: 15px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.c-header--shopex .h--shopex .h__top .h__logo,
header .h--shopex .h__top .h__logo {
  width: 60px;
  height: 60px;
  border-left: 1px solid var(--header-border);
}

.c-header--shopex .h--shopex .h__top .h__menu ul li,
header .h--shopex .h__top .h__menu ul li {
  display: inline-block;
  margin-inline: 5px;
  color: var(--header-text);
  font-weight: 500;
  cursor: pointer;
  position: relative;
  transition: 0.3s;
}

.c-header--shopex .h--shopex .h__top .h__menu ul li:after,
header .h--shopex .h__top .h__menu ul li:after {
  content: "";
  position: absolute;
  bottom: -10px;
  display: flex;
  width: 0;
  height: 2px;
  background: var(--header-text-hover);
  border-radius: 5px;
  transition: 0.3s;
  opacity: 0;
  visibility: hidden;
}

.c-header--shopex .h--shopex .h__top .h__menu ul li:hover:after,
header .h--shopex .h__top .h__menu ul li:hover:after {
  opacity: 1;
  visibility: visible;
  transition: 0.3s;
  width: 100%;
}

.h--shopex .h__top .h__search {
  background: var(--bg-box);
  width: 389px;
  border-radius: 14px;
  opacity: 1;
}

.h--shopex .h__top .h__search input {
  border: none;
  background: var(--bg-box);
  width: 100%;
  padding: 0 15px;
  border-radius: 14px;
  height: 52px;
}

.h--shopex .h__top .h__search-btn {
  background: var(--header-accent);
  height: 52px;
  align-items: center;
  width: 52px;
  justify-content: center;
}

.h--shopex .h__top .h__cart {
  box-shadow: 0 4px 30px 0 rgba(0, 0, 0, 0.1);
  background: var(--header-accent);
  border-radius: 14px;
  width: 100px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-around;
}

.h--shopex .h__top .h__cart-count {
  background: var(--header-accent-text);
  padding: 3px 6px;
  border-radius: 14px;
}

.h--shopex .h__top .h__user {
  background: var(--bg-element);
  border-radius: 10px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  height: 52px;
}

.h--shopex .h__top .h__dark-mode {
  box-shadow: 0 4px 30px 0 rgba(0, 0, 0, 0.1);
  background: var(--header-accent);
  border-radius: 14px;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-around;
}

.h--shopex .h__top .h__user-name {
  margin-right: 1px;
}

.h--shopex .h__bottom {
  border: 2px solid var(--header-accent);
  background: var(--header-bg);
  padding: 10px 0;
  color: var(--header-accent-text);
}

.h--shopex .h__category {
  background: var(--header-bg);
  color: var(--header-text);
  padding: 5px 20px;
  border-radius: 12px;
  display: flex;
  align-items: center;
}

.h--shopex .h__start ul li {
  margin: 0 10px;
}

.h--shopex .h__start ul li a {
  display: flex;
  align-items: center;
  font-size: 14px;
  color: var(--header-text);
}

.h--shopex .h__start ul li a:hover {
  color: var(--header-text-hover);
}

.h--shopex .h__nav-icon {
  width: 40px;
  height: 40px;
  background: var(--bg-element);
  border-radius: 10px;
  margin-left: 5px;
}

.h--shopex .h__phone {
  text-align: center;
  position: relative;
}

.h--shopex .h__phone span {
  font-size: 14px;
}

.h--shopex .h__phone span:before {
  content: "";
  display: inline-block;
  border-radius: 10px;
  width: 5px;
  height: 5px;
  background: var(--header-accent);
  margin-left: 5px;
}

.h--shopex .h__phone-icon {
  position: relative;
}

.h--shopex .h__phone-icon:after {
  content: "";
  width: 2.5px;
  height: 50px;
  display: flex;
  top: -10px;
  right: -10px;
  transform: rotate(6deg);
  position: absolute;
  background: radial-gradient(50% 50% at 50% 50%,
      var(--header-accent) 0%,
      transparent 100%);
}

.h--shopex .h__phone-icon:before {
  content: "";
  width: 2.5px;
  height: 50px;
  display: flex;
  top: -10px;
  left: -10px;
  transform: rotate(6deg);
  position: absolute;
  background: radial-gradient(50% 50% at 50% 50%,
      var(--header-accent) 0%,
      transparent 100%);
}

.h--shopex .h__category span {
  background: var(--header-accent);
}

/* ========== User Dropdown ========== */
.c-header--shopex .user-dropdown-wrapper {
  position: relative;
  display: inline-block;
}

.c-header--shopex .user-dropdown-wrapper .c-user-dashboard {
  display: none;
  position: absolute;
  right: 0;
  min-width: 150px;
  background: var(--bg-box, #fff);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  z-index: 999;
  border: 1px solid var(--header-border, #e5e5e5);
}

.c-header--shopex .user-dropdown-wrapper:hover .c-user-dashboard {
  display: block !important;
}

.c-header--shopex .c-top-header-shopex .user {
  position: relative;
}

.c-header--shopex .c-top-header-shopex .user .user-name {
  cursor: pointer;
}

.mobile-search .search-input-wrapper button {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* مخفی‌سازی در موبایل */
.desktop-only {
  display: flex !important;
}

@media screen and (max-width: 1200px) {
  .c-bottom-header-shopex {
    display: none;
  }

  .desktop-only {
    display: none !important;
  }

  .c-header--shopex .mobile-menu-toggle {
    display: flex !important;
  }

  .c-header--shopex .c-top-header-shopex .image {
    margin-right: 20%;
  }

  /* تنظیمات برای نمایش لوگو و دکمه‌ها در موبایل */
  .c-header--shopex .c-top-header-shopex {
    justify-content: space-between;
    flex-wrap: nowrap;
  }

  .c-header--shopex .c-top-header-shopex .mobile-menu-toggle {
    order: 1;
  }

  .c-header--shopex .c-top-header-shopex .image {
    order: 2;
  }

  .c-header--shopex .c-top-header-shopex .header-actions {
    order: 3;
  }
}

@media (min-width: 1025px) {

  .mobile-drawer,
  .mobile-drawer-overlay {
    display: none !important;
  }
}

@media screen and (max-width: 768px) {
  .c-header--shopex .c-top-header-shopex .user {
    display: none;
  }
}

/* ========== Ajax search (header) ========== */
.haeder-type-one .ajax-search h4,
.haeder-type-one .ajax-search p,
.haeder-type-one .ajax-search a {
  text-decoration: none !important;
  color: var(--text-color) !important;
}

.haeder-type-one .ajax-search {
  background: var(--bg-box);
  width: 535px;
  height: auto;
  border-radius: 10px;
  z-index: 2;
  padding: 10px;
  margin-top: 5px;
  flex-direction: column;
  align-content: flex-start;
  justify-content: flex-start;
  display: none;
}

.ajax-search-product-box {
  padding: 8px 10px 0 10px;
  border-radius: 5px;
  margin: 7px 0;
}

.ajax-search-product-box-name-picture h4 {
  line-height: 3 !important;
  font-size: 17px !important;
  margin-right: 10px !important;
}

.ajax-search-product-box-name-picture img {
  border-radius: 5px;
}

/* ========== Menu Phone ========== */
.h--phone {
  position: fixed;
  bottom: 0;
  height: 50px;
  width: 100%;
  background: var(--header-accent);
  border-radius: 10px 10px 0 0;
  display: none;
  z-index: 100;
  color: var(--header-accent-text);
  justify-content: space-around;
  align-items: center;
}

.h--phone .h__logo {
  background: var(--bg-element);
  border-radius: 50%;
  height: 60px;
  width: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -40px;
  position: relative;
}

.h--phone .h__menu:hover ul {
  opacity: 1;
  visibility: visible;
  transition: 0.4s;
}

.h--phone .h__menu ul {
  position: absolute;
  width: 40%;
  opacity: 0;
  visibility: hidden;
  bottom: 50px;
  padding-right: 10px;
  border-radius: 10px;
  color: var(--header-accent-text);
  cursor: pointer;
  background: var(--header-accent);
  transition: 0.4s;
}

.h--phone .h__menu ul li {
  margin: 10px 0;
  cursor: pointer;
}

/* ========== Header responsive (moved from frontend.css) ========== */
@media (max-width: 576px) {

  .h--comma .h__top,
  .c-header--comma .c-top-header {
    padding: 0 5px;
  }

  .h--comma .h__top h6,
  .c-header--comma .c-top-header h6 {
    font-size: 12px;
  }
}

@media (max-width: 768px) {

  .h--comma .h__top,
  .c-header--comma .c-top-header {
    padding: 0 10px;
  }
}

@media (max-width: 1400px) {
  header .c-content-start {
    width: 68%;
  }

  header .c-content-end {
    width: 31%;
  }
}

/* ========== Dark Mode Toggle (headers) ========== */
.comma-dark-mode-toggle {
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  color: var(--sabad-icon, var(--header-accent, #378fc6));
  background: var(--sabad-bg, rgba(204, 225, 238, 0.44));
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.comma-dark-mode-toggle:hover {
  background: var(--sabad-bg-hover, rgba(170, 212, 238, 0.44));
  transform: translateY(-2px);
}

.comma-dark-mode-toggle__track {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  position: relative;
}

.comma-dark-mode-toggle__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}

.comma-dark-mode-toggle__icon--moon {
  position: absolute;
  opacity: 0;
  transform: rotate(-20deg) scale(0.8);
}

.comma-dark-mode-toggle.switched .comma-dark-mode-toggle__icon--sun,
body.dark .comma-dark-mode-toggle .comma-dark-mode-toggle__icon--sun {
  opacity: 0;
  transform: rotate(20deg) scale(0.8);
}

.comma-dark-mode-toggle.switched .comma-dark-mode-toggle__icon--moon,
body.dark .comma-dark-mode-toggle .comma-dark-mode-toggle__icon--moon {
  opacity: 1;
  transform: rotate(0) scale(1);
}

.comma-dark-mode-toggle--comma {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  /* margin-top: 8px; */
}

.c-header--comma .header .org-nav .btns .comma-dark-mode-toggle--comma {
  box-shadow: none;
}

.comma-dark-mode-toggle--digikala {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #f0f0f1;
  color: #1c274c;
}

.c-header--digikala .comma-dark-mode-toggle--digikala:hover {
  background: #e4e4e7;
}

.comma-dark-mode-toggle--shopex {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--header-accent);
  color: var(--header-accent-text, #fff);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.comma-dark-mode-toggle--style1 {
  width: 55px;
  height: 55px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.06);
  color: #6b6671;
}

.comma-dark-mode-toggle--style1:hover {
  background: rgba(0, 0, 0, 0.09);
}

.comma-dark-mode-toggle--elementor {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(0, 87, 255, 0.08);
  color: var(--first-color, #0057ff);
}

.comma-mini-cart--digikala .comma-mini-cart__toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.comma-mini-cart--digikala .comma-mini-cart__count {
  position: absolute;
  top: -8px;
  inset-inline-end: -8px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--header-accent, #ef394e);
  color: #404040;
  font-size: 11px;
  font-weight: 700;
  line-height: 20px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(239, 57, 78, 0.35);
}

.comma-mini-cart--style1 .sabad {
  position: relative;
}

.comma-mini-cart--style1 .comma-mini-cart__count {
  position: absolute;
  top: -8px;
  inset-inline-end: -8px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--header-bg);
  color: var(--sabadSpanTextColor, #fff);
  font-size: 11px;
  font-weight: 700;
  line-height: 20px;
  text-align: center;
}

.comma-mini-cart--elementor .header-cart-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(0, 87, 255, 0.08);
}

.comma-mini-cart--elementor .comma-mini-cart__count {
  position: absolute;
  top: -6px;
  inset-inline-end: -6px;
}

/* ========== Ajax Mini Cart (shared) ========== */
.comma-mini-cart {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
  z-index: 1001;
}

.comma-mini-cart::after {
  content: "";
  position: absolute;
  top: 100%;
  inset-inline: 0;
  height: 14px;
}

.comma-mini-cart__toggle {
  text-decoration: none;
  color: inherit;
}

.comma-mini-cart__popup {
  position: absolute;
  top: calc(100% + 12px);
  inset-inline-end: 0;
  inset-inline-start: auto;
  width: min(360px, calc(100vw - 24px));
  background: var(--header-bg, #fff);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.16);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px) scale(0.98);
  transform-origin: top right;
  transition:
    opacity 0.28s ease,
    transform 0.28s ease,
    visibility 0.28s ease;
  overflow: hidden;
}

.comma-mini-cart.is-open .comma-mini-cart__popup,
.comma-mini-cart:hover .comma-mini-cart__popup {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.comma-mini-cart__popup-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.comma-mini-cart__popup-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--header-text, #252525);
}

.comma-mini-cart__popup-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--sabad-sp-color, var(--header-accent, #378fc6));
  color: var(--sabad-sp-num-color, #fff);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.comma-mini-cart__popup-body {
  padding: 12px 16px 16px;
  max-height: min(340px, 52vh);
  overflow-y: auto;
}

.comma-mini-cart__popup-body::-webkit-scrollbar {
  width: 6px;
}

.comma-mini-cart__popup-body::-webkit-scrollbar-thumb {
  background: rgba(15, 23, 42, 0.15);
  border-radius: 999px;
}

.comma-mini-cart__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.comma-mini-cart__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  position: relative;
}

.comma-mini-cart__item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.comma-mini-cart__remove {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.04);
  color: #98a2b3;
  font-size: 18px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition:
    color 0.2s ease,
    background 0.2s ease;
}

.comma-mini-cart__remove:hover {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.comma-mini-cart__item.updating,
.comma-mini-cart__item.blockUI,
.comma-mini-cart__item .blockUI {
  border-radius: 10px;
}

.comma-mini-cart__thumb {
  width: 52px;
  height: 52px;
  object-fit: contain;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.04);
  padding: 4px;
  flex-shrink: 0;
}

.comma-mini-cart__info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.comma-mini-cart__name {
  font-size: 13px;
  font-weight: 600;
  color: var(--header-text, #252525);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.comma-mini-cart__meta {
  font-size: 12px;
  color: var(--header-text-secondary, #667085);
  font-weight: 500;
}

.comma-mini-cart__footer {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.comma-mini-cart__total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 12px;
  font-size: 13px;
  color: var(--header-text-secondary, #667085);
}

.comma-mini-cart__total strong {
  font-size: 15px;
  font-weight: 700;
  color: var(--header-text, #252525);
}

.comma-mini-cart__empty-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px 8px 8px;
  text-align: center;
}

.comma-mini-cart__empty-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(5, 62, 194, 0.08);
  position: relative;
}

.comma-mini-cart__empty-icon::before {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 24px;
  height: 20px;
  border: 2px solid var(--sabad-icon, var(--header-accent, #378fc6));
  border-radius: 0 0 8px 8px;
  top: 8px;
}

.comma-mini-cart__empty-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 12px;
  width: 14px;
  height: 10px;
  border: 2px solid var(--sabad-icon, var(--header-accent, #378fc6));
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  transform: translateX(-50%);
}

.comma-mini-cart__empty {
  margin: 0;
  font-size: 13px;
  color: var(--header-text-secondary, #667085);
  line-height: 1.6;
}

.comma-mini-cart__view,
.comma-mini-cart .cart-page {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 12px;
  background: var(--header-accent, #378fc6);
  color: #fff;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
  box-shadow: 0 8px 20px rgb(0 0 0 / 25%);
}

.comma-mini-cart__view:hover,
.comma-mini-cart .cart-page:hover {
  transform: translateY(-1px);
  opacity: 0.95;
  color: #fff;
}

.c-header--comma .comma-mini-cart--comma {
  z-index: 102;
}

.c-header--digikala .comma-mini-cart--digikala .comma-mini-cart__view,
.c-header--digikala .comma-mini-cart--digikala .cart-page {
  background: var(--header-accent) !important;
  color: var(--header-accent-text, #fff) !important;
  box-shadow: none;
}

.c-header--digikala .comma-mini-cart--digikala .comma-mini-cart__view:hover,
.c-header--digikala .comma-mini-cart--digikala .cart-page:hover {
  background: var(--secondary-color, var(--header-accent));
}

.c-header--shopex .comma-mini-cart--shopex .comma-mini-cart__view,
.c-header--shopex .comma-mini-cart--shopex .cart-page {
  background: var(--header-accent);
  color: var(--header-accent-text, #fff);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

body.comma-mini-cart-open::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  z-index: 1000;
  backdrop-filter: blur(2px);
}

@media (max-width: 991px) {
  .comma-mini-cart:hover .comma-mini-cart__popup {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(10px) scale(0.98);
  }

  .comma-mini-cart.is-open .comma-mini-cart__popup {
    position: fixed;
    top: auto;
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
    inset-inline: 12px;
    width: auto;
    max-height: min(420px, 62vh);
    z-index: 10001;
    transform: translateY(0) scale(1);
  }

  .comma-mini-cart.is-open .comma-mini-cart__popup-body {
    max-height: min(280px, 45vh);
  }

  .comma-dark-mode-toggle--comma {
    margin-top: 5px;
  }
}

@media (min-width: 992px) {
  body.comma-mini-cart-open::before {
    display: none;
  }
}

body.dark .comma-mini-cart__popup {
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

body.dark .comma-mini-cart__popup-head {
  background: rgba(255, 255, 255, 0.04);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

body.dark .comma-mini-cart__item {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

body.dark .comma-mini-cart__remove {
  background: rgba(255, 255, 255, 0.06);
  color: #94a3b8;
}

body.dark .comma-mini-cart__remove:hover {
  background: rgba(239, 68, 68, 0.18);
  color: #f87171;
}

body.dark .comma-mini-cart__thumb {
  background: rgba(255, 255, 255, 0.06);
}

body.dark .comma-mini-cart__footer {
  border-top-color: rgba(255, 255, 255, 0.08);
}

body.dark .comma-dark-mode-toggle--comma {
  background: #2d2d2d;
  color: #cce1ee;
}

body.dark .comma-dark-mode-toggle--digikala {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* ========== Header dark mode (moved from darkmode.css) ========== */
body.dark header {
  box-shadow: 0 0 42px 0 rgba(36, 47, 92, 0.34);
}

body.dark header .c-bottom-header .image img,
body.dark .c-header--comma .c-bottom-header .image img {
  box-shadow: 0 0 25px 0 rgb(0 0 0 / 40%) !important;
}

body.dark .c-bottom-header .c-i-search,
body.dark .c-b-c-search {
  background-color: var(--bg-body-dark);
}