 /* ========== RESET & BASE ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: #faf3e8;
  color: #3e2e23;
  line-height: 1.6;
  font-family: "Playpen Sans Arabic", sans-serif;
}

/* ========== HEADER ========== */
.header {
  background-color: #6b4f3a;
  color: #faf3e8;
  padding: 1rem 2rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  transition:
    background-color 0.3s ease,
    padding 0.3s ease;
}

.header.scrolled {
  background-color: #4f3a2b;
  padding: 0.5rem 2rem;
}

.header-container {
  max-width: 1300px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ========== تنسيق الشعار الاحترافي ========== */
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  transition: all 0.3s ease;
  margin-bottom: 0.5rem;
}

/* تنسيق الصورة داخل الشعار */
.logo img {
  height: 80px;
  width: auto;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
  transition: transform 0.3s ease;
}

/* تنسيق النص داخل الشعار */
.logo span {
  font-size: 33px;
  font-weight: 800;
  background: linear-gradient(135deg, #F5E6D3 0%, #D4A373 50%, #F5E6D3 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  letter-spacing: 2px;
  position: relative;
  padding-right: 15px;
}

/* إضافة فاصل زخرفي بين الصورة والنص */
.logo span::before {
  content: '|';
  position: absolute;
  right: -8px;
  color: #D4A373;
  font-weight: 300;
  font-size: 24px;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
  color: #D4A373;
}

/* تأثير hover على الشعار بالكامل */
.logo:hover {
  cursor: pointer;
  opacity: 0.9;
}

.logo:hover img {
  transform: scale(1.05) rotate(2deg);
}

.logo:hover span {
  background: linear-gradient(135deg, #FFFFFF 0%, #F0DBC8 50%, #FFFFFF 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

/* تأثير ارتداد للصورة */
.logo:hover img {
  animation: subtleBounce 0.5s ease;
}

@keyframes subtleBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* ========== NAVIGATION ========== */
.nav-wrapper {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  border-top: 1px solid #c9b6a5;
  padding-top: 0.5rem;
}

.main-nav {
  display: flex;
  gap: 1.2rem;
  font-size: 1.1rem;
  font-weight: 500;
  order: 1;
  flex-wrap: wrap;
}

.main-nav a {
  color: #faf3e8;
  text-decoration: none;
  transition:
    color 0.3s,
    border-bottom 0.3s;
  border-bottom: 2px solid transparent;
  padding-bottom: 4px;
}

.main-nav a:hover {
  color: #f0dbc8;
  border-bottom-color: #f0dbc8;
}

.icon-nav {
  display: flex;
  gap: 1.5rem;
  font-size: 1.2rem;
  order: 2;
  align-items: center;
  flex-wrap: wrap;
}

.icon-nav a {
  color: #faf3e8;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 5px;
  transition: transform 0.2s;
}

.icon-nav a:hover {
  transform: translateY(-2px);
  color: #ffecd6;
}

.icon-nav span {
  font-size: 0.9rem;
}

.search-box {
  display: flex;
  align-items: center;
  background-color: #f5e6d8;
  border-radius: 20px;
  padding: 0.1rem 0.8rem;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  width: 90px;
  padding: 0.3rem 0;
  font-size: 0.9rem;
  color: #3e2e23;
}

.search-box input::placeholder {
  color: #6b4f3a;
  font-size: 0.8rem;
}

.search-box button {
  background: none;
  border: none;
  color: #6b4f3a;
  cursor: pointer;
  font-size: 1rem;
}

/* ========== DROPDOWN ========== */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown > a {
  cursor: pointer;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  right: 0;
  background: #6b4f3a;
  list-style: none;
  padding: 0.5rem 0;
  margin: 0;
  min-width: 160px;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 100;
}

.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu li {
  list-style: none;
}

.dropdown-menu li a {
  display: block;
  padding: 0.6rem 1.2rem;
  color: #faf3e8;
  text-decoration: none;
  font-size: 0.9rem;
  transition: background 0.2s ease;
}

.dropdown-menu li a:hover {
  background: #8b6f50;
  border-radius: 0;
}

/* ========== HERO SECTION ========== */
.hero-section {
  position: relative;
  width: 100%;
  height: 80vh;
  min-height: 600px;
  overflow: hidden;
  direction: rtl;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.3),
    rgba(0, 0, 0, 0.5)
  );
  z-index: 2;
}

.hero-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 3;
  text-align: center;
  color: white;
  width: 90%;
  max-width: 900px;
  padding: 2rem;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
}

.hero-content h1 {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.3;
  color: white;
}

.hero-content p {
  font-size: 1.5rem;
  margin-bottom: 2.5rem;
  opacity: 0.95;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== تحسين زر تصفح المجموعات ===== */
.btn-primary {
  background: linear-gradient(135deg, #c49a6c 0%, #8b5a2b 100%);
  color: white;
  border: none;
  padding: 1rem 3rem;
  font-size: 1.3rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: "🪑";
  font-size: 1.2rem;
  transition: transform 0.3s ease;
}

.btn-primary::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.4s ease, height 0.4s ease;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #d4aa7c 0%, #9b6a3b 100%);
  transform: scale(1.05);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
  gap: 15px;
}

.btn-primary:hover::before {
  transform: translateX(-4px) rotate(-5deg);
}

.btn-primary:hover::after {
  width: 300px;
  height: 300px;
}

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

/* ========== MODAL (Category) ========== */
.modal {
  display: none;
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  justify-content: center;
  align-items: center;
  z-index: 9999;
  animation: fadeInModal 0.3s ease;
}

.modal.show {
  display: flex !important;
}

@keyframes fadeInModal {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-content {
  background: linear-gradient(145deg, #f5e6d3, #ead6bf);
  padding: 30px 25px;
  border-radius: 28px;
  width: 320px;
  text-align: center;
  position: relative;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.3s ease;
}

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

.modal-content h2 {
  margin-bottom: 25px;
  color: #5c3a21;
  font-size: 1.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  cursor: pointer;
  color: #3e2e23;
  transition: 0.2s;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.close:hover {
  color: #b08a5a;
  transform: scale(1.1);
  background: rgba(0, 0, 0, 0.05);
}

/* تنسيق الـ Dropdown داخل المودال */
.modal-content .dropdown {
  margin: 15px 0;
  width: 100%;
}

.modal-content .main-link {
  display: block;
  padding: 14px 20px;
  background: #6b4f3a;
  color: #faf3e8;
  text-decoration: none;
  border-radius: 50px;
  text-align: center;
  transition: all 0.3s ease;
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.modal-content .main-link:hover {
  background: #8b6f50;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.modal-content .dropdown-menu {
  position: static;
  display: none;
  background: #fffaf0;
  list-style: none;
  padding: 10px 0;
  margin-top: 10px;
  border-radius: 20px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  width: 100%;
  opacity: 1;
  visibility: visible;
  transform: none;
}

.modal-content .dropdown:hover .dropdown-menu {
  display: block;
  animation: fadeIn 0.3s ease;
}

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

.modal-content .dropdown-menu li a {
  display: block;
  padding: 10px 20px;
  color: #5c3a21;
  text-decoration: none;
  font-size: 1rem;
  transition: all 0.2s ease;
  text-align: center;
}

.modal-content .dropdown-menu li a:hover {
  background: #e7dac8;
  padding-right: 25px;
  color: #6b4f3a;
}

.modal-content .dropdown-menu li a i {
  margin-left: 8px;
}

/* ========== PRODUCTS SECTION ========== */
.additional-content {
  max-width: 1400px;
  margin: 4rem auto;
  padding: 2rem;
  background-color: #faf3e8;
}

.shop-header {
  text-align: center;
  margin-bottom: 2rem;
  border-bottom: 2px solid #e2c7a5;
  padding-bottom: 1rem;
}

.shop-header h1 {
  font-size: 2.2rem;
  color: #6b4f3a;
  letter-spacing: -0.5px;
  font-weight: 700;
}

.shop-header p {
  color: #a07e5c;
  margin-top: 0.3rem;
  font-size: 1rem;
}

.info-badge {
  background: #e7dac8;
  padding: 2px 10px;
  border-radius: 40px;
  display: inline-block;
  font-weight: bold;
}

.products-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
  margin-top: 1.8rem;
  direction: rtl;
  max-width: 1400px;
  margin: 2rem auto;
  padding: 0 2rem;
}

/* Responsive design - adjusts for smaller screens */
@media (max-width: 1200px) {
  .products-container {
    grid-template-columns: repeat(3, 1fr);
  }
}

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

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

.product {
  background-color: #fffaf0;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition:
    transform 0.25s ease,
    box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
}

.product:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.12);
}

.product-img-wrapper {
  width: 100%;
  height: 210px;
  overflow: hidden;
  background-color: #f3ede2;
  border-bottom: 1px solid #eedfcb;
}

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

.product:hover img {
  transform: scale(1.02);
}

.product h3 {
  font-size: 1rem;
  font-weight: 600;
  color: #5c3a21;
  margin: 14px 16px 6px 16px;
  line-height: 1.4;
  min-height: 48px;
}

.price-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 18px 4px 18px;
  margin-top: 4px;
  flex-wrap: wrap;
  gap: 8px;
}

.product .price {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1b6b2f;
  background: #e9f3e6;
  display: inline-block;
  padding: 4px 12px;
  border-radius: 40px;
  letter-spacing: 0.3px;
  margin: 0;
}

.info-btn {
  background-color: #e7dac8;
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 1.3rem;
  font-weight: bold;
  color: #6b4f3a;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.info-btn:hover {
  background-color: #cdb694;
  color: white;
  transform: scale(1.05);
}

.product button.add-cart {
  background-color: #6b4f3a;
  color: #f5f0e8;
  border: none;
  border-radius: 40px;
  padding: 10px 18px;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.85rem;
  margin: 12px 18px 18px 18px;
  transition: all 0.25s ease;
  width: calc(100% - 36px);
  font-family: inherit;
}

.product button.add-cart:hover {
  background-color: #8b6f50;
  transform: scale(0.98);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* ========== INFO MODAL ========== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  visibility: hidden;
  opacity: 0;
  transition:
    visibility 0.2s,
    opacity 0.2s ease;
}

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

.modal-card {
  background: #fffcf5;
  max-width: 420px;
  width: 90%;
  border-radius: 36px;
  box-shadow: 0 30px 40px rgba(0, 0, 0, 0.3);
  direction: rtl;
  text-align: center;
  overflow: hidden;
  transform: scale(0.95);
  transition: transform 0.2s ease;
}

.modal-overlay.active .modal-card {
  transform: scale(1);
}

.modal-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: #e9dfcf;
}

/* ========== CART SIDEBAR ========== */
.cart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  display: none;
  z-index: 998;
}

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

.cart-sidebar {
  position: fixed;
  top: 0;
  right: -350px;
  width: 350px;
  height: 100%;
  background: #fff;
  transition: 0.3s ease;
  z-index: 999;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
}

.cart-sidebar.active {
  right: 0;
}

.cart-header {
  display: flex;
  justify-content: space-between;
  padding: 15px;
  background: #5a3e2b;
  color: #fff;
  align-items: center;
}

#closeCart {
  cursor: pointer;
  font-size: 22px;
}

.cart-content {
  padding: 15px;
}

/* ========== FOOTER ========== */
.footer {
  background-color: #3e2e23;
  color: #ecd9c5;
  padding: 2.5rem 2rem 1rem;
  direction: rtl;
}

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

.footer-col {
  display: flex;
  flex-direction: column;
}

.footer-col h4 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid #b3967a;
  display: inline-block;
  padding-bottom: 5px;
  color: #f5e2d3;
}

.footer-col a {
  color: #e0cebc;
  text-decoration: none;
  margin-bottom: 0.7rem;
  transition:
    margin-right 0.2s,
    color 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-col a:hover {
  color: #fff5e6;
  margin-right: 5px;
}

.footer-col i {
  width: 20px;
  color: #c5ab94;
}

.copyright {
  text-align: center;
  padding-top: 2.5rem;
  font-size: 0.95rem;
  color: #bba28c;
  border-top: 1px solid #5f4e3d;
  margin-top: 2rem;
}

/* ========== NOTIFICATION ========== */
.notification {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: white;
  color: #6b4f3a;
  padding: 15px 30px;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 10000;
  transition: transform 0.3s ease;
  border-right: 4px solid #6b4f3a;
  direction: rtl;
}

.notification.show {
  transform: translateX(-50%) translateY(0);
}

.notification.success {
  border-right-color: #28a745;
}

.notification.error {
  border-right-color: #dc3545;
}

.notification i {
  font-size: 1.3rem;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .nav-wrapper {
    flex-direction: column;
    gap: 0.5rem;
  }
  .main-nav {
    flex-wrap: wrap;
    justify-content: center;
  }
  .icon-nav {
    justify-content: center;
    flex-wrap: wrap;
  }
  .logo {
    margin-bottom: 0.5rem;
  }
  .logo img {
    height: 40px;
  }
  .logo span {
    font-size: 22px;
  }
  .hero-section {
    height: 70vh;
    min-height: 500px;
  }
  .hero-content h1 {
    font-size: 2.2rem;
  }
  .hero-content p {
    font-size: 1.2rem;
  }
  .btn-primary {
    padding: 0.8rem 2rem;
    font-size: 1.1rem;
  }
  .footer {
    padding: 2rem 1rem 1rem;
  }
  .footer-container {
    gap: 1.5rem;
  }
  .footer-col h4 {
    font-size: 1.1rem;
  }
  .footer-col a {
    font-size: 0.9rem;
  }
  .products-container {
    padding: 0 1rem;
  }
  .modal-card {
    width: 95%;
  }
  .modal-img {
    height: 180px;
  }
}

@media (max-width: 480px) {
  .hero-section {
    height: 60vh;
    min-height: 400px;
  }
  .hero-content h1 {
    font-size: 1.8rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
  .cart-sidebar {
    width: 280px;
  }
  .btn-primary {
    padding: 0.7rem 1.5rem;
    font-size: 1rem;
    gap: 6px;
  }
  .btn-primary::before {
    font-size: 1rem;
  }
  .logo img {
    height: 40px;
  }
  .logo span {
    font-size: 35px;
  }
  .logo span::before {
    font-size: 18px;
    right: -6px;
  }
}


/* ========== تنسيق زر الإغلاق في نافذة معلومات المنتج ========== */
.close-modal-btn {
  background: linear-gradient(135deg, #6b4f3a, #4f3a2b);
  color: #faf3e8;
  border: none;
  padding: 10px 24px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 40px;
  cursor: pointer;
  transition: all 0.3s ease;
  margin: 15px auto 20px auto;
  display: inline-block;
  width: auto;
  min-width: 120px;
  font-family: "Playpen Sans Arabic", sans-serif;
}

.close-modal-btn:hover {
  background: linear-gradient(135deg, #8b6f50, #6b4f3a);
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.close-modal-btn:active {
  transform: scale(0.98);
}

/* تنسيق إضافي للمودال كارد للتأكد من ظهور الزر بشكل جميل */
.modal-card .modal-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px 10px 20px;
}

.modal-price {
  font-size: 1.3rem;
  font-weight: 700;
  color: #1b6b2f;
  background: #e9f3e6;
  display: inline-block;
  padding: 6px 16px;
  border-radius: 40px;
  margin: 10px 0;
}

.modal-description {
  color: #3e2e23;
  line-height: 1.7;
  margin: 10px 0;
  text-align: center;
  font-size: 0.95rem;
  padding: 0 10px;
}


/* ========== GENERAL UTILITIES ========== */
html {
  scroll-behavior: smooth;
}