/* Shared theme controls for the archive and original photo albums. */
.theme-toggle{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;width:40px;height:40px;padding:0;border:1px solid var(--line,#ccd6e2);border-radius:4px;background:transparent;color:var(--ink,#20334b);font:26px/1 Arial,sans-serif;cursor:pointer;touch-action:manipulation}
.theme-toggle:hover{background:#e0eafa;color:#145dac}
.theme-toggle:focus-visible{outline:3px solid #579ce8;outline-offset:3px}
.theme-toggle[hidden]{display:none}
.theme-toggle{border-radius:8px}
.theme-toggle svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.theme-toggle .theme-sun{display:none}
.theme-toggle[aria-pressed=true] .theme-moon{display:none}
.theme-toggle[aria-pressed=true] .theme-sun{display:block}
body.index .logo .album-theme-brand{display:inline-block;position:relative;width:180px;max-width:100%;vertical-align:middle}
body.index .logo .album-logo-globe{display:block;width:100%;height:auto;max-height:none;clip-path:inset(0 78% 0 0);background:none;padding:0}
body.index .logo .album-logo-lettering{position:absolute;inset:0;width:100%;height:100%;max-height:none;clip-path:inset(0 0 0 22%);filter:brightness(0);pointer-events:none;background:none;padding:0}
.header-actions{display:flex;align-items:center;gap:14px;margin-left:auto}
.header-actions .search-link{margin-left:0;padding-left:16px}
.header-inner{gap:20px}.header-inner nav{gap:16px}
body.index .top-bar-right{display:flex;align-items:center;gap:12px}
body.index .title-bar .theme-toggle{position:absolute;right:16px;top:10px}
@media(max-width:1050px){.header-actions{margin-left:auto}}
@media(max-width:700px){.header-inner{gap:14px}.header-inner .brand{width:min(230px,calc(100% - 130px))}.header-actions{gap:8px}.header-actions .search-link{padding-left:0;border-left:0}}

@media screen{
  :root{color-scheme:light}
  :root[data-theme=dark]{color-scheme:dark;--paper:#111923;--ink:#e5edf7;--muted:#b0bfd2;--accent:#8fc2ff;--gold:#9bc8ff;--line:#36485e;--white:#1b2838;background:var(--paper);color:var(--ink)}
  :root[data-theme=dark] .site-header{background:#162231;border-color:var(--line);border-top-color:var(--accent)}
  :root[data-theme=dark] .brand .logo-lettering{filter:brightness(0) invert(1)}
  :root[data-theme=dark] :is(.site-footer,.article-index,.album-callout,.intro-strip,.prose blockquote,.learning-quote,.teaching-quote,.galileo-quote){background:#1b2a3e;border-color:var(--line)}
  :root[data-theme=dark] :is(.card-image,.gallery img){background:#182536}
  :root[data-theme=dark] :is(.article-tags a,.year-group summary){background:#22354c;border-color:var(--line)}
  :root[data-theme=dark] :is(.archive-controls button,.social-links a,.tag-directory a){background:var(--white);color:var(--ink);border-color:var(--line)}
  :root[data-theme=dark] :is(.article-index nav a:hover,.article-index nav a[aria-current],.year-group li a:hover,.year-group li a:focus-visible,.year-group summary:hover,.tag-directory a:hover,.tag-directory a:focus-visible,.article-tags a:hover,.article-tags a:focus-visible,.archive-controls button:hover,.theme-toggle:hover){background:#304967;color:var(--accent)}
  :root[data-theme=dark] :is(.button,.share-actions .share-primary,.back-to-top){background:#2466aa;color:#fff}
  :root[data-theme=dark] :is(.button:hover,.share-actions .share-primary:hover,.back-to-top:hover){background:#327bc6;color:#fff}
  :root[data-theme=dark] .archive-banner .button{background:#dcecff;color:#123a67}
  :root[data-theme=dark] .archive-banner .button:hover{background:#b5d8ff;color:#102f58}
  :root[data-theme=dark] .pagination [aria-current]{background:#2466aa;color:#fff}
  :root[data-theme=dark] .social-links a:hover{background:#2466aa;color:#fff}
  :root[data-theme=dark] .search-box input{border-color:var(--line);color:var(--ink)}
  :root[data-theme=dark] .search-results mark{background:#f2cb65;color:#152e50}
  :root[data-theme=dark] :is(.copyright,.search-link){border-color:var(--line)}
  /* The original jAlbum pages use independent styles and class names. */
  :root[data-theme=dark] body.index{background:var(--paper);color:var(--ink)}
  :root[data-theme=dark] body.index :is(.page-top,.top-bar,.top-bar ul,.title-bar,.main,.page-bottom,footer,.card,.card .caption,.cont,.bottom-bar){background:#1b2838;color:var(--ink);border-color:var(--line)}
  :root[data-theme=dark] body.index :is(h1,h2,h3,h4,p,.counts,a:not(.button)){color:inherit}
  :root[data-theme=dark] body.index :is(input,.search-input){background:#111923;color:var(--ink);border-color:var(--line)}
  :root[data-theme=dark] body.index .logo .album-logo-lettering{filter:brightness(0) invert(1)}
  :root[data-theme=dark] body.index .counts,:root[data-theme=dark] body.index .counts span{color:#b0bfd2}
  :root[data-theme=dark] body.index .overlay header{background:#22354c;color:var(--ink);border-bottom:1px solid var(--line)}
  :root[data-theme=dark] body.index .overlay header h4 small{color:var(--muted)}
  :root[data-theme=dark] body.index .overlay header .close{color:var(--muted)}
  :root[data-theme=dark] body.index .overlay header .close:hover{background:#304967;color:var(--ink)}
  :root[data-theme=dark] .lightbox{color:var(--ink)}
  :root[data-theme=dark] .lightbox .lightbox-overlay{background:rgba(8,15,24,.96)}
  :root[data-theme=dark] .lightbox :is(.controls,.thumb-strip,.lightbox-caption){background:rgba(27,40,56,.94);color:var(--ink)}
  :root[data-theme=dark] .lightbox :is(.controls,.thumb-strip,.lightbox-caption):hover{background:#22354c}
  :root[data-theme=dark] .lightbox :is(.controls button,.thumb-strip button,.lightbox-caption .caption,.lightbox-caption .caption h1,.lightbox-caption .caption h2,.lightbox-caption .caption h3,.lightbox-caption .caption h4,.lightbox-caption .caption h5,.lightbox-caption .caption h6,.lightbox-caption .numbers,.lightbox-caption .download::before){color:var(--ink)}
  :root[data-theme=dark] .lightbox :is(.controls button,.thumb-strip button):hover{color:var(--accent)}
  :root[data-theme=dark] .lightbox .thumbs a.active{background:var(--accent)}
  :root[data-theme=dark] .lightbox .thumbs a:hover{background:#5279a4}
  :root[data-theme=dark] .lightbox .controls button:focus-visible{outline:2px solid var(--accent);outline-offset:-3px}
}
@media print{.theme-toggle{display:none!important}:root{color-scheme:light}}
