/* الألوان والمتغيرات العامة */
:root {
  --main-color: #FF6F61;
  --secondary-color: #6A5ACD;
  --dark-color: #2C2C2C;
  --notifications-color: #474949;
  --light-color: #FFFFFF;
  --bg-light: #FAFAFA;
  --bg-dark: #1E1E1E;
  --accent: #1F2937;
  --accent-color: #aaa3f2;
  --gray-color: #95a5a6;
  --light-gray: #c4d0d1;
  --text-light: #757575;
  --text-dark: #121212;
  --text-muted: #94a3b8;
  --success-color: #4CAF50;
  --warning-color: #FFC107;
  --danger-color: #FF5252;
  --border-radius: 8px;
  --input-border: #2C2C2C;
  --box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  --footer-bg: #0b1220;
  --footer-text: #ffffff;
  --footer-text-light: #cccccc;
  --footer-heading: #ffffff;
  --footer-divider: #1a2235;
  --primary-color: #4b6fff;
  --navbar-toggler-width: 24px;
  --navbar-toggler-height: 2px;
  --navbar-toggler-gap: 8px;
  --navbar-toggler-transition: all 0.3s ease-in-out;
  --navbar-toggler-color: var(--main-color);
  --navbar-toggler-color-active: var(--light-color);
}

/* :root {
  --main-color: #474af8;
  --secondary-color: #1b87c6;
  --accent-color: #A78BFA;
  --primary-color: #3B82F6;

  --dark-color: #1F2937;
  --light-color: #FFFFFF;
  --bg-light: #F9FAFB;
  --bg-dark: #111827;

  --text-dark: #111827;
  --text-light: #3b5f9c;
  --gray-color: #D1D5DB;

  --success-color: #10B981;
  --warning-color: #F59E0B;
  --danger-color: #EF4444;

  --border-radius: 10px;
  --box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);

  --footer-bg: #0F172A;
  --footer-text: #F1F5F9;
  --footer-text-light: #94A3B8;
  --footer-heading: #E2E8F0;
  --footer-divider: #1E293B;

  --navbar-toggler-width: 24px;
  --navbar-toggler-height: 2px;
  --navbar-toggler-gap: 6px;
  --navbar-toggler-transition: all 0.3s ease-in-out;
  --navbar-toggler-color: var(--main-color);
  --navbar-toggler-color-active: var(--light-color);
} */


.bottom-bar {
  overflow: visible;
  width: 100%;
  max-width: 100vw;
  max-height: 100vh;
  box-sizing: border-box;
}


/* الوضع الداكن */
body.dark {
  --main-color: #FF6F61;
  --secondary-color: #9370DB;
  --dark-color: #E0E0E0;
  --light-color: #1E1E1E;
  --bg-light: #121212;
  --bg-dark: #2C2C2C;
  --text-light: #B0B0B0;
  --text-dark: #FFFFFF;
  --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

/* الأنماط الأساسية */
body {
  font-family: 'Open Sans', sans-serif;
  font-weight: 400;
  background: var(--bg-light);
  color: var(--text-dark);
  transition: background 0.5s, color 0.5s;
  line-height: 1.6;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

* {
  box-sizing: border-box;
}

a {
  color: var(--main-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Source Code Pro', monospace;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.container {
  width: 100%;
  padding-right: 15px;
  padding-left: 15px;
  margin-right: auto;
  margin-left: auto;
}

.container-fluid {
  padding: 0 15px;
}

@media(min-width: 992px) {
  .container-fluid {
    padding-right: 10px;
    padding-left: 10px;
  }
}

@media (min-width: 576px) {
  .container {
    max-width: 540px;
  }
}

@media (min-width: 768px) {
  .container {
    max-width: 720px;
  }
}

@media (min-width: 992px) {
  .container {
    max-width: 960px;
  }
}

@media (min-width: 1200px) {
  .container {
    max-width: 1140px;
  }
}

.section-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0px 20px;
  border-radius: 10px;
}

.relative{
  position: relative;
}

.section-title {
  font-weight: bold;
  text-align: center;
  color: var(--text-dark);
  position: relative;
  margin-top: 20px;
  font-size: 1.5rem;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--glass-border);
}

.section-title::after {
  content: '';
  display: block;
  width: 120px;
  height: 3px;
  background: var(--main-color);
  margin: 15px auto 0;
}

/* نظام الجريد المتجاوب */
.row {
  display: flex;
  flex-wrap: wrap;
  margin-right: -15px;
  margin-left: -15px;
}

.col {
  position: relative;
  width: 100%;
  padding-right: 15px;
  padding-left: 15px;
}

@media (min-width: 576px) {
  .col-sm {
    flex: 1 0 0%;
  }

  .col-sm-auto {
    flex: 0 0 auto;
    width: auto;
  }

  .col-sm-1 {
    width: 8.33%;
  }

  .col-sm-2 {
    width: 16.66%;
  }

  .col-sm-3 {
    width: 25%;
  }

  .col-sm-4 {
    width: 33.33%;
  }

  .col-sm-5 {
    width: 41.66%;
  }

  .col-sm-6 {
    width: 50%;
  }

  .col-sm-7 {
    width: 58.33%;
  }

  .col-sm-8 {
    width: 66.66%;
  }

  .col-sm-9 {
    width: 75%;
  }

  .col-sm-10 {
    width: 83.33%;
  }

  .col-sm-11 {
    width: 91.66%;
  }

  .col-sm-12 {
    width: 100%;
  }
}

@media (min-width: 768px) {
  .col-md {
    flex: 1 0 0%;
  }

  .col-md-auto {
    flex: 0 0 auto;
    width: auto;
  }

  .col-md-1 {
    width: 8.33%;
  }

  .col-md-2 {
    width: 16.66%;
  }

  .col-md-3 {
    width: 25%;
  }

  .col-md-4 {
    width: 33.33%;
  }

  .col-md-5 {
    width: 41.66%;
  }

  .col-md-6 {
    width: 50%;
  }

  .col-md-7 {
    width: 58.33%;
  }

  .col-md-8 {
    width: 66.66%;
  }

  .col-md-9 {
    width: 75%;
  }

  .col-md-10 {
    width: 83.33%;
  }

  .col-md-11 {
    width: 91.66%;
  }

  .col-md-12 {
    width: 100%;
  }
}

@media (min-width: 992px) {
  .col-lg {
    flex: 1 0 0%;
  }

  .col-lg-auto {
    flex: 0 0 auto;
    width: auto;
  }

  .col-lg-1 {
    width: 8.33%;
  }

  .col-lg-2 {
    width: 16.66%;
  }

  .col-lg-3 {
    width: 25%;
  }

  .col-lg-4 {
    width: 33.33%;
  }

  .col-lg-5 {
    width: 41.66%;
  }

  .col-lg-6 {
    width: 50%;
  }

  .col-lg-7 {
    width: 58.33%;
  }

  .col-lg-8 {
    width: 66.66%;
  }

  .col-lg-9 {
    width: 75%;
  }

  .col-lg-10 {
    width: 83.33%;
  }

  .col-lg-11 {
    width: 91.66%;
  }

  .col-lg-12 {
    width: 100%;
  }
}

@media (min-width: 1200px) {
  .col-xl {
    flex: 1 0 0%;
  }

  .col-xl-auto {
    flex: 0 0 auto;
    width: auto;
  }

  .col-xl-1 {
    width: 8.33%;
  }

  .col-xl-2 {
    width: 16.66%;
  }

  .col-xl-3 {
    width: 25%;
  }

  .col-xl-4 {
    width: 33.33%;
  }

  .col-xl-5 {
    width: 41.66%;
  }

  .col-xl-6 {
    width: 50%;
  }

  .col-xl-7 {
    width: 58.33%;
  }

  .col-xl-8 {
    width: 66.66%;
  }

  .col-xl-9 {
    width: 75%;
  }

  .col-xl-10 {
    width: 83.33%;
  }

  .col-xl-11 {
    width: 91.66%;
  }

  .col-xl-12 {
    width: 100%;
  }
}

/**********************************/
/******** Back to Top CSS *********/
/**********************************/
.back-to-top {
  position: fixed;
  display: none;
  background: linear-gradient(45deg, var(--main-color), var(--secondary-color));
  color: var(--light-color);
  width: 50px;
  height: 50px;
  text-align: center;
  line-height: 50px;
  font-size: 1.25rem;
  border-radius: 50%;
  inset-inline-end: 20px;
  /* ✅ يمين في LTR، يسار في RTL تلقائيًا */
  bottom: 20px;
  box-shadow: var(--box-shadow);
  z-index: 20000;
  transition: all 0.3s ease;
  cursor: pointer;
}

.back-to-top:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}


/**********************************/
/********* Form Input CSS *********/
/**********************************/
.sline {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.text-muted {
  color: #6c757d;
  /* اللون الرمادي */
  font-size: 1rem;
  /* حجم الخط أصغر قليلاً */
  font-weight: 700;
  /* وزن الخط عادي */
}

input,
select,
textarea {
  font-family: "Tahoma", "Arial", "Segoe UI", sans-serif;
}

.form-control,
.custom-select {
  width: 100%;
  height: 40px;
  padding: 0 5px;
  color: var(--text-dark);
  border: 1px solid #dddddd;
  border-radius: var(--border-radius);
  margin-bottom: 5px;
  transition: all 0.3s ease;
  background: var(--light-color);
}

.form-control:focus,
.custom-select:focus {
  box-shadow: 0 0 0 3px rgba(255, 111, 97, 0.2);
  border-color: var(--main-color);
}

.form-group {
  margin-bottom: 0.2rem;
}

.form-label {
  display: inline-block;
  margin-bottom: 0.5rem;
}

/* الأزرار */
.btn {
  display: inline-block;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  user-select: none;
  border: 1px solid transparent;
  padding: 10px 20px;
  font-size: 1rem;
  line-height: 1.5;
  border-radius: var(--border-radius);
  transition: all 0.3s ease;
  cursor: pointer;
  color: var(--light-color);
  background: linear-gradient(45deg, var(--main-color), var(--secondary-color));
  box-shadow: var(--box-shadow);
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

.btn-primary {
  color: var(--light-color);
  background-color: var(--main-color);
  border-color: var(--main-color);
}

.btn-primary:hover {
  background-color: #e04b3a;
  border-color: #d44332;
}

.btn-secondary {
  color: var(--light-color);
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
}

.btn-secondary:hover {
  background-color: #5849c0;
  border-color: #4d3fb7;
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--main-color);
  color: var(--main-color);
}

.btn-outline:hover {
  background: var(--main-color);
  color: var(--light-color);
}

.btn-outline-primary {
  /* color: var(--light-color); */
  background-color: transparent;
  border-color: var(--main-color);
}

.btn-outline-primary:hover {
  /* color: var(--gray-color); */
  background-color: var(--main-color);
}

.btn-lg {
  padding: 0.75rem 1.75rem;
  font-size: 1.25rem;
}

.btn-sm {
  padding: 0.25rem 0.75rem;
  font-size: 0.875rem;
}

.error {
  width: 100%;
  align-items: center !important;
  text-align: center !important;
}

/**********************************/
/********** Top Bar CSS ***********/
/**********************************/
.top-bar {
  padding: 10px 0;
  font-size: 14px;
  color: var(--light-color);
  background: var(--bg-dark);
}

.top-bar .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
}

.top-bar-left,
.top-bar-right {
  display: flex;
  align-items: center;
}

.top-bar-item {
  margin-right: 1rem;
  display: flex;
  align-items: center;
}

.top-bar-item:last-child {
  margin-right: 0;
}

.top-bar i {
  margin-right: 5px;
  color: var(--main-color);
}

.top-bar-item i {
  margin-right: 0.5rem;
  color: var(--main-color);
}

@media (max-width: 768px) {
  .top-bar .container {
    flex-direction: column;
    gap: 0.5rem;
  }

  .top-bar-left,
  .top-bar-right {
    width: 100%;
    justify-content: center;
  }

  .top-bar-item {
    margin: 0 0.5rem;
  }
}

/**********************************/
/*********** Nav Bar CSS **********/
/**********************************/
.navbar {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  /* background: linear-gradient(90deg, var(--main-color), var(--secondary-color)) !important; */
  box-shadow: var(--box-shadow);
  transition: all 0.3s ease;
}

html[dir="ltr"] .navbar {
  background: linear-gradient(90deg, var(--main-color), var(--secondary-color)) !important;
}

html[dir="rtl"] .navbar {
  background: linear-gradient(90deg, var(--secondary-color), var(--main-color)) !important;
}

.navbar-brand {
  display: inline-block;
  padding-top: 0.3125rem;
  padding-bottom: 0.3125rem;
  margin-right: 1rem;
  font-size: 1.25rem;
  line-height: inherit;
  white-space: nowrap;
}

.navbar-brand img {
  height: 40px;
}

#navbar-user-image {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #fff2;
  margin-right: 6px;
  vertical-align: middle;
}

.navbar-nav {
  display: flex;
  flex-direction: row;
  padding-left: 0;
  margin-bottom: 0;
  list-style: none;
}

.navbar-dark .navbar-nav .nav-link {
  color: var(--light-color);
  font-weight: 600;
  padding: 8px 15px;
  transition: all 0.3s ease;
}

.nav-link {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--main-color);
  font-weight: 600;
  transition: all 0.3s ease;
}

.nav-link.active {
  border-bottom: 2px solid white;
}

.navbar-dark .navbar-nav .nav-link:hover {
  color: var(--dark-color);
  transform: translateY(-2px);
}

.nav-link:hover {
  color: var(--dark-color);
}

.dark {
  color: rgb(53, 53, 142);
}

@media (max-width: 992px) {
  /* .navbar-toggler {
    display: block;
  } */

  .navbar-collapse {
    display: none;
    width: 100%;
    padding: 1rem 0;
  }

  .navbar-collapse.show {
    display: flex;
    flex-direction: column;
  }

  .navbar-nav {
    flex-direction: column;
  }

  .nav-item {
    width: 100%;
    text-align: center;
  }

  .userdropdown {
    flex-direction: column;
  }

  .dropdown-toggle {
    width: 100%;
    text-align: center;
  }
}

/**********************************/
/******** dropdown ***************/
/**********************************/

.userdropdown {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 12px;
  border-radius: 30px;
  color: var(--light-color);
  font-weight: 600;
  transition: all 0.3s ease;
}

.userdropdown:hover {
  background-color: rgba(0, 0, 0, 0.08);
  /* خفيف عند التمرير */
}

.dropdown-link {
  display: flex;
  align-items: center;
  gap: 10px;
  background-color: transparent;
  font-weight: 600;
  color: var(--light-color);
  border: none !important;
}

.dropdown-link:hover {
  color: var(--dark-color);
  transform: translateY(-2px);
  border: none !important;
}

/* شكل الأيقونة */
.dropdown i {
  font-size: 18px;
  color: #555;
}

/* قائمة المستخدم المنسدلة */
.dropdown-menu {
  position: relative;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  min-width: 180px;
}

/* عناصر القائمة */
.dropdown-menu .dropdown-item {
  font-size: 15px;
  font-weight: 600;
  color: var(--light-color);
  transition: background-color 0.2s ease;
}

html[dir="rtl"] #user-menu .dropdown-menu {
  right: auto !important;
  left: 0 !important;
}

html[dir="ltr"] .dropdown-background {
  background: linear-gradient(90deg, var(--main-color), var(--secondary-color));
}

html[dir="rtl"] .dropdown-background {
  background: linear-gradient(90deg, var(--secondary-color), var(--main-color));
}

/**********************************/
/*********** Header CSS ***********/
/**********************************/
.header-slider .header-slider-caption {
  background: rgba(255, 111, 97, 0.8);
  border-radius: var(--border-radius);
  backdrop-filter: blur(5px);
}

.header .img-text {
  background: rgba(255, 111, 97, 0.8);
  backdrop-filter: blur(5px);
  opacity: 0;
  transition: all 0.5s ease;
}

.header .img-text:hover {
  opacity: 1;
}

/**********************************/
/*********** Bottom Bar ***********/
/**********************************/
.bottom-bar {
  background-color: var(--light-color);
  padding: 2px 0;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 100;
}

.backwhite {
  background: white !important;
  color: var(--primary-color) !important;
}

.flex-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}

.flex-container-center {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

/* Logo Styles */
.logo img {
  height: 40px;
  transition: transform 0.3s ease;
}

.logo a:hover img {
  transform: scale(1.05);
}

/* شريط البحث */
.search-bar {
  padding: 1rem 0;
  background-color: var(--light-color);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.search-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Search Bar Styles */
.search {
  flex-grow: 1;
  max-width: 500px;
  position: relative;
}

.search input {
  width: 100%;
  padding: 10px 40px 10px 15px;
  border: 1px solid #ddd;
  border-radius: 20px;
  background-color: var(--light-color);
  color: var(--text-dark);
  transition: all 0.3s ease;
}

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

.search button {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--main-color);
  cursor: pointer;
}

.search-form {
  flex-grow: 1;
  max-width: 600px;
  margin: 0 2rem;
  position: relative;
}

.search-input {
  width: 100%;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  border: 1px solid #ddd;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.search-input:focus {
  border-color: var(--main-color);
  box-shadow: 0 0 0 0.2rem rgba(255, 111, 97, 0.25);
}

.search-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--main-color);
  cursor: pointer;
}

/* User Actions Styles */
/* .user-actions {
  display: flex;
  align-items: center;
  gap: 20px;
} */

/* .wishlist,
.cart {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: #333;
  text-decoration: none;
  width: 40px;
  height: 40px;
  transition: all 0.3s ease;
} */



/* .count {
  position: absolute;
  top: -8px;
  right: -8px;
  background-color: #ff4757;
  color: white;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: bold;
  min-width: 22px;
  padding: 2px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  z-index: 10;
} */



/* ✅ عند الشاشات الصغيرة */
@media (max-width: 768px) {
  .flex-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  html[lang="en"],
  body[dir="ltr"] .flex-container {
    align-items: flex-end;
  }

  html[lang="ar"],
  body[dir="rtl"] .flex-container {
    align-items: flex-start;
  }

  .flex-container .logo,
  .flex-container .search {
    align-self: flex-start;
  }

  html[dir="ltr"] .flex-container .user-actions {
    align-self: flex-end;
    /* الإنجليزية → يمين */
  }

  html[dir="rtl"] .flex-container .user-actions {
    align-self: flex-start;
    /* العربية → شمال */
  }
}


/* الدائرة الخلفية */
.icon-bg {
  width: 40px;
  height: 40px;
  background: rgba(0, 0, 0, 0.1);
  /* لون خفيف */
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background 0.3s;
}

/* تأثيرات إضافية */
.notifications .fas,
.messages .fas,
.wishlist .fas,
.cart .fas {
  position: relative;
  z-index: 1;
}

.notifications::before,
.messages::before,
.wishlist::before,
.cart::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background-color: rgba(74, 107, 255, 0.1);
  border-radius: 50%;
  transform: scale(0);
  transition: transform 0.3s ease;
}

.wishlist:hover::before,
.cart:hover::before {
  transform: scale(1);
}

.notifications:hover,
.messages:hover,
.wishlist:hover,
.cart:hover {
  color: var(--main-color);
  transform: scale(1.1);
}

@media (max-width: 768px) {
  .search-container {
    flex-direction: column;
    gap: 1rem;
  }

  .search-form {
    margin: 0;
    width: 100%;
  }

  .user-actions {
    gap: 1rem;
    margin-bottom: 5px;
  }
}

/**********************************/
/*********** Brand Section ********/
/**********************************/
.brand-section {
  padding: 20px 0;
  background-color: var(--light-color);
  min-height: 150px;
}

.brand-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.brand-slider {
  overflow: hidden;
  padding: 10px 0;
}

.brand-slide {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100px;
  padding: 0 15px;
  box-sizing: border-box;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.brand-slider .swiper-wrapper {
  transition-timing-function: linear !important;
  will-change: transform;
}

.brand-slide:hover {
  transform: scale(1);
}

.brand-slide img {
  max-height: 80px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: all 0.3s ease;
}

.brand-slide:hover img {
  filter: grayscale(0);
  opacity: 1;
  transform: scale(1.1);
}

/**********************************/
/******** Call to Action **********/
/**********************************/
.cta-section {
  background: linear-gradient(to right, var(--main-color), var(--secondary-color));
  color: white;
  padding: 30px 0;
}

.cta-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
}

.cta-title {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 15px;
}

.cta-phone {
  font-size: 20px;
  text-decoration: underline;
  color: white;
  transition: color 0.3s ease;
}

.cta-phone:hover {
  color: var(--highlight-color);
}

/**********************************/
/******** قسم المنتجات ***********/
/**********************************/

.no-products {
  width: 100%;
  text-align: center;
  padding: 20px;
  color: var(--text-light);
  grid-column: 1 / -1;
}

.products-section {
  padding: 40px 0;
  background-color: var(--light-color);
}

.products-layout {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 2rem;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}

.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  max-height: 450px;
  border: 1px solid #eee;
  background-color: var(--light-color);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--box-shadow);
  transition: all 0.3s ease;
}

.rating {
  display: inline-flex;
  /* يجعل العناصر بجانب بعضها أفقياً */
  align-items: center;
  gap: 5px;
  /* مسافة بسيطة بين النجوم */
  font-size: 0.8rem;
  cursor: pointer;
  direction: ltr;
  /* لضمان ترتيب النجوم الصحيح */
}

.rating i {
  color: #B8860B;
}

.fa-star,
.fa-star-half-alt {
  color: #B8860B;
}

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

.product-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--secondary-color);
  color: white;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: bold;
  z-index: 1;
}

/* عند العربية (RTL) */
[dir="rtl"] .product-badge {
  background: linear-gradient(135deg, var(--danger-color), var(--primary-color));
}

.product-image {
  position: relative;
  height: 250px;
  overflow: hidden;
}

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

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

.made-in-under-image {
  position: absolute;
  font-size: 12px;
  color: #444;
  background: #f9fafb;
  border-radius: 6px;
  display: inline-block;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);

  border-radius: 4px;
  font-weight: bold;
  z-index: 1;
}

.product-action {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  gap: 15px;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 2;
}

.product-action-madein {
  width: 100%;
  position: absolute;
  bottom: 23px;
  left: 3px;
  padding: 3px 8px;
  display: flex;
  gap: 15px;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 2;
}

.product-card:hover .product-action-madein,
.product-card:hover .product-action {
  opacity: 1;
}

.product-action a {
  width: 40px;
  height: 40px;
  background: white;
  color: #333;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.product-action a:hover {
  background: var(--main-color);
  color: white;
  transform: translateY(-3px);
}

.product-details {
  padding: 1rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.product-title {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.product-description {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-bottom: 1rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-price {
  font-weight: bold;
  color: var(--primary-color);
  font-size: 1.1rem;
}

.product-old-price {
  min-height: 20px;
  font-size: 1rem;
  color: var(--danger-color);
  text-decoration: line-through;
  margin-left: 0.5rem;
}

.product-footer {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #f0f0f0;
}

.add-to-cart {
  background-color: var(--main-color);
  color: white;
  border: none;
  padding: 0.5rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.wide-btn {
  width: 100%;
}

.add-to-cart:hover {
  background-color: #e04b3a;
}

.btn-favorite.active i {
  color: var(--danger-color)
}

/* ===== Quantity Controls ===== */
.qty-controls {
  display: flex;
  align-items: center;
}

.qty-btn {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  padding: 5px 12px;
  cursor: pointer;
  color: #495057;
  transition: all 0.3s;
}

.qty-btn:hover {
  background: #e9ecef;
}

.btn-minus {
  border-radius: 4px 0 0 4px;
}

.btn-plus {
  border-radius: 0 4px 4px 0;
}

.qty-input {
  width: 50px;
  text-align: center;
  border: 1px solid #dee2e6;
  border-left: none;
  border-right: none;
  padding: 5px;
  outline: none;
}

@media (max-width: 992px) {
  .products-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 576px) {
  .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
  }

  .product-image {
    height: 150px;
  }

  .product-action {
    gap: 10px;
  }

  .product-action a {
    width: 35px;
    height: 35px;
  }
}

/**********************************/
/******** breadcrumb ************/
/**********************************/

#breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  font-size: 16px;
  margin-bottom: 10px;
}

#breadcrumb a {
  color: #007bff;
  text-decoration: none;
}

#breadcrumb a:hover {
  text-decoration: underline;
}

#breadcrumb .separator {
  color: #6c757d;
}

#breadcrumb .active {
  font-weight: bold;
  color: #333;
}

/**********************************/
/******** قسم الميزات ************/
/**********************************/
.features-section {
  padding: 3rem 0;
  background-color: var(--bg-light);
}

.features-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature-card {
  background-color: var(--light-color);
  border-radius: var(--border-radius);
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: var(--box-shadow);
  transition: transform 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-10px);
}

.feature-icon {
  font-size: 2.5rem;
  color: var(--main-color);
  margin-bottom: 1rem;
}

.feature-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--text-dark);
}

.feature-description {
  font-size: 0.9rem;
  color: var(--text-light);
}

/**********************************/
/********** Footer CSS ************/
/**********************************/
.site-footer,
.footer {
  background-color: var(--footer-bg);
  color: var(--footer-text);
  padding: 10px;
  font-family: 'Open Sans', sans-serif;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  overflow: hidden;
}

/* Logo Styles */
.logo,
.footer-logo {
  font-weight: bold;
  margin: 10px;
  font-size: 28px;
  display: flex;
  font-family: 'Arial', sans-serif;
  align-items: flex-start;
}

.logo-part1,
.footer-logo-part1 {
  color: var(--primary-color);
}

.logo-part2,
.footer-logo-part2 {
  color: var(--secondary-color);
}

.x-char {
  font-size: 1.4em;
  margin: 0 3px;
  position: relative;
  animation: pulse 2s infinite;
  background: #4a6bff;
  color: white;
  width: 1.1em;
  height: 1.1em;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transform: translateY(-5%);
}

@keyframes pulse {
  0% {
    transform: translateY(-5%) scale(1);
  }

  50% {
    transform: translateY(-5%) scale(1.1);
  }

  100% {
    transform: translateY(-5%) scale(1);
  }
}

.logo-part3 {
  color: var(--primary-color);
}

.about-text,
.footer-about {
  color: var(--footer-text-light);
  line-height: 1.6;
  max-width: 320px;
}

.about-text{
  text-align: center;
}

/* Links Section */
.footer-title {
  color: var(--footer-heading);
  margin-bottom: 20px;
  font-size: 22px;
  font-weight: 600;
  text-transform: capitalize;
}


/* Reset list style */
.links-list,
.footer-links {
  list-style: none;
  padding: 0px;
  margin: 0px;
  display: flex;
  flex-direction: column;
  white-space: nowrap;
  gap: 10px;
}

.footer-links {
  padding-left: 20px;
  margin: 20px;
}

/* List items */
.links-list li,
.footer-links li {
  margin: 0;
  /* خلي المسافة تعتمد على gap */
}

/* Links */
.links-list a,
.footer-links a {
  color: var(--footer-text-light);
  text-decoration: none;
  transition: color 0.3s ease, padding-left 0.3s ease;
  font-size: 16px;
  display: inline-block;
}

.links-list a:hover,
.footer-links a:hover {
  color: var(--primary-color);
  padding-left: 4px;
  /* لمسة بسيطة عند الهوفر */
}

/* ===== Responsive ===== */

/* شاشات صغيرة */
@media (max-width: 768px) {
  .footer-title {
    font-size: 18px;
    margin-bottom: 15px;
    text-align: center;
  }

  .links-list,
  .footer-links {
    align-items: center;
    /* توسيط العناصر */
    gap: 8px;
  }

  .links-list a,
  .footer-links a {
    font-size: 15px;
  }
}

/* شاشات أصغر (موبايل) */
@media (max-width: 480px) {
  .footer-title {
    font-size: 16px;
  }

  .links-list a,
  .footer-links a {
    font-size: 14px;
  }
}


/* Payment & Security Section */
.footer-bottom-section,
.footer-bottom {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  margin-top: 30px;
  padding-top: 30px;
  border-top: 1px solid var(--footer-divider);
}

.payment-methods img {
  max-width: 100%;
  height: auto;
}

.payment-methods,
.security-badges {
  text-align: center;
  margin-top: 20px;
  padding: 0 15px;
}

.payment-methods h4,
.security-badges h4 {
  margin-bottom: 10px;
  font-size: 1.2rem;
  color: #666;
}

.payment-container,
.badges-container {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  max-width: 100%;
  overflow: hidden;
}

.payment-container img,
.badges-container img {
  height: 30px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  opacity: 0.8;
  transition: all 0.3s ease;
}

.payment-container img:hover,
.badges-container img:hover {
  filter: grayscale(0);
  opacity: 1;
}

/* Copyright Section */
.copyright-section,
.copyright {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  padding-top: 20px;
  border-top: 1px solid var(--footer-divider);
  font-size: 14px;
  color: var(--footer-text-light);
}

.copyright-section a,
.copyright a {
  color: var(--primary-color);
  text-decoration: none;
}

.copyright-section a:hover,
.copyright a:hover {
  text-decoration: underline;
}

.payment-methods {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.payment-methods img {
  height: 25px;
}

@media (max-width: 768px) {
  .section-title {
    font-size: 1rem;
  }

  .footer-container {
    grid-template-columns: 1fr 1fr;
  }

  .footer-about {
    grid-column: 1 / -1;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

.loader {
  border: 6px solid #f3f3f3;
  /* اللون الخلفي */
  border-top: 6px solid #3498db;
  /* اللون الأساسي */
  border-radius: 50%;
  /* دائري */
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  /* دوران مستمر */
  margin: auto;
  /* توسيط */
  align-items: center;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}


/**********************************/
/******** Dark Mode Toggle ********/
/**********************************/
.dark-mode-toggle {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 99;
  background: var(--main-color);
  color: var(--light-color);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--box-shadow);
  transition: all 0.3s ease;
}

.dark-mode-toggle:hover {
  transform: scale(1.1);
}

.dark-mode {
  background-color: #1a1a1a;
  color: #f0f0f0;
}

.navbar.dark-mode {
  background-color: #121212 !important;
}

.product-card.dark-mode {
  background-color: #2d2d2d;
  border-color: #444;
}

.back-to-top {
  transition: opacity 0.3s ease;
}

/* الوضع الداكن - يطبق عند وجود class="dark-mode" على body */
body.dark-mode {
  background-color: #121212;
  color: #e0e0e0;
}

/* الروابط */
body.dark-mode a {
  color: #90caf9;
}

body.dark-mode a:hover {
  color: #bbdefb;
}

/* Navbar */
body.dark-mode .navbar {
  background-color: #1f1f1f !important;
  border-bottom: 1px solid #333;
}

body.dark-mode .navbar .nav-link,
body.dark-mode .navbar-brand {
  color: #e0e0e0 !important;
}

body.dark-mode .navbar .nav-link:hover {
  color: #90caf9 !important;
}

/* البطاقات */
body.dark-mode .card {
  background-color: #1e1e1e;
  color: #f1f1f1;
  border: 1px solid #333;
}

/* الأزرار */
body.dark-mode .btn {
  background-color: #333333;
  color: #ffffff;
  border: 1px solid #444444;
}

body.dark-mode .btn:hover {
  background-color: #555555;
}

/* الجداول */
body.dark-mode .table {
  color: #e0e0e0;
}

body.dark-mode .table thead {
  background-color: #1f1f1f;
}

body.dark-mode .table tbody tr {
  background-color: #1a1a1a;
  border-color: #333;
}

/* الفورم */
body.dark-mode .form-control {
  background-color: #1e1e1e;
  color: #e0e0e0;
  border: 1px solid #444;
}

body.dark-mode .form-control:focus {
  background-color: #2a2a2a;
  color: #ffffff;
  border-color: #90caf9;
  box-shadow: none;
}

/* مودال */
body.dark-mode .modal-content {
  background-color: #1f1f1f;
  color: #f1f1f1;
  border: 1px solid #333;
}

/* Footer */
body.dark-mode footer {
  background-color: #1a1a1a;
  color: #e0e0e0;
}


/* Dark Mode Styles */
body.dark .select-wrapper {
  background: var(--bg-dark);
  border-color: #444;
}

body.dark .filter-select {
  color: var(--dark-color);
}

body.dark .filter-select option {
  background-color: var(--bg-dark);
  color: var(--dark-color);
}

body.dark .select-arrow {
  color: var(--dark-color);
}

/* تأثيرات الحركة */
@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.fade-in {
  animation: fadeIn 0.5s ease-in;
}

@keyframes slideInUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.slide-in-up {
  animation: slideInUp 0.5s ease-out;
}

/* كلاسات مساعدة */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.mt-1 {
  margin-top: 0.25rem;
}

.mt-2 {
  margin-top: 0.5rem;
}

.mt-3 {
  margin-top: 1rem;
}

.mt-4 {
  margin-top: 1.5rem;
}

.mt-5 {
  margin-top: 3rem;
}

.mb-1 {
  margin-bottom: 0.25rem;
}

.mb-2 {
  margin-bottom: 0.5rem;
}

.mb-3 {
  margin-bottom: 1rem;
}

.mb-4 {
  margin-bottom: 1.5rem;
}

.mb-5 {
  margin-bottom: 3rem;
}

.p-1 {
  padding: 0.25rem;
}

.p-2 {
  padding: 0.5rem;
}

.p-3 {
  padding: 1rem;
}

.p-4 {
  padding: 1.5rem;
}

.p-5 {
  padding: 3rem;
}

.d-block {
  display: block;
}

.d-inline {
  display: inline;
}

.d-inline-block {
  display: inline-block;
}

.d-flex {
  display: flex;
}

.d-none {
  display: none;
}

.justify-content-center {
  justify-content: center;
}

.justify-content-between {
  justify-content: space-between;
}

.align-items-center {
  align-items: center;
}

.w-100 {
  width: 100%;
}

.h-100 {
  height: 100%;
}

/* كلاسات للشاشات الصغيرة فقط */
@media (max-width: 768px) {
  .mobile-hide {
    display: none !important;
  }

  .mobile-show {
    display: block !important;
  }

  .mobile-flex {
    display: flex !important;
  }
}

/* كلاسات للشاشات الكبيرة فقط */
@media (min-width: 769px) {
  .desktop-hide {
    display: none !important;
  }

  .desktop-show {
    display: block !important;
  }

  .desktop-flex {
    display: flex !important;
  }
}