/* Clear source illustrations are given enough space to be read in full. */
#structure .layer-image{display:flex;align-items:center;justify-content:center;height:300px;min-height:0}
#structure .layer-image img{width:auto;height:auto;max-width:100%;max-height:100%;min-height:0;min-width:0}
#structure .layer-text{display:block}
#structure .layer-detail{display:block;margin:24px 0 0;padding-top:20px;border-top:1px solid var(--line)}
#structure .layer-detail img{width:100%;height:230px;max-height:none;object-fit:contain}
#structure .layer-detail figcaption{text-align:center;margin-top:13px;font-size:12px}
#structure .detail-base .detail-window{position:relative;overflow:hidden;aspect-ratio:6/5;max-width:430px;margin:auto}
#structure .detail-base img{position:absolute;inset:0 auto auto 0;width:100%;height:auto;transform:translateY(-20%)}
#materials .material-item>img{width:190px;height:190px;max-width:100%;object-fit:contain;margin:0 auto 25px}
#materials .pattern-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:45px}
#materials .pattern-item{min-width:0}
#materials .pattern-image{height:300px;min-height:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
#materials .pattern-image img{width:auto;height:auto;max-width:100%;max-height:100%;min-height:0;min-width:0;object-fit:contain}
#history .history-item{display:block;padding:28px 0 32px}
#history .history-item>figure{padding:0;margin-bottom:22px}
#history .history-item>figure img{width:100%;height:240px;max-height:none;object-fit:contain}
#history .history-item-copy h3{font-size:26px}
#history .poem-panel{display:grid;grid-template-columns:1fr;justify-items:center;gap:22px}
#history .poem-panel>img{width:min(100%,340px);height:auto;max-height:none}
#history .poem-panel blockquote{writing-mode:horizontal-tb;text-align:center;font-size:24px;line-height:1.9;letter-spacing:.06em}
#ritual .ritual-spread{grid-template-columns:minmax(0,1.05fr) minmax(0,1fr);gap:50px}
#ritual .ritual-picture>img{width:100%;height:auto;max-width:none;max-height:none}
#ritual .ceremony-vignettes img{width:100%;height:190px;max-height:none;object-fit:contain}
#ritual .procession-strip{overflow:visible}
#ritual .procession-window{overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;scrollbar-color:var(--gold) transparent;padding-bottom:16px}
#ritual .procession-strip img{width:max(100%,1000px);max-width:none;height:auto;max-height:none;object-fit:contain}
#ritual .procession-strip figcaption{display:flex;justify-content:space-between;gap:20px;font-size:12px;margin-top:12px}
#ritual .procession-strip figcaption span{display:none}
#city .city-node-details{grid-template-columns:repeat(2,minmax(0,1fr));gap:30px 40px}
#city .city-node-details>article{display:grid;grid-template-columns:minmax(150px,.85fr) minmax(0,1fr);gap:0 25px;border-left:0;border-top:1px solid var(--line);padding:25px 0 0;align-content:start}
#city .city-node-details>article>img{grid-column:1;grid-row:1/8;width:100%;height:220px;margin:0;object-fit:contain}
#city .city-node-details :is(h3,p){grid-column:2}
#city .city-node-details h3{margin-bottom:15px}
#water .source-details .source-detail>img{width:100%;height:360px;max-height:none;object-fit:contain}
#heritage .archaeology-image{height:auto;min-height:0;padding:15px}
#heritage .archaeology-image img{width:100%;height:auto;max-height:350px;object-fit:contain}
#heritage .today-gallery{grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr);align-items:center}
#heritage .today-gallery img,#heritage .today-gallery>figure:first-child img{width:100%;height:auto;max-height:none;aspect-ratio:auto;object-fit:contain}
#heritage .axis-pair img{width:100%;height:440px;max-height:none;object-fit:contain}
#heritage .present-sites img{width:100%;height:230px;max-height:none;object-fit:contain}
#design .design-transform{grid-template-columns:1fr;gap:25px}
#design .design-transform img{width:100%;height:340px;object-fit:contain}
#design .design-transform figcaption{grid-column:1}
.finale-image{width:100%;margin-left:auto;margin-right:auto}
.image-zoomable{cursor:zoom-in;outline-offset:6px;touch-action:manipulation}
.image-zoomable:focus-visible{outline:2px solid var(--red)}
@media(max-width:1000px){
 #ritual .ritual-spread{grid-template-columns:1fr;gap:35px}
 #ritual .ritual-picture{border-left:0;padding-left:0;padding-top:30px;border-top:1px solid var(--line)}
 #ritual .ritual-picture>img{max-width:750px}
 #ritual .ceremony-vignettes{max-width:700px}
 #city .city-node-details>article{grid-template-columns:1fr}
 #city .city-node-details>article>img{grid-row:auto;height:210px;margin:0 0 20px}
 #city .city-node-details :is(h3,p){grid-column:1}
 #design .design-transform{grid-template-columns:repeat(2,minmax(0,1fr))}
 #design .design-transform figcaption{grid-column:1/-1}
}
@media(max-width:600px){
 #structure .layer-image{height:240px}
 #structure .layer-detail img{width:100%;height:220px}
 #structure .detail-base img{height:auto}
 #materials .material-item>img{width:145px;height:145px;margin-bottom:20px}
 #materials .material-item:last-child{display:block;max-width:none}
 #materials .material-item:last-child>img{width:100%;max-width:360px;height:190px}
 #materials .material-item:last-child h3{text-align:center}
 #materials .pattern-grid{grid-template-columns:1fr;gap:35px}
 #materials .pattern-item{display:block}
 #materials .pattern-image{height:260px;margin-bottom:20px}
 #materials .pattern-item h3{margin-bottom:14px}
 #history .history-item>figure{margin-bottom:20px}
 #history .history-item>figure img{height:auto;max-height:240px}
 #history .history-item-copy h3{font-size:24px}
 #history .poem-panel{gap:20px}
 #history .poem-panel>img{width:100%;max-width:340px}
 #history .poem-panel blockquote{font-size:21px}
 #ritual .ceremony-vignettes{grid-template-columns:1fr;gap:25px;justify-items:center}
 #ritual .ceremony-vignettes img{width:100%;max-width:330px;height:auto;max-height:250px;object-fit:contain}
 #ritual .procession-strip img{width:1000px;max-width:none;height:auto}
 #ritual .procession-strip figcaption span{display:inline;color:var(--red)}
 #city .city-node-details{grid-template-columns:1fr;gap:28px}
 #city .city-node-details>article{grid-template-columns:minmax(130px,.85fr) minmax(0,1fr);gap:0 20px}
 #city .city-node-details>article>img{grid-row:1/8;height:185px;margin:0}
 #city .city-node-details :is(h3,p){grid-column:2}
 #city .city-node-details h3{font-size:23px;margin-bottom:12px}
 #water .source-details .source-detail>img{height:auto;max-height:420px}
 #heritage .today-gallery{grid-template-columns:1fr}
 #heritage .archaeology-image{padding:5px 0}
 #heritage .archaeology-image img{max-height:300px}
 #heritage .axis-pair{grid-template-columns:1fr;gap:28px}
 #heritage .axis-pair img{height:auto;max-height:420px}
 #heritage .present-sites img{height:auto;max-height:300px}
 #design .design-transform{grid-template-columns:1fr;gap:25px}
 #design .design-transform img{height:310px}
 #design .design-transform figcaption{grid-column:1}
 .finale-image{width:100%;margin-left:0;margin-right:0}
}
