/* ==========================================================================
   测评详情页 (t01-t72) 通用样式表
   提取自各量表 HTML 文件的内联样式，用于统一维护视觉风格。
   ========================================================================== */

.stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    height: 100%;
    border: 1px solid #eee;
}
.stat-card h5 {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 15px;
}
.stat-values {
    display: flex;
    justify-content: space-around;
    margin-bottom: 15px;
}
.stat-values .v {
    text-align: center;
}
.stat-values .v b {
    font-size: 1.5rem;
    display: block;
    color: var(--t11-green-dark);
}
.stat-values .v span {
    font-size: 0.75rem;
    color: #999;
}
.tag-sev {
    background-color: #f8d7da;
    color: #842029;
    border: 1px solid #f5c2c7;
}
.score-legend {
    display: flex;
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0;
    flex-wrap: wrap;
}
.score-legend li {
    font-size: 0.85rem;
    background: #f8f9fa;
    padding: 4px 10px;
    border-radius: 20px;
}
.score-legend b {
    margin-right: 5px;
    color: var(--t11-green-dark);
}

.opt-btn {
    background: #fff;
    border: 2px solid #eee;
    border-radius: 12px;
    padding: 15px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    text-align: left;
    position: relative;
    overflow: hidden;
}
.opt-btn:hover {
    border-color: #fd7e14;
    background: rgba(253, 126, 20, 0.02);
}
.opt-btn.selected {
    border-color: #fd7e14;
    background: rgba(253, 126, 20, 0.08);
    box-shadow: 0 4px 12px rgba(253, 126, 20, 0.1);
}
.opt-btn .opt-num {
    background: #f0f0f0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.85rem;
    color: #666;
    transition: all 0.2s ease;
}
.opt-btn.selected .opt-num {
    background: #fd7e14;
    color: white;
}

.quiz-nav .btn {
    border-radius: 10px;
    padding: 10px 25px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-link-back {
    color: #64748b;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px !important;
    border-radius: 8px;
    background: #f1f5f9;
}
.btn-link-back:hover {
    color: #fd7e14;
    background: #fff7ed;
    text-decoration: none;
}
.text-orange {
    color: #c2410c !important;
}

.bg-orange-light {
    background-color: #fff9f2 !important;
}

/* 针对所有板块标题统一颜色（量表说明、编制依据、免责声明、评分方式） */
.quiz-card .rule-box h6,
.quiz-card .rule-box h6 i,
.quiz-card .rule-box h6 span,
.quiz-card .warn-box h6,
.quiz-card .warn-box h6 i,
.quiz-card .warn-box h6 span,
.quiz-card .tip-box h6,
.quiz-card .tip-box h6 i,
.quiz-card .tip-box h6 span {
    color: #c2410c !important;
    font-weight: 700 !important;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

/* 统一结果页板块正文字号 */
.quiz-card .rule-box p,
.quiz-card .warn-box p {
    font-size: 0.95rem !important;
    line-height: 1.6;
}

/* 折叠面板美化 - 仅针对主标题 */
.quiz-card > .rule-box > h6 {
    margin-bottom: 0;
    padding-right: 5px;
}
.quiz-card > .rule-box > h6 .chevron-icon {
    transition: transform 0.3s ease;
    font-size: 0.9rem;
    opacity: 0.5;
}
.quiz-card > .rule-box > h6[aria-expanded="true"] .chevron-icon {
    transform: rotate(180deg);
    opacity: 1;
}
.source-content-inner {
    padding: 10px 0 5px 12px;
    border-left: 2px solid #ffe8cc;
    margin-left: 8px;
    margin-top: 10px;
}

/* 科普介绍版块样式 */
.info-section {
    margin-top: 5rem;
    padding-top: 2rem;
    border-top: 1px dashed #ffe8cc;
}
.info-item {
    margin-bottom: 2.5rem;
}
.info-item h4 {
    font-size: 1.15rem;
    color: #c2410c;
    font-weight: 700;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 10px;
}
.info-item h4::before {
    content: "";
    width: 4px;
    height: 18px;
    background: #fd7e14;
    border-radius: 2px;
    display: inline-block;
}
.info-item p {
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.7;
    margin-bottom: 0.5rem;
    text-align: justify;
}
.info-item strong {
    color: #d9480f;
}

/* 结果页推荐卡片图标样式 */
.tip-card-body {
    display: flex;
    align-items: center;
    gap: 15px;
}
.tip-card-content {
    flex-grow: 1;
}
.tip-card-icon {
     width: 140px;
     height: 140px;
     object-fit: cover;
     border-radius: 12px;
     box-shadow: 0 4px 12px rgba(0,0,0,0.15);
     flex-shrink: 0;
 }

/* 答题详情复盘样式 */
.answer-review {
    transition: all 0.3s ease;
}
.answer-review-header {
    cursor: pointer;
    padding: 14px 18px;
    border-radius: 10px;
    background: linear-gradient(135deg, #fd7e14, #ff922b);
    color: white;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(253, 126, 20, 0.15);
    border: 1px solid transparent;
}
.answer-review-header h6, 
.answer-review-header .review-toggle-icon {
    color: white !important;
    transition: color 0.3s ease;
}
.answer-review-header:hover {
    background: #fff7ed;
    transform: translateY(-1px);
    box-shadow: 0 6px 15px rgba(253, 126, 20, 0.1);
    border-color: #ffe8cc;
}
.answer-review-header:hover h6, 
.answer-review-header:hover .review-toggle-icon {
    color: #c2410c !important;
}
.answer-review-item {
    border-bottom: 1px dashed #eee;
    padding: 12px 0;
}
.answer-review-item:last-child {
    border-bottom: none;
}
.answer-review-item .q-text {
    font-size: 0.9rem;
    color: #334155;
    margin-bottom: 4px;
}
.answer-review-item .q-ans {
    font-size: 0.85rem;
    color: #fd7e14;
    font-weight: 600;
}
.answer-review-item .q-note {
    font-size: 0.75rem;
    color: #94a3b8;
}
.review-toggle-icon {
    transition: transform 0.3s ease;
}
.collapsed .review-toggle-icon {
    transform: rotate(-90deg);
}

@media (max-width: 576px) {
    .tip-card-body {
        flex-direction: row;
        align-items: flex-start;
        gap: 12px;
    }
    .tip-card-icon {
        width: 80px;
        height: 80px;
        margin-bottom: 0;
    }
    .tip-card-content h6 {
        font-size: 0.95rem;
    }
    .tip-card-content p {
        font-size: 0.85rem;
        margin-bottom: 8px !important;
    }
}
.extra-small { font-size: 0.75rem !important; }
.text-flash-red {
    font-weight: bold;
    animation: color-shift 3s infinite;
}

/* 修复结果页右侧插图在滚动时覆盖导航栏的问题 */
.sticky-top {
    z-index: 990 !important; /* 低于 common.css 中 .navbar 的 1000 */
}

/* 强制结果 Banner 中的标题居中，防止被 quiz.css 中的 .quiz-card h2 { text-align: left } 覆盖 */
.result-banner h2, 
.result-banner h3, 
.result-banner h4, 
.result-banner h5 {
    text-align: center !important;
}

@keyframes color-shift {
    0%, 100% { color: #ff4d4f; }
    50% { color: #3b82f6; }
}

/* 测评记录入口卡片 */
.record-link-card {
    background: linear-gradient(135deg, #fff5eb 0%, #fff 100%);
    border: 1px dashed #fd7e14;
    border-radius: 16px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
    text-decoration: none !important;
    margin-top: 1rem;
    position: relative;
    overflow: hidden;
}
.record-link-card::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 60px;
    height: 60px;
    background: radial-gradient(circle at top right, rgba(253, 126, 20, 0.05) 0%, transparent 70%);
    pointer-events: none;
}
.record-link-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(253, 126, 20, 0.12);
    border-style: solid;
    background: #fff9f2;
}
.record-link-icon {
    width: 48px;
    height: 48px;
    background: #fd7e14;
    color: white;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
    box-shadow: 0 4px 10px rgba(253, 126, 20, 0.2);
}
.record-link-content {
    flex-grow: 1;
}
.record-link-content h6 {
    margin-bottom: 4px !important;
    color: #c2410c !important;
    font-weight: 700 !important;
    font-size: 1rem !important;
}
.record-link-content p {
    margin-bottom: 0 !important;
    font-size: 0.85rem !important;
    color: #64748b !important;
    line-height: 1.4 !important;
}

/* 生成图片时的水印 */
.share-watermark {
    display: none;
    text-align: center;
    padding: 20px;
    background: #f8f9fa;
    border-top: 1px solid #eee;
    margin-top: 20px;
    border-radius: 0 0 16px 16px;
}
.share-watermark p {
    margin: 0;
    color: #64748b;
    font-size: 0.85rem;
}
.share-watermark b {
    color: #fd7e14;
}

/* 版本选择卡片样式 (t11 等多版本量表) */
.version-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}
.version-card {
    background: #fff;
    border: 2px solid #eee;
    border-radius: 16px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.version-card:hover {
    border-color: #fd7e14;
    background: #fffcf9;
}
.version-card.selected {
    border-color: #fd7e14;
    background: #fff7ed;
    box-shadow: 0 8px 20px rgba(253, 126, 20, 0.1);
}
.version-card input[type="radio"] {
    position: absolute;
    opacity: 0;
}
.vc-title {
    font-weight: 700;
    font-size: 1.1rem;
    color: #c2410c;
}
.vc-meta {
    font-size: 0.8rem;
    color: #94a3b8;
}
.vc-desc {
    font-size: 0.9rem;
    color: #475569;
    margin: 0;
    line-height: 1.5;
}

/* ASRS/WURS 专用样式 */
.question-en {
    font-size: 0.9rem;
    color: #64748b;
    font-style: italic;
    margin-top: -10px;
    margin-bottom: 15px;
    line-height: 1.5;
}
.opt-grid-5 {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
}
.tier {
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 25px;
    text-align: center;
}
.tier.low { background: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; }
.tier.mid { background: #fffbeb; border: 1px solid #fde68a; color: #92400e; }
.tier.high { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.t-name { font-size: 1.4rem; font-weight: 800; margin-bottom: 8px; }
.t-mean { font-size: 0.95rem; opacity: 0.9; }

.stat-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}
.stat-item {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 15px;
    text-align: center;
}
.stat-item.hit { border-color: #fecaca; background: #fff5f5; }
.stat-item .s-label { font-size: 0.8rem; color: #64748b; margin-bottom: 5px; }
.stat-item .s-value { font-size: 1.5rem; font-weight: 700; color: #1e293b; }
.stat-item.hit .s-value { color: #dc2626; }
.stat-item .s-note { font-size: 0.75rem; color: #94a3b8; margin-top: 5px; }

@media (max-width: 576px) {
    .opt-grid-5 {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

/* MBTI 结果页特有样式 */
.type-display {
    font-size: 4rem;
    font-weight: 900;
    color: #fd7e14;
    letter-spacing: 4px;
    line-height: 1;
    margin-bottom: 0.5rem;
}
.type-title {
    font-size: 1.5rem;
    color: #334155;
    font-weight: 700;
    margin-bottom: 1.5rem;
}
.dim-bar-container {
    margin-bottom: 1.5rem;
}
.dim-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 6px;
    color: #64748b;
}
.dim-progress {
    height: 24px;
    background: #f1f5f9;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    position: relative;
}
.dim-fill-left {
    height: 100%;
    background: #fd7e14;
    display: flex;
    align-items: center;
    padding-left: 12px;
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.dim-fill-right {
    height: 100%;
    background: #3b82f6;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 12px;
    color: white;
    font-size: 0.75rem;
    font-weight: bold;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
.opt-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

@media (max-width: 576px) {
    .opt-grid-2 {
        grid-template-columns: 1fr;
    }
    .type-display {
        font-size: 3rem;
    }
}
