/* Navigation width also anchors the fixed action bar. */
#app { --navigation-width: 200px; }
#app.sidebar-collapsed { --navigation-width: 64px; }
#app .sidebar { display: flex; width: var(--navigation-width); overflow: hidden; transition: width .2s ease; }
.sidebar-toggle { display: flex; align-items: center; gap: 12px; width: 100%; height: 52px; padding: 0 22px; border: 0; border-bottom: 1px solid #edf0f5; color: #64758b; background: #fff; cursor: pointer; white-space: nowrap; flex-shrink: 0; text-align: left; }
.sidebar-toggle i { font-size: 20px; }
.sidebar-toggle:hover { background: #ecf5ff; color: #409eff; }
.sidebar-toggle:focus-visible { outline: 2px solid #409eff; outline-offset: -3px; }
#app .sidebar-menu { width: 100%; flex: 1; min-height: 0; overflow-y: auto; }
#app .sidebar-menu .el-menu-item { margin: 4px 8px; border-radius: 8px; padding-left: 16px !important; }
#app .sidebar-menu .el-menu-item.is-active { background: #ecf5ff; font-weight: 600; }
#app.sidebar-collapsed .sidebar-menu .el-menu-item { margin: 4px; padding-left: 16px !important; }
#app .content-area { min-width: 0; }
#app .config-layout-split { align-items: stretch; }
#app .document-config-card { min-height: 0; }
#app .document-config-card .document-selector-new { flex: 1; min-height: 0; }
#app .document-config-card .doc-grid { flex: 1 1 480px; height: 480px; max-height: none; min-height: 0; align-content: start; }
#app .config-column-right { width: 320px; }
#app .config-column-right .action-card { margin-top: 0; }
.question-types-card .type-selector { display: block; }
.question-types-card .el-checkbox-group { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.question-types-card .el-checkbox-button { min-width: 0; }
.question-types-card .el-checkbox-button__inner { width: 100%; padding: 10px 6px; border: 1px solid #dcdfe6; border-radius: 6px !important; box-shadow: none !important; }
.question-types-card .type-hint { margin-top: 12px; }
#app .fixed-action-bar { left: var(--navigation-width); height: auto; min-height: 58px; padding: 10px 20px; transition: left .2s ease; }
#app .action-bar-content { justify-content: space-between; gap: 20px; }
.action-bar-left, .action-bar-right { display: flex; align-items: center; gap: 10px; }
.action-bar-left { flex-shrink: 0; }
.action-bar-right { margin-left: auto; justify-content: flex-end; flex-wrap: wrap; }
#app .action-bar-stats { order: -1; margin-left: 0; padding: 0 8px; font-size: 12px; }
#app .content-wrapper { padding-bottom: 92px; }
@media (max-width: 1100px) and (min-width: 769px) {
    #app .config-layout-split { flex-direction: row; gap: 16px; }
    #app .config-column-right { width: 280px; }
    #app .doc-grid { grid-template-columns: minmax(0,1fr); }
}
@media (max-width: 768px) {
    #app { --navigation-width: 168px; }
    #app.sidebar-collapsed { --navigation-width: 64px; }
    #app .sidebar-toggle { padding: 0 18px; }
    #app .sidebar-menu .el-menu-item { padding-left: 12px !important; }
    #app .config-layout-split { flex-direction: column; }
    #app .config-column-left, #app .config-column-right { width: 100%; }
    #app .document-config-card .doc-grid { flex: none; height: auto; max-height: 480px; }
    #app .config-column-left { order: 0; }
    #app .config-column-right { order: 1; }
    #app .fixed-action-bar { padding: 8px; }
    #app .action-bar-content { flex-wrap: wrap; gap: 8px; }
    .action-bar-right { width: 100%; gap: 6px; }
    #app .action-bar-right .el-button { padding: 8px 6px; font-size: 11px; }
    #app .action-bar-stats { width: 100%; text-align: right; }
    #app .doc-grid { grid-template-columns: minmax(0,1fr); }
    #app .doc-toolbar { flex-wrap: wrap; }
    #app .content-wrapper { padding-bottom: 160px; }
    #app .brand-logo { width: 140px; height: 36px; }
    #app .top-navbar { padding: 0 10px; gap: 8px; }
    #app .top-navbar h1 { font-size: 12px; }
    #app .top-navbar .brand-area { min-width: 0; gap: 5px; }
    #app .top-navbar .user-info { gap: 4px; }
    #app .top-navbar .user-info > span { display: none; }
}
@media (prefers-reduced-motion: reduce) { #app .sidebar, #app .fixed-action-bar { transition: none; } }

.brand-logo.tianma-brand-logo{width:150px;max-height:56px;height:auto;object-fit:contain;background:#fff;padding:4px 8px;border-radius:4px}
