/* Deneme sonuc sayfasi ekleri (public/exam-result.php, includes/exams/result-insights.php):
   konu analizi, en yavas 3 soru, soru gezgini, soru suresi, acilir cozumler */

.tp-insights { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 16px; margin: 0 0 36px; }
.tp-insights.is-single { grid-template-columns: minmax(0, 1fr); }
.tp-card { min-width: 0; padding: 20px 22px; background: var(--white, #fff); border: 1px solid rgba(20,33,61,0.08); border-radius: 18px; box-shadow: 0 12px 32px -24px rgba(20,33,61,0.3); }
.tp-card-head { margin-bottom: 14px; }
.tp-card-head h2 { display: flex; align-items: center; gap: 8px; margin: 0 0 4px; font-family: var(--hm-display); font-size: 19px; font-weight: 700; color: var(--hm-ink); }
.tp-card-head h2 i { color: var(--th-sky, #1f7fbf); }
.tp-card-head p { margin: 0; font-size: 14px; color: var(--hm-muted); }

.tp-topic-list { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.tp-topic-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.tp-topic-name { min-width: 0; font-size: 15.5px; font-weight: 600; color: var(--hm-ink); overflow-wrap: anywhere; }
.tp-badge { flex-shrink: 0; padding: 3px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.tp-badge.is-strong { background: #e6f7f0; color: #0a7250; }
.tp-badge.is-improve { background: #fff4d1; color: #6b4f00; }
.tp-badge.is-weak { background: #fdeeee; color: #b4232a; }
.tp-bar { height: 8px; overflow: hidden; border-radius: 999px; background: var(--hm-paper, #f3f5f8); }
.tp-bar span { display: block; height: 100%; min-width: 2px; border-radius: inherit; }
.tp-topic.is-strong .tp-bar span { background: var(--hm-mint, #0e9f6e); }
.tp-topic.is-improve .tp-bar span { background: var(--hm-gold, #e0a400); }
.tp-topic.is-weak .tp-bar span { background: var(--hm-coral, #e5484d); }
.tp-topic-meta { display: flex; justify-content: space-between; gap: 10px; margin-top: 5px; font-size: 13.5px; color: var(--hm-muted); }
.tp-topic-meta strong { color: var(--hm-ink); }
.tp-legend { margin: 14px 0 0; font-size: 12.5px; color: var(--hm-muted); }

.tp-slow-list { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.tp-slow-item { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 14px; border: 1px solid rgba(20,33,61,0.1); border-radius: 14px; color: var(--hm-ink); text-decoration: none; }
.tp-slow-num { display: flex; align-items: center; justify-content: center; flex-shrink: 0; width: 34px; height: 34px; border-radius: 50%; font-size: 14px; font-weight: 700; color: #fff; background: var(--hm-muted); }
.tp-slow-num.is-correct, .tp-dot.is-correct { background: var(--hm-mint, #0e9f6e); }
.tp-slow-num.is-wrong, .tp-dot.is-wrong { background: var(--hm-coral, #e5484d); }
.tp-slow-text { flex: 1 1 auto; min-width: 0; font-weight: 600; }
.tp-slow-text small { display: block; font-size: 12.5px; font-weight: 500; color: var(--hm-muted); }
.tp-slow-time { font-variant-numeric: tabular-nums; font-size: 15px; }
.tp-slow-item:focus-visible, .tp-dot:focus-visible, .tp-toggle-all:focus-visible, .tp-sol-sum:focus-visible { outline: 3px solid var(--hm-gold, #e0a400); outline-offset: 2px; }

/* Soru gezgini */
.tp-qnav { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.tp-dot { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; font-size: 14px; font-weight: 700; color: #fff; text-decoration: none; transition: opacity 0.15s ease; }
.tp-dot.is-empty { background: var(--hm-paper, #f3f5f8); color: var(--hm-muted); border: 1px solid rgba(20,33,61,0.12); }
.tp-dot.is-dim { opacity: 0.3; }

.tp-tools { display: flex; justify-content: flex-end; margin: 0 0 14px; }
.tp-tools[hidden] { display: none; }
.tp-toggle-all { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid rgba(20,33,61,0.12); border-radius: 999px; background: var(--white, #fff); color: var(--hm-ink); font: inherit; font-size: 14.5px; font-weight: 600; cursor: pointer; }
.tp-toggle-all i { color: #e0a400; }

/* Soru suresi (kart basligi) */
.rs-card-head .tp-time { display: inline-flex; align-items: center; gap: 5px; margin-inline-start: auto; font-size: 13.5px; font-weight: 600; color: var(--hm-muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.rs-card { scroll-margin-top: 90px; }
.rs-card:focus { outline: none; }
.rs-card:focus-visible { outline: 3px solid var(--hm-gold, #e0a400); outline-offset: 2px; }

/* Acilir cozum */
.tp-sol > summary { list-style: none; }
.tp-sol > summary::-webkit-details-marker { display: none; }
.tp-sol-sum { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; margin: -6px 0; cursor: pointer; }
.rs-explain.tp-sol .tp-sol-sum h4 { margin: 0; }
.tp-sol[open] > .tp-sol-sum { margin-bottom: 6px; }
.tp-sol-chev { flex-shrink: 0; color: var(--hm-muted); transition: transform 0.2s ease; }
.tp-sol[open] .tp-sol-chev { transform: rotate(180deg); }

@media (hover: hover) {
    .tp-slow-item:hover, .tp-toggle-all:hover { background: var(--hm-paper, #f3f5f8); }
    .tp-dot:not(.is-dim):hover { opacity: 0.85; }
}
@media (max-width: 900px) {
    .tp-insights { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
@media (max-width: 640px) {
    .tp-insights { grid-template-columns: minmax(0, 1fr); margin-bottom: 28px; }
    .tp-card { padding: 16px; }
    .tp-qnav { gap: 5px; }
    .tp-tools { justify-content: stretch; }
    .tp-toggle-all { flex: 1 1 100%; justify-content: center; }
    .rs-card-head { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
    .tp-sol-chev, .tp-dot { transition: none; }
}
