/* A calm map-first surface; the existing project library remains a secondary view. */
.planner-app{--forest:#41372a;--lime:#eee2cd;--cream:#f5f0e6;--ink:#30291f;--line:#d9cfbd;--orange:#c75a1a}
.planner-app .workspace{height:100dvh;overflow:hidden}.planner-app .app-header{height:58px;background:#faf7ef;border-bottom:1px solid var(--line);padding:0 18px;gap:14px}.planner-app .brand-mark{background:#382b1d;color:#f6b35e}.planner-app .app-main{height:calc(100dvh - 58px);display:block}.planner-app .map-workspace{height:100%;width:100%;position:relative}.planner-app #map{height:100%;width:100%;position:absolute;inset:0}
.planner-app .project-sidebar{position:absolute;left:0;top:58px;bottom:0;width:320px;z-index:1400;display:none;background:#faf7ef}.planner-app.menu-open .project-sidebar{display:block}.planner-app #menu,.planner-app #close-menu{display:block}.planner-app .map-topbar{top:14px;left:auto;right:62px;width:auto;max-width:calc(100% - 440px);gap:8px}.planner-app #setup,.planner-app .map-tools,.planner-app .map-legend{display:none}.planner-app .leaflet-top.leaflet-left{margin-top:0}.planner-app .leaflet-top.leaflet-right{margin-top:12px}.planner-app .project-crumb{flex:1}.planner-app .header-actions{margin-left:auto}.planner-app .header-actions .admin-button{display:none}
#planner-panel{position:absolute;z-index:1000;left:16px;top:14px;bottom:174px;width:342px;background:#faf7ef;border:1px solid #d5c7b2;border-radius:14px;box-shadow:0 6px 30px #211b2030;display:flex;flex-direction:column;overflow:hidden}#planner-panel.collapsed{bottom:auto}#planner-panel.collapsed .planner-body{display:none}.planner-heading{padding:17px 18px 10px;display:flex;justify-content:space-between;align-items:center}.planner-heading small{font-size:9px;font-weight:800;letter-spacing:.15em;color:#8a7150}.planner-heading h1{font-family:Georgia,serif;font-size:30px;font-weight:normal;margin:3px 0 0;line-height:1.1}.planner-heading button,#profile-toggle{border:1px solid var(--line);background:transparent;border-radius:7px;width:32px;height:32px;font-size:20px;cursor:pointer}.planner-body{overflow:auto;padding:8px 18px 18px;overscroll-behavior:contain;scrollbar-width:thin}
.planner-body button,.planner-body input,.planner-body select{font:inherit;font-size:12px}.planner-body button{border:1px solid var(--line);background:#fffaf2;border-radius:7px;min-height:36px;padding:7px 10px;cursor:pointer}.planner-body button:hover{border-color:#a18458;background:#f0e7d7}.planner-body button:disabled{opacity:.45;cursor:default}.planner-body input:not([type=range]),.planner-body select{display:block;border:1px solid var(--line);border-radius:7px;background:#fffaf2;min-height:38px;width:100%;padding:9px;box-sizing:border-box}.planner-body label{display:block;font-size:12px;font-weight:600;margin:12px 0 6px}.planner-body label small{float:right;color:#87785e;font-weight:400}.planner-body output{float:right}.planner-body input[type=range]{display:block;width:100%;accent-color:#c15d24;margin:8px 0 12px}.planner-body details{border:1px solid var(--line);border-radius:8px;padding:10px 11px;margin-top:10px}.planner-body summary{font-size:12px;cursor:pointer;font-weight:600}.planner-body summary span{float:right;font-size:10px;font-weight:400;color:#7b6c55}.planner-body details p{font-size:11px;line-height:1.5;color:#776952}.planner-body .control-note{font-size:10px;line-height:1.5;color:#7b6c56;margin:7px 0}.planner-body .planner-primary{display:block;width:100%;background:#bc5118;color:white;border-color:#bc5118;font-size:14px;font-weight:700;min-height:44px;margin-top:15px}.planner-body .planner-primary:hover{background:#9f4210}
#place-search{display:flex;gap:6px}#place-query{min-width:0}#place-search button{flex-shrink:0}#place-results{font-size:10px;color:#796a56}#place-results button{display:block;width:100%;text-align:left;margin-top:4px;font-size:11px}.planner-body .trail-name-label{font-size:10px;color:#877459;margin-top:15px}#planner-name{font-family:Georgia,serif;font-size:20px}.save-note{display:block;font-size:9px;color:#8a785b;margin:5px 0 11px}.planner-actions{display:flex;gap:5px;flex-wrap:wrap}.planner-actions button{font-size:10px;flex:1;white-space:nowrap}.planner-divider{border-top:1px solid var(--line);margin:15px -18px 8px}.planner-point{display:flex;gap:9px;align-items:center;padding:8px 0}.planner-point>span{width:25px;height:25px;border-radius:50%;display:grid;place-items:center;background:#e9e1d4;color:#706047;font-weight:700;font-size:11px}.planner-point.placed>span{background:#466846;color:white}.planner-point div{flex:1}.planner-point b{display:block;font-size:12px}.planner-point small{font-size:9px;color:#847359}.planner-point button{border:none;min-height:30px;font-size:16px}.planner-tools{display:grid;grid-template-columns:repeat(2,1fr);gap:5px;margin:8px 0}.planner-tools .on{border-color:#bc5118;background:#f6e5ce}.planner-history{display:flex;justify-content:space-between;gap:3px}.planner-history button{border:0;background:transparent;padding:5px;font-size:10px}.trail-styles{display:flex;margin-top:14px}.trail-styles button{border-radius:0;flex:1}.trail-styles button:first-child{border-radius:6px 0 0 6px}.trail-styles button:last-child{border-radius:0 6px 6px 0}.trail-styles button.on{background:#493522;color:#fff9ed;border-color:#493522}#style-summary{font-size:11px;color:#7a684f;line-height:1.5;margin:8px 0}#planner-status{font-size:11px;line-height:1.55;color:#536347}#planner-status.error{color:#9c421b;background:#f8e8d8;border-left:3px solid #b25122;padding:9px}#planner-cancel{width:100%;margin-top:6px}
#planner-result{border-top:1px solid var(--line);padding-top:12px;margin-top:14px}.route-verdict{font-size:11px;color:#47613c;font-weight:600}.route-verdict.stale{color:#a15a22}.planner-metrics{display:grid;grid-template-columns:repeat(2,1fr);gap:14px;margin:14px 0}.planner-metrics b{display:block;font-family:Georgia,serif;font-size:25px;font-weight:400}.planner-metrics small{font-size:10px;color:#7f715b}.planner-admin{display:block;text-decoration:none;font-size:10px;color:#7f715b;margin-top:15px}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
#planner-profile{position:absolute;left:0;right:0;bottom:0;z-index:1000;background:#faf7ef;border-top:1px solid #cfc4b1;height:158px}#planner-profile.collapsed{height:40px}#planner-profile.collapsed #profile-chart{display:none}.profile-heading{height:39px;padding:5px 20px;display:flex;gap:18px;align-items:center;font-size:12px}.profile-heading span{font-size:11px;color:#7b6d56}.profile-heading button{margin-left:auto;width:27px;height:27px}#profile-chart svg{width:100%;height:116px;display:block}#profile-chart text{fill:#7c705c;font-family:Arial,sans-serif;font-size:10px}#planner-map-hint{position:absolute;right:62px;top:65px;z-index:900;padding:8px 13px;border-radius:7px;background:#faf7efed;font-size:11px;color:#64533b;max-width:calc(100% - 440px);pointer-events:none}
.planner-app .floating-panel{z-index:1300;max-height:calc(100% - 50px);overflow:auto}.planner-app .results-panel{z-index:1300}.planner-app .portfolio-hero{grid-template-columns:1fr;min-height:0}.planner-app .hero-copy-block{padding:30px}.planner-app .hero-copy-block h1{font-size:40px}.planner-app .portfolio-header .brand-mark{color:#f4b769}.planner-app .project-card-map{display:none}.planner-app .project-card{grid-template-columns:1fr}
@media(max-width:750px){
  .planner-app .app-header{height:52px;padding:0 10px;gap:9px}.planner-app .app-main{height:calc(100dvh - 52px)}.planner-app .brand{font-size:12px}.planner-app .brand-mark{width:26px;height:26px}.planner-app .project-crumb{display:flex;flex:0;margin-left:auto;gap:0}.planner-app .project-crumb>b,.planner-app .project-crumb>i,.planner-app #project-status-button,.planner-app .header-actions{display:none}.planner-app .project-crumb button{font-size:11px}.planner-app .project-sidebar{top:52px;width:min(320px,90vw)}
  #planner-panel{left:9px;top:10px;width:min(320px,calc(100% - 58px));bottom:auto;max-height:calc(100% - 155px)}.planner-heading{padding:12px 14px 8px}.planner-heading h1{font-size:25px}.planner-heading small{font-size:8px}.planner-body{padding:5px 14px 15px}.planner-body button{min-height:40px}.planner-tools{grid-template-columns:repeat(2,1fr)}.planner-history button{min-height:36px}
  .planner-app .map-topbar{top:10px;left:auto;right:10px;max-width:40px}.planner-app .map-mode{display:none}.planner-app .leaflet-top.leaflet-right{margin-top:12px;margin-right:0}#planner-map-hint{top:auto;bottom:151px;left:9px;right:9px;max-width:none;text-align:center;font-size:10px;box-shadow:0 1px 6px #0002}#planner-profile{height:140px}.profile-heading{padding:4px 10px;gap:10px;font-size:11px}.profile-heading span{font-size:10px}#profile-chart svg{height:100px}.planner-app .floating-panel{left:9px;right:9px;top:10px;width:auto;max-height:calc(100% - 20px)}.planner-app .results-panel{left:9px;right:9px;bottom:10px;width:auto;max-height:80%}
}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
/* Keep the primary task and cancellation in view while the detail panel scrolls. */
#planner-project-file{display:none}
@media(max-width:750px){#planner-panel.collapsed .planner-heading{padding:8px 14px}#planner-panel.collapsed .planner-heading small{display:none}#planner-panel.collapsed .planner-heading h1{font-size:20px}}
#planner-panel .planner-body{min-height:0;flex:1}
.planner-footer{flex-shrink:0;padding:10px 18px 12px;border-top:1px solid var(--line);background:#faf7ef}
.planner-footer button{font:inherit;font-size:12px;min-height:40px;border:1px solid var(--line);border-radius:7px;padding:8px 10px;background:#fffaf2;cursor:pointer;width:100%}
.planner-footer .planner-primary{background:#bc5118;color:white;border-color:#bc5118;font-size:14px;font-weight:700;min-height:44px}
.planner-footer button:disabled{opacity:.5;cursor:default}.planner-footer #planner-status{margin:7px 0 0;max-height:105px;overflow:auto}
#planner-suggestion{margin-top:8px}#planner-save-state.error{color:#a13c22;font-weight:700}
#planner-panel.collapsed .planner-footer{display:none}#planner-panel.collapsed.ready .planner-footer{display:block}#planner-panel.collapsed .planner-footer #planner-status{display:none}
#planner-panel.busy #planner-find{display:none}.map-workspace:not(.has-profile) #planner-panel{bottom:16px}
#planner-panel.collapsed{bottom:auto!important}.project-files .planner-actions{margin-top:8px}.project-files p{margin-bottom:0}
@media(max-width:750px){.planner-footer{padding:8px 14px 10px}.planner-footer #planner-status{max-height:85px;font-size:11px}.map-workspace:not(.has-profile) #planner-panel{bottom:auto;max-height:calc(100% - 115px)}.map-workspace:not(.has-profile) #planner-map-hint{bottom:25px}.planner-body input:not([type=range]),.planner-body select{font-size:16px}}
