/* =========================================== */
/* ===   1. GLOBAL & BASE STYLES           === */
/* =========================================== */
* {
  box-sizing: border-box;
}

/* === Animation Addition: Smooth Scrolling === */
html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Helvetica Neue', sans-serif;
  background-color: #fff;
  color: #000;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.separator-line {
  border-bottom: 2px solid #ccc; /* لون الخط */
  margin: 10px 0 20px; /* هوامش أعلى وأسفل */
}

main {
  flex-grow: 1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =========================================== */
/* ===   2. HEADER & MENU STYLES (UNIFIED) === */
/* =========================================== */

/* --- Header Layout --- */
header {
  padding: 15px 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #fff;
  position: sticky; /* لجعل الهيدر يلتصق في الأعلى */
  top: 0;
  z-index: 100;
  border-bottom: 1px solid #eee;
}

.logo img {
  height: 45px;
  width: auto;
  transition: height 0.3s ease;
}

/* --- Hamburger Menu Icon (☰) --- */
.menu-icon {
  font-size: 28px;
  cursor: pointer;
  display: block; /* إظهاره دائماً على كل الشاشات */
  /* === Animation Addition: Hover Effect === */
  transition: transform 0.3s ease;
}
.menu-icon:hover {
  transform: scale(1.1);
}

/* --- The Slide-out Menu Panel (Hidden by default) --- */
.nav-menu {
    position: fixed;
    top: 0;
    right: -100%; /* إخفاء القائمة خارج الشاشة إلى اليمين */
    width: 280px;
    height: 100vh;
    background-color: #fff;
    box-shadow: -3px 0 8px rgba(0,0,0,0.15);
    z-index: 1000;
    padding-top: 60px;
    transition: right 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* --- Active state to show the menu (added via JS) --- */
.nav-menu.active {
    right: 0; /* إظهار القائمة */
}

/* --- Close Icon (X) --- */
.close-icon {
    display: block;
    position: absolute;
    top: 15px;
    right: 25px;
    font-size: 35px;
    color: #333;
    cursor: pointer;
    /* === Animation Addition: Hover Effect === */
    transition: transform 0.3s ease;
}
.close-icon:hover {
    transform: scale(1.1) rotate(90deg);
}

/* --- Menu Links --- */
.nav-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.nav-menu li {
    width: 100%;
    text-align: left;
    /* === Animation Addition: Prepare for Staggered Animation === */
    opacity: 0;
    transform: translateX(20px);
}

.nav-menu a {
    display: block;
    padding: 18px 25px;
    text-decoration: none;
    color: #333;
    font-weight: bold;
    font-size: 16px;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.3s, color 0.3s;
}

.nav-menu a:hover {
    background-color: #f5f5f5;
    color: #007bff;
}

/* =========================================== */
/* ===   3. PAGE CONTENT STYLES            === */
/* =========================================== */

.hero img {
  width: 100%;
  height: auto;
  display: block;
  /* === Animation Addition: Gentle Zoom on Load === */
  animation: zoomIn 1s ease-out forwards;
}

.section-title {
  padding: 40px 20px 20px;
  text-align: center;
  
}

.section-title h2 {
  font-size: 28px;
  margin-bottom: 15px;
  animation: fadeInUp 0.8s ease-out forwards;


}
.section-title h3 {
  font-size: 28px;
  margin-bottom: 15px;
  animation: fadeInUp 0.8s ease-out forwards;

  text-decoration: underline;
  text-decoration-color: #000000;       /* Change underline color */
  text-decoration-thickness: 1px;       /* Thickness */
  text-underline-offset: 4px;           /* Distance from text */
}
.note-price {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
}

.note-price h5 {
  margin: 0;
  font-size: 10px;
  color: #444;
}
.section-title p {
  font-size: 18px;
  color: #444;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  /* === Animation Addition: Fade In on Load (with delay) === */
  animation: fadeInUp 0.8s ease-out 0.2s forwards;
  opacity: 0; /* يبدأ مخفيًا قبل الحركة */
}

.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.product-card {
  background: #000;
  color: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(0,0,0,0.15);
  transition: transform 0.3s ease, box-shadow 0.3s ease; /* تحسين الانتقال */
  display: flex;
  flex-direction: column;
  /* === Animation Addition: Prepare for Staggered Animation === */
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease-out forwards;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 25px rgba(0,0,0,0.2); /* تكبير الظل عند المرور */
}

/* === Animation Addition: Staggered effect for product cards === */
.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }
/* يمكنك إضافة المزيد حسب الحاجة */


.product-card img {
width: 100%;
height: 355px;
}

.product-card .info {
  padding: 20px;
  flex-grow: 1;
  
}
#image-swiper-container {
    cursor: pointer; /* يغير شكل المؤشر إلى يد عند التمرير */
    max-width: 500px; /* نفس عرض الصورة القصوى */
    margin: 0 auto 30px auto; /* نفس هوامش الصورة */
}
#main-product-image {
    margin-bottom: 0; /* أزلنا الهامش السفلي من الصورة لأنه أصبح الآن على الحاوية */
}
/* في ملف product_details.php داخل <style> */

.product-price {
    font-size: 15px; /* حجم خط كبير لجعله بارزًا */
    font-weight: bold; /* خط عريض */
    color: #B8860B; /* استخدام لون أحمر مميز (نفس لون العناوين) */
    text-align: left; /* توسيط السعر */
    
}
.product-card-link {
  text-decoration: none;
  color: inherit;
}

.product-card h3 {
  font-size: 20px;
  margin-bottom: 10px;
}

.product-card p {
  font-size: 14px;
  color: #bbb;
}

.warranty-section {
    padding: 60px 0;
    background-color: #f9f9f9;
}
.warranty-container {
    display: flex;
    align-items: center;
    gap: 50px;
}
.warranty-graphic {
    flex: 1;
    max-width: 250px;
    /* === Animation Addition: Slide In === */
    opacity: 0;
    animation: slideInLeft 1s ease-out 0.2s forwards;
}
.warranty-graphic img {
    width: 100%;
    height: auto;
}
.warranty-text {
    flex: 2;
    /* === Animation Addition: Slide In === */
    opacity: 0;
    animation: slideInRight 1s ease-out 0.4s forwards;
}
.warranty-text h3 {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
}
.warranty-text p {
    font-size: 16px;
    line-height: 1.7;
    color: #555;
}

/* =========================================== */
/* ===   4. FOOTER STYLES                  === */
/* =========================================== */

.site-footer {
  background-color: #000000;
  color: #ccc;
  padding: 50px 0 20px;
}

.footer-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-column {
  flex: 1;
  min-width: 220px;
  /* === Animation Addition: Fade In on Load === */
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.8s ease-out forwards;
}

/* === Animation Addition: Staggered effect for footer columns === */
.footer-column:nth-child(1) { animation-delay: 0.2s; }
.footer-column:nth-child(2) { animation-delay: 0.4s; }
.footer-column:nth-child(3) { animation-delay: 0.6s; }


.footer-column .logo-footer img {
  height: 40px;
  margin-bottom: 15px;
  filter: brightness(0) invert(1);
}

.footer-column h3 {
  font-size: 18px;
  color: #fff;
  margin-bottom: 20px;
}

.footer-column p, .footer-column li {
  margin-bottom: 10px;
  line-height: 1.7;
}

.footer-column ul {
  list-style: none;
  padding: 0;
}

.footer-column a {
  color: #ccc;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-column a:hover {
  color: #fff;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #444;
  font-size: 14px;
  color: #888;
}

/* ======================================================= */
/* ===   5. RESPONSIVE STYLES (MEDIA QUERIES)          === */
/* ======================================================= */

/* --- للأجهزة اللوحية والهواتف الكبيرة (حتى 768px) --- */
@media (max-width: 768px) {
  .logo img {
    height: 40px;
  }

  .section-title h2 {
    font-size: 24px;
  }

  .warranty-container {
      flex-direction: column;
      text-align: center;
      gap: 30px;
  }
  .warranty-graphic {
      max-width: 180px;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }
}

/* --- للهواتف المحمولة الصغيرة (حتى 480px) --- */
@media (max-width: 480px) {
  .logo img {
    height: 35px;
  }

  header, .container {
    padding-left: 15px;
    padding-right: 15px;
  }

  .section-title h2 {
    font-size: 22px;
  }
  .section-title p {
    font-size: 16px;
  }
  .warranty-text h3 {
    font-size: 20px;
  }
  .product-card h3 {
    font-size: 18px;
  }

  .products {
    padding: 15px;
    gap: 20px;
  }

  .product-card .info {
    padding: 15px;
  }
  
  .warranty-section {
    padding: 40px 15px;
  }

  .footer-column h3 {
    font-size: 16px;
  }
}
a.product-link {
    text-decoration: none;
    color: inherit; /* يجعل لون النص موروثًا من العنصر الأب */
    display: block; /* مهم لجعل الرابط يحتل كامل مساحة البطاقة */
}
/* ======================================================= */
/* ===   6. BEAUTIFUL ANIMATIONS (إضافات حركية)         === */
/* ======================================================= */

/* === Animation for Staggered Menu Items === */
/* لجعل عناصر القائمة تظهر بشكل متتابع عند فتحها */
.nav-menu.active li {
  animation: slideInRight 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.nav-menu.active li:nth-child(1) { animation-delay: 0.1s; }
.nav-menu.active li:nth-child(2) { animation-delay: 0.15s; }
.nav-menu.active li:nth-child(3) { animation-delay: 0.2s; }
.nav-menu.active li:nth-child(4) { animation-delay: 0.25s; }
.nav-menu.active li:nth-child(5) { animation-delay: 0.3s; }
/* يمكنك إضافة المزيد حسب عدد عناصر القائمة */


/* === Keyframes Definitions (تعريف الحركات) === */

/* حركة ظهور تدريجي مع صعود لأعلى */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* حركة تكبير الصورة عند تحميل الصفحة */
@keyframes zoomIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* حركة انزلاق من اليسار */
@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* حركة انزلاق من اليمين */
@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}
.hero img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover; /* الوضع الافتراضي 'cover' يبدو أفضل على الجوال */
  object-position: center; 
  animation: zoomIn 1.5s ease-out forwards;
  
  /* خاصية انتقالية لجعل التغيير بين cover و contain سلساً عند تغيير حجم الشاشة */
  transition: transform 0.3s ease; 
}

/* 3. The Animation Keyframes (تعريف الأنيميشن) */
@keyframes zoomIn {
  from {
    transform: scale(1.1); 
    opacity: 0;
  }
  to {
    transform: scale(1); 
    opacity: 1;
  }
}

/* 4. Media Queries for Responsiveness (تعديلات للشاشات المختلفة) */

/* === للهواتف الصغيرة === */
@media (max-width: 600px) {
  .hero {
    height: 50vh;
    min-height: 300px;
  }
}

/* === للشاشات الكبيرة (الكمبيوتر) === */
@media (min-width: 992px) {
  .hero img {
    /* تغيير سلوك الصورة لتظهر كاملة */
    object-fit: contain;
        height: 80vh;
    min-height: 100px;
    /* تكبير الصورة بصرياً لتقليل الشرائط الفارغة */
    transform: scale(20.2); /* <-- قم بتعديل هذا الرقم حسب رغبتك */
  }
  .note-price h5 {
  margin: 0;
  font-size: 25px;
  color: #444;
}
  .product-price {
    font-size: 25px; /* حجم خط كبير لجعله بارزًا */
    font-weight: bold; /* خط عريض */
    color: #B8860B; /* استخدام لون أحمر مميز (نفس لون العناوين) */
    text-align: left; /* توسيط السعر */
    
}
}