/*
 * Single Course Page Styles
 * For: /tutor/single-course.php
 */

/* === Progress Bar in Sidebar === */
.custom-course-progress-bar {
    margin: 15px 0;
}
.custom-course-progress-bar-track {
    width: 100%;
    height: 15px;
    background: #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}
.custom-course-progress-bar-fill {
    height: 100%;
    background: #3498DB;
    border-radius: 4px;
    transition: width 0.3s ease;
}
/* === Main Wrapper === */
.custom-course-wrapper {
    display: flex;
    min-height: 100vh;
    background: #f5f5f5;
}
/* === Left Sidebar === */
.custom-course-sidebar {
    width: 25%;
    min-width: 250px;
    background: #f8f9fa;
    border-right: 1px solid #e0e0e0;
    padding: 0;
}
.custom-course-sidebar-inner {
    padding: 30px 20px;
    position: sticky;
    top: 0;
}
/* Course Thumbnail */
.custom-course-thumb {
    text-align: center;
    margin-bottom: 20px;
}
.custom-course-thumb img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.custom-course-thumb-placeholder {
    width: 150px;
    height: 100px;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    border-radius: 4px;
    font-size: 32px;
    color: #999;
}
/* Course Title */
.custom-course-sidebar-title {
    font-size: 24px;
    font-weight: 700;
    color: #2C3E50;
    line-height: 1.4;
    margin: 0 0 15px 0;
    padding: 0;
}
/* Divider */
.custom-course-sidebar-divider {
    height: 1px;
    background: #e0e0e0;
    margin: 12px 0;
}
/* Progress Text */
.custom-course-progress-text {
    text-align: center;
    padding: 5px 0;
    margin-bottom: 5px;
}
.custom-course-progress-text span {
    font-size: 12px;
    font-weight: 600;
    color: rgba(0, 104, 136);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.custom-course-retake-action {
    margin: 12px 0 6px;
}
.custom-course-retake-action .tutor-course-retake-button {
    width: 100%;
}
.custom-course-enroll-status {
    display: grid;
    gap: 10px;
    margin-top: 16px;
    color: #6b7280;
    font-size: 13px;
    font-weight: 700;
    text-align: center;
}
.custom-course-enroll-form {
    margin: 0;
}
/* Sidebar Navigation */
.custom-course-sidebar-nav {
    margin-top: 5px;
}
.custom-course-nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    color: #3498DB !important;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none !important;
    border-radius: 4px;
    transition: background 0.2s;
    border-bottom: 1px solid #e0e0e0;
}
.custom-course-nav-link:hover,
.custom-course-nav-link.active {
    background: #e6f7fa;
}
.custom-nav-icon {
    display: flex;
    align-items: center;
    color: #3498DB;
}
.custom-nav-icon svg {
    width: 16px;
    height: 16px;
}
/* === Main Content === */
.custom-course-main {
    width: 75%;
    padding: 0;
    overflow-x: hidden;
    background: #fff;
}
.custom-course-main-inner {
    max-width: 100%;
    padding: 30px 30px 60px 30px;
}
/* Course Curriculum Title */
.custom-course-curriculum-title {
    font-size: 32px;
    font-weight: 700;
    color: #2C3E50;
    margin: 0 0 30px 0;
    padding: 0;
    text-align: left;
    line-height: 1.3;
}
/* === Progress Bar === */
.custom-course-progress-bar-wrapper {
    width: 100%;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 30px;
}
.custom-progress-segment {
    height: 100%;
    width: 100%;
    position: relative;
}
.custom-progress-segment-fill {
    height: 100%;
    background: #3498DB;
    border-radius: 4px;
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    overflow: visible;
}
/* === Course Topics === */
.custom-course-topics-wrapper {
    margin-top: 10px;
}
.custom-course-topic-block {
    margin-bottom: 20px;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #e0e0e0;
}
/* Topic Header */
.custom-topic-header {
    background: #e8e8e8;
    padding: 12px 20px;
}
.custom-topic-title {
    font-size: 20px;
    font-weight: 600;
    color: #2C3E50 !important;
    margin: 0;
    padding: 0;
    font-weight: bold;
    line-height: 24px;
}
/* Lesson Rows */
.custom-topic-lessons {
    background: transparent;
    padding: 0px 0px;
}
.custom-lesson-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    border-bottom: 1px solid #e0e0e0;
    transition: background 0.15s;
    /* background: rgba(0, 130, 170, 0.3); */
}
.custom-lesson-row:last-child {
    border-bottom: none;
}
.custom-lesson-row:hover {
    background: rgba(0, 130, 170, 0.5);
}
.custom-lesson-row.completed {
    background: transparent;
}
.custom-lesson-row.completed:hover {
    background: rgba(0, 130, 170, 0.5);
}
.custom-lesson-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}
.custom-lesson-info-icon {
    color: #666;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.custom-lesson-file-icon {
    color: #666;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.custom-lesson-title {
    font-size: 17px;
    color: #2C3E50;
    font-weight: 400;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.custom-lesson-right {
    flex-shrink: 0;
    margin-left: 15px;
}
/* Start Button */
.custom-lesson-start-btn {
    display: inline-block;
    color: #fff !important;
    font-size: 14px;
    padding: 8px 16px;
    text-decoration: none !important;
    text-transform: capitalize;
    transition: background 0.2s;
    background: rgba(0, 130, 170);
}
.custom-lesson-start-btn:hover {
    background: rgba(0, 130, 170, 0.8);
    color: #fff !important;
}
/* Enroll Button */
.custom-lesson-enroll-btn {
    display: inline-block;
    background: #28a745;
    color: #fff !important;
    font-size: 14px;
    font-weight: 700;
    padding: 8px 16px;
    border-radius: 20px;
    text-decoration: none !important;
    text-transform: capitalize;
    transition: background 0.2s;
}
.custom-lesson-enroll-btn:hover {
    background: #218838;
    color: #fff !important;
}
.custom-lesson-locked {
    color: #999;
    display: flex;
    align-items: center;
}
/* === Hide default TutorLMS elements === */
/* .single-courses .tutor-wrap-parent,
.single-courses .tutor-course-details-page {
    display: none !important;
} */

/* === Responsive === */
@media (max-width: 768px) {
    .custom-course-wrapper {
        flex-direction: column;
    }
    .custom-course-sidebar {
        width: 100%;
        min-width: 100%;
        border-right: none;
        border-bottom: 1px solid #e0e0e0;
    }
    .custom-course-sidebar-inner {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 15px;
        padding: 20px;
    }
    .custom-course-thumb {
        margin-bottom: 0;
    }
    .custom-course-thumb img {
        max-width: 80px;
    }
    .custom-course-sidebar-title {
        flex: 1;
        margin-bottom: 0;
    }
    .custom-course-sidebar-divider {
        display: none;
    }
    .custom-course-progress-text {
        width: 100%;
        text-align: left;
    }
    .custom-course-sidebar-nav {
        width: 100%;
    }
    .custom-course-main {
        width: 100%;
    }
    .custom-course-main-inner {
        padding: 20px 15px 40px;
    }
    .custom-course-curriculum-title {
        font-size: 22px;
    }
    .custom-course-progress-bar-wrapper {
        height: 28px;
    }
    .custom-progress-segment-fill {
        font-size: 10px;
        padding: 0 8px;
    }
}
