:root{--ink:#183c32;--muted:#63786d;--paper:#f7f6ee;--line:#d1d9c9;--accent:#ac5c3f;--gold:#b18a49;--serif:"Noto Serif SC","Songti SC","STSong","SimSun",serif;--sans:-apple-system,BlinkMacSystemFont,"Segoe UI","Microsoft YaHei",sans-serif;color-scheme:light}*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden}body{font:14px/1.7 var(--sans);color:var(--ink);background:#e6e9da}button,a,input{-webkit-tap-highlight-color:transparent}button,a{touch-action:manipulation}button{font:inherit;color:inherit;cursor:pointer;border:0;background:none}button:disabled{opacity:.45;cursor:default}button:focus-visible,a:focus-visible,input:focus-visible,svg:focus-visible{outline:2px solid var(--accent);outline-offset:4px}a{color:inherit;text-decoration:none}button,a{transition:background .18s,color .18s,opacity .18s}button:hover:not(:disabled){color:#a35138}[hidden]{display:none!important}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}.skip-link{position:fixed;top:-80px;left:20px;background:var(--paper);z-index:100;padding:12px}.skip-link:focus{top:8px}#terrain,.fallback-map{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}.map-shade{position:absolute;inset:0;pointer-events:none;background:linear-gradient(90deg,rgba(238,240,222,.83),rgba(238,240,222,0) 55%);transition:opacity .5s}.book-header{position:absolute;z-index:10;top:0;left:0;right:0;height:88px;padding:0 40px;display:flex;align-items:center;gap:24px;background:linear-gradient(#f2f2e9e8,#f2f2e930,transparent)}.brand{display:flex;align-items:center;gap:13px}.brand strong{font:600 24px var(--serif);letter-spacing:5px}.seal{width:30px;height:42px;display:flex;flex-direction:column;justify-content:center;align-items:center;background:#a55038;color:#fff9ed;font:14px/1.18 var(--serif);border:1px solid #bd7c5e;box-shadow:inset 0 0 0 2px #a55038,inset 0 0 0 3px #d5a38b}.book-kind{font-size:12px;letter-spacing:2px;color:var(--muted);padding-left:22px;border-left:1px solid #acb9a799}.book-header nav{margin-left:auto;display:flex;gap:25px;align-items:center;font-size:12px}.book-header nav button,.book-header nav a{min-height:44px;display:flex;align-items:center;gap:10px}.book-header nav span{opacity:.6}.cover{position:absolute;z-index:3;left:8.5%;top:50%;transform:translateY(-46%);max-width:500px}.eyebrow{font-size:10px;line-height:1.6;letter-spacing:3px;text-transform:uppercase;color:var(--muted);margin:0}.cover>.eyebrow{display:flex;align-items:center;gap:17px;margin-bottom:30px;font-size:12px}.cover>.eyebrow i{width:35px;height:1px;background:#869a83}.cover h1{font:500 clamp(56px,6.5vw,104px)/1.2 var(--serif);letter-spacing:7px;margin:0 0 10px}.cover-question{font:400 26px/1.6 var(--serif);letter-spacing:4px;margin:0 0 27px}.cover-intro{font-size:14px;line-height:2.1;letter-spacing:1px;color:#4a6456;margin:0 0 30px}.cover-actions{display:flex;align-items:center;gap:22px}.primary{display:inline-flex;align-items:center;justify-content:space-between;gap:25px;background:var(--ink);color:#fffcf0;border-radius:3px;min-height:49px;padding:12px 22px;font-size:13px;font-weight:500;letter-spacing:1px}.primary:hover:not(:disabled){background:#285846;color:white}.primary span{font-size:19px;font-weight:300}.text-button{font-size:12px;min-height:44px;padding:8px 0;color:var(--muted)}.cover-meta{display:flex;align-items:center;gap:13px;margin-top:30px;color:#758274;font-size:10px;letter-spacing:1px}.cover-meta i{width:2px;height:2px;border-radius:50%;background:#83937d}.map-controls{position:absolute;z-index:8;top:110px;right:30px;display:flex;border:1px solid #c9d1bd99;background:#f7f7eee8;border-radius:4px;box-shadow:0 3px 12px #243c2410;overflow:hidden}.map-controls button{min-height:42px;min-width:59px;padding:8px 13px;font-size:11px}.map-controls button+button{border-left:1px solid #d9ddcf}.map-controls button[aria-pressed=true]{background:#dfe8d6}.map-credit{position:absolute;z-index:8;bottom:14px;left:40px;right:30px;display:flex;justify-content:space-between;font-size:10px;color:#617260;pointer-events:none}.map-credit span{background:#f2f2e6b8;padding:1px 5px;border-radius:2px}.map-credit button{pointer-events:auto;font-size:10px;background:#f7f7ecca;min-height:28px;padding:2px 8px;border-radius:2px}.map-status{position:absolute;z-index:8;top:103px;left:50%;transform:translateX(-50%);font-size:11px;padding:7px 13px;background:#fbf8eddf;border:1px solid #d8decb;border-radius:3px}.map-status.error{color:#965238}.map-status:empty{display:none}.chapter-card{position:absolute;z-index:5;left:40px;top:50%;transform:translateY(-47%);width:370px;padding:30px;background:#f8f8eeeF;border:1px solid #fff9;box-shadow:0 12px 46px #2d473714;border-radius:5px;backdrop-filter:blur(14px)}.chapter-top{display:flex;align-items:center;justify-content:space-between}.chapter-top>span:last-child{font:11px/1.5 var(--sans);font-variant-numeric:tabular-nums;color:#6e816e;letter-spacing:2px}.chapter-progress{display:flex;gap:5px;margin:16px 0 27px}.chapter-progress button{height:17px;flex:1;padding:7px 0;position:relative}.chapter-progress button:after{content:"";display:block;height:2px;background:#cfd8c9}.chapter-progress button[aria-current=step]:after{background:var(--accent)}.chapter-progress button.visited:after{background:#718d77}.chapter-card h1{font:500 29px/1.5 var(--serif);letter-spacing:1px;margin:0 0 18px}.chapter-body{font-size:13px;line-height:2;color:#4f6658;margin:0 0 20px}.chapter-hint{font-size:12px;padding:13px 0 13px 15px;border-left:2px solid #b59660;color:#59715f;margin:0 0 20px;background:linear-gradient(90deg,#edeeddb0,transparent)}.chapter-pager{display:flex;align-items:center;justify-content:space-between;border-top:1px solid #dbe0d0;padding-top:17px;margin-top:20px}.chapter-pager .primary{min-height:43px;padding:9px 18px;font-size:12px}.chapter-pager .text-button{font-size:11px}.chapter-extra:empty{display:none}.chapter-extra{font-size:11px;color:#738171}.interaction-panel{position:absolute;z-index:6;right:30px;bottom:55px;width:min(650px,calc(100vw - 490px));padding:22px 25px;background:#f8f8eef2;backdrop-filter:blur(15px);border:1px solid #fff9;border-radius:5px;box-shadow:0 8px 35px #26412b16}.panel-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.panel-heading h2{font:500 18px/1.6 var(--serif);margin:4px 0 0;letter-spacing:1px}.small-button{border:1px solid #cdd6c3;min-height:38px;padding:7px 13px;border-radius:3px;font-size:11px;background:#f7f8ef;white-space:nowrap}.small-button:hover{background:#e8efdf}.profile-readout{display:flex;justify-content:space-between;align-items:center;min-height:32px;font-size:11px;color:#72826e;margin-top:9px}.profile-readout strong{color:#34583e;font-size:15px;font-weight:500;font-variant-numeric:tabular-nums}#profileChart{display:block;width:100%;height:150px;overflow:visible;touch-action:none}.panel-note{font-size:10px;line-height:1.8;color:#75816f;margin:9px 0 0}.profile-error{font-size:11px;color:#a45034}.river-panel{width:min(570px,calc(100vw - 490px))}#riverPosition{width:100%;margin:25px 0 5px;accent-color:#387a83;cursor:ew-resize;min-height:25px}.river-ends{display:flex;justify-content:space-between;font-size:10px;color:#607a72}.compare-options{display:flex;gap:10px;margin-top:12px}.compare-options button{flex:1;text-align:left;min-height:70px;padding:11px 12px;background:#eef0e3;border:1px solid #d9dfcf;border-radius:3px;font-size:12px}.compare-options button span{display:block;color:#98a68b;font-size:9px;letter-spacing:1px;margin-bottom:4px}.compare-options button[aria-pressed=true]{border-color:#53765b;background:#dfe7d5}.free-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}.map-label{color:#26472f;text-shadow:0 1px 0 #fff8e6,1px 0 0 #fff8e6,-1px 0 0 #fff8e6,0 -1px 0 #fff8e6;font:12px/1.4 var(--serif);letter-spacing:1px;pointer-events:none;white-space:nowrap}.map-label.mountain{font-size:15px;font-weight:500;letter-spacing:4px;color:#476043}.map-label.city:before{content:"";display:inline-block;width:4px;height:4px;border:1px solid #304f38;background:#faf8e7;border-radius:50%;margin-right:4px;vertical-align:2px}.map-label.water{color:#246c78}.profile-pin{width:23px;height:23px;border-radius:50%;background:#ae6545;color:#fff9e9;border:2px solid #fff3d8;text-align:center;font:11px/19px var(--sans);box-shadow:0 2px 6px #34402b40}.sample-pin{width:10px;height:10px;border-radius:50%;background:#a95035;border:2px solid #fff4d8;box-shadow:0 0 0 5px #a9503525}.river-pin{width:13px;height:13px;border:3px solid #fff7df;background:#286e7d;border-radius:50%;box-shadow:0 0 0 7px #286e7d22}.draw-prompt{position:absolute;z-index:12;top:110px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:20px;padding:10px 15px;border-radius:4px;background:#244c3e;color:#fff9e9;font-size:12px;box-shadow:0 4px 20px #244c3e20}.draw-prompt button{font-size:11px;color:#d1dfcf;border-left:1px solid #7b958780;padding-left:13px}.is-drawing .maplibregl-canvas-container{cursor:crosshair!important}.toast{position:fixed;z-index:40;left:50%;bottom:40px;transform:translate(-50%,15px);background:#244638f2;color:#fff9e9;font-size:12px;padding:10px 17px;border-radius:4px;opacity:0;pointer-events:none;transition:.2s}.toast.show{opacity:1;transform:translate(-50%,0)}dialog{color:var(--ink);background:#f8f7ef;border:1px solid #d6ddcb;border-radius:6px;padding:28px;max-width:530px;width:calc(100vw - 32px);max-height:85dvh;box-shadow:0 20px 100px #163d343d}dialog::backdrop{background:#233a3266;backdrop-filter:blur(4px)}.dialog-head{display:flex;align-items:center;justify-content:space-between}.dialog-head button{font-size:25px;width:36px;height:36px;color:#73826e}dialog h2{font:500 27px/1.6 var(--serif);letter-spacing:1px;margin:14px 0 22px}dialog p{font-size:12px;line-height:1.9;color:#5c705e}#contentsList{list-style:none;padding:0;margin:0 0 15px}#contentsList button{display:flex;text-align:left;gap:18px;align-items:center;border-bottom:1px solid #dae1d1;width:100%;padding:17px 0;font-size:14px}#contentsList button span{font-size:11px;color:#a48a5e}#contentsList button[aria-current=step]{color:#a35439}#sourceList{padding-left:19px;font-size:12px}#sourceList li{margin:13px 0}#sourceList a{text-decoration:underline;text-underline-offset:4px}#sourceList small{display:block;font-size:10px;color:#7c8976}#dataNotes{border-block:1px solid #dae1d1;margin:18px 0;padding:5px 0}#savedPreview{display:block;width:100%;border:1px solid #d9decc}#saveDialog .primary{width:100%;justify-content:center;margin-top:10px}#shareImage{width:100%;margin-top:10px}.no-script{position:fixed;inset:40%;z-index:20;background:#faf8e9;padding:25px}.reading-mode .map-shade{opacity:.35}.fallback-mode .map-controls{display:none}.fallback-mode .map-status{max-width:80%;text-align:center}.fallback-map{opacity:.9}.maplibregl-ctrl-bottom-left,.maplibregl-ctrl-bottom-right{bottom:37px!important}.maplibregl-ctrl-scale{background:#f8f7eac7!important;border-color:#49694b!important;color:#34533c!important;font-size:9px!important}.maplibregl-ctrl-attrib{display:none}
@media(min-width:1500px){.chapter-card{left:60px;width:400px;padding:35px}.interaction-panel{right:50px;width:690px}.cover{left:10%}}
@media(max-height:760px) and (min-width:821px){.chapter-card{top:105px;transform:none;padding:22px 27px;max-height:calc(100dvh - 160px);overflow:auto}.chapter-card h1{font-size:26px}.chapter-progress{margin-bottom:15px}.chapter-body{margin-bottom:12px}.cover>.eyebrow{margin-bottom:17px}.cover-intro{margin-bottom:19px}.cover h1{font-size:70px}}
@media(max-width:1050px) and (min-width:821px){.chapter-card{width:310px;left:25px;padding:24px}.interaction-panel{width:calc(100vw - 390px);right:25px}.chapter-card h1{font-size:25px}.cover{left:6%}.book-header{padding-inline:25px}}
@media(max-width:820px){.book-header{height:66px;padding:0 18px;gap:10px;background:linear-gradient(#f5f4e9ef,#f5f4e94d,transparent)}.brand{gap:9px}.brand strong{font-size:20px;letter-spacing:3px}.seal{width:24px;height:34px;font-size:11px}.book-kind{display:none}.book-header nav{gap:19px;font-size:11px}.book-header nav button,.book-header nav a{min-height:44px;gap:6px}.book-header nav span{font-size:10px}.cover{left:28px;top:auto;bottom:max(72px,env(safe-area-inset-bottom));transform:none;right:25px;max-width:none}.cover>.eyebrow{font-size:10px;letter-spacing:2px;margin-bottom:19px}.cover h1{font-size:61px;letter-spacing:5px}.cover-question{font-size:21px;letter-spacing:2px;margin-bottom:19px}.cover-intro{font-size:12px;line-height:1.9;margin-bottom:24px}.cover-meta{margin-top:21px;font-size:9px;gap:10px}.cover-actions{gap:20px}.cover-actions .primary{min-height:47px;padding-inline:20px;font-size:12px}.map-shade{background:linear-gradient(0deg,#eef0e4f5 2%,#eef0e4c4 32%,#eef0e427 60%,transparent 80%)}.map-controls{top:77px;right:16px;border-color:#c9d1bd77}.map-controls button{font-size:10px;min-width:51px;min-height:38px;padding:7px 10px}.map-credit{bottom:max(8px,env(safe-area-inset-bottom));left:18px;right:16px;font-size:8px;align-items:end}.map-credit button{font-size:9px}.map-status{top:76px;font-size:10px;left:18px;transform:none;max-width:calc(100vw - 160px);padding:6px 9px}.chapter-card{left:0;top:auto;bottom:0;transform:none;width:100%;border-radius:15px 15px 0 0;padding:19px 22px calc(16px + env(safe-area-inset-bottom));box-shadow:0 -8px 35px #354e3315;max-height:51dvh;overflow:auto;background:#f8f8f0f7;z-index:7}.chapter-top .eyebrow{font-size:9px}.chapter-top>span:last-child{font-size:10px}.chapter-progress{margin:7px 0 8px}.chapter-card h1{font-size:24px;line-height:1.45;margin-bottom:9px}.chapter-body{font-size:12px;line-height:1.85;margin-bottom:10px}.chapter-hint{font-size:11px;padding:7px 0 7px 10px;margin-bottom:9px}.chapter-pager{padding-top:10px;margin-top:12px}.chapter-pager .primary{min-height:42px;font-size:11px;padding:8px 16px}.chapter-extra{font-size:10px}.reading-mode .map-credit{bottom:var(--card-bottom,360px);left:14px;right:14px;margin-bottom:8px}.reading-mode .map-credit span{display:none}.reading-mode .map-shade{opacity:0}.interaction-panel{z-index:8;right:12px;left:12px;bottom:calc(var(--card-bottom,360px) + 12px);width:auto!important;padding:12px 15px;border-radius:5px;max-height:32dvh;overflow:auto;box-shadow:0 5px 23px #32492d16}.panel-heading h2{font-size:14px;line-height:1.5;margin-top:0}.panel-heading .eyebrow{font-size:8px;letter-spacing:2px}.small-button{min-height:34px;padding:6px 10px;font-size:10px}.profile-readout{min-height:22px;font-size:9px;margin-top:4px}.profile-readout strong{font-size:12px}#profileChart{height:103px}.panel-note{font-size:9px;line-height:1.6;margin-top:5px}.profile-panel .panel-note{display:none}.river-panel .panel-heading h2{font-size:16px}#riverPosition{margin-top:11px;margin-bottom:0}.river-ends{font-size:9px}.compare-options{gap:7px;margin-top:8px}.compare-options button{padding:8px 9px;min-height:50px;font-size:11px}.compare-options button span{font-size:8px;margin-bottom:1px}.free-actions{gap:6px;margin-top:7px}.interaction-panel>.eyebrow{font-size:8px;letter-spacing:2px}.draw-prompt{top:123px;left:12px;right:12px;transform:none;justify-content:space-between;font-size:11px;padding:9px 12px}.toast{bottom:calc(var(--card-bottom,0px) + 25px);font-size:11px;max-width:90vw;white-space:normal;width:max-content}.map-label{font-size:10px}.map-label.mountain{font-size:12px;letter-spacing:2px}.reading-mode.has-panel .chapter-hint{display:none}.reading-mode.has-panel .chapter-extra{display:none}.reading-mode.has-panel .chapter-body{font-size:11px;line-height:1.7}.reading-mode.has-panel .chapter-card{padding-top:14px}.reading-mode.has-panel .chapter-progress{margin:3px 0 6px}.reading-mode.has-panel .chapter-card h1{font-size:22px;margin-bottom:7px}.reading-mode.has-panel .chapter-pager{margin-top:9px;padding-top:8px}.is-drawing .interaction-panel{display:none!important}dialog{padding:22px;max-height:85dvh}dialog h2{font-size:24px}.maplibregl-ctrl-bottom-left{bottom:var(--map-scale-bottom,37px))!important}}
@media(max-width:370px){.cover{left:23px;bottom:64px}.cover h1{font-size:54px}.cover-question{font-size:19px}.chapter-card{padding-inline:18px}.chapter-card h1{font-size:22px}.book-header nav{gap:14px}.book-header{padding-inline:14px}.cover-intro{font-size:11px}.interaction-panel{padding:10px 12px}}
@media(max-height:700px) and (max-width:820px){.cover h1{font-size:48px}.cover>.eyebrow{margin-bottom:12px}.cover-question{font-size:18px;margin-bottom:12px}.cover-intro{font-size:11px;margin-bottom:16px}.cover-meta{margin-top:15px}.cover{bottom:58px}.chapter-card{max-height:49dvh}.reading-mode.has-panel .chapter-body{max-height:3.4em;overflow:auto}#profileChart{height:86px}.interaction-panel{max-height:29dvh}.panel-note{display:none}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{transition:none!important;scroll-behavior:auto!important}}
.profile-buttons{display:flex;gap:7px}.chapter-sources{display:none}@media(max-width:820px){.reading-mode .map-credit{display:none}.chapter-sources{display:block;font-size:9px;color:#78876e;min-height:24px;margin-left:auto;margin-right:17px}.maplibregl-ctrl-bottom-left{bottom:calc(var(--card-bottom,0px) + 24px)!important}.has-panel .maplibregl-ctrl-scale{display:none}.profile-buttons .small-button{font-size:9px;padding-inline:8px}.cover-mode .maplibregl-ctrl-scale{display:none}}
.river-ends{position:relative;display:block;height:18px}.river-ends span{position:absolute;transform:translateX(-50%);white-space:nowrap}
@media(max-width:820px){#profilePanel .panel-note{display:block!important}}
@media(max-height:550px) and (min-width:821px) and (max-width:1100px){.book-header{height:56px;padding-inline:16px}.brand strong{font-size:20px}.seal{height:32px;width:23px;font-size:11px}.book-kind{font-size:9px;letter-spacing:1px}.book-header nav{font-size:10px;gap:18px}.chapter-card{left:12px;top:68px;bottom:auto;transform:none;width:245px;max-height:calc(100dvh - 82px);padding:16px;overflow:auto}.chapter-card h1{font-size:21px;margin-bottom:8px}.chapter-progress{margin:4px 0 9px}.chapter-body{font-size:11px;line-height:1.65;margin-bottom:8px}.chapter-hint{display:none}.chapter-pager{padding-top:8px;margin-top:10px}.chapter-pager .primary{min-height:36px;padding:6px 12px;font-size:10px}.chapter-pager .text-button{font-size:10px;min-height:36px}.chapter-top .eyebrow{font-size:8px}.chapter-top>span:last-child{font-size:9px}.chapter-sources{display:block;font-size:9px;margin-left:auto;margin-right:8px}.interaction-panel{right:12px;bottom:12px;width:calc(100vw - 293px)!important;max-height:174px;padding:10px 14px;overflow:auto}.panel-heading .eyebrow{font-size:8px}.panel-heading h2{font-size:14px;margin:0}.profile-readout{font-size:9px;min-height:21px;margin-top:2px}.profile-readout strong{font-size:11px}#profileChart{height:77px}.panel-note{font-size:8px;margin-top:3px;line-height:1.4}.small-button{min-height:30px;padding:4px 9px;font-size:9px}.map-controls{top:65px;right:12px}.map-controls button{min-height:31px;font-size:9px;padding:5px 9px;min-width:48px}.reading-mode .map-credit{display:none}.maplibregl-ctrl-scale{display:none}.cover{left:45px;top:auto;bottom:45px;transform:none}.cover h1{font-size:49px;letter-spacing:4px}.cover>.eyebrow{margin-bottom:12px;font-size:10px}.cover-question{font-size:18px;margin-bottom:13px}.cover-intro{display:none}.cover-meta{margin-top:13px;font-size:9px}.cover .primary{min-height:41px;padding:8px 17px;font-size:11px}.cover-actions{gap:18px}.draw-prompt{top:67px;font-size:10px;padding:7px 11px}.toast{bottom:20px}.compare-options button{min-height:50px;padding:8px;font-size:10px}#riverPosition{margin-top:9px}.river-ends{height:14px;font-size:9px}}
.is-drawing .interaction-panel{display:none!important}
