/* SPDX-License-Identifier: Apache-2.0 */
/* Establish reading hierarchy and divide panel interiors into labelled passages. */
:root { --copy-size: 16px; --panel-title-size: 19px; }
.reading-title { padding-block: 14px; align-items: center; }
.reading-title h2, .layout-spread .reading-title h2, .project-methods .reading-title h2 { font: var(--panel-title-size)/1.55 var(--display); }
.reading-title .section-number { align-self: start; min-height: 33px; font-size: 19px; }
.reading-title .dots { flex-basis: 19px; width: 19px; }
.reading-body { --passage-ink: #d1e8d8; --passage-bright: #e0ffe8; --passage-muted: #a0c4ad; --passage-rule: #749e8380; --passage-well: #071f1288; --passage-edge: #accab6; counter-reset: passage; }
.reading-body p, .reading-body > p, .chapter-body .reading-body > p,
.layout-spread .reading-body > p, .project-methods .reading-body > p { font-size: var(--copy-size); line-height: 1.75; color: var(--passage-ink); }
.reading-body > p + p { margin-top: 18px; }
.reading-body strong { color: var(--passage-bright); font-weight: 600; }
.reading-body .panel-deck { font-size: 17px; line-height: 1.65; padding: 2px 0 20px 16px; margin: 0 0 24px; border-left: 3px double var(--passage-edge); color: var(--passage-bright); }
.passage { position: relative; min-width: 0; counter-increment: passage; }
.passage + .passage { margin-top: 28px; }
.reading-body > p + .passage, .reading-body > .passage + p { margin-top: 26px; }
.passage-label { position: relative; display: flex; align-items: baseline; gap: 10px; margin: 0 0 14px; padding: 0 0 12px; font: 11px/1.85 var(--display); letter-spacing: .45px; text-transform: uppercase; color: var(--passage-bright); border-bottom: 1px solid var(--passage-rule); }
.passage-label:before { content: counter(passage, decimal-leading-zero); flex: 0 0 auto; font: 12px/1 var(--body); color: var(--passage-muted); padding-right: 8px; border-right: 1px solid var(--passage-rule); }
.passage-label:after { content: ''; position: absolute; left: 0; bottom: -3px; width: 54px; height: 5px; background: var(--passage-edge); clip-path: polygon(0 0,100% 0,calc(100% - 6px) 100%,0 100%); }
.passage p { margin: 0; max-width: 64ch; }
.passage p + p { margin-top: 16px; }
.passage-end { padding-top: 4px; }
.passage-end .passage-label:after { width: 34%; background: repeating-linear-gradient(110deg,var(--passage-edge) 0 2px,transparent 2px 5px); }
.boundary-inset { padding: 19px 18px; border: 1px solid var(--passage-rule); border-left: 4px solid var(--passage-edge); background: var(--passage-well); box-shadow: inset 0 2px 8px #00160944; }
.boundary-inset:after { content: ''; position: absolute; right: 8px; bottom: 7px; width: 26px; height: 4px; border-inline: 6px double var(--passage-edge); opacity: .75; }
.boundary-inset .passage-label { padding-bottom: 10px; margin-bottom: 12px; }
.boundary-inset p { font-size: 15px; line-height: 1.75; }
.contract-lines { list-style: none; padding: 0; margin: 18px 0; border-top: 1px solid var(--passage-rule); }
.contract-lines li { position: relative; padding: 12px 10px 12px 22px; border-bottom: 1px solid var(--passage-rule); background: linear-gradient(90deg,#a1d3b00c,transparent); color: var(--passage-ink); font: 15px/1.7 var(--body); }
.contract-lines li:before { content: ''; position: absolute; top: 19px; left: 4px; width: 5px; height: 5px; border: 1px solid var(--passage-edge); box-shadow: 2px 2px #02170b; }
.reading-body .passage-note { color: var(--passage-muted); font-size: 15px; line-height: 1.7; }
.reading-body:has(> .passage) { padding-block: 26px; }
.layout-spread .reading-body, .project-methods .reading-body { padding: 26px 23px; }
.layout-spread > .metal-section:nth-child(4) .reading-body { --passage-ink: #173d25; --passage-bright: #102f1b; --passage-muted: #355a40; --passage-rule: #34594066; --passage-well: #e2f3e44d; --passage-edge: #456a51; }
.layout-spread > .metal-section:nth-child(4) .reading-body .passage p { color: var(--passage-ink); }
.definition-register dt, .capability-register dt { font: 13px/1.7 var(--display); }
.definition-register dd, .capability-register dd { font-size: var(--copy-size); line-height: 1.75; }
.capability-register dd { padding: 18px 21px; }
.capability-register dd p { font-size: var(--copy-size); line-height: 1.7; margin: 0; }
.capability-register dd .register-condition { position: relative; margin-top: 17px; padding-top: 16px; border-top: 1px solid #89b89a66; color: #afcdb9; font-size: 15px; }
.register-condition:before { content: ''; position: absolute; top: -2px; left: 0; width: 40px; height: 3px; background: #a8cdb5; }
.project-status .reading-body > p:last-child { padding: 19px; border-left: 3px solid #a1c3ac; background: #0a251888; font-size: 15px; }
.chapter-sequence .reading-title h2 { font-size: 20px; line-height: 1.65; }
.chapter-sequence .chapter-body { grid-template-columns: minmax(0,1fr) 248px; }
.chapter-sequence .reading-body > p { font-size: 17px; line-height: 1.75; }
.chapter-sequence .reading-body > p + p { padding-top: 16px; border-top: 1px solid #80ab911f; }
.chapter-sequence .margin-note h3 { font-size: 17px; line-height: 1.6; }
.chapter-sequence .margin-note p { font-size: 15px; line-height: 1.7; }
.state-journey h2, .ccir-explorer h2 { font-size: 20px; line-height: 1.6; }
.node-screen h3 { font-size: 16px; line-height: 1.6; }
.trace-step h3, .container-readout h3 { font-size: 18px; line-height: 1.6; }
.trace-step > p:last-child { font-size: 16px; line-height: 1.75; }
.node-screen p { font-size: 14px; }
.container-readout p { font-size: 16px; line-height: 1.7; }
.continuity-path h3 { font-size: 18px; }
.representative-card h2 { font: 19px/1.55 var(--display); margin-bottom: 12px; }
.representative-card p { font-size: 16px; line-height: 1.75; }
.ccir-feature h2 { font-size: 20px; }
.ccir-feature-copy > p:not(.eyebrow) { font-size: 16px; line-height: 1.75; }
.overview-brief { --passage-ink: #d1e8d8; --passage-bright: #e0ffe8; --passage-muted: #a0c4ad; --passage-rule: #749e8380; --passage-well: #071f1288; --passage-edge: #accab6; }
.overview-brief article { counter-reset: passage; align-self: start; }
.overview-brief h2 { font: 20px/1.55 var(--display); margin-bottom: 25px; }
.overview-brief p { color: var(--passage-ink); font-size: 16px; line-height: 1.75; }
.overview-brief .brief-index { font-size: 8px; line-height: 1.8; margin-bottom: 13px; }
.overview-brief .text-link { margin-top: 23px; font-size: 14px; }
.overview-brief article:nth-child(2) { --passage-ink: #173d25; --passage-bright: #102f1b; --passage-muted: #355a40; --passage-rule: #34594066; --passage-well: #e2f3e44d; --passage-edge: #456a51; }
.overview-brief article:nth-child(2) .passage-label { color: var(--passage-bright); }

@container (max-width: 780px) {
  .chapter-sequence .chapter-body { grid-template-columns: 1fr; }
  .chapter-sequence .reading-title h2 { font-size: 19px; }
}
@container (max-width: 440px) {
  .reading-title h2, .layout-spread .reading-title h2, .project-methods .reading-title h2 { font-size: 17px; line-height: 1.6; }
  .reading-title { gap: 9px; }
  .reading-title .dots { display: none; }
  .reading-title .section-number { flex-basis: 29px; font-size: 17px; }
  .reading-body, .layout-spread .reading-body, .project-methods .reading-body { padding: 23px 17px; }
  .reading-body .panel-deck { font-size: 17px; padding-left: 12px; }
  .passage-label { font-size: 10px; letter-spacing: .2px; gap: 8px; }
  .boundary-inset { padding: 17px 13px; }
  .contract-lines li { padding-right: 0; }
  .definition-register dt, .capability-register dt { font-size: 12px; }
  .capability-register dd { padding: 17px; }
  .chapter-sequence .reading-title h2 { font-size: 18px; }
  .chapter-sequence .reading-body { padding: 4px 0 20px; }
  .chapter-sequence .reading-body > p { font-size: 16px; }
  .chapter-sequence .margin-note h3 { font-size: 17px; }
  .state-journey h2, .ccir-explorer h2 { font-size: 18px; }
  .node-screen h3 { font-size: 16px; }
  .trace-step h3, .container-readout h3 { font-size: 18px; }
  .representative-card h2 { font-size: 18px; }
}
@media (max-width: 620px) {
  .overview-brief h2 { font-size: 19px; }
  .overview-brief article { padding: 23px 19px; }
}
@media print {
  .reading-body, .overview-brief, .overview-brief article:nth-child(2), .layout-spread > .metal-section:nth-child(4) .reading-body { --passage-ink: #000; --passage-bright: #000; --passage-muted: #222; --passage-rule: #777; --passage-edge: #777; --passage-well: transparent; }
  .boundary-inset { box-shadow: none; background: none; }
  .contract-lines li { background: none; }
  .passage-label:after, .boundary-inset:after { display: none; }
  .passage { break-inside: avoid; }
  .capability-register dd .register-condition { color: black; }
}
