:root{font-family:Arial,"Microsoft YaHei",sans-serif;color:#718996;background:#ecf2fe;--pink:#c78fa9;--land:#dce6f0;--ink:#7692a5}*{box-sizing:border-box}body{margin:0}button,a,select{-webkit-tap-highlight-color:transparent}button{border:0;background:transparent;color:inherit;cursor:pointer;padding:10px;border-radius:12px}button:hover{background:#dee8f4}button:focus-visible,select:focus-visible{outline:2px solid var(--pink)}button svg{width:28px;height:28px;display:block;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}header{display:grid;grid-template-columns:1fr auto minmax(220px,25%);align-items:center;height:94px;padding:0 4vw;gap:24px}.brand{font-size:26px;text-decoration:none;color:inherit;letter-spacing:-1px}.sharing,.preferences{display:flex;gap:14px}.preferences{justify-content:flex-end}.sharing{padding-right:18px}main{display:grid;grid-template-columns:minmax(0,1fr) minmax(220px,25%);gap:24px;margin:0 4vw;height:calc(100dvh - 110px);min-height:580px}.left{display:flex;flex-direction:column;min-width:0}.mapbar{display:flex;justify-content:space-between;align-items:center;height:54px;padding:0 12px}select{font:inherit;color:inherit;border:0;background:transparent;font-size:22px;padding:8px;cursor:pointer}#progress{font-size:18px;color:#96a8b6}#mapArea{position:relative;flex:1;min-height:360px;display:flex;align-items:center}#map{width:100%;height:100%;overflow:hidden}#map path{fill:var(--land);stroke:#ecf2fe;stroke-width:.45;vector-effect:non-scaling-stroke}#map .done{fill:#a9bdc9}#map.assisted path{stroke:none}#map .target{fill:var(--pink)}#map .hover{fill:#b47b98}#word{position:absolute;bottom:2%;left:0;right:0;text-align:center;font-size:25px;pointer-events:none}#lens{position:absolute;display:none;border:2px dashed var(--pink);border-radius:50%;background:#ecf2fe;overflow:hidden;pointer-events:none}#lens path{fill:var(--pink);stroke:none}#tray{display:flex;flex-direction:column;justify-content:space-evenly;padding:8px 16px 45px;gap:12px}.tile{flex:1;min-height:130px;max-height:220px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;cursor:grab;touch-action:none;border:2px solid transparent;border-radius:22px;user-select:none}.tile:hover{background:#e3ecf8}.tile.speaking{border-color:#b5c5d1}.tile.dragging{opacity:.3}.tile svg{width:82%;height:120px;overflow:visible}.tile path{fill:var(--ink);stroke:var(--ink);stroke-width:.6;vector-effect:non-scaling-stroke}.tile span{font-size:21px;text-align:center}.actions{height:86px;display:flex;justify-content:center;align-items:center;gap:52px}.actions button{color:#a4b4c3}.actions button.active{color:var(--pink)}.actions svg{width:33px;height:33px}#ghost{position:fixed;width:160px;height:130px;pointer-events:none;z-index:20;opacity:.85;filter:drop-shadow(0 5px 10px #8ea1b52a)}#ghost path{fill:var(--ink)}dialog{border:0;border-radius:18px;background:#ecf2fe;color:#718996;padding:48px;box-shadow:0 15px 80px #526d8b22}dialog::backdrop{background:#647a8c22}#close{position:absolute;right:8px;top:4px;font-size:27px}#toast{position:fixed;bottom:28px;left:50%;transform:translateX(-50%);color:#9c7189;font-size:17px;pointer-events:none}@media(max-width:760px){header{padding:0 18px;grid-template-columns:1fr auto auto;gap:8px;height:75px}.brand{font-size:20px}.sharing,.preferences{gap:0}.sharing{padding:0}main{margin:0 14px;grid-template-columns:minmax(0,1fr) 150px;gap:8px;height:calc(100dvh - 90px)}#tray{padding:0;gap:4px}.tile span{font-size:16px}.tile svg{height:90px}.actions{gap:24px}select{font-size:18px}}

/* Fit the complete desktop stage inside the live browser viewport. */
:root{--edge:4vw;--column:minmax(180px,25%);--gutter:24px;--nav:clamp(58px,10dvh,94px);--bottom:32px}
html{height:100%;overflow:hidden}
body{height:100vh;height:100dvh;display:grid;grid-template-rows:var(--nav) minmax(0,1fr);padding-bottom:var(--bottom);overflow:hidden}
header{height:auto;min-height:0;grid-template-columns:minmax(0,1fr) var(--column);grid-template-rows:1fr;padding:0 var(--edge);gap:var(--gutter)}
.brand{grid-column:1;grid-row:1;justify-self:start;font-size:clamp(19px,2vw,26px)}
.sharing{grid-column:1;grid-row:1;justify-self:end;padding-right:0}
.preferences{grid-column:2;grid-row:1}
main{height:auto;min-height:0;grid-template-columns:minmax(0,1fr) var(--column);gap:var(--gutter);margin:0 var(--edge)}
.left{min-height:0}
.mapbar{height:clamp(38px,6dvh,54px);flex-shrink:0}
#mapArea{min-height:0;overflow:hidden}
#map{min-height:0;display:block}
#word{font-size:clamp(17px,2.6dvh,25px);bottom:1%}
#tray{min-height:0;display:grid;grid-template-rows:repeat(3,minmax(0,1fr));padding:0 16px;gap:clamp(4px,1.3dvh,12px)}
.tile{min-height:0;max-height:none;padding:clamp(3px,1dvh,10px);gap:clamp(4px,1.2dvh,12px);overflow:hidden}
.tile svg{height:auto;min-height:0;flex:1;width:82%;max-height:120px;overflow:visible}
.tile span{flex-shrink:0;font-size:clamp(14px,2.3dvh,21px);line-height:1.25;overflow-wrap:anywhere}
.actions{height:clamp(52px,9dvh,86px);flex-shrink:0;gap:clamp(24px,4vw,52px)}
.actions svg{width:clamp(26px,3.6dvh,33px);height:clamp(26px,3.6dvh,33px)}
#toast{bottom:4px;font-size:14px}
@media(max-width:760px){:root{--edge:14px;--column:minmax(112px,27%);--gutter:8px}.brand{font-size:18px}.sharing,.preferences{gap:0}header button{padding:7px}header button svg{width:23px;height:25px}#tray{padding:0}.tile span{font-size:clamp(12px,2.3dvh,16px)}select{font-size:18px}}
@media(max-height:500px){.mapbar select{font-size:17px}.tile svg{max-height:75px}.tile span{font-size:14px}header button{padding:6px}.actions button{padding:6px}}

/* Requested visual reduction; hit areas and layout anchors stay stable. */
.brand{font-size:clamp(9.5px,1vw,13px)}
header button svg{transform:scale(.7)}
.mapbar select{font-size:15.4px}
.tile svg{transform:scale(.7);transform-origin:center}
#ghost{width:112px;height:91px}
#ghost svg{width:100%;height:100%}
@media(max-width:760px){.brand{font-size:9px}.mapbar select{font-size:12.6px}}
@media(max-height:500px){.mapbar select{font-size:11.9px}}

/* Shared map/tray stage, with separate country name and control rows. */
main{grid-template-rows:clamp(38px,6dvh,54px) minmax(0,1fr) clamp(26px,3.8dvh,36px) clamp(52px,9dvh,86px);column-gap:var(--gutter);row-gap:0}
.left{grid-column:1;grid-row:1/5;display:grid;grid-template-rows:subgrid}
.mapbar{grid-row:1;position:relative;height:auto}
#progress{position:absolute;left:50%;transform:translateX(-50%);font-size:9px;pointer-events:none}
#mapArea{grid-row:2}
#word{grid-row:3;position:static;align-self:center;line-height:1.2}
.actions{grid-row:4;height:auto}
#tray{grid-column:2;grid-row:2;align-self:stretch}
.tile svg{transform:scale(.35)}
#ghost{width:56px;height:45.5px}

/* Compact map assist and separate voice controls. */
:root{--gutter:4.8px}
header{position:relative}
.brand{position:absolute;left:20px;top:20px}
.mapbar{padding:0}
.mapbar select{padding-left:0}
#tray{padding-left:3.2px;padding-right:3.2px}
#sound{position:absolute;right:20px;bottom:20px;z-index:2;padding:10px}
#sound svg{width:19.6px;height:19.6px}
#sound .mute-mark{display:none}
#sound.muted .mute-mark{display:block}
#sound.muted{color:#9daebc}
#lens{border-width:1px}
#lens path{stroke:var(--pink);stroke-width:.55;stroke-linejoin:round;vector-effect:non-scaling-stroke}
#lens.sparse path{stroke-width:1}
.dialog-close{position:absolute;right:8px;top:4px;font-size:27px}
.voice-fields{display:grid;grid-template-columns:auto minmax(120px,260px);align-items:center;gap:20px;font-size:14px}
.voice-fields select{font-size:15px;max-width:260px}
.voice-fields input{width:100%;accent-color:#91a9b9}
#voiceTest{grid-column:2;justify-self:end;font-size:24px}
#rateValue{margin-left:8px;color:#9aafbd}
@media(max-width:760px){:root{--gutter:1.6px}.voice-fields{grid-template-columns:1fr;gap:12px}.voice-fields select{max-width:220px}#voiceTest{grid-column:1}dialog{padding:38px 24px}}
.brand{grid-column:auto;grid-row:auto}
#sound{width:40px;height:40px;padding:0;display:flex;align-items:flex-end;justify-content:flex-end}
#region{appearance:none;-webkit-appearance:none;padding-left:0;padding-right:22px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5' viewBox='0 0 8 5'%3E%3Cpath d='M1 1l3 3 3-3' fill='none' stroke='%23718996' stroke-width='1.2'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 6px center;background-size:8px 5px}

/* Fixed world-sized stage and 40 px drag corridor. */
:root{--map-column:60%;--extra-gap:32px;--frame-height:300px}
header,main{grid-template-columns:minmax(0,var(--map-column)) minmax(0,1fr);column-gap:40px}
main{grid-template-rows:clamp(38px,6dvh,54px) minmax(0,1fr) clamp(26px,3.8dvh,36px) var(--extra-gap) clamp(52px,9dvh,86px)}
.left{grid-row:1/6}
#mapArea{display:block}
#mapFrame{position:absolute;left:0;top:50%;transform:translateY(-50%);width:100%;height:var(--frame-height)}
#map{width:100%;height:100%}
.actions{grid-row:5;position:relative}
#sound{top:0;bottom:auto;align-items:flex-start;right:20px}
#tray{padding-left:0;padding-right:0}
.tile span{font-size:clamp(7px,1.15dvh,10.5px)}
.tile svg{width:min(82%,240px)}
.tile.adaptive svg{transform:scale(1);max-height:120px}
.tile.adaptive path,#ghost.adaptive path{stroke:var(--ink);stroke-width:1;stroke-linejoin:round;vector-effect:non-scaling-stroke}
@media(max-width:760px){.tile span{font-size:clamp(6px,1.15dvh,8px)}}
@media(max-height:500px){.tile span{font-size:7px}.tile.adaptive svg{max-height:75px}}

/* Compact draggable groups; original graphics are measured before resizing. */
header,main{column-gap:8px}
main{grid-template-rows:0 minmax(0,1fr) clamp(26px,3.8dvh,36px) var(--extra-gap) clamp(52px,9dvh,86px)}
#progress{left:calc(var(--edge) + var(--map-column)/2);top:50%;transform:translate(-50%,-50%);font-size:18px}
#region{position:absolute;left:0;top:50%;transform:translateY(-50%);font-size:15.4px}
.slot{position:relative;min-width:0;min-height:0;display:grid;place-items:center}
.tile{position:relative;flex:0;width:max-content;max-width:100%;height:max-content;min-width:var(--frame-width,0px);min-height:var(--frame-height,0px);padding:0;gap:var(--graphic-gap,6px);border:0;background:transparent;overflow:visible}
.tile:hover{background:transparent}
.tile::before{content:"";position:absolute;left:50%;top:50%;width:var(--frame-width,0px);height:var(--frame-height,0px);transform:translate(-50%,-50%);border:2px solid transparent;border-radius:6.6px;box-sizing:border-box;pointer-events:none;z-index:-1}
.tile:hover::before{background:#e3ecf8}
.tile.speaking::before{border-color:#b5c5d1}
.tile svg,.tile.adaptive svg{flex:none;min-height:0;max-height:none;max-width:none;transform:none;overflow:visible}
.tile span{font-size:clamp(4.9px,.805dvh,7.35px);line-height:1.25;white-space:nowrap;overflow-wrap:normal}
.tile.measuring{width:100%;height:100%;max-width:none;min-width:0;min-height:0;box-sizing:border-box;border:2px solid transparent;padding:clamp(3px,1dvh,10px);gap:clamp(4px,1.2dvh,12px);overflow:hidden}
.tile.measuring svg{height:auto;width:min(82%,240px);min-height:0;flex:1;max-height:120px;transform:scale(.35)}
.tile.measuring.adaptive svg{transform:scale(1)}
.tile.measuring span{font-size:clamp(7px,1.15dvh,10.5px);white-space:normal}
@media(max-width:760px){.tile span{font-size:clamp(4.2px,.805dvh,5.6px)}.tile.measuring span{font-size:clamp(6px,1.15dvh,8px)}#region{font-size:12.6px}}
@media(max-height:500px){.tile span{font-size:4.9px}.tile.measuring span{font-size:7px}.tile.measuring svg{max-height:75px}}

.tile{isolation:isolate}

#tray{justify-content:normal;grid-template-columns:minmax(0,1fr)}

/* Shared visual scale for every country; the map-to-tray gap is fixed. */
header,main{column-gap:20px}
.tile.sparse path{stroke:var(--ink);stroke-width:1;stroke-linejoin:round;vector-effect:non-scaling-stroke}

/* Navigation typography. */
.brand{font-size:18px}
#progress{font-size:16px}

/* Match feedback uses the existing country tile without moving the layout. */
.tile.matched::before{border-color:transparent}

.match-check{position:absolute;right:-24px;top:50%;transform:translateY(-50%);color:#5d9e78;font-size:24px!important;line-height:1}
.tile:focus-visible{outline:2px solid var(--pink);outline-offset:6px}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto}}

/* Names remain readable and selectable independently of the draggable shape. */
.tile>span:not(.match-check){font-size:14px;line-height:1.4;transform:none;letter-spacing:normal;user-select:text;-webkit-user-select:text;cursor:text;touch-action:auto}
.tile svg{cursor:grab}
.tile.dragging svg{cursor:grabbing}

/* Region picker opens upward from the bottom navigation. */
#region{display:inline-flex;align-items:center;gap:9px;background-image:none;padding:8px 10px 8px 0;font-size:15.4px;white-space:nowrap}
#region .region-chevron{width:14px;height:14px;stroke-width:1.5;transition:transform .15s}
#region[aria-expanded="true"] .region-chevron{transform:rotate(180deg)}
#regionDialog{position:fixed;margin:0;padding:12px;width:224px;max-width:calc(100vw - 24px);max-height:calc(100dvh - 24px);overflow:auto;border:1px solid #dce5ef;border-radius:14px;background:#f7f9fd;box-shadow:0 12px 36px #526d8b22}
#regionDialog::backdrop{background:transparent}
.region-heading{display:flex;align-items:center;justify-content:space-between;padding:0 4px 8px 10px;color:#92a3b2;font-size:12px;border-bottom:1px solid #e5ebf2;margin-bottom:6px}
#regionClose{font-size:22px;line-height:1;padding:5px 8px}
#regionOptions{display:grid;gap:3px}
.region-option{display:flex;align-items:center;justify-content:space-between;width:100%;padding:11px 12px;border-radius:8px;font:inherit;font-size:14px;text-align:left}
.region-option[aria-checked="true"]{background:#e9edf7;color:#a7718c}
.region-option:hover{background:#e8eff7}
.region-mark{font-size:15px}
#regionDialog button:focus-visible{outline:2px solid var(--pink);outline-offset:-2px}
@media(prefers-reduced-motion:reduce){#region .region-chevron{transition:none}}

/* European Russia is the solid playable piece; Asia is only a visual cue. */
.tile path.asia-context,#ghost path.asia-context{fill:none;stroke:#a5b6c5;stroke-width:.8;vector-effect:non-scaling-stroke;pointer-events:none}
.tile path.ural-boundary,#ghost path.ural-boundary{fill:none;stroke:#a5b6c5;stroke-width:.8;vector-effect:non-scaling-stroke;pointer-events:none}

/* The entire Russia silhouette, including its outline, is draggable. */
.tile path.asia-context{pointer-events:all;cursor:grab}

/* Only the latest completion is emphasized, using the existing blue-grey palette. */
:root{--recent-country:#96afbf}
#map path.done.recent{fill:var(--recent-country)}
#completedLens{position:absolute;display:none;border:1px dashed #b8c7d4;border-radius:50%;background:#ecf2fe;overflow:hidden;pointer-events:none;z-index:1}
#completedLens path{fill:var(--recent-country);stroke:var(--recent-country);stroke-width:.55;stroke-linejoin:round;vector-effect:non-scaling-stroke}
#completedLens.sparse path{stroke-width:1}
#lens{z-index:2}

/* Completed countries always use true geometry, with a transient locator. */
#map path.done,#map path.done.recent {fill:#A6C3AA}
#placementShrink {position:fixed;pointer-events:none;z-index:25;overflow:visible;transition:left .18s ease-out,top .18s ease-out,width .18s ease-out,height .18s ease-out}
#placementShrink path {fill:#A6C3AA;stroke:none}
.placement-feedback {position:absolute;z-index:6;width:0;height:0;opacity:1;transition:opacity .25s;pointer-events:none}
.placement-feedback.faded {opacity:0}
.placement-circle {position:absolute;left:-15px;top:-15px;width:30px;height:30px;border:1px solid #AAB3BA;border-radius:50%;background:transparent;pointer-events:auto}
.placement-leader {position:absolute;left:15px;top:0;width:8px;border-top:1px solid #AAB3BA}
.placement-label {position:absolute;left:23px;display:flex;flex-direction:column;gap:3px;white-space:nowrap;background:#FFF;border-radius:4px;padding:5px 7px;color:#626C77;font-size:12px;line-height:1.3;box-shadow:none;pointer-events:auto}
.placement-label small {font-size:10px;color:#929CA8}
.placement-feedback.label-left .placement-label {left:auto;right:23px}
.placement-feedback.label-left .placement-leader {left:auto;right:15px}
@media(prefers-reduced-motion:reduce){#placementShrink,.placement-feedback {transition:none}}
.placement-feedback.faded :is(.placement-circle,.placement-label) {pointer-events:none}

/* Reserve green for the most recently completed country. */
#map path.done {fill:#A9BDC9}
#map path.done.recent {fill:#A6C3AA}

#map path.done.recent,#placementShrink path {fill:#82C99A}
.placement-outgoing,.placement-outgoing * {pointer-events:none!important}

/* Keep success feedback independent from pointer-driven name previews. */
.placement-feedback,.placement-feedback * {pointer-events:none!important}
.placement-feedback.large-country :is(.placement-circle,.placement-leader) {display:none}
.placement-feedback .placement-leader {left:auto;right:15px;top:15px;transform:rotate(-45deg);transform-origin:right center;width:11px}

.placement-feedback.feedback-right .placement-leader {right:auto;left:15px;transform:rotate(45deg);transform-origin:left center}
.placement-feedback.feedback-above .placement-leader {top:-15px;transform:rotate(45deg)}
.placement-feedback.feedback-above.feedback-right .placement-leader {transform:rotate(-45deg)}
#tinyCountryDots {position:absolute;inset:0;z-index:5;pointer-events:none}
.tiny-country-dot {position:absolute;width:2px;height:2px;border-radius:50%;background:#E5484D;transform:translate(-50%,-50%);pointer-events:none}

.placement-dot {display:none;position:absolute;left:-1px;top:-1px;width:2px;height:2px;background:#E5484D;border-radius:50%;pointer-events:none}
.placement-feedback.tiny-country .placement-dot {display:block}
.placement-label {z-index:1}

/* Match A09: transparent speaker control, red pressed state. */
#sound,#sound:hover,#sound:active {background:transparent;box-shadow:none;border:0;color:#727D89}
#sound[aria-pressed="true"],#sound.muted {color:#A33E37}
#sound svg {width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:.9;stroke-linecap:round;stroke-linejoin:round}
/* Map09 操作栏：静音固定在地图右下角，分享与语言入口右移。 */

.sharing {transform:translateX(40px)}
.map-carousel {display:flex;align-items:center;gap:20px}
.map-carousel button {display:grid;place-items:center;width:44px;height:44px;padding:0;color:#727D89;border-radius:50%}
.map-carousel svg {width:22px;height:22px;stroke-width:1.3}
#mapPrevious,#mapNext {background:#edf0f3}
#mapPlay {width:48px;height:48px;color:#AA4C34;background:#f3e9e8}
#mapPlay svg {stroke-width:1.2}
.actions {gap:clamp(12px,2.7vw,40px)}
#word {white-space:normal;font-size:clamp(16px,2.3dvh,22px)}
#systemTitle {font-size:18px;font-weight:400}
#systemLanguageEntry {font-size:16px;padding:12px 0}


#word {white-space:pre-line;line-height:1.4}
.tile>span:not(.match-check) {white-space:pre-line;overflow-wrap:anywhere;max-width:100%;text-align:center}
.placement-label small[hidden] {display:none}

/* 与 A09 PC 一致的 44px 点击区、24px 翻页圆底和 30.4px 播放圆底。 */
.right-column {grid-column:2;grid-row:2/6;display:grid;grid-template-rows:subgrid;min-width:0;min-height:0}
.right-column>#tray {grid-column:1;grid-row:1;min-width:0}
.right-column>.map-carousel {grid-column:1;grid-row:4;align-self:center;justify-self:center;display:grid;grid-template-columns:repeat(3,44px);--map-page-step:clamp(44px,5vw,76px);column-gap:calc(var(--map-page-step) - 44px);align-items:center}
.right-column .map-carousel button {width:44px;height:44px;margin:0;padding:0;border-radius:0;color:#727D89;display:grid;place-items:center}
.right-column .map-carousel svg {width:22px;height:22px;stroke-width:1.3;fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round}
.right-column :is(#mapPrevious,#mapNext) {background:radial-gradient(circle,#eef0f2 0 12px,transparent 12px)}
.right-column #mapPlay {width:44px;height:44px;color:#A33E37;background:radial-gradient(circle,#a33e371a 0 15.2px,transparent 15.2px)}
.right-column #mapPlay svg {stroke-width:1.2}

/* 轮播复用放置完成的配色，但不修改拼图完成记录。 */
#map path.browse-current {fill:#82C99A}
#map path.browse-previous {fill:#A9BDC9}
/* Direct A09 PC V49 desktop.css language geometry (CSS pixels, no scaling).
   951px summary; 240px selectors; 355.5px column pitch; 12px / 10px type. */
.map-language-page {position:fixed;inset:0;margin:0;max-width:none;max-height:none;width:100%;height:100dvh;padding:0;border:0;border-radius:0;box-shadow:none;background:#fafafa;color:#7E8B9E;overflow:auto}
.map-language-page[open] {display:block}
.map-language-header {position:relative;height:64px;display:flex;align-items:center;padding:0 36px;gap:14px}
.map-language-header button {display:grid;place-items:center;width:24px;min-width:24px;height:44px;padding:0;background:transparent;color:#727D89}
.map-language-header svg {width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.3;stroke-linecap:round;stroke-linejoin:round}
.map-language-header span {font-size:12px;font-weight:400;color:#858D96}
.map-language-header button:last-child {position:absolute;right:max(36px,calc((100vw - 1100px)/2));top:10px}
.map-language-content {margin:18px 36px 24px 72px;max-width:none;padding:0}
.map-language-summary {display:grid;width:951px;max-width:calc(100vw - 108px);grid-template-columns:repeat(3,240px);column-gap:115.5px;margin:0 0 24px -16px}
.map-language-summary>button {display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:6px;min-width:0;width:100%;height:auto;min-height:66px;padding:10px 14px 10px 15px;border:1px solid #DDE2E7;border-radius:8px;text-align:left;background:transparent;box-shadow:none}
.map-language-summary>button:hover {border-color:#CBD3DB}
.map-language-summary>button[aria-pressed=true] {border:1px solid #A6C3AA;box-shadow:inset 0 0 0 1px #A6C3AA}
.map-language-summary strong {font-size:12px;font-weight:400;color:#7E8B9E}
.map-language-summary>button[aria-pressed=true] strong {font-weight:500;color:#5D6F82}
.map-language-summary>button>span {font-size:12px;font-weight:400;color:#626C77;line-height:1.5;white-space:normal;overflow-wrap:anywhere;unicode-bidi:plaintext}
.map-language-summary>button:focus-visible {outline:1px solid #A6C3AA;outline-offset:3px}
.map-language-content h3 {display:flex;align-items:baseline;gap:9px;font-size:12px;font-weight:500;line-height:1.5;color:#5D6F82;margin:0 0 16px}
.map-language-content h3 strong {font-weight:500}
.map-language-content h3 small {font-size:10px;font-weight:400;color:#9AA8BC;unicode-bidi:plaintext}
.map-language-layout {display:grid;grid-template-columns:651px 240px;column-gap:60px}
.map-language-grid {display:grid;width:651px;grid-template-columns:repeat(2,295.5px);grid-template-rows:repeat(8,40px);grid-auto-flow:column;gap:0 60px}
.map-language-grid button {display:flex;align-items:center;gap:9px;min-width:0;min-height:0;text-align:left;padding:0;font-size:12px;font-weight:400;line-height:1.5;color:#7E8B9E;background:transparent;white-space:nowrap}
.map-language-grid span {font-size:12px;font-weight:400}
.map-language-grid small {font-size:10px;font-weight:400;color:#9AA8BC}
.map-language-grid button[aria-pressed=true] {color:#5D6F82}
.map-language-grid button[aria-pressed=true]>span {font-weight:600}
.map-language-check {width:14px;height:14px;flex:none;fill:none;stroke:#66B77A;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round;margin-left:-1px}
.map-language-rates {display:flex;flex-direction:column;align-items:flex-start;align-self:end;gap:8px;padding-bottom:10px;margin-top:0}
.map-language-rates>button {font-size:12px;font-weight:400;color:#9AA8BC;min-height:32px;text-align:left;padding:0;background:transparent}
.map-language-rates>button:hover {color:#626C77}
.map-language-rates small {font-size:10px;margin-left:8px}
.map-speed-content {margin:18px 36px 24px 72px}
.map-speed-section {margin-bottom:24px}
.map-speed-section h3 {font-size:12px;font-weight:400;color:#7E8B9E;margin:0 0 8px}
.map-speed-row {display:flex;flex-direction:column;align-items:flex-start;gap:8px;min-height:44px;color:#626B6C;font-size:14px}
.map-speed-row>span {font-size:17px;font-weight:400}
.map-speed-options {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0 3px;
}
.map-speed-options::before,
.map-speed-options button[aria-pressed="true"]::before {
  content: "";
  position: absolute;
  inset: 50% 0 auto;
  transform: translateY(-50%);
  z-index: -1;
  border-radius: 999px;
}
.map-speed-options::before { height: var(--map-speed-capsule-height, 30px); background: #e9edf1; }
.map-speed-options button {
  position: relative;
  isolation: isolate;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0 5px;
  border: 0;
  background: transparent;
  color: #445460;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.map-speed-options button[aria-pressed="true"] { color: #18242e; }
.map-speed-options button[aria-pressed="true"]::before { height: 24px; background: #fff; }

@media(max-width:1099px){.map-language-summary {width:min(800px,100%);grid-template-columns:repeat(3,minmax(0,1fr));column-gap:40px}.map-language-layout {display:block}.map-language-rates {margin-top:24px;padding:0}.map-language-grid {width:min(651px,100%);grid-template-columns:repeat(2,minmax(0,1fr));column-gap:32px}}
@media(max-width:650px){.map-language-content,.map-speed-content {margin-left:36px}.map-language-summary {column-gap:16px;max-width:100%;margin-left:0}.map-language-grid {column-gap:20px}.map-speed-options {max-width:100%;overflow-x:auto}.map-language-header button:last-child {right:24px}}
/* A09's original capsule is directly available at both language/settings entrances. */
.map-language-rates {gap:22px}
.map-inline-speed {display:flex;flex-direction:column;align-items:flex-start;gap:8px;max-width:100%;font-size:14px;color:#626B6C}
.map-inline-speed>span {font-size:17px;font-weight:400;line-height:1.5}
.map-inline-speed .map-speed-options {max-width:100%;overflow-x:auto;flex-shrink:0}

#mapSystemSpeeds {display:flex;flex-direction:column;gap:24px;margin-top:24px}

/* Simple country silhouettes with first/second voice names, no card settings. */
#tray .tile>.country-card-names {display:flex;flex-direction:column;align-items:center;gap:4px;white-space:normal;line-height:1.35;user-select:text;cursor:text}
#tray .country-card-names strong {font-size:18px;font-weight:400;color:#718996}
#tray .country-card-names small {font-size:13.5px;font-weight:400;color:#9aaab8}

/* Main-map country card only; the three tray silhouettes remain minimal. */
#tray .country-card-names strong {font-size:10.8px}
.placement-feedback .placement-label,.placement-feedback .placement-label * {pointer-events:auto!important}
.placement-feedback.faded .placement-label,.placement-feedback.faded .placement-label *,.placement-outgoing .placement-label,.placement-outgoing .placement-label * {pointer-events:none!important}
.placement-feedback .placement-label {width:230px;max-width:calc(100vw - 40px);padding:12px 14px;border-radius:7px;gap:9px;white-space:normal;user-select:text}
.placement-label>.placement-zh {font-size:16px;line-height:1.4;color:#626C77;overflow-wrap:anywhere}
.map-main-card-tools {display:flex;align-items:center;justify-content:flex-end;gap:8px;margin:-6px -6px 0 0}
.map-main-card-tools button {display:flex;align-items:center;gap:7px;padding:4px 6px;height:28px;border-radius:4px;color:#929CA8;font-size:11px;cursor:pointer}
.map-main-card-tools svg {width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.3;stroke-linecap:round;stroke-linejoin:round}
.map-main-more svg {stroke:#c8cfd5;stroke-width:2.2}
.map-main-more[aria-expanded=true] svg {stroke:#66B77A}
.map-main-card-facts {margin:0;padding:8px 0 0;border-top:1px solid #edf0f2;font-size:12px;line-height:1.6;max-height:min(280px,40dvh);overflow:auto;scrollbar-width:thin}
.map-main-card-facts[hidden] {display:none}
.map-main-card-facts>div {display:grid;grid-template-columns:auto minmax(0,1fr);gap:14px;margin:4px 0}
.map-main-card-facts dt {color:#98a4af}
.map-main-card-facts dd {margin:0;text-align:right;color:#626C77;overflow-wrap:anywhere}
.map-main-card-settings {width:min(360px,calc(100vw - 40px));padding:18px 24px;background:#fafafa;color:#727D89}
.map-main-settings-head {display:flex;align-items:center;gap:12px}
.map-main-settings-head h2 {flex:1;font-size:16px;font-weight:400;margin:0}
.map-main-settings-head button {font-size:24px;padding:0;width:30px;height:40px}
.map-main-settings-fields {display:flex;flex-direction:column;gap:18px;margin:24px 0}
.map-main-settings-fields label {display:flex;align-items:center;gap:12px;font-size:14px;cursor:pointer}
.map-main-settings-fields input {accent-color:#66B77A}
.map-main-card-settings p {font-size:11px;color:#a0acb8}

/* Business-card proportions and restrained type hierarchy. */
.placement-feedback .placement-label {display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:24px minmax(0,1fr);align-content:stretch;gap:8px;width:240px;aspect-ratio:5/3;min-height:144px;padding:12px 16px 16px;border-radius:7px;box-sizing:border-box}
.placement-feedback .placement-label.map-main-expanded {aspect-ratio:auto;grid-template-rows:24px auto auto;min-height:144px}
.placement-label .map-main-card-tools {display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;justify-content:flex-end;gap:5px;height:24px;margin:-4px -6px 0 0;min-width:0}
.placement-label .map-main-card-tools button {display:inline-flex;flex-direction:row;flex-wrap:nowrap;align-items:center;justify-content:center;gap:5px;flex:0 0 auto;min-width:24px;width:auto;height:24px;padding:4px;white-space:nowrap;font:400 10px/1.2 Arial,'Microsoft YaHei',sans-serif;color:#B9C1C9;background:transparent;border-radius:4px}
.placement-label .map-main-card-tools button:hover,.placement-label .map-main-card-tools button:focus-visible {color:#8E9AA6;background:#f5f7f9}
.placement-label .map-main-card-tools button>span {font-size:10px;line-height:1.2;white-space:nowrap}
.placement-label .map-main-card-tools button>svg {display:block;flex:0 0 12px;width:12px;height:12px;min-width:12px;max-width:12px;stroke-width:1.2;fill:none}
.placement-label .map-main-more svg {stroke:#C4CCD3;stroke-width:1.6}
.placement-label .map-main-more[aria-expanded=true] svg {stroke:#8DC49A}
.map-main-card-names {display:flex;flex-direction:column;align-items:flex-start;justify-content:center;align-self:stretch;gap:5px;min-width:0;padding-bottom:8px}
.map-main-card-names>.placement-zh {font-size:15px;line-height:1.4;font-weight:400;color:#626C77;overflow-wrap:anywhere}
.placement-label .map-main-card-names>small {display:block;font-size:12px;line-height:1.4;font-weight:400;color:#A0A9B3;overflow-wrap:anywhere}
.map-main-expanded .map-main-card-names {padding-top:8px;padding-bottom:4px}

/* First paint uses final measured geometry; visibility preserves layout measurement. */
html.map-booting body>header,html.map-booting body>main {visibility:hidden;pointer-events:none}

/* Compact business card; drag avoidance does not remove the locator circle/dot. */
.placement-feedback .placement-label {width:168px;min-height:100.8px;aspect-ratio:5/3;padding:8px 11px 10px;grid-template-rows:22px minmax(0,1fr);gap:5px}
.placement-feedback .placement-label.map-main-expanded {min-height:100.8px;grid-template-rows:22px auto auto;aspect-ratio:auto}
.map-main-card-names {gap:4px;padding-bottom:3px}
.map-main-card-names>.placement-zh {font-size:13px}
.placement-label .map-main-card-names>small {font-size:11px}
.placement-label .map-main-card-tools {height:24px;gap:3px;margin:-4px -5px 0 0}
.placement-label .map-main-card-tools button {font-size:9px;min-width:24px;height:24px;gap:4px;padding:3px}
.placement-label .map-main-card-tools button>span {font-size:9px}
.placement-label .map-main-card-tools button>svg {width:10px;height:10px;min-width:10px;max-width:10px;flex-basis:10px}
.placement-feedback.card-drag-hidden .placement-label,.placement-feedback.card-drag-hidden .placement-label * {visibility:hidden!important;pointer-events:none!important}
.placement-feedback.card-drag-hidden .placement-leader {visibility:hidden}

/* Compact name label: settings become available only after expanding. */
.placement-feedback .placement-label {width:168px;min-height:50px;aspect-ratio:auto;display:grid;grid-template-rows:auto;gap:5px;padding:7px 10px;border-radius:6px}
.placement-feedback .placement-label.map-main-expanded {min-height:50px;grid-template-rows:auto auto auto;padding-top:30px}
.placement-label .map-main-card-tools {position:absolute;top:3px;right:4px;height:24px;margin:0;gap:0}
.placement-label .map-main-card-names {padding:0 48px 0 0;gap:3px;justify-content:center;min-height:36px}
.placement-label.map-main-expanded .map-main-card-names {padding:0;min-height:0}
.map-main-card-names>.placement-zh {font-size:11px;font-weight:400;color:#626C77;line-height:1.35;opacity:1}
.placement-label .map-main-card-names>small {font-size:9px;font-weight:400;color:#929CA8;line-height:1.35;opacity:1}
.placement-label .map-main-card-names>small:lang(zh) {font-size:10px;color:#929CA8;opacity:1}
.map-main-card-footer {display:flex;justify-content:flex-end;align-items:center}
.map-main-card-footer .map-main-settings {display:grid;place-items:center;width:24px;height:24px;padding:6px;background:transparent;color:#B9C1C9;border-radius:4px}
.map-main-card-footer .map-main-settings svg {width:12px;height:12px;fill:none;stroke:currentColor;stroke-width:1.2;stroke-linecap:round;stroke-linejoin:round}
.map-main-card-footer .map-main-settings:hover {color:#8E9AA6;background:#f5f7f9}

/* Keep all utility controls anchored to the existing settings position. */
body>header>.preferences {display:flex;align-items:center;justify-content:flex-end;gap:14px;grid-column:2;grid-row:1}
body>header>.preferences>.sharing {display:contents;transform:none;padding:0}
body>header>.preferences button {flex:none;align-self:center}

/* Bottom navigation speaker; card manual visibility is independent of drag avoidance. */
.actions>#sound {position:absolute;top:50%;bottom:auto;right:0;left:auto;transform:translateY(-50%);display:flex;align-items:center;justify-content:center;width:44px;height:44px;padding:0;z-index:2}
#mapArea.map-cards-hidden .placement-label,#mapArea.map-cards-hidden .placement-label * {visibility:hidden!important;pointer-events:none!important}
#mapArea.map-cards-hidden .placement-leader {visibility:hidden}

/* A fixed top information band replaces radial card positioning. */
#word {display:none}
main {grid-template-rows:0 minmax(0,1fr) 0 var(--extra-gap) clamp(52px,9dvh,86px)}
.actions>#progress {position:absolute;left:0;top:calc(50% - 34px);right:auto;bottom:auto;transform:none;font-size:9px;line-height:12px;color:#96A8B6;white-space:nowrap;pointer-events:none}
.placement-feedback {position:fixed}
.placement-feedback .placement-leader {display:none!important}
.placement-feedback .map-card-connector {position:absolute;left:0;top:0;width:1px;height:1px;overflow:visible;pointer-events:none!important}
.map-card-connector path {fill:none;stroke:#B7C0C8;stroke-width:.7;stroke-linecap:round;stroke-linejoin:round;vector-effect:non-scaling-stroke}
.placement-feedback.card-drag-hidden .map-card-connector,#mapArea.map-cards-hidden .map-card-connector {visibility:hidden}

/* Readable progress, separated from the region label by 24px. */
#regionLabel {line-height:20px}
.actions>#progress {top:auto;bottom:calc(50% + 34px);left:0;transform:none;font-size:18px;line-height:22px;color:#A8B6C4;opacity:1}
/* Cards and their connectors switch immediately; success-shrink is unchanged. */
.placement-feedback,.placement-feedback .placement-label,.placement-feedback .placement-label *,.placement-feedback .map-card-connector,.placement-feedback .map-card-connector * {transition:none!important;animation:none!important}
.map-card-connector path {stroke:#D0D8E0;stroke-width:.5;opacity:1}

/* Shared 44px footer row, with the hit-area edge 8px from the viewport. */
:root {--bottom:8px;--recent-country:#E5484D}
main {grid-template-rows:0 minmax(0,1fr) 0 var(--extra-gap) 44px}
.actions {height:44px;min-height:44px;align-items:center}
.right-column>.map-carousel {align-self:center}
.right-column {transform:translateX(-20px)}
.actions>:is(#box,#reset,#help) {display:grid;place-items:center;flex:0 0 44px;width:44px;height:44px;padding:0}
.actions>:is(#box,#reset,#help)>svg {width:clamp(18.2px,2.52dvh,23.1px);height:clamp(18.2px,2.52dvh,23.1px)}
#mapFrame {transform:translateY(calc(-50% + 10px));width:calc(100% - 12px)}
.brand {font-size:14px;line-height:20px;min-height:44px;display:inline-flex;align-items:flex-start}
#region {font-size:10.8px;min-height:44px}
#regionLabel {line-height:16px}
.actions>#progress {font-size:10.8px;line-height:14px;bottom:calc(50% + 32px);color:#A8B6C4}
.placement-feedback .placement-label {width:218px}
.map-main-card-names>.placement-zh {font-weight:500;color:#626C77}
#map path.target,#map path.hover,#map path.browse-current {fill:#82C99A}
#map path.done,#map path.browse-previous {fill:#A9BDC9}
#map path.done.recent {fill:#E5484D}
#lens {border-color:#82C99A}
#lens path {fill:#82C99A;stroke:#82C99A}

/* Browsing highlights only its current country; completion state is untouched. */
#map path.browse-current {fill:#E5484D}
#map path.browse-previous {fill:#A9BDC9}
.tiny-country-dot.browse-dot {width:3px;height:3px}
.placement-feedback.browse-feedback .placement-dot {left:-1.5px;top:-1.5px;width:3px;height:3px}
.placement-feedback.browse-feedback.tiny-country .placement-circle {display:block;border-color:#AAB3BA}
/* Move map content, not its navigation. Screen-CTM-based hit testing follows it. */
#mapArea {overflow:visible}
#mapFrame {left:40px}
#region {font-size:13px}
#regionLabel {line-height:18px}
.actions>#progress {font-size:13px;line-height:16px;bottom:calc(50% + 33px)}

/* Additional +80px: world content is now offset 120px; footer remains anchored. */
#mapFrame {left:120px}
/* Carousel uses fixed A/B/C rows; puzzle slots are preserved independently. */
#tray.carousel-tray {display:grid!important;grid-template-rows:repeat(3,minmax(0,1fr));align-self:stretch!important;height:100%!important;transform:none!important;gap:0!important}
#tray.carousel-tray>.slot {height:auto!important;margin:0!important;display:grid;place-items:center;min-height:0}
#tray.carousel-tray .tile {cursor:default}
#tray.carousel-tray .country-drawing {cursor:default}
#tray.carousel-tray [data-carousel-role=current] .country-shape {fill:#8B8993;stroke:#8B8993}
#tray.carousel-tray [data-carousel-role=current] .country-card-names strong {font-weight:400;color:#8B8993}
#tray.carousel-tray [data-carousel-role=previous] .tile {opacity:.55}
#tray.carousel-tray>.carousel-empty {visibility:hidden}

/* Align the reset control to the rendered world, not to its unshifted grid column. */
.placement-feedback .placement-label {width:226px}
.actions>:is(#box,#reset,#help,#sound) {position:absolute;top:50%;bottom:auto;right:auto;transform:translate(-50%,-50%);width:44px;height:44px;margin:0}
