/* ============================================================
   مركز التدريب أونلاين — ثيم "البينتو الملوّن"
   خط العرض: Cairo · خط النص: Noto Kufi Arabic
   (مبني على نفس نظام التصميم المرسل)
   ============================================================ */

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

:root {
    --danger: #E24B4A; --danger-bg: #FDECEC; --danger-fg: #A82F2E;
    --success: #1D9E75; --success-bg: #E1F5EE;

    --ink: #241E35; --ink-soft: #4A4360; --muted: #6E6785; --faint: #9B94AF;
    --canvas: #FBFAF7; --paper: #FFFFFF; --line: #ECE8F2;

    --primary: #534AB7; --primary-deep: #3C3489; --primary-soft: #EEEDFE; --primary-mid: #7F77DD;

    --radius-lg: 22px; --radius-md: 16px; --radius-sm: 12px; --pill: 999px;
    --shadow-pop: 0 10px 30px -12px rgba(36, 30, 53, 0.18);
    --t: all .25s cubic-bezier(.34, 1.4, .64, 1);

    /* ألوان التصنيفات — تتدور حسب رقم التصنيف */
    --c0-bg: #EEEDFE; --c0-fg: #3C3489; --c0-mid: #7F77DD;
    --c1-bg: #FBEAF0; --c1-fg: #72243E; --c1-mid: #D4537E;
    --c2-bg: #E1F5EE; --c2-fg: #085041; --c2-mid: #1D9E75;
    --c3-bg: #FAEEDA; --c3-fg: #633806; --c3-mid: #EF9F27;
    --c4-bg: #FAECE7; --c4-fg: #712B13; --c4-mid: #D85A30;
    --c5-bg: #E6F1FB; --c5-fg: #0C447C; --c5-mid: #378ADD;
}

/* ---- الوضع الليلي ---- */
html[data-theme="dark"] {
    --danger: #F0736F; --danger-bg: #3A2226; --danger-fg: #FF9B97;
    --success: #26A882; --success-bg: #15302B;
    --ink: #EDEAF5; --ink-soft: #C3BDD4; --muted: #9A93AE; --faint: #7B7490;
    --canvas: #14121C; --paper: #1E1B29; --line: #2E2A3D;
    --primary: #8F86E8; --primary-deep: #A79FF0; --primary-soft: #2A2540; --primary-mid: #7F77DD;
    --shadow-pop: 0 12px 34px -14px rgba(0, 0, 0, .7);
    --c0-bg: #241F3D; --c0-fg: #C6C1F0; --c0-mid: #8B83E0;
    --c1-bg: #33202A; --c1-fg: #EDAEC3; --c1-mid: #D4537E;
    --c2-bg: #15302B; --c2-fg: #8FD9C0; --c2-mid: #26A882;
    --c3-bg: #302614; --c3-fg: #E8BC77; --c3-mid: #D99B36;
    --c4-bg: #33211A; --c4-fg: #EDB5A1; --c4-mid: #D86A45;
    --c5-bg: #1B2C3F; --c5-fg: #A5C8E8; --c5-mid: #4A92D8;
}
html[data-theme="dark"] body { color-scheme: dark; }
html[data-theme="dark"] .navbar { background: rgba(20, 18, 28, .9); }
html[data-theme="dark"] .site-topbar {
    background: linear-gradient(90deg,#221D3A,#2C2650 55%,#241F42);
}

html { scroll-behavior: smooth; }
body {
    font-family: 'Noto Kufi Arabic', 'Tajawal', 'Segoe UI', Tahoma, sans-serif;
    background: var(--canvas); color: var(--ink);
    line-height: 1.8; min-height: 100vh; -webkit-font-smoothing: antialiased;
    position: relative;
}
/* ===== خلفية زخرفية متحركة (فقاعات لونية تتبع الثيم) ===== */
body::before, body::after {
    content: ''; position: fixed; z-index: -2; pointer-events: none;
    border-radius: 50%; filter: blur(55px); will-change: transform;
}
body::before {
    width: 44vw; height: 44vw; max-width: 560px; max-height: 560px;
    top: -6vw; right: -4vw;
    background: radial-gradient(circle at 35% 35%, var(--primary-mid), transparent 66%);
    opacity: .5; animation: bgFloatA 16s ease-in-out infinite;
}
body::after {
    width: 40vw; height: 40vw; max-width: 520px; max-height: 520px;
    bottom: -8vw; left: -4vw;
    background: radial-gradient(circle at 60% 60%, var(--primary), transparent 66%);
    opacity: .42; animation: bgFloatB 20s ease-in-out infinite;
}
@keyframes bgFloatA {
    0%   { transform: translate(0,0) scale(1); }
    33%  { transform: translate(-160px, 120px) scale(1.25); }
    66%  { transform: translate(-70px, 60px) scale(1.1); }
    100% { transform: translate(0,0) scale(1); }
}
@keyframes bgFloatB {
    0%   { transform: translate(0,0) scale(1); }
    33%  { transform: translate(150px, -110px) scale(1.2); }
    66%  { transform: translate(70px, -50px) scale(1.08); }
    100% { transform: translate(0,0) scale(1); }
}
html[data-theme="dark"] body::before { opacity: .30; }
html[data-theme="dark"] body::after  { opacity: .26; }

@media (prefers-reduced-motion: reduce) {
    body::before, body::after { animation: none; }
}
h1, h2, h3, .logo, .page-title, .section-title,
.course-card-title, .hero-title { font-family: 'Cairo', 'Noto Kufi Arabic', sans-serif; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
a { color: var(--primary); text-decoration: none; }
::selection { background: var(--c3-bg); color: var(--c3-fg); }
img { max-width: 100%; display: block; }

/* ============================================================
   الشريط العلوي
   ============================================================ */
.site-announce { font-size: 13px; line-height: 1.5; }
.site-announce .ann-inner { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 38px; padding: 7px 0; text-align: center; }
.site-announce .ann-ico { flex-shrink: 0; display: inline-flex; animation: annBell 2.4s ease-in-out infinite; }
.site-announce .ann-ico svg { width: 17px; height: 17px; }
.site-announce .ann-text { flex: 0 1 auto; min-width: 0; font-weight: 400; font-family: 'Cairo', sans-serif; }
.site-announce .ann-link { flex-shrink: 0; color: inherit; font-weight: 800; font-size: 12px; text-decoration: none;
    background: rgba(255,255,255,.18); padding: 3px 12px; border-radius: 999px; white-space: nowrap; transition: background .2s; }
.site-announce .ann-link:hover { background: rgba(255,255,255,.32); }
@keyframes annBell { 0%,70%,100%{transform:rotate(0)} 80%{transform:rotate(-14deg)} 90%{transform:rotate(12deg)} }
@media (max-width: 640px) {
    .site-announce { font-size: 12px; }
    .site-announce .ann-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}

.site-topbar {
    background: linear-gradient(90deg, var(--primary-deep), var(--primary));
    color: rgba(255,255,255,.92); font-size: 12px;
    border-bottom: 1px solid rgba(255,255,255,.08); line-height: 1;
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between;
    gap: 10px; min-height: 32px; padding: 5px 0; }
.topbar-start, .topbar-end { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tb-date, .tb-city, .tb-time { display: inline-flex; align-items: center; gap: 5px;
    font-family: 'Cairo', sans-serif; font-weight: 600; color: rgba(255,255,255,.92); }
.tb-city { font-weight: 700; }
.tb-date svg, .tb-city svg, .tb-time svg { width: 12px; height: 12px; }
.tb-sep { color: rgba(255,255,255,.35); font-weight: 700; font-size: 10px; user-select: none; }
.topbar-end { gap: 4px; }
.tb-social { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px;
    border-radius: 50%; background: rgba(255,255,255,.14); color: #fff; transition: var(--t); }
.tb-social svg { width: 14px; height: 14px; }
.tb-social:hover { background: rgba(255,255,255,.28); transform: translateY(-2px); }
.tb-auth { display: inline-flex; gap: 8px; align-items: center; }
.tb-auth a { color: #fff; font-weight: 600; font-size: 12px; }
.tb-auth a:hover { text-decoration: underline; }

/* ============================================================
   النافبار
   ============================================================ */
.navbar {
    background: rgba(251, 250, 247, .88); backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line);
    padding: 6px 0; position: sticky; top: 0; z-index: 100;
}
.navbar .container { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.navbar nav { flex: 1; justify-content: center; }
.logo { display: flex; align-items: center; gap: 14px; color: var(--ink); position: relative; min-width: 0; flex-shrink: 0; }
.logo img { height: 60px; width: auto; flex-shrink: 0; object-fit: contain; }
.logo-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.logo-name { position: relative; align-self: flex-start; font-size: 18px; font-weight: 800;
    letter-spacing: -.3px; line-height: 1.2; padding-bottom: 3px; }
.logo-name::after { content: ''; position: absolute; right: 0; bottom: 0; width: 100%; height: 7px;
    background: var(--c3-mid); border-radius: var(--pill); opacity: .45; z-index: -1;
    transform: skewX(-12deg); transition: var(--t); }
.logo:hover .logo-name::after { height: 55%; opacity: .35; }
.logo-tagline { font-size: 11px; font-weight: 500; color: var(--muted); line-height: 1.4;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px; }

.navbar nav { display: flex; gap: 1px; flex-wrap: wrap; align-items: center; }
.nav-link, .navbar nav a, .nav-btn {
    display: inline-flex; align-items: center; gap: 5px; color: var(--ink-soft);
    background: transparent; border: none; padding: 7px 10px; border-radius: var(--pill);
    font-family: inherit; font-weight: 500; font-size: 13px; cursor: pointer; transition: var(--t); }
.nav-icon { width: 15px; height: 15px; flex-shrink: 0; }
.nav-link:hover, .navbar nav a:hover, .nav-btn:hover {
    background: var(--primary-soft); color: var(--primary-deep); transform: translateY(-2px); }
.nav-link.is-active { background: var(--primary-soft); color: var(--primary-deep); }
.nav-admin-link { background: var(--c2-bg); color: var(--c2-fg); }
.nav-admin-link:hover { background: var(--c2-mid); color: #fff; }
.nav-cta { background: var(--primary); color: #fff; font-weight: 700; }
.nav-cta:hover { background: var(--primary-deep); color: #fff; }

/* زر السلة في الهيدر — نخصّص المحدّد ليتغلّب على .navbar nav a */
.navbar nav a.cart-btn { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; padding: 0; border-radius: 50%; border: 1.5px solid var(--line);
    background: var(--canvas); color: var(--ink-soft); position: relative; transition: var(--t); text-decoration: none; }
.navbar nav a.cart-btn:hover { color: var(--primary-deep); border-color: var(--primary-mid);
    background: var(--primary-soft); transform: none; }
.navbar nav a.cart-btn svg { width: 18px; height: 18px; }
.cart-label { display: none; }
.cart-badge { position: absolute; top: -5px; inset-inline-start: -5px; min-width: 18px; height: 18px; padding: 0 4px;
    background: var(--primary); color: #fff; border-radius: 999px; font-size: 11px; font-weight: 800;
    display: inline-flex; align-items: center; justify-content: center; line-height: 1; box-shadow: 0 0 0 2px var(--paper); }

.theme-toggle { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; border-radius: 50%; border: 1.5px solid var(--line);
    background: var(--canvas); color: var(--ink-soft); cursor: pointer; transition: var(--t); position: relative; }
.theme-icon { width: 18px; height: 18px; position: absolute;
    transition: opacity .25s, transform .35s cubic-bezier(.34, 1.4, .64, 1); }
.theme-icon-sun { opacity: 0; transform: rotate(-90deg) scale(.5); }
.theme-icon-moon { opacity: 1; }
html[data-theme="dark"] .theme-icon-moon { opacity: 0; transform: rotate(90deg) scale(.5); }
html[data-theme="dark"] .theme-icon-sun { opacity: 1; transform: rotate(0) scale(1); }
.theme-toggle:hover { background: var(--primary-soft); border-color: var(--primary-mid);
    color: var(--primary-deep); transform: translateY(-2px) rotate(-8deg); }

/* زر الهمبرغر والقائمة الجانبية (مخفية على الكمبيوتر) */
.nav-burger { display: none; background: transparent; border: none; cursor: pointer; color: var(--ink); padding: 6px; }
.nav-burger svg { width: 26px; height: 26px; }
.nav-overlay { display: none; }

@media (max-width: 900px) {
    .nav-burger { display: inline-flex; align-items: center; }
    .navbar .container { justify-content: space-between; }
    /* القائمة تصير درج جانبي (من اليمين — مناسب للعربي) */
    .navbar nav {
        position: fixed; top: 0; right: -300px; left: auto; width: 280px; max-width: 82vw; height: 100vh;
        background: var(--paper); flex-direction: column; align-items: stretch; justify-content: flex-start;
        gap: 4px; padding: 70px 16px 24px; box-shadow: -8px 0 30px rgba(0,0,0,.15); z-index: 200;
        transition: right .3s ease; overflow-y: auto; flex: none;
    }
    .navbar nav.is-open { right: 0; }
    .navbar nav .nav-link, .navbar nav a, .navbar nav .nav-cta {
        width: 100%; justify-content: flex-start; padding: 12px 14px; border-radius: 10px; font-size: 15px;
    }
    .navbar nav .nav-link span, .navbar nav a span { display: inline !important; }
    .navbar nav .nav-cta { background: var(--primary); color: #fff; margin-top: 8px; justify-content: center; transform: none !important; }
    .navbar nav .nav-cta:hover, .navbar nav .nav-link:hover { transform: none !important; }
    /* زر الوضع الليلي داخل القائمة الجانبية */
    .navbar nav .theme-toggle-edge {
        width: 100% !important; height: auto !important; justify-content: flex-start; gap: 12px;
        padding: 12px 14px !important; border-radius: 10px !important; border: 1px solid var(--line) !important;
        margin: 4px 0 0; background: var(--canvas); transform: none !important; flex-direction: row;
    }
    .navbar nav .theme-toggle-edge:hover, .navbar nav .theme-toggle-edge:active { transform: none !important; }
    /* حاوية الأيقونة بحجم ثابت حتى لا تتداخل مع النص */
    .navbar nav .theme-toggle-edge .theme-icon { position: static; width: 20px; height: 20px; transform: none !important; }
    .navbar nav .theme-toggle-edge .theme-icon-sun { display: none; }
    html[data-theme="dark"] .navbar nav .theme-toggle-edge .theme-icon-moon { display: none; }
    html[data-theme="dark"] .navbar nav .theme-toggle-edge .theme-icon-sun { display: inline; opacity: 1; }
    .navbar nav .theme-label { display: inline; font-size: 15px; font-weight: 500; color: var(--ink); }
    /* زر السلة داخل القائمة الجانبية — نفس شكل زر الوضع الليلي */
    .navbar nav a.cart-btn {
        width: 100% !important; height: auto !important; justify-content: flex-start; gap: 12px;
        padding: 12px 14px !important; border-radius: 10px !important; border: 1px solid var(--line) !important;
        margin: 4px 0 0; background: var(--canvas); transform: none !important; }
    .navbar nav a.cart-btn svg { width: 20px; height: 20px; }
    .navbar nav a.cart-btn .cart-label { display: inline; font-size: 15px; font-weight: 500; color: var(--ink); }
    .navbar nav a.cart-btn .cart-badge { display: none; }
    .nav-overlay { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 199; opacity: 0; pointer-events: none; transition: opacity .3s; }
    .nav-overlay.is-open { opacity: 1; pointer-events: auto; }
}
@media (max-width: 640px) {
    .logo-tagline { display: none; }
    .logo img { height: 46px; }
    .logo-name { font-size: 16px; }
}

/* ============================================================
   الأزرار
   ============================================================ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 22px; border-radius: var(--pill); font-family: inherit; font-weight: 700;
    font-size: 15px; border: none; cursor: pointer; transition: var(--t); }
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-deep); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-pop); }
.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { transform: translateY(-2px); }
.btn-outline { background: var(--paper); color: var(--primary-deep); border: 1.5px solid var(--line); }
.btn-outline:hover { border-color: var(--primary-mid); background: var(--primary-soft); }
.btn-block { width: 100%; }
.btn-lg { padding: 14px 30px; font-size: 16px; }

/* ============================================================
   العناوين والأقسام
   ============================================================ */
main { min-height: 70vh; padding: 34px 0 60px; }
.page-title { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 26px;
    font-size: 30px; font-weight: 800; color: var(--ink); position: relative; padding-bottom: 4px; }
.section-title { display: flex; align-items: center; gap: 12px; font-size: 24px; font-weight: 800;
    margin: 40px 0 22px; color: var(--ink); }
.section-title-mark { width: 6px; height: 26px; border-radius: var(--pill);
    background: linear-gradient(180deg, var(--primary-deep), var(--primary-mid)); }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.section-sub { font-size: 14px; font-weight: 400; color: var(--muted); margin: 6px 0 0; padding-right: 18px; line-height: 1.6; }
.section-more { font-weight: 700; font-size: 14px; color: var(--primary); }

/* ============================================================
   الهيرو (رأس الصفحة الرئيسية)
   ============================================================ */
.hero { background: linear-gradient(135deg, var(--primary-deep), var(--primary));
    color: #fff; border-radius: var(--radius-lg); padding: 54px 40px; margin: 8px 0 12px;
    position: relative; overflow: hidden; }
.hero::after { content: ''; position: absolute; inset: 0; pointer-events: none;
    background-image: radial-gradient(circle at 85% 20%, rgba(255,255,255,.12), transparent 40%),
    radial-gradient(circle at 10% 90%, rgba(255,255,255,.08), transparent 35%); }
/* الطبقات الزخرفية لقسم الهيرو والشرائح لا تلتقط الضغط أبداً (تضمن قابلية ضغط الأزرار) */
.hero::before, .hero::after,
.hero-v2::before, .hero-v2::after,
.hero-v2.has-bg-img::before, .hero-v2.has-bg-img::after,
.hero-slide::before, .hero-slide::after,
.hero-slide.has-bg-img::before, .hero-slide.has-bg-img::after { pointer-events: none !important; }
.hero-inner { position: relative; z-index: 2; max-width: 640px; }
.hero-title { font-size: clamp(28px, 5vw, 44px); font-weight: 900; line-height: 1.3; margin-bottom: 14px; }

/* ===== مسار المتدرب حتى الشهادة ===== */
.journey { position: relative; }
.journey-head { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; }
.journey-title { font-family: 'Cairo','Noto Kufi Arabic',sans-serif; font-size: 24px; font-weight: 900; margin: 0; color: var(--ink); }
.journey-sub { margin: 3px 0 0; color: var(--muted); font-size: 14px; }
.journey-track { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; position: relative; }
/* الخط الواصل بين الخطوات */
.journey-track::before { content: ''; position: absolute; top: 40px; right: 8%; left: 8%; height: 2px;
  background: repeating-linear-gradient(90deg, var(--primary-mid) 0 10px, transparent 10px 20px); opacity: .5; z-index: 0; }
.journey-step { position: relative; z-index: 1; text-align: center; padding: 8px 10px;
  opacity: 0; transform: translateY(16px); animation: journeyIn .5s ease forwards; animation-delay: var(--d,0s); }
.journey-icon { width: 80px; height: 80px; margin: 0 auto 14px; border-radius: 22px; position: relative;
  display: flex; align-items: center; justify-content: center; color: #fff;
  background: linear-gradient(145deg, var(--primary), var(--primary-deep));
  box-shadow: 0 10px 26px -8px rgba(83,74,183,.55); transition: transform .3s ease, box-shadow .3s ease; }
.journey-icon svg { width: 34px; height: 34px; }
.journey-step:hover .journey-icon { transform: translateY(-6px) scale(1.05); box-shadow: 0 16px 34px -8px rgba(83,74,183,.7); }
.journey-num { position: absolute; top: -8px; left: -8px; width: 28px; height: 28px; border-radius: 50%;
  background: var(--paper); color: var(--primary-deep); border: 2px solid var(--primary-soft);
  font-family: 'Cairo'; font-weight: 900; font-size: 14px; display: flex; align-items: center; justify-content: center; }
.journey-step h3 { font-size: 16px; font-weight: 800; margin: 0 0 6px; color: var(--ink); }
.journey-step p { font-size: 13px; color: var(--muted); line-height: 1.7; margin: 0; }
@keyframes journeyIn { to { opacity: 1; transform: translateY(0); } }
@media (max-width: 900px) {
  .journey-track { grid-template-columns: repeat(2, 1fr); gap: 20px 14px; }
  .journey-track::before { display: none; }
}
@media (max-width: 520px) {
  .journey-track { grid-template-columns: 1fr; }
  .journey-step { display: flex; align-items: center; gap: 14px; text-align: right; padding: 6px 0; }
  .journey-icon { margin: 0; width: 64px; height: 64px; flex-shrink: 0; }
  .journey-icon svg { width: 28px; height: 28px; }
}
.hero-sub { font-size: 17px; opacity: .92; margin-bottom: 26px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero .btn-outline { background: rgba(255,255,255,.14); color: #fff; border-color: rgba(255,255,255,.3); }
.hero .btn-outline:hover { background: rgba(255,255,255,.24); }
/* الصف السفلي للهيرو: الشارات يمين + الأرقام يسار */
.hero-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 26px;
    margin-top: 34px; flex-wrap: wrap; position: relative; z-index: 2; }
.hero-accreds { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.hero-accred { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 700;
    color: #fff; background: rgba(0,0,0,.34); backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,.18); border-radius: 999px; padding: 7px 15px; line-height: 1.3; }
.hero-accred svg { width: 17px; height: 17px; flex-shrink: 0; color: #6fe3a8; }
.hero-stats { display: flex; gap: 28px; flex-wrap: wrap; position: relative; z-index: 2; }
.hero-stat { text-align: center; }
.hero-stat b { display: block; font-family: 'Cairo'; font-size: 26px; font-weight: 900; }
.hero-stat span { font-size: 13px; opacity: .85; }
@media (max-width: 760px) {
    .hero-foot { flex-direction: column; align-items: stretch; gap: 18px; }
    .hero-accreds { align-items: stretch; }
    .hero-accred { justify-content: flex-start; }
    .hero-stats { justify-content: space-between; gap: 14px; }
}

/* ============================================================
   شبكة بطاقات الدورات
   ============================================================ */
.course-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 1024px){ .course-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px){ .course-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px){ .course-grid { grid-template-columns: 1fr; } }
.course-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
    overflow: hidden; transition: var(--t); display: flex; flex-direction: column; position: relative; }
.course-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-pop); border-color: var(--primary-mid); }
.course-card-media { position: relative; aspect-ratio: 16/9; background: var(--primary-soft); overflow: hidden; }
.course-card-media img { width: 100%; height: 100%; object-fit: cover; }
.course-card-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
    color: var(--primary-mid); }
.course-card-placeholder svg { width: 54px; height: 54px; opacity: .5; }
.course-card-cat { position: absolute; top: 10px; right: 10px; font-size: 10.5px; font-weight: 700;
    padding: 3px 9px; border-radius: var(--pill); background: var(--paper); color: var(--ink); }
.course-badge { position: absolute; top: 10px; left: 10px; font-size: 10.5px; font-weight: 800;
    padding: 3px 10px; border-radius: var(--pill); }
.badge-free { background: var(--success); color: #fff; }
.badge-paid { background: var(--c3-mid); color: #1c1305; }
.course-card-body { padding: 15px; display: flex; flex-direction: column; flex: 1; gap: 8px; }
.course-card-title { font-size: 15.5px; font-weight: 800; line-height: 1.4; color: var(--ink);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.course-card-summary { font-size: 12.5px; color: var(--muted); line-height: 1.7; display: -webkit-box; -webkit-line-clamp: 2;
    -webkit-box-orient: vertical; overflow: hidden; }
.course-card-meta { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--faint);
    margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.course-card-meta span { display: inline-flex; align-items: center; gap: 5px; }
.course-card-meta svg { width: 15px; height: 15px; }
.course-card-meta svg { width: 15px; height: 15px; }
.course-card-foot { display: flex; align-items: center; justify-content: space-between; padding: 0 18px 18px; }
.course-price { font-family: 'Cairo'; font-weight: 900; font-size: 20px; color: var(--primary-deep); }
.course-price.is-free { color: var(--success); }

/* بطاقة تلوين حسب التصنيف */
.cc-0 .course-card-cat { background: var(--c0-bg); color: var(--c0-fg); }
.cc-1 .course-card-cat { background: var(--c1-bg); color: var(--c1-fg); }
.cc-2 .course-card-cat { background: var(--c2-bg); color: var(--c2-fg); }
.cc-3 .course-card-cat { background: var(--c3-bg); color: var(--c3-fg); }
.cc-4 .course-card-cat { background: var(--c4-bg); color: var(--c4-fg); }
.cc-5 .course-card-cat { background: var(--c5-bg); color: var(--c5-fg); }

/* ============================================================
   صفحة تفاصيل الدورة
   ============================================================ */
.course-hero { display: grid; grid-template-columns: 1fr 1.25fr; gap: 30px; align-items: center; margin-bottom: 30px; }
@media (max-width: 820px){ .course-hero { grid-template-columns: 1fr; } }

/* تخطيط صفحة الدورة: عمود عريض (بانر+محتوى) + عمود أضيق (مدرب+تسجيل+دورات) */
.course-detail-grid { display: grid; grid-template-columns: minmax(0,1.7fr) 340px; gap: 30px; align-items: start; margin: 8px 0 34px; }
.course-main { min-width: 0; }

/* بانر الصورة العريض */
.course-main .course-hero-media { aspect-ratio: auto; border-radius: var(--radius-lg); overflow: hidden; margin-bottom: 22px; box-shadow: var(--shadow-pop); background: var(--primary-soft); }
.course-main .course-hero-media img { width: 100%; height: auto; max-height: 72vh; object-fit: contain; display: block; margin: 0 auto; }

/* شريط العنوان تحت الصورة */
.course-titlebar { margin-bottom: 28px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.course-titlebar .course-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.course-title { font-size: clamp(26px,3.4vw,38px); font-weight: 900; line-height: 1.3; margin-bottom: 10px; color: var(--ink); }
.course-lede { color: var(--muted); font-size: 16px; }

/* العمود الجانبي */
.course-side { display: flex; flex-direction: column; gap: 20px; }
.course-side .buy-box { position: static; }

/* بطاقة المدرب */
.trainer-card { display: flex; align-items: center; gap: 14px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 16px 18px; }
.trainer-avatar { width: 52px; height: 52px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); display: flex; align-items: center; justify-content: center; overflow: hidden; flex-shrink: 0; }
.trainer-avatar img { width: 100%; height: 100%; object-fit: cover; }
.trainer-avatar svg { width: 28px; height: 28px; }
.trainer-label { font-size: 12px; color: var(--muted); }
.trainer-name { font-size: 17px; font-weight: 800; color: var(--ink); }

/* عدّاد أسفل صندوق التسجيل */
.buy-counter { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; }
.buy-counter b { display: block; font-family: 'Cairo'; font-size: 20px; font-weight: 900; color: var(--primary-deep); }
.buy-counter span { font-size: 12px; color: var(--muted); }

/* بلوك الدورات الأخرى */
.other-courses { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px; }
.other-title { font-size: 17px; font-weight: 800; margin-bottom: 14px; color: var(--ink); }
.other-item { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); transition: var(--t); }
.other-item:last-child { border-bottom: none; }
.other-item:hover { transform: translateX(-4px); }
.other-thumb { width: 60px; height: 46px; border-radius: 10px; overflow: hidden; flex-shrink: 0; background: var(--primary-soft); display: flex; align-items: center; justify-content: center; color: var(--primary-mid); }
.other-thumb img { width: 100%; height: 100%; object-fit: cover; }
.other-thumb svg { width: 26px; height: 26px; }
.other-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.other-name { font-size: 14px; font-weight: 700; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.4; }
.other-price { font-size: 13px; font-weight: 800; color: var(--primary-deep); }
.other-price.is-free { color: var(--success); }

@media (max-width: 900px){
  .course-detail-grid { grid-template-columns: 1fr; }
  .course-main .course-hero-media { aspect-ratio: auto; }
}
.course-hero-media { border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 16/9; background: var(--primary-soft); }
.course-hero-media img { width: 100%; height: 100%; object-fit: cover; }
.course-hero-body h1 { font-size: clamp(24px,4vw,34px); font-weight: 900; line-height: 1.3; margin-bottom: 12px; }
.course-hero-body .lede { color: var(--muted); font-size: 16px; margin-bottom: 18px; }
.course-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.chip { font-size: 13px; font-weight: 700; padding: 6px 14px; border-radius: var(--pill);
    background: var(--primary-soft); color: var(--primary-deep); display: inline-flex; align-items: center; gap: 6px; }
.chip svg { width: 15px; height: 15px; }

.buy-box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: 24px; box-shadow: var(--shadow-pop); }
.buy-price { font-family: 'Cairo'; font-size: 34px; font-weight: 900; color: var(--primary-deep); margin-bottom: 4px; }
.buy-price.is-free { color: var(--success); }
.buy-note { font-size: 13px; color: var(--muted); margin-bottom: 18px; }
.buy-features { list-style: none; margin: 18px 0; display: grid; gap: 10px; }
.buy-features li { display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--ink-soft); }
.buy-features svg { width: 18px; height: 18px; color: var(--success); flex-shrink: 0; }

/* منهج الدورة */
.curriculum { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.lesson-row { display: flex; align-items: center; gap: 12px; padding: 15px 20px; border-bottom: 1px solid var(--line); }
.lesson-row:last-child { border-bottom: none; }
.lesson-ico { width: 34px; height: 34px; border-radius: 50%; background: var(--primary-soft); color: var(--primary-deep);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.lesson-ico svg { width: 17px; height: 17px; }
.lesson-title { flex: 1; font-weight: 600; color: var(--ink); }
.lesson-dur { font-size: 13px; color: var(--faint); }
.lesson-preview { font-size: 11px; font-weight: 700; color: #1c8a55; background: rgba(43,182,115,.12);
    padding: 2px 8px; border-radius: 99px; margin-right: 4px; }
.lesson-lock { color: var(--faint); }
.lesson-lock svg { width: 16px; height: 16px; }

/* طبقة القفل للمحتوى المدفوع */
.locked-content { position: relative; border-radius: var(--radius-lg); overflow: hidden;
    background: var(--primary-soft); padding: 60px 24px; text-align: center; border: 1px dashed var(--primary-mid); }
.locked-content .lock-ic { width: 60px; height: 60px; margin: 0 auto 16px; color: var(--primary); }
.locked-content h3 { font-size: 20px; font-weight: 800; margin-bottom: 8px; color: var(--ink); }
.locked-content p { color: var(--muted); margin-bottom: 20px; }

/* ============================================================
   نماذج الدفع
   ============================================================ */
.pay-methods { display: grid; gap: 12px; margin: 18px 0; }
.pay-method { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1.5px solid var(--line);
    border-radius: var(--radius-md); cursor: pointer; transition: var(--t); background: var(--paper); }
.pay-method:hover { border-color: var(--primary-mid); }
.pay-method input { accent-color: var(--primary); width: 18px; height: 18px; }
.pay-method.selected { border-color: var(--primary); background: var(--primary-soft); }
.pay-method .pm-label { font-weight: 700; }
.pay-method .pm-desc { font-size: 13px; color: var(--muted); }

/* ============================================================
   النماذج العامة
   ============================================================ */
.form-card { max-width: 460px; margin: 20px auto; background: var(--paper); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 34px; box-shadow: var(--shadow-pop); }
.form-card h1 { font-size: 26px; font-weight: 800; margin-bottom: 6px; text-align: center; }
.form-card .sub { text-align: center; color: var(--muted); margin-bottom: 24px; font-size: 14px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 7px; color: var(--ink-soft); }
.field input, .field select, .field textarea {
    width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
    font-family: inherit; font-size: 15px; background: var(--canvas); color: var(--ink); transition: var(--t); }
.field input:focus, .field select:focus, .field textarea:focus {
    outline: none; border-color: var(--primary-mid); background: var(--paper); }
.form-foot { text-align: center; margin-top: 16px; font-size: 14px; color: var(--muted); }

/* التنبيهات */
.alert { padding: 13px 18px; border-radius: var(--radius-md); margin-bottom: 18px; font-weight: 600; font-size: 14px; }
.alert-success { background: var(--success-bg); color: var(--success); }
.alert-error { background: var(--danger-bg); color: var(--danger-fg); }
.alert-info { background: var(--primary-soft); color: var(--primary-deep); }

/* الجداول */
.table-wrap { overflow-x: auto; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); }
table.data { width: 100%; border-collapse: collapse; }
table.data th, table.data td { padding: 13px 16px; text-align: right; border-bottom: 1px solid var(--line); font-size: 14px; }
table.data th { background: var(--canvas); font-weight: 700; color: var(--ink-soft); }
table.data tr:last-child td { border-bottom: none; }
.status-pill { font-size: 12px; font-weight: 700; padding: 3px 12px; border-radius: var(--pill); }
.status-pending { background: var(--c3-bg); color: var(--c3-fg); }
.status-approved,.status-paid { background: var(--success-bg); color: var(--success); }
.status-rejected,.status-failed { background: var(--danger-bg); color: var(--danger-fg); }

/* حالة فارغة */
.empty { text-align: center; padding: 60px 20px; color: var(--muted); }
.empty svg { width: 64px; height: 64px; opacity: .4; margin: 0 auto 16px; }

/* ============================================================
   التذييل
   ============================================================ */
.site-footer { background: var(--primary-deep); color: rgba(255,255,255,.8); margin-top: 60px;
    padding: 46px 0 24px; }
html[data-theme="dark"] .site-footer { background: #100E18; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.2fr; gap: 30px; margin-bottom: 34px; }
@media (max-width: 900px){ .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px){ .footer-grid { grid-template-columns: 1fr; } }
.footer-brand h3 { color: #fff; font-size: 22px; font-weight: 800; margin-bottom: 10px; }
.footer-brand p { font-size: 14px; line-height: 1.9; max-width: 340px; }
.footer-col h4 { color: #fff; font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.footer-col a { display: block; color: rgba(255,255,255,.72); font-size: 14px; padding: 5px 0; transition: var(--t); }
.footer-col a:hover { color: #fff; padding-right: 5px; }
.footer-compliance { display: flex; gap: 10px; flex-wrap: wrap; margin: 20px 0; }
.compliance-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14); border-radius: var(--pill); padding: 6px 12px; font-size: 11px; color: #fff; }
.compliance-badge svg { width: 14px; height: 14px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding-top: 20px;
    font-size: 13px; color: rgba(255,255,255,.6);
    display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
@media (max-width: 560px){ .footer-bottom { justify-content: center; text-align: center; } }
.dev-badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: var(--pill);
    background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15); color: rgba(255,255,255,.75);
    font-size: 12.5px; transition: var(--t); }
.dev-badge:hover { background: rgba(255,255,255,.16); color: #fff; }
.dev-badge b { color: var(--c3-mid, #EF9F27); font-weight: 800; }
.dev-badge svg { opacity: .7; }

/* شبكة لوحة التحكم */
.admin-shell { display: grid; grid-template-columns: 240px 1fr; gap: 24px; align-items: start; }
@media (max-width: 820px){ .admin-shell { grid-template-columns: 1fr; } }
.admin-side { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: 10px; position: sticky; top: 90px; display: flex; flex-direction: column; gap: 2px; }

/* عنصر تنقّل (رابط أو رأس مجموعة) */
.admin-side .nav-item { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: var(--radius-sm);
    color: var(--ink-soft); font-weight: 600; font-size: 14px; transition: var(--t);
    width: 100%; background: none; border: none; cursor: pointer; text-align: right; font-family: inherit; }
.admin-side .nav-item svg { width: 18px; height: 18px; flex-shrink: 0; }
.admin-side .nav-item span { flex: 1; }
.admin-side .nav-item:hover { background: var(--primary-soft); color: var(--primary-deep); }
.admin-side a.nav-item.is-active { background: var(--primary); color: #fff; }

/* رأس المجموعة */
.admin-side .nav-head.is-parent-active { color: var(--primary-deep); }
.admin-side .nav-chev { width: 16px !important; height: 16px !important; transition: transform .25s ease; opacity: .6; }
.admin-side .nav-group.open .nav-chev { transform: rotate(180deg); }

/* القائمة الفرعية القابلة للطي */
.admin-side .nav-sub { max-height: 0; overflow: hidden; transition: max-height .28s ease;
    margin: 0 8px; padding-right: 14px; border-right: 2px solid transparent; }
.admin-side .nav-group.open .nav-sub { max-height: 800px; border-right-color: var(--line); }
.admin-side .nav-sub a { display: block; padding: 8px 12px; border-radius: var(--radius-sm);
    font-size: 12.5px; font-weight: 600; color: var(--muted); transition: var(--t); }
.admin-side .nav-sub a:first-child { margin-top: 2px; }
.admin-side .nav-sub a:hover { background: var(--primary-soft); color: var(--primary-deep); }
.admin-side .nav-sub a.is-active { background: var(--primary-soft); color: var(--primary-deep); }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px,1fr)); gap: 16px; margin-bottom: 26px; }
.stat-box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; }
.stat-box b { display: block; font-family: 'Cairo'; font-size: 30px; font-weight: 900; color: var(--primary-deep); }
.stat-box span { color: var(--muted); font-size: 14px; }

/* بطاقات بوابات الدفع في الأدمن */
.gateway-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px,1fr)); gap: 20px; }
.gateway-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px; }
.gateway-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.gateway-name { font-weight: 800; font-size: 17px; }
.gateway-body { display: grid; gap: 12px; }
/* مفتاح التبديل */
.switch { position: relative; display: inline-block; width: 48px; height: 27px; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider { position: absolute; inset: 0; background: var(--line); border-radius: var(--pill); transition: var(--t); }
.switch .slider::before { content: ''; position: absolute; width: 21px; height: 21px; right: 3px; top: 3px;
    background: #fff; border-radius: 50%; transition: var(--t); }
.switch input:checked + .slider { background: var(--success); }
.switch input:checked + .slider::before { transform: translateX(-21px); }

/* ============================================================
   صفحة ملف المدرب العامة
   ============================================================ */
.trainer-profile { display: flex; gap: 26px; align-items: center; background: linear-gradient(135deg, var(--primary-deep), var(--primary));
    color: #fff; border-radius: var(--radius-lg); padding: 34px; margin-bottom: 20px; position: relative; overflow: hidden; }
.trainer-profile::after { content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 85% 15%, rgba(255,255,255,.12), transparent 40%); }
.trainer-profile-avatar { width: 120px; height: 120px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
    background: rgba(255,255,255,.15); display: flex; align-items: center; justify-content: center; border: 3px solid rgba(255,255,255,.3); position: relative; z-index: 2; }
.trainer-profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.trainer-profile-avatar svg { width: 64px; height: 64px; color: #fff; }
.trainer-profile-info { position: relative; z-index: 2; }
.trainer-profile-role { display: inline-block; background: rgba(255,255,255,.18); padding: 4px 14px; border-radius: var(--pill); font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.trainer-profile-info h1 { font-size: clamp(24px,3vw,32px); font-weight: 900; margin-bottom: 10px; }
.trainer-profile-bio { opacity: .92; font-size: 15px; line-height: 1.9; max-width: 620px; margin-bottom: 16px; }
.trainer-profile-stats { display: flex; gap: 30px; }
.trainer-profile-stats b { display: block; font-family: 'Cairo'; font-size: 24px; font-weight: 900; }
.trainer-profile-stats span { font-size: 13px; opacity: .85; }
@media (max-width: 640px){ .trainer-profile { flex-direction: column; text-align: center; } .trainer-profile-stats { justify-content: center; } }

/* ============================================================
   توحيد أحجام الخطوط في لوحة التحكم
   نص/أزرار: 13px · عناوين: 16px بولد
   ============================================================ */
.admin-main { font-size: 13px; }
.admin-main .btn { font-size: 13px; padding: 7px 16px; }
.admin-main .btn-lg { font-size: 13px; padding: 9px 18px; }
.admin-main table.data th,
.admin-main table.data td { font-size: 12.5px; padding: 10px 10px; }

/* أزرار وروابط داخل الجداول: صغيرة وموحّدة (تتغلّب على الـ inline) */
.admin-main table.data .btn { font-size: 11.5px !important; padding: 4px 10px !important; border-radius: 7px; }
.admin-main table.data .btn-sm { font-size: 11.5px !important; padding: 4px 10px !important; }
/* روابط عادية داخل الجداول (مثل "الدروس") تأخذ شكل رابط صغير واضح */
.admin-main table.data td a:not(.btn) {
    display: inline-block; font-size: 11.5px !important; font-weight: 600;
    color: var(--primary); background: var(--primary-soft);
    padding: 4px 10px; border-radius: 7px; text-decoration: none; transition: var(--t); white-space: nowrap;
}
.admin-main table.data td a:not(.btn):hover { background: var(--primary); color: #fff; }
.admin-main table.data td form { display: inline; }
.admin-main table.data td { white-space: nowrap; vertical-align: middle; }
/* تصغير المسافة بين أزرار الإجراءات */
.admin-main table.data td .btn + .btn,
.admin-main table.data td form + .btn,
.admin-main table.data td .btn + form { margin-right: 4px; }

.admin-main .field label { font-size: 13px; }
.admin-main .field input,
.admin-main .field select,
.admin-main .field textarea { font-size: 13px; }
.admin-main .alert { font-size: 13px; }
.admin-main .status-pill { font-size: 12px; padding: 3px 10px; }

/* العناوين: 16px بولد */
.admin-main .page-title { font-size: 16px; font-weight: 700; margin-bottom: 18px; }
.admin-main .section-title { font-size: 16px; font-weight: 700; margin: 24px 0 14px; }
.admin-main .gateway-name,
.admin-main .other-title,
.admin-main h3 { font-size: 16px; font-weight: 700; }
.admin-main .stat-box b { font-size: 22px; }
.admin-main .stat-box span { font-size: 13px; }
/* ============================================================
   صفحة الملف الشخصي (self-service)
   ============================================================ */
.profile-wrap { max-width: 960px; margin: 0 auto; }
.profile-head { display: flex; align-items: center; gap: 20px; margin-bottom: 24px; }
.profile-head h1 { font-size: clamp(22px,3vw,28px); font-weight: 900; }
.profile-role { color: var(--muted); font-size: 14px; }
.profile-avatar { width: 90px; height: 90px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
    background: var(--primary-soft); color: var(--primary); display: flex; align-items: center; justify-content: center; border: 3px solid var(--line); }
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.profile-avatar svg { width: 46px; height: 46px; }
.profile-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 760px){ .profile-grid { grid-template-columns: 1fr; } }
/* ============================================================
   لوحة تحكم الأدمن — الرسوم والإحصائيات
   ============================================================ */
.dash-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 820px){ .dash-grid { grid-template-columns: 1fr; } }

/* رسم الأعمدة */
.chart-bars { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; height: 180px; padding-top: 10px; }
.chart-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; }
.chart-bar-track { flex: 1; width: 100%; max-width: 34px; display: flex; align-items: flex-end; }
.chart-bar-fill { width: 100%; background: linear-gradient(180deg, var(--primary), var(--primary-deep));
    border-radius: 8px 8px 0 0; transition: height .6s cubic-bezier(.22,.9,.3,1); min-height: 4px; }
.chart-val { font-size: 12px; font-weight: 700; color: var(--primary-deep); }
.chart-label { font-size: 11px; color: var(--muted); }

/* صفوف الترتيب */
.rank-row { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.rank-name { font-size: 13px; font-weight: 600; flex: 0 0 40%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-track { flex: 1; height: 8px; background: var(--line); border-radius: 999px; overflow: hidden; }
.rank-fill { height: 100%; background: var(--success); border-radius: 999px; transition: width .6s ease; }
.rank-num { font-size: 13px; font-weight: 800; color: var(--primary-deep); min-width: 22px; text-align: left; }
/* ============================================================
   القائمة الفرعية في السايدبار + تفاصيل التحويل + التصنيفات
   ============================================================ */
.admin-submenu { display: flex; flex-direction: column; gap: 2px; margin: 2px 12px 6px; padding-right: 14px; border-right: 2px solid var(--line); }
.admin-submenu a { display: block; padding: 8px 12px; border-radius: var(--radius-sm); font-size: 12.5px; color: var(--muted); }
.admin-submenu a:hover { background: var(--primary-soft); color: var(--primary-deep); }
.admin-submenu a.is-active { background: var(--primary-soft); color: var(--primary-deep); font-weight: 700; }

/* تفاصيل التحويل البنكي */
.bt-detail-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 820px){ .bt-detail-grid { grid-template-columns: 1fr; } }
.bt-rows { display: flex; flex-direction: column; }
.bt-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.bt-row:last-child { border-bottom: none; }
.bt-row span { color: var(--muted); }
.bt-receipt-img { width: 100%; border-radius: 12px; border: 1px solid var(--line); display: block; }
.bt-receipt-pdf { width: 100%; height: 420px; border-radius: 12px; border: 1px solid var(--line); }

/* التصنيفات */
.cat-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 820px){ .cat-grid { grid-template-columns: 1fr; } }

/* ============================================================
   صفحة تفاصيل المدرب (الأدمن)
   ============================================================ */
.td-head { display: flex; align-items: center; gap: 20px; }
.td-avatar { width: 84px; height: 84px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
    background: var(--primary-soft); color: var(--primary); display: flex; align-items: center; justify-content: center; border: 2px solid var(--line); }
.td-avatar img { width: 100%; height: 100%; object-fit: cover; }
.td-avatar svg { width: 42px; height: 42px; }
.td-meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; color: var(--muted); }
@media (max-width: 640px){ .td-head { flex-direction: column; text-align: center; } }

/* ============================================================
   تحسين بطاقات إحصائيات لوحة التحكم + تفصيل الإيرادات
   ============================================================ */
.stat-grid-lg { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.stat-grid-lg .stat-box { position: relative; padding: 18px 16px 16px; border-radius: var(--radius-lg);
    background: var(--paper); border: 1px solid var(--line); text-align: center; transition: var(--t); }
.stat-grid-lg .stat-box:hover { transform: translateY(-3px); box-shadow: 0 12px 24px -14px rgba(60,52,137,.35); }
.stat-grid-lg .stat-box b { display: block; font-family: 'Cairo'; font-size: 30px; font-weight: 900; color: var(--primary-deep); line-height: 1; }
.stat-grid-lg .stat-box span { display: block; font-size: 13px; color: var(--muted); margin-top: 6px; }
.stat-grid-lg .stat-sub { display: block; font-size: 11px; color: var(--primary); margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); }
.stat-box-accent { background: linear-gradient(135deg, var(--primary), var(--primary-deep)) !important; border: none !important; }
.stat-box-accent b, .stat-box-accent span, .stat-box-accent .stat-sub { color: #fff !important; }
.stat-box-accent .stat-sub { border-top-color: rgba(255,255,255,.3); }

.rev-split { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.rev-item { display: flex; justify-content: space-between; align-items: center; gap: 10px;
    background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 14px 18px; }
.rev-item span { font-size: 13px; color: var(--muted); }
.rev-item b { font-size: 15px; font-weight: 800; color: var(--primary-deep); }
.rev-item-warn { border-color: var(--warning, #EF9F27); background: rgba(239,159,39,.06); }
.rev-item-warn b a { color: var(--warning, #EF9F27); }

/* ============================================================
   بانر الدخل الكلي (للأدمن فقط)
   ============================================================ */
.income-banner { display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
    background: linear-gradient(135deg, var(--primary-deep), var(--primary));
    color: #fff; border-radius: var(--radius-lg); padding: 22px 26px; position: relative; overflow: hidden; margin-bottom: 8px; }
.income-banner::after { content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 88% 20%, rgba(255,255,255,.14), transparent 45%); pointer-events: none; }
.income-lock { width: 44px; height: 44px; border-radius: 12px; background: rgba(255,255,255,.16);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0; position: relative; z-index: 2; }
.income-lock svg { width: 22px; height: 22px; color: #fff; }
.income-main { position: relative; z-index: 2; }
.income-label { font-size: 13px; opacity: .85; }
.income-value { font-family: 'Cairo'; font-size: 34px; font-weight: 900; line-height: 1.1; }
.income-value small { font-size: 15px; font-weight: 700; opacity: .8; }
.income-side { display: flex; gap: 26px; margin-right: auto; flex-wrap: wrap; position: relative; z-index: 2; }
.income-cell span { display: block; font-size: 12px; opacity: .8; margin-bottom: 3px; }
.income-cell b { font-size: 16px; font-weight: 800; }
.income-note { font-size: 12px; color: var(--muted); margin: 8px 2px 22px;
    display: flex; align-items: center; gap: 6px; }
.income-note::before { content: '🔒'; font-size: 11px; }
@media (max-width: 700px){ .income-side { margin-right: 0; gap: 18px; } .income-value { font-size: 28px; } }

/* ============================================================
   تحسين مظهر جداول لوحة التحكم
   ============================================================ */
.admin-main .table-wrap { background: var(--paper); border: 1px solid var(--line);
    border-radius: var(--radius-lg); overflow-x: auto; overflow-y: hidden; }
.admin-main table.data { border-collapse: separate; border-spacing: 0; }
.admin-main table.data th { background: var(--canvas); font-weight: 700; font-size: 12.5px;
    color: var(--muted); padding: 14px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin-main table.data td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.admin-main table.data tbody tr { transition: background .18s ease; }
.admin-main table.data tbody tr:hover { background: var(--primary-soft); }
.admin-main table.data tbody tr:last-child td { border-bottom: none; }

/* القوائم المنسدلة داخل الجداول (الدور/الحالة) */
.admin-main table.data td select {
    font-size: 12px !important; padding: 6px 10px !important; border-radius: 8px !important;
    border: 1px solid var(--line) !important; background: var(--paper) !important; color: var(--ink) !important;
    cursor: pointer; transition: var(--t); min-width: 80px;
}
.admin-main table.data td select:hover:not(:disabled) { border-color: var(--primary) !important; }

/* شريط الفلترة والبحث فوق الجدول */
.admin-main form input[type="search"] {
    padding: 8px 14px !important; border-radius: 10px !important; font-size: 13px !important;
    border: 1px solid var(--line) !important; background: var(--paper) !important;
}
.admin-main form input[type="search"]:focus { border-color: var(--primary) !important; outline: none; }
.admin-main form > select {
    padding: 8px 12px !important; border-radius: 10px !important; font-size: 13px !important;
    border: 1px solid var(--line) !important; background: var(--paper) !important; color: var(--ink); cursor: pointer;
}
.admin-main table.data td select:hover { border-color: var(--primary); }
.admin-main table.data td select:disabled { opacity: .55; cursor: not-allowed; }

/* خلية الاسم مع الصورة */
.admin-main table.data td .u-avatar {
    width: 34px; height: 34px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
    background: var(--primary-soft); display: inline-flex; align-items: center; justify-content: center;
}
.admin-main table.data td .u-avatar img { width: 100%; height: 100%; object-fit: cover; }

/* عمود الإجراءات: محاذاة ومسافات مرتّبة */
.admin-main table.data td:last-child { text-align: left; }

/* ============================================================
   صفحة إعدادات الرسائل النصية
   ============================================================ */
.sms-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 820px){ .sms-grid { grid-template-columns: 1fr; } }
.sms-grid code { background: var(--primary-soft); padding: 2px 8px; border-radius: 6px; font-size: 12px; }

/* ============================================================
   نظام التقويم الذاتي (Quiz)
   ============================================================ */
/* أدمن */
.quiz-admin-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 820px){ .quiz-admin-grid { grid-template-columns: 1fr; } }
.quiz-q-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 16px 18px; margin-bottom: 14px; }
.quiz-opts { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.quiz-opts li { font-size: 13px; padding: 7px 12px; border-radius: 8px; background: var(--canvas); color: var(--ink-soft); }
.quiz-opts li.is-correct { background: rgba(43,182,115,.12); color: #1c8a55; font-weight: 700; }
.quiz-opts li.is-wrong { background: rgba(224,72,72,.1); color: var(--danger); }

/* المتدرب */
.quiz-wrap { max-width: 800px; margin: 0 auto; }
.quiz-choices { display: flex; flex-direction: column; gap: 8px; }
.quiz-choice { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1.5px solid var(--line);
    border-radius: 12px; cursor: pointer; transition: var(--t); }
.quiz-choice:hover { border-color: var(--primary); background: var(--primary-soft); }
.quiz-choice input { accent-color: var(--primary); width: 18px; height: 18px; }
.quiz-choice input:checked + span { font-weight: 700; color: var(--primary-deep); }

/* النتيجة */
.quiz-result { display: flex; align-items: center; gap: 24px; background: var(--paper); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 26px; flex-wrap: wrap; }
.quiz-score-ring { width: 110px; height: 110px; border-radius: 50%; flex-shrink: 0; display: flex; flex-direction: column;
    align-items: center; justify-content: center; color: #fff; background: var(--rc, var(--primary)); }
.quiz-score-ring b { font-family: 'Cairo'; font-size: 28px; font-weight: 900; line-height: 1; }
.quiz-score-ring span { font-size: 13px; opacity: .9; }
.quiz-review-card { background: var(--paper); border: 1px solid var(--line); border-right: 4px solid var(--line);
    border-radius: var(--radius-lg); padding: 16px 18px; margin-bottom: 12px; }
.quiz-review-card.ok { border-right-color: var(--success); }
.quiz-review-card.wrong { border-right-color: var(--danger); }

/* صف خيار في نموذج إضافة السؤال (أدمن) */
.quiz-opt-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.quiz-opt-row input[type="radio"] { width: 20px; height: 20px; flex-shrink: 0; accent-color: var(--success); cursor: pointer; margin: 0; }
.quiz-opt-row input[type="text"] { flex: 1 1 auto; width: auto; min-width: 0;
    padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px;
    background: var(--paper); color: var(--ink); font-size: 13px; }
.quiz-opt-row input[type="text"]:focus { border-color: var(--primary); outline: none; }

/* ============================================================
   الصفحة الرئيسية — واجهة حيّة
   ============================================================ */
/* البانر المطوّر */
.hero-v2 { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--primary-deep) 0%, var(--primary) 55%, var(--primary-mid) 100%);
    background-size: 200% 200%; animation: heroGrad 14s ease infinite; }
@keyframes heroGrad { 0%,100%{background-position:0% 50%} 50%{background-position:100% 50%} }
.hero-shape { position: absolute; border-radius: 50%; background: rgba(255,255,255,.08); pointer-events: none; }
.hero-shape.s1 { width: 320px; height: 320px; top: -120px; right: -80px; animation: floaty 9s ease-in-out infinite; }
.hero-shape.s2 { width: 200px; height: 200px; bottom: -90px; left: 10%; background: rgba(239,159,39,.14); animation: floaty 11s ease-in-out infinite reverse; }
.hero-shape.s3 { width: 140px; height: 140px; top: 30%; left: -50px; animation: floaty 8s ease-in-out infinite; }
@keyframes floaty { 0%,100%{transform:translateY(0) scale(1)} 50%{transform:translateY(28px) scale(1.08)} }
.hero-v2 .hero-inner, .hero-v2 .hero-stats { position: relative; z-index: 2; }
.hero-badge-top { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.15);
    color: #fff; padding: 7px 16px; border-radius: var(--pill); font-size: 13px; font-weight: 700; margin-bottom: 18px; backdrop-filter: blur(6px); }
.hero-badge-top .dot { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 0 rgba(74,222,128,.6); animation: pulse 2s infinite; }
@keyframes pulse { 0%{box-shadow:0 0 0 0 rgba(74,222,128,.6)} 70%{box-shadow:0 0 0 8px rgba(74,222,128,0)} 100%{box-shadow:0 0 0 0 rgba(74,222,128,0)} }
.hero-counters .hero-stat b { font-variant-numeric: tabular-nums; }
.btn-glass { background: rgba(255,255,255,.15); color: #fff; border: 1.5px solid rgba(255,255,255,.35); backdrop-filter: blur(6px); }
.btn-glass:hover { background: rgba(255,255,255,.28); transform: translateY(-3px); }

/* شريط الثقة */
.trust-bar { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 30px; padding: 18px 24px; margin: 22px 0 8px;
    background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.trust-bar span { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; color: var(--ink-soft); }
.trust-bar svg { width: 20px; height: 20px; color: var(--primary); }

/* المميزات */
.accred-section .features-grid { margin-bottom:0; }
.accred-divider { height:1px; background:var(--line); margin:24px 0; opacity:.7; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px,1fr)); gap: 18px; margin-bottom: 20px; }
.feature-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 26px 22px; text-align: center; transition: var(--t); }
.feature-card:hover { transform: translateY(-6px); box-shadow: 0 18px 36px -20px rgba(60,52,137,.4); border-color: var(--primary-soft); }
.feature-ic { width: 60px; height: 60px; margin: 0 auto 16px; border-radius: 18px; display: flex; align-items: center; justify-content: center;
    background: var(--primary-soft); color: var(--primary-deep); }
.feature-ic svg { width: 30px; height: 30px; }
.feature-card h3 { font-size: 17px; font-weight: 800; margin-bottom: 8px; }
.feature-card p { font-size: 13.5px; color: var(--muted); line-height: 1.9; }

/* دعوة أخيرة */
.cta-final { position: relative; overflow: hidden; text-align: center; margin: 44px 0 10px; padding: 48px 30px;
    border-radius: var(--radius-lg); background: linear-gradient(135deg, var(--primary), var(--primary-deep)); color: #fff; }
.cta-final h2 { font-size: clamp(24px,3.5vw,32px); font-weight: 900; margin-bottom: 10px; }
.cta-final p { opacity: .9; margin-bottom: 22px; font-size: 16px; }
/* خلفية صورة للدعوة الأخيرة مع طبقة تغميق لوضوح النص */
.cta-final.has-bg { background: #201c26 center/cover no-repeat var(--cta-img); }
.cta-final.has-bg::before { content:''; position:absolute; inset:0; z-index:1;
  background: linear-gradient(135deg, rgba(18,14,24,.80), rgba(18,14,24,.70)); }
.cta-final.has-bg > * { position: relative; z-index: 2; }
.cta-final.has-bg h2, .cta-final.has-bg p { text-shadow: 0 2px 14px rgba(0,0,0,.5); }
html[data-theme="dark"] .cta-final.has-bg { background: #201c38 center/cover no-repeat var(--cta-img); }

/* ============================================================
   تهدئة ألوان الهيرو والدعوة في الوضع الداكن
   ============================================================ */
html[data-theme="dark"] .hero-v2 {
    background: linear-gradient(135deg, var(--canvas) 0%, var(--primary-soft) 60%, var(--primary-soft) 100%);
    background-size: 200% 200%;
}
html[data-theme="dark"] .cta-final {
    background: linear-gradient(135deg, var(--primary-soft), var(--canvas));
}
/* أشكال وطبقات أهدأ */
html[data-theme="dark"] .hero-shape { background: rgba(255,255,255,.05); }
html[data-theme="dark"] .hero-shape.s2 { background: rgba(239,159,39,.08); }
html[data-theme="dark"] .hero-badge-top { background: rgba(255,255,255,.08); }
html[data-theme="dark"] .btn-glass { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.2); }
html[data-theme="dark"] .btn-glass:hover { background: rgba(255,255,255,.16); }
/* بطاقة الميزة والثقة في الداكن */
html[data-theme="dark"] .feature-card:hover { box-shadow: 0 18px 36px -20px rgba(0,0,0,.5); }

/* ============================================================
   صفحة اتصل بنا + رأس الصفحات
   ============================================================ */
.page-head { text-align: center; margin: 10px 0 30px; }
.page-title-lg { font-size: clamp(26px,4vw,36px); font-weight: 900; margin-bottom: 8px; }
.page-head p { color: var(--muted); font-size: 15px; }
.contact-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 24px; align-items: start; }
@media (max-width: 820px){ .contact-grid { grid-template-columns: 1fr; } }
.contact-info { display: flex; flex-direction: column; gap: 14px; }
.contact-item { display: flex; align-items: center; gap: 14px; background: var(--paper); border: 1px solid var(--line);
    border-radius: var(--radius-lg); padding: 18px; transition: var(--t); }
a.contact-item:hover { transform: translateX(-4px); border-color: var(--primary-soft); box-shadow: 0 12px 24px -16px rgba(60,52,137,.35); }
.ci-ic { width: 48px; height: 48px; border-radius: 14px; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
    background: var(--primary-soft); color: var(--primary-deep); }
.ci-ic svg { width: 24px; height: 24px; }
.ci-label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 3px; }
.contact-item b { font-size: 15px; color: var(--ink); }

/* ============================================================
   الشركاء + الصفحات النصية
   ============================================================ */
.partners-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px,1fr)); gap: 18px; }
.partner-card { display: flex; flex-direction: column; align-items: center; gap: 12px; background: var(--paper);
    border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px 18px; text-align: center; transition: var(--t); }
a.partner-card:hover { transform: translateY(-5px); box-shadow: 0 16px 32px -18px rgba(60,52,137,.4); border-color: var(--primary-soft); }
.partner-card-logo { width: 90px; height: 90px; display: flex; align-items: center; justify-content: center;
    background: var(--canvas); border-radius: 16px; overflow: hidden; color: var(--primary-mid); }
.partner-card-logo img { max-width: 100%; max-height: 100%; object-fit: contain; }
.partner-card-logo svg { width: 42px; height: 42px; }
.partner-card span { font-size: 14px; font-weight: 700; color: var(--ink); }

/* إدارة الشركاء */
.partners-admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px,1fr)); gap: 14px; }
.partner-admin-card { display: flex; flex-direction: column; align-items: center; gap: 10px; background: var(--paper);
    border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 16px 12px; }
.partner-logo { width: 64px; height: 64px; display: flex; align-items: center; justify-content: center;
    background: var(--canvas); border-radius: 12px; overflow: hidden; color: var(--primary-mid); }
.partner-logo img { max-width: 100%; max-height: 100%; object-fit: contain; }
.partner-logo svg { width: 30px; height: 30px; }

/* الصفحات النصية */
.static-page { max-width: 800px; margin: 0 auto; }
.static-page.static-wide { max-width: 100%; }
.static-body { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: 30px; font-size: 15px; line-height: 2.1; color: var(--ink-soft); }

/* صورة خلفية البانر (اختيارية) */
.hero-v2.has-bg-img { position: relative; background: #201c26; animation: none; }
/* الصورة تملأ البانر كامل وواضحة */
.hero-v2.has-bg-img::before {
    content: ''; position: absolute; inset: 0 !important; width: 100% !important; height: 100% !important;
    top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
    border-radius: 0 !important; transform: none !important; animation: none !important; z-index: 0;
    filter: none !important; -webkit-filter: none !important;
    background-image: var(--hero-img); background-size: cover; background-position: center;
    opacity: 1;
}
/* طبقة داكنة خفيفة فقط لقراءة النص الأبيض */
.hero-v2.has-bg-img::after {
    content: ''; position: absolute; inset: 0; z-index: 1;
    background-image: none !important;
    background: linear-gradient(to top, rgba(20,16,45,.42), rgba(20,16,45,.16) 55%, rgba(20,16,45,.06)) !important;
}
.hero-v2.has-bg-img .hero-inner, .hero-v2.has-bg-img .hero-stats { position: relative; z-index: 3; }
/* ظل قوي للنصوص عشان تبان فوق الصورة الواضحة */
.hero-v2.has-bg-img .hero-title { text-shadow: 0 2px 16px rgba(0,0,0,.55), 0 1px 3px rgba(0,0,0,.6); }
.hero-v2.has-bg-img .hero-sub { text-shadow: 0 1px 10px rgba(0,0,0,.6); }
.hero-v2.has-bg-img .hero-badge-top { background: rgba(0,0,0,.35); backdrop-filter: blur(4px); }
.hero-v2.has-bg-img .hero-stat b,
.hero-v2.has-bg-img .hero-stat span { text-shadow: 0 1px 8px rgba(0,0,0,.6); }
/* إخفاء الأشكال الدائرية عند وجود صورة (تشوّش عليها) */
.hero-v2.has-bg-img .hero-shape { display: none; }
html[data-theme="dark"] .hero-v2.has-bg-img::after { background: linear-gradient(to top, rgba(6,4,16,.55), rgba(6,4,16,.28) 55%, rgba(6,4,16,.12)) !important; }


/* اللوقو في الوضع الليلي: خلفية فاتحة عشان الكتابة السوداء تبان */
html[data-theme="dark"] .logo img {
    background: #fff; padding: 6px 10px; border-radius: 12px;
}
.hero-v2.has-bg-img .hero-shape { z-index: 2; }

/* أيقونات المميزات ملوّنة */
.fic-1 { background: rgba(239,159,39,.15) !important; color: #d98a1a !important; }   /* ذهبي */
.fic-2 { background: rgba(43,182,115,.15) !important; color: #1c8a55 !important; }   /* أخضر */
.fic-3 { background: rgba(83,74,183,.15) !important; color: var(--primary) !important; } /* بنفسجي */
.fic-4 { background: rgba(224,72,72,.13) !important; color: #d64545 !important; }    /* أحمر */

/* ============================================================
   محرّر المقالات البسيط
   ============================================================ */
.editor-toolbar { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px; background: var(--canvas);
    border: 1px solid var(--line); border-bottom: none; border-radius: 10px 10px 0 0; }
.editor-toolbar button { background: var(--paper); border: 1px solid var(--line); border-radius: 7px;
    padding: 6px 10px; font-size: 13px; cursor: pointer; color: var(--ink); transition: var(--t); min-width: 34px; }
.editor-toolbar button:hover { background: var(--primary-soft); border-color: var(--primary); color: var(--primary-deep); }
.editor-toolbar .ed-sep { width: 1px; background: var(--line); margin: 2px 4px; }
.editor-area { min-height: 300px; padding: 16px; background: var(--paper); border: 1px solid var(--line);
    border-radius: 0 0 10px 10px; font-size: 15px; line-height: 2; color: var(--ink); overflow-y: auto; }
.editor-area:focus { outline: none; border-color: var(--primary); }
.editor-area:empty::before { content: 'ابدأ كتابة المقال هنا...'; color: var(--muted); }
.editor-area h2 { font-size: 22px; font-weight: 800; margin: 16px 0 8px; }
.editor-area h3 { font-size: 18px; font-weight: 700; margin: 14px 0 6px; }
.editor-area p { margin: 8px 0; }
.editor-area ul, .editor-area ol { margin: 8px 24px; }
.editor-area img { max-width: 100%; height: auto; border-radius: 10px; margin: 10px 0; }
.editor-area blockquote { border-right: 4px solid var(--primary); padding: 8px 16px; margin: 12px 0;
    background: var(--primary-soft); border-radius: 0 8px 8px 0; color: var(--ink-soft); }
.editor-area a { color: var(--primary); text-decoration: underline; }
/* عرض المقال العام */
.article-body img { max-width: 100%; height: auto; border-radius: 12px; margin: 16px 0; }
.article-body h2 { font-size: 26px; font-weight: 800; margin: 24px 0 12px; }
.article-body h3 { font-size: 21px; font-weight: 700; margin: 20px 0 10px; }
.article-body blockquote { border-right: 4px solid var(--primary); padding: 12px 20px; margin: 18px 0;
    background: var(--primary-soft); border-radius: 0 10px 10px 0; }
.article-body ul, .article-body ol { margin: 12px 28px; }
/* تباعد الفقرات والقوائم في المحتوى الغني (وصف الدورة، الصفحات، المقالات) */
.article-body p { margin: 0 0 14px; line-height: 1.95; }
.article-body p:last-child { margin-bottom: 0; }
.article-body li { margin-bottom: 6px; line-height: 1.9; }
.article-body h2:first-child, .article-body h3:first-child, .article-body p:first-child { margin-top: 0; }
.article-body a { color: var(--primary-deep); text-decoration: underline; }
.article-body b, .article-body strong { font-weight: 800; }

/* ============================================================
   صفحة SEO — المعاينات
   ============================================================ */
.seo-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 900px){ .seo-grid { grid-template-columns: 1fr; } }
.seo-preview-google .sp-title { color: #1a0dab; font-size: 18px; margin-bottom: 2px; }
.seo-preview-google .sp-url { color: #006621; font-size: 13px; margin-bottom: 4px; direction: ltr; text-align: right; }
.seo-preview-google .sp-desc { color: #545454; font-size: 13px; line-height: 1.6; }
html[data-theme="dark"] .seo-preview-google .sp-title { color: #8ab4f8; }
html[data-theme="dark"] .seo-preview-google .sp-url { color: #6ee7a0; }
.seo-preview-social { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.seo-preview-social img { width: 100%; aspect-ratio: 1200/630; object-fit: cover; display: block; }
.seo-preview-social .sp-noimg { aspect-ratio: 1200/630; display: flex; align-items: center; justify-content: center;
    background: var(--canvas); color: var(--muted); font-size: 13px; }
.sp-social-body { padding: 12px 14px; background: var(--canvas); }
.sp-social-site { font-size: 11px; color: var(--muted); text-transform: uppercase; direction: ltr; text-align: right; }
.sp-social-title { font-size: 15px; font-weight: 700; margin: 3px 0; }
.sp-social-desc { font-size: 13px; color: var(--muted); }

/* ============================================================
   سلايدر الهيرو (شرائح متحركة + أزرار وإحصائيات ثابتة)
   ============================================================ */
.hero-slider { position: relative; overflow: hidden; }
.hero-slides { position: absolute; inset: 0; z-index: 0; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease;
    padding: 44px 40px 190px; pointer-events: none; display: flex; flex-direction: column; justify-content: flex-start; }
.hero-slide.is-active { opacity: 1; pointer-events: auto; }
/* صورة خلفية الشريحة */
.hero-slide.has-bg-img::before {
    content: ''; position: absolute; inset: 0; z-index: 0;
    background-image: var(--hero-img); background-size: cover; background-position: center; filter: none;
}
.hero-slide.has-bg-img::after {
    content: ''; position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(to top, rgba(20,16,45,.55), rgba(20,16,45,.28) 55%, rgba(20,16,45,.15));
}
.hero-slide .hero-inner { position: relative; z-index: 3; max-width: 640px; margin-left: auto; margin-right: 0; text-align: right; }
.hero-slide.has-bg-img .hero-title { text-shadow: 0 2px 16px rgba(0,0,0,.55), 0 1px 3px rgba(0,0,0,.6); }
.hero-slide.has-bg-img .hero-sub { text-shadow: 0 1px 10px rgba(0,0,0,.6); }
.hero-slide.has-bg-img .hero-badge-top { background: rgba(0,0,0,.35); }

/* الهيكل: الصورة تملأ الشريحة (بحجم المحتوى)، النص+الأزرار أعلى، والإحصائيات أسفل فوق الصورة */
.hero-slider { display: block; position: relative; padding: 0; }
.hero-slider .hero-slides { position: relative; inset: auto; z-index: 0; }
.hero-slide { padding: 44px 40px; justify-content: space-between; }
.hero-slide.is-active { position: relative; inset: auto; opacity: 1; min-height: 560px; }
.hero-slide .hero-inner .hero-actions { margin-top: 24px; position: relative; z-index: 3; justify-content: flex-start; }
.hero-slider .hero-actions-wrap { display: none; }
.hero-slide .hero-stats { position: relative; z-index: 3; margin-top: 34px; gap: 30px; justify-content: flex-start; }
/* ضمان قابلية الضغط: الطبقات الزخرفية لا تلتقط الضغط، وأزرار الشريحة النشطة قابلة للضغط وفوق التدرّج */
.hero-slide.has-bg-img::before,
.hero-slide.has-bg-img::after { pointer-events: none; }
.hero-slide.is-active { pointer-events: auto; }
.hero-slide.is-active .hero-inner,
.hero-slide.is-active .hero-inner .hero-actions,
.hero-slide.is-active .hero-inner .hero-actions a { pointer-events: auto; }
.hero-slide.is-active .hero-inner .hero-actions a { position: relative; z-index: 5; }
.hero-slide.has-bg-img .hero-stat b, .hero-slide.has-bg-img .hero-stat span { text-shadow: 0 1px 8px rgba(0,0,0,.6); }
/* تكبير العنوان والوصف ليملآ الهيرو */
.hero-slide .hero-inner { max-width: 700px; }
.hero-slide .hero-title { font-size: clamp(34px, 5.6vw, 56px); line-height: 1.28; margin-bottom: 18px; }
.hero-slide .hero-sub { font-size: 19px; line-height: 1.9; margin-bottom: 4px; }
/* تحكم حجم عنوان الهيرو من الأدمن (يتغلّب على الحجم الافتراضي أعلاه) */
.hero-slide .hero-title.hts-sm { font-size: clamp(22px, 3.4vw, 32px); }
.hero-slide .hero-title.hts-md { font-size: clamp(28px, 5vw, 44px); }
.hero-slide .hero-title.hts-lg { font-size: clamp(34px, 6vw, 56px); }
.hero-slide .hero-title.hts-xl { font-size: clamp(40px, 7.5vw, 70px); }

/* النقاط */
.hero-dots { position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%); display: flex; gap: 2px; z-index: 6; }
/* هدف لمس 24px مع إبقاء النقطة المرئية صغيرة (ترضي تدقيق الوصول) */
.hero-dot { width: 24px; height: 24px; border: none; background: transparent; cursor: pointer; padding: 0; position: relative; }
.hero-dot::before { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
    width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,.4); transition: var(--t); }
.hero-dot.is-active::before { background: #fff; width: 26px; border-radius: 6px; }
/* الأسهم */
.hero-arrow { display: none; }

/* ============================================================
   صفحة الخطأ 404
   ============================================================ */
.err-page { text-align: center; padding: 60px 20px; max-width: 600px; margin: 0 auto; }
.err-code { font-family: 'Cairo'; font-size: clamp(90px, 18vw, 160px); font-weight: 900; line-height: 1;
    background: linear-gradient(135deg, var(--primary), var(--primary-deep)); -webkit-background-clip: text;
    background-clip: text; -webkit-text-fill-color: transparent; }
.err-title { font-size: clamp(22px, 4vw, 30px); font-weight: 900; margin: 8px 0 10px; }
.err-sub { color: var(--muted); font-size: 16px; margin-bottom: 26px; }
.err-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 34px; }
.err-links { display: flex; gap: 8px 18px; justify-content: center; flex-wrap: wrap; align-items: center;
    padding-top: 22px; border-top: 1px solid var(--line); font-size: 14px; }
.err-links span { color: var(--muted); }
.err-links a { color: var(--primary); font-weight: 600; }
.err-links a:hover { color: var(--primary-deep); }

/* ============================================================
   صفحة الرسائل + تنبيه القائمة
   ============================================================ */
.msg-card { margin-bottom: 14px; }
.msg-head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.msg-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: flex-start; }
.msg-btn { padding: 5px 12px !important; font-size: 12px !important; }
.msg-reply { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.msg-reply textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px;
    font-size: 14px; font-family: inherit; background: var(--paper); color: var(--ink); resize: vertical; }
.msg-reply textarea:focus { outline: none; border-color: var(--primary); }
/* تنبيه عدد الرسائل في القائمة */
.nav-badge { background: var(--danger); color: #fff; font-size: 11px; font-weight: 800; min-width: 18px; height: 18px;
    border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; margin-right: auto; }
.admin-side .nav-item.is-active .nav-badge { background: #fff; color: var(--primary-deep); }

/* ============================================================
   شارات اعتماد المركز الوطني
   ============================================================ */
.chip-nelc { background: rgba(43,182,115,.12) !important; color: #1c8a55 !important; border: 1px solid rgba(43,182,115,.3); font-weight: 700; }
.chip-nelc svg { width: 15px; height: 15px; }
.nelc-banner { display: flex; align-items: center; gap: 12px; background: linear-gradient(135deg, rgba(43,182,115,.1), rgba(43,182,115,.04));
    border: 1px solid rgba(43,182,115,.25); border-radius: var(--radius-lg); padding: 14px 18px; margin-bottom: 20px; }
.nelc-banner svg { width: 26px; height: 26px; color: #1c8a55; flex-shrink: 0; }
.nelc-banner span { font-size: 14px; color: var(--ink-soft); }
.nelc-banner b { color: #1c8a55; }
html[data-theme="dark"] .nelc-banner span { color: var(--ink); }

/* زر حفظ بحجم طبيعي (بدل الممتد) */
.btn-save { padding: 10px 44px !important; width: auto; display: inline-block; }

/* أزرار جدول صغيرة + روابط الجدول */
.btn-sm { padding: 4px 12px !important; font-size: 12.5px !important; }
.tbl-link { color: var(--primary); font-weight: 600; font-size: 13px; }
.tbl-link:hover { color: var(--primary-deep); text-decoration: underline; }

/* ترقيم الصفحات */
.pagination { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; margin-top: 20px; }
.page-btn { min-width: 38px; height: 38px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink-soft);
    font-size: 14px; font-weight: 600; transition: var(--t); }
.page-btn:hover { border-color: var(--primary); color: var(--primary); }
.page-btn.is-active { background: var(--primary); color: #fff; border-color: var(--primary); }
/* منطقة الرد في الرسالة */
.msg-reply-area { width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px;
    font-size: 14px; font-family: inherit; background: var(--paper); color: var(--ink); resize: vertical; }
.msg-reply-area:focus { outline: none; border-color: var(--primary); }

/* زر الوضع الليلي في طرف الهيدر (منفصل عن القوائم) */
.theme-toggle-edge { flex-shrink: 0; margin-right: 6px; }
.theme-label { display: none; }
/* على الكمبيوتر: زر الوضع الليلي يُدفع لطرف القائمة اليسار */
@media (min-width: 901px) {
    .navbar nav .theme-toggle-edge { margin-right: auto; }
}

/* ============================================================
   الهيرو على الموبايل — ترتيب رأسي بدون تداخل
   ============================================================ */
@media (max-width: 768px) {
    .hero-slider { min-height: 0 !important; display: block !important; position: relative !important; }
    /* الشريحة النشطة تتدفّق وتحدّد الارتفاع؛ غير النشطة خلفها للتلاشي */
    .hero-slider .hero-slides { position: relative !important; inset: auto !important; z-index: 0; }
    .hero-slide { position: absolute !important; inset: 0 !important; opacity: 0 !important;
        display: flex !important; flex-direction: column !important; justify-content: flex-start !important;
        padding: 30px 20px !important; transition: opacity .6s ease; }
    .hero-slide.is-active { position: relative !important; inset: auto !important; opacity: 1 !important; }
    .hero-slide::before { border-radius: 0 !important; }
    .hero-slide::after { border-radius: 0 !important;
        background: linear-gradient(to top, rgba(15,12,35,.82), rgba(15,12,35,.35) 45%, rgba(15,12,35,.25)) !important; }
    .hero-slide .hero-inner { max-width: 100% !important; position: relative; z-index: 3; }
    .hero-title { font-size: 22px !important; line-height: 1.5 !important; margin-bottom: 10px; }
    /* على الجوال تُحترم أحجام الأدمن أيضاً */
    .hero-slide .hero-title.hts-sm { font-size: 19px !important; }
    .hero-slide .hero-title.hts-md { font-size: 22px !important; }
    .hero-slide .hero-title.hts-lg { font-size: 27px !important; }
    .hero-slide .hero-title.hts-xl { font-size: 32px !important; }
    .hero-sub { font-size: 13.5px !important; }
    /* الأزرار تحت النص، عمودية بعرض كامل */
    .hero-slide .hero-inner .hero-actions { flex-direction: column; margin-top: 16px; }
    .hero-slide .hero-inner .hero-actions .btn { width: 100%; }
    /* الإحصائيات تنساب أسفل الشريحة مباشرة */
    .hero-slider .hero-stats { position: relative !important; z-index: 5; right: auto !important; left: auto !important;
        top: auto !important; bottom: auto !important; margin: 0 !important; padding: 16px 20px !important; gap: 12px !important;
        background: transparent !important; border-top: 1px solid rgba(255,255,255,.25); justify-content: space-around !important; }
    .hero-stat b { font-size: 20px !important; }
    .hero-stat span { font-size: 11px !important; }
    .hero-dots { position: absolute; top: 12px; bottom: auto; z-index: 6; left: 50%; transform: translateX(-50%); }
}

/* التوب بار على الموبايل: إخفاء الوقت والفواصل الزائدة */
@media (max-width: 640px) {
    .site-topbar .tb-time, .site-topbar .tb-date .cal-full { display: none; }
    .site-topbar .tb-sep { display: none; }
    .site-topbar .topbar-inner { gap: 8px; font-size: 11.5px; }
    .site-topbar .tb-city svg, .site-topbar .tb-date svg { width: 13px; height: 13px; }
}

/* أيقونات السوشال في الفوتر */
.footer-social { display: flex; gap: 10px; margin: 16px 0; flex-wrap: wrap; }
.footer-social a { width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15); color: rgba(255,255,255,.85); transition: var(--t); }
.footer-social a:hover { background: #fff; color: var(--primary-deep); transform: translateY(-3px); }
.footer-social svg { width: 19px; height: 19px; }

/* ============================================================
   عناصر التحويل في الواجهة: شريط الجلسة، الآراء، الأسئلة الشائعة
   ============================================================ */
.live-strip { display:flex; align-items:center; gap:14px; flex-wrap:wrap; margin:14px 0;
  padding:14px 20px; border-radius:var(--radius-lg); text-decoration:none;
  background:linear-gradient(120deg,#7c3aed,#4f46e5); color:#fff;
  box-shadow:0 8px 24px rgba(79,70,229,.25); transition:transform .2s, box-shadow .2s; }
.live-strip:hover { transform:translateY(-2px); box-shadow:0 12px 30px rgba(79,70,229,.35); }
.live-strip-badge { display:inline-flex; align-items:center; gap:7px; font-weight:800; font-size:13px;
  background:rgba(255,255,255,.18); padding:5px 12px; border-radius:999px; white-space:nowrap; }
.live-dot { width:9px; height:9px; border-radius:50%; background:#ff5b5b; animation:livePulse 1.4s infinite; }
@keyframes livePulse { 0%{box-shadow:0 0 0 0 rgba(255,91,91,.6)} 70%{box-shadow:0 0 0 10px rgba(255,91,91,0)} 100%{box-shadow:0 0 0 0 rgba(255,91,91,0)} }
.live-strip-title { font-weight:800; font-size:15px; flex:1; min-width:180px; }
.live-strip-course { font-weight:500; opacity:.8; }
.live-strip-count { font-weight:900; font-size:18px; background:rgba(0,0,0,.18); padding:6px 12px; border-radius:10px; }
.live-strip-count span { font-size:12px; font-weight:700; opacity:.85; }
.live-strip-cta { font-weight:800; font-size:14px; background:#fff; color:var(--primary-deep); padding:8px 16px; border-radius:999px; white-space:nowrap; }

.testi-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(300px,1fr)); gap:18px; margin-bottom:10px; }
.testi-card { background:var(--paper); border:1px solid var(--line); border-radius:var(--radius-lg); padding:22px; display:flex; flex-direction:column; gap:14px; transition:transform .2s, box-shadow .2s; }
.testi-card:hover { transform:translateY(-3px); box-shadow:0 10px 28px rgba(0,0,0,.08); }
.testi-stars { color:#f5a623; letter-spacing:2px; font-size:15px; }
.testi-stars span { color:var(--line); }
.testi-body { font-size:15px; line-height:1.9; color:var(--ink); flex:1; margin:0; }
.testi-person { display:flex; align-items:center; gap:12px; }
.testi-avatar { width:46px; height:46px; border-radius:50%; object-fit:cover; flex-shrink:0; }
.testi-initial { display:flex; align-items:center; justify-content:center; background:var(--primary-soft); color:var(--primary-deep); font-weight:900; font-size:18px; }
.testi-name { display:block; font-size:14px; }
.testi-role { font-size:12px; color:var(--muted); }

.faq-list { max-width:820px; margin:0 auto 10px; display:flex; flex-direction:column; gap:10px; }
.faq-item { background:var(--paper); border:1px solid var(--line); border-radius:14px; overflow:hidden; }
.faq-item summary { list-style:none; cursor:pointer; padding:16px 20px; font-weight:700; font-size:15px; color:var(--ink); display:flex; justify-content:space-between; align-items:center; gap:12px; }
.faq-item summary::-webkit-details-marker { display:none; }
.faq-plus { font-size:24px; color:var(--primary); transition:transform .2s; font-weight:400; line-height:1; }
.faq-item[open] .faq-plus { transform:rotate(45deg); }
.faq-answer { padding:0 20px 18px; color:var(--muted); font-size:14px; line-height:1.9; }

@media (max-width:768px){
  .live-strip { flex-direction:column; align-items:stretch; text-align:center; }
  .live-strip-title { min-width:0; }
  .live-strip-count, .live-strip-cta { align-self:center; }
}

/* ===== الاعتمادات الرسمية ===== */
.accred-section { margin:26px 0; padding:24px; border-radius:var(--radius-lg);
  background:linear-gradient(180deg, var(--primary-soft), var(--paper)); border:1px solid var(--line); }
.accred-head { display:flex; align-items:center; justify-content:center; gap:10px;
  font-size:18px; font-weight:800; color:var(--primary-deep); margin-bottom:20px; text-align:center; }
.accred-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); gap:14px; }
.accred-card { display:flex; flex-direction:column; align-items:center; text-align:center; gap:12px; background:var(--paper);
  border:1px solid var(--line); border-radius:14px; padding:20px 16px; transition:transform .2s, box-shadow .2s; }
.accred-card:hover { transform:translateY(-2px); box-shadow:0 8px 22px rgba(0,0,0,.07); }
.accred-icon { width:48px; height:48px; flex-shrink:0; border-radius:12px;
  background:var(--primary-soft); color:var(--primary-deep); display:flex; align-items:center; justify-content:center; }
.accred-icon svg { width:26px; height:26px; }
.accred-logo { height:56px; display:flex; align-items:center; justify-content:center; padding:4px 8px; }
.accred-logo img { max-width:170px; max-height:56px; width:auto; height:auto; object-fit:contain; }
.accred-body { display:flex; flex-direction:column; gap:4px; align-items:center; min-width:0; }
.accred-name { font-size:14px; font-weight:800; color:var(--ink); line-height:1.5; }
.accred-num { font-size:12px; color:var(--muted); }
.accred-verified { color:var(--success); font-weight:700; }

/* ===== بطاقة المنتج في القائمة ===== */
.product-card .course-card-foot { flex-direction: column; align-items: stretch; gap: 12px; }
.product-card .course-price { text-align: center; white-space: nowrap; font-size: 22px; }
.product-card .course-card-foot .btn { width: 100%; justify-content: center; padding: 11px; font-size: 14px; }

/* ===== صفحة تفاصيل المنتج ===== */
.product-detail { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; margin: 6px 0 30px; }
@media (max-width: 860px){ .product-detail { grid-template-columns: 1fr; } }
.product-tag { display:inline-block; font-size:12px; font-weight:800; color:var(--primary-deep); background:var(--primary-soft); padding:5px 14px; border-radius:999px; margin-bottom:14px; }
.product-tag.is-free { color:var(--success); background:rgba(16,185,129,.12); }
.product-title { font-size: clamp(24px, 3.5vw, 34px); font-weight: 900; line-height: 1.4; margin-bottom: 12px; color: var(--ink); }
.product-summary { font-size: 16px; line-height: 1.9; color: var(--muted); margin-bottom: 18px; }
.product-desc { font-size: 15px; line-height: 2; color: var(--ink); }
.product-includes { margin-top: 24px; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
.product-includes-head { font-weight: 800; margin-bottom: 12px; font-size: 15px; }
.product-includes ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.product-includes li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--ink); }
.product-includes li svg { color: var(--primary); flex-shrink: 0; }
.product-buy-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; box-shadow: 0 10px 30px rgba(0,0,0,.08); position: sticky; top: 20px; }
.product-buy-cover { border-radius: 12px; overflow: hidden; margin-bottom: 16px; }
.product-buy-cover img { width: 100%; display: block; }
.product-buy-price { font-size: 30px; font-weight: 900; color: var(--primary-deep); text-align: center; margin-bottom: 18px; }
.product-buy-price.is-free { color: var(--success); }
.product-buy-card .btn-block { width: 100%; justify-content: center; }
.product-buy-note { font-size: 12px; color: var(--muted); text-align: center; margin-top: 12px; line-height: 1.7; }
.product-buy-meta { font-size: 12px; color: var(--muted); text-align: center; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.product-owned { background: rgba(16,185,129,.12); color: var(--success); font-weight: 700; text-align: center; padding: 10px; border-radius: 10px; margin-bottom: 14px; font-size: 14px; }
.product-pending { background: var(--primary-soft); color: var(--primary-deep); text-align: center; padding: 14px; border-radius: 10px; font-size: 13px; line-height: 1.7; }

/* ===== سلايدر الجلسات المباشرة ===== */
.live-carousel { position: relative; margin: 14px 0; }
.live-carousel .live-strip { margin: 0; }
.live-slide { display: none; }
.live-slide.is-active { display: flex; }
.live-dots { display: flex; justify-content: center; gap: 7px; margin-top: 8px; }
.live-dots button { width: 8px; height: 8px; border-radius: 50%; border: none; background: var(--line); cursor: pointer; padding: 0; transition: all .25s; }
.live-dots button.is-active { background: var(--primary); width: 22px; border-radius: 999px; }

/* ألوان دوّارة للجلسات في السلايدر (خلفية كاملة لكل جلسة) */
/* شريط الفصول الافتراضية يتبع ألوان الثيم مع تنويع بسيط بين الشرائح */
.live-strip.live-c0 { background: linear-gradient(120deg,var(--primary),var(--primary-deep)); }
.live-strip.live-c1 { background: linear-gradient(120deg,var(--primary-deep),var(--primary-mid)); }
.live-strip.live-c2 { background: linear-gradient(120deg,var(--primary-mid),var(--primary)); }
.live-strip.live-c3 { background: linear-gradient(300deg,var(--primary),var(--primary-deep)); }
.live-strip.live-c4 { background: linear-gradient(300deg,var(--primary-deep),var(--primary-mid)); }
.live-strip.live-c5 { background: linear-gradient(300deg,var(--primary-mid),var(--primary)); }
.live-carousel .live-strip-cta { color: #111827; }
