/* ==========================================================================
   شِعاري — الخدمات المميزة في الصفحة الرئيسية
   يُحمَّل في index.html بعد styles.css و design-flat.css.

   OWNER REVISION: same visual language as the packages section (#homePackages)
   but a DIFFERENT presentation, so the two never read as the same component:
     - packages  : header strip (badge + delivery) / name / desc / price / list / full CTA
     - featured  : MEDIA-LED card (photo, replaceable from the dashboard) /
                   name / desc / price / inline CTA  — a magazine-style tile
   Uniform row, equal heights, one clear lead card, soft-square corners, and
   identity colours only (--ink / --pearl / --paper / --sand + alpha) so light
   and dark both stay on-brand. No hardcoded colour outside the two tokens.
   ========================================================================== */

#featuredServices{ padding-top:74px; }

/* عند عدم وجود أي خدمة مميزة — نخفي القسم بالكامل. */
#featuredServices.is-empty{ display:none; }

/* ============ الشبكة: ثلاثة أعمدة متساوية، بطاقات بنفس الحجم ============ */
.featured-services-grid{
  display:grid;
  grid-template-columns:repeat(3, minmax(0,1fr));
  gap:24px;
  align-items:stretch;
}
/* كل بطاقة تملأ ارتفاع صفّها — فلا تتفاوت بارتفاعاتها */
.featured-services-grid > .fs-card{
  height:100%;
  min-width:0;
}
/* إن زادت الخدمات عن ثلاثة، تُكمل في صفّ جديد بنفس المساحة */
@media (min-width:901px){
  .featured-services-grid{ grid-auto-rows:1fr; }
}

/* ============ البطاقة — مستوحاة من بطاقات الباقات ============ */
.fs-card{
  display:flex;
  flex-direction:column;
  min-height:0;
  border:1px solid var(--line) !important;
  border-radius:20px !important;
  overflow:hidden;
  background:var(--paper) !important;
  color:var(--ink) !important;
  text-decoration:none;
  transition:border-color .22s ease, transform .22s ease, background .22s ease;
}
.fs-card:hover{
  border-color:var(--ink) !important;
  transform:translateY(-5px);
}
html.dark-mode .fs-card{ background:var(--paper-2) !important; }
html.dark-mode .fs-card:hover{ background:var(--paper-2) !important; }

/* ---- الوسائط: الصورة أولاً (قابلة للاستبدال من اللوحة) ---- */
.fs-media{
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--ink);
  background:transparent;
  flex:0 0 auto;
}
.fs-media-img{
  padding:0;
  aspect-ratio:16 / 10;
  width:100%;
  overflow:hidden;
  border-bottom:1px solid var(--line) !important;
}
.fs-media-img img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transition:transform .6s cubic-bezier(.22,.61,.36,1);
}
.fs-card:hover .fs-media-img img{ transform:scale(1.04); }

/* بلا صورة: أيقونة داخل مربّع حدود ناعم (بديل بصري متّسق مع باقي الموقع).
   الأيقونة بأحجام مختلفة أصلاً (document / star / calculator …) فتنسيق
   مباشر للـsvg يجعل الأكبر منها تملأ المربّع — لذلك نثبّت مقاسًا واحدًا
   ونضع الأيقونة داخل مربّع حدود ثابت العرض والارتفاع في الوسط. */
.fs-media-icon{
  width:100%;
  aspect-ratio:16 / 7;
  border-bottom:1px solid var(--line) !important;
}
.fs-media-icon svg{
  width:74px !important;
  height:74px !important;
  color:var(--ink);
  box-sizing:border-box;
  border:1px solid var(--line);
  border-radius:16px;
  padding:16px;
  flex:0 0 auto;
}
.fs-media-icon-lg{ aspect-ratio:16 / 7; }
.fs-media-icon-lg svg{ width:88px !important; height:88px !important; }

/* ---- المتن: متمركز ومحاذي، كالIPE ---- */
.fs-card-body{
  flex:1 1 auto;
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  padding:22px 24px 24px;
  gap:0;
}
/* التصنيف: بادج ناعم بحواف لينة */
.fs-card-body .fs-cat{
  align-self:center;
  font-size:12px;
  font-weight:400;
  color:var(--muted) !important;
  background:transparent;
  border:1px solid var(--line);
  padding:5px 13px;
  border-radius:13px;
  margin-bottom:12px;
  white-space:nowrap;
  max-width:100%;
  overflow:hidden;
  text-overflow:ellipsis;
}
.fs-card h3{
  margin:0 0 9px;
  font-size:22px;
  font-weight:400;
  color:var(--ink) !important;
  line-height:1.32;
  text-align:center;
  width:100%;
}
.fs-card .fs-desc{
  margin:0 0 16px;
  font-size:14.5px;
  font-weight:400;
  color:var(--muted) !important;
  line-height:1.8;
  text-align:center;
  width:100%;
  max-width:34ch;
  flex:1 1 auto;
}
/* السعر: بارز ومتمركز — أوضح من الباقات مع إبقاء التوازن */
.fs-price{
  margin:0 0 18px !important;
  display:flex !important;
  align-items:baseline !important;
  justify-content:center !important;
  gap:7px;
  font-size:14px !important;
  color:var(--muted) !important;
  text-align:center !important;
  width:100%;
}
.fs-price strong{
  font-size:36px !important;
  font-weight:400 !important;
  line-height:1.05 !important;
  color:var(--ink) !important;
  letter-spacing:-.5px;
}
/* الزر: مربّع داكن واضح (نفس لغة بطاقات الباقات) */
.fs-cta{
  display:inline-flex !important;
  align-items:center;
  justify-content:center;
  gap:8px;
  width:100%;
  min-height:48px;
  padding:12px 20px !important;
  font-size:15px !important;
  font-weight:700;
  border-radius:14px;
  color:var(--btn-solid-fg) !important;
  background:var(--ink) !important;
  border:1.5px solid var(--ink);
  transition:opacity .2s ease, transform .2s ease;
}
.fs-cta:hover{
  color:var(--btn-solid-fg) !important;
  background:var(--ink) !important;
  opacity:.85;
  transform:translateY(-1px);
}
html.dark-mode .fs-cta{
  background:var(--ink) !important;
  color:var(--btn-solid-fg) !important;
}

/* ============ لا بطاقة قائدة: الثلاث متساوية ============
   Section layout is uniform on purpose — the owner asked for three cards of
   the SAME size side by side, so there is deliberately no enlarged lead card.
   If a lead card is ever reintroduced, keep this block with it. */

/* ==========================================================================
   بطاقة الباقة الاحترافية — بطاقة ترويجية داكنة بعرض كامل أسفل شبكة الخدمات.
   السطح ثابت الداكن (#110A05) في الوضعين الفاتح والداكن، والنص لؤلؤي
   (#DBE4FF) — هوية الموقع نفسها بلا أي لون ثالث.
   ========================================================================== */
.fs-promo{
  display:grid !important;
  grid-template-columns:minmax(0,1fr) minmax(0,1.06fr);
  align-items:center;
  gap:40px;
  margin-top:24px;
  padding:38px 44px;
  border:1px solid rgba(219,228,255,.22) !important;
  border-radius:24px !important;
  background:#110A05 !important;
  color:#DBE4FF !important;
  text-decoration:none;
  overflow:hidden;
  position:relative;
  transition:transform .22s ease, border-color .22s ease;
}
.fs-promo:hover{
  border-color:rgba(219,228,255,.45) !important;
  transform:translateY(-5px);
}

/* ---- العمود الأول: الترويسة + الوصف + السعر ---- */
.fs-promo-lead{ min-width:0; }

.fs-promo-top{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  margin-bottom:16px;
}
.fs-promo-badge{
  display:inline-flex !important;
  align-items:center;
  gap:7px;
  padding:6px 14px;
  border-radius:999px;
  font-size:12px;
  font-weight:700;
  letter-spacing:.2px;
  color:#110A05 !important;
  background:#DBE4FF !important;
  border:1px solid #DBE4FF;
  white-space:nowrap;
}
.fs-promo-badge svg{ width:14px; height:14px; }
.fs-promo-delivery{
  display:inline-flex !important;
  align-items:center;
  gap:7px;
  padding:6px 14px;
  border-radius:999px;
  font-size:12.5px;
  font-weight:400;
  color:#DBE4FF !important;
  background:rgba(219,228,255,.09) !important;
  border:1px solid rgba(219,228,255,.26);
  white-space:nowrap;
}
.fs-promo-delivery svg{ width:14px; height:14px; opacity:.9; }

.fs-promo h3{
  margin:0 0 6px;
  font-size:32px;
  font-weight:400;
  line-height:1.25;
  color:#DBE4FF !important;
}
.fs-promo-tagline{
  margin:0 0 18px;
  font-size:15px;
  font-weight:400;
  color:rgba(219,228,255,.78) !important;
}
.fs-promo-price{
  margin:0 0 22px !important;
  display:flex !important;
  align-items:baseline !important;
  flex-wrap:wrap;
  gap:9px;
}
.fs-promo-price strong{
  font-size:44px !important;
  font-weight:400 !important;
  line-height:1 !important;
  color:#DBE4FF !important;
  letter-spacing:-.5px;
}
.fs-promo-note{
  font-size:13px;
  color:rgba(219,228,255,.7) !important;
}

/* ---- العمود الثاني: قائمة المزايا ---- */
.fs-promo-features{
  list-style:none;
  margin:0;
  padding:0;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:11px 26px;
}
.fs-promo-features li{
  display:flex;
  align-items:flex-start;
  gap:10px;
  font-size:14px;
  line-height:1.6;
  color:rgba(219,228,255,.92) !important;
}
.fs-promo-features svg{
  width:17px;
  height:17px;
  flex:0 0 auto;
  margin-top:2px;
  color:#DBE4FF;
}

/* ---- الزر: مربّع لؤلؤي (معكوس عن زر البطاقات الفاتحة) ---- */
.fs-promo .fs-cta{
  width:auto;
  min-width:190px;
  color:#110A05 !important;
  background:#DBE4FF !important;
  border-color:#DBE4FF;
}
.fs-promo .fs-cta:hover{
  color:#110A05 !important;
  background:#DBE4FF !important;
  opacity:.9;
}

/* ---- تثبيت ألوان البطاقة الداكنة فوق أي تنسيق قسم محقون ----
   موصل CMS يولّد `#featuredServices h3{color:…!important}` من لون نص
   القسم متى حُفظ في اللوحة، فيكسر نصوص هذه البطاقة الداكنة. هذا التثبيت
   (معرّف + !important ولاحق في الترتيب) يبقيها لؤلؤيّة في الوضعين دائمًا. */
#featuredServices .fs-promo h3,
#featuredServices .fs-promo .fs-promo-price strong{
  color:#DBE4FF !important;
  -webkit-text-fill-color:#DBE4FF !important;
}
#featuredServices .fs-promo .fs-promo-tagline{
  color:rgba(219,228,255,.78) !important;
  -webkit-text-fill-color:rgba(219,228,255,.78) !important;
}
#featuredServices .fs-promo .fs-promo-price{
  color:#DBE4FF !important;
  -webkit-text-fill-color:#DBE4FF !important;
}

/* ---- استجابة الشاشات ---- */
@media (max-width:1000px){
  .fs-promo{ grid-template-columns:1fr; gap:28px; padding:32px 30px; }
  .fs-promo h3{ font-size:27px; }
  .fs-promo-price strong{ font-size:38px !important; }
}
@media (max-width:640px){
  .fs-promo{ padding:26px 22px; margin-top:20px; border-radius:20px !important; }
  .fs-promo h3{ font-size:23px; }
  .fs-promo-price strong{ font-size:34px !important; }
  .fs-promo-features{ grid-template-columns:1fr; gap:9px; }
  .fs-promo .fs-cta{ width:100%; min-width:0; }
}

/* ============ الاستجابة: ثلاث بطاقات متساوية تنهار بسلاسة ============ */
/* متوسطة: بطاقتان جنب بعض والثالثة بعرض الصف — لا بطاقة يتيمة صغيرة */
@media (max-width:900px){
  .featured-services-grid{ grid-template-columns:repeat(2, minmax(0,1fr)); }
  .featured-services-grid > .fs-card:last-child:nth-child(odd){ grid-column:1 / -1; }
}
@media (max-width:640px){
  #featuredServices{ padding-top:54px; }
  .featured-services-grid{ grid-template-columns:1fr; gap:20px; }
  .featured-services-grid > .fs-card:last-child:nth-child(odd){ grid-column:auto; }
  .fs-card h3{ font-size:21px; }
  .fs-price strong{ font-size:32px !important; }
  .fs-card .fs-desc{ max-width:none; }
  .fs-media-icon{ aspect-ratio:16 / 5; }
}
