/* 后台管理样式 - 蓝白主题 */
.admin-body {
    background: #f0f4f8;
}

.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

/* 侧边栏 - 天空蓝 */
.admin-sidebar {
    width: 250px;
    background: #e0f2fe;
    color: #1e3a5f;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    transition: width 0.3s;
    border-right: 1px solid #bfdbfe;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #bfdbfe;
    background: #dbeafe;
}

.sidebar-header .logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #1e40af;
    font-size: 20px;
    font-weight: bold;
}

.sidebar-header .logo i {
    font-size: 24px;
    color: #2563eb;
}

.sidebar-nav {
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    color: #475569;
    transition: all 0.3s;
    text-decoration: none;
    margin: 4px 12px;
    border-radius: 8px;
}

.nav-item:hover {
    background: #dbeafe;
    color: #1e40af;
    text-decoration: none;
}

.nav-item.active {
    background: #2563eb;
    color: #fff;
}

.nav-item i {
    width: 20px;
    text-align: center;
}

/* 主内容区 */
.admin-main {
    flex: 1;
    margin-left: 250px;
    display: flex;
    flex-direction: column;
    background: #ffffff;
}

/* 顶部导航 */
.admin-header {
    background: #ffffff;
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border-bottom: 1px solid #e2e8f0;
}

.sidebar-toggle {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #64748b;
}

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

.header-link {
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s;
}

.header-link:hover {
    color: #2563eb;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #334155;
}

/* 内容区域 */
.admin-container {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
    background: #ffffff;
}

.admin-content {
    background: #ffffff;
}

.admin-content h1 {
    margin-bottom: 30px;
    font-size: 28px;
    color: #1e293b;
}

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

.stat-card {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    text-decoration: none;
    color: inherit;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    background: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 24px;
}

.stat-card:nth-child(2) .stat-icon {
    background: #3b82f6;
}

.stat-card:nth-child(3) .stat-icon {
    background: #60a5fa;
}

.stat-card:nth-child(4) .stat-icon {
    background: #93c5fd;
}

.stat-info h3 {
    font-size: 32px;
    color: #1e293b;
    margin-bottom: 5px;
}

.stat-info p {
    color: #64748b;
    font-size: 14px;
}

/* 管理区块 */
.admin-sections {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.admin-section {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: 1px solid #e2e8f0;
}

.admin-section h2 {
    font-size: 18px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e2e8f0;
    color: #1e293b;
}

/* 表格样式 */
.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.admin-table th {
    font-weight: 600;
    color: #475569;
    background: #f8fafc;
}

.admin-table tr:hover {
    background: #f8fafc;
}

.admin-table a {
    color: #2563eb;
    margin-right: 10px;
    text-decoration: none;
}

.admin-table a:hover {
    text-decoration: underline;
}

.admin-table a.text-danger {
    color: #dc2626;
}

/* 表单样式 */
.admin-form {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    max-width: 600px;
    border: 1px solid #e2e8f0;
}

.admin-form .form-group {
    margin-bottom: 20px;
}

.admin-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #334155;
}

.admin-form .form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    transition: border-color 0.2s;
}

.admin-form .form-control:focus {
    border-color: #2563eb;
    outline: none;
}

.admin-form textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

/* 按钮样式 */
.btn-sm {
    padding: 5px 15px;
    font-size: 13px;
}

.btn-success {
    background: #2563eb;
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-success:hover {
    background: #1d4ed8;
}

/* 分页 */
.pagination {
    margin-top: 20px;
}

/* 内容头部 */
.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

.content-header h2 {
    color: #1e293b;
    font-size: 24px;
    margin: 0;
}

/* 卡片样式 */
.card {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border: 1px solid #e2e8f0;
}

/* 警告框 */
.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.alert-success {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #86efac;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

/* 响应式 */
@media (max-width: 768px) {
    .admin-sidebar {
        width: 0;
        overflow: hidden;
    }
    
    .admin-main {
        margin-left: 0;
    }
    
    .sidebar-collapsed .admin-sidebar {
        width: 250px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .admin-sections {
        grid-template-columns: 1fr;
    }
}

/* 深色模式支持 - 预留 */
@media (prefers-color-scheme: dark) {
    /* 深色模式样式将在后续添加 */
}
