/* Map-first mobile shell: 52px header, ~102px dock, no counter rail. */
html,body{height:100%;overflow:hidden;overscroll-behavior:none}
.app.compact-app{position:fixed!important;top:0;left:50%;transform:translateX(-50%);width:100%;max-width:1440px;min-height:0!important;--map-top:calc(env(safe-area-inset-top) + 52px)}
.compact-app .top{padding:calc(env(safe-area-inset-top) + 5px) 10px 0!important;height:calc(env(safe-area-inset-top) + 51px);background:#181818!important}
.compact-app .top-row{height:39px;gap:7px}.compact-app .wordmark-logo{width:90px!important;max-height:26px!important}
.compact-app .event{font-size:10px!important;text-align:left}.compact-app .top-sub{display:none!important}
.compact-app .top-row>.round,.compact-app #progress{position:static!important;display:grid!important;place-items:center!important;width:36px!important;min-width:36px!important;height:36px!important;min-height:36px!important;padding:0!important;border:0!important;background:transparent!important;border-radius:50%!important;color:#e6e8dc;font-size:17px!important}
.compact-app #progressTrack{margin:4px 0 0!important;gap:3px!important}.compact-app #progressTrack span{height:2px!important}
.app.compact-app .map-layer{inset:var(--map-top) 0 calc(var(--dock-height) + 1px) 0!important;border-radius:0!important;border:0!important;display:flex!important;padding:0!important}
.compact-app .map-layer>.course-svg{height:100%!important;min-height:0!important;flex:1!important}
.compact-app .map-view-switch{left:9px!important;right:auto!important;top:8px!important;height:30px!important;gap:2px!important;padding:2px!important;border:1px solid #81818144!important;border-radius:20px!important;background:#1e1e1eef!important;z-index:9}
.compact-app .map-view-switch button{height:26px!important;min-height:26px!important;min-width:64px!important;padding:3px 11px!important;border:0!important;border-radius:17px!important;font-size:10px!important;background:transparent!important;flex:none!important}
.compact-app .map-view-switch button[aria-pressed=true]{background:#d2c895!important}
.compact-app .map-toolbar{display:none!important}
.phase-legend{position:absolute;top:42px;left:11px;z-index:8;font-size:8px;line-height:1.2;color:#b5c7b7;background:#242424d9;padding:3px 6px;border-radius:6px;pointer-events:none}
.approach-count rect{fill:#2f2f2f;stroke:#9ad6c6;stroke-width:.7}.approach-count text{font:11px Arial,sans-serif;fill:#c2f3dc;paint-order:stroke;stroke:none}
.approach-plan{display:flex;gap:5px;margin:12px 0}.approach-plan>div{flex:1;min-width:0;padding:8px 5px;background:#222222;border:1px solid #9ad6c644;border-radius:8px}.approach-plan b,.approach-plan span,.approach-plan strong{display:block}.approach-plan b{font-size:14px;color:#b3e4cf}.approach-plan span{font-size:10px;margin-top:4px;color:#becabc}.approach-plan strong{font-size:12px;color:#efb18a;margin-top:4px}.model-error{color:#efb18a!important}.rhythm-calibration{margin:15px 0}.rhythm-calibration summary,.compact-app .sheet details>summary{font-size:12px;color:#d2c895;min-height:38px;padding:10px 0;cursor:pointer}
.compact-app .compact-map-tools{position:absolute;right:9px;bottom:9px;display:flex;gap:5px;z-index:9}
.compact-app .compact-map-tools>#rotate,.compact-app .compact-map-tools>#recenterMap{position:static!important;display:grid!important;place-items:center!important;width:34px!important;height:34px!important;min-height:34px!important;border:1px solid #7e7e7e44!important;border-radius:50%!important;background:#232323ef!important;color:#d2c895;padding:0!important}
.compact-app .map-layer>.zoom-actions{position:absolute!important;left:9px!important;bottom:9px!important;top:auto!important;right:auto!important;height:34px!important;padding:0!important;gap:0!important;border-radius:18px!important;border:1px solid #7e7e7e44!important;background:#232323ef!important;box-shadow:none!important}
.compact-app .map-layer>.zoom-actions button{width:34px!important;min-width:34px!important;height:32px!important;min-height:32px!important;border:0!important;background:transparent!important;font-size:19px!important}
.compact-app .map-layer>.zoom-actions output{font-size:9px!important;min-width:26px!important}
.app.compact-app .dock{position:absolute!important;left:0!important;right:0!important;top:auto!important;bottom:0!important;width:auto!important;max-width:none!important;max-height:none!important;margin:0!important;padding:4px 9px calc(env(safe-area-inset-bottom) + 6px)!important;border-radius:0!important;border:0!important;border-top:1px solid #7e7e7e44!important;background:#1b1b1b!important;overflow:visible!important}
.compact-app .dock>.dock-top,.compact-app .dock>.bottom-actions,.compact-app .dock>.stride-outcomes,.compact-app .dock>.walk-inline,.compact-app #details{display:none!important}
.compact-summary{display:grid;grid-template-columns:32px minmax(65px,1fr) auto 32px;align-items:center;gap:5px;min-height:40px}
.compact-summary>#prev,.compact-summary>#next{width:32px;height:36px;min-height:36px;display:grid;place-items:center;background:transparent;color:#e3e4d6;padding:0}
.compact-app .compact-summary>.segment{padding:0!important;text-align:left;min-height:36px!important;background:transparent}
.compact-app .compact-summary .segment strong{display:block;font-size:17px!important;line-height:1.2}.compact-app .compact-summary .segment small{font-size:9px!important;margin-top:1px;color:#b5c2b3}
#compactStats{background:transparent;padding:2px 3px;text-align:right;color:#e5dfbd;min-height:36px}
#compactStats b{display:block;font-size:13px;font-weight:600;line-height:1.2}#compactStats b small{font-size:9px;font-weight:400}#compactStats>span{display:block;font-size:10px;color:#a9bfae;margin-top:1px}
.compact-count-row{display:grid;grid-template-columns:minmax(0,1fr) 44px;gap:9px;align-items:center;min-height:52px}
.app.compact-app .compact-counters{position:static!important;inset:auto!important;width:100%!important;max-width:none!important;display:grid!important;grid-template-columns:1fr 1fr!important;gap:10px!important;align-items:center!important;margin:0!important;padding:0!important}
.compact-app .compact-counters .big-strides,.compact-app .compact-counters .walk-counter{position:relative!important;display:grid!important;grid-template-columns:34px minmax(30px,1fr) 34px!important;grid-template-rows:12px 36px!important;align-items:center!important;gap:0!important;min-height:48px!important;height:48px!important;width:100%!important;min-width:0!important;padding:0!important;margin:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important}
.compact-app .walk-counter:before{display:none!important}
.compact-app #bigStridesLabel,.compact-app #walkStepsLabel{position:static!important;display:block!important;grid-column:1/-1!important;grid-row:1!important;padding:0!important;margin:0!important;text-align:center!important;font-size:8px!important;line-height:12px!important;letter-spacing:.08em!important;color:#c6c9aa!important}
.compact-app #strideFloatPlus,.compact-app #walkStepsPlus{grid-column:3!important;grid-row:2!important}
.compact-app #strideFloatMinus,.compact-app #walkStepsMinus{grid-column:1!important;grid-row:2!important}
.compact-app .compact-counters .stride-float-btn,.compact-app .compact-counters #walkStepsPlus,.compact-app .compact-counters #walkStepsMinus{width:34px!important;height:36px!important;min-height:36px!important;padding:0!important;border:0!important;border-radius:50%!important;background:#ffffff05!important;font-size:22px!important;line-height:1!important;color:#d2c895}
.compact-app #strideCountEdit,.compact-app .compact-counters #walkStepsEdit{grid-column:2!important;grid-row:2!important;display:grid!important;place-items:center!important;gap:0!important;position:static!important;min-width:0!important;width:100%!important;min-height:36px!important;height:36px!important;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;color:#eef0e2}
.compact-app #strideCountEdit b,.compact-app #walkStepsValue{font-size:22px!important;line-height:1!important;font-weight:600!important;font-variant-numeric:tabular-nums}
.compact-app #bigStrides>small,.compact-app #walkStepsMeta{display:none!important}
.compact-app #doneNext{display:grid;place-items:center;width:42px;height:42px;min-height:42px;padding:0;border:0;border-radius:50%;background:#d2c895;color:#222222}
.compact-app #doneNext svg{width:23px;height:23px}
.compact-app .sheet{position:absolute!important;top:auto!important;left:0!important;right:0!important;bottom:0!important;width:auto!important;max-height:calc(var(--visible-height,100dvh) - 10px)!important;padding:10px 14px calc(env(safe-area-inset-bottom) + 16px)!important;border-radius:18px 18px 0 0!important;scroll-padding-top:60px;touch-action:pan-y}
.compact-app .sheet-head{top:-10px!important;padding-top:6px!important;margin-bottom:8px!important;background:#262626!important}.compact-app .sheet-head h2{font-size:17px!important}
.compact-app .sheet input,.compact-app .sheet select,.compact-app .sheet textarea{font-size:16px!important}
.compact-check-note{font-size:11px;color:#b6c6b7;margin:0 0 10px}.compact-checklist{display:grid;gap:4px}
.compact-check-row{display:grid;grid-template-columns:30px minmax(60px,1fr) 60px 60px;gap:7px;align-items:center;min-height:61px;padding:5px 0;border-bottom:1px solid #80808033}
.compact-check-row .tick{width:28px;height:32px;border-radius:8px}.compact-check-row .tick.yes{background:#d2c895;color:#212121}
.compact-check-row .check-leg{padding:4px 0;min-height:44px;text-align:left;background:transparent}.compact-check-row .check-leg b{display:block;font-size:14px}.compact-check-row .check-leg small{display:block;font-size:10px;color:#a9bdac;margin-top:3px}
.compact-check-row>[data-edit-strides],.compact-check-row>[data-edit-steps]{padding:5px 3px;min-height:47px;border:1px solid #80808044;border-radius:9px;background:#222222;color:#d6ddca}
.compact-check-row>[data-edit-strides] b,.compact-check-row>[data-edit-steps] b{display:block;font-size:18px;font-weight:500}.compact-check-row>[data-edit-strides] small,.compact-check-row>[data-edit-steps] small{display:block;font-size:9px;color:#a8baaa;margin-top:1px}
.compact-check-row>.count-saved{border-color:#8dc3a880!important;color:#acf0ce!important}
#numberModal[hidden]{display:none!important}#numberModal{position:fixed;inset:0;z-index:100;display:flex;align-items:flex-end;justify-content:center;background:#090909b8;padding:10px 8px max(8px,env(safe-area-inset-bottom));touch-action:manipulation}
.number-panel{width:100%;max-width:410px;max-height:calc(100dvh - 20px);overflow:auto;background:#2b2b2b;border:1px solid #85987a55;border-radius:20px;padding:13px 14px 12px;color:#eef0e2;outline:none;overscroll-behavior:contain}
.number-panel header{display:flex;justify-content:space-between;align-items:center;gap:12px}.number-panel header small{font-size:10px;color:#adbeab}.number-panel h2{font-size:18px;font-weight:500;margin:4px 0 0}.number-panel header button{flex:none;width:36px;height:36px;display:grid;place-items:center;border-radius:50%;background:#ffffff08}
#numberDraft{display:block;text-align:center;font-size:38px;font-weight:500;line-height:1.1;margin:10px 0 6px;font-variant-numeric:tabular-nums;color:#f0e5af}#numberDraft.is-suggestion{color:#acbba6}
#numberPreview{font-size:11px;text-align:center;color:#b8d9c0;margin:4px 0;min-height:15px}#numberError{font-size:11px;text-align:center;color:#efb18a;min-height:14px;margin:3px 0 6px}
.number-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:5px}.number-grid button{height:43px;min-height:43px;display:grid;place-items:center;border-radius:9px;background:#ffffff08;color:#f1f1df;font-size:23px;font-weight:400}.number-grid button[data-digit=","][hidden]{visibility:hidden;display:grid!important}
.number-panel footer{position:sticky;bottom:-12px;display:grid;grid-template-columns:1fr 2fr;gap:8px;padding:9px 0 0;background:#2b2b2b}.number-panel footer button{min-height:43px;border-radius:10px;background:#ffffff08;font-size:14px}.number-panel #numberSave{background:#d2c895;color:#222222;font-weight:600}.number-panel #numberSave:disabled{opacity:.4}
@media(min-width:850px){.compact-app .top{padding-left:22px!important;padding-right:22px!important}.app.compact-app .map-layer{left:0!important;right:0!important}.app.compact-app .dock{max-width:680px!important;left:50%!important;right:auto!important;transform:translateX(-50%);width:100%!important;border-radius:15px 15px 0 0!important}.compact-app .sheet{left:auto!important;right:14px!important;width:440px!important}.compact-app .event{font-size:12px!important}}
@media(max-width:355px){.compact-app .wordmark-logo{width:76px!important}.compact-app .event{font-size:9px!important}.compact-counters{gap:5px!important}.compact-summary{gap:2px}.compact-check-row{grid-template-columns:28px minmax(50px,1fr) 52px 52px;gap:5px}.number-panel{padding:10px}.number-grid button{height:41px;min-height:41px}}
@media(max-height:450px){.compact-app .top{height:43px!important;padding-top:2px!important}.app.compact-app{--map-top:43px}.compact-summary{min-height:35px}.compact-app .compact-count-row{min-height:48px}.compact-app .map-view-switch{top:6px!important}.number-panel{max-width:500px}.number-panel header{float:left;width:45%;margin-right:5%}#numberDraft{margin:0 0 6px;font-size:30px}#numberPreview{clear:both}.number-grid button{height:36px;min-height:36px}.number-panel footer button{min-height:38px}}

/* Summary columns must all fit at 320px. */
.compact-app .insights-table{min-width:0;table-layout:fixed;width:100%;font-size:11px}.compact-app .insights-table th,.compact-app .insights-table td{padding:9px 4px;white-space:normal;overflow-wrap:anywhere}.compact-app .insights-table th:nth-child(1){width:28%}.compact-app .insights-table th:nth-child(2){width:28%}.compact-app .insights-table th:nth-child(3),.compact-app .insights-table th:nth-child(4){width:22%}.phase-legend.has-warning{max-width:calc(100% - 22px);font-size:10px;line-height:1.35;padding:6px;color:#ffd1ad;pointer-events:none}.approach-count{pointer-events:none}

.premium-teaser{margin:14px 0}.premium-caption{font-size:10px;letter-spacing:.14em;color:#d2c895;margin:12px 0}.premium-card{display:flex;gap:13px;align-items:center;border:1px solid #d2c89533;border-radius:13px;background:linear-gradient(120deg,#d2c8950d,transparent);padding:15px 12px;margin:8px 0}.premium-symbol{font-size:26px;color:#d2c895}.premium-card>div{flex:1}.premium-card b{display:block;font-size:14px;color:#e8e7d2}.premium-card small{display:block;font-size:11px;margin-top:4px;color:#b4c3b6}.premium-card>svg{color:#c5bd91}

/* Source-grounded import and narrow controls outside the drawing. */
.compact-app .top{height:auto!important;min-height:52px;padding-bottom:4px!important}
.app.compact-app .map-layer{right:70px!important}
.app.compact-app>.compact-counters{position:absolute!important;left:auto!important;right:5px!important;top:calc(var(--map-top) + 8px)!important;bottom:calc(var(--dock-height) + 8px)!important;width:60px!important;display:flex!important;flex-direction:column!important;justify-content:center!important;gap:12px!important;padding:0!important;z-index:9}
.compact-app>.compact-counters .big-strides,.compact-app>.compact-counters .walk-counter{display:flex!important;flex-direction:column!important;gap:0!important;width:60px!important;min-width:0!important;height:auto!important;min-height:144px!important;border:1px solid #d2c89544!important;border-radius:16px!important;background:#252525!important;padding:5px 0!important}
.compact-app>.compact-counters #bigStridesLabel,.compact-app>.compact-counters #walkStepsLabel{order:-2!important;font-size:7px!important;line-height:18px!important;letter-spacing:0!important}
.compact-app>.compact-counters #strideFloatPlus,.compact-app>.compact-counters #walkStepsPlus{order:-1!important}
.compact-app>.compact-counters #strideCountEdit,.compact-app>.compact-counters #walkStepsEdit{order:0!important;width:56px!important;height:38px!important;min-height:38px!important}
.compact-app>.compact-counters #strideFloatMinus,.compact-app>.compact-counters #walkStepsMinus{order:1!important}
.compact-app>.compact-counters button.stride-float-btn,.compact-app>.compact-counters #walkStepsPlus,.compact-app>.compact-counters #walkStepsMinus{width:48px!important;min-height:40px!important;height:40px!important}
.app.compact-app .dock{display:grid!important;grid-template-columns:minmax(0,1fr) 44px;align-items:center;gap:4px;padding-top:5px!important}
.compact-app .compact-count-row{display:block;min-height:44px}.compact-summary{grid-template-columns:28px minmax(50px,1fr) auto 28px;gap:2px}
.source-fence-id{font:600 15px Arial;fill:#f2dda1;paint-order:stroke;stroke:#252525;stroke-width:4px;pointer-events:none}.source-boundary{fill:#f2dda1;pointer-events:none}.source-boundary text{font:13px Arial;paint-order:stroke;stroke:#252525;stroke-width:3px}
.compact-app .course-svg .source-highlight{stroke:#d2c895;fill:#d2c8950a}
.import-evidence,.import-routes{margin:16px 0}.import-evidence h4,.import-routes h4{font-size:14px;margin:6px 0}.import-evidence p,.import-routes p{font-size:11px;line-height:1.5;color:#b8bab6}
.evidence-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}.evidence-grid button{min-height:65px;text-align:left;padding:9px;border:1px solid #d2c89544;border-radius:10px;background:#242424}.evidence-grid button b{font-size:17px;color:#f2dda1}.evidence-grid span,.evidence-grid small{display:block;font-size:10px;margin-top:3px}.evidence-grid .needs-review{border-color:#efb18a}.evidence-grid .needs-review span{color:#efb18a}
.route-review-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}.route-review-list button{display:flex;align-items:center;justify-content:space-between;gap:5px;padding:10px 7px;background:#242424;border:1px solid #7775;border-radius:8px;font-size:11px}.route-review-list span{font-size:9px;color:#d2c895}
.review-image{isolation:isolate}.dark-source-preview{filter:grayscale(1) invert(.88)!important}.source-trace-preview{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;z-index:1}.source-trace-preview polyline{fill:none;stroke:#f2dda1;stroke-width:2px;vector-effect:non-scaling-stroke}.source-trace-preview .trace-draft{stroke:#efb18a;stroke-width:3px}.review-markers{z-index:2;position:absolute;inset:0;pointer-events:none}
.trace-editor{padding:12px;border:1px solid #d2c895;border-radius:10px;margin:10px 0}.trace-editor p{font-size:12px}.trace-editor>div{display:flex;gap:6px}.trace-editor button{flex:1;padding:8px;font-size:11px;background:#d2c89518}.trace-editor small{display:block;margin-top:6px;font-size:11px}
@media(max-height:480px) and (orientation:landscape){.app.compact-app>.compact-counters{flex-direction:row!important;width:124px!important;top:auto!important;bottom:calc(var(--dock-height) + 5px)!important;gap:4px!important}.compact-app>.compact-counters .big-strides,.compact-app>.compact-counters .walk-counter{min-height:0!important}.app.compact-app .map-layer{right:130px!important}.compact-app>.compact-counters #bigStridesLabel,.compact-app>.compact-counters #walkStepsLabel{line-height:12px!important}.compact-app>.compact-counters button.stride-float-btn,.compact-app>.compact-counters #walkStepsPlus,.compact-app>.compact-counters #walkStepsMinus{min-height:32px!important;height:32px!important}}
.trace-options{display:flex;gap:4px;margin-bottom:6px}.trace-options button{padding:5px!important;font-size:9px!important;min-height:30px!important;color:#bfc3ba!important}
#sourceRouteChoice{grid-column:1/-1;justify-self:center;font-size:10px;min-height:26px;padding:3px 16px;border:1px solid #cfc78f44;border-radius:15px;background:#cfc78f12;color:#cfc78f}#sourceRouteChoice:disabled{opacity:.7;background:transparent}

body:not(.has-course-source) #dock,body:not(.has-course-source) .compact-counters,body:not(.has-course-source) .map-view-switch,body:not(.has-course-source) .phase-legend,body:not(.has-course-source) .compact-map-tools,body:not(.has-course-source) .zoom-actions{display:none!important}


/* All map chrome is anchored at the bottom and on the right edge. */
.compact-app .top{display:none!important}
.app.compact-app .map-layer{inset:env(safe-area-inset-top) 78px calc(var(--dock-height) + 1px) 0!important}
.app.compact-app .dock{grid-template-columns:minmax(0,1fr) 44px!important;row-gap:3px!important}
.bottom-utility{grid-column:1/-1;display:flex;gap:6px;align-items:center;justify-content:flex-end;min-height:44px}
.compact-app .bottom-utility .map-view-switch{position:static!important;height:40px!important;margin-right:auto}
.compact-app .bottom-utility .map-view-switch button{min-height:36px!important;height:36px!important;min-width:64px!important}
.compact-app .bottom-utility>#progress,.compact-app .bottom-utility>#settings{position:static!important;width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important;display:grid!important;place-items:center!important;padding:0!important;border:1px solid #ffffff19!important;border-radius:50%!important;background:#262626!important;color:#e6e8dc}
.compact-app .dock>.phase-legend{position:static!important;grid-column:1/-1;max-width:none!important;margin:0;padding:2px 0;font-size:9px;background:transparent;pointer-events:none}
.compact-app #progressTrack{grid-column:1/-1;margin:2px 0 0!important}
.app.compact-app>.compact-counters{top:auto!important;bottom:calc(var(--dock-height) + 7px)!important;right:5px!important;width:68px!important;gap:7px!important;justify-content:flex-end!important}
.compact-app>.compact-counters .big-strides,.compact-app>.compact-counters .walk-counter{width:68px!important;min-height:136px!important}
.compact-app>.compact-counters #strideCountEdit,.compact-app>.compact-counters #walkStepsEdit{min-height:44px!important;height:44px!important;width:64px!important}
.edge-tools{width:68px;display:grid;gap:6px}
.compact-app .edge-tools .compact-map-tools{position:static!important;display:grid;grid-template-columns:1fr 1fr;gap:0}
.compact-app .edge-tools .compact-map-tools>#rotate,.compact-app .edge-tools .compact-map-tools>#recenterMap{min-height:44px!important;height:44px!important;width:34px!important;border-radius:12px!important}
.compact-app .edge-tools>.zoom-actions{position:static!important;display:grid!important;grid-template-columns:1fr 1fr!important;width:68px!important;padding:0!important;height:auto!important;gap:0!important;border-radius:12px!important;background:#232323!important}
.compact-app .edge-tools .zoom-actions output{grid-column:1/-1;grid-row:1;text-align:center;font-size:9px;padding-top:3px}
.compact-app .edge-tools .zoom-actions button{width:34px!important;min-width:34px!important;height:44px!important;min-height:44px!important;padding:0!important;background:transparent!important}
.compact-app #sourceRouteChoice:disabled{display:none!important}
@media(min-width:850px){.app.compact-app .dock{left:auto!important;right:84px!important;transform:none!important;width:min(680px,calc(100% - 90px))!important}.app.compact-app>.compact-counters{right:6px!important}}
@media(max-height:570px) and (orientation:landscape){.app.compact-app>.compact-counters{flex-direction:row!important;align-items:flex-end!important;width:208px!important;gap:3px!important}.compact-app>.compact-counters .big-strides,.compact-app>.compact-counters .walk-counter{min-height:0!important}.app.compact-app .map-layer{right:218px!important}.edge-tools{width:68px;flex:none}.compact-app .dock>.phase-legend{font-size:8px!important}.compact-app .bottom-utility{min-height:38px}.compact-app .bottom-utility .map-view-switch{height:36px!important}}

/* The drawing owns map gestures; one-finger sheets remain scrollable. */
.compact-app .course-svg{touch-action:none!important;overscroll-behavior:contain}
.compact-app .dock,.compact-app .compact-counters{touch-action:manipulation}
.compact-app .sheet{touch-action:pan-y!important;overscroll-behavior:contain}
.compact-app .phase-legend[hidden]{display:none!important}
.compact-app .clean-course-menu #sheetBody{padding-top:2px}
.course-menu-group{padding:4px 0;margin-bottom:10px;border-bottom:1px solid #ffffff12}
.course-menu-item{display:flex;align-items:center;gap:12px;width:100%;min-height:54px;padding:12px 4px;text-align:left;background:transparent;color:#efeee5;border-radius:10px}
.course-menu-item:hover,.course-menu-item:focus-visible{background:#ffffff08}
.course-menu-item>span:nth-child(2){flex:1;min-width:0}.course-menu-item b{display:block;font-size:15px;line-height:1.35;font-weight:500;letter-spacing:0}
.course-menu-item small{display:block;font-size:12px;line-height:1.4;color:#b9b9b2;margin-top:3px}.course-menu-icon{color:#d2c895;display:grid;place-items:center;width:28px;flex:none}.course-menu-item>svg{width:16px;color:#85857f;flex:none}
.compact-app .menu-save-status{flex-wrap:wrap;gap:8px;padding:10px 4px;font-size:12px;line-height:1.4}.compact-app .menu-save-status button{min-height:44px}.compact-app .menu-save-status span{margin-left:0}
.sport-guide,.map-mark-guide{font-size:14px;line-height:1.6;color:#d3d3cc}.sport-guide h3,.map-mark-guide h3{font-size:17px;color:#f1f0e8;font-weight:500;margin:20px 0 12px}
.sport-guide dt,.map-mark-guide dt{font-size:15px;font-weight:600;color:#e7dfbc;line-height:1.4;margin:20px 0 5px}.sport-guide dd,.map-mark-guide dd{margin:0;line-height:1.6;color:#c3c3bc;font-size:14px}.guide-intro{color:#c3c3bc;margin:8px 0 18px}.guide-method p{font-size:13px;line-height:1.6}
.map-mark-guide>svg{width:100%;height:auto;max-height:88px;background:#1c1c1c;border-radius:12px;padding:8px}.map-mark-guide svg text{font:13px Arial;fill:#f0e8ca}
.map-mark-guide dt{display:flex;align-items:center;gap:9px}.map-mark-guide p{font-size:13px;line-height:1.6;margin-top:18px}.mark-swatch{display:inline-grid;place-items:center;width:20px;height:22px;font-size:12px;font-style:normal;font-weight:700;flex:none}.mark-swatch.zone{color:#efb18a;border-left:3px solid #efb18a}.mark-swatch.stride:before,.mark-swatch.last:before{content:'';display:block;width:4px;height:18px;border-radius:2px;background:#9ad6c6}.mark-swatch.last:before{background:#cbd2a1}

/* Embedded Workspace preview: source overview only, never a cramped application shell. */
.course-preview-mode,.course-preview-mode body{height:100%;overflow:hidden}
.course-preview-mode .app.compact-app{position:absolute!important;inset:0!important;left:0!important;top:0!important;transform:none!important;max-width:none!important;width:100%!important;height:100%!important;border:0!important}
.course-preview-mode .app.compact-app .map-layer{inset:0!important;right:0!important;background:#1e1e1e!important}
.course-preview-mode .app.compact-app .course-svg{width:100%!important;height:100%!important;pointer-events:none}
.course-preview-mode .compact-app :is(.dock,.compact-counters,.top,.sheet,.shade,.welcome,.phase-legend){display:none!important}
.course-preview-mode #toast{display:none!important}

/* Mobile targets stay finger-sized; short portrait screens never use the landscape rail. */
@media(max-width:849px){
 .app.compact-app .map-layer{right:98px!important}
 .app.compact-app>.compact-counters{width:88px!important}
 .compact-app>.compact-counters .big-strides,.compact-app>.compact-counters .walk-counter{width:88px!important;min-height:152px!important}
 .compact-app>.compact-counters #bigStridesLabel,.compact-app>.compact-counters #walkStepsLabel{font-size:8px!important;line-height:18px!important}
 .compact-app>.compact-counters #strideCountEdit,.compact-app>.compact-counters #walkStepsEdit{width:84px!important}
 .compact-app>.compact-counters button.stride-float-btn,.compact-app>.compact-counters #walkStepsPlus,.compact-app>.compact-counters #walkStepsMinus{width:44px!important;min-height:44px!important;height:44px!important}
 .edge-tools{width:88px}.compact-app .edge-tools .compact-map-tools>#rotate,.compact-app .edge-tools .compact-map-tools>#recenterMap{width:44px!important;height:44px!important}
 .compact-app .edge-tools>.zoom-actions{width:88px!important}.compact-app .edge-tools .zoom-actions button{width:44px!important;min-width:44px!important;height:44px!important}
}
@media(max-width:849px) and (max-height:570px) and (orientation:portrait){
 .compact-app>.compact-counters .big-strides,.compact-app>.compact-counters .walk-counter{display:grid!important;grid-template-columns:44px 44px!important;grid-template-rows:14px 36px 44px!important;padding:3px 0!important;min-height:0!important;height:100px!important}
 .compact-app>.compact-counters #bigStridesLabel,.compact-app>.compact-counters #walkStepsLabel{grid-column:1/-1!important;grid-row:1!important}
 .compact-app>.compact-counters #strideCountEdit,.compact-app>.compact-counters #walkStepsEdit{grid-column:1/-1!important;grid-row:2!important;height:36px!important;min-height:36px!important}
 .compact-app>.compact-counters #strideFloatMinus,.compact-app>.compact-counters #walkStepsMinus{grid-column:1!important;grid-row:3!important}
 .compact-app>.compact-counters #strideFloatPlus,.compact-app>.compact-counters #walkStepsPlus{grid-column:2!important;grid-row:3!important}
}
.course-preview-mode .app.compact-app .map-layer{right:0!important}

.course-preview-mode :is(.source-highlight,.source-fence-id,.source-boundary){display:none!important}
.compact-app .edge-tools>.zoom-actions{grid-template-rows:14px 44px!important;height:60px!important;min-height:60px!important;align-items:center!important}
.compact-app .edge-tools .zoom-actions output{grid-column:1/-1!important;grid-row:1!important;min-height:0!important;align-self:center!important;padding:0!important}
.compact-app .edge-tools #zoomIn{grid-column:2!important;grid-row:2!important}.compact-app .edge-tools #zoomOut{grid-column:1!important;grid-row:2!important}
@media(max-width:849px) and (orientation:portrait){.app.compact-app>.compact-counters{max-height:calc(100% - var(--dock-height) - 14px)!important;overflow-y:auto;overflow-x:hidden;justify-content:flex-start!important}.compact-app>.compact-counters>:is(.big-strides,.walk-counter,.edge-tools){flex-shrink:0!important}}

.course-preview-mode .course-preview-error::after{content:"Öppna banan för att läsa originalskissen.";position:fixed;inset:0;display:grid;place-items:center;padding:24px;text-align:center;font:13px/1.5 Arial,sans-serif;color:#b9bcb4;pointer-events:none}


/* Reset inherited grid coordinates inside the count edit button. */
.compact-app #strideCountEdit b,.compact-app #walkStepsValue{grid-area:auto!important;justify-self:center!important;align-self:center!important;margin:0!important;text-align:center!important;min-width:0!important;width:auto!important;transform:none!important}

.course-back{display:grid;place-items:center;flex:none;width:44px;height:44px;border:1px solid #ffffff26;border-radius:50%;color:#e7dfbc;text-decoration:none;font-size:22px}
.course-complete{padding:14px;margin-bottom:16px;background:#d2c89512;border:1px solid #d2c89566;border-radius:14px}.course-complete h3{font-size:18px;margin:0 0 8px}.course-complete p{font-size:14px;line-height:1.5;color:#d3d3cc}.course-workspace-link{display:block;min-height:44px;padding:12px 0;color:#e7dfbc;text-decoration:underline;font-size:14px}
@media(max-width:355px){.compact-app .bottom-utility .map-view-switch button{min-width:56px!important;padding-left:8px!important;padding-right:8px!important}.bottom-utility{gap:4px}}
