/* ============================================================
   Modern — نظام تصميم عصري كامل (تخطيط + خطوط + أشكال)
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;800;900&display=swap');

html[data-company-theme="modern"] {
  --color-primary: #0f766e;
  --color-secondary: #5eead4;
  --m-bg: #f0fdfa;
  --m-surface: #ffffff;
  --m-ink: #0b3d39;
  --m-muted: #5b7c78;
  --m-radius: 20px;
  --m-shadow: 0 12px 32px rgba(15, 118, 110, 0.14);
  --m-shadow-lg: 0 20px 50px rgba(15, 118, 110, 0.2);
}

html[data-company-theme="modern"] body,
html[data-company-theme="modern"] textarea {
  font-family: 'Tajawal', sans-serif !important;
  background-color: var(--m-bg);
  color: var(--m-ink);
}

/* ---------- Header / Navigation ---------- */
html[data-company-theme="modern"] .header,
html[data-company-theme="modern"] #header,
html[data-company-theme="modern"] .heading_section {
  background: linear-gradient(135deg, var(--color-primary) 0%, #115e59 100%) !important;
  color: #fff !important;
  box-shadow: 0 6px 24px rgba(15, 118, 110, 0.28) !important;
  border-bottom: 3px solid var(--color-secondary) !important;
  border-radius: 0 0 26px 26px !important;
}
html[data-company-theme="modern"] .heading_section h1,
html[data-company-theme="modern"] #header h1 {
  color: #fff !important;
  font-weight: 900 !important;
  letter-spacing: 0.3px;
}

/* ---------- Hero ---------- */
html[data-company-theme="modern"] .hero .icon-boxx {
  border-radius: var(--m-radius) !important;
  overflow: hidden;
  box-shadow: var(--m-shadow-lg);
}
html[data-company-theme="modern"] .hero .title a { color: #fff !important; }

/* ---------- Section headers ---------- */
html[data-company-theme="modern"] .section-header { text-align: center; }
html[data-company-theme="modern"] .section-header h2 {
  position: relative;
  display: inline-block;
  font-weight: 900 !important;
  color: var(--color-primary) !important;
  padding-bottom: 14px;
  font-size: 30px !important;
}
html[data-company-theme="modern"] .section-header h2::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 66px;
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
}
html[data-company-theme="modern"] .section-header p { color: var(--m-muted) !important; }

/* ---------- About section ---------- */
html[data-company-theme="modern"] .card1,
html[data-company-theme="modern"] .about_us_section {
  background: var(--m-surface) !important;
  border-radius: var(--m-radius) !important;
  box-shadow: var(--m-shadow) !important;
  border: 1px solid #d7f5f0 !important;
  overflow: hidden;
}
html[data-company-theme="modern"] .brand_side {
  background: linear-gradient(160deg, var(--color-primary), #115e59) !important;
  color: #fff !important;
  border-radius: var(--m-radius) !important;
  padding: 22px !important;
}
html[data-company-theme="modern"] .brand_side h3 { color: #fff !important; }

/* ---------- Blog cards ---------- */
html[data-company-theme="modern"] .blog_card {
  background: var(--m-surface) !important;
  border-radius: var(--m-radius) !important;
  box-shadow: var(--m-shadow) !important;
  border: none !important;
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease;
}
html[data-company-theme="modern"] .blog_card:hover {
  transform: translateY(-8px);
  box-shadow: var(--m-shadow-lg) !important;
}
html[data-company-theme="modern"] .blog_card .post-img img {
  transition: transform .4s ease;
}
html[data-company-theme="modern"] .blog_card:hover .post-img img { transform: scale(1.06); }
html[data-company-theme="modern"] .blog_card .post-category {
  background: var(--color-secondary);
  color: var(--m-ink);
  display: inline-block;
  border-radius: 999px;
  padding: 4px 14px;
  font-weight: 700;
  font-size: 13px;
}

/* ---------- Staff / members ---------- */
html[data-company-theme="modern"] .staf_card {
  border-radius: var(--m-radius) !important;
  box-shadow: var(--m-shadow) !important;
  overflow: hidden;
}
html[data-company-theme="modern"] .member_section .teams_h1 h1 {
  color: var(--color-primary) !important;
  font-weight: 900 !important;
}

/* ---------- Buttons ---------- */
html[data-company-theme="modern"] .custom-btn,
html[data-company-theme="modern"] .btn-primary,
html[data-company-theme="modern"] .learn-more {
  background: linear-gradient(135deg, var(--color-primary), #14b8a6) !important;
  border: none !important;
  border-radius: 999px !important;
  color: #fff !important;
  box-shadow: 0 8px 20px rgba(15, 118, 110, 0.3) !important;
  font-weight: 700 !important;
  transition: transform .2s ease, filter .2s ease;
}
html[data-company-theme="modern"] .custom-btn:hover,
html[data-company-theme="modern"] .btn-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.05);
}

/* ---------- Section background ---------- */
html[data-company-theme="modern"] .sections-bg {
  background: #ffffff !important;
  border-radius: var(--m-radius);
  box-shadow: 0 6px 22px rgba(15,118,110,.06);
}

/* ---------- Background overlay ---------- */
html[data-company-theme="modern"] body::after {
  background: linear-gradient(180deg, rgba(15,118,110,.35), rgba(240,253,250,.55)) !important;
}

/* ============================================================
   NEWS LAYOUT — Modern = بطاقات "Overlay" (النص فوق الصورة)
   ============================================================ */
html[data-company-theme="modern"] #blog .blog_card {
  display: flex !important;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  height: 360px;
  padding: 22px !important;
  border-radius: var(--m-radius) !important;
  overflow: hidden;
}
html[data-company-theme="modern"] #blog .blog_card .post-img {
  position: absolute !important;
  inset: 0 !important;
  margin: 0 !important;
  max-height: none !important;
  height: 100% !important;
  z-index: 0;
}
html[data-company-theme="modern"] #blog .blog_card .post-img img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform .5s ease;
}
html[data-company-theme="modern"] #blog .blog_card:hover .post-img img { transform: scale(1.08); }
html[data-company-theme="modern"] #blog .blog_card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11,61,57,.92) 0%, rgba(11,61,57,.35) 55%, transparent 100%);
  z-index: 1;
}
html[data-company-theme="modern"] #blog .blog_card > .post-category,
html[data-company-theme="modern"] #blog .blog_card > .title,
html[data-company-theme="modern"] #blog .blog_card > .title a,
html[data-company-theme="modern"] #blog .blog_card > .d-flex,
html[data-company-theme="modern"] #blog .blog_card .post-date {
  position: relative;
  z-index: 2;
  color: #fff !important;
}
html[data-company-theme="modern"] #blog .blog_card > .post-category {
  align-self: flex-start;
  background: var(--color-secondary);
  color: var(--m-ink) !important;
  border-radius: 999px;
  padding: 4px 14px;
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 10px;
}
html[data-company-theme="modern"] #blog .blog_card > .title { font-size: 20px !important; margin: 0 0 8px !important; }

/* ---------- Profile page ---------- */
html[data-company-theme="modern"] .profile-container .custom-section {
  border-radius: var(--m-radius) !important;
  box-shadow: var(--m-shadow) !important;
  border: 1px solid #d7f5f0 !important;
}
html[data-company-theme="modern"] .profile-container .image-section h4 { color: var(--color-primary) !important; }
