/* 澄心教务 - 自定义样式 */

/* 顶栏下方留白 */
body {
    background-color: #f5f7fa;
}

/* 左栏菜单样式 */
.list-group-item {
    border: none !important;
    padding: 0.5rem 1rem;
    color: #333;
}

.list-group-item-action:hover {
    background-color: #e9ecef;
    color: #0d6efd;
}

.list-group-item-action.active {
    background-color: #0d6efd !important;
    color: #fff !important;
}

/* 二级菜单选中：浅蓝底 + 蓝色字，与一级菜单区分 */
.collapse .list-group-item-action.active {
    background-color: #e3f2fd !important;
    color: #0d6efd !important;
    border-left: 3px solid #0d6efd !important;
}

/* 卡片样式优化 */
.card {
    border: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border-radius: 8px;
}

/* 表格样式优化 */
.table {
    font-size: 0.9rem;
}

/* 表格表头固定，滚动时不消失 */
.card-body:has(> .table) {
    max-height: calc(100vh - 220px);
    overflow-y: auto;
    padding: 0 !important;
}
.card-body:has(> .table) > .table {
    margin-bottom: 0;
}
.card-body:has(> .table) > .table thead th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #f8f9fa !important;
}

/* 课务详情表格美化 */
.detail-schedule-table {
    border-collapse: separate;
    border-spacing: 0;
}
.detail-schedule-table thead th {
    background-color: #e8ecf0 !important;
    font-weight: 600;
    border-bottom: 2px solid #c8cdd3 !important;
}
.detail-schedule-table .row-header {
    font-weight: 500;
    color: #374151;
}
.detail-schedule-table .data-cell:hover {
    background-color: #eef2ff !important;
}
.detail-schedule-table td, 
.detail-schedule-table th {
    border-color: #d1d5db !important;
}
.detail-schedule-table tbody tr:nth-child(even) {
    background-color: #fafbfc;
}

/* 手机端侧栏 */
@media (max-width: 767.98px) {
    .sidebar {
        width: 280px !important;
        min-width: 280px !important;
        box-shadow: 2px 0 12px rgba(0,0,0,0.15);
    }
    /* 学期列表只显示2行 */
    .semester-list {
        max-height: 180px !important;
    }
}

/* 学期列表选中时文字颜色 */
.list-group-item.active .small {
    color: #000 !important;
}
.list-group-item.active .badge {
    background-color: #0056b3 !important;
}

/* 欢迎区域 */
.welcome-box {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* 模态框优化 */
.modal-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

/* 表单标签 */
.form-label {
    font-weight: 500;
    font-size: 0.9rem;
    color: #495057;
}

/* 分页样式 */
.pagination {
    font-size: 0.9rem;
}

/* Bootstrap Icons 大小调整 */
.bi {
    font-size: 1.1em;
    vertical-align: middle;
}
