/* 全局样式 */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
    --primary: #2563eb;
    --primary-dark: #1e40af;
    --success: #16a34a;
    --danger: #dc2626;
    --warning: #d97706;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-500: #6b7280;
    --gray-700: #374151;
    --gray-900: #111827;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background: var(--gray-100);
    color: var(--gray-900);
    line-height: 1.6;
}
.container { max-width: 1100px; margin: 0 auto; padding: 20px; }
.card { background: #fff; border-radius: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.08); padding: 24px; margin-bottom: 20px; }
.btn { display: inline-block; padding: 10px 20px; border-radius: 6px; border: none; cursor: pointer; font-size: 15px; text-decoration: none; transition: all .15s; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-success { background: var(--success); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-outline { background: #fff; border: 1px solid var(--gray-300); color: var(--gray-700); }
.btn-outline:hover { background: var(--gray-50); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.input { width: 100%; padding: 10px 12px; border: 1px solid var(--gray-300); border-radius: 6px; font-size: 15px; }
.input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.label { display: block; margin-bottom: 6px; font-weight: 600; color: var(--gray-700); }
.alert { padding: 12px 16px; border-radius: 6px; margin-bottom: 16px; }
.alert-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.alert-success { background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }
.tag { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 12px; }
.tag-single { background: #dbeafe; color: #1e40af; }
.tag-multiple { background: #fef3c7; color: #92400e; }
.tag-fill { background: #dcfce7; color: #166534; }
.tag-essay { background: #fce7f3; color: #9f1239; }
.header { background: var(--primary); color: #fff; padding: 14px 0; box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.header h1 { font-size: 18px; }
.header .container { display: flex; justify-content: space-between; align-items: center; padding: 0 20px; }
.header .user-info { font-size: 14px; }
.progress-bar { background: var(--gray-200); border-radius: 20px; height: 8px; overflow: hidden; }
.progress-bar > div { background: var(--primary); height: 100%; transition: width .3s; }
.question-item { padding: 20px 0; border-bottom: 1px solid var(--gray-200); }
.question-item:last-child { border-bottom: none; }
.question-item .q-title { font-weight: 600; margin-bottom: 12px; }
.question-item .q-options label { display: block; padding: 8px 12px; margin: 6px 0; border: 1px solid var(--gray-200); border-radius: 6px; cursor: pointer; }
.question-item .q-options label:hover { background: var(--gray-50); }
.question-item .q-options input { margin-right: 8px; }
.timer { font-size: 18px; font-weight: 700; color: var(--danger); }
.timer.warning { animation: pulse 1s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .5; } }
table { width: 100%; border-collapse: collapse; }
table th, table td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--gray-200); }
table th { background: var(--gray-50); font-weight: 600; }
.stat-card { text-align: center; padding: 20px; }
.stat-card .num { font-size: 32px; font-weight: 700; color: var(--primary); }
.stat-card .lbl { color: var(--gray-500); font-size: 14px; }
.badge-pass { background: #dcfce7; color: #166534; padding: 4px 10px; border-radius: 4px; }
.badge-fail { background: #fef2f2; color: #991b1b; padding: 4px 10px; border-radius: 4px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 20px; }
.text-center { text-align: center; }
.mt-2 { margin-top: 8px; } .mt-4 { margin-top: 16px; } .mt-6 { margin-top: 24px; }
.mb-2 { margin-bottom: 8px; } .mb-4 { margin-bottom: 16px; }
.text-danger { color: var(--danger); } .text-success { color: var(--success); }
.hidden { display: none; }
