
/* HUIDI Docs Community Local V1.2.0 RC5 — final visual/interaction closure */
html,body{max-width:100%;overflow-x:hidden}
body.huidi-local-workspace-rc5 #huidiLocalModeBar,
body.huidi-local-editor-rc5 #huidiLocalModeBar,
body.huidi-local-catalog-rc5 #huidiLocalModeBar{display:none!important}

/* Workspace: keep the full journey only where it is actually useful. */
body.huidi-local-workspace-rc5 .main{max-width:100%;overflow-x:hidden}
body.huidi-local-workspace-rc5.huidi-workspace-compact .workflow{display:none!important}
body.huidi-local-workspace-rc5.huidi-workspace-compact .mode-strip{margin:10px 0 14px;padding:9px 12px;box-shadow:none;background:var(--panel)}
body.huidi-local-workspace-rc5 .table-wrap{max-width:100%;overflow:auto}
body.huidi-local-workspace-rc5 .empty-rich{display:grid;grid-template-columns:54px minmax(0,1fr) auto;gap:14px;align-items:center;padding:18px;border:1px dashed var(--line2);border-radius:16px;background:linear-gradient(145deg,var(--panel2),var(--panel));color:var(--text)}
body.huidi-local-workspace-rc5 .empty-rich .empty-icon{width:52px;height:52px;border-radius:15px;display:grid;place-items:center;background:linear-gradient(145deg,#e8f2ff,#dceaff);color:#1757b9;font-weight:900;font-size:22px}
body.huidi-local-workspace-rc5 .empty-rich b{display:block;font-size:14px;margin-bottom:4px}
body.huidi-local-workspace-rc5 .empty-rich p{margin:0;color:var(--muted);font-size:11px;line-height:1.65}
body.huidi-local-workspace-rc5 .catalog-local-grid{display:grid;grid-template-columns:1fr .9fr;gap:14px}
body.huidi-local-workspace-rc5 .mini-product-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-top:12px}
body.huidi-local-workspace-rc5 .mini-product{border:1px solid var(--line);border-radius:14px;background:var(--panel2);padding:10px;display:grid;grid-template-columns:52px minmax(0,1fr);gap:9px;align-items:center}
body.huidi-local-workspace-rc5 .mini-product img,body.huidi-local-workspace-rc5 .mini-product .mini-ph{width:52px;height:52px;border-radius:11px;object-fit:cover;background:#edf2f7;display:grid;place-items:center;color:#8a98aa;font-size:10px}
body.huidi-local-workspace-rc5 .mini-product b{font-size:11px;display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body.huidi-local-workspace-rc5 .mini-product small{display:block;color:var(--muted);font-size:9px;margin-top:3px}
body.huidi-local-workspace-rc5 .doc-chain{display:flex;align-items:center;gap:5px;flex-wrap:wrap;margin-top:5px}
body.huidi-local-workspace-rc5 .doc-chain span{font-size:9px;color:var(--muted)}

/* Editor: restore the canonical white toolbar; hide only redundant online-era shells while preserving toolbar functions. */
body.huidi-local-editor-rc5 .site-header,
body.huidi-local-editor-rc5 .intro,
body.huidi-local-editor-rc5 #editorAccessBanner,
body.huidi-local-editor-rc5 #fp-xm-editor,
body.huidi-local-editor-rc5 #fp30EditorContext,
body.huidi-local-editor-rc5 #fpV3321SideNav,
body.huidi-local-editor-rc5 #fp-pilot-header,
body.huidi-local-editor-rc5 .floating-help,
body.huidi-local-editor-rc5 #fp-assistant41-launcher,
body.huidi-local-editor-rc5 #fp-assistant41-dialog,
body.huidi-local-editor-rc5 #fpPrivacyButton{display:none!important}
body.huidi-local-editor-rc5 .app{width:min(1540px,calc(100% - 24px));padding:14px 0 48px;margin:auto}
body.huidi-local-editor-rc5 .workbench{gap:12px}
body.huidi-local-editor-rc5 .form-column,body.huidi-local-editor-rc5 .preview-shell{min-width:0}
body.huidi-local-editor-rc5 .doc .fp-trial-watermark{display:none!important}
body.huidi-local-editor-rc5 .fp-a12-readiness-banner{border:1px solid #f0c8c4!important;border-radius:12px!important;background:#fff8f7!important;padding:10px 12px!important;margin-bottom:10px!important;display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:7px 10px!important;align-items:center!important}
body.huidi-local-editor-rc5 .fp-a12-readiness-banner>strong{font-size:12px!important;margin:0!important}
body.huidi-local-editor-rc5 .fp-a12-readiness-banner>span{display:flex!important;gap:7px!important;flex-wrap:wrap!important;min-width:0!important}
body.huidi-local-editor-rc5 .fp-a12-readiness-banner>span button{display:inline-flex!important;width:auto!important;padding:3px 6px!important;border:1px solid #f0d3d0!important;border-radius:7px!important;background:#fff!important;text-decoration:none!important;font-size:9px!important;white-space:nowrap!important}
body.huidi-local-editor-rc5 .fp-a12-readiness-banner>small{grid-column:1/-1;font-size:9px!important;color:#9a5b54!important}

/* Catalog: local-only page gets one journey, local XLSX, and no trial/online chrome. */
body.huidi-local-catalog-rc5 #fp-xm-catalog,
body.huidi-local-catalog-rc5 #fp-assistant41-launcher,
body.huidi-local-catalog-rc5 #fp-assistant41-dialog,
body.huidi-local-catalog-rc5 #fpPrivacyButton,
body.huidi-local-catalog-rc5 .catalog-trial-watermark,
body.huidi-local-catalog-rc5 .trial-preview-note,
body.huidi-local-catalog-rc5 .fp-dependency-warning{display:none!important}
body.huidi-local-catalog-rc5 .catalog-local-flow{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:0 0 14px}
body.huidi-local-catalog-rc5 .catalog-local-flow span{display:flex;align-items:center;gap:7px;padding:9px 11px;border-radius:12px;background:#fff;border:1px solid var(--line);color:#52647f;font-size:11px;font-weight:800}
body.huidi-local-catalog-rc5 .catalog-local-flow b{display:grid;place-items:center;width:22px;height:22px;border-radius:8px;background:#eaf1ff;color:#2755b7;font-size:10px}
body.huidi-local-catalog-rc5 .layout{grid-template-columns:minmax(330px,390px) minmax(0,1fr)}
body.huidi-local-catalog-rc5 .side{max-height:calc(100vh - 24px)}
body.huidi-local-catalog-rc5 .stage{min-width:0}
@media(max-width:1100px){body.huidi-local-catalog-rc5 .layout{grid-template-columns:330px minmax(0,1fr)}body.huidi-local-catalog-rc5 .app{padding-left:10px;padding-right:10px}}
@media(max-width:820px){body.huidi-local-catalog-rc5 .layout{grid-template-columns:1fr}body.huidi-local-catalog-rc5 .side{position:static;max-height:none}body.huidi-local-catalog-rc5 .catalog-local-flow{grid-template-columns:1fr 1fr}}


/* ===== HUIDI Community Local RC5 stability + layout closure ===== */
html,body{max-width:100%;overflow-x:hidden}
.app{width:100%;max-width:100vw;grid-template-columns:292px minmax(0,1fr)}
.main,.topbar,.view,.section-head,.panel,.table-wrap,.info-grid,.support-grid,.catalog-local-grid{min-width:0;max-width:100%}
.workflow{grid-template-columns:repeat(8,minmax(0,1fr));gap:7px}
.flow-step{min-width:0}.flow-step b,.flow-step small{overflow:hidden;text-overflow:ellipsis}
/* One page = one page header. Keep topbar title; inner section header becomes actions-only. */
body:not([data-huidi-view="home"]) .top-actions{display:none}
.view:not(#view-home) .section-head>div:first-child{display:none!important}
.view:not(#view-home) .section-head{justify-content:flex-end;margin:10px 0 12px;min-height:0}
#view-recycle .section-head,#view-backup .section-head,#view-help .section-head{display:none!important}
.mode-strip{padding:8px 11px;margin:10px 0 12px;gap:7px;box-shadow:none;border-radius:12px}
.mode-strip>span:not(.mode-badge):not(.pill){display:none}
.mode-strip strong{font-size:11px}.mode-strip .mode-badge,.mode-strip .pill{font-size:9px}
.section-actions{max-width:100%;justify-content:flex-end}
.section-actions>*{flex:0 0 auto}
.filterbar>*{min-width:0}
.table-wrap{overflow-x:auto;overscroll-behavior-inline:contain}
.support-grid,.info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
#view-help .info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
#view-help .info-card:last-child{grid-column:1/-1}
#view-help .support-grid{grid-template-columns:repeat(2,minmax(0,320px));justify-content:start}
#view-help .support-card img{max-width:280px;margin-inline:auto;object-fit:contain}
.empty-rich{display:flex;align-items:center;gap:14px;justify-content:flex-start;flex-wrap:wrap;padding:22px;text-align:left;color:var(--muted)}
.empty-rich .empty-icon{flex:0 0 auto}.empty-rich>div:nth-child(2){min-width:220px;flex:1}.empty-rich .btn{flex:0 0 auto}
/* editor: no stacked legacy header and no assistant residue */
.huidi-local-editor-rc5 #fp-xm-editor,.huidi-local-editor-rc5 #fp30EditorContext,.huidi-local-editor-rc5 #fpV3321SideNav,.huidi-local-editor-rc5 #fp-pilot-header,.huidi-local-editor-rc5 #fp-assistant41-launcher,.huidi-local-editor-rc5 #fp-assistant41-dialog,.huidi-local-editor-rc5 .fp-trial-watermark{display:none!important}
@media(max-width:1450px){.workflow{grid-template-columns:repeat(4,minmax(0,1fr))}.flow-step:after{display:none}.section-actions{width:100%;justify-content:flex-start}.section-actions .btn,.section-actions label.btn{flex:0 1 auto}.info-grid,#view-help .info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.app{grid-template-columns:1fr}.sidebar{position:relative;height:auto}.workflow{grid-template-columns:1fr}.info-grid,#view-help .info-grid{grid-template-columns:1fr}.section-actions{display:grid;grid-template-columns:1fr 1fr}.section-actions>*{width:100%}.main{padding:14px}.title-block h2{font-size:25px}}


/* ===== HUIDI Community Local RC5 — canonical editor toolbar restoration ===== */
body.huidi-local-editor-rc5 #fpLiteToolbar{display:flex!important;visibility:visible!important;position:sticky!important;top:0!important;z-index:9900!important;background:#fff!important;border-bottom:1px solid #dfe6ee!important;box-shadow:0 5px 18px rgba(22,42,72,.07)!important;min-height:58px!important}
body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-left{min-width:190px!important;flex:0 1 auto!important}
body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-left strong{color:#17263d!important;font-size:16px!important}
body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-left small{color:#718096!important;max-width:360px!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important}
body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-actions{display:flex!important;align-items:center!important;gap:5px!important;flex-wrap:wrap!important;min-width:0!important;overflow:visible!important;padding-bottom:1px!important}
body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-actions::-webkit-scrollbar{display:none!important}
body.huidi-local-editor-rc5 #fpLiteAccountBtn,body.huidi-local-editor-rc5 #fpLiteVersion{display:none!important}
body.huidi-local-editor-rc5 #huidiLocalCheckHeader{background:#f7fafc;color:#2b496f;border-color:#d7e1eb}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>summary{min-height:36px;padding:0 11px;border:1px solid #c8d9ee;border-radius:9px;background:#edf5ff;color:#1d5aa5;font-size:11px;font-weight:900;cursor:pointer;list-style:none;white-space:nowrap;display:flex;align-items:center}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>summary::-webkit-details-marker{display:none}
body.huidi-local-editor-rc5 #huidiLocalNextHeader{position:relative;flex:0 0 auto}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>div{position:absolute;right:0;top:calc(100% + 7px);z-index:12000;min-width:250px;max-width:min(340px,calc(100vw - 20px));padding:7px;border:1px solid #d6e1ec;border-radius:12px;background:#fff;box-shadow:0 18px 50px rgba(20,41,70,.18);display:grid;gap:5px}
body.huidi-local-editor-rc5 #huidiLocalNextHeader:not([open])>div{display:none}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>div button{width:100%;padding:9px 10px;border:0;border-radius:9px;background:#fff;color:#263b58;text-align:left;display:grid;gap:2px;cursor:pointer}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>div button:hover{background:#f1f6fd}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>div button.primary{background:#edf5ff;color:#174f9c}
body.huidi-local-editor-rc5 #huidiLocalNextHeader>div button b{font-size:12px}body.huidi-local-editor-rc5 #huidiLocalNextHeader>div button small{font-size:9px;color:#728198;font-weight:600}
body.huidi-local-editor-rc5 .huidi-local-state-badge{display:inline-flex;align-items:center;min-height:30px;padding:0 9px;border:1px solid #bfe6d8;border-radius:999px;background:#ebf9f4;color:#167259;font-size:10px;font-weight:900;white-space:nowrap;flex:0 0 auto}
body.huidi-local-editor-rc5 .site-header,body.huidi-local-editor-rc5 .intro,body.huidi-local-editor-rc5 #editorAccessBanner,body.huidi-local-editor-rc5 #fp-xm-editor,body.huidi-local-editor-rc5 #fp30EditorContext,body.huidi-local-editor-rc5 #fpV3321SideNav,body.huidi-local-editor-rc5 #fp-pilot-header,body.huidi-local-editor-rc5 .floating-help,body.huidi-local-editor-rc5 #fp-assistant41-launcher,body.huidi-local-editor-rc5 #fp-assistant41-dialog,body.huidi-local-editor-rc5 #fpPrivacyButton,body.huidi-local-editor-rc5 .fp-trial-watermark{display:none!important}
body.huidi-local-editor-rc5 .app{width:min(1540px,calc(100% - 24px));padding:14px 0 48px;margin:auto}
body.huidi-local-editor-rc5 .workbench{gap:12px}body.huidi-local-editor-rc5 .form-column,body.huidi-local-editor-rc5 .preview-shell{min-width:0}
body.huidi-local-editor-rc5 .doc .fp-trial-watermark{display:none!important}
@media(max-width:900px){body.huidi-local-editor-rc5 #fpLiteToolbar{align-items:flex-start!important;padding:8px 10px!important}body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-left{min-width:150px!important}body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-actions{width:100%!important}body.huidi-local-editor-rc5 #fpV3321TemplateHeader,body.huidi-local-editor-rc5 #fpV3321FieldsHeader,body.huidi-local-editor-rc5 #fpV3325DocSelect,body.huidi-local-editor-rc5 #fpV3325LayoutHeader,body.huidi-local-editor-rc5 #fpV3325ClearHeader{display:inline-flex!important}body.huidi-local-editor-rc5 .app{width:calc(100% - 12px)!important}}
@media(max-width:620px){body.huidi-local-editor-rc5 #fpLiteToolbar{display:block!important}body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-left{margin-bottom:6px}body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-actions>#fpLiteImportBtn{display:flex!important}}

@media(min-width:1500px){body.huidi-local-editor-rc5 #fpLiteToolbar .fp-lite-toolbar-actions{flex-wrap:nowrap!important}}
body.huidi-local-editor-rc5 #huidiLocalEditorBar{display:none!important}

@media(max-width:1050px){.app{grid-template-columns:240px minmax(0,1fr)}.sidebar{padding-inline:10px}.brand p,.nav-copy small,.status-dot{display:none}.nav-btn{grid-template-columns:40px minmax(0,1fr)}.main{padding:16px 18px 34px}.title-block h2{font-size:28px}.support-grid,#view-help .support-grid{grid-template-columns:1fr}.filterbar{grid-template-columns:1fr}.workflow{grid-template-columns:repeat(2,minmax(0,1fr))}}
