/* Cleaned CSS for Bon Mocha */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { background-color: #FDFBF7; color: #3E2723; font-family: 'Lato', sans-serif; line-height: 1.8; overflow-x: hidden; }
h1, h2, h3 { font-family: 'Lora', serif; }
.container { width: 90%; max-width: 1200px; margin: 0 auto; }



/* =========================================
   الشريط العلوي (Header)
========================================= */
#mainheader {
  background-color: transparent;
  padding: 15px 0; /* تقليل المساحة العلوية لرفع العناصر لأعلى */
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2000;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 96%; /* توسيع العرض لسحب زر البرجر لليمين أكثر */
  max-width: 1600px;
  margin: 0 auto;
}

/* الشعار */
.mega-logo {
  width: 450px; /* تكبير الشعار بشكل كبير كما طلبت */
  height: auto;
  filter: none; /* إزالة التغميق ليعود للونه الطبيعي */
  transition: transform 0.4s ease;
}

.mega-logo:hover { transform: scale(1.05); }

/* قائمة البرجر */
.menu-trigger {
  color: #FFFFFF;
  font-size: 35px;
  cursor: pointer;
  text-shadow: 0 2px 10px rgba(0,0,0,0.5);
  margin-top: -20px; /* سحب الزر للأعلى ليبتعد عن المبنى */
  margin-right: 15px; /* سحب إضافي لليمين باتجاه الزاوية */
}

/* =========================================
   واجهة الشاشة (Hero Section)
========================================= */
.full-screen-hero {
  width: 100%;
  aspect-ratio: 3 / 2; /* رجعنا لفكرتك الأصلية لضمان عدم قص أي جزء من الصورة */
  background-image: url('../assets/background.jpg');
  background-size: cover;
  background-position: center; /* أعدناها للمنتصف لأن حاوية القسم أصبحت مطابقة تماماً لأبعاد الصورة */
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  text-align: center;
  color: #FFFFFF;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(46, 26, 20, 0.8) 100%);
  z-index: 5;
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 900px;
  padding: 0 20px;
  margin-top: 80px;
}

.hero-content h1 {
  font-size: 50px;
  line-height: 1.3;
  margin-bottom: 20px;
  text-shadow: 2px 2px 15px rgba(0,0,0,0.8);
}

.hero-content p {
  font-size: 22px;
  font-style: normal;
  color: #FDFBF7;
  text-shadow: 1px 1px 8px rgba(0,0,0,0.8);
}



/* Common Sections */
.section { padding: 90px 0; text-align: center; }
.story-section { padding: 100px 0; text-align: center; max-width: 900px; margin: 0 auto; }
.alt-bg { background-color: #EFEBE1; }
h2 { font-size: 38px; margin-bottom: 30px; color: #4E342E; position: relative; display: inline-block; }
h2::after { content: ''; position: absolute; bottom: -15px; left: 50%; transform: translateX(-50%); width: 60px; height: 3px; background-color: #4CAF50; }
p { font-size: 19px; margin: 0 auto 20px auto; color: #5D4037; }

/* تنسيق قسم قصتنا المطور */
.story-intro {
  max-width: 800px;
  margin: 0 auto 50px auto;
  font-style: italic;
  font-size: 20px;
  color: #4E342E;
}


/* تنسيق القسم بنظام الهرمي الجديد */
.story-layout {
  display: grid;
  grid-template-columns: 1fr 1fr; /* عمودين للمربعات الصغيرة */
  gap: 25px;
  margin-top: 50px;
}

.feature-card {
  background: #FFFFFF;
  padding: 40px;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.05);
  text-align: center;
  transition: transform 0.3s ease;
  border: 1px solid #EFEBE1;
}

/* المستطيل الكبير (المعلومة الجوهرية) */
.main-feature {
  grid-column: 1 / -1; /* يأخذ العرض كاملاً */
  border-bottom: 5px solid #4CAF50;
  padding: 60px 40px;
}

.main-feature i { font-size: 50px; color: #4CAF50; margin-bottom: 25px; }
.main-feature h3 { font-size: 32px; margin-bottom: 20px; }
.main-feature .large-text { font-size: 24px; line-height: 1.6; color: #2E1A14; font-weight: 400; }

/* المربعات الصغيرة */
.sub-feature {
  padding: 30px;
  border-bottom: 3px solid #8D6E63;
}
.sub-feature i { font-size: 35px; color: #8D6E63; margin-bottom: 15px; }
.sub-feature h3 { font-size: 22px; }

/* تنسيق المصدر (الـ Quelle) */
.source-tag {
  display: block;
  font-size: 12px;
  margin-top: 20px;
  color: #A1887F;
  font-style: italic;
  letter-spacing: 0.5px;
}

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

/* ضبط التجاوب للجوال */
@media (max-width: 768px) {
  .story-layout { grid-template-columns: 1fr; }
  .main-feature .large-text { font-size: 19px; }
}



/* Side Menu (Glassmorphism) */
.side-nav { height: 100%; width: 0; position: fixed; z-index: 3000; top: 0; right: 0; background-color: rgba(46, 26, 20, 0.95); backdrop-filter: blur(10px); overflow-x: hidden; transition: 0.5s ease; padding-top: 80px; box-shadow: -10px 0 30px rgba(0,0,0,0.5); }
.side-links li { padding: 15px 30px; list-style: none; }
.side-links a { text-decoration: none; font-size: 20px; color: #FDFBF7; font-family: 'Lora', serif; display: flex; align-items: center; gap: 15px; transition: 0.3s; }
.side-links a:hover { color: #4CAF50; transform: translateX(-10px); }
.close-btn { position: absolute; top: 25px; left: 25px; font-size: 35px; color: #FDFBF7; cursor: pointer; }

/* Menu Section Styles */
.menu-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px; margin-top: 50px; }
.menu-card { background: #FFFFFF; padding: 40px 30px; border-radius: 15px; box-shadow: 0 10px 20px rgba(0,0,0,0.05); transition: transform 0.3s ease; text-align: center; }
.menu-card:hover { transform: translateY(-5px); }
.menu-card i { font-size: 45px; color: #4CAF50; margin-bottom: 20px; display: block; }
.menu-card h3 { font-size: 24px; margin-bottom: 15px; color: #2E1A14; }
.menu-card p { font-size: 17px; color: #5D4037; }

/* Galleries & Partners */
.media-container { margin-top: 50px; width: 100%; max-width: 800px; margin: 50px auto 0 auto; border-radius: 15px; overflow: hidden; box-shadow: 0 15px 30px rgba(0,0,0,0.15); }
.event-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.event-item:hover img { transform: scale(1.08); }
.building-gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 25px; margin-top: 50px; margin-bottom: 40px; }
.gallery-item { height: 350px; border-radius: 15px; overflow: hidden; box-shadow: 0 10px 25px rgba(0,0,0,0.1); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; }
.partner-logos { display: flex; justify-content: center; align-items: center; gap: 35px; flex-wrap: wrap; margin-top: 60px; }
.partner-img { background-color: #FFFFFF; padding: 25px; border-radius: 15px; height: 120px; width: auto; object-fit: contain; box-shadow: 0 5px 20px rgba(0,0,0,0.06); transition: transform 0.3s ease; }
.partner-img:hover { transform: translateY(-8px); }

/* Footer */
#contact { background-color: #2E1A14; color: #FFFFFF; text-align: center; padding: 70px 0; }
#contact h2 { color: #4CAF50; margin-bottom: 30px; }
#contact h2::after { display: none; }
.contact-links a { color: #4CAF50; text-decoration: none; font-weight: bold; }

/* Responsive */
@media (max-width: 768px) {
  .mega-logo { width: 180px; }
  .menu-trigger { font-size: 28px; }
  .hero-content { padding-top: 100px; }
  .hero-content h1 { font-size: 35px; }
  .hero-content p { font-size: 18px; }
  .full-screen-hero {
    aspect-ratio: auto; /* نلغي النسبة الثابتة في الجوال */
    min-height: 70vh;   /* نعطيها ارتفاعاً مناسباً يغطي أغلب الشاشة */
    background-position: center center; /* نركز على منتصف الصورة */
    background-size: cover;
    padding: 120px 0 60px 0; /* مساحة داخلية لضمان عدم تداخل النص مع الشعار */
  }
  .building-gallery { grid-template-columns: 1fr; }
  .gallery-item { height: 250px; }
  .building-gallery .gallery-item:nth-child(3) img { width: 100%; }
}

/* حاوية صور المباني والمصادر */
.gallery-item-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.gallery-item-wrapper .source-tag {
  margin-top: 0;
  text-align: center;
  font-size: 13px;
}

/* تنسيق صورة الشباك المستقلة لتكون أصغر وواضحة */
.window-image-container {
  text-align: center;
  margin-top: 60px;
}
.window-img {
  width: 45%; /* حجم أصغر وأنيق */
  max-width: 450px;
  height: auto;
  border-radius: 15px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.15);
  object-fit: contain;
}
.window-caption {
  font-size: 16px;
  color: #5D4037;
  margin-top: 15px;
  font-style: italic;
}

/* التجاوب للجوال */
@media (max-width: 768px) {
  .window-img { width: 85%; }
}


/* تنسيقات السلايدر الأنيق */
.event-slider {
  width: 100%;
  max-width: 900px; /* عرض السلايدر */
  height: 500px; /* ارتفاع السلايدر */
  margin: 50px auto 0 auto;
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  box-shadow: 0 15px 40px rgba(0,0,0,0.2);
}

.slider-wrapper {
  width: 100%;
  height: 100%;
  position: relative;
}

.slider-img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* هذا السر يمنع قص أي جزء من الصورة مهما كانت أبعادها */
  background-color: #1A0F0C; /* لون بني داكن كخلفية أنيقة للمساحات المتبقية */
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
}


.slider-img.active {
  opacity: 1; /* إظهار الصورة النشطة فقط */
}

@media (max-width: 768px) {
  .event-slider { height: 300px; } /* تصغير الارتفاع في الجوال */
}


/* إخفاء النصوص العربية والإنجليزية افتراضياً حتى يتم تفعيل زر التبديل */
[data-lang="ar"],
[data-lang="en"] {
  display: none;
}


/* أزرار تغيير اللغة في أقصى اليسار */
.lang-switcher {
  position: absolute;
  top: 25px;
  left: 30px;
  color: #FFFFFF;
  font-weight: 600;
  font-size: 16px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.5);
  z-index: 3000;
}

.lang-btn {
  cursor: pointer;
  padding: 0 4px;
  transition: color 0.3s ease;
}

.lang-btn:hover {
  color: #4CAF50;
}

/* التجاوب للجوال: تصغير المسافات والخط */
@media (max-width: 768px) {
  .lang-switcher {
    top: 15px;
    left: 15px;
    font-size: 14px;
  }
}

.lang-btn {
  cursor: pointer;
  padding: 0 4px;
  transition: color 0.3s ease;
}

.lang-btn:hover {
  color: #4CAF50;
}

/* إصلاح الهيرو وصورة الحصاد للجوال فقط */
@media (max-width: 768px) {

  /* 1. إصلاح صورة الخلفية (الهيرو) */
  .full-screen-hero {
    aspect-ratio: 1234 / 864 !important; /* هذه أبعاد صورتك الأصلية للحفاظ عليها */
    height: auto !important;
    min-height: 500px !important; /* نعطيها ارتفاع يضمن استيعاب النص */
    padding: 0 !important;
    margin: 0 !important;
    background-position: center bottom !important; /* نركز على الدلة والمباني في الأسفل */
    background-size: cover !important;
  }

  .hero-content {
    margin-top: 0 !important;
    padding: 0 20px !important;
  }

  /* 2. إصلاح صورة حصاد القهوة */
  .media-container.custom-image-wrapper {
    width: 100% !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
  }

  .harvest-img {
    width: 100% !important;
    height: auto !important;
    object-fit: contain !important;
    display: block !important;
  }
}
