
html, body { height: 100%; margin: 0; overflow: hidden; }
body {
  background: radial-gradient(ellipse at 50% 38%, #45403a 0%, #2e2a26 55%, #1d1a17 100%);
  overscroll-behavior: none;
  -webkit-user-select: none; user-select: none;
}
#stage {
  position: fixed; inset: 0;
  display: flex; align-items: center; justify-content: center;
  touch-action: none;
}
#flipbook { position: relative; }
#flipbook.open { box-shadow: 0 22px 60px rgba(0,0,0,.55), 0 4px 14px rgba(0,0,0,.4); }

/* ---------- hard covers ---------- */
.cover {
  background:
    radial-gradient(ellipse at 30% 25%, rgba(255,255,255,.09), rgba(255,255,255,0) 55%),
    linear-gradient(135deg, #142e56 0%, #24487f 46%, #142e56 100%);
  box-shadow: inset 0 0 40px rgba(0,0,0,.35);
}
.cover-front::before, .cover-back::before {
  content: ''; position: absolute; top: 0; bottom: 0; width: 12%;
  pointer-events: none; z-index: 2;
}
.cover-front::before { left: 0;  background: linear-gradient(to right, rgba(0,0,0,.5), rgba(0,0,0,.14) 55%, rgba(0,0,0,0)); }
.cover-back::before  { right: 0; background: linear-gradient(to left,  rgba(0,0,0,.5), rgba(0,0,0,.14) 55%, rgba(0,0,0,0)); }
.cover-inner { position: absolute; inset: 0; }
.cover-frame {
  position: absolute; inset: 7%;
  border: 3px double #c9a84c; border-radius: 3px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; color: #e7c96f;
  font-family: Georgia, 'Palatino Linotype', serif;
  padding: 0 6%;
}
.cover-title {
  font-variant: small-caps; letter-spacing: .1em;
  font-size: 2em; line-height: 1.25;
  text-shadow: 0 2px 3px rgba(0,0,0,.55);
}
.cover-orn { color: #b89a4e; font-size: 1.5em; margin-top: 1.1em; }
.cover-orn.big { font-size: 2.4em; }
.cover-sub { letter-spacing: .5em; font-size: .68em; margin-top: 1em; color: #cdb069; text-indent: .5em; }
.cover-author { margin-top: 2.4em; font-variant: small-caps; letter-spacing: .18em; font-size: 1.02em; color: #e2c26a; }

/* ---------- endpapers ---------- */
.endpaper {
  background:
    repeating-linear-gradient(45deg, rgba(120,96,58,.05) 0 3px, rgba(0,0,0,0) 3px 6px),
    linear-gradient(#e8dfc8, #dcd2b6);
  box-shadow: inset 0 0 55px rgba(96,74,40,.25);
}

/* ---------- paper pages ---------- */
.paper {
  background:
    radial-gradient(ellipse at 50% 45%, #faf5e9 55%, #f1e8d4 92%, #eadfc7 100%);
  color: #33291f;
}
/* inner spine shadow — the fold between the two pages of a spread */
.pg-right::before {
  content: ''; position: absolute; top: 0; bottom: 0; left: 0; width: 9%;
  background: linear-gradient(to right, rgba(84,26,18,.30), rgba(84,26,18,.10) 52%, rgba(84,26,18,0));
  pointer-events: none; z-index: 3;
}
.pg-left::before {
  content: ''; position: absolute; top: 0; bottom: 0; right: 0; width: 9%;
  background: linear-gradient(to left, rgba(84,26,18,.26), rgba(84,26,18,.09) 52%, rgba(84,26,18,0));
  pointer-events: none; z-index: 3;
}
.pg-single::before {
  content: ''; position: absolute; top: 0; bottom: 0; left: 0; width: 6%;
  background: linear-gradient(to right, rgba(62,44,16,.18), rgba(84,26,18,0));
  pointer-events: none; z-index: 3;
}
/* outer edge — hint of the closed page stack */
.pg-right::after, .pg-left::after {
  content: ''; position: absolute; top: 0; bottom: 0; width: 7px;
  pointer-events: none; z-index: 3; opacity: .5;
}
.pg-right::after { right: 0; background: repeating-linear-gradient(to left, rgba(90,70,40,.16) 0 1px, rgba(0,0,0,0) 1px 3px); }
.pg-left::after  { left: 0;  background: repeating-linear-gradient(to right, rgba(90,70,40,.16) 0 1px, rgba(0,0,0,0) 1px 3px); }

/* ---------- text ---------- */
.textenv {
  font-family: Georgia, 'Palatino Linotype', 'Book Antiqua', 'Times New Roman', serif;
  line-height: 1.55; text-align: justify;
  hyphens: auto; -webkit-hyphens: auto; -ms-hyphens: auto;
  text-rendering: optimizeLegibility;
  color: #33291f;
}
.textenv p { margin: 0; text-indent: 1.5em; }
.textenv p.noind { text-indent: 0; }
.chead { margin-bottom: 1.25em; }
.cnum {
  text-align: center; font-variant: small-caps;
  letter-spacing: .24em; font-size: 1.26em;
  padding-top: 1em; text-indent: .24em; color: #4a3b28;
}
.corn { text-align: center; color: #8a744a; margin-top: .4em; font-size: 1em; }
.brk { text-align: center; margin: 1.1em 0; color: #8a744a; font-size: .78em; letter-spacing: .5em; text-indent: .5em; }
.theend { text-align: center; margin-top: 2.6em; letter-spacing: .4em; text-indent: .4em; font-size: 1.02em; color: #5a4a33; }
.folio { text-align: center; font-size: .66em; letter-spacing: .18em; color: #8d7b5f; font-family: Georgia, serif; }

/* ---------- title page ---------- */
.titlepage {
  position: absolute; inset: 10% 12%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; font-family: Georgia, 'Palatino Linotype', serif; color: #3d3020;
}
.tp-title { font-variant: small-caps; font-size: 1.85em; letter-spacing: .1em; line-height: 1.3; }
.tp-rule { width: 42%; height: 1px; background: #a08c5a; margin: 1.4em 0; }
.tp-sub { letter-spacing: .45em; font-size: .72em; color: #6a583c; text-indent: .45em; }
.tp-by { margin-top: 2.2em; font-style: italic; font-size: .85em; color: #6a583c; }
.tp-author { margin-top: .5em; font-variant: small-caps; letter-spacing: .16em; font-size: 1.12em; }
.tp-orn { margin-top: 2.2em; color: #8a744a; font-size: 1.3em; }

/* ---------- chrome ---------- */
.nav {
  position: fixed; top: 50%; transform: translateY(-50%);
  z-index: 60; cursor: pointer;
  font: 46px/1 Georgia, serif; color: rgba(255,255,255,.30);
  padding: 26px 14px; transition: color .2s;
  background: none; border: 0; margin: 0;
  -webkit-appearance: none; appearance: none;
}
.nav:hover { color: rgba(255,255,255,.75); }
#nav-prev { left: 4px; }
#nav-next { right: 4px; }

#hint {
  position: fixed; left: 50%; bottom: 58px; transform: translateX(-50%);
  z-index: 60; font: 12.5px/1.4 Georgia, serif; letter-spacing: .06em;
  color: rgba(255,255,255,.45); background: rgba(0,0,0,.25);
  padding: 6px 14px; border-radius: 20px; white-space: nowrap;
  transition: opacity 1.2s; pointer-events: none;
}
#hint.gone { opacity: 0; }

#loader {
  position: fixed; inset: 0; z-index: 100;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  background: rgba(24,21,18,.82);
  font: 15px Georgia, serif; letter-spacing: .08em; color: #d8c9a6;
  opacity: 0; pointer-events: none; transition: opacity .25s;
}
#loader.show { opacity: 1; pointer-events: auto; }
#loader .spin {
  width: 34px; height: 34px; border-radius: 50%;
  border: 3px solid rgba(216,201,166,.25); border-top-color: #d8c9a6;
  animation: lspin .9s linear infinite;
}
@keyframes lspin { to { transform: rotate(360deg); } }

/* ---------- embossed cover tooling ---------- */
.cover-inner::before {
  content: ''; position: absolute; inset: 2.2%;
  pointer-events: none; opacity: .9;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='28'%20height='28'%3E%20%3Cg%20fill='none'%20stroke-width='1.4'%3E%20%3Cg%20transform='translate(0.9,0.9)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.6,-0.6)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E"), url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='28'%20height='28'%3E%20%3Cg%20fill='none'%20stroke-width='1.4'%3E%20%3Cg%20transform='translate(0.9,0.9)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.6,-0.6)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E"), url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='28'%20height='28'%3E%20%3Cg%20fill='none'%20stroke-width='1.4'%3E%20%3Cg%20transform='translate(0.9,0.9)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.6,-0.6)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E"), url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='28'%20height='28'%3E%20%3Cg%20fill='none'%20stroke-width='1.4'%3E%20%3Cg%20transform='translate(0.9,0.9)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.6,-0.6)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Cpath%20d='M14%206%20L22%2014%20L14%2022%20L6%2014%20Z'/%3E%3Ccircle%20cx='14'%20cy='14'%20r='1.8'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E");
  background-repeat: repeat-x, repeat-x, repeat-y, repeat-y;
  background-position: left top, left bottom, left top, right top;
  background-size: 28px 28px;
}
.cover-inner::after {
  content: ''; position: absolute; inset: 1.4%;
  pointer-events: none; opacity: .95;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='56'%20height='56'%3E%20%3Cg%20fill='none'%20stroke-width='1.5'%3E%20%3Cg%20transform='translate(1,1)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.7,-0.7)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E"), url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='56'%20height='56'%3E%20%3Cg%20fill='none'%20stroke-width='1.5'%3E%20%3Cg%20transform='translate(1,1)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.7,-0.7)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E"), url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='56'%20height='56'%3E%20%3Cg%20fill='none'%20stroke-width='1.5'%3E%20%3Cg%20transform='translate(1,1)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.7,-0.7)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E"), url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='56'%20height='56'%3E%20%3Cg%20fill='none'%20stroke-width='1.5'%3E%20%3Cg%20transform='translate(1,1)'%20stroke='rgba(0,0,0,0.50)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3Cg%20transform='translate(-0.7,-0.7)'%20stroke='rgba(255,255,255,0.13)'%3E%20%3Ccircle%20cx='28'%20cy='28'%20r='16'/%3E%3Ccircle%20cx='28'%20cy='28'%20r='9'/%3E%20%3Cpath%20d='M28%2012%20Q31%2020%2028%2024%20Q25%2020%2028%2012%20Z%20M28%2044%20Q31%2036%2028%2032%20Q25%2036%2028%2044%20Z%20M12%2028%20Q20%2031%2024%2028%20Q20%2025%2012%2028%20Z%20M44%2028%20Q36%2031%2032%2028%20Q36%2025%2044%2028%20Z'/%3E%20%3C/g%3E%20%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left top, right top, left bottom, right bottom;
  background-size: 52px 52px;
}

/* ---------- illustration captions & display lines ---------- */
.illus {
  margin: 1.15em 5%; padding: .5em 3%;
  text-align: center; font-style: italic;
  font-size: .84em; line-height: 1.45; color: #6b5a3e;
  border-top: 1px solid rgba(122,100,60,.4);
  border-bottom: 1px solid rgba(122,100,60,.4);
}
.disp {
  text-align: center; margin: 1em 8%;
  font-variant: small-caps; letter-spacing: .12em;
  font-size: .95em; color: #4a3b28;
}

.ctitle {
  text-align: center; font-variant: small-caps;
  letter-spacing: .08em; font-size: 1.05em;
  margin-top: .45em; color: #5a4a33;
}
.verse {
  text-align: center; font-style: italic;
  margin: 1.1em 0; line-height: 1.65; color: #4a3b28;
}

.letter {
  margin: 1.1em 6%; padding: .7em 1em;
  font-size: .88em; line-height: 1.6; font-style: italic;
  color: #4a3b28; background: rgba(146,120,70,.07);
  border-left: 2px solid rgba(122,100,60,.45);
}

.songtitle {
  text-align: center; font-variant: small-caps; letter-spacing: .18em;
  text-indent: .18em; font-size: .92em; color: #5a4a33; margin: 1.2em 0 .3em;
}
.plate {
  margin: 1.2em auto; padding: .45em 1.2em; width: fit-content;
  text-align: center; letter-spacing: .3em; text-indent: .3em; font-size: .86em;
  color: #4a3b28; border: 1px solid rgba(122,100,60,.55); border-radius: 2px;
  background: rgba(170,150,95,.14);
}
.prog {
  margin: 1.1em 6%; text-align: center; font-size: .85em; line-height: 1.75;
  color: #4a3b28; border-top: 1px solid rgba(122,100,60,.4);
  border-bottom: 1px solid rgba(122,100,60,.4); padding: .7em 0;
}


/* ---------- skip to page (fixed overlay: never touches #flipbook) ---------- */
#skipbar {
  position: fixed; left: 50%; bottom: 12px;
  transform: translateX(-50%) translateY(10px);
  z-index: 70;
  display: flex; align-items: center; gap: 8px;
  opacity: 0; pointer-events: none;
  transition: opacity .32s ease, transform .32s ease;
  font-family: Georgia, 'Palatino Linotype', serif;
}
#skipbar.vis { opacity: 1; pointer-events: auto; transform: translateX(-50%) translateY(0); }

#skipbar button {
  font: 13.5px/1 Georgia, serif; letter-spacing: .06em;
  color: #ffeec0; background: rgba(38,10,66,.85);
  border: 1px solid rgba(255,216,106,.55); border-radius: 18px;
  padding: 9px 16px; cursor: pointer;
  -webkit-appearance: none; appearance: none;
  transition: background .18s, color .18s, border-color .18s;
}
#skipbar button:hover { background: rgba(70,21,122,.94); color: #fff8dc; border-color: #ffd86a; }
#skipbar button:focus-visible { outline: 2px solid #ffd86a; outline-offset: 2px; }

#skip-wrap {
  display: none; align-items: center; gap: 6px;
  background: rgba(38,10,66,.9);
  border: 1px solid rgba(255,216,106,.55); border-radius: 18px;
  padding: 5px 6px 5px 12px;
}
#skip-wrap.open { display: flex; }
#skip-btn.gone { display: none; }

#skip-input {
  width: 74px; font: 14px/1 Georgia, serif; text-align: center;
  color: #1b0733; background: #f8f0e2;
  border: 1px solid rgba(255,216,106,.7); border-radius: 12px;
  padding: 7px 8px; -webkit-appearance: none; appearance: none;
}
#skip-input:focus { outline: 2px solid #ffd86a; outline-offset: 1px; }
#skip-err {
  font: 11.5px/1 Georgia, serif; letter-spacing: .05em;
  color: rgba(255,238,192,.72); padding-right: 8px; white-space: nowrap;
}

@keyframes skipShake {
  0%,100% { transform: translateX(0); }
  20% { transform: translateX(-5px); } 40% { transform: translateX(5px); }
  60% { transform: translateX(-3px); } 80% { transform: translateX(3px); }
}
#skip-wrap.bad { animation: skipShake .34s ease; border-color: #ff5c7a; }
#skip-wrap.bad #skip-err { color: #ffb3c1; }

@media (prefers-reduced-motion: reduce) {
  #skipbar { transition: opacity .2s ease; transform: translateX(-50%); }
  #skipbar.vis { transform: translateX(-50%); }
  #skip-wrap.bad { animation: none; }
}

/* ---------- chapter half-title page ----------
   Same cream stock, margins and rules as a text page; no folio, as a printed
   half-title carries none. .chapanim is an empty full-bleed stage kept for
   per-chapter artwork later. Animation "rise and settle": numeral lifts, a
   hairline draws outward from the centre, the title follows.                */
.paper.intro { overflow: hidden; }

.intropage {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.chapanim { position: absolute; inset: 0; pointer-events: none; }

.intro-label {
  position: relative; z-index: 2;
  text-align: center; padding: 0 14%;
  font-family: Georgia, 'Palatino Linotype', serif;
  color: #3a2f22;
}
.intro-label .il-num {
  display: block; font-size: .74em; letter-spacing: .34em;
  text-transform: uppercase; color: #8a6d3a;
}
.intro-label .il-rule {
  display: block; height: 1px; width: 0; margin: 1.15em auto;
  background: linear-gradient(to right, transparent, #b08d4c, transparent);
}
.intro-label .il-txt {
  display: block; font-size: 1.42em; line-height: 1.35; letter-spacing: .04em;
}
.intro-label .il-txt.il-solo {
  font-size: 1.9em; letter-spacing: .3em; text-indent: .3em; text-transform: uppercase;
}

/* the reveal runs when the page comes into view, not on a loop */
.intropage .il-num,
.intropage .il-rule,
.intropage .il-txt { opacity: 0; }

.intropage.play .il-num  { animation: introUp   .70s ease-out .10s both; }
.intropage.play .il-rule { animation: introRule .60s ease-out .68s both; }
.intropage.play .il-txt  { animation: introUp   .80s ease-out 1.00s both; }

@keyframes introUp   { from { opacity: 0; transform: translateY(12px); }
                       to   { opacity: 1; transform: none; } }
@keyframes introRule { from { width: 0;  opacity: 0; }
                       to   { width: 42%; opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .intropage .il-num, .intropage .il-txt { opacity: 1; }
  .intropage .il-rule { opacity: 1; width: 42%; }
  .intropage.play .il-num,
  .intropage.play .il-rule,
  .intropage.play .il-txt { animation: none; }
}


/* ---------- translator's footnote ----------
   Three notes in Crime and Punishment are the translator's, not Dostoevsky's.
   They are set smaller and ruled off so they can't be mistaken for the text. */
.tnote { font-size: .82em; line-height: 1.5; color: #5b4f3f; margin: 1.05em 0 .95em;
         padding-top: .55em; border-top: 1px solid rgba(90,70,40,.28); text-indent: 0; }
.tnote::before { content: '\2020\2003'; color: #937a45; }


/* ---------- part half-title ----------
   'Part I' owns a whole leaf, like a chapter half-title. .partanim is a
   full-bleed stage left deliberately empty: the per-part animation goes there
   later and needs no change to the page geometry. The page keeps the ordinary
   paper aesthetic rather than going dark. */
.paper.part { overflow: hidden; }
.parttitle { position: absolute; inset: 0; display: flex;
             flex-direction: column; align-items: center; justify-content: center; }
.partanim  { position: absolute; inset: 0; pointer-events: none; }
.part-label { position: relative; z-index: 2; text-align: center; padding: 0 14%;
              font-family: Georgia,'Palatino Linotype',serif; color: #3a2f22; }
.part-label .pt-rule { display: block; height: 1px; width: 0; margin: 1.5em auto;
              background: linear-gradient(to right, transparent, #b08d4c, transparent); }
.part-label .pt-txt  { display: block; font-size: 2.1em; letter-spacing: .34em;
              text-indent: .34em; text-transform: uppercase; }

.parttitle .pt-txt, .parttitle .pt-rule { opacity: 0; }
.parttitle.play .pt-rule:first-child { animation: ptRule .60s ease-out .10s both; }
.parttitle.play .pt-txt              { animation: ptUp   .80s ease-out .42s both; }
.parttitle.play .pt-rule:last-child  { animation: ptRule .60s ease-out .95s both; }
@keyframes ptUp   { from { opacity:0; transform: translateY(14px); } to { opacity:1; transform:none; } }
@keyframes ptRule { from { width:0; opacity:0; } to { width:46%; opacity:1; } }


/* ---------- signature and subhead ----------
   Both were emitted by the engine but never styled: 75 signature lines across
   Little Women, Pride and Prejudice and The Jungle Book were rendering as
   ordinary paragraphs. A signature closes a letter, so it sits right and
   italic; a subhead is a minor division inside a chapter. */
.sig { text-align: right; font-style: italic; text-indent: 0;
       margin: .35em 0 1.05em; padding-right: .4em; color: #40362a; }
.subhead { text-align: center; text-indent: 0; margin: 1.35em 0 .85em;
           font-size: .93em; letter-spacing: .17em; text-transform: uppercase;
           color: #5b4a33; }


/* ---------- A Room with a View: the shutters open on Florence ---------- */
.cover-front .cover-frame { padding: 0; border: 0; }
.cover-front .cover-title { width: 100%; font-size: 1em; letter-spacing: 0; text-shadow: none; }
.cover-front svg.cvsvg { width: 100%; height: auto; display: block; overflow: visible; }
.cover-front .cover-orn, .cover-front .cover-sub, .cover-front .cover-author { display: none; }

.cover-front .cvsvg text { font-family: Georgia,'Times New Roman',serif; text-anchor: middle; }
.cover-front .emb-d, .cover-front .emb-l, .cover-front .emb-f { font-size: 62px; letter-spacing: 9px; font-weight: 700; }
.cover-front .emb-d { fill:#5c2f18; transform: translateY(2.5px); }
.cover-front .emb-l { fill:#fff4dc; opacity:.34; transform: translateY(-1.1px); }
.cover-front .emb-f { fill:url(#rgold); }
.cover-front .wth   { font-size:33px; fill:#f0dcb4; font-style:italic; letter-spacing:3px; }
.cover-front .bylsm { font-size:16px; letter-spacing:6px; fill:#f0dcb4; }
.cover-front .bylbg { font-size:31px; letter-spacing:5px; fill:url(#rgold); }

/* one-shot reveals */
.cover-front .ttl { opacity:0; animation: rvTitle 1.40s ease-out .18s forwards; }
.cover-front .byl { opacity:0; animation: rvFade 1.25s ease-out 3.05s forwards; }
@keyframes rvTitle { from { opacity:0; transform: translateY(-15px); } to { opacity:1; transform:none; } }
@keyframes rvFade  { from { opacity:0; } to { opacity:1; } }

/* the shutters swing open — the whole point of the cover */
.cover-front .shL { transform-origin: 150px 432px; animation: rvShutL 1.90s cubic-bezier(.3,.85,.35,1) .95s forwards; }
@keyframes rvShutL { 0%,8% { transform: perspective(760px) rotateY(0deg); } 100% { transform: perspective(760px) rotateY(-88deg); } }
.cover-front .shR { transform-origin: 450px 432px; animation: rvShutR 2.14s cubic-bezier(.3,.85,.35,1) 1.12s forwards; }
@keyframes rvShutR { 0%,8% { transform: perspective(760px) rotateY(0deg); } 100% { transform: perspective(760px) rotateY(88deg); } }

/* the view breathes — every element on its own period */
.cover-front .sun     { animation: rvSun 7.30s ease-in-out infinite; transform-origin:364px 340px; }
@keyframes rvSun      { 0%,100% { opacity:.80; transform:scale(1); } 50% { opacity:1; transform:scale(1.09); } }
.cover-front .hillfar { animation: rvHaze 11.70s ease-in-out infinite; }
@keyframes rvHaze     { 0%,100% { opacity:.72; } 50% { opacity:.50; } }
.cover-front .s0 { animation: rvShim0 4.10s ease-in-out 0.40s infinite; }
@keyframes rvShim0 { 0%,100% { opacity:.20; transform:translateX(-7px); } 50% { opacity:.62; transform:translateX(7px); } }
.cover-front .s1 { animation: rvShim1 4.73s ease-in-out 0.71s infinite; }
@keyframes rvShim1 { 0%,100% { opacity:.20; transform:translateX(-7px); } 50% { opacity:.62; transform:translateX(7px); } }
.cover-front .s2 { animation: rvShim2 5.36s ease-in-out 1.02s infinite; }
@keyframes rvShim2 { 0%,100% { opacity:.20; transform:translateX(-7px); } 50% { opacity:.62; transform:translateX(7px); } }
.cover-front .s3 { animation: rvShim3 5.99s ease-in-out 1.33s infinite; }
@keyframes rvShim3 { 0%,100% { opacity:.20; transform:translateX(-7px); } 50% { opacity:.62; transform:translateX(7px); } }
.cover-front .v0.swift { animation: rvSwift0 9.40s linear 1.90s infinite; }
@keyframes rvSwift0 { 0% { transform:translate(0,0); opacity:0; } 12% { opacity:.85; } 88% { opacity:.85; } 100% { transform:translate(150px,-34px); opacity:0; } }
.cover-front .v1.swift { animation: rvSwift1 10.77s linear 3.00s infinite; }
@keyframes rvSwift1 { 0% { transform:translate(0,0); opacity:0; } 12% { opacity:.85; } 88% { opacity:.85; } 100% { transform:translate(150px,-34px); opacity:0; } }
.cover-front .v2.swift { animation: rvSwift2 12.14s linear 4.10s infinite; }
@keyframes rvSwift2 { 0% { transform:translate(0,0); opacity:0; } 12% { opacity:.85; } 88% { opacity:.85; } 100% { transform:translate(150px,-34px); opacity:0; } }
.cover-front .c0 { animation: rvCyp0 6.20s ease-in-out 0.50s infinite; transform-origin: bottom; }
@keyframes rvCyp0 { 0%,100% { transform:skewX(0deg); } 50% { transform:skewX(1.6deg); } }
.cover-front .c1 { animation: rvCyp1 6.67s ease-in-out 0.79s infinite; transform-origin: bottom; }
@keyframes rvCyp1 { 0%,100% { transform:skewX(0deg); } 50% { transform:skewX(1.9deg); } }
.cover-front .c2 { animation: rvCyp2 7.14s ease-in-out 1.08s infinite; transform-origin: bottom; }
@keyframes rvCyp2 { 0%,100% { transform:skewX(0deg); } 50% { transform:skewX(2.2deg); } }
.cover-front .c3 { animation: rvCyp3 7.61s ease-in-out 1.37s infinite; transform-origin: bottom; }
@keyframes rvCyp3 { 0%,100% { transform:skewX(0deg); } 50% { transform:skewX(2.4deg); } }
.cover-front .c4 { animation: rvCyp4 8.08s ease-in-out 1.66s infinite; transform-origin: bottom; }
@keyframes rvCyp4 { 0%,100% { transform:skewX(0deg); } 50% { transform:skewX(2.7deg); } }
.cover-front .c5 { animation: rvCyp5 8.55s ease-in-out 1.95s infinite; transform-origin: bottom; }
@keyframes rvCyp5 { 0%,100% { transform:skewX(0deg); } 50% { transform:skewX(3.0deg); } }

/* violets open one after another, none in step with another */
.cover-front .vio.v0 { transform-origin: center; opacity:0; animation: rvVio0 0.70s ease-out 2.30s both, rvSway0 3.05s ease-in-out 3.00s infinite; }
@keyframes rvVio0 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway0 { 0%,100% { transform:rotate(-2.4deg); } 50% { transform:rotate(2.4deg); } }
.cover-front .vio.v1 { transform-origin: center; opacity:0; animation: rvVio1 0.70s ease-out 2.43s both, rvSway1 3.39s ease-in-out 3.19s infinite; }
@keyframes rvVio1 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway1 { 0%,100% { transform:rotate(-2.6deg); } 50% { transform:rotate(2.6deg); } }
.cover-front .vio.v2 { transform-origin: center; opacity:0; animation: rvVio2 0.70s ease-out 2.56s both, rvSway2 3.73s ease-in-out 3.38s infinite; }
@keyframes rvVio2 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway2 { 0%,100% { transform:rotate(-2.8deg); } 50% { transform:rotate(2.8deg); } }
.cover-front .vio.v3 { transform-origin: center; opacity:0; animation: rvVio3 0.70s ease-out 2.69s both, rvSway3 4.07s ease-in-out 3.57s infinite; }
@keyframes rvVio3 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway3 { 0%,100% { transform:rotate(-3.0deg); } 50% { transform:rotate(3.0deg); } }
.cover-front .vio.v4 { transform-origin: center; opacity:0; animation: rvVio4 0.70s ease-out 2.82s both, rvSway4 4.41s ease-in-out 3.76s infinite; }
@keyframes rvVio4 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway4 { 0%,100% { transform:rotate(-3.2deg); } 50% { transform:rotate(3.2deg); } }
.cover-front .vio.v5 { transform-origin: center; opacity:0; animation: rvVio5 0.70s ease-out 2.95s both, rvSway5 4.75s ease-in-out 3.95s infinite; }
@keyframes rvVio5 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway5 { 0%,100% { transform:rotate(-3.4deg); } 50% { transform:rotate(3.4deg); } }
.cover-front .vio.v6 { transform-origin: center; opacity:0; animation: rvVio6 0.70s ease-out 3.08s both, rvSway6 5.09s ease-in-out 4.14s infinite; }
@keyframes rvVio6 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway6 { 0%,100% { transform:rotate(-3.6deg); } 50% { transform:rotate(3.6deg); } }
.cover-front .vio.v7 { transform-origin: center; opacity:0; animation: rvVio7 0.70s ease-out 3.21s both, rvSway7 5.43s ease-in-out 4.33s infinite; }
@keyframes rvVio7 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway7 { 0%,100% { transform:rotate(-3.8deg); } 50% { transform:rotate(3.8deg); } }
.cover-front .vio.v8 { transform-origin: center; opacity:0; animation: rvVio8 0.70s ease-out 3.34s both, rvSway8 5.77s ease-in-out 4.52s infinite; }
@keyframes rvVio8 { from { opacity:0; transform:scale(.35); } to { opacity:1; transform:scale(1); } }
@keyframes rvSway8 { 0%,100% { transform:rotate(-4.0deg); } 50% { transform:rotate(4.0deg); } }
