[v-cloak] {
  display: none !important;
}
* {
  margin:0;
  padding:0;
  box-sizing:border-box;
}
html, body {
  overflow-x: hidden;   /* 旧浏览器 fallback */
  overflow-x: clip;     /* 不创建滚动容器，保证 position:sticky 正常冻结 */
}
body {
  background:#f7fbf8;
  font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto;
  padding:16px;
  padding-top:220px;
  color:#222;
  -webkit-tap-highlight-color: transparent;
  display:flex;
  flex-direction:column;
  min-height:100vh;
  box-sizing:border-box;
}
/* 任务管理页：无顶部横幅，页面直接置顶 */
body.task-page {
  padding-top:8px;
}
/* 首页：无大标题，整体上移 */
body.home-page {
  padding-top:6px;
}
body.home-page .page-header {
  margin-bottom:4px;
}
body.task-page .task-sticky-header {
  top:0;
}
.container {
  max-width:1400px;
  margin:0 auto;
}
.page-header {
  text-align:center;
  margin-bottom:32px;
  color:#166534;
  position:relative;
}
.page-header h2 {
  font-size:32px;
  font-weight:700;
  letter-spacing:2px;
  opacity:0.5;
  background:linear-gradient(90deg, #166534, #22a74d, #0d47a1, #6a1b9a, #d32f2f, #f57c00, #166534);
  background-size:300% 100%;
  -webkit-background-clip:text;
  background-clip:text;
  -webkit-text-fill-color:transparent;
  animation: titleGradient 4s linear infinite;
  text-shadow:none;
}
@keyframes titleGradient {
  0% { background-position:0% 50%; }
  100% { background-position:300% 50%; }
}
.admin-link {
  display:inline-flex;
  align-items:center;
  color:#166534;
  text-decoration:none;
  font-size:13px;
  padding:5px 10px;
  border:1px solid #86c993;
  border-radius:8px;
  background:rgba(255,255,255,0.5);
  transition: all 0.2s ease;
}
.admin-link:hover {
  background:#dcf5e3;
}
.feature-link {
  display:inline-flex;
  align-items:center;
  color:#1e40af;
  text-decoration:none;
  font-size:13px;
  padding:5px 10px;
  border:1px solid #93c5fd;
  border-radius:8px;
  background:rgba(219,234,254,0.5);
  transition: all 0.2s ease;
}
.feature-link:hover {
  background:#dbeafe;
  box-shadow:0 2px 6px rgba(30,64,175,0.12);
}
.header-links {
  position:absolute;
  right:0;
  top:50%;
  transform:translateY(-50%);
  display:flex;
  gap:6px;
  align-items:center;
}
.last-update {
  position:fixed;
  right:16px;
  bottom:16px;
  z-index:100;
  color:#888;
  font-size:11px;
  white-space:nowrap;
  background:rgba(230,245,235,0.85);
  padding:4px 10px;
  border-radius:6px;
  box-shadow:0 1px 3px rgba(0,0,0,0.08);
}
.page-header {
  position:relative;
  min-height:48px;
}

.search-wrap {
  display:flex;
  gap:12px;
  margin-bottom:16px;
}
.search-input-wrap {
  flex:1;
  position:relative;
}
.search-suggest {
  position:absolute;
  top:calc(100% + 6px);
  left:0;
  right:0;
  background:#fff;
  border:1px solid #d1e7d8;
  border-radius:10px;
  box-shadow:0 6px 18px rgba(22,101,52,0.1);
  max-height:300px;
  overflow-y:auto;
  z-index:50;
}
.search-suggest-item {
  padding:9px 14px;
  font-size:14px;
  cursor:pointer;
  border-bottom:1px solid #f3f4f6;
  color:#1f2937;
  transition:background 0.15s;
}
.search-suggest-item:last-child { border-bottom:none; }
.search-suggest-item:hover {
  background:#f0fdf4;
  color:#166534;
}
.hl-sug {
  font-style:normal;
  color:#2563eb;
  font-weight:600;
  background:#dbeafe;
  padding:0 2px;
  border-radius:2px;
}
.search-input {
  width:100%;
  border:1px solid #86c993;
  border-radius:12px;
  padding:12px 40px 12px 14px;
  font-size:16px;
  background:#ffffff;
  min-width:0;
}
.search-input:focus {
  outline:none;
  border-color:#22a74d;
  box-shadow:0 0 0 2px rgba(34,167,77,0.15);
}
.clear-btn {
  position:absolute;
  right:10px;
  top:50%;
  transform:translateY(-50%);
  width:24px;
  height:24px;
  border:none;
  border-radius:50%;
  background:#d1d5db;
  color:#fff;
  font-size:16px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:0;
}
.clear-btn:hover {
  background:#9ca3af;
}
.search-btn {
  min-width:90px;
}

.ios26-glass {
  background: rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.6);
  box-shadow: 0 4px 16px rgba(22,101,52,0.12), inset 0 1px 0 rgba(255,255,255,0.7);
  color:#166534;
  border-radius:14px;
  padding:12px 20px;
  font-size:15px;
  cursor:pointer;
  transition: all 0.22s ease;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  white-space:nowrap;
}
.ios26-glass:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.38);
  box-shadow: 0 6px 20px rgba(22,101,52,0.15), inset 0 1px 0 rgba(255,255,255,0.8);
}
.ios26-glass:active:not(:disabled) {
  transform: scale(0.96);
  background:rgba(255,255,255,0.18);
  box-shadow:0 2px 8px rgba(22,101,52,0.08);
}
.ios26-glass:disabled {
  opacity:0.6;
  cursor:not-allowed;
}

/* ============= 自定义弹窗：绿色描边 + 磨砂玻璃 ============= */
.md-mask {
  position:fixed;
  inset:0;
  background:rgba(22,101,52,0.22);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:9999;
  animation: mdFadeIn 0.18s ease;
  padding:20px;
}
@keyframes mdFadeIn {
  from { opacity:0; }
  to   { opacity:1; }
}
.md-box {
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  border: 2px solid rgba(34,197,94,0.75);
  outline: 1px solid rgba(22,163,74,0.35);
  outline-offset: 4px;
  box-shadow:
    0 20px 48px rgba(22,101,52,0.22),
    0 2px 6px rgba(22,101,52,0.08),
    inset 0 1px 0 rgba(255,255,255,0.9),
    inset 0 0 0 1px rgba(255,255,255,0.45);
  border-radius:18px;
  padding:24px 24px 20px;
  width:100%;
  max-width:380px;
  min-width:260px;
  color:#14532d;
  animation: mdPopIn 0.22s cubic-bezier(0.2, 0.9, 0.25, 1.05);
}
@supports not (backdrop-filter: blur(22px)) {
  .md-box {
    background: rgba(255,255,255,0.94);
  }
}
@keyframes mdPopIn {
  from { opacity:0; transform: translateY(-10px) scale(0.96); }
  to   { opacity:1; transform: translateY(0) scale(1); }
}
.md-header {
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:12px;
}
.md-icon {
  flex:none;
  width:22px;
  height:22px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-size:13px;
  font-weight:700;
}
.md-icon.md-info  { background:#dcfce7; color:#15803d; border:1px solid #86efac; }
.md-icon.md-warn  { background:#fef3c7; color:#a16207; border:1px solid #fcd34d; }
.md-icon.md-err   { background:#fee2e2; color:#b91c1c; border:1px solid #fca5a5; }
.md-title {
  font-size:15px;
  font-weight:700;
  color:#14532d;
  letter-spacing:0.2px;
}
.md-msg {
  font-size:14px;
  line-height:1.65;
  color:#1f2937;
  padding:6px 0 4px 0;
  word-break:break-all;
}
.md-btns {
  margin-top:20px;
  display:flex;
  gap:10px;
  justify-content:flex-end;
}
.md-btn {
  padding:8px 18px;
  border-radius:10px;
  font-size:14px;
  font-weight:500;
  cursor:pointer;
  border:1px solid transparent;
  transition: all 0.18s ease;
  white-space:nowrap;
}
.md-btn.md-primary {
  background: linear-gradient(180deg, #22c55e 0%, #16a34a 100%);
  color:#fff;
  border:1px solid rgba(22,163,74,0.6);
  box-shadow:
    0 2px 6px rgba(22,163,74,0.3),
    inset 0 1px 0 rgba(255,255,255,0.35);
}
.md-btn.md-primary:hover {
  background: linear-gradient(180deg, #16a34a 0%, #15803d 100%);
  transform: translateY(-1px);
  box-shadow:
    0 4px 10px rgba(22,163,74,0.35),
    inset 0 1px 0 rgba(255,255,255,0.35);
}
.md-btn.md-primary:active { transform: translateY(0) scale(0.97); }

.md-btn.md-ghost {
  background: rgba(255,255,255,0.45);
  color:#166534;
  border:1px solid rgba(34,167,77,0.35);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.md-btn.md-ghost:hover {
  background: rgba(255,255,255,0.75);
  border-color: rgba(34,167,77,0.6);
}
.md-btn.md-ghost:active { transform: scale(0.97); }

@media(max-width:640px){
  .md-box {
    padding:20px 18px 16px;
    border-radius:16px;
  }
  .md-msg { font-size:14px; }
  .md-btns { gap:8px; }
  .md-btn  { padding:9px 16px; width:50%; }
}

.spinner {
  width:16px;
  height:16px;
  border:2px solid rgba(22,101,52,0.2);
  border-top-color:#166534;
  border-radius:50%;
  animation: spin 0.6s linear infinite;
  display:inline-block;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

.result-stats {
  font-size:14px;
  color:#555;
  margin-bottom:12px;
}
.result-stats strong {
  color:#166534;
  font-size:16px;
}
.result-stats-empty {
  color:#aaa;
}
.error-msg {
  background:#fef2f2;
  border:1px solid #fecaca;
  color:#dc2626;
  padding:12px 16px;
  border-radius:8px;
  margin-bottom:16px;
  font-size:14px;
}
.result-stats-empty strong {
  color:#999;
}

/* 结果表格 */
.table-wrap {
  overflow-x:auto;
  overflow-y:auto;
  max-height:calc(100vh - 200px);
  border:2px solid #22a74d;
  border-radius:12px;
  background:#fff;
  -webkit-overflow-scrolling:touch;
  box-shadow:0 2px 8px rgba(22,101,52,0.08);
}

/* 表格外搜索栏（固定不随表格滚动） */
.table-search-bar {
  display:flex;
  gap:10px;
  padding:14px 16px;
  margin-bottom:16px;
  background:linear-gradient(180deg, #f0faf3, #e6f5ea);
  border:2px solid #86c993;
  border-radius:12px;
  align-items:center;
}
.table-search-input {
  flex:1;
}
.table-search-input .search-input {
  font-size:14px;
  padding:10px 36px 10px 12px;
}
.search-btn-small {
  padding:10px 20px;
  font-size:14px;
  white-space:nowrap;
}

/* 搜索进度条 */
.search-progress-bar {
  position:relative;
  height:28px;
  background:#e8f5ed;
  overflow:hidden;
  margin:4px 2px 0;
  border-radius:14px;
}
.search-progress-fill {
  position:absolute;
  top:0;
  left:0;
  height:100%;
  background:linear-gradient(90deg, #166534, #22a74d, #4ade80, #22a74d, #166534);
  background-size:300% 100%;
  transition:width 0.15s ease-out;
  animation: progressShimmer 1.2s linear infinite;
}
@keyframes progressShimmer {
  0% { background-position:0% 50%; }
  100% { background-position:300% 50%; }
}
.search-progress-text {
  position:absolute;
  top:50%;
  left:50%;
  transform:translate(-50%, -50%);
  font-size:12px;
  font-weight:600;
  color:#166534;
  white-space:nowrap;
  z-index:2;
  letter-spacing:0.5px;
}
.result-table {
  width:100%;
  border-collapse:separate;
  border-spacing:0;
  font-size:13px;
  min-width:1400px;
}
.result-table th {
  background:linear-gradient(180deg, #f0faf3, #e6f5ea);
  color:#166534;
  font-weight:600;
  padding:12px 10px;
  text-align:center;
  border-bottom:2px solid #86c993;
  border-right:1px solid #b8e1c1;
  white-space:nowrap;
  position:sticky;
  top:0;
  z-index:10;
  background-clip:padding-box;
}
.result-table th:last-child {
  border-right:none;
}
.result-table td {
  padding:10px;
  border-bottom:1px solid #e8f5ed;
  border-right:1px solid #e8f5ed;
  white-space:nowrap;
  color:#333;
  background:#fff;
  text-align:center;
}
.result-table td:last-child {
  border-right:none;
}
.result-table tbody tr:hover td {
  background:#f4faf5;
}
.result-table tbody tr:last-child td {
  border-bottom:none;
}
.result-table tbody tr.row-left td,
.result-table tbody tr.row-left td.loc-col {
  background:rgba(173, 216, 230, 0.5) !important;
}
.result-table tbody tr.row-right td,
.result-table tbody tr.row-right td.loc-col {
  background:rgba(144, 238, 144, 0.5) !important;
}
.result-table tbody tr.row-left.row-border td,
.result-table tbody tr.row-right.row-border td {
  --bc: #ef4444;
  animation: marqueeRainbow 1.2s linear infinite;
}
.result-table tbody tr.row-left.row-border td:first-child,
.result-table tbody tr.row-right.row-border td:first-child {
  box-shadow:
    inset 0 3px 0 var(--bc),
    inset 0 -3px 0 var(--bc),
    inset 3px 0 0 var(--bc);
}
.result-table tbody tr.row-left.row-border td:last-child,
.result-table tbody tr.row-right.row-border td:last-child {
  box-shadow:
    inset 0 3px 0 var(--bc),
    inset 0 -3px 0 var(--bc),
    inset -3px 0 0 var(--bc);
}
.result-table tbody tr.row-left.row-border td:not(:first-child):not(:last-child),
.result-table tbody tr.row-right.row-border td:not(:first-child):not(:last-child) {
  box-shadow:
    inset 0 3px 0 var(--bc),
    inset 0 -3px 0 var(--bc);
}
@keyframes marqueeRainbow {
  0%   { --bc: #ef4444; }
  16%  { --bc: #f97316; }
  33%  { --bc: #eab308; }
  50%  { --bc: #22c55e; }
  66%  { --bc: #06b6d4; }
  83%  { --bc: #3b82f6; }
  100% { --bc: #ef4444; }
}
.loc-col {
  color:#166534;
  font-weight:500;
  background:#f0faf3 !important;
  min-width:100px;
}
.td-empty {
  text-align:center;
  color:#888;
  padding:40px 0 !important;
  font-size:14px;
}
.td-error {
  color:#dc2626;
  background:#fef2f2 !important;
}
.td-loading {
  text-align:center;
  color:#166534;
  padding:30px 0 !important;
  font-size:14px;
}
.empty-row {
  text-align:center;
  color:#999;
  padding:40px 8px !important;
  background:#fafdfb;
}
.hl {
  background:#fef08a;
  color:#166534;
  font-style:normal;
  border-radius:2px;
  padding:0 1px;
  animation: hlPulse 1.5s ease-in-out infinite;
}
@keyframes hlPulse {
  0%, 100% {
    background:#fef08a;
    box-shadow:0 0 0 0 rgba(254,240,138,0.6);
  }
  50% {
    background:#fde047;
    box-shadow:0 0 6px 2px rgba(253,224,71,0.5);
  }
}

/* 颜色徽章 - 高对比度 */
.color-badge {
  display:inline-block;
  padding:4px 12px;
  border-radius:14px;
  font-size:12px;
  font-weight:600;
  border:1.5px solid #ccc;
  min-width:56px;
  text-align:center;
  line-height:1.4;
  position:relative;
  overflow:hidden;
  white-space:nowrap;
  letter-spacing:0.3px;
}
.color-badge-dual {
  position:relative;
  padding:4px 12px;
}
.color-badge-dual .color-half {
  position:absolute;
  left:0;
  right:0;
  height:50%;
}
.color-badge-dual .color-half-top {
  top:0;
}
.color-badge-dual .color-half-bottom {
  bottom:0;
}
.color-badge-dual .color-text {
  position:relative;
  z-index:1;
  font-weight:700;
  font-size:11px;
}
.color-unknown {
  color:#666;
  font-size:13px;
}

.empty-tip {
  text-align:center;
  color:#779980;
  padding:60px 0;
  font-size:15px;
}

.search-info {
  text-align:center;
  color:#8ab197;
  font-size:13px;
  padding:6px 0 10px;
}
.search-info strong {
  color:#14532d;
  font-size:16px;
  margin:0 2px;
  font-weight:800;
}
.footer-bar {
  display:flex;
  justify-content:space-between;
  align-items:center;
  color:#8ab197;
  font-size:13px;
  padding:24px 0 8px;
  gap:12px;
  flex-wrap:wrap;
}
.footer-bar strong {
  color:#166534;
  font-size:16px;
  margin:0 2px;
}
.footer-link {
  color:#166534;
  text-decoration:none;
  font-size:13px;
  font-weight:500;
  padding:4px 12px;
  border:1px solid #86c993;
  border-radius:16px;
  background:rgba(220,252,231,0.6);
  white-space:nowrap;
  transition:all 0.2s ease;
}
.footer-link:hover {
  background:#dcfce7;
  box-shadow:0 2px 6px rgba(22,101,52,0.12);
}
/* 留言 / 任务管理 按钮组：两按钮相邻排列 */
.footer-links {
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
/* 任务管理按钮：与留言按钮 UI 一致，浅蓝色系 */
.footer-link-blue {
  color:#1e40af;
  border-color:#93c5fd;
  background:rgba(219,234,254,0.6);
}
.footer-link-blue:hover {
  background:#dbeafe;
  box-shadow:0 2px 6px rgba(30,64,175,0.12);
}
.footer-db-time {
  color:#8ab197;
  font-size:12px;
  white-space:nowrap;
}
/* 页脚信息行：数据库更新 + 当前在线 + 历史最高。窄屏自动换行，不会顶破布局 */
.footer-meta {
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  align-items:center;
  gap:4px 16px;
  max-width:100%;
  padding:0 10px;
}
.footer-online,
.footer-peak {
  font-size:12px;
  color:#8ab197;
  white-space:nowrap;
}
.footer-online b,
.footer-peak b {
  font-size:13px;
  font-weight:600;
  /* 等宽数字：人数从 9 变 10 时整行不会左右抖动 */
  font-variant-numeric:tabular-nums;
}
.footer-online b { color:#15803d; }
.footer-peak b { color:#b45309; }
/* 在线状态小圆点：持续呼吸，暗示"实时"；绿色代表在线，各主题下都保持绿色 */
.online-dot {
  display:inline-block;
  width:7px;
  height:7px;
  margin-right:5px;
  border-radius:50%;
  background:#22c55e;
  vertical-align:1px;
  box-shadow:0 0 0 0 rgba(34,197,94,0.5);
  animation:onlinePulse 2.4s ease-out infinite;
}
@keyframes onlinePulse {
  0%   { box-shadow:0 0 0 0 rgba(34,197,94,0.5); }
  70%  { box-shadow:0 0 0 6px rgba(34,197,94,0); }
  100% { box-shadow:0 0 0 0 rgba(34,197,94,0); }
}
@media (prefers-reduced-motion: reduce) {
  .online-dot { animation:none; }
}
.footer-bar .greeting {
  color:#7a9eaf;
  font-style:italic;
  font-size:12px;
}
.daily-quote {
  margin-top:24px;
  font-size:16px;
  letter-spacing:0.5px;
  overflow:hidden;
  white-space:nowrap;
  max-width:400px;
  margin-left:auto;
  margin-right:auto;
}
.daily-quote span {
  display:inline-block;
  padding-left:100%;
  background:linear-gradient(90deg, #166534, #0d47a1, #6a1b9a, #d32f2f, #f57c00, #166534);
  background-size:300% 100%;
  -webkit-background-clip:text;
  background-clip:text;
  -webkit-text-fill-color:transparent;
  animation: quoteScroll 12s linear infinite, titleGradient 4s linear infinite;
}
@keyframes quoteScroll {
  0% { transform:translateX(0); }
  100% { transform:translateX(-100%); }
}

/* ---------- 右下角悬浮终端窗（语录 / 国庆祝福）
   视觉：iOS 液态玻璃（Liquid Glass）—— 75% 不透明玻璃体 + 高模糊提饱和 +
   顶部镜面高光 + 内侧白色描边 + 大圆角。
   标题栏右侧为 macOS 风格三色按钮（紧凑尺寸），顺序 绿 / 黄 / 红：
   绿 = 最小化（收起正文，再点还原）· 黄 = 装饰 · 红 = 关闭（点红点即关闭） ---------- */
.term-widget {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 20;                  /* 低于搜索联想(30)与看板弹窗(9997)，不抢页面交互 */
  width: 300px;
  border-radius: 20px;          /* 液态玻璃：更大的连续圆角 */
  overflow: hidden;
  /* 玻璃体 75% 不透明度；文字本身保持不透明，保证清晰可读 */
  background: rgba(18, 20, 24, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow:
    0 20px 44px rgba(0, 0, 0, 0.32),
    0 2px 10px rgba(0, 0, 0, 0.20),
    inset 0 1px 0 rgba(255, 255, 255, 0.34),
    inset 0 -1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  font-family: ui-monospace, Menlo, Consolas, "Courier New", monospace;
  user-select: none;
  isolation: isolate;
}
/* 镜面高光层：模拟玻璃表面斜向反射，指针穿透、不影响交互 */
.term-widget::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  border-radius: inherit;
  background:
    linear-gradient(158deg, rgba(255, 255, 255, 0.20) 0%, rgba(255, 255, 255, 0.06) 30%, rgba(255, 255, 255, 0) 56%),
    radial-gradient(120% 62% at 50% -16%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0) 72%);
}
.term-bar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  height: 22px;                 /* 紧凑标题条：只比 z8866.top 字体（12.5px）高一点 */
  padding: 0 10px;
  background: rgba(255, 255, 255, 0.10);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.term-bar:hover { background: rgba(255, 255, 255, 0.16); }
.term-title {
  flex: 1;
  min-width: 0;
  font-size: 12.5px;
  letter-spacing: 0.5px;
  color: #f4f4f5;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* --- 三色按钮：从左到右 绿 / 黄 / 红 --- */
.term-dots { display: inline-flex; align-items: center; gap: 7px; flex: none; }
.term-dot {
  flex: none;
  width: 10px;
  height: 10px;
  padding: 0;
  border: none;
  border-radius: 50%;
  display: block;
  position: relative;
  appearance: none;
  -webkit-appearance: none;
  /* 液态玻璃按钮：顶部内高光 + 底部暗边 + 轻微外投影，做出果冻质感 */
  box-shadow:
    inset 0 1px 0.75px rgba(255, 255, 255, 0.75),
    inset 0 -1px 1.5px rgba(0, 0, 0, 0.20),
    0 1px 2px rgba(0, 0, 0, 0.30);
}
.term-dot-green  { background: radial-gradient(circle at 32% 28%, #7df2a0, #2ecc5a 62%, #21a447); }
.term-dot-yellow { background: radial-gradient(circle at 32% 28%, #ffe07a, #ffc93c 62%, #e0a900); }
.term-dot-red    { background: radial-gradient(circle at 32% 28%, #ff9a90, #ff5f57 62%, #d93a32); }

/* 可点击的点（绿 = 最小化、红 = 关闭）；::after 把热区扩到约 31px，移动端好点 */
.term-dot-btn { cursor: pointer; transition: filter 0.15s, transform 0.12s; }
.term-dot-btn::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
}
.term-dot-btn:hover { filter: brightness(1.14); }
.term-dot-btn:active { transform: scale(0.9); filter: brightness(0.94); }
.term-dot-btn:focus-visible { outline: 2px solid rgba(255, 255, 255, 0.78); outline-offset: 2px; }
.term-body {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  /* 紧凑包裹：不设固定高度，由文字 + padding 撑起，框体只比文字高一点 */
  padding: 10px 14px 12px;
  overflow: hidden;
}
.term-text {
  margin: 0;
  width: 100%;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.55;
  color: #6cf7a3;
  text-shadow: 0 0 7px rgba(108, 247, 163, 0.55);
  /* 长文本自动换行 + 最多 2 行 + 溢出省略：紧凑框体下不溢出、不被裁切 */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
  word-break: break-word;
  /* 出现动画：位移限制在窗口内部（仅 6px）
     注意用 forwards 而不是 both：both 会在动画首帧前就套用 opacity:0，
     一旦动画被暂停（后台标签页 / 减少动态效果 / 截图定格）文字会整体消失 */
  animation: termTextIn 0.45s ease forwards;
}
@keyframes termTextIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
.term-cursor {
  display: inline-block;
  width: 7px;
  height: 1em;
  margin-left: 3px;
  vertical-align: -0.12em;
  background: currentColor;
  animation: termCursorBlink 1s steps(1, end) infinite;
}
@keyframes termCursorBlink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}
/* 系统开启"减少动态效果"时关掉动画，避免任何不可见状态 */
@media (prefers-reduced-motion: reduce) {
  .term-text, .term-cursor { animation: none; }
  /* 滚动字幕降级为静态换行——绝不允许文字停在容器外不可见 */
  .term-text.term-marquee { display: -webkit-box; white-space: normal; }
  .term-marquee-inner { animation: none !important; padding-left: 0; transform: none; white-space: normal; }
}

/* ---------- 语录滚动字幕（从右往左，经典跑马灯方向） ----------
   p.term-text 负责裁剪（overflow hidden），span.term-marquee-inner 负责移动。
   做法：inner 加 padding-left:100%（相对容器宽），使文字初始恰好停在容器右缘外；
   再用 translateX 从 0 → -100%（相对 inner 自身宽 = 容器宽 + 文本宽），
   恰好把文字从右缘一路送到左缘外——全程单向、无不可见死区。
   滚动时长由 JS 用隐藏测宽尺（.term-measure）实测「容器宽 + 文本实宽」
   按恒定速度换算，任何长度的语录都能完整滚完。 */
.term-measure {
  position: absolute;
  left: 0;
  top: 0;
  visibility: hidden;          /* 只参与布局测量，不显示、不拦截事件 */
  white-space: nowrap;
  pointer-events: none;
  font-size: 13px;             /* 必须与 .term-text 同字号，测量才准确 */
  font-weight: 500;
}
.term-text.term-marquee {
  display: block;
  white-space: nowrap;
  overflow: hidden;
}
.term-marquee-inner {
  display: inline-block;
  white-space: nowrap;
  padding-left: 100%;            /* 文字起点 = 容器右缘（padding 撑出容器宽的距离） */
  animation: termMarqueeRL 14s linear infinite; /* 实际时长由内联样式按文本长度给定 */
}
@keyframes termMarqueeRL {
  0%   { transform: translateX(0); }     /* 文字头在容器右缘，即将进入 */
  90%  { transform: translateX(-100%); } /* 文字尾完全滚出容器左缘 */
  100% { transform: translateX(-100%); } /* 尾部约 10% 空窗停顿，再进下一条 */
}
/* 国庆期间（10-01~10-07）：金色祝福字，与页面国庆主题呼应 */
.term-widget.term-festive .term-text {
  color: #ffd76a;
  text-shadow: 0 0 8px rgba(255, 215, 106, 0.55);
}
/* 移动端自适应：贴边、限宽、字号收紧、整体上移避开浏览器底部工具栏 */
@media (max-width: 640px) {
  .term-widget {
    right: 10px;
    /* 移动端浏览器（Safari / Chrome / 微信）底部有一条工具栏会压住窗口，
       整体上移 72px，保证窗口与三色按钮都能被点到 */
    bottom: 72px;
    width: auto;
    min-width: 190px;
    max-width: calc(100vw - 20px);
    border-radius: 18px;
    /* 移动端 GPU 较弱，模糊降一档，仍然保持玻璃质感 */
    backdrop-filter: blur(18px) saturate(170%);
    -webkit-backdrop-filter: blur(18px) saturate(170%);
  }
  .term-bar { height: 20px; padding: 0 10px; }
  .term-dots { gap: 7px; }
  .term-dot { width: 10px; height: 10px; }
  .term-body { padding: 9px 12px 11px; }
  .term-text { font-size: 12px; -webkit-line-clamp: 2; }
  .term-measure { font-size: 12px; }
  /* 页脚在线人数：移动端字体收紧，窄屏换行更好看 */
  .footer-online,
  .footer-peak { font-size: 11px; }
  .footer-online b,
  .footer-peak b { font-size: 12px; }
  .online-dot { width: 6px; height: 6px; margin-right: 4px; }
}
.eop-warn {
  display:block;
  margin:6px auto 0;
  padding:8px 16px;
  font-size:15px;
  font-weight:bold;
  color:#dc2626;
  background:#fef08a;
  border-radius:6px;
  text-align:center;
  width:fit-content;
  animation:eopBlink 0.8s ease-in-out infinite;
}
@keyframes eopBlink {
  0%, 100% { background:#fef08a; color:#dc2626; }
  50% { background:#fde047; color:#b91c1c; }
}

/* 任务管理 */
.task-add-form {
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  border: 1px solid rgba(134, 201, 147, 0.85);
  outline: 1px solid rgba(34,197,94,0.22);
  outline-offset: 2px;
  box-shadow:
    0 14px 34px rgba(22,101,52,0.12),
    0 2px 6px rgba(22,101,52,0.06),
    inset 0 1px 0 rgba(255,255,255,0.9),
    inset 0 0 0 1px rgba(255,255,255,0.45);
  border-radius:16px;
  padding:16px 18px;
  margin: 0 auto 14px;
  width: 100%;
  position: relative;
  z-index: 30;            /* 高于筛选栏(10)：保证自动补全下拉覆盖筛选栏与列表 */
}
@supports not (backdrop-filter: blur(22px)) {
  .task-add-form {
    background: rgba(255,255,255,0.94);
  }
}
.task-add-row {
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
  justify-content:flex-start;
}
.task-input-wrap {
  position:relative;
  flex: 1 1 360px;            /* 看板号占据主体弹性空间（加宽） */
  min-width: 260px;
  z-index: 1;
}
.task-input {
  width:100%;
  padding:10px 40px 10px 14px;
  border:1.5px solid rgba(167, 243, 208, 0.95);
  border-radius:10px;
  font-size:16px;
  outline:none;
  box-sizing:border-box;
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.9),
    0 1px 2px rgba(15,23,42,0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.1s ease, background 0.2s ease;
  color:#0f172a;
  -webkit-appearance: none;
}
.task-input::placeholder { color:#94a3b8; letter-spacing: 0.2px; }
.task-input:hover {
  border-color: rgba(74, 222, 128, 0.95);
  background: rgba(255,255,255,0.82);
}
.task-input:focus {
  border-color: rgba(22,163,74,0.95);
  box-shadow:
    0 0 0 3px rgba(134, 239, 172, 0.45),
    inset 0 1px 0 rgba(255,255,255,0.9);
  background: rgba(255,255,255,0.95);
  transform: translateY(-0.5px);
}
@supports not (backdrop-filter: blur(16px)) {
  .task-input { background: rgba(255,255,255,0.96); }
}
.task-clear-btn {
  position:absolute;
  right:8px;
  top:50%;
  transform:translateY(-50%);
  width:24px;
  height:24px;
  border:1px solid rgba(209, 213, 219, 0.75);
  background: rgba(255,255,255,0.82);
  color:#6b7280;
  border-radius:50%;
  font-size:15px;
  cursor:pointer;
  line-height:1;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.95),
    0 1px 2px rgba(15,23,42,0.06);
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}
.task-clear-btn:hover {
  background: rgba(254, 226, 226, 0.95);
  color:#b91c1c;
  border-color: rgba(252, 165, 165, 0.85);
  transform: translateY(-50%) rotate(90deg);
}
.task-input-sm {
  width: 84px;
  padding:10px 8px;
  border:1.5px solid rgba(167, 243, 208, 0.95);
  border-radius:10px;
  font-size:16px;
  outline:none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.1s ease, background 0.2s ease;
  box-sizing:border-box;
  text-align:center;
  font-weight:600;
  color:#14532d;
  background: rgba(255,255,255,0.7);
  -webkit-appearance: none;
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.9),
    0 1px 2px rgba(15,23,42,0.04);
}
.task-input-sm::-webkit-inner-spin-button,
.task-input-sm::-webkit-outer-spin-button {
  -webkit-appearance: none !important;
  margin: 0 !important;
}
.task-input-sm::-moz-outer-spin-button,
.task-input-sm::-moz-inner-spin-button {
  -moz-appearance: none !important;
  margin: 0 !important;
}
.task-input-sm {
  -moz-appearance: textfield !important;
}
.task-input-sm::placeholder { color:#94a3b8; font-weight:400; }
.task-input-sm:hover {
  border-color: rgba(74, 222, 128, 0.95);
  background: rgba(255,255,255,0.82);
}
.task-input-sm:focus {
  border-color: rgba(22,163,74,0.95);
  box-shadow:
    0 0 0 3px rgba(134, 239, 172, 0.45),
    inset 0 1px 0 rgba(255,255,255,0.9);
  background: rgba(255,255,255,0.96);
  transform: translateY(-0.5px);
}
@supports not (backdrop-filter: blur(16px)) {
  .task-input-sm { background: rgba(255,255,255,0.96); }
}
.task-add-btn {
  padding:10px 22px;
  background:
    linear-gradient(180deg, rgba(52,211,153,0.2) 0%, rgba(34,197,94,0) 55%),
    linear-gradient(135deg, #16a34a 0%, #15803d 100%);
  color:#fff;
  border: 1px solid rgba(21, 128, 61, 0.95);
  border-radius:10px;
  font-size:14.5px;
  cursor:pointer;
  white-space:nowrap;
  transition: transform 0.16s ease, box-shadow 0.2s ease, filter 0.2s ease;
  font-weight: 600;
  letter-spacing: 0.3px;
  box-shadow:
    0 10px 20px rgba(22,101,52,0.22),
    0 1px 0 rgba(255,255,255,0.35) inset,
    0 -1px 0 rgba(21,128,61,0.35) inset;
  text-shadow: 0 1px 0 rgba(20,83,45,0.55);
}
.task-add-btn:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow:
    0 14px 26px rgba(22,101,52,0.28),
    0 1px 0 rgba(255,255,255,0.4) inset,
    0 -1px 0 rgba(21,128,61,0.4) inset;
}
.task-add-btn:active {
  transform: translateY(0.5px);
  filter: brightness(0.98);
  box-shadow:
    0 6px 12px rgba(22,101,52,0.22),
    0 1px 0 rgba(255,255,255,0.35) inset,
    0 -1px 0 rgba(21,128,61,0.4) inset;
}
.task-add-btn:disabled {
  opacity:0.5;
  cursor:not-allowed;
  filter: saturate(0.6);
  transform: none;
  box-shadow:
    0 3px 8px rgba(15,23,42,0.12),
    0 1px 0 rgba(255,255,255,0.3) inset;
}

.type-tag {
  display:inline-block;
  padding:2px 8px;
  border-radius:4px;
  font-size:12px;
  font-weight:500;
}
.type-K { background:#dbeafe; color:#1e40af; }
.type-S { background:#fce7f3; color:#be185d; }
.type-T { background:#fed7aa; color:#9a3412; }
.type-M { background:#dcfce7; color:#166534; }

.task-suggest {
  position:absolute;
  top:calc(100% + 4px);
  left:0;
  right:0;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  border:1.5px solid rgba(34,197,94,0.55);
  outline: 1px solid rgba(22,163,74,0.22);
  outline-offset: 1px;
  border-radius:12px;
  box-shadow:
    0 14px 34px rgba(22,101,52,0.22),
    0 2px 6px rgba(22,101,52,0.08),
    inset 0 1px 0 rgba(255,255,255,0.95);
  max-height: 420px;
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 99995;         /* 彻底置顶：高于 9999 的主弹窗 mask，避免任何容器截住下拉 */
}
@supports not (backdrop-filter: blur(22px)) {
  .task-suggest {
    background: rgba(255,255,255,0.96);
  }
}
.task-suggest-item {
  padding:9px 12px;
  cursor:pointer;
  border-bottom:1px solid rgba(209, 231, 216, 0.7);
  display:flex;
  justify-content: space-between;
  align-items:center;
  gap:10px;
  overflow: hidden;
}
.task-suggest-no {
  font-size:14px;
  font-weight:700;
  color:#166534;
  flex-shrink: 0;
}
.task-suggest-machine {
  font-size:12px;
  color:#4b5563;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width: 55%;
}
.task-suggest-item:hover {
  background: rgba(220, 252, 231, 0.85);
}
.task-suggest-item:last-child { border-bottom:none; }

.task-loading {
  text-align:center;
  color:#9ca3af;
  padding:40px 0;
  font-size:14px;
}

.task-filter-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  padding: 8px 12px;
  border: 1.5px solid rgba(34, 197, 94, 0.55);
  outline: 1px solid rgba(22, 163, 74, 0.25);
  outline-offset: 2px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  position: relative;
  z-index: 10;
}
@supports not (backdrop-filter: blur(22px)) {
  .task-filter-bar {
    background: rgba(247, 251, 248, 0.92);
  }
}
.task-filter-label {
  font-size: 14px;
  font-weight: 500;
  color: #166534;
  white-space: nowrap;
}
.task-filter-select-wrap {
  position: relative;
}
.task-filter-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border: 1.5px solid rgba(34,197,94,0.55);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  font-size: 14px;
  color: #166534;
  cursor: pointer;
  user-select: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
  transition: border-color 0.15s;
}
.task-filter-trigger:hover {
  border-color: #22a74d;
}
.filter-arrow {
  font-size: 9px;
  color: #6b7280;
  transition: transform 0.2s;
  display: inline-block;
}
.filter-arrow.open {
  transform: rotate(180deg);
}
.task-filter-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  min-width: 130px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  border: 1.5px solid rgba(34,197,94,0.55);
  outline: 1px solid rgba(22,163,74,0.22);
  outline-offset: 1px;
  border-radius: 12px;
  box-shadow:
    0 14px 34px rgba(22,101,52,0.22),
    0 2px 6px rgba(22,101,52,0.08),
    inset 0 1px 0 rgba(255,255,255,0.95);
  z-index: 99995;
  overflow: hidden;
}
.task-filter-item {
  padding: 9px 14px;
  font-size: 14px;
  color: #1f2937;
  cursor: pointer;
  border-bottom: 1px solid rgba(209, 231, 216, 0.7);
  text-align: center;
}
.task-filter-item:last-child { border-bottom: none; }
.task-filter-item:hover {
  background: rgba(220, 252, 231, 0.85);
  color: #166534;
}
.task-filter-item.active {
  background: rgba(220, 252, 231, 0.9);
  color: #166534;
  font-weight: 600;
}

.task-table-wrap {
  padding: 4px 0 20px;
  overflow: visible;
  -webkit-overflow-scrolling: touch;
  position: relative;
  width: 100%;
  margin: 0 auto;
}

/* ========== 固定区：添加表单 + 筛选栏 sticky ========== */
.task-sticky-header {
  position: sticky;
  top: 14px;
  z-index: 500;
  background: rgba(247, 251, 248, 0.96);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid rgba(134, 201, 147, 0.45);
  padding-bottom: 6px;
}
/* 任务页：冻结时横向铺满屏幕，避免两侧缝隙露出滚动内容（内边距与 body 一致保持对齐） */
body.task-page .task-sticky-header {
  margin-left: -16px;
  margin-right: -16px;
  padding-left: 16px;
  padding-right: 16px;
  padding-top: 8px;
}
/* 桌面端：同样用 clip 防止横向滚动且不破坏 sticky */
@media(min-width:641px){
  html, body { overflow-x: clip; }
}
.task-table {
  width:100%;
  border-collapse:separate;
  border-spacing:0;
  background: transparent;
  border-radius:10px;
  overflow:visible;
  border:0;
  font-size:13px;
  table-layout:fixed;
  margin: 0 auto;
}
/* 固定列宽：今日任务与历史记录、进行中与已完成行共享同一套列几何，彻底杜绝列偏移 */
.task-table col.col-board { width: 27%; }
.task-table col.col-qty   { width: 18%; }
.task-table col.col-date  { width: 32%; }
.task-table col.col-act   { width: 23%; }
.task-table thead {
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.task-table thead tr {
  border: 1.5px solid rgba(134, 201, 147, 0.85);
  border-radius: 10px 10px 0 0;
}
.task-table th {
  padding:10px 10px;
  text-align:center;
  color:#166534;
  font-weight:600;
  font-size:13px;
  border: none !important;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  background: rgba(247, 251, 248, 0.9);
  height: 38px;
  line-height: 1.2;
  box-sizing: border-box;
}
/* 表头随页面滚动锁定在固定头 + 折叠栏下方 */
.task-table thead th {
  position: sticky;
  top: calc(var(--sticky-head-h, 0px) + var(--sticky-toggle-h, 41px));
  z-index: 200;
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  transition: opacity 0.25s ease;
}
.task-table th:first-child { border-top-left-radius:10px; }
.task-table th:last-child  { border-top-right-radius:10px; }

/* 吸顶状态：固定头 + 折叠栏 + 表头半透明（50%），点击/聚焦后由 JS 移除该 class 恢复 */
.task-sticky-header {
  transition: opacity 0.25s ease;
}
.task-history-toggle {
  transition: opacity 0.25s ease, background 0.2s;
}
body.task-stuck .task-sticky-header,
body.task-stuck .task-history-toggle,
body.task-stuck .task-table thead th {
  opacity: 0.5;
}

/* 4 列布局：看板号 / 数量 / 日期时间 / 操作 */
.task-table th:nth-child(1) { text-align:center; padding-left:8px; padding-right:8px; }
.task-table th:nth-child(2) { }
.task-table th:nth-child(3) { }
.task-table th:nth-child(4) { }

/* ========== 行级卡片：整行矩形描边 via tr+box-shadow，单元格全透明 ========== */
.task-table tbody tr {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  cursor: pointer;
}
.task-table tbody tr td input,
.task-table tbody tr td button {
  -webkit-user-select: auto;
  user-select: auto;
  -webkit-touch-callout: default;
}
/* —— 所有 td 统一：无边框、无阴影、透明背景、固定高度 —— */
.task-table td {
  padding: 9px 6px;
  vertical-align:middle;
  text-align:center;
  overflow:visible;
  white-space:nowrap;
  color:#1f2937;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  box-sizing: border-box;
  line-height: 1.2;
  height: 44px;
}
.task-table td:first-child {
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
}
.task-table td:last-child {
  border-top-right-radius: 10px;
  border-bottom-right-radius: 10px;
}

/* td 内联子元素统一垂直居中 */
.task-table td > .td-static,
.task-table td > .td-empty-act,
.task-table td > .td-act-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  line-height: 1.2;
}
/* td 保持 table-cell，flex 布局下沉到内部包装层，保证列宽由表格统一计算 */
.td-board-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  vertical-align: middle;
}
.td-date-inner {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  line-height: 1.2;
  white-space: nowrap;
}
/* input 元素保持 inline-block，通过 height/line-height 对齐 */
.task-table td > .td-input {
  display: inline-block;
  vertical-align: middle;
  line-height: 1.2;
}
/* td-board-inner 内部元素也统一居中 */
.td-board-inner > .task-board-no {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
}
/* td-act-inner 内部按钮和占位也统一居中 */
.td-act-inner > .task-action-btn,
.td-act-inner > .td-empty-act {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
  vertical-align: middle;
}

/* ========== 行描边：统一蓝色细线 ========== */
.task-table tbody tr {
  background: transparent;
  box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
  border-radius: 10px;
  margin-top: 4px;
}
/* 生产中：绿色背景 + 蓝细线 */
.task-table tbody tr.tr-in-progress {
  background: rgba(236, 253, 245, 0.62);
  box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
}
/* 已完成：浅蓝背景 + 蓝细线 */
.task-table tbody tr.tr-completed {
  background: rgba(219, 234, 254, 0.58);
  box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
}
/* 重复任务：浅红背景 + 蓝细线 */
.task-table tbody tr.tr-duplicate {
  background: rgba(254, 242, 242, 0.7);
  box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
}
/* 已完成 + 重复 */
.task-table tbody tr.tr-completed.tr-duplicate {
  background: rgba(254, 226, 226, 0.78);
  box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
}

/* 行 hover：整行轻微变色 */
.task-table tbody tr:hover {
  background: rgba(240, 253, 244, 0.9);
}
.task-table tbody tr.tr-in-progress:hover {
  background: rgba(224, 251, 231, 0.95);
}
.task-table tbody tr.tr-completed:hover {
  background: rgba(219, 234, 254, 0.82);
}
.task-table tbody tr.tr-duplicate:hover {
  background: rgba(254, 226, 226, 0.95);
}

.td-shelf-text {
  display:inline-block;
  max-width:100%;
  background:#ecfdf5;
  color:#166534;
  border:1px solid #a7f3d0;
  padding:2px 8px;
  border-radius:6px;
  font-size:12px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  line-height:1.4;
}
.task-table tbody tr.tr-completed .td-shelf-text {
  background:#dbeafe;
  color:#1e3a8a;
  border-color:#93c5fd;
}

/* （旧的行背景/描边已移至上方卡片规则） */

.task-table .td-board {
  text-align:center;
}
.td-board-inner {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  vertical-align:middle;
  line-height: 1.2;
}
.task-board-no {
  font-size:12px;
  font-weight:700;
  color:#1e40af;
}
.task-dup-badge {
  background:#ef4444;
  color:#fff;
  font-size:10px;
  padding:1px 5px;
  border-radius:3px;
  line-height:1.4;
}

.task-table .td-date {
  color:#6b7280;
  font-size:12px;
  white-space:nowrap;
}
.task-table .td-date .td-date-top {
  font-size: 11px;
  color: inherit;
}
/* 日期时间下的任务类型标签 — 按类型着色（使用更高优先级） */
.task-table td .td-date-type {
  font-size: 10px;
  margin-top: 2px;
  font-weight: 500;
  padding: 0 6px;
  border-radius: 8px;
  line-height: 1.4;
  white-space: nowrap;
}
.task-table td .td-date-type.type-k {
  color: #166534 !important;
  background: rgba(220,252,231,0.9) !important;
}
.task-table td .td-date-type.type-s {
  color: #1e40af !important;
  background: rgba(219,234,254,0.9) !important;
}
.task-table td .td-date-type.type-t {
  color: #c2410c !important;
  background: rgba(254,231,211,0.95) !important;
}
.task-table td .td-date-type.type-m {
  color: #0369a1 !important;
  background: rgba(224,242,254,0.9) !important;
}
.task-table tbody tr.tr-completed .td-date {
  color:#374151;
}
.task-table .td-act {
  text-align:center;
  background: transparent;
  border: none;
  box-shadow: none;
}
.td-act-inner {
  display:inline-flex;
  gap:6px;
  justify-content:center;
  align-items:center;
  vertical-align:middle;
  line-height: 1.2;
}
.task-table .td-empty-act {
  color:#d1d5db;
  font-size:13px;
}
.type-empty {
  color:#9ca3af;
}

/* 工艺流程箭头形状 */
.process-flow-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  line-height: 1.4;
}

/* 工艺流程区域样式 */
.process-flow-section {
  margin: 12px 0;
  padding: 12px 14px;
  background: transparent;
  border-radius: 10px;
}
.process-flow-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.process-flow-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}
/* 工艺流程徽章（单独上方一行） */
.process-flow-title-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: linear-gradient(135deg, #1e40af, #3b82f6);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(30,64,175,0.3);
  letter-spacing: 0.5px;
  white-space: nowrap;
  margin-bottom: 6px;
}
.process-flow-steps {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
  justify-content: flex-start;
}

/* 箭头形状工序步骤（放大1.5倍） */
.process-flow-step {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 27px;
  padding: 0 16px 0 13px;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  margin-left: -2px;
  letter-spacing: 0.3px;
  line-height: 1;
  --step-color: #6366f1;
  background: #1a1a1a;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 50%, calc(100% - 10px) 100%, 0 100%, 10px 50%);
}
.process-flow-step:first-child {
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 50%, calc(100% - 10px) 100%, 0 100%);
  margin-left: 0;
  padding-left: 10px;
}
/* 彩色填充层（内缩2px形成描边） */
.process-flow-step::after {
  content: '';
  position: absolute;
  inset: 2px;
  z-index: 0;
  background: var(--step-color);
  clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 50%, calc(100% - 7px) 100%, 0 100%, 7px 50%);
}
.process-flow-step:first-child::after {
  clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 50%, calc(100% - 7px) 100%, 0 100%);
}
.process-flow-step .step-text {
  position: relative;
  z-index: 1;
  text-shadow: 0 1px 1px rgba(0,0,0,0.25);
}
.step-arrow { display: none; }

/* 工序颜色（通过CSS变量传给::after填充层） */
.step-blue { --step-color: #3b82f6; }
.step-green { --step-color: #16a34a; }
.step-green-light { --step-color: #22c55e; }
.step-yellow { --step-color: #eab308; color: #1a1a1a; text-shadow: none; }
.step-orange { --step-color: #f97316; }
.step-default { --step-color: #6366f1; }

.td-static {
  font-size:13px;
  font-weight:600;
  color:#15803d;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
}

.td-input {
  width:56px;
  padding:0 4px;
  border:none;
  border-radius:4px;
  font-size:13px;
  text-align:center;
  outline:none;
  transition:background 0.2s;
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
  background: transparent !important;
  color:#1f2937;
  font-weight:600;
  line-height: 1.2;
}
.td-input::-webkit-inner-spin-button,
.td-input::-webkit-outer-spin-button {
  -webkit-appearance: none !important;
  margin: 0 !important;
}
.td-input::-moz-outer-spin-button,
.td-input::-moz-inner-spin-button {
  -moz-appearance: none !important;
  margin: 0 !important;
}
.td-input {
  -moz-appearance: textfield !important;
}
.td-input:focus {
  background: transparent !important;
}

.task-action-btn {
  padding:3px 10px;
  line-height: 1.2;
  background:#dbeafe;
  border:1px solid #93c5fd;
  color:#1e40af;
  border-radius:6px;
  font-size:12px;
  cursor:pointer;
  transition:all 0.2s;
  box-sizing: border-box;
  white-space:nowrap;
}
.task-action-btn:hover { background:#bfdbfe; }
.task-del-btn {
  background:#fef2f2;
  border-color:#fca5a5;
  color:#dc2626;
}
.task-del-btn:hover { background:#fee2e2; }

.task-table .td-empty {
  text-align:center;
  color:#9ca3af;
  padding:40px 0;
  font-size:14px;
  background: rgba(255,255,255,0.55);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  border:1px solid rgba(134, 201, 147, 0.55);
  border-radius:12px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
}
.task-table tbody tr:has(.td-empty) td {
  border:0 !important;
  background: transparent !important;
  box-shadow:none !important;
  padding:12px 6px;
}
.task-done-badge {
  background: linear-gradient(180deg, #3b82f6 0%, #2563eb 100%);
  color:#fff;
  font-size:10px;
  padding:1px 6px;
  border-radius:6px;
  font-weight:500;
  line-height:1.4;
}
.task-prog-badge {
  background: linear-gradient(180deg, #22c55e 0%, #16a34a 100%);
  color:#fff;
  font-size:10px;
  padding:1px 6px;
  border-radius:6px;
  font-weight:500;
  line-height:1.4;
}

.task-history {
  margin: 14px auto 0;
  width: 100%;
  border: 1.5px solid rgba(34,197,94,0.55);
  outline: 1px solid rgba(22,163,74,0.25);
  outline-offset: 2px;
  border-radius:14px;
  overflow:visible;
  background: transparent;
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  box-shadow:
    0 12px 28px rgba(22,101,52,0.10),
    0 2px 6px rgba(22,101,52,0.05),
    inset 0 1px 0 rgba(255,255,255,0.85);
}
@supports not (backdrop-filter: blur(22px)) {
  .task-history-body {
    background: rgba(255,255,255,0.92);
  }
}
.task-history-toggle {
  padding:10px 16px;
  background: rgba(247,251,248,0.85);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  cursor:pointer;
  display:flex;
  justify-content:space-between;
  align-items:center;
  color:#166534;
  font-size:13px;
  font-weight:600;
  user-select:none;
  transition:background 0.2s;
  border-bottom:1px solid rgba(134, 201, 147, 0.45);
  border-radius:14px;
  /* 冻结：紧跟在固定头（输入+筛选）下方 */
  position: sticky;
  top: var(--sticky-head-h, 0px);
  z-index: 300;
}
/* 展开状态：折叠头仅顶部圆角，底部圆角交给 body */
.task-history:has(.toggle-arrow.open) > .task-history-toggle {
  border-radius:14px 14px 0 0;
}
.task-history-toggle:hover {
  background: rgba(220, 252, 231, 0.85);
}
.toggle-arrow {
  font-size:10px;
  color:#6b7280;
  transition:transform 0.25s ease;
  display:inline-block;
}
.toggle-arrow.open {
  transform:rotate(180deg);
}
.task-history-body {
  padding:0;
  background: rgba(255,255,255,0.55);
  border-radius: 0 0 14px 14px;
}
.task-history-body .task-table {
  border:none;
  border-radius:0;
}
.task-history-body .task-table thead th {
  border-top:1px solid #e5e7eb;
}

/* ========== 今日任务内「已完成」折叠分隔条（tbody 内跨 4 列） ========== */
.task-table tbody tr.task-done-sep {
  box-shadow: none !important;
  background: transparent !important;
  cursor: pointer;
  margin-top: 0;
}
.task-table tbody tr.task-done-sep:hover {
  background: transparent !important;
}
.task-table tbody tr.task-done-sep td {
  height: auto !important;
  padding: 6px 0 2px !important;
  background: transparent !important;
}
.task-done-sep-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 14px;
  background: rgba(219, 234, 254, 0.75);
  color: #1e40af;
  font-size: 12px;
  font-weight: 600;
  border-radius: 8px;
  user-select: none;
  transition: background 0.2s;
  line-height: 1.2;
}
.task-done-sep:hover .task-done-sep-inner,
.task-done-sep:active .task-done-sep-inner {
  background: rgba(219, 234, 254, 0.95);
}

/* ========== 已完成任务折叠面板（旧独立面板样式保留兼容） ========== */
.task-done-section {
  margin-top: 4px;
  border-top: 1px dashed rgba(134, 201, 147, 0.5);
  padding-top: 2px;
}
.task-done-toggle {
  padding: 8px 16px;
  background: rgba(219, 234, 254, 0.55);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #1e40af;
  font-size: 12px;
  font-weight: 600;
  user-select: none;
  border-radius: 8px;
  margin-top: 6px;
}
.task-done-toggle:hover {
  background: rgba(219, 234, 254, 0.85);
}

.task-footer {
  text-align:center;
  padding:20px 0;
}
.back-link {
  color:#166534;
  text-decoration:none;
  font-size:13px;
}
.back-link:hover { text-decoration:underline; }

/* 任务管理页面：移除宽度限制，充满屏幕 */
#app {
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
  flex: 1;
  display: flex;
  flex-direction: column;
}
/* 首页 container 单独控制宽度 */
#app.container {
  max-width: 1400px;
}

@media(max-width:640px){
  /* 手机端：clip 禁止横向滚动但不创建滚动容器，保证 sticky 冻结生效 */
  html, body {
    overflow-x: hidden !important;
    overflow-x: clip !important;
    max-width: 100vw;
  }
  body {
    padding: 12px 10px;
    padding-top: 140px;
  }
  /* 任务管理页移动端：置顶无顶部留白 */
  body.task-page {
    padding-top: 6px;
  }
  /* 首页移动端：置顶 */
  body.home-page {
    padding-top: 4px;
  }
  /* sticky 头部移动端 */
  .task-sticky-header {
    top: 12px;
    padding-bottom: 4px;
  }
  body.task-page .task-sticky-header {
    top: 0;
    margin-left: -10px;
    margin-right: -10px;
    padding-left: 10px;
    padding-right: 10px;
    padding-top: 6px;
  }
  #app {
    width: 100%;
    max-width: 100vw;
    overflow-x: clip;
    box-sizing: border-box;
  }
  .task-add-form {
    width: 100%;
    padding:10px 12px;
    border-radius:10px;
    box-sizing: border-box;
  }
  .task-add-row {
    flex-direction:row;
    align-items:center;
    gap:6px;
  }
  .task-input-wrap { min-width:auto; flex:1; min-width:0; }
  .task-input {
    width: 100%;
    box-sizing: border-box;
  }
  .task-input-sm {
    width: 64px;
    min-width: 60px;
    padding:10px 6px;
    font-size:13px;
    box-sizing: border-box;
  }
  .task-add-btn {
    width:auto;
    padding:10px 12px;
    font-size:14px;
    white-space:nowrap;
  }
  /* 任务表：与首页策略一致 —— 单元格不换行，容器允许横向滚动 */
  .task-table-wrap {
    width: 100%;
    overflow: visible;
    max-width: 100vw;
    margin: 0 auto;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }
  .task-table {
    width: 100%;
    font-size: 12px;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
  }
  .task-table th,
  .task-table td {
    padding: 7px 8px;
    white-space: nowrap;
    box-sizing: border-box;
    vertical-align: middle;
    line-height: 1.2;
    min-height: 40px;
  }
  .task-table td > .td-static,
  .task-table td > .td-empty-act,
  .task-table td > .td-act-inner {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    line-height: 1.2;
  }
  /* td 保持 table-cell，纵向排列交给 .td-date-inner 包装层（桌面端统一定义） */
  .task-table td > .td-input {
    display: inline-block;
    vertical-align: middle;
    line-height: 1.2;
  }
  .td-board-inner > .task-board-no {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
  }
  .task-table th:first-child,
  .task-table td:first-child {
    padding-left: 8px;
  }
  .task-table th:last-child,
  .task-table td:last-child {
    padding-right: 8px;
  }
  /* 移动端：列宽随内容自适应 */
  .task-board-no {
    font-size: 12.5px;
    line-height: 1.3;
  }
  .task-dup-badge,
  .task-done-badge,
  .task-prog-badge {
    padding: 1px 3px;
    font-size: 8px;
    line-height: 1.3;
  }
  .task-action-btn {
    padding: 3px 6px;
    line-height: 1.2;
    font-size: 11px;
    box-sizing: border-box;
  }
  .td-input {
    width: 48px;
    padding: 0 2px;
    font-size: 12.5px;
    box-sizing: border-box;
    -webkit-appearance: none;
    background: transparent;
    border: none;
    color:#1f2937;
    font-weight:600;
    line-height: 1.2;
  }
  .td-static {
    font-size: 12.5px;
  }
  .td-date .td-date-top {
    font-size: 10px !important;
    line-height: 1.25;
  }
  .td-date .td-date-type {
    font-size: 9px;
  }
  /* 手机端：自动补全下拉显示机台与捆数信息，缩小字体 */
  .task-suggest-machine {
    display: block;
    font-size: 11px;
  }
  /* 手机端性能优化：关闭 backdrop-filter（移动端 GPU 性能差），改用半透明背景 */
  .task-add-form,
  .task-history,
  .shelf-pop-box,
  .md-box,
  .task-table thead,
  .task-table tbody tr,
  .ios26-glass,
  .md-mask {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  .task-add-form {
    background: rgba(247, 251, 248, 0.96) !important;
  }
  .task-history {
    max-width: 100vw;
    margin: 14px auto 0;
  }
  .task-history-body {
    background: rgba(247, 251, 248, 0.96) !important;
  }
  .task-table thead {
    background: rgba(240, 249, 242, 0.98) !important;
  }
  /* 移动端 tr 背景更实 + 蓝细线描边（与桌面统一） */
  .task-table tbody tr {
    background: rgba(255,255,255,0.92);
    box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
  }
  .task-table tbody tr.tr-in-progress {
    background: rgba(236, 253, 245, 0.95);
    box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
  }
  .task-table tbody tr.tr-completed {
    background: rgba(219, 234, 254, 0.92);
    box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
  }
  .task-table tbody tr.tr-duplicate {
    background: rgba(254, 242, 242, 0.95);
    box-shadow: inset 0 0 0 1px rgba(59,130,246,0.85);
  }
  .shelf-pop-box {
    box-shadow: 0 6px 16px rgba(22,101,52,0.18), 0 1px 4px rgba(22,101,52,0.08) !important;
  }
  .md-mask {
    background: rgba(15, 42, 23, 0.45) !important;
  }
  .md-box {
    box-shadow: 0 10px 30px rgba(0,0,0,0.18) !important;
  }
  .ios26-glass {
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
  }
  .task-footer {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background: transparent !important;
  }
  .task-history-toggle {
    font-size: 12.5px;
    padding: 10px 12px;
  }
}

/* ========== 架位地址小弹窗（按下悬停提示 / 按项目风格：绿描边 + 磨砂玻璃，背景 50%） ========== */
.shelf-pop {
  position:fixed;
  z-index:9997;
  pointer-events:none;       /* 不拦截鼠标，保证"按在按钮上松开"仍触发原按钮动作 */
  transform-origin: 0 0;
  animation: shelfPopIn 0.14s cubic-bezier(0.2, 0.9, 0.25, 1) both;
}
@keyframes shelfPopIn {
  from { opacity:0; transform: translate(0, -4px) scale(0.96); }
  to   { opacity:1; transform: translate(0, 0)    scale(1); }
}
.shelf-pop-box {
  /* 按需求：背景透明度 50% + 磨砂玻璃 + 绿色描边
     宽高自适应内容，不允许换行，紧凑贴合文字 */
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  border: 2px solid rgba(34,197,94,0.72);
  outline: 1px solid rgba(22,163,74,0.32);
  outline-offset: 3px;
  box-shadow:
    0 18px 44px rgba(22,101,52,0.20),
    0 2px 8px rgba(22,101,52,0.08),
    inset 0 1px 0 rgba(255,255,255,0.9),
    inset 0 0 0 1px rgba(255,255,255,0.45);
  border-radius:14px;
  padding:4px 8px 5px;
  padding-top: 20px;  /* 为进度条+关闭按钮预留空间 */
  width: fit-content;
  min-width: 0;
  max-width: calc(100vw - 24px);
  color:#1e40af;
  text-align: left;
  white-space: nowrap;       /* 不允许换行 */
  position: relative;
  pointer-events: auto;
}

/* 顶部加载进度条 */
.shelf-pop-drag {
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}
.shelf-pop-drag:active {
  cursor: grabbing;
}
.shelf-pop-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 18px;
  background: linear-gradient(90deg, #2563eb 0%, #3b82f6 50%, #2563eb 100%);
  background-size: 200% 100%;
  border-radius: 14px 14px 0 0;
  animation: shelfPopBar 1.2s linear infinite;
  z-index: 1;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.shelf-pop-bar-pct {
  position: relative;
  z-index: 2;
  font-size: 11px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
  font-variant-numeric: tabular-nums;
}
@keyframes shelfPopBar {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.shelf-pop-bar::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  animation: shelfPopShine 1.5s ease-in-out infinite;
}
@keyframes shelfPopShine {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}
.shelf-pop-bar-done {
  background: linear-gradient(90deg, #3b82f6, #2563eb);
  animation: none;
}
.shelf-pop-loaded-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 18px;
  background: rgba(37, 99, 235, 0.08);
  border-bottom: 1px solid rgba(37, 99, 235, 0.25);
  border-radius: 14px 14px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}
.shelf-pop-loaded-text {
  font-size: 11px;
  color: #1d4ed8;
  font-weight: 600;
  letter-spacing: 0.3px;
}
@supports not (backdrop-filter: blur(22px)) {
  .shelf-pop-box { background: rgba(255,255,255,0.92); }
}
.shelf-pop-close {
  position: absolute;
  top: 3px;
  right: 5px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1px solid rgba(37,99,235,0.5);
  background: rgba(255,255,255,0.85);
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  z-index: 2;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.shelf-pop-close:hover {
  background: rgba(239, 68, 68, 0.15);
  color: #dc2626;
  border-color: rgba(239, 68, 68, 0.5);
}
.shelf-pop-close:active {
  transform: scale(0.92);
}
.shelf-pop-head {
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  margin-bottom:12px;
}
.shelf-pop-ico {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:24px;
  height:24px;
  border-radius:50%;
  background:#dcfce7;
  border:1px solid #86efac;
  font-size:13px;
}
.shelf-pop-title {
  font-size:15px;
  font-weight:700;
  color:#14532d;
  letter-spacing:0.3px;
}
.shelf-pop-body {
  padding-top: 0;
  display:flex;
  flex-direction:column;
  align-items: flex-start;
  gap: 2px;
  text-align: left;
}
.shelf-pop-row {
  display:flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 1px;
  white-space: nowrap;
  line-height: 1.25;
}
.shelf-pop-label {
  font-size:12.5px;
  color:#1e40af;
  font-weight:600;
  letter-spacing:0.1px;
  background: none;
  border: none;
  padding: 0;
  border-radius: 0;
}
.shelf-pop-row--type {
  padding-top: 10px;
  border-top: 1px dashed rgba(74, 222, 128, 0.5);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap:6px;
}
.shelf-pop-row--type .type-tag {
  font-size:13.5px;
  padding:4px 12px;
  border-radius:8px;
  margin: 0 auto;
}
.type-lg { font-size:13.5px !important; padding:4px 12px !important; margin: 0 auto; display: inline-block; }
.shelf-pop-machine {
  width:100%;
  display:block;
  text-align: center;
  font-size:11.5px;
  color:#4b5563;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.shelf-pop-val {
  display:inline;
  background: none;
  color:#1e3a8a;
  border: none;
  padding: 0;
  font-size:12.5px;
  font-weight:600;
  line-height:1.3;
  white-space: nowrap;
}
.shelf-pop-empty {
  display:inline-block;
  color:#6b7280;
  font-size:13px;
  padding:4px 0;
  margin: 0 auto;
}
.shelf-pop-sub {
  margin-top: 2px;
  font-size:12px;
  color:#4b5563;
  border-top:1px dashed rgba(74, 222, 128, 0.5);
  padding-top:10px;
  text-align: center;
}
.shelf-pop-sub b {
  color:#1e40af;
  font-weight:600;
}

/* 手机端适配：弹窗宽高自适应内容、紧凑贴合文字 */
@media(max-width:640px){
  .shelf-pop-box {
    width: fit-content !important;
    min-width: 0;
    max-width: calc(100vw - 24px);
    padding: 3px 6px 4px;
    padding-top: 18px;
  }
  .shelf-pop-label,
  .shelf-pop-val {
    font-size: 11.5px;
  }
  .shelf-pop-loaded-text {
    font-size: 10px;
  }
  .shelf-pop-bar-pct {
    font-size: 10px;
  }
  .shelf-pop-body {
    gap: 1px;
  }
  .shelf-pop-row {
    gap: 0;
  }
  .task-table .task-board-no {
    font-size: 13px;
  }
}

/* 备案信息 */
.footer-icp {
  width:100%;
  text-align:center;
  padding:10px 0 16px;
}
.footer-bottom {
  width:100%;
  text-align:center;
  padding:12px 0 16px;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:6px;
  margin-top:auto;
}
.icp-text {
  display:inline-block;
  font-size:12px;
  color:#8ab197;
  text-decoration:none;
  position:relative;
  padding:4px 12px;
  overflow:hidden;
  border-radius:4px;
  white-space:nowrap;
}
.icp-text::after {
  content:"";
  position:absolute;
  top:0;
  left:-100%;
  width:100%;
  height:100%;
  background:linear-gradient(90deg, transparent, rgba(255,255,255,0.6), transparent);
  animation: icpShine 3s ease-in-out infinite;
}
.icp-text:hover {
  color:#166534;
}
@keyframes icpShine {
  0% { left:-100%; }
  50% { left:100%; }
  100% { left:100%; }
}

/* 上传相关 */
.upload-row {
  display:flex;
  gap:10px;
  align-items:center;
  margin-bottom:8px;
}
.target-select {
  flex:1;
  border:1px solid #86c993;
  border-radius:12px;
  padding:12px 14px;
  font-size:14px;
  background:#fff;
  color:#166534;
  cursor:pointer;
  appearance:none;
  background-image:url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23166534' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat:no-repeat;
  background-position:right 12px center;
  background-size:16px;
  padding-right:36px;
}
.target-select:focus {
  outline:none;
  border-color:#22a74d;
  box-shadow:0 0 0 2px rgba(34,167,77,0.15);
}
.btn-disabled {
  opacity:0.5;
  cursor:not-allowed;
  pointer-events:none;
}
.upload-progress {
  margin-top:10px;
  display:flex;
  align-items:center;
  gap:10px;
}
.progress-bar {
  flex:1;
  height:8px;
  background:#e8f5ed;
  border-radius:4px;
  overflow:hidden;
}
.progress-fill {
  height:100%;
  background:linear-gradient(90deg, #22a74d, #16a34a);
  border-radius:4px;
  transition: width 0.3s ease;
}
.progress-text {
  font-size:13px;
  color:#166534;
  font-weight:500;
  min-width:50px;
  text-align:right;
}
.upload-msg {
  font-size:13px;
  color:#337044;
  margin-top:6px;
  padding-left:2px;
}
.upload-info-text {
  font-size:13px;
  color:#6b9b78;
  margin-bottom:8px;
}
.tip {
  margin-top:8px;
  font-size:14px;
  color:#22a74d;
}
.tip-error {
  color:#dc2626;
}

/* 管理页面 */
.login-box {
  max-width:400px;
  margin:60px auto;
  background:#fff;
  border:1px solid #b8e1c1;
  border-radius:16px;
  padding:32px 24px;
  text-align:center;
}
.login-box h3 {
  color:#166534;
  margin-bottom:20px;
}
.login-input-row {
  display:flex;
  gap:10px;
  margin-bottom:12px;
}
.admin-section {
  background:#fff;
  border:1px solid #b8e1c1;
  border-radius:12px;
  padding:20px;
  margin-bottom:16px;
}
.admin-section h3 {
  color:#166534;
  margin-bottom:16px;
  font-size:16px;
}
.help-list {
  list-style:none;
  padding:0;
}
.help-note {
  color:#888;
  font-size:13px;
  margin-bottom:12px;
}
.columns-preview {
  display:flex;
  gap:16px;
  flex-wrap:wrap;
}
.columns-block {
  flex:1;
  min-width:280px;
  background:#f7fbf8;
  border:1px solid #d1e7d8;
  border-radius:8px;
  padding:12px;
}
.columns-title {
  display:flex;
  justify-content:space-between;
  align-items:center;
  margin-bottom:10px;
  color:#166534;
  font-weight:500;
  font-size:14px;
}
.columns-list {
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}
.col-tag {
  background:#fff;
  border:1px solid #b8e1c1;
  color:#337044;
  padding:3px 8px;
  border-radius:4px;
  font-size:12px;
}
.columns-empty {
  color:#aaa;
  font-size:13px;
  text-align:center;
  padding:16px 0;
}
.help-list li {
  padding:6px 0;
  color:#555;
  font-size:14px;
  padding-left:18px;
  position:relative;
}
.help-list li::before {
  content:"•";
  color:#22a74d;
  position:absolute;
  left:4px;
}
.help-list strong {
  color:#166534;
}

/* 统计卡片 */
.stats-card {
  display:flex;
  gap:16px;
  margin-bottom:16px;
  flex-wrap:wrap;
}
.stats-item {
  flex:1;
  min-width:200px;
  background:#fff;
  border:1px solid #b8e1c1;
  border-radius:12px;
  padding:16px 20px;
  display:flex;
  align-items:center;
  gap:12px;
}
.stats-label {
  color:#555;
  font-size:14px;
}
.stats-num {
  color:#166534;
  font-size:24px;
  font-weight:600;
  flex:1;
}
.mini-btn {
  background:#fef2f2;
  border:1px solid #fca5a5;
  color:#dc2626;
  padding:4px 10px;
  border-radius:6px;
  font-size:12px;
  cursor:pointer;
}
.mini-btn:hover {
  background:#fee2e2;
}

@media(max-width:640px){
  body {
    padding:40px 10px 10px;
  }
  .page-header h2 {
    font-size:18px;
  }
  .page-header {
    text-align:center;
    margin-bottom:16px;
  }
  .header-links {
    position:static;
    transform:none;
    display:flex;
    flex-wrap:wrap;
    justify-content:center;
    gap:6px;
    margin-top:10px;
  }
  .admin-link,
  .feature-link {
    position:static;
    font-size:12px;
    padding:4px 8px;
  }
  .search-wrap {
    flex-direction:column;
  }
  .search-input {
    font-size:16px !important;
    padding:14px 44px 14px 16px !important;
  }
  .clear-btn {
    width:28px;
    height:28px;
    right:12px;
    font-size:18px;
  }
  .ios26-glass {
    width:100%;
    text-align:center;
    padding:14px 20px;
    font-size:16px;
    min-height:48px;
  }
  /* 表格外搜索栏 —— 移动端保持左右布局 */
  .table-search-bar {
    flex-direction:row;
    gap:8px;
    padding:10px;
    margin:0 0 16px;
    border-radius:12px;
  }
  .table-search-input {
    flex:1;
    width:auto;
    min-width:0;
  }
  .table-search-input .search-input {
    font-size:14px !important;
    padding:10px 36px 10px 12px !important;
    border-radius:10px;
  }
  .search-btn-small {
    width:auto;
    flex-shrink:0;
    padding:10px 16px;
    font-size:14px;
    min-height:auto;
  }
  .login-box {
    margin:30px auto;
    padding:24px 16px;
  }
  .login-input-row {
    flex-direction:column;
  }
  .stats-card {
    flex-direction:column;
  }
  .stats-item {
    min-width:auto;
  }
  .upload-row {
    flex-direction:column;
    align-items:stretch;
  }
  .target-select {
    font-size:16px;
    padding:14px 40px 14px 16px;
  }
  .result-table {
    font-size:12px;
    min-width:1200px;
  }
  .result-table th,
  .result-table td {
    padding:8px 6px;
  }
  .table-wrap {
    max-height:calc(100vh - 260px);
  }
  .result-stats {
    font-size:13px;
  }
  .footer-bar {
    font-size:12px;
    padding:16px 0 4px;
    justify-content:center;
  }
  .footer-center {
    min-width:auto;
  }
  .search-info {
    font-size:12px;
  }
  /* 首页性能优化：移动端关闭 backdrop-filter */
  .ios26-glass {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
  }
  .search-wrap,
  .table-search-bar,
  .login-box {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
}

@supports not (backdrop-filter: blur(14px)) {
  .ios26-glass {
    background: rgba(220, 245, 227, 0.85);
  }
}

/* 留言页面 */
.msg-form-section {
  margin-bottom: 20px;
}
.msg-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.msg-form-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.msg-form-field {
  flex: 1;
  min-width: 200px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.msg-form-full {
  flex-basis: 100%;
}
.msg-label {
  font-size: 14px;
  color: #166534;
  font-weight: 500;
}
.req {
  color: #dc2626;
  margin-right: 2px;
}
.msg-input {
  font-size: 14px;
  padding: 10px 14px;
}
.msg-select {
  font-size: 14px;
  padding: 10px 36px 10px 14px;
}
.msg-textarea {
  font-size: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #86c993;
  background: #fff;
  resize: vertical;
  min-height: 100px;
  font-family: inherit;
  line-height: 1.6;
  width: 100%;
}
.msg-textarea:focus {
  outline: none;
  border-color: #22a74d;
  box-shadow: 0 0 0 2px rgba(34, 167, 77, 0.15);
}
.msg-char-count {
  text-align: right;
  font-size: 12px;
  color: #999;
}
.msg-form-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}
.msg-submit-btn {
  min-width: 120px;
}
.msg-reset-btn {
  padding: 8px 16px;
  font-size: 13px;
}

.msg-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}
.msg-list-header h3 {
  margin-bottom: 0;
}
.msg-total {
  font-size: 13px;
  color: #888;
}
.msg-loading {
  text-align: center;
  padding: 40px 0;
  color: #166534;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.msg-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.msg-item {
  background: #f7fbf8;
  border: 1px solid #d1e7d8;
  border-left: 4px solid #22a74d;
  border-radius: 10px;
  padding: 16px 18px;
  transition: box-shadow 0.2s ease;
}
.msg-item:hover {
  box-shadow: 0 2px 8px rgba(22, 101, 52, 0.08);
}
.msg-item-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.msg-author {
  font-weight: 600;
  color: #166534;
  font-size: 15px;
}
.msg-cat-tag {
  font-size: 11px;
  padding: 2px 10px;
  border-radius: 10px;
  font-weight: 500;
  white-space: nowrap;
}
.msg-cat-tag.cat-suggest {
  background: #dbeafe;
  color: #1e40af;
}
.msg-cat-tag.cat-bug {
  background: #fee2e2;
  color: #b91c1c;
}
.msg-cat-tag.cat-feature {
  background: #f3e8ff;
  color: #6b21a8;
}
.msg-cat-tag.cat-other {
  background: #f3f4f6;
  color: #4b5563;
}
.msg-time {
  font-size: 12px;
  color: #aaa;
  margin-left: auto;
}
.msg-content {
  color: #333;
  font-size: 14px;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}
.msg-item-footer {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.like-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #fff;
  border: 1px solid #d1e7d8;
  border-radius: 20px;
  padding: 4px 12px;
  cursor: pointer;
  font-size: 13px;
  color: #888;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.like-btn:hover:not(:disabled) {
  border-color: #ef4444;
  color: #ef4444;
  background: #fff5f5;
}
.like-btn.liked {
  color: #ef4444;
  border-color: #fca5a5;
  background: #fef2f2;
  cursor: default;
}
.like-icon {
  font-size: 13px;
  line-height: 1;
}
.like-count {
  font-size: 12px;
  font-weight: 600;
  min-width: 14px;
  text-align: center;
}
.msg-reply-list {
  margin-top: 10px;
  padding: 8px 12px;
  background: #f9fafb;
  border-left: 3px solid #e5e7eb;
  border-radius: 0 6px 6px 0;
}
.msg-reply-item {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 4px 0;
  font-size: 13px;
  line-height: 1.5;
  flex-wrap: wrap;
}
.msg-reply-item + .msg-reply-item {
  border-top: 1px dashed #e5e7eb;
}
.msg-reply-author {
  color: #1e40af;
  font-weight: 600;
  white-space: nowrap;
}
.msg-reply-item .msg-reply-text {
  color: #374151;
  flex: 1;
  min-width: 0;
  word-break: break-word;
}
.msg-reply-time {
  color: #9ca3af;
  font-size: 11px;
  white-space: nowrap;
}
.msg-reply-del {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 11px;
  padding: 0 4px;
  white-space: nowrap;
}
.msg-reply-del:hover {
  text-decoration: underline;
}
.msg-reply-form {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}
.msg-reply-input {
  flex: 1;
  padding: 6px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}
.msg-reply-input:focus {
  border-color: #93c5fd;
}
.msg-reply-btn {
  background: #dbeafe;
  border-color: #93c5fd;
  color: #1e40af;
  white-space: nowrap;
}
.msg-admin-del-btn {
  background: #fef2f2;
  border-color: #fca5a5;
  color: #dc2626;
}
.msg-reply {
  margin-top: 12px;
  padding: 10px 14px;
  background: #fff;
  border: 1px dashed #86c993;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.6;
}
.msg-reply-label {
  color: #166534;
  font-weight: 600;
}
.msg-reply-text {
  color: #444;
}
.msg-reply-time {
  color: #aaa;
  font-size: 11px;
}
.msg-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-top: 20px;
}
.msg-page-btn {
  padding: 6px 16px;
}
.msg-page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.msg-page-info {
  font-size: 13px;
  color: #555;
}

.msg-admin-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.msg-admin-item {
  background: #f7fbf8;
  border: 1px solid #d1e7d8;
  border-radius: 10px;
  padding: 14px 16px;
}
.msg-admin-item.pending {
  border-left: 4px solid #f59e0b;
}
.msg-admin-item.approved {
  border-left: 4px solid #22a74d;
}
.msg-admin-item.rejected {
  border-left: 4px solid #dc2626;
}
.msg-admin-top {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.msg-admin-status {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 500;
}
.msg-admin-status.st-0 {
  background: #fef3c7;
  color: #92400e;
}
.msg-admin-status.st-1 {
  background: #dcfce7;
  color: #166534;
}
.msg-admin-status.st-2 {
  background: #fee2e2;
  color: #b91c1c;
}
.msg-admin-contact {
  font-size: 12px;
  color: #888;
}
.msg-admin-likes {
  font-size: 12px;
  color: #ef4444;
  font-weight: 500;
}
.msg-admin-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.msg-admin-reply-input {
  flex: 1;
  min-width: 200px;
  border: 1px solid #86c993;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 13px;
  background: #fff;
  font-family: inherit;
}
.msg-admin-reply-input:focus {
  outline: none;
  border-color: #22a74d;
  box-shadow: 0 0 0 2px rgba(34, 167, 77, 0.15);
}
.msg-admin-filter {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.msg-filter-btn {
  border: 1px solid #b8e1c1;
  background: #fff;
  color: #555;
  padding: 5px 14px;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
}
.msg-filter-btn.active {
  background: #166534;
  color: #fff;
  border-color: #166534;
}
.msg-pending-count {
  display: inline-block;
  background: #f59e0b;
  color: #fff;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 8px;
  margin-left: 4px;
}

@media(max-width:640px){
  .msg-form-row {
    flex-direction: column;
  }
  .msg-form-field {
    min-width: auto;
  }
  .msg-textarea {
    font-size: 16px;
  }
  .msg-item {
    padding: 14px;
  }
  .msg-time {
    margin-left: 0;
    width: 100%;
  }
  .msg-admin-reply-input {
    min-width: auto;
  }
}

/* ---------- 数据体检报告 ---------- */
.diag-box {
  margin: 0;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.9;
  color: #444;
  white-space: pre-wrap;
  word-break: break-all;
  font-family: ui-monospace, Menlo, Consolas, "Courier New", monospace;
}

/* ---------- 上传文件管理 ---------- */
.head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.file-clear {
  background: #fee2e2 !important;
  border-color: #fca5a5 !important;
  color: #b91c1c !important;
}
.file-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 10px;
}
.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(0, 0, 0, 0.07);
  border-radius: 10px;
}
.file-main {
  min-width: 0;
  flex: 1;
}
.file-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}
.file-name {
  font-size: 14px;
  color: #222;
  font-weight: 600;
  word-break: break-all;
}
.file-tag {
  flex-shrink: 0;
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid transparent;
}
.file-tag-ok {
  background: #dcfce7;
  color: #15803d;
  border-color: #86efac;
}
.file-tag-error {
  background: #fee2e2;
  color: #b91c1c;
  border-color: #fca5a5;
}
.file-tag-unknown {
  background: #f3f4f6;
  color: #6b7280;
  border-color: #e5e7eb;
}
.file-tag-tbl {
  background: #dbeafe;
  color: #1e40af;
  border-color: #93c5fd;
}
.file-sub {
  margin-top: 4px;
  font-size: 12px;
  color: #888;
  word-break: break-all;
}
.file-msg {
  color: #999;
}
.file-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}
.file-del {
  background: #fee2e2 !important;
  border-color: #fca5a5 !important;
  color: #b91c1c !important;
}
@media (max-width: 600px) {
  .file-item {
    flex-direction: column;
    align-items: stretch;
  }
  .file-actions {
    justify-content: flex-end;
  }
}
