/* =========================================================
   FOOTER – Premium RTL + CTA + Better Center Content
========================================================= */

.footer-ijf{
  --footer-accent: var(--accent-orange);
  --footer-text: #fff;
  --footer-muted: rgba(255,255,255,.82);
  --footer-divider: rgba(255,255,255,.14);
  --footer-bg: linear-gradient(135deg,var(--primary-blue-dark) 0%,var(--primary-blue) 100%);
  --footer-bottom-bg: rgba(0,0,0,.20);

  background: var(--footer-bg);
  color: var(--footer-text);
  direction: rtl;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.footer-ijf::before{
  content:"";
  position:absolute;
  top:0;
  inset-inline:0;
  height:3px;
  background:linear-gradient(90deg,transparent,var(--footer-accent),transparent);
  opacity:.95;
}

.footer-ijf::after{
  content:"";
  position:absolute;
  inset:0;
  background:
    radial-gradient(900px 420px at 85% 10%, rgba(255,159,0,.10), transparent 60%),
    radial-gradient(700px 380px at 15% 90%, rgba(37,99,235,.12), transparent 60%);
  pointer-events:none;
}

/* =========================================================
   ✅ Unified containers (match header)
========================================================= */
.footer-ijf-cta,
.footer-ijf-inner,
.footer-ijf-bottom-inner{
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
  padding-inline: clamp(16px, 3.2vw, 48px);
  box-sizing: border-box;
  position: relative;
  z-index: 2;
}

/* =========================
   CTA
========================= */
.footer-ijf-cta{
  padding-top: 22px;
  padding-bottom: 0;
}

.footer-ijf-cta-card{
  width: 100%;
  background: linear-gradient(135deg, rgba(255,159,0,.20), rgba(255,255,255,.06));
  border: 1px solid rgba(255,159,0,.32);
  border-radius: var(--radius-md);
  padding: 18px 24px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  box-shadow: var(--shadow-lg);
  transform: translateY(18px);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.footer-ijf-cta-title{
  font-size: 16px;
  font-weight: 900;
  font-family: "Tajawal", sans-serif;
  line-height: 1.25;
}

.footer-ijf-cta-sub{
  margin-top: 4px;
  font-size: 12.5px;
  font-weight: 700;
  color: rgba(255,255,255,.82);
  font-family: "Tajawal", sans-serif;
}

.footer-ijf-cta-actions{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
}

.footer-ijf-cta-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding: 10px 14px;
  border-radius: 14px;
  font-weight: 900;
  font-size: 12px;
  text-decoration:none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease, color .18s ease;
  font-family: "Tajawal", sans-serif;
  white-space: nowrap;
}

.footer-ijf-cta-btn.primary{
  background: linear-gradient(135deg,#ffb020,#f59e0b);
  color:#0b1f3f;
  box-shadow:0 14px 26px rgba(245,158,11,.25);
}

.footer-ijf-cta-btn.primary:hover{
  transform: translateY(-1px);
  box-shadow:0 18px 30px rgba(245,158,11,.33);
}

.footer-ijf-cta-btn.ghost{
  background:transparent;
  border:none;
  color:#fff;
  padding:0;
  font-size:13px;
  font-weight:800;
}

.footer-ijf-cta-btn.ghost:hover{
  text-decoration: underline;
  color: var(--footer-accent);
}

/* =========================
   INNER
========================= */
.footer-ijf-inner{
  padding-top: 56px; /* مساحة للـ overlap */
  padding-bottom: 26px;
}

/* =========================
   GRID (✅ middle is stronger)
========================= */
.footer-ijf-grid{
  display:grid;
  /* ✅ الوسط أعرض فعلياً */
  grid-template-columns: 1.1fr 2.2fr 1.1fr;
  gap: 26px;
  align-items: start;
  grid-template-areas: "brand links contact";
}

.footer-ijf-brand{ grid-area: brand; }
.footer-ijf-links{ grid-area: links; }
.footer-ijf-contact{ grid-area: contact; }

/* =========================
   BRAND
========================= */
.footer-ijf-brand{
  display:flex;
  gap:12px;
  align-items:flex-start;
  min-width:0;
  justify-self:start;
}

.footer-ijf-logo{
  width:46px;
  height:46px;
  border-radius: var(--radius-sm);
  overflow:hidden;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.10);
  box-shadow: 0 10px 24px rgba(0,0,0,.22);
  flex-shrink:0;
  margin-top:2px;
}

.footer-ijf-logo img{
  width:100%;
  height:100%;
  object-fit:contain;
  display:block;
}

.footer-ijf-name{
  font-weight:900;
  font-size:14px;
  line-height:1.25;
  margin-bottom:6px;
  font-family:"Tajawal",sans-serif;
}

.footer-ijf-address{
  display:flex;
  align-items:center;
  gap:8px;
  color: var(--footer-muted);
  font-size:12px;
  font-weight:700;
}

.footer-ijf-pin{
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

/* =========================
   LINKS (✅ center looks premium)
========================= */
.footer-ijf-links{
  /* ✅ خليها كتلة متماسكة بعرض العمود الأوسط */
  width: 100%;
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  align-items:start;
  justify-self:center;
  text-align:right;
}

/* ✅ عنوان أنظف + خط ثابت */
.footer-ijf-group-title{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  font-size: 11.5px;
  font-weight: 900;
  color: rgba(255,255,255,.70);
  padding-bottom: 10px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,.18);
  font-family:"Tajawal",sans-serif;
  letter-spacing:.2px;
}

/* ✅ الروابط أقل فراغ وأكثر تماسُك */
.footer-ijf-list{
  list-style:none;
  margin:0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap: 10px;
}

.footer-ijf-link{
  color: rgba(255,255,255,.86);
  text-decoration:none;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.35;
  transition: color .18s ease, transform .18s ease;
}

.footer-ijf-link:hover{
  color: var(--footer-accent);
  transform: translateX(-2px);
}

/* =========================
   CONTACT + SOCIAL
========================= */
.footer-ijf-contact{
  justify-self:end;
  min-width:0;
}

.footer-ijf-contact-label,
.footer-ijf-social-label{
  display:block;
  font-size: 11.5px;
  font-weight: 900;
  color: rgba(255,255,255,.70);
  margin-bottom: 10px;
  font-family:"Tajawal",sans-serif;
}

.footer-ijf-contact-list{
  display:flex;
  flex-direction:column;
  gap:10px;
  margin-bottom:16px;
}

.footer-ijf-contact-item{
  display:flex;
  flex-direction:row;
  align-items:center;
  gap:10px;
  text-decoration:none;
  color: rgba(255,255,255,.86);
  font-size:13px;
  font-weight:800;
  transition: color .18s ease, transform .18s ease;
  min-width:0;
}

.footer-ijf-contact-text{
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.footer-ijf-contact-item:hover{
  color: var(--footer-accent);
  transform: translateX(-2px);
}

.footer-ijf-ico{
  width:34px;
  height:34px;
  border-radius:12px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
}

/* Social */
.footer-ijf-social{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.footer-ijf-social-btn{
  width:38px;
  height:38px;
  border-radius:14px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  display:flex;
  align-items:center;
  justify-content:center;
  transition: transform .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease;
  box-shadow: 0 12px 22px rgba(0,0,0,.18);
}

.footer-ijf-social-btn:hover{
  transform: translateY(-2px);
  background: rgba(245,158,11,.18);
  border-color: rgba(245,158,11,.42);
  box-shadow: 0 16px 28px rgba(0,0,0,.24);
}

/* icon coloring */
.footer-ijf-social-btn img,
.footer-ijf-ico img,
.footer-ijf-pin img{
  width:16px;
  height:16px;
  display:block;
  filter: brightness(0) saturate(100%) invert(100%);
  opacity:.95;
}

/* =========================
   BOTTOM
========================= */
.footer-ijf-bottom{
  background: var(--footer-bottom-bg);
  border-top: 1px solid var(--footer-divider);
  position: relative;
  z-index: 2;
  margin-top: 0;
}

.footer-ijf-bottom-inner{
  padding-block: 14px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  flex-wrap:wrap;
  color: var(--footer-muted);
  font-size: 11px;
  font-weight: 700;
  font-family:"Tajawal",sans-serif;
}

.footer-ijf-bottom-links{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
}

.footer-ijf-bottom-links a{
  color: var(--footer-muted);
  text-decoration:none;
  font-weight:800;
  transition: color .18s ease;
}

.footer-ijf-bottom-links a:hover{
  color: var(--footer-accent);
}

.footer-ijf-sep{ opacity:.35; }

/* =========================
   Responsive
========================= */
@media (max-width: 1100px){
  .footer-ijf-grid{
    grid-template-columns: 1fr;
    grid-template-areas:
      "brand"
      "links"
      "contact";
    gap: 22px;
  }

  .footer-ijf-links{
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }

  .footer-ijf-contact{
    justify-self: stretch;
  }

  .footer-ijf-cta-card{
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-ijf-cta-actions{
    width: 100%;
  }

  .footer-ijf-cta-btn.primary{
    width: 100%;
  }
}

@media (max-width: 576px){
  .footer-ijf-links{
    grid-template-columns: 1fr;
  }

  .footer-ijf-cta{
    padding-top: 18px;
  }

  .footer-ijf-inner{
    padding-top: 52px;
    padding-bottom: 16px;
  }

  .footer-ijf-bottom-inner{
    flex-direction: column;
    text-align: center;
  }
}
