@font-face{font-family:PoetTypewriter;src:url('../assets/fonts/poet-typewriter.otf') format('opentype');font-weight:400;font-style:normal;font-display:swap}
/* Approved literary desk: the same reusable art frames every poem. */
body.poet-active{background:#171310}
.poet-desk{color:#181310;min-height:100dvh;--poet-serif:Georgia,'Times New Roman',serif;--poet-mono:PoetTypewriter,'Courier New',Courier,monospace}
.poet-scene{position:relative;width:100%;aspect-ratio:1672/941;max-width:2000px;margin:auto;background:url('../assets/ui/poet-desk/backdrop.webp') center/100% 100% no-repeat;isolation:isolate}
.poet-topbar{position:absolute;inset:0 0 auto;height:8.2%;display:grid;grid-template-columns:24% 48% 28%;align-items:center;padding:0 2.8%;font-family:var(--poet-serif)}
.poet-topbar h1{text-align:center;white-space:nowrap;font:700 clamp(30px,3.65vw,68px)/1 var(--poet-serif);margin:0;letter-spacing:-.035em}
.poet-topbar h1 span{color:#8d1213}
.poet-topbar .back{font:400 clamp(16px,1.65vw,28px)/1.1 var(--poet-serif);color:#171310;gap:12px}
.poet-topbar .back .icon{width:24px;height:24px}
.poet-progress{justify-self:end;display:flex;align-items:center;gap:16px}
.poet-progress p{font-size:clamp(14px,1.36vw,24px);white-space:nowrap;margin:0}
.poet-progress ol{list-style:none;display:flex;gap:clamp(5px,.65vw,11px);padding:0;margin:0}
.poet-progress li{height:clamp(7px,.98vw,17px);width:clamp(7px,.98vw,17px);background:#b4afa7;border:2px solid transparent;border-radius:50%}
.poet-progress li.done{background:#8d1213}.poet-progress li.current{background:transparent;border-color:#8d1213}
.poet-sheet{position:absolute;left:25.7%;top:17.7%;width:47.2%;height:45.9%;display:flex;flex-direction:column;align-items:center;font-family:var(--poet-serif)}
.poet-sheet h2{width:100%;margin:0;font:400 clamp(18px,2.02vw,36px)/1.2 var(--poet-serif);text-align:center;display:flex;align-items:center;justify-content:center;gap:18px;white-space:nowrap}
.poet-sheet h2:before,.poet-sheet h2:after{content:'';width:18%;height:1px;background:#9b2020}
.poet-verse-area{width:100%;min-height:0;flex:1;display:flex;align-items:center;justify-content:center;padding:18px 0 12px}
.poet-verse{width:88%;position:relative;margin:0;font:400 clamp(18px,2.03vw,35px)/1.62 var(--poet-mono);white-space:pre-line;text-align:left;letter-spacing:-.035em;text-shadow:.3px 0 currentColor,-.3px 0 currentColor}
.poet-reserve{display:block;opacity:0;white-space:pre;pointer-events:none}
.poet-typed{position:absolute;inset:0;white-space:pre;display:block}
.poet-verse.is-typing .poet-typed:after{content:'';display:inline-block;height:1em;width:1px;vertical-align:-.12em;background:#2f2620;animation:poet-cursor .55s step-end infinite}
.poet-choices{width:80%;max-width:none;gap:6%;margin:0;flex:none}
.poet-choices .choice{position:relative;border:0;border-radius:0;--poet-key:url('../assets/ui/poet-desk/key-dark.webp');background:transparent var(--poet-key) center/100% 100% no-repeat;aspect-ratio:2.8;min-width:0;min-height:0;padding:12px 20px;color:#f5e8d0;font:700 clamp(22px,2.55vw,46px)/1 var(--poet-serif);box-shadow:none;transition:filter 140ms ease,transform 80ms ease}
.poet-choices .choice:nth-child(2){--poet-key:url('../assets/ui/poet-desk/key-light.webp');background-image:var(--poet-key);color:#181310}
.poet-choices .choice:is(:hover,:active,.selected,.correct,.wrong){background:transparent var(--poet-key) center/100% 100% no-repeat}
.poet-choices .choice:not(:disabled):hover{transform:none;filter:brightness(1.04);box-shadow:none}
.poet-choices .choice:active:not(:disabled){transform:translateY(1px);filter:brightness(.98)}
.poet-choices .choice.correct{outline:3px solid #2d7847;outline-offset:-8px;border-radius:28px;background-color:transparent}
.poet-choices .choice.wrong{outline:3px solid #a82925;outline-offset:-8px;border-radius:28px;background-color:transparent}
.poet-choices .choice .icon{width:clamp(18px,1.6vw,26px);height:clamp(18px,1.6vw,26px)}
.poet-choices .choice:first-child .icon{filter:invert(1)}
/* The result is another sheet on the same desk, with live text and a fixed key. */
.poet-feedback{--poet-serif:Georgia,'Times New Roman',serif;--poet-mono:PoetTypewriter,'Courier New',monospace;width:min(640px,86vw);max-width:none;max-height:calc(100dvh - 64px);padding:44px 50px 32px;border:0;background:transparent url('../assets/ui/poet-desk/feedback-paper.webp') center/100% 100% no-repeat;color:#181310;font-family:var(--poet-serif);overflow:hidden;filter:drop-shadow(0 12px 24px #0005)}
.poet-feedback[open]{display:flex;flex-direction:column}
.poet-feedback::backdrop{background:#130d0826}
.poet-feedback-close{position:absolute;z-index:1;right:16px;top:13px;display:grid;place-items:center;width:44px;height:44px;padding:10px;border:0;background:transparent;color:#181310;border-radius:0}
.poet-feedback-close .icon{width:27px;height:27px}
.poet-feedback-close:hover{background:#4f29100c}
.poet-feedback-scroll{min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#a98f72 transparent;scroll-padding:10px;padding-right:4px}
.poet-feedback-scroll:focus{outline:none}
.poet-feedback h2{font:700 52px/1.06 var(--poet-serif);letter-spacing:-.025em;color:#850e0f;border-bottom:1px solid #8d2621;padding:0 38px 20px 0;margin:0 0 22px}
.poet-attribution{padding-bottom:22px;margin-bottom:22px;border-bottom:1px solid #8d2621}
.poet-feedback h3{font:700 35px/1.14 var(--poet-serif);letter-spacing:-.018em;margin:0 0 10px}
.poet-attribution p{font:400 21px/1.45 var(--poet-mono);margin:0;overflow-wrap:anywhere}
.poet-explanation{font:400 22px/1.45 var(--poet-serif);margin:0 0 24px}
.poet-sources{display:flex;flex-wrap:wrap;gap:6px 14px;align-items:baseline;font:400 19px/1.4 var(--poet-serif);margin:0 0 8px;overflow-wrap:anywhere}
.poet-sources a{color:#181310;text-decoration:underline;text-underline-offset:5px}
.poet-sources a:hover{color:#850e0f}
.poet-feedback-footer{flex:none;padding-top:16px}
.poet-next{border:0;border-radius:0;background:transparent url('../assets/ui/poet-desk/key-dark.webp') center/contain no-repeat;aspect-ratio:800/263;min-height:0;width:min(100%,400px);margin-inline:auto;padding:0 24px;font:400 25px/1.15 var(--poet-serif,Georgia,serif);color:#f5e8d0;display:flex;align-items:center;justify-content:center;gap:12px;transition:filter 140ms ease,transform 80ms ease}
.poet-next .icon{width:26px;height:26px;filter:invert(1);flex:none}
.poet-next:hover{filter:brightness(1.06)}
.poet-next:active{transform:translateY(1px);filter:brightness(.98)}
.poet-reopen{position:absolute;left:50%;translate:-50% 0;top:74%;width:min(54%,400px);aspect-ratio:800/263;background-size:contain;font-size:clamp(17px,1.8vw,26px);min-height:0;padding:0 26px;z-index:1}
.poet-feedback-close:focus-visible,.poet-next:focus-visible,.poet-sources a:focus-visible{outline:2px solid #8d1213;outline-offset:3px}
@media(prefers-reduced-motion:no-preference){.poet-feedback[open]{animation:poet-paper-enter 220ms ease-out both}.poet-feedback::backdrop{animation:poet-dim-enter 220ms ease-out both}}
@keyframes poet-paper-enter{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:translateY(0)}}
@keyframes poet-dim-enter{from{opacity:0}to{opacity:1}}
@keyframes poet-cursor{50%{opacity:0}}
@media(min-width:2001px){.poet-topbar h1{font-size:68px}.poet-topbar .back{font-size:28px}.poet-sheet h2{font-size:36px}.poet-verse{font-size:35px}.poet-choices .choice{font-size:46px}}
@media(max-width:1200px) and (min-width:701px){.poet-progress{display:block;text-align:center}.poet-progress ol{justify-content:center;margin-top:6px}.poet-sheet{height:47.5%;top:16.3%}.poet-sheet h2{gap:10px}.poet-verse-area{padding-top:10px;padding-bottom:8px}.poet-choices .choice{padding:9px}}
@media(max-width:700px){
 .poet-scene{min-height:730px;aspect-ratio:auto;background-size:auto 100%;background-position:center}
 .poet-topbar{position:relative;height:auto;min-height:120px;grid-template-columns:1fr 1fr;gap:10px;padding:12px 18px;background:#eee6d8 url('../assets/ui/dossier/paper-sheet.webp') center/cover}
 .poet-topbar h1{grid-column:1/-1;grid-row:2;font-size:clamp(28px,9.7vw,38px);margin:1px 0 6px}
 .poet-topbar .back{font-size:16px;gap:6px;min-height:36px}
 .poet-topbar .back .icon{width:20px;height:20px}
 .poet-progress{display:block;text-align:right}.poet-progress p{font-size:14px}.poet-progress ol{justify-content:flex-end;margin-top:6px;gap:5px}.poet-progress li{width:8px;height:8px;border-width:1.5px}
 .poet-sheet{position:relative;top:auto;left:auto;margin:12px 16px 0;width:calc(100% - 32px);height:auto;min-height:410px;background:#ece3d1 url('../assets/ui/dossier/paper-sheet.webp') center/cover;padding:25px 18px 28px;box-shadow:0 10px 20px #0004}
 .poet-sheet h2{font-size:21px;white-space:normal;gap:8px;line-height:1.3}.poet-sheet h2:before,.poet-sheet h2:after{width:18px;flex:none}
 .poet-verse-area{min-height:235px;flex:none;padding:22px 0}
 .poet-verse{width:100%;font-size:20px;line-height:1.7;letter-spacing:-.045em;overflow-wrap:anywhere}
 .poet-reserve,.poet-typed{white-space:pre-line}
 .poet-choices{width:100%;gap:10px}.poet-choices .choice{font-size:27px;min-height:56px;padding:12px;aspect-ratio:2.5}
 .poet-choices .choice .icon{width:18px;height:18px}
 .poet-feedback{width:90%;top:min(14dvh,118px);max-height:calc(100dvh - 40px - min(14dvh,118px));padding:50px 55px 18px}
 .poet-feedback-close{right:10px;top:10px;width:40px;height:40px;padding:10px}.poet-feedback-close .icon{width:23px;height:23px}
 .poet-feedback h2{font-size:35px;padding-bottom:12px;margin-bottom:15px}
 .poet-feedback h3{font-size:26px;margin-bottom:9px}
 .poet-attribution{padding-bottom:16px;margin-bottom:15px}.poet-attribution p{font-size:17px;line-height:1.45}
 .poet-explanation{font-size:16px;line-height:1.4;margin-bottom:20px}
 .poet-sources{font-size:16px;gap:5px 8px;line-height:1.5}
 .poet-feedback-footer{padding-top:8px;margin-left:-28px;margin-right:-28px}
 .poet-next{font-size:19px;gap:7px;padding:0 13px}.poet-next .icon{width:21px;height:21px}
 .poet-reopen{position:relative;left:auto;top:auto;translate:none;width:80%;max-width:400px;min-height:0;padding:0 18px;margin:22px auto 0;font-size:20px}
}
@media(max-width:360px){.poet-feedback{width:94%;padding-left:33px;padding-right:33px}.poet-feedback-footer{margin-left:-18px;margin-right:-18px}.poet-feedback h3{font-size:24px}.poet-next{font-size:17px}}
@media(prefers-reduced-motion:reduce){.poet-verse.is-typing .poet-typed:after{animation:none}}
