/* 乐学乐伴后台管理系统 - 自定义样式 */

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f4f6f9;
    overflow-x: hidden;
}

/* 顶部导航 */
.top-navbar {
    z-index: 1040;
    height: 56px;
}

/* 布局 */
.wrapper {
    display: flex;
    width: 100%;
    margin-top: 56px;
    min-height: calc(100vh - 56px);
}

/* 侧边栏 */
#sidebar {
    width: 240px;
    min-height: calc(100vh - 56px);
    transition: all 0.3s;
    position: fixed;
    top: 56px;
    left: 0;
    bottom: 0;
    z-index: 1030;
    overflow-y: auto;
}

#sidebar .sidebar-menu {
    padding: 1rem 0;
}

.sidebar-link {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.25rem;
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.sidebar-link:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar-link.active {
    color: #fff;
    background-color: rgba(13, 110, 253, 0.5);
    border-right: 3px solid #0d6efd;
}

.sidebar-link i {
    margin-right: 0.75rem;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

/* 主内容区 */
#content {
    width: calc(100% - 240px);
    margin-left: 240px;
    transition: all 0.3s;
    min-height: calc(100vh - 56px);
}

/* 卡片样式 */
.stat-card {
    border: none;
    border-radius: 0.75rem;
    box-shadow: 0 0.15rem 1.75rem rgba(0, 0, 0, 0.08);
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
}

.stat-card .card-body {
    padding: 1.25rem;
}

.stat-card .stat-icon {
    font-size: 2.5rem;
    opacity: 0.3;
}

.stat-card .stat-number {
    font-size: 1.75rem;
    font-weight: 700;
}

/* 表格 */
.table-container {
    background: #fff;
    border-radius: 0.75rem;
    box-shadow: 0 0.15rem 1.75rem rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.table-container .card-header {
    background-color: #fff;
    border-bottom: 1px solid #e3e6f0;
    padding: 1rem 1.25rem;
}

/* 登录页面 */
.login-page {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    width: 100%;
    max-width: 420px;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.2);
}

/* 表单样式 */
.form-label {
    font-weight: 500;
    color: #495057;
}

/* 分页 */
.pagination .page-link {
    color: #0d6efd;
}

.pagination .page-item.active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

/* 响应式 */
@media (max-width: 991.98px) {
    #sidebar {
        margin-left: -240px;
    }

    #sidebar.active {
        margin-left: 0;
    }

    #content {
        width: 100%;
        margin-left: 0;
    }
}

/* 标签样式 */
.badge-dimension {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
}

/* JSON编辑区域 */
.json-editor {
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    padding: 1rem;
    margin-bottom: 0.5rem;
    background-color: #f8f9fa;
}

.json-editor .row {
    margin-bottom: 0.5rem;
}
