/* Insaniya LMS Front-End Design (Gold Theme) */
:root {
    --gold-primary: #D4AF37;
    --gold-hover: #B5952F;
    --dark-bg: #111;
    --light-bg: #F9F9F9;
    --text-main: #333;
    --border-color: #EAEAEA;
    --font-cairo: 'Cairo', sans-serif;
}

body {
    background-color: #fff; /* تأكد أن الخلفية بيضاء */
}

.ins-lms-single-wrapper {
    font-family: var(--font-cairo);
    direction: rtl;
    text-align: right;
}

.ins-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 1. Header Area */
.ins-course-header {
    background-color: var(--dark-bg);
    padding: 60px 0;
    color: #fff;
    margin-bottom: 40px;
}

.ins-badge {
    background-color: var(--gold-primary);
    color: #000;
    padding: 5px 15px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.9rem;
    display: inline-block;
    margin-bottom: 15px;
}

.course-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 0 0 20px;
    line-height: 1.3;
    color: #fff;
}

.course-meta-header span {
    margin-left: 20px;
    color: #ccc;
    font-size: 0.95rem;
}

.course-meta-header i {
    color: var(--gold-primary);
    vertical-align: middle;
}

/* 2. Layout (Grid) */
.ins-course-layout {
    display: grid;
    grid-template-columns: 2fr 1fr; /* المحتوى يأخذ مساحة أكبر */
    gap: 40px;
    margin-bottom: 60px;
}

/* Content Area */
.ins-box {
    margin-bottom: 40px;
}

.ins-box h3 {
    font-size: 1.5rem;
    border-right: 4px solid var(--gold-primary);
    padding-right: 15px;
    margin-bottom: 20px;
    color: var(--text-main);
}

.the-content {
    line-height: 1.8;
    color: #555;
    font-size: 1.05rem;
}

/* 3. Sticky Sidebar (Desktop) */
.ins-course-sidebar {
    position: relative;
}

.ins-sticky-widget {
    position: sticky;
    top: 100px; /* المسافة من الأعلى عند التمرير */
    background: #fff;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    border-radius: 12px;
    overflow: hidden;
    margin-top: -150px; /* تداخل مع الهيدر الأسود */
    z-index: 10;
}

.sidebar-media {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: #000;
}

.sidebar-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
}

.play-btn {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255,255,255,0.9);
    color: #000;
    padding: 10px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    transition: 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.play-btn:hover {
    background: var(--gold-primary);
    color: #fff;
}

.sidebar-info {
    padding: 30px;
}

.price-tag {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.old-price {
    font-size: 1.2rem;
    text-decoration: line-through;
    color: #999;
    font-weight: 400;
}

.ins-btn-enroll {
    display: block;
    width: 100%;
    background: linear-gradient(45deg, var(--gold-primary), #e6c86e);
    color: #000;
    text-align: center;
    padding: 15px;
    border: none;
    border-radius: 6px;
    font-weight: 800;
    font-size: 1.1rem;
    cursor: pointer;
    transition: 0.3s;
    margin-bottom: 15px;
}

.ins-btn-enroll:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(212, 175, 55, 0.3);
}

.guarantee-text {
    text-align: center;
    font-size: 0.8rem;
    color: #777;
    margin-bottom: 25px;
}

.course-features-list {
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
}

.course-features-list li {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px dashed #eee;
    color: #555;
}

.course-features-list li:last-child {
    border-bottom: none;
}

.course-features-list .icon {
    width: 25px;
}

/* 4. Mobile Responsiveness */
.ins-mobile-sticky-bar {
    display: none; /* مخفي في الديسك توب */
}

.mobile-media-area {
    display: none;
}

@media (max-width: 992px) {
    .ins-course-layout {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .ins-course-sidebar {
        display: none; /* إخفاء السايد بار بالكامل في الموبايل */
    }

    .ins-sticky-widget {
        display: none; 
    }

    .mobile-media-area {
        display: block;
        margin-bottom: 30px;
        position: relative;
    }
    
    .mobile-media-area img {
        width: 100%;
        border-radius: 10px;
    }

    .ins-course-header {
        padding: 40px 0;
    }
    
    .course-title {
        font-size: 1.8rem;
    }

    /* الشريط السفلي المثبت للموبايل */
    .ins-mobile-sticky-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #fff;
        padding: 15px 20px;
        box-shadow: 0 -5px 20px rgba(0,0,0,0.1);
        z-index: 999;
        justify-content: space-between;
        align-items: center;
        border-top: 1px solid #eee;
    }

    .ins-mobile-sticky-bar .mobile-price {
        display: flex;
        flex-direction: column;
    }

    .ins-mobile-sticky-bar .mobile-price .label {
        font-size: 0.8rem;
        color: #777;
    }

    .ins-mobile-sticky-bar .mobile-price .val {
        font-size: 1.2rem;
        font-weight: 800;
        color: var(--gold-primary);
    }

    .ins-mobile-sticky-bar .mobile-btn {
        width: auto;
        padding: 12px 30px;
        margin: 0;
        font-size: 1rem;
    }
    
    /* رفع المحتوى قليلاً حتى لا يغطيه الشريط السفلي */
    body {
        padding-bottom: 80px; 
    }
}
/* ================= Curriculum Accordion ================= */
.ins-accordion-item {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    background: #fff;
}

.ins-accordion-header {
    background: #fdfdfd;
    padding: 15px 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: 0.2s;
}

.ins-accordion-header:hover {
    background: #f5f5f5;
}

.ins-accordion-header .section-name {
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ins-accordion-header .toggle-icon {
    transition: transform 0.3s;
    font-size: 1.2rem;
    color: var(--gold-primary);
}

/* حالة الفتح (سنضيف كلاس JS لاحقاً) */
.ins-accordion-item.open .toggle-icon {
    transform: rotate(180deg);
}

.lesson-count {
    font-size: 0.85rem;
    color: #888;
    background: #eee;
    padding: 2px 10px;
    border-radius: 20px;
}

.ins-accordion-body {
    display: none; /* مخفي افتراضياً */
    border-top: 1px solid var(--border-color);
    background: #fff;
}

.ins-accordion-item.open .ins-accordion-body {
    display: block;
}

.ins-accordion-body ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ins-accordion-body li {
    padding: 12px 20px;
    border-bottom: 1px solid #f9f9f9;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #555;
    font-size: 0.95rem;
    transition: 0.2s;
}

.ins-accordion-body li:last-child {
    border-bottom: none;
}

.ins-accordion-body li:hover {
    background: #fafafa;
    color: var(--gold-primary);
    padding-right: 25px; /* حركة بسيطة */
}

.ins-accordion-body li .icon {
    font-size: 0.8rem;
    color: #ccc;
}

.ins-accordion-body li .lock {
    margin-right: auto; /* دفع القفل لليسار */
    font-size: 1rem;
    color: #ddd;
}


/* ================= Instructor Card ================= */
.ins-instructor-card {
    display: flex;
    align-items: center;
    gap: 25px;
    background: #fdfdfd;
    padding: 25px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.inst-avatar img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.inst-info h4 {
    margin: 0 0 5px;
    font-size: 1.2rem;
    color: var(--text-main);
}

.inst-job {
    color: var(--gold-primary);
    font-size: 0.9rem;
    font-weight: 700;
    display: block;
    margin-bottom: 10px;
}

.inst-bio {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .ins-instructor-card {
        flex-direction: column;
        text-align: center;
    }
}
/* ================= Course Cards Grid ================= */
.ins-courses-grid {
    display: grid;
    gap: 30px;
}
.ins-courses-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.ins-courses-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

/* Card Design */
.ins-course-card {
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
    display: flex;
    flex-direction: column;
}

.ins-course-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
    border-color: var(--gold-primary);
}

.card-thumb {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.ins-course-card:hover .card-thumb img {
    transform: scale(1.1);
}

.card-level {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    backdrop-filter: blur(5px);
}

.card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 0.85rem;
    color: #777;
}

.cat-badge {
    background: #f4f4f4;
    padding: 3px 10px;
    border-radius: 20px;
    color: #555;
    transition: 0.3s;
}
.ins-course-card:hover .cat-badge {
    background: var(--gold-primary);
    color: #fff;
}

.card-title {
    font-size: 1.1rem;
    margin: 0 0 15px;
    line-height: 1.5;
}

.card-title a {
    color: var(--text-main);
    text-decoration: none;
    transition: 0.3s;
}
.ins-course-card:hover .card-title a {
    color: var(--gold-primary);
}

.card-instructor {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #666;
}
.card-instructor img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
}

.card-footer {
    margin-top: auto;
    border-top: 1px solid #f0f0f0;
    padding-top: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-price del {
    color: #ccc;
    font-size: 0.9rem;
    margin-left: 5px;
}
.card-price .current {
    font-weight: 800;
    color: var(--text-main);
    font-size: 1.1rem;
}

.card-btn {
    color: var(--gold-primary);
    font-weight: 700;
    text-decoration: none;
    font-size: 0.9rem;
}
.card-btn:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 992px) {
    .ins-courses-grid.cols-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
    .ins-courses-grid.cols-3 { grid-template-columns: 1fr; }
}

/* ================= Archive Page Styles ================= */

/* Header */
.ins-archive-header {
    background: #111;
    color: #fff;
    padding: 60px 0;
    text-align: center;
    margin-bottom: 50px;
}
.ins-archive-header h1 {
    font-size: 2.5rem;
    color: var(--gold-primary);
    margin-bottom: 10px;
}

/* Layout */
.ins-archive-layout {
    display: grid;
    grid-template-columns: 300px 1fr; /* السايدبار 300 بكسل والباقي للمحتوى */
    gap: 40px;
    padding-bottom: 80px;
}

/* Sidebar & Filters */
.ins-archive-sidebar {
    /* Sticky Magic */
    position: sticky;
    top: 100px;
    height: fit-content;
}

.ins-filter-box {
    background: #fff;
    border: 1px solid var(--border-color);
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.ins-filter-box h3 {
    margin-top: 0;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--gold-primary);
    margin-bottom: 20px;
}

.filter-group {
    margin-bottom: 20px;
}

.filter-group label {
    display: block;
    font-weight: 700;
    margin-bottom: 8px;
    color: #333;
}

.filter-group input,
.filter-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #f9f9f9;
    font-family: 'Cairo';
}

.ins-btn-filter {
    width: 100%;
    background: var(--gold-primary);
    color: #000;
    border: none;
    padding: 12px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.3s;
}

.ins-btn-filter:hover {
    background: var(--gold-hover);
}

.reset-link {
    display: block;
    text-align: center;
    margin-top: 10px;
    color: #888;
    text-decoration: none;
    font-size: 0.9rem;
}

/* Pagination */
.ins-pagination {
    margin-top: 50px;
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.ins-pagination span, 
.ins-pagination a {
    display: inline-block;
    padding: 10px 18px;
    background: #fff;
    border: 1px solid #ddd;
    color: #333;
    text-decoration: none;
    border-radius: 6px;
    transition: 0.3s;
}

.ins-pagination .current,
.ins-pagination a:hover {
    background: var(--gold-primary);
    color: #fff;
    border-color: var(--gold-primary);
}

/* Mobile Responsive */
@media (max-width: 992px) {
    .ins-archive-layout {
        grid-template-columns: 1fr; /* عمود واحد في الموبايل */
    }
    .ins-archive-sidebar {
        position: static; /* إلغاء التثبيت */
        margin-bottom: 30px;
    }
}
---

### الخطوة 4: تصميم بطاقات الأقسام (`assets/css/lms-front.css`)

أضف هذا التنسيق لملف الـ CSS ليظهر بشكل فخم (صورة مع طبقة سوداء شفافة، وعند المرور تظهر حواف ذهبية).

```css
/* ================= Categories Grid ================= */
.ins-categories-wrapper {
    padding: 20px 0;
}

.ins-cat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 أعمدة */
    gap: 20px;
}

.ins-cat-card {
    position: relative;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    display: block;
    text-decoration: none;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.ins-cat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(212, 175, 55, 0.2); /* ظل ذهبي خفيف */
}

.cat-img {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: 0.5s;
}

.ins-cat-card:hover .cat-img {
    transform: scale(1.1);
}

.cat-img .overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), rgba(0,0,0,0.2));
    transition: 0.3s;
}

.ins-cat-card:hover .cat-img .overlay {
    background: linear-gradient(to top, rgba(212, 175, 55, 0.8), rgba(0,0,0,0.2)); /* تدرج ذهبي عند المرور */
}

.cat-info {
    position: absolute;
    bottom: 20px;
    right: 20px;
    z-index: 2;
    color: #fff;
}

.cat-info h3 {
    margin: 0 0 5px;
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
}

.cat-info .count {
    font-size: 0.9rem;
    background: rgba(255,255,255,0.2);
    padding: 3px 10px;
    border-radius: 20px;
}

/* Responsive */
@media (max-width: 992px) {
    .ins-cat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 500px) {
    .ins-cat-grid { grid-template-columns: 1fr; }
}

/* ================= Enrollment Modal ================= */
.ins-modal {
    display: none; /* مخفي افتراضياً */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8); /* خلفية سوداء شفافة */
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s;
}

.ins-modal-content {
    background-color: #fff;
    margin: 10% auto; /* 10% من الأعلى */
    padding: 0;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    position: relative;
    overflow: hidden;
    animation: slideUp 0.4s;
}

/* زر الإغلاق */
.ins-close-modal {
    color: #aaa;
    float: left; /* لأن الاتجاه RTL */
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    left: 20px;
    top: 10px;
    cursor: pointer;
    z-index: 10;
}
.ins-close-modal:hover { color: #000; }

.modal-header {
    background: #111;
    color: #fff;
    padding: 30px;
    text-align: center;
}
.modal-header h3 { margin: 0; color: var(--gold-primary); }
.modal-header p { margin: 5px 0 0; color: #ccc; font-size: 0.9rem; }

.modal-body { padding: 30px; }

/* ملخص الدورة داخل المودال */
.course-summary {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #f9f9f9;
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #eee;
}
.course-summary .thumb img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
}
.course-summary h4 { margin: 0; font-size: 1rem; }
.course-summary .price { 
    color: var(--gold-primary); 
    font-weight: 800; 
    font-size: 1.1rem; 
    display: block; 
    margin-top: 5px; 
}

.divider { border: 0; border-top: 1px dashed #ddd; margin: 20px 0; }

/* زر الواتساب */
.ins-btn-whatsapp {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background-color: #25D366;
    color: #fff;
    text-decoration: none;
    padding: 15px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: 0.3s;
}
.ins-btn-whatsapp:hover {
    background-color: #1ebc57;
    box-shadow: 0 5px 15px rgba(37, 211, 102, 0.3);
    color: #fff;
}

/* Animations */
@keyframes fadeIn { from {opacity: 0;} to {opacity: 1;} }
@keyframes slideUp { from {transform: translateY(50px);} to {transform: translateY(0);} }

/* ================= Breadcrumbs ================= */
.ins-breadcrumbs {
    font-size: 0.9rem;
    color: #bbb; /* لون رمادي فاتح لأنه على خلفية سوداء */
    margin-bottom: 10px;
    font-weight: 600;
}

.ins-breadcrumbs a {
    color: #eee;
    text-decoration: none;
    transition: 0.2s;
}

.ins-breadcrumbs a:hover {
    color: var(--gold-primary); /* تلوين ذهبي عند المرور */
}

.ins-breadcrumbs .ins-sep {
    margin: 0 10px;
    color: var(--gold-primary); /* الفاصل لونه ذهبي */
    font-size: 0.8rem;
}

.ins-breadcrumbs .current {
    color: var(--gold-primary); /* الصفحة الحالية لونها ذهبي */
    opacity: 0.8;
}

/* تعديل للهيدر ليحتوي المسار بشكل جيد */
.ins-course-header,
.ins-archive-header {
    padding-top: 40px; /* تقليل الحشوة العلوية قليلاً */
}
/* ================= VIDEO MODAL FIX ================= */

/* 1. إجبار النافذة تكون فوق كل شيء */
.ins-modal {
    z-index: 9999999 !important; /* رقم عالي جداً */
    background-color: rgba(0,0,0,0.9) !important; /* تغميق الخلفية */
}

/* 2. ضبط صندوق الفيديو */
.ins-modal-content.video-content {
    background: #000;
    width: 90%;
    max-width: 900px; /* عرض مناسب للشاشات */
    height: auto;
    border: 1px solid #333;
    padding: 0 !important; /* إزالة الحواف الزائدة */
    display: block !important; /* ضمان الظهور */
    visibility: visible !important;
}

/* 3. زر الإغلاق يكون واضح */
.ins-close-video {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000000;
    text-shadow: 0 2px 5px #000;
}

/* 4. جعل الفيديو متجاوب (Responsive 16:9) */
.video-container-responsive {
    position: relative;
    padding-bottom: 56.25%; /* النسبة القياسية لليوتيوب */
    height: 0;
    overflow: hidden;
    background: #000;
}

.video-container-responsive iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    border: none;
}