/* Only source-confirmed single-image cards use explicit media/copy slots. */
.spc.spr-relational [data-layout="media-first-card"]>.group{display:flex;flex-direction:column;gap:20px;}
.spc.spr-relational .spr-card-media{height:240px;display:flex;align-items:center;justify-content:center;min-width:0;}
.spc.spr-relational .spr-card-media .spc-media{height:100%;width:100%;margin:0;padding:12px;display:flex;align-items:center;justify-content:center;}
.spc.spr-relational .spr-card-media img{height:100%;max-height:214px;max-width:100%;object-fit:contain;}
.spc.spr-relational .spr-card-media a,.spc.spr-relational .spr-card-media picture{display:block;max-width:100%;max-height:100%;height:100%;}
.spc.spr-relational .spr-card-copy{min-width:0;}
.spc.spr-relational .spr-card-copy>.spc-atom:last-child{margin-bottom:0;}
@media(max-width:640px){.spc.spr-relational .spr-card-media{height:220px;}.spc.spr-relational .spr-card-media img{max-height:194px;}}

/* Type-level rhythm: source relationships are fixed; these tokens control presentation. */
.spc.spr-relational{--spr-space:clamp(24px,3vw,40px);--spr-copy-width:76ch;--spr-media-bg:#f8fafc;line-height:1.75;}
.spc.spr-relational .spc-header{padding:clamp(28px,4vw,48px) 0 28px;}
.spc.spr-relational .spc-section{padding:var(--spr-space) 0;}
.spc.spr-relational h2:not(.spc-functional *){margin:0 0 20px;line-height:1.3;}
.spc.spr-relational h3:not(.spc-functional *),.spc.spr-relational h4:not(.spc-functional *){margin:24px 0 12px;}
.spc.spr-relational .spc-prose{max-width:var(--spr-copy-width);}
.spc.spr-relational .spc-atom{margin-bottom:18px;}
.spc.spr-relational li:not(.spc-functional *){margin-top:6px;margin-bottom:6px;}
/* Gallery count and available width jointly own the grid; no empty third column for two images. */
.spc.spr-relational .spc-gallery{grid-template-columns:minmax(0,1fr);gap:20px;margin:0 0 24px;}
.spc.spr-relational .spc-gallery>li{min-width:0;margin:0;}
.spc.spr-relational .spc-gallery>li>.group{background:var(--spr-media-bg);padding:12px;}
.spc.spr-relational .spc-gallery img{width:100%;height:clamp(220px,30vw,360px);object-fit:contain;}
@media(min-width:640px){.spc.spr-relational .spc-gallery{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(min-width:1024px){.spc.spr-relational .spc-gallery{grid-template-columns:repeat(var(--spr-gallery-columns,3),minmax(0,1fr));}}
/* Pair membership is source-confirmed. Move only the pure media slot above its copy on narrow screens. */
.spc.spr-relational .spc-image-text{gap:24px;align-items:center;margin:24px 0;grid-template-columns:minmax(0,1fr);}
.spc.spr-relational .spc-image-text-slot{min-width:0;}
.spc.spr-relational .spc-image-text-slot>div{max-width:var(--spr-copy-width);}
.spc.spr-relational .spr-media-slot img{max-height:400px;width:auto;max-width:100%;margin:auto;object-fit:contain;}
@media(min-width:768px){.spc.spr-relational .spc-image-text{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:clamp(24px,4vw,48px);}}
@media(max-width:767px){.spc.spr-relational [data-pair="confirmed"]>.spr-media-slot{order:0;}.spc.spr-relational [data-pair="confirmed"]>.spr-copy-slot{order:1;}}
/* Short cards keep their media and text slots. Tablet layouts keep an odd last item on its own full row. */
.spc.spr-relational .spc-source-group{gap:24px;}
.spc.spr-relational .spc-source-item>.group{padding:clamp(18px,2vw,24px);}
@media(min-width:640px) and (max-width:1023px){.spc.spr-relational .spc-source-item:last-child:nth-child(odd){grid-column:1/-1;}}
/* Narrative groups remain in original order and use a reading width instead of an oversized card box. */
.spc.spr-relational .spc-story>.group{padding:0;border:0;background:transparent;max-width:var(--spr-copy-width);margin-inline:auto;}
.spc.spr-relational .spc-story .spc-media{margin-block:20px;background:var(--spr-media-bg);}
.spc.spr-relational .spc-story .spc-media img{max-height:480px;}
/* Preserve all table cells/spans. Scroll belongs to the table wrapper, never the whole page. */
.spc.spr-relational .spc-licensed-table{margin:24px 0;}
.spc.spr-relational .spc-licensed-table>div{border:1px solid #dbe3ed;border-radius:8px;overscroll-behavior-x:contain;}
.spc.spr-relational .spc-licensed-table>div>div{display:block;padding-block:0;}
.spc.spr-relational .spc-licensed-table table{width:100%;line-height:1.6;}
.spc.spr-relational .spc-licensed-table td,.spc.spr-relational .spc-licensed-table th{padding:12px 16px;min-width:92px;vertical-align:top;}
.spc.spr-relational .spr-table-cue{font-size:13px;color:#64748b;margin:0 0 8px;}
.spc.spr-relational [data-sp-component="key-value"] dt{color:#334155;}
.spc.spr-relational [data-sp-component="key-value"] dd{color:#172033;}
@media(max-width:640px){.spc.spr-relational .spc-gallery img{height:260px;}.spc.spr-relational .spc-image-text{gap:16px;}.spc.spr-relational .spc-licensed-table td,.spc.spr-relational .spc-licensed-table th{padding:10px 12px;}.spc.spr-relational .spc-source-group{gap:20px;}}

@media(min-width:1024px){.spc.spr-relational .spr-table-cue{display:none;}}
.spc.spr-relational .spc-licensed-table table{overflow-wrap:normal;word-break:normal;}
