.stage{max-width:430px;transition:max-width 1s cubic-bezier(.22,.65,.28,1)}.stage:has(.book.open){max-width:800px}.book{background:#55202c;border-radius:12px;box-shadow:0 28px 60px #40231d30,3px 4px 0 #3f1621,5px 6px 0 #8b6a54}.cover{background:linear-gradient(110deg,#fff3 0,transparent 20%,#0003 100%),url(assets/leather-cover.png.preview.webp) center/cover;border-radius:11px;padding:35px 30px;color:#d9bc78;box-shadow:inset 4px 0 6px #0006,inset -2px -2px 3px #230d16,inset 0 0 0 8px #0002;overflow:hidden}.cover:before{content:'';position:absolute;inset:13px;border:1px solid #c79c5870;border-radius:6px;box-shadow:0 1px 0 #190c1899,inset 0 1px 0 #ffd69b30;pointer-events:none}.cover:after{content:'';position:absolute;inset:22px;border:1px solid #b6824344;border-radius:3px;box-shadow:0 1px 1px #1b0a18,inset 0 1px 1px #ffd69b29;pointer-events:none}.cover>*{position:relative;z-index:1}.cover h1{font:25px/1.3 Arial,sans-serif;letter-spacing:6px;margin:8px 0;color:#e3c786;text-shadow:0 1px 0 #fff0bb65,0 -1px 1px #200b14,1px 2px 2px #170913}.cover .subtitle{font:10px/1.5 Arial,sans-serif;letter-spacing:3px;margin:8px 0 18px;color:#cfad6c;text-shadow:0 -1px 1px #200b14}.passport-crest{position:relative;width:190px;height:190px;margin:20px 0 23px;display:grid;place-items:center;border:1px solid #b68c4666;border-radius:50%;box-shadow:0 1px 1px #160711,inset 0 1px 0 #e9c17d33}.passport-crest:before{content:'';position:absolute;inset:9px;border-radius:50%;border:1px solid #c49e5755;box-shadow:0 1px 1px #190916}.passport-crest>img{width:146px;height:146px;filter:drop-shadow(0 1px 0 #ffe4ab55) drop-shadow(1px 2px 1px #140911)}.crest-leaves{position:absolute;width:220px;height:220px;inset:-15px;fill:none;stroke:#c09752;stroke-width:.9;filter:drop-shadow(0 1px 0 #f1ce8c33) drop-shadow(0 -1px 1px #150910)}.cover .names{font-size:35px;line-height:1.15;color:#e3c58a;margin:12px 0;text-shadow:0 1px 0 #fff4b122,0 -1px 1px #250e17}.cover .date{font:11px/1.5 Arial;letter-spacing:2.5px;color:#c3a66e}.passport-cover-foot{font:9px/1.8 Arial;letter-spacing:2px;color:#b79560;margin:22px 0 0}.cover button{background:transparent;border:1px solid #c39e5c88;color:#d3b875;font-size:11px;min-height:44px;padding:11px 20px;box-shadow:inset 0 1px 0 #fff2;margin-top:21px}.cover .line{display:none}.passport-chip{width:27px;height:18px;display:block;margin:14px auto 0;fill:none;stroke:currentColor;stroke-width:1.2}.page{background-image:repeating-radial-gradient(ellipse at 45% 50%,transparent 0 8px,#ad987312 9px 9.5px,transparent 10px 13px),linear-gradient(90deg,#f6eedf,#fff8eb 90%,#e9ddc7)}.page+.page{background-image:repeating-radial-gradient(ellipse at 55% 50%,transparent 0 8px,#ad987312 9px 9.5px,transparent 10px 13px),linear-gradient(90deg,#e9ddc7,#fff8eb 9%,#f6eedf)}.passport-number{font:9px/1.5 Arial;letter-spacing:2px;align-self:flex-end;opacity:.7;margin-bottom:15px}.passport-fields{width:100%;text-align:left;margin:18px 0 8px;border-top:1px solid #bfa68488;border-bottom:1px solid #bfa68488;padding:10px 0;display:grid;grid-template-columns:1fr 1fr;gap:10px}.passport-fields small{display:block;font:8px/1.7 Arial;letter-spacing:1px;color:#97866d}.passport-fields b{display:block;font:14px/1.5 Georgia;font-weight:400}.passport-mrz{max-width:100%;font:10px/1.7 monospace;letter-spacing:1px;white-space:nowrap;overflow:hidden;text-align:left;margin:14px 0 0;opacity:.7}.page .photo{height:225px;border:5px solid #fff9ec}.page h2{font-size:20px;letter-spacing:1.5px}.page .names{font-size:33px;margin:16px 0 8px}.page .date{font-size:22px}@media(max-width:600px){.stage,.stage:has(.book.open){max-width:390px}.cover{padding:30px 25px}.cover h1{font-size:23px}.cover .subtitle{font-size:10px}.passport-crest{width:175px;height:175px;margin:14px 0 20px}.passport-crest>img{width:135px;height:135px}.crest-leaves{width:205px;height:205px}.cover .names{font-size:32px}.page{padding:27px 23px}.passport-mrz{font-size:9px;letter-spacing:.4px}}@media(prefers-reduced-motion:reduce){.stage{transition:none}}

/* Closed cover height is independent of its inner pages. */
.stage{max-width:350px}.book:not(.open){height:min(520px,calc(100svh - 130px));min-height:390px}.book:not(.open) .pages{display:none}.cover{min-height:0!important;padding:24px}.cover h1{font-size:23px}.passport-crest{width:145px;height:145px;margin:14px 0}.passport-crest>img{width:112px;height:112px}.crest-leaves{width:175px;height:175px}.cover .names{font-size:29px;margin:10px 0}.cover .subtitle{margin:7px 0 10px}.passport-cover-foot{margin-top:14px}.cover button{margin-top:14px}.stage:has(.book.open){max-width:800px}@media(max-width:600px){.stage{max-width:330px}.stage:has(.book.open){max-width:390px}.cover .names{font-size:28px}.cover h1{font-size:22px}.passport-crest{width:140px;height:140px}.passport-crest>img{width:108px;height:108px}.crest-leaves{width:170px;height:170px}}@media(max-height:650px){.cover{padding:20px}.passport-crest{width:115px;height:115px;margin:10px 0}.passport-crest>img{width:90px;height:90px}.crest-leaves{width:145px;height:145px}.passport-cover-foot{margin-top:10px}.passport-chip{margin-top:8px}.cover button{margin-top:10px}.cover .names{font-size:26px}}
