/* 测试页面专用样式 */

/* 测试引导页 */
.test-intro {
    min-height: 100vh;
    padding: 120px 0 80px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
}

.intro-content {
    max-width: 900px;
    margin: 0 auto;
}

.intro-header {
    text-align: center;
    margin-bottom: 48px;
}

.intro-header h1 {
    font-size: 42px;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
}

.intro-desc {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.intro-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 48px;
}

.intro-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-normal);
}

.intro-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.intro-card .card-icon {
    font-size: 36px;
    margin-bottom: 12px;
}

.intro-card h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.intro-card p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* 评分指南 */
.rating-guide {
    background: white;
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-sm);
}

.rating-guide h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 24px;
    color: var(--text-primary);
    text-align: center;
}

.rating-scale {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.rating-item {
    flex: 1;
    text-align: center;
    padding: 20px 12px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    transition: var(--transition-fast);
}

.rating-item:hover {
    background: rgba(74, 144, 164, 0.1);
}

.rating-num {
    display: block;
    width: 36px;
    height: 36px;
    line-height: 36px;
    background: var(--gradient-primary);
    color: white;
    font-weight: 700;
    border-radius: 50%;
    margin: 0 auto 12px;
}

.rating-label {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.rating-desc {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* 测评须知 */
.intro-notice {
    background: linear-gradient(135deg, #E3F2FD 0%, #BBDEFB 100%);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 40px;
}

.intro-notice .notice-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.intro-notice h4 {
    font-size: 18px;
    font-weight: 600;
    color: #1565C0;
    margin-bottom: 12px;
}

.intro-notice ul {
    list-style: none;
}

.intro-notice li {
    font-size: 15px;
    color: #1976D2;
    padding: 6px 0;
    padding-left: 20px;
    position: relative;
}

.intro-notice li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #1976D2;
    font-weight: bold;
}

/* 开始按钮 */
.intro-action {
    text-align: center;
}

.btn-large {
    padding: 18px 48px;
    font-size: 18px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.btn-large svg {
    width: 20px;
    height: 20px;
}

/* 测试进行中 */
.test-progress {
    min-height: 100vh;
    padding: 120px 0 80px;
    background: var(--bg-light);
}

.progress-header {
    background: white;
    border-radius: var(--radius-lg);
    padding: 24px 32px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-sm);
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.progress-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.progress-count {
    font-size: 15px;
    color: var(--text-secondary);
}

.progress-count span {
    color: var(--primary-color);
    font-weight: 600;
}

.progress-bar {
    height: 8px;
    background: var(--bg-light);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 4px;
    transition: width 0.3s ease;
}

/* 题目容器 */
.question-container {
    max-width: 800px;
    margin: 0 auto;
}

.question-box {
    background: white;
    border-radius: var(--radius-lg);
    padding: 48px;
    text-align: center;
    margin-bottom: 32px;
    box-shadow: var(--shadow-md);
}

.factor-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(74, 144, 164, 0.1);
    color: var(--primary-color);
    font-size: 13px;
    font-weight: 500;
    border-radius: 20px;
    margin-bottom: 20px;
}

.question-text {
    font-size: 32px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.question-desc {
    font-size: 16px;
    color: var(--text-secondary);
}

/* 选项容器 */
.options-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 32px;
}

.option-btn {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 28px;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition-fast);
    text-align: left;
}

.option-btn:hover {
    border-color: var(--primary-color);
    background: rgba(74, 144, 164, 0.05);
}

.option-btn.selected {
    border-color: var(--primary-color);
    background: rgba(74, 144, 164, 0.1);
}

.option-num {
    width: 36px;
    height: 36px;
    line-height: 36px;
    text-align: center;
    background: var(--bg-light);
    color: var(--text-secondary);
    font-weight: 600;
    border-radius: 50%;
    transition: var(--transition-fast);
}

.option-btn:hover .option-num,
.option-btn.selected .option-num {
    background: var(--gradient-primary);
    color: white;
}

.option-label {
    font-size: 17px;
    font-weight: 500;
    color: var(--text-primary);
}

/* 题目导航 */
.question-nav {
    display: flex;
    justify-content: space-between;
    gap: 16px;
}

.question-nav .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.question-nav .btn svg {
    width: 18px;
    height: 18px;
}

/* 测试结果 */
.test-result {
    min-height: 100vh;
    padding: 120px 0 80px;
    background: var(--bg-light);
}

.result-header {
    text-align: center;
    margin-bottom: 48px;
}

.result-header h1 {
    font-size: 40px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.result-date {
    font-size: 15px;
    color: var(--text-secondary);
}

/* 结果概览 */
.result-overview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    margin-bottom: 48px;
}

.overview-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-md);
    text-align: center;
}

.score-circle {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto 24px;
}

.score-circle svg {
    transform: rotate(-90deg);
}

.circle-bg {
    fill: none;
    stroke: var(--border-color);
    stroke-width: 8;
}

.circle-progress {
    fill: none;
    stroke: url(#gradient);
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 283;
    stroke-dashoffset: 283;
    transition: stroke-dashoffset 1s ease;
}

.score-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.score-num {
    display: block;
    font-size: 56px;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
}

.score-label {
    font-size: 16px;
    color: var(--text-secondary);
    margin-top: 4px;
}

.score-status {
    font-size: 18px;
    font-weight: 600;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    display: inline-block;
}

.score-status.good {
    background: rgba(76, 175, 80, 0.1);
    color: #4CAF50;
}

.score-status.warning {
    background: rgba(255, 152, 0, 0.1);
    color: #FF9800;
}

.score-status.caution {
    background: rgba(255, 140, 0, 0.1);
    color: #FF8C00;
}

.score-status.danger {
    background: rgba(244, 67, 54, 0.1);
    color: #F44336;
}

/* 概览统计 */
.overview-stats {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stat-box {
    background: white;
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
}

.stat-box .stat-label {
    font-size: 16px;
    color: var(--text-secondary);
}

.stat-box .stat-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
}

/* 维度结果 */
.factors-result {
    background: white;
    border-radius: var(--radius-lg);
    padding: 40px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-sm);
}

.factors-result h2 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 28px;
}

.factors-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.factor-result-card {
    background: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 24px;
    border-left: 4px solid var(--primary-color);
}

.factor-result-card.warning {
    border-left-color: var(--warning-color);
}

.factor-result-card.danger {
    border-left-color: var(--danger-color);
}

.factor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.factor-name {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
}

.factor-score {
    font-size: 24px;
    font-weight: 700;
}

.factor-score.normal {
    color: var(--success-color);
}

.factor-score.warning {
    color: var(--warning-color);
}

.factor-score.danger {
    color: var(--danger-color);
}

.factor-bar {
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 8px;
}

.factor-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.6s ease;
}

.factor-bar-fill.normal {
    background: var(--success-color);
}

.factor-bar-fill.warning {
    background: var(--warning-color);
}

.factor-bar-fill.danger {
    background: var(--danger-color);
}

.factor-desc {
    font-size: 13px;
    color: var(--text-secondary);
}

/* 建议区域 */
.result-suggestions {
    background: white;
    border-radius: var(--radius-lg);
    padding: 40px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-sm);
}

.result-suggestions h2 {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 28px;
}

.suggestion-item {
    padding: 24px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    margin-bottom: 16px;
}

.suggestion-item:last-child {
    margin-bottom: 0;
}

.suggestion-item h4 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.suggestion-item p {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
}

.suggestion-item ul {
    margin-top: 12px;
    padding-left: 20px;
}

.suggestion-item li {
    font-size: 14px;
    color: var(--text-secondary);
    padding: 4px 0;
}

/* 结果操作 */
.result-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 32px;
}

.result-actions .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.result-actions .btn svg {
    width: 18px;
    height: 18px;
}

/* 结果声明 */
.result-notice {
    background: linear-gradient(135deg, #FFF3E0 0%, #FFE0B2 100%);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.result-notice .notice-icon {
    font-size: 28px;
    flex-shrink: 0;
}

.result-notice h4 {
    font-size: 17px;
    font-weight: 600;
    color: #E65100;
    margin-bottom: 8px;
}

.result-notice p {
    font-size: 15px;
    color: #BF360C;
    line-height: 1.7;
}

/* 打印样式 */
@media print {
    .navbar,
    .result-actions,
    .footer {
        display: none !important;
    }
    
    .test-result {
        padding: 20px 0;
    }
    
    .result-overview,
    .factors-result,
    .result-suggestions,
    .result-notice {
        box-shadow: none;
        border: 1px solid #ddd;
        break-inside: avoid;
    }
}

/* 响应式 */
@media (max-width: 768px) {
    .intro-cards {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .rating-scale {
        flex-wrap: wrap;
    }
    
    .rating-item {
        flex: 1 1 calc(50% - 6px);
    }
    
    .result-overview {
        grid-template-columns: 1fr;
    }
    
    .factors-grid {
        grid-template-columns: 1fr;
    }
    
    .question-box {
        padding: 32px 24px;
    }
    
    .question-text {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    .intro-cards {
        grid-template-columns: 1fr;
    }
    
    .rating-item {
        flex: 1 1 100%;
    }
    
    .result-actions {
        flex-direction: column;
    }
    
    .result-actions .btn {
        width: 100%;
        justify-content: center;
    }
}
