/* chaxun.yzgz.cn - 样式 v1
   风格: 高级感 · 简约 · 留白 · 微动效
   调色: 暖白底 + 墨色文字 + 印章橘红
   字体: Inter + 系统字 + 苹方/雅黑
*/

:root {
  /* 基础色 */
  --bg: #fafaf7;
  --bg-soft: #f4f3ef;
  --surface: #ffffff;
  --surface-hover: #fbfaf7;

  /* 文字 */
  --ink: #1a1a1a;
  --ink-2: #4a4a48;
  --ink-3: #8a8a86;
  --ink-4: #b8b8b3;

  /* 线条 */
  --line: #ece9e2;
  --line-strong: #d8d4ca;

  /* 强调 - 印章橘红 */
  --accent: #c2410c;
  --accent-soft: #fff5ed;
  --accent-strong: #9a3412;

  /* 分类色 */
  --cat-gov: #1e3a8a;
  --cat-gov-bg: #eff3fb;
  --cat-transport: #065f46;
  --cat-transport-bg: #ecf6f1;
  --cat-life: #92400e;
  --cat-life-bg: #fbf2e6;
  --cat-business: #9f1239;
  --cat-business-bg: #fbeaef;

  /* 阴影 */
  --shadow-xs: 0 1px 2px rgba(28, 25, 23, 0.04);
  --shadow-sm: 0 1px 2px rgba(28, 25, 23, 0.04), 0 1px 3px rgba(28, 25, 23, 0.05);
  --shadow-md: 0 4px 8px -2px rgba(28, 25, 23, 0.06), 0 2px 4px -2px rgba(28, 25, 23, 0.04);
  --shadow-lg: 0 12px 32px -8px rgba(28, 25, 23, 0.12), 0 4px 12px -4px rgba(28, 25, 23, 0.06);

  /* 圆角 */
  --r-sm: 6px;
  --r: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;

  /* 字体 */
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', '微软雅黑', sans-serif;
  --font-serif: 'Source Serif Pro', 'Noto Serif SC', 'Songti SC', 'SimSun', serif;
}

/* ===== 暗色模式 ===== */
[data-theme="dark"] {
  --bg: #0c0c0d;
  --bg-soft: #161618;
  --surface: #1a1a1c;
  --surface-hover: #202022;

  --ink: #f5f5f4;
  --ink-2: #c8c8c4;
  --ink-3: #888884;
  --ink-4: #5a5a58;

  --line: #2a2a2c;
  --line-strong: #3a3a3c;

  --accent: #fb923c;
  --accent-soft: #2a1810;
  --accent-strong: #fdba74;

  --cat-gov: #93c5fd;
  --cat-gov-bg: #1e293b;
  --cat-transport: #6ee7b7;
  --cat-transport-bg: #064e3b;
  --cat-life: #fcd34d;
  --cat-life-bg: #422006;
  --cat-business: #fda4af;
  --cat-business-bg: #4c0519;

  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3), 0 1px 3px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 8px -2px rgba(0, 0, 0, 0.4), 0 2px 4px -2px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 12px 32px -8px rgba(0, 0, 0, 0.5), 0 4px 12px -4px rgba(0, 0, 0, 0.3);
}

/* 跟随系统: 仅在用户未显式设置时 */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --bg: #0c0c0d;
    --bg-soft: #161618;
    --surface: #1a1a1c;
    --surface-hover: #202022;

    --ink: #f5f5f4;
    --ink-2: #c8c8c4;
    --ink-3: #888884;
    --ink-4: #5a5a58;

    --line: #2a2a2c;
    --line-strong: #3a3a3c;

    --accent: #fb923c;
    --accent-soft: #2a1810;
    --accent-strong: #fdba74;

    --cat-gov: #93c5fd;
    --cat-gov-bg: #1e293b;
    --cat-transport: #6ee7b7;
    --cat-transport-bg: #064e3b;
    --cat-life: #fcd34d;
    --cat-life-bg: #422006;
    --cat-business: #fda4af;
    --cat-business-bg: #4c0519;
  }
}

/* 主题切换按钮 */
.theme-toggle {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: grid; place-items: center;
  color: var(--ink-2);
  transition: all 0.15s;
  position: relative;
}
.theme-toggle:hover {
  background: var(--bg-soft);
  color: var(--ink);
}
.theme-toggle svg { width: 16px; height: 16px; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* 主题切换的平滑过渡 (仅切时) */
.theme-transitioning, .theme-transitioning *,
.theme-transitioning *::before, .theme-transitioning *::after {
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease, fill 0.3s ease !important;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  font-family: var(--font);
  font-feature-settings: 'cv11', 'ss01', 'ss03';
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  font-size: 15px;
  letter-spacing: -0.005em;
}

body {
  min-height: 100vh;
  background-image:
    radial-gradient(800px circle at 100% 0%, rgba(194, 65, 12, 0.025), transparent 40%),
    radial-gradient(600px circle at 0% 100%, rgba(30, 58, 138, 0.02), transparent 40%);
}
[data-theme="dark"] body {
  background-image:
    radial-gradient(800px circle at 100% 0%, rgba(251, 146, 60, 0.06), transparent 40%),
    radial-gradient(600px circle at 0% 100%, rgba(147, 197, 253, 0.04), transparent 40%);
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, textarea, select { font-family: inherit; font-size: inherit; }

/* 容器 */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ========== 顶栏 ========== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 247, 0.75);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line);
}
[data-theme="dark"] .nav {
  background: rgba(12, 12, 13, 0.75);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
}
.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--accent);
  color: white;
  display: grid;
  place-items: center;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.brand small {
  color: var(--ink-3);
  font-weight: 400;
  margin-left: 4px;
  font-size: 12px;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-link {
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 13px;
  color: var(--ink-2);
  transition: all 0.15s;
}
.nav-link:hover {
  color: var(--ink);
  background: var(--bg-soft);
}
.nav-link.admin {
  color: var(--ink-3);
  font-size: 12px;
}

/* ========== 搜索条 (hero 删了, 搜下放独立条) ========== */
.search-bar {
  padding: 20px 0 0;
}
.search-bar .container {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.search-bar .search-box {
  flex: 1;
  min-width: 0;
  max-width: 520px;
  margin: 0;
  position: relative;
}
.search-bar .stats-line {
  margin-top: 0;
  flex-shrink: 0;
}

/* 搜索框 */
.search-box {
  max-width: 520px;
  margin: 0 auto;
  position: relative;
}
.search-box svg {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-3);
  pointer-events: none;
}
.search-input {
  width: 100%;
  padding: 14px 16px 14px 44px;
  font-size: 15px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  outline: none;
  transition: all 0.2s;
  box-shadow: var(--shadow-xs);
}
.search-input:focus {
  border-color: var(--ink-3);
  box-shadow: var(--shadow-md), 0 0 0 3px rgba(194, 65, 12, 0.08);
}
.search-input::placeholder { color: var(--ink-4); }

.stats-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-3);
}
.stats-line .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #16a34a;
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.12);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* ========== 分类区 ========== */
.section {
  margin-bottom: 56px;
}
.section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}
.section-title {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title .icon {
  width: 28px; height: 28px;
  border-radius: 8px;
  display: grid; place-items: center;
  font-size: 14px;
}
.section-meta {
  font-size: 13px;
  color: var(--ink-3);
  margin-left: auto;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}

/* 卡片 */
.card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-xs);
  overflow: hidden;
}
.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 60%, rgba(194, 65, 12, 0.02));
  opacity: 0;
  transition: opacity 0.18s;
  pointer-events: none;
}
.card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}
.card:hover::before { opacity: 1; }

.card-icon {
  flex-shrink: 0;
  width: 44px; height: 44px;
  border-radius: var(--r);
  display: grid; place-items: center;
  font-size: 22px;
  background: var(--bg-soft);
  transition: transform 0.18s;
}
.card:hover .card-icon {
  transform: scale(1.05);
}
.card-body { flex: 1; min-width: 0; }
.card-title {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.card-desc {
  font-size: 13px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.card-arrow {
  flex-shrink: 0;
  color: var(--ink-4);
  opacity: 0;
  transform: translateX(-4px);
  transition: all 0.18s;
}
.card:hover .card-arrow {
  opacity: 1;
  transform: translateX(0);
  color: var(--accent);
}

/* 标签 */
.tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 500;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--bg-soft);
  color: var(--ink-3);
  letter-spacing: 0.02em;
  vertical-align: middle;
  margin-left: 4px;
}
.tag.mini {
  background: rgba(22, 163, 74, 0.08);
  color: #15803d;
}

/* 分类主题 */
.cat-gov .card-icon { background: var(--cat-gov-bg); }
.cat-transport .card-icon { background: var(--cat-transport-bg); }
.cat-life .card-icon { background: var(--cat-life-bg); }
.cat-business .card-icon { background: var(--cat-business-bg); }

.cat-gov .section-title .icon { background: var(--cat-gov-bg); color: var(--cat-gov); }
.cat-transport .section-title .icon { background: var(--cat-transport-bg); color: var(--cat-transport); }
.cat-life .section-title .icon { background: var(--cat-life-bg); color: var(--cat-life); }
.cat-business .section-title .icon { background: var(--cat-business-bg); color: var(--cat-business); }

/* 隐藏的卡片 (搜索过滤) */
.card.hidden { display: none; }
.section.hidden { display: none; }

/* 空状态 */
.empty {
  text-align: center;
  padding: 80px 20px;
  color: var(--ink-3);
}
.empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.4;
}

/* ========== Footer ========== */
.footer {
  margin-top: 80px;
  padding: 40px 0;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 13px;
  color: var(--ink-3);
}
.footer a { color: var(--ink-2); }
.footer a:hover { color: var(--accent); }

/* ========== 响应式 ========== */
/* ---- 平板横竖 (≤1024px) ---- */
@media (max-width: 1024px) {
  .container { padding: 0 22px; }
  .search-bar .container { gap: 12px; }
  .admin-wrap { padding: 28px 20px 60px; }
  .table-row { grid-template-columns: 36px 2fr 2.5fr 1fr 90px; gap: 10px; padding: 12px 14px; }
  .modal { max-width: 480px; padding: 24px; }
}

/* ---- 手机大屏 / 小平板 (≤768px) ---- */
@media (max-width: 768px) {
  html { font-size: 15px; }
  body { font-size: 14.5px; }
  .container { padding: 0 18px; }

  /* nav: 横排可滚动, 不换行 */
  .nav-inner { padding: 12px 0; gap: 10px; }
  .brand { font-size: 14px; gap: 8px; min-width: 0; }
  .brand small { display: none; }  /* 隐藏 "yzgz 查询" 小字 */
  .nav-links {
    flex: 1;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;  /* Firefox */
    -ms-overflow-style: none;  /* IE */
    white-space: nowrap;
    padding: 2px 0;
    margin: 0 -4px;
  }
  .nav-links::-webkit-scrollbar { display: none; }
  .nav-link {
    padding: 8px 12px;
    min-height: 44px;  /* iOS 触摸目标 */
    display: inline-flex;
    align-items: center;
    font-size: 13.5px;
  }
  .nav-link.admin { display: none; }

  /* 搜索条: 搜索 input 占满, 状态行换到下一行 */
  .search-bar { padding: 14px 0 0; }
  .search-bar .container { flex-direction: column; align-items: stretch; gap: 10px; }
  .search-bar .search-box { max-width: none; }
  .search-bar .stats-line { font-size: 12px; }
  .search-input { font-size: 16px; padding: 12px 14px 12px 42px; min-height: 44px; }  /* 16px 防 iOS 放大 */

  /* 卡片网格: 1 列 */
  .grid { grid-template-columns: 1fr; gap: 10px; }
  .card { padding: 14px; }

  /* footer */
  .footer { padding: 32px 0 24px; font-size: 12px; }

  /* toast 防被底部 home bar 遮住 */
  .toast { bottom: max(24px, env(safe-area-inset-bottom)); }

  /* ========== 后台 (≤768px) ========== */
  .admin-wrap { padding: 20px 16px max(40px, env(safe-area-inset-bottom)); }
  .admin-header {
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 16px;
  }
  .admin-header h1 { font-size: 20px; }
  .admin-header > div:last-child { gap: 6px; }
  .admin-header .btn { padding: 7px 10px; font-size: 12px; }

  .admin-stats { gap: 6px; margin-bottom: 18px; }
  .stat-pill { padding: 10px 12px; }
  .stat-pill .v { font-size: 18px; }
  .stat-pill .k { font-size: 11px; }

  /* 工具栏: tabs 允许横滚, +新增 按钮另起一行 */
  .toolbar { flex-wrap: wrap; margin-bottom: 12px; }
  .tabs { flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab { padding: 8px 12px; font-size: 12.5px; min-height: 36px; }
  #btn-add { width: 100%; justify-content: center; padding: 10px; min-height: 44px; }

  /* 表格: 改卡片堆叠 */
  .table { background: transparent; border: none; border-radius: 0; overflow: visible; }
  .table-row {
    display: flex;
    flex-wrap: wrap;
    grid-template-columns: none;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    padding: 14px;
    margin-bottom: 10px;
    gap: 8px 12px;
  }
  .table-row.head { display: none; }  /* 隐藏表头 */
  .table-row .icon-cell { order: 1; font-size: 22px; flex: 0 0 32px; }
  .table-row .title-cell { order: 2; font-size: 15px; font-weight: 600; flex: 1; }
  .table-row .url-cell { order: 3; flex: 0 0 100%; font-size: 12px; }
  .table-row > div:nth-child(4) { order: 4; flex: 0 0 auto; }
  .table-row .act-cell { order: 5; flex: 0 0 auto; margin-left: auto; }
  .table-row .cat-cell { font-size: 11px; }

  /* 模态: 占满屏幕 */
  .modal-bg { padding: max(12px, env(safe-area-inset-top)) 12px max(12px, env(safe-area-inset-bottom)); align-items: stretch; }
  .modal { max-width: none; border-radius: var(--r-md); padding: 22px 18px; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .modal-actions { flex-direction: column-reverse; gap: 6px; }
  .modal-actions .btn { width: 100%; justify-content: center; min-height: 44px; }

  /* 登录 */
  .login-bg { padding: max(20px, env(safe-area-inset-top)) 16px max(20px, env(safe-area-inset-bottom)); }
  .login-card { padding: 32px 22px; }
  .login-card .field input { font-size: 16px; min-height: 44px; }  /* 防 iOS 放大 */
}

/* ---- 小手机 (≤480px) ---- */
@media (max-width: 480px) {
  .container { padding: 0 14px; }
  .brand-mark { width: 24px; height: 24px; font-size: 12px; border-radius: 6px; }
  .nav-link { padding: 7px 10px; font-size: 13px; }
  .search-bar { padding: 10px 0 0; }
  .card { padding: 12px; gap: 12px; }
  .card .icon-cell { font-size: 22px; }
  .table-row { padding: 12px; }
}

/* iOS safe-area 全局支持 */
body { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
.nav { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }

/* ========== 后台页面 ========== */
.admin-wrap {
  max-width: 960px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}
.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}
.admin-header h1 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.admin-stats {
  display: flex;
  gap: 8px;
  margin-bottom: 28px;
}
.stat-pill {
  flex: 1;
  padding: 14px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-pill .v {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.stat-pill .k {
  font-size: 12px;
  color: var(--ink-3);
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--r);
  font-size: 13px;
  font-weight: 500;
  transition: all 0.15s;
  border: 1px solid transparent;
}
.btn-primary {
  background: var(--ink);
  color: white;
}
.btn-primary:hover { background: #000; }
.btn-ghost {
  background: var(--surface);
  color: var(--ink-2);
  border-color: var(--line);
}
.btn-ghost:hover {
  border-color: var(--line-strong);
  color: var(--ink);
}
.btn-danger {
  background: transparent;
  color: #b91c1c;
  border-color: transparent;
}
.btn-danger:hover {
  background: #fef2f2;
}
.btn-sm { padding: 5px 10px; font-size: 12px; }

.tabs {
  display: inline-flex;
  background: var(--bg-soft);
  border-radius: var(--r);
  padding: 3px;
  gap: 2px;
}
.tab {
  padding: 6px 14px;
  border-radius: 7px;
  font-size: 13px;
  color: var(--ink-2);
  font-weight: 500;
  transition: all 0.15s;
}
.tab.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-xs);
}

.table {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
}
.table-row {
  display: grid;
  grid-template-columns: 40px 2fr 3fr 1fr 100px;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
  transition: background 0.12s;
}
.table-row:last-child { border-bottom: none; }
.table-row.head {
  background: var(--bg-soft);
  font-size: 11px;
  font-weight: 500;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding-top: 10px;
  padding-bottom: 10px;
}
.table-row:hover:not(.head) {
  background: var(--surface-hover);
}
.table-row .icon-cell { font-size: 18px; text-align: center; }
.table-row .title-cell { font-weight: 500; }
.table-row .url-cell {
  color: var(--ink-3);
  font-size: 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-family: 'SF Mono', Menlo, monospace;
}
.table-row .cat-cell {
  font-size: 12px;
  padding: 3px 8px;
  background: var(--bg-soft);
  border-radius: 6px;
  color: var(--ink-2);
  display: inline-block;
}
.table-row .act-cell {
  display: flex;
  gap: 4px;
  justify-content: flex-end;
}
.inactive { opacity: 0.5; }

/* 模态框 */
.modal-bg {
  position: fixed; inset: 0;
  background: rgba(28, 25, 23, 0.4);
  backdrop-filter: blur(4px);
  z-index: 100;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 80px 20px 20px;
  overflow-y: auto;
}
.modal-bg.show { display: flex; animation: fadein 0.15s; }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--surface);
  border-radius: var(--r-lg);
  width: 100%;
  max-width: 520px;
  padding: 28px;
  box-shadow: var(--shadow-lg);
  animation: slideup 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes slideup {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.modal h2 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: -0.01em;
}
.field { margin-bottom: 14px; }
.field label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-2);
  margin-bottom: 6px;
}
.field input, .field select, .field textarea {
  width: 100%;
  padding: 9px 12px;
  font-size: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  outline: none;
  transition: all 0.15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--ink-3);
  box-shadow: 0 0 0 3px rgba(28, 25, 23, 0.05);
}
.field textarea { resize: vertical; min-height: 60px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: white;
  padding: 10px 18px;
  border-radius: var(--r);
  font-size: 13px;
  box-shadow: var(--shadow-lg);
  z-index: 200;
  opacity: 0;
  transition: all 0.2s;
  pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(-4px); }
.toast.err { background: #b91c1c; }

/* 登录 */
.login-bg {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: var(--bg);
}
.login-card {
  width: 100%;
  max-width: 380px;
  padding: 40px 32px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-md);
}
.login-card h1 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}
.login-card .sub {
  color: var(--ink-3);
  font-size: 13px;
  margin-bottom: 24px;
}
.login-card .field { margin-bottom: 12px; }
.login-card .btn { width: 100%; justify-content: center; padding: 11px; margin-top: 8px; }
