.report-body { line-height: var(--leading-prose); }
/* Justified prose, matching the document reader; see the note in style.css for
   why word-break stays normal. Tables, code blocks and headings are excluded. */
.report-body p,
.report-body li,
.report-body blockquote { text-align: justify; word-break: normal; hyphens: auto; }
.report-body h1 { font-size: 1.6em; margin: 1.2em 0 0.6em; border-bottom: 1px solid var(--border); padding-bottom: 0.3em; }
.report-body h2 { font-size: 1.3em; margin: 1em 0 0.5em; }
.report-body h3 { font-size: 1.1em; margin: 0.8em 0 0.4em; }
.report-body p { margin: 0.6em 0; }
.report-body ul, .report-body ol { margin: 0.5em 0; padding-left: 1.5em; }
.report-body li { margin: 0.3em 0; }
.report-body blockquote { border-left: 3px solid var(--border-emphasis); padding-left: 1em; margin: 0.8em 0; color: var(--text-secondary); }
.report-body code { background: var(--code-bg); padding: 0.15em 0.4em; border-radius: 0; font-size: 0.9em; }
.report-body pre { background: var(--code-bg); padding: 1em; border-radius: 0; overflow-x: auto; border: 1px solid var(--border); }
.report-body pre code { background: none; padding: 0; }
.report-body table { border-collapse: collapse; width: 100%; margin: 0.8em 0; }
.report-body th, .report-body td { border: 1px solid var(--border); padding: 0.5em 0.8em; text-align: left; }
.report-body th { background: var(--bg-surface); }
.report-body a { color: var(--link); }
.report-task-label { color: var(--text-muted); font-size: 0.9em; }
.report-task-details { margin-bottom: 0.5em; }
.report-task-details summary { color: var(--link); font-size: 0.85em; cursor: pointer; }
.report-task-content { color: var(--text-secondary); font-size: 0.85em; white-space: pre-wrap; margin-top: 0.3em; padding-left: 0.5em; border-left: 1px solid var(--border); }
.report-id { font-size: 0.65em; color: var(--text-muted); margin-right: 0.4em; vertical-align: middle; }

.research-series-nav {
    position: static;
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent);
    margin: 14px 0 20px;
    background: var(--bg-surface);
    padding: 0;
    z-index: auto;
}

.research-series-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border);
}

.research-series-label {
    color: var(--text-muted);
    font-size: 0.72rem;
    line-height: var(--leading-tight);
}

.research-series-header h2 {
    font-size: 0.92rem;
    line-height: var(--leading-tight);
    margin: 2px 0 0;
}

.research-series-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    flex: 0 0 auto;
}

.research-series-actions .btn { white-space: nowrap; }

.research-series-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.research-series-list li + li {
    border-top: 1px solid var(--border);
}

.research-series-list a,
.research-series-list span {
    display: flex;
    gap: 8px;
    padding: 7px 10px;
    color: var(--text-primary);
    font-size: 0.84rem;
    line-height: var(--leading-tight);
}

.research-series-list a:hover {
    background: var(--bg-surface-hover);
    color: var(--link);
    text-decoration: none;
}

.research-series-list li.current > span {
    background: var(--bg-surface-hover);
    color: var(--accent-red);
    font-weight: 600;
}

.research-series-episode {
    flex: 0 0 auto;
    min-width: 1.8em;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
}

@media (max-width: 560px) {
    .research-series-header {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .research-series-actions {
        justify-content: stretch;
    }

    .research-series-actions a {
        flex: 1;
    }
}

/* CommuLingo entity links inside report prose: quiet dashed underline, same
   vocabulary as the dictionary pages (see commulingo.css .commu-person-link). */
.report-body .commu-person-link,
.report-body .commu-topic-link,
.report-body .commu-term-link,
.report-body .commu-event-link {
    color: inherit;
    text-decoration: none;
    /* Full-strength link green: a low-opacity currentColor dash was invisible
       against the dark canvas. */
    border-bottom: 2px dashed var(--link, #5d7a5a);
}

.report-body .commu-person-link:hover,
.report-body .commu-topic-link:hover,
.report-body .commu-term-link:hover,
.report-body .commu-event-link:hover {
    border-bottom-style: solid;
}

/* Deep links from 관련 보고서 sections land on a first-mention anchor:
   keep it clear of the sticky nav and flag the landing spot. */
.report-body .commu-person-link,
.report-body .commu-topic-link,
.report-body .commu-term-link,
.report-body .commu-event-link {
    scroll-margin-top: 90px;
}

.report-body a:target {
    background: color-mix(in srgb, var(--link, #5d7a5a) 30%, transparent);
}

.report-body .commu-event-link {
    color: var(--accent-red, #b84f4f);
    border-bottom-color: color-mix(in srgb, currentColor 80%, transparent);
}

/* Related CommuLingo entries panel under the report body */
.report-related {
    margin-top: 2.2em;
    padding: 1.1em 1.2em 1.2em;
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent-red, #b84f4f);
    background: var(--bg-surface);
}

.report-related-title {
    margin: 0 0 0.8em;
    font-size: 1.05em;
}

.report-related-kicker {
    display: block;
    font-size: 0.78em;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--accent-red, #b84f4f);
}

.report-related-events {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 0.6em;
}

.report-related-event {
    display: block;
    padding: 0.7em 0.85em;
    border: 1px solid var(--border);
    color: inherit;
    text-decoration: none;
}

.report-related-event:hover {
    border-color: var(--accent-red, #b84f4f);
}

.report-related-event strong {
    display: block;
    margin-top: 0.15em;
    font-size: 1.02em;
}

.report-related-period {
    display: block;
    margin-top: 0.15em;
    font-size: 0.85em;
    color: var(--text-muted);
}

.report-related-people {
    margin-top: 0.9em;
}

.report-related-people .report-related-kicker {
    margin-bottom: 0.45em;
}

.report-related-person {
    display: inline-block;
    margin: 0 0.35em 0.4em 0;
    padding: 0.22em 0.6em;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: inherit;
    text-decoration: none;
    font-size: 0.92em;
}

.report-related-person:hover {
    border-color: var(--accent-red, #b84f4f);
}

/* External-text source card (::: 외부문헌 blocks, utils/markdown.js) */
.report-body .report-source-card {
    margin: 1.2em 0;
    padding: 0.9em 1.1em;
    border: 1px solid var(--border);
    border-left: 3px solid var(--accent-red, #b84f4f);
    background: var(--bg-surface);
}

.report-body .report-source-card .report-source-kicker {
    display: block;
    font-size: 0.78em;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--accent-red, #b84f4f);
}

.report-body .report-source-card .report-source-title {
    margin: 0.25em 0 0;
    font-size: 1.05em;
    font-weight: 700;
}

.report-body .report-source-card .report-source-title a {
    color: inherit;
}

.report-body .report-source-card .report-source-meta,
.report-body .report-source-card .report-source-note {
    margin: 0.25em 0 0;
    font-size: 0.88em;
    color: var(--text-muted);
}
