.help-launcher{position:fixed;right:20px;bottom:max(20px,env(safe-area-inset-bottom));z-index:70;display:flex;align-items:center;gap:8px;border:1px solid #285e50;border-radius:999px;padding:11px 17px;background:#174f43;color:white;box-shadow:0 4px 18px #153e4026;font-family:inherit;font-size:13px;font-weight:600;line-height:1.2;min-height:44px;cursor:pointer}
.help-launcher>span{display:grid;place-items:center;border:1px solid #ffffff99;border-radius:50%;width:20px;height:20px;font-weight:700}.help-launcher-inline{position:static;flex-shrink:0;box-shadow:none;margin:0;padding:8px 12px;align-self:center}.welcome-heading .help-launcher-inline{margin:12px auto 0}.settings-header:has(.help-launcher-inline){flex-wrap:wrap}.help-launcher[hidden]{display:none}
#helpPanel.help-panel{position:fixed;inset:auto 18px 18px auto;margin:0;width:min(410px,calc(100vw - 36px));max-width:calc(100vw - 36px);height:min(640px,calc(100dvh - 36px));max-height:calc(100dvh - 36px);padding:0;border:1px solid #d5e0da;border-radius:18px;background:#fff;color:#263e37;box-shadow:0 16px 65px #102b3540;overflow:hidden;font:14px/1.55 Arial,sans-serif}
#helpPanel[open]{display:flex;flex-direction:column}#helpPanel::backdrop{background:#152d2533}.help-heading{display:flex;justify-content:space-between;align-items:center;padding:18px 20px 12px;gap:10px;background:#f3f7f3}.help-heading p{margin:0 0 3px;font-size:9px;letter-spacing:1.4px;font-weight:700;color:#577369}.help-heading h2{font-size:21px;line-height:1.25;margin:0;letter-spacing:-.4px}.help-close{border:0;background:transparent;font-size:29px;color:#244c40;min-width:44px;min-height:44px;cursor:pointer}.help-search-area{padding:14px 20px;border-bottom:1px solid #e1e7df}.help-search-area label{display:block;font-weight:600;font-size:13px;margin-bottom:6px}.help-search-row{display:flex;align-items:center;gap:7px}.help-search-row input{width:100%;min-width:0;padding:10px 12px;border:1px solid #b8c9c0;border-radius:8px;font:16px Arial,sans-serif;color:#243e34;background:#fff;min-height:44px}.help-search-row button{background:transparent;color:#235747;border:0;text-decoration:underline;cursor:pointer;min-height:44px}.help-search-area p{font-size:11px;color:#667a70;margin:7px 0 10px}.help-search-area .help-category-label{display:inline;margin-right:8px;font-size:12px}.help-search-area select{max-width:75%;padding:7px;border:1px solid #cfdbd3;background:#f6f8f5;border-radius:6px;color:#264638;font-size:14px;min-height:36px}.help-scroll{overflow-y:auto;overscroll-behavior:contain;padding:12px 20px 20px;flex:1;min-height:0}#helpStatus{font-size:12px;color:#5e756b;margin:0 0 8px}.help-topic{width:100%;display:flex;justify-content:space-between;gap:14px;text-align:left;padding:12px 0;border:0;border-bottom:1px solid #e7ece6;background:white;color:#284b3d;font:inherit;min-height:48px;cursor:pointer}.help-topic:hover{background:#f3f7f2}.help-back{border:0;background:none;color:#426853;padding:7px 0;font:inherit;font-size:12px;min-height:40px;cursor:pointer}#helpAnswer h3{font-size:21px;line-height:1.3;margin:8px 0 12px;letter-spacing:-.3px}#helpAnswer p{margin:0 0 18px}.help-actions{display:flex;flex-direction:column;gap:8px}.help-action{border:1px solid #b9d0bd;border-radius:8px;padding:11px 13px;background:#eef5eb;color:#174f43;font:600 13px/1.4 Arial,sans-serif;text-align:left;display:flex;justify-content:space-between;gap:12px;cursor:pointer;min-height:44px}.help-action:hover{background:#e0edda}#helpAnswer .help-action-note{font-size:11px;color:#6c7c72;margin:12px 0 0}.help-footer{padding:10px 20px;background:#f5f7f3;border-top:1px solid #e2e8df;color:#6c7c72;font-size:10px}.help-panel :focus-visible,.help-launcher:focus-visible{outline:3px solid #6c9b4f;outline-offset:3px}.help-destination{outline:3px solid #76a85c!important;outline-offset:5px;box-shadow:0 0 0 7px #c4dfad55!important;scroll-margin:20px}.help-empty{color:#5e756b}
@media(max-width:600px){#helpPanel.help-panel{inset:auto 8px max(8px,env(safe-area-inset-bottom)) 8px;width:auto;max-width:none;height:min(680px,calc(100dvh - 24px));max-height:calc(100dvh - 24px);border-radius:14px}.help-launcher{right:12px;bottom:max(12px,env(safe-area-inset-bottom));padding:10px 13px}.help-launcher-inline{position:static;font-size:12px;min-height:40px;padding:6px 10px}.help-search-area select{font-size:16px}body:has(>.help-launcher:not([hidden])) .workspace{padding-bottom:80px}.help-heading,.help-search-area,.help-scroll{padding-left:16px;padding-right:16px}}
@media(prefers-reduced-motion:reduce){.help-panel *{scroll-behavior:auto}}
/* On mobile inputs, Help lives in the header, never over footer actions. */
@media(max-width:800px){
 #planSidebar .sidebar-heading{flex-wrap:wrap;align-items:flex-start;gap:8px}
 #planSidebar .sidebar-tools{margin-left:auto;display:flex;align-items:center;gap:6px}
 #planSidebar .sidebar-tools .help-launcher{position:static;inset:auto;box-shadow:none;border-radius:7px;padding:8px 10px;min-height:44px;font-size:12px;white-space:nowrap}
 #planSidebar .sidebar-tools .help-launcher>span{width:16px;height:16px;font-size:11px}
 body:has(>.help-launcher:not([hidden])) .workspace{padding-bottom:90px}
}
/* Pair wizard actions at the right edge, in keyboard and visual order. */
#settingsDialog .settings-header{flex-wrap:wrap}
#settingsDialog .settings-header>div:first-child{flex:1 1 230px;min-width:0}
#settingsDialog #settingsHeaderActions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex:0 0 auto;margin-left:auto}
#settingsDialog #settingsHeaderActions>button{position:static;display:inline-flex;justify-content:center;align-items:center;align-self:center;gap:6px;width:100px;min-width:100px;height:36px;min-height:36px;margin:0;padding:7px 10px;border:1px solid var(--border);border-radius:7px;background:#f4f7f4;color:var(--green);box-shadow:none;font-family:inherit;font-size:11px;font-weight:600;line-height:1.2;white-space:nowrap}
#settingsDialog #settingsHeaderActions>button:hover{background:#e8f0e5}
#settingsDialog #settingsHeaderActions>button[hidden]{display:none}
#settingsDialog #settingsHeaderActions .help-launcher>span{width:16px;height:16px;border-color:currentColor;font-size:11px}
@media(max-width:700px){#settingsDialog #settingsHeaderActions>button{height:44px;min-height:44px}}

#settingsDialog #settingsHeaderActions>#minimizeSettings{background:var(--green);border-color:var(--green);color:#fff}
#settingsDialog #settingsHeaderActions>#minimizeSettings:hover{background:#123e34;border-color:#123e34}

/* On mobile, help sits beside Manage scenarios; Adjust plan owns the floating spot. */
@media(max-width:800px){
 #applicationHeader .header-plan-actions>.help-launcher{position:static;inset:auto;display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:40px;height:40px;margin:0;padding:9px 12px;border:1px solid var(--border);border-radius:7px;background:#f4f7f4;color:var(--green);box-shadow:none;font-size:12px;line-height:1.2;white-space:nowrap}
 #applicationHeader .header-plan-actions>.help-launcher:hover{background:#e8f0e5}
 #applicationHeader .header-plan-actions>.help-launcher>span{width:16px;height:16px;border-color:currentColor;font-size:11px}
}

.help-content{display:flex;flex-direction:column;flex:1;min-width:0;min-height:0;overflow:hidden;background:#fff;color:#263e37;font:14px/1.55 Arial,sans-serif}
.help-content>.help-heading,.help-content>.help-search-area,.help-content>.help-footer{flex:none}
.help-content .help-footer{display:flex;flex-direction:column;gap:5px}
.help-feedback-link{align-self:flex-start;padding:0;border:0;background:none;color:#416756;font:inherit;font-size:12px;text-decoration:underline;cursor:pointer;min-height:30px}
.help-content.is-docked>.help-heading{display:none}
.help-content.is-docked .help-search-area{padding:16px 16px 12px}
.help-content.is-docked .help-search-area>label:first-child{font-size:17px;font-weight:600;margin-bottom:10px}
.help-content.is-docked .help-scroll{padding:12px 16px 20px}
.help-content.is-docked .help-footer{padding:10px 16px}
.help-content.is-docked #helpAnswer h3{font-size:18px}
.help-content :focus-visible{outline:3px solid #6c9b4f;outline-offset:2px}
