/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'PingFang SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 30px;
    min-height: calc(100vh - 100px);
}

/* 头部样式 */
header {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, #4a6fa5 0%, #2c3e50 100%);
    color: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(44, 62, 80, 0.2);
    margin-bottom: 20px;
}

.header-content {
    max-width: 800px;
    margin: 0 auto;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 15px;
}

header h1 i {
    font-size: 2.2rem;
    color: #64b5f6;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 25px;
}

.progress-container {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    padding: 5px;
    position: relative;
    height: 40px;
}

.progress-bar {
    background: linear-gradient(90deg, #4fc3f7 0%, #29b6f6 100%);
    height: 30px;
    border-radius: 50px;
    width: 10%;
    transition: width 0.5s ease;
    position: relative;
    overflow: hidden;
}

.progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.2) 50%, 
        transparent 100%);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: 500;
    font-size: 1.1rem;
}

/* 主要内容区域 */
main {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    grid-column: 1;
}

.question-container {
    min-height: 400px;
}

.question-card {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.question-number {
    color: #4a6fa5;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.question-text {
    font-size: 1.4rem;
    font-weight: 500;
    margin-bottom: 30px;
    line-height: 1.5;
    color: #2c3e50;
}

.options-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.option {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 15px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 15px;
}

.option:hover {
    background: #edf2f7;
    border-color: #c5d5ea;
    transform: translateY(-2px);
}

.option.selected {
    background: #e3f2fd;
    border-color: #4fc3f7;
    box-shadow: 0 5px 15px rgba(79, 195, 247, 0.2);
}

.option-letter {
    width: 40px;
    height: 40px;
    background: #4a6fa5;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.option.selected .option-letter {
    background: #4fc3f7;
}

.option-text {
    font-size: 1.1rem;
    flex-grow: 1;
}

/* 导航按钮 */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
    gap: 15px;
}

.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 150px;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(0, 0, 0, 0.15);
}

.btn:active {
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, #4a6fa5 0%, #3a5985 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #3a5985 0%, #2c3e50 100%);
}

.btn-secondary {
    background: #e9ecef;
    color: #495057;
}

.btn-secondary:hover {
    background: #dee2e6;
}

.btn-submit {
    background: linear-gradient(135deg, #4caf50 0%, #388e3c 100%);
    color: white;
    display: none;
}

.btn-submit:hover {
    background: linear-gradient(135deg, #388e3c 0%, #2e7d32 100%);
}

.btn-guide {
    background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%);
    color: white;
}

/* 信息面板 */
.info-panel {
    grid-column: 2;
}

.info-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 20px;
}

.info-card h3 {
    color: #4a6fa5;
    font-size: 1.3rem;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-card p {
    margin-bottom: 20px;
    color: #666;
}

.info-card ul {
    list-style: none;
}

.info-card li {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #555;
}

.info-card li i {
    color: #4fc3f7;
    width: 20px;
}

/* 结果容器 */
.result-container {
    grid-column: 1 / -1;
    animation: fadeIn 0.5s ease;
}

.result-card {
    background: white;
    border-radius: 20px;
    padding: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.result-header {
    text-align: center;
    margin-bottom: 40px;
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.low-risk .result-icon {
    color: #4caf50;
}

.medium-risk .result-icon {
    color: #ff9800;
}

.high-risk .result-icon {
    color: #f44336;
}

.result-title {
    font-size: 2.2rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #2c3e50;
}

.result-score {
    display: inline-block;
    background: #e3f2fd;
    color: #4a6fa5;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
}

.result-content {
    max-width: 800px;
    margin: 0 auto;
}

.result-section {
    margin-bottom: 30px;
}

.result-section h4 {
    color: #4a6fa5;
    font-size: 1.3rem;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.result-section p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #555;
    margin-bottom: 15px;
}

.recommendations {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 25px;
    margin-top: 30px;
}

.recommendations ul {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.recommendations li {
    background: white;
    padding: 15px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.recommendations li i {
    color: #4fc3f7;
    font-size: 1.2rem;
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

/* 底部 */
footer {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px 0;
    color: #666;
    font-size: 0.95rem;
    border-top: 1px solid #e9ecef;
    margin-top: 30px;
}

footer a {
    color: #4a6fa5;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

.disclaimer {
    font-size: 0.85rem;
    color: #888;
    margin-top: 10px;
    font-style: italic;
}

/* 加载动画 */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-spinner {
    text-align: center;
}

.loading-spinner i {
    font-size: 4rem;
    color: #4a6fa5;
    margin-bottom: 20px;
}

.loading-spinner p {
    font-size: 1.2rem;
    color: #666;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .info-panel {
        grid-column: 1;
    }
    
    .info-card {
        position: static;
    }
}

@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    header {
        padding: 20px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    main {
        padding: 25px;
    }
    
    .question-text {
        font-size: 1.2rem;
    }
    
    .option {
        padding: 15px;
    }
    
    .navigation-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .result-card {
        padding: 30px;
    }
    
    .result-title {
        font-size: 1.8rem;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .recommendations ul {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .header-content {
        padding: 0 10px;
    }
    
    .question-text {
        font-size: 1.1rem;
    }
    
    .option-text {
        font-size: 1rem;
    }
    
    .result-card {
        padding: 20px;
    }
}