/* ============ 优嬴财务系统 全局样式 ============ */
:root {
  --primary: #0E7490;
  --primary-dark: #0B5A6F;
  --primary-light: #E8F4F8;
  --sidebar-bg: #0F2E3D;
  --sidebar-active: #0E7490;
  --bg: #F1F5F9;
  --card: #FFFFFF;
  --text: #1F2937;
  --muted: #6B7280;
  --income: #16A34A;
  --expense: #DC2626;
  --gold: #D97706;
  --border: #E5E7EB;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(15, 46, 61, .08), 0 4px 14px rgba(15, 46, 61, .06);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
}
a { color: var(--primary); text-decoration: none; }
h1, h2, h3 { font-weight: 600; }

/* ============ 布局 ============ */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: 224px; flex: 0 0 224px;
  background: linear-gradient(180deg, #12394B 0%, #0F2E3D 100%);
  color: #D3E3EA; display: flex; flex-direction: column; position: fixed;
  top: 0; bottom: 0; left: 0; z-index: 20;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 20px 18px; border-bottom: 1px solid rgba(255,255,255,.08); }
.brand-logo {
  width: 42px; height: 42px; border-radius: 11px; flex: 0 0 42px;
  background: linear-gradient(135deg, #0E7490, #14B8A6);
  color: #fff; font-size: 22px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 8px rgba(14,116,144,.4);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.35; }
.brand-text strong { color: #fff; font-size: 17px; letter-spacing: .5px; }
.brand-text span { color: #8FB3C4; font-size: 12px; }
.nav { flex: 1; padding: 14px 10px; display: flex; flex-direction: column; gap: 4px; }
.nav-item {
  display: flex; align-items: center; gap: 10px; color: #B9CFDA;
  padding: 11px 14px; border-radius: 9px; font-size: 14px; transition: .15s;
}
.nav-item svg { width: 18px; height: 18px; flex: 0 0 18px; opacity: .85; }
.nav-item:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-item.active { background: var(--sidebar-active); color: #fff; box-shadow: 0 2px 8px rgba(14,116,144,.35); }
/* 二级分组菜单 */
.nav-group { display: flex; flex-direction: column; gap: 4px; }
.nav-group-title { width: 100%; border: 0; background: none; font: inherit; cursor: pointer; }
.nav-group-title .nav-caret { margin-left: auto; font-size: 12px; opacity: .8; transition: transform .15s; }
.nav-group:not(.open) .nav-caret { transform: rotate(-90deg); }
.nav-group.group-active > .nav-group-title { color: #fff; }
.nav-sub { display: none; flex-direction: column; gap: 4px; padding-left: 16px; }
.nav-group.open .nav-sub { display: flex; }
.nav-sub-item {
  display: flex; align-items: center; color: #B9CFDA; font-size: 13.5px;
  padding: 9px 14px; border-radius: 9px; transition: .15s;
}
.nav-sub-item:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-sub-item.active { background: var(--sidebar-active); color: #fff; box-shadow: 0 2px 8px rgba(14,116,144,.35); }
.sidebar-foot { padding: 14px 18px; font-size: 12px; color: #6E93A6; border-top: 1px solid rgba(255,255,255,.08); }

.main { flex: 1; margin-left: 224px; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 60px; background: var(--card); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 26px; position: sticky; top: 0; z-index: 10;
}
.topbar-title { font-size: 17px; font-weight: 600; color: var(--text); }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.company-name { color: var(--primary); font-weight: 600; font-size: 14px; }
.user-chip {
  background: var(--primary-light); color: var(--primary-dark);
  border-radius: 999px; padding: 4px 14px; font-size: 13px; font-weight: 600;
}

/* ============ 项目选择器（多独立项目 · V1.9.10 美化） ============ */
.project-picker { position: relative; }
.project-btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 6px 11px 6px 12px; border-radius: 999px;
  border: 1px solid #D7E5EC;
  background: linear-gradient(180deg, #FFFFFF 0%, #F3FAFC 100%);
  box-shadow: 0 1px 2px rgba(15, 46, 61, .06), inset 0 1px 0 #fff;
  font-size: 13.5px; color: var(--text); cursor: pointer;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}
.project-btn:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 14px rgba(14, 116, 144, .18), inset 0 1px 0 #fff;
  transform: translateY(-1px);
}
.project-btn:active { transform: translateY(0); box-shadow: 0 1px 3px rgba(15,46,61,.12); }
.project-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(14,116,144,.22); }
.project-btn .pdot {
  width: 9px; height: 9px; flex: 0 0 9px; border-radius: 50%;
  background: linear-gradient(135deg, #2DD4BF 0%, #0E7490 100%);
  box-shadow: 0 0 0 3px rgba(20, 184, 166, .16);
}
.project-btn-label {
  color: var(--muted); font-size: 11.5px; letter-spacing: .4px;
  border-right: 1px solid var(--border); padding-right: 9px; line-height: 1.2;
}
#project-name {
  font-weight: 700; color: #0F2E3D; letter-spacing: .2px;
  max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.project-btn .switch-tag {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 11.5px; color: #0E7490; background: #E4F4F9;
  border: 1px solid #CBEAEF; border-radius: 999px; padding: 2px 8px;
  white-space: nowrap; transition: background .16s ease, color .16s ease, border-color .16s ease;
}
.project-btn:hover .switch-tag { background: var(--primary); color: #fff; border-color: var(--primary); }
.project-btn .caret { color: #90A7B2; font-size: 10px; transition: transform .16s ease; }
.project-btn[aria-expanded="true"] .caret { transform: rotate(180deg); }
.project-menu {
  display: none; position: absolute; right: 0; top: calc(100% + 8px); width: 312px;
  background: #fff; border: 1px solid #DCE8EE; border-radius: 14px;
  box-shadow: 0 18px 42px rgba(15, 46, 61, .18); z-index: 60; padding: 8px;
}
.project-menu.show { display: block; }
.project-menu-title {
  font-size: 12px; color: var(--muted); padding: 8px 10px 9px;
  border-bottom: 1px solid var(--border); margin-bottom: 6px; line-height: 1.5;
}
.project-list { max-height: 268px; overflow-y: auto; }
.project-item {
  display: flex; align-items: center; justify-content: space-between; gap: 6px;
  padding: 9px 10px; border-radius: 9px; cursor: pointer; font-size: 13.5px;
  transition: background .14s ease;
}
.project-item:hover { background: #F2FAFD; }
.project-item.cur { background: #E8F6FA; color: var(--primary-dark); font-weight: 700; }
.project-item .cur-tag {
  font-size: 11px; color: #fff; background: linear-gradient(135deg, #14B8A6, #0E7490);
  border-radius: 999px; padding: 1px 8px; flex-shrink: 0;
}
.project-item .project-item-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project-item .project-ops { display: none; gap: 3px; margin-left: 4px; flex-shrink: 0; }
.project-item:hover .project-ops { display: inline-flex; }
.project-item .op-btn {
  width: 24px; height: 24px; line-height: 1; border: 1px solid var(--border);
  background: #fff; border-radius: 7px; cursor: pointer; font-size: 12px; color: var(--muted); padding: 0;
}
.project-item .op-btn:hover { border-color: var(--primary); color: var(--primary); background: #fff; }
.project-item .op-btn.danger:hover { border-color: #e11d48; color: #e11d48; }
.project-new { display: flex; gap: 8px; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--border); }
.project-new .input { flex: 1; min-width: 0; }
.project-new .btn { white-space: nowrap; }
.content { padding: 24px 26px 40px; flex: 1; }

/* ============ 通用组件 ============ */
.card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 20px; margin-bottom: 20px; border: 1px solid rgba(15,46,61,.04);
}
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.card-head h3 { font-size: 16px; }
.card-head .sub { color: var(--muted); font-size: 13px; }

.btn {
  display: inline-flex; align-items: center; gap: 6px; justify-content: center;
  border: 1px solid transparent; border-radius: 8px; cursor: pointer;
  font-size: 14px; padding: 8px 16px; font-family: inherit; transition: .15s;
  background: #fff; color: var(--text); border-color: var(--border); white-space: nowrap;
}
.btn:hover { border-color: #C9D3DB; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-danger { background: #fff; color: var(--expense); border-color: #F3C4C4; }
.btn-danger:hover { background: #FDECEC; border-color: var(--expense); }
.btn-success { background: #fff; color: var(--income); border-color: #BBE7C8; }
.btn-success:hover { background: #EAF7EF; border-color: var(--income); }
.btn-ghost { background: transparent; color: var(--muted); border-color: transparent; }
.btn-ghost:hover { background: rgba(15,46,61,.06); color: var(--text); }
.btn-sm { padding: 5px 11px; font-size: 13px; border-radius: 7px; }

.input, .select, .textarea {
  width: 100%; border: 1px solid var(--border); border-radius: 8px;
  padding: 8px 12px; font-size: 14px; font-family: inherit; background: #fff;
  color: var(--text); outline: none; transition: .15s;
}
.input:hover, .select:hover, .textarea:hover { border-color: #C9D3DB; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(14,116,144,.12); }
/* 输入框提示文字：全系统统一淡化为半透明灰，避免与真实填写的文字混淆 */
input::placeholder, textarea::placeholder,
.input::placeholder, .textarea::placeholder,
input::-webkit-input-placeholder, textarea::-webkit-input-placeholder {
  color: #B7C2CE;
  opacity: 1;
  font-weight: 400;
}

/* 收支类别标签管理（系统设置） */
.cat-tags { display: flex; flex-wrap: wrap; gap: 8px; min-height: 38px; padding: 8px; border: 1px dashed var(--border); border-radius: 10px; background: #FBFCFD; }
.cat-tags .cat-tag { display: inline-flex; align-items: center; gap: 2px; background: var(--primary-light); color: var(--primary-dark); border: 1px solid rgba(14,116,144,.25); border-radius: 999px; padding: 4px 6px 4px 12px; font-size: 13.5px; }
.cat-tags .cat-tag-name { cursor: pointer; border-bottom: 1px dashed transparent; }
.cat-tags .cat-tag-name:hover { border-bottom-color: var(--primary); }
.cat-tags .cat-tag-x { position: relative; width: 34px; height: 34px; line-height: 1; border: none; background: transparent; color: var(--primary-dark); border-radius: 50%; cursor: pointer; font-size: 14px; padding: 0; }
.cat-tags .cat-tag-x::before { content: ""; position: absolute; inset: -5px; }
.cat-tags .cat-tag-x:hover { background: rgba(14,116,144,.18); }
.cat-add { display: flex; gap: 8px; margin-top: 8px; }
.cat-add .input { flex: 1; max-width: 320px; }
.btn:active { transform: translateY(1px); }
.textarea { resize: vertical; min-height: 72px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 13px; color: #374151; font-weight: 600; }
.field .hint { font-size: 12px; color: var(--muted); }
#reg-username-hint { min-height: 16px; line-height: 1.45; }
#reg-username-hint.bad { color: #DC2626; }
#reg-username-hint.good { color: #15803D; }
#reg-username-hint.checking { color: var(--muted); }
#reg-username[aria-invalid="true"] { border-color: #DC2626; }
#reg-username[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px rgba(220,38,38,.12); }

.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 10px; }
.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table thead th {
  background: #F8FAFC; color: #475569; font-weight: 600; text-align: left;
  padding: 11px 13px; border-bottom: 1px solid var(--border); white-space: nowrap;
}
.table tbody td { padding: 10px 13px; border-bottom: 1px solid #F0F3F6; }
.table tbody tr:hover { background: #F8FCFE; }
.table tbody tr:last-child td { border-bottom: none; }
/* 疑似重复行：同日同类同金额出现 ≥2 笔，黄色底纹提示人工复核 */
.table tbody tr.row-dup { background: #FEF6D8; }
.table tbody tr.row-dup:hover { background: #FDEFC4; }
.dup-flag {
  display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px;
  font-size: 11px; font-weight: 600; color: #92400E; background: #FDE68A; white-space: nowrap;
}
.tag {
  display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600;
}
.tag-income { background: #EAF7EF; color: var(--income); }
.tag-expense { background: #FDECEC; color: var(--expense); }
.money { font-variant-numeric: tabular-nums; font-weight: 600; }
.money-income { color: var(--income); }
.money-expense { color: var(--expense); }
.empty { text-align: center; color: var(--muted); padding: 34px 0; }

.pagination { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; gap: 12px; flex-wrap: wrap; }
.pagination .info { color: var(--muted); font-size: 13px; }
.pagination .btns { display: flex; gap: 8px; }

/* ============ 统计卡片 ============ */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 20px; }
.stat-card {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 18px 20px; display: flex; align-items: center; gap: 16px; border: 1px solid rgba(15,46,61,.04);
}
.stat-ico {
  width: 52px; height: 52px; border-radius: 13px; flex: 0 0 52px;
  display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 700; color: #fff;
}
.stat-ico.income { background: linear-gradient(135deg, #16A34A, #22C55E); }
.stat-ico.expense { background: linear-gradient(135deg, #DC2626, #EF4444); }
.stat-ico.net { background: linear-gradient(135deg, #0E7490, #14B8A6); }
.stat-ico.cnt { background: linear-gradient(135deg, #D97706, #F59E0B); }
.stat-body { min-width: 0; }
.stat-body .label { color: var(--muted); font-size: 13px; }
.stat-body .value { font-size: 24px; font-weight: 700; line-height: 1.3; font-variant-numeric: tabular-nums; }
.stat-body .value.income { color: var(--income); }
.stat-body .value.expense { color: var(--expense); }
.stat-body .value.net { color: var(--primary-dark); }

.chart-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 18px; }
.chart-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; border: 1px solid rgba(15,46,61,.04); }
.chart-card h4 { font-size: 15px; margin-bottom: 6px; }
.chart-box { width: 100%; height: 320px; }
.chart-box.half { height: 300px; }

/* ============ 筛选栏 ============ */
.filter-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.filter-bar .field { width: 180px; }
.filter-bar .field.wide { width: 240px; }
.filter-actions { display: flex; gap: 8px; margin-left: auto; flex-wrap: wrap; }
.filter-actions .btn { padding: 8px 14px; }

/* 收支管理：顶部工具栏 + 点「查询」才展开的筛选面板 */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar .btn { display: inline-flex; align-items: center; gap: 7px; }
.toolbar-actions { display: flex; gap: 8px; margin-left: auto; flex-wrap: wrap; }
.filter-card { display: none; }
.filter-card.show { display: block; }
.filter-badge { font-size: 12px; opacity: .9; }
#btn-toggle-filter.active { box-shadow: 0 0 0 3px rgba(14,116,144,.2); }

/* ============ 弹窗 ============ */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(15,46,61,.45); z-index: 100;
  display: none; align-items: center; justify-content: center; padding: 20px;
}
.modal-overlay.show { display: flex; }
/* 修改记录身份验证弹窗置于编辑弹窗之上 */
#modal-verify { z-index: 130; }
/* V1.9.6：删除 / 修改数据、资料时的身份验证弹窗 */
#modal-pwd { z-index: 140; }
/* V1.9.6：打印预览弹窗（大尺寸，内嵌实际打印页） */
#modal-print { z-index: 120; }
.modal-print { max-width: 1100px; width: 100%; }
.print-preview-body { padding: 0; background: #EEF2F6; overflow: hidden; }
.print-preview-body iframe { display: block; width: 100%; height: 68vh; border: 0; background: #fff; }
/* V1.9.44：打印预览弹窗固定为上下结构，底部“打印”按钮始终留在屏幕内（手机 / iPad 同样生效） */
#modal-print .modal { display: flex; flex-direction: column; overflow: hidden; height: 92vh; max-height: 92vh; }
#modal-print .modal-body.print-preview-body { flex: 1 1 auto; min-height: 0; }
#modal-print .print-preview-body iframe { height: 100%; min-height: 0; }
#modal-print .modal-foot { flex: 0 0 auto; position: sticky; bottom: 0; z-index: 6; background: #fff; }
.modal {
  background: #fff; border-radius: 14px; width: 100%; max-width: 560px;
  box-shadow: 0 18px 50px rgba(15,46,61,.25); max-height: 92vh; overflow-y: auto;
}
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--border); }
.modal-head h3 { font-size: 16px; }
.modal-close { background: none; border: none; font-size: 22px; color: var(--muted); cursor: pointer; line-height: 1; }
.modal-close:hover { color: var(--text); }
.modal-body { padding: 22px; }
.modal-foot { padding: 14px 22px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 10px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }

/* ============ 提示 ============ */
.toast-wrap {
  position: fixed; inset: 0; z-index: 200;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; padding: 24px; pointer-events: none;
}
.toast {
  background: #fff; border-radius: 10px; box-shadow: 0 8px 24px rgba(15,46,61,.18);
  padding: 12px 18px; font-size: 14px; display: flex; align-items: center; gap: 10px;
  min-width: 260px; max-width: 420px; border-left: 4px solid var(--primary);
  animation: toastPop .22s ease; pointer-events: auto;
}
.toast.success { border-left-color: var(--income); }
.toast.error { border-left-color: var(--expense); }
.toast .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); flex: 0 0 8px; }
.toast.success .dot { background: var(--income); }
.toast.error .dot { background: var(--expense); }
@keyframes toastPop { from { opacity: 0; transform: translateY(10px) scale(.97); } to { opacity: 1; transform: none; } }

/* ============ 导入报告 ============ */
.import-summary { display: flex; gap: 16px; margin-bottom: 14px; flex-wrap: wrap; }
.import-summary .item { background: var(--bg); border-radius: 10px; padding: 12px 18px; text-align: center; }
.import-summary .item b { display: block; font-size: 22px; }
.import-summary .item span { color: var(--muted); font-size: 12.5px; }
.import-summary .item.ok b { color: var(--income); }
.import-summary .item.bad b { color: var(--expense); }
.import-summary .item.dup b { color: #D97706; }
.err-table { width: 100%; font-size: 13px; border-collapse: collapse; }
.err-table th, .err-table td { padding: 7px 10px; border: 1px solid var(--border); text-align: left; }
.err-table th { background: #F8FAFC; }

/* ============ 资料库 ============ */
.upload-row { display: flex; gap: 14px; flex-wrap: wrap; align-items: flex-end; }
.upload-row .field { flex: 1 1 240px; }
.upload-row .btn { padding: 8px 18px; }
#lib-upload-result { transition: .2s; }

/* ============ 登录页 ============ */
.login-wrap { display: flex; min-height: 100vh; }
.login-brand {
  flex: 1.15; background: linear-gradient(150deg, #0F2E3D 0%, #0E7490 62%, #14B8A6 110%);
  color: #fff; display: flex; flex-direction: column; justify-content: center;
  padding: 60px 7%; position: relative; overflow: hidden;
}
.login-brand::after {
  content: ""; position: absolute; right: -90px; top: -90px; width: 340px; height: 340px;
  border-radius: 50%; background: rgba(255,255,255,.05);
}
.login-brand::before {
  content: ""; position: absolute; right: 90px; bottom: -140px; width: 420px; height: 420px;
  border-radius: 50%; background: rgba(255,255,255,.04);
}
.login-brand .logo-row { display: flex; align-items: center; gap: 14px; margin-bottom: 34px; }
.login-brand .logo-badge {
  width: 58px; height: 58px; border-radius: 15px; background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.28); font-size: 30px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}
.login-brand h1 { font-size: 34px; letter-spacing: 2px; }
.login-brand .slogan { color: rgba(255,255,255,.78); font-size: 15px; margin-top: 6px; }
.login-brand .features { margin-top: 44px; display: flex; flex-direction: column; gap: 20px; }
.login-brand .feature { display: flex; gap: 14px; align-items: flex-start; }
.login-brand .feature .f-ico {
  width: 40px; height: 40px; border-radius: 10px; flex: 0 0 40px;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22);
  display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.login-brand .feature b { display: block; font-size: 15px; margin-bottom: 2px; }
.login-brand .feature span { color: rgba(255,255,255,.72); font-size: 13px; }
.login-brand .foot-ver { position: absolute; bottom: 26px; left: 7%; color: rgba(255,255,255,.5); font-size: 12.5px; }

.login-panel { flex: 1; background: #fff; display: flex; align-items: center; justify-content: center; padding: 40px; }
.login-card { width: 100%; max-width: 420px; }
.login-card .tabs { display: flex; background: var(--bg); border-radius: 11px; padding: 5px; margin-bottom: 26px; }
.login-card .tab {
  flex: 1; text-align: center; padding: 9px 0; border-radius: 8px; cursor: pointer;
  font-size: 15px; font-weight: 600; color: var(--muted); transition: .15s; border: none; background: none;
}
.login-card .tab.active { background: #fff; color: var(--primary-dark); box-shadow: 0 2px 8px rgba(15,46,61,.1); }
.login-card h2 { font-size: 22px; margin-bottom: 6px; }
.login-card .sub { color: var(--muted); font-size: 13.5px; margin-bottom: 26px; }
/* V1.9.61：试用项目提示横幅 */
.trial-banner {
  margin: -14px 0 18px; padding: 10px 14px; border-radius: 10px;
  background: var(--primary-light); color: var(--primary-dark);
  font-size: 13px; line-height: 1.7; border: 1px solid #B8D7E8;
}
.trial-banner b { color: var(--primary); font-weight: 600; }
.login-form { display: flex; flex-direction: column; gap: 16px; }
.login-form .field input { padding: 11px 14px; font-size: 15px; }
.login-form .btn-login { margin-top: 6px; padding: 12px; font-size: 16px; border-radius: 10px; }
/* V1.9.15：选择项目页「新建自己的项目」入口 + 页面内新建表单 */
.login-form .btn-new-project {
  margin-top: -4px; padding: 11px; font-size: 14.5px; border-radius: 10px;
  color: var(--primary-dark); border-color: #B8D7E8; background: #F4FAFD;
}
.login-form .btn-new-project:hover { background: #E8F5FB; border-color: var(--primary); }
#sel-new .modal-body .field { margin-bottom: 14px; }
#sel-new .modal-body .field:last-child { margin-bottom: 0; }
.login-tip { margin-top: 18px; text-align: center; color: var(--muted); font-size: 12.5px; }
.login-tip b { color: var(--primary); font-weight: 600; }
/* V1.9.8：登录页「忘记密码」入口 + 找回码展示 */
.forgot-row { margin-top: 10px; text-align: right; }
.link-btn {
  border: 0; background: none; padding: 4px 2px; cursor: pointer;
  color: var(--primary); font-size: 13px; font-family: inherit;
}
.link-btn:hover { text-decoration: underline; }
.recovery-code-view {
  font-family: Consolas, Menlo, monospace; font-size: 18px; letter-spacing: 1px;
  color: #0f2b46; background: #F1F5F9; border: 1px dashed #CBD5E1;
  border-radius: 8px; padding: 12px; text-align: center; word-break: break-all;
}
/* 登录页：公司 logo 居中于欢迎语上方；登录/注册切换移到卡片最下方 */
.login-logo { text-align: center; margin-bottom: 20px; }
.login-logo img { width: 210px; max-width: 66%; height: auto; vertical-align: middle; }
.login-card .tabs-bottom { margin-top: 24px; margin-bottom: 0; }

/* ============ 打印报表 ============ */
.print-page { background: #fff; padding: 30px 40px; max-width: 1000px; margin: 0 auto; color: #1f2937; }
.print-toolbar { text-align: right; margin-bottom: 16px; }
.print-head { text-align: center; border-bottom: 2px solid var(--primary-dark); padding-bottom: 14px; margin-bottom: 18px; }
.print-brand { font-size: 11px; letter-spacing: 4px; color: #0E7490; font-weight: 700; margin-bottom: 5px; }
.print-head h1 { font-size: 24px; letter-spacing: 2px; color: var(--primary-dark); }
.print-head .meta { color: #555; font-size: 13px; margin-top: 8px; }
.print-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.print-table th, .print-table td { border: 1px solid #B9C4CC; padding: 8px 10px; text-align: center; }
.print-table th { background: #E8F4F8; color: var(--primary-dark); font-weight: 700; }
.print-table td.l { text-align: left; }
.print-table tbody tr:nth-child(even) { background: #F9FBFC; }
.print-total { margin-top: 16px; display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 22px 38px; font-weight: 600; font-size: 14px; border-top: 1px solid #D8E2EA; padding-top: 10px; }
.print-foot { margin-top: 34px; display: flex; justify-content: space-between; color: #555; font-size: 13px; }
.print-summary { background: #F8FAFC; border: 1px solid var(--border); border-radius: 8px; padding: 12px 16px; margin-bottom: 16px; font-size: 13.5px; color: #374151; }

@page { size: A4 portrait; margin: 12mm 11mm; }
@media print {
  html, body { background: #fff !important; }
  body { margin: 0; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .print-toolbar { display: none; }
  .print-page { padding: 0; max-width: none; }
  .print-head { border-bottom: 2px solid #12324a; padding-bottom: 10px; margin-bottom: 12px; }
  .print-head h1 { font-size: 20px; letter-spacing: 2px; color: #12324a; }
  .print-head .meta { font-size: 11px; color: #475569; }
  .print-summary { font-size: 11px; padding: 8px 10px; margin-bottom: 10px; border-radius: 6px; }
  .print-table { font-size: 10.5px; }
  .print-table th, .print-table td { border: 1px solid #8fa1b2; padding: 4px 6px; }
  .print-table thead { display: table-header-group; }
  .print-table tr { page-break-inside: avoid; }
  .print-table th { background: #e8f4f8 !important; color: #12324a; }
  .print-total { margin-top: 10px; gap: 26px; font-size: 11.5px; }
  .print-foot { margin-top: 22px; font-size: 11px; }
}

/* ============ 响应式 ============ */
@media (max-width: 1200px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .chart-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .sidebar { display: none; }
  .main { margin-left: 0; }
  .login-brand { display: none; }
  .form-grid { grid-template-columns: 1fr; }
}

/* ============ V1.9.0 手机端适配 ============ */
/* 顶栏汉堡按钮（桌面隐藏） */
.btn-menu {
  display: none; align-items: center; justify-content: center;
  width: 40px; height: 40px; flex: 0 0 40px; padding: 0;
  border: 1px solid var(--border); border-radius: 9px; background: #fff;
  color: var(--text); font-size: 19px; line-height: 1; cursor: pointer;
}
.sidebar-close {
  display: none; position: absolute; top: 12px; right: 10px; width: 32px; height: 32px;
  border: none; background: rgba(255,255,255,.12); color: #D3E3EA; border-radius: 8px;
  font-size: 16px; line-height: 1; cursor: pointer; z-index: 2;
}
.sidebar-mask { display: none; position: fixed; inset: 0; background: rgba(15,46,61,.45); z-index: 19; }
.sidebar-mask.show { display: block; }
body.nav-open { overflow: hidden; }

@media (max-width: 900px) {
  .sidebar {
    display: flex; transform: translateX(-100%); transition: transform .22s ease;
    width: 250px; flex-basis: 250px; box-shadow: 0 0 30px rgba(0,0,0,.25);
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-close { display: flex; align-items: center; justify-content: center; }
  .main { margin-left: 0; }
  .btn-menu { display: inline-flex; }
  .topbar { height: 56px; padding: 0 12px; gap: 10px; }
  .topbar-title { font-size: 16px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .topbar-right { gap: 8px; flex-shrink: 0; }
  .company-name { display: none; }
  .user-chip { padding: 3px 10px; font-size: 12.5px; }
  .content { padding: 14px 12px 30px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .chart-box { height: 260px; }
  .chart-box.half { height: 240px; }
  .project-menu { width: min(300px, calc(100vw - 24px)); }
}

@media (max-width: 640px) {
  body { font-size: 13.5px; }
  .card { padding: 14px 12px; border-radius: 10px; margin-bottom: 12px; }
  .card-head { flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { padding: 13px 14px; gap: 10px; }
  .stat-ico { width: 40px; height: 40px; flex-basis: 40px; font-size: 18px; border-radius: 10px; }
  .stat-body .value { font-size: 19px; }
  .stat-body .label { font-size: 12px; }
  .filter-bar { gap: 10px; }
  .filter-bar .field, .filter-bar .field.wide { width: 100%; }
  .filter-actions { margin-left: 0; width: 100%; flex-wrap: wrap; gap: 8px; }
  .filter-actions .btn { flex: 1 1 calc(50% - 4px); min-width: 0; justify-content: center; padding: 8px 10px; }
  .toolbar { gap: 8px; margin-bottom: 12px; }
  .toolbar > #btn-toggle-filter { width: 100%; justify-content: center; }
  .toolbar-actions { width: 100%; margin-left: 0; gap: 8px; }
  .toolbar-actions .btn { flex: 1 1 calc(50% - 4px); min-width: 0; justify-content: center; padding: 8px 10px; }
  .toolbar-actions #btn-export { flex: 1 1 100%; }
  .btn { min-height: 38px; padding: 8px 14px; font-size: 13.5px; }
  .btn-sm { min-height: 32px; }
  .input, .select, .textarea { min-height: 38px; font-size: 14px; }
  .table { font-size: 12.8px; }
  .table thead th { padding: 9px 10px; }
  .table tbody td { padding: 8px 10px; }
  .modal-overlay { padding: 10px; }
  .modal { max-width: 100%; border-radius: 12px; max-height: 90vh; }
  .modal-head { padding: 14px 16px; }
  .modal-body { padding: 16px; }
  .modal-foot { padding: 12px 16px; flex-wrap: wrap; }
  .modal-foot .btn { flex: 1; }
  /* V1.9.44：手机端打印预览固定头部和底部，避免“打印”按钮被挤出屏幕 */
  #modal-print .modal { height: 94vh; max-height: 94vh; }
  #modal-print .modal-head { flex: 0 0 auto; }
  #modal-print .print-preview-body iframe { height: 100%; min-height: 0; }
  #modal-print .modal-foot { padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }
  .form-grid { gap: 12px; }
  .chart-box { height: 240px; }
  .chart-box.half { height: 220px; }
  .toast-wrap { inset: 0; padding: 16px; align-items: center; justify-content: center; }
  .toast { min-width: 0; max-width: 100%; width: 100%; }
  .login-wrap { flex-direction: column; min-height: 100vh; }
  .login-brand { display: none; }
  .login-panel { padding: calc(5vh + env(safe-area-inset-top, 0px)) 18px 36px; align-items: flex-start; min-height: 100vh; box-sizing: border-box; }
  .login-card { max-width: 100%; }
  .login-logo { margin-bottom: 22px; }
  .login-logo img { width: 240px; max-width: 70%; }
  .login-card h2 { font-size: 20px; }
  .login-form .field input { padding: 10px 12px; }
  .project-menu { position: fixed; left: 12px; right: 12px; width: auto; top: 62px; }
  .project-item .project-ops { display: inline-flex; }
  .pagination { justify-content: center; }
  .pagination .btn { flex: 1; }
  .print-page { padding: 12px !important; }
  .print-total { flex-direction: column; align-items: flex-end; gap: 6px; }
  .cat-add { flex-wrap: wrap; }
  .cat-add .input { max-width: none; }
}

@media (max-width: 400px) {
  .stat-grid { grid-template-columns: 1fr; }
  .btn-menu { width: 36px; height: 36px; flex-basis: 36px; }
}

/* 触屏设备（手机 / iPad / 安卓平板）没有 hover：项目操作按钮必须常显，且加大点按区域 */
@media (hover: none), (pointer: coarse), (max-width: 900px) {
  .project-item .project-ops { display: inline-flex; gap: 6px; }
  .project-item .op-btn {
    width: 32px; height: 32px; font-size: 15px; border-radius: 8px;
  }
}
@media (max-width: 480px) {
  .project-item { flex-wrap: wrap; row-gap: 6px; }
  .project-item .project-ops {
    width: 100%; justify-content: flex-end; margin-left: 0; padding-top: 2px;
  }
  .project-item .op-btn { width: 34px; height: 34px; }
}

/* ============ 仪表盘月份导航（手机端防挤压）============ */
.dashboard-top {
  padding: 14px 20px; display: flex; align-items: center;
  justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.month-nav {
  display: flex; align-items: center; gap: 14px;
  flex-wrap: wrap; row-gap: 10px; min-width: 0;
}
.month-nav .month-label {
  font-size: 16px; min-width: 130px; text-align: center;
  display: inline-block; white-space: nowrap;
}
.month-nav .btn { flex: 0 0 auto; white-space: nowrap; }
.dashboard-hint { color: var(--muted); font-size: 13px; }

@media (max-width: 640px) {
  .dashboard-top { padding: 12px 12px; gap: 8px; }
  .month-nav { width: 100%; gap: 8px; row-gap: 8px; }
  .month-nav .month-label {
    min-width: 0; flex: 1 1 90px; font-size: 15.5px;
  }
  .month-nav .btn { padding: 6px 11px; }
  .dashboard-hint { font-size: 12px; }
}

@media (max-width: 400px) {
  .month-nav .btn { padding: 6px 9px; }
  .month-nav .month-label { flex: 1 1 76px; font-size: 15px; }
}

/* ============ 手机端下拉刷新提示条 ============ */
.pull-tip {
  position: fixed; left: 0; right: 0; top: 0; height: 0; overflow: hidden;
  background: var(--primary); color: #fff; text-align: center;
  font-size: 13px; line-height: 40px; letter-spacing: .5px;
  transition: height .18s ease; z-index: 9999; pointer-events: none;
}

/* ============ V1.9.10 登录后选择项目页（沿用登录页视觉，下拉选项目） ============ */
.project-select-body { background: var(--bg); }
.project-select .login-card { max-width: 460px; }
.select-shell { position: relative; }
.select-shell select.input {
  width: 100%; appearance: none; -webkit-appearance: none; -moz-appearance: none;
  padding: 11px 40px 11px 14px; font-size: 15px; background: #fff;
  border: 1px solid var(--border); border-radius: 9px; color: var(--text);
  cursor: pointer; transition: border-color .15s ease, box-shadow .15s ease;
}
.select-shell select.input:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(14, 116, 144, .14);
}
.select-shell .sel-caret {
  position: absolute; right: 16px; top: 50%; margin-top: -2px;
  width: 0; height: 0; overflow: hidden; line-height: 0; font-size: 0;
  color: transparent; pointer-events: none;
  border-left: 5px solid transparent; border-right: 5px solid transparent;
  border-top: 6px solid #5B7B8A;
}
.select-state {
  display: flex; align-items: center; gap: 7px;
  margin: 10px 0 2px; font-size: 12.5px; color: var(--muted); line-height: 1.6;
}
.select-state-dot { width: 7px; height: 7px; border-radius: 50%; background: #14B8A6; flex: 0 0 7px; }
.select-state-dot.locked { background: var(--gold); }
.select-err { display: none; margin-top: -2px; color: var(--expense); font-size: 13px; line-height: 1.6; }
.project-select .login-form .field { margin-bottom: 17px; }
.project-select .login-tip { margin-top: 16px; }
.project-select .tabs-bottom {
  background: transparent; border-top: 1px solid var(--border); border-radius: 0;
  margin-top: 22px; padding: 0;
}
.project-select .tabs-bottom .sel-userbar { padding-top: 13px; }
.sel-userbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 2px; }
.sel-user { color: var(--muted); font-size: 13px; }
.select-empty {
  background: #F8FAFC; border: 1px dashed #CBD5E1; border-radius: 10px;
  padding: 18px; font-size: 13.5px; color: var(--muted); line-height: 1.8; text-align: center;
}

@media (max-width: 560px) {
  .login-panel { padding: 30px 18px; }
  .project-select .login-card { max-width: 100%; }
  .project-btn { gap: 7px; padding: 4px 8px; }
  .project-btn-label { display: none; }
  #project-name { max-width: 108px; font-size: 13px; }
  .project-btn .switch-tag { padding: 1px 7px; font-size: 11px; }
}

/* V1.9.9：系统设置里的「每月自动备份」区块 */
.auto-backup-box {
  margin-top: 18px; padding-top: 16px;
  border-top: 1px dashed var(--border);
}
.auto-backup-row {
  display: flex; gap: 14px; flex-wrap: wrap; align-items: flex-end; margin-top: 12px;
}
.auto-backup-row .btn { white-space: nowrap; }

@media (max-width: 560px) {
  .select-page { padding: 18px 12px 30px; }
  .select-title { font-size: 19px; }
  .select-card { padding: 14px 15px; }
  .select-card-act .btn, .select-card-pwd .btn { flex: 1 1 auto; min-height: 40px; }
  .select-card-pwd { flex-direction: column; align-items: stretch; }
}

/* ===== V1.9.11：项目成员（授权账号共享本项目账目 / 资料 / 设置） ===== */
.project-empty { padding: 10px 2px; font-size: 12.5px; color: #6B7C8F; line-height: 1.7; }
.share-tag { font-size: 11px; color: #2F6F8F; background: #EAF3F8; border-radius: 8px; padding: 1px 6px; margin-left: 4px; }
.members-hint { font-size: 12.5px; color: #5A6B7C; line-height: 1.7; margin-bottom: 10px; }
.member-list { max-height: 220px; overflow: auto; border: 1px solid #E2E8F0; border-radius: 10px; background: #FBFDFE; }
.member-row { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-bottom: 1px solid #EEF2F6; font-size: 13.5px; color: #24344d; }
.member-row:last-child { border-bottom: none; }
.member-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.member-tag { font-size: 11px; color: #5B7B8A; background: #EEF4F7; border-radius: 8px; padding: 1px 7px; }
.member-tag.owner { color: #8A5A00; background: #FFF4DC; }
.member-tag.view { color: #1F6FB2; background: #E6F1FA; }
.member-tag.edit { color: #1E7A46; background: #E7F5EC; }
.member-perm-switch { display: inline-flex; gap: 4px; }
.perm-btn { font-size: 11px; padding: 2px 8px; border-radius: 8px; border: 1px solid #D8E0E8; background: #fff; color: #5B7B8A; cursor: pointer; }
.perm-btn.active { color: #fff; background: #2F6FE0; border-color: #2F6FE0; }
.cat-tag-name.ro { cursor: default; }
.member-empty { padding: 14px 10px; font-size: 12.5px; color: #7A8896; text-align: center; }
.member-add { display: flex; gap: 8px; margin-top: 12px; }
.member-add .input { flex: 1; }
.member-err { margin-top: 8px; font-size: 12.5px; color: #DC2626; }
@media (max-width: 560px) {
  .member-add { flex-direction: column; align-items: stretch; }
  .member-add .btn { min-height: 40px; }
}

/* ===== V1.9.13：资料列表操作列（横排按钮）===== */
.ops-cell { white-space: nowrap; }
.ops { display: flex; flex-direction: row; flex-wrap: wrap; gap: 6px; justify-content: flex-end; align-items: center; }
.ops .btn { padding: 4px 9px; font-size: 12.5px; line-height: 1.5; min-height: 0; border-radius: 7px; }
.ops .btn-primary { color: #fff; }

/* ===== V1.9.13：微信来源上传 ===== */
.drop-zone { position: relative; border: 1.5px dashed #CBD5E1; border-radius: 10px; padding: 10px; transition: border-color .15s, background .15s; cursor: pointer; }
.drop-zone:hover { border-color: var(--primary); background: #F8FAFC; }
.drop-zone.dragging { border-color: var(--primary); background: var(--primary-light); }
.drop-zone .input { background: #fff; }
.drop-tip { font-size: 12.5px; color: #6B7280; margin-top: 6px; line-height: 1.7; }
.drop-zone .btn { flex: 0 0 auto; }
.wx-tabs { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.wx-tab { border: 1px solid #E2E8F0; background: #fff; color: #475569; border-radius: 8px; padding: 6px 12px; font-size: 13px; cursor: pointer; }
.wx-tab.on { border-color: var(--primary); color: var(--primary-dark); background: var(--primary-light); font-weight: 600; }
.wx-tip { font-size: 12px; color: #94A3B8; margin-left: auto; }
.wx-hint { font-size: 12.5px; color: #92400E; background: #FFFBEB; border: 1px solid #FDE68A; border-radius: 8px; padding: 8px 10px; margin-bottom: 10px; line-height: 1.7; }
.wx-list { max-height: 52vh; overflow: auto; border: 1px solid #E2E8F0; border-radius: 10px; }
.wx-empty { padding: 26px 16px; text-align: center; color: #94A3B8; font-size: 13.5px; line-height: 1.8; }
.wx-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid #F1F5F9; }
.wx-item:last-child { border-bottom: none; }
.wx-ico { width: 30px; text-align: center; font-size: 18px; flex: 0 0 auto; }
.wx-meta { flex: 1; min-width: 0; }
.wx-name { font-size: 13.5px; color: #1F2937; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wx-sub { font-size: 12px; color: #94A3B8; margin-top: 2px; }
@media (max-width: 560px) {
  .ops { justify-content: flex-start; }
  .wx-tip { display: none; }
}
/* V1.9.56：注册滑块验证（自研，无第三方依赖） */
/* V1.9.59：保持与输入框同宽，只把图区高度压到原来一半（2:1 → 4:1） */
.yy-captcha {
  --cap-h: 40px;
  width: 100%;
  border: 1px solid #D8E5EA;
  border-radius: 12px;
  padding: 8px;
  background: linear-gradient(180deg, #F7FBFC 0%, #EEF6F8 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9);
}
.yy-captcha-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 1;
  border-radius: 9px;
  overflow: hidden;
  background: #0E7490;
  touch-action: none;
  user-select: none;
}
.yy-captcha-stage img {
  position: absolute;
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}
#cap-bg { inset: 0; width: 100%; height: 100%; object-fit: cover; }
#cap-piece {
  top: 30%;
  left: 0;
  width: 10%;
  height: 40%;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.28));
  transition: filter .15s;
  z-index: 2;
}
.yy-captcha.done #cap-piece { filter: drop-shadow(0 0 5px rgba(22,163,74,.55)); }
.yy-captcha-mask {
  position: absolute; inset: 0; z-index: 3;
  display: flex; align-items: center; justify-content: center;
  color: #E8F4F8; font-size: 12px; letter-spacing: .4px;
  background: rgba(15,46,61,.32);
  backdrop-filter: blur(1px);
  transition: opacity .2s;
}
.yy-captcha-mask.hide { opacity: 0; pointer-events: none; }
.yy-captcha-track {
  position: relative;
  width: 100%;
  height: var(--cap-h);
  margin: 8px auto 0;
  border-radius: 10px;
  background: #E7EFF2;
  border: 1px solid #D5E2E7;
  overflow: hidden;
  touch-action: none;
  user-select: none;
}
.yy-captcha-fill {
  position: absolute; left: 0; top: 0; bottom: 0; width: 0;
  background: linear-gradient(90deg, rgba(14,116,144,.14), rgba(20,184,166,.22));
  border-radius: 9px 0 0 9px;
}
.yy-captcha-tip {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  padding: 0 42px;
  color: #64748B; font-size: 11.5px; letter-spacing: .3px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.yy-captcha-thumb {
  position: absolute; left: 0; top: 0;
  width: var(--cap-h); height: var(--cap-h);
  border-radius: 9px;
  background: linear-gradient(135deg, #0E7490, #14B8A6);
  color: #fff; font-size: 20px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  cursor: grab;
  box-shadow: 0 2px 8px rgba(14,116,144,.34);
  transition: background .15s, box-shadow .15s, transform .08s;
  touch-action: none;
}
.yy-captcha-thumb:active { cursor: grabbing; transform: scale(.98); }
.yy-captcha.done .yy-captcha-thumb {
  background: linear-gradient(135deg, #15803D, #22C55E);
  box-shadow: 0 2px 8px rgba(22,163,74,.32);
  cursor: default;
}
.yy-captcha.done .yy-captcha-tip { color: #15803D; font-weight: 600; }
.yy-captcha-foot {
  display: flex; align-items: center; gap: 8px;
  width: 100%; margin: 5px auto 0; min-height: 18px;
  font-size: 11.5px; color: #7C8F99;
}
.yy-captcha-foot #cap-status { flex: 1; min-width: 0; }
.yy-captcha-foot #cap-status.err { color: #DC2626; }
.yy-captcha-foot #cap-status.ok { color: #15803D; font-weight: 600; }
.yy-captcha-refresh {
  border: 0; background: transparent; color: #0E7490;
  font-size: 12px; cursor: pointer; padding: 2px 0; white-space: nowrap;
}
.yy-captcha-refresh:hover { text-decoration: underline; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
@media (max-width: 560px) {
  .yy-captcha { padding: 6px; }
  .yy-captcha-tip { padding: 0 42px; font-size: 11.5px; letter-spacing: .2px; }
  .yy-captcha-foot { font-size: 11px; }
}


/* V1.9.25：登录页底部只留一个注册入口（与登录按钮同宽同高），注册页显示「返回登录」 */
.login-card .switch-row { margin-top: 16px; }
.login-card .switch-btn { width: 100%; padding: 12px; font-size: 15.5px; border-radius: 10px; letter-spacing: 1px; }

/* V1.9.60：公开隐私政策 / 用户协议 / 个人信息清单 */
.legal-page{background:#f3f6f9;color:#1e293b;font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif;margin:0;padding:0}
.legal-wrap{max-width:880px;margin:0 auto;padding:28px 18px 48px;box-sizing:border-box}
.legal-brand{display:flex;align-items:center;gap:12px;margin-bottom:18px}
.legal-logo{width:44px;height:44px;border-radius:12px;background:#F47B20;color:#fff;display:flex;align-items:center;justify-content:center;font-weight:800;font-size:20px}
.legal-brand strong{display:block;font-size:17px;color:#12324a}
.legal-brand span{display:block;font-size:12px;color:#64748b;margin-top:2px}
.legal-tabs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:14px}
.legal-tabs a{text-decoration:none;color:#475569;background:#fff;border:1px solid #dbe4ee;border-radius:999px;padding:9px 14px;font-size:13px;min-height:36px;box-sizing:border-box;display:inline-flex;align-items:center}
.legal-tabs a.active{background:#0b6b7d;border-color:#0b6b7d;color:#fff}
.legal-card{background:#fff;border-radius:16px;padding:26px 28px;box-shadow:0 10px 30px rgba(15,23,42,.06);line-height:1.9;font-size:14px}
.legal-card h1{font-size:24px;margin:0 0 6px;color:#12324a}
.legal-meta{font-size:12px;color:#64748b;border-bottom:1px solid #e2e8f0;padding-bottom:14px;margin-bottom:18px}
.legal-note{background:#f0f8fa;border-left:3px solid #0b6b7d;border-radius:8px;padding:12px 14px;color:#28546b;margin-bottom:18px;font-size:13.5px}
.legal-card h2{font-size:17px;margin:24px 0 8px;color:#12324a}
.legal-card p{margin:0 0 10px;color:#334155}
.legal-table{width:100%;border-collapse:collapse;margin:8px 0 16px;font-size:13px}
.legal-table th,.legal-table td{border:1px solid #e2e8f0;padding:9px 10px;text-align:left;vertical-align:top}
.legal-table th{background:#f8fafc;color:#12324a;font-weight:700}
.legal-foot{display:flex;justify-content:space-between;gap:12px;align-items:center;color:#94a3b8;font-size:12px;padding:18px 4px 0;flex-wrap:wrap}
.legal-foot a{color:#0b6b7d;text-decoration:none}
@media (max-width:560px){.legal-wrap{padding:18px 12px 36px}.legal-card{padding:18px 16px;border-radius:12px}.legal-card h1{font-size:21px}.legal-table{display:block;overflow-x:auto;white-space:nowrap}}

/* V1.9.60：390px 窄屏顶栏收口，避免项目选择 + 用户名 + 退出按钮横向溢出 */
@media (max-width: 430px){
  .user-chip{display:none}
  .topbar-right{gap:6px}
  .topbar-right #btn-logout{padding:6px 10px;font-size:12.5px}
}

/* V1.9.60：文字按钮与合规页底部链接的触控高度补到 44px */
.forgot-row .link-btn{min-height:44px;padding:8px 0;display:inline-flex;align-items:center}
.legal-foot a{display:inline-flex;align-items:center;min-height:44px}
