/* ===== PERLA COSMETIC - MAIN STYLES ===== */
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800&display=swap');

:root {
  --pink-light: #9be4f1;
  --pink-main: #18bddc;
  --pink-dark: #10b8d7;
  --pink-deep: #18bddc;
  --pink-bg: #fff5f8;
  --white: #ffffff;
  --gray-light: #f8f8f8;
  --gray: #e0e0e0;
  --gray-text: #757575;
  --dark: #2d2d2d;
  --shadow: 0 2px 12px rgba(244,143,177,0.15);
  --shadow-hover: 0 8px 30px rgba(244,143,177,0.3);
  --radius: 14px;
  --radius-sm: 8px;
  --transition: all 0.25s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Cairo', sans-serif;
  direction: rtl;
  background: var(--white);
  color: var(--dark);
  line-height: 1.6;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; }
button { cursor: pointer; font-family: 'Cairo', sans-serif; }
input, select, textarea { font-family: 'Cairo', sans-serif; }

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--pink-light); }
::-webkit-scrollbar-thumb { background: var(--pink-main); border-radius: 3px; }
/* ===== NEW ADDITIONS TO style.css =====*/

/* 1. WHATSAPP ORDER MODAL */
.modal {
  position: fixed;
  overflow: auto;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 80vh;
  max-height: 80vh;
  background: white;
  border-radius: 30px 30px 0 0;
  z-index: 2000;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  display: flex;
  flex-direction: column;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
  -webkit-overflow-scrolling: touch;
}

.modal.active {
  transform: translateY(0);
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1999;
  display: none;
}

.modal-overlay.active {
  display: block;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid #f0f0f0;
  flex-shrink: 0;
}

.modal-header h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--pink-deep);
}

.modal-close {
  background: none;
  border: none;
  font-size: 28px;
  color: #999;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
}

.modal-close:hover {
  color: var(--pink-main);
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  -webkit-overflow-scrolling: touch;
}

.form-section {
  margin-bottom: 24px;
}

.form-section h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--pink-deep);
  margin-bottom: 16px;
  margin-top: 0;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: #333;
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 14px;
  font-family: 'Cairo', sans-serif;
  transition: border-color 0.2s;
  box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--pink-main);
}

.order-summary {
  background: #f9f9f9;
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 12px;
  max-height: 200px;
  overflow-y: auto;
}

.order-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e0e0e0;
  font-size: 13px;
}

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

.order-item-name {
  flex: 1;
  color: #333;
}

.order-item-qty {
  color: #999;
  margin: 0 8px;
}

.order-item-price {
  color: var(--pink-main);
  font-weight: 600;
}

.order-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  background: var(--pink-light);
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--pink-deep);
}

.form-actions {
  display: flex;
  gap: 12px;
  padding: 20px;
  border-top: 1px solid #f0f0f0;
  flex-shrink: 0;
}

.form-actions button {
  flex: 1;
  padding: 12px 16px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  font-family: 'Cairo', sans-serif;
}

.form-actions .btn-outline {
  background: #f0f0f0;
  color: #333;
}

.form-actions .btn-outline:active {
  background: #e0e0e0;
}

.form-actions .btn-primary {
  background: var(--pink-main);
  color: white;
}

.form-actions .btn-primary:active {
  transform: scale(0.98);
}

/* 2. FILTERS BOTTOM SHEET UPDATE */

.filters-sidebar.mobile-open {
  transform: translateY(0);
}

/* 3. FILTER MOBILE ACTIONS */
.filter-mobile-actions {
  display: none;
  gap: 12px;
  padding: 16px 0;
  border-top: 1px solid #e0e0e0;
  margin-top: 16px;
}

@media (max-width: 768px) {
  .filter-mobile-actions {
    display: flex;
  }
  
  .filter-mobile-actions button {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Cairo', sans-serif;
  }
  
  .filter-mobile-actions .btn-primary {
    background: var(--pink-main);
    color: white;
  }
  
  .filter-mobile-actions .btn-outline {
    background: #f0f0f0;
    color: #333;
  }
}

/* 4. BRANDS CAROUSEL */
.brands-list {
  display: flex;
  gap: 12px;
  overflow: hidden;
  padding: 12px 0;
  position: relative;
  width: 100%;
}

.brands-list::-webkit-scrollbar {
  display: none;
}

.brand-chip {
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  background: var(--pink-light);
  color: var(--pink-deep);
  border: 2px solid var(--pink-main);
  border-radius: 25px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Cairo', sans-serif;
  white-space: nowrap;
  flex-shrink: 0;
  animation: scrollBrands 20s linear infinite;
}



.brand-chip:hover {
  background: var(--pink-main);
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(233, 30, 140, 0.3);
  animation-play-state: paused;
}

.brand-chip:active {
  transform: translateY(-1px);
}

@keyframes scrollBrands {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-100vw);
  }
}
/* ===== HEADER ===== */
.header {
  background: var(--white);
  box-shadow: 0 2px 15px rgba(244,143,177,0.12);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-top {
  background: linear-gradient(135deg, var(--pink-deep), var(--pink-dark));
  color: white;
  text-align: center;
  padding: 8px;
  font-size: 13px;
  font-weight: 600;
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  max-width: 1400px;
  margin: 0 auto;
  gap: 16px;
}

.logo img { height: 65px; object-fit: contain; }

.search-bar {
  flex: 1;
  max-width: 500px;
  position: relative;
  margin:  auto;
}

.search-bar input {
  width: 100%;
  padding: 11px 20px 11px 48px;
  border: 2px solid var(--pink-light);
  border-radius: 50px;
  font-size: 14px;
  outline: none;
  transition: var(--transition);
  background: var(--pink-bg);
}

.search-bar input:focus { border-color: var(--pink-main); background: white; }

.search-bar button {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--pink-dark);
  font-size: 18px;
}

.header-actions { display: flex; align-items: center; gap: 12px; }

.cart-btn {
  background: #18bddc;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
  position: relative;
}

.cart-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }

.cart-count {
  background: white;
  color: var(--pink-deep);
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
}

/* ===== NAV ===== */
.nav {
  background: var(--pink-bg);
  border-top: 1px solid var(--pink-light);
  overflow-x: auto;
}

.nav-inner {
  display: flex;
  overflow-y: hidden;
  overflow-x: auto;

  align-items: center;
  gap: 4px;
  padding: 0 24px;
  max-width: 1400px;
  margin: 0 auto;
  white-space: nowrap;
}

.nav-item {
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 600;
  color: var(--dark);
  border-bottom: 3px solid transparent;
  transition: var(--transition);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-item:hover, .nav-item.active {
  color: var(--pink-deep);
  border-bottom-color: var(--pink-deep);
}

/* ===== HERO ===== */
.hero {
  padding: 60px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(244,143,177,0.2) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content { position: relative; z-index: 1; max-width: 700px; margin: 0 auto; }

.hero h1 {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 800;
  color: var(--pink-deep);
  margin-bottom: 16px;
  line-height: 1.3;
}

.hero p {
  font-size: 17px;
  color: var(--gray-text);
  margin-bottom: 32px;
}

.hero-btns { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.btn-primary {
  background: #18bddc;
  color: white;
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 700;
  border: none;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }

.btn-outline {
  background: transparent;
  color: var(--pink-deep);
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 700;
  border: 2px solid var(--pink-deep);
  transition: var(--transition);
}

.btn-outline:hover { background: var(--pink-deep); color: white; }

/* ===== SECTION ===== */
.section { padding: 50px 24px; max-width: 1400px; margin: 0 auto; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 12px;
}

.section-title {
  font-size: 24px;
  font-weight: 800;
  color: var(--dark);
  position: relative;
  padding-right: 16px;
}

.section-title::before {
  content: '';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 28px;
  background: linear-gradient(var(--pink-dark), var(--pink-deep));
  border-radius: 2px;
}

.view-all {
  color: var(--pink-deep);
  font-weight: 600;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition);
}

.view-all:hover { gap: 8px; }

/* ===== CATEGORIES GRID ===== */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 16px;
}

.category-card {
  background: var(--white);
  border: 2px solid var(--pink-light);
  border-radius: var(--radius);
  padding: 20px 12px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
}

.category-card:hover, .category-card.active {
  border-color: var(--pink-dark);
  background: var(--pink-bg);
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.category-icon { font-size: 32px; margin-bottom: 8px; }
.category-name { font-size: 13px; font-weight: 600; color: var(--dark); }

/* ===== PRODUCTS LAYOUT ===== */
.products-page { display: flex; gap: 24px; max-width: 1400px; margin: 0 auto; padding: 24px; }

/* ===== FILTERS SIDEBAR ===== */
.filters-sidebar {
  width: 260px;
  flex-shrink: 0;
  background: var(--white);
  border: 1px solid var(--pink-light);
  border-radius: var(--radius);
  padding: 20px;
  height: fit-content;
    position: fixed;

  position: sticky;
  
  top: 90px;
}

.filter-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--pink-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.filter-section { margin-bottom: 20px; }

.filter-section-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--pink-deep);
  margin-bottom: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.filter-options { display: flex; flex-direction: column; gap: 6px; max-height: 200px; overflow-y: auto; }

.filter-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  font-size: 13px;
}

.filter-option:hover { background: var(--pink-bg); }

.filter-option input[type="checkbox"] {
  accent-color: var(--pink-deep);
  width: 16px;
  height: 16px;
}

.filter-option.selected { background: var(--pink-light); font-weight: 600; color: var(--pink-deep); }

.clear-filters {
  width: 100%;
  padding: 10px;
  background: var(--pink-bg);
  border: 1px solid var(--pink-main);
  border-radius: var(--radius-sm);
  color: var(--pink-deep);
  font-weight: 600;
  font-size: 13px;
  transition: var(--transition);
}

.clear-filters:hover { background: var(--pink-light); }

/* ===== PRODUCTS MAIN ===== */
.products-main { flex: 1; min-width: 0; }

.products-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.results-count { font-size: 14px; color: var(--gray-text); }
.results-count span { font-weight: 700; color: var(--dark); }

.sort-select {
  padding: 8px 16px;
  border: 2px solid var(--pink-light);
  border-radius: var(--radius-sm);
  font-size: 14px;
  outline: none;
  background: white;
  color: var(--dark);
  cursor: pointer;
}

.sort-select:focus { border-color: var(--pink-main); }

/* ===== PRODUCTS GRID ===== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
}

/* ===== PRODUCT CARD ===== */
.product-card {
  background: var(--white);
  border: 1px solid var(--pink-light);
  border-radius: var(--radius);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
  cursor: pointer;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
  border-color: var(--pink-main);
}

.product-img-wrap {
  position: relative;
  overflow: hidden;
  background: var(--pink-bg);
  aspect-ratio: 1;
}

.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.product-card:hover .product-img-wrap img { transform: scale(1.06); }

.product-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
}

.badge-new { background: #4caf50; color: white; }
.badge-sale { background: #000; color: white; }
.badge-best { background: #ff9800; color: white; }

.product-info { padding: 14px; }

.product-brand { font-size: 11px; color: var(--pink-dark); font-weight: 600; margin-bottom: 4px; }

.product-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
}

.product-price { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }

.price-current { font-size: 17px; font-weight: 800; color: var(--pink-deep); }

.price-original {
  font-size: 13px;
  color: var(--gray-text);
  text-decoration: line-through;
}

.discount-pct {
  background: var(--pink-light);
  color: var(--pink-deep);
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
}

.add-to-cart-btn {
  width: 100%;
  padding: 10px;
  background: #18bddc;
  color: white;
  border: none;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 700;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.add-to-cart-btn:hover { opacity: 0.9; transform: translateY(-1px); }
.add-to-cart-btn:disabled { background: var(--gray); cursor: not-allowed; }

/* ===== CART SIDEBAR ===== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.cart-overlay.open { opacity: 1; visibility: visible; }

.cart-sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: 380px;
  background: white;
  z-index: 2001;
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform 0.35s ease;
  box-shadow: 5px 0 30px rgba(0,0,0,0.15);
}

.cart-sidebar.open { transform: translateX(0); }

.cart-header {
  padding: 20px 24px;
  background: #18bddc;
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cart-header h3 { font-size: 18px; font-weight: 700; }

.cart-close {
  background: rgba(255,255,255,0.2);
  border: none;
  color: white;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.cart-close:hover { background: rgba(255,255,255,0.35); }

.cart-items { flex: 1; overflow-y: auto; padding: 16px; }

.cart-item {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--pink-light);
}

.cart-item-img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--pink-bg);
  flex-shrink: 0;
}

.cart-item-info { flex: 1; }
.cart-item-name { font-size: 13px; font-weight: 600; margin-bottom: 4px; line-height: 1.4; }
.cart-item-price { font-size: 14px; font-weight: 800; color: var(--pink-deep); }

.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.qty-btn {
  width: 28px;
  height: 28px;
  border: 1px solid var(--pink-main);
  background: white;
  color: var(--pink-deep);
  border-radius: 50%;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.qty-btn:hover { background: var(--pink-light); }

.qty-num { font-weight: 700; font-size: 15px; min-width: 24px; text-align: center; }

.remove-item { color: #ef5350; background: none; border: none; font-size: 18px; padding: 4px; }

.cart-footer {
  padding: 20px 24px;
  border-top: 2px solid var(--pink-light);
  background: var(--pink-bg);
}

.cart-total {
  display: flex;
  justify-content: space-between;
  font-size: 18px;
  font-weight: 800;
  margin-bottom: 16px;
  color: var(--dark);
}

.cart-total span:last-child { color: var(--pink-deep); }

.whatsapp-btn {
  width: 100%;
  padding: 15px;
  background: #25d366;
  color: white;
  border: none;
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: var(--transition);
}

.whatsapp-btn:hover { background: #128c7e; transform: translateY(-2px); box-shadow: 0 6px 20px rgba(37,211,102,0.35); }

.cart-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--gray-text);
}

.cart-empty .empty-icon { font-size: 60px; margin-bottom: 16px; }
.cart-empty p { font-size: 16px; }

/* ===== PAGINATION ===== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
  flex-wrap: wrap;
}

.page-btn {
  width: 40px;
  height: 40px;
  border: 2px solid var(--pink-light);
  background: white;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--dark);
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-btn:hover, .page-btn.active {
  background: var(--pink-deep);
  border-color: var(--pink-deep);
  color: white;
}

/* ===== LOADING ===== */
.loading {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 60px;
}

.spinner {
  width: 45px;
  height: 45px;
  border: 4px solid var(--pink-light);
  border-top-color: var(--pink-deep);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ===== TOAST ===== */
.toast-container {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  background: var(--dark);
  color: white;
  padding: 14px 20px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: slideUp 0.3s ease;
  max-width: 320px;
}

.toast.success { background: #4caf50; }
.toast.error { background: #ef5350; }

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

/* ===== PRODUCT MODAL ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal-overlay.open { opacity: 1; visibility: visible; }

.modal23 {
  background: white;
  border-radius: var(--radius);
  max-width: 800px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.modal-overlay.open .modal23 { transform: scale(1); }

.modal-body { display: flex; gap: 24px; padding: 24px; flex-wrap: wrap; }

.modal-img {
  width: 280px;
  height: 280px;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--pink-bg);
  flex-shrink: 0;
}

.modal-info { flex: 1; min-width: 200px; }
.modal-brand { color: var(--pink-dark); font-weight: 700; font-size: 13px; margin-bottom: 6px; }
.modal-name { font-size: 20px; font-weight: 800; margin-bottom: 12px; line-height: 1.4; }
.modal-price { font-size: 24px; font-weight: 800; color: var(--pink-deep); margin-bottom: 16px; }
.modal-desc { font-size: 14px; color: var(--gray-text); line-height: 1.7; margin-bottom: 16px; }

.modal-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.modal-tag {
  background: var(--pink-light);
  color: var(--pink-deep);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.modal-close {
  position: absolute;
  top: 16px;
  left: 16px;
  background: white;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 20px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== MOBILE FILTER TOGGLE ===== */
.filter-toggle-btn {
  display: none;
  padding: 10px 20px;
  background: var(--pink-bg);
  border: 2px solid var(--pink-main);
  border-radius: var(--radius-sm);
  color: var(--pink-deep);
  font-weight: 700;
  font-size: 14px;
  align-items: center;
  gap: 8px;
}

/* ===== NO RESULTS ===== */
.no-results {
  text-align: center;
  padding: 80px 20px;
  color: var(--gray-text);
}

.no-results .no-icon { font-size: 64px; margin-bottom: 16px; }
.no-results h3 { font-size: 20px; font-weight: 700; color: var(--dark); margin-bottom: 8px; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .filters-sidebar { width: 220px; }
  .products-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
}

@media (max-width: 768px) {
  .header-main { padding: 10px 16px; }
  .search-bar { max-width: 100%; order: 3; flex-basis: 100%; }
  .header-main { flex-wrap: wrap; }
  
  .products-page { flex-direction: column; padding: 16px; }
  
  .filters-sidebar {
   border-top-left-radius: 30px;
    border-top-right-radius: 30px ;
    width: 100%;
    position: fixed;
 max-height: 65vh;
    right: 0;
    bottom: 0;
    z-index: 1500;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    top: auto;
  }
  
  .filters-sidebar.mobile-open { transform: translateX(0); }
  
  .filter-toggle-btn { display: flex; }
  
  .products-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  
  .cart-sidebar { width: 100%; }
  
  .modal-body { flex-direction: column; }
  .modal-img { width: 100%; height: 250px; }
  
  .hero { padding: 40px 16px; }
  .section { padding: 30px 16px; }
}

@media (max-width: 480px) {
  .products-grid { grid-template-columns: repeat(2, 1fr); }
  .categories-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ===== TOAST NOTIFICATIONS ===== */
#toast-container {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.toast {
  background: #333;
  color: white;
  padding: 12px 20px;
  border-radius: 10px;
  font-size: 14px;
  font-family: 'Cairo', sans-serif;
  animation: slideIn 0.3s ease;
  max-width: 280px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.toast.success { background: #4caf50; }
.toast.error { background: #f44336; }
@keyframes slideIn {
  from { transform: translateX(-100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ===== FOOTER FIX ===== */
footer {
  background: linear-gradient(135deg, #18bddc, #18bddc);
  color: white;
  padding: 50px 24px 24px;
  margin-top: 60px;
}
.footer-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
  max-width: 1200px;
  margin: 0 auto 32px;
}
.footer-brand img {
  height: 70px;
  filter: brightness(0) invert(1);
  margin-bottom: 12px;
  display: block;
}
.footer-brand p {
  font-size: 14px;
  opacity: 0.85;
  line-height: 1.7;
  color: white;
}
.footer-links h4, .footer-contact h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
  color: white;
}
.footer-links a, .footer-contact a {
  display: block;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  margin-bottom: 8px;
  font-size: 14px;
  transition: var(--transition);
}
.footer-links a:hover, .footer-contact a:hover {
  color: white;
  padding-right: 6px;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.2);
  padding-top: 20px;
  text-align: center;
  font-size: 13px;
  opacity: 0.7;
  max-width: 1200px;
  margin: 0 auto;
  color: white;
}

.wave-wrapper {
    margin-bottom: -1px;
    overflow: hidden;
    width: 100%
}

.wave-wrapper-top {
    top: 0
}

.wave-wrapper-bottom {
    bottom: 0
}

.wave,.wave-wrapper {
    position: absolute;
    z-index: 9
}

.wave,.wave-wrapper {
    height: 100px;
    height: 50px
}

.wave {
    -webkit-mask-repeat-x: round;
    -webkit-animation: move-wave 50s linear infinite;
    animation: move-wave 50s linear infinite;
    background-image: url(curve-light.png);
    background-image: url(curve-light_550x50.png);
    background-repeat: repeat-x;
    background-size: contain;
    width: 6400px
}
@-webkit-keyframes move-wave {
    0% {
        left: 0
    }

    to {
        left: -1600px
    }
}

@keyframes move-wave {
    0% {
        left: 0
    }

    to {
        left: -1600px
    }
}
/* ===== BRANDS LIST ===== */
.brands-list {
  display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 10px;
        padding: 10px;
        margin: 0;
        text-align: center;
        display: flex;
        overflow-x: scroll;
        flex-wrap: nowrap;
        white-space: nowrap;
        overflow-x:auto; 
}
@keyframes scrollInfinite {
    0% { transform: translateX(0); }
    100% { transform: translateX(33.33%); }
}
.brands-list.auto-scroll:hover {
  animation-play-state: paused;  /* توقف عند الـ hover */
}

.brand-chip {
    display: inline-flex;
    align-items: center;
    padding: 10px 18px;
    background: var(--pink-light);
    color: var(--pink-deep);
    border: 2px solid var(--pink-main);
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Cairo', sans-serif;
    white-space: nowrap;
    flex-shrink: 0;
}

.brand-chip:hover {
  background: var(--pink-main);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.brand-chip:active {
  transform: translateY(0);
}
.mobile-filter-btn{
  display: none;
  padding: 10px 20px;
  background: var(--pink-bg);
  border: 2px solid var(--pink-main);
  border-radius: var(--radius-sm);
  color: var(--pink-deep);
  font-weight: 700;
  font-size: 14px;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
}

mobile-filter-btn:hover {
  background: var(--pink-light);
}
@media (max-width: 768px) {
  .mobile-filter-btn { display: flex; }
}