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

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f7fa;
}

/* 容器样式 */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

/* 头部样式 */
.header {
    text-align: center;
    margin-bottom: 30px;
    padding: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    color: white;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.header h1 {
    font-size: 2.8em;
    margin-bottom: 15px;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header p {
    font-size: 1.2em;
    opacity: 0.9;
}

/* 进度条容器 */
.progress-container {
    margin-bottom: 25px;
}

.progress-bar {
    width: 100%;
    height: 12px;
    background-color: #e8ebf1;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 6px;
    transition: width 0.5s ease;
}

.progress-text {
    text-align: center;
    font-size: 0.9em;
    color: #666;
    font-weight: 500;
}

/* 测试容器 */
.quiz-container {
    background: white;
    border-radius: 15px;
    padding: 35px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

/* 问题容器 */
.question-container {
    text-align: center;
}

.question {
    font-size: 1.5em;
    margin-bottom: 35px;
    color: #2c3e50;
    font-weight: 600;
    line-height: 1.5;
}

.options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
    max-width: 700px;
    margin: 0 auto;
}

.option {
    padding: 20px 25px;
    border: 2px solid #e0e6ed;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    font-size: 1.1em;
    background-color: white;
}

.option:hover {
    background-color: #f8faff;
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.1);
}

.option.selected {
    background-color: #e8f4ff;
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

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

.nav-btn {
    padding: 15px 40px;
    border: none;
    border-radius: 8px;
    font-size: 1.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

#prev-btn {
    background-color: #90a4ae;
    color: white;
}

#next-btn {
    background-color: #667eea;
    color: white;
}

.nav-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.nav-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

/* 结果容器 - 主要样式 */
.result-container {
    background: white;
    border-radius: 15px;
    padding: 35px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

/* 结果头部 */
.result-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    color: white;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.result-title {
    font-size: 2.5em;
    margin-bottom: 15px;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.result-subtitle {
    font-size: 1.2em;
    opacity: 0.9;
}

/* 各部分通用标题样式 */
.section-title {
    font-size: 1.8em;
    margin-bottom: 25px;
    color: #2c3e50;
    text-align: center;
    font-weight: 700;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
}

/* 饼状图部分 */
.chart-section {
    text-align: center;
    margin-bottom: 45px;
}

.chart-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f8faff;
    border-radius: 15px;
    padding: 40px 30px;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.05);
    min-height: 500px;
}

/* 颜色得分部分 */
.score-section {
    margin-bottom: 45px;
}

.score-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.score-item {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    border-left: 4px solid #667eea;
    transition: transform 0.3s ease;
}

.score-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.score-item.red {
    border-left-color: #ff6b6b;
}

.score-item.blue {
    border-left-color: #4facfe;
}

.score-item.yellow {
    border-left-color: #ffd43b;
}

.score-item.green {
    border-left-color: #69db7c;
}

.score-info {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.score-icon {
    font-size: 2em;
}

.score-name {
    font-size: 1.2em;
    font-weight: 600;
    color: #333;
}

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

.score-value {
    font-size: 1.5em;
    font-weight: 700;
    color: #333;
}

.score-percentage {
    font-size: 1em;
    color: #666;
    font-weight: 500;
}

.score-bar {
    flex: 1;
    height: 8px;
    background-color: #f0f0f0;
    border-radius: 4px;
    margin: 0 15px;
    overflow: hidden;
}

.score-fill {
    height: 100%;
    border-radius: 6px;
    transition: width 0.8s ease;
}

.score-fill.red {
    background-color: #ff6b6b;
}

.score-fill.blue {
    background-color: #4facfe;
}

.score-fill.yellow {
    background-color: #ffd43b;
}

.score-fill.green {
    background-color: #69db7c;
}

.score-description {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

.color-traits, .color-keywords {
    margin-bottom: 8px;
    font-size: 0.9em;
    color: #666;
}

.color-traits strong, .color-keywords strong {
    color: #333;
    font-weight: 600;
}

/* 性格分析部分 */
.analysis-section {
    margin-bottom: 45px;
}

.personality-summary {
    background: white;
    padding: 35px;
    border-radius: 15px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    border-top: 5px solid #667eea;
}

.personality-header {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}

.personality-icon {
    font-size: 3em;
    margin-right: 20px;
}

.personality-title h2 {
    color: #333;
    margin-bottom: 10px;
    font-size: 2em;
}

.personality-title p {
    color: #666;
    font-size: 1.1em;
    line-height: 1.6;
}

.personality-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

.personality-section h3 {
    color: #333;
    margin-bottom: 15px;
    font-size: 1.3em;
}

.advantage-list, .challenge-list {
    display: grid;
    gap: 10px;
}

.advantage-item, .challenge-item {
    background-color: #f8f9fa;
    padding: 12px 16px;
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
    color: #555;
    font-size: 14px;
    line-height: 1.5;
}

.challenge-item {
    border-left-color: #FF9800;
}

.secondary-personality {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid #e9ecef;
    display: flex;
    align-items: center;
}

.secondary-personality .personality-icon {
    font-size: 2.5em;
}

.secondary-personality .personality-title h3 {
    color: #666;
    font-size: 1.5em;
    margin-bottom: 8px;
}

.secondary-personality .personality-title p {
    font-size: 1em;
    color: #888;
}

/* 性格特点部分 */
.traits-section {
    margin-bottom: 45px;
}

.strengths-weaknesses {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.strengths-column, .weaknesses-column {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.strengths-column {
    border-top: 4px solid #69db7c;
}

.weaknesses-column {
    border-top: 4px solid #ff6b6b;
}

.strengths-column h4, .weaknesses-column h4 {
    font-size: 1.3em;
    margin-bottom: 20px;
    color: #2c3e50;
    text-align: center;
}

.strengths-column h4 {
    color: #2b8a3e;
}

.weaknesses-column h4 {
    color: #c92a2a;
}

.traits-list {
    list-style: none;
    padding: 0;
}

.strength-item, .weakness-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    color: #555;
    font-size: 14px;
}

.strength-item:last-child, .weakness-item:last-child {
    border-bottom: none;
}

.strength-icon, .weakness-icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    margin-top: 2px;
}

.strength-text, .weakness-text {
    flex: 1;
    line-height: 1.5;
}

.strengths-column .strength-icon {
    color: #2b8a3e;
}

.weaknesses-column .weakness-icon {
    color: #c92a2a;
}

/* 职业建议部分 */
.career-section {
    margin-bottom: 45px;
}

.career-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.career-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    text-align: center;
    transition: transform 0.3s ease;
    border-top: 4px solid #667eea;
}

.career-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.career-icon {
    font-size: 3em;
    margin-bottom: 15px;
    display: block;
}

.career-name {
    font-size: 1.2em;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.career-description {
    color: #666;
    font-size: 0.95em;
    line-height: 1.5;
}

/* 人际关系建议部分 */
.relationship-section {
    margin-bottom: 45px;
}

.tips-content {
    display: grid;
    gap: 15px;
    margin-top: 20px;
}

.tip-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: transform 0.3s ease;
}

.tip-item:hover {
    transform: translateX(5px);
}

.tip-number {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9em;
}

.tip-text {
    flex: 1;
    color: #555;
    line-height: 1.6;
    font-size: 0.95em;
}
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.career-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    border-top: 4px solid #667eea;
    text-align: center;
}

.career-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.career-icon {
    font-size: 2.5em;
    margin-bottom: 15px;
}

.career-name {
    font-size: 1.3em;
    font-weight: 700;
    margin-bottom: 15px;
    color: #2c3e50;
}

.career-description {
    color: #666;
    line-height: 1.7;
}

/* 人际关系建议部分 */
.relationship-section {
    margin-bottom: 45px;
}

.tips-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.tip-item {
    padding: 15px 0;
    border-bottom: 1px solid #f0f2f5;
    display: flex;
    align-items: flex-start;
}

.tip-item:last-child {
    border-bottom: none;
}

.tip-number {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    margin-right: 15px;
    flex-shrink: 0;
}

.tip-text {
    color: #555;
    line-height: 1.7;
    font-size: 1.05em;
}

/* 重新测试按钮 */
.restart-btn {
    display: block;
    margin: 40px auto 0;
    padding: 18px 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 1.2em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.restart-btn:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* 响应式设计 - 移动端优化 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .header h1 {
        font-size: 1.8em;
        margin-bottom: 10px;
    }
    
    .header p {
        font-size: 1em;
    }
    
    .quiz-container {
        padding: 20px;
    }
    
    .question {
        font-size: 1.2em;
        margin-bottom: 20px;
        line-height: 1.4;
    }
    
    .nav-btn {
        padding: 12px 25px;
        font-size: 0.9em;
    }
    
    .strengths-weaknesses {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .career-list {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .chart-wrapper {
        padding: 15px;
        min-height: 300px;
    }
    
    .personality-header {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }
    
    .color-badge {
        margin-bottom: 10px;
        margin-right: 0;
    }
    
    .score-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 15px;
    }
    
    .score-details {
        align-items: flex-start;
        margin-top: 10px;
        flex-direction: column;
        gap: 10px;
    }
    
    .score-bar {
        width: 100%;
        margin: 10px 0;
    }
    
    /* 结果页移动端优化 */
    .result-container {
        padding: 20px;
        margin: 10px;
    }
    
    .result-header {
        padding: 20px;
        margin-bottom: 25px;
    }
    
    .result-title {
        font-size: 1.8em;
        margin-bottom: 10px;
    }
    
    .result-subtitle {
        font-size: 1em;
    }
    
    .section-title {
        font-size: 1.4em;
        margin-bottom: 15px;
    }
    
    .chart-section, .score-section, .analysis-section, .traits-section, .career-section, .relationship-section {
        padding: 20px;
        margin: 15px 0;
    }
    
    .personality-summary {
        padding: 20px;
    }
    
    .personality-details {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .score-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .tips-content {
        padding: 20px;
    }
    
    .tip-item {
        padding: 15px 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .tip-number {
        margin-right: 0;
        margin-bottom: 10px;
    }
    
    .restart-btn {
        padding: 15px 30px;
        font-size: 1em;
        margin: 30px auto 0;
        width: 90%;
        max-width: 300px;
    }
    
    /* 特殊样式优化 */
    .development-section, .famous-section, .psychology-section {
        padding: 20px;
        margin: 20px 0;
    }
    
    .development-item {
        padding: 15px;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .famous-item {
        padding: 12px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .certification-badges {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    
    .cert-badge {
        min-width: auto;
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 5px;
    }
    
    .header h1 {
        font-size: 1.5em;
    }
    
    .quiz-container {
        padding: 15px;
    }
    
    .question {
        font-size: 1.1em;
        margin-bottom: 15px;
    }
    
    .option {
        padding: 12px 15px;
        font-size: 0.9em;
    }
    
    .nav-btn {
        padding: 10px 15px;
        font-size: 0.85em;
    }
    
    .section-title {
        font-size: 1.3em;
    }
    
    .score-name {
        font-size: 1.1em;
    }
    
    .personality-desc {
        font-size: 1em;
        padding: 0;
    }
    
    .restart-btn {
        padding: 12px 25px;
        font-size: 0.9em;
    }
    
    .result-title {
        font-size: 1.6em;
    }
    
    .result-container {
        padding: 15px;
        margin: 5px;
    }
    
    .result-header {
        padding: 15px;
    }
    
    .chart-wrapper {
        min-height: 250px;
        padding: 10px;
    }
    
    .career-card {
        padding: 15px;
    }
    
    .tip-item {
        padding: 10px 0;
    }
    
    /* 超小屏幕优化 */
    .score-value {
        font-size: 1.3em;
    }
    
    .personality-icon {
        font-size: 2em;
    }
    
    .career-icon {
        font-size: 2em;
    }
    
    .development-number {
        width: 30px;
        height: 30px;
        font-size: 0.9em;
    }
    
    .tip-number {
        width: 25px;
        height: 25px;
        font-size: 0.8em;
    }
}