
/* 返回按钮样式 */
.back-to-learning-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background-color: var(--primary);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(44, 111, 187, 0.2);
}

.back-to-learning-btn:hover {
    background-color: #2a6fa8;
    color: white;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(44, 111, 187, 0.3);
}

.back-to-learning-btn i {
    transition: transform 0.3s ease;
}

.back-to-learning-btn:hover i {
    transform: translateX(-3px);
}

/* 资源页面样式 */
#learning-resources-module .page-title {
font-size: 1.8rem;
color: var(--primary);
font-weight: 600;
}

.search-box {
width: 300px;
}

.input-group {
display: flex;
}

.input-group .form-control {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-right: none;
}

.input-group .btn {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.filter-tags {
display: flex;
gap: 10px;
flex-wrap: wrap;
}

.filter-tags .btn.active {
    background-color: var(--primary);
    color: white;
}

/* PDF目录样式 */
.pdf-directory {
border: 1px solid var(--light-gray);
border-radius: var(--border-radius);
overflow: hidden;
}

.pdf-item {
border-bottom: 1px solid var(--light-gray);
}

.pdf-item:last-child {
    border-bottom: none;
}

.pdf-header {
padding: 15px 20px;
background-color: rgba(44, 111, 187, 0.05);
cursor: pointer;
transition: background-color 0.2s;
}

.pdf-header:hover {
    background-color: rgba(44, 111, 187, 0.1);
}

.pdf-header i.fa-folder {
    color: var(--warning);
    font-size: 1.2rem;
}

.pdf-title {
font-size: 1.1rem;
font-weight: 500;
margin: 0;
}

.pdf-content {
padding: 0 20px;
max-height: 0;
overflow: hidden;
transition: max-height 0.3s ease, padding 0.3s ease;
}

.pdf-item.expanded .pdf-content {
padding: 20px;
max-height: 2000px;
}

.pdf-file {
margin-bottom: 15px;
padding-bottom: 15px;
border-bottom: 1px dashed var(--light-gray);
}

.pdf-file:last-child {
    border-bottom: none;
}

.pdf-filename {
font-weight: 500;
}

.pdf-description {
font-size: 0.9rem;
line-height: 1.4;
}

/* 视频网格样式 */
.video-grid {
display: grid;
grid-template-columns: repeat(5, 1fr);
gap: 20px;
}

.video-card {
background-color: white;
border-radius: var(--border-radius);
overflow: hidden;
box-shadow: var(--box-shadow);
transition: all 0.3s ease;
cursor: pointer;
}

.video-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.video-thumbnail {
position: relative;
width: 100%;
height: 140px;
overflow: hidden;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-overlay {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-color: rgba(0, 0, 0, 0.3);
display: flex;
align-items: center;
justify-content: center;
opacity: 0;
transition: opacity 0.3s;
}

.video-card:hover .video-overlay {
opacity: 1;
}

.video-play-btn {
width: 50px;
height: 50px;
border-radius: 50%;
background-color: var(--primary);
color: white;
border: none;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
font-size: 1.2rem;
transition: transform 0.3s;
}

.video-play-btn:hover {
    transform: scale(1.1);
    background-color: var(--primary-dark);
}

.video-duration {
position: absolute;
bottom: 10px;
right: 10px;
background-color: rgba(0, 0, 0, 0.7);
color: white;
padding: 2px 6px;
border-radius: 3px;
font-size: 0.8rem;
}

.video-info {
padding: 15px;
}

.video-title {
font-size: 1rem;
font-weight: 600;
margin-bottom: 8px;
color: var(--dark);
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
}

.video-meta {
display: flex;
justify-content: space-between;
font-size: 0.8rem;
color: var(--gray);
}

/* 分页样式 */
.pagination {
display: flex;
list-style: none;
margin: 0;
padding: 0;
}

.pagination .page-item {
    margin: 0 2px;
}

.pagination .page-link {
    display: block;
    padding: 6px 12px;
    border: 1px solid var(--light-gray);
    background-color: white;
    color: var(--primary);
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.2s;
}

    .pagination .page-link:hover {
        background-color: var(--light);
        border-color: var(--primary);
    }

.pagination .page-item.active .page-link {
    background-color: var(--primary);
    border-color: var(--primary);
    color: white;
}

.pagination .page-item.disabled .page-link {
    color: var(--gray);
    cursor: not-allowed;
    background-color: var(--light);
}

.pagination.justify-center {
    justify-content: center;
}

/* 模态框样式 */
.modal-overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-color: rgba(0, 0, 0, 0.7);
display: flex;
align-items: center;
justify-content: center;
z-index: 1000;
animation: fadeIn 0.3s;
}

@keyframes fadeIn {
from {
    opacity: 0;
}

to {
    opacity: 1;
}
}

.modal-content {
background-color: white;
border-radius: var(--border-radius);
box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
max-width: 800px;
width: 90%;
max-height: 90%;
overflow: hidden;
}

.modal-header {
padding: 15px 20px;
border-bottom: 1px solid var(--light-gray);
display: flex;
justify-content: space-between;
align-items: center;
}

.modal-header h5 {
    margin: 0;
    font-weight: 600;
}

.modal-close {
background: none;
border: none;
font-size: 1.5rem;
cursor: pointer;
color: var(--gray);
transition: color 0.2s;
}

.modal-close:hover {
    color: var(--dark);
}

.modal-body {
padding: 20px;
}

.video-wrapper {
position: relative;
padding-bottom: 56.25%; /* 16:9 */
height: 0;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}


 

/* 响应式调整 */
@media (max-width: 768px) {
    .accordion-header {
        padding: 14px 20px;
        font-size: 0.95rem;
    }

    .grade-header {
        padding-left: 20px;
        font-size: 1rem;
    }

    .unit-header {
        padding-left: 30px;
    }

    .chapter-header {
        padding-left: 40px;
        font-size: 0.9rem;
    }

    .chapter-body.active {
        padding-left: 40px;
    }

    .chapter-actions {
        margin-right: 20px;
    }

    .btn-icon {
        padding: 3px 6px;
    }
}

/* 响应式调整 */
@media (max-width: 1200px) {
.video-grid {
    grid-template-columns: repeat(4, 1fr);
}
}

@media (max-width: 992px) {
.video-grid {
    grid-template-columns: repeat(3, 1fr);
}
}

@media (max-width: 768px) {
.search-box {
    width: 100%;
    margin-top: 15px;
}

#learning-resources-module .d-flex {
    flex-direction: column;
    align-items: flex-start;
}

.video-grid {
    grid-template-columns: repeat(2, 1fr);
}
}

@media (max-width: 576px) {
.video-grid {
    grid-template-columns: 1fr;
}

.pdf-actions {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 10px;
}

    .pdf-actions .btn {
        width: 100%;
    }
}



/*手风琴基础样式*/
/*.accordion {
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.accordion-item {
    border-bottom: 1px solid var(--light-gray);
    background-color: white;
}

    .accordion-item:last-child {
        border-bottom: none;
    }

.accordion-header {
    width: 100%;
    text-align: left;
    border: none;
    padding: 18px 24px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--dark);
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
}

    .accordion-header:hover {
        background-color: rgba(44, 111, 187, 0.05);
    }

    .accordion-header .triangle {
        position: absolute;
        right: 24px;
        top: 50%;
        transform: translateY(-50%) rotate(0deg);
        transition: transform 0.3s ease;
        color: var(--gray);
        font-size: 0.8rem;
    }

    .accordion-header.open .triangle {
        transform: translateY(-50%) rotate(180deg);
    }

.accordion-body {
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background-color: white;
}

.accordion-item.active .accordion-body {
    max-height: 2000px;
}*/

/*学段级别样式*/
/*.grade-item {
    border-left: 4px solid #0088ff;
}

    .grade-item[data-grade="middle"] {
        border-left-color: #ccc;
    }

    .grade-item[data-grade="high"] {
        border-left-color: #0088ff;
    }

.grade-header {
    background-color: rgba(44, 111, 187, 0.08);
    font-size: 1.1rem;
    font-weight: 600;
}

    .grade-header.open {
        background-color: rgba(44, 111, 187, 0.12);
    }

.grade-body {
    padding: 0 !important;
}

    .grade-body.active {
        padding: 0 !important;
    }*/

/*单元级别样式*/
/*.unit-accordion {
    border: none;
    border-radius: 0;
    margin: 0;
}

.unit-item {
    border-bottom: 1px solid var(--light-gray);
    border-left: none;
}

    .unit-item:last-child {
        border-bottom: none;
    }

.unit-header {
    background-color: rgba(44, 111, 187, 0.04);
    padding-left: 40px;
    font-weight: 500;
}

.unit-body {
    padding: 0 !important;
}

    .unit-body.active {
        padding: 0 !important;
    }*/

/*章节级别样式*/
/*.chapter-accordion {
    border: none;
    border-radius: 0;
    margin: 0;
}

.chapter-item {
    border-bottom: 1px dashed var(--light-gray);
    border-left: none;
}

    .chapter-item:last-child {
        border-bottom: none;
    }

.chapter-header {
    padding-left: 60px;
    font-size: 0.95rem;
    background-color: rgba(44, 111, 187, 0.02);
}

    .chapter-header:hover {
        background-color: rgba(44, 111, 187, 0.05);
    }

.chapter-body {
    padding-left: 60px;
    background-color: white;
}

    .chapter-body.active {
        padding: 20px 20px 20px 60px;
    }*/

/*章节内容样式*/
/*.chapter-desc {
    color: var(--gray);
    line-height: 1.6;
    margin-bottom: 15px;
}

.chapter-info {
    display: flex;
    gap: 20px;
    font-size: 0.9rem;
    color: var(--gray);
}

.file-info, .update-info {
    display: flex;
    align-items: center;
}

    .file-size, .update-info span {
        margin-left: 4px;
    }*/

/*按钮图标样式*/
/*.chapter-actions {
    display: flex;
    gap: 10px;
    margin-right: 30px;
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .btn-icon:hover {
        background-color: rgba(0, 0, 0, 0.05);
    }

    .btn-icon i.text-gray {
        color: var(--gray);
    }

    .btn-icon:hover i.text-gray {
        color: var(--primary);
    }

.download-btn {
    text-decoration: none;
}*/

/*空状态提示*/
/*.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--gray);
    font-style: italic;
}*/

/* 单元手风琴样式 */
/*.unit-accordion {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 2rem;
}*/

/* 单元头部 */
/*.unit-header {
    padding: 1.25rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: none;
    border-bottom: 1px solid #dee2e6;
    width: 100%;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

    .unit-header:hover {
        background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
    }

.unit-item:first-child .unit-header {
    border-top: none;
}

.unit-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: #2c3e50;
}

.unit-toggle {
    font-size: 0.875rem;
    color: #6c757d;
    transition: transform 0.3s ease;
}

.unit-item.active .unit-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}*/


/* 单元内容 */
/*.unit-body {
    padding: 0;
    background-color: #fff;
}*/

/* 章节手风琴 */
/*.chapter-accordion {
    border: none;
    margin: 0;
}

.chapter-item {
    border-bottom: 1px solid #e9ecef;
}

    .chapter-item:last-child {
        border-bottom: none;
    }*/

/* 章节头部 */
/*.chapter-header {
    padding: 1rem 1.25rem;
    background-color: #fafbfc;
    border: none;
    width: 100%;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .chapter-header:hover {
        background-color: #f1f5f9;
    }


.chapter-title {
    font-weight: 500;
    color: #495057;
}

.chapter-toggle {
    font-size: 0.75rem;
    color: #6c757d;
    transition: transform 0.3s ease;
    margin-left: 0.5rem;
}

.chapter-item.active .chapter-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}*/

/* 章节操作按钮 */
/*.chapter-actions {
    display: flex;
    gap: 0.5rem;
    margin-right: 1rem;
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: white;
    border: 1px solid #dee2e6;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .btn-icon:hover {
        background-color: #f8f9fa;
        border-color: #adb5bd;
        color: #495057;
    }

    .btn-icon i {
        font-size: 0.875rem;
    }

.preview-btn:hover {
    background-color: #e7f4ff;
    border-color: #86b7fe;
    color: #0d6efd;
}

.download-btn {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

    .download-btn:hover {
        background-color: #e8f5e8;
        border-color: #75b798;
        color: #28a745;
    }*/

/* 章节内容 */
/*.chapter-body {
    padding: 1rem 1.25rem 1rem 3.25rem;
    background-color: white;
}

.chapter-desc {
    color: #6c757d;
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.chapter-info {
    display: flex;
    gap: 1.5rem;
    font-size: 0.875rem;
    color: #868e96;
}

.file-info, .update-info {
    display: flex;
    align-items: center;
}*/

/* 响应式设计 */
/*@media (max-width: 768px) {
    .unit-header {
        padding: 1rem;
    }

    .chapter-header {
        padding: 0.875rem 1rem;
    }

    .chapter-body {
        padding: 0.875rem 1rem 0.875rem 2.5rem;
    }

    .chapter-actions {
        margin-right: 0.5rem;
    }

    .btn-icon {
        width: 28px;
        height: 28px;
    }

    .chapter-info {
        flex-direction: column;
        gap: 0.5rem;
    }
}*/

/* 动画效果 */
/*.accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.accordion-item.active .accordion-body {
    max-height: 1000px;
    transition: max-height 0.5s ease-in;
}*/

/* 确保切换箭头正确旋转 */
/*.unit-toggle, .chapter-toggle {
    transition: transform 0.3s ease;
    font-size: 0.875rem;
    color: #6c757d;
}

.unit-item.active .unit-toggle,
.chapter-item.active .chapter-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}*/

/* 手风琴内容默认隐藏 */
/*.unit-body, .chapter-body {
    display: none;
}

.unit-item.active .unit-body,
.chapter-item.active .chapter-body {
    display: block;
}*/

/* 确保按钮组在行内正确显示 */
/*.chapter-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}*/

/* 单元手风琴样式 */
/*.unit-accordion {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 2rem;
}*/

/* 单元头部 */
/*.unit-header {
    padding: 1.25rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: none;
    border-bottom: 1px solid #dee2e6;
    width: 100%;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

    .unit-header:hover {
        background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
    }

.unit-item:first-child .unit-header {
    border-top: none;
}

.unit-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: #2c3e50;
}

.unit-toggle {
    font-size: 0.875rem;
    color: #6c757d;
    transition: transform 0.3s ease;
}

.unit-item.active .unit-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}*/

/* 单元内容 */
/*.unit-body {
    padding: 0;
    background-color: #fff;
}*/

/* 章节手风琴 */
/*.chapter-accordion {
    border: none;
    margin: 0;
}

.chapter-item {
    border-bottom: 1px solid #e9ecef;
}

    .chapter-item:last-child {
        border-bottom: none;
    }*/

/* 章节头部 */
/*.chapter-header {
    padding: 1rem 1.25rem;
    background-color: #fafbfc;
    border: none;
    width: 100%;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .chapter-header:hover {
        background-color: #f1f5f9;
    }


.chapter-title {
    font-weight: 500;
    color: #495057;
}

.chapter-toggle {
    font-size: 0.75rem;
    color: #6c757d;
    transition: transform 0.3s ease;
    margin-left: 0.5rem;
}

.chapter-item.active .chapter-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}*/

/* 章节操作按钮 */
/*.chapter-actions {
    display: flex;
    gap: 0.5rem;
    margin-right: 1rem;
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: white;
    border: 1px solid #dee2e6;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .btn-icon:hover {
        background-color: #f8f9fa;
        border-color: #adb5bd;
        color: #495057;
    }

    .btn-icon i {
        font-size: 0.875rem;
    }

.preview-btn:hover {
    background-color: #e7f4ff;
    border-color: #86b7fe;
    color: #0d6efd;
}

.download-btn {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

    .download-btn:hover {
        background-color: #e8f5e8;
        border-color: #75b798;
        color: #28a745;
    }*/

/* 章节内容 */
/*.chapter-body {
    padding: 1rem 1.25rem 1rem 3.25rem;
    background-color: white;
}

.chapter-desc {
    color: #6c757d;
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.chapter-info {
    display: flex;
    gap: 1.5rem;
    font-size: 0.875rem;
    color: #868e96;
}

.file-info, .update-info {
    display: flex;
    align-items: center;
}*/

/* 响应式设计 */
/*@media (max-width: 768px) {
    .unit-header {
        padding: 1rem;
    }

    .chapter-header {
        padding: 0.875rem 1rem;
    }

    .chapter-body {
        padding: 0.875rem 1rem 0.875rem 2.5rem;
    }

    .chapter-actions {
        margin-right: 0.5rem;
    }

    .btn-icon {
        width: 28px;
        height: 28px;
    }

    .chapter-info {
        flex-direction: column;
        gap: 0.5rem;
    }
}*/

/* 动画效果 */
/*.accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.accordion-item.active .accordion-body {
    max-height: 1000px;
    transition: max-height 0.5s ease-in;
}*/

/* 确保切换箭头正确旋转 */
/*.unit-toggle, .chapter-toggle {
    transition: transform 0.3s ease;
    font-size: 0.875rem;
    color: #6c757d;
}

.unit-item.active .unit-toggle,
.chapter-item.active .chapter-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}*/

/* 手风琴内容默认隐藏 */
/*.unit-body, .chapter-body {
    display: none;
}

.unit-item.active .unit-body,
.chapter-item.active .chapter-body {
    display: block;
}*/

/* 确保按钮组在行内正确显示 */
/*.chapter-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}*/

/*手风琴基础样式*/

.accordion {
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.accordion-item {
    border-bottom: 1px solid var(--light-gray);
    background-color: white;
}

    .accordion-item:last-child {
        border-bottom: none;
    }

.accordion-header {
    width: 100%;
    text-align: left;
    border: none;
    padding: 18px 24px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--dark);
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
}

    .accordion-header:hover {
        background-color: rgba(44, 111, 187, 0.05);
    }

    .accordion-header .triangle {
        position: absolute;
        right: 24px;
        top: 50%;
        transform: translateY(-50%) rotate(0deg);
        transition: transform 0.3s ease;
        color: var(--gray);
        font-size: 0.8rem;
    }

    .accordion-header.open .triangle {
        transform: translateY(-50%) rotate(180deg);
    }

.accordion-body {
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background-color: white;
}

.accordion-item.active .accordion-body {
    max-height: 2000px;
}

/*学段级别样式*/
.grade-item {
    border-left: 4px solid var(--primary);
}

    .grade-item[data-grade="middle"] {
        border-left-color: var(--warning);
    }

    .grade-item[data-grade="high"] {
        border-left-color: var(--danger);
    }

.grade-header {
    background-color: rgba(44, 111, 187, 0.08);
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

    .grade-header.open {
        background-color: rgba(44, 111, 187, 0.12);
    }

.grade-body {
    padding: 0 !important;
}

    .grade-body.active {
        padding: 0 !important;
    }

/*单元级别样式*/
.unit-accordion {
    border: none;
    border-radius: 0;
    margin: 0;
    overflow: hidden;
    margin-bottom: 2rem;
}

.unit-header {
    padding: 1.25rem 1.25rem 1.25rem 2.5rem; /* 左侧缩进40px显示层级 */
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: none;
    border-bottom: 1px solid #dee2e6;
    width: 100%;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 500;
}

    .unit-header:hover {
        background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
    }


.unit-item {
    border-bottom: 1px solid var(--light-gray);
    border-left: none;
    border-top: none;
}

    .unit-item:last-child {
        border-bottom: none;
    }

/* 移除重复的 .unit-header 定义，统一使用上面的样式 */


.unit-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: #2c3e50;
}

.unit-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.unit-toggle {
    font-size: 0.875rem;
    color: #6c757d;
    transition: transform 0.3s ease;
    margin-left: 0;
}

.unit-item.active .unit-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}

/* 单元内容 */
.unit-body {
    padding: 0;
    background-color: #fff;
}

/*章节级别样式*/
.chapter-list {
    padding: 0;
    margin: 0;
}

.chapter-item {
    border-bottom: 1px solid #e9ecef;
    border-left: none;
    background-color: #fff;
}

    .chapter-item:last-child {
        border-bottom: none;
    }

.chapter-header {
    padding: 1rem 1.25rem 1rem 3.5rem; /* 增加左侧缩进以显示层级 */
    font-size: 0.95rem;
    background-color: #fafbfc;
    border: none;
    width: 100%;
    cursor: default; /* 节不需要点击折叠 */
    transition: all 0.2s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

    .chapter-header:hover {
        background-color: rgba(44, 111, 187, 0.03);
    }


.chapter-title {
    font-weight: 500;
    color: #495057;
}

.chapter-toggle {
    font-size: 0.75rem;
    color: #6c757d;
    transition: transform 0.3s ease;
    margin-left: 0.5rem;
}

.chapter-item.active .chapter-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}

/*章节内容样式*/
.chapter-desc {
    color: var(--gray);
    line-height: 1.6;
    margin-bottom: 15px;
}

.chapter-info {
    display: flex;
    gap: 20px;
    font-size: 0.9rem;
    color: var(--gray);
}

.file-info, .update-info {
    display: flex;
    align-items: center;
}

    .file-size, .update-info span {
        margin-left: 4px;
    }

/*按钮图标样式*/
.chapter-actions {
    display: flex;
    gap: 10px;
    margin-right: 30px;
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .btn-icon:hover {
        background-color: rgba(0, 0, 0, 0.05);
    }

    .btn-icon i.text-gray {
        color: var(--gray);
    }

    .btn-icon:hover i.text-gray {
        color: var(--primary);
    }

.download-btn {
    text-decoration: none;
}

/* 章节操作按钮  */
.chapter-actions {
    display: flex;
    gap: 0.5rem;
    margin-right: 0;
    align-items: center;
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: white;
    border: 1px solid #dee2e6;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s ease;
}

    .btn-icon:hover {
        background-color: #f8f9fa;
        border-color: #adb5bd;
        color: #495057;
    }

    .btn-icon i {
        font-size: 0.875rem;
    }

.preview-btn:hover {
    background-color: #e7f4ff;
    border-color: #86b7fe;
    color: #0d6efd;
}

.download-btn {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

    .download-btn:hover {
        background-color: #e8f5e8;
        border-color: #75b798;
        color: #28a745;
    }

/* 章节内容*/
.chapter-body {
    padding: 1rem 1.25rem 1rem 3.25rem;
    background-color: white;
}

.chapter-desc {
    color: #6c757d;
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.chapter-info {
    display: flex;
    gap: 1.5rem;
    font-size: 0.875rem;
    color: #868e96;
}

.file-info, .update-info {
    display: flex;
    align-items: center;
}

/*空状态提示*/
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--gray);
    font-style: italic;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .unit-header {
        padding: 1rem 1rem 1rem 1.5rem; /* 移动端减少缩进 */
        font-size: 0.95rem;
    }

    .chapter-header {
        padding: 0.875rem 1rem 0.875rem 2rem; /* 移动端减少缩进 */
        font-size: 0.9rem;
    }

    .chapter-actions {
        margin-right: 0.5rem;
        gap: 0.25rem;
    }

    .btn-icon {
        width: 28px;
        height: 28px;
    }

    .chapter-title {
        font-size: 0.85rem;
    }

    .unit-title {
        font-size: 1rem;
    }
}

/* 动画效果 */
.accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.accordion-item.active .accordion-body {
    max-height: 1000px;
    transition: max-height 0.5s ease-in;
}

/* 确保切换箭头正确旋转 */
.unit-toggle, .chapter-toggle {
    transition: transform 0.3s ease;
    font-size: 0.875rem;
    color: #6c757d;
}

.unit-item.active .unit-toggle,
.chapter-item.active .chapter-toggle {
    transform: rotate(180deg);
    color: #0d6efd;
}

/* 手风琴内容默认隐藏 */
.unit-body {
    display: none;
}

.unit-item.active .unit-body {
    display: block;
}

/* 节始终显示，不需要折叠功能 */
.chapter-list {
    display: block;
}

/* 确保按钮组在行内正确显示 */
.chapter-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}