/* Preserve the accepted map illustrations. New framing and ink feedback stay inside the map. */
body.atlas161-live .atlas161-stage{background:#171e19!important;border:1px solid #695d42;box-shadow:inset 0 0 35px #05090780;padding:12px!important;gap:10px}
.atlas161-stage::before{display:none}
.atlas161-stage #route-guide:not(:has(button)){display:none!important}
.atlas161-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;flex:none;text-align:left;padding:0 3px 10px;margin:0;border-bottom:1px solid #9b875a55;color:#e2d8bd}
.atlas161-actions{display:flex;gap:7px;flex:none}.atlas161-actions button{margin:0!important;padding:7px 12px!important;min-height:34px;min-width:0;font-size:12px;white-space:nowrap;background:#303629;border:1px solid #7c7050;color:#ddceb0}.atlas161-actions button[hidden]{display:none!important}.atlas161-frame::before{display:none!important}
.atlas161-heading>div:first-child{display:flex;align-items:baseline;gap:15px}.atlas161-heading small{font-size:10px;letter-spacing:.12em;color:#a79b7c}.atlas161-heading h2{font:400 22px/1.3 Georgia,'STSong',serif;letter-spacing:.1em;margin:0;color:#e0d2ac}
.atlas161-key{display:flex;align-items:center;gap:15px;font-size:11px;color:#c1b392;white-space:nowrap}.atlas161-key-next::before{content:'◆';font-size:9px;color:#c9a96a;margin-right:5px}.atlas161-key-done::before{content:'✓';color:#aeb998;margin-right:5px}
body.atlas161-live .atlas161-frame{gap:12px!important;grid-template-columns:minmax(0,1fr) 232px!important}
body.atlas161-live .route130-regions>span{background:none;border-bottom:1px solid #9f8c585c;padding:4px 8px;font-size:12px;letter-spacing:.08em;color:#cdbf9e}.atlas161-frame .route130-regions small{color:#8e846b}
body.atlas161-live #board#board#board.map107{box-shadow:0 4px 15px #0008!important;border-radius:3px 8px 5px 3px!important}
.atlas161-frame .map107-lines path{stroke:#503b28;stroke-width:1.7;opacity:.58}.atlas161-frame .map107-lines path.map107-next{stroke:#91612e;stroke-width:3;opacity:1;stroke-dasharray:5 3;filter:drop-shadow(0 1px 0 #f5d7a288)}
.atlas161-node-base{position:absolute;width:36px;height:31px;left:50%;top:50%;transform:translate(-50%,-50%) rotate(-5deg);background:#ddbd7966;clip-path:polygon(7% 5%,89% 0,100% 83%,12% 100%,0 30%);pointer-events:none;opacity:0}
.atlas161-frame .map107-cell:has(.route-step-button:not([hidden]))>.atlas161-node-base{opacity:1;box-shadow:inset 0 0 0 1px #694820}.atlas161-frame .atlas161-current>.atlas161-node-base{opacity:1;background:#eee0a673}.atlas161-frame .atlas161-selected:not(.map107-unknown)>.atlas161-node-base{opacity:1;background:#ecd39c77}
.atlas161-frame .map107-unknown .map107-art{opacity:.63}.atlas161-frame .map107-complete .map107-art{opacity:.74}.atlas161-frame .map107-art{filter:none!important}.atlas161-frame .map107-cell:has(.route-step-button) .map107-art{color:#4d351c!important}
body.atlas161-live #board#board.map107 .piece.map109-self{box-shadow:0 2px 5px #0009,0 0 0 2px #6e4c23!important}.atlas161-frame .piece-moving{animation:none!important}.atlas161-frame .map107-check{font-size:20px;color:#485137}
body.atlas161-live #board#board.map107 button:focus-visible{outline:2px dashed #614420!important;outline-offset:3px!important}
.atlas161-frame .map107-notes{padding:12px;border:1px solid #7f715044;background:linear-gradient(145deg,#292f23,#1c251e);box-shadow:inset 2px 0 #a28d5444;color:#ddd1b6}
.atlas161-frame .route130-destination{padding:10px;background:#121b1555;border:1px solid #8a7c4c55}.atlas161-frame .route130-copy strong{font-size:15px;font-weight:500}.atlas161-frame .route130-controls{gap:7px}.atlas161-frame .route130-controls button{font-size:13px;min-height:38px}.atlas161-frame .route130-controls small{font-size:11px;line-height:1.6;color:#b9b093}
.atlas161-frame .workspace135-route{margin-bottom:14px}.atlas161-frame .map107-notes>p{font-size:11px!important;color:#afa58a!important}.atlas161-inspection{position:relative;text-align:left;padding:13px 0 0;border-top:1px solid #8c7d5155;min-height:140px}.atlas161-note-status{display:inline-block;font:11px/1.5 'Microsoft YaHei',sans-serif;letter-spacing:.12em;color:#bea773;padding-bottom:12px}.atlas161-note-art{position:absolute;right:2px;top:13px;opacity:.8}.atlas161-note-art .map107-art{width:30px;height:30px;color:#bba978;filter:none}.atlas161-note-art .map107-art svg{width:29px;height:29px}.atlas161-inspection h3{font-size:11px;color:#a69b7f;margin:0 0 3px;font-weight:400;letter-spacing:.15em}.atlas161-inspection>strong{display:block;font:400 21px/1.5 Georgia,'STSong',serif;color:#e5d6b3}.atlas161-inspection>p{font-size:13px;line-height:1.9;color:#c8c0a8;margin:10px 0 0}
.atlas161-trail{position:absolute;inset:0;width:100%;height:100%;z-index:3;pointer-events:none}.atlas161-trail path{stroke:#735024;fill:none;stroke-width:2.6;vector-effect:non-scaling-stroke;stroke-dasharray:1}
#atlas161-passage{position:fixed;z-index:180;pointer-events:none;overflow:hidden;border-radius:4px;contain:layout paint}#atlas161-passage:empty{display:none}.atlas161-echo{position:absolute;inset:0;isolation:isolate}.atlas161-echo-node{position:absolute;display:grid;place-items:center;transform:translate(-50%,-50%);pointer-events:none}.atlas161-echo .map107-art{filter:none}.atlas161-echo .map107-lines{z-index:0}
body.atlas161-live .atlas161-frame{position:relative;overflow:clip!important;background:linear-gradient(#111c1740,#111c1759),url('/assets/optimized/wasteland-map-backdrop.jpg') center/cover!important}
body.atlas161-live .atlas161-frame:has(#board.map108){background:linear-gradient(#111c1730,#111c1759),url('/assets/optimized/underground-108/events/battle-v1.webp') center/cover!important}
.atlas161-frame .route130-regions{background:#172019dc}.atlas161-frame .map107-notes{background:linear-gradient(145deg,#292f23f5,#1c251ef5)}
.atlas161-hands{position:absolute;pointer-events:none;z-index:7;overflow:visible}
.atlas161-hand{position:absolute;top:60%;width:var(--atlas161-hand-width,110px);height:auto;max-width:none;filter:drop-shadow(2px 5px 3px #0009);pointer-events:none}
.atlas161-hand.is-left{left:0;transform:translateX(-78%) rotate(-4deg);transform-origin:88% 10%}.atlas161-hand.is-right{right:0;transform:translateX(78%) rotate(4deg);transform-origin:12% 10%}
.atlas161-arrival-mark{position:absolute;width:44px;height:44px;border:2px solid #4e341c;border-radius:44% 51% 46% 49%;translate:-50% -50%;box-shadow:0 0 0 4px #bd9a5055;z-index:8;pointer-events:none}
@media(max-width:1099px),(max-height:649px){.atlas161-frame:has(.route130-regions)>.map107-notes{grid-column:1;grid-row:3}}
/* Two paper leaves share one central crease. The hands follow the outer paper edges. */
.atlas161-fold{position:absolute;perspective:1800px;perspective-origin:50% 60%;isolation:isolate;z-index:2}
.atlas161-journey{position:absolute;background-size:cover;background-position:center;transform-origin:50% 58%;overflow:hidden;box-shadow:inset 0 0 90px #07100abb}
.atlas161-journey::after{content:'';position:absolute;inset:0;background:radial-gradient(ellipse at 50% 45%,transparent 25%,#0d151777 100%);pointer-events:none}
.atlas161-arrival{position:absolute;z-index:1;overflow:hidden;background:#152019;pointer-events:none}
.atlas161-arrival img{display:block;width:100%;height:100%;object-fit:cover;object-position:center;transform-origin:50% 58%}
.atlas161-fold-leaf{position:absolute;top:0;width:50%;height:100%;transform-style:preserve-3d;backface-visibility:hidden}
.atlas161-fold-leaf.is-left{left:0;transform-origin:100% 50%}.atlas161-fold-leaf.is-right{left:50%;transform-origin:0 50%}
.atlas161-fold-face{position:absolute;inset:0;overflow:hidden;box-shadow:0 6px 10px #0007;backface-visibility:hidden}
.atlas161-fold-shade{position:absolute;inset:0;background:linear-gradient(90deg,#21150815,#211508b0);opacity:0;pointer-events:none}
.atlas161-fold-leaf.is-right .atlas161-fold-shade{background:linear-gradient(90deg,#211508b0,#21150815)}
.atlas161-fold-crease{position:absolute;left:50%;top:0;width:2px;height:100%;background:#59402280;box-shadow:1px 0 #f7df9c55;pointer-events:none}
.atlas161-fold .atlas161-hands{inset:0!important;width:100%!important;height:100%!important}
.atlas161-frame.atlas161-unfolding>#board,.atlas161-frame.atlas161-unfolding>.atlas161-hands{visibility:hidden!important}
@media(max-width:650px){
 body.atlas161-live #board#board#board.map107{width:calc(100% - 48px)!important;justify-self:center}
 .atlas161-frame>.route130-destination{background:#1c251ef2}
}
.atlas161-echo-pin{position:absolute;width:40px;height:40px;z-index:4;border:2px solid #7db7b1;border-radius:50%;background:#192c2b;box-shadow:0 2px 5px #0009,0 0 0 2px #342b20}.atlas161-echo-pin.is-self{border-color:#ffe19b;background:#46371d}.atlas161-echo-pin .map109-tag{position:absolute;top:35px;left:50%;transform:translateX(-50%);padding:1px 5px;white-space:nowrap;background:#233b39;color:#e8f5e9;border:1px solid #80b3aa;font:700 11px/15px 'Microsoft YaHei',sans-serif}.atlas161-echo-pin.is-self .map109-tag{background:#594324;border-color:#e8c980;color:#fff2c4}
body.atlas161-live #event-scene:not(.combat-scene).scene-entering{animation:atlas161-scene-settle .4s ease-out both}body.atlas161-live #event-scene:not(.combat-scene).scene-entering::after{display:none!important}@keyframes atlas161-scene-settle{from{opacity:.65}to{opacity:1}}
body.atlas161-live.atlas161-static #event-scene:not(.combat-scene).scene-entering{animation:none!important}
@media(max-width:1099px),(max-height:649px){body.atlas161-live .atlas161-frame{grid-template-columns:minmax(0,1fr)!important}.atlas161-heading{padding-bottom:9px}.atlas161-heading>div:first-child{display:block}.atlas161-heading h2{font-size:21px;margin-top:3px}.atlas161-key{gap:8px;flex-wrap:wrap;justify-content:flex-end;max-width:155px}.atlas161-key small{flex-basis:100%;text-align:right;font-size:10px}.atlas161-frame .map107-notes{max-height:none!important;overflow:visible;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px}.atlas161-frame .atlas161-inspection{grid-column:2;grid-row:1/4;padding-top:7px;border-top:0;border-left:1px solid #8c7d5144;padding-left:12px;min-width:0}.atlas161-frame .atlas161-inspection>strong{font-size:19px}.atlas161-frame .route130-destination{grid-column:1/-1}.atlas161-frame .map109-roster{grid-column:1;margin:0}.atlas161-frame .map107-notes>.route130-locate{grid-column:1}.atlas161-frame .map107-notes>p{grid-column:1}.atlas161-frame .atlas161-note-art{display:none}}
@media(max-width:520px){body.atlas161-live .atlas161-stage{padding:8px!important}.atlas161-heading{flex-wrap:wrap;gap:8px}.atlas161-heading>div:first-child>small{font-size:9px;letter-spacing:.05em}.atlas161-heading h2{font-size:19px;letter-spacing:.05em}.atlas161-key{gap:6px;font-size:10px;max-width:140px}.atlas161-actions{width:100%;justify-content:flex-end}.atlas161-actions button{min-height:40px}.atlas161-frame .map107-notes{padding:10px;gap:10px}.atlas161-inspection>p{font-size:12px}.atlas161-frame .route130-regions>span{padding:4px 2px;font-size:10px;letter-spacing:0}.atlas161-frame .route130-regions small{margin-right:4px;font-size:9px}}
@media(prefers-reduced-motion:reduce){#atlas161-passage{display:none!important}.atlas161-trail{display:none!important}body.atlas161-live #event-scene:not(.combat-scene).scene-entering{animation:none!important}}
/* Explicit slots keep late travel notices and route captions out of the map's track. */
body.atlas161-live .atlas161-frame.atlas161-frame{grid-template-rows:minmax(0,1fr) auto!important}
body.atlas161-live .atlas161-frame>#board.map107{grid-column:1!important;grid-row:1!important;min-width:0}
body.atlas161-live .atlas161-frame>.map107-notes{grid-column:2!important;grid-row:1!important;min-height:0}
body.atlas161-live .atlas161-frame>.route130-regions{grid-column:1!important;grid-row:1!important;align-self:start;min-height:0}
body.atlas161-live .atlas161-frame>.route130-destination{grid-column:1/-1!important;grid-row:2!important;align-self:start}
body.atlas161-live .atlas161-frame:has(>.route130-regions){grid-template-rows:auto minmax(0,1fr) auto!important}
body.atlas161-live .atlas161-frame:has(>.route130-regions)>#board.map107{grid-row:2!important}
body.atlas161-live .atlas161-frame:has(>.route130-regions)>.map107-notes{grid-row:1/3!important}
body.atlas161-live .atlas161-frame:has(>.route130-regions)>.route130-destination{grid-row:3!important}
.atlas161-frame #exhausted-search-145{margin:0 0 12px;padding:10px;border:1px solid #9b82504d;background:#4f47262e;min-width:0;grid-column:1/-1}
.atlas161-frame #exhausted-search-145 p{margin:0;font-size:13px;line-height:1.65}
.atlas161-frame #exhausted-search-145 button{width:100%;min-height:44px;margin-top:9px;white-space:normal}
@media(max-width:1099px),(max-height:649px){
 body.atlas161-live .atlas161-frame.atlas161-frame{grid-template-rows:auto auto auto!important}
 body.atlas161-live .atlas161-frame>.map107-notes{grid-column:1!important;grid-row:2!important}
 body.atlas161-live .atlas161-frame>.route130-destination{grid-row:3!important}
 body.atlas161-live .atlas161-frame:has(>.route130-regions){grid-template-rows:auto auto auto auto!important}
 body.atlas161-live .atlas161-frame:has(>.route130-regions)>.map107-notes{grid-column:1!important;grid-row:3!important}
 body.atlas161-live .atlas161-frame:has(>.route130-regions)>.route130-destination{grid-row:4!important}
 .atlas161-frame .map107-notes:has(#exhausted-search-145) .atlas161-inspection{grid-row:2/5}
}
