* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background-color: #f5f5f5;
    color: #333;
    font-size: 14px;
    line-height: 1.5;
}

#app {
    display: flex;
    min-height: 100vh;
}

/* 侧边栏样式 */
.sidebar {
    width: 200px;
    background: linear-gradient(180deg, #1890ff 0%, #096dd9 100%);
    color: white;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
}

.sidebar-header {
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header h2 {
    font-size: 16px;
    font-weight: 600;
}

.sidebar-nav {
    flex: 1;
    padding: 8px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.nav-item.active {
    background: rgba(255, 255, 255, 0.15);
    border-left-color: white;
    color: white;
}

.nav-icon {
    font-size: 18px;
    margin-right: 10px;
}

.nav-text {
    font-size: 14px;
}

/* 主内容区样式 */
.main-content {
    flex: 1;
    margin-left: 200px;
    padding: 20px 24px;
    min-height: 100vh;
}

.content-wrapper {
    max-width: 1400px;
    margin: 0 auto;
}

h1 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1f1f1f;
}

.content-wrapper > p {
    color: #8c8c8c;
    margin-bottom: 16px;
    font-size: 13px;
}

/* 卡片样式 */
.dashboard-cards {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-top: 16px;
}

.card {
    background: white;
    border-radius: 6px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    cursor: pointer;
}

.card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.card-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.card-content h3 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #1f1f1f;
}

.card-content p {
    color: #8c8c8c;
    font-size: 12px;
}

/* 表格样式 */
.table-container {
    background: white;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: #fafafa;
}

th {
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
    color: #1f1f1f;
    border-bottom: 1px solid #f0f0f0;
    font-size: 13px;
}

td {
    padding: 10px 12px;
    border-bottom: 1px solid #f0f0f0;
    color: #595959;
    font-size: 13px;
}

tr:hover {
    background: #fafafa;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 4px;
    border: none;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-primary {
    background: #1890ff;
    color: white;
}

.btn-primary:hover {
    background: #40a9ff;
}

.btn-success {
    background: #52c41a;
    color: white;
}

.btn-success:hover {
    background: #73d13d;
}

.btn-danger {
    background: #ff4d4f;
    color: white;
}

.btn-danger:hover {
    background: #ff7875;
}

.btn-secondary {
    background: #f0f0f0;
    color: #595959;
}

.btn-secondary:hover {
    background: #d9d9d9;
}

.btn-small {
    padding: 4px 8px;
    font-size: 12px;
}

/* 表单样式 */
.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #1f1f1f;
    font-size: 13px;
}

.form-input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #d9d9d9;
    border-radius: 4px;
    font-size: 13px;
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
}

.form-textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #d9d9d9;
    border-radius: 4px;
    font-size: 13px;
    font-family: inherit;
    resize: vertical;
    min-height: 80px;
}

.form-textarea:focus {
    outline: none;
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
}

/* 页面标题样式 */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f1f1f;
}

/* 加载状态 */
.loading {
    text-align: center;
    padding: 24px;
    color: #8c8c8c;
    font-size: 13px;
}

/* 空状态 */
.empty {
    text-align: center;
    padding: 40px 20px;
    color: #8c8c8c;
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

/* 操作栏 */
.action-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.search-box {
    display: flex;
    gap: 10px;
}

.search-input {
    padding: 6px 10px;
    border: 1px solid #d9d9d9;
    border-radius: 4px;
    width: 240px;
    font-size: 13px;
}

/* 图片预览 */
.image-preview {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid #f0f0f0;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 6px;
    padding: 20px 24px;
    max-width: 500px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.modal-title {
    font-size: 16px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #8c8c8c;
}

.modal-close:hover {
    color: #1f1f1f;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
}

/* 内容项样式 */
.content-item {
    background: white;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.item-title {
    font-size: 14px;
    font-weight: 500;
    color: #1f1f1f;
}

.item-actions {
    display: flex;
    gap: 8px;
}

.item-image {
    width: 100%;
    max-width: 300px;
    height: auto;
    margin-top: 10px;
    border-radius: 4px;
}

/* 标签页样式 */
.tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    background: white;
    padding: 4px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.tab {
    padding: 8px 16px;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    font-size: 13px;
    color: #595959;
    transition: all 0.3s ease;
}

.tab:hover {
    background: #f5f5f5;
}

.tab.active {
    background: #1890ff;
    color: white;
}

/* 上传区域 */
.upload-area {
    border: 2px dashed #d9d9d9;
    border-radius: 6px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-area:hover {
    border-color: #1890ff;
}

.upload-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.upload-text {
    color: #8c8c8c;
    font-size: 13px;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .dashboard-cards {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .dashboard-cards {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .sidebar {
        width: 180px;
    }
    
    .main-content {
        margin-left: 180px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 64px;
    }
    
    .sidebar-header h2 {
        display: none;
    }
    
    .nav-text {
        display: none;
    }
    
    .nav-icon {
        margin-right: 0;
    }
    
    .main-content {
        margin-left: 64px;
        padding: 12px;
    }
    
    .dashboard-cards {
        grid-template-columns: 1fr;
    }
}
