#openBook{position:absolute;left:35%;top:54.5%;width:35%;height:28.5%;z-index:3;border:0;padding:0;clip-path:polygon(14% 0,48% 25%,75% 15%,100% 78%,36% 100%,0 70%);background:transparent;cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent}
#journey[data-mobile=true] #openBook{left:19%;top:55.5%;width:76%;height:19%;clip-path:polygon(14% 0,47% 30%,80% 22%,100% 80%,33% 100%,0 65%)}
#openBook:focus-visible{clip-path:none;outline:2px solid #dcc296;outline-offset:3px;border-radius:5px}
/* The book invitation rises from the dark front edge of the worktable. */
#tablePlane[data-guide-target=book] .portrait-guide{left:48.6%;top:78.4%;width:10%;height:18%;transform:none}
#journey[data-mobile=true] #tablePlane[data-guide-target=book] .portrait-guide{left:42%;top:69%;width:25%;height:11.5%}
#tablePlane[data-book-guide=true] .portrait-guide{opacity:1;visibility:visible}
#bookDialog{border:0;background:transparent;padding:12px;margin:auto;width:min(1350px,calc(100vw - 24px),calc((100dvh - 86px)*1.777));max-width:none;max-height:calc(100dvh - 24px);overflow:hidden;color:#ecdac0;opacity:0;transform:translateY(18px) scale(.88);transition:opacity 580ms ease,transform 680ms cubic-bezier(.2,.65,.25,1),display 580ms allow-discrete,overlay 580ms allow-discrete}
#bookDialog[open]{opacity:1;transform:translateY(0) scale(1)}
#bookDialog::backdrop{background:#100d09a8;opacity:0;transition:opacity 580ms ease,display 580ms allow-discrete,overlay 580ms allow-discrete}
#bookDialog[open]::backdrop{opacity:1}
@starting-style{#bookDialog[open]{opacity:0;transform:translateY(18px) scale(.88)}#bookDialog[open]::backdrop{opacity:0}}
.book-shell{position:relative;padding-top:48px}
.book-surface{position:relative;width:100%;aspect-ratio:1672/941;filter:drop-shadow(0 18px 20px #0009)}
.book-art-mobile{display:none}
.book-art{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;user-select:none}
.book-pages{position:absolute;inset:7% 10% 10%;display:grid;grid-template-columns:1fr 1fr;gap:12%}
.book-page{min-width:0;min-height:0;overflow:auto;color:#493b2d;font:19px/1.7 Georgia,serif}
#bookClose{position:absolute;top:0;right:8px;width:44px;height:44px;z-index:2;display:grid;place-items:center;padding:0;border:1px solid #d7bd8b80;border-radius:50%;background:#30281fe8;color:#f1dfbd;box-shadow:0 3px 10px #0004;font:32px/1 Georgia,serif;cursor:pointer;touch-action:manipulation}
#bookClose:hover{background:#51412b}#bookClose:focus-visible{outline:2px solid #efd4a5;outline-offset:3px}
#aboutOpenBook{display:block;min-height:44px;margin:26px auto 0;padding:10px 20px;border:1px solid #90795380;border-radius:3px;background:#fff9ed80;color:#57412c;font:17px/1.3 Georgia,serif;cursor:pointer;touch-action:manipulation}
#aboutOpenBook:hover{background:#fffaf0}#aboutOpenBook:focus-visible{outline:2px solid #806039;outline-offset:3px}
.book-page-contents{grid-column:2;grid-row:1}
.book-page-illustration{grid-column:1;grid-row:1;display:flex;align-items:center;justify-content:center;overflow:hidden;padding:8px}
.book-botanical{display:block;width:100%;height:100%;object-fit:contain;pointer-events:none;user-select:none;opacity:1}
@media(max-width:1023px) and (orientation:portrait){
 #bookDialog{width:min(calc(100vw - 8px),calc((100dvh - 80px)*.667));padding:4px}
 .book-surface{aspect-ratio:2/3;overflow:hidden}
 .book-art{display:none;left:0;width:100%;max-width:none}
 .book-art-mobile{display:block}
 .book-pages{inset:6% 13% 7% 17%;display:block}.book-page-contents{display:flex;height:100%}.book-page-illustration{display:none}
 /* Comparison only: ?book-layout=spread shows the whole spread on a phone. */
 #bookDialog[data-mobile-spread=true]{width:calc(100vw - 16px)}
 #bookDialog[data-mobile-spread=true] .book-surface{aspect-ratio:1672/941}
 #bookDialog[data-mobile-spread=true] .book-art{display:block;left:0;width:100%}
 #bookDialog[data-mobile-spread=true] .book-art-mobile{display:none}
 #bookDialog[data-mobile-spread=true] .book-pages{inset:7% 10% 10%;display:grid}
 #bookDialog[data-mobile-spread=true] .book-page-contents{display:flex}
 #bookDialog[data-mobile-spread=true] .book-page-illustration{display:block}
}
@media(prefers-reduced-motion:reduce){#bookDialog,#bookDialog::backdrop{transition:none;transform:none}}

/* Contents remain editable text, with the same quiet serif palette as About. */
.book-page-contents{display:flex;flex-direction:column;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#9e8462 transparent}
.book-contents{flex:0 0 auto;width:100%;margin:auto;padding:24px 18px 28px}
.book-contents h1{margin:0 0 18px;text-align:center;font:400 30px/1.25 Georgia,serif;letter-spacing:.025em;color:#4b3928}
.book-subtitle{margin:0 0 30px;text-align:center;font:17px/1.6 Georgia,serif;color:#79634b}
.book-contents ol{margin:0;padding:0;list-style:none;counter-reset:book-section;font:19px/1.7 Georgia,serif}
.book-contents li{counter-increment:book-section;display:grid;grid-template-columns:1.35em minmax(0,1fr);column-gap:.55em;align-items:baseline;padding:0;margin:0 0 14px}.book-contents li:last-child{margin-bottom:0}
/* Dedicated lining numerals avoid Georgia's varying old-style digit shapes. */
.book-contents li::before{content:counter(book-section) ".";display:block;text-align:right;white-space:nowrap;font:400 19px/1.7 "Times New Roman",Times,serif;font-variant-numeric:lining-nums tabular-nums;letter-spacing:0}
.book-page-contents:focus-visible{outline:2px solid #94774c;outline-offset:-2px}
@media(max-width:1023px) and (orientation:portrait){.book-contents{padding:14px 4px 22px}.book-contents h1{font-size:28px}.book-subtitle{margin-bottom:24px}.book-contents li{margin-bottom:12px}}

/* Approved contents artwork is shown whole; semantic text remains for screen readers. */
.book-page-contents{position:relative;align-items:center;justify-content:center}
.book-contents-approved{display:block;width:100%;height:100%;object-fit:contain;flex:0 0 auto;user-select:none}
.book-contents-accessible{position:absolute;width:1px;height:1px;min-height:0;margin:-1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);clip-path:inset(50%);white-space:nowrap}
@media(max-width:1023px) and (orientation:portrait){
 #bookDialog[data-contents-art=true]:not([data-mobile-spread=true]) .book-pages{inset:3% 7% 4% 13%}
}

/* Both approved prints use the book paper as their substrate. No new sheet. */
.book-pages{inset:7% 10%;column-gap:0}
.book-page-illustration{padding:0;justify-content:center;align-items:center}
.book-page-contents{padding:0}
.book-print{display:block;width:100%;height:100%;flex:0 0 auto;mix-blend-mode:multiply;pointer-events:none;user-select:none;overflow:visible;box-shadow:none;border:0}
.book-print.book-botanical{object-fit:initial}
@media(max-width:1023px) and (orientation:portrait){
 #bookDialog[data-contents-art=true]:not([data-mobile-spread=true]) .book-pages{inset:3% 10% 4% 12%}
}

.book-print-view{width:100%;height:100%;flex:0 0 auto}
.book-print-view[hidden],.book-chapter[hidden]{display:none}
.book-page-contents,.book-page-illustration{container-type:size}
.book-print-link{pointer-events:auto;touch-action:manipulation}
.book-print-link rect{fill:transparent;stroke:transparent;stroke-width:20px;vector-effect:non-scaling-stroke;pointer-events:all}
.book-print-link:focus{outline:none}
.book-print-link:focus-visible rect{stroke:#8d673f;stroke-width:1.5px;fill:#8d673f0a}
@container(max-height:400px){.book-print-link rect{stroke-width:8px}}
.book-chapter{flex:0 0 auto;align-self:stretch;min-height:100%;display:flex;flex-direction:column;padding:24px 20px 16px}
.book-chapter h2{margin:0;text-align:center;font:400 28px/1.4 Georgia,serif;color:#4b3928}
.book-chapter-body{flex:1;min-height:120px}
.book-return{display:block;align-self:center;min-height:44px;padding:8px 12px;font:18px/1.6 Georgia,serif;color:#65492f;text-underline-offset:4px;touch-action:manipulation}
.book-return:focus-visible{outline:2px solid #94774c;outline-offset:2px}

/* Match the mobile book's paper white point to the unchanged desktop spread. */
@media(max-width:1023px) and (orientation:portrait){
 .book-art-mobile{filter:url(#mobileBookPaperColor)}
}

/* Author jewelry uses the existing physical pages, fonts and ink. */
.jewelry-photo-page[hidden]{display:none}
.jewelry-photo-page{position:relative;inset:auto;display:grid;grid-template-rows:minmax(72px,auto) minmax(0,1fr);gap:0;width:100%;height:100%;min-height:0;padding:0 20px 36px;overflow:hidden}
.jewelry-photo-page h2{align-self:center;margin:0;text-align:center;font:400 28px/1.4 Georgia,serif;color:#4b3928}
.jewelry-photo-frame{min-width:0;min-height:0;display:flex;align-items:center;justify-content:center}
.jewelry-photo{display:block;width:auto;max-width:100%;height:100%;aspect-ratio:1024/1490;object-fit:cover;object-position:center top}
.jewelry-photo[hidden]{display:none}
#bookDialog[data-view^="jewelry"] .book-botanical{display:none}
#bookDialog[data-view^="jewelry"] .book-page-contents{justify-content:flex-start;align-items:stretch}
#chapter-jewelry>h2{display:none}
#chapter-jewelry{padding:24px 24px 16px}
.jewelry-copy{flex:1 0 auto;display:flex;flex-direction:column;justify-content:center;min-height:0;padding:0;font:19px/1.7 Georgia,serif;color:#493b2d}
.jewelry-copy p{margin:0 0 1.15em}.jewelry-copy p:last-child{margin-bottom:0}
#chapter-jewelry .book-return{margin-top:18px}
@media(max-width:1023px) and (orientation:portrait){
 #bookDialog[data-view="jewelry-photo"] .book-page-illustration{display:block;height:100%;overflow:hidden}
 #bookDialog[data-view="jewelry-photo"] .book-page-contents{display:none}
 #bookDialog[data-view="jewelry-text"] .book-page-illustration{display:none}
 #bookDialog[data-view^="jewelry"] .book-pages{inset:6% 10% 7% 15%}
 .jewelry-photo-page{padding:8px 4px 16px;grid-template-rows:minmax(76px,auto) minmax(0,1fr);gap:0}
 .jewelry-photo{width:100%;height:100%;aspect-ratio:auto;object-fit:contain;object-position:center}
 #chapter-jewelry{padding:16px 6px 14px}
}

#bookDialog .book-surface{touch-action:pan-y}
/* Programmatic reading focus must not draw a frame around the page text. */
#jewelry-photo-title:focus,.jewelry-copy:focus{outline:none}

/* Text flows onto further book pages; reading never requires vertical scrolling. */
#bookDialog[data-view^="jewelry"] .book-page{overflow:hidden}
#chapter-jewelry{height:100%;min-height:0;overflow:hidden}
#chapter-jewelry .jewelry-copy{flex:1 1 0;min-height:0;overflow:hidden}
#chapter-jewelry .book-return{flex:0 0 auto}
.jewelry-copy[data-measuring=true]{justify-content:flex-start}
.jewelry-continuation[hidden]{display:none}
.jewelry-continuation{display:flex;flex-direction:column;width:100%;height:100%;min-height:0;padding:24px 24px 16px;overflow:hidden}
.jewelry-continuation-copy{flex:1;min-height:0;display:flex;flex-direction:column;justify-content:center;overflow:hidden;font:19px/1.7 Georgia,serif;color:#493b2d}
.jewelry-continuation-copy p{margin:0 0 1.15em}.jewelry-continuation-copy p:last-child{margin-bottom:0}
.jewelry-continuation-copy:focus{outline:none}

.book-return[hidden]{display:none}
.jewelry-continuation>.book-return{flex:0 0 auto;margin-top:18px}

/* Immersive reader: the native paper fills the viewport, controls sit on its margins. */
#bookDialog{width:100vw;height:100dvh;max-width:none;max-height:none;margin:0;padding:0;overflow:hidden;transform:none;transition:opacity 220ms ease,display 220ms allow-discrete,overlay 220ms allow-discrete}
#bookDialog[open]{transform:none}
@starting-style{#bookDialog[open]{opacity:0;transform:none}}
#bookDialog .book-shell{width:100%;height:100%;padding:0}
#bookDialog .book-surface{width:100%;height:100%;aspect-ratio:auto}
#bookDialog .book-art{width:100%;height:100%;object-fit:fill}
#bookDialog .book-pages{inset:7% 10% calc(9% + 56px)}
.book-pagination{position:absolute;inset:0;z-index:3;pointer-events:none}
.book-pagination button{position:absolute;bottom:9%;width:44px;height:44px;min-width:44px;padding:0;border:0;background:transparent;color:#725c41;cursor:pointer;pointer-events:auto;touch-action:manipulation}
.book-pagination button::before{content:'';position:absolute;inset:5px;border:1px solid #90795370;border-radius:3px;background:#f4e6cb99;transition:background 160ms ease}
.book-pagination button svg{position:relative;display:block;margin:auto;width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
#bookPrevious{left:13%}#bookNext{right:13%}
.book-pagination button:hover:not(:disabled)::before{background:#fff4df}
.book-pagination button:disabled{opacity:.25;cursor:default}
.book-pagination button:focus-visible{outline:2px solid #806039;outline-offset:-1px}
#bookCounter{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.book-folio{position:absolute;bottom:calc(9% + 12px);transform:translateX(-50%);font:15px/20px Georgia,serif;color:#79664e;font-variant-numeric:lining-nums tabular-nums}
.book-folio-left{left:30%}.book-folio-right{left:70%}
.book-folio[hidden]{display:none}
#bookClose{top:max(8px,env(safe-area-inset-top));right:max(8px,env(safe-area-inset-right));width:44px;height:44px;border:0;background:transparent;box-shadow:none;color:#65513c;font:24px/1 Georgia,serif;z-index:4}
#bookClose::before{content:'';position:absolute;inset:8px;border:1px solid #90795370;border-radius:50%;background:#f4e6cbe6}
#bookClose span{position:relative}
#bookClose:hover{background:transparent}#bookClose:hover::before{background:#fff4df}
#bookClose:focus-visible{outline:2px solid #806039;outline-offset:-2px}
@media(max-width:1023px) and (orientation:portrait){
 #bookDialog[data-contents-art=true]:not([data-mobile-spread=true]) .book-pages{inset:4% 10% calc(5% + 56px) 12%}
 #bookDialog[data-view^="jewelry"]:not([data-mobile-spread=true]) .book-pages{inset:6% 10% calc(5% + 56px) 15%}
 .book-pagination button{bottom:5%}
 #bookPrevious{left:15%}#bookNext{right:10%}
 .book-folio{bottom:calc(5% + 12px)}
 .book-folio-right{left:52.5%}
}
@media(prefers-reduced-motion:reduce){#bookDialog,#bookDialog::backdrop{transition:none;transform:none}}

/* Text pages share a fixed optical centre, independently of the final return link. */
#chapter-jewelry,.jewelry-continuation{position:relative}
#chapter-jewelry .jewelry-copy,.jewelry-continuation-copy{padding-block:62px}
#chapter-jewelry .book-return,.jewelry-continuation>.book-return{position:absolute;left:50%;bottom:16px;transform:translateX(-50%);margin:0;white-space:nowrap}
/* Feather only the photograph perimeter; the hands and bracelet remain sharp. */
.jewelry-photo{--photo-feather:14px;mask-image:linear-gradient(to right,transparent,#000 var(--photo-feather),#000 calc(100% - var(--photo-feather)),transparent),linear-gradient(to bottom,transparent,#000 var(--photo-feather),#000 calc(100% - var(--photo-feather)),transparent);mask-composite:intersect;-webkit-mask-composite:source-in}
@media(max-width:1023px) and (orientation:portrait){
 .jewelry-photo-page h2{line-height:1.16}
 .jewelry-photo{--photo-feather:10px}
}
@media(max-height:480px) and (orientation:landscape){
 #bookDialog[data-section="aromalava"] .jewelry-photo-page h2{line-height:1.16}
}

/* One title slot and one centred text slot per chapter keep every page aligned. */
.jewelry-photo-page{grid-template-rows:88px minmax(0,1fr)}
.jewelry-photo-page h2{align-self:center;justify-self:stretch;text-align:center;line-height:1.16}
.book-text-block{flex:0 0 auto;width:100%;display:flow-root}

.jewelry-photo-page h2 .book-heading-number{font-family:"Times New Roman",Times,serif;font-size:1.07em;font-variant-numeric:lining-nums tabular-nums;font-feature-settings:"lnum" 1,"onum" 0;vertical-align:baseline;line-height:inherit}

/* Reuse the wide spread's original paper within the existing mobile binding.
   Feather only the join to its native page edge; content and controls stay above. */
@media(max-width:1023px) and (orientation:portrait){
 #bookDialog:not([data-mobile-spread=true]) .book-surface::after{
  content:'';position:absolute;inset:3.4% 10.6% 3.7% 11.1%;z-index:0;
  background:#ead8b7 url('assets/open-book-blank.webp') 83.17% 43.65% / 257.23% 115.46% no-repeat;
  pointer-events:none;border-radius:1% 3% 3% 0;
  mask-image:linear-gradient(to right,transparent,#000 2%,#000 98%,transparent),linear-gradient(to bottom,transparent,#000 1%,#000 99%,transparent);
  mask-composite:intersect;
  -webkit-mask-image:linear-gradient(to right,transparent,#000 2%,#000 98%,transparent),linear-gradient(to bottom,transparent,#000 1%,#000 99%,transparent);
  -webkit-mask-composite:source-in;
 }
 #bookDialog:not([data-mobile-spread=true]) .book-pages{z-index:1}
}
