/* =========================================================================
   تنسيقات قالب المحلات والمعارض الفاخر (Master Retail Template - v6 Clean)
   هيدر فائق النحافة والأناقة لجميع الشاشات وتجربة مستخدم مثالية
   ========================================================================= */

:root {
  --primary: #0F4C30;
  --primary-light: #2D8041;
  --accent-gold: #D4AF37;
  --accent-gold-hover: #B8972E;
  --dark-bg: #0B1F17;
  --light-bg: #FAF8EE;
  --card-bg: #FFFFFF;
  --text-color: #1A2E26;
  --muted-text: #64748B;
  --border-color: #E2E8F0;
  --header-height: 75px;
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  --shadow-sm: 0 2px 8px rgba(15, 76, 48, 0.05);
  --shadow-md: 0 10px 25px rgba(15, 76, 48, 0.08);
  --shadow-lg: 0 16px 36px rgba(15, 76, 48, 0.12);
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-family: 'Cairo', 'Tajawal', -apple-system, sans-serif;
  background-color: var(--light-bg);
  color: var(--text-color);
  direction: rtl;
}

body {
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ضبط موضع التمرير لجميع الأقسام */
section[id] {
  scroll-margin-top: calc(var(--header-height) + 10px);
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 90%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 15px;
}

/* =========================================
   الهيدر النحيف والأنيق (Navbar)
   ========================================= */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  z-index: 1000;
  background: rgba(11, 31, 23, 0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(212, 175, 55, 0.25);
  display: flex;
  align-items: center;
}

.nav-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  max-width: 45%;
}

.brand-logo .logo-icon {
  font-size: 1.8rem;
  line-height: 1;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}

.brand-logo h1 {
  font-size: clamp(0.85rem, 1.5vw, 1.25rem);
  font-weight: 800;
  color: #FFFFFF;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-logo span {
  font-size: clamp(0.6rem, 1vw, 0.75rem);
  color: var(--accent-gold);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* روابط الديسكتوب */
.nav-links {
  display: flex;
  gap: 20px;
  list-style: none;
  margin: 0 auto;
}

.nav-links a {
  color: #E2E8F0;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent-gold);
  background: rgba(212, 175, 55, 0.12);
}

.header-cta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, var(--accent-gold), var(--accent-gold-hover));
  color: #0B1F17;
  font-weight: 800;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
  border: none;
  cursor: pointer;
  font-size: 0.88rem;
  transition: var(--transition);
  white-space: nowrap;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 175, 55, 0.45);
}

/* زر القائمة المنسدلة للهواتف (Hamburger) */
.mobile-toggle {
  display: none;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(212, 175, 55, 0.3);
  color: #FFFFFF;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 1.3rem;
  cursor: pointer;
  line-height: 1;
}

/* =========================================
   قسم البداية (Hero Section)
   ========================================= */
.hero-section {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, rgba(11, 31, 23, 0.95), rgba(15, 76, 48, 0.92)),
              url('https://images.unsplash.com/photo-1592945403244-b3fbafd7f539?auto=format&fit=crop&w=1600&q=80') center/cover no-repeat;
  color: #FFFFFF;
  padding: calc(var(--header-height) + 30px) 0 50px;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.badge-trust {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid rgba(212, 175, 55, 0.4);
  color: var(--accent-gold);
  padding: 5px 16px;
  border-radius: var(--radius-full);
  font-size: clamp(0.72rem, 1.4vw, 0.85rem);
  font-weight: 700;
  margin-bottom: 18px;
}

.hero-title {
  font-size: clamp(1.6rem, 3.6vw, 2.9rem);
  font-weight: 900;
  line-height: 1.3;
  margin-bottom: 16px;
}

.hero-title span {
  color: var(--accent-gold);
}

.hero-subtitle {
  font-size: clamp(0.88rem, 1.6vw, 1.1rem);
  color: #E2E8F0;
  margin-bottom: 28px;
  font-weight: 400;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 8px 20px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 700;
  transition: var(--transition);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* =========================================
   شريط الاعتمادات الرسمية (Trust Bar)
   ========================================= */
.trust-bar {
  background: #FFFFFF;
  padding: 20px 0;
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  text-align: center;
}

.trust-item h4 {
  font-size: clamp(0.95rem, 1.6vw, 1.15rem);
  font-weight: 800;
  color: var(--primary);
}

.trust-item p {
  font-size: 0.82rem;
  color: var(--muted-text);
  margin-top: 2px;
}

/* =========================================
   الأقسام العامة وقسم المنتجات
   ========================================= */
.section {
  padding: 40px 0 60px;
}

.section-header {
  text-align: center;
  max-width: 650px;
  margin: 0 auto 30px;
}

.section-tag {
  color: var(--primary-light);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 1px;
  margin-bottom: 6px;
  display: block;
}

.section-title {
  font-size: clamp(1.4rem, 2.6vw, 2.1rem);
  font-weight: 800;
  color: var(--text-color);
  margin-bottom: 8px;
}

.section-desc {
  color: var(--muted-text);
  font-size: clamp(0.85rem, 1.3vw, 0.95rem);
  line-height: 1.6;
}

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

.product-card {
  background: var(--card-bg);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(226, 232, 240, 0.8);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-gold);
}

.product-image-wrap {
  position: relative;
  height: 220px;
  overflow: hidden;
  background: #ECEFF1;
}

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

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

.product-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--primary);
  color: var(--accent-gold);
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.product-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-category {
  font-size: 0.78rem;
  color: var(--muted-text);
  margin-bottom: 4px;
  font-weight: 600;
}

.product-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-color);
  margin-bottom: 6px;
}

.product-desc {
  font-size: 0.85rem;
  color: #4A5568;
  line-height: 1.5;
  margin-bottom: 14px;
  flex-grow: 1;
}

.product-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 12px;
  border-top: 1px solid var(--border-color);
}

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

.btn-order-whatsapp {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #25D366;
  color: #FFFFFF;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  transition: var(--transition);
}

.btn-order-whatsapp:hover {
  background: #1EBE5B;
  transform: scale(1.03);
}

/* =========================================
   قسم من نحن (About)
   ========================================= */
.about-section {
  background: #FFFFFF;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 45px;
  align-items: center;
}

.about-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.about-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 18px;
}

.feature-box {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--light-bg);
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border-right: 4px solid var(--accent-gold);
}

.feature-icon {
  font-size: 1.4rem;
  line-height: 1;
}

.feature-info h4 {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--primary);
}

.feature-info p {
  font-size: 0.82rem;
  color: var(--muted-text);
  margin-top: 2px;
}

.about-image-wrap {
  width: 100%;
  height: 400px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.about-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* =========================================
   قسم التواصل (Contact)
   ========================================= */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.contact-card {
  background: #FFFFFF;
  padding: clamp(18px, 3vw, 30px);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 16px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
}

.contact-item-icon {
  width: 40px;
  height: 40px;
  background: rgba(15, 76, 48, 0.08);
  color: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.contact-item h5 {
  font-size: 0.78rem;
  color: var(--muted-text);
}

.contact-item p {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-color);
}

/* =========================================
   الفوتر (Footer)
   ========================================= */
.site-footer {
  background: var(--dark-bg);
  color: #A0AEC0;
  padding: 40px 0 20px;
  border-top: 2px solid var(--accent-gold);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 25px;
  margin-bottom: 20px;
}

.footer-brand h3 {
  color: #FFFFFF;
  font-size: 1.2rem;
  margin-bottom: 6px;
}

.footer-bottom {
  text-align: center;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.8rem;
}

/* =========================================
   زر الواتساب العائم
   ========================================= */
.floating-whatsapp {
  position: fixed;
  bottom: 18px;
  left: 18px;
  background: #25D366;
  color: #FFFFFF;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.5), 0 2px 8px rgba(0,0,0,0.2);
  z-index: 9999;
  transition: var(--transition);
  animation: pulseWhatsapp 2.5s infinite;
}

.floating-whatsapp svg {
  width: 30px;
  height: 30px;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.15));
}

.floating-whatsapp:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(37, 211, 102, 0.65);
}

@keyframes pulseWhatsapp {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.6); }
  70% { box-shadow: 0 0 0 12px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* ==========================================================
   التجاوب الذكي للشاشات المتوسطة والتابلت والهواتف (Switch at 992px)
   ========================================================== */
@media (max-width: 992px) {
  :root {
    --header-height: 58px;
  }

  .site-header {
    height: var(--header-height);
  }

  .nav-wrapper {
    height: 100%;
    gap: 8px;
  }

  .brand-logo {
    max-width: calc(100% - 150px);
    gap: 8px;
  }

  .brand-logo .logo-icon {
    font-size: 1.4rem;
  }

  .brand-logo h1 {
    font-size: clamp(0.78rem, 2.5vw, 0.95rem);
  }

  .brand-logo span {
    font-size: 0.62rem;
  }

  /* زر تسوق الآن بحجم مصغر للهاتف بجانب زر القائمة */
  .btn-primary {
    padding: 6px 12px;
    font-size: 0.74rem;
  }

  /* إظهار زر الهامبرغر ☰ */
  .mobile-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    font-size: 1.25rem;
    flex-shrink: 0;
  }

  /* القائمة المنسدلة الذكية في الهاتف والتابلت */
  .nav-container {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: rgba(11, 31, 23, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 2px solid var(--accent-gold);
    display: none;
    padding: 15px 20px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
    animation: slideDown 0.3s ease;
  }

  .nav-container.open {
    display: block;
  }

  .nav-links {
    flex-direction: column;
    width: 100%;
    gap: 12px;
  }

  .nav-links a {
    display: block;
    font-size: 1rem;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-sm);
    border-right: 3px solid var(--accent-gold);
  }

  .about-grid, .contact-grid, .footer-grid {
    grid-template-columns: 1fr;
  }

  .products-grid {
    grid-template-columns: 1fr;
  }

  .trust-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
}

/* شاشات الهواتف الضيقة (أقل من 480px) */
@media (max-width: 480px) {
  .brand-logo {
    max-width: calc(100% - 130px);
  }

  .brand-logo h1 {
    font-size: 0.82rem;
  }

  .brand-logo span {
    display: none; /* إخفاء النص الفرعي لضمان بقاء الأزرار واضحة */
  }

  .btn-primary {
    padding: 5px 9px;
    font-size: 0.7rem;
  }

  .btn-primary span:last-child {
    display: none;
  }

  .mobile-toggle {
    padding: 5px 9px;
    font-size: 1.15rem;
  }
}

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