 :root{
      --page-bg:#ffffff;
      --card:#ffffff;
      --muted:#6b7280;
      --accent:#1ed760;
      --muted-2:#737373;
      --border: #e6e6e6;
      --shadow: 0 6px 20px rgba(16,24,40,0.06);
      --radius:12px;
      --text:#111827;
    }
    body{
      font-family: 'Vazirmatn', sans-serif;
      height:100%;background:var(--page-bg);
      color:var(--text);
      margin:0
    }

    /* Header */
    .topbar{background:#f8fafc;border-bottom:1px solid var(--border);font-size:0.95rem}
    .topbar a{color:var(--muted)}
    .site-header{background:transparent}
    .brand{font-weight:700;font-size:1.25rem;color:var(--text)}
    .search-input{min-width:300px}

    /* Navigation */
    .nav-card{background:transparent}

    /* Hero */
    .hero{border-radius:var(--radius);overflow:hidden;box-shadow:var(--shadow);background:#fafafa;padding:0}
    .hero-slide{height:420px;background-size:cover;background-position:center;display:flex;align-items:center}
    .hero-inner{padding:3rem}
    .hero h1{font-size:2rem}
    .hero p{color:var(--muted)}

    /* Category cards */
    .category-card{background:#fff;border:1px solid var(--border);border-radius:10px;padding:18px;text-align:center;box-shadow:var(--shadow)}
    .category-card img{max-width:80%;height:80px;object-fit:contain}

    /* Product card */
    .product-card{background:#fff;border:1px solid var(--border);border-radius:12px;padding:14px;transition:transform .18s,box-shadow .18s;box-shadow:0 6px 18px rgba(15,23,42,0.04)}
    .product-card:hover{transform:translateY(-6px);box-shadow:0 14px 30px rgba(16,24,40,0.08)}
    .product-image{height:190px;display:flex;align-items:center;justify-content:center;border-radius:10px;background:#fbfbfb;overflow:hidden}
    .price{color:var(--accent);font-weight:700}
    .muted{color:var(--muted)}

    /* Sections */
    .section-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:1rem}

    /* Brands */
    .brand-item{background:#fff;border:1px solid var(--border);padding:12px;border-radius:10px;display:flex;align-items:center;justify-content:center}

    /* Testimonials */
    .testimonial{background:#fafafa;border:1px solid var(--border);padding:20px;border-radius:10px}

    /* Footer */
    .site-footer{background:#f8fafc;border-top:1px solid var(--border);padding:2.5rem 0;margin-top:2.5rem;color:var(--muted)}

    /* Responsive tweaks */
    @media (max-width:992px){.search-input{min-width:200px}}
    @media (max-width:768px){.hero-slide{height:260px}.search-input{width:100%}}
    .sticky-sidebar {
  position: sticky;
  top: 20px; /* فاصله از بالای صفحه هنگام چسبیدن */
}
.pagination .page-link {
    border-radius: 8px !important;   /* گوشه‌ها */
    width: 40px;                     /* مربع */
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    transition: 0.2s ease;
}

.pagination .page-item.active .page-link {
    background-color: #0d6efd !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 0 8px rgba(0, 123, 255, 0.5);
}

.pagination .page-link:hover {
    background-color: #e7f1ff;
    color: #0d6efd;
}

.pagination .page-item.disabled .page-link {
    opacity: 0.5;
    cursor: not-allowed;
}
.sidebar-widget {
  position: sticky;
  top: 80px;
}

.category-card {
  background: #ffffff;
  padding: 18px 16px;
  border-radius: 14px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  transition: 0.3s ease-in-out;
  border: 1px solid #eee;
}

.category-card:hover {
  box-shadow: 0 6px 28px rgba(0,0,0,0.10);
  transform: translateY(-3px);
}

.category-title {
  font-size: 15px;
  margin-bottom: 12px;
  font-weight: bold;
  color: #333;
  padding-bottom: 6px;
  border-bottom: 1px solid #f0f0f0;
}

.category-list a {
  display: block;
  padding: 10px 12px;
  margin-bottom: 6px;
  border-radius: 10px;
  background: #fafafa;
  color: #444;
  font-size: 14px;
  text-decoration: none;
  transition: all 0.25s ease;
  border: 1px solid #eee;
}

.category-list a:hover {
  background: #f5f7ff;
  border-color: #ccd5ff;
  color: #2a3cff;
  transform: translateX(-5px);
}
.price-filter-card {
  background: #ffffff;
  padding: 18px 16px;
  border-radius: 14px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  border: 1px solid #eee;
  margin-top: 12px;
  transition: 0.3s ease;
}

.price-filter-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 26px rgba(0,0,0,0.10);
}

.filter-title {
  font-size: 15px;
  font-weight: bold;
  color: #333;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid #f0f0f0;
}

.filter-inputs {
  display: flex;
  gap: 10px;
}

.filter-inputs .form-control {
  border-radius: 10px;
  border: 1px solid #e0e0e0;
  padding: 8px 10px;
  font-size: 14px;
  transition: 0.25s ease;
  background: #fafafa;
}

.filter-inputs .form-control:focus {
  border-color: #5576ff;
  background: #f5f7ff;
  box-shadow: 0 0 0 3px rgba(85,118,255,0.15);
}

.filter-btn {
  width: 100%;
  margin-top: 16px;
  background: #2a3cff;
  color: #fff;
  padding: 9px 0;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  transition: 0.3s ease;
}

.filter-btn:hover {
  background: #1f2fcc;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(42,60,255,0.35);
}
    /* استایل بسیار زیبا برای جعبه دسته‌بندی */
    .category-box {
        background: #ffffff;
        border-radius: 14px;
        padding: 20px;
        border: 1px solid #e3e3e3;
        box-shadow: 0 0 18px rgba(0,0,0,0.05);
        transition: all 0.3s ease;
    }

    .category-box:hover {
        box-shadow: 0 0 28px rgba(0,0,0,0.10);
        border-color: #d5d5d5;
    }

    .category-title {
        font-size: 18px;
        font-weight: 600;
        margin-bottom: 15px;
        padding-bottom: 10px;
        border-bottom: 2px solid #eee;
    }

    .category-item {
        padding: 8px 0;
        cursor: pointer;
        transition: 0.3s;
        border-bottom: 1px solid #f1f1f1;
    }

    .category-item:last-child {
        border-bottom: none;
    }

    .category-item:hover {
        color: #007bff;
        padding-right: 5px;
    }
/* کانتینر اصلی اسلاید */
.hero-slide-new {
  position: relative;
  width: 100%;
  height: 600px; /* افزایش ارتفاع برای نمایش بهتر */
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center; /* عمودی وسط */
  justify-content: flex-end; /* افقی سمت راست */
  padding: 0 10%; /* فاصله از طرفین برای تناسب بهتر */
  overflow: hidden;
}

/* گرادینت بهبود یافته برای خوانایی بهتر متن */
.hero-gradient {
  position: absolute;
  inset: 0;
  /* گرادینت غلیظ‌تر در سمت راست برای خوانایی متن */
  background: linear-gradient(270deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 50%, rgba(0,0,0,0.1) 100%);
  z-index: 1;
}

/* محتوای متنی با افکت شیشه‌ای */
.hero-content {
  position: relative;
  z-index: 5;
  max-width: 650px;
  width: 100%;
  /* انیمیشن ورود محتوا */
  animation: slideInRight 1s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

/* استایل عنوان */
.hero-title-new {
  font-family: 'Tahoma', 'Segoe UI', sans-serif; /* فونت خوانا */
  font-size: 3rem; /* اندازه بزرگتر */
  font-weight: 900;
  color: #ffffff;
  margin-bottom: 1.2rem;
  line-height: 1.3;
  text-shadow: 0 4px 20px rgba(0,0,0,0.6);
  opacity: 0;
  animation: fadeInUp 0.8s ease 0.3s forwards; /* تاخیر برای ظاهر شدن بعد از کانتینر */
}

/* استایل توضیحات */
.hero-desc-new {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 1.25rem;
  color: #f0f0f0;
  line-height: 1.8;
  margin-bottom: 2.5rem;
  text-shadow: 0 2px 10px rgba(0,0,0,0.5);
  opacity: 0;
  animation: fadeInUp 0.8s ease 0.6s forwards; /* تاخیر بیشتر */
}

/* دکمه جذاب‌تر */
.hero-btn-new {
  display: inline-block;
  background: linear-gradient(135deg, #00c853, #009624);
  border: none;
  padding: 1rem 3rem; /* بزرگتر */
  font-size: 1.1rem;
  font-weight: 700;
  color: white;
  border-radius: 50px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* افکت فنری */
  box-shadow: 0 10px 30px rgba(0, 200, 83, 0.4);
  opacity: 0;
  animation: fadeInUp 0.8s ease 0.9s forwards;
}

.hero-btn-new:hover {
  background: linear-gradient(135deg, #00e676, #00c853);
  transform: translateY(-5px) scale(1.05); /* بزرگ شدن و بالا آمدن */
  box-shadow: 0 15px 40px rgba(0, 200, 83, 0.6);
}

/* انیمیشن‌های جدید و روان */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* واکنش‌گرایی برای موبایل و تبلت */
@media (max-width: 992px) {
  .hero-slide-new {
    height: 500px;
    padding: 0 5%;
  }
  .hero-title-new {
    font-size: 2.2rem;
  }
}

@media (max-width: 768px) {
  .hero-slide-new {
    /* تغییر ارتفاع به ۳۵۰ پیکسل (یا هر عدد کمتر که می‌خواهید) */
    height: 350px; 
    min-height: auto; /* غیرفعال کردن حداقل ارتفاع قبلی */
    
    padding: 2rem 1.5rem; /* کاهش پدینگ بالا و پایین برای فشرده‌تر شدن */
    justify-content: center;
    text-align: center;
  }

  /* تغییر گرادینت برای موبایل (تیره‌تر در پایین) */
  .hero-gradient {
    background: linear-gradient(180deg, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.8) 100%);
  }

  .hero-content {
    max-width: 100%;
    /* حذف انیمیشن چپ به راست در موبایل برای پرفورمنس بهتر */
    animation: fadeIn 1s ease forwards;
  }

  .hero-title-new {
    font-size: 1.8rem;
    margin-bottom: 1rem;
  }

  .hero-desc-new {
    font-size: 1rem;
    margin-bottom: 2rem;
  }

  .hero-btn-new {
    width: 100%; /* دکمه تمام عرض */
    max-width: 300px;
    padding: 0.9rem 2rem;
  }
}

/* Card Style */
.custom-product-card {
    background: #fff;
    border: 1px solid #eee;
    transition: 0.3s ease;
}

.custom-product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.08);
}

/* Main Image */
.main-image-wrapper {
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 20px;
    position: relative;
}

.main-product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease, opacity .4s ease;
}

.main-product-image:hover {
    transform: scale(1.05);
}

/* Fade Animation */
.fade-effect {
    opacity: 0;
    transition: opacity .35s ease;
}

.fade-effect.fade-show {
    opacity: 1;
}
    /* کارت و استایل کلی (از استایل‌هایی که قبلاً دوست داشتی الهام گرفته شده) */
    .card-clean {
      border-radius: 16px;
      background: #fff;
      padding: 20px;
      box-shadow: 0 8px 24px rgba(9,10,10,.06);
      transition: box-shadow .25s ease, transform .2s ease;
    }
    .card-clean:hover { transform: translateY(-4px); box-shadow: 0 12px 36px rgba(9,10,10,.08); }

    .custom-product-card { max-width: 720px; margin: 0 auto; }

    /* اصلی تصویر */
    .carousel-wrapper { position: relative; overflow: hidden; border-radius: 12px; }
    .main-product-image {
      width: 100%;
      height: 480px;
      object-fit: contain;
      background: #f6f7fb;
      display: block;
      transition: transform .35s ease, box-shadow .25s ease;
      cursor: zoom-in;
    }
    .main-product-image:active { transform: scale(.995); }

    /* thumbnail carousel */
    .thumb-carousel-container { align-items: center; gap: .5rem; }
    .thumbs-wrapper {
      display: flex;
      gap: .6rem;
      overflow-x: auto;
      scroll-behavior: smooth;
      padding-bottom: 6px;
      -webkit-overflow-scrolling: touch;
    }
    .thumbs-wrapper::-webkit-scrollbar { height: 8px; }
    .thumbs-wrapper::-webkit-scrollbar-thumb { background: rgba(0,0,0,.12); border-radius: 99px; }

    .thumb-img-advanced {
      width: 92px;
      height: 72px;
      object-fit: cover;
      border-radius: 10px;
      cursor: pointer;
      flex: 0 0 auto;
      box-shadow: 0 2px 8px rgba(0,0,0,.06);
      transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
      border: 2px solid transparent;
    }
    .thumb-img-advanced:hover { transform: translateY(-4px); }
    .thumb-img-advanced.active {
      border-color: #198754;
      box-shadow: 0 8px 24px rgba(25,135,84,.12);
      opacity: 1;
      transform: translateY(-6px) scale(1.02);
    }

    /* nav buttons */
    .thumb-nav-btn {
      border: none;
      background: linear-gradient(180deg, rgba(0,0,0,.06), rgba(0,0,0,.03));
      width: 42px;
      height: 42px;
      border-radius: 10px;
      display: inline-grid;
      place-items: center;
      font-size: 20px;
      cursor: pointer;
      transition: background .15s ease, transform .12s ease;
    }
    .thumb-nav-btn:active { transform: translateY(1px); }
    .thumb-nav-btn:focus { outline: 2px solid rgba(25,135,84,.14); }

    /* responsive tweaks */
    @media (max-width: 900px) {
      .main-product-image { height: 360px; }
      .thumb-img-advanced { width: 78px; height: 62px; }
    }
    @media (max-width: 520px) {
      .main-product-image { height: 240px; }
      .thumb-img-advanced { width: 64px; height: 52px; }
    }

    /* small helper text */
    .gallery-note { font-size: .9rem; color: #6c757d; margin-top: .6rem; }
      .star-rating span {
    font-size: 2rem;
    cursor: pointer;
    color: gray;
    transition: color 0.2s;
  }
  .star-rating span:hover,
  .star-rating span:hover ~ span {
    color: gold;
  }
  .star-rating span {
  font-size: 2rem;
  cursor: pointer;
  color: gray;
  transition: color 0.2s;
}
.star-rating-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.star-rating {
  display: flex;
  gap: 4px;
}

.star {
  font-size: 1.6rem;
  position: relative;
  transition: transform 0.2s, color 0.2s;
  cursor: default;
  text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* ستاره کامل */
.star.full {
  color: #FFD700; /* طلایی */
}

/* ستاره نیمه */
.star.half {
  color: #ddd;
}
.star.half::before {
  content: '★';
  position: absolute;
  left: 0;
  width: 50%;
  overflow: hidden;
  color: #FFD700;
}

/* ستاره خالی */
.star.empty {
  color: #ccc;
}

/* جلوه hover برای زیبایی */
.star-rating .star:hover,
.star-rating .star:hover ~ .star {
  transform: scale(1.2) translateY(-2px);
}
.rating-text {
  font-size: 1rem;
  color: #555;
}
.star-rating-small {
  display: inline-block;
  font-size: 1rem;
  color: #ddd;
  margin-bottom: 4px;
}

.star-rating-small .full {
  color: gold;
}

.star-rating-small .half {
  position: relative;
  color: #ddd;
}

.star-rating-small .half::before {
  content: '★';
  position: absolute;
  left: 0;
  width: 50%;
  overflow: hidden;
  color: gold;
}

.star-rating-small .empty {
  color: #ccc;
}
    .product-card {
      background: #fff;
      border-radius: 12px;
      box-shadow: 0 4px 15px rgba(0,0,0,0.08);
      padding: 1rem;
      display: flex;
      flex-direction: column;
      transition: transform 0.2s;
      position: relative;
      min-height: 320px;
    }

    .product-card:hover {
      transform: translateY(-5px);
      box-shadow: 0 8px 25px rgba(0,0,0,0.12);
    }

    .product-card img {
      max-width: 100%;
      border-radius: 8px;
      margin-bottom: 0.8rem;
    }

    h6 {
      margin: 0.4rem 0;
      font-size: 0.95rem;
      font-weight: 600;
    }

    .brand {
      font-size: 0.8rem;
      color: #6c757d;
      margin-bottom: 0.6rem;
    }

    .price {
      margin-bottom: 1rem;
    }

    .price .old-price {
      text-decoration: line-through;
      color: #6c757d;
      font-size: 0.85rem;
    }

    .price .final-price {
      font-weight: bold;
      color: #198754;
    }

    .actions {
      margin-top: auto;
      display: flex;
      gap: 0.5rem;
    }

    .btn-outline:hover {
      background: #6c757d;
      color: #fff;
    }

    .btn-success {
      background: #198754;
      color: #fff;
    }

    .btn-success:hover {
      background: #146c43;
    }

    /* Swiper navigation */
    .swiper-button-next,
    .swiper-button-prev {
      color: #111827;
    }

    .swiper-pagination-bullet {
      background: #198754;
      opacity: 0.7;
    }

    .swiper-pagination-bullet-active {
      opacity: 1;
    }
    .toastMessage {
    background-color: #28a745;
    color: white;
    padding: 15px 25px;
    margin-top: 10px;
    border-radius: 12px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.2);
    font-weight: 500;
    min-width: 250px;
    max-width: 350px;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.5s ease;
}

.toastMessage.show {
    opacity: 1;
    transform: translateX(0);
}

.toastMessage.hide {
    opacity: 0;
    transform: translateX(100%);
}
/* Box محصولات */
.product-box-modern {
    background: #fff;
    transition: .25s ease;
    border: 1px solid #eee;
}

.product-box-modern:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.08);
}

/* تصویر محصول */
.product-img-hover {
    transition: .3s ease;
    max-height: 190px;
    object-fit: contain;
}
.product-img-hover:hover {
    transform: scale(1.06);
}

/* Badge تخفیف */
.discount-badge-new {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #dc3545;
    color: #fff;
    padding: 4px 9px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: bold;
}

/* محدود کردن طول عنوان محصول */
.product-title-limit {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* کارت بلاگ */
.blog-card-modern:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.10);
}
/* کارت جدید وبلاگ */
.latest-blog-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fc 100%);
    border: 1px solid #eee;
    transition: .25s ease;
}

.latest-blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

/* تصویر وبلاگ */
.blog-image-wrapper {
    flex-shrink: 0;
}

.blog-image {
    width: 120px;
    height: 80px;
    border-radius: 12px;
    object-fit: cover;
    transition: .3s ease;
}

.latest-blog-card:hover .blog-image {
    transform: scale(1.05);
}

/* عنوان وبلاگ */
.blog-title {
    font-size: 15px;
    line-height: 1.5;
}

/* هدر */
.blog-header h5 {
    font-size: 17px;
}

.blog-header small {
    font-size: 13px;
}
.site-logo{
  height: 75px;              /* اندازه جدید لوگو */
  width: auto;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(16,24,40,0.08);
  transition: transform .25s ease;
}

.site-logo:hover{
  transform: scale(1.05);
}

/* تنظیم ارتفاع navbar برای هماهنگی */
.navbar{
  padding-top: 0.6rem;
  padding-bottom: 0.6rem;
}

/* موبایل */
@media (max-width:768px){
  .site-logo{
    height: 60px;
  }
}
/* فقط در نمایش دسکتاپ */
@media (min-width: 992px) {
  /* بهتر کردن انیمیشن منو */
  .dropdown.position-static .dropdown-menu {
    transition: transform .12s ease, opacity .12s ease;
    transform-origin: top center;
  }

  /* وقتی منو باز است آن را واضح‌تر نشان بده */
  .dropdown.position-static.show .dropdown-menu,
  .dropdown.position-static:hover .dropdown-menu {
    transform: translateY(0);
    opacity: 1;
  }

  /* چرخیدن آیکون chevron وقتی زیرمنو باز است */
  .dropdown-submenu button[aria-expanded="true"] i.bi {
    transform: rotate(-90deg);
    transition: transform .18s ease;
  }

  .dropdown-submenu .collapse .dropdown-item {
    padding-right: 0.8rem;
    padding-left: 0.8rem;
  }
}
.dropdown-submenu:hover>.submenu {
  display: block;
}

/* نمایش زیر دسته‌ها روی hover دسکتاپ */
.nav-item.dropdown .dropdown-submenu:hover > .submenu {
  display: block !important;
  position: absolute;
  top: 0;
  left: 100%;
  min-width: 200px;
  background: #fff;
  border-radius: 5px;
  z-index: 1000;
  box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

/* فلش چرخان */
.dropdown-submenu:hover > a i.rotate-icon {
  transform: rotate(-90deg);
  transition: transform 0.3s;
}

/* Logo */
.site-logo{
  height:44px;
  border-radius:10px;
  box-shadow:0 6px 18px rgba(0,0,0,0.08);
}

/* Mobile action buttons */
.mobile-actions{
  gap:8px;
}

.action-btn{
  width:42px;
  height:42px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#f1f3f7;
  color:#333;
  border:none;
  box-shadow:0 4px 10px rgba(0,0,0,0.06);
  transition:0.25s;
  text-decoration:none;
}

.action-btn i{
  font-size:18px;
}

.action-btn:hover{
  background:var(--accent);
  color:#fff;
  transform:translateY(-2px);
}

/* Cart badge */
.badge-cart{
  position:absolute;
  top:-4px;
  right:-4px;
  background:#ff3b30;
  color:#fff;
  font-size:10px;
  padding:3px 6px;
  border-radius:10px;
}

/* Mobile search */
.mobile-search-box{
  display:flex;
  background:#f1f3f7;
  border-radius:30px;
  padding:6px;
  box-shadow:0 6px 18px rgba(0,0,0,0.05);
}

.mobile-search-box input{
  flex:1;
  border:none;
  background:transparent;
  padding:8px 12px;
  outline:none;
}

.mobile-search-box button{
  border:none;
  background:var(--accent);
  color:white;
  border-radius:20px;
  padding:6px 12px;
}

/* Offcanvas modern */
.modern-offcanvas{
  width:280px;
  border-radius:0 20px 20px 0;
  overflow:hidden;
}

.modern-offcanvas .offcanvas-header{
  background:linear-gradient(135deg,var(--accent),#6a8dff);
  color:white;
  border:none;
}

.modern-offcanvas .offcanvas-body{
  padding:15px;
  background:#f8f9fb;
}

/* Menu items */
.menu-item{
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px;
  border-radius:12px;
  text-decoration:none;
  color:#333;
  margin-bottom:8px;
  background:white;
  box-shadow:0 4px 10px rgba(0,0,0,0.04);
  transition:0.25s;
}

.menu-item i{
  font-size:18px;
  color:var(--accent);
}

.menu-item:hover{
  background:var(--accent);
  color:white;
  transform:translateX(-3px);
}

.menu-item:hover i{
  color:white;
}
  /* hover effects for nav links */
  .navbar .nav-link{ color:var(--muted); transition: all .15s ease; }
  .navbar .nav-link:hover{ color:var(--text); background: rgba(30,215,96,0.06); text-decoration:none; }
  .navbar .dropdown-menu .dropdown-item{ transition:.12s; }
  .navbar .dropdown-menu .dropdown-item:hover{ background: rgba(16,24,40,0.03); }
  /* ensure toggler icon visible on light background */
  .navbar-toggler{ border-color: rgba(16,24,40,0.04); }
  .navbar-toggler-icon{ filter: grayscale(1) contrast(.7) opacity(.6); }
  /* small responsive tweak for welcome text */
  @media (max-width:991px){
    .navbar .text-end{ display:none !important; }
  }
      /* --- استایل‌های عمومی اسکلتون لودینگ --- */
    .skeleton-bg {
        background-color: #e0e0e0;
        /* گرادینت متحرک برای افکت موج */
        background-image: linear-gradient(
            90deg, 
            rgba(255, 255, 255, 0) 0, 
            rgba(255, 255, 255, 0.5) 20%, 
            rgba(255, 255, 255, 0.8) 60%, 
            rgba(255, 255, 255, 0)
        );
        background-size: 200px 100%;
        background-repeat: no-repeat;
        background-position: -200px 0;
        animation: skeleton-shimmer 1.5s infinite linear;
        border-radius: 4px;
    }

    @keyframes skeleton-shimmer {
        to {
            background-position: calc(200px + 100%) 0;
        }
    }

    /* کلاس کمکی برای مخفی کردن محتوا تا زمان لود شدن */
    .content-hidden {
        display: none !important;
    }
    /* Quickbar styles */
.top-quickbar {
  background: linear-gradient(90deg, rgba(255,255,255,0.95), rgba(250,250,250,0.9));
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(22, 22, 22, 0.06);
  transition: transform .25s ease, box-shadow .25s ease;
}

/* Buttons */
.quick-btn {
  padding: 10px 22px;
  border-radius: 10px;
  font-weight: 600;
  transition: transform .15s ease, box-shadow .15s ease;
}
.quick-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 18px rgba(0,0,0,0.08);
}

/* responsive */
@media (max-width: 576px){
  .top-quickbar .container { padding-left:8px; padding-right:8px; }
  .quick-btn { padding: 8px 14px; font-size: 14px; }
}

:root{
  --thumb-size: 140px;
  --ring-color-start: #ff4b2b;
  --ring-color-end: #ff416c;
}
@media(max-width:992px){:root{--thumb-size:120px;} }
@media(max-width:576px){:root{--thumb-size:100px;} }

.video-card{
  cursor:pointer;
  transition: transform .3s ease;
}
.video-card:hover, .video-card:focus{
  transform: scale(1.05);
}

.video-thumb-wrap{
  width: var(--thumb-size);
  height: var(--thumb-size);
  border-radius:50%;
  overflow:hidden;
  position: relative;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:5px;
  background: linear-gradient(45deg, #ff4b2b, #ff416c, #ff9a4b, #ff4b2b);
  background-size: 400% 400%;
  animation: gradientMove 6s ease infinite;
  box-shadow: 0 0 20px rgba(255,75,43,0.5), 0 0 40px rgba(255,65,108,0.3);
}

@keyframes gradientMove {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.video-thumb{
  width: 100%;
  height: 100%;
  border-radius:50%;
  object-fit:cover;
  transition: transform .4s ease, box-shadow .3s ease;
}
.video-card:hover .video-thumb{
  transform: scale(1.12);
  box-shadow: 0 0 25px rgba(255,255,255,0.6);
}


.play-overlay{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  background: rgba(0,0,0,0.25);
  border-radius:50%;
  opacity:0;
  transition: opacity .25s ease;
}
.video-card:hover .play-overlay{
  opacity:1;
}

.views-badge{
  position:absolute;
  bottom:6px;
  left:50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.7);
  padding:2px 6px;
  font-size:12px;
  border-radius:12px;
  color:#fff;
}
.video-title{
  font-size:14px;
  font-weight:600;
  color:#fff;
  max-width: var(--thumb-size);
  margin:8px auto 0;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
/* ===== Scroll Wrapper (fade edges like Digikala) ===== */
.cat-icon img{
  width:42px;
  height:42px;
  object-fit:cover;
  border-radius:10px;
}

.modern-scroll-wrapper{
  position: relative;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}

.modern-scroll-wrapper{
  position: relative;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  border-radius:14px;
}


/* ===== CATEGORY CARD ===== */

.cat-card{
  min-width:110px;
  flex:0 0 auto;
  background:#fff;
  border-radius:16px;
  padding:14px 10px;
  text-align:center;
  border:1px solid #eee;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor:pointer;
}

.cat-card:hover{
  transform: translateY(-8px) scale(1.05);
  box-shadow: 0 16px 40px rgba(0,0,0,0.12);
}

.cat-card.active{
  background: linear-gradient(135deg,#ff6b6b,#ff416c);
  color:#fff;
  border:none;
  box-shadow: 0 12px 30px rgba(255,65,108,0.25);
}




.cat-icon{
  width:48px;
  height:48px;
  margin:auto;
  margin-bottom:6px;
  display:flex;
  align-items:center;
  justify-content:center;
}

.cat-icon img{
  width:42px;
  height:42px;
  object-fit:contain;
}

.cat-placeholder{
  width:42px;
  height:42px;
  border-radius:12px;
  background:#f2f2f2;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:bold;
}

.cat-title{
  font-size:13px;
  font-weight:600;
}

.cat-badge{
  position:absolute;
  top:6px;
  left:6px;
  background:#f1f1f1;
  padding:2px 6px;
  border-radius:20px;
  font-size:11px;
}


/* ===== SUBCATEGORY ===== */

.subcat-pill{
  background:#fff;
  border-radius:999px;
  padding:8px 16px;
  border:1px solid #eee;
  font-size:13px;
  transition:.2s;
  white-space:nowrap;
}

.subcat-pill:hover{
  transform:translateY(-3px);
  box-shadow:0 6px 15px rgba(0,0,0,.06);
}

.subcat-pill.active{
  background:linear-gradient(90deg,#00c9a7,#00e4b8);
  color:#004d40;
  border:none;
}


/* ===== BRAND ===== */

.brand-pill{
  background:#fff;
  border-radius:12px;
  padding:8px 14px;
  border:1px solid #eee;
  display:flex;
  align-items:center;
  gap:6px;
  font-size:13px;
  transition:.2s;
  white-space:nowrap;
}

.brand-pill:hover{
  transform:translateY(-3px);
  box-shadow:0 6px 15px rgba(0,0,0,.06);
}

.brand-pill.active{
  background:linear-gradient(90deg,#6c63ff,#8b7bff);
  color:#fff;
  border:none;
}

.brand-thumb{
  height:26px;
  object-fit:contain;
}


/* ===== scrollbar ===== */

.modern-scroll-wrapper::-webkit-scrollbar{
  height:6px;
}

.modern-scroll-wrapper::-webkit-scrollbar-thumb{
  background:#ddd;
  border-radius:10px;
}
.modern-cats-row,
.modern-subcats-row,
.modern-brand-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}

.cat-card,
.subcat-pill,
.brand-pill {
  scroll-snap-align: start;
}


/* افکت هاور روی باکس محصول: کمی بالا آمدن و سایه بیشتر */
.product-box-modern:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1) !important;
    border-color: rgba(0, 0, 0, 0.08);
}

/* کانتینر تصویر برای ایجاد افکت‌های زیبا */
.product-box-modern .text-center {
    position: relative;
    overflow: hidden;
    border-radius: 12px; /* گوشه‌های گرد برای کادر تصویر */
    background-color: #f8f9fa; /* رنگ پس‌زمینه روشن پشت تصویر */
    padding: 0; /* پدینگ را صفر کردیم تا تصویر تمام کادر را پر کند */
    margin-bottom: 1rem; /* کمی فاصله از پایین */
}

/* استایل تصویر محصول */
.product-img-hover {
    width: 100%;
    height: 250px; /* ارتفاع ثابت برای تصویر */
    object-fit: cover; /* تغییر اصلی: تصویر تمام کادر را پر می‌کند و بریده می‌شود */
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    opacity: 0.95;
    border-radius: 12px; /* گرد کردن گوشه‌های خود تصویر */
    display: block; /* حذف فضای خالی زیر تصویر */
}

/* افکت زوم تصویر هنگام هاور */
.product-box-modern:hover .product-img-hover {
    transform: scale(1.08); /* بزرگ شدن تصویر به میزان ۸ درصد */
    opacity: 1;
}




.product-box-modern .btn-success:hover {
    background-color: #218838;
    transform: scale(1.02);
}

/* استایل دکمه جزئیات */
.product-box-modern .btn-outline-dark {
    transition: all 0.3s ease;
}

.product-box-modern .btn-outline-dark:hover {
    background-color: #343a40;
    color: #fff;
}

/* بهینه‌سازی برای موبایل */
@media (max-width: 768px) {
    .product-img-hover {
        height: 200px; /* تنظیم ارتفاع برای موبایل */
    }
}
/* کانتینر کلی */
.categories-menu {
  position: relative;
  font-family: Vazir, sans-serif;
}

/* لینک دسته‌ها */
.category-link {
  display: block;
  padding: 10px 15px;
  border-radius: 25px;
  background: #f8f9fa;
  text-decoration: none;
  color: #333;
  transition: background 0.3s;
}

.category-link:hover {
  background: #e2e6ea;
}

/* dropdown اصلی */
.categories-dropdown {
  position: absolute;
  top: 110%;
  left: 0;
  width: 320px; /* کمی بزرگ‌تر برای دسکتاپ */
  background: #fff;
  box-shadow: 0 6px 24px rgba(0,0,0,0.08);
  border-radius: 12px;
  overflow: hidden;
  display: none;
  z-index: 1000;
  padding: 8px 0;
}

/* نمایش dropdown وقتی hover شد */
.categories-menu:hover .categories-dropdown {
  display: block;
  animation: fadeIn 0.18s ease-in-out;
}

/* هر دسته اصلی */
.category-item {
  border-bottom: 1px solid #f0f0f0;
  position: relative;
}

/* لینک دسته اصلی */
.main-category {
  display: flex;
  justify-content: space-between;
  padding: 10px 16px;
  text-decoration: none;
  color: #333;
  transition: background 0.2s;
}

.main-category:hover {
  background: #f1f3f5;
}

/* فلش کنار دسته اصلی */
.arrow {
  font-size: 12px;
  transition: transform 0.25s;
}

/* زیر دسته‌ها */
.sub-categories {
  display: none;
  flex-direction: column;
  background: #f8f9fa;
  padding: 6px 0;
}

.sub-category {
  padding: 8px 30px;
  text-decoration: none;
  color: #555;
  transition: background 0.2s;
}

.sub-category:hover {
  background: #e9ecef;
}

/* نمایش زیر دسته‌ها وقتی روی دسته اصلی hover شد */
.category-item:hover .sub-categories {
  display: flex;
  animation: slideDown 0.2s ease-in-out;
}

/* انیمیشن‌ها */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-6px);}
  to { opacity: 1; transform: translateY(0);}
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px);}
  to { opacity: 1; transform: translateY(0);}
}

/* موبایل: ظاهری مدرن‌تر برای منو و آیکون‌ها */
@media (max-width: 991.98px) {
  .navbar-brand { gap: 10px; }
  .site-logo { height:44px; }
  /* دکمه‌های بالای موبایل کوچکتر و گرد */
  .navbar .btn { border-radius:12px; }
  .offcanvas-body a { font-size: 0.98rem; }
  /* فاصله داخلی بیشتر برای آیشمینه های موبایل */
  .offcanvas .list-unstyled li { padding-left: 0; padding-right: 0; }
}
 /* ===========================
     Mobile-only visual improvements
     =========================== */

  /* make a small set of CSS variables for accenting mobile */
  :root {
    --mobile-accent: #2b8cff;
    --mobile-bg: #ffffff;
    --mobile-muted: #6b7280;
    --mobile-radius: 14px;
  }

  /* Mobile icon buttons - larger tappable area */
  .mobile-icon-btn {
    width:44px;
    height:44px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:12px;
    background:transparent;
    transition:transform .12s ease, background .12s ease;
  }
  .mobile-icon-btn:active { transform:scale(.97); }
  .mobile-icon-btn i { font-size:1.05rem; }

  /* cart badge small and large */
  .cart-badge { font-size:0.72rem; padding:.25rem .45rem; }
  .cart-badge-lg { font-size:0.85rem; padding:.4rem .6rem; }

  /* mobile search card */
  .mobile-search-card {
    border-radius:999px;
    overflow:hidden;
    border:1px solid rgba(16,24,40,0.06);
  }
  .mobile-search-btn {
    background:var(--mobile-accent);
    color:#fff;
    font-weight:700;
    padding:0 1rem;
    border-radius:0;
  }

  /* Offcanvas header improvements */
  .mobile-logo { height:40px; width:40px; border-radius:8px; object-fit:cover; }
  .mobile-offcanvas-header .offcanvas-title { font-weight:700; }
  .offcanvas-body { padding-bottom:80px; } /* give space above bottom nav */

  /* mobile card style in offcanvas */
  .mobile-card { padding: .9rem; border-radius:12px; }

  /* Mobile bottom nav */
  .mobile-bottom-nav {
    position:fixed;
    left:0;
    right:0;
    bottom:0;
    height:64px;
    background:linear-gradient(180deg, rgba(255,255,255,0.95), rgba(250,250,250,0.98));
    box-shadow: 0 -8px 30px rgba(16,24,40,0.06);
    display:flex;
    justify-content:space-around;
    align-items:center;
    gap:0.25rem;
    padding:6px 10px;
    z-index:1060; /* above offcanvas backdrop */
    border-top-left-radius:12px;
    border-top-right-radius:12px;
    backdrop-filter: blur(4px);
  }
  .mbn-item {
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    text-decoration:none;
    color:#333;
    font-size:11px;
    width:56px;
    height:56px;
    border-radius:12px;
    gap:2px;
    transition:transform .12s, background .12s, color .12s;
    position:relative;
  }
  .mbn-item i { font-size:18px; }
  .mbn-item:hover { transform:translateY(-3px); }
  .mbn-item.central-action {
    background:var(--mobile-accent);
    color:#fff;
    width:64px;
    height:64px;
    margin-top:-18px;
    box-shadow:0 8px 16px rgba(43,140,255,0.18);
    font-weight:600;
    display:flex;
    align-items:center;
    justify-content:center;
  }
  .mbn-badge {
    position:absolute;
    top:6px;
    right:8px;
    background:#ff4d4f;
    color:white;
    font-size:10px;
    padding:2px 6px;
    border-radius:999px;
  }

  /* small-screen only rules (make sure desktop unchanged) */
  @media (min-width: 992px) {
    .mobile-bottom-nav, .mobile-icon-btn, .mobile-search-card { display:none !important; }
  }

  /* Accessibility: increase tap target for offcanvas menu items */
  .mobile-offcanvas-list a { padding: .8rem .75rem; display:block; border-radius:8px; }
  #mobileSidebar .collapse .sub-categories a { padding-left:1rem; }

  /* subtle hover */
  #mobileSidebar a:hover, #mobileSidebar .mobile-card:hover { background: rgba(43,140,255,0.04); transition: background .12s ease; }

  /* small alignment fixes for mobile controls */
  .mobile-controls .mobile-cart-btn .cart-text { display:none; }
  @media (min-width: 420px) {
    .mobile-controls .mobile-cart-btn .cart-text { display:inline; margin-left:6px; }
  }

  /* ensure content above bottom nav */
  body { padding-bottom:72px; } /* ensure page content doesn't hide under bottom nav on small screens */