/* =========================================================
   养老机构运营评估平台 · 屏幕 UI 设计系统
   设计原则：美观大气 · 适老化（大字号/高对比/大按钮） · 简洁易辨识
   字号体系：全部基于 rem，--fs 由顶部工具条调节（0.92~1.6）
   ========================================================= */
:root {
  /* 主色：权威深蓝 */
  --blue:      #14365c;
  --blue-600:  #1d4e7e;
  --blue-700:  #0f2c4a;
  --blue-300:  #3f76ab;
  /* 强调：温暖金色（关键操作/提示，老人友好高可见） */
  --accent:      #c8922e;
  --accent-600:  #b07d1d;
  --accent-soft: #fbf3e2;
  /* 背景与表面 */
  --bg:      #eef2f6;
  --bg-2:    #e3eaf1;
  --surface: #ffffff;
  /* 文字 */
  --ink:       #1a2330;
  --ink-soft:  #4a5562;
  --ink-mute:  #7c8794;
  /* 线/标签 */
  --line: #d4dde6;
  --lab:  #eaf1f7;
  /* 状态色（强对比） */
  --ok: #1d7a45;   --ok-bg: #e3f5ea;
  --warn: #a8650a; --warn-bg: #fbeedd;
  --info: #1a5fb4; --info-bg: #e6f0fb;
  --danger: #b3261e; --danger-bg: #fbe3e1;
  /* 阴影与圆角 */
  --shadow-sm: 0 1px 3px rgba(20,54,92,.06);
  --shadow:    0 4px 18px rgba(20,54,92,.10);
  --shadow-lg: 0 10px 30px rgba(20,54,92,.16);
  --radius: 12px;
  --radius-sm: 8px;
  /* 适老化工具条高度 */
  --util-h: 3rem;
  /* 字号缩放（由工具条写入） */
  --fs: 1.06;
}

/* 高对比模式：纯黑底白字 + 金黄强调，满足 WCAG AAA */
html.hc {
  --bg: #000;  --bg-2: #0a0a0a;  --surface: #0a0a0a;
  --ink: #ffffff; --ink-soft: #f2f2f2; --ink-mute: #cfcfcf;
  --line: #ffffff; --lab: #1c1c1c;
  --blue: #ffffff; --blue-600: #ffffff; --blue-700: #ffffff; --blue-300: #ffffff;
  --accent: #ffd23f; --accent-600: #ffd23f; --accent-soft: #2a2200;
  --ok: #8cff9e; --ok-bg: #06220f; --warn: #ffd23f; --warn-bg: #2a2200;
  --info: #66ccff; --info-bg: #002033; --danger: #ff8a8a; --danger-bg: #2a0000;
  --shadow-sm: none; --shadow: none; --shadow-lg: none;
}

* { box-sizing: border-box; }

html { font-size: calc(17px * var(--fs)); scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Source Han Sans SC", sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
body.has-util { padding-top: var(--util-h); }

a { color: var(--blue-600); text-decoration: none; }
a:hover { text-decoration: underline; }

/* 焦点可见（无障碍） */
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* ===================== 顶部适老化工具条 ===================== */
.utilbar {
  position: fixed; top: 0; left: 0; right: 0; height: var(--util-h);
  z-index: 300;
  background: var(--blue-700);
  color: #fff;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 1rem;
  box-shadow: var(--shadow-sm);
}
.utilbar .ubrand { font-weight: 700; font-size: .92rem; letter-spacing: .5px; white-space: nowrap; }
.utilbar .utools { display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.utilbar .ulabel { font-size: .78rem; color: #cdd9e6; margin-right: .2rem; }
.utilbar .ubtn {
  background: rgba(255,255,255,.12); color: #fff; border: 1px solid rgba(255,255,255,.28);
  padding: .25rem .7rem; border-radius: 6px; cursor: pointer; font-size: .82rem; line-height: 1.2;
  min-height: 2rem; transition: background .15s, border-color .15s;
}
.utilbar .ubtn:hover { background: rgba(255,255,255,.24); }
.utilbar .ubtn.on { background: var(--accent); border-color: var(--accent); color: #1a1205; font-weight: 700; }
.utilbar .ubtn.hc.on { background: var(--accent); color: #1a1205; }

/* ===================== 顶部标题栏 ===================== */
.topbar {
  background: linear-gradient(135deg, var(--blue-700), var(--blue-600) 70%);
  color: #fff; padding: .85rem 1.4rem;
  display: flex; align-items: center; justify-content: space-between;
  box-shadow: var(--shadow);
  position: sticky; top: var(--util-h); z-index: 50;
}
.topbar h1 { font-size: 1.15rem; margin: 0; font-weight: 700; letter-spacing: .5px; }
.topbar .who { font-size: .85rem; color: #e8eef5; display: flex; align-items: center; gap: .6rem; }
.topbar .who button, .topbar .who a {
  background: rgba(255,255,255,.16); color: #fff; border: 1px solid rgba(255,255,255,.4);
  padding: .35rem .9rem; border-radius: 6px; cursor: pointer; font-size: .82rem;
}
.topbar .who button:hover, .topbar .who a:hover { background: rgba(255,255,255,.3); }

/* ===================== 布局容器 ===================== */
.wrap { max-width: 1180px; margin: 1.4rem auto; padding: 0 1.2rem; }
.hidden { display: none !important; }
.center { text-align: center; }
.muted { color: var(--ink-mute); font-size: .82rem; }

/* ===================== 卡片 ===================== */
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 1.2rem 1.4rem; margin-bottom: 1.1rem;
  box-shadow: var(--shadow-sm);
}
.card h2 {
  font-size: 1.12rem; margin: 0 0 .85rem; color: var(--blue);
  border-left: 5px solid var(--accent); padding-left: .6rem; font-weight: 700;
}
.card h3 { font-size: 1rem; color: var(--ink); margin: 1rem 0 .6rem; }
.note {
  background: var(--accent-soft); border: 1px solid #ecd49b; color: var(--accent-600);
  padding: .55rem .85rem; border-radius: var(--radius-sm); font-size: .82rem; margin: .4rem 0 .8rem;
}

/* ===================== 按钮 ===================== */
.row { display: flex; gap: .9rem; flex-wrap: wrap; align-items: center; }
.btn {
  background: var(--blue); color: #fff; border: 0;
  padding: .7rem 1.5rem; border-radius: var(--radius-sm); cursor: pointer;
  font-size: 1rem; font-weight: 600; line-height: 1.3;
  min-height: 3rem; transition: background .15s, transform .05s, box-shadow .15s;
  box-shadow: var(--shadow-sm);
}
.btn:hover { background: var(--blue-600); box-shadow: var(--shadow); }
.btn:active { transform: translateY(1px); }
.btn.sec { background: var(--blue-300); }
.btn.sec:hover { background: var(--blue-600); }
.btn.ghost { background: #fff; color: var(--blue); border: 2px solid var(--blue); }
.btn.ghost:hover { background: var(--lab); }
.btn.danger { background: var(--danger); }
.btn.danger:hover { filter: brightness(1.05); }
.btn:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; }
.btn-mini { background: #fff; border: 1px solid var(--line); border-radius: 5px; padding: .2rem .6rem; font-size: .78rem; cursor: pointer; margin-top: .25rem; }
.btn-mini:hover { background: var(--lab); }

/* ===================== 表单 ===================== */
label.fld { display: flex; flex-direction: column; gap: .35rem; font-size: .9rem; color: var(--ink-soft); font-weight: 600; }
label.fld > span::after { content: ""; }
label.fld.w30 { width: 30%; } label.fld.w45 { width: 45%; } label.fld.w100 { width: 100%; }
input[type=text], input[type=password], input[type=number], textarea, select {
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  padding: .6rem .7rem; font-size: 1rem; font-family: inherit; width: 100%;
  background: #fff; color: var(--ink); transition: border-color .15s, box-shadow .15s;
}
input:focus, textarea:focus, select:focus { border-color: var(--blue-300); box-shadow: 0 0 0 3px rgba(63,118,171,.18); outline: none; }
textarea { min-height: 5rem; resize: vertical; }
.field-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .9rem; }
@media (max-width: 640px) { .field-grid { grid-template-columns: 1fr; } label.fld.w30, label.fld.w45 { width: 100%; } }

/* ===================== 表格（表单渲染） ===================== */
table.frm { border-collapse: collapse; width: 100%; margin: .6rem 0 .4rem; table-layout: fixed; font-size: .92rem; background: #fff; }
table.frm th, table.frm td { border: 1px solid var(--line); padding: .5rem .65rem; vertical-align: middle; word-break: break-word; }
table.frm thead th { background: var(--lab); color: var(--blue); font-weight: 700; text-align: center; }
table.frm td.lbl { background: var(--lab); font-weight: 600; color: var(--ink); }
table.frm td.idx { text-align: center; width: 2rem; color: var(--ink-mute); }
table.frm th.cat { background: #dbe7f2; width: 5.5rem; color: var(--blue); font-weight: 700; }
table.frm td.area { white-space: pre-wrap; }
table.frm tr.sum td { background: var(--bg-2); }
table.frm .opts { line-height: 1.9; }
table.frm .opt { display: inline-flex; align-items: center; margin-right: .8rem; font-weight: 400; cursor: pointer; gap: .25rem; }
table.frm input[type=text], table.frm textarea, table.frm select { width: 100%; border: 1px solid #dde3ea; padding: .4rem .55rem; font-size: .92rem; }
table.frm textarea { min-height: 2.2rem; resize: vertical; }
table.frm input[type=radio], table.frm input[type=checkbox] { width: 1.1rem; height: 1.1rem; accent-color: var(--blue); }

/* 图片单元格（拍照核查 / 签字） */
table.frm td.imgcell { text-align: center; vertical-align: middle; }
table.frm td.imgcell img.thumb { max-width: 8rem; max-height: 6rem; border: 1px solid var(--line); display: block; margin: 0 auto .3rem; object-fit: contain; background: #fafafa; border-radius: 4px; }
table.frm td.imgcell input[type=file] { font-size: .8rem; width: 100%; }

/* 列表表格 */
table.list { width: 100%; border-collapse: collapse; font-size: .92rem; background: #fff; border-radius: var(--radius); overflow: hidden; }
table.list th, table.list td { border: 1px solid var(--line); padding: .7rem .9rem; text-align: left; vertical-align: middle; }
table.list th { background: var(--lab); color: var(--blue); font-weight: 700; }
table.list tr:nth-child(even) td { background: #fafcfe; }

/* ===================== 状态标签 ===================== */
.status-pill { display: inline-block; padding: .2rem .8rem; border-radius: 999px; font-size: .82rem; background: var(--info-bg); color: var(--info); font-weight: 600; white-space: nowrap; }
.status-pill.submitted { background: var(--warn-bg); color: var(--warn); }
.status-pill.reviewing { background: var(--info-bg); color: var(--info); }
.status-pill.approved { background: var(--ok-bg); color: var(--ok); }
.status-pill.rejected { background: var(--danger-bg); color: var(--danger); }
.status-pill.draft { background: var(--bg-2); color: var(--ink-soft); }

/* ===================== 报告双栏布局 ===================== */
.report-grid { display: grid; grid-template-columns: clamp(13rem, 21vw, 17rem) 1fr; gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.side { border-right: 1px solid var(--line); padding: .8rem 0; background: #f7fafd; max-height: 70vh; overflow: auto; }
.side a { display: block; padding: .6rem 1rem; color: var(--ink-soft); text-decoration: none; border-left: 4px solid transparent; font-size: .9rem; }
.side a:hover { background: var(--lab); text-decoration: none; }
.side a.active { background: var(--lab); border-left-color: var(--accent); color: var(--blue); font-weight: 700; }
.content { padding: .6rem 1.4rem 1.4rem; overflow: auto; max-height: 70vh; }
.block-title { font-size: 1.05rem; font-weight: 700; color: var(--blue); margin: 1.1rem 0 .5rem; padding-bottom: .3rem; border-bottom: 2px solid var(--line); }

/* ===================== 填写进度条 ===================== */
.progress { display: flex; align-items: center; gap: .8rem; margin: .6rem 0 1rem; }
.progress .track { flex: 1; height: .9rem; background: var(--bg-2); border-radius: 999px; overflow: hidden; border: 1px solid var(--line); }
.progress .fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--blue-600), var(--accent)); border-radius: 999px; transition: width .4s ease; }
.progress .ptext { font-size: .85rem; color: var(--ink-soft); font-weight: 600; white-space: nowrap; min-width: 6rem; text-align: right; }

/* ===================== 签名弹窗 ===================== */
.sig-modal { position: fixed; inset: 0; background: rgba(15,30,50,.5); display: none; align-items: center; justify-content: center; z-index: 99; }
.sig-modal .box { background: #fff; padding: 1.2rem 1.4rem; border-radius: var(--radius); width: min(30rem, 92vw); box-shadow: var(--shadow-lg); }
.sig-modal .box h3 { margin-top: 0; }
.sig-modal canvas { border: 1.5px dashed #9aa7b4; width: 100%; height: 11rem; max-width: 26rem; background: #fafafa; touch-action: none; border-radius: var(--radius-sm); display: block; }

/* ===================== Toast ===================== */
.toast { position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%); background: #2a3340; color: #fff; padding: .7rem 1.3rem; border-radius: 8px; font-size: .9rem; opacity: 0; transition: .25s; z-index: 400; pointer-events: none; box-shadow: var(--shadow); }
.toast.show { opacity: .97; }

/* ===================== 落地页（首页） ===================== */
.hero { background: linear-gradient(135deg, var(--blue-700), var(--blue-600) 55%, var(--blue-300)); color: #fff; border-radius: var(--radius); padding: 2.4rem 2.2rem; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; right: -3rem; top: -3rem; width: 12rem; height: 12rem; background: radial-gradient(circle, rgba(200,146,46,.35), transparent 70%); border-radius: 50%; }
.hero .gov { font-size: .9rem; letter-spacing: 3px; color: #d6e2ef; }
.hero h1 { font-size: 2rem; font-weight: 800; margin: .6rem 0 .4rem; letter-spacing: 1px; }
.hero p { font-size: 1.02rem; color: #e8eef5; max-width: 46rem; margin: .3rem 0 0; }
.hero .hero-actions { margin-top: 1.4rem; display: flex; gap: .9rem; flex-wrap: wrap; }
.hero .hero-actions .btn { background: #fff; color: var(--blue-700); }
.hero .hero-actions .btn:hover { background: var(--accent-soft); }
.hero .hero-actions .btn.ghost { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.6); }
.hero .hero-actions .btn.ghost:hover { background: rgba(255,255,255,.14); }

.role-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.3rem; margin-top: 1.3rem; }
@media (max-width: 820px) { .role-grid { grid-template-columns: 1fr; } }
.role-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem 1.4rem; text-align: center; box-shadow: var(--shadow-sm); transition: transform .15s, box-shadow .15s, border-color .15s; }
.role-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: var(--accent); }
.role-card .ico { width: 4rem; height: 4rem; margin: 0 auto .8rem; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 2.1rem; background: var(--lab); border: 2px solid var(--accent-soft); }
.role-card h3 { font-size: 1.2rem; color: var(--blue); margin: .2rem 0 .5rem; }
.role-card .role-desc { font-size: .9rem; color: var(--ink-soft); min-height: 4.2rem; }
.role-card .btn { margin-top: .9rem; width: 100%; }

.standards { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .4rem; }
.chip { background: var(--lab); border: 1px solid var(--line); color: var(--blue-600); padding: .35rem .8rem; border-radius: 999px; font-size: .82rem; font-weight: 600; }
.footer-note { margin-top: 1.4rem; text-align: center; color: var(--ink-mute); font-size: .82rem; line-height: 1.8; }

.codebox { font-family: "Cascadia Code", Consolas, monospace; background: var(--bg-2); padding: .9rem 1rem; border-radius: var(--radius-sm); color: var(--ink); border: 1px solid var(--line); white-space: pre-wrap; font-size: .85rem; }

/* ===================== 超级管理员控制台（原内联样式迁入） ===================== */
.tabs { display: flex; gap: .5rem; border-bottom: 1px solid var(--line); margin-bottom: .9rem; flex-wrap: wrap; }
.tabs button { background: #fff; border: 1px solid var(--line); border-bottom: 0; padding: .6rem 1.1rem; border-radius: var(--radius-sm) var(--radius-sm) 0 0; cursor: pointer; font-size: .95rem; color: var(--ink-soft); font-weight: 600; min-height: 2.6rem; }
.tabs button.active { background: var(--blue); color: #fff; border-color: var(--blue); }
.tabpane { display: none; }
.tabpane.active { display: block; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: .9rem; margin: .8rem 0; }
.stat { background: linear-gradient(180deg, #f4f8fc, #eaf1f7); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem; text-align: center; }
.stat b { display: block; font-size: 1.7rem; color: var(--blue); }
.stat span { font-size: .85rem; color: var(--ink-soft); }
table.admin { width: 100%; border-collapse: collapse; font-size: .9rem; background: #fff; }
table.admin th, table.admin td { border: 1px solid var(--line); padding: .6rem .8rem; text-align: left; vertical-align: middle; }
table.admin th { background: var(--lab); color: var(--blue); font-weight: 700; }
.inline-form { display: flex; gap: .7rem; flex-wrap: wrap; align-items: flex-end; background: #fafcff; border: 1px solid var(--line); padding: .9rem; border-radius: var(--radius); margin-bottom: .9rem; }
.inline-form label { display: flex; flex-direction: column; gap: .25rem; font-size: .82rem; color: var(--ink-soft); font-weight: 600; }
.inline-form input, .inline-form select { width: 9.5rem; }
.inline-form input[type=checkbox] { width: 1.2rem; height: 1.2rem; }
.pill { display: inline-block; padding: .15rem .6rem; border-radius: 999px; font-size: .8rem; font-weight: 600; }
.pill.pending { background: var(--warn-bg); color: var(--warn); }
.pill.approved { background: var(--ok-bg); color: var(--ok); }
.pill.rejected { background: var(--danger-bg); color: var(--danger); }
.mutiline { max-width: 14rem; word-break: break-all; color: var(--ink-soft); }

/* ===================== 返回顶部 ===================== */
.totop { position: fixed; right: 1.2rem; bottom: 1.2rem; width: 3rem; height: 3rem; border-radius: 50%; background: var(--blue); color: #fff; border: 0; font-size: 1.2rem; cursor: pointer; box-shadow: var(--shadow); z-index: 200; display: none; align-items: center; justify-content: center; }
.totop.show { display: flex; }

/* ===================== 表格横向滚动容器 ===================== */
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--radius); }
.table-wrap table.list, .table-wrap table.admin { min-width: 640px; }

/* ===================== 响应式 ===================== */
@media (max-width: 760px) {
  body.has-util { padding-top: 4.6rem; }
  body.has-util .topbar { top: 4.6rem; }
  .utilbar { height: auto; min-height: var(--util-h); padding: .35rem .7rem; flex-wrap: wrap; gap: .3rem; }
  .utilbar .ubrand { font-size: .82rem; }
  .utilbar .ubtn { padding: .2rem .5rem; font-size: .75rem; min-height: 1.7rem; }
  .topbar { padding: .65rem .9rem; flex-wrap: wrap; gap: .5rem; position: sticky; top: 4.6rem; }
  .topbar h1 { font-size: .98rem; line-height: 1.35; width: 100%; }
  .topbar .who { width: 100%; justify-content: flex-end; font-size: .8rem; }
  .topbar .who button, .topbar .who a { padding: .3rem .7rem; font-size: .78rem; min-height: 2.2rem; }
  .report-grid { grid-template-columns: 1fr; }
  .side { max-height: none; border-right: 0; border-bottom: 1px solid var(--line); display: flex; gap: .4rem; overflow-x: auto; }
  .side a { border-left: 0; border-bottom: 3px solid transparent; white-space: nowrap; }
  .side a.active { border-left: 0; border-bottom-color: var(--accent); }
  .content { max-height: none; padding: .6rem .9rem 1.2rem; }
  .wrap { padding: 0 .8rem; margin-top: .9rem; }
  .card { padding: 1rem; }
  .btn { padding: .75rem 1.2rem; min-height: 3.2rem; }
  .hero { padding: 1.4rem 1.2rem; }
  .hero h1 { font-size: 1.5rem; }
  .hero p { font-size: .95rem; }
  table.frm { font-size: .85rem; }
  table.frm th, table.frm td { padding: .4rem .45rem; }
}

@media (max-width: 860px) {
  .auth-split { grid-template-columns: 1fr; min-height: calc(100vh - 4.6rem); }
  .auth-hero { display: none; }
  .auth-form { padding: 1.2rem 1rem; align-items: flex-start; }
  .auth-card { padding: 1.4rem 1.2rem; }
}

/* ===================== 分屏登录（左品牌 / 右表单） ===================== */
.auth-split { display: grid; grid-template-columns: 1.05fr 1fr; min-height: calc(100vh - var(--util-h)); }
@media (max-width: 860px) { .auth-split { grid-template-columns: 1fr; } .auth-hero { display: none; } }
.auth-hero {
  position: relative; overflow: hidden; color: #fff;
  background: linear-gradient(150deg, var(--blue-700) 0%, var(--blue-600) 55%, var(--blue-300) 100%);
  display: flex; align-items: center; padding: 3rem 3rem;
}
.auth-hero::after { content: ""; position: absolute; right: -4rem; bottom: -4rem; width: 16rem; height: 16rem; background: radial-gradient(circle, rgba(200,146,46,.32), transparent 70%); border-radius: 50%; }
.auth-hero-inner { position: relative; z-index: 1; max-width: 30rem; }
.auth-hero .brand { display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; letter-spacing: 1px; color: #f3e6c8; font-size: .95rem; border: 1px solid rgba(255,255,255,.3); padding: .3rem .8rem; border-radius: 999px; margin-bottom: 1.4rem; }
.auth-hero h1 { font-size: 2.1rem; font-weight: 800; margin: 0 0 .8rem; line-height: 1.25; }
.auth-hero p { font-size: 1.02rem; color: #e8eef5; line-height: 1.8; }
.auth-hero ul.auth-points { list-style: none; padding: 0; margin: 1.6rem 0 0; }
.auth-hero ul.auth-points li { position: relative; padding-left: 1.6rem; margin-bottom: .8rem; color: #eaf1f8; font-size: .96rem; line-height: 1.6; }
.auth-hero ul.auth-points li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 1.2rem; height: 1.2rem; border-radius: 50%; background: var(--accent); color: #1a1205; font-weight: 800; text-align: center; line-height: 1.2rem; font-size: .8rem; }

.auth-form { display: flex; align-items: center; justify-content: center; padding: 2.5rem 2rem; background: var(--bg); }
.auth-card { width: 100%; max-width: 30rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 2rem 2rem 1.6rem; box-shadow: var(--shadow); }
.auth-card h2 { font-size: 1.3rem; color: var(--blue); margin: 0 0 .3rem; font-weight: 800; }
.auth-card .sub { color: var(--ink-mute); font-size: .88rem; margin: 0 0 1.2rem; }
.auth-tabs { display: flex; gap: .4rem; margin-bottom: 1.2rem; background: var(--bg-2); padding: .3rem; border-radius: 999px; }
.auth-tabs button { flex: 1; border: 0; background: transparent; padding: .55rem; border-radius: 999px; cursor: pointer; font-size: .95rem; font-weight: 600; color: var(--ink-soft); min-height: 2.6rem; }
.auth-tabs button.active { background: var(--blue); color: #fff; box-shadow: var(--shadow-sm); }
.auth-msg { min-height: 1.3rem; font-size: .88rem; margin: .6rem 0 0; }
.auth-msg.err { color: var(--danger); }
.auth-msg.ok { color: var(--ok); }
.auth-hint { margin-top: 1.3rem; font-size: .82rem; color: var(--ink-mute); text-align: center; }
.auth-hint a { color: var(--blue-600); }
.auth-back { display: inline-block; margin-bottom: 1rem; color: var(--blue-600); font-size: .9rem; cursor: pointer; }

/* ===================== 管理端/机构端登录壳（admin.html / agency.html） ===================== */
.login-shell { display: grid; grid-template-columns: 1.05fr 1fr; min-height: calc(100vh - var(--util-h) - 5rem); margin: 1.5rem 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
@media (max-width: 860px) {
  .login-shell { grid-template-columns: 1fr; min-height: auto; margin: .8rem 0; }
  .login-aside { display: none; }
  .login-card { border-radius: 0; }
}
.login-aside { position: relative; overflow: hidden; color: #fff; background: linear-gradient(150deg, var(--blue-700) 0%, var(--blue-600) 55%, var(--blue-300) 100%); display: flex; align-items: center; padding: 3rem; }
.login-aside-deco { position: absolute; right: -4rem; bottom: -4rem; width: 16rem; height: 16rem; background: radial-gradient(circle, rgba(200,146,46,.32), transparent 70%); border-radius: 50%; }
.login-aside-inner { position: relative; z-index: 1; max-width: 30rem; }
.login-emblem { width: 4rem; height: 4rem; border-radius: 50%; background: rgba(255,255,255,.14); border: 2px solid rgba(255,255,255,.35); display: flex; align-items: center; justify-content: center; font-size: 1.8rem; font-weight: 800; margin-bottom: 1.2rem; }
.login-aside h2 { font-size: 1.7rem; font-weight: 700; margin: 0 0 .8rem; }
.login-aside p { font-size: 1rem; color: #e8eef5; line-height: 1.8; }
.login-points { list-style: none; padding: 0; margin: 1.4rem 0 0; }
.login-points li { position: relative; padding-left: 1.5rem; margin-bottom: .7rem; color: #eaf1f8; font-size: .95rem; }
.login-points li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 1.1rem; height: 1.1rem; border-radius: 50%; background: var(--accent); color: #1a1205; font-weight: 800; text-align: center; line-height: 1.1rem; font-size: .75rem; }
.login-card { background: var(--surface); padding: 2.2rem; display: flex; flex-direction: column; justify-content: center; }
.login-head { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.6rem; }
.login-logo { width: 3.2rem; height: 3.2rem; border-radius: 50%; background: var(--blue); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; font-weight: 800; flex-shrink: 0; }
.login-head h1 { font-size: 1.25rem; color: var(--blue); margin: 0; font-weight: 800; }
.login-head p { font-size: .85rem; color: var(--ink-mute); margin: .2rem 0 0; }
.login-form { display: flex; flex-direction: column; gap: 1rem; }
.login-field { display: flex; flex-direction: column; gap: .35rem; font-size: .88rem; color: var(--ink-soft); font-weight: 600; }
.login-field input { border: 1.5px solid var(--line); border-radius: var(--radius-sm); padding: .7rem .8rem; font-size: 1rem; font-family: inherit; }
.login-msg { min-height: 1.3rem; font-size: .88rem; margin: 0; }
.login-msg.err { color: var(--danger); }
.login-btn { width: 100%; margin-top: .4rem; }
.login-foot { margin-top: 1.2rem; font-size: .8rem; color: var(--ink-mute); text-align: center; }
.login-card-wide { max-width: 42rem; margin: 0 auto; }
.login-tabs { display: flex; gap: .4rem; margin-bottom: 1.2rem; background: var(--bg-2); padding: .3rem; border-radius: 999px; }
.login-tab { flex: 1; border: 0; background: transparent; padding: .55rem; border-radius: 999px; cursor: pointer; font-size: .95rem; font-weight: 600; color: var(--ink-soft); min-height: 2.6rem; }
.login-tab.active { background: var(--blue); color: #fff; box-shadow: var(--shadow-sm); }
.login-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.login-field-full { grid-column: 1 / -1; }
@media (max-width: 640px) { .login-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) {
  .login-card { padding: 1.4rem 1rem; }
  .login-aside { padding: 1.8rem; }
  .login-head h1 { font-size: 1.1rem; }
}

/* ===================== 全局错误条（强提示脚本错误 / 浏览器内核过旧） ===================== */
#errbar { display: none; position: fixed; top: 0; left: 0; right: 0; z-index: 999; background: var(--danger); color: #fff; padding: .7rem 1.2rem; font-size: .9rem; font-weight: 600; text-align: center; box-shadow: var(--shadow); }
body.has-errbar { padding-top: calc(var(--util-h) + 2.6rem); }
body.has-errbar .topbar { top: calc(var(--util-h) + 2.6rem); }

/* ===================== 评估机构工作区 ===================== */
.kv-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .9rem 1.2rem; }
.kv-grid .full { grid-column: 1 / -1; }
.kv { display: flex; flex-direction: column; gap: .25rem; }
.kv label { font-size: .8rem; color: var(--ink-mute); font-weight: 600; }
.kv .val { font-size: 1rem; color: var(--ink); padding: .35rem 0; border-bottom: 1px dashed var(--line); word-break: break-all; }
.section-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .6rem; margin: 1.2rem 0 .6rem; }

