/* LMS Premium Styles Refined */
.course_hero_section {
    position: relative;
    overflow: hidden;
}

.course_hero_content .badge {
    font-size: 13px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.course_hero_content .badge a {
    color: white;
}

.course_hero_content h1 {
    line-height: 1.2;
    color: #1e293b;
}

.course_meta_wrapper .meta_item {
    font-size: 15px;
    font-weight: 500;
}

.author_avatar img {
    border: 2px solid #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.course_feature_img img {
    transition: transform 0.5s ease;
}

.course_feature_img:hover img {
    transform: scale(1.02);
}

/* Tabs */
.course_info_tabs .nav-pills .nav-link {
    color: #64748b;
    font-weight: 600;
    padding: 12px 25px;
    border-radius: 50px;
    font-size: 16px;
    margin-right: 15px;
    background: #f1f5f9;
    transition: all 0.3s ease;
}

.course_info_tabs .nav-pills .nav-link.active,
.course_info_tabs .nav-pills .nav-link:hover {
    background-color: var(--colorPrimary);
    color: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Accordion */
.accordion-item {
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.accordion-item:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05) !important;
}

.accordion-button {
    padding: 20px 25px;
    font-size: 18px;
    background-color: #fff !important;
    color: #1e293b !important;
    box-shadow: none !important;
}

.accordion-button:not(.collapsed) {
    background-color: #f8fafc !important;
    color: var(--colorPrimary) !important;
}

.accordion-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2364748b'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.accordion-button:not(.collapsed)::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%234f46e5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.list-group-item {
    border-color: #f1f5f9;
}

.list-group-item.hover-bg-light:hover {
    background-color: #f8fafc;
}

.stretched-link::after {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    content: "";
}

/* Sidebar Card */
.course_sidebar_card {
    transition: transform 0.3s ease;
}

.price_box h2 {
    color: #0f172a;
    letter-spacing: -1px;
}

.course_specs .list-unstyled li {
    font-size: 15px;
}

.course_specs i {
    width: 20px;
    text-align: center;
}

/* Progress Bar */
.progress {
    background-color: #e2e8f0;
    border-radius: 50px;
    overflow: hidden;
}

.progress-bar {
    background: linear-gradient(90deg, var(--colorPrimary) 0%, #6366f1 100%) !important;
    border-radius: 50px;
}

/* Quiz Styles */
.quiz_container {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.06);
}

.question_item {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #f1f5f9;
}

.question_item h4 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    color: #1e293b;
}

.answer_item {
    padding: 15px 20px;
    background: #f8fafc;
    border: 2px solid #f1f5f9;
    border-radius: 12px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.answer_item:hover {
    border-color: var(--colorPrimary);
    background: #fdf2f8;
}

.answer_item input {
    margin-right: 15px;
    width: 20px;
    height: 20px;
}

.quiz_header {
    margin-bottom: 30px;
}

.quiz_meta {
    font-size: 14px;
    color: #64748b;
}

/* Lesson Sidebar Enhancements */
.lesson_sidebar {
    position: sticky;
    top: 100px;
}

.lesson_sidebar_item a {
    color: #1a1a1a;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.lesson_sidebar_item a:hover {
    background: #f8fafc;
    color: var(--colorPrimary);
}

.lesson_sidebar_item.active a {
    background: #e0e7ff;
    border-color: var(--colorPrimary);
    color: var(--colorPrimary);
    font-weight: 600;
}

.letter-spacing-1 {
    letter-spacing: 1px;
}

.text-wrap {
    white-space: normal;
}

/* Course Filter */
.course_filter_btn {
    display: inline-block;
    padding: 10px 25px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 50px;
    color: #64748b;
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
}

.course_filter_btn:hover {
    background: #f8fafc;
    color: var(--colorPrimary);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.05);
}

.course_filter_btn.active {
    background: var(--colorPrimary) !important;
    color: #fff !important;
    border-color: var(--colorPrimary) !important;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15) !important;
}

/* Reduced Button Padding for Enroll/Action Buttons */
.action_box .btn-lg {
    padding-top: 12px;
    padding-bottom: 12px;
}

/* Fix for Double Titlebar: Hide Theme Breadcrumb on LMS Pages */
body.post-type-archive-course .breadcrumb_area,
body.tax-course_cat .breadcrumb_area,
body.single-course .breadcrumb_area,
body.single-lesson .breadcrumb_area,
body.single-quiz .breadcrumb_area {
    display: none !important;
}

/* Improved Spacing for Course Grid Items */
.course_item .course_badge,
.course_item .course_price {
    margin: 24px !important;
    /* Align with p-4 (1.5rem) container padding */
}


.course_item .category {
    margin-bottom: 15px !important;
    display: inline-block;
}

/* Fix for missing thumbnails: Reserve space for badges */
.course_item .course_img {
    min-height: 240px;
    background-color: #f8fafc;
    width: 100%;
}

/* Stylish Category Label */
.course_item .category a {
    background: #e0e7ff;
    /* Light indigo background */
    color: var(--colorPrimary);
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.course_item .category a:hover {
    background: var(--colorPrimary);
    color: #fff;
    box-shadow: 0 4px 10px rgba(99, 102, 241, 0.3);
}

/* Stylish Title Effects */
.course_item h3 a {
    text-decoration: none;
    color: #1e293b;
    background-image: linear-gradient(var(--colorPrimary), var(--colorPrimary));
    background-size: 0% 2px;
    background-repeat: no-repeat;
    background-position: left bottom;
    transition: background-size 0.3s ease, color 0.3s ease;
    padding-bottom: 2px;
}

.course_item h3 a:hover {
    color: var(--colorPrimary);
    background-size: 100% 2px;
}