/* A compact, always-visible toolbar shared by both color schemes. */
:root{--surface:#151b24;--page:#080808;--text:#f5f7fb;--subtle:#b3bfd0;--edge:#2b3b53;--link:#8ebcff}
html[data-theme=light]{--surface:#f2f5f9;--page:#fff;--text:#17263c;--subtle:#526176;--edge:#d4dce8;--link:#205eaa;--blue:#205eaa;--muted:#526176;--line:#d4dce8}
body{background:var(--page);color:var(--text)}
.preferences{display:flex;align-items:center;gap:10px;flex-shrink:0}
.language-control select{appearance:none;background:transparent;color:var(--text);border:1px solid var(--edge);border-radius:7px;padding:8px 10px;font-size:12px;font-weight:700;cursor:pointer;width:64px}
.language-control option{color:var(--text);background:var(--page)}
.theme-control{display:flex;padding:3px;border:1px solid var(--edge);border-radius:8px;gap:2px}
.theme-control button{display:flex;align-items:center;justify-content:center;gap:5px;background:transparent;color:var(--subtle);border-radius:5px;padding:6px;font-size:11px;min-height:30px}
.theme-control button[aria-pressed=true]{background:#274c7e;color:#fff}
.theme-control svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
#translation-note{max-width:800px;color:var(--subtle);font-size:11px}
.nav{gap:18px} .brand span{font-size:8px;letter-spacing:.7px}.saved-link{font-size:12px}
html[data-theme=light] header,html[data-theme=light] footer{background:#fff;border-color:var(--edge)}
html[data-theme=light] .brand span,html[data-theme=light] .menu-button,html[data-theme=light] #navigation a{color:var(--text)}
html[data-theme=light] #search{background:#f2f5f9;border:1px solid var(--edge)}
html[data-theme=light] #query,html[data-theme=light] #search button{background:transparent;color:var(--text)}
html[data-theme=light] .saved-link b{background:#e5ecf5;color:#254a7a}
html[data-theme=light] .theme-control button[aria-pressed=true]{background:#e1ecfc;color:#174f99}
html[data-theme=light] .intro-line,html[data-theme=light] .intro-line strong,html[data-theme=light] .search-heading p,html[data-theme=light] .section-deck,html[data-theme=light] .card .sub,html[data-theme=light] .card .type,html[data-theme=light] .results-line,html[data-theme=light] .eyebrow,html[data-theme=light] .fine,html[data-theme=light] .footer-top p span,html[data-theme=light] .footer-links,html[data-theme=light] .feed-status{color:var(--subtle)}
html[data-theme=light] .intro-line>a,html[data-theme=light] .news-item small,html[data-theme=light] .card .proof{color:var(--link)}
html[data-theme=light] .next-list{background:var(--surface)}
html[data-theme=light] .next-item{border-color:var(--edge)}
html[data-theme=light] .next-item small,html[data-theme=light] .museum-tile p,html[data-theme=light] .news-item p{color:var(--subtle)}
html[data-theme=light] .card,html[data-theme=light] .museum-tile,html[data-theme=light] .video-card,html[data-theme=light] .opportunity,html[data-theme=light] .aside-panel{background:var(--surface);border-color:var(--edge)}
html[data-theme=light] .card .open{background:#e0eafb;color:#164c94}
html[data-theme=light] .chip{border-color:#c1ccdc;color:#354b69}
html[data-theme=light] .chip.active,html[data-theme=light] .chip:hover{background:#215faa;color:#fff;border-color:#215faa}
html[data-theme=light] .band,html[data-theme=light] .funding-link{background:#edf3fc;border-color:#d1dff1;color:var(--text)}
html[data-theme=light] .band p,html[data-theme=light] .funding-link p{color:var(--subtle)}
html[data-theme=light] .band .eyebrow{color:#846400}
html[data-theme=light] .filters input,html[data-theme=light] .filters select{background:#fff;color:var(--text);border-color:#bccade}
html[data-theme=light] .profile-top{background:linear-gradient(115deg,#edf3fc,#fff)}
html[data-theme=light] .profile-title p,html[data-theme=light] .profile-summary .source-count,html[data-theme=light] .breadcrumb{color:var(--subtle)}
html[data-theme=light] .profile-title button{background:#e0ebfc;color:#164c94}
html[data-theme=light] .profile-nav{background:#fff;border-color:var(--edge)}
html[data-theme=light] .profile-nav a{color:var(--text)}
html[data-theme=light] .light{background:#fff;color:var(--text)}
html[data-theme=light] .light .section-deck,html[data-theme=light] .facts dd,html[data-theme=light] .timeline-row p,html[data-theme=light] .timeline-row time,html[data-theme=light] .aside-panel p,html[data-theme=light] .work-item p,html[data-theme=light] .relationship small,html[data-theme=light] .source-list small{color:var(--subtle)}
html[data-theme=light] .light a.text-link,html[data-theme=light] .source-link,html[data-theme=light] .aside-panel a,html[data-theme=light] .source-list a,html[data-theme=light] .video-details a,html[data-theme=light] .more-videos summary{color:var(--link)}
html[data-theme=light] .facts div,html[data-theme=light] .timeline-row,html[data-theme=light] .aside-panel,html[data-theme=light] .aside-panel a,html[data-theme=light] .source-list li,html[data-theme=light] .work-item,html[data-theme=light] .relationship{border-color:var(--edge)}
html[data-theme=light] .media-tiles button,html[data-theme=light] .empty-section,html[data-theme=light] .empty{background:var(--surface);color:var(--subtle);border-color:var(--edge)}
html[data-theme=light] .card .card-photo,html[data-theme=light] .next-item img,html[data-theme=light] .museum-tile img,html[data-theme=light] .profile-image,html[data-theme=light] .profile-image img,html[data-theme=light] .media-tiles img,html[data-theme=light] .person-tile img{background:#e9edf3}
html[data-theme=light] .image-placeholder{background:#e6edf7;color:var(--subtle)}
html[data-theme=light] .image-placeholder span,html[data-theme=light] .about p,html[data-theme=light] .about li,html[data-theme=light] .stats span,html[data-theme=light] .empty p,html[data-theme=light] .video-details p,html[data-theme=light] .video-details small,html[data-theme=light] .video-filters label,html[data-theme=light] .opportunity p{color:var(--subtle)}
html[data-theme=light] .stats strong{color:var(--text)}
html[data-theme=light] dialog{background:#fff;color:var(--text)}
html[data-theme=light] dialog p,html[data-theme=light] #close-media{color:var(--subtle)}
html[data-theme=light] dialog a{color:var(--link)}
/* Image overlays remain dark in either mode so captions retain contrast. */
.feature,.feature .eyebrow,.feature-credit{color:#fff}.feature .eyebrow{color:#f5c518}
@media(max-width:1180px){.brand span{display:none}.nav{gap:12px}.theme-control button span{display:none}.theme-control button{padding:7px}.saved-link span{display:none}}
@media(max-width:760px){.preferences{gap:7px;margin-left:0}.saved-link{margin-left:auto}.nav{gap:12px}.language-control select{width:59px;padding:8px}.theme-control button{padding:6px}.brand .brand-symbol{width:75px;height:35px}#search{flex-basis:100%}.profile-nav{top:112px}}
@media(max-width:380px){.nav{gap:7px}.preferences{gap:5px}.theme-control{padding:2px}.theme-control button{padding:5px}.language-control select{width:53px;padding:7px}.saved-link{gap:2px}.wrap{padding-left:12px;padding-right:12px}}

.original-headline{display:none}html[lang=en] .original-headline{display:block;font-size:10px;color:var(--subtle);margin-top:5px}
/* Full photographs, centered inside the frame. Intrinsic proportions are never changed. */
.card>a:first-of-type{display:flex;align-items:center;justify-content:center;background:#0b0f16;overflow:hidden}
.card .card-photo,.next-item img,.museum-tile img,.mixed-gallery img,.person-tile img,.media-tiles img{object-fit:contain!important;object-position:50% 50%!important;display:block}
.card .card-photo{width:100%;height:250px;max-width:100%}
.profile-media{align-items:start}
.profile-image{display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:0;max-height:none;height:auto;overflow:hidden;background:#0b0f16}
.profile-image img{display:block;width:100%;height:440px;max-height:65vh;padding:0;object-fit:contain!important;object-position:center center!important}
.profile-image span{position:static;display:block;align-self:stretch;flex:none;background:#101824;text-align:left;padding:12px 16px;line-height:1.5}
.profile-summary{align-self:center}
.minister-portrait{object-fit:contain!important;object-position:center!important;width:100%;height:auto;max-height:500px}
.feature>img{object-fit:contain!important;object-position:center!important}
.feature-archive>img{height:66%}
html[data-theme=light] .card>a:first-of-type,html[data-theme=light] .profile-image{background:#e9edf3}
html[data-theme=light] .profile-image span{background:#e1e8f2;color:#354b69}
@media(max-width:760px){.card .card-photo{height:220px}.profile-image img{height:340px;max-height:60vh}}
@media(max-width:400px){.card .card-photo{height:190px}}

html[data-theme=light] .opportunity a{color:var(--link)}html[data-theme=light] .opportunity .status{color:#765500}html[data-theme=light] .minister-portrait{background:#e9edf3}
/* Fill-frame thumbnails: proportional crop, with portrait focal points applied by portraits.js. */
.card .card-photo,.card .small-portrait,.next-item img,.museum-tile img,.mixed-gallery img,.person-tile img,.media-tiles img,.profile-image img,.feature>img,.minister-portrait{object-fit:cover!important;object-position:50% 35%!important}
.card .card-photo{width:100%;height:250px;display:block}
.card>a:first-of-type{display:block;width:100%}
.profile-image img{height:440px;width:100%;max-height:65vh}
.minister-portrait{height:440px;width:100%}
@media(max-width:760px){.card .card-photo{height:220px}.profile-image img{height:340px}}
@media(max-width:400px){.card .card-photo{height:190px}}
.alphabet-nav{display:flex;flex-wrap:wrap;align-items:center;gap:6px;padding:17px 0;border-top:1px solid var(--edge);border-bottom:1px solid var(--edge);margin:24px 0}
.alphabet-nav .alphabet-label{font-size:12px;color:var(--subtle);margin-right:10px}
.alphabet-nav a{min-width:29px;min-height:33px;display:inline-flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;color:var(--text);padding:4px 7px;border-radius:5px}
.alphabet-nav a.active,.alphabet-nav a:hover{background:#286ad0;color:#fff;text-decoration:none}
@media(max-width:760px){.alphabet-nav{gap:5px}.alphabet-nav .alphabet-label{width:100%;margin-bottom:4px}.alphabet-nav a{min-width:30px;min-height:36px}}
