/* ---------------------------- */
/* 📌 Layout الأساسي */
/* ---------------------------- */

.vendors-container {
  width: 100%;
  position: relative;
}

.vendors-title {
  display: block;
  /* يخليه ياخد عرض كامل */
  text-align: center !important;
  /* يوسّط النص */
}

/* ============================= */
/* 🎯 Vendors Sidebar Styling */
/* ============================= */

.vendors-sidebar {
  background: var(--sidebar-bg, #fff);
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 20px;
  width: 100%;
  max-width: 300px;
  position: sticky;
  top: 100px;
  height: fit-content;
}

.vendors-sidebar .filters-card {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.vendor-search-input {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #ddd;
  border-radius: 8px;
  outline: none;
  font-size: 15px;
  transition: all 0.3s ease;
}

.vendor-search-input:focus {
  border-color: var(--primary-color, #007bff);
  box-shadow: 0 0 5px rgba(0, 123, 255, 0.3);
}

/* ---------------------------- */
/* 📌 Vendor List Wrapper       */
/* ---------------------------- */
.vendor-list-wrapper {
  width: 100%;
  max-height: 80px;
  /* أقصى ارتفاع */
  overflow-y: auto;
  /* تمرير رأسي */
  border: 1px solid #ddd;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;

  /* إخفاء شريط التمرير */
  scrollbar-width: none;
  /* Firefox */
  -ms-overflow-style: none;
  /* IE و Edge القديم */
}

.vendor-list-wrapper::-webkit-scrollbar {
  display: none;
  /* Chrome و Safari */
}


/* ✅ عند وجود نتائج */
.vendor-list-wrapper.active {
  display: block;
}

/* ✅ عناصر القائمة */
.vendor-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.vendor-list li {
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
  transition: all 0.2s ease;
}

.vendor-list li:last-child {
  border-bottom: none;
}

.vendor-list li:hover {
  background: var(--primary-color, #007bff);
  color: #fff;
}

.vendor-list li.selected {
  background: var(--primary-color, #007bff);
  color: #fff;
}

/* ✅ Scrollbar أنيق */
.vendor-list-wrapper::-webkit-scrollbar {
  width: 6px;
}

.vendor-list-wrapper::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 6px;
}

.vendor-list-wrapper::-webkit-scrollbar-thumb:hover {
  background: #999;
}

/* 🌙 دعم الوضع الليلي */
body.dark .vendors-sidebar {
  background: #1e1e1e;
  color: #eee;
  border: 1px solid #333;
}

body.dark .vendor-search-input {
  background: #2b2b2b;
  color: #fff;
  border: 1px solid #444;
}

body.dark .vendor-list-wrapper {
  background: #2a2a2a;
}

body.dark .vendor-list li {
  border-bottom: 1px solid #333;
}

body.dark .vendor-list li:hover,
body.dark .vendor-list li.selected {
  background: var(--primary-color, #007bff);
  color: #fff;
}


.offers-sidebar {
  position: relative;
  height: fit-content;

}

/* ✅ Cards */
.vendors-card {
  background-color: var(--bg-light);
  padding: 20px;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

/* html[dir="ltr"] .offers-card {
  direction: rtl;
  text-align: right;
} */

/* ✅ RTL (العربية) */
/* html[dir="rtl"] .offers-card {
  direction: ltr;
  text-align: left;
} */

.vendorswiper-card {
  position: relative;
  width: 170px;
  height: 100px;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transition: transform 0.3s ease;
}

.vendorswiper-card:hover {
  transform: scale(1.05);
}

.vendorswiper-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.vendorswiper-name {
  position: absolute;
  bottom: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.6);
  color: var(--danger-color);
  text-align: center;
  padding: 10px;
  font-weight: bold;
  font-size: 1.1rem;
}

/* ---------------------------- */
/* 📌 Search Input              */
/* ---------------------------- */
.vendor-search-input {
  width: 100%;
  padding: 10px 15px;
  text-align: center;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  background: var(--light-color);
  color: var(--text-dark);
  font-size: 14px;
  transition: all 0.3s ease;
}

.vendor-search-input:focus {
  border-color: var(--main-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(255, 111, 97, 0.2);
}

.profile-card {
  width: 100%;
  margin: 30px auto;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  position: relative;
  background: #fff;
  font-family: Arial, sans-serif;
  align-items: center;
}

.cover-photo {
  width: 100%;
  height: 360px;
  position: relative;
  overflow: auto;
  /* يمنع أي تمدد خارج الإطار */
  display: block;
  /* مش inline-block */
}

.cover-photo img {
  width: 100%;
  height: 100%;
  /* نفس ارتفاع الديف */
  object-fit: contain;
  /* املأ الصورة بشكل متناسق */
  display: block;
  background: #f5f5f5;
}

/* الزر */
.vbtn-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: white;
  border: 1px solid var(--gray-color, #ccc);
  color: var(--dark-color, #333);
  display: flex;
  align-items: center;
  justify-content: center;

  position: absolute;
  top: 10px;
  /* مسافة من الأعلى */
  right: 10px;
  /* مسافة من اليمين */
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: 0.3s;
}

.vbtn-icon:hover {
  background: var(--primary-color, #007bff);
  color: white;
}

/* النصوص */
.profile-info {
  height: 100px;
  align-items: center;
  padding: 15px;
}

/* html[dir="ltr"] .profile-info {
  left: 50%;
}


html[dir="rtl"] .profile-info {
  right: 50%;
} */

.profile-name {
  font-size: 20px;
  font-weight: bold;
  margin-bottom: 5px;
}

.profile-bio {
  font-size: 14px;
  color: #666;
}



/* ---------------------------- */
/* 📌 Vendor List (UL Reset)   */
/* ---------------------------- */
.vendor-list {
  list-style: none;
  margin: 0;
  padding: 12px 8px;
  min-height: 200px;
  /* ارتفاع أدنى */
  max-height: 500px;
  /* ارتفاع أقصى */
  display: flex;
  flex-direction: column;
  align-items: stretch;
  /* العناصر تمتد بعرض القائمة */
  justify-content: flex-start;
  gap: 8px;
  /* مسافة بين العناصر */
  width: 100%;
}

/* ---------------------------- */
/* 📌 Vendor Item               */
/* ---------------------------- */
.vendor-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: background .2s, transform .1s, box-shadow .2s;
}

.vendor-item:hover {
  background: #f5f7fb;
  transform: translateY(-1px);
}

.vendor-item.selected {
  background: linear-gradient(90deg, rgba(0, 123, 255, 0.18), rgba(0, 123, 255, 0.06));
  border: 1px solid rgba(0, 123, 255, 0.6);
  box-shadow: 0 2px 6px rgba(0, 123, 255, 0.25);
}

/* ---------------------------- */
/* 📌 Vendor Image              */
/* ---------------------------- */
.vendor-item img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  border-radius: 6px;
  border: 1px solid #eee;
  background: #fafafa;
  flex-shrink: 0;
}

/* ---------------------------- */
/* 📌 Vendor Meta Info          */
/* ---------------------------- */
.vendor-meta {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.vendor-name {
  font-size: 14px;
  font-weight: 600;
  color: #222;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vendor-sub {
  font-size: 12px;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---------------------------- */
/* 📌 Empty State               */
/* ---------------------------- */
.vendor-empty {
  padding: 15px;
  text-align: center;
  font-size: 13px;
  color: #777;
}

html {
  scroll-behavior: smooth;
}

/* ---------------------------- */
/* 📌 Responsive للشاشات الصغيرة */
/* ---------------------------- */
@media (max-width: 992px) {
  .vendors-sidebar {
    position: relative;
  }

  .cover-photo {
    height: 180px;
  }

}

@media (max-width: 576px) {
  .vendors-layout {
    grid-template-areas:
      "filters"
      "vendors"
      "main";
    grid-template-columns: 1fr;
  }

}

@media (max-width: 992px) {

  /* عند الشاشات المتوسطة، تقل النسبة */
  .col-md-8 {
    flex: 0 0 66.6667%;
    max-width: 66.6667%;
  }

  .col-md-4 {
    flex: 0 0 33.3333%;
    max-width: 33.3333%;
  }
}

@media (max-width: 768px) {

  /* عند الشاشات الصغيرة، يتساوى العمودان */
  .col-sm-12 {
    flex: 0 0 100%;
    max-width: 100%;
  }
}