/* 全局样式 */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

/* 导航栏样式 */
.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
}

/* 卡片样式 */
.card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

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

/* 按钮样式 */
.btn {
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: none;
}

.btn-success:hover {
    background: linear-gradient(135deg, #218838 0%, #1ea585 100%);
}

/* 表单样式 */
.form-control {
    border-radius: 8px;
    border: 1px solid #dee2e6;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

/* 进度条样式 */
.progress {
    background-color: #e9ecef;
    border-radius: 10px;
}

.progress-bar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
}

/* 警告框样式 */
.alert {
    border: none;
    border-radius: 10px;
    border-left: 4px solid;
}

.alert-success {
    background-color: #d4edda;
    border-left-color: #28a745;
    color: #155724;
}

.alert-warning {
    background-color: #fff3cd;
    border-left-color: #ffc107;
    color: #856404;
}

.alert-danger {
    background-color: #f8d7da;
    border-left-color: #dc3545;
    color: #721c24;
}

.alert-info {
    background-color: #d1ecf1;
    border-left-color: #17a2b8;
    color: #0c5460;
}

/* 表格样式 */
.table {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
}

.table th {
    background-color: #f8f9fa;
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
}

.table-hover tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05);
}

/* 徽章样式 */
.badge {
    font-size: 0.85em;
    padding: 0.4em 0.8em;
    border-radius: 6px;
}

/* 页脚样式 */
footer {
    margin-top: auto;
    background-color: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .card {
        border-radius: 10px;
    }

    .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }

    .table-responsive {
        font-size: 0.9rem;
    }
}

/* 测试页面特殊样式 */
.question-item {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    transition: all 0.2s;
}

.question-item:hover {
    background-color: #e9ecef;
}

.question-text {
    color: #2c3e50;
    font-weight: 500;
    margin-bottom: 1rem;
}

.form-check {
    margin-bottom: 0.5rem;
}

.form-check-input:checked + .form-check-label {
    background-color: #e7f3ff;
    border-radius: 0.375rem;
    padding: 0.25rem;
}

.score-label {
    font-size: 0.85rem;
    line-height: 1.2;
    color: #6c757d;
}

.score-number {
    font-weight: bold;
    font-size: 1.1rem;
    color: #333;
}

/* 结果页面特殊样式 */
.result-summary {
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.dimension-card {
    border-radius: 8px;
    transition: transform 0.2s;
}

.dimension-card:hover {
    transform: translateY(-2px);
}

/* 管理后台特殊样式 */
.stat-card {
    border-radius: 10px;
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
}

.stat-card .card-title {
    font-size: 2.5rem;
    font-weight: bold;
}

.stat-card .card-text {
    font-size: 1rem;
    opacity: 0.9;
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* 打印样式 */
@media print {
    .btn, .navbar, footer, .no-print {
        display: none !important;
    }

    .card {
        box-shadow: none !important;
        border: 1px solid #dee2e6 !important;
        margin-bottom: 1rem !important;
    }

    body {
        background-color: white !important;
        font-size: 12pt;
    }

    .alert {
        border: 1px solid #dee2e6 !important;
        background-color: white !important;
        color: black !important;
    }
}