/* Acervo local: eixo cronológico, títulos claros e fotografias sem recorte. */
.timeline-intro .page-description { max-width: 68ch; }
.timeline-section { background: #edf2f6; padding-block: 42px 64px; }
.timeline-section .timeline-layout { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 52px; align-items: start; }
.timeline-index { position: sticky; top: 124px; }
.timeline-sidebar { align-self: stretch; }
.timeline-index h2 { font: 700 1rem/1.4 var(--sans); letter-spacing: 0; margin: 0 0 15px; }
.timeline-index nav { display: grid; gap: 3px; }
.timeline-index nav a { display: flex; justify-content: space-between; align-items: center; gap: 15px; padding: 7px 10px; border-radius: 5px; color: var(--navy); font-weight: 650; text-decoration: none; border-left: 2px solid transparent; }
.timeline-index nav a:hover, .timeline-index nav a:focus-visible { background: #dbe7f0; border-left-color: var(--school-blue); }
.timeline-index small { font-size: .75rem; color: var(--muted); font-weight: 500; }
.timeline-index > p { margin-top: 22px; color: var(--muted); font-size: .8125rem; }
.timeline-feed { min-width: 0; max-width: 880px; }
.timeline-note { margin-bottom: 30px; padding: 18px 23px; background: #e1ebf3; border-left: 3px solid var(--school-blue); border-radius: 0 8px 8px 0; color: #324f64; font-size: .875rem; }
.timeline-note p { margin: 0; }
.timeline-note a { color: var(--navy); text-decoration: underline; font-weight: 700; }
.timeline-year { scroll-margin-top: 126px; }
.timeline-year + .timeline-year { margin-top: 46px; }
.timeline-year > h2 { display: flex; align-items: baseline; gap: 18px; margin: 0 0 22px; font: 700 2rem/1.2 var(--serif); color: var(--navy); letter-spacing: -.02em; }
.timeline-year > h2 small { font: 500 .8125rem/1.5 var(--sans); color: var(--muted); letter-spacing: 0; }
.timeline-year-posts { --timeline-gutter: 28px; border-left: 1px solid #b9cad7; margin-left: 8px; padding-left: var(--timeline-gutter); display: grid; gap: 25px; }
.timeline-post { position: relative; min-width: 0; background: white; border: 1px solid #d0dde6; border-radius: 10px; padding: 29px 32px 0; box-shadow: 0 4px 16px rgb(12 54 89 / 4%); scroll-margin-top: 126px; }
.timeline-post::before { content: ''; position: absolute; box-sizing: border-box; left: calc(-1 * var(--timeline-gutter, 28px) - 10px); top: 36px; width: 17px; height: 17px; border: 3px solid #edf2f6; border-radius: 50%; background: #a58748; box-shadow: 0 0 0 1px #b9cad7; }
.post-anchor { position: absolute; top: 0; scroll-margin-top: 126px; }
.post-header { border-top: 3px solid var(--gold); padding-top: 17px; margin-bottom: 19px; }
.post-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; color: var(--muted); font-size: .75rem; line-height: 1.7; }
.post-meta time { color: var(--school-blue); font-weight: 750; }
.post-header h3 { color: #102f49; font: 700 clamp(1.3rem, 2.1vw, 1.75rem)/1.33 var(--serif); margin: 10px 0 0; letter-spacing: -.025em; text-wrap: pretty; }
main .timeline-post p.post-date-context { margin: 8px 0 0; font-size: .75rem; color: var(--muted); }
.post-content, .post-excerpt { color: #344c5d; font-size: 1rem; line-height: 1.85; overflow-wrap: anywhere; }
.post-content:empty { display: none; }
.post-content { padding-bottom: 5px; }
.post-content p, .post-content > div { margin: 0 0 16px; }
.post-content p:last-child, .post-content > div:last-child { margin-bottom: 0; }
.post-content strong { font-weight: 700; color: #213e53; }
.post-content ul, .post-content ol { padding-left: 23px; margin: 12px 0 20px; }
.post-content li + li { margin-top: 5px; }
.post-content a { color: #18568b; text-decoration: underline; }
.post-content h4 { font: 700 1.1rem/1.5 var(--sans); margin: 24px 0 14px; }
.post-content blockquote { border-left: 3px solid var(--gold); padding-left: 20px; margin-inline: 0; }
main .timeline-post p.post-hashtags { color: var(--muted); font-size: .8125rem; }
main .timeline-post p.post-notice { font-size: .8125rem; line-height: 1.7; color: #644f26; background: #faf4e6; border-radius: 6px; padding: 12px 15px; margin: 0 0 20px; }
.post-reading { margin-bottom: 20px; }
.post-reading > summary, .post-gallery > summary { cursor: pointer; color: var(--navy); font-weight: 700; font-size: .875rem; padding: 12px 0; }
.post-reading > summary:hover, .post-gallery > summary:hover { color: var(--school-link); }
.post-reading .when-open { display: none; }
.post-reading[open] .when-open { display: inline; }
.post-reading[open] .when-closed { display: none; }
.timeline-post:has(> .post-reading[open]) > .post-excerpt { display: none; }
.post-reading[open] > .post-content { padding-top: 12px; }
.post-photo { margin: 21px 0 0; padding: 12px; background: #f1f5f8; border: 1px solid #e0e8ee; border-radius: 6px; }
.post-photo img { display: block; width: var(--photo-display-width, auto); aspect-ratio: var(--photo-aspect, auto); height: auto; max-width: 100%; max-height: 610px; margin: 0 auto; object-fit: contain; border-radius: 2px; }
.post-image-link { display: block; cursor: zoom-in; }
.post-gallery { margin-top: 9px; }
.post-gallery-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; margin: 9px 0 22px; }
.post-gallery-grid .post-photo { margin: 0; padding: 6px; }
.post-gallery-grid img { max-height: none; }
.post-video { margin: 22px 0; }
.post-video video { display: block; width: 100%; max-height: 550px; background: #0c1630; border-radius: 6px; }
.post-video figcaption { margin-top: 8px; font-size: .75rem; color: var(--muted); }
main .timeline-post p.post-video-reference { margin: 9px 0 0; font-size: .75rem; color: var(--muted); }
.post-embed { margin-top: 22px; }
.post-play-button { display: inline-flex; align-items: center; gap: 12px; text-align: left; padding: 13px 18px; border: 1px solid #afc6d7; border-radius: 7px; color: var(--navy); background: #e9f1f7; font: 700 .875rem/1.5 var(--sans); }
.post-play-button:hover { background: #dbe9f4; }
.post-player:empty { display: none; }
.post-player iframe { display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 6px; margin-top: 15px; background: var(--deep); }
.post-footer { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 12px 22px; margin-top: 25px; padding: 18px 0; border-top: 1px solid #dde5eb; }
.post-footer > span { font-size: .6875rem; color: #5a7081; }
.post-footer a { color: #205b8c; font-size: .8125rem; font-weight: 750; text-decoration: underline; text-decoration-color: #aec4d6; }
.post-footer a:hover { color: var(--school-link); }
.timeline-provenance { background: #e0eaf2; padding-block: 25px; color: #486173; font-size: .8125rem; }
.timeline-provenance p { max-width: 100ch; margin: 0; }
.school-updates { background: #edf2f6; }
.school-post-feed { display: grid; gap: 25px; max-width: 780px; margin-inline: auto; }
.school-post-feed .timeline-post::before { content: none; }
.post-reading:focus-within, .post-gallery:focus-within { scroll-margin-top: 126px; }
@media (max-width: 1000px) {
  .timeline-section .timeline-layout { grid-template-columns: 115px minmax(0, 1fr); gap: 25px; }
  .timeline-post { padding: 24px 24px 0; }
}
@media (max-width: 680px) {
  .timeline-section { padding-block: 28px 40px; }
  .timeline-section .timeline-layout { grid-template-columns: minmax(0, 1fr); gap: 23px; }
  .timeline-index { position: static; }
  .timeline-index nav { display: flex; flex-wrap: wrap; gap: 7px; }
  .timeline-index nav a { background: #e0eaf2; padding: 7px 11px; gap: 10px; border-left: 0; }
  .timeline-index > p { margin: 13px 0 0; }
  .timeline-note { padding: 15px 17px; }
  .timeline-year-posts { --timeline-gutter: 15px; margin-left: 3px; gap: 20px; }
  .timeline-post { padding: 20px 18px 0; }
  .timeline-post::before { top: 35px; }
  .post-header h3 { font-size: 1.35rem; }
  .post-content, main .timeline-post .post-content p, main .timeline-post p.post-excerpt { font-size: .9375rem; line-height: 1.8; }
  .post-photo { padding: 6px; margin-top: 18px; }
  .post-photo img { width: var(--photo-natural-width, auto); max-height: none; }
  .post-gallery-grid { grid-template-columns: minmax(0, 1fr); }
  .post-footer { padding-block: 15px; gap: 9px; }
  .post-footer > span { flex-basis: 100%; }
  .timeline-year, .timeline-post, .post-anchor { scroll-margin-top: 100px; }
}
@media print {
  .timeline-sidebar, .post-reading > summary, .post-gallery > summary { display: none; }
  .timeline-section .timeline-layout { display: block; }
  .timeline-section { background: white; }
  .timeline-post { box-shadow: none; break-inside: avoid; }
  .post-excerpt { display: none; }
  .post-reading > .post-content, .post-gallery > .post-gallery-grid { display: block !important; }
}

/* Paginação da Comunidade, após o último ano da página. */
.timeline-pagination { margin: 34px 0 0 37px; padding-top: 26px; border-top: 1px solid #b9cad7; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
main .timeline-feed .timeline-pagination > p { margin: 0; color: var(--muted); font-size: .875rem; }
.timeline-pagination .button { font-size: .9375rem; min-height: 48px; }
@media (max-width: 680px) { .timeline-pagination { margin-left: 18px; align-items: flex-start; flex-direction: column; } .timeline-pagination .button { max-width: 100%; } }

.timeline-index .timeline-page-link { width: 100%; margin-top: 20px; padding: 12px 14px; gap: 10px; justify-content: space-between; font-size: .875rem; line-height: 1.5; text-align: left; }
.timeline-page-link > span:first-child { min-width: 0; }
.timeline-page-link > span[aria-hidden] { flex-shrink: 0; }
@media (max-width: 680px) { .timeline-index .timeline-page-link { width: auto; max-width: 100%; margin-top: 16px; } }

.timeline-index .timeline-page-link small {
  display: block;
  margin-top: 4px;
  color: inherit;
  font-size: .8125rem;
  font-weight: 500;
  letter-spacing: .02em;
}
.timeline-index > .timeline-total {
  margin-top: 16px;
  font-size: .875rem;
  line-height: 1.6;
}

/* Related source posts share a card; the original texts and links stay local. */
.timeline-index > .timeline-group-total { margin-top: 3px; font-size: .75rem; line-height: 1.6; color: var(--muted); }
.post-summary { color: #344c5d; line-height: 1.85; }
.post-sources { min-width: 0; max-width: 100%; }
.post-sources > summary { cursor: pointer; color: #205b8c; font-size: .8125rem; font-weight: 750; }
.post-sources ul { margin: 15px 0 0; padding-left: 18px; }
.post-sources li + li { margin-top: 14px; }
.post-sources a { overflow-wrap: anywhere; }
.post-sources .source-date { display: block; margin-top: 3px; font-size: .75rem; color: var(--muted); }
.post-footer:has(.post-sources[open]) { display: block; }
.post-sources[open] { margin-top: 12px; }
.grouped-texts { margin-top: 16px; }
.source-text { padding-top: 12px; scroll-margin-top: 125px; }
.source-text + .source-text { border-top: 1px solid #d7e2eb; margin-top: 22px; padding-top: 22px; }
.source-text > h4, .grouped-video > h4 { font: 750 1rem/1.55 var(--sans); color: #173b56; margin: 0 0 9px; overflow-wrap: anywhere; }
.source-text > .post-content { margin-top: 15px; }
.grouped-video + .grouped-video { padding-top: 20px; border-top: 1px solid #d7e2eb; }
.study-selection { background: #edf2f6; }
.study-selection-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.study-entry { background: white; border: 1px solid #cddde9; border-radius: 8px; padding: 27px 30px; }
.study-entry::before { content: ''; display: block; width: 42px; height: 3px; background: var(--gold); margin-bottom: 20px; }
.study-entry h2 { font-size: clamp(1.2rem, 2vw, 1.5rem); line-height: 1.4; margin: 10px 0 14px; }
.study-entry h2 a { color: var(--navy); text-decoration-thickness: 1px; text-underline-offset: 5px; }
.study-entry h2 a:hover { color: var(--school-link); text-decoration: underline; }
.study-entry h2 span { font-family: var(--sans); font-size: .9rem; }
.study-entry > p:last-child { color: var(--muted); font-size: .9375rem; margin: 0; }
.unit-detail .email-link { font-size: .875rem; overflow-wrap: anywhere; }
@media (max-width: 680px) {
  .study-selection-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .study-entry { padding: 23px; }
  .source-text { scroll-margin-top: 100px; }
}
