/* Workspace changes are restricted to phone widths. Desktop work areas retain their existing styles. */
.mobile-workspace-menu{display:none}
.mobile-workspace-jump{display:none}
.mobile-review-heading{display:none}
.mobile-review-name-toggle{display:none}
@media(max-width:760px){
 .compact-layout{--font-size-body:15px;--font-size-caption:13px;font-size:15px;background:var(--ui-bg)}
 .compact-layout .image2-workflow-shell{padding:10px 12px calc(90px + env(safe-area-inset-bottom));gap:12px;max-width:100%;box-sizing:border-box}
 .compact-layout .mobile-workspace-jump{position:fixed;bottom:0;left:0;right:0;z-index:90;display:grid;grid-template-columns:auto 1fr 1fr;gap:8px;background:#ffffffef;backdrop-filter:blur(8px);border-top:1px solid var(--ui-border);padding:10px 12px calc(10px + env(safe-area-inset-bottom));box-shadow:0 -3px 12px rgba(var(--ui-text-rgb), 0.0431)}
 .compact-layout .mobile-workspace-jump button{font-size:14px;min-height:46px;padding:8px}
 .compact-layout .mobile-workspace-jump.annual{grid-template-columns:auto 1fr}.compact-layout .mobile-workspace-jump.annual>button:nth-child(2){display:none}
 .compact-layout .unified-workbench :is(.workflow-progress,.unified-map-panel,.model-annotation-review,.unified-side-panel){scroll-margin-top:12px}
 .compact-layout .image2-workflow-shell :is(button,input,select,textarea){font-size:16px;min-height:44px;box-sizing:border-box;max-width:100%}
 .compact-layout .image2-workflow-shell :is(input[type=checkbox],input[type=radio]){min-height:22px;min-width:22px;width:22px;height:22px;flex-shrink:0}
 .compact-layout .image2-workflow-shell :is(small,.small,.muted){font-size:13px;line-height:1.65}
 .compact-layout .image2-workflow-shell :is(h2,h3){font-size:18px;white-space:normal}
 .compact-layout .ui-navbar{padding:10px 12px;display:flex;flex-wrap:wrap;gap:10px;border-radius:12px}
 .compact-layout .ui-navbar-brand{flex:1}
 .compact-layout .mobile-workspace-menu{display:block;background:var(--ui-surface-soft);color:var(--ui-primary);border:1px solid var(--ui-border);padding:8px 12px}
 .compact-layout .ui-navbar-actions{display:flex;flex-wrap:wrap;flex-basis:100%;gap:8px;min-width:0}
 .compact-layout .ui-navbar:not(.mobile-menu-open) .ui-navbar-actions>:not(.image2-control):not(.image2-save-state){display:none}
 .compact-layout .ui-navbar-actions .image2-control{min-width:0;max-width:none;flex:1 1 100%}
 .compact-layout .ui-navbar-actions .image2-control select{font-size:15px;height:44px;min-height:44px}
 .compact-layout .image2-save-state{margin:0;font-size:12px;width:100%;text-align:left}
 .compact-layout .ui-navbar-actions .image2-user-pill{width:100%;order:10}
 .compact-layout .compact-progress-bar{display:flex!important;flex-direction:column;align-items:stretch;padding:8px;background:#fff;border:1px solid var(--ui-border);border-radius:12px;gap:10px}
 .compact-layout .workflow-progress{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;width:100%}
 .compact-layout .workflow-progress button{white-space:normal;display:flex;flex-direction:column;justify-content:center;gap:5px;min-height:68px;padding:8px 3px;border:1px solid var(--ui-border);border-radius:9px;font-size:14px;background:var(--ui-surface-soft)}
 .compact-layout .workflow-progress button>span{width:24px;height:24px;font-size:13px}
 .compact-layout .workflow-progress button.current{background:var(--ui-primary);color:white;border-color:var(--ui-primary);box-shadow:0 3px 9px rgba(var(--ui-primary-rgb), 0.1255)}
 .compact-layout .workflow-progress button.current>span{background:#fff;color:var(--ui-primary)}
 .compact-layout .workflow-input-modes{display:flex;gap:8px;margin:0;width:100%;box-sizing:border-box;min-width:0}.compact-layout .workflow-input-modes button{flex:1;min-width:0;font-size:14px}
 .compact-layout .compact-progress-bar .input-issues-toolbar{flex:0 0 auto;margin:0;width:100%;max-width:100%;min-width:0;box-sizing:border-box;align-items:stretch}
 .compact-layout .input-issues-toolbar .input-issue-first{min-width:0;gap:6px;flex-wrap:wrap;padding:8px;text-align:left}
 .compact-layout .input-issue-first .input-issue-text{white-space:normal;overflow-wrap:anywhere;flex:1 1 150px}
 .compact-layout .input-issue-first span:last-child{white-space:normal;font-size:12px}
 .compact-layout .input-issues-all{padding:6px;min-width:64px;max-width:88px;white-space:normal}
 .compact-layout .unified-workbench{display:grid;grid-template-columns:minmax(0,1fr)!important;height:auto!important;min-height:0;gap:12px}
 .compact-layout .unified-workbench.review-workbench{grid-template-rows:auto auto auto!important}
 .compact-layout .review-workbench>.compact-progress-bar{grid-area:1/1/2/2}
 .compact-layout .review-workbench>.ui-workflow-guide{grid-area:auto}
 .compact-layout .unified-workbench.review-workbench:not(.results-mode):not(.no-base-asset) .unified-map-panel{grid-area:2/1/3/2;height:auto;min-height:0;overflow:visible}
 .compact-layout .review-workbench>.model-annotation-review{grid-area:3/1/4/2;height:auto!important;max-height:none!important;overflow:visible!important;padding:14px;gap:12px}
 .compact-layout .review-workbench .model-review-scroll{height:auto;max-height:none;min-height:0;overflow:visible;padding:0;gap:12px}
 .compact-layout .unified-map-grid,.compact-layout .base-setup-workbench:not(.review-workbench):not(.no-base-asset)>.unified-map-grid{height:auto!important;min-height:0;display:grid;grid-template-columns:minmax(0,1fr)!important;gap:12px}
 .compact-layout .unified-workbench:not(.results-mode):not(.no-base-asset) .unified-map-panel{height:auto;min-height:0;overflow:visible;padding:10px;border-radius:12px}
 .compact-layout .unified-workbench:not(.results-mode) .unified-map-stage{height:auto;min-height:0;flex:none}
 .compact-layout .unified-workbench:not(.results-mode) :is(.canvas-shell,.canvas-stage){height:auto;min-height:0;flex:none}
 /* Match the desktop :not() specificity so the drawing surface cannot collapse. */
 .compact-layout .unified-workbench:not(.results-mode):not(.no-base-asset) .unified-map-panel .unified-map-stage{height:auto;min-height:0;flex:none}
 .compact-layout .unified-workbench:not(.results-mode) .canvas-viewport,.compact-layout .results-mode .canvas-viewport{height:clamp(260px,43dvh,420px);min-height:260px;flex:0 0 auto;touch-action:none}
 .compact-layout .results-mode :is(.unified-map-stage,.canvas-shell,.canvas-stage){height:auto;min-height:0}
 .compact-layout .unified-map-panel>.section-head{flex-wrap:wrap}.compact-layout .unified-map-panel>.section-head>div:first-child>.small{display:none}
 .compact-layout .unified-map-panel>.section-head>.row{max-width:100%}
 .compact-layout .canvas-stage{display:flex;flex-direction:column;gap:8px;position:relative}
 .compact-layout .canvas-toolbar{position:static!important;order:0;display:flex!important;flex-direction:row!important;width:auto!important;align-self:flex-end;padding:0!important;gap:6px!important;background:transparent!important;border:0!important;box-shadow:none!important}
 .compact-layout .canvas-toolbar button{height:44px!important;width:48px;min-height:44px!important;font-size:22px!important}
 .compact-layout .canvas-toolbar button[aria-label="适合窗口"]{width:auto;min-width:80px;font-size:14px!important;white-space:nowrap;padding:6px 10px}
 .compact-layout .canvas-minimap,.compact-layout .floating-operation-guide{display:none}
 .mobile-canvas-help{font-size:13px;line-height:1.7;background:var(--ui-surface-soft);color:var(--ui-primary);padding:8px 10px;border-radius:8px}
 .compact-layout .unified-side-panel{height:auto!important;max-height:none!important;overflow:visible;scrollbar-gutter:auto;padding:14px;border-radius:12px;min-width:0}
 .compact-layout .base-mode-switch{position:static;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:100%;gap:6px}
 .compact-layout .base-mode-switch button{font-size:14px;padding:8px 4px}
 .compact-layout .base-setup-workbench .unified-inspector-head{display:flex;flex-direction:column;align-items:stretch;gap:10px}
 .compact-layout .no-base-asset .upload-create-form,.compact-layout .no-base-asset .unified-form-section{display:flex;flex-direction:column;gap:14px;width:100%}
 .compact-layout .upload-create-form>*{width:100%;min-width:0}.compact-layout .upload-create-form .required-field{padding:12px}
 .compact-layout .upload-create-form label,.compact-layout .compact-field{font-size:15px}
 .compact-layout .layout-actionbar{gap:8px;display:flex;flex-wrap:wrap;padding:12px 0 0;margin-top:8px}
 .compact-layout .layout-actionbar button{flex:1 1 120px;min-width:0!important;min-height:48px;font-size:15px}
 .compact-layout .base-summary-grid .setup-summary-only{display:block;padding:10px}
 .compact-layout .base-summary-grid .setup-checklist{display:grid;grid-template-columns:1fr 1fr;gap:8px}
 .compact-layout .base-summary-grid .setup-check-item{min-width:0;min-height:64px;display:grid;gap:3px;padding:8px}
 .compact-layout .base-summary-grid .setup-check-item :is(strong,span,small){font-size:12px;white-space:normal}
 .compact-layout .model-review-categories{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}
 .compact-layout .model-review-categories button{font-size:14px;min-height:52px;padding:8px 4px}
 .compact-layout .review-workbench .model-annotation-object-list{max-height:160px;overflow:auto;padding:0;gap:7px}
 .compact-layout .review-workbench .model-annotation-object{min-width:100px;min-height:48px;font-size:14px;padding:8px}
 .compact-layout .review-four-steps{gap:5px}.compact-layout .review-four-steps button{font-size:13px;min-height:58px;padding:7px 4px}
 .compact-layout .review-four-steps button[aria-current=step]{background:var(--ui-primary-soft);border:2px solid var(--ui-primary);color:var(--ui-primary)}
 .compact-layout .review-four-steps small{font-size:11px}.compact-layout .review-step-editor{padding:12px;gap:12px}
 .compact-layout .review-step-editor :is(p,label){font-size:15px;line-height:1.7}.compact-layout .review-step-editor h4{font-size:17px}
 .compact-layout .review-role-options{gap:8px}.compact-layout .review-role-options label{padding:8px;border:1px solid var(--ui-border);border-radius:8px;min-height:44px;gap:8px}
 .compact-layout .review-value-row{flex-wrap:wrap;gap:8px}.compact-layout .review-value-row>strong{flex:1}
 .compact-layout .review-save-actions{grid-template-columns:1fr 1fr;gap:8px}.compact-layout .review-save-actions>button:first-child{grid-column:1/-1;min-height:50px}
 .compact-layout .review-save-actions button{font-size:15px}.compact-layout .review-step-navigation{gap:8px}.compact-layout .review-step-navigation button{flex:1;font-size:14px}
 .compact-layout .unified-workbench.review-workbench .model-review-footer{background:#fff;padding-top:12px;gap:12px;position:static;bottom:auto}
 .compact-layout .unified-workbench.review-workbench .model-review-footer .review-save-actions{grid-template-columns:1fr 1fr}
 .compact-layout .review-area-filter{font-size:14px;flex-wrap:wrap}.compact-layout .review-area-filter select{font-size:16px;min-height:44px}
 .compact-layout .model-review-more>div{position:absolute;left:0;right:0;width:auto;max-height:65dvh;overflow:auto;padding:14px}
 .compact-layout .results-mode .unified-map-grid{grid-template-areas:'toolbar' 'map' 'analysis' 'annual';gap:12px}
 .compact-layout .result-explorer-bar{grid-area:toolbar;display:flex;flex-direction:column;align-items:stretch;gap:12px;padding:14px;border-radius:12px}
 .compact-layout .result-explorer-title{display:block}.compact-layout .result-explorer-title span{font-size:13px;line-height:1.7;display:block;margin-top:6px}
 .compact-layout :is(.result-mode-tabs,.result-view-toggle){display:flex;flex-wrap:wrap;gap:6px;width:100%}
 .compact-layout :is(.result-mode-tabs,.result-view-toggle)>button{font-size:14px;flex:1;min-width:85px}
 .compact-layout .ui-result-toolbar{display:grid;grid-template-columns:1fr 1fr;gap:8px}.compact-layout .ui-result-toolbar button{font-size:14px;min-height:44px}
 .compact-layout .results-mode .unified-map-panel{position:static}.compact-layout .result-map-head{display:flex;flex-wrap:wrap;gap:8px}
 .compact-layout .result-map-head [role=group]{display:flex;flex-wrap:wrap;gap:6px}.compact-layout .result-map-head button{font-size:13px;padding:5px 8px;min-height:44px}
 .compact-layout .ui-result-groups{grid-template-columns:minmax(0,1fr);gap:12px}.compact-layout .ui-result-item{padding:14px}.compact-layout .ui-result-item p{font-size:15px;line-height:1.9}
 .compact-layout .ui-result-item-head{flex-wrap:wrap;gap:8px}.compact-layout .ui-object-link{font-size:16px}
 .compact-layout .map-annual-summary{min-width:0;overflow:auto}.compact-layout .unified-table{font-size:14px;min-width:520px}
 .compact-layout .point-result-card p,.compact-layout .point-result-card .annual-result-text{font-size:15px;line-height:1.85}
 .compact-layout .point-result-card .point-summary-explanation{font-size:13px;line-height:1.7}
 .compact-layout .annual-position-summary-head{display:flex;flex-direction:column;align-items:stretch;gap:14px}
 .compact-layout .annual-filter-controls{display:grid;grid-template-columns:1fr 1fr;gap:10px;width:100%}
 .compact-layout .annual-filter-controls label{min-width:0;width:auto;font-size:14px;display:grid;gap:6px}
 .compact-layout .annual-filter-controls label:first-child{grid-column:1/-1}.compact-layout .annual-filter-controls select{min-width:0;width:100%}
 .compact-layout .annual-year-control{flex-wrap:wrap}.compact-layout .annual-year-control input{flex:1;min-width:100px;max-width:180px}
 .compact-layout .annual-compact-table{display:grid;gap:12px;overflow:visible;border:0}
 .compact-layout .annual-compact-row{min-width:0;width:100%;box-sizing:border-box;display:grid;grid-template-columns:auto 1fr auto;gap:10px;padding:14px;border:1px solid var(--ui-border);background:white;border-radius:10px;font-size:15px;line-height:1.8}
 .compact-layout .annual-compact-row.head{display:none}.compact-layout .annual-compact-row>:nth-child(3){grid-column:1/-1;grid-row:2;color:var(--ui-muted);font-size:13px;overflow-wrap:anywhere}
 .compact-layout .annual-compact-row>:nth-child(3)::before{content:'关联开口：'}
 .compact-layout .annual-compact-row>.annual-verdict-cell{grid-column:3;grid-row:1;font-size:14px}
 .compact-layout .annual-compact-row>.annual-result-text{grid-column:1/-1;grid-row:3;white-space:pre-wrap}
 .compact-layout .annual-compact-row>:last-child{grid-column:1/-1}.compact-layout .annual-compact-row>strong{font-size:16px}
 .compact-layout .annual-detail-block summary{min-height:44px;display:flex;align-items:center}.compact-layout .annual-detail-content{font-size:14px}
 .compact-layout .feedback-modal-head{align-items:flex-start;gap:10px}.compact-layout .feedback-modal-head>button{min-width:60px;white-space:nowrap;flex-shrink:0}
 .compact-layout .workflow-notice{position:relative;inset:auto;max-width:100%;width:100%;font-size:14px;padding:12px;z-index:20}
 .compact-layout .layout-editor-launch{display:none}.compact-layout .row{flex-wrap:wrap;min-width:0}
 .compact-layout [role=dialog],.compact-layout [role=alertdialog]{max-width:calc(100vw - 24px);box-sizing:border-box;max-height:calc(100dvh - 24px);overflow:auto}
 .compact-layout .image2-workflow-shell :is(input,select,textarea){min-width:0;scroll-margin-block:80px}
 .compact-layout .image2-workflow-shell :is(button,input,select,textarea):focus-visible{outline:3px solid var(--ui-primary);outline-offset:2px}
 .mobile-box-panel{padding:10px;background:var(--ui-surface-soft);border:1px solid var(--ui-border);border-radius:10px;display:grid;gap:8px;flex-shrink:0}
 .mobile-box-heading,.mobile-box-actions{display:flex;align-items:center;justify-content:space-between;gap:8px}.mobile-box-heading strong{font-size:14px}.mobile-box-heading button{font-size:13px!important;padding:5px 7px}
 .mobile-box-buttons{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}.mobile-box-buttons button{font-size:14px!important;min-height:44px;padding:6px 2px}
 .mobile-box-actions>button:last-child{flex:1}.mobile-box-actions small{font-size:12px}
 .mobile-draw-modes{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}.mobile-draw-modes button{font-size:14px!important;min-height:44px;background:var(--ui-surface-soft);color:var(--ui-primary);padding:8px 4px}
 .mobile-draw-modes button[aria-pressed=true]{background:var(--ui-primary);color:#fff}
 .compact-layout .unified-workbench .canvas-stage.is-model-correcting{position:fixed;inset:0;z-index:1000;background:#fff;padding:calc(10px + env(safe-area-inset-top)) 12px calc(10px + env(safe-area-inset-bottom));box-sizing:border-box;height:100dvh;display:flex;flex-direction:column;gap:8px;overflow:auto}
 .compact-layout .canvas-stage.is-model-correcting>.model-canvas-guide{position:static;display:grid;grid-template-columns:minmax(0,1fr) auto;padding:0;gap:4px 8px;flex-shrink:0;background:transparent;border:0;box-shadow:none}
 .compact-layout .canvas-stage.is-model-correcting>.model-canvas-guide strong{font-size:16px}.compact-layout .canvas-stage.is-model-correcting>.model-canvas-guide span{font-size:13px;grid-column:1/-1;grid-row:2;line-height:1.6}
 .compact-layout .canvas-stage.is-model-correcting>.model-canvas-guide button{grid-area:1/2/2/3;min-height:44px;font-size:14px}
 .compact-layout .canvas-stage.is-model-correcting>.canvas-viewport{height:auto!important;min-height:150px;flex:1 0 150px;max-height:none}
 .compact-layout .canvas-stage.is-model-correcting>.canvas-toolbar{margin:-2px 0;gap:6px!important}
 .compact-layout .canvas-stage.is-model-correcting>.small{display:none}
 .compact-layout .site-editor{max-width:100vw;max-height:100dvh}

 /* One visible task at a time. Supporting controls stay available in More settings. */
 .compact-layout .review-workbench{--mobile-review-map-height:clamp(180px,28dvh,250px)}
 .compact-layout .review-workbench>.unified-map-grid{display:contents!important}
 .compact-layout .unified-workbench.review-workbench:not(.results-mode):not(.no-base-asset) .unified-map-panel{position:sticky;top:0;z-index:25;align-self:start;padding:6px;background:#fff;box-shadow:0 3px 12px #0000000c}
 .compact-layout .unified-workbench.review-workbench:not(.results-mode):not(.no-base-asset) .unified-map-panel:has(.is-model-correcting){z-index:1100}
 .compact-layout .review-workbench .unified-map-panel>.section-head{display:none}
 .compact-layout .unified-workbench.review-workbench:not(.results-mode) .canvas-stage:not(.is-model-correcting)>.canvas-viewport{height:var(--mobile-review-map-height);min-height:180px;flex:none}
 .compact-layout .review-workbench .canvas-stage:not(.is-model-correcting)>.mobile-canvas-help{order:2;padding:3px 4px;font-size:12px;line-height:1.5}
 .compact-layout .review-workbench .canvas-stage:not(.is-model-correcting)>.canvas-toolbar{position:absolute!important;left:auto!important;bottom:auto!important;right:6px;top:6px;z-index:6;background:#fffffff2!important;padding:3px!important;border-radius:8px}
 .compact-layout .review-workbench .canvas-stage:not(.is-model-correcting)>.canvas-toolbar button{width:42px;min-height:44px!important}
 .compact-layout .mobile-review-heading{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end;gap:8px}
 .compact-layout .mobile-review-heading label{display:grid;gap:4px;font-size:13px;min-width:0}
 .compact-layout .mobile-review-heading select{width:100%;font-weight:600}
 .compact-layout .mobile-review-heading button{min-height:44px;font-size:14px;padding:8px}
 .compact-layout .review-workbench .model-review-categories{display:none}
 .compact-layout .review-workbench .model-annotation-review:not(.mobile-options-open)>.model-annotation-review-head{display:none}
 .compact-layout .review-workbench .model-annotation-review-head{display:flex;flex-wrap:wrap;gap:8px;padding:10px;background:var(--ui-surface-soft);border-radius:8px}
 .compact-layout .review-workbench .model-annotation-review-head h3{display:none}
 .compact-layout .review-workbench .review-basic-status{display:grid;grid-template-columns:1fr 1fr;width:100%;gap:6px}
 .compact-layout .review-workbench .review-basic-status button{min-height:44px;font-size:13px}
 .compact-layout .review-workbench [data-mobile-name-open=false] .review-name-editor{display:none}
 .compact-layout .mobile-review-name-toggle{display:block;align-self:flex-start;font-size:13px;min-height:44px;padding:6px 10px}
 .compact-layout .review-workbench .review-context-row{flex-wrap:wrap;gap:4px}
 .compact-layout .review-workbench .review-context-row>span{display:none}
 .compact-layout .review-workbench .model-annotation-object-list:has(>.model-annotation-object.selected:only-child){display:none}
 .compact-layout .review-workbench .review-four-steps button{min-height:44px;padding:5px 3px;font-size:12px}
 .compact-layout .review-workbench .review-four-steps small{font-size:10px}
 .compact-layout .review-workbench :is(.review-step-editor,.model-review-scroll,.mobile-review-heading){scroll-margin-top:calc(var(--mobile-review-map-height) + 56px)}
 .compact-layout .review-workbench .review-guided-question{margin:0 0 4px;gap:4px}
 .compact-layout .review-workbench .review-step-editor{padding:10px;gap:8px}
 .compact-layout .review-workbench .review-step-editor>.optional-opening-entry{order:5;border-top:1px solid var(--ui-border);padding-top:10px}
 .compact-layout .review-workbench .review-name-fields{display:flex;flex-wrap:wrap;gap:8px}
 .compact-layout .review-workbench .review-name-fields>label{flex:1 1 160px}
 .compact-layout .review-workbench .review-name-fields>button{font-size:14px}
 .compact-layout .review-workbench .bed-residents .row>label{min-height:44px;box-sizing:border-box;padding:4px;gap:6px;font-size:14px}
 .compact-layout .review-workbench:has([data-mobile-actions=true])>.mobile-workspace-jump{display:none}
 .compact-layout .image2-workflow-shell:has([data-mobile-actions=true]){padding-bottom:calc(160px + env(safe-area-inset-bottom))}
 .compact-layout .unified-workbench.review-workbench [data-mobile-actions=true]>.model-review-footer{position:fixed;inset:auto 0 0;z-index:80;display:grid;grid-template-columns:1fr 1fr auto;gap:8px;padding:10px 12px calc(10px + env(safe-area-inset-bottom));margin:0;border-top:1px solid var(--ui-border);box-shadow:0 -3px 12px #0000000d;max-height:45dvh;overflow:auto}
 .compact-layout [data-mobile-actions=true]>.model-review-footer :is(.review-step-navigation,.review-save-actions){display:contents}
 .compact-layout [data-mobile-actions=true]>.model-review-footer .review-save-actions>button:first-child{grid-row:1;grid-column:1/-1;min-height:48px}
 .compact-layout [data-mobile-actions=true]>.model-review-footer .review-step-navigation>button:first-child{grid-row:2;grid-column:1}
 .compact-layout [data-mobile-actions=true]>.model-review-footer .review-step-navigation>button:not(:first-child){display:none}
 .compact-layout [data-mobile-actions=true]>.model-review-footer .review-save-actions>button:nth-child(2){grid-row:2;grid-column:2}
 .compact-layout [data-mobile-actions=true]>.model-review-footer .review-delete-menu{grid-row:2;grid-column:3}
 .compact-layout .review-delete-menu>summary{padding:10px;min-height:44px;box-sizing:border-box}
 .compact-layout .review-delete-menu>button{position:fixed;right:12px;bottom:calc(124px + env(safe-area-inset-bottom));max-width:calc(100vw - 24px);white-space:normal}

 /* Full-screen floor plan: the paper fills the phone, camera tools float at the thumb. */
 .compact-layout .unified-workbench .unified-map-panel:has(.is-mobile-fullscreen,.is-model-correcting){z-index:1100!important;-webkit-backdrop-filter:none!important;backdrop-filter:none!important}
 .compact-layout .unified-workbench .canvas-stage.is-mobile-fullscreen{position:fixed;inset:0;z-index:1000;margin:0;background:var(--ui-bg);padding:calc(8px + env(safe-area-inset-top)) max(8px,env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom)) max(8px,env(safe-area-inset-left));box-sizing:border-box;height:100dvh;display:flex;flex-direction:column;gap:6px;overflow:hidden}
 .compact-layout .unified-workbench .canvas-stage.is-mobile-fullscreen>.canvas-viewport{height:auto!important;min-height:0!important;max-height:none!important;flex:1 1 auto!important;border-radius:10px}
 .compact-layout .unified-workbench .canvas-stage.is-mobile-fullscreen>.canvas-toolbar{position:absolute!important;top:auto!important;left:auto!important;right:calc(16px + env(safe-area-inset-right))!important;bottom:calc(16px + env(safe-area-inset-bottom))!important;z-index:6;display:flex!important;gap:6px!important;padding:4px!important;border-radius:12px;background:rgba(255,255,255,.94)!important;box-shadow:0 6px 18px rgba(0,0,0,.18)!important}
 .compact-layout .canvas-stage.is-mobile-fullscreen>.mobile-canvas-help{flex:none;order:-1!important}
 .compact-layout .canvas-stage.is-mobile-fullscreen>:is(.small,.base-mobile-adjust,.canvas-minimap){display:none}
 .compact-layout .mobile-fullscreen-toggle{min-width:48px;font-size:18px!important}
 .compact-layout .mobile-fullscreen-toggle[aria-pressed=true]{font-size:14px!important;padding:6px 10px;white-space:nowrap;width:auto!important}
 /* Box drawing: magnifier above the finger, so the corner under it stays visible. */
 .compact-layout .mobile-loupe{position:fixed;z-index:1200;width:112px;height:112px;border-radius:50%;pointer-events:none;box-shadow:0 0 0 3px #fff,0 0 0 5px var(--ui-primary),0 8px 24px rgba(0,0,0,.28)}
}
/* A short landscape window or a resized viewport needs room to read the form. */
@media(max-width:760px) and (max-height:560px){
 .compact-layout .unified-workbench.review-workbench:not(.results-mode):not(.no-base-asset) .unified-map-panel{position:relative;top:auto}
 .compact-layout .review-workbench :is(.review-step-editor,.model-review-scroll,.mobile-review-heading){scroll-margin-top:12px}
}
@container home (max-width:760px){
 .home-auth{scroll-margin-top:16px}
 .home-mobile-bar[data-auth-visible=true]{display:none}
}
/* 2026-10-21 dark theme: full-screen canvas toolbar follows the theme */
html.tq-dark .compact-layout .unified-workbench .canvas-stage.is-mobile-fullscreen>.canvas-toolbar{background:rgba(20,26,40,.86)!important;-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px)}

/* ===== Mobile restyle (Style C, Code 版本 2026-10-21) =====
   Phone layout of the four workflow steps. Colours only under html.tq-dark; light theme unchanged. */
@media(max-width:760px){
 /* Shared: compact four-step bar and a pill-shaped input-mode switch */
 .compact-layout .compact-progress-bar{padding:8px;gap:8px}
 .compact-layout .workflow-progress{grid-template-columns:repeat(4,minmax(0,1fr));gap:4px}
 .compact-layout .workflow-progress button{min-height:46px;padding:4px 2px;gap:3px;font-size:12px;line-height:1.25}
 .compact-layout .workflow-progress button>span{width:22px;height:22px;font-size:11px}
 .compact-layout .workflow-input-modes{padding:3px;gap:3px;border-radius:999px}
 .compact-layout .workflow-input-modes button{min-height:38px;border-radius:999px;font-size:14px}

 /* Shared: bottom bars are solid navy glass (theme-c-auto made the review footer see-through) */
 html.tq-dark .compact-layout .mobile-workspace-jump,
 html.tq-dark .compact-layout .unified-workbench.review-workbench [data-mobile-actions=true]>.model-review-footer{
  background:rgba(10,18,40,.92)!important;-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);
  border-top:1px solid rgba(255,255,255,.08)!important;box-shadow:0 -10px 28px rgba(0,0,0,.45)!important}
 html.tq-dark .compact-layout .mobile-workspace-jump button{border-radius:999px}
 /* The jump bar only navigates, so its last button is secondary; gold stays on the real submit. */
 html.tq-dark .compact-layout .mobile-workspace-jump button:last-child{background:rgba(227,200,143,.1)!important;color:#f3dcaa!important;font-weight:600;box-shadow:inset 0 0 0 1px rgba(227,200,143,.55)!important}
 html.tq-dark .compact-layout [data-mobile-actions=true]>.model-review-footer button{border-radius:999px}
}
@media(max-width:760px){
 /* Step 1 · 基础设置: each part is a card with a numbered ring and a status pill */
 html.tq-dark .compact-layout .base-checks-expanded{display:grid;gap:8px}
 html.tq-dark .compact-layout .base-check-section{background:rgba(255,255,255,.035)!important;border-radius:16px!important;padding:12px!important}
 html.tq-dark .compact-layout .base-check-section.base-check-incomplete{box-shadow:inset 3px 0 0 rgba(227,200,143,.8)}
 html.tq-dark .compact-layout .base-check-section>header{display:flex;align-items:center;gap:8px;margin-bottom:8px}
 html.tq-dark .compact-layout .base-check-section>header h2{flex:1;display:flex;align-items:center;gap:8px;font-size:15px;font-weight:600;margin:0}
 html.tq-dark .compact-layout .base-check-section>header h2>span{display:grid;place-items:center;width:22px;height:22px;font-size:11px;background:transparent!important;box-shadow:inset 0 0 0 1px rgba(227,200,143,.45)}
 html.tq-dark .compact-layout .base-check-section:not(.base-check-incomplete)>header h2>span{color:#3fb8a8!important;background:rgba(63,184,168,.15)!important;box-shadow:inset 0 0 0 1px #3fb8a8}
 html.tq-dark .compact-layout .base-check-status{padding:2px 9px;font-size:11px;background:rgba(255,255,255,.06)!important;color:#93a1b6!important}
 html.tq-dark .compact-layout .base-check-status.saved{background:rgba(63,184,168,.12)!important;color:#3fb8a8!important}
 /* Finished scene/upload parts drop their how-to line to save height */
 .compact-layout .base-check-section:not(.base-check-incomplete):is(:has(#base-scene-heading),:has(#base-upload-heading)) .base-field-help{display:none}
 /* The one gold action on this screen: confirm and continue */
 html.tq-dark .compact-layout .base-confirm-footer button:not(:disabled){background:linear-gradient(180deg,#f0dca8,#c8a96a)!important;color:#1a1408!important;font-weight:600;border-radius:999px;box-shadow:inset 0 1px 0 rgba(255,255,255,.5),0 0 18px rgba(255,210,120,.28)}
 html.tq-dark .compact-layout .base-confirm-footer button:disabled{border-radius:999px}
 html.tq-dark .compact-layout .base-confirm-footer{border-radius:16px 16px 0 0}
}
@media(max-width:760px){
 /* The sticky confirm bar sat under the fixed jump bar; stick it just above that bar instead. */
 .compact-layout .base-setup-workbench:has(>.mobile-workspace-jump) .base-confirm-footer{bottom:calc(68px + env(safe-area-inset-bottom))}
}
@media(max-width:760px){
 /* Step 2 · 户型核对: the category buttons become one swipeable row of chips (replaces the dropdown) */
 .compact-layout .review-workbench .model-annotation-review>.model-review-categories{display:flex!important;flex-wrap:nowrap;gap:6px;overflow-x:auto;scrollbar-width:none;padding:2px 0 6px;margin:0;-webkit-overflow-scrolling:touch}
 .compact-layout .review-workbench .model-annotation-review>.model-review-categories::-webkit-scrollbar{display:none}
 .compact-layout .review-workbench .model-annotation-review>.model-review-categories button{flex:none;min-height:36px!important;padding:0 13px!important;border-radius:999px!important;font-size:13px!important;white-space:nowrap;width:auto}
 html.tq-dark .compact-layout .review-workbench .model-review-categories button.stage-done small{color:#3fb8a8}
 html.tq-dark .compact-layout .review-workbench .model-review-categories button:is(.stage-optional,.extra-category):not([aria-pressed=true]){color:#93a1b6}
 .compact-layout .mobile-review-heading>label{display:none}
 .compact-layout .mobile-review-heading{display:flex!important;justify-content:flex-end}
 .compact-layout .mobile-review-heading>button{min-height:34px!important;padding:4px 12px!important;font-size:13px!important;border-radius:999px}
}
@media(max-width:760px){
 /* Step 3 · 输出结果: signal bar on each conclusion card */
 html.tq-dark .compact-layout .comprehensive-person-point{border-radius:12px!important;border-left-width:3px!important;border-left-style:solid!important;padding:12px 12px 10px 14px!important}
 html.tq-dark .compact-layout .comprehensive-person-point.signal-alert{border-left-color:#ff6b5e!important}
 html.tq-dark .compact-layout .comprehensive-person-point.signal-unfavorable{border-left-color:#e8a25a!important}
 html.tq-dark .compact-layout .comprehensive-person-point.signal-notice{border-left-color:#f0c96a!important}
 html.tq-dark .compact-layout .comprehensive-person-point.signal-good{border-left-color:#4fd18b!important}
 .compact-layout .comprehensive-person-point .comprehensive-location{display:flex;align-items:center;justify-content:space-between;gap:8px}
 .compact-layout .comprehensive-person-point .reading-location-link{min-height:36px!important;padding:0!important;font-size:15px!important;font-weight:600}
 html.tq-dark .compact-layout .comprehensive-person-point .result-basis{font-size:12px;color:#93a1b6}
 /* Compass picks: one swipeable row of pills instead of a wrapped list */
 .compact-layout .compass-choice-list{flex-wrap:nowrap!important;overflow-x:auto;gap:6px!important;scrollbar-width:none;padding-bottom:2px}
 .compact-layout .compass-choice-list::-webkit-scrollbar{display:none}
 .compact-layout .compass-choice{flex:none;display:inline-flex!important;align-items:center;gap:4px;padding:0 4px 0 10px;border-radius:999px;min-height:40px}
 html.tq-dark .compact-layout .compass-choice{background:rgba(255,255,255,.05)!important}
 html.tq-dark .compact-layout .compass-choice.is-visible{background:rgba(227,200,143,.14)!important}
 .compact-layout .compass-choice>button{min-height:36px!important;padding:0 8px!important;white-space:nowrap;background:transparent!important}
 /* Map filters and grouping tabs as pills */
 .compact-layout .result-map-head [role=group] button,.compact-layout .result-map-head button.all{min-height:34px!important;padding:0 12px!important;border-radius:999px!important}
 .compact-layout .summary-group-tabs{gap:3px;padding:3px;border-radius:999px;background:rgba(0,0,0,.2)}
 .compact-layout .summary-group-tabs button{min-height:36px!important;border-radius:999px!important}
}
@media(max-width:760px){
 /* Step 4 · 调整方案: one column on phones. adjustment-layout.css keeps a 660px two-column shell
    (side panel off-screen, page scrolls sideways); here the side panel stacks under the canvas. */
 html body.compact-layout .unified-workbench.adjustment-mode .adjustment-workspace-shell{grid-template-columns:minmax(0,1fr)!important;min-width:0!important;width:100%!important;height:auto!important;gap:12px}
 html body.compact-layout .unified-workbench.adjustment-mode .adjustment-workspace-shell>.adjustment-side-panel{position:static!important;width:auto!important;height:auto!important;max-height:none!important;overflow:visible!important;border-radius:16px;padding:12px!important}
 html body.compact-layout .unified-workbench.adjustment-mode .adjustment-workspace-left{min-width:0;width:100%}
 html.tq-dark body.compact-layout .unified-workbench.adjustment-mode .adjustment-side-panel{background:rgba(255,255,255,.035)!important;border:0!important}
}

/* 2026-11-13 tunqi mobile alignment: phone prompt, header, blanks */
@media (max-width: 760px) {
  /* ---- Phone prompt: compact bar, reserve space so it never covers buttons ---- */
  html body #phone-prompt-root .phone-prompt {
    box-sizing: border-box !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 8px !important;
    padding: 8px 12px !important;
    font-size: 13px !important;
    line-height: 1.35 !important;
    min-height: 48px !important;
    z-index: 200 !important;
  }
  html body #phone-prompt-root .phone-prompt > span {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 13px !important;
    line-height: 1.35;
  }
  html body #phone-prompt-root .phone-prompt button.pp-main,
  html body #phone-prompt-root .phone-prompt button.pp-later {
    flex: 0 0 auto !important;
    height: 32px !important;
    min-height: 32px !important;
    padding: 0 12px !important;
    font-size: 13px !important;
    white-space: nowrap !important;
  }
  html body #phone-prompt-root .phone-prompt form {
    flex: 1 1 auto;
    min-width: 0;
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 8px !important;
  }
  html body #phone-prompt-root .phone-prompt form input {
    width: 9em !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 32px !important;
    min-height: 32px !important;
  }

  body.compact-layout:has(#phone-prompt-root .phone-prompt) {
    --tq-phone-prompt-h: 52px;
  }
  body.compact-layout:has(#phone-prompt-root .phone-prompt form) {
    --tq-phone-prompt-h: 96px;
  }
  body.compact-layout:has(#phone-prompt-root .phone-prompt) .mh {
    padding-top: var(--tq-phone-prompt-h);
    box-sizing: border-box;
  }
  body.compact-layout:has(#phone-prompt-root .phone-prompt) .image2-workflow-shell {
    padding-top: calc(10px + var(--tq-phone-prompt-h));
  }

  /* ---- Logged-in home: one tight header, hide name/points, keep actions on one row ---- */
  html body .mh {
    overflow-x: hidden;
    overflow-y: visible;
  }
  html body .mh .mh-top {
    align-items: center;
    gap: 8px;
    min-height: 48px;
    padding: 4px 0;
    flex-wrap: nowrap;
  }
  html body .mh .mh-brand {
    flex: 0 0 auto;
    min-width: 0;
  }
  html body .mh .mh-brand b {
    font-size: 18px;
    letter-spacing: 2px;
  }
  html body .mh .mh-acct {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 1 1 auto;
    flex-wrap: nowrap;
    gap: 6px;
    min-width: 0;
    margin-left: auto;
  }
  html body .mh .mh-acct > span {
    display: none !important;
  }
  html body .mh .mh-acct button,
  html body .mh .mh-acct .mh-out,
  html body .mh .mh-acct .invite-entry > summary,
  html body .mh button.ghost {
    box-sizing: border-box;
    height: 36px;
    min-height: 36px !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
    font-size: 13px !important;
    line-height: 1 !important;
    white-space: nowrap;
    flex: 0 0 auto;
  }
  html body .mh .mh-acct .invite-entry {
    padding: 0 !important;
    min-width: 0;
    height: 36px;
    display: inline-flex;
    align-items: center;
  }
    html body .mh .invite-entry:not([open]) .invite-card,
  html body.compact-layout .invite-entry:not([open]) .invite-card {
    display: none !important;
  }
  html body .mh .invite-entry .invite-card,
  html body.compact-layout .invite-entry .invite-card,
  html body .mh [data-topbar-entries] .invite-card,
  html body.compact-layout [data-topbar-entries] .invite-card {
    position: fixed !important;
    left: 12px !important;
    right: 12px !important;
    width: auto !important;
    max-width: calc(100vw - 24px) !important;
    transform: none !important;
    top: calc(var(--tq-phone-prompt-h, 0px) + 56px) !important;
    box-sizing: border-box !important;
  }
  html body .mh .invite-entry .invite-card button,
  html body.compact-layout .invite-entry .invite-card button {
    height: auto !important;
    min-height: 40px !important;
    white-space: normal !important;
    padding: 8px 10px !important;
  }
  html body .mh .mh-hello {
    padding: 12px 0 14px;
  }
  html body .mh .mh-hello h1 {
    font-size: clamp(22px, 6vw, 28px);
    letter-spacing: 1px;
    line-height: 1.3;
    text-wrap: pretty;
    overflow-wrap: break-word;
  }
  html body .mh button.mh-main {
    gap: 8px;
    padding: 16px 16px 14px;
  }
  html body .mh .mh-seal.big {
    width: 72px;
    height: 72px;
    font-size: 34px;
  }
  html body .mh .mh-in {
    padding-bottom: 88px;
  }
  html body .mh .mh-grid {
    gap: 10px;
    padding-bottom: 8px;
  }
  html body .mh .mh-card {
    min-width: 0;
    padding: 12px 10px;
    gap: 8px;
  }
  html body .mh .mh-card-text {
    min-width: 0;
    flex: 1 1 auto;
  }
  html body .mh .mh-card .mh-kind,
  html body .mh .mh-card .mh-soon {
    max-width: 100%;
    line-height: 1.3;
    text-wrap: pretty;
    overflow-wrap: break-word;
  }

  /* ---- Workspace navbar: brand + actions on ONE row, case + save on the next ---- */
  html body.compact-layout .image2-workflow-shell > .ui-navbar {
    align-items: center;
    gap: 6px 8px;
    padding: 8px 10px;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar > .ui-navbar-brand {
    flex: 0 1 auto;
    height: 40px;
    min-width: 0;
    display: inline-flex;
    align-items: center;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar > .tq-home-theme {
    display: inline-flex;
    align-items: center;
    height: 40px;
    gap: 6px;
    margin-left: auto !important;
    flex: 0 0 auto;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar > .mobile-workspace-menu {
    flex: 0 1 auto;
    margin-left: 0 !important;
    max-width: 38vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar .tq-home-link,
  html body.compact-layout .image2-workflow-shell > .ui-navbar .theme-toggle,
  html body.compact-layout .image2-workflow-shell > .ui-navbar > .mobile-workspace-menu {
    box-sizing: border-box;
    height: 40px !important;
    min-height: 40px !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
    font-size: 13px !important;
    line-height: 1.2;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar > .ui-navbar-actions {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 8px;
    flex-basis: 100%;
    width: 100%;
    min-width: 0;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar .ui-navbar-actions .image2-control,
  html body.compact-layout .image2-workflow-shell > .ui-navbar .image2-control {
    flex: 1 1 auto !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
  }
  html body.compact-layout .image2-workflow-shell > .ui-navbar .image2-save-state {
    flex: 0 0 auto;
    width: auto !important;
    max-width: 42%;
    height: 44px;
    margin: 0;
    display: inline-flex;
    align-items: center;
    text-align: right;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* ---- Empty floorplan: shorter drop zone, dashed box starts below zoom tools ---- */
  html body.compact-layout .base-setup-screen.no-base-asset .canvas-viewport {
    height: min(230px, 32dvh) !important;
    min-height: 200px !important;
    max-height: 240px !important;
  }
  html body.compact-layout .base-setup-screen.no-base-asset .base-canvas-upload {
    inset: 8px 10px 10px !important;
    max-height: none;
  }
  html body.compact-layout .base-setup-screen.no-base-asset .canvas-stage {
    position: relative;
  }
  html body.compact-layout .base-setup-screen.no-base-asset .canvas-toolbar {
    position: relative !important;
    top: auto !important;
    right: auto !important;
    left: auto !important;
    justify-content: flex-end;
    margin: 0 0 6px auto;
    z-index: 8;
  }
  html body.compact-layout .base-setup-screen.no-base-asset .base-canvas-upload small {
    padding: 0 8px;
    text-wrap: pretty;
    overflow-wrap: break-word;
  }

  /* ---- AI launcher: icon-only so it no longer covers cards or form controls ---- */
  #ai-chat-root .ai-chat-launcher {
    width: 48px !important;
    min-width: 48px !important;
    max-width: 48px !important;
    height: 48px !important;
    min-height: 48px !important;
    padding: 0 !important;
    justify-content: center !important;
    gap: 0 !important;
    overflow: hidden !important;
    font-size: 0 !important;
    line-height: 0 !important;
    color: transparent !important;
    letter-spacing: -2em !important;
    right: 12px !important;
    bottom: calc(12px + env(safe-area-inset-bottom, 0px)) !important;
  }
  #ai-chat-root .ai-chat-launcher .aic-spark {
    margin: 0 !important;
    width: 32px !important;
    height: 32px !important;
    flex: 0 0 auto !important;
    letter-spacing: 0 !important;
    font-size: 16px !important;
    color: inherit !important;
  }
}

@media (max-width: 760px) and (max-height: 700px) {
  html body.compact-layout .base-setup-screen.no-base-asset .canvas-viewport {
    height: min(200px, 28dvh) !important;
    min-height: 180px !important;
    max-height: 210px !important;
  }
  html body .mh button.mh-main {
    padding: 14px 14px 12px;
  }
  html body .mh .mh-seal.big {
    width: 64px;
    height: 64px;
    font-size: 30px;
  }
}
