/* ===== 基础重置与全局样式 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "微软雅黑", "Segoe UI", sans-serif;
}

body {
    font-size: 13px;
    line-height: 1.5;
    color: #333;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    padding: 15px;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===== 主要布局容器 ===== */
.container {
    max-width: 1400px;
    margin: 0 auto;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

/* ===== 顶部导航栏 ===== */
.header {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    font-size: 18px;
    font-weight: 600;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.date-display {
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
}

/* ===== 搜索区域 ===== */
.search-section {
    background: #fff;
    padding: 20px 25px;
    border-bottom: 1px solid #eaeaea;
}

.search-form {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.search-input, .search-select {
    flex: 1;
    min-width: 180px;
    padding: 10px 16px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 13px;
    background: #f9f9f9;
    transition: all 0.3s ease;
    height: 38px;
}

.search-input:focus, .search-select:focus {
    border-color: #3498db;
    outline: none;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.search-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(231, 76, 60, 0.3);
    font-size: 13px;
    height: 38px;
}

.search-btn:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(231, 76, 60, 0.4);
}

/* ===== 数据列表项 ===== */
.list-section {
    padding: 15px;
}

.list-item {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

.list-item:hover {
    background-color: #f8fafc;
}

.item-checkbox {
    margin-right: 12px;
}

.item-content {
    flex: 1;
    font-weight: 500;
    font-size: 13px;
}

.item-actions {
    display: flex;
    gap: 8px;
}

.action-btn {
    padding: 5px 10px;
    border: none;
    border-radius: 12px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.edit-btn { 
    background: #2ecc71;
    color: white;
}

.edit-btn:hover {
    background: #27ae60;
}

.delete-btn { 
    background: #e74c3c;
    color: white;
}

.delete-btn:hover {
    background: #c0392b;
}

/* ===== 蓝色按钮（用这个，必生效） ===== */
.action-btn.blue-btn {
    background: #3498db !important;
    color: #ffffff !important;
}
.action-btn.blue-btn:hover {
    background: #2980b9 !important;
    color: #ffffff !important;
}


/* ===== 表单组件 ===== */
.form-section {
    padding: 25px;
    background: #f9f9f9;
}

.form-title {
    font-size: 16px;
    margin-bottom: 15px;
    color: #2c3e50;
    font-weight: 600;
}

.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: #495057;
    font-size: 13px;
}

.form-input, .form-upinput, textarea {
    width: 100%;
    max-width: 400px;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 13px;
    transition: all 0.3s ease;
    background: #fff;
}

.form-input, .form-upinput {
    height: 36px;
}

.form-input:focus, .form-upinput:focus, textarea:focus {
    border-color: #3498db;
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* 新增短尺寸输入框 - 与原表单组件配色/交互一致 */
.form-shortinput {
    width: 100%;
    max-width: 260px; /* 短尺寸核心：比原400px更紧凑，可按需微调 */
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 13px;
    transition: all 0.3s ease;
    background: #fff;
    height: 36px; /* 与原form-input高度完全一致 */
}

.form-shortinput:focus {
    border-color: #3498db; /* 原配色不变 */
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1); /* 原聚焦阴影不变 */
}

textarea {
    min-height: 100px;
    resize: vertical;
    line-height: 1.5;
}

.submit-btn {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
    height: 36px;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(52, 152, 219, 0.4);
}

/* ===== 功能类与状态样式 ===== */
.error-message {
    color: #e74c3c;
    font-weight: bold;
    padding: 8px;
    background: #ffeaea;
    border-radius: 4px;
    margin-bottom: 12px;
    font-size: 13px;
}

.batch-actions {
    padding: 12px 25px;
    background: #f0f7ff;
    border-top: 1px solid #e0e0e0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.batch-submit {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    font-size: 13px;
}

.batch-submit:hover {
    background: #c0392b;
}

/* ===== 分页组件 ===== */
.pagination {
    display: flex;
    justify-content: center;
    padding: 15px;
    background: #f9f9f9;
    gap: 4px;
    flex-wrap: wrap;
}

.page-link {
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #3498db;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 12px;
    min-width: 36px;
    text-align: center;
    display: inline-block;
    white-space: nowrap;
}

.page-link:hover, .page-current {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

/* ===== 响应式设计 ===== */
@media (max-width: 768px) {
    .container {
        margin: 8px;
        border-radius: 8px;
    }
    
    .header {
        flex-direction: column;
        gap: 12px;
        text-align: center;
        padding: 12px 15px;
    }
    
    .search-form {
        flex-direction: column;
        gap: 10px;
    }
    
    .search-input, .search-select {
        width: 100%;
    }
    
    .list-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px 12px;
    }
    
    .item-actions {
        margin-top: 8px;
        width: 100%;
        justify-content: flex-end;
    }
    
    .form-input, .form-upinput, textarea {
        max-width: 100%;
    }
    
    .form-section {
        padding: 20px;
    }
    
    .pagination {
        padding: 10px;
        gap: 3px;
    }
    
    .page-link {
        padding: 5px 8px;
        font-size: 11px;
        min-width: 32px;
        margin: 2px;
    }
}

@media (max-width: 480px) {
    .page-link {
        padding: 4px 6px;
        font-size: 10px;
        min-width: 28px;
    }
}

