/* Global admin palette aligned with the original WeCom workspace. */
:root {
  --bg:#f3f7fb; --surface:#fff; --surface-soft:#f7f9fc; --ink:#202a3c; --muted:#7d8797;
  --line:#dfe5ec; --line-soft:#edf1f5; --primary-neutral:#1677ff; --primary-neutral-dark:#1268df;
  --primary-neutral-soft:#eaf3ff; --accent:#1677ff; --accent-dark:#1268df; --accent-soft:#eaf3ff;
}
body,.content,.main-area { background:#f3f7fb; color:#202a3c; }
.topbar,.panel,.table-panel,.record-card,.plan-card,.settings-section,.account-summary>div,
.ip-panel,.ip-commandbar,.ip-history,.tl-card,.tl-list article,.tl-food-table,.te-header,.te-meta,.te-footer { border-color:#dfe5ec; background:#fff; box-shadow:0 5px 18px rgba(33,48,70,.045); }
.topbar { border-bottom:1px solid #e5eaf0; }
.page-head p,.topbar-title p { color:#7d8797; }
.sidebar { border-right:1px solid #dfe5ec; background:#fff; color:#263247; box-shadow:4px 0 18px rgba(33,48,70,.04); }
.sidebar-brand { border-bottom-color:#edf1f5; }
.sidebar-brand .brand-mark,.brand-mark { background:linear-gradient(145deg,#4595ff,#1677ff); box-shadow:0 7px 18px rgba(22,119,255,.20); }
.sidebar-brand strong { color:#202a3c; }
.sidebar-brand span,.sidebar-section-label { color:#8a94a4; }
.main-nav button { color:#59677a; }
.main-nav button:hover { background:#f3f7fb; color:#1677ff; }
.main-nav button.active { background:#eaf3ff !important; color:#1677ff !important; box-shadow:inset 3px 0 #1677ff !important; }
.main-nav button.active::before { display:none; }
.main-nav button.active .nav-icon { color:#1677ff; }
.sidebar-foot { border-color:#dfe5ec; background:#f7f9fc; }
.sidebar-foot span { color:#8a94a4; }
.sidebar-foot strong { color:#526073; }
.sidebar-foot i { background:#14c982 !important; box-shadow:0 0 0 3px #e5faf2 !important; }
.primary-button,.command-button { border-color:#1677ff !important; background:#1677ff !important; color:#fff !important; box-shadow:0 4px 12px rgba(22,119,255,.15) !important; }
.primary-button:hover,.command-button:hover { border-color:#1268df !important; background:#1268df !important; }
.ghost-button,.table-action,.filter-control,.ip-add-row { border-color:#d8e2ee; background:#fff; color:#526073; }
.ghost-button:hover,.table-action:hover,.ip-add-row:hover { border-color:#9bc7f8; background:#f3f7fb; color:#1677ff; }
.panel-action,.table-action,.page-head p,.tl-card header span,.tl-list article>div>span,.te-header>div>span { color:#1677ff !important; }
button.active,.ip-section-nav button.active,.tl-tabs button.active,.te-nav button.active { border-color:#1677ff !important; background:#eaf3ff !important; color:#1677ff !important; box-shadow:inset 0 0 0 1px #cfe0ff !important; }
.te-nav button.active i { border-color:#1677ff; }
.tl-tabs b { background:rgba(22,119,255,.10); }
button.active b { background:rgba(22,119,255,.12); }
input:focus,select:focus,textarea:focus,.ip-field input:focus,.ip-field textarea:focus { border-color:#78acf1 !important; box-shadow:0 0 0 3px rgba(22,119,255,.08) !important; }
.metric-card,.ip-facts>div,.task-column,.detail-metrics div,.review-food,.tl-food-table>div.head { background:#f7f9fc; }
.metric-card,.ip-patient-banner,.tl-hero { border-color:#dfe5ec; background:linear-gradient(125deg,#fff,#f3f7fb); }
.metric-icon,.ip-avatar,.avatar,.user-menu>div:first-child { background:#eaf3ff; color:#1677ff; }
.status-pill.low,.review-pill.reviewed,.binding-pill.bound { background:#e5f7ed !important; color:#10a264 !important; }
.status-pill.medium,.review-pill.pending { background:#fff3df !important; color:#c37813 !important; }
.status-pill.high,.review-pill.rejected { background:#ffebea !important; color:#d44f4f !important; }
.ip-stage-index,.ip-timeline i { background:#eaf3ff; color:#1677ff; }
.ip-macro-check.ok,.ip-publish-checks>div.ok,.ip-publish-checks>div.ok i,.ip-checklist i.done { background:#e5f7ed; color:#10a264; }
.ip-total-kcal strong,.plan-card .plan-metric,.ip-history article>span { color:#1677ff; }
.ip-nutrient-bars b.good { background:#21b978; }
.tl-card header em { background:#eaf3ff; color:#1677ff; }
.login-view { background:radial-gradient(circle at 18% 16%,rgba(22,119,255,.10),transparent 30%),radial-gradient(circle at 84% 82%,rgba(20,201,130,.07),transparent 28%),#f3f7fb; }
.login-panel { border-color:#dfe5ec; background:rgba(255,255,255,.98); box-shadow:0 22px 60px rgba(33,48,70,.12); }
.login-copy>p { color:#1677ff; }
.login-form input { border-color:#dfe5ec; background:#f7f9fc; }
.login-security i { background:#14c982; box-shadow:0 0 0 3px #e5faf2; }
.toast { border-left-color:#1677ff; background:#263247; }

/* Assessment and 24-hour dietary recall. */
.ip-assessment-workspace { gap:18px; }
.ip-assessment-basic { grid-template-columns:repeat(4,minmax(0,1fr)); }
.ip-assessment-basic .ip-field-wide { grid-column:span 2; }
.ip-field select { width:100%; height:42px; padding:0 11px; border:1px solid #d7dee8; border-radius:6px; background:#fff; color:var(--ip-ink); outline:none; }
.ip-field input[readonly] { background:#f4f7fb; color:#526073; cursor:default; }
.ip-recall-table { overflow:hidden; border:1px solid #dce3ec; border-radius:9px; }
.ip-recall-table .head,.ip-recall-table .row { display:grid; grid-template-columns:100px minmax(300px,1fr) 160px; align-items:center; gap:12px; padding:10px 14px; }
.ip-recall-table .head { min-height:42px; background:#f3f7fb; color:#667085; font-size:12px; }
.ip-recall-table .row { min-height:76px; border-top:1px solid #e8edf3; }
.ip-recall-table .row strong { color:#263247; font-size:14px; }
.ip-recall-table textarea { width:100%; min-height:54px; padding:9px 11px; resize:vertical; border:1px solid #d7dee8; border-radius:6px; color:#263247; font:inherit; line-height:1.5; outline:none; }
.ip-recall-table label { position:relative; display:block; }
.ip-recall-table input { width:100%; height:40px; padding:0 48px 0 10px; border:1px solid #d7dee8; border-radius:6px; color:#263247; outline:none; }
.ip-recall-table label span { position:absolute; right:10px; top:12px; color:#8a94a4; font-size:11px; }
.ip-recall-table textarea:focus,.ip-recall-table input:focus,.ip-field select:focus { border-color:#78acf1; box-shadow:0 0 0 3px rgba(22,119,255,.08); }
.ip-recall-summary { margin-top:18px; padding:16px; border:1px solid #dce3ec; border-radius:9px; background:#f9fbfe; }
.ip-recall-summary header { display:flex; align-items:center; justify-content:space-between; gap:18px; margin-bottom:12px; }
.ip-recall-summary h4 { margin:0; color:#263247; font-size:15px; }
.ip-recall-summary p { margin:5px 0 0; color:#7d8797; font-size:12px; }
.ip-recall-summary textarea { width:100%; min-height:130px; padding:12px 13px; resize:vertical; border:1px solid #d7dee8; border-radius:7px; background:#fff; color:#263247; font:inherit; line-height:1.7; outline:none; }
.ip-recall-summary>small { display:block; margin-top:8px; color:#8a94a4; font-size:11px; }
.ip-recall-summary .ghost-button { flex:0 0 auto; border-color:#9bc4fb; background:#edf5ff; color:#1677ff; }
.ip-recall-summary .ghost-button:hover { border-color:#1677ff; background:#e5f1ff; }
@media (max-width:1180px) { .ip-assessment-basic { grid-template-columns:repeat(2,minmax(0,1fr)); } }
/* 干预方案新版可追加记录表单 */
.ip-prescription-workspace{max-width:1500px;margin:0 auto}.ip-nutrition-template-bar{display:flex;align-items:end;gap:12px;margin-bottom:18px;padding:14px;background:#f7f9fc;border:1px solid #e5eaf2;border-radius:10px}.ip-nutrition-template-bar label{flex:1;display:grid;gap:7px;color:#4b5565;font-weight:600}.ip-nutrition-template-bar :is(select,input){min-height:40px;border:1px solid #d8dee9;border-radius:8px;background:#fff;padding:0 12px}.ip-prescription-tip{margin:16px 0 12px;padding:11px 14px;border-left:3px solid #3178e8;background:#f4f8ff;color:#41516a;border-radius:4px 8px 8px 4px}.ip-record-table{width:100%;overflow-x:auto}.ip-record-head,.ip-record-row{display:grid;grid-template-columns:repeat(var(--ip-cols),minmax(150px,1fr)) 38px;gap:10px;align-items:stretch;min-width:620px}.ip-record-head{padding:0 0 8px;color:#5c6678;font-size:13px}.ip-record-head b{padding:0 10px}.ip-record-row{padding:9px 0;border-top:1px solid #edf0f5}.ip-record-row textarea{min-height:64px;width:100%;resize:vertical;border:1px solid #d8dee9;border-radius:8px;background:#fff;padding:10px 11px;color:#1e2a3a}.ip-bottom-add{width:100%;min-height:44px;margin-top:12px;border:1px dashed #9db7df;border-radius:9px;background:#f7faff;color:#2565c7;cursor:pointer;font-weight:600}.ip-bottom-add:hover{background:#eef5ff;border-color:#3178e8}.ip-bottom-add span{margin-right:6px;font-size:18px}.ip-bottom-add.compact{min-height:36px;margin-top:8px}.ip-stage-path-card{grid-template-columns:38px minmax(160px,1fr) minmax(190px,1fr) minmax(260px,2fr) 38px}.ip-exercise-phases,.ip-monitor-goals,.ip-line-list{display:grid;gap:14px}.ip-exercise-phase,.ip-monitor-goal{padding:16px;border:1px solid #e1e6ef;border-radius:11px;background:#fbfcfe}.ip-exercise-phase>header,.ip-monitor-goal>header{display:flex;align-items:flex-end;gap:12px;margin-bottom:14px}.ip-exercise-phase>header strong{flex:1;font-size:16px}.ip-monitor-goal>header label{flex:1;display:grid;gap:7px;color:#4b5565;font-weight:600}.ip-monitor-goal input,.ip-subtasks input{min-height:40px;border:1px solid #d8dee9;border-radius:8px;background:#fff;padding:0 11px}.ip-subtasks{display:grid;gap:8px;padding-left:22px}.ip-subtasks>div{display:grid;grid-template-columns:1fr 34px;gap:8px}.ip-subtasks>div button{border:0;background:transparent;color:#a24747;cursor:pointer;font-size:19px}.ip-line-list>div{display:grid;grid-template-columns:1fr 38px;gap:10px}.ip-line-list textarea{min-height:58px;border:1px solid #d8dee9;border-radius:8px;padding:10px 11px;resize:vertical}@media(max-width:900px){.ip-stage-path-card{grid-template-columns:38px 1fr 38px}.ip-stage-path-card label{grid-column:2}.ip-stage-path-card .wide{grid-column:2}.ip-stage-path-card .ip-icon-danger{grid-column:3;grid-row:1}.ip-nutrition-template-bar{align-items:stretch;flex-direction:column}}
.ip-exercise-phase-fields{grid-template-columns:1fr}.ip-exercise-phase-fields label{display:grid;gap:7px;color:#4b5565;font-weight:600}.ip-exercise-phase-fields :is(input,textarea){width:100%;border:1px solid #d8dee9;border-radius:8px;background:#fff;padding:10px 11px}.ip-exercise-phase-fields textarea{min-height:74px;resize:vertical}.ip-pair-list{display:grid;gap:10px}.ip-pair-list>div{display:grid;grid-template-columns:minmax(160px,.55fr) minmax(300px,1.45fr) 38px;gap:10px;align-items:stretch}.ip-pair-list :is(input,textarea),.ip-subtasks textarea{width:100%;border:1px solid #d8dee9;border-radius:8px;background:#fff;padding:10px 11px}.ip-pair-list textarea,.ip-subtasks textarea{min-height:64px;resize:vertical}.ip-subtasks>div{grid-template-columns:minmax(150px,.5fr) minmax(280px,1.5fr) 34px;align-items:stretch}.ip-food-amount{grid-template-columns:minmax(52px,1fr) 58px!important;gap:5px!important}.te-back.ghost-button{display:inline-flex;margin:0 0 12px;padding:0 14px;min-height:34px;align-items:center}

.ip-assessment-basic textarea{min-height:72px;max-height:110px}
.ip-plan-name-combobox{position:relative;display:grid;grid-template-columns:1fr 42px}.ip-plan-name-combobox>input{width:100%;border-radius:8px 0 0 8px!important;border-right:0!important}.ip-plan-name-combobox>button{min-height:40px;border:1px solid #d8dee9;border-radius:0 8px 8px 0;background:#fff;color:#526174;font-size:22px;line-height:1;cursor:pointer}.ip-plan-name-combobox>button:hover,.ip-plan-name-combobox>button.open{background:#eef5ff;color:#1677ff}.ip-plan-name-combobox>button.open{transform:none}.ip-plan-template-menu{position:absolute;z-index:30;top:calc(100% + 6px);left:0;right:0;max-height:280px;overflow:auto;padding:6px;background:#fff;border:1px solid #d9e0ea;border-radius:9px;box-shadow:0 10px 30px rgba(31,45,68,.15)}.ip-plan-template-menu[hidden]{display:none}.ip-plan-template-menu>button{display:flex;width:100%;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border:0;border-radius:7px;background:#fff;text-align:left;cursor:pointer}.ip-plan-template-menu>button:hover{background:#eef5ff;color:#1268df}.ip-plan-template-menu>button strong{font-size:14px}.ip-plan-template-menu>button small{color:#8a94a4;font-size:12px}.ip-template-empty{padding:16px;text-align:center;color:#8a94a4;font-weight:400}
.ip-meal-plan-table{overflow-x:auto}.ip-meal-plan-head,.ip-meal-plan-row{display:grid;grid-template-columns:minmax(90px,.65fr) minmax(90px,.65fr) minmax(320px,2.2fr) minmax(220px,1.4fr) 38px;gap:10px;min-width:900px;align-items:stretch}.ip-meal-plan-head{padding:0 10px 8px;color:#5c6678;font-size:13px}.ip-meal-plan-row{padding:10px 0;border-top:1px solid #edf0f5}.ip-meal-plan-row>textarea{min-height:74px;border:1px solid #d8dee9;border-radius:8px;padding:10px;resize:vertical}.ip-meal-food-trigger{display:flex;flex-direction:column;justify-content:space-between;gap:8px;min-height:74px;border:1px solid #cfd8e6;border-radius:8px;background:#fff;padding:9px 11px;text-align:left;cursor:pointer}.ip-meal-food-trigger:hover{border-color:#1677ff;background:#f8fbff}.ip-meal-food-trigger>small{padding-top:7px;border-top:1px dashed #dce3ed;color:#65738a}.ip-meal-food-lines,.ip-meal-tip-lines{display:grid;gap:5px}.ip-meal-food-lines>div{display:grid;grid-template-columns:1fr auto;gap:10px}.ip-meal-food-lines em{color:#1677ff;font-style:normal}.ip-meal-tip-lines{min-height:74px;padding:10px;border:1px solid #e3e7ee;border-radius:8px;background:#fafbfc;color:#526174}.ip-meal-tip-lines>div+div{padding-top:5px;border-top:1px dashed #e1e6ed}.ip-meal-summary{margin-top:18px;padding:16px;border:1px solid #dfe5ee;border-radius:10px;background:#f8fafc}.ip-meal-summary>strong{display:block;margin-bottom:12px}.ip-meal-summary>div{display:grid;grid-template-columns:repeat(4,minmax(130px,1fr));gap:10px}.ip-meal-summary span{display:grid;gap:5px;padding:11px 13px;border-radius:8px;background:#fff;color:#6c7788}.ip-meal-summary b{color:#1e2a3a;font-size:17px}.ip-meal-food-editor{overflow-x:auto}.ip-meal-food-editor-head,.ip-meal-food-editor-row{display:grid;grid-template-columns:minmax(210px,1.7fr) 95px 105px 95px 95px 95px minmax(180px,1.4fr) 34px;gap:8px;min-width:1050px;align-items:stretch}.ip-meal-food-editor-head{padding:0 8px 8px;color:#5c6678;font-size:12px}.ip-meal-food-editor-row{padding:10px 0;border-top:1px solid #edf0f5}.ip-meal-food-editor-row>div{display:grid;gap:6px}.ip-meal-food-editor-row input,.ip-meal-food-editor-row select,.ip-meal-food-editor-row textarea{width:100%;min-height:38px;border:1px solid #d8dee9;border-radius:7px;background:#fff;padding:7px 8px}.ip-meal-food-editor-row textarea{min-height:76px;resize:vertical}.ip-meal-food-editor-row>button{border:0;background:transparent;color:#a24747;font-size:20px;cursor:pointer}@media(max-width:900px){.ip-meal-summary>div{grid-template-columns:repeat(2,1fr)}}
.ip-meal-food-pairs{grid-column:3/5;padding:0;overflow:hidden}.ip-meal-food-pairs>div>div{display:grid;grid-template-columns:minmax(320px,2.2fr) minmax(220px,1.4fr);align-items:stretch}.ip-meal-food-pairs>div>div+div{border-top:1px dashed #e1e6ed}.ip-meal-food-pairs>div>div>span{display:flex;align-items:center;gap:10px;min-height:42px;padding:9px 11px}.ip-meal-food-pairs>div>div>span+span{border-left:1px solid #e3e7ee;background:#fafbfc;color:#526174}.ip-meal-food-pairs>div>div>span:first-child{justify-content:space-between}.ip-meal-food-pairs>div>div em{color:#1677ff;font-style:normal}.ip-meal-food-pairs>small{margin:0 11px 9px}
