/* ===== 全局变量 ===== */
:root {
  --primary: #3b5bdb;
  --primary-dark: #364fc7;
  --primary-light: #edf2ff;
  --success: #2f9e44;
  --success-light: #ebfbee;
  --warning: #f08c00;
  --warning-light: #fff9db;
  --danger: #e03131;
  --danger-light: #fff5f5;
  --info: #1971c2;
  --info-light: #e7f5ff;
  --gray-50: #f8f9fa;
  --gray-100: #f1f3f5;
  --gray-200: #e9ecef;
  --gray-300: #dee2e6;
  --gray-400: #ced4da;
  --gray-500: #adb5bd;
  --gray-600: #868e96;
  --gray-700: #495057;
  --gray-800: #343a40;
  --gray-900: #212529;
  --sidebar-w: 240px;
  --radius: 8px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.08);
  --shadow: 0 2px 8px rgba(0,0,0,.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,.12);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body {
  font-family: var(--font);
  background: var(--gray-100);
  color: var(--gray-900);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 14px; }
ul { list-style: none; }

/* ===== 布局 ===== */
.app { display: flex; min-height: 100vh; }

/* 侧边栏 */
.sidebar {
  width: var(--sidebar-w);
  background: var(--gray-900);
  color: var(--gray-300);
  position: fixed;
  top: 0; left: 0; bottom: 0;
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform .3s;
}
.sidebar-brand {
  padding: 20px 20px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.sidebar-brand .logo {
  width: 36px; height: 36px;
  background: var(--primary);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: #fff;
}
.sidebar-brand h1 { font-size: 16px; color: #fff; font-weight: 700; }
.sidebar-brand span { font-size: 11px; color: var(--gray-500); }

.nav { flex: 1; padding: 12px 0; overflow-y: auto; }
.nav-section { margin-bottom: 8px; }
.nav-section-title {
  padding: 8px 20px;
  font-size: 11px;
  color: var(--gray-600);
  text-transform: uppercase;
  letter-spacing: .5px;
}
.nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 20px;
  color: var(--gray-400);
  cursor: pointer;
  transition: all .15s;
  font-size: 14px;
  border-left: 3px solid transparent;
}
.nav-item:hover { background: rgba(255,255,255,.05); color: #fff; }
.nav-item.active {
  background: rgba(59,91,219,.15);
  color: #fff;
  border-left-color: var(--primary);
}
.nav-item .icon { font-size: 18px; width: 22px; text-align: center; }

.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid rgba(255,255,255,.08);
  font-size: 12px;
  color: var(--gray-600);
}

/* 主内容区 */
.main {
  flex: 1;
  margin-left: var(--sidebar-w);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* 顶栏 */
.topbar {
  background: #fff;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  position: sticky; top: 0; z-index: 50;
}
.topbar-title { font-size: 18px; font-weight: 700; }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.topbar-user {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 12px;
  background: var(--gray-100);
  border-radius: 20px;
  font-size: 13px;
}
.topbar-user .avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary);
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600;
}

/* 内容区域 */
.content { padding: 24px; flex: 1; }

/* ===== 卡片 ===== */
.card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card-header h3 { font-size: 16px; font-weight: 600; }
.card-body { padding: 20px; }

/* ===== 统计卡片 ===== */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.stat-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform .2s, box-shadow .2s;
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.stat-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}
.stat-icon.blue { background: var(--info-light); color: var(--info); }
.stat-icon.green { background: var(--success-light); color: var(--success); }
.stat-icon.orange { background: var(--warning-light); color: var(--warning); }
.stat-icon.red { background: var(--danger-light); color: var(--danger); }
.stat-icon.purple { background: #f3f0ff; color: #7950f2; }
.stat-info .label { font-size: 13px; color: var(--gray-600); margin-bottom: 4px; }
.stat-info .value { font-size: 26px; font-weight: 700; color: var(--gray-900); }
.stat-info .delta { font-size: 12px; margin-top: 2px; }

/* ===== 按钮 ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  transition: all .15s;
  white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { filter: brightness(.92); }
.btn-warning { background: var(--warning); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { filter: brightness(.92); }
.btn-outline { border: 1px solid var(--gray-300); color: var(--gray-700); background: #fff; }
.btn-outline:hover { background: var(--gray-100); }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-block { width: 100%; justify-content: center; }

/* ===== 表格 ===== */
.table-wrap { overflow-x: auto; }
table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.data-table thead th {
  text-align: left;
  padding: 12px 16px;
  background: var(--gray-50);
  color: var(--gray-600);
  font-weight: 600;
  font-size: 13px;
  border-bottom: 2px solid var(--gray-200);
  white-space: nowrap;
}
.data-table tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-100);
  color: var(--gray-800);
}
.data-table tbody tr:hover { background: var(--gray-50); }
.data-table .actions { display: flex; gap: 8px; }

/* ===== 标签/徽章 ===== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
}
.badge-success { background: var(--success-light); color: var(--success); }
.badge-warning { background: var(--warning-light); color: var(--warning); }
.badge-danger { background: var(--danger-light); color: var(--danger); }
.badge-info { background: var(--info-light); color: var(--info); }
.badge-gray { background: var(--gray-100); color: var(--gray-600); }

/* ===== 搜索栏 ===== */
.toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.search-box {
  position: relative;
  flex: 1;
  max-width: 320px;
}
.search-box input {
  width: 100%;
  padding: 8px 12px 8px 36px;
  border: 1px solid var(--gray-300);
  border-radius: 6px;
  background: #fff;
  outline: none;
  transition: border-color .15s;
}
.search-box input:focus { border-color: var(--primary); }
.search-box .search-icon {
  position: absolute;
  left: 10px; top: 50%;
  transform: translateY(-50%);
  color: var(--gray-500);
  font-size: 16px;
}
.select-input {
  padding: 8px 12px;
  border: 1px solid var(--gray-300);
  border-radius: 6px;
  background: #fff;
  outline: none;
  cursor: pointer;
}
.toolbar-right { margin-left: auto; display: flex; gap: 8px; }

/* ===== 模态框 ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
  animation: fadeIn .15s;
}
@keyframes fadeIn { from { opacity: 0; } }
.modal {
  background: #fff;
  border-radius: 12px;
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  animation: slideUp .2s;
}
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } }
.modal-lg { max-width: 800px; }
.modal-header {
  padding: 16px 24px;
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-header h3 { font-size: 17px; font-weight: 600; }
.modal-close {
  width: 32px; height: 32px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  color: var(--gray-500);
  font-size: 20px;
}
.modal-close:hover { background: var(--gray-100); }
.modal-body { padding: 24px; overflow-y: auto; }
.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--gray-200);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ===== 表单 ===== */
.form-group { margin-bottom: 18px; }
.form-row { display: flex; gap: 16px; }
.form-row .form-group { flex: 1; }
.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 6px;
}
.form-label .req { color: var(--danger); }
.form-control {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--gray-300);
  border-radius: 6px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  background: #fff;
}
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}
textarea.form-control { resize: vertical; min-height: 80px; }
.form-hint { font-size: 12px; color: var(--gray-500); margin-top: 4px; }
.form-error { font-size: 12px; color: var(--danger); margin-top: 4px; }

/* ===== 图表容器 ===== */
.chart-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
.chart-container { position: relative; height: 300px; }
.chart-container-sm { position: relative; height: 260px; }

/* ===== 空状态 ===== */
.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--gray-500);
}
.empty-state .icon { font-size: 48px; margin-bottom: 12px; }
.empty-state p { font-size: 14px; }

/* ===== Toast 提示 ===== */
.toast-container {
  position: fixed;
  top: 20px; right: 20px;
  z-index: 300;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  background: #fff;
  border-radius: 8px;
  padding: 12px 20px;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  min-width: 280px;
  animation: slideInRight .2s;
  border-left: 4px solid var(--primary);
}
@keyframes slideInRight { from { transform: translateX(100%); opacity: 0; } }
.toast.success { border-left-color: var(--success); }
.toast.error { border-left-color: var(--danger); }
.toast.warning { border-left-color: var(--warning); }
.toast .toast-icon { font-size: 18px; }

/* ===== 分页 ===== */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 16px;
}
.pagination button {
  padding: 6px 12px;
  border: 1px solid var(--gray-300);
  border-radius: 6px;
  background: #fff;
  color: var(--gray-700);
  font-size: 13px;
}
.pagination button:hover:not(:disabled) { background: var(--primary-light); border-color: var(--primary); }
.pagination button.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination button:disabled { opacity: .4; cursor: not-allowed; }

/* ===== 页面切换 ===== */
.page { display: none; }
.page.active { display: block; animation: fadeIn .2s; }

/* ===== 移动端菜单按钮 ===== */
.menu-toggle {
  display: none;
  font-size: 22px;
  color: var(--gray-700);
  padding: 4px;
}

/* ===== 响应式 ===== */
@media (max-width: 992px) {
  .chart-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .main { margin-left: 0; }
  .menu-toggle { display: block; }
  .content { padding: 16px; }
  .form-row { flex-direction: column; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat-info .value { font-size: 20px; }
}
@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr; }
  .topbar-actions .topbar-user span { display: none; }
}

/* ===== 批次看板卡片 ===== */
.batch-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}
.batch-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 18px;
  border-left: 4px solid var(--gray-300);
  cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}
.batch-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.batch-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}
.batch-cat { font-size: 12px; color: var(--gray-500); margin-bottom: 4px; }
.batch-name { font-size: 15px; font-weight: 600; color: var(--gray-900); margin-bottom: 2px; }
.batch-no { font-size: 12px; color: var(--gray-400); }
.batch-qty {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 12px;
}
.batch-remaining { font-size: 32px; font-weight: 700; line-height: 1; }
.batch-unit { font-size: 15px; color: var(--gray-600); font-weight: 500; }
.batch-initial { font-size: 13px; color: var(--gray-400); margin-left: auto; }
.batch-bar-wrap {
  width: 100%;
  height: 6px;
  background: var(--gray-100);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 12px;
}
.batch-bar { height: 100%; border-radius: 3px; transition: width .3s; }
.batch-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
}

/* ===== 品类卡片 ===== */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.cat-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.cat-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  background: var(--gray-50);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}
.cat-info { flex: 1; }
.cat-name { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.cat-meta { font-size: 13px; color: var(--gray-500); }
.cat-actions { display: flex; gap: 8px; }

/* ===== 图标选择器 ===== */
.icon-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.icon-option {
  width: 40px; height: 40px;
  border-radius: 8px;
  border: 2px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
  transition: all .15s;
}
.icon-option:hover { border-color: var(--primary); background: var(--primary-light); }
.icon-option.selected { border-color: var(--primary); background: var(--primary-light); transform: scale(1.05); }

@media (max-width: 768px) {
  .batch-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: 1fr; }
}

/* ===== 仪表盘：图表+预警并排布局 ===== */
.dash-row {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 16px;
  margin-bottom: 16px;
}
@media (max-width: 992px) {
  .dash-row { grid-template-columns: 1fr; }
}

/* ===== 柱状图（CSS 实现） ===== */
.bar-chart { display: flex; flex-direction: column; gap: 14px; }
.bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.bar-label {
  width: 100px;
  font-size: 13px;
  font-weight: 500;
  color: var(--gray-700);
  flex-shrink: 0;
  white-space: nowrap;
}
.bar-track {
  flex: 1;
  height: 28px;
  background: var(--gray-100);
  border-radius: 6px;
  overflow: hidden;
  position: relative;
}
.bar-fill {
  height: 100%;
  border-radius: 6px;
  transition: width .4s ease;
  min-width: 2px;
}
.bar-value {
  width: 60px;
  text-align: right;
  font-size: 14px;
  font-weight: 600;
  color: var(--gray-800);
  flex-shrink: 0;
}

/* ===== 预警标签区 ===== */
.alert-section { }
.alert-title {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}
.alert-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.alert-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: transform .15s, filter .15s;
}
.alert-tag:hover { transform: translateY(-1px); filter: brightness(.95); }
.alert-tag.warning { background: var(--warning-light); color: var(--warning); }
.alert-tag.danger { background: var(--danger-light); color: var(--danger); }

/* ===== 品类胶囊（库存管理顶部） ===== */
.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid var(--gray-200);
  border-radius: 16px;
  font-size: 13px;
  color: var(--gray-600);
  background: #fff;
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
}
.cat-pill:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}
.cat-pill strong {
  color: var(--gray-700);
  font-weight: 600;
  margin: 0 2px;
}

/* ===== 品类管理弹窗列表 ===== */
.cat-manage-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 60vh;
  overflow-y: auto;
}
.cat-manage-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  transition: all 0.15s;
}
.cat-manage-item:hover {
  background: #fff;
  border-color: var(--primary);
  box-shadow: 0 2px 8px rgba(59,91,219,0.06);
}
.cat-manage-icon {
  flex-shrink: 0;
  width: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cat-manage-info {
  flex: 1;
  min-width: 0;
}
.cat-manage-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 4px;
}
.cat-manage-meta {
  font-size: 12px;
  color: var(--gray-500);
}
.cat-manage-meta strong {
  color: var(--gray-700);
  font-weight: 600;
  margin: 0 2px;
}
.cat-manage-actions {
  flex-shrink: 0;
  display: flex;
  gap: 6px;
}

/* ===== 树形视图 ===== */
.tree-view { }
.tree-node { margin-bottom: 4px; }
.tree-node.collapsed .tree-children { display: none; }

.tree-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--gray-50);
  border-radius: 6px;
  cursor: pointer;
  transition: background .15s;
  user-select: none;
}
.tree-header:hover { background: var(--gray-100); }
.tree-toggle {
  width: 18px;
  font-size: 12px;
  color: var(--gray-500);
  text-align: center;
  flex-shrink: 0;
}
.tree-cat-icon { font-size: 18px; }
.tree-cat-name { font-size: 15px; font-weight: 600; color: var(--gray-800); }
.tree-cat-meta {
  font-size: 13px;
  color: var(--gray-500);
  margin-left: auto;
}

.tree-children {
  margin-left: 26px;
  border-left: 2px solid var(--gray-200);
  padding-left: 0;
}

.tree-batch {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--gray-100);
  cursor: pointer;
  transition: background .12s;
}
.tree-batch:hover { background: var(--gray-50); }
.tree-batch:last-child { border-bottom: none; }

.tree-batch-main {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 160px;
}
.tree-batch-name { font-size: 13px; font-weight: 500; color: var(--gray-800); }
.tree-batch-no { font-size: 11px; color: var(--gray-400); }

.tree-batch-qty {
  display: flex;
  align-items: baseline;
  gap: 4px;
  min-width: 90px;
}
.tree-batch-remaining { font-size: 18px; font-weight: 700; }
.tree-batch-unit { font-size: 12px; color: var(--gray-600); }
.tree-batch-initial { font-size: 11px; color: var(--gray-400); }

.tree-batch-bar { flex: 1; }

@media (max-width: 768px) {
  .tree-batch { flex-wrap: wrap; }
  .tree-batch-bar { width: 100%; order: 5; }
  .tree-cat-meta { display: none; }
}

/* ===== 自定义日期输入（彻底遮盖浏览器原生 placeholder，避免重影） ===== */
.date-field { position: relative; display: inline-block; }
.date-field input[type="date"] { color: var(--gray-800); caret-color: transparent; }
/* 未填值时，把浏览器原生日历的内嵌编辑段全部透明（包括年、月、日文本和字段容器）。聚焦/有值时再恢复可见，这样日历图标仍然可以点击 */
.date-field:not(.has-value) input[type="date"]::-webkit-datetime-edit,
.date-field:not(.has-value) input[type="date"]::-webkit-datetime-edit-fields-wrapper,
.date-field:not(.has-value) input[type="date"]::-webkit-datetime-edit-text,
.date-field:not(.has-value) input[type="date"]::-webkit-datetime-edit-month-field,
.date-field:not(.has-value) input[type="date"]::-webkit-datetime-edit-day-field,
.date-field:not(.has-value) input[type="date"]::-webkit-datetime-edit-year-field {
  color: transparent;
}
.date-field.has-value input[type="date"],
.date-field input[type="date"]:focus { caret-color: var(--gray-800); }
.date-field input[type="date"]::-moz-placeholder { color: transparent; }
.date-hint {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-400);
  font-size: 13px;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, "Courier New", monospace;
  letter-spacing: 0.3px;
  pointer-events: none;
  user-select: none;
  z-index: 2;
}
.date-field.has-value .date-hint { display: none; }

/* ===== 密码输入框 + 小眼睛切换 ===== */
.password-wrap { position: relative; }
.password-wrap .form-control { padding-right: 42px; }
.toggle-pwd {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-500);
  cursor: pointer;
  border-radius: 4px;
  padding: 0;
}
.toggle-pwd:hover { background: var(--gray-100); color: var(--gray-700); }
.toggle-pwd:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
.toggle-pwd svg { width: 18px; height: 18px; }

