/* The MAPA DA REGIAO window EXACTLY as zenux's mockup 08 (Work-ID 20261020-mockup-exact-b1-bda6; "FACA EXATAMENTE COMO NA IMAGEM"): the window is the mockup's 1586 x 992 sheet
   (map/sheet.webp = 08-mapa-da-regiao with its texts, tabs, place panel and chart painted out, Tools/build_mx_sheets.py), so the dragon shield, the castle and moon, the frames, ornaments and the
   bottom pokeball are zenux's own pixels; the tabs, the chart with its labels, the place panel and the fly button are drawn over it at the mockup's coordinates (tabs and button take frames cropped from
   the mockup, so one frame serves every label and every state). ui_scale.js multiplies the sheet by --win-s (WINDOWS townmap); everything is written in mockup px inside a `zoom` of that factor.
   A control keeps ONE authored box in every state (AGENTS.md "Absolute UI hover geometry"). Desktop only. The chart is drawn at a whole number of art pixels per art pixel (--tm-k) centred in the frame. */
@media screen and (min-width:901px){
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view]:is([open],[data-view]){--s:var(--win-s,1);--sf:Georgia,"Times New Roman",serif;--ss:Arial,Helvetica,sans-serif;width:calc(1586px * var(--s))!important;height:calc(992px * var(--s))!important;max-width:none!important;max-height:none!important;padding:0!important;border:0!important;border-image:none!important;border-radius:0!important;overflow:hidden!important;background:#0d111c!important;box-shadow:0 0 30px #0d111c,0 0 0 1px #202a43!important;color:#e0ddd7!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view]:is([open],[data-view])>.modal-header{display:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] #modal-body{position:absolute!important;left:0!important;top:0!important;display:block!important;zoom:var(--s)!important;box-sizing:border-box!important;width:1586px!important;height:992px!important;max-height:none!important;margin:0!important;padding:0!important;overflow:hidden!important;border:0!important;border-image:none!important;border-radius:0!important;box-shadow:none!important;background:#0d111c url("map/sheet.webp?v=mx1") 0 0/1586px 992px no-repeat!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map{position:absolute!important;left:0!important;top:0!important;display:block!important;box-sizing:border-box!important;width:1586px!important;height:992px!important;margin:0!important;padding:0!important;gap:0!important;border:0!important;background:none!important;overflow:visible!important}
/* ---- the header ------------------------------------------------------------------------------------------------------------------------------------- */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-head{position:absolute!important;left:0!important;top:0!important;display:block!important;width:1586px!important;height:140px!important;margin:0!important;padding:0!important;border:0!important;background:none!important;box-shadow:none!important;pointer-events:none!important;z-index:4!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-head .sgx-emblem,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-head .sgx-icon{display:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-titles{position:absolute!important;left:0!important;top:0!important;display:block!important;width:1000px!important;height:140px!important;margin:0!important;padding:0!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-eyebrow{position:absolute!important;left:190px!important;top:29px!important;display:block!important;margin:0!important;white-space:nowrap!important;color:#f2dfae!important;font:700 21px/26px var(--sf)!important;letter-spacing:.1em!important;text-transform:uppercase!important;text-shadow:0 1px 0 #0d111c!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-title{position:absolute!important;left:188px!important;top:50px!important;display:block!important;margin:0!important;white-space:nowrap!important;color:#f0d58f!important;-webkit-text-fill-color:transparent!important;background:linear-gradient(180deg,#fff0c4 0,#f0cf86 38%,#c58a3a 78%,#e8b860 100%)!important;-webkit-background-clip:text!important;background-clip:text!important;font:700 56px/64px var(--sf)!important;letter-spacing:.015em!important;text-transform:uppercase!important;transform:scaleX(.9)!important;transform-origin:0 50%!important;text-shadow:none!important;filter:drop-shadow(0 2px 0 #0d111c)!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-close{position:absolute!important;left:1493px!important;top:38px!important;display:block!important;width:60px!important;height:60px!important;min-width:0!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;color:transparent!important;font-size:0!important;line-height:0!important;pointer-events:auto!important;cursor:pointer!important;outline:none!important;z-index:6!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .sgx-close:is(:hover,:focus-visible,.pad-focus){background:#cc6b5d22!important;box-shadow:inset 0 0 0 2px #d28071,0 0 14px #cc6b5d99!important}
/* ---- the tabs: one authored box per slot (the mockup has eight, the closed regions of the game leave theirs empty) ---------------------------------------- */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs{position:absolute!important;left:0!important;top:0!important;display:block!important;width:1586px!important;height:232px!important;margin:0!important;padding:0!important;border:0!important;background:none!important;pointer-events:none!important;overflow:visible!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]{position:absolute!important;top:151px!important;display:block!important;box-sizing:border-box!important;width:162px!important;height:58px!important;min-width:0!important;margin:0!important;padding:0 0 0 38px!important;border:0 solid transparent!important;border-image:url("map/tab.webp?v=mx1") 20 24 fill/20px 24px stretch!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;color:#e0ddd7!important;font:700 19px/58px var(--sf)!important;letter-spacing:.03em!important;text-transform:uppercase!important;text-align:center!important;text-shadow:0 1px 0 #0d111c!important;white-space:nowrap!important;overflow:visible!important;pointer-events:auto!important;cursor:pointer!important;outline:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"].selected,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"][aria-selected="true"]{border-image:none!important;padding-left:46px!important;color:#fff4dc!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"].selected::after,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"][aria-selected="true"]::after{content:""!important;position:absolute!important;left:-11px!important;right:-11px!important;top:-3px!important;bottom:-3px!important;z-index:-1!important;display:block!important;border:0 solid transparent!important;border-image:url("map/tab-sel.webp?v=mx1") 22 28 fill/22px 28px stretch!important;pointer-events:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(1){left:67px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(2){left:246px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(3){left:425px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(4){left:603px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(5){left:782px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(6){left:961px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(7){left:1140px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(8){left:1318px!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:is(:hover:not(:disabled),:focus-visible,.pad-focus){filter:brightness(1.25) saturate(1.1)!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:disabled,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"].soon{opacity:.55!important;cursor:default!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tab-soon{display:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs .town-map-tab-lock{left:14px!important;right:auto!important;top:20px!important}
/* the notes (away from this region / locked region) sit on the chart's top-left corner */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-notes{position:absolute!important;left:64px!important;top:246px!important;display:block!important;width:560px!important;margin:0!important;padding:0!important;pointer-events:none!important;z-index:5!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-notes>p{margin:0 0 4px!important;padding:4px 10px!important;border:1px solid #7b5a3a!important;border-radius:5px!important;background:#141a2ad9!important;color:#e0ddd7!important;font:400 15px/20px var(--ss)!important}
/* ---- the chart ------------------------------------------------------------------------------------------------------------------------------------------ */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-frame{position:absolute!important;left:calc(584px - var(--tm-w,240px) * var(--tm-k,4) * .5px)!important;top:calc(545px - var(--tm-h,144px) * var(--tm-k,4) * .5px)!important;box-sizing:border-box!important;width:calc(var(--tm-w,240px) * var(--tm-k,4) * 1px)!important;height:calc(var(--tm-h,144px) * var(--tm-k,4) * 1px)!important;max-width:none!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;background:#07122a!important;box-shadow:none!important;overflow:hidden!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-frame>img{position:absolute!important;left:0!important;top:0!important;display:block!important;width:100%!important;height:100%!important;max-width:none!important;margin:0!important;border:0!important;image-rendering:pixelated!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-label{box-sizing:border-box!important;height:auto!important;margin:0!important;padding:1px 7px 2px!important;border:1px solid #6e5030!important;border-radius:6px!important;background:linear-gradient(180deg,#1c253bf2,#131928f2)!important;box-shadow:inset 0 0 0 1px #0d111c99,0 1px 3px #0d111ccc!important;color:#f3e4c4!important;font-family:var(--sf)!important;font-weight:700!important;text-shadow:0 1px 0 #0d111c!important;text-transform:uppercase!important;letter-spacing:.02em!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-label.route{padding:0 5px!important;border-color:#24314d!important;background:#131a29d1!important;color:#cdbf9f!important;font-weight:400!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-label:is(:hover:not(:disabled),:focus-visible,.pad-focus,.active){background:linear-gradient(180deg,#2d3853,#1d273d)!important;border-color:#e8b84a!important;box-shadow:inset 0 0 0 1px #0d111c,0 0 10px #f3c96b88!important;color:#fff0cc!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-icon{color:#e8b84a!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-back{position:absolute!important;left:750px!important;top:862px!important;display:block!important;width:78px!important;height:78px!important;min-width:0!important;margin:0!important;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;color:transparent!important;font-size:0!important;z-index:5!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-back i,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-back img{display:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-back:is(:hover,:focus-visible,.pad-focus){box-shadow:inset 0 0 0 2px #f6d488aa,0 0 14px #cc6b5d88!important;border-radius:50%!important}
/* ---- the place panel ------------------------------------------------------------------------------------------------------------------------------ */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info{position:absolute!important;left:1141px!important;top:250px!important;display:block!important;box-sizing:border-box!important;width:404px!important;height:518px!important;margin:0!important;padding:0!important;border:0!important;background:none!important;box-shadow:none!important;overflow:visible!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>strong{position:absolute!important;left:20px!important;top:36px!important;display:block!important;width:364px!important;margin:0!important;padding:0!important;color:#f0d58f!important;font:700 36px/50px var(--sf)!important;text-align:center!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;text-shadow:0 2px 0 #0d111c!important;background:none!important;-webkit-text-fill-color:#f0d58f!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>.town-map-services{position:absolute!important;left:28px!important;top:118px!important;display:block!important;width:348px!important;height:62px!important;margin:0!important;padding:0!important;color:#dad7d1!important;font:400 20px/32px var(--sf)!important;text-align:center!important;overflow:hidden!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>small{position:absolute!important;left:28px!important;top:184px!important;display:block!important;width:348px!important;height:22px!important;margin:0!important;padding:0!important;color:#b9ab94!important;font:400 14px/22px var(--ss)!important;text-align:center!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-photo{position:absolute!important;left:34px!important;top:210px!important;display:block!important;box-sizing:border-box!important;width:337px!important;height:182px!important;margin:0!important;border:0!important;background-color:#121927!important;background-repeat:no-repeat!important;image-rendering:pixelated!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-photo::after{content:""!important;position:absolute!important;left:-6px!important;top:-6px!important;width:349px!important;height:194px!important;background:url("map/photo-frame.webp?v=mx1") 0 0/100% 100% no-repeat!important;pointer-events:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>button{position:absolute!important;left:11px!important;top:414px!important;display:block!important;box-sizing:border-box!important;width:376px!important;height:98px!important;min-width:0!important;margin:0!important;padding:0 28px 0 128px!important;border:0 solid transparent!important;border-image:url("map/fly.webp?v=mx1") 30 40 fill/30px 40px stretch!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;color:#f7e7c4!important;font:700 27px/98px var(--sf)!important;letter-spacing:.02em!important;text-transform:uppercase!important;text-align:center!important;text-shadow:0 2px 0 #0d111c!important;white-space:nowrap!important;overflow:hidden!important;cursor:pointer!important;outline:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>button:is(:hover:not(:disabled),:focus-visible,.pad-focus){filter:brightness(1.2) saturate(1.1)!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>button:disabled{filter:grayscale(.6) brightness(.7)!important;cursor:default!important}
/* ---- the hint ----------------------------------------------------------------------------------------------------------------------------------------- */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-hint{position:absolute!important;left:1136px!important;top:910px!important;display:block!important;width:400px!important;height:34px!important;margin:0!important;padding:0!important;border:0!important;background:none!important;box-shadow:none!important;color:#dad7d1!important;font:400 22px/34px var(--sf)!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
/* the tab icons are cropped from the mockup: one per region while the tab is idle, the red ball on the lit tab; the old pseudo-elements of the buttons and the hint are off */
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:not(.selected):not([aria-selected="true"])::after,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>button::before,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-info>button::after,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-hint::before,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-hint::after{content:none!important;display:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]::before{content:""!important;position:absolute!important;left:20px!important;top:50%!important;display:block!important;width:36px!important;height:36px!important;margin:-18px 0 0!important;padding:0!important;border:0!important;background:url("map/ico-silver.webp?v=mx1") 0 0/36px 36px no-repeat!important;clip-path:none!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(1)::before{background-image:url("map/ico-kanto.webp?v=mx1")!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"]:nth-of-type(2)::before{background-image:url("map/ico-johto.webp?v=mx1")!important}
body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"].selected::before,body:not(.mobile-web) #modal#modal[data-view="townmap"][data-view][data-view] .town-map-tabs>button[role="tab"][aria-selected="true"]::before{left:26px!important;background-image:url("map/ico-ball.webp?v=mx1")!important}
}
