/* 红白公信：统一后台视觉基础 */
:root{--brand:#ad2935;--brand-soft:#f9edef;--ink:#202124;--text:#45474b;--muted:#6c7075;--line:#e5e7eb;--surface:#f7f8fa;--success:#39702c;--radius:8px;font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;color:var(--ink);background:#fff;font-size:15px;line-height:1.6}
*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button{cursor:pointer;border:1px solid transparent;border-radius:var(--radius);background:var(--brand);color:#fff;padding:10px 18px;font-weight:600;line-height:1.5;min-height:42px;transition:background .15s,color .15s,border-color .15s}button:hover{background:#92212c}button:disabled{opacity:.42;cursor:not-allowed}button:focus-visible{outline:3px solid #eab6bd;outline-offset:3px}.quiet{background:#fff;color:var(--text);border:1px solid #dfe1e5}.quiet:hover{color:var(--brand);background:#fcf7f8;border-color:#d7abb1}input,select,textarea{padding:10px 12px;min-height:44px;border:1px solid #dfe1e5;border-radius:var(--radius);background:#fff;color:var(--ink);max-width:100%}input:focus,select:focus,textarea:focus{outline:2px solid #e1a5ae;outline-offset:2px}label{display:grid;gap:8px;margin:14px 0;font-weight:500;color:var(--ink)}textarea{min-height:110px;resize:vertical;line-height:1.7}h1{font-size:32px;letter-spacing:0;line-height:1.3;margin:0 0 12px;font-weight:700}h2{font-size:21px;line-height:1.5}.muted,header p{color:var(--muted)}header p{font-size:15px;margin:0;line-height:1.7}.brand{font-size:20px;font-weight:700;letter-spacing:0}aside{position:fixed;inset:0 auto 0 0;width:216px;padding:28px 20px;background:#fff;border-right:1px solid var(--line)}nav{display:grid;gap:8px;margin-top:30px}nav button{text-align:left;background:transparent;color:var(--text);padding:12px 16px;min-height:46px;font-size:15px;border-radius:8px}nav button:hover{background:var(--surface);color:var(--brand)}nav button.active{background:var(--brand-soft);color:var(--brand)}.aside-bottom{display:grid;gap:10px}main{margin-left:216px;padding:36px 32px 40px;max-width:1800px}header{display:flex;justify-content:space-between;align-items:center;gap:24px;margin-bottom:36px}#add{flex-shrink:0;padding:12px 22px;min-height:46px}.toolbar{display:flex;gap:12px;align-items:center;margin-bottom:24px}.toolbar input{flex:1;min-width:120px}.toolbar select{min-width:150px}.toolbar button{min-height:44px;padding-left:24px;padding-right:24px}.table-wrap{background:#fff;border:1px solid var(--line);border-radius:10px;overflow:auto}table{border-collapse:collapse;width:100%;text-align:left;min-width:680px}th{background:#f7f7f8;color:#484b50;font-size:14px;font-weight:600;white-space:nowrap}th,td{padding:16px 18px;border-bottom:1px solid #eceef0;vertical-align:middle}tbody tr:last-child td{border-bottom:0}tbody tr:hover{background:#fdfafb}td:first-child{font-weight:500}th:first-child{width:46%}th:last-child{min-width:234px}td button{font-size:14px}.badge{display:inline-block;white-space:nowrap;padding:3px 9px;border-radius:5px;background:#edf5e9;color:var(--success);font-size:13px;font-weight:500;line-height:1.7}.off{background:#f1f2f4;color:#656a71}.sort-cell{font-variant-numeric:tabular-nums;text-align:center;color:#303339}.row-actions{white-space:nowrap}.row-action{font-weight:400;border:0;border-radius:4px;background:transparent;color:#656a71;padding:7px 8px;min-height:36px;font-size:14px}.row-action:hover{color:var(--brand);background:var(--brand-soft)}.row-action.primary{font-weight:600;color:var(--brand)}.row-action.danger{color:#a8323e;margin-left:10px;position:relative}.row-action.danger::before{content:'';position:absolute;left:-3px;top:11px;bottom:11px;border-left:1px solid var(--line)}.record-identity{display:flex;gap:14px;align-items:center;min-width:0}.record-thumb{width:44px;height:44px;flex:0 0 44px;border:1px solid var(--line);border-radius:8px;background:#fafafa;display:flex;align-items:center;justify-content:center;overflow:hidden;color:#7b8087}.record-thumb img{display:block;width:100%;height:100%;object-fit:cover}.record-thumb img.contain{object-fit:contain;background:#fff;padding:3px}.record-thumb .nav-icon{width:24px;height:24px}.record-copy{min-width:0;flex:1}.record-name{font-size:16px;font-weight:600;line-height:1.6;overflow-wrap:anywhere}.name-summary{font-size:13px;color:var(--muted);font-weight:400;line-height:1.6;margin-top:3px;max-width:380px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}footer{display:flex;justify-content:space-between;align-items:center;gap:16px;color:var(--muted);font-size:14px;margin-top:24px}footer>div{display:flex;align-items:center;gap:12px}footer span{margin:0}#page{font-variant-numeric:tabular-nums;color:var(--ink);font-weight:500}footer button{min-height:38px;padding:8px 14px;font-size:14px}#empty{padding:48px 24px;text-align:center;color:var(--muted)}.login{max-width:460px;margin:12vh auto;padding:32px}.login .brand{color:var(--brand)}.login h1{margin-top:36px}.login p{line-height:1.8;color:var(--muted)}.login form{margin-top:32px}.login button{width:100%;margin-top:12px}dialog{border:1px solid var(--line);border-radius:12px;max-width:800px;width:94vw;padding:28px;max-height:90vh;color:var(--ink)}dialog::backdrop{background:#17212b66}.dialog-head{display:flex;align-items:center;justify-content:space-between}.fields{display:grid;grid-template-columns:1fr 1fr;gap:0 24px}.wide{grid-column:1/-1}.dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:28px}.checkbox{display:flex;align-items:center;gap:10px}.checkbox input{width:18px;height:18px;min-height:0;accent-color:var(--brand)}#notice{position:fixed;top:max(20px,env(safe-area-inset-top));bottom:auto;left:50%;transform:translateX(-50%);margin:0;padding:14px 22px;color:#fff;background:#30353d;border:0;border-radius:8px;width:max-content;max-width:min(640px,calc(100vw - 32px));box-sizing:border-box;line-height:1.6;white-space:normal;overflow-wrap:anywhere;box-shadow:0 8px 28px #17212b26;pointer-events:none;z-index:1000}[hidden]{display:none!important}
.settings-block{background:#fff;border:1px solid var(--line);border-radius:14px;padding:25px;margin-bottom:20px}.settings-block h2,.settings-block h3{margin-top:0}.settings-block p{line-height:1.7}.settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.settings-grid .settings-block{margin:0}@media(max-width:650px){.settings-grid{grid-template-columns:1fr}}

.form-panel{max-width:1000px}.form-panel .dialog-head{margin-bottom:20px}.form-panel .dialog-actions{position:sticky;bottom:0;background:#fff;padding:18px 0 4px;border-top:1px solid #edf0eb}.settings-tabs{display:flex;gap:12px;margin-bottom:24px;flex-wrap:wrap}.settings-page-select{min-width:200px;margin-bottom:20px}.form-panel textarea{min-height:130px}

.article-toolbar{display:flex;gap:7px;flex-wrap:wrap;padding:12px;background:#f6f5f1;border-radius:10px;margin:15px 0}.article-toolbar button{font-size:12px;padding:7px 10px}.document-block{border:1px solid #e1e5df;border-radius:10px;padding:15px;margin:15px 0;background:white}.block-controls{display:flex;gap:7px;align-items:center;flex-wrap:wrap;border-bottom:1px solid #eef0eb;padding-bottom:10px;margin-bottom:14px}.block-controls button{padding:6px 9px;font-size:12px}.block-controls select{padding:6px;font-size:12px}.block-editable{min-height:90px;white-space:pre-wrap;word-break:break-word;line-height:1.9;padding:8px;outline:none}.block-editable:focus{box-shadow:0 0 0 2px #e9ced0;border-radius:6px}.block-editable[data-align=center]{text-align:center}.block-editable[data-align=right]{text-align:right}.block-editable a{color:#a52b35;text-decoration:underline}.block-editable.type-heading{font-size:22px;font-weight:650}.block-editable.type-quote{background:#f8f5ef;border-left:3px solid #b78486;padding-left:18px;color:#6e796f}.block-editable.type-list{padding-left:20px;background:#fafbf9}.body-image-preview{display:block;max-width:100%;max-height:400px;margin:auto;border-radius:8px}.article-editor .muted{font-size:12px;line-height:1.7}

.upload-hint{margin:2px 0 0;color:var(--muted);font-size:12px;font-weight:400;line-height:1.7;overflow-wrap:anywhere}.article-editor>.upload-hint{margin:0 0 18px}

/* 编辑弹窗：标题栏在滚动区域外，内嵌表单仍使用自然页面布局。 */
#editor{padding:0;overflow:hidden}#editor>#editForm{display:flex;flex-direction:column;max-height:calc(90vh - 2px);max-height:calc(90dvh - 2px);min-height:0}#editor .dialog-head{flex-shrink:0;gap:16px;padding:20px 28px;border-bottom:1px solid var(--line);background:#fff}#editor .dialog-head h2{margin:0;min-width:0;overflow-wrap:anywhere}#editor .dialog-head button{flex-shrink:0}#editor .dialog-body{min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:0 28px 28px;scroll-padding-top:16px}
@media(max-width:600px){#editor .dialog-head{padding:16px 20px}#editor .dialog-body{padding:0 20px 20px}}

.pinned-label{display:inline-block;margin-left:10px;padding:3px 7px;border-radius:5px;background:#f8e9e8;color:#a52b35;font-size:11px;font-weight:500;vertical-align:middle}

.dialog-head-actions{display:flex;align-items:center;gap:10px;flex-shrink:0}#editor .dialog-head h2{flex:1}

.sort-field input{width:140px;max-width:100%}.sort-field{justify-items:start}

.nav-icon{width:20px;height:20px;flex-shrink:0;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}nav button,.aside-bottom button{display:flex;align-items:center;gap:12px}aside>.brand{line-height:1.6}aside>.muted{font-size:13px;line-height:1.6;margin-top:8px}

/* 分类二级菜单，导航独立滚动，底部账号操作保持可见。 */
aside{display:flex;flex-direction:column;overflow:hidden}aside>.brand,aside>.muted{flex-shrink:0}nav{flex:1;min-height:0;overflow-y:auto;align-content:start;margin-top:26px;scrollbar-width:thin}.aside-bottom{position:static;margin-top:20px;flex-shrink:0}.submenu-arrow{margin-left:auto;font-size:24px;line-height:1;transition:transform .15s}nav button[aria-expanded=true] .submenu-arrow{transform:rotate(90deg)}.category-submenu{display:grid;gap:4px;padding:0 0 4px 30px}.category-submenu button{font-size:13px;padding:10px 14px;gap:8px}.category-submenu button::before{content:'';width:5px;height:5px;flex-shrink:0;border-radius:50%;background:currentColor;opacity:.6}@media(max-width:850px){aside{display:block;overflow:visible}nav{flex:none;overflow-x:auto;overflow-y:visible;align-content:normal}.aside-bottom{margin-top:15px}.category-submenu{min-width:136px;padding-left:8px}}

/* 共用表单与导航同一套字号、颜色与间距。 */
aside>.brand{font-size:20px;line-height:1.5}aside>.muted{font-size:14px;color:var(--muted);line-height:1.6;margin-top:8px}nav{margin-top:32px}nav button.active{background:var(--brand-soft);color:var(--brand)}.nav-icon{width:20px;height:20px}.aside-bottom button{font-size:14px;justify-content:flex-start;min-height:42px}.form-section-title{font-size:16px;font-weight:650;color:var(--ink);margin:24px 0 0;padding:0 0 10px;border-bottom:1px solid var(--line)}.form-section-title+label{margin-top:16px}.upload{gap:10px}.upload-content{display:flex;align-items:center;flex-wrap:wrap;gap:16px;min-height:48px}.image-list{display:flex;gap:12px;flex-wrap:wrap}.image-list:empty{display:none}.image-list img{width:72px;height:72px;object-fit:contain;border:1px solid var(--line);border-radius:8px;background:#fff}.image-item{display:grid;gap:6px;justify-items:center}.image-item button{font-size:12px;min-height:28px;padding:3px 10px}.upload-trigger{display:inline-flex;gap:8px;align-items:center;padding:10px 14px;font-size:14px;min-height:42px}.upload-trigger .nav-icon{width:18px;height:18px}.upload-hint,.hint{font-size:13px;line-height:1.7;color:var(--muted);font-weight:400;margin:0}.settings-block{border-color:var(--line);border-radius:10px}.article-toolbar{background:var(--surface)}.article-toolbar button,.block-controls button{min-height:32px}.block-controls select{min-height:32px}.document-block{border-color:var(--line)}.block-editable.type-quote{background:#fbf6f7;color:var(--text);border-left-color:#c86a75}.block-editable.type-list{background:var(--surface)}.article-editor .muted{font-size:13px;color:var(--muted)}#editor .dialog-head{padding:20px 28px;border-bottom-color:var(--line)}#editor .dialog-body{padding-top:6px}.pinned-label{font-size:12px;background:var(--brand-soft);color:var(--brand);padding:2px 7px}.sort-field input{width:120px}.category-submenu button{font-size:14px;min-height:38px}
@media(max-width:1100px) and (min-width:851px){aside{width:200px;padding:28px 16px}main{margin-left:200px;padding:30px 24px}aside>.brand{font-size:19px}th,td{padding:15px 14px}.row-action{padding:7px 6px}.toolbar select{min-width:125px}}
@media(max-width:850px){aside{position:static;width:auto;padding:20px;display:block;overflow:visible}aside>.brand{font-size:20px}nav{display:flex;overflow-x:auto;overflow-y:visible;flex:none;margin-top:20px;align-content:normal}nav button{white-space:nowrap;min-height:42px}.aside-bottom{display:flex;position:static;margin-top:16px;flex-wrap:wrap}.category-submenu{min-width:136px;padding-left:8px}main{margin:0;padding:28px 20px}header{margin-bottom:28px;gap:16px}h1{font-size:28px}.toolbar{flex-wrap:wrap}.toolbar input{min-width:180px}.toolbar select{min-width:120px}}
@media(max-width:600px){.fields{grid-template-columns:1fr;gap:0}header{align-items:flex-start}#add{padding:10px 12px;font-size:14px}header p{font-size:14px}footer{align-items:flex-start;flex-wrap:wrap}#editor .dialog-head{padding:18px 20px}#editor .dialog-body{padding:6px 20px 24px}.dialog-head-actions{gap:6px}.dialog-head-actions button{padding:8px 12px}#editor .dialog-head h2{font-size:19px}.toolbar input{flex-basis:100%}}

/* 对照选定稿调整桌面主区域与导航的比例。 */
@media(min-width:1101px){aside{width:272px;padding:32px 24px}aside>.brand{font-size:26px}aside>.muted{font-size:16px;margin-top:10px}nav{margin-top:36px;gap:10px}nav button{font-size:18px;min-height:52px;padding:13px 16px}.nav-icon{width:22px;height:22px}.aside-bottom button{font-size:16px;min-height:46px}main{margin-left:272px;padding:48px 40px}h1{font-size:42px;line-height:1.3}header{margin-bottom:44px}header p{font-size:17px}#add{font-size:17px;min-height:52px;padding:13px 24px}.toolbar{margin-bottom:30px}.toolbar input,.toolbar select,.toolbar button{font-size:16px;min-height:50px}.toolbar select{min-width:200px}.toolbar button{padding-left:26px;padding-right:26px}th{font-size:16px}th,td{padding:17px 20px}.record-thumb{width:50px;height:50px;flex-basis:50px}.record-name{font-size:18px}.name-summary{font-size:14px;margin-top:4px}.badge{font-size:14px}.row-action{font-size:15px;min-height:40px;padding:8px}.row-action.primary{font-size:16px}footer{font-size:15px;margin-top:30px}.sort-cell{font-size:16px}}

thead th:nth-last-child(2){text-align:center}

/* 登录页：平台名称为主标题，欢迎语作为次级标题。 */
.login .brand{font-size:clamp(28px,6vw,44px);font-weight:750;line-height:1.3;letter-spacing:0;color:var(--brand)}
.login h1{font-size:clamp(24px,4.8vw,30px);font-weight:650;line-height:1.4;margin:28px 0 12px}

/* 协会红侧栏：白色文字与图标，选中项使用白底红字。 */
aside{background:var(--brand);border-right-color:var(--brand);color:#fff}
aside>.brand{color:#fff}
aside>.muted{color:#f6dce0}
aside nav button{color:#fff}
aside nav button:hover{background:rgba(255,255,255,.12);color:#fff}
aside nav button.active,aside nav button.active:hover{background:#fff;color:var(--brand)}
aside .aside-bottom button{background:transparent;border-color:rgba(255,255,255,.4);color:#fff}
aside .aside-bottom button:hover{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.7);color:#fff}
aside button:focus-visible{outline-color:#fff}
aside nav{scrollbar-color:rgba(255,255,255,.5) transparent}
aside nav::-webkit-scrollbar{width:6px;height:6px}
aside nav::-webkit-scrollbar-track{background:transparent}
aside nav::-webkit-scrollbar-thumb{background:rgba(255,255,255,.5);border-radius:6px}

@media(min-width:1101px){aside{width:288px}aside>.brand{font-size:28px}nav button{font-size:20px}.nav-icon{width:24px;height:24px}main{margin-left:288px;padding:52px 44px}h1{font-size:44px}header{margin-bottom:48px}.toolbar{margin-bottom:34px}.toolbar input,.toolbar select,.toolbar button{font-size:17px;min-height:54px}.toolbar select{min-width:220px}.record-thumb{width:56px;height:56px;flex-basis:56px}.record-name{font-size:20px}.name-summary{font-size:16px}.badge{font-size:16px}th{font-size:17px}.row-action{font-size:16px}.row-action.primary{font-size:17px}footer{font-size:16px}}

/* Global mini-program theme settings */
.theme-presets{display:flex;gap:10px;flex-wrap:wrap}.theme-preview{border:1px solid #e1e3e7;border-radius:14px;overflow:hidden}.theme-preview-header{background:var(--preview-color,#ad2935);color:var(--preview-ink,#fff);padding:28px;font-size:24px;font-weight:650}.theme-preview-header small{display:block;font-size:14px;font-weight:400;margin-top:10px}.theme-preview-body{padding:24px;display:flex;align-items:center;justify-content:space-between;background:#fff}.theme-preview-tag{border:1px solid #dfe3e7;border-radius:6px;padding:6px 12px}.theme-preview-button{background:var(--preview-color,#ad2935);color:var(--preview-ink,#fff);border:0}input[type=color]{width:100%;height:44px;padding:4px;cursor:pointer}
