/* استایل‌های فرانت‌اند */
.ccc-curriculum-display {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    margin: 30px 0;
    direction: rtl;
}

.ccc-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px 30px;
    border-radius: 12px 12px 0 0;
    margin-bottom: 0;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

.ccc-header h3 {
    margin: 0 0 15px 0;
    font-size: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
}

.ccc-stats {
    display: flex;
    gap: 25px;
    font-size: 15px;
    opacity: 0.95;
    flex-wrap: wrap;
}

.ccc-stats span {
    background: rgba(255, 255, 255, 0.15);
    padding: 6px 15px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

.ccc-chapters-list {
    border: 1px solid #e9ecef;
    border-top: none;
    border-radius: 0 0 12px 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.ccc-chapter-item {
    border-bottom: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.ccc-chapter-item:last-child {
    border-bottom: none;
}

.ccc-chapter-item.ccc-hover {
    background: #fafafa;
}

.ccc-chapter-item.ccc-active {
    background: #f8f9fa;
}

.ccc-chapter-title {
    background: #f8f9fa;
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.ccc-chapter-title:hover {
    background: #e9ecef;
}

.ccc-chapter-title.ccc-active,
.ccc-chapter-title:hover {
    background: #e3f2fd;
}

.ccc-chapter-title h4 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    flex: 1;
}

.ccc-chapter-number {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    color: white;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    min-width: 90px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(118, 75, 162, 0.3);
}

.ccc-chapter-name {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    flex: 1;
}

.ccc-toggle-description {
    background: #6c757d;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.ccc-toggle-description:hover {
    background: #545b62;
    transform: scale(1.1);
}

.ccc-video-count {
    background: #28a745;
    color: white;
    padding: 8px 18px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 700;
    min-width: 90px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
    margin-right: 15px;
}

.ccc-chapter-description {
    padding: 20px 25px;
    background: #f1f3f4;
    border-top: 1px solid #dee2e6;
    color: #555;
    font-size: 15px;
    line-height: 1.7;
    border-bottom: 1px solid #dee2e6;
}

.ccc-videos-list {
    padding: 0;
    background: white;
    overflow: hidden;
}

.ccc-video-item {
    padding: 18px 25px;
    border-bottom: 1px solid #f8f9fa;
    transition: all 0.3s ease;
    position: relative;
}

.ccc-video-item:last-child {
    border-bottom: none;
}

.ccc-video-item:hover {
    background: #f8f9fa;
    padding-right: 30px;
}

.ccc-video-info {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.ccc-video-number {
    background: #6c757d;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    flex-shrink: 0;
}

.ccc-video-name {
    flex: 1;
    font-weight: 500;
    color: #2c3e50;
    font-size: 16px;
}

.ccc-video-duration {
    background: #ffc107;
    color: #333;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.ccc-video-description {
    margin-top: 12px;
    padding: 15px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    border-right: 4px solid #dee2e6;
    margin-right: 45px;
}

.ccc-no-curriculum {
    text-align: center;
    padding: 40px;
    background: #f8f9fa;
    border-radius: 12px;
    color: #6c757d;
    font-size: 16px;
    border: 2px dashed #dee2e6;
}

/* انیمیشن‌ها */
.ccc-chapter-item {
    animation: fadeInUp 0.5s ease-out;
}

.ccc-video-item {
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* حالت موبایل */
@media (max-width: 768px) {
    .ccc-header {
        padding: 20px;
    }
    
    .ccc-header h3 {
        font-size: 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .ccc-stats {
        flex-direction: column;
        gap: 10px;
    }
    
    .ccc-stats span {
        width: fit-content;
    }
    
    .ccc-chapter-title {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 15px 20px;
    }
    
    .ccc-chapter-title h4 {
        width: 100%;
    }
    
    .ccc-video-count {
        margin-right: 0;
        align-self: flex-start;
    }
    
    .ccc-video-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .ccc-video-duration {
        align-self: flex-start;
    }
    
    .ccc-video-description {
        margin-right: 0;
        margin-top: 15px;
    }
}

/* حالت تاریک */
@media (prefers-color-scheme: dark) {
    .ccc-curriculum-display {
        color-scheme: dark;
    }
    
    .ccc-header {
        background: linear-gradient(135deg, #434343 0%, #000000 100%);
    }
    
    .ccc-chapters-list {
        border-color: #444;
        background: #1e1e1e;
    }
    
    .ccc-chapter-item {
        border-bottom-color: #444;
    }
    
    .ccc-chapter-title {
        background: #2d2d2d;
        color: #fff;
    }
    
    .ccc-chapter-title:hover {
        background: #3d3d3d;
    }
    
    .ccc-chapter-name {
        color: #fff;
    }
    
    .ccc-videos-list {
        background: #1e1e1e;
    }
    
    .ccc-video-item {
        border-bottom-color: #333;
        color: #ddd;
    }
    
    .ccc-video-item:hover {
        background: #2d2d2d;
    }
    
    .ccc-video-name {
        color: #fff;
    }
    
    .ccc-video-description {
        background: #2d2d2d;
        color: #bbb;
        border-right-color: #444;
    }
    
    .ccc-chapter-description {
        background: #2d2d2d;
        color: #ccc;
        border-color: #444;
    }
}