/* app/(public)/home.css
   Home Facelift — balanced copper + green accents
   يعمل فوق globals.css — كل القيم اللونية من التوكنز الموجودة لديك.
*/

/* =========================================================
   0) نطاق الصفحة (اختياري لكنه مستحب)
   ========================================================= */
.lan-page.home { --home-accent: var(--brand-copper); --home-accent-2: var(--success); }

/* =========================================================
   1) تحسينات عامة للعناوين والفواصل
   ========================================================= */
.lan-page.home .section-title {
  position: relative;
  letter-spacing: -.02em;
}
.lan-page.home .section-title::after {
  content: "";
  position: absolute; inset-inline: 40%; bottom: -6px;
  height: 3px; border-radius: 2px;
  background: linear-gradient(90deg, hsl(var(--brand-copper)), hsl(var(--success)));
  transition: inset-inline .25s var(--motion-in-timing);
  opacity: .65;
}
.lan-page.home .section-header:hover .section-title::after {
  inset-inline: 30%;
}

/* فاصل بصري لطيف بين المجموعات */
.lan-page.home .section-divider__orb {
  background: hsl(var(--success));
  opacity: .5;
}

/* =========================================================
   2) منطقة البطل (Hero Split)
   ========================================================= */
.lan-page.home header.section .grid > .card:first-child {
  /* بطاقة الرسالة */
  border-top: 3px solid hsl(var(--brand-copper));
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--brand-copper) / .18), transparent 60%) border-box;
}
:dir(rtl) .lan-page.home header.section .grid > .card:first-child { border-inline-end: 0; }
:dir(ltr) .lan-page.home header.section .grid > .card:first-child { border-inline-start: 0; }

/* بطاقة الهايلايت الجانبية */
.lan-page.home header.section .grid > .card:last-child {
  border-top: 3px solid hsl(var(--success));
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--success) / .14), transparent 60%) border-box;
}

/* عناصر داخل البطاقة اليمنى/اليسرى */
.lan-page.home .stats-strip .stat {
  border-color: hsl(var(--border));
  background: hsl(var(--surface));
}
.lan-page.home .stats-strip .stat:hover {
  box-shadow: var(--shadow-md);
}
.lan-page.home header.section .icon-pill {
  animation: floaty 4.5s ease-in-out infinite;
}

/* حركة عائمة رقيقة للأيقونات */
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

/* قوائم الفحص في الهيرو */
.lan-page.home .card .check-list {
  justify-items: start;
}
.lan-page.home .card .check-list li::before {
  background: hsl(var(--brand-copper) / .16);
  border-color: hsl(var(--brand-copper) / .45);
}
.lan-page.home .card .check-list li::after {
  color: hsl(var(--brand-copper));
}

/* =========================================================
   3) شريط الشركاء (Logo Wall)
   ========================================================= */
.lan-page.home section[aria-labelledby="partners-title"] > .container-xl {
  padding: 12px;
  border-radius: var(--r-card);
  border: 1px solid hsl(var(--border));
  background: linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface-2)));
  box-shadow: var(--shadow-sm);
}
.lan-page.home .logo-tile {
  filter: grayscale(.85) contrast(1.05);
  transition: transform .18s ease, filter .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.lan-page.home .logo-tile:hover {
  transform: translateY(-2px);
  filter: grayscale(.2);
  box-shadow: var(--shadow-md);
  border-color: color-mix(in hsl, hsl(var(--border)), hsl(var(--success)) 30%);
}

/* =========================================================
   4) شبكة الميزات (Value features)
   ========================================================= */
.lan-page.home section[aria-labelledby="value-title"] .card {
  border-top: 3px solid hsl(var(--success));
}
.lan-page.home section[aria-labelledby="value-title"] .icon-pill {
  background: hsl(var(--success) / .12);
  border-color: hsl(var(--success) / .35);
  color: hsl(var(--success));
}

/* =========================================================
   5) مسارات البرنامج (Tiers) — تلوين متنوّع بالترتيب
   ========================================================= */
.lan-page.home section[aria-labelledby="tiers-title"] .grid > .card:nth-child(1) {
  border-top: 3px solid hsl(var(--brand-sand));
}
.lan-page.home section[aria-labelledby="tiers-title"] .grid > .card:nth-child(2) {
  border-top: 3px solid hsl(var(--brand-copper));
}
.lan-page.home section[aria-labelledby="tiers-title"] .grid > .card:nth-child(3) {
  border-top: 3px solid hsl(var(--brand-stone));
}
.lan-page.home section[aria-labelledby="tiers-title"] .grid > .card .icon-pill {
  background: hsl(var(--muted-bg));
  border-color: hsl(var(--border));
}

/* =========================================================
   6) الفعاليات/الأنشطة/القصص — تحسينات خفيفة
   ========================================================= */
.lan-page.home section[aria-labelledby="ev-title"] .section-subtitle,
.lan-page.home section[aria-labelledby="act-title"] .section-subtitle,
.lan-page.home section[aria-labelledby="stories-title"] .section-subtitle {
  color: hsl(var(--muted-fg));
}

/* بطاقات موحّدة الهوفر */
.lan-page.home .auto-grid .card.card-hover:hover,
.lan-page.home .grid-cards .card.card-hover:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* اقتباسات لاحقة تحت القصص */
.lan-page.home blockquote.card .card-content p {
  position: relative;
  padding-inline-start: 18px;
}
.lan-page.home blockquote.card .card-content p::before {
  content: "“";
  position: absolute; inset-inline-start: 0; top: -4px;
  font-size: 1.4rem; line-height: 1; color: hsl(var(--brand-copper));
  opacity: .8;
}

/* =========================================================
   7) Trust highlights (المكوّن لديك)
   ========================================================= */
.lan-page.home [aria-label="مزايا المنارة"] .card {
  border: 1px solid hsl(var(--border));
  background: hsl(var(--surface));
}
.lan-page.home [aria-label="مزايا المنارة"] .icon-pill.tone-copper-solid,
.lan-page.home [aria-label="مزايا المنارة"] .icon-pill.tone-stone-solid,
.lan-page.home [aria-label="مزايا المنارة"] .icon-pill.tone-sand-solid,
.lan-page.home [aria-label="مزايا المنارة"] .icon-pill.tone-ink-solid {
  box-shadow: var(--shadow-xs);
}

/* =========================================================
   8) FAQ — details/summary محسّنة
   ========================================================= */
.lan-page.home section[aria-labelledby="faq-title"] details.card {
  overflow: hidden;
}
.lan-page.home section[aria-labelledby="faq-title"] details.card summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between;
}
.lan-page.home section[aria-labelledby="faq-title"] details.card summary::after {
  content: "▾"; color: hsl(var(--muted-fg));
  transition: transform .2s ease;
}
.lan-page.home section[aria-labelledby="faq-title"] details[open].card summary::after {
  transform: rotate(180deg);
}
.lan-page.home section[aria-labelledby="faq-title"] details[open].card summary {
  border-bottom: 1px solid hsl(var(--border));
}

/* =========================================================
   9) نشرة بريدية (Newsletter CTA)
   ========================================================= */
.lan-page.home .cta-bar {
  border-color: hsl(var(--success) / .28);
  background: linear-gradient(180deg, hsl(var(--success) / .10), hsl(var(--surface)));
}
.lan-page.home .cta-bar .input-lg {
  min-width: min(380px, 100%);
}
@media (max-width: 520px) {
  .lan-page.home .cta-bar .input-lg { min-width: 100%; }
}

/* =========================================================
   10) شارات الاعتماد/الذكر
   ========================================================= */
.lan-page.home .chips .chip {
  border-color: hsl(var(--border));
  background: hsl(var(--muted-bg));
}
.lan-page.home .chips .chip:hover {
  border-color: hsl(var(--success) / .4);
  color: hsl(var(--success));
}

/* =========================================================
   11) إضافات صورية خفيفة (خطوط فاصلة/ظلال)
   ========================================================= */
.lan-page.home .card {
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--surface-2)), transparent 60%) border-box;
}

/* إبراز ناعم للأزرار عند التركيز */
.lan-page.home .btn:focus-visible {
  box-shadow: 0 0 0 3px hsl(var(--success) / .22);
}

/* =========================================================
   12) شريط التمرير (ScrollProgress) إن وجد
   ========================================================= */
.lan-page.home .manarah-scrollbar {
  opacity: 1;
  background:
    linear-gradient(90deg, hsl(var(--success)) var(--_p, 0%), transparent 0),
    linear-gradient(90deg, hsl(var(--border)), hsl(var(--border)));
}

/* =========================================================
   13) لمسات RTL
   ========================================================= */
:dir(rtl) .lan-page.home .card .check-list li { padding-inline-start: 28px; }
:dir(ltr) .lan-page.home .card .check-list li { padding-inline-start: 28px; }

/* =========================================================
   14) تأثيرات دخول خفيفة (يمكنك استعمال Framer حيث يلزم)
   ========================================================= */
.lan-page.home .card.card-hover {
  transition: transform .18s ease, box-shadow .18s ease, background-color .15s ease, border-color .15s ease;
}
.lan-page.home .card.card-hover:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* =========================================================
   15) تحسين طفيف لمقاطع “band” إن أردت استخدامها
   (ضع class="home-band" على أي div لتكوين شريط بارز)
   ========================================================= */
.lan-page.home .home-band {
  border: 1px solid hsl(var(--border));
  border-radius: var(--r-card);
  padding: 12px;
  background: linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface-2)));
  box-shadow: var(--shadow-sm);
}




/* =========================================================
   16) Background Textures — Fabric / Paper / Dots
   خفيفة + قابلة للتخصيص + متوافقة مع RTL/Dark
   فعِّلها عبر data-bg على .lan-page.home (fabric|paper|dots)
   ========================================================= */

.lan-page.home {
  /* نُعَوِّم الخلفية لنضع طبقات عبر ::before/::after */
  position: relative;
  isolation: isolate;
}

/* طبقة "النسيج" الرئيسية (pattern/texture) */
.lan-page.home::before {
  content: "";
  position: fixed; /* تمتد الشاشة كلها */
  inset: 0;
  z-index: -2;
  pointer-events: none;

  /* افتراضيًا: fabric */
  --_line: hsl(var(--brand-ink) / 0.028);
  --_cross: hsl(var(--brand-ink) / 0.022);
  --_noise-opacity: 0.06;

  /* طبقات: خطوط قماش متقاطعة + ضوضاء SVG خفيفة */
  background-image:
    /* cross-hatch (45deg) */
    repeating-linear-gradient(45deg, var(--_line) 0 2px, transparent 2px 7px),
    /* cross-hatch (-45deg) */
    repeating-linear-gradient(-45deg, var(--_cross) 0 2px, transparent 2px 7px),
    /* procedural noise via SVG (feTurbulence) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140' viewBox='0 0 140 140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='140' height='140' filter='url(%23n)' opacity='0.06'/></svg>");
  background-size:
    22px 22px,
    28px 28px,
    240px 240px;
  background-repeat: repeat;
  opacity: 0.9;
}

/* طبقة تلوين واسعة + فينييت خفيف على الأطراف (تعطي عمق بدون تشويش) */
.lan-page.home::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;

  /* تدرّجات واسعة بالعلامة التجارية (emerald + copper) */
  background-image:
    radial-gradient(60% 45% at 15% -10%, hsl(var(--success) / 0.06), transparent 60%),
    radial-gradient(65% 50% at 110% 110%, hsl(var(--brand-copper) / 0.06), transparent 58%),
    linear-gradient(180deg, hsl(var(--bg)), hsl(var(--bg)));
  background-repeat: no-repeat;
  background-size: auto, auto, auto;

  /* فينييت ناعم حول الحواف */
  box-shadow: inset 0 0 120px 40px hsl(var(--brand-ink) / 0.06);
}

/* ------- أوضاع بديلة عبر data-bg ------- */

/* Paper: حبيبات ورق ناعمة دون تقاطعات */
.lan-page.home[data-bg="paper"]::before {
  --_noise-opacity: 0.07;
  background-image:
    /* speckles خفيفة */
    radial-gradient(circle at 10% 20%, hsl(var(--brand-ink) / 0.02) 0 0.5px, transparent 0 10px),
    radial-gradient(circle at 80% 70%, hsl(var(--brand-ink) / 0.02) 0 0.5px, transparent 0 10px),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140' viewBox='0 0 140 140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='140' height='140' filter='url(%23n)' opacity='0.07'/></svg>");
  background-size:
    28px 28px,
    36px 36px,
    260px 260px;
  opacity: 0.9;
}

/* Dots: نسيج نقاطي شبه مهني */
.lan-page.home[data-bg="dots"]::before {
  background-image:
    radial-gradient(1px 1px at 10px 10px, hsl(var(--brand-ink) / 0.06) 1px, transparent 0),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140' viewBox='0 0 140 140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='140' height='140' filter='url(%23n)' opacity='0.05'/></svg>");
  background-size:
    20px 20px,
    240px 240px;
  opacity: 0.85;
}

/* ------- Dark mode ضبط ألوان الخلفية ------- */
.dark .lan-page.home::before {
  --_line: hsl(var(--tertiary-fg) / 0.05);
  --_cross: hsl(var(--tertiary-fg) / 0.04);
  opacity: 0.55; /* أقل كي لا تزحم المحتوى */
}
.dark .lan-page.home::after {
  background-image:
    radial-gradient(60% 45% at 15% -10%, hsl(var(--success) / 0.10), transparent 60%),
    radial-gradient(65% 50% at 110% 110%, hsl(var(--brand-copper) / 0.10), transparent 58%),
    linear-gradient(180deg, hsl(var(--bg)), hsl(var(--bg)));
  box-shadow: inset 0 0 160px 60px hsl(var(--black) / 0.35);
}

/* ------- حساسية الحركة/الشاشات الصغيرة ------- */
@media (max-width: 640px) {
  .lan-page.home::before { opacity: 0.75; background-size: 24px 24px, 30px 30px, 280px 280px; }
  .lan-page.home::after  { box-shadow: inset 0 0 90px 30px hsl(var(--brand-ink) / 0.06); }
}
@media (prefers-reduced-motion: reduce) {
  .lan-page.home::after { background-attachment: initial; }
}

/* ------- زر إطفاء الخامة عند الحاجة (Debug/Performance) ------- */
.no-texture .lan-page.home::before,
.no-texture .lan-page.home::after { display: none !important; }


/* === Texture intensity (soft | normal | bold) === */
.lan-page.home[data-bg-strength="soft"]::before { opacity: .55; }
.lan-page.home[data-bg-strength="soft"]::after  { box-shadow: inset 0 0 80px 28px hsl(var(--brand-ink) / 0.05); }

.lan-page.home[data-bg-strength="bold"]::before { opacity: 1; }
.lan-page.home[data-bg-strength="bold"]::after  { box-shadow: inset 0 0 140px 48px hsl(var(--brand-ink) / 0.08); }

/* Mobile tuning */
@media (max-width: 480px){
  .lan-page.home::before{ opacity:.7 }
  .lan-page.home::after{ box-shadow: inset 0 0 70px 24px hsl(var(--brand-ink)/.05) }
}



/* =========================================================
   17) Responsive compact (Home-only)
   ========================================================= */

/* ≤ 640px: تقليل الإيقاع العام + استغلال العرض */
@media (max-width: 640px){
  .lan-page.home .section{ padding-block:12px; }
  .lan-page.home .section + .section{ margin-block-start:12px; }
  .lan-page.home .section-header{ padding-inline:8px; }

  /* العنوان: خط التزيين أقصر وأنحف */
  .lan-page.home .section-title::after{
    inset-inline: 34%;
    height: 2px;
    bottom: -4px;
  }

  /* بطاقات وأشباهها */
  .lan-page.home .card .card-content{ padding:10px; }
  .lan-page.home .auto-grid,
  .lan-page.home .grid-cards{ gap:10px; }

  /* شريط الأرقام والشركاء */
  .lan-page.home .stats-strip{ gap:10px; }
  .lan-page.home .logo-tile{ min-height:62px; padding:8px; }
  .lan-page.home .logo-img{ max-height:40px; }

  /* Hero (إن وُجد كـ hero-split) */
  .lan-page.home .hero-split{ border-radius:12px; }
  .lan-page.home .hero-split__content,
  .lan-page.home .hero-split__visual{ padding:10px; }
  .lan-page.home .hero-split__list{ gap:6px; }
  .lan-page.home .hero-split__actions{ gap:8px; }

  /* Audience / HowItWorks / Stepper */
  .lan-page.home .stepper > li{ padding:10px; }
  .lan-page.home .icon-pill{ inline-size:34px; block-size:34px; }

  /* Events/Activities/Stories grids */
  .lan-page.home [aria-labelledby="ev-title"] .section-subtitle,
  .lan-page.home [aria-labelledby="act-title"] .section-subtitle,
  .lan-page.home [aria-labelledby="stories-title"] .section-subtitle{ font-size:.9rem; }

  /* اقتباسات تحت القصص */
  .lan-page.home blockquote.card .card-content p{ padding-inline-start:14px; }
}

/* ≤ 480px: حواف Edge-to-Edge + ضغط أقوى */
@media (max-width: 480px){
  /* غلاف شركاء السوشال/الشركاء */
  .lan-page.home section[aria-labelledby="partners-title"] > .container-xl{
    padding:8px; border-radius:12px; box-shadow:none;
  }

  /* أزرار */
  .lan-page.home .btn-lg{ min-height:44px; padding-inline:14px; }
  .lan-page.home .btn-md{ min-height:38px; }
  .lan-page.home .btn-sm{ min-height:32px; }

  /* CTA البريد */
  .lan-page.home .cta-bar{ padding:10px; }
  .lan-page.home .cta-bar .input-lg{ min-width:100%; }

  /* شريط التمرير أعلى الصفحة */
  .lan-page.home .manarah-scrollbar{ height:2px; }
}

/* ≤ 360px: قصوى الضغط بدون كسر */
@media (max-width: 360px){
  .lan-page.home .section{ padding-block:10px; }
  .lan-page.home .section + .section{ margin-block-start:10px; }
  .lan-page.home .card .card-content{ padding:8px; }
  .lan-page.home .auto-grid,
  .lan-page.home .grid-cards,
  .lan-page.home .stats-strip{ gap:8px; }
  .lan-page.home .section-title{ font-size: clamp(1.35rem, 1rem + 1.2vw, 1.6rem); }
  .lan-page.home .section-title::after{ inset-inline: 40%; }
}

/* وضع مضغوط إجباري (اختياري): فعّله بإضافة data-compact="true" على .lan-page.home */
.lan-page.home[data-compact="true"] .container-xl{ width:100%; margin-inline:0; }
.lan-page.home[data-compact="true"] .section{ padding-block:10px; }
.lan-page.home[data-compact="true"] .section + .section{ margin-block-start:10px; }
.lan-page.home[data-compact="true"] .card .card-content{ padding:10px; }



/* === Container reset & mobile gutters (final override) === */

/* Desktop / default: no internal padding, centered max-width */
.container,
.container-xl{
  width: min(100% - 24px, var(--container-max));
  margin-inline: auto;
  padding-inline: 0; /* مهم: لا نضيف padding على الديسكتوب لتفادي التضاعف */
  box-sizing: border-box;
}

/* Mobile: full width + single small gutter (no width shrinking) */
@media (max-width: 640px){
  :root{ --mobile-gutter: 3px; } /* عدّلها لـ 8/12 حسب ذوقك */

  .container,
  .container-xl{
    width: 100% !important;          /* لا نُصغّر العرض */
    margin-inline: 0 !important;      /* لا نحتاج auto */
    padding-inline: var(--mobile-gutter) !important; /* gutter واحد فقط */
  }

  /* لا تسمح بتراكم الـ padding إذا كان في Container داخل Container */
  .container > .container,
  .container > .container-xl,
  .container-xl > .container,
  .container-xl > .container-xl{
    width: 100% !important;
    margin: 0 !important;
    padding-inline: 0 !important;
  }

  /* مقاطع تريدها تتمدّد للحافة (سلايدر، هيرو)، ضع class="edge-mobile" على الغلاف الداخلي */
  .edge-mobile{
    margin-inline: calc(-1 * var(--mobile-gutter)) !important;
    padding-inline: 0 !important; /* نخلي المحتوى يلمس الحافة */
  }

  /* خفّف أي padding أفقي عام على الأقسام لو وُجد */
  .section{ padding-inline: 0 !important; }
}

/* Tip: لا تجمع بين width: min(100% - X) و padding-inline على نفس العنصر في الجوال. اختر أحدهما فقط. */

/* app/home-visuals.css
   إضافات مرئية للصفحة الرئيسية — متوافقة مع Server Components
*/

.hero-art{
  border: 1px solid hsl(var(--border));
  border-radius: var(--r-blob);
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--success)/.10), transparent 60%) border-box;
  min-height: 160px;
  position: relative;
  overflow: hidden;
}

/* عناصر زخرفية عائمة فوق الرسم */
.hero-accent{
  position: absolute;
  filter: drop-shadow(0 8px 20px hsl(var(--brand-ink)/.18));
  opacity: .95;
  animation: floaty 6s ease-in-out infinite;
}
.accent-a{ inset-inline-start: 10px; bottom: -12px; animation-delay: .2s; }
.accent-b{ inset-inline-end: 12px; top: -10px; animation-delay: .6s; }

@keyframes floaty {
  0%, 100% { transform: translateY(0) }
  50%      { transform: translateY(-6px) }
}

/* بطاقات لقطات الشاشة */
.peek-grid .card{
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--surface-2)), transparent 60%) border-box;
  border-top: 3px solid hsl(var(--brand-emerald));
}

/* شريط CTA بصري */
.cta-band{
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
  align-items: center;
  border: 1px solid hsl(var(--border));
  border-radius: var(--r-card);
  padding: 12px;
  background: linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface-2)));
}
@media (min-width: 860px){
  .cta-band{ grid-template-columns: 1fr auto; padding: 16px 18px; }
  .cta-visual{ max-width: 320px; }
}

/* app/peek.css */
/* ——— الحاوية العامة للقسم ——— */
.peek-section{
  position: relative;
  isolation: isolate;
}

/* ——— خلفية تموّجات لطيفة مع حركة ——— */
.peek-bg{
  position: absolute;
  inset: -8px;
  z-index: -1;
  pointer-events: none;

  /* طبقات: تموّج نحاسي + أخضر على خلفية خافتة */
  --c1: hsl(var(--brand-copper) / .10);
  --c2: hsl(var(--brand-emerald) / .10);
  --c3: hsl(var(--muted-bg));
  background:
    radial-gradient(60% 45% at 15% 10%, var(--c1), transparent 60%),
    radial-gradient(55% 50% at 85% 20%, var(--c2), transparent 58%),
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface-2)));
  filter: saturate(1.05) contrast(1.02);

  /* أمواج ممسوحة (mask) تعطي حواف متموّجة بدل المربع الصِرف */
  -webkit-mask-image:
    radial-gradient(120% 60% at 50% -20%, #000 60%, transparent 61%),
    radial-gradient(120% 60% at 50% 120%, #000 60%, transparent 61%);
  -webkit-mask-composite: source-over;
  mask-image:
    radial-gradient(120% 60% at 50% -20%, #000 60%, transparent 61%),
    radial-gradient(120% 60% at 50% 120%, #000 60%, transparent 61%);

  border-radius: 22px;
  box-shadow: var(--shadow-sm);
  animation: peekFloat 10s ease-in-out infinite alternate;
}

@keyframes peekFloat{
  0%   { transform: translateY(0px) }
  100% { transform: translateY(6px) }
}

/* ——— قائمة البطاقات ——— */
.peek-list{
  display: grid;
  gap: 14px;
}

/* بطاقة مفصّلة: صورة أصغر + محتوى أغنى */
.peek-card{
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(220px, 360px) 1fr; /* ← الصورة حوالي “نصف” السابق */
  align-items: center;
  border-radius: var(--r-card);
  border: 1px solid hsl(var(--border));
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--surface-2)), transparent 60%) border-box;
  overflow: hidden;
}

.peek-card:hover{ box-shadow: var(--shadow-md) }

/* جانب الصورة */
.peek-media{
  position: relative;
  margin: 8px;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: hsl(var(--muted-bg));
  border: 1px solid hsl(var(--border));
}

.peek-img{
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  transform: translateZ(0);
  transition: transform .25s cubic-bezier(.22,1,.36,1), filter .25s ease;
}

.peek-card:hover .peek-img{
  transform: scale(1.03);
  filter: saturate(1.03);
}

/* جانب النص */
.peek-body{
  padding: 12px 12px 12px 4px;
}

.peek-h{
  font-weight: 900;
  letter-spacing: -.01em;
  margin-bottom: 6px;
}

.peek-bullets{
  margin: 8px 0 10px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
}
.peek-bullets li{
  position: relative;
  padding-inline-start: 22px;
  color: hsl(var(--fg));
}
.peek-bullets li::before{
  content: "✓";
  position: absolute;
  inset-inline-start: 0;
  top: 0;
  width: 16px;
  height: 16px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 12px;
  line-height: 1;
  background: hsl(var(--brand-emerald)/.14);
  border: 1px solid hsl(var(--brand-emerald)/.38);
  color: hsl(var(--brand-emerald));
}

/* شارات صغيرة أسفل كل بطاقة */
.peek-meta{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* ——— CTA أسفل القسم ——— */
.peek-cta{
  margin-top: 12px;
  padding: 12px;
  border-radius: var(--r-card);
  border: 1px solid hsl(var(--border));
  background: linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface-2)));
  display: grid; gap: 10px; grid-template-columns: 1fr auto; align-items: center;
}
.peek-cta__text{ display: grid; gap: 2px }

/* ——— استجابة ——— */
@media (max-width: 900px){
  .peek-card{ grid-template-columns: 1fr }
  .peek-body{ padding: 10px }
  .peek-media{ margin: 10px; aspect-ratio: 16/10 }
}
@media (max-width: 520px){
  .peek-bullets li{ padding-inline-start: 18px }
  .peek-bullets li::before{ border-radius: 5px }
  .peek-cta{ grid-template-columns: 1fr; gap: 8px }
}

/* تكبير الأيقونات + تنسيق متناسق مع النظام */

.aud-grid { --min: 300px; }

.aud-card{
  position: relative;
  overflow: hidden;
  border-top: 4px solid hsl(var(--accent));
  background:
    linear-gradient(180deg, hsl(var(--surface)), hsl(var(--surface))) padding-box,
    linear-gradient(180deg, hsl(var(--muted-bg)), transparent 60%) border-box;
}

/* تأثير التيلت */
.aud-tilt{
  transform: perspective(1000px)
             rotateX(var(--tiltX, 0deg))
             rotateY(var(--tiltY, 0deg));
  transform-style: preserve-3d;
  will-change: transform;
  transition: transform .12s ease-out;
}

/* هالة متتبّعة للمؤشر */
.aud-glow{
  position: absolute;
  inset: -1px;
  pointer-events: none;
  background:
    radial-gradient(240px 160px at var(--mx, 50%) var(--my, 50%),
      hsl(var(--accent) / .16), transparent 55%);
  opacity: .75;
  transition: opacity .2s ease;
}

/* حاوية الأيقونة الكبيرة */
.aud-icon{
  width: 104px; height: 104px;
  border-radius: 18px;
  background: hsl(var(--muted-bg));
  border: 1px solid hsl(var(--border));
  display: inline-grid; place-items: center;
  box-shadow: var(--shadow-xs);
}

/* صورة الإليستريتور الكبيرة */
.aud-icon-img{
  width: 84px; height: 84px;
  -o-object-fit: contain;
     object-fit: contain;
  image-rendering: auto;
}

/* العنوان والفائدة */
.aud-title{
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: .01em;
  line-height: 1.35;
  margin-top: 2px;
}
.aud-benefit{ line-height: 1.8; }

/* تفاعل لطيف */
.aud-card:hover .aud-icon{
  border-color: hsl(var(--accent) / .5);
  box-shadow: var(--shadow-sm);
}
.aud-card:hover .aud-title{
  color: hsl(var(--accent));
}

/* موبايل: أحجام أصغر قليلًا */
@media (max-width: 640px){
  .aud-icon{ width: 88px; height: 88px; border-radius: 16px; }
  .aud-icon-img{ width: 72px; height: 72px; }
  .aud-title{ font-size: 1rem; }
}

/* ==========================================================================
   Events — Responsive, Polished, RTL-safe (NO horizontal scroll)
   ========================================================================== */

/* ===== 0) Hard guard: لا تمرير أفقي على مستوى الصفحة (كشبّاك أمان) ===== */
html, body, .lan-page {
  overflow-x: hidden;
}

/* ===== 0.1) حاوية هذا القسم تحديداً ===== */
.events-root {
  overflow-x: clip;   /* يقطع أي تمدد داخلي */
  max-width: 100%;
}
.events-root * {
  max-width: 100%;    /* لا أحد يتجاوز عرض الحاوية */
  box-sizing: border-box;
}

/* Utilities محلية */
.truncate-2{
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3{
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* مهم جدًا: لا تسمح لعناصر معيّنة تطوّل أفقيًا */
.events-groups,
.events-grid,
.event-card,
.event-body,
.event-meta {
  min-inline-size: 0;
}
.event-title,
.event-desc,
.event-meta {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* =============== 1) Filters (scrollable chips) =============== */
.events-filter{
  display:flex; gap:8px;
  overflow:auto; -webkit-overflow-scrolling: touch;
  padding:6px 2px 10px;
  margin-block-end: 10px;
  scrollbar-width: none;
  max-width: 100%;         /* ألزم الفلاتر بعرض الحاوية */
}
.events-filter::-webkit-scrollbar{ display:none; }

.filter-chip{
  padding:8px 12px; border-radius:999px;
  font-weight:800; font-size:.86rem; line-height:1;
  border:1px solid hsl(var(--border));
  background:hsl(var(--muted-bg)); color:hsl(var(--muted-fg));
  white-space:nowrap; -webkit-user-select:none; -moz-user-select:none; user-select:none;
  transition: background-color .15s ease, border-color .15s ease, transform .15s ease, color .15s ease, box-shadow .15s ease;
  will-change: transform;
}
.filter-chip:hover{ transform: translateY(-1px); }
.filter-chip:focus-visible{
  outline: none;
  box-shadow: 0 0 0 3px hsl(var(--brand-copper) / .22);
  border-color: hsl(var(--brand-copper) / .45);
}
.filter-chip.is-active{
  background:hsl(var(--brand-copper)/.14);
  border-color:hsl(var(--brand-copper)/.45);
  color:hsl(var(--brand-copper));
}
.filter-chip[data-tone="seminar"].is-active{
  background:hsl(var(--brand-stone)/.14);
  border-color:hsl(var(--brand-stone)/.45);
  color:hsl(var(--brand-stone));
}
.filter-chip[data-tone="festival"].is-active{
  background:hsl(var(--brand-sand)/.22);
  border-color:hsl(var(--brand-sand)/.45);
  color:hsl(var(--tertiary-fg));
}
.filter-chip[data-tone="online"].is-active{
  background:hsl(var(--brand-emerald)/.14);
  border-color:hsl(var(--brand-emerald)/.45);
  color:hsl(var(--brand-emerald));
}

/* =============== 2) Groups (desktop/tablet) =============== */
.events-groups{ display:grid; gap:14px; }
.events-group{ display:grid; gap:12px; margin-top: 12px; }
.events-group__head{
  display:grid; grid-template-columns:auto 1fr; align-items:center; gap:10px;
}
.events-group__title{
  margin:0;
  font-weight:900; letter-spacing:-.01em;
  font-size: clamp(1.06rem, .95rem + .6vw, 1.28rem);
}
.events-group__rule{
  height:1px;
  background: linear-gradient(90deg, hsl(var(--brand-copper)), hsl(var(--success)));
  border-radius:2px; opacity:.35;
}

/* =============== 3) Grid — أقصى أمان ضد الـoverflow =============== */
.events-grid{
  --min: 280px;
  display:grid; gap:12px;
  /* المهم: اجعل الـmin داخل 100% دومًا */
  grid-template-columns: repeat(auto-fit, minmax(min(var(--min), 100%), 1fr));
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
}
.events-grid > * { min-width: 0; }

/* =============== 4) Card =============== */
.event-card{
  display:grid; grid-template-columns: 74px 1fr; gap:12px;
  border:1px solid hsl(var(--border));
  border-radius: var(--r-card);
  background: hsl(var(--surface));
  box-shadow: var(--shadow-sm);
  padding: 12px;
  transition: box-shadow .18s ease, transform .18s ease, border-color .15s ease, background .18s ease, color .18s ease;
  min-height: 172px;
  position: relative; isolation: isolate;

  width: 100%;
  max-width: 100%;
  overflow: clip; /* لا تسمح بطفح المحتوى أفقيًا */
}

/* Top tone stripe */
.event-card::before{
  content: "";
  position: absolute; inset-inline: 0; top: 0; height: 3px;
  border-top-left-radius: var(--r-card); border-top-right-radius: var(--r-card);
  background: hsl(var(--brand-copper)); opacity: .95;
}
.event-card[data-tone="seminar"]::before{  background: hsl(var(--brand-stone)); }
.event-card[data-tone="festival"]::before{ background: hsl(var(--brand-sand)); }
.event-card[data-tone="online"]::before{   background: hsl(var(--brand-emerald)); }

/* Hover الأخضر + تناغم النص */
.event-card:hover{
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.event-card::after{
  content:"";
  position:absolute; inset:-35%;
  background:
    radial-gradient(260px 200px at var(--mx, 50%) var(--my, 50%),
      hsl(147 8% 38% / .16), transparent 60%);
  opacity: 0; pointer-events:none;
  transition: opacity .2s ease;
}
.event-card:hover::after{ opacity: 1; }
.event-card:hover .event-title{ color: hsl(var(--brand-olive)); }
.event-card:hover .event-meta{ color: hsl(var(--brand-olive)); }

/* Date column */
.event-date{
  display:grid; place-items:center; align-content:center; gap:2px;
  border:1px dashed hsl(var(--border));
  border-radius: 12px;
  background: hsl(var(--muted-bg));
  min-height: 100%;
}
.event-date__day{
  font-weight:900; font-size: clamp(1.25rem,1rem + .9vw,1.6rem);
}
.event-date__mon{
  font-weight:800; font-size:.85rem; color:hsl(var(--muted-fg));
}

/* Body */
.event-body{
  display:grid; grid-template-rows: auto auto 1fr auto; gap:6px;
  min-width: 0;
}
.event-head{
  display:flex; flex-wrap:wrap; gap:8px; align-items:center; justify-content: space-between;
}
.event-title{
  font-size:1.05rem; font-weight:800; line-height:1.3; margin:0; max-width: 100%;
}
.event-meta{
  display:flex; flex-wrap:wrap; align-items:center; gap:6px;
  color:hsl(var(--muted-fg));
  font-size:.92rem;
}
.event-desc{ color:hsl(var(--muted-fg)); font-size:.95rem; }

/* Actions */
.event-actions{
  display:flex; gap:8px; align-items:center; justify-content:flex-start; margin-top:4px;
}
.event-actions .btn:focus-visible{
  outline: none;
  box-shadow: 0 0 0 3px hsl(var(--ring) / .28);
}

/* =============== 5) Mobile (slider edge-to-edge) =============== */
.ev-embla { position: relative; max-width: 100%; overflow: hidden; }
.ev-embla .embla__viewport { overflow: hidden; max-width: 100%; }
.ev-embla .embla__container { will-change: transform; max-width: 100%; }
.ev-embla .embla__slide,
.ev-slide {
  box-sizing: border-box;
  max-width: 100%;
}

.ev-slide { flex: 0 0 94%; padding-inline: 8px; }
@media (max-width: 420px){
  .ev-slide { flex-basis: 96%; padding-inline: 6px; }
}

@media (max-width: 767px){
  :root{ --mobile-gutter: 3px; }

  /* الفلاتر تبقى قابلة للتمرير داخليًا بدون ما تكسر الصفحة */
  .events-filter{
    margin-inline: 0;
    padding-inline: var(--mobile-gutter);
  }

  /* Embla كسلسلة عناصر تحت بعض (بدون overlay) */
  .ev-embla .embla{
    display: grid;
    grid-template-areas:
      "viewport"
      "arrows"
      "dots";
    row-gap: 8px;
    max-width: 100%;
  }
  .ev-embla .embla__viewport{ grid-area: viewport; }
  .ev-embla :where(.embla__arrows, .embla__controls, .embla__buttons){
    grid-area: arrows;
    position: static !important;
    display: flex; justify-content: center; gap: 10px; margin-top: 2px;
  }
  .ev-embla :where(.embla__prev, .embla__next, .embla__button, .embla__button--prev, .embla__button--next){
    position: static !important; inset: auto !important; transform: none !important;
    width: 42px; height: 42px; border-radius: 12px;
  }
  .ev-embla .embla__dots{
    grid-area: dots;
    display: flex; justify-content: center; gap: 6px; margin-top: 2px; position: static !important;
  }

  /* بطاقة أصغر عمود تاريخ */
  .event-card{ grid-template-columns: 64px 1fr; }
  .event-date{ border-radius: 10px; }

  /* إصلاح RTL: سحب LTR، محتوى RTL */
  [dir="rtl"] .ev-embla .embla__container{ direction: ltr; }
  [dir="rtl"] .ev-embla .embla__slide{ direction: rtl; }
}

/* =============== 6) Tablet / Desktop columns =============== */
/* عمود واحد مريح للتابلت الصغيرة */
@media (min-width: 768px){
  .events-grid{ grid-template-columns: repeat(1, minmax(0,1fr)); }
}
/* عمودان للديسكتوب المتوسط */
@media (min-width: 1024px){
  .events-grid{ grid-template-columns: repeat(2, minmax(0,1fr)); }
}
/* ثلاثة أعمدة للشاشات العريضة فقط */
@media (min-width: 1360px){
  .events-grid{ grid-template-columns: repeat(3, minmax(0,1fr)); }
}

/* =============== 7) Reduced motion =============== */
@media (prefers-reduced-motion: reduce){
  .event-card,
  .filter-chip{ transition: none !important; }
}

/* Hero Split — تفاعلي، بسيط، واضح (بدون تغبيش) */

.hero-split {
  --hs-gap: clamp(14px, 2.2vw, 22px);
  --hs-pad: clamp(14px, 3vw, 26px);
  --hs-br: 18px;

  /* نقاط الهالة الافتراضية (تتغير مع المؤشر) */
  --mx: 50%;
  --my: 50%;

  /* لون النبرة النشط (يتغير حسب الكلاس) */
  --accent: hsl(var(--brand-copper));
  --accent-2: hsl(var(--brand-olive)); /* مزج نحاسي + زيتي بشكل لطيف */

  position: relative;
  isolation: isolate;
}
.hero-split .container-xl { position: relative; }

.hero-split__wrap{
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--hs-gap);
  align-items: center;
}
@media (min-width: 960px){
  .hero-split__wrap{
    grid-template-columns: 1.2fr 1fr;
  }
}

/* الجهة النصية */
.hero-split__content{
  background: hsl(var(--surface));
  border: 1px solid hsl(var(--border));
  border-radius: var(--hs-br);
  padding: var(--hs-pad);
  box-shadow: var(--shadow-sm);
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.hero-split:hover .hero-split__content{
  border-color: color-mix(in hsl, var(--accent) 35%, hsl(var(--border)));
  box-shadow: var(--shadow-md);
}
.hero-split__title{
  font-weight: 900;
  letter-spacing: -.01em;
  line-height: 1.2;
  font-size: clamp(1.9rem, 1.1rem + 2.2vw, 2.6rem);
  margin-top: 8px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  transition: letter-spacing .2s ease, filter .2s ease;
}
.hero-split:hover .hero-split__title{
  letter-spacing: -.015em;
  filter: brightness(1.02);
}
.hero-split__subtitle{
  margin-top: 6px;
  font-size: 1.02rem;
}
.hero-split__list{
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
}
.hero-split__li{
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 8px;
  align-items: start;
  transition: transform .15s ease;
}
.hero-split__li:hover{ transform: translateY(-1px); }
.hero-split__tick{
  display: grid;
  place-items: center;
  width: 20px; height: 20px;
  border-radius: 999px;
  background: color-mix(in hsl, var(--accent) 16%, hsl(var(--muted-bg)));
  color: var(--accent);
  border: 1px solid color-mix(in hsl, var(--accent) 45%, hsl(var(--border)));
  font-weight: 900;
  line-height: 1;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .15s ease;
}
.hero-split__li:hover .hero-split__tick{
  transform: scale(1.06);
  background: color-mix(in hsl, var(--accent) 22%, hsl(var(--muted-bg)));
  border-color: color-mix(in hsl, var(--accent) 55%, hsl(var(--border)));
}
.hero-split__actions{
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}
.hero-split .btn{
  transition: transform .12s ease, box-shadow .2s ease, filter .2s ease;
}
.hero-split .btn:hover{
  transform: translateY(-1px) scale(1.015);
  box-shadow: var(--shadow-md);
}

/* الجهة البصرية */
.hero-split__visual{
  position: relative;
  min-height: 320px;
  border-radius: var(--hs-br);
  padding: var(--hs-pad);
  border: 1px solid hsl(var(--border));
  background: hsl(var(--surface));
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.hero-split:hover .hero-split__visual{
  border-color: color-mix(in hsl, var(--accent) 25%, hsl(var(--border)));
  box-shadow: var(--shadow-md);
}

/* شبكة نقطية بسيطة */
.hero-split__dots{
  position: absolute; inset: 0;
  background-image: radial-gradient(hsl(var(--brand-ink) / .08) 1px, transparent 1px);
  background-size: 18px 18px;
  opacity: .6;
  pointer-events: none;
}

/* هالة تتبع المؤشر (بدون أي blur) */
.hero-split__glow{
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(240px 180px at var(--mx) var(--my),
    color-mix(in hsl, var(--accent) 12%, transparent),
    transparent 60%);
  transition: opacity .2s ease;
  opacity: .9;
}

/* بطاقة العرض (tilt خفيف مستمد من متغيرات CSS) */
.hero-split__card{
  position: relative;
  z-index: 2;
  border-radius: 16px;
  border: 1px solid hsl(var(--border));
  padding: 10px;
  display: grid;
  gap: 8px;
  background: linear-gradient(180deg, hsl(var(--surface) / .92), hsl(var(--surface) / .76));
  transform: perspective(900px) rotateX(var(--tiltX, 0deg)) rotateY(var(--tiltY, 0deg));
  will-change: transform;
  transition: transform .18s ease, border-color .2s ease, box-shadow .2s ease;
  box-shadow: var(--shadow-sm);
}
.hero-split__card:hover{ box-shadow: var(--shadow-md); }
.hero-split__card-head, .hero-split__card-foot{
  display: flex; gap: 6px; flex-wrap: wrap; align-items: center;
}
.hero-split__card-body{
  border: 1px dashed hsl(var(--border));
  border-radius: 12px;
  min-height: 180px;
  background: hsl(var(--surface));
  display: grid; place-items: center;
  padding: 8px;
}
.hero-split__img{
  width: 100%; height: auto; -o-object-fit: cover; object-fit: cover; border-radius: 10px;
}
.hero-split__placeholder{
  width: 100%;
  display: grid; gap: 8px;
}
.hero-split__meter{
  height: 8px; border-radius: 999px; background: hsl(var(--muted-bg));
  border: 1px solid hsl(var(--border));
  overflow: hidden;
}
.hero-split__meter > span{
  display: block; height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
}

/* نبرات بحسب الـtone */
.hero-split--copper { --accent: hsl(var(--brand-copper)); --accent-2: hsl(var(--brand-olive)); }
.hero-split--stone  { --accent: hsl(var(--brand-stone));  --accent-2: hsl(var(--brand-olive)); }
.hero-split--olive  { --accent: hsl(var(--brand-olive));  --accent-2: hsl(var(--brand-copper)); }

/* ريبون ناعم */
.hero-split--copper .ribbon{ background: color-mix(in hsl, var(--accent) 12%, hsl(var(--surface))); color: var(--accent); border: 1px solid color-mix(in hsl, var(--accent) 35%, hsl(var(--border))); }
.hero-split--stone  .ribbon{ background: color-mix(in hsl, var(--accent) 12%, hsl(var(--surface))); color: var(--accent); border: 1px solid color-mix(in hsl, var(--accent) 35%, hsl(var(--border))); }
.hero-split--olive  .ribbon{ background: color-mix(in hsl, var(--accent) 12%, hsl(var(--surface))); color: var(--accent); border: 1px solid color-mix(in hsl, var(--accent) 35%, hsl(var(--border))); }

/* تقليل الحركة */
@media (prefers-reduced-motion: reduce){
  .hero-split__card{ transition: none !important; transform: none !important; }
  .hero-split__glow{ display: none !important; }
}

/* RTL/LTR: لا حاجة لتخصيص إضافي هنا */

/* HowItWorks — نظام Hover أنيق وخفيف (زيتي + نحاسي + أخضر) */

/* المتغيّرات التفاعلية الافتراضية */
.how-item{
  position: relative;
  overflow: hidden;

  /* مؤشر الماوس الافتراضي */
  --mx: 50%;
  --my: 50%;
  /* اللون المميِّز لكل بطاقة (HSL ثلاثي). لو ما كان هناك --brand-olive، نوفّر بديل */
  --accent: var(--brand-olive, 146 8% 38%);

  /* إطار علوي ملوّن + ظل هوفر */
  border-top: 3px solid hsl(var(--accent) / .85);
  transition:
    border-color .2s ease,
    box-shadow .2s ease,
    transform .18s ease;

  /* Tilt خفيف جداً */
  transform: perspective(900px) rotateX(var(--tiltX, 0deg)) rotateY(var(--tiltY, 0deg));
  will-change: transform;
}
.how-item:hover{
  border-color: hsl(var(--accent));
  box-shadow: var(--shadow-md);
}

/* الهالة التي تتبع المؤشر (بدون أي تغبيش) */
.how-glow{
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(160px 160px at var(--mx) var(--my),
      hsl(var(--accent) / .14),
      transparent 60%);
  opacity: .9;
  transition: opacity .2s ease;
}

/* رقم الخطوة */
.how-index{
  background: hsl(var(--accent) / .14);
  border: 1px solid hsl(var(--accent) / .40);
  color: hsl(var(--accent));
  transition: transform .15s ease, background-color .2s ease, border-color .2s ease, color .2s ease;
}
.how-item:hover .how-index{
  transform: translateY(-1px);
  background: hsl(var(--accent) / .18);
  border-color: hsl(var(--accent) / .50);
}

/* الأيقونة */
.how-icon{
  background: hsl(var(--accent) / .14);
  border: 1px solid hsl(var(--accent) / .35);
  color: hsl(var(--accent));
  transition: transform .15s ease, background-color .2s ease, border-color .2s ease, color .2s ease;
}
.how-item:hover .how-icon{
  transform: translateY(-1px) scale(1.04);
  background: hsl(var(--accent) / .18);
  border-color: hsl(var(--accent) / .45);
}

/* العنوان والوصف */
.how-title{ transition: color .2s ease, letter-spacing .2s ease; }
.how-desc { transition: color .2s ease; }

.how-item:hover .how-title{
  color: hsl(var(--fg));
  letter-spacing: -.005em;
}
.how-item:hover .how-desc{
  color: color-mix(in hsl, hsl(var(--muted-fg)) 80%, hsl(var(--accent)) 20%);
}

/* دعم التركيز بلوحة المفاتيح — نفس سلوك الـ hover عندما يوجد تركيز داخل العنصر */
.how-item:focus-within{
  border-color: hsl(var(--accent));
  box-shadow: var(--shadow-md);
}

/* تقليل الحركة */
@media (prefers-reduced-motion: reduce){
  .how-glow{ display: none !important; }
  .how-item{ transform: none !important; transition: none !important; }
}

/* Social Proof slider — RTL-safe on mobile */

.sp-embla { --sp-gap: 10px; }

/* لو مكوّن Embla يضيف هذه الكلاسات (قاسم مشترك)، نضمن الـ overflow والسلوك */
.sp-embla [class*="embla__viewport"] {
  overflow: hidden;
  width: 100%;
  /* مهم: إجبار الاتجاه على LTR لحساب الترانسليت بشكل صحيح */
  direction: ltr;
}

.sp-embla [class*="embla__container"] {
  display: flex;
  gap: var(--sp-gap);
  align-items: stretch;
}

/* عرض الشريحة على الموبايل */
.sp-slide {
  flex: 0 0 82%;
  min-width: 0; /* يمنع التوسّع اللي يطير المحتوى خارج الفيو */
}

/* نحسّن التدريج حسب العرض */
@media (min-width: 360px) {
  .sp-slide { flex-basis: 70%; }
}
@media (min-width: 480px) {
  .sp-slide { flex-basis: 58%; }
}

/* تأكد أن بطاقة الشريك تتمدّد بشكل صحيح */
.partner-card { inline-size: 100%; }
.logo-tile { inline-size: 100%; }
.logo-img { max-width: 100%; height: auto; }

