/* Corrections are scoped to chapter four. Keep earlier chapter geometry unchanged. */
#stage.x4Live #q4Deduction[data-x4-type=chest] .m4Content{left:17%!important;right:2%!important;top:14%!important;bottom:6%!important}
#stage.x4Live .m4ChestObject{left:-4%;width:47%;height:83%;bottom:5%;animation:none}
#stage.x4Live .m4ExtractedPapers{left:43%;right:0;top:0;bottom:5%;gap:14% 10%;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr}
#stage.x4Live .m4ExtractedPapers button,#stage.x4Live .m4ExtractedPapers button:hover,#stage.x4Live .m4ExtractedPapers button:focus,#stage.x4Live .m4ExtractedPapers button:active{background:transparent!important;border:0!important;box-shadow:none!important;outline:none;min-height:0;overflow:visible;transition:filter .2s}
#stage.x4Live .m4ExtractedPapers button:hover{filter:drop-shadow(0 4px 7px #efd69f55) brightness(1.06)}
#stage.x4Live .m4ExtractedPapers button:focus-visible{outline:1px solid #c1a56d;outline-offset:4px}
#stage.x4Live .m4ExtractedPapers span{left:4%;right:4%;bottom:-8%;background:transparent!important;border-bottom:1px solid #b9a16b77;padding:2px;font-size:clamp(13px,1.25vw,20px);text-shadow:0 2px 4px #14291f}
#stage.x4Live .m4OpenNotice{left:0;right:58%;bottom:0;font-size:clamp(12px,1.1vw,18px)}
#stage.x4Live #q4Deduction[data-x4-type=document] .m4Content{left:18%!important;right:2%!important;top:14%!important;bottom:3%!important}
#stage.x4Live #q4Deduction[data-x4-type=document].has-action .m4Content{bottom:25%!important}
#stage.x4Live .x4Document{grid-template-columns:70% 27%;gap:3%;padding-bottom:3%}
#stage.x4Live .x4Document .x4Original{height:100%!important;min-height:0;display:flex;align-items:center;justify-content:center}
#stage.x4Live .x4Document .x4Original img{width:100%!important;height:100%!important;object-fit:contain!important}
#stage.x4Live .x4Document aside{font-size:clamp(12px,1.15vw,19px);line-height:1.7}
#stage.x4Live .x4Document aside h3{font-size:clamp(20px,1.85vw,30px)}
#stage.x4Live #q4Deduction.x4Board .q4Action.y4ClassicAction{left:20%!important;right:2%!important;bottom:1%!important;min-height:0!important;height:22%!important;max-height:none!important;padding:6px 0 0!important;background:transparent!important;border:0!important;border-top:1px solid #baaa7955!important;box-sizing:border-box;z-index:30}
#stage.x4Live .y4ClassicAction .q4ActionHeader{margin:0 0 5px;min-height:0;align-items:center;gap:10px}
#stage.x4Live .y4ClassicAction .q4ActionHeader b{max-width:58%;white-space:normal;font:500 clamp(13px,1.2vw,20px)/1.4 QFSystem!important;color:#ebdcba}
#stage.x4Live .y4ClassicAction .q4ActionHeader span{font:400 clamp(10px,.95vw,15px)/1.5 QFSystem!important;max-width:42%;color:#d5d3b7}
#stage.x4Live .y4ClassicAction .q4Options{gap:10px;min-height:0}
#stage.x4Live .y4ClassicAction .q4Options button{background:#e1d1ad url('assets/chapter4/paper-3.jpg') center/cover!important;border:1px solid #aca780!important;border-radius:1px 3px 2px 1px!important;box-shadow:0 3px 5px #10281c75!important;min-height:42px;padding:.4em .7em!important;font:500 clamp(14px,1.25vw,21px)/1.4 QFSystem!important;color:#284633!important}
#stage.x4Live .y4ClassicAction .q4Options button:hover:not(:disabled){background-color:#eee3c6!important;filter:brightness(1.06);translate:0 -1px}
#stage.x4Live .y4ClassicAction .q4Options button.chosen{background:#d7cfb4!important;box-shadow:inset 0 -2px #b19b68!important}
#stage.x4Live .y4ClassicAction .q4Options i{color:#80704b;font-size:10px}
#stage.x4Live .y4ObjectTask{height:10%!important}.y4InspectObject{position:absolute;left:18%;bottom:3%;padding:8px 14px!important;background:#e6d8b7eF!important;border:1px solid #a58a5b!important;color:#3c4c36;font:500 clamp(12px,1.1vw,18px) QFSystem;z-index:8;box-shadow:0 3px 6px #152d2455;cursor:pointer}
#stage.x4Live .y4ObjectTask .q4ActionHeader b{max-width:60%}
.y4Present{height:100%;width:100%;position:relative}.y4PresentDesk{position:absolute;left:0;bottom:14%;width:45%;height:74%}.y4PresentDesk img{width:100%;height:100%;object-fit:contain}.y4PresentPapers{position:absolute;left:40%;right:0;top:0;bottom:15%;display:flex;gap:5%;align-items:center}.y4PresentPapers>div{height:93%;width:31%;rotate:calc((var(--i) - 1)*3deg);animation:x4EvidenceIn .7s calc(var(--i)*.17s) both}
#stage.x4Live .m4PaperPixels{overflow:visible!important}.x4ThreeEvidence{padding-bottom:12%;gap:6%}.x4ThreeEvidence .m4Paper{height:88%!important}.x4ThreeEvidence section>b{font-size:clamp(14px,1.3vw,22px)}
#stage.x4Live .m4Route{overflow:hidden;border:0;background:#21372d}.m4Route .m4RouteArt{filter:none;animation:none}.m4Route .m4RouteLines{inset:0 0 12%;height:88%}.m4Route .m4RouteTimeline{height:10%;min-height:0;padding:3px 8px;box-sizing:border-box;font-size:clamp(11px,1.1vw,18px)}.m4Route .m4RouteCaption{font-size:clamp(11px,1vw,16px);left:4%;bottom:10%}.m4Route .m4CourierBox{width:11%;height:20%;filter:drop-shadow(0 3px 4px #172d23aa);animation-duration:5s}.m4Route .m4Unknown{font-size:clamp(15px,1.5vw,23px)}
.x4SealArt{background-image:url('assets/chapter4/review-20261130/seal-desk-clear.webp')}
.x4SealSample>img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;pointer-events:none;filter:drop-shadow(1px 3px 2px #1a2c2277)}
.x4Seal[data-held-sample="0"].x4Carrying [data-x4-sample="0"]>img,.x4Seal[data-held-sample="1"].x4Carrying [data-x4-sample="1"]>img,.x4Seal[data-held-sample="2"].x4Carrying [data-x4-sample="2"]>img{visibility:hidden}
.x4SealCarry{padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important;min-width:0;width:12%;height:13%;rotate:0deg;filter:drop-shadow(4px 7px 4px #142d2377)}.x4SealCarry>img{width:100%;height:100%;object-fit:contain}
.y4Grain .x4Stock{width:40%;left:4%;top:12%}.y4Grain .x4GrainNote{right:2%;width:35%;padding:12px;top:10%;font-size:clamp(14px,1.45vw,23px);gap:10px}.y4Grain .x4GrainBg{filter:brightness(.7)}.y4Grain .x4Equation{z-index:5}.y4ClaimCross{position:absolute;right:0;top:0;width:48px;height:48px;pointer-events:none}.y4ClaimCross path{fill:none;stroke:#ce6747;stroke-width:6;stroke-linecap:round;stroke-dasharray:1;animation:x4Cross .6s ease both}.x4GrainNote em{font:500 clamp(11px,1.1vw,17px) QFSystem;color:#e5b38a}.x4GrainNote.challenged b{padding-right:20px}
.x4CourtDoor{background-image:url('assets/chapter4/review-20261130/court-screen.webp')!important;background-size:200% 100%!important;background-repeat:no-repeat!important;border:0!important;box-shadow:0 0 12px #172d24aa}.x4CourtDoor.left{background-position:left center!important}.x4CourtDoor.right{background-position:right center!important}
#stage.x4Live #q4Deduction[data-x4-type=grain],#stage.x4Live #q4Deduction[data-x4-type=route],#stage.x4Live #q4Deduction[data-x4-type=dispatch],#stage.x4Live #q4Deduction[data-x4-type=courtOpening]{background:#172f26f5!important}
#stage.x4Live #q4Deduction[data-x4-type=grain] .m4Content{left:20%!important;right:2%!important}
#stage.x4Live .m4RouteArt{object-fit:cover!important;width:100%!important;height:100%!important}
#stage.x4Live .m4RouteCamera{bottom:11%}.m4Route .m4RouteLines{inset:0;height:100%}
#stage.x4Live .m4Place{z-index:8}.m4Route .m4Unknown{top:12%;left:39%;padding:4px 8px;background:#233f31dd;border:1px solid #c1aa72}
#stage.x4Live .x4ArchiveShelves{display:none}#stage.x4Live .x4Archive{background:linear-gradient(120deg,#18372cc9,#233b30e8)}
#stage.x4Live .m4PaperPixels{opacity:1!important}#stage.x4Live .m4PaperPixels img{opacity:1!important}
.y4Timeline,.y4EvidenceChain,.y4Compare{position:relative;height:100%;width:100%;box-sizing:border-box;padding-bottom:12%}.y4TimelineObject{height:63%;display:flex;justify-content:center}.y4TimelineObject button{height:100%;width:42%;background:transparent!important;border:0!important;display:flex;flex-direction:column;align-items:center;cursor:grab;touch-action:none;color:#efe3c3;font:500 clamp(15px,1.5vw,23px) QFSystem;position:relative}.y4TimelineObject img{height:83%;width:100%;pointer-events:none}.y4TimelineRail{display:flex;gap:12%;justify-content:center;height:24%;border-top:1px solid #ac9665;padding-top:10px}.y4TimelineRail button{width:38%;background:#d8c8a4!important;border:1px solid #9e855b!important;color:#2a4938;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:4px;font:500 clamp(17px,1.6vw,25px) QFSystem}.y4TimelineRail button span{font-size:.6em}.y4Timeline p{text-align:center;font:400 clamp(11px,1vw,16px) QFSystem;color:#d4c59c}
.y4ChainPapers{display:flex;justify-content:space-between;gap:6%;height:70%}.y4ChainPapers button{width:30%;height:95%;border:0!important;background:transparent!important;padding:0!important;touch-action:none;cursor:grab;position:relative;color:#eadcbb;font:500 clamp(12px,1.2vw,19px) QFSystem;display:flex;flex-direction:column;align-items:center;gap:5px}.y4ChainPapers .m4Paper{height:90%!important}.y4ChainPapers .placed{opacity:.45}.y4ChainDestination{margin-top:2%;height:28%;border:1px dashed #c4ac73;background:#1d392dcf;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;color:#edddba;font:500 clamp(15px,1.4vw,23px) QFSystem}.y4ChainDestination>span{font-size:.65em;color:#c4c5a5}.y4ChainDestination>div{display:flex;gap:12px;font-size:.7em}.y4ChainPapers .selected{filter:drop-shadow(0 0 5px #e5c37e)}
.y4ComparePapers{height:80%;display:flex;gap:8%;justify-content:center}.y4ComparePapers>figure{width:44%;height:100%;margin:0;display:flex;flex-direction:column;align-items:center;gap:7px}.y4ComparePapers .m4Paper{height:90%!important}.y4ComparePapers figcaption{font:500 clamp(14px,1.4vw,22px) QFSystem;color:#ead7ac}.y4CompareReveal{position:absolute;top:20%;left:33%;width:34%;padding:8px;background:#e0d3b2f2;color:#2b4937;display:flex;justify-content:center;gap:10px;opacity:var(--compare,0);transform:translateY(calc((1 - var(--compare,0))*12px));font:500 clamp(18px,1.8vw,29px) QFSystem}.y4CompareReveal i{font-style:normal;color:#a5523b}.y4Compare label{position:absolute;bottom:2%;left:4%;right:4%;display:flex;align-items:center;justify-content:center;gap:15px;font:500 clamp(12px,1.2vw,18px) QFSystem;color:#dfcfaa}.y4Compare input{width:55%;accent-color:#a98b56;cursor:ew-resize;touch-action:none}
#stage.x4Live .m4Route .m4CourierBox{width:9%;height:17%}
#stage.x4Live #q4Deduction:has(.y4Timeline) .m4Content,#stage.x4Live #q4Deduction:has(.y4EvidenceChain) .m4Content,#stage.x4Live #q4Deduction:has(.y4Compare) .m4Content{bottom:15%!important}
#stage.x4Live #q4Deduction:has(.y4Timeline) .q4Action,#stage.x4Live #q4Deduction:has(.y4EvidenceChain) .q4Action,#stage.x4Live #q4Deduction:has(.y4Compare) .q4Action{height:11%!important}
.y4Timeline,.y4EvidenceChain,.y4Compare{position:absolute;inset:0;padding:0!important;height:auto!important;width:auto!important}
.y4TimelineObject{position:absolute;top:0;left:0;right:0;bottom:36%;height:auto}.y4TimelineObject button{width:39%;height:100%;padding:0!important;box-sizing:border-box}.y4TimelineObject button img{height:85%!important;max-height:85%!important;width:100%!important;max-width:100%!important;object-fit:contain!important}.y4TimelineObject button>span{font-size:clamp(14px,1.3vw,21px)}
.y4TimelineRail{position:absolute;left:0;right:0;bottom:8%;height:22%;padding-top:8px}.y4Timeline p{position:absolute;left:0;right:0;bottom:-2%;margin:0}
.y4ChainPapers{position:absolute;left:0;right:0;top:0;bottom:31%;height:auto;min-height:0}.y4ChainPapers button{height:100%;min-height:0;flex:1;min-width:0}.y4ChainPapers button .m4Paper{flex:1;min-height:0;height:auto!important;pointer-events:none}.y4ChainPapers button>span{flex:none}
.y4ChainDestination{position:absolute;left:0;right:0;bottom:0;height:25%;box-sizing:border-box;margin:0;padding:5px}
.y4ComparePapers{position:absolute;top:0;left:0;right:0;bottom:20%;height:auto;min-height:0}.y4ComparePapers>figure{min-height:0}.y4ComparePapers .m4Paper{flex:1;min-height:0;height:auto!important}.y4ComparePapers figcaption{flex:none}.y4Compare label{bottom:1%;height:12%;min-height:25px}.y4CompareReveal{top:34%}
@media(max-width:900px){#stage.x4Live .y4ClassicAction .q4ActionHeader span{display:none}#stage.x4Live .y4ClassicAction .q4ActionHeader b{max-width:100%;font-size:12px!important}#stage.x4Live .y4ClassicAction .q4Options button{font-size:11px!important;min-height:30px!important;padding:4px!important}.x4SealCarry{width:13%;height:14%}.x4ThreeEvidence section>b{font-size:12px}}
