/**
 * 全局样式
 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #f5f7fa;
}

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

.login-card {
    width: 450px;
}

.card-header {
    text-align: center;
}

.card-header h2 {
    margin: 0;
    color: #303133;
}

.login-tips {
    margin-top: 20px;
    text-align: center;
    color: #909399;
    font-size: 14px;
}

/* 主页面 */
.app-container {
    display: flex;
    min-height: 100vh;
    max-width: 100vw;
    overflow-x: hidden;
}

.sidebar {
    width: 200px;
    min-width: 200px;
    max-width: 200px;
    flex-shrink: 0;
    background: #304156;
    color: #fff;
    overflow-y: auto;
}

.sidebar-header {
    height: 60px;
    line-height: 60px;
    text-align: center;
    background: #1f2d3d;
    font-size: 18px;
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 10px;
}

.sidebar-menu {
    padding: 10px 0;
}

.menu-item {
    padding: 15px 20px;
    cursor: pointer;
    transition: background 0.3s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    user-select: none;
}

.menu-item:hover {
    background: #263445;
}

.menu-item.active {
    background: #409eff;
    font-weight: 500;
}

.main-container {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.header {
    height: 60px;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0,21,41,.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.header-left h1 {
    font-size: 20px;
    margin: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.content {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.page-header {
    margin-bottom: 20px;
}

.page-title {
    font-size: 24px;
    margin: 0 0 10px 0;
}

.filter-bar {
    margin-bottom: 20px;
}

.table-container {
    background: #fff;
    border-radius: 4px;
    padding: 20px;
}

.pagination-container {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
}

/* 统计卡片 */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.stat-card {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
}

.stat-title {
    font-size: 14px;
    color: #909399;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 28px;
    font-weight: bold;
    color: #303133;
}

/* 响应式 */
@media (max-width: 768px) {
    .app-container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
    }
    
    .stats-container {
        grid-template-columns: 1fr;
    }
}
