:root{color-scheme:light;--ink:#34281d;--gold:#ad8550}*{box-sizing:border-box}body{margin:0;color:var(--ink);font:18px/1.5 system-ui,sans-serif;background:radial-gradient(ellipse at 15% 10%,#b58a5240,transparent 55%),radial-gradient(ellipse at 95% 65%,#765d3540,transparent 50%),#231c17;min-height:100dvh}button,a{-webkit-tap-highlight-color:transparent}button{font:inherit;cursor:pointer;border:1px solid #bea47f;border-radius:8px;background:#faf4e7;color:var(--ink);min-height:48px;padding:8px 16px}button:disabled{opacity:.4;cursor:default}button:focus-visible,a:focus-visible{outline:3px solid #cb9c56;outline-offset:4px}header{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:12px 16px;color:#eedbc0}header a{color:inherit;text-decoration:none;font-size:16px}main{max-width:1280px;margin:auto;padding:0 12px 24px}.album-heading{color:#eedbc0;text-align:center;padding:8px 0 16px}.album-heading span{font-size:14px;letter-spacing:.12em}h1{font:normal 24px/1.25 Georgia,serif;margin:4px 0}#book{perspective:1800px;display:grid;grid-template-columns:1fr;gap:2px;filter:drop-shadow(0 14px 24px #0006)}.page{background:linear-gradient(100deg,#e9dcc7,#fcf6e9 12%,#f4ead7 95%,#e4d5bc);padding:22px 18px 16px;min-width:0;display:flex;flex-direction:column;min-height:65dvh;border-radius:3px;position:relative;transform-origin:left center}.page .eyebrow{text-transform:uppercase;font-size:14px;letter-spacing:.08em;color:#765b36}.page h2{font:normal 25px/1.2 Georgia,serif;margin:8px 0 14px}.photo-button{padding:0;border:0;background:none;border-radius:0;display:block;width:100%;flex:1;min-height:0}.photo-button img{display:block;width:100%;height:auto;max-height:55dvh;object-fit:contain;margin:auto}.page p{margin:14px 0;font-size:18px;white-space:pre-line}.page small{font-size:14px;color:#806d53;margin-top:auto;text-align:right}.page.cover{text-align:center;justify-content:center}.cover .photo-button{flex:0}.cover img{max-height:38dvh}.page.intro,.page.end{justify-content:center;padding:36px 26px}.page.end{text-align:center}.motion{align-self:flex-start;margin:0 0 12px}.paging{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:18px 0 0;color:#f3e4cd}.paging button{min-width:92px}#counter{font-size:16px;text-align:center}.hint{color:#d0bfa6;text-align:center;font-size:14px;margin:12px auto}.turn-next{animation:turnNext .55s ease}.turn-prev{animation:turnPrev .55s ease}@keyframes turnNext{0%{opacity:.35;transform:rotateY(-22deg)}100%{opacity:1;transform:rotateY(0)}}@keyframes turnPrev{0%{opacity:.35;transform:rotateY(22deg)}100%{opacity:1;transform:rotateY(0)}}dialog{border:0;border-radius:12px;padding:18px;background:#faf3e7;color:var(--ink);max-width:calc(100vw - 20px);max-height:92dvh}dialog::backdrop{background:#100d0bef}.dialog-head{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin-bottom:12px}.dialog-head h2{margin:0;font:26px Georgia,serif}.dialog-head span{flex:1;min-width:160px;font-size:16px}#chapters{display:grid;gap:8px}#chapters button{text-align:left}#viewer{width:1200px}#media{overflow:auto;max-height:70dvh;text-align:center;touch-action:pan-x pan-y pinch-zoom}#media img,#media video{display:block;max-width:100%;max-height:68dvh;width:auto;height:auto;object-fit:contain;margin:auto}#media.enlarged img{max-width:none;max-height:none;width:180%;margin:0}#view-caption{font-size:16px;white-space:pre-line}@media(min-width:900px){#book{grid-template-columns:1fr 1fr}.page{min-height:680px;padding:32px 30px 20px}.page:nth-child(2){background:linear-gradient(90deg,#ded0b8,#faf2e2 8%,#faf3e5)}.page h2{font-size:30px}.photo-button img{max-height:430px}.album-heading{padding-bottom:22px}h1{font-size:32px}main{padding:0 30px 30px}}@media(prefers-reduced-motion:reduce){.turn-next,.turn-prev{animation:none}}

/* Album revision: separate photograph and caption areas, modern typography. */
body{font-family:"Trebuchet MS",Arial,sans-serif}h1,.page h2,.dialog-head h2{font-family:"Trebuchet MS",Arial,sans-serif;font-weight:500;line-height:1.3}.page{display:block;min-height:0}.page h2{overflow-wrap:anywhere}.photo-button{flex:none;min-height:0;margin:18px 0;line-height:0}.photo-button img{height:auto;width:100%;max-height:55dvh;object-fit:contain}.page p{position:static;line-height:1.6;margin:18px 0}.page small{display:block;margin-top:20px}.page.cover{display:flex;min-height:70dvh;background:radial-gradient(ellipse at 80% 15%,#bc945b33,transparent 60%),linear-gradient(130deg,#2f403c,#152923);color:#f3e4c7;border:8px double #ae8b59;box-shadow:inset 0 0 0 12px #ffffff05;padding:40px 24px}.cover .eyebrow{color:#d6b47d;letter-spacing:.08em}.cover h2{white-space:pre-line;font-size:clamp(28px,6vw,44px);margin:42px 0 26px;line-height:1.4}.cover p{color:#d9c7a9;font-size:18px}.cover small{color:#d9c7a9}.page.intro,.page.end{display:flex;min-height:65dvh}.page.intro{justify-content:center}@media(min-width:900px){.page{min-height:700px}.photo-button img{max-height:430px}.page.cover{min-height:700px}.page.intro,.page.end{min-height:700px}}
.offline-panel{max-width:700px;margin:24px auto 0;padding:18px;background:#ffffff0b;border:1px solid #ad855055;border-radius:12px;color:#eedbc0}.offline-panel button{margin:0 8px 10px 0}.offline-panel p,.offline-panel summary{font-size:16px;line-height:1.6}.offline-panel summary{cursor:pointer;min-height:44px}

#book{transform-style:preserve-3d;background:#e7d7bd;border-radius:4px;box-shadow:0 6px 0 #c4b194,0 10px 0 #a68c68}.page{backface-visibility:hidden;box-shadow:inset 5px 0 15px #6b4b2010}.page::after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(90deg,#4a32151a,transparent 8%,transparent 94%,#4a321514)}#book[aria-busy=true]{pointer-events:none}@media(prefers-reduced-motion:reduce){#book{transform-style:flat}}

.animation-switch{display:flex;align-items:center;justify-content:center;gap:10px;color:#eedbc0;min-height:48px;margin-top:16px;font-size:16px}.animation-switch input{width:22px;height:22px;accent-color:#ad8550}

#book{position:relative}.flipping-sheet{backface-visibility:hidden;box-shadow:16px 5px 30px #0004}.page.end{grid-column:1 / -1;text-align:center;align-items:center}.page.end p{max-width:680px}.page.end small{align-self:stretch}@media(min-width:900px){.page.end h2{font-size:40px}.page.end p{font-size:22px}}

/* Fixed viewer, matching the family-album viewer: the footer never follows content. */
html{height:100%;overflow:hidden}body{height:100dvh;min-height:0;overflow:hidden;display:flex;flex-direction:column;background:#18120e;color:#eadbc2;padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom)}
header{flex:0 0 60px;padding:8px 16px;border-bottom:1px solid #a5824f55}header a{font-size:14px}header button,.paging button{background:transparent;color:#d8bd91;border:1px solid #725839;border-radius:3px;min-height:44px;font-size:14px}
main{flex:1;min-height:0;width:100%;max-width:1600px;padding:0;display:grid;grid-template-rows:60px minmax(0,1fr) auto 68px 26px;overflow:hidden}
.album-heading{padding:8px 16px;text-align:left;border-bottom:1px solid #a5824f33}.album-heading span{font-size:10px;text-transform:uppercase;letter-spacing:.1em}.album-heading h1{font-size:18px;margin:2px 0}
#book{display:block;position:relative;min-height:0;overflow:hidden;filter:none;perspective:none;transform-style:flat;background:#18120e;border-radius:0;box-shadow:none;touch-action:pan-y}
#book .page{position:absolute;width:720px;height:720px;min-height:0;max-height:none;padding:36px 40px 28px;display:flex;flex-direction:column;transform-origin:center;box-shadow:none;border-radius:0;color:#34281d;overflow:hidden}
#book .page .eyebrow{font-size:16px;line-height:24px;flex:none}#book .page h2{font-size:30px;line-height:1.25;margin:10px 0 16px;flex:none}#book .photo-button{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;margin:0;width:100%;overflow:hidden}#book .photo-button img{height:100%;width:100%;max-height:100%;object-fit:contain;margin:0}#book .page p{font-size:21px;line-height:1.5;margin:16px 0 10px;flex:none}#book .page small{font-size:14px;line-height:20px;margin:6px 0 0;flex:none}#book .motion{font-size:18px;min-height:44px;margin:2px 0 4px;padding:7px 14px;flex:none}
#book .page.cover{color:#f3e4c7;padding:48px 42px;border:8px double #ae8b59;justify-content:center}#book .cover h2{font-size:46px;margin:46px 0 30px}#book .cover p{font-size:24px}#book .page.intro,#book .page.end{justify-content:center;padding:60px}#book .page.intro h2,#book .page.end h2{font-size:38px}#book .page.intro p,#book .page.end p{font-size:25px;line-height:1.65}#book .page.end small{align-self:stretch}
.paging{margin:0;padding:10px 16px;border-top:1px solid #a5824f55;min-height:0}.paging button{min-width:84px}#counter{font-size:14px;color:#d8bd91}.hint{font-size:11px;margin:0;padding:3px 10px;line-height:20px}
#page-text{position:relative;border-top:1px solid #a5824f55;color:#d8bd91;font-size:13px;padding:0 16px}#page-text summary{cursor:pointer;min-height:36px;display:flex;align-items:center}#page-text summary::before{content:'▸';margin-right:6px}#page-text[open] summary::before{content:'▾'}#page-text>div{position:absolute;bottom:100%;left:0;right:0;z-index:10;max-height:45dvh;overflow:auto;padding:20px;background:#211a13;white-space:pre-line;color:#eadbc2;font-size:17px;line-height:1.6;border-top:1px solid #725839}
@media(max-height:520px){header{flex-basis:48px}main{grid-template-rows:44px minmax(0,1fr) auto 58px 0}.album-heading{padding:3px 12px}.album-heading span,.hint{display:none}.album-heading h1{font-size:16px}.paging{padding:6px 12px}#page-text summary{min-height:28px}}


/* Vintage leather and gilt treatment for the Alexander album cover. */
#book .page.cover{
  position:absolute;
  color:#ead7ae;
  background-color:#26382f;
  background-image:
    radial-gradient(ellipse at 18% 16%,#d4b87917 0,transparent 38%),
    radial-gradient(ellipse at 84% 86%,#050c091c 0,transparent 42%),
    repeating-linear-gradient(7deg,#ffffff05 0 1px,#00000004 1px 3px),
    linear-gradient(132deg,#34463a 0%,#1c3028 46%,#293c30 100%);
  border:10px double #a98a53;
  outline:1px solid #d2b875;
  outline-offset:-20px;
  box-shadow:inset 0 0 0 18px #0c171133,inset 7px 0 20px #0308065c,0 5px 18px #0003;
  font-family:Georgia,"Times New Roman",serif;
  letter-spacing:.025em;
}
#book .page.cover::before{
  content:"✦";
  position:absolute;
  top:25px;left:50%;transform:translateX(-50%);
  color:#d0b16d;font:22px/1 Georgia,serif;text-shadow:0 1px 1px #100d08;
}
#book .page.cover::after{
  content:"";position:absolute;inset:25px;pointer-events:none;
  border:1px solid #c4a5689c;
  background:linear-gradient(90deg,#dfc17d16,transparent 5%,transparent 95%,#090f0c16);
  box-shadow:inset 0 0 0 5px #d0b16d15;
}
#book .page.cover .eyebrow{color:#d8bd83;font:italic 18px/1.5 Georgia,"Times New Roman",serif;letter-spacing:.16em;text-shadow:0 1px 1px #090d0b}
#book .page.cover h2{font:normal 52px/1.35 Georgia,"Times New Roman",serif;letter-spacing:.035em;color:#f0dfb7;text-shadow:0 2px 1px #10150f,0 0 12px #d7bc7952}
#book .page.cover p,#book .page.cover small{font:italic 23px/1.6 Georgia,"Times New Roman",serif;color:#ddc99e;text-shadow:0 1px 1px #10150f}
#book .page.cover .photo-button{position:relative;z-index:1}
#book .page.cover .photo-button img{border:5px solid #b69a64;outline:1px solid #e0c987;box-shadow:0 5px 20px #05080670}

#originals{width:min(1080px,calc(100% - 24px));max-height:90dvh;overflow:auto;background:#241d15;color:#eedbc0}#originals .dialog-head{position:sticky;top:0;background:#241d15;z-index:1}#originals .dialog-head h2{font-size:22px;margin:0}.originals-hint{font-size:15px;line-height:1.5;margin:12px 0 18px}#originals-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.original-thumb{display:flex;flex-direction:column;gap:10px;padding:10px;border:1px solid #ad855066;border-radius:4px;background:#ffffff08;color:#eedbc0;text-align:left;min-width:0}.original-thumb img{width:100%;height:180px;object-fit:contain;image-orientation:from-image}.original-thumb span{font-size:14px;line-height:1.5;overflow-wrap:anywhere}#compare-actions{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;padding:10px}#compare-actions button{min-height:44px;padding:10px 16px;border:1px solid #ad8550;border-radius:4px;background:transparent;color:#34281d}#compare-actions button[aria-pressed=true]{background:#d8bd91;color:#241d15}[hidden]{display:none!important}@media(max-width:700px){#originals-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.original-thumb img{height:150px}.original-thumb span{font-size:12px}}

/* Original-photo navigation keeps controls below the full photograph. */
#original-navigation{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:16px;padding-top:12px;border-top:1px solid #bea47f}#original-navigation button{min-height:44px}#original-counter{font-size:16px;color:#34281d;white-space:nowrap}#compare-actions button:focus-visible{outline-color:#765b36}

/* On desktop, reserve space for comparison navigation below the photograph. */
@media(min-width:900px) and (min-height:600px){
 #viewer[open]{display:grid;grid-template-rows:auto auto minmax(0,1fr) auto auto;height:92dvh;overflow:hidden}
 #viewer>.dialog-head{grid-row:1}
 #viewer>#compare-actions{grid-row:2}
 #viewer #media{grid-row:3;min-height:0;height:100%;max-height:none}
 #viewer #media img,#viewer #media video{max-height:100%;max-width:100%;object-fit:contain}
 #viewer #media.enlarged img{max-height:none;max-width:none;width:180%}
 #viewer #view-caption{grid-row:4;max-height:14dvh;overflow:auto;margin:10px 0 0}
 #viewer #original-navigation{grid-row:5;margin-top:10px;padding-top:10px}
}
