/* 生产动态管理系统 - 样式文件 */
:root {
    --primary: #1890ff;
    --success: #52c41a;
    --warning: #faad14;
    --danger: #ff4d4f;
    --bg: #f5f5f5;
    --text: #333;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    max-width: 750px;
    margin: 0 auto;
    min-height: 100vh;
}

/* 头部 */
.header {
    background: linear-gradient(135deg, #1890ff, #096dd9);
    color: white;
    padding: 20px;
    text-align: center;
}

.header h1 { font-size: 20px; margin-bottom: 5px; }
.header p { font-size: 14px; opacity: 0.9; }

/* 导航卡片 */
.nav-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    padding: 20px;
}

.nav-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    cursor: pointer;
    transition: transform 0.2s;
}

.nav-card:active { transform: scale(0.98); }
.nav-card .icon { font-size: 40px; margin-bottom: 10px; }
.nav-card h3 { font-size: 16px; margin-bottom: 5px; }
.nav-card p { font-size: 12px; color: #999; }

/* 表单 */
.form-container {
    padding: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-size: 14px;
    margin-bottom: 5px;
    color: #666;
}

.form-group label .required { color: red; }

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
}

.form-group textarea { resize: vertical; min-height: 80px; }

/* 按钮 */
.btn {
    display: block;
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
}

.btn-primary { background: var(--primary); color: white; }
.btn-success { background: var(--success); color: white; }
.btn-danger { background: var(--danger); color: white; }

/* 列表项 */
.list-item {
    background: white;
    padding: 15px;
    margin: 10px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.list-item .title { font-weight: 600; margin-bottom: 5px; }
.list-item .info { font-size: 13px; color: #666; }
.list-item .status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    margin-top: 5px;
}

.status-pending { background: #e6f7ff; color: var(--primary); }
.status-processing { background: #fff7e6; color: var(--warning); }
.status-done { background: #f6ffed; color: var(--success); }
.status-overdue { background: #fff1f0; color: var(--danger); }

/* 二维码 */
.qr-container {
    text-align: center;
    padding: 20px;
    background: white;
    margin: 20px;
    border-radius: 12px;
}

.qr-container canvas {
    margin: 10px auto;
}

/* 统计卡片 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    padding: 20px;
}

.stat-card {
    background: white;
    padding: 15px;
    border-radius: 12px;
    text-align: center;
}

.stat-card .num {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
}

.stat-card .label { font-size: 12px; color: #999; margin-top: 5px; }

/* Tab切换 */
.tabs {
    display: flex;
    background: white;
    border-bottom: 1px solid #eee;
}

.tab {
    flex: 1;
    padding: 12px;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
}

.tab.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
}

/* 审核按钮 */
.action-btns {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.action-btns button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
}

/* 扫码区域 */
.scan-area {
    background: white;
    margin: 20px;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
}

.scan-area .scan-icon {
    font-size: 80px;
    margin-bottom: 15px;
}

/* 弹窗 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
}

.modal-content {
    background: white;
    margin: 20px;
    border-radius: 12px;
    padding: 20px;
    max-height: 80vh;
    overflow-y: auto;
}

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

.modal-header h3 { font-size: 18px; }
.modal-header .close { font-size: 24px; cursor: pointer; }

/* Toast */
.toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 15px 30px;
    border-radius: 8px;
    z-index: 2000;
    display: none;
}

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

.empty .icon { font-size: 60px; margin-bottom: 15px; }
