
body {
  background-color: #e5dac9 !important; /* New creamy background color */
  color: var(--text-color);
  overflow-x: hidden;
}


/* Prevent horizontal scrolling on mobile */
.container, .container-fluid {
  max-width: 100%;
  overflow-x: hidden;
}

/* Navbar logo styles */

/* Responsive navbar brand */
@media (max-width: 576px) {
  .navbar-brand-text {
    font-size: 1.1rem !important;
  }

  .navbar-logo {
    height: 45px !important;
    max-width: 150px !important;
  }
}

/* Even larger for extra small mobile */
@media (max-width: 360px) {
  .navbar-brand-text {
    font-size: 1rem !important;
  }

  .navbar-logo {
    height: 40px !important;
    max-width: 130px !important;
  }
}

/* Ensure all content fits within viewport */
* {
  box-sizing: border-box;
}

/* Product card styles */
.product-card {
  position: relative;
}

.product-card-img {
  height: 250px;
  object-fit: cover;
}

/* Remove hover effects from product card links */
.product-link {
  text-decoration: none;
  color: inherit;
}

.product-link:hover {
  /* Removed hover effect for performance */
  text-decoration: none;
  color: inherit;
}

.product-card a {
  text-decoration: none;
  color: inherit;
}


/* Out of stock overlay */
.out-of-stock-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
  text-align: center;
  padding: 10px;
  border-radius: calc(0.375rem - 1px) calc(0.375rem - 1px) 0 0;
}

.product-card {
  position: relative;
}

/* Custom Modal Close Button */
.custom-modal-close {
  position: absolute;
  top: -15px;
  left: -15px; /* Outside the modal top-left */
  z-index: 1060;
  background-color: white;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  opacity: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: bold;
}

/* Product added badge */
.product-added-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background-color: #28a745;
  color: white;
  border-radius: 50%;
  width: 25px;
  height: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: bold;
  z-index: 10;
}

/* Best Selling Products Slider - Compact Version */
.best-selling-slider {
  margin: 20px 0;
  padding: 15px 0;
}



.best-selling-product-card {
  margin: 0 5px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  overflow: hidden;
  background: white;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  transition: transform 0.2s ease;
  height: auto;
}

.best-selling-product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}

.best-selling-product-img {
  width: 100%;
  height: 120px;
  object-fit: cover;
}

.best-selling-product-info {
  padding: 10px;
}

.best-selling-product-title {
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 5px;
  height: 32px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.best-selling-product-price {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 8px;
}

.slick-prev, .slick-next {
  width: 24px;
  height: 24px;
  z-index: 10;
}

.slick-prev:before, .slick-next:before {
  font-size: 18px;
  color: var(--primary-color);
}

/* Reduce spacing for all sections on homepage */
.section {
  margin-bottom: 10px !important;
}

.section .row.mb-4 {
  margin-bottom: 5px !important;
}

.section-title {
  margin-bottom: 5px !important;
}

.section-subtitle {
  margin-bottom: 5px !important;
}

/* Subcategories Carousel */
.subcategories-carousel {
  margin: 0 0 5px 0;
  position: relative;
}

.subcategory-card-wrapper {
  padding: 0 5px;
  height: 100%;
}

/* Badge - ribbon style */
.subcategories-carousel .badge {
  font-size: 0.875rem !important;
  padding: 8px 20px 8px 30px !important;
  border-radius: 0 8px 8px 0 !important;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25), inset 0 1px 0 rgba(255,255,255,0.3), inset 0 -1px 0 rgba(0,0,0,0.15);
  position: absolute;
  top: 0;
  left: -25px;
  z-index: 10;
}

.subcategories-carousel .slick-track {
  display: flex;
  align-items: stretch;
}

.subcategories-carousel .slick-slide {
  height: auto;
}

.subcategories-carousel .slick-slide > div {
  height: 100%;
}

/* Card — matching category.php exactly */
.subcategories-carousel .category-card,
.subcategory-card-wrapper .category-card {
  text-align: center;
  background: white !important;
  border: 2px solid #d4af37 !important;
  border-radius: 0.75rem !important;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.1) !important;
  transition: all 0.3s ease !important;
  display: flex;
  flex-direction: column;
  margin: 0;
  height: 300px !important;      /* ثابت */
  max-height: 300px !important;
}

.subcategories-carousel .category-card:hover,
.subcategory-card-wrapper .category-card:hover {
  transform: translateY(-5px) !important;
  box-shadow: 0 8px 25px rgba(212, 175, 55, 0.3) !important;
  border-color: #ffd700 !important;
}

.subcategories-carousel .category-link {
  text-decoration: none;
  color: inherit;
  display: block;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Image wrapper — matching category.php */
.subcategories-carousel .category-image-wrapper {
  position: relative;
  width: 100%;
  height: 180px !important;
  min-height: 180px !important;
  max-height: 180px !important;
  display: flex !important;
  align-items: flex-start !important;
  justify-content: center;
  overflow: hidden;
  padding: 0 !important;
  flex: none !important;
}

.subcategories-carousel .category-image {
  width: 100%;
  height: 100%;
  object-fit: cover !important;
  border-radius: 0 !important;
}

/* Info area — matching category.php */
.subcategory-info-blur {
  background: transparent !important;
  backdrop-filter: none !important;
  padding: 0 !important;
  margin-top: 0;
  box-shadow: none !important;
  flex: 1;
}

.subcategory-info-content {
  background: transparent !important;
  color: #333;
  text-align: center;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

/* Store name */
.subcategory-name {
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0 0 2px 0;
  color: #2c3e50;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  padding: 0 !important;
}

.description-separator {
  margin: 4px auto 8px auto;
  border: 0;
  border-top: 1px solid #d4af37;
  opacity: 0.4;
  width: 35%;
  flex-shrink: 0;
}

/* Description */
.subcategory-description {
  font-size: 0.85rem;
  margin: 0;
  color: #1a1a1a;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 1;         /* سطر واحد فقط */
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;           /* يمنع الانتقال لسطر جديد */
  font-weight: 500;
}

/* Prevent overscroll/bounce on mobile */
.subcategories-carousel .slick-list {
  overflow: hidden; /* Changed back to hidden */
  position: relative;
  touch-action: pan-y;
  padding: 0 !important; /* Reset padding */
}

/* Back to Top Button */
.back-to-top-btn {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 45px;
  height: 45px;
  background-color: #f2711c; /* Vibrant Orange */
  color: white;
  border: 3px solid white; /* Double-like border effect can be achieved with box-shadow or extra border */
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1050;
  cursor: pointer;
  box-shadow: 0 0 0 2px #f2711c, 0 4px 12px rgba(0,0,0,0.2); /* Double ring effect */
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-size: 1.2rem;
  padding: 0;
  outline: none;
}

.back-to-top-btn:hover {
  transform: scale(1.1);
  background-color: #e0610e;
  box-shadow: 0 0 0 2px #e0610e, 0 6px 15px rgba(0,0,0,0.3);
}

.back-to-top-btn.show {
  display: flex;
}

/* Mobile responsiveness for best selling slider */
@media (max-width: 768px) {
  .best-selling-product-img {
    height: 100px;
  }
  
  .subcategories-carousel .category-image-wrapper {
    height: 160px !important;
  }
  
  .subcategory-card-wrapper {
    padding: 0 3px;
  }
  
  .best-selling-product-title {
    font-size: 0.75rem;
    height: 28px;
  }
  
  .best-selling-product-price {
    font-size: 0.85rem;
  }
}

@media (max-width: 576px) {
  .best-selling-product-img {
    height: 90px;
  }
  
  .best-selling-product-info {
    padding: 8px;
  }
  
  .best-selling-product-title {
    font-size: 0.7rem;
    height: 26px;
  }
  
  .best-selling-product-price {
    font-size: 0.8rem;
  }
  
  .add-to-cart-btn {
    font-size: 0.75rem;
    padding: 4px 8px;
  }
}

/* Global Add to Cart Button Color */
.add-to-cart-btn, #modalAddToCartBtn {
  background-color: #dc3545 !important;
  border-color: #dc3545 !important;
  color: white !important;
  transition: all 0.3s ease !important;
}

.add-to-cart-btn:hover, #modalAddToCartBtn:hover {
  background-color: #c82333 !important;
  border-color: #bd2130 !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(220, 53, 69, 0.3) !important;
}

/* Global Price Color */
.product-card .card-text.text-primary, 
.best-selling-product-price, 
#modalProductPrice {
  color: #198754 !important; /* Green color for prices */
}

/* Dark Gold Product Code */
.product-card .text-muted.small, .product-code-text {
  color: #996515 !important;
  font-weight: 600;
}

/* Bold and Larger Product Names */
.product-card .card-title {
  font-size: 1.15rem !important;
  font-weight: 700 !important;
  color: #2c3e50 !important;
  margin-bottom: 10px !important;
}

/* Solid Green View Button */
.btn-outline-primary {
  background-color: #198754 !important; /* Solid Green */
  color: white !important;
  border-color: #198754 !important;
}

.btn-outline-primary:hover {
  background-color: #157347 !important;
  border-color: #146c43 !important;
  transform: translateY(-1px);
}

@media (max-width: 576px) {
  .product-card .card-title {
    font-size: 0.8rem !important;
    white-space: normal; /* Allow text wrapping */
    overflow: visible;   /* Ensure text is seen */
    line-height: 1.3;    /* Better spacing for wrapped text */
    margin-bottom: 4px;
  }
}

/* =========================================
   MODAL TRANSPARENCY & GLASSMORPHISM
   ========================================= */

/* BACKDROP BLUR - Enhanced for Premium Look */
.modal-backdrop.show {
    opacity: 0.7 !important; /* Strong darkening - Portrait Mode */
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    background-color: rgba(0, 0, 0, 0.5) !important;
    /* أعلى من شريط التنقل السفلي (z-index: 2000) */
    z-index: 2100 !important;
}

/* Modal Dialog - Transparent Container (عرض المودال من CSS ليتغير على الديسكتوب) */
#productQuickViewModal .modal-dialog.product-quick-view-modal-dialog {
    width: 90% !important;
    max-width: 330px !important;
    background: transparent !important;
    background-color: transparent !important;
    pointer-events: none !important;
}
#productQuickViewModal .modal-dialog {
    background: transparent !important;
    background-color: transparent !important;
    pointer-events: none !important;
}
/* المنبثقة فوق شريط التنقل السفلي */
#productQuickViewModal {
    z-index: 2200 !important;
}

/* Modal Content - Transparent Wrapper */
#productQuickViewModal .modal-content {
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    pointer-events: auto !important;
}

/* Modal Body - Transparent */
#productQuickViewModal .modal-body {
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    padding: 0 !important;
}

/* Row Container - Transparent (عمودي على الجوال) */
#productQuickViewModal .row.g-0.product-modal-inner-row {
    flex-direction: column !important;
    border: none !important;
}
#productQuickViewModal .row.g-0 {
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
}

/* Column Wrappers - Transparent */
#productQuickViewModal .col-md-5,
#productQuickViewModal .col-md-7 {
    background: transparent !important;
    background-color: transparent !important;
}

/* Force all children to be transparent unless explicitly styled */
#productQuickViewModal .modal-dialog > *,
#productQuickViewModal .modal-content > *:not(.super-close-btn),
#productQuickViewModal .modal-body > * {
    background: transparent !important;
    background-color: transparent !important;
}

/* Product Quick View Modal Styles */
.product-modal-image-container {
  height: 300px;
  width: 100%;
  background: #f8f9fa;
  border-radius: 15px;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

#modalProductImage {
  max-height: 100%;
  width: 100%;
  object-fit: cover;
  /* Fill the container completely */
}

#modalProductAttributes {
  max-height: 250px;
  overflow-y: auto;
}

#modalProductAttributes::-webkit-scrollbar {
  width: 6px;
}

#modalProductAttributes::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

#modalProductAttributes::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 10px;
}

.attribute-item {
  display: flex;
  align-items: center;
  padding: 10px 15px;
  border-bottom: 1px solid #f0f0f0;
  transition: all 0.2s ease;
  cursor: pointer;
  gap: 15px;
}

.attribute-item:hover {
  background-color: #f8f9fa;
}

.attribute-label {
  flex: 1;
  font-size: 1rem;
  color: #2c3e50;
  cursor: pointer;
  text-align: right;
}

.attribute-input-field {
  width: 24px;
  height: 24px;
  accent-color: #198754;
}

#productQuickViewModal .btn-close {
  background-color: #dc3545;
  background-image: none;
  border-radius: 50%;
  width: 35px;
  height: 35px;
  opacity: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  position: relative;
  cursor: pointer;
}

#productQuickViewModal .btn-close::before {
  content: "\00d7";
  font-size: 28px;
}
/* Multi-step Navigation Styles */
/* Multi-step Modal Navigation */
.modal-step-indicator-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 12px;
  background: #f8f9fa;
  border-radius: 10px;
  margin-bottom: 1rem;
}

.modal-step-indicator {
  font-weight: bold;
  color: #2c3e50;
  font-size: 0.9rem;
}

.modal-step-name {
  font-weight: bold;
  color: #2c3e50;
  font-size: 0.9rem;
}

.modal-navigation {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
}

.nav-btn {
  flex: 1;
  padding: 6px;
  border-radius: 40px;
  border: none;
  font-weight: bold;
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.nav-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  border-radius: 50px;
  font-weight: bold;
  border: none;
  transition: all 0.3s ease;
  font-size: 1rem;
  cursor: pointer;
}

.nav-btn-next {
  background-color: #dc3545;
  color: white;
  box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.nav-btn-next:hover {
  background-color: #c82333;
  transform: translateY(-2px);
}

.nav-btn-back {
  background-color: #f8f9fa;
  color: #6c757d;
  border: 1px solid #dee2e6;
}

.nav-btn .bi {
  font-size: 1.2rem;
}

.attribute-group {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.attribute-group.d-none {
  display: none !important;
}

@media (max-width: 768px) {
  .product-modal-image-container {
    height: 250px;
  }
}

@media (max-width: 576px) {
  .product-modal-image-container {
    height: 180px;
  }
}

/* Section styling - Single line layout */
.section-title {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  justify-content: space-between !important;
  align-items: center !important;
  padding: 0 0 10px 0 !important;
  margin-bottom: 12px !important;
  background: transparent !important;
  border: none !important;
}

.section-title-main {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 8px; /* Compact gap between name and count */
  margin-left: 15px; /* Space before the View All button */
}

.section-title-text {
  font-size: 0.95rem !important;
  font-weight: 800 !important;
  color: #1a1a1a !important;
  margin: 0 !important;
  white-space: nowrap !important; /* Keep it on one line as requested */
}

/* View All button styling - Small and Light Green */
.section-title .view-all-btn {
  flex-shrink: 0;
  white-space: nowrap;
  padding: 5px 14px !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  border-radius: 50px !important;
  transition: all 0.2s ease;
  text-decoration: none !important;
  display: inline-block;
  background: #eaf8ef !important; /* Very light green */
  color: #2fb344 !important; /* Green text */
  border: none !important;
  margin-right: auto; /* Push to the left in RTL */
}

.section-title .view-all-btn:hover {
  background: #dcf2e4 !important;
  color: #269a3a !important;
  transform: translateY(-1px);
}


.section-title span {
  flex: none; /* Prevent stretching */
}

/* Badge for count - Small and Compact */
.section-product-count {
  background-color: #fdf2f2 !important; /* Very light red */
  color: #f15c5c !important; /* Red text */
  padding: 2px 10px !important; /* Compact padding */
  border-radius: 50px !important;
  font-size: 0.75rem !important;
  font-weight: 600 !important;
  margin: 0 !important;
  box-shadow: none !important;
  border: none !important;
  white-space: nowrap;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important; /* Don't stretch */
}

.section-subtitle {
  color: #6c757d;
  font-size: 1.1rem;
}

/* Categories grid styling */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 15px;
  margin-bottom: 30px;
  padding: 0 10px;
  width: 100%;
  overflow-x: hidden;
}

.category-item {
  text-align: center;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

.category-link {
  text-decoration: none;
  color: inherit;
  display: block;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
}

/* Main Categories Grid - Scoped Circular Design */
.categories-grid .category-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1 !important;
  margin-bottom: 12px;
  border-radius: 50% !important;
  border: 3px solid #d4af37 !important; /* Golden border */
  overflow: hidden;
  background-color: transparent !important; /* Transparent background */
  box-shadow: 0 4px 10px rgba(0,0,0,0.1) !important;
  display: flex;
  align-items: center;
  justify-content: center;
}

#categories .category-image {
  width: 100%;
  height: 100%;
  object-fit: cover !important;
  border-radius: 50% !important;
}

#categories .category-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: transparent !important;
  color: #d4af37 !important;
  font-size: 2rem !important;
}

.category-name {
  font-weight: 500;
  font-size: 0.95rem;
  line-height: 1.3;
  padding: 0 2px;
  margin-top: 5px;
  display: block;
}

.featured-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  background-color: #ffc107;
  color: #000;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  z-index: 2;
}

/* Button styles */
.btn-primary {
  background-color: var(--button-primary-color) !important;
  border-color: var(--button-primary-color) !important;
  color: var(--button-text-color) !important;
}

.btn-primary:hover {
  /* Removed hover effect for performance */
  background-color: var(--button-primary-color) !important;
  border-color: var(--button-primary-color) !important;
}

.btn-secondary {
  background-color: var(--button-secondary-color) !important;
  border-color: var(--button-secondary-color) !important;
  color: var(--button-text-color) !important;
}

.btn-secondary:hover {
  /* Removed hover effect for performance */
  background-color: var(--button-secondary-color) !important;
  border-color: var(--button-secondary-color) !important;
}

/* Add to cart button */
.add-to-cart-btn {
  background-color: var(--button-primary-color);
  border-color: var(--button-primary-color);
  color: var(--button-text-color);
}

.add-to-cart-btn:hover {
  /* Removed hover effect for performance */
  background-color: var(--button-primary-color);
  border-color: var(--button-primary-color);
  color: var(--button-text-color);
}

/* Responsive adjustments */
@media (max-width: 576px) {
  .categories-grid {
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
    padding: 0 5px;
    overflow-x: hidden;
  }
  
  .category-image-wrapper,
  .category-placeholder {
    height: auto;
  }
  
  .category-name {
    font-size: 0.85rem;
    margin-top: 3px;
    display: block;
  }
  
  .featured-badge {
    width: 18px;
    height: 18px;
  }
  
  /* Mobile cart adjustments */
  .cart-dropdown-below {
    width: calc(100vw - 30px);
    max-height: 75vh;
  }
}

@media (min-width: 992px) {
  .categories-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }
  
  .category-image-wrapper,
  .category-placeholder {
    height: auto !important;
  }
}

/* Ensure main container matches search-categories section width */
@media (min-width: 769px) and (max-width: 991px) {
  .container.my-5,
  .container {
    max-width: 960px !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); /* Subtle shadow for depth */
  }
}

.floating-cart-btn-container {
    position: relative;
    transform: translateY(25px); /* Raised higher (half-out) */
    margin-bottom: -25px; /* Pull parent up to match */
    z-index: 10;
    margin-top: 5px;
    text-align: center;
}

/* Make modal corners rounder and ensure overflow */
.modal-content {
    border-radius: 30px !important;
    overflow: visible !important;
    border: none !important;
}

@media (min-width: 768px) and (max-width: 1199px) {
  .container.my-5,
  .container {
    max-width: 960px !important;
  }
}

/* Mobile bottom navigation bar - Beautiful and Modern Design */
@media (max-width: 767px) {
  .mobile-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, #ffffff 0%, #f8f9fa 100%);
    border-top: 2px solid #e9ecef;
    padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
    z-index: 1030;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.12);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
  }

  .mobile-nav-content {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 0 4px;
    gap: 6px;
    max-width: 100%;
  }

  .mobile-nav-item {
    flex-shrink: 0;
    text-align: center;
    min-width: 70px;
    flex: 0 0 auto;
  }

  .mobile-nav-item a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #6c757d;
    font-size: 0.7rem;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 4px 6px;
    border-radius: 12px;
    min-height: 45px;
    position: relative;
  }

  .mobile-nav-item a:hover,
  .mobile-nav-item a.active {
    color: var(--primary-color);
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.1) 0%, rgba(var(--primary-color-rgb), 0.15) 100%);
    transform: translateY(-2px);
  }

  .mobile-nav-item a.active::before {
    content: '';
    position: absolute;
    top: 0;
    right: 50%;
    transform: translateX(50%);
    width: 40%;
    height: 3px;
    background: var(--primary-color);
    border-radius: 0 0 3px 3px;
  }

  .mobile-nav-item i {
    font-size: 1.3rem;
    margin-bottom: 2px;
    display: block;
  }

  .mobile-nav-item span {
    font-size: 0.65rem;
    font-weight: 600;
    line-height: 1.1;
  }

  .mobile-categories-scroll {
    flex: 1;
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    gap: 10px;
    padding: 0 8px;
    scroll-behavior: smooth;
  }

  .mobile-categories-scroll::-webkit-scrollbar {
    display: none;
  }

  .mobile-category-item {
    flex-shrink: 0;
    min-width: 65px;
    max-width: 80px;
    text-align: center;
  }

  .mobile-category-item a {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #495057;
    font-size: 0.65rem;
    font-weight: 500;
    padding: 4px 4px;
    border-radius: 12px;
    min-height: 45px;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .mobile-category-item a:hover,
  .mobile-category-item a:active {
    color: var(--primary-color);
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.1) 0%, rgba(var(--primary-color-rgb), 0.15) 100%);
    transform: translateY(-2px);
  }

  .mobile-category-image-wrapper {
    width: 35px !important;
    height: 35px !important;
    margin-bottom: 3px !important;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
  }

  .mobile-category-item a:hover .mobile-category-image-wrapper,
  .mobile-category-item a:active .mobile-category-image-wrapper {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }

  .mobile-category-image {
    width: 35px !important;
    height: 35px !important;
    object-fit: cover;
    border-radius: 10px;
  }

  .mobile-category-placeholder {
    width: 35px !important;
    height: 35px !important;
    border-radius: 10px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 1.3rem !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  }

  .mobile-category-name {
    display: block;
    line-height: 1.2;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.65rem !important;
    font-weight: 500;
    margin-top: 0 !important;
  }

  /* Cart badge improvements */
  .mobile-nav-item .badge {
    font-size: 0.65rem !important;
    padding: 3px 5px !important;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
  }

  /* Smooth animations */
  @keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
  }

  .mobile-nav-item a:active,
  .mobile-category-item a:active {
    animation: bounce 0.3s ease;
  }

  /* Safe area for devices with notch */
  @supports (padding: max(0px)) {
    .mobile-nav {
      padding-bottom: max(6px, env(safe-area-inset-bottom));
    }
  }
}



/* =========================================
   PRODUCT QUICK VIEW MODAL
   MOVED TO: assets/components/product-modal/product-modal.css
   ========================================= */

