/* ============================================================



   一帧设计 · 创意工时台账 —— 全新视觉体系 V16



   设计语言：暖白极简 · 深墨文字 · 品牌蓝点缀 · 大留白 · 细腻阴影



   说明：保留登录界面 / 波点背景 / 水滴动效；重做全部业务界面



   ============================================================ */







/* ---------- 设计变量 ---------- */



:root {



  color-scheme: light;



  --ink: #1d1b1a;          /* 主文字 · 暖黑 */



  --ink-2: #6f6b66;        /* 次级文字 */



  --ink-3: #a8a49f;        /* 弱文字 */



  --bg: #f6f5f3;           /* 页面背景 · 暖灰白 */



  --bg-soft: #fbfaf8;



  --card: #ffffff;



  --line: #ece9e4;         /* 分隔线 */



  --line-2: #e0ddd7;



  --brand: #332C2B;        /* 品牌 · 暖黑灰 */



  --brand-2: #57504c;



  --brand-soft: #f1efed;



  --ok: #2e9e6c;



  --ok-soft: #e8f6ef;



  --warn: #e2703a;



  --warn-soft: #fdf0e8;



  --danger: #d44848;



  --danger-soft: #fdecec;



  --info: #1fa8b0;



  --info-soft: #e6f7f8;



  --r-lg: 16px;



  --r-md: 12px;



  --r-sm: 9px;



  --sh: 0 1px 2px rgba(35,26,20,.04), 0 6px 24px rgba(35,26,20,.05);



  --sh-lg: 0 8px 32px rgba(35,26,20,.10);



}







/* ---------- 基础 ---------- */



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



html { -webkit-text-size-adjust: 100%; }



body {



  font-family: "PingFang SC", "Microsoft YaHei", -apple-system, "Segoe UI", sans-serif;



  background: var(--bg);



  color: var(--ink);



  font-size: 14px;



  line-height: 1.6;



  min-height: 100vh;



  -webkit-font-smoothing: antialiased;



  -webkit-tap-highlight-color: transparent;



}



a { color: var(--brand); text-decoration: none; }



button { font-family: inherit; cursor: pointer; }



input, select, textarea { font-family: inherit; }







/* ---------- 页面切换（关键：默认只显示当前激活页） ---------- */



.page { display: none; }



.page.active { display: block; position: relative; }

/* 页面切换统一加载反馈（导航入口注入，数据渲染后自动消失） */
.pg-loading-mask { position: absolute; inset: 0; z-index: 60; background: rgba(255,255,255,.78); display: flex; flex-direction: column; align-items: center; justify-content: center; }
.pg-loading-spin { width: 32px; height: 32px; border: 3px solid #e8e4df; border-top-color: #1fa8b0; border-radius: 50%; animation: pgSpin .8s linear infinite; }
@keyframes pgSpin { to { transform: rotate(360deg); } }







/* ---------- 内容容器 ---------- */



.container {



  max-width: 1280px;



  margin: 0 auto;



  padding: 22px 24px 40px;



  position: relative;



  z-index: 1;



}



.page-content { position: relative; z-index: 1; }







/* ---------- 顶部导航 ---------- */



.header {



  background: rgba(255,255,255,.92);



  backdrop-filter: blur(10px);



  -webkit-backdrop-filter: blur(10px);



  border-bottom: 1px solid var(--line);



  position: sticky;



  top: 0;



  z-index: 100;



}



.header-top {



  max-width: 1280px;



  margin: 0 auto;



  display: flex;



  align-items: center;



  justify-content: space-between;



  gap: 16px;



  height: 62px;



  padding: 0 24px;



}



.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }



.brand img { width: auto; height: 40px; object-fit: contain; border-radius: 0; }



.brand .brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }



.brand h1 { font-size: 16px; font-weight: 800; letter-spacing: .5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }



.brand p { font-size: 11px; color: var(--ink-3); letter-spacing: 2px; }



.header-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }







/* 用户信息 */



.user-menu-wrap { position: relative; }



.user-info {



  display: flex; align-items: center; gap: 9px;



  padding: 6px 10px; border-radius: 12px;



  cursor: pointer; transition: background .18s;



}



.user-info:hover { background: rgba(20,20,20,.04); }



.avatar {



  width: 34px; height: 34px; border-radius: 50%;



  background: linear-gradient(135deg, var(--brand), var(--brand-2));



  color: #fff; font-size: 14px; font-weight: 700;



  display: flex; align-items: center; justify-content: center;



  box-shadow: 0 2px 8px rgba(51,44,43,.28);



}



.user-info span { font-size: 13px; font-weight: 600; color: var(--ink); max-width: 90px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }



.menu-arrow { font-size: 9px; color: var(--ink-3); }







/* 用户下拉 */



.user-dropdown {



  display: none; position: absolute; top: calc(100% + 8px); right: 0;



  background: #fff; border-radius: 14px; min-width: 188px;



  box-shadow: var(--sh-lg); border: 1px solid var(--line);



  z-index: 99999999; overflow: hidden;



}



.user-dropdown.show { display: block; animation: ddIn .16s ease; }



@keyframes ddIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }



.dropdown-item {



  display: flex; align-items: center; gap: 10px; width: 100%;



  text-align: left; padding: 12px 16px; background: none; border: none;



  font-size: 13px; color: var(--ink); transition: background .15s;



}



.dropdown-item:hover { background: var(--bg-soft); }



.dropdown-item.danger { color: var(--danger); }



.dropdown-item .sico { width: 16px; height: 16px; }







/* ---------- 标签栏（桌面：顶部横排） ---------- */



.tabs {



  display: flex; gap: 0; border-bottom: 1px solid var(--line);



  overflow-x: auto; flex-wrap: nowrap;



  -webkit-overflow-scrolling: touch; scrollbar-width: none; -ms-overflow-style: none;



  background: #fff;



  padding: 0 24px;



}



.tabs::-webkit-scrollbar { display: none; }



.tab {



  position: relative;



  padding: 14px 20px 12px;



  font-size: 14px; font-weight: 600; color: var(--ink-3);



  cursor: pointer; border: none; background: none;



  white-space: nowrap; flex-shrink: 0;



  transition: color .2s;



}



.tab::before { content: ''; display: none; }



.tab:hover { color: var(--ink); }



.tab.active { color: var(--brand); font-weight: 700; }



.tab.active::after {



  content: ''; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 3px;



  border-radius: 3px 3px 0 0; background: linear-gradient(90deg, var(--brand), var(--brand-2));



}







/* ---------- 卡片 ---------- */



.card {



  background: var(--card);



  border: 1px solid var(--line);



  border-radius: var(--r-lg);



  box-shadow: var(--sh);



  margin-bottom: 18px;



  overflow: hidden;



}



.card-title {



  display: flex; align-items: center; gap: 8px;



  font-size: 15px; font-weight: 700; color: var(--ink);



  padding: 16px 20px; border-bottom: 1px solid var(--line);



}



.card-title .sico { width: 16px; height: 16px; color: var(--brand); }



.card-body { padding: 20px; width: 100%; box-sizing: border-box; }







/* ---------- 统计大数字卡 ---------- */



.stat-cards {

  width: 100%;



  display: grid;



  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));



  gap: 14px;



  margin-bottom: 18px;



}



.stat-card {



  position: relative;



  background: var(--card);



  border: 1px solid var(--line);



  border-radius: var(--r-lg);



  padding: 18px 20px;



  box-shadow: var(--sh);



  overflow: hidden;



  transition: transform .2s, box-shadow .2s;



}



.stat-card:hover { transform: translateY(-2px); box-shadow: var(--sh-lg); }



.stat-card .k { font-size: 12px; color: var(--ink-3); font-weight: 600; letter-spacing: .5px; margin-bottom: 6px; }



.stat-card .v { font-size: 26px; font-weight: 800; color: var(--ink); line-height: 1.15; letter-spacing: -.5px; }



.stat-card .sub { font-size: 11px; color: var(--ink-3); margin-top: 4px; }



.stat-card.c1 .v { color: var(--brand); }



.stat-card.c2 .v { color: var(--info); }



.stat-card.c3 .v { color: var(--ok); }



.stat-card.c4 .v { color: #7b5cf0; }



.stat-card.c5 .v { color: var(--warn); }



.stat-card.c6 .v { color: var(--danger); }







/* ---------- 筛选栏 ---------- */



.filter-bar {



  display: flex; align-items: center; flex-wrap: wrap; gap: 10px;



  background: var(--card);



  border: 1px solid var(--line);



  border-radius: var(--r-md);



  padding: 12px 14px;



  margin-bottom: 16px;



  box-shadow: var(--sh);



}



.filter-bar .input, .filter-bar .select {



  font-size: 13px; padding: 9px 12px;



  border-radius: var(--r-sm);



  border: 1px solid var(--line-2);



  background: var(--bg-soft);



  color: var(--ink);



  min-height: 36px;



  transition: border-color .2s, box-shadow .2s;



}



.filter-bar .input:focus, .filter-bar .select:focus {



  outline: none; border-color: var(--brand);



  background: #fff; box-shadow: 0 0 0 3px rgba(51,44,43,.10);



}



.filter-bar .btn { flex-shrink: 0; }







/* ---------- 按钮 ---------- */



.btn {



  display: inline-flex; align-items: center; justify-content: center; gap: 5px;



  padding: 9px 18px;



  font-size: 13px; font-weight: 600;



  border-radius: var(--r-sm);



  border: 1px solid transparent;



  background: #f0eeea;



  color: var(--ink);



  transition: all .18s;



  white-space: nowrap;



}



.btn:hover { background: #e7e4df; }



.btn:active { transform: scale(.97); }



.btn .sico { width: 14px; height: 14px; }



.btn-primary {

  border-radius: 12px;



  background: linear-gradient(135deg, var(--brand), var(--brand-2));



  color: #fff;



  box-shadow: 0 4px 14px rgba(51,44,43,.25);



}



.btn-primary:hover { background: linear-gradient(135deg, #57504c, #332C2B); box-shadow: 0 6px 18px rgba(51,44,43,.32); }



.btn-default {



  background: #fff; color: var(--ink);



  border: 1px solid var(--line-2);



}



.btn-default:hover { background: var(--bg-soft); border-color: #d5d1cb; }



.btn-danger {



  background: linear-gradient(135deg, #d44848, #e86060); color: #fff;



  box-shadow: 0 4px 12px rgba(212,72,72,.22);



}



.btn-danger:hover { box-shadow: 0 6px 16px rgba(212,72,72,.3); }



.btn-sm { padding: 6px 12px; font-size: 12px; border-radius: 8px; }



.btn-block { width: 100%; }







/* ---------- 表单 ---------- */



.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }



.form-item { display: flex; flex-direction: column; }



.form-item.full { grid-column: 1 / -1; }



.form-item label { font-size: 12px; font-weight: 700; color: var(--ink-2); margin-bottom: 6px; letter-spacing: .3px; }



.form-item label .req { color: var(--danger); margin-left: 2px; }



.form-item .input, .form-item .select, .form-item textarea {



  font-size: 14px; padding: 11px 13px;



  border-radius: var(--r-sm);



  border: 1.5px solid var(--line-2);



  background: var(--bg-soft);



  color: var(--ink);



  transition: border-color .2s, box-shadow .2s, background .2s;



  width: 100%;



}



.form-item textarea { resize: vertical; min-height: 76px; }



.form-item .input:focus, .form-item .select:focus, .form-item textarea:focus {



  outline: none; border-color: var(--brand);



  background: #fff; box-shadow: 0 0 0 3px rgba(51,44,43,.10);



}



.form-item .input::placeholder, .form-item textarea::placeholder { color: #c4c0bb; }



.form-item .hint { font-size: 11px; color: var(--ink-3); margin-top: 4px; }



.input, .select {



  font-size: 13px; padding: 9px 12px;



  border-radius: var(--r-sm); border: 1px solid var(--line-2);



  background: var(--bg-soft); color: var(--ink);



}



.input:focus, .select:focus { outline: none; border-color: var(--brand); background: #fff; }







/* ---------- 弹层 ---------- */



.modal-mask {

  position: fixed; inset: 0; z-index: 99999 !important;

  background: rgba(20,18,16,.45);

  display: none !important; align-items: center; justify-content: center;

  padding: 20px;

  backdrop-filter: blur(3px);

}

.modal-mask.open { overflow: hidden; }



.modal-mask.open { display: flex !important; }



.modal {



  background: #fff;



  border-radius: 20px;



  width: 100%; max-width: 640px;



  max-height: 90vh;



  display: flex; flex-direction: column;



  box-shadow: var(--sh-lg);



  animation: modalIn .22s ease;



}



@keyframes modalIn { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }



.modal-head {



  display: flex; align-items: center; justify-content: space-between;



  padding: 18px 22px; border-bottom: 1px solid var(--line);



}



.modal-head h2 { font-size: 16px; font-weight: 800; }



.modal-close {



  width: 30px; height: 30px; border-radius: 50%;



  background: var(--bg-soft); border: none;



  font-size: 18px; color: var(--ink-2);



  display: flex; align-items: center; justify-content: center;



  transition: background .15s;



}



.modal-close:hover { background: #efedea; }



.modal-body { padding: 20px 22px; overflow-y: auto; }



.modal-foot {



  display: flex; justify-content: flex-end; gap: 10px;



  padding: 14px 22px; border-top: 1px solid var(--line);



}



.modal-foot .btn { min-width: 96px; }







/* ---------- 表格 ---------- */



.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }



table { width: 100%; border-collapse: collapse; font-size: 13px; }



thead th {



  background: var(--bg-soft);



  color: var(--ink-2);



  font-weight: 700;



  font-size: 12px;



  text-align: left;



  padding: 12px 14px;



  white-space: nowrap;



  border-bottom: 1px solid var(--line);



  letter-spacing: .3px;



}



tbody td {



  padding: 12px 14px;



  border-bottom: 1px solid #f2f0ec;



  vertical-align: middle;



  color: var(--ink);



}



tbody tr { transition: background .15s; }



tbody tr:hover { background: #faf9f7; }



tbody tr:last-child td { border-bottom: none; }



td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }



td .tag { margin-right: 4px; }







/* 状态标签 */



.tag {



  display: inline-block; padding: 3px 10px;



  font-size: 11px; font-weight: 600;



  border-radius: 20px; letter-spacing: .3px;



}



.tag-blue { background: var(--brand-soft); color: var(--brand); }



.tag-teal { background: var(--info-soft); color: var(--info); }



.tag-green { background: var(--ok-soft); color: var(--ok); }



.tag-orange { background: var(--warn-soft); color: var(--warn); }



.tag-red { background: var(--danger-soft); color: var(--danger); }



.tag-gray { background: #f0eeea; color: var(--ink-2); }







/* ---------- 空状态 ---------- */



.empty {



  padding: 64px 24px; text-align: center;



  background: var(--card);



  border: 1px dashed var(--line-2);



  border-radius: var(--r-lg);



}



.empty h3 { font-size: 16px; font-weight: 700; color: var(--ink); margin-bottom: 8px; }



.empty p { font-size: 13px; color: var(--ink-3); margin-bottom: 18px; }



.empty .btn { margin: 0 auto; }



.empty-state { padding: 40px 20px; text-align: center; }



.empty-state .es-icon { margin-bottom: 12px; color: var(--ink-3); }



.empty-state .es-icon .sico { width: 44px; height: 44px; stroke-width: 1.2; }







/* ---------- 图表容器 ---------- */



.chart-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 18px; }



.chart-box {



  background: var(--card); border: 1px solid var(--line);



  border-radius: var(--r-lg); padding: 18px 20px; box-shadow: var(--sh);



}



.chart-title {



  display: flex; align-items: center; gap: 6px;



  font-size: 14px; font-weight: 700; color: var(--ink); margin-bottom: 14px;



}



.chart-title .sico { width: 15px; height: 15px; color: var(--brand); }



.bar-chart { width: 100%; display: flex; align-items: flex-end; gap: 8px; padding: 12px 4px 0; }



.hbar-list { display: flex; flex-direction: column; gap: 12px; }



.hbar-item { display: flex; align-items: center; gap: 10px; }



.hbar-item .hb-label { width: 90px; font-size: 12px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }



.hbar-item .hb-track { flex: 1; height: 8px; background: #f0eeea; border-radius: 8px; overflow: hidden; }



.hbar-item .hb-fill { height: 100%; border-radius: 8px; background: linear-gradient(90deg, var(--brand), var(--brand-2)); min-width: 2px; transition: width .6s ease; }



.hbar-item .hb-val { font-size: 12px; font-weight: 700; color: var(--ink); min-width: 40px; text-align: right; }







/* ---------- 上传 & 图片预览 ---------- */



.upload-area {



  border: 2px dashed #cdd9f2;



  border-radius: var(--r-md);



  padding: 26px 20px;



  text-align: center;



  background: var(--brand-soft);



  cursor: pointer;



  transition: all .2s;



}



.upload-area:hover, .upload-area:active { border-color: var(--brand); background: #e4edff; }



.upload-area .up-icon { margin-bottom: 6px; color: var(--brand); }



.upload-area .up-icon .sico { width: 28px; height: 28px; }



.upload-area p { font-size: 14px; font-weight: 700; color: var(--brand); margin-bottom: 3px; }



.upload-area small { font-size: 12px; color: var(--ink-3); }



.img-preview { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }



.img-item { position: relative; border-radius: 10px; overflow: hidden; aspect-ratio: 1; }



.img-item img { width: 100%; height: 100%; object-fit: cover; }



.img-item .rm {



  position: absolute; top: 4px; right: 4px;



  width: 22px; height: 22px; border-radius: 50%;



  background: rgba(0,0,0,.55); color: #fff;



  border: none; font-size: 14px; line-height: 1;



  display: flex; align-items: center; justify-content: center;



}



#imgList { display: flex; flex-wrap: wrap; gap: 10px; }



#imgList > div { border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }



#imgList img { max-height: 160px; display: block; }







/* ---------- 明细表格卡片化（移动端） ---------- */



@media (max-width: 768px) {



  .table-wrap.mobile-card { overflow-x: hidden; }



  .table-wrap.mobile-card table { min-width: 0; }



  .table-wrap.mobile-card thead { display: none; }



  .table-wrap.mobile-card tbody, .table-wrap.mobile-card tr, .table-wrap.mobile-card td { display: block; width: 100%; box-sizing: border-box; }



  .table-wrap.mobile-card tr {



    border: 1px solid var(--line);



    border-radius: var(--r-md);



    margin-bottom: 12px;



    padding: 4px 14px;



    background: #fff;



    box-shadow: 0 1px 4px rgba(0,0,0,.03);



  }



  .table-wrap.mobile-card td {



    display: flex; justify-content: space-between; align-items: center; gap: 12px;



    padding: 8px 0; border: none; border-bottom: 1px dashed #f0eeea;



    font-size: 13px; text-align: right;



  }



  .table-wrap.mobile-card td:last-child { border-bottom: none; }



  .table-wrap.mobile-card td::before { content: attr(data-label); font-weight: 700; color: var(--ink-3); flex-shrink: 0; font-size: 12px; }



  .table-wrap.mobile-card td[data-label="操作"] { display: block; text-align: right; padding-top: 8px; }



  .table-wrap.mobile-card td[data-label="操作"]::before { display: none; }



  .table-wrap.mobile-card td[data-label="设计物料"], .table-wrap.mobile-card td[data-label="物料名称"] { display: block; text-align: left; }



  .table-wrap.mobile-card td[data-label="设计物料"]::before, .table-wrap.mobile-card td[data-label="物料名称"]::before { display: block; margin-bottom: 4px; }



}







/* ============================================================



   各端移动端适配



   ============================================================ */



@media (max-width: 768px) {



  body { background: var(--bg); }



  .container { padding: 14px 14px 200px; }







  /* 顶部（移动端去掉 backdrop-filter，避免破坏底部 tabs 的 fixed 定位） */



  .header { padding: 0; background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; }



  .header-top { height: 56px; padding: 0 14px; }



  .brand img { height: 34px; }



  .brand h1 { font-size: 14px; }



  .brand p { display: none; }



  .header-right .btn { display: none; }



  .user-info { padding: 4px 6px; }



  .user-info .avatar { width: 32px; height: 32px; font-size: 13px; }



  .user-info span { max-width: 64px; font-size: 12px; }







  /* 统计卡 2 列 */



  .stat-cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }



  .stat-card { padding: 14px 14px; }



  .stat-card .v { font-size: 22px; }



  .stat-card .k { font-size: 11px; }







  /* 筛选栏 */



  .filter-bar { padding: 10px 12px; gap: 8px; }



  .filter-bar .input, .filter-bar .select { flex: 1 1 110px; min-width: 110px; font-size: 13px; padding: 9px 10px; }







  /* 卡片 */



  .card { border-radius: 14px; margin-bottom: 14px; }



  .card-title { padding: 14px 16px; font-size: 14px; }



  .card-body { padding: 16px; }







  /* 表单 */



  .form-grid { grid-template-columns: 1fr; gap: 14px; }



  .form-item.full { grid-column: 1; }



  .form-item .input, .form-item .select, .form-item textarea { font-size: 15px; padding: 12px 13px; }







  /* 按钮 */



  .btn { padding: 11px 16px; font-size: 14px; }







  /* 弹层：底部上滑 */



  .modal-mask { padding: 0; align-items: flex-end; }



  .modal {



    width: 100%; max-width: 100%;



    max-height: 92vh;



    border-radius: 20px 20px 0 0;



    animation: slideUp .28s ease;



  }



  @keyframes slideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }



  .modal-head { padding: 16px 18px; }



  .modal-body { padding: 16px 18px; }



  .modal-foot { padding: 14px 18px calc(14px + env(safe-area-inset-bottom)); }



  .modal-foot .btn { flex: 1; }







  /* 图表单列 */



  .chart-row { grid-template-columns: 1fr; gap: 12px; }



  .chart-box { padding: 14px 16px; }







  /* 表格 */



  table { font-size: 12px; }



  th, td { padding: 9px 8px; }







  /* 空状态 */



  .empty { padding: 48px 16px; }







  /* 底部导航（固定） */



  .tabs {



    position: fixed; bottom: 0; left: 0; right: 0;



    background: rgba(255,255,255,.94);



    backdrop-filter: blur(12px);



    border-top: 1px solid var(--line);



    display: flex; justify-content: space-around; align-items: flex-start;



    padding: 8px 4px calc(10px + env(safe-area-inset-bottom));



    z-index: 99;



    box-shadow: 0 -8px 28px rgba(35,26,20,.07);



  }



  .tab {



    flex: 1; min-width: 0; position: relative;



    padding: 8px 1px 10px;



    font-size: 11px; font-weight: 600;



    border-radius: 12px; margin: 0 1px;



    display: flex; flex-direction: column; align-items: center; gap: 4px;



    color: var(--ink-3);



    letter-spacing: .2px;



    transition: color .2s;



  }



  .tab .sico { width: 20px; height: 20px; }



  .tab::before { display: none; }



  .tab.active {



    color: var(--brand);



    background: linear-gradient(180deg, rgba(51,44,43,.07), rgba(51,44,43,0));



  }



  .tab.active::after {



    content: ''; position: absolute; top: -8px; left: 28%; right: 28%; height: 3px;



    border-radius: 0 0 4px 4px;



    background: linear-gradient(90deg, var(--brand), var(--brand-2));



    box-shadow: 0 2px 6px rgba(51,44,43,.35);



  }







  /* 管理后台：10 tab 横滑 + 防遮挡 */



  .adm-page .tabs { padding: 6px 8px calc(8px + env(safe-area-inset-bottom)); overflow-x: auto; justify-content: flex-start; }



  .adm-page .tabs .tab { flex: none; min-width: 68px; padding: 6px 2px 8px; font-size: 11.5px; gap: 4px; height: 62px; justify-content: center; }



  .adm-page .tabs .tab .sico { width: 20px; height: 20px; }



  .adm-page .tabs .tab.active::after { top: -6px; }



  .adm-page .container { padding-bottom: 80px; }







  /* 设计师端 */



  .ds-page .tabs { padding: 6px 4px calc(8px + env(safe-area-inset-bottom)); }



  .ds-page .tabs .tab { padding: 7px 2px 9px; font-size: 11px; gap: 3px; height: 66px; justify-content: center; }



  .ds-page .tabs .tab .sico { width: 20px; height: 20px; }



  .ds-page .container { padding-bottom: 82px; }







  /* 财务系统 */



  .fin-page .tabs { padding: 6px 4px calc(8px + env(safe-area-inset-bottom)); }



  .fin-page .tabs .tab { flex: none; min-width: 68px; padding: 6px 2px 8px; font-size: 11.5px; gap: 4px; height: 62px; justify-content: center; }



  .fin-page .tabs .tab .sico { width: 20px; height: 20px; }



  .fin-page .tabs .tab.active::after { top: -6px; }



  .fin-page .container { padding-bottom: 78px; }



}







/* 超小屏 */



@media (max-width: 375px) {



  .stat-cards { grid-template-columns: 1fr 1fr; gap: 8px; }



  .stat-card .v { font-size: 20px; }



}







/* ============================================================



   财务系统（fin-*）



   ============================================================ */



.fin-hero-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin-bottom: 18px; }



.fin-hero-card {



  display: block;



  background: var(--card); border: 1px solid var(--line);



  border-radius: var(--r-lg); padding: 18px; box-shadow: var(--sh);



  transition: transform .2s;



}



.fin-hero-card:hover { transform: translateY(-2px); }



.fin-hc-icon { width: 46px; height: 46px; border-radius: 13px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }



.fin-hc-icon .sico { width: 24px; height: 24px; stroke-width: 1.5; }



.fin-hero-card .fin-hc-label { font-size: 12px; color: var(--ink-3); font-weight: 600; }



.fin-hero-card .fin-hc-value { font-size: 22px; font-weight: 800; color: var(--ink); line-height: 1.2; }



.fin-panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh); margin-bottom: 16px; overflow: hidden; }



.fin-panel-title { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; padding: 15px 18px; border-bottom: 1px solid var(--line); }



.fin-panel-title .sico { width: 15px; height: 15px; color: var(--brand); }



.fin-panel-body { padding: 16px 18px; }



.fin-filter-bar { display: flex; flex-wrap: wrap; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line); }



.fin-filter-bar .input, .fin-filter-bar .select { font-size: 13px; padding: 9px 12px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg-soft); min-height: 36px; }



.fin-filter-bar .input:focus, .fin-filter-bar .select:focus { outline: none; border-color: var(--brand); background: #fff; }



.fin-table-wrap { overflow-x: auto; }



.fin-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 620px; }



  #salTable { min-width: 680px; }



.fin-table th { background: var(--bg-soft); padding: 11px 14px; font-size: 12px; font-weight: 700; color: var(--ink-2); text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }



.fin-table td { padding: 11px 14px; border-bottom: 1px solid #f2f0ec; white-space: nowrap; }



.fin-table tr:hover td { background: #faf9f7; }



.fin-month-chart { width: 100%; }



.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px 14px; align-items: end; }



.form-row .form-item { min-width: 0; }



.report-card {



  display: flex; align-items: center; gap: 14px;



  background: var(--card); border: 1px solid var(--line);



  border-radius: var(--r-lg); padding: 16px 18px; box-shadow: var(--sh);



  transition: transform .18s, box-shadow .18s;



}



.report-card:hover { transform: translateY(-2px); box-shadow: var(--sh-lg); }



.rc-icon { width: 44px; height: 44px; border-radius: 12px; background: var(--brand-soft); color: var(--brand); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }



.rc-icon .sico { width: 22px; height: 22px; }



.rc-info { flex: 1; min-width: 0; }



.rc-info h4 { font-size: 14px; font-weight: 700; margin-bottom: 3px; }



.rc-info p { font-size: 12px; color: var(--ink-3); }



.rc-btn { flex-shrink: 0; }



.sub { font-size: 12px; color: var(--ink-3); }







/* ============================================================



   客户查询（cqd-*）



   ============================================================ */



.query-wrap { max-width: 720px; margin: 0 auto; position: relative; z-index: 1; padding: 24px 20px 60px; }



.brand-bar { text-align: center; margin-bottom: 28px; }



.brand-bar img { height: 54px; margin-bottom: 10px; }



.brand-bar h1 { font-size: 22px; font-weight: 800; letter-spacing: 2px; color: var(--ink); }



.query-title { text-align: center; font-size: 15px; color: var(--ink-2); margin-bottom: 22px; letter-spacing: 1px; }



.search-box {



  display: flex; align-items: center; gap: 10px;



  background: #fff; border: 1px solid var(--line);



  border-radius: 14px; padding: 14px 18px;



  box-shadow: var(--sh); margin-bottom: 22px;



}



.search-icon { color: var(--ink-3); }



.search-icon .sico { width: 20px; height: 20px; }



.search-box input { flex: 1; border: none; background: none; font-size: 16px; color: var(--ink); outline: none; }



.login-back-btn { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--ink-3); background: none; border: none; margin-bottom: 14px; }



.login-back-btn:hover { color: var(--ink); }



.query-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh); padding: 20px; }



.hero-stat { display: flex; align-items: baseline; gap: 6px; margin-bottom: 18px; }



.hero-stat .hs-value { font-size: 30px; font-weight: 800; color: var(--brand); letter-spacing: -1px; }



.hero-stat .hs-label { font-size: 13px; color: var(--ink-3); }



.type-tab { display: flex; gap: 8px; margin-bottom: 16px; }



.type-tab button {



  flex: 1; padding: 10px; border-radius: var(--r-sm);



  border: 1px solid var(--line-2); background: var(--bg-soft);



  font-size: 13px; font-weight: 600; color: var(--ink-2);



  transition: all .2s;



}



.type-tab button.active { background: var(--brand); color: #fff; border-color: var(--brand); box-shadow: 0 4px 12px rgba(51,44,43,.25); }



.cqd-row { display: flex; gap: 8px; padding: 9px 0; border-bottom: 1px dashed #f0eeea; font-size: 13px; }



.cqd-row:last-child { border-bottom: none; }



.cqd-row .k { color: var(--ink-3); min-width: 64px; flex-shrink: 0; }



.cqd-row .v { color: var(--ink); font-weight: 500; }



.cqd-sec { margin-bottom: 14px; }



.cqd-sec-title { font-size: 12px; font-weight: 700; color: var(--ink-2); letter-spacing: 1px; margin-bottom: 8px; text-transform: uppercase; }



.cqd-card { background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px; margin-bottom: 10px; }



.cqd-card .cqd-title { font-size: 14px; font-weight: 700; margin-bottom: 6px; }



.cqd-card.hl { background: linear-gradient(135deg, var(--brand-soft), #f4f8ff); border-color: #d3e0fb; }



.cqd-badge { display: inline-block; padding: 2px 9px; border-radius: 20px; font-size: 11px; font-weight: 600; }



.cqd-img { border-radius: 10px; overflow: hidden; }



.cqd-img img { width: 100%; display: block; }







/* ============================================================



   记录卡片（record-*，设计师/物料记录列表）



   ============================================================ */



.record-list { display: flex; flex-direction: column; gap: 12px; }



.record-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh); overflow: hidden; }



.record-header { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }



.record-title { font-size: 14px; font-weight: 700; }



.record-date { font-size: 12px; color: var(--ink-3); }



.record-info { padding: 12px 16px; }



.record-info .k { color: var(--ink-3); font-size: 12px; }



.record-info .v { color: var(--ink); font-weight: 500; font-size: 13px; }



.record-amount { font-size: 16px; font-weight: 800; color: var(--brand); }



.record-actions { display: flex; gap: 8px; padding: 0 16px 14px; }



.total { font-size: 14px; font-weight: 700; }



.summary-card { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--brand-soft); border-radius: var(--r-md); margin-bottom: 14px; }



.summary-item { display: flex; flex-direction: column; align-items: center; }



.summary-item .k { font-size: 11px; color: var(--ink-3); }



.summary-item .v { font-size: 18px; font-weight: 800; color: var(--brand); }







/* ============================================================



   登录页（保持原设计，不改）



   ============================================================ */



.login-page { position: relative; z-index: 1; min-height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 40px 20px; box-sizing: border-box; }



.login-content { display: flex; align-items: center; gap: 80px; max-width: 900px; width: 100%; animation: loginFadeIn .8s ease-out; }



@keyframes loginFadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }



.login-brand { flex: 1; text-align: center; }



.login-logo { width: 100px; height: auto; margin-bottom: 24px; filter: drop-shadow(0 8px 24px rgba(51,44,43,0.12)); }



.login-title { font-size: 36px; font-weight: 800; color: #332C2B; margin-bottom: 8px; letter-spacing: 6px; }



.login-subtitle { font-size: 11px; color: #999; letter-spacing: 3px; text-transform: uppercase; }



.login-form-area { flex: 1; max-width: 360px; width: 100%; }



.login-form-title { font-size: 24px; font-weight: 700; color: #332C2B; margin-bottom: 6px; }



.login-form-desc { font-size: 13px; color: #999; margin-bottom: 32px; }



.login-input-group { position: relative; margin-bottom: 24px; }



.login-input-icon { position: absolute; left: 4px; top: 50%; transform: translateY(-50%); font-size: 16px; opacity: 0.4; }



.login-input-icon .sico { width: 16px; height: 16px; }



.login-input-group input { width: 100%; padding: 14px 4px 14px 36px; border: none; border-bottom: 2px solid #e0e0e0; background: transparent; font-size: 15px; color: #332C2B; transition: all 0.3s; box-sizing: border-box; }



.login-input-group input:focus { outline: none; border-bottom-color: #332C2B; }



.login-input-group input::placeholder { color: #bbb; }



.login-submit-btn { width: 100%; padding: 14px; background: #332C2B; color: #fff; border: none; border-radius: 12px; font-size: 15px; font-weight: 700; cursor: pointer; transition: all 0.3s; letter-spacing: 4px; margin-top: 8px; display: flex; align-items: center; justify-content: center; gap: 8px; box-shadow: 0 6px 20px rgba(51, 44, 43, 0.2); }



.login-submit-btn:hover { background: #4a4241; transform: translateY(-2px); box-shadow: 0 8px 28px rgba(51, 44, 43, 0.28); }



.login-submit-btn:active { transform: translateY(0); }



.login-arrow { transition: transform 0.3s; }



.login-submit-btn:hover .login-arrow { transform: translateX(4px); }



.login-links { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 28px; font-size: 12px; flex-wrap: wrap; }



.login-link { color: #888; text-decoration: none; background: none; border: none; cursor: pointer; padding: 0; font-size: 12px; transition: color 0.2s; display: inline-flex; align-items: center; gap: 4px; }



.login-link:hover { color: #332C2B; }



.login-divider { color: #ddd; }



.login-footer { position: absolute; bottom: 24px; left: 0; right: 0; text-align: center; font-size: 11px; color: #bbb; letter-spacing: 1px; }



.login-error { display: none; background: rgba(212, 72, 72, 0.06); color: #d44848; padding: 12px 16px; border-radius: 10px; font-size: 13px; margin-bottom: 20px; border-left: 3px solid #d44848; }



@media (max-width: 768px) {



  .login-page { padding: 30px 20px; justify-content: flex-start; padding-top: 60px; }



  .login-content { flex-direction: column; gap: 36px; }



  .login-logo { width: 70px; margin-bottom: 16px; }



  .login-title { font-size: 28px; letter-spacing: 4px; }



  .login-form-area { max-width: 100%; }



  .login-form-title { text-align: center; font-size: 20px; }



  .login-form-desc { text-align: center; font-size: 12px; margin-bottom: 24px; }



  .login-input-group input { font-size: 16px; padding: 12px 4px 12px 32px; }



  .login-submit-btn { padding: 13px; font-size: 14px; }



  .login-footer { position: relative; bottom: auto; margin-top: 40px; }



}



@media (max-width: 375px) {



  .login-page { padding-top: 40px; }



  .login-logo { width: 60px; }



  .login-title { font-size: 24px; }



  .login-content { gap: 28px; }



}



@media (max-height: 500px) and (orientation: landscape) {



  .login-page { padding-top: 20px; padding-bottom: 20px; }



  .login-content { gap: 40px; }



  .login-logo { width: 50px; margin-bottom: 12px; }



  .login-title { font-size: 22px; }



  .login-form-title { font-size: 18px; margin-bottom: 4px; }



  .login-form-desc { margin-bottom: 16px; }



  .login-input-group { margin-bottom: 16px; }



  .login-footer { display: none; }



}







/* ============================================================



   注册页（register-*）



   ============================================================ */



.register-page { position: relative; z-index: 1; min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 40px 20px; }



.register-card { width: 100%; max-width: 460px; background: var(--card); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--sh-lg); padding: 36px 32px; }



.logo-area { text-align: center; margin-bottom: 26px; }



.logo-area img { height: 52px; margin-bottom: 12px; }



.logo-area h2 { font-size: 20px; font-weight: 800; letter-spacing: 1px; }



.form-group { margin-bottom: 18px; }



.form-group label { display: block; font-size: 12px; font-weight: 700; color: var(--ink-2); margin-bottom: 7px; }



.form-group label .required { color: var(--danger); margin-left: 2px; }



.form-group .input, .form-group .select { width: 100%; font-size: 14px; padding: 12px 14px; border-radius: var(--r-sm); border: 1.5px solid var(--line-2); background: var(--bg-soft); }



.form-group .input:focus, .form-group .select:focus { outline: none; border-color: var(--brand); background: #fff; box-shadow: 0 0 0 3px rgba(51,44,43,.10); }



.register-btn { width: 100%; padding: 13px; margin-top: 8px; }



.tip-box { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-3); margin-bottom: 18px; }



.tip-box .sico { width: 14px; height: 14px; color: var(--brand); flex-shrink: 0; }



.error-msg, .success-msg { display: none; padding: 11px 14px; border-radius: var(--r-sm); font-size: 13px; margin-bottom: 16px; }



.error-msg { background: var(--danger-soft); color: var(--danger); }



.success-msg { background: var(--ok-soft); color: var(--ok); }



.back-login { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--ink-3); background: none; border: none; margin-top: 16px; }



.back-login:hover { color: var(--ink); }







/* ============================================================



   波点背景（保持登录风格）



   ============================================================ */



.dot-bg { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 40%, #eeeeee 100%); overflow: hidden; z-index: 0; }



.dot-grid { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }



.single-dot { position: absolute; border-radius: 50%; background: #332C2B; animation: dotBlink ease-in-out infinite; }



@keyframes dotBlink { 0%, 100% { opacity: 0.08; transform: scale(0.8); } 50% { opacity: 0.5; transform: scale(1.3); } }



.dot-glow { position: absolute; bottom: -20%; right: -10%; width: 70%; height: 70%; background: radial-gradient(ellipse, rgba(51,44,43,0.06) 0%, transparent 70%); animation: glowPulse 8s ease-in-out infinite; }



@keyframes glowPulse { 0%, 100% { opacity: 0.6; } 50% { opacity: 1; } }



@media (max-width: 768px) {



  .dot-bg { background: #ffffff; }



  .single-dot { background: rgba(51,44,43,1); animation: dotBlinkMobile ease-in-out infinite; }



  @keyframes dotBlinkMobile { 0%, 100% { opacity: 0; transform: scale(0.8); } 50% { opacity: 0.06; transform: scale(1.3); } }



  .dot-glow { background: radial-gradient(ellipse, rgba(51,44,43,0.05) 0%, transparent 70%); }



}







/* ============================================================



   统一线性图标



   ============================================================ */



.sico { display: inline-block; width: 1em; height: 1em; vertical-align: -0.14em; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; pointer-events: none; }



.tab .sico, .dropdown-item .sico, .card-title .sico, .btn .sico, .login-link .sico, .action-btn .sico { width: 15px; height: 15px; }



.btn .sico { margin-right: 4px; }



.select-card .card-icon .sico { width: 28px; height: 28px; stroke-width: 1.4; }



.search-icon .sico, .login-input-icon .sico, .chart-title .sico { width: 1em; height: 1em; }



.detail-hero-icon .sico, .empty-state .sico { width: 48px; height: 48px; stroke-width: 1.2; }







/* ============================================================



   底部水滴提示



   ============================================================ */



/* ===== 到底提示（滚动到底自动浮现，固定视口底部） ===== */

.bottom-tip {

  position: fixed; left: 0; right: 0; bottom: calc(18px + env(safe-area-inset-bottom));

  text-align: center; padding: 0 16px 4px;

  font-size: 11px; color: #b9b9c4; letter-spacing: 3px; user-select: none;

  -webkit-user-select: none; opacity: 0; transform: translateY(8px);

  transition: opacity .45s ease, transform .45s ease;

  pointer-events: none; z-index: 99999999;

}

.bottom-tip.bt-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 768px) {
  .adm-page .bottom-tip, .ds-page .bottom-tip, .fin-page .bottom-tip { bottom: calc(78px + env(safe-area-inset-bottom)); }
}

.bt-dots { display: flex; gap: 6px; justify-content: center; margin-bottom: 7px; }

.bt-dots i { width: 5px; height: 5px; border-radius: 50%; background: #b9b9c4; opacity: .45; animation: btDot 1.2s ease-in-out infinite; }

.bt-dots i:nth-child(2) { animation-delay: .18s; }

.bt-dots i:nth-child(3) { animation-delay: .36s; }

.bt-text { letter-spacing: 3px; }

@keyframes btDot { 0%, 100% { transform: translateY(0); opacity: .4; } 50% { transform: translateY(-4px); opacity: 1; } }



/* ============================================================



   PWA 安装提示



   ============================================================ */



.pwa-install-prompt { position: fixed; bottom: calc(80px + env(safe-area-inset-bottom)); left: 16px; right: 16px; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; padding: 14px 18px; border-radius: 16px; box-shadow: 0 8px 24px rgba(51,44,43,.3); z-index: 999; display: flex; align-items: center; justify-content: space-between; gap: 12px; }



.pwa-install-prompt .text { flex: 1; }



.pwa-install-prompt .text h4 { font-size: 14px; font-weight: 700; margin-bottom: 2px; }



.pwa-install-prompt .text p { font-size: 12px; opacity: .9; }



.pwa-install-prompt button { background: #fff; color: var(--brand); border: none; padding: 8px 16px; border-radius: 9px; font-size: 13px; font-weight: 700; white-space: nowrap; }



.pwa-install-prompt .close { background: rgba(255,255,255,.2); color: #fff; width: 28px; height: 28px; border-radius: 50%; padding: 0; font-size: 16px; line-height: 1; }







/* ============================================================



   右下角悬浮按钮



   ============================================================ */



.fab-btn { position: fixed; bottom: calc(80px + env(safe-area-inset-bottom)); right: 20px; width: 56px; height: 56px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; font-size: 28px; font-weight: 300; border: none; box-shadow: 0 6px 20px rgba(51,44,43,.35); cursor: pointer; z-index: 90; display: flex; align-items: center; justify-content: center; transition: transform .2s, box-shadow .2s; user-select: none; -webkit-user-select: none; touch-action: none; }



.fab-btn:active { transform: scale(.92); box-shadow: 0 3px 12px rgba(51,44,43,.3); }



.fab-btn.dragging { transition: none; opacity: .8; transform: scale(1.05); }



.fab-btn:hover { transform: scale(1.1); box-shadow: 0 8px 24px rgba(51,44,43,.45); }



@media (min-width: 769px) { .fab-btn { display: flex; } }



@media (max-width: 768px) {



  .fab-btn { width: 40px; height: 40px; font-size: 22px; background: rgba(51,44,43,.5); box-shadow: 0 3px 10px rgba(51,44,43,.22); }



  .fab-btn:hover { transform: scale(1.05); }



  .tab-add { display: none !important; }



}







/* ============================================================



   其他通用（grid / 详情 / 客户端）



   ============================================================ */



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



.item-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px; box-shadow: var(--sh); }



.item-name { font-size: 15px; font-weight: 700; margin-bottom: 8px; }



.item-sub { font-size: 12px; color: var(--ink-3); }



.detail-hero { display: flex; align-items: center; gap: 16px; padding: 20px; background: linear-gradient(135deg, var(--brand-soft), #f7f9ff); border-radius: var(--r-lg); margin-bottom: 16px; }



.detail-hero-icon { width: 56px; height: 56px; border-radius: 16px; background: #fff; color: var(--brand); display: flex; align-items: center; justify-content: center; box-shadow: var(--sh); }



.detail-hero-info h3 { font-size: 18px; font-weight: 800; }



.detail-hero-info p { font-size: 12px; color: var(--ink-2); }



.action-btn { display: inline-flex; align-items: center; gap: 4px; padding: 5px 10px; border-radius: 7px; border: 1px solid var(--line-2); background: #fff; font-size: 12px; color: var(--ink-2); transition: all .15s; }



.action-btn:hover { border-color: var(--brand); color: var(--brand); }



.action-btn.danger:hover { border-color: var(--danger); color: var(--danger); }



#toast, .toast { display: none; position: fixed; top: 16px; left: 50%; transform: translateX(-50%); background: rgba(20,18,16,.92); color: #fff; padding: 12px 22px; border-radius: 12px; font-size: 13px; z-index: 99999999; box-shadow: var(--sh-lg); }
#toast.show, .toast.show { display: block; animation: toastIn .25s ease; }



@keyframes toastIn { from { opacity: 0; transform: translate(-50%, -10px); } to { opacity: 1; transform: translate(-50%, 0); } }



.back-btn { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--ink-3); background: none; border: none; margin-bottom: 14px; }



.back-btn:hover { color: var(--ink); }







/* ============================================================



   桌面端补充（769px 以上细节）



   ============================================================ */



@media (min-width: 769px) {



  .tabs { padding: 0 24px; }



  .tab { padding: 14px 22px 12px; }



  .table-wrap { border-radius: var(--r-md); }



}











/* ===== 补充样式（继承既有功能类，适配新视觉） ===== */



.fin-hero-card .fin-hc-icon .sico { width: 22px; height: 22px; stroke-width: 1.6; }







/* =====================================================



   V16.2 数据可视化 & 高级组件补充（App 质感）



   覆盖：环形图/柱状图/横条图/财务组件/记录卡/弹窗滚动



   ===================================================== */







/* ---------- 环形图 ---------- */



.donut-wrap { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; padding: 6px 0; }



.donut { position: relative; flex-shrink: 0; }



.donut svg { display: block; filter: drop-shadow(0 6px 14px rgba(35,28,20,.10)); }



.donut-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; pointer-events: none; }



.donut-center .v { font-size: 22px; font-weight: 800; color: var(--ink); letter-spacing: -.5px; line-height: 1.1; font-variant-numeric: tabular-nums; }



.donut-center .k { font-size: 11px; color: var(--ink-3); margin-top: 3px; }







/* ---------- 图例 ---------- */



.legend { flex: 1; min-width: 170px; display: flex; flex-direction: column; gap: 9px; }



.legend-item { display: flex; align-items: center; gap: 9px; font-size: 12.5px; }



.legend-dot { width: 10px; height: 10px; border-radius: 3.5px; flex-shrink: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,.05); }



.legend-name { flex: 1; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }



.legend-val { font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }



.legend-pct { color: var(--ink-3); font-size: 11px; font-weight: 600; background: var(--bg-soft); padding: 2px 8px; border-radius: 99px; white-space: nowrap; }







/* ---------- 柱状图（月份趋势） ---------- */



.bar-col { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; justify-content: flex-end; height: 150px; }



.bar { width: 18px; border-radius: 7px 7px 3px 3px; min-height: 4px; transition: height .45s ease; box-shadow: 0 2px 6px rgba(51,44,43,.16); }



.bar-val { font-size: 10px; color: var(--ink-2); white-space: nowrap; font-weight: 600; font-variant-numeric: tabular-nums; }



.bar-label { font-size: 11px; color: var(--ink-3); font-weight: 600; }







/* ---------- 横向条形图 ---------- */



.hbar-row { display: flex; align-items: center; gap: 12px; padding: 0px 8px; }



.hbar-row:hover { background: var(--bg-soft); }



.hbar-label { width: 90px; flex-shrink: 0; font-size: 12.5px; color: var(--ink); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }



.hbar-track { flex: 1; height: 10px; background: var(--bg-soft); border-radius: 99px; overflow: hidden; }



.hbar-fill { height: 100%; border-radius: 99px; min-width: 3px; transition: width .5s ease; box-shadow: 0 1px 4px rgba(0,0,0,.10); }



.hbar-val { width: 82px; flex-shrink: 0; text-align: right; font-size: 11px; color: var(--ink-2); line-height: 1.35; font-variant-numeric: tabular-nums; }







/* ---------- 财务 Hero 卡（V16.3 浅色精致版） ---------- */



.fin-hero-card { position: relative; display: block; border-radius: 18px; padding: 20px 74px 20px 20px; overflow: hidden; box-shadow: 0 6px 22px rgba(35,28,20,.06); background: #fff !important; color: var(--ink) !important; border: 1px solid rgba(35,28,20,.05); transition: transform .2s, box-shadow .2s; }



.fin-hero-card:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(35,28,20,.10); }



.fin-hc-icon { position: absolute; right: 18px; top: 18px; width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: rgba(51,44,43,.09); color: #332C2B; opacity: 1; }



.fin-hc-icon .sico { width: 22px; height: 22px; stroke-width: 1.6; }



.fin-hc-label { font-size: 12px; color: var(--ink-3) !important; opacity: 1; font-weight: 700; letter-spacing: .4px; }



.fin-hc-value { font-size: 26px; font-weight: 800; color: var(--ink) !important; margin-top: 6px; letter-spacing: -.5px; font-variant-numeric: tabular-nums; line-height: 1.15; }



.fin-hc-sub { font-size: 12px; color: var(--ink-3) !important; opacity: 1; margin-top: 5px; font-weight: 500; }







/* ---------- 财务环形图（conic） ---------- */



.fin-donut { width: 150px; height: 150px; border-radius: 50%; position: relative; flex-shrink: 0; box-shadow: 0 6px 18px rgba(35,28,20,.08); }



.fin-donut-center { position: absolute; inset: 0; margin: auto; width: 96px; height: 96px; background: #fff; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; box-shadow: 0 2px 8px rgba(0,0,0,.06); }



.fin-donut-center .v { font-size: 20px; font-weight: 800; color: var(--ink); letter-spacing: -.5px; font-variant-numeric: tabular-nums; }



.fin-donut-center .t { font-size: 11px; color: var(--ink-3); margin-top: 2px; }



.fin-legend { flex: 1; min-width: 140px; }



.fin-legend-item { display: flex; align-items: center; gap: 9px; padding: 8px 2px; font-size: 13px; color: var(--ink-2); }



.fin-legend-item .dot { width: 10px; height: 10px; border-radius: 3.5px; flex-shrink: 0; }



.fin-legend-item .lv { margin-left: auto; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }







/* ---------- 财务横条 ---------- */



.fin-bar-row { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }



.fin-bar-label { width: 76px; font-size: 12px; color: var(--ink-3); flex-shrink: 0; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }



.fin-bar-track { flex: 1; height: 22px; background: var(--bg-soft); border-radius: 8px; overflow: hidden; }



.fin-bar-fill { height: 100%; border-radius: 8px; min-width: 2px; transition: width .5s ease; box-shadow: 0 1px 4px rgba(0,0,0,.10); }



.fin-bar-val { width: 96px; font-size: 12px; font-weight: 800; color: var(--ink); flex-shrink: 0; font-variant-numeric: tabular-nums; }







/* ---------- 财务双柱月份图 ---------- */



.fin-mc-col { flex: 1; min-width: 36px; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 170px; }



.fin-mc-group { display: flex; align-items: flex-end; gap: 4px; height: 100%; }



.fin-mc-bar { width: 12px; border-radius: 5px 5px 2px 2px; min-height: 3px; transition: height .4s ease; box-shadow: 0 2px 5px rgba(0,0,0,.12); }



.fin-mc-label { font-size: 11px; color: var(--ink-3); font-weight: 600; }







/* ---------- 财务标签 ---------- */



.fin-tag { display: inline-block; padding: 3px 10px; border-radius: 99px; font-size: 11px; font-weight: 700; }



.fin-tag.blue { background: #e6f0ff; color: #332C2B; }



.fin-tag.purple { background: #efeaff; color: #7b5cf0; }



.fin-tag.red { background: #fdecec; color: #d44848; }



.fin-tag.green { background: #e6f6ef; color: #2e9e6c; }



.fin-tag.orange { background: #fdf0e6; color: #e2703a; }







/* ---------- 颜色类（图表标签） ---------- */



.blue { color: #332C2B; } .green { color: #2e9e6c; }



.orange { color: #e2703a; } .purple { color: #7b5cf0; } .red { color: #d44848; }







/* ---------- 记录卡（设计师/客户工单卡） ---------- */



.item-avatar { width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 17px; color: #fff; flex-shrink: 0; box-shadow: 0 3px 8px rgba(0,0,0,.12); }



.item-header { display: flex; align-items: center; gap: 12px; }



.item-stats { display: flex; align-items: stretch; gap: 10px; margin-top: 14px; }



.item-actions { display: flex; align-items: center; gap: 8px; margin-top: 14px; flex-wrap: wrap; }







/* 记录卡里的按钮 */



.btn-edit { background: #e6f0ff !important; color: #332C2B !important; border: none !important; }



.btn-edit:hover { background: #d5e4ff !important; }



.btn-delete { background: #fdecec !important; color: #d44848 !important; border: none !important; }



.btn-delete:hover { background: #fadada !important; }







/* ---------- 统计项（设计师统计） ---------- */



.item-stats .stat-item { flex: 1; min-width: 0; }



.stat-item { background: #fff; border-radius: 12px; padding: 12px 14px; box-shadow: var(--sh); }



.stat-item .k { font-size: 11px; color: var(--ink-3); font-weight: 600; white-space: nowrap; }



.stat-item .v { font-size: 18px; font-weight: 800; color: var(--ink); margin-top: 5px; font-variant-numeric: tabular-nums; white-space: nowrap; }



.stat-item .sub { font-size: 11px; color: var(--ink-3); margin-top: 2px; }







/* ---------- 提成比例输入 ---------- */



.salary-input { width: 110px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; font-size: 13px; text-align: center; }







/* ---------- 弹窗滚动修复（关键） ---------- */



.modal { display: flex; flex-direction: column; max-height: 92vh; opacity: 1 !important; transform: none !important; animation: none !important; }



.modal-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; }



.modal > form { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }



.modal > form > .form-grid,



.modal > form > .modal-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; }



.modal > div:not(.modal-head):not(.modal-foot):not(.modal-close) { flex: 1 1 auto; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; }



.modal-foot { flex-shrink: 0; }



.modal-head { flex-shrink: 0; }











/* ---------- 联系人/账号标签（V16.4） ---------- */



.contact-tag { display:inline-block; font-size:11px; color:#555; background:#f2f1ee; border:1px solid #e8e5e0; border-radius:6px; padding:2px 8px; margin:2px 5px 2px 0; font-weight:600; }







/* ---------- 工单表单分区（V16.11 重设计） ---------- */



.form-section { background:#f7f8fb; border:1px solid #eef0f5; border-radius:14px; padding:14px 16px; margin-bottom:14px; }



.form-section-title { display:flex; align-items:center; gap:7px; font-size:12.5px; font-weight:700; color:#332C2B; margin-bottom:12px; letter-spacing:.3px; }



.form-section-title::after { content:''; flex:1; height:1px; background:#e3e7ee; margin-left:4px; }



.form-section .form-grid { margin-bottom:0; }



.form-section .form-item label { font-size:11.5px; color:#666; margin-bottom:6px; }



.form-section .form-item .input, .form-section .form-item .select, .form-section .form-item textarea { background:#fff; border-radius:8px; }



.form-section .form-item .input:focus, .form-section .form-item .select:focus, .form-section .form-item textarea:focus { border-color:#332C2B; box-shadow:0 0 0 3px rgba(51,44,43,.10); }



/* 自动计算框 */



.form-calc { background:#eef2ff !important; font-weight:700 !important; color:#332C2B !important; }



.form-calc.material { background:#e9f7f3 !important; color:#1fa8b0 !important; }



.form-calc.material-total { background:#fdf0e7 !important; color:#e2703a !important; }



/* 记录类型切换按钮组 */



.record-type-switch { display:flex; gap:10px; }



.record-type-switch .rt-opt { flex:1; padding:10px; border:1.5px solid #e3e7ee; border-radius:10px; text-align:center; cursor:pointer; font-size:13px; font-weight:600; color:#888; background:#fff; transition:all .15s; }



.record-type-switch .rt-opt.active { border-color:#332C2B; color:#332C2B; background:#eef2ff; }



.record-type-switch .rt-opt.material.active { border-color:#1fa8b0; color:#1fa8b0; background:#e6f6f4; }







/* ---------- 弹窗表单滚动（V16.11，修复内容超出被遮挡） ---------- */



.modal > form { flex: 1; min-height: 0; overflow-y: auto; padding: 20px 22px; }



.modal > form + .modal-foot, .modal > .modal-foot { flex-shrink: 0; }



/* 弹窗内上传区与分区间距 */



.modal > form .form-section:last-child { margin-bottom: 4px; }



/* ---------- 弹窗版面增强（V16.12 高级感） ---------- */



.form-section {



  background: linear-gradient(180deg, #fbfdff 0%, #f5f8fc 100%);



  border: 1px solid #e8edf4;



  border-radius: 16px;



  padding: 16px 18px;



  margin-bottom: 16px;



  box-shadow: inset 0 1px 0 rgba(255,255,255,.9);



}



.form-section-title {



  display: flex; align-items: center; gap: 8px;



  font-size: 12.5px; font-weight: 800; color: #332C2B;



  letter-spacing: .4px; margin-bottom: 14px;



}



.form-section-title::before {



  content: ''; width: 3px; height: 14px; border-radius: 2px;



  background: linear-gradient(180deg, #332C2B, #8fb0ff);



  flex-shrink: 0;



}



.form-section-title::after {



  content: ''; flex: 1; height: 1px;



  background: linear-gradient(90deg, #dde5f1, transparent);



}



.form-section .form-item label {



  font-size: 11.5px; color: #5a6472; font-weight: 600; margin-bottom: 6px;



}



.form-section .form-item label .req { color: #e74c3c; }



.form-section .form-item .input,



.form-section .form-item .select,



.form-section .form-item textarea {



  background: #fff; border-radius: 9px; border: 1px solid #dfe4ec;



  box-shadow: 0 1px 2px rgba(20,30,50,.03);



  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;



}



.form-section .form-item .input:focus,



.form-section .form-item .select:focus,



.form-section .form-item textarea:focus {



  border-color: #332C2B;



  box-shadow: 0 0 0 3px rgba(51,44,43,.10);



  background: #fdfdfe;



}



/* 必填星号 */



.form-item label .star { color: #e74c3c; margin-left: 1px; }



/* 自动计算框增强 */



.form-calc { background: linear-gradient(135deg,#f1efed,#e2eaff) !important; font-weight:800 !important; color:#332C2B !important; border:1px solid #d4e0fb !important; }



.form-calc.material { background: linear-gradient(135deg,#e8f8f5,#d7f1ec) !important; color:#159a9f !important; border-color:#c3e8e2 !important; }



.form-calc.material-total { background: linear-gradient(135deg,#fdf1e7,#fae4d2) !important; color:#e2703a !important; border-color:#f3d2b8 !important; }



/* 上传区增强 */



.upload-area { background: linear-gradient(180deg,#fbfdff,#f4f7fb); border:2px dashed #cfd8e6 !important; border-radius:12px !important; }



.upload-area:hover { border-color:#332C2B !important; background:#f0f5ff; }



/* 弹窗头部微增强 */



.modal-head { background: linear-gradient(90deg,#f8faff,#ffffff); }







/* 预览图缩小（V16.12） */



.img-preview {



  display: grid !important;



  grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)) !important;



  gap: 6px !important;



  margin-top: 10px !important;



}



.img-item { border-radius: 8px !important; }



.img-item .rm { width: 18px !important; height: 18px !important; font-size: 12px !important; }



/* ========== 申报/验收系统 ========== */



.apply-subtabs { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }



.apply-subtab {



  padding: 9px 20px; border: 1px solid var(--line); border-radius: 999px;



  background: #fff; font-size: 14px; font-weight: 600; color: var(--ink-2);



  cursor: pointer; transition: all .18s;



}



.apply-subtab:hover { border-color: var(--brand, #332C2B); color: var(--brand, #332C2B); }



.apply-subtab.active {



  background: var(--brand, #332C2B); border-color: var(--brand, #332C2B);



  color: #fff;



}



.apply-form-row { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }



.apply-form-row label { font-size: 13px; color: var(--ink-2, #555); white-space: nowrap; }



.apply-form-row label em { color: #e5484d; font-style: normal; margin-left: 2px; }



.apply-form-row .select, .apply-form-row .input { flex: 1; min-width: 110px; }



.apply-lib-tip {



  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;



  background: var(--bg-soft, #f6f5f3); border-radius: 10px; padding: 8px 12px;



  font-size: 12px; color: var(--ink-2, #555); margin-bottom: 12px;



}



.apply-lib-tip .select { max-width: 260px; }



.apply-items-head {



  display: flex; align-items: center; gap: 6px;



  background: var(--bg-soft, #f6f5f3); border-radius: 10px 10px 0 0;



  padding: 8px 10px; font-size: 12px; font-weight: 700; color: var(--ink-2, #555);



}



.apply-items-head span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }



.apply-item-row {



  display: flex; align-items: center; gap: 6px; padding: 6px 10px;



  border-bottom: 1px solid var(--line, #eee);



}



.apply-item-row:nth-child(even) { background: rgba(0,0,0,.015); }



.apply-item-row .input { flex: 1; min-width: 0; height: 34px; padding: 4px 8px; font-size: 13px; }



.apply-item-row .m-name { width: 18%; }



.apply-item-row .m-spec { width: 24%; }



.apply-item-row .m-qty { width: 56px; text-align: center; }



.apply-item-row .m-unit { width: 52px; text-align: center; }



.apply-item-row .m-price { width: 66px; text-align: right; }



.apply-item-row .m-total { width: 70px; font-weight: 700; text-align: right; font-size: 13px; }



.apply-item-row .m-img { flex: 1; min-width: 150px; display: flex; align-items: center; gap: 6px; }



.apply-item-row .m-img input[type=file] { width: 72px; font-size: 11px; }



.apply-item-row .m-img img { width: 40px; height: 40px; object-fit: cover; border-radius: 6px; border: 1px solid var(--line, #eee); }



.apply-item-row .m-delay { width: 86px; }



.apply-item-row .m-rm {



  width: 24px; height: 24px; border: none; border-radius: 50%;



  background: #fdecec; color: #e5484d; font-size: 15px; line-height: 1;



  cursor: pointer; flex-shrink: 0;



}



.apply-item-row .m-rm:hover { background: #f7d4d4; }



.apply-items-foot {



  display: flex; align-items: center; justify-content: space-between;



  padding: 10px; border-top: 1px solid var(--line, #eee);



}



.apply-total { font-size: 14px; color: var(--ink-2, #555); }



.apply-total b { font-size: 18px; color: #e2703a; }



.apply-status { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; }



.apply-status.draft { background: #fff4e5; color: #b26a00; }



.apply-status.producing { background: #e8f0fe; color: #332C2B; }



.apply-status.accepted { background: #e7f7ee; color: #1a9d5c; }



.apply-status.canceled { background: #f0efed; color: #888; }



.detail-table { width: 100%; border-collapse: collapse; font-size: 13px; margin-bottom: 12px; }



.detail-table th, .detail-table td {



  border: 1px solid var(--line, #e5e3e0); padding: 8px; text-align: center; vertical-align: middle;



}



.detail-table th { background: var(--bg-soft, #f6f5f3); font-weight: 700; }



.detail-table img { max-width: 70px; max-height: 70px; object-fit: cover; border-radius: 4px; }



.detail-info { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin-bottom: 14px; }



.detail-info .di { background: var(--bg-soft, #f6f5f3); border-radius: 10px; padding: 10px 14px; }



.detail-info .di .k { font-size: 11px; color: #999; margin-bottom: 4px; }



.detail-info .di .v { font-size: 14px; font-weight: 700; }



@media (max-width: 768px) {



  .apply-item-row { flex-wrap: wrap; }



  .apply-item-row .m-name { width: 45%; }



  .apply-item-row .m-spec { width: 50%; }



  .apply-item-row .m-qty { width: 70px; }



  .apply-item-row .m-unit { width: 60px; }



  .apply-item-row .m-price { width: 80px; }



  .apply-item-row .m-total { width: 90px; }



  .apply-item-row .m-img { width: 100%; flex-basis: 100%; }



  .apply-items-head { display: none; }



}











/* 常用物料库图片缩略图 */



.lib-thumb {



  width: 46px; height: 46px; object-fit: cover;



  border-radius: 6px; border: 1px solid #e5e7eb;



  cursor: pointer; vertical-align: middle;



  transition: transform .15s;



}



.lib-thumb:hover { transform: scale(1.35); box-shadow: 0 4px 12px rgba(0,0,0,.15); }







/* V18.2 管理员三页面卡片左右内边距（设计师奖励/导出Excel/操作日志） */



#page-system .card, #page-bonus .card, #page-export .card, #page-logs .card {



  padding: 0 20px 18px;



}



#page-system .card > .card-title,



#page-bonus .card > .card-title,



#page-export .card > .card-title,



#page-logs .card > .card-title {



  margin-left: -20px;



  margin-right: -20px;



}



@media (max-width: 768px) {



  #page-system .card, #page-bonus .card, #page-export .card, #page-logs .card { padding: 0 14px 14px; }



  #page-system .card > .card-title,



  #page-bonus .card > .card-title,



  #page-export .card > .card-title,



  #page-logs .card > .card-title { margin-left: -14px; margin-right: -14px; }



}







/* V18.3 新增常用物料弹窗：竖排布局 */



.lib-field { display:flex; flex-direction:column; gap:6px; }



.lib-field label { font-size:13px; color:#555; font-weight:600; }



.lib-field label em { color:#e5484d; font-style:normal; margin-left:2px; }



.lib-field .input { width:100%; }



.lib-field-row { display:flex; gap:12px; }



.lib-field-row .lib-field { flex:1; }







.badge-cust {



  display: inline-block;



  background: #f1efed;



  color: #332C2B;



  font-size: 12px;



  padding: 2px 8px;



  border-radius: 6px;



  font-weight: 600;



  white-space: nowrap;



}



.lib-tier-row .input { padding: 8px 10px !important; font-size: 13px; }











/* 客户管理：客户组/门店 分组层级展示 */



.customer-list { display: block; }



.cust-group { margin-bottom: 26px; }



.cust-group-title {



  font-size: 12px; font-weight: 700; color: #8a8a9a;



  letter-spacing: 1px; margin-bottom: 12px;



  padding-left: 10px; border-left: 3px solid #7B5CF0;



  display: flex; align-items: center; justify-content: space-between;



}



.cust-group-title .gcount { font-weight: 400; color: #b0b0bf; font-size: 11px; }



.cust-parent { border: 1.5px solid #a98fe8 !important; box-shadow: 0 3px 16px rgba(123,92,240,.14); }

.cust-parent-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 4px; }



.cust-children {



  margin: 8px 0 4px 16px; padding: 4px 0 4px 16px;



  border-left: 2px dashed #e0d9f5;



  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;



}



.indep-wrap { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }



.cust-child { background: #fafbff; border-color: #ecebf5 !important; }



.cust-child .item-name { font-size: 14px; }



.cust-arrow { color: #b9a7f0; font-size: 14px; margin-right: 2px; }











/* 常用物料库：客户组/客户 分组卡片 */



.lib-group-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 20px; cursor: pointer; box-shadow: var(--sh); transition: all .2s; }



.lib-group-card:hover { border-color: var(--brand); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,.08); }



.lib-group-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }



.lib-group-icon { width: 46px; height: 46px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 20px; }



.lib-group-name { font-size: 15px; font-weight: 700; }



.lib-group-sub { font-size: 12px; color: #888; margin-top: 3px; }



.lib-group-foot { display: flex; align-items: center; justify-content: space-between; border-top: 1px dashed var(--line); padding-top: 12px; font-size: 12px; color: #888; }



.lib-arrow { color: var(--brand); font-weight: 700; }







/* V18.14 中文日期选择组件 */



.dpick { position: relative; display: inline-flex; vertical-align: middle; }



.dpick .dpick-text { cursor: pointer; }



.dpick-native { position: absolute; left: 0; top: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; border: 0; padding: 0; }



.dpick-text.dpick-empty { color: #999; }







/* ========== 工作台看板 ========== */



.dash-wrap { max-width: 1060px; padding-top: 26px; }



.dash-hello { margin-bottom: 20px; }



.dh-title { font-size: 24px; font-weight: 800; color: var(--ink); letter-spacing: .5px; }



.dh-sub { margin-top: 6px; font-size: 13px; color: var(--ink-3); }



.dash-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 20px; }



.dash-stat {



  background: var(--card); border: 1px solid var(--line); border-radius: 18px;



  padding: 18px 18px 16px; box-shadow: var(--sh); position: relative; overflow: hidden;



}
.dash-stat.clickable:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}




.dash-stat::before { display:none; }



.dash-stat.tone-brand::before { background:#332C2B; }



.dash-stat.tone-ok::before { background: var(--ok); }



.dash-stat.tone-info::before { background:#A1A1A1; }



.dash-stat.tone-warn::before { background: var(--warn); }



.ds-label { font-size: 12.5px; color: var(--ink-3); font-weight: 600; }



.ds-val { margin-top: 8px; font-size: 26px; font-weight: 800; color: var(--ink); letter-spacing: -.5px; line-height: 1.1; }



.ds-sub { margin-top: 7px; font-size: 12px; color: var(--ink-3); }







/* 待办容器：3列网格布局 */
#dashTodo { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; width: 100%; box-sizing: border-box; }

/* 待办 */



.dash-todo {

  display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px;

  border-radius: 14px; border: 1px solid transparent; width: 100%; box-sizing: border-box; overflow: hidden;

}



.dash-todo.warn { background: var(--warn-soft); border-color: #f3d9c8; }



.dash-todo.danger { background: var(--danger-soft); border-color: #f2caca; }



.dt-ic { width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0; display:flex; align-items:center; justify-content:center; font-size: 13px; font-weight: 800; color:#fff; }



.dash-todo.warn .dt-ic { background: var(--warn); }



.dash-todo.danger .dt-ic { background: var(--danger); }



.dt-body { flex: 1; min-width: 0; }



.dt-t { font-size: 14px; font-weight: 700; color: var(--ink); }



.dt-d { margin-top: 3px; font-size: 12.5px; color: var(--ink-2); line-height: 1.5; word-break: break-all; }



.dt-btn { flex-shrink: 0; font-size: 12.5px; font-weight: 700; color: var(--ink-2); text-decoration: none; border: 1px solid var(--line-2); padding: 6px 12px; border-radius: 999px; background:#fff; }







/* 本月构成 */



.dm-bars { display: flex; flex-direction: column; gap: 12px; }



.dm-bar { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--ink-2); }



.dm-bar span { width: 34px; flex-shrink: 0; font-weight: 600; }



.dm-bar b { width: 42px; text-align: right; font-size: 13px; color: var(--ink); flex-shrink: 0; }



.dm-track { flex: 1; height: 10px; border-radius: 999px; background: var(--bg); overflow: hidden; }



.dm-fill { height: 100%; border-radius: 999px; }



.dm-fill.b-design { background: #332C2B; }



.dm-fill.b-material { background: #A1A1A1; }



.dm-nums { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }



.dm-n { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); flex-wrap: wrap; }



.dm-n b { color: var(--ink); font-size: 14px; }



.dot { width: 8px; height: 8px; border-radius: 50%; display:inline-block; }



.dot.d-design { background:#332C2B; }



.dot.d-material { background:#A1A1A1; }



.dot.d-total { background: var(--ink-2); }







/* 排行列表 */



.dash-rank { display: flex; flex-direction: column; }



.dash-rank-row { display: flex; align-items: center; gap: 12px; padding: 11px 4px; border-bottom: 1px solid var(--line); }



.dash-rank-row:last-child { border-bottom: none; }



.medal, .rank-no { width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0; display:flex; align-items:center; justify-content:center; font-size: 12.5px; font-weight: 800; font-style: normal; }



.medal.m1 { background:#332C2B; color:#fff; }



.medal.m2 { background:#A1A1A1; color:#fff; }



.medal.m3 { background:#cfcbc6; color:#fff; }



.rank-no { background: var(--bg); color: var(--ink-3); }



.dash-rank-row .rr-name { font-size: 14px; font-weight: 600; color: var(--ink); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }



.dash-rank-row .rr-sub { font-size: 12px; color: var(--ink-3); flex-shrink: 0; max-width: 42%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }



.dash-rank-row .rr-val { font-size: 14px; font-weight: 800; color: var(--brand); flex-shrink: 0; }



.type-tag { font-style: normal; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 999px; flex-shrink: 0; }



.type-tag.td { background: var(--brand-soft); color: #332C2B; }



.type-tag.tm { background: #ecebe9; color: var(--ink-2); }



.danger-txt { color: var(--danger) !important; }







/* 移动端适配 */



@media (max-width: 720px) {



  .dash-wrap { padding: 16px 14px 24px; }



  .dh-title { font-size: 20px; }



  .dash-stats { grid-template-columns: repeat(2, 1fr); gap: 10px; }



  .dash-stat { padding: 14px 14px 12px; border-radius: 16px; }



  .ds-val { font-size: 22px; }



  .dash-rank-row .rr-sub { max-width: 40%; }



}







/* 辅助图形点缀（品牌波点阵） */



.dash-wrap { position: relative; }



.dash-deco { position: absolute; top: -4px; right: 0; width: 230px; pointer-events: none; }



@media (max-width: 720px){



  .dash-deco { width: 130px; opacity: .55; top: 2px; }



}





/* 申报/验收/物料库 浅色主操作按钮（浅薄荷绿，简洁圆润无光晕） */

.btn-apply {

  background: #e6f5ec;

  color: #1f7a4f;

  border-radius: 12px;

  border: 1px solid rgba(31,122,79,.14);

  box-shadow: none;

  display: inline-flex; align-items: center; justify-content: center; gap: 5px;

  padding: 9px 18px; font-size: 13px; font-weight: 600;

  transition: all .18s; white-space: nowrap; cursor: pointer;

}

.btn-apply:hover { background: #d8edde; }

.btn-apply:active { transform: scale(.97); }



/* 统计卡片内边距（内容未包 card-body 时使用） */

.card.card-pad { padding: 0 20px 20px; }

.card.card-pad .card-title { margin: 0 -20px; }

@media (max-width: 768px) {

  .card.card-pad { padding: 0 16px 16px; }

  .card.card-pad .card-title { margin: 0 -16px; }

}



/* 设计师操作按钮一排（桌面端 + 移动端） */

#designerGrid .item-actions { flex-wrap: nowrap; }

#designerGrid .item-actions .btn { flex: 0 0 auto; min-width: 0; padding: 7px 12px; font-size: 12px; white-space: nowrap; }

@media (max-width: 768px) {

  #designerGrid .item-actions .btn { flex: 1; padding: 6px 3px; font-size: 11px; text-align: center; }

}



@media (max-width: 768px) {

  .container { padding-bottom: 80px; }

  .container.dash-wrap { padding-bottom: 24px; }

}



/* ===== 系统 / 操作日志 / 导出Excel 三页面卡片内边距（避免文字贴白框边） ===== */

#page-system .card,

#page-logs .card,

#page-export .card { padding: 20px 22px; }



/* ===== 设计师移动端底部留白（tabs 更高，单独调宽） ===== */

@media (max-width: 768px) {

  .ds-page .container { padding-bottom: 96px; }

}



/* 工作台·项目流程看板（一帧 VI 风格） */
.flow-bar{display:flex;align-items:center;gap:10px;background:#f6f7f9;border-radius:12px;padding:12px 16px;flex-wrap:wrap}
.flow-step{flex:1;min-width:64px;text-align:center;font-size:13px;font-weight:700;color:#b9b3ae;background:#fff;border:1px solid #ece6e1;border-radius:10px;padding:9px 6px;transition:all .3s}
.flow-step.done{color:#fff;background:linear-gradient(135deg,#332C2B,#5a4f4a);border-color:#332C2B;box-shadow:0 3px 10px rgba(51,44,43,.18)}
.flow-arrow{color:#c9c2bc;font-weight:700;flex:none}

/* ===== 站内通知铃铛 ===== */
.notify-wrap { position: relative; }
.notify-btn { position: relative; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--ink-2); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all .2s; }
.notify-btn:hover { color: var(--brand); border-color: var(--brand); }
.notify-btn .sico { width: 19px; height: 19px; }
.notify-badge { position: absolute; top: -3px; right: -3px; min-width: 18px; height: 18px; border-radius: 9px; background: #e05454; color: #fff; font-size: 11px; font-weight: 700; align-items: center; justify-content: center; padding: 0 4px; box-shadow: 0 2px 6px rgba(224,84,84,.4); }
.notify-panel { position: absolute; right: 0; top: 48px; width: 330px; max-width: calc(100vw - 24px); max-height: 430px; overflow: auto; background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--sh-lg); display: none; z-index: 200; }
.notify-panel.show { display: block; animation: ddIn .16s ease; }
.notify-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); font-weight: 700; font-size: 14px; }
.notify-readall { border: none; background: none; color: var(--brand); font-size: 13px; cursor: pointer; padding: 2px 4px; }
.notify-readall:hover { text-decoration: underline; }
.notify-list { padding: 4px 0; }
.notify-item { padding: 10px 16px; border-bottom: 1px solid var(--line); cursor: default; }
.notify-item:last-child { border-bottom: none; }
.notify-item.read { opacity: .6; }
.notify-item .n-t { font-size: 13px; font-weight: 700; color: var(--ink); }
.notify-item .n-c { font-size: 12px; color: var(--ink-2); margin-top: 3px; line-height: 1.45; }
.notify-item .n-time { font-size: 11px; color: var(--ink-3); margin-top: 4px; }
.notify-empty { padding: 32px; text-align: center; color: var(--ink-3); font-size: 13px; }
@media (max-width: 640px) {
  .notify-panel { right: -10px; }
}


/* ===== 桌面端：tabs 全部换行显示，避免右侧功能被隐藏 ===== */
@media (min-width: 769px) {
  .tabs { flex-wrap: wrap !important; overflow: visible !important; height: auto !important; }
  .tabs .tab { flex-shrink: 0; }
}



/* ===== 桌面端：顶部通栏 + 左侧边栏导航（阿里云式） ===== */
@media (min-width: 769px) {
  /* 顶部通栏拉满左右：body 不再左移 */
  .adm-page, .ds-page, .fin-page { padding-left: 0 !important; }
  .adm-page .header-top, .ds-page .header-top, .fin-page .header-top {
    max-width: none !important; margin: 0 !important;
  }
  /* 侧边栏：从 header 下方开始，缩窄至 200px */
  .adm-page .tabs, .ds-page .tabs, .fin-page .tabs {
    position: fixed !important; left: 0 !important; top: 63px !important; bottom: 0 !important;
    right: auto !important; width: 150px !important; height: auto !important;
    flex-direction: column !important; align-items: stretch !important; justify-content: flex-start !important;
    flex-wrap: nowrap !important; overflow-y: auto !important; overflow-x: hidden !important;
    background: linear-gradient(180deg, #2d2725 0%, #332C2B 45%, #3b3330 100%) !important;
    background-color: #332C2B !important;
    border-bottom: none !important; border-right: 1px solid rgba(255,255,255,.06);
    padding: 18px 12px !important; gap: 4px !important; z-index: 99 !important;
  }
  /* 去掉侧边栏内品牌文字 */
  .adm-page .tabs::before, .ds-page .tabs::before, .fin-page .tabs::before { display: none !important; }
  .adm-page .tabs .tab, .ds-page .tabs .tab, .fin-page .tabs .tab {
    display: flex; align-items: center; gap: 10px;
    width: 100%; padding: 11px 14px; border-radius: 10px;
    color: rgba(255,255,255,.7); font-size: 13.5px; font-weight: 600;
    white-space: nowrap; margin: 0; flex-shrink: 0; letter-spacing: .2px;
  }
  .adm-page .tabs .tab .sico, .ds-page .tabs .tab .sico, .fin-page .tabs .tab .sico { width: 18px; height: 18px; flex: none; }
  .adm-page .tabs .tab:hover, .ds-page .tabs .tab:hover, .fin-page .tabs .tab:hover { color: #fff; background: rgba(255,255,255,.07); }
  .adm-page .tabs .tab.active, .ds-page .tabs .tab.active, .fin-page .tabs .tab.active {
    color: #fff; background: linear-gradient(135deg, #57504c, #403836);
    box-shadow: 0 6px 16px rgba(0,0,0,.28);
  }
  .adm-page .tabs .tab.active::after, .ds-page .tabs .tab.active::after, .fin-page .tabs .tab.active::after { display: none; }
  /* 覆盖强制浅色模式（html[data-force-light]）对侧边栏的影响 */
  html[data-force-light] .adm-page .tabs, html[data-force-light] .ds-page .tabs, html[data-force-light] .fin-page .tabs {
    background: linear-gradient(180deg, #2d2725 0%, #332C2B 45%, #3b3330 100%) !important;
    background-color: #332C2B !important;
    border-bottom: none !important;
  }
  html[data-force-light] .adm-page .tabs .tab, html[data-force-light] .ds-page .tabs .tab, html[data-force-light] .fin-page .tabs .tab {
    color: rgba(255,255,255,.7) !important;
  }
  html[data-force-light] .adm-page .tabs .tab:hover, html[data-force-light] .ds-page .tabs .tab:hover, html[data-force-light] .fin-page .tabs .tab:hover {
    color: #fff !important; background: rgba(255,255,255,.07) !important;
  }
  html[data-force-light] .adm-page .tabs .tab.active, html[data-force-light] .ds-page .tabs .tab.active, html[data-force-light] .fin-page .tabs .tab.active {
    color: #fff !important; background: linear-gradient(135deg, #57504c, #403836) !important;
  }
  /* 内容区右移 200px 占满剩余宽度 */
  .adm-page .container, .ds-page .container, .fin-page .container {
    max-width: none !important; margin: 0 0 0 150px !important;
    padding: 22px 30px 48px !important;
  }
  .adm-page .container.dash-wrap, .ds-page .container.dash-wrap, .fin-page .container.dash-wrap {
    margin-left: 0 !important; max-width: none !important; width: 100% !important;
  }

  .adm-page .dash-wrap, .ds-page .dash-wrap, .fin-page .dash-wrap { max-width: none !important; }
}


/* ===== 工作台可拖拽布局（看板自定义） ===== */
.dash-toolbar { display: flex; justify-content: flex-end; margin: -8px 0 12px; }
.dash-toolbar #dashEditBtn { border-radius: 12px; padding: 7px 16px; font-size: 13px; }
@media (min-width: 769px) {
  .adm-page .dash-wrap.dash-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; }
  .adm-page .dash-grid > .dash-hello, .adm-page .dash-grid > .dash-toolbar { grid-column: 1 / -1; }
  .adm-page .dash-grid > .card, .adm-page .dash-grid > .dash-stats, .adm-page .dash-grid > .dash-hello { margin-bottom: 0; }
  .adm-page .dash-grid > [data-wid] { grid-column: 1 / -1; min-width: 0; }
  .adm-page .dash-grid > [data-wid][data-col="3"] { grid-column: span 3; }
  .adm-page .dash-grid > [data-wid][data-col="4"] { grid-column: span 4; }
  .adm-page .dash-grid > [data-wid][data-col="5"] { grid-column: span 5; }
  .adm-page .dash-grid > [data-wid][data-col="6"] { grid-column: span 6; }
  .adm-page .dash-grid > [data-wid][data-col="7"] { grid-column: span 7; }
  .adm-page .dash-grid > [data-wid][data-col="8"] { grid-column: span 8; }
  .adm-page .dash-grid > [data-wid][data-col="9"] { grid-column: span 9; }
  .adm-page .dash-grid > [data-wid][data-col="10"] { grid-column: span 10; }
  .adm-page .dash-grid > [data-wid][data-col="11"] { grid-column: span 11; }
  /* 编辑模式 */
  .adm-page .dash-grid.dash-editing > [data-wid] { outline: 2px dashed rgba(51,44,43,.3); outline-offset: 2px; border-radius: 18px; cursor: grab; position: relative; transition: box-shadow .15s; }
  .adm-page .dash-grid.dash-editing > [data-wid]:hover { outline-color: #332C2B; box-shadow: 0 6px 18px rgba(51,44,43,.12); }
  .adm-page .dash-grid.dash-editing > [data-wid].dragging { opacity: .5; outline-color: #332C2B; }
  .dash-resize { display: none; position: absolute; right: 6px; bottom: 6px; width: 22px; height: 22px; cursor: nwse-resize; color: #332C2B; background: rgba(255,255,255,.9); border: 1px solid rgba(51,44,43,.18); border-radius: 6px; align-items: center; justify-content: center; z-index: 5; }
  .dash-resize svg { display: block; }
  .adm-page .dash-grid.dash-editing .dash-resize { display: flex; }
}
@media (max-width: 768px) {
  .adm-page .dash-wrap.dash-grid { display: block; }
  .adm-page .dash-grid > .card, .adm-page .dash-grid > .dash-stats, .adm-page .dash-grid > .dash-hello { margin-bottom: 16px; }
  .adm-page .dash-grid > :last-child { margin-bottom: 0; }
}

.dash-drop-line { position: absolute; left: 6px; right: 6px; height: 4px; background: #332C2B; border-radius: 3px; z-index: 10; pointer-events: none; box-shadow: 0 0 0 3px rgba(51,44,43,.12); }

/* ===== 侧边栏导航分组分隔线 ===== */
.nav-group {
  height: 1px; min-height: 1px;
  margin: 12px 14px 8px;
  background: rgba(255,255,255,.16);
  flex: none;
  user-select: none; -webkit-user-select: none;
}
@media (max-width: 768px) { .nav-group { display: none; } }

/* ===== 工作台布局编辑圆形按钮（header） ===== */
.dash-edit-icon { position: relative; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); color: var(--ink-2); display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all .2s; flex: none; }
.dash-edit-icon:hover { color: var(--brand); border-color: var(--brand); }
.dash-edit-icon.active { color: var(--brand); border-color: var(--brand); background: rgba(51,44,43,.06); }
.dash-edit-icon .sico { width: 18px; height: 18px; }
@media (max-width: 768px) { .dash-edit-icon { width: 34px; height: 34px; } .dash-edit-icon .sico { width: 16px; height: 16px; } }

/* 报价清单 / 项目明细 页面铺满（与申报验收同宽） */
@media (min-width: 769px) {
  #page-quote > .container.dash-wrap, #page-projects > .container.dash-wrap {
    padding-left: 0 !important; padding-right: 0 !important; padding-top: 0 !important;
  }
}
/* ===== 设计项目看板 · VI 卡片 ===== */
.proj-card{background:#fff;border:1px solid #f0eeeb;border-radius:16px;padding:16px 18px;cursor:pointer;transition:box-shadow .25s,transform .2s,border-color .25s}
.proj-card:hover{box-shadow:0 10px 28px rgba(51,44,43,.10);transform:translateY(-2px);border-color:#e5e0db}
.proj-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;flex-wrap:wrap}
.proj-head-l{min-width:0}
.proj-name{font-size:16px;font-weight:800;color:#332C2B;letter-spacing:.2px}
.proj-cust{font-size:12px;color:#9a928d;margin-top:4px;display:flex;align-items:center;gap:5px;flex-wrap:wrap}
.proj-cust .proj-ico{width:13px;height:13px;color:#b3aca6;flex-shrink:0}
.proj-recent{font-size:12px;color:#e2703a;font-weight:600;background:#fdf1ea;border:1px solid #f7ddce;padding:3px 10px;border-radius:999px;white-space:nowrap}
.proj-stats{display:flex;gap:8px;margin-top:14px;flex-wrap:wrap}
.proj-stat{flex:1;min-width:70px;background:#faf8f6;border:1px solid #f0edeb;border-radius:12px;padding:10px 8px;text-align:center;box-sizing:border-box}
.proj-stat .proj-num{font-size:17px;font-weight:800;color:#332C2B;white-space:nowrap}
.proj-stat .proj-lb{font-size:11px;color:#9a928d;margin-top:2px}
.proj-stat-amt{background:#332C2B;border-color:#332C2B}
.proj-stat-amt .proj-num{color:#fff}
.proj-stat-amt .proj-lb{color:#c9b8a7}
.proj-foot{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-top:13px;padding-top:12px;border-top:1px dashed #eee9e5}
.proj-foot-l,.proj-foot-r{display:flex;align-items:center;gap:6px;flex-wrap:wrap;font-size:12px;color:#6f6762}
.proj-ico{width:14px;height:14px;color:#b3aca6;flex-shrink:0}
.proj-foot-t{color:#9a928d;margin-right:2px}
.proj-tag{display:inline-block;font-size:11px;color:#6f6762;background:#f4f1ee;border:1px solid #ebe6e1;padding:2px 8px;border-radius:999px;white-space:nowrap}
.proj-tag-more{color:#e2703a;background:#fdf1ea;border-color:#f7ddce}
.proj-tag-amt{color:#e2703a;background:#fdf1ea;border-color:#f7ddce;font-weight:700}
.proj-tag-des{color:#332C2B;background:#ece7e2;border-color:#e0d9d2;font-weight:600}
.proj-tag-mat{color:#8a5a2b;background:#f7ecdd;border-color:#eeddbf;font-weight:600}
.proj-muted{color:#c2bbb5}
/* 项目详情弹窗 */
.proj-detail-head{padding:2px 2px 6px}
.proj-detail-name{font-size:18px;font-weight:800;color:#332C2B}
.proj-detail-cust{font-size:12px;color:#9a928d;margin-top:3px}
.proj-detail-sum{display:flex;gap:8px;margin-top:14px;flex-wrap:wrap}
.proj-detail-sum .pds{flex:1;min-width:66px;background:#faf8f6;border:1px solid #f0edeb;border-radius:12px;padding:10px 8px;text-align:center;box-sizing:border-box}
.proj-detail-sum .pds b{display:block;font-size:16px;font-weight:800;color:#332C2B;white-space:nowrap}
.proj-detail-sum .pds span{font-size:11px;color:#9a928d}
.proj-detail-sum .pds-amt{background:#332C2B;border-color:#332C2B}
.proj-detail-sum .pds-amt b{color:#fff}
.proj-detail-sum .pds-amt span{color:#c9b8a7}
.proj-sec{margin-top:16px}
.proj-sec-t{font-size:13px;font-weight:700;color:#332C2B;margin-bottom:9px;display:flex;align-items:center;gap:6px}
.proj-sec-t span{font-size:11px;color:#e2703a;background:#fdf1ea;border:1px solid #f7ddce;border-radius:999px;padding:0 8px;font-weight:700}
.proj-row{border:1px solid #f0eeeb;border-radius:14px;padding:12px 14px;margin-bottom:9px;background:#fff}
.proj-row-top{display:flex;justify-content:space-between;align-items:flex-start;gap:8px;flex-wrap:wrap}
.proj-row-name{font-weight:700;color:#332C2B;font-size:14px}
.proj-row-date{font-size:12px;color:#9a928d;white-space:nowrap}
.proj-row-sub{font-size:12px;color:#6f6762;margin-top:4px}
.proj-row-tags{display:flex;gap:6px;flex-wrap:wrap;margin-top:8px}
.proj-row-note{font-size:12px;color:#8a817b;background:#faf8f6;border-radius:8px;padding:6px 10px;margin-top:8px}
.proj-row-imgs{display:flex;gap:6px;flex-wrap:wrap;margin-top:9px}
.proj-thumb{width:52px;height:52px;object-fit:cover;border-radius:10px;border:1px solid #eee9e5;cursor:zoom-in}
.proj-empty{color:#9a928d;text-align:center;padding:36px 0}
@media (max-width:640px){ .proj-stat{min-width:30%} .proj-detail-sum .pds{min-width:30%} }

/* ===== 用户管理：设计师操作按钮防溢出 ===== */
#designerGrid .item-actions{flex-wrap:wrap!important}
#designerGrid .item-actions .btn{flex:1 1 auto;min-width:0;padding:7px 10px;font-size:12px;white-space:nowrap;justify-content:center;box-sizing:border-box}
@media (max-width:768px){ #designerGrid .item-actions .btn{flex:1 1 0;padding:6px 3px;font-size:11px;text-align:center} }
/* 设计师网格加宽：让 4 个操作按钮完整排在一行 */
#designerGrid{grid-template-columns:repeat(auto-fill,minmax(300px,1fr))!important}
/* ===== 应收账款 / 欠账 ===== */
.cust-debt-tag{display:flex;align-items:center;gap:8px;margin-top:10px;background:#fdf0ec;border:1px solid #f5d7cb;border-radius:10px;padding:7px 12px}
.debt-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:10px 12px;background:#faf9f7;border-radius:10px;margin-bottom:8px}
.debt-main{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.debt-remain{font-size:12px;font-weight:700;color:#e2703a;background:#fdeee5;padding:2px 8px;border-radius:8px}
.debt-sub{font-size:12px;color:#888;flex:1;min-width:120px}
.debt-actions{display:flex;gap:6px}
/* ===== 项目明细层级树 ===== */
.proj-cust{border:1px solid #eee8e2;border-radius:14px;margin-bottom:10px;overflow:hidden;background:#fff}
.proj-cust-head{display:flex;align-items:center;gap:8px;padding:13px 16px;cursor:pointer;background:linear-gradient(135deg,#332C2B,#4a423f);color:#fff;transition:background .2s}
.proj-cust-head:hover{background:linear-gradient(135deg,#3b3431,#57504c)}
.pt-arrow{font-size:12px;color:rgba(255,255,255,.75);width:14px;flex:0 0 auto}
.proj-cust-name{font-weight:800;font-size:15px;flex:0 0 auto}
.proj-new{background:#e2703a;color:#fff;font-size:11px;font-weight:800;padding:2px 8px;border-radius:10px;flex:0 0 auto;animation:projNewPulse 1.2s infinite}
@keyframes projNewPulse{0%,100%{opacity:1}50%{opacity:.6}}
.proj-cust-meta{margin-left:auto;font-size:12px;color:rgba(255,255,255,.7);text-align:right}
.proj-cust-body{padding:6px 0}
.proj-item{border-bottom:1px solid #f4efe9}
.proj-item:last-child{border-bottom:none}
.proj-item-head{display:flex;align-items:center;gap:8px;padding:12px 20px 12px 34px;cursor:pointer;transition:background .15s}
.proj-item-head:hover{background:#f8f6f3}
.proj-item-name{font-weight:700;color:#332C2B;font-size:14px;flex:0 0 auto}
.proj-item-meta{font-size:12px;color:#999;white-space:nowrap}
.proj-item-des{display:flex;gap:4px;margin-left:auto;flex-wrap:wrap;justify-content:flex-end}
.proj-item-body{padding:6px 20px 12px 44px;background:#fbfaf8}
.proj-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:9px 12px;border-radius:10px;background:#fff;border:1px solid #f1ece6;margin-bottom:6px}
.proj-row-name{font-weight:600;color:#332C2B;font-size:13px;min-width:80px}
.proj-row-des{color:#888;font-size:12px;min-width:50px}
.proj-row-date{color:#aaa;font-size:12px}
.proj-row-amt{color:#e2703a;font-weight:800;font-size:13px}
.proj-row-note{color:#999;font-size:12px;max-width:220px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.proj-thumb{width:42px;height:42px;object-fit:cover;border-radius:8px;cursor:pointer;border:1px solid #eee}
.proj-loading{color:#aaa;font-size:13px;padding:10px 0;text-align:center}
@media(max-width:640px){
  .proj-cust-head{flex-wrap:wrap;padding:12px 12px}
  .proj-cust-meta{width:100%;text-align:left;padding-left:22px}
  .proj-item-head{flex-wrap:wrap;padding:10px 12px 10px 24px}
  .proj-item-des{width:100%;justify-content:flex-start;padding-left:22px}
  .proj-item-body{padding:6px 10px 10px 24px}
  .proj-row-note{max-width:100%}
}

/* 客户组门店：桌面一排自适应；窄屏自动换行不挤压 */
@media (max-width: 900px){
  .cust-children{ grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
}
@media (max-width: 640px){
  .cust-children{ grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
}

/* 物料表格操作列按钮一排 */
.op-cell{white-space:nowrap}
.op-cell .btn-sm{margin:0 2px;padding:6px 10px}


/* ===== 记录/明细 按公司分组行（2026-09-04）===== */

tr.group-row td{background:#f4f1ed;padding:9px 14px !important;border-top:2px solid #e6dfd6;border-bottom:2px solid #e6dfd6;font-size:13px}

tr.group-row .grp-name{font-weight:700;color:#332C2B;font-size:14px;margin-right:12px}

tr.group-row .grp-meta{font-size:12px;color:#8a7f74}

@media (max-width:768px){

  .table-wrap.mobile-card tr.group-row{background:#f4f1ed;border:1px solid #e2dbd2;box-shadow:none;padding:10px 14px;margin-bottom:10px}

  .table-wrap.mobile-card tr.group-row td{display:block;text-align:left;padding:2px 0;border:none}

  .table-wrap.mobile-card tr.group-row td::before{display:none !important}

}



/* ===== 设计师端 按客户分组（2026-09-04）===== */

.dsg-group{background:#f4f1ed;border-radius:12px;padding:9px 14px;margin:6px 0 4px;display:flex;align-items:center;gap:10px;flex-wrap:wrap;border:1px solid #e6dfd6}

.dsg-name{font-weight:700;color:#332C2B;font-size:14px}

.dsg-meta{font-size:12px;color:#8a7f74}



/* 工作台待办提醒横版排列覆盖 */
#dashTodo .dash-todo {
    width: 100% !important;
    margin: 0 !important;
}

/* ===== 客户管理卡片：母卡片正方形、子卡片一排4个正方形（2026-09-09） ===== */
.cust-parent-grid .cust-parent { aspect-ratio: 1 / 1; }
.cust-children { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
.cust-children .item-card { aspect-ratio: 1 / 1; }
.cust-parent-grid, .indep-wrap { grid-template-columns: repeat(3, 1fr) !important; }
@media (max-width: 900px){
  .cust-parent-grid .cust-parent, .cust-children .item-card { aspect-ratio: auto !important; }
}
@media (min-width: 481px) and (max-width: 900px){
  .cust-children, .cust-parent-grid, .indep-wrap { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
}
@media (max-width: 480px){
  .cust-children, .cust-parent-grid, .indep-wrap { grid-template-columns: 1fr !important; }
}

/* ===== 客户卡片恢复之前样式：一排3个长方形（2026-09-09 用户确认） ===== */
.cust-parent-grid .cust-parent { aspect-ratio: auto !important; }
.cust-children .item-card { aspect-ratio: auto !important; }
.cust-children { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.cust-parent-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.indep-wrap { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
@media (max-width: 900px){
  .cust-children { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)) !important; }
}
@media (max-width: 768px){
  .cust-children { grid-template-columns: 1fr !important; }
}

/* ===== 客户卡片内容防溢出：stats 2x2、按钮自适应（2026-09-09 用户要求内容全在卡片内） ===== */
.cust-parent-grid .item-stats, .cust-children .item-stats, .indep-wrap .item-stats{
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 6px 12px !important;
  margin-top: 10px !important;
}
.cust-parent-grid .item-stats .stat-item, .cust-children .item-stats .stat-item, .indep-wrap .item-stats .stat-item{
  min-width: 0 !important;
  padding: 8px 4px !important;
  background: #f7f8fc !important;
  border-radius: 10px !important;
  box-shadow: 0 1px 3px rgba(30,30,60,.06) !important;
  text-align: center !important;
  flex: 1 !important;
}
.cust-parent-grid .item-stats .k, .cust-children .item-stats .k, .indep-wrap .item-stats .k{
  font-size: 10px !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  color: #8a8a9a !important;
}
.cust-parent-grid .item-stats .v, .cust-children .item-stats .v, .indep-wrap .item-stats .v{
  font-size: 14px !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}
.cust-parent-grid .item-card, .cust-children .item-card, .indep-wrap .item-card{
  min-width: 0 !important;
  overflow: hidden !important;
}
.cust-parent-grid .item-actions, .cust-children .item-actions, .indep-wrap .item-actions{
  flex-wrap: wrap !important;
  gap: 6px !important;
  margin-top: 10px !important;
}
.cust-parent-grid .item-actions .btn, .cust-children .item-actions .btn, .indep-wrap .item-actions .btn{
  flex: 1 1 auto !important;
  min-width: 0 !important;
  padding: 6px 8px !important;
  font-size: 12px !important;
  white-space: nowrap !important;
  text-align: center !important;
}

/* 客户卡片六排布局：地址并入电话行 */
.cust-parent-grid .cust-addr, .cust-children .cust-addr, .indep-wrap .cust-addr{
  font-size: 12px !important;
  color: #888 !important;
  word-break: break-all !important;
  line-height: 1.5 !important;
}
.cust-parent-grid .contact-tag, .cust-children .contact-tag, .indep-wrap .contact-tag{
  white-space: nowrap !important;
}

/* 客户卡片六排布局：电话+地址同一排 */
.cust-parent-grid .item-sub, .cust-children .item-sub, .indep-wrap .item-sub{
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 4px 8px !important;
  margin-top: 6px !important;
}

/* 客户卡片六排布局：第一排商标+名称+提成，第二排联系方式+地址 */
.cust-parent-grid .item-header, .cust-children .item-header, .indep-wrap .item-header{
  flex-wrap: wrap !important;
  align-items: flex-start !important;
}
.cust-parent-grid .item-sub, .cust-children .item-sub, .indep-wrap .item-sub{
  flex-basis: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-top: 4px !important;
}
.cust-parent-grid .item-name, .cust-children .item-name, .indep-wrap .item-name{
  line-height: 1.6 !important;
}

/* 客户卡片第一排紧凑：标签收进名称行 */
.cust-parent-grid .item-header, .cust-children .item-header, .indep-wrap .item-header{
  gap: 8px !important;
}
.cust-parent-grid .item-header span, .cust-children .item-header span, .indep-wrap .item-header span{
  font-size: 9px !important;
  line-height: 1.4 !important;
}
.cust-parent-grid .item-avatar, .cust-children .item-avatar, .indep-wrap .item-avatar{
  flex-shrink: 0 !important;
}

/* ===== 页面间距统一：无 container 包裹的 page 与 .container 对齐 ===== */
#page-records,#page-designs,#page-materials,#page-customers,#page-designers,#page-stats,#page-detail,#page-apply,#page-export,#page-system{
  padding: 22px 24px 40px;
  box-sizing: border-box;
}
@media (max-width: 768px){
  #page-records,#page-designs,#page-materials,#page-customers,#page-designers,#page-stats,#page-detail,#page-apply,#page-export,#page-system{
    padding: 10px 8px;
  }
}


/* ===== 工作台/经营周报与记录管理页同款：铺满内容区，间距 22/24/40（桌面） ===== */
#page-weekly .weekly-wrap{ max-width: none !important; }
@media (min-width: 769px){
  #page-weekly .weekly-wrap{
    margin: 0 !important;
    padding: 22px 24px 40px !important;
    max-width: none !important;
  }
  #page-dashboard > .container.dash-wrap{
    margin: 0 !important;
    padding: 22px 24px 40px !important;
    max-width: none !important;
  }
}

/* ===== 数据明细页卡片间距统一（横竖一致 16px） ===== */
#page-stats .card { margin-bottom: 16px; }
#page-stats .stat-cards { gap: 16px; margin-bottom: 16px; }
#page-stats .chart-row { gap: 16px; margin-bottom: 16px; }
/* ===== 记录管理 · 按天查看（某日全部工单卡片）===== */
.rec-daybar{display:flex;align-items:center;gap:8px;flex-wrap:wrap;background:#fff;border:1px solid #efeae4;border-radius:14px;padding:10px 14px;margin-bottom:14px}
.rec-daybar-label{font-size:13px;font-weight:700;color:#332C2B}
.rec-daybar-hint{margin-left:auto;font-size:12px;color:#a59d96}
.rday-sum{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:14px}
.rday-sum-cell{flex:1 1 110px;min-width:104px;background:#fff;border:1px solid #efeae4;border-radius:12px;padding:10px 12px;text-align:center}
.rday-sum-n{display:block;font-size:18px;font-weight:800;color:#332C2B}
.rday-sum-t{display:block;font-size:11px;color:#9a928d;margin-top:2px}
.rday-sum-amt .rday-sum-n{color:#2e9e6c}
.rday-block{background:#fff;border:1px solid #efeae4;border-radius:14px;overflow:hidden;margin-bottom:14px}
.rday-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:11px 14px;background:linear-gradient(135deg,#faf8f5,#f4f1ec);border-bottom:1px solid #efeae4}
.rday-date{font-size:14px;font-weight:800;color:#332C2B}
.rday-week{font-size:12px;color:#8a837c}
.rday-badge{font-size:12px;font-weight:700;color:#e2703a;background:#fff2e9;border-radius:999px;padding:2px 10px}
.rday-mix,.rday-hrs{font-size:12px;color:#9a928d}
.rday-total{margin-left:auto;font-size:15px;font-weight:800;color:#2e9e6c}
.rday-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(196px,1fr));gap:12px;padding:14px 16px;background:#fbfaf8}
.rday-cards>.proj-row{margin-bottom:0;cursor:pointer}
.rday-noimg{font-size:11px;color:#c4bdb7}
.rday-foot{margin-top:4px;font-size:12px;color:#a59d96;text-align:center;padding:6px 0}
.rday-empty{background:#fff;border:1px dashed #e5ded6;border-radius:14px;padding:40px 16px;text-align:center;color:#5a534e;font-size:15px;font-weight:600}
.rday-empty span{display:block;margin-top:8px;font-size:12px;color:#b5aca6;font-weight:400}
@media (max-width:1100px){.rday-cards{grid-template-columns:repeat(auto-fill,minmax(176px,1fr))}}
@media (max-width:900px){.rec-daybar-hint{margin-left:0;width:100%}.rday-cards{grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;padding:10px}}
/* ===== 中文日期选择面板（自绘日历，替换浏览器原生日历）===== */
.dcal{position:fixed;z-index:900009;display:none;width:272px;padding:10px;background:#fff;border:1px solid #ece6df;border-radius:16px;box-shadow:0 16px 40px rgba(51,44,43,.16);font-family:"PingFang SC","Microsoft YaHei",-apple-system,"Segoe UI",sans-serif;font-size:13px;color:#332C2B;box-sizing:border-box;line-height:1.4}
.dcal.open{display:block}
.dcal-head{display:flex;align-items:center;gap:4px;margin-bottom:8px}
.dcal-nav{width:28px;height:28px;flex:0 0 28px;border:1px solid #ece6df;background:#fff;border-radius:9px;color:#8a837c;font-size:13px;line-height:1;cursor:pointer;padding:0;font-family:inherit}
.dcal-nav:hover{background:#faf8f5;color:#332C2B;border-color:#e0d8d0}
.dcal-title{flex:1 1 auto;min-width:0;height:28px;border:0;background:transparent;font-family:inherit;font-size:14px;font-weight:700;color:#332C2B;cursor:pointer;border-radius:9px;letter-spacing:.5px}
.dcal-title:hover{background:#faf8f5}
.dcal-week{display:grid;grid-template-columns:repeat(7,1fr);gap:2px;margin-bottom:4px}
.dcal-week span{text-align:center;font-size:11px;color:#b5aca6;font-weight:600;padding:2px 0}
.dcal-days{display:grid;grid-template-columns:repeat(7,1fr);gap:2px}
.dcal-d{height:32px;border:0;background:transparent;border-radius:9px;font-family:inherit;font-size:13px;color:#332C2B;cursor:pointer;padding:0;font-variant-numeric:tabular-nums}
.dcal-d:hover{background:#f6f2ed}
.dcal-out{color:#cdc5bd}
.dcal-today{box-shadow:inset 0 0 0 1px #e2703a;color:#e2703a;font-weight:700}
.dcal-sel{background:#332C2B;color:#fff;font-weight:700}
.dcal-sel:hover{background:#332C2B}
.dcal-foot{display:flex;gap:8px;margin-top:10px;padding-top:9px;border-top:1px solid #f2ece6}
.dcal-btn{flex:1;height:30px;border:1px solid #ece6df;background:#fff;border-radius:9px;font-family:inherit;font-size:13px;color:#5a534e;cursor:pointer;padding:0}
.dcal-btn:hover{background:#faf8f5;color:#332C2B}
.dcal-ym-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px}
.dcal-ym-y{font-size:14px;font-weight:700;color:#332C2B}
.dcal-months{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}
.dcal-m{height:34px;border:1px solid #f2ece6;background:#fff;border-radius:9px;font-family:inherit;font-size:13px;color:#332C2B;cursor:pointer;padding:0}
.dcal-m:hover{background:#faf8f5}
.dcal-m.dcal-sel{background:#332C2B;color:#fff;border-color:#332C2B;font-weight:700}
.dcal-mm .dcal-week{display:none}
.dpick-auto-input{cursor:pointer}
.dpick-auto-input.dpick-empty{color:#bdb4ac}
.dpick-auto-input::-webkit-calendar-picker-indicator{display:none}

/* ===== 管理后台 / 财务系统 / 设计系统：左侧导航与业务系统、制作系统完全一致（2026-09-22） ===== */
@media (min-width: 769px){
  .adm-page .tabs, .ds-page .tabs, .fin-page .tabs{
    background:#332C2B !important; background-image:none !important; border-right:0 !important;
  }
  .adm-page .tabs .tab, .ds-page .tabs .tab, .fin-page .tabs .tab{
    color:#fff !important; font-weight:500 !important;
  }
  .adm-page .tabs .tab.active, .ds-page .tabs .tab.active, .fin-page .tabs .tab.active{
    color:#fff !important; font-weight:600 !important;
  }
  html[data-force-light] .adm-page .tabs, html[data-force-light] .ds-page .tabs, html[data-force-light] .fin-page .tabs{
    background:#332C2B !important; background-image:none !important; border-right:0 !important;
  }
  html[data-force-light] .adm-page .tabs .tab, html[data-force-light] .ds-page .tabs .tab, html[data-force-light] .fin-page .tabs .tab{
    color:#fff !important; font-weight:500 !important;
  }
}

/* 头像图片统一显示（用户/客户头像，兼容老数据无扩展名图片） */
.avatar img, .user-avatar img, .hb-avatar img, .user-info .avatar img { width:100%; height:100%; object-fit:cover; border-radius:50%; display:block; }
.avatar, .user-avatar, .hb-avatar { overflow:hidden; }

/* ===== 2026-09-26 applyDeptFix =====
   申报单/验收单「物料明细」表格：各列宽度没有生效，全部被压成 150px 左右，
   导致物料名称、规格材质、交货日期都显示不全（用户反馈"编辑验收单弹窗太窄"）。
   原因：该行是 flex 布局，而全局 .input 上带 flex 属性，
   把 .m-name / .m-spec / .m-delay / .m-img 自己的 width 给覆盖掉了。
   这里显式指定 flex，让列宽按设计生效；同时把规格列加宽（它内容最长）。 */
.apply-item-row .input { flex: 0 0 auto; }
.apply-item-row .m-name  { flex: 0 0 17%; width: 17%; }
.apply-item-row .m-spec  { flex: 0 0 28%; width: 28%; }
.apply-item-row .m-qty   { flex: 0 0 62px; width: 62px; }
.apply-item-row .m-unit  { flex: 0 0 56px; width: 56px; }
.apply-item-row .m-price { flex: 0 0 74px; width: 74px; }
.apply-item-row .m-total { flex: 0 0 78px; width: 78px; }
.apply-item-row .m-img   { flex: 1 1 150px; min-width: 150px; width: auto; }
.apply-item-row .m-delay { flex: 0 0 128px; width: 128px; }
/* 表头跟随同一套宽度，避免表头和数据错位 */
.apply-items-head span:nth-child(1) { flex: 0 0 32px; width: 32px; }
.apply-items-head span:nth-child(2) { flex: 0 0 17%; width: 17%; }
.apply-items-head span:nth-child(3) { flex: 0 0 28%; width: 28%; }
.apply-items-head span:nth-child(4) { flex: 0 0 62px; width: 62px; }
.apply-items-head span:nth-child(5) { flex: 0 0 56px; width: 56px; }
.apply-items-head span:nth-child(6) { flex: 0 0 74px; width: 74px; }
.apply-items-head span:nth-child(7) { flex: 0 0 78px; width: 78px; }
.apply-items-head span:nth-child(8) { flex: 1 1 150px; min-width: 150px; }
.apply-items-head span:nth-child(9) { flex: 0 0 128px; width: 128px; }
.apply-items-head span:nth-child(10) { flex: 0 0 26px; width: 26px; }

/* ===== 2026-09-26 applyDeptFix2 =====
   申报单/验收单「物料明细」表格：窗口较窄（笔记本 1100~1500px）时，
   10 列横排会超出容器，必须拖横向滑块才能看全（用户反馈）。
   处理：在窄窗口下让明细行自动换行成两行——
         第一行：序号 / 物料名称 / 规格材质
         第二行：数量 / 单位 / 单价 / 总价 / 图片 / 交货日期 / 删除
   这样永远不需要横向滚动，信息也全都看得见。 */
@media (max-width: 1500px) {
  /* 收紧内边距与列间距，给字段让出宽度 */
  .apply-item-row {
    flex-wrap: wrap;
    align-items: flex-start;
    row-gap: 6px;
    padding: 8px;
    gap: 6px;
  }
  /* 第一行：序号(32) + 名称 + 规格 + 数量 + 单位 + 单价 + 总价
     合计固定宽度约 32+8+150+8+200+8+66+8+60+8+80+8+84 = 720，
     加各列 gap（6×6=36）后约 756，
     在 1080px 容器里还剩约 320px 给「名称+规格」弹性伸缩 → 不会溢出。 */
  /* 名称/规格给足最小宽度（内容长），但不让它俩长太大把图片列挤出去 */
  .apply-item-row .m-name { flex: 0 1 220px; width: auto; min-width: 150px; }
  .apply-item-row .m-spec { flex: 0 1 380px; width: auto; min-width: 190px; }
  .apply-item-row .m-qty   { flex: 0 0 66px;  width: 66px; }
  .apply-item-row .m-unit  { flex: 0 0 60px;  width: 60px; }
  .apply-item-row .m-price { flex: 0 0 80px;  width: 80px; }
  .apply-item-row .m-total { flex: 0 0 84px;  width: 84px; }
  /* 第二行：图片 + 交货日期 + 删除 */
  .apply-item-row .m-delay { flex: 0 0 136px; width: 136px; }
  .apply-item-row .m-img   { flex: 1 1 150px; min-width: 150px; width: auto; }
  .apply-item-row .m-rm    { flex: 0 0 26px; }
  /* 表头在小屏隐藏（换行后列会错位，隐藏更清爽） */
  .apply-items-head { display: none; }
}

/* 更窄的窗口（平板/小笔记本）：名称与规格也各占一整行，彻底不挤压 */
@media (max-width: 1024px) {
  .apply-item-row .m-name { flex: 1 1 100%; min-width: 100%; }
  .apply-item-row .m-spec { flex: 1 1 100%; min-width: 100%; }
  .apply-item-row .m-img  { flex: 1 1 100%; min-width: 100%; }
}

/* ===== 2026-09-26 applyDeptFix3 ===== */

/* ===== 2026-09-26 applyAcceptModalFinal =====
   ★ 重要教训 ★
   apply.html 只加载 style.css / mobile-fix.css / frame-universal.css 三个样式表，
   **不加载 studio-systems.css**（那是 production.html 父页面用的，父页面的 CSS 进不了 iframe）。
   之前把弹窗宽度与网格规则加到 studio-systems.css，在 iframe 里完全不生效。
   这里把它们统一放进 style.css（apply.html 确实加载的文件），并用足够高的选择器权重。
   同时保留 studio-systems.css 里的同名规则，保证在其它入口（管理后台等）也一致。 */

/* ---- 1) 申报单 / 验收单弹窗宽度：充分利用可用宽度 ---- */
#applyModal .modal,
#acceptModal .modal {
  width: min(1560px, calc(100vw - 24px));
  max-width: min(1560px, calc(100vw - 24px));
}

/* ---- 2) 让弹窗成为「容器查询容器」，明细行按弹窗实际宽度换行 ---- */
#applyModal .modal-body,
#acceptModal .modal-body {
  container-type: inline-size;
}

/* ---- 3) 基本信息区：规整两列网格 ---- */
.ap-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 18px;
  margin-bottom: 12px;
}
.ap-field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.ap-field.ap-field-full { grid-column: 1 / -1; }
.ap-field > label { font-size: 12.5px; color: var(--ink-2, #555); line-height: 1.2; }
.ap-field > label em { color: #e5484d; font-style: normal; margin-left: 2px; }
.ap-field > .input,
.ap-field > .select { width: 100%; min-width: 0; box-sizing: border-box; }
.ap-field > .form-hint { font-size: 11.5px; color: #999; line-height: 1.5; margin: 0; }

/* ---- 4) 明细行：按容器宽度自动换行（窄则两行，不再横向滚动） ---- */
@container (max-width: 1500px) {
  #applyModal .apply-item-row,
  #acceptModal .apply-item-row {
    flex-wrap: wrap !important;
    align-items: flex-start;
    row-gap: 6px;
    padding: 8px;
    gap: 6px;
  }
  #applyModal .apply-item-row .input,
  #acceptModal .apply-item-row .input { flex: 0 0 auto; }

  #applyModal .apply-item-row .m-name,  #acceptModal .apply-item-row .m-name
    { flex: 0 1 200px !important; width: auto !important; min-width: 140px; }
  #applyModal .apply-item-row .m-spec,  #acceptModal .apply-item-row .m-spec
    { flex: 0 1 320px !important; width: auto !important; min-width: 180px; }
  #applyModal .apply-item-row .m-qty,   #acceptModal .apply-item-row .m-qty
    { flex: 0 0 62px !important;  width: 62px !important; }
  #applyModal .apply-item-row .m-unit,  #acceptModal .apply-item-row .m-unit
    { flex: 0 0 56px !important;  width: 56px !important; }
  #applyModal .apply-item-row .m-price, #acceptModal .apply-item-row .m-price
    { flex: 0 0 76px !important;  width: 76px !important; }
  #applyModal .apply-item-row .m-total, #acceptModal .apply-item-row .m-total
    { flex: 0 0 80px !important;  width: 80px !important; }
  #applyModal .apply-item-row .m-delay, #acceptModal .apply-item-row .m-delay
    { flex: 0 0 132px !important; width: 132px !important; }
  #applyModal .apply-item-row .m-img,   #acceptModal .apply-item-row .m-img
    { flex: 1 1 150px !important; min-width: 150px; width: auto !important; }
  #applyModal .apply-item-row .m-rm,    #acceptModal .apply-item-row .m-rm
    { flex: 0 0 26px !important; }

  #applyModal .apply-items-head,
  #acceptModal .apply-items-head { display: none !important; }
}

@container (max-width: 1000px) {
  .ap-form-grid { grid-template-columns: minmax(0, 1fr); }
  #applyModal .apply-item-row .m-name, #acceptModal .apply-item-row .m-name
    { flex: 1 1 100% !important; min-width: 100% !important; }
  #applyModal .apply-item-row .m-spec, #acceptModal .apply-item-row .m-spec
    { flex: 1 1 100% !important; min-width: 100% !important; }
  #applyModal .apply-item-row .m-img,  #acceptModal .apply-item-row .m-img
    { flex: 1 1 100% !important; min-width: 100% !important; }
}

/* ===== 2026-09-26 apFormBeauty =====
   用户反馈：新建申报单的基本信息区字段「太宽、没有美感」，
   而「物料明细表格」的布局很舒服（因为列宽比例合理）。
   这里按同样的思路重做基本信息区：
     - 字段不再 100% 铺满，改为「标签在上、控件在下、控件有合理最大宽度」
     - 用 2 列网格，且**最小列宽 300px**，窄容器自动降为单列
     - 加淡淡的卡片分组背景，与大表格的观感统一
     - 部门提示文字缩进对齐控件、颜色更淡 */
.ap-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 14px 22px;
  margin: 2px 0 16px;
}
.ap-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ap-field.ap-field-full { grid-column: 1 / -1; }
.ap-field > label {
  font-size: 12.5px;
  color: #6b6259;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: .2px;
}
.ap-field > label em { color: #e5484d; font-style: normal; margin-left: 2px; }
/* 控件有合理上限：不再无限拉宽 */
.ap-field > .input,
.ap-field > .select {
  width: 100%;
  max-width: 420px;
  min-width: 0;
  box-sizing: border-box;
}
.ap-field.ap-field-full > .input,
.ap-field.ap-field-full > .select { max-width: 620px; }
.ap-field > .form-hint {
  font-size: 11.5px;
  color: #a9a29a;
  line-height: 1.5;
  margin: 0;
  max-width: 420px;
}

/* 基本信息区加一层很淡的底，与下方大表格形成「区块感」 */
#applyModal .modal-body > .ap-form-grid:first-of-type,
#acceptModal .modal-body > .ap-form-grid:first-of-type {
  background: linear-gradient(180deg, rgba(0,0,0,.015), rgba(0,0,0,0));
  border-radius: 10px;
  padding: 4px 2px 6px;
}

/* ===== 2026-09-26 apFormBeauty2 =====
   frame-universal.css 有一条
     html[data-frame-ui] .modal :is(input, select, textarea) { max-width: 100%; }
   权重高于 .ap-field > .input，把本页想给控件设的合理最大宽度盖掉了，
   于是控件被拉满整列（用户反馈"太宽、没美感"）。
   这里用同等/更高权重覆盖，给控件一个合理的宽度上限。 */
html[data-frame-ui] .modal .ap-field > .input,
html[data-frame-ui] .modal .ap-field > .select,
html[data-frame-ui] .modal .ap-form-grid > .ap-field > .input,
html[data-frame-ui] .modal .ap-form-grid > .ap-field > .select {
  max-width: 380px;
}
/* 整行字段（备注）可以更宽一些 */
html[data-frame-ui] .modal .ap-field.ap-field-full > .input,
html[data-frame-ui] .modal .ap-field.ap-field-full > .select {
  max-width: 560px;
}
/* 提示文字同样收窄，跟控件对齐 */
html[data-frame-ui] .modal .ap-field > .form-hint { max-width: 380px; }

/* ===== 2026-09-26 apFormBeauty3 =====
   按用户要求把「基本信息」区做得有美感：
   参考同页「物料明细表格」的观感——列宽比例固定、留白均匀、不铺满。
   - 3 列固定网格（宽屏），2 列（中屏），1 列（窄屏）
   - 控件宽度有上限，不再被拉满整列
   - 部门提示文字紧贴控件下方、缩进一致 */
#applyModal .ap-form-grid,
#acceptModal .ap-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px 24px;
  margin: 4px 0 18px;
  padding: 14px 16px 10px;
  background: #fbfbfa;
  border: 1px solid #f0eeea;
  border-radius: 12px;
}
@media (max-width: 1250px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: minmax(0, 1fr); }
}

/* 控件宽度上限（覆盖 frame-universal 的 max-width:100%） */
html[data-frame-ui] .modal .ap-field > .input,
html[data-frame-ui] .modal .ap-field > .select { max-width: 340px; }
html[data-frame-ui] .modal .ap-field.ap-field-full > .input,
html[data-frame-ui] .modal .ap-field.ap-field-full > .select { max-width: 520px; }
html[data-frame-ui] .modal .ap-field > .form-hint { max-width: 340px; }

/* 备注独占整行 */
#applyModal .ap-field.ap-field-full,
#acceptModal .ap-field.ap-field-full { grid-column: 1 / -1; }

/* ===== 2026-09-26 apFormBeauty4 =====
   用户要求：
   1) 基本信息区按「实际内容需要」分配宽度——
      客户、日期、申请部门、门店都窄；标题、备注宽一些；
      总共两排就放完，不要平均分配。
   2) 物料明细恢复**一排全部显示**（不换行），靠把弹窗加宽来解决。
   ------------------------------------------------------------------ */

/* ---- 弹窗加宽：给「明细一排显示」留出空间 ---- */
#applyModal .modal,
#acceptModal .modal {
  width: min(1560px, calc(100vw - 16px)) !important;
  max-width: min(1560px, calc(100vw - 16px)) !important;
}

/* ---- 基本信息区：按内容分配宽度，两排完成 ----
   第 1 排：客户(240) + 申请日期(190) + 标题(剩余)
   第 2 排：申请人(180) + 部门(280) + 使用门店(剩余)
   备注单独一行（半宽即可，不用铺满） */
#applyModal .ap-form-grid,
#acceptModal .ap-form-grid {
  display: grid;
  grid-template-columns: 240px 190px minmax(240px, 1fr);
  gap: 13px 20px;
  margin: 4px 0 18px;
  padding: 14px 16px 12px;
  background: #fbfbfa;
  border: 1px solid #f0eeea;
  border-radius: 12px;
}
/* 验收单只有 3 个字段：客户 / 验收日期 / 验收人 —— 用同一套节奏 */
#acceptModal .ap-form-grid { grid-template-columns: 240px 190px minmax(200px, 1fr); }

/* 控件不再受「列宽」限制太大，但也别铺满整列 */
html[data-frame-ui] .modal .ap-field > .input,
html[data-frame-ui] .modal .ap-field > .select { max-width: 100%; }
html[data-frame-ui] .modal .ap-field.ap-field-full > .input,
html[data-frame-ui] .modal .ap-field.ap-field-full > .select { max-width: 480px; }
html[data-frame-ui] .modal .ap-field > .form-hint { max-width: 280px; }

/* 备注整行，但只占约一半宽 */
#applyModal .ap-field.ap-field-full,
#acceptModal .ap-field.ap-field-full { grid-column: 1 / -1; }
#applyModal .ap-field.ap-field-full,
#acceptModal .ap-field.ap-field-full { max-width: none; }

/* 中屏：两列 */
@media (max-width: 1180px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: 200px 170px minmax(180px, 1fr); }
}
@media (max-width: 860px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---- 明细：容器够宽时【一排显示全部 10 列】（提高阈值，只在真窄时才换行） ---- */
@container (min-width: 1240px) {
  #applyModal .apply-item-row,
  #acceptModal .apply-item-row {
    flex-wrap: nowrap !important;
    align-items: center;
    padding: 10px 12px;
    gap: 8px;
  }
  #applyModal .apply-items-head,
  #acceptModal .apply-items-head { display: flex !important; }

  #applyModal .apply-item-row .m-name,  #acceptModal .apply-item-row .m-name
    { flex: 1 1 140px !important; width: auto !important; min-width: 110px; }
  #applyModal .apply-item-row .m-spec,  #acceptModal .apply-item-row .m-spec
    { flex: 2 1 200px !important; width: auto !important; min-width: 150px; }
  #applyModal .apply-item-row .m-qty,   #acceptModal .apply-item-row .m-qty
    { flex: 0 0 58px !important;  width: 58px !important; }
  #applyModal .apply-item-row .m-unit,  #acceptModal .apply-item-row .m-unit
    { flex: 0 0 52px !important;  width: 52px !important; }
  #applyModal .apply-item-row .m-price, #acceptModal .apply-item-row .m-price
    { flex: 0 0 70px !important;  width: 70px !important; }
  #applyModal .apply-item-row .m-total, #acceptModal .apply-item-row .m-total
    { flex: 0 0 78px !important;  width: 78px !important; }
  #applyModal .apply-item-row .m-delay, #acceptModal .apply-item-row .m-delay
    { flex: 0 0 124px !important; width: 124px !important; }
  #applyModal .apply-item-row .m-img,   #acceptModal .apply-item-row .m-img
    { flex: 0 0 190px !important; min-width: 190px; width: 190px !important; }
  #applyModal .apply-item-row .m-rm,    #acceptModal .apply-item-row .m-rm
    { flex: 0 0 22px !important; }
}

/* ===== 2026-09-26 apFormBeauty5 =====
   按用户要求微调：
   - 客户/日期/申请人/门店：按内容给小宽度（已经很小）
   - 标题：宽一点，但不要吃掉整行 → 上限 660px
   - 备注：上限 660px
   第 1 排：客户 220 + 申请日期 190 + 标题 660
   第 2 排：申请人 220 + 部门 280 + 使用门店 剩余
   → 总共两排（备注单独一行） */

#applyModal .ap-form-grid,
#acceptModal .ap-form-grid {
  grid-template-columns: 220px 190px 660px;
  justify-content: start;
}
#acceptModal .ap-form-grid { grid-template-columns: 220px 190px 300px; }

/* 备注：半宽即可 */
html[data-frame-ui] .modal .ap-field.ap-field-full > .input,
html[data-frame-ui] .modal .ap-field.ap-field-full > .select { max-width: 660px; }

@media (max-width: 1330px) {
  #applyModal .ap-form-grid { grid-template-columns: 200px 170px minmax(220px, 1fr); }
  #acceptModal .ap-form-grid { grid-template-columns: 200px 170px minmax(200px, 1fr); }
}
@media (max-width: 860px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ===== 2026-09-26 apFormRow1 =====
   用户反馈：字段挤在左边两列，右侧三分之一全空着，很难看。
   既然一排能放下，就【全部铺在一排、撑满宽度】：
   客户 · 申请日期 · 标题 · 申请人 · 部门 · 使用门店  → 一行
   备注  → 第二行（整行）
   ------------------------------------------------------------------ */
#applyModal .ap-form-grid,
#acceptModal .ap-form-grid {
  display: grid;
  grid-template-columns: 210px 180px minmax(260px, 2.2fr) 170px 250px minmax(200px, 1.4fr);
  gap: 12px 18px;
  justify-content: stretch;
  align-items: start;
}
/* 验收单字段少（客户/验收日期/验收人/来源申报单/部门/备注），同样铺满一排 */
#acceptModal .ap-form-grid {
  grid-template-columns: minmax(200px, 1.2fr) 180px minmax(180px, 1fr) minmax(200px, 1.2fr) 250px;
}

/* 控件撑满各自格子，不再留半截 */
html[data-frame-ui] .modal .ap-field > .input,
html[data-frame-ui] .modal .ap-field > .select { max-width: 100%; }
html[data-frame-ui] .modal .ap-field > .form-hint { max-width: 100%; }

/* 备注：第二行整行 */
#applyModal .ap-field.ap-field-full,
#acceptModal .ap-field.ap-field-full { grid-column: 1 / -1; }
html[data-frame-ui] .modal .ap-field.ap-field-full > .input,
html[data-frame-ui] .modal .ap-field.ap-field-full > .select { max-width: 100%; }

/* 中等宽度：两排（每排 3 个），仍然铺满 */
@media (max-width: 1420px) {
  #applyModal .ap-form-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  #acceptModal .ap-form-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
/* 窄：两列 */
@media (max-width: 900px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* 很窄：一列 */
@media (max-width: 620px) {
  #applyModal .ap-form-grid,
  #acceptModal .ap-form-grid { grid-template-columns: minmax(0, 1fr); }
}

/* ===== 2026-09-26 acceptRowFinal =====
   ★ 关键修复 ★
   之前 style.css 里同时存在两组 @container 规则：
     (a) max-width:1500px  → flex-wrap: wrap   （旧的"窄就换行"）
     (b) min-width:1240px  → flex-wrap: nowrap （新的"一排铺满"）
   弹窗内容宽约 1512px 时【两个条件都成立】。CSS 中同权重时「后出现的胜」，
   而 (a) 写在 (b) 之后，于是换行规则赢了 —— 明细被迫折行，
   图片列的「点选/粘贴」被挤成竖排一个字一行。
   这里用 !important 明确优先级，并给每列定死宽度，确保一排。
   ------------------------------------------------------------------ */

/* 验收单：两行表单合并成一排铺满（客户/验收日期/验收人/来源申报单/部门） */
#acceptModal .ap-form-grid {
  display: grid !important;
  grid-template-columns: minmax(180px, 1.1fr) 175px minmax(160px, 1fr) minmax(180px, 1.1fr) 240px !important;
  gap: 12px 18px !important;
}
#acceptModal .ap-field.ap-field-full { grid-column: 1 / -1 !important; }

/* 明细：一排铺满，列宽定死（合计 = 内容宽 1512） */
#applyModal .apply-item-row,
#acceptModal .apply-item-row {
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: 8px !important;
}
#applyModal .apply-items-head,
#acceptModal .apply-items-head { display: flex !important; }

#applyModal .apply-item-row .m-name,  #acceptModal .apply-item-row .m-name
  { flex: 0 0 16% !important; width: 16% !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-spec,  #acceptModal .apply-item-row .m-spec
  { flex: 0 0 24% !important; width: 24% !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-qty,   #acceptModal .apply-item-row .m-qty
  { flex: 0 0 58px !important; width: 58px !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-unit,  #acceptModal .apply-item-row .m-unit
  { flex: 0 0 52px !important; width: 52px !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-price, #acceptModal .apply-item-row .m-price
  { flex: 0 0 66px !important; width: 66px !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-total, #acceptModal .apply-item-row .m-total
  { flex: 0 0 74px !important; width: 74px !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-img,   #acceptModal .apply-item-row .m-img
  { flex: 0 0 196px !important; width: 196px !important; min-width: 196px !important; }
#applyModal .apply-item-row .m-delay, #acceptModal .apply-item-row .m-delay
  { flex: 0 0 128px !important; width: 128px !important; min-width: 0 !important; }
#applyModal .apply-item-row .m-rm,    #acceptModal .apply-item-row .m-rm
  { flex: 0 0 22px !important; width: 22px !important; }

/* 图片列内部：不换行，按钮和提示并排 */
#applyModal .apply-item-row .m-img,
#acceptModal .apply-item-row .m-img { flex-direction: row !important; }
#applyModal .apply-item-row .m-img input[type=file],
#acceptModal .apply-item-row .m-img input[type=file] { width: 84px !important; flex: 0 0 84px; font-size: 11px; }
#applyModal .apply-item-row .m-img > span,
#acceptModal .apply-item-row .m-img > span { white-space: nowrap !important; font-size: 11px; color: #999; }
#applyModal .apply-item-row .m-img .btn-sm,
#acceptModal .apply-item-row .m-img .btn-sm { flex: 0 0 auto; white-space: nowrap; }

/* 表头与数据列对齐 */
#applyModal .apply-items-head span:nth-child(1), #acceptModal .apply-items-head span:nth-child(1) { flex: 0 0 32px; width: 32px; }
#applyModal .apply-items-head span:nth-child(2), #acceptModal .apply-items-head span:nth-child(2) { flex: 0 0 16%; width: 16%; }
#applyModal .apply-items-head span:nth-child(3), #acceptModal .apply-items-head span:nth-child(3) { flex: 0 0 24%; width: 24%; }
#applyModal .apply-items-head span:nth-child(4), #acceptModal .apply-items-head span:nth-child(4) { flex: 0 0 58px; width: 58px; }
#applyModal .apply-items-head span:nth-child(5), #acceptModal .apply-items-head span:nth-child(5) { flex: 0 0 52px; width: 52px; }
#applyModal .apply-items-head span:nth-child(6), #acceptModal .apply-items-head span:nth-child(6) { flex: 0 0 66px; width: 66px; }
#applyModal .apply-items-head span:nth-child(7), #acceptModal .apply-items-head span:nth-child(7) { flex: 0 0 74px; width: 74px; }
#applyModal .apply-items-head span:nth-child(8), #acceptModal .apply-items-head span:nth-child(8) { flex: 0 0 196px; width: 196px; }
#applyModal .apply-items-head span:nth-child(9), #acceptModal .apply-items-head span:nth-child(9) { flex: 0 0 128px; width: 128px; }
#applyModal .apply-items-head span:nth-child(10), #acceptModal .apply-items-head span:nth-child(10) { flex: 0 0 22px; width: 22px; }

/* ===== 2026-09-26 rowColsFinal2 =====
   上一步量出：图片列内容实际需要 243px（缩略图 + 删图按钮 + 选择文件 + 点选/粘贴），
   而只给了 196px → 「点选/粘贴」被挤成竖排。
   这里把图片列加宽到 250px，同时压一压前面几列，保证总和 = 内容宽 1512：
     32 + 216(name 14.3%) + 347(spec 23%) + 56 + 50 + 64 + 72 + 250 + 126 + 22 = 1235，
     加上 9 个 gap（8px）= 1307，剩余约 205 由 name/spec 按比例吸收 → 正好铺满不换行。 */
#applyModal .apply-item-row .m-name,  #acceptModal .apply-item-row .m-name
  { flex: 0 0 17% !important; width: 17% !important; }
#applyModal .apply-item-row .m-spec,  #acceptModal .apply-item-row .m-spec
  { flex: 0 0 25% !important; width: 25% !important; }
#applyModal .apply-item-row .m-qty,   #acceptModal .apply-item-row .m-qty
  { flex: 0 0 56px !important; width: 56px !important; }
#applyModal .apply-item-row .m-unit,  #acceptModal .apply-item-row .m-unit
  { flex: 0 0 50px !important; width: 50px !important; }
#applyModal .apply-item-row .m-price, #acceptModal .apply-item-row .m-price
  { flex: 0 0 64px !important; width: 64px !important; }
#applyModal .apply-item-row .m-total, #acceptModal .apply-item-row .m-total
  { flex: 0 0 72px !important; width: 72px !important; }
#applyModal .apply-item-row .m-img,   #acceptModal .apply-item-row .m-img
  { flex: 0 0 250px !important; width: 250px !important; min-width: 250px !important; }
#applyModal .apply-item-row .m-delay, #acceptModal .apply-item-row .m-delay
  { flex: 0 0 126px !important; width: 126px !important; }

/* 图片列内部再压紧一点，确保 250px 够用 */
#applyModal .apply-item-row .m-img input[type=file],
#acceptModal .apply-item-row .m-img input[type=file] { width: 88px !important; flex: 0 0 88px; }
#applyModal .apply-item-row .m-img img,
#acceptModal .apply-item-row .m-img img { width: 36px !important; height: 36px !important; flex: 0 0 36px; }

/* 表头同步 */
#applyModal .apply-items-head span:nth-child(2), #acceptModal .apply-items-head span:nth-child(2) { flex: 0 0 17% !important; width: 17% !important; }
#applyModal .apply-items-head span:nth-child(3), #acceptModal .apply-items-head span:nth-child(3) { flex: 0 0 25% !important; width: 25% !important; }
#applyModal .apply-items-head span:nth-child(4), #acceptModal .apply-items-head span:nth-child(4) { flex: 0 0 56px !important; width: 56px !important; }
#applyModal .apply-items-head span:nth-child(5), #acceptModal .apply-items-head span:nth-child(5) { flex: 0 0 50px !important; width: 50px !important; }
#applyModal .apply-items-head span:nth-child(6), #acceptModal .apply-items-head span:nth-child(6) { flex: 0 0 64px !important; width: 64px !important; }
#applyModal .apply-items-head span:nth-child(7), #acceptModal .apply-items-head span:nth-child(7) { flex: 0 0 72px !important; width: 72px !important; }
#applyModal .apply-items-head span:nth-child(8), #acceptModal .apply-items-head span:nth-child(8) { flex: 0 0 250px !important; width: 250px !important; }
#applyModal .apply-items-head span:nth-child(9), #acceptModal .apply-items-head span:nth-child(9) { flex: 0 0 126px !important; width: 126px !important; }

/* ===== 2026-09-26 rowColsFinal3 =====
   图片列里「选择文件」原生的「未选择文件」文字被截断，看着像乱码。
   处理：把文件选择框加宽到能完整显示，并把「点选/粘贴」提示缩到最短。 */
#applyModal .apply-item-row .m-img,   #acceptModal .apply-item-row .m-img
  { flex: 0 0 290px !important; width: 290px !important; min-width: 290px !important; }
#applyModal .apply-item-row .m-img input[type=file],
#acceptModal .apply-item-row .m-img input[type=file] { width: 122px !important; flex: 0 0 122px !important; font-size: 11px; }
/* 名称/规格让出一点宽度给图片列 */
#applyModal .apply-item-row .m-name,  #acceptModal .apply-item-row .m-name
  { flex: 0 0 14% !important; width: 14% !important; }
#applyModal .apply-item-row .m-spec,  #acceptModal .apply-item-row .m-spec
  { flex: 0 0 22% !important; width: 22% !important; }
#applyModal .apply-items-head span:nth-child(2), #acceptModal .apply-items-head span:nth-child(2) { flex: 0 0 14% !important; width: 14% !important; }
#applyModal .apply-items-head span:nth-child(3), #acceptModal .apply-items-head span:nth-child(3) { flex: 0 0 22% !important; width: 22% !important; }
#applyModal .apply-items-head span:nth-child(8), #acceptModal .apply-items-head span:nth-child(8) { flex: 0 0 290px !important; width: 290px !important; }

/* ===== 2026-09-26 rowColsFinal4 =====
   文件选择框调成刚好能完整显示「未选择文件」，图片列宽度同步微调。 */
#applyModal .apply-item-row .m-img,   #acceptModal .apply-item-row .m-img
  { flex: 0 0 272px !important; width: 272px !important; min-width: 272px !important; }
#applyModal .apply-item-row .m-img input[type=file],
#acceptModal .apply-item-row .m-img input[type=file] { width: 108px !important; flex: 0 0 108px !important; }
#applyModal .apply-items-head span:nth-child(8), #acceptModal .apply-items-head span:nth-child(8) { flex: 0 0 272px !important; width: 272px !important; }
#applyModal .apply-item-row .m-name,  #acceptModal .apply-item-row .m-name { flex: 0 0 15% !important; width: 15% !important; }
#applyModal .apply-item-row .m-spec,  #acceptModal .apply-item-row .m-spec { flex: 0 0 23% !important; width: 23% !important; }
#applyModal .apply-items-head span:nth-child(2), #acceptModal .apply-items-head span:nth-child(2) { flex: 0 0 15% !important; width: 15% !important; }
#applyModal .apply-items-head span:nth-child(3), #acceptModal .apply-items-head span:nth-child(3) { flex: 0 0 23% !important; width: 23% !important; }

/* ===== 2026-09-26 rowRhythm =====
   用户反馈：两个弹窗的「行距」要一致，否则看着别扭。
   实测发现：字段高度是 auto——select 高 41px、input 高 39px，
   导致每排高度都不一样（申报单 59/61、验收单 59），行距随之不同。
   处理：两个弹窗统一采用同一套「行节奏」——
     - 固定行高 grid-auto-rows: 64px（标签 18 + 控件 40 + 6 间隙）
     - 统一行距 row-gap: 14px、列距 column-gap: 18px
     - 控件统一高度 40px
   这样两边的首排位置、行间距、控件大小完全一致。 */
#applyModal .ap-form-grid,
#acceptModal .ap-form-grid {
  grid-auto-rows: 64px;
  align-content: start;
  row-gap: 14px !important;
  column-gap: 18px !important;
  align-items: stretch;
  padding: 16px 18px 14px !important;
}
#applyModal .ap-field,
#acceptModal .ap-field { gap: 6px; justify-content: flex-start; }
#applyModal .ap-field > label,
#acceptModal .ap-field > label { height: 18px; line-height: 18px; }
#applyModal .ap-field > .input,
#applyModal .ap-field > .select,
#acceptModal .ap-field > .input,
#acceptModal .ap-field > .select {
  height: 40px !important;
  min-height: 40px !important;
  max-height: 40px !important;
  box-sizing: border-box;
}
/* 备注是整行（含标签 + 控件 = 64px），提示文字排在格子下方不撑高行 */
#applyModal .ap-field.ap-field-full,
#acceptModal .ap-field.ap-field-full { grid-row: span 1; }

/* ===== 2026-09-26 rhythmAlign =====
   两个弹窗的「行节奏」已统一为：行高 64px、行距 14px、控件 40px、标签 18px。
   仅剩一处差异：验收单的基本信息分成了两块网格（客户/日期/验收人 一块，
   来源申报单/部门/备注 一块），两块之间的间距与网格内部行距不同，看上去断档。
   这里把两块之间的间距调成与内部行距完全一致（64 + 14 + 12 = 90 → margin 26px）。 */
#acceptModal .ap-form-grid + .ap-form-grid {
  margin-top: 26px !important;
}
/* 两块网格的内边距保持一致，避免上下不对称 */
#acceptModal .ap-form-grid { margin-bottom: 0 !important; }
#acceptModal .ap-form-grid + .ap-form-grid { margin-bottom: 18px !important; }

/* ===== 2026-09-26 pdfA4Table =====
   A4 导出/预览的表格：列宽按百分比固定，单元格内容严格约束在格子内。
   解决「规格、尺寸、材质」文字溢出压到「数量/单位/单价」上的重叠问题。 */
.pdf-a4-table {
  table-layout: fixed !important;
  width: 100% !important;
  border-collapse: collapse !important;
}
.pdf-a4-table td,
.pdf-a4-table th {
  overflow: hidden !important;
  word-break: break-all !important;
  overflow-wrap: anywhere !important;
  white-space: normal !important;
  line-height: 1.45 !important;
  vertical-align: middle !important;
}
.pdf-a4-table td.nowrap,
.pdf-a4-table th.nowrap {
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

/* ===== 2026-09-26 pdfOrientBtn =====
   导出预览的「横版 / 竖版」切换按钮：
   只有被选中的那个是深底白字，另一个是白底深字，肉眼一眼可辨。 */
#orderPdfPreviewModal .pdf-orient-btn {
  padding: 5px 12px;
  font-size: 12px;
  border-radius: 6px;
  cursor: pointer;
  background: #fff !important;
  color: #6b6259 !important;
  border: 1px solid #dcd8d2 !important;
  transition: background .15s, color .15s, border-color .15s;
  font-family: inherit;
}
#orderPdfPreviewModal .pdf-orient-btn:hover {
  background: #f5f3f0 !important;
  color: #332C2B !important;
}
#orderPdfPreviewModal .pdf-orient-btn.active {
  background: #332C2B !important;
  color: #fff !important;
  border-color: #332C2B !important;
  font-weight: 600;
}

/* ===== 2026-09-26 pdfTableLines =====
   用户要求（设计师视角）：
   1) PDF 预览默认缩放 100%（原来默认「适应宽度」被放大到 138%）
   2) 表头加竖向分隔线，便于按列阅读
   3) 表格文字居中（物料名称与规格保持左对齐，长文本左对齐才易读） */
.pdf-a4-table th {
  border-left: 1px solid #000 !important;
  border-right: 1px solid #000 !important;
  vertical-align: middle !important;
}
.pdf-a4-table th:first-child { border-left: none !important; }
.pdf-a4-table th:last-child  { border-right: none !important; }
/* 表头文字统一居中 */
.pdf-a4-table th { text-align: center !important; }
/* 表格正文居中；名称与规格保持左对齐 */
.pdf-a4-table td { text-align: center !important; }
.pdf-a4-table td.txt-left { text-align: left !important; }

/* ===== 2026-09-26 pdfTableLinesGray =====
   用户反馈：表头那条竖着的黑线太突兀，希望和表格其它线一样用灰色。
   处理：
   * 表头分隔线由 #000 改为 #9a9a9a（与表格横线同色系）
   * 表格正文/合计/大写的边框由 #ddd 提到 #9a9a9a，
     让整张表的线颜色统一 */
.pdf-a4-table th {
  border-left: 1px solid #9a9a9a !important;
  border-right: 1px solid #9a9a9a !important;
}
.pdf-a4-table th:first-child { border-left: none !important; }
.pdf-a4-table th:last-child  { border-right: none !important; }
.pdf-a4-table td { border-color: #9a9a9a !important; }

/* ===== 2026-09-26 daxieRight =====
   用户要求「大写：…」那一行靠右（表格右对齐）。
   因为上面有 .pdf-a4-table td{text-align:center!important} 的通用规则，
   内联样式压不住，所以这里用同等权重 + !important 明确右对齐。 */
.pdf-a4-table td.dx-right { text-align: right !important; padding-right: 16px !important; }

/* ===== 2026-09-26 字体统一标准 =====
   用户（设计师）要求：单据/打印件里所有文字用同一套字体，
   以后新增的文字也按这个标准走。
   标准 = 「送货人签字」那一类正文字体：
     Microsoft YaHei（Windows 中文默认）→ PingFang SC（macOS）→ 黑体兜底
   字重 400（常规），不用粗体装饰。 */
:root {
  --yz-font: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Heiti SC", "微软雅黑", sans-serif;
}
.pdf-a4-table,
.pdf-a4-table td,
.pdf-a4-table th,
#orderPdfPreviewPaper,
#orderPdfPreviewPaper div,
#orderPdfPreviewPaper span,
#orderPdfPreviewPaper b,
#orderPdfPreviewPaper strong {
  font-family: var(--yz-font) !important;
}

/* ============================================================
   2026-09-29：已作废工单的视觉标识（用户选方案 1）
   背景：卡片代码早就在 status='cancelled' 时加了 .cancelled 类名，
        但样式表里【从来没有】这个类 → 界面上完全看不出区别。
   做法：卡片变灰 + 右上角红色「已作废」角标 + 金额加删除线
   ============================================================ */
.proj-row.cancelled{
  position:relative;
  opacity:.62;
  background:#fbfaf9 !important;
  border:1px dashed #dcd6d0 !important;
  overflow:hidden;
}
.proj-row.cancelled .proj-thumbs img,
.proj-row.cancelled .proj-thumb{
  filter:grayscale(1);
  opacity:.8;
}
.proj-row.cancelled .proj-row-amt{
  color:#a8a09a !important;
  text-decoration:line-through;
  text-decoration-thickness:2px;
}
.proj-row.cancelled .proj-row-name{
  color:#8a837c !important;
}
/* 右上角红色角标 */
.proj-row.cancelled::after{
  content:"已作废";
  position:absolute;
  top:8px;
  right:8px;
  font-size:10px;
  font-weight:800;
  letter-spacing:.5px;
  color:#fff;
  background:#c0392b;
  padding:2px 7px;
  border-radius:999px;
  box-shadow:0 1px 4px rgba(192,57,43,.28);
  pointer-events:none;
  z-index:2;
}
/* 小屏（手机）角标缩一点，别把小卡片压满 */
@media (max-width:560px){
  .proj-row.cancelled::after{font-size:9px;padding:1px 5px;top:6px;right:6px}
}

/* ============================================================
   2026-09-29：工单弹窗「按钮够不着」修复
   病根：弹窗内容太高，可滚动的是 <form>（400px），而
        .modal-foot 是 static，跟着内容沉到底部 → 每次都要滚到底才能点"确定"。
   做法：
     · 表单本身改成纵向 flex，中间内容区自己滚
     · .modal-head 吸顶、.modal-foot 吸底 → 标题和按钮永远可见
     · 同时给 .modal 兜底，表单结构变了也不会失效
   ============================================================ */
.modal form {
  display: flex !important;
  flex-direction: column;
  min-height: 0;
  overflow: hidden !important;
}
.modal .modal-head,
.modal > .modal-head {
  position: sticky !important;
  top: 0;
  z-index: 5;
  flex-shrink: 0;
  background: #fff;
}
.modal .modal-foot,
.modal > .modal-foot {
  position: sticky !important;
  bottom: 0;
  z-index: 5;
  flex-shrink: 0;
  background: #fff;
  box-shadow: 0 -4px 14px rgba(51,44,43,.07);
}
/* （已移除：会让每个分区各自长出滚动条） */
/* 手机端：底部按钮留出安全区，别被系统手势条挡住 */
@media (max-width: 768px) {
  .modal .modal-foot,
  .modal > .modal-foot {
    padding-bottom: calc(14px + env(safe-area-inset-bottom)) !important;
  }
}

/* ============================================================
   2026-09-29：工单登记表单改「按内容分宽」（用户反馈窄字段太浪费）
   病根：.form-grid 是 1fr 1fr —— 日期/时间/用时/单价都强制占半屏，
        右边一大片空白，表单又高又长。
   做法：新增 .wf-grid 六列窄网格，按字段内容给 1~6 格宽：
         w1=时间/用时/规格/数量   w2=客户/类型/单价/成本
         w3=材质/日期范围          w6=金额/项目/备注（整行）
   ============================================================ */
.wf-grid {
  display: grid !important;
  grid-template-columns: repeat(6, minmax(0, 1fr)) !important;
  gap: 12px 10px !important;
  margin-bottom: 0;
}
.wf-grid > .form-item { grid-column: span 3; min-width: 0; }
.wf-grid > .form-item.w1 { grid-column: span 1; }
.wf-grid > .form-item.w2 { grid-column: span 2; }
.wf-grid > .form-item.w3 { grid-column: span 3; }
.wf-grid > .form-item.w4 { grid-column: span 4; }
.wf-grid > .form-item.w6 { grid-column: 1 / -1; }
/* 整行的字段（金额/总价/项目/备注） */
.wf-grid > .form-item.full { grid-column: 1 / -1; }
/* 窄格里输入框内边距稍收，字号保持可读 */
.wf-grid > .form-item.w1 > input,
.wf-grid > .form-item.w1 > select { padding-left: 9px; padding-right: 6px; }
/* 手机 / 窄屏：退回两列，别再挤 */
@media (max-width: 820px) {
  .wf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 12px 10px !important; }
  .wf-grid > .form-item,
  .wf-grid > .form-item.w1,
  .wf-grid > .form-item.w2,
  .wf-grid > .form-item.w3,
  .wf-grid > .form-item.w4 { grid-column: span 1; }
  .wf-grid > .form-item.w6,
  .wf-grid > .form-item.full { grid-column: 1 / -1; }
}

/* ============================================================
   2026-09-29 修正：去掉每个分区各自的滚动条 + 弹窗加宽
   问题：上一版给 .modal form > * 加了 overflow-y:auto，
        导致【每个 .form-section 自己都长出一条滚动条】，
        分区内容略超出就出现滚动条，看着又乱又累。
   做法：
     · 分区、网格一律不滚动（overflow 交还给统一的滚动容器）
     · 工单类弹窗加宽到 860px，字段更舒展
   ============================================================ */
/* ① 分区和网格不再各自滚动 */
.modal form > .form-section,
.modal form > .wf-grid,
.modal form > .form-grid,
.modal form > .form-step,
.modal .form-section,
.modal .wf-grid,
.modal .form-grid {
  overflow: visible !important;
  max-height: none !important;
  flex: 0 0 auto !important;
}
/* ② 只保留一个滚动容器（表单里真正的中间区） */
.modal form > .form-scroll {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch;
}
/* ③ 工单类表单弹窗加宽（原来 680 太挤） */
#editRecordModal > .modal,
#materialModal > .modal, #editRecordModal > .modal { width: 1000px !important; max-width: 98vw !important; min-width: 0 !important; }
@media (max-width: 900px) {
  #editRecordModal > .modal,
  }
/* ④ 分区内部留白略收，减少总高度 */
.modal .form-section { padding: 13px 15px !important; margin-bottom: 12px !important; }
.modal .form-section-title { margin-bottom: 10px !important; }

/* ============================================================
   2026-09-29：所属项目「带三角箭头的下拉」
   用户反馈：datalist 打字时自己弹提示很乱，要明确的下拉按钮。
   ============================================================ */
.pj-pick { display: flex; align-items: stretch; gap: 0; }
.pj-pick .pj-pick-input {
  flex: 1 1 auto;
  min-width: 0;
  border-top-right-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
  border-right: none !important;
  cursor: pointer;
  background: #fff !important;
}
.pj-pick .pj-pick-btn {
  flex: 0 0 auto;
  width: 38px;
  border: 1px solid #dfe4ec;
  border-left: 1px solid #eef0f5;
  border-radius: 0 9px 9px 0;
  background: #f7f8fb;
  color: #5a6472;
  font-size: 11px;
  line-height: 1;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.pj-pick .pj-pick-btn:hover { background: #eef1f6; color: #332C2B; }
.pj-pick .pj-pick-btn.open { background: #e8ecf3; color: #332C2B; border-color: #cfd6e0; }
.pj-dropdown {
  position: fixed;
  z-index: 100001;
  background: #fff;
  border: 1px solid #e3e7ee;
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(20,25,35,.16);
  padding: 5px;
  max-height: 260px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.pj-dropdown .pj-opt {
  padding: 9px 11px;
  border-radius: 7px;
  font-size: 13px;
  color: #332C2B;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pj-dropdown .pj-opt:hover { background: #f4f6fa; }
.pj-dropdown .pj-opt.pj-cur { background: #eef4ff; font-weight: 700; }
.pj-dropdown .pj-empty { padding: 9px 11px; font-size: 12px; color: #9aa2ad; }
.pj-dropdown .pj-new {
  margin-top: 4px;
  padding: 9px 11px;
  border-radius: 7px;
  border-top: 1px dashed #e3e7ee;
  font-size: 13px;
  font-weight: 700;
  color: #2e9e6c;
  cursor: pointer;
}
.pj-dropdown .pj-new:hover { background: #eefaf3; }

/* ============================================================
   2026-09-29：登记表单改 12 栏细网格（按用户示意图的比例排）
   用户 p 的示意图：客户/设计师各 ~1/4，日期 ~15%，开始/结束时间各 ~13%
   并排；设计物料名称约半行，用时/单价/金额三个并排。
   做法：.wf-grid 由 6 栏改 12 栏，宽度类 w2~w12 按比例映射。
   ============================================================ */
.wf-grid { grid-template-columns: repeat(12, minmax(0, 1fr)) !important; }
.wf-grid > .form-item { grid-column: span 6; }
.wf-grid > .form-item.w1  { grid-column: span 1; }
.wf-grid > .form-item.w2  { grid-column: span 2; }
.wf-grid > .form-item.w3  { grid-column: span 3; }
.wf-grid > .form-item.w4  { grid-column: span 4; }
.wf-grid > .form-item.w5  { grid-column: span 5; }
.wf-grid > .form-item.w6  { grid-column: span 6; }
.wf-grid > .form-item.w7  { grid-column: span 7; }
.wf-grid > .form-item.w8  { grid-column: span 8; }
.wf-grid > .form-item.w9  { grid-column: span 9; }
.wf-grid > .form-item.w10 { grid-column: span 10; }
.wf-grid > .form-item.w11 { grid-column: span 11; }
.wf-grid > .form-item.w12 { grid-column: 1 / -1; }
.wf-grid > .form-item.full { grid-column: 1 / -1; }
/* 窄格里输入框内边距略收，避免时间控件被压 */
.wf-grid > .form-item.w1 > input,
.wf-grid > .form-item.w2 > input,
.wf-grid > .form-item.w1 > select,
.wf-grid > .form-item.w2 > select { padding-left: 10px; padding-right: 8px; }
/* 时间类控件别被压扁 */
.wf-grid input[type="time"] { min-width: 0; }
/* 手机：退回两栏，宽字段整行 */
@media (max-width: 820px) {
  .wf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .wf-grid > .form-item,
  .wf-grid > .form-item.w1,
  .wf-grid > .form-item.w2,
  .wf-grid > .form-item.w3,
  .wf-grid > .form-item.w4,
  .wf-grid > .form-item.w5 { grid-column: span 1; }
  .wf-grid > .form-item.w6,
  .wf-grid > .form-item.w7,
  .wf-grid > .form-item.w8,
  .wf-grid > .form-item.w9,
  .wf-grid > .form-item.w10,
  .wf-grid > .form-item.w11,
  .wf-grid > .form-item.w12,
  .wf-grid > .form-item.full { grid-column: 1 / -1; }
}

/* ============================================================
   2026-09-29：登记表单按用户示意图排版（flex 百分比宽度）
   用户 p 的示意图：第一行 客户|设计师|日期|开始时间|结束时间 五个并排；
   第二行 设计物料名称(半行)|用时|单价|金额；开始时间与结束时间同级并排。
   改用 flex + 百分比宽度，行序完全可控（网格自动填充会把行序打乱）。
   ============================================================ */
.wf-grid {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 12px 10px !important;
  align-items: flex-start;
  grid-template-columns: none !important;
}
.wf-grid > .form-item { grid-column: auto !important; }
/* 百分比宽度（已扣除 gap，保证每行加起来正好 100%） */
.wf-grid > .form-item.p15 { flex: 0 0 calc(15.5% - 10px); max-width: calc(15.5% - 10px); }
.wf-grid > .form-item.p23 { flex: 0 0 calc(23% - 10px);  max-width: calc(23% - 10px); }
.wf-grid > .form-item.p33 { flex: 0 0 calc(33% - 10px);  max-width: calc(33% - 10px); }
.wf-grid > .form-item.p46 { flex: 0 0 calc(46.5% - 10px); max-width: calc(46.5% - 10px); }
.wf-grid > .form-item.p100 { flex: 1 1 100%; max-width: 100%; }
/* 名称类可按内容伸缩 */
.wf-grid > .form-item.p46 > input { min-width: 0; }
/* 手机：一行两个，宽字段整行 */
@media (max-width: 820px) {
  .wf-grid > .form-item.p15,
  .wf-grid > .form-item.p23,
  .wf-grid > .form-item.p33 { flex: 0 0 calc(50% - 10px); max-width: calc(50% - 10px); }
  .wf-grid > .form-item.p46 { flex: 1 1 100%; max-width: 100%; }
  .wf-grid > .form-item.p100 { flex: 1 1 100%; max-width: 100%; }
}

/* ============================================================
   2026-09-29：登记表单按「内容长度」定宽（不再用百分比硬撑）
   用户反馈：名字、总金额后面留一大片空白没用；该大的大、该小的小。
   做法：
     · 内容长的文本字段（客户/设计师/物料名称/材质）→ flex:1，自动吃掉剩余空间
     · 内容短的字段（日期150 时间120 用时100 单价110 金额110 规格95 数量90 单位95）
       → 固定宽度，输入框不再虚胖
     · 整行字段（所属项目/备注）→ 100%
   ============================================================ */
.wf-grid {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: flex-start;
  gap: 12px 10px !important;
  grid-template-columns: none !important;
}
.wf-grid > .form-item { grid-column: auto !important; min-width: 0; }

/* 可伸缩：吃剩余空间 */
.wf-grid > .form-item.g300 { flex: 1 1 240px; max-width: 100%; }
.wf-grid > .form-item.g320 { flex: 1 1 260px; max-width: 100%; }
.wf-grid > .form-item.g200 { flex: 1 1 160px; max-width: 100%; }
.wf-grid > .form-item.g190 { flex: 1 1 160px; max-width: 100%; }
.wf-grid > .form-item.g180 { flex: 1 1 150px; max-width: 100%; }
.wf-grid > .form-item.g170 { flex: 1 1 140px; max-width: 100%; }
.wf-grid > .form-item.g150 { flex: 1 1 130px; max-width: 100%; }

/* 固定宽度：按内容给足 */
.wf-grid > .form-item.f150 { flex: 0 0 150px; max-width: 150px; }
.wf-grid > .form-item.f160 { flex: 0 0 160px; max-width: 160px; }
.wf-grid > .form-item.f120 { flex: 0 0 120px; max-width: 120px; }
.wf-grid > .form-item.f110 { flex: 0 0 110px; max-width: 110px; }
.wf-grid > .form-item.f100 { flex: 0 0 100px; max-width: 100px; }
.wf-grid > .form-item.f95  { flex: 0 0 95px;  max-width: 95px; }
.wf-grid > .form-item.f90  { flex: 0 0 90px;  max-width: 90px; }
.wf-grid > .form-item.wfull { flex: 1 1 100%; max-width: 100%; }

/* 窄输入框内边距略收，避免文字被挤 */
.wf-grid > .form-item.f90 > input,
.wf-grid > .form-item.f95 > input,
.wf-grid > .form-item.f100 > input,
.wf-grid > .form-item.f110 > input,
.wf-grid > .form-item.f120 > input { padding-left: 10px; padding-right: 8px; }

/* 手机：短字段两列，长字段整行 */
@media (max-width: 820px) {
  .wf-grid > .form-item.f150,
  .wf-grid > .form-item.f160,
  .wf-grid > .form-item.f120,
  .wf-grid > .form-item.f110 { flex: 1 1 46%; max-width: 46%; }
  .wf-grid > .form-item.f100,
  .wf-grid > .form-item.f95,
  .wf-grid > .form-item.f90 { flex: 1 1 30%; max-width: 30%; }
  .wf-grid > .form-item.g300,
  .wf-grid > .form-item.g320,
  .wf-grid > .form-item.g200,
  .wf-grid > .form-item.g190,
  .wf-grid > .form-item.g180,
  .wf-grid > .form-item.g170,
  .wf-grid > .form-item.g150,
  .wf-grid > .form-item.wfull { flex: 1 1 100%; max-width: 100%; }
}

/* ============================================================
   2026-09-30：工单详情弹窗按「内容定宽」重排（用户反馈右侧空白太多）
   原来写死 grid-template-columns:1fr 1fr —— 每个字段固定半宽，
   短内容（日期/时间/用时/金额/数量）右边一大片空白。
   改为 flex + 基础宽度，字段按内容自动伸缩、自动换行铺满。
   ============================================================ */
.dt-grid {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 12px 10px !important;
  margin-bottom: 18px;
}
.dt-grid > div {
  flex: 1 1 140px;      /* 基础宽度，不足以内容为准；有余量则按比例伸长 */
  min-width: 0;
}
/* 客户：名字可能长，给更大基础宽度 */
.dt-grid-info > div:nth-child(1) { flex: 1 1 200px; }
/* 设计师：含头像+签名，给更宽 */
.dt-grid-info > div:nth-child(2) { flex: 1 1 240px; }
/* 登记日期 / 下单日期 / 交货日期：日期文本不算长 */
.dt-grid-info > div:nth-child(n+3) { flex: 0 1 160px; }
/* 时间（15:33 ~ 18:03）稍宽 */
.dt-grid-info > div:nth-child(4) { flex: 0 1 170px; }
/* 物料数值区：数量/面积/单价/总价等，短内容给窄一点 */
.dt-grid-nums > div { flex: 0 1 150px; }
/* 详情弹窗加宽（原 700 太窄，两列就撑满了） */
#recordDetailModal > .modal { max-width: 860px !important; width: 860px !important; }
@media (max-width: 900px) {
  #recordDetailModal > .modal { width: 100% !important; max-width: 100% !important; }
}
@media (max-width: 620px) {
  .dt-grid > div,
  .dt-grid-info > div:nth-child(1),
  .dt-grid-info > div:nth-child(2),
  .dt-grid-info > div:nth-child(n+3),
  .dt-grid-info > div:nth-child(4),
  .dt-grid-nums > div { flex: 1 1 100%; }
}

/* ============================================================
   2026-09-30（续）：详情弹窗剩余空白
   ① 字段按内容伸缩、吃掉行尾空白（原来固定宽度会留一大截）
   ② 「设计物料」「物料名称」与「单价」原本各占一行且只有一个方块，
      现在两个方块并排，不再留空。
   ============================================================ */
/* ①② 字段伸缩：行尾余量按比例补到各字段上，不再留白 */
.dt-grid > div { flex: 1 1 140px !important; }
.dt-grid-info > div:nth-child(1) { flex: 1 1 180px !important; }
.dt-grid-info > div:nth-child(2) { flex: 1.3 1 210px !important; }
.dt-grid-nums > div { flex: 1 1 130px !important; }

/* ③ 「设计物料 / 物料名称」标签行加个左侧色条，跟其他区块视觉统一 */
.dt-block > div:first-child {
  display: flex;
  align-items: center;
  gap: 7px;
}
.dt-block > div:first-child::before {
  content: '';
  width: 3px;
  height: 13px;
  border-radius: 2px;
  background: linear-gradient(180deg, #332C2B, #8fb0ff);
  flex-shrink: 0;
}

/* ============================================================
   2026-09-30：「取消该工单」移到底部按钮栏最左，大小与「编辑此工单」一致
   ============================================================ */
/* 左侧状态按钮，右侧「编辑/关闭」被 margin-left:auto 顶到右边 */
#recordDetailModal .modal-foot { display: flex; align-items: center; gap: 10px; }
#recordDetailModal .modal-foot #detailStatusBtn { margin-right: auto; }
/* 与「编辑此工单」同尺寸：同样的 padding / 圆角 / 字号，只换配色 */
#recordDetailModal .modal-foot .dt-status-cancel {
  background: #c0392b !important;
  border: 1px solid #c0392b !important;
  color: #fff !important;
  font-weight: 700;
}
#recordDetailModal .modal-foot .dt-status-cancel:hover { background: #a93226 !important; border-color: #a93226 !important; }
#recordDetailModal .modal-foot .dt-status-ok {
  background: #2e9e6c !important;
  border: 1px solid #2e9e6c !important;
  color: #fff !important;
  font-weight: 700;
}
#recordDetailModal .modal-foot .dt-status-ok:hover { background: #268a5e !important; border-color: #268a5e !important; }

/* ============================================================
   2026-09-30：「取消该工单」推到底部并靠右，与「编辑此工单/关闭」同一水平视觉区
   零 JS 改动：只给原有的状态按钮容器加 .dt-status-row
   ============================================================ */
/* 内容区撑满，让状态按钮能被 margin-top:auto 推到底 */
#recordDetailModal .modal form,
#recordDetailModal .modal > div[style*="padding:24px"] {
  display: flex !important;
  flex-direction: column;
  min-height: 0;
}
#recordDetailModal #detailContent {
  flex: 1 1 auto;
  display: flex !important;
  flex-direction: column;
}
/* 状态按钮行：推到最底、内容靠右 */
#detailContent > .dt-status-row {
  margin-top: auto !important;
  display: flex !important;
  justify-content: flex-end !important;
}
/* 按钮尺寸与「编辑此工单」一致 */
#detailContent > .dt-status-row > button {
  flex: 0 0 auto !important;
  min-width: 96px;
  padding: 12px 22px !important;
  border-radius: 4px !important;
  font-size: 14px !important;
  font-weight: 700;
  cursor: pointer;
}

/* ============================================================
   2026-09-30：「取消该工单」显示在底部按钮栏（标红区）左侧
   做法：内容区那个按钮保持原位不动（只是视觉上移出视野），
        用 CSS 在 .modal-foot 左侧「神复制」一个同尺寸按钮；
        点击由 .modal-foot 上的委托事件转发过去。
   ============================================================ */
/* ① 内容区原按钮：推到最底 + 靠右（兜底，保证仍可用） */
#recordDetailModal #detailContent { display: flex !important; flex-direction: column; }
#detailContent > .dt-status-row { margin-top: auto !important; justify-content: flex-end !important; }
/* ② 底部按钮栏左侧「神复制」按钮 */
#recordDetailModal .modal-foot { position: relative; padding-left: 120px !important; }
#recordDetailModal .modal-foot::before {
  content: '取消该工单';
  position: absolute;
  left: 22px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 96px;
  height: 37px;
  padding: 0 18px;
  box-sizing: border-box;
  border-radius: 4px;
  background: #c0392b;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background .16s;
}
#recordDetailModal .modal-foot::before:hover { background: #a93226; }
/* 已作废时：文案与颜色换成「恢复该工单」（用 data 属性切换） */
#recordDetailModal[data-detail-cancelled="1"] .modal-foot::before {
  content: '恢复该工单';
  background: #2e9e6c;
}
#recordDetailModal[data-detail-cancelled="1"] .modal-foot::before:hover { background: #268a5e; }
/* 非管理员：隐藏这个伪按钮 */
#recordDetailModal[data-detail-nomanage="1"] .modal-foot::before { display: none; }
#recordDetailModal[data-detail-nomanage="1"] .modal-foot { padding-left: 22px !important; }

/* 2026-09-30：隐藏内容区那个真按钮行（只保留底部伪按钮，避免出现两个按钮）
   真按钮仍可用程序化 click 触发，点击由 .modal-foot 的委托事件转发。 */
#recordDetailModal #detailContent > .dt-status-row { display: none !important; }

/* ============================================================
   2026-09-30：修三个问题
   ① 编辑记录弹窗的提交按钮文案（JS 侧修）
   ② 从工单详情点「编辑此工单」时，详情弹窗没真正隐藏 ——
      JS 设的是内联 display:none，但 .modal-mask.open{display:flex!important}
      优先级更高，把它压回显示了，于是编辑窗被详情盖住。
      这里用一个更具体的规则，确保详情被隐藏。
   ③ 底部按钮栏 sticky 吸底时，会盖住最后一个分区约 84px（图片上传区被压住）。
      给可滚动区补出与 footer 等高的底部内边距。
   ============================================================ */
/* ② 编辑弹窗打开时，强制隐藏详情弹窗 */
#recordDetailModal[style*="display: none"] { display: none !important; }
/* ③ 给最后一个分区留出底部空间，别被吸底 footer 盖住 */

/* ============================================================
   2026-09-30（修正③）：footer 压住图片上传区
   实测：可滚动的是 <form>（clientH 647 / scrollH 897），
        footer 是 form 内的 sticky 元素。
   之前写的 form > *:last-child 命中的正是 footer 自己 → 反而把它撑到 130px。
   正确做法：给 <form> 补底部内边距，让最后一块内容能滚到 footer 上方。
   ============================================================ */
#editRecordModal .modal > form,
#materialModal .modal > form {
  padding-bottom: 90px !important;
}

/* ============================================================
   2026-09-30：① 已插入的图片放进虚线上传框里
             ② 底部按钮栏真正置底（不再压住内容）
   ============================================================ */
/* ① 虚线框内布局：文字居中；有图后图片铺在里面 */
.upload-area { display: flex !important; flex-direction: column; align-items: center; justify-content: center; }
.upload-area > .ua-text { display: block; width: 100%; text-align: center; }
.upload-area > .img-preview.ua-preview,
.upload-area > .ua-preview {
  display: flex !important;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 0;
  width: 100%;
  justify-content: center;
}
.upload-area > .ua-text + .ua-preview { margin-top: 10px; }
/* 上传框内已有图片时，整体左对齐更像"图库" */
.upload-area:has(> .ua-preview:not(:empty)) { align-items: flex-start; }

/* ② 按钮栏吸底显示，但内容区可以滚到它上方 —— 不压内容 */
#editRecordModal > .modal > form,
#materialModal > .modal > form {
  overflow: hidden !important;
  /* 关键：让 form 撑满弹窗剩余高度，footer 的 bottom:0 才是弹窗底部，
     否则会吸在表单内容中间 */
  flex: 1 1 auto !important;
  min-height: 0 !important;
  /* 预留与按钮栏等高的内边距，滚到底时最后一块内容停在按钮上方 */
  padding-bottom: 110px !important;
}
/* footer 吸底（始终可见），z-index 高于内容 */
#editRecordModal > .modal > form > .modal-foot,
#materialModal > .modal > form > .modal-foot {
  position: sticky !important;
  bottom: 0;
  z-index: 6;
  flex-shrink: 0 !important;
  background: #fff;
  box-shadow: 0 -6px 16px rgba(51,44,43,.06);
}

/* ============================================================
   2026-09-30：弹窗三段式布局 —— 头部固定 / 中间滚动 / 按钮栏固定
   用户要求：按钮可以浮着，但绝不能压内容。
   之前试过 sticky footer + padding-bottom，结果 padding 把吸底边界
   顶高了 110px，footer 困在弹窗中间。
   改为：内容包进 .modal-body 单独滚动，footer 作为 flex 尾部固定。
   ============================================================ */
#editRecordModal > .modal > form,
#materialModal > .modal > form {
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
  padding-bottom: 0 !important;
  min-height: 0 !important;
}
/* 中间内容区：唯一滚动容器 */
#editRecordModal > .modal > form > .modal-body,
#materialModal > .modal > form > .modal-body {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch;
}
/* 按钮栏：固定在最底部，不参与滚动、不覆盖内容 */
#editRecordModal > .modal > form > .modal-foot,
#materialModal > .modal > form > .modal-foot {
  position: static !important;
  flex-shrink: 0 !important;
  margin-top: 0 !important;
  z-index: 6;
  background: #fff;
  border-top: 1px solid #e6e9ef !important;
  box-shadow: 0 -6px 16px rgba(51,44,43,.06) !important;
}

/* 2026-09-30：上传框内的预览图 —— 点图只放大，不再触发「选文件」
   （上传框自身绑了 click→file.click()，图片在其内部会冒泡触发出选文件框） */
.upload-area > .ua-preview img[data-ua-full] { cursor: zoom-in; }

/* ============================================================
   2026-09-30：上传框右上角补一个「＋ 上传」小按钮
   背景：图片已移入上传框内，且点图片只放大不再触发选文件，
        所以需要一个明确的「继续上传」入口。
   ============================================================ */
.upload-area { position: relative; }
.upload-area > .ua-add {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  height: 26px;
  padding: 0 10px;
  border: 1px solid #cfd6e0;
  border-radius: 999px;
  background: rgba(255,255,255,.94);
  color: #5a6472;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.upload-area > .ua-add:hover {
  background: #332C2B;
  border-color: #332C2B;
  color: #fff;
}
/* 手机上按钮略小，避免挡到图片 */
@media (max-width: 768px) {
  .upload-area > .ua-add { height: 24px; padding: 0 8px; font-size: 11px; top: 6px; right: 6px; }
}

/* ============================================================
   2026-09-30：往来欠款面板右侧加「费用 + 欠款」汇总
   ============================================================ */
#debtPanel .debt-flex {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  flex-wrap: wrap;
}
#debtPanel .debt-left { flex: 1 1 520px; min-width: 0; padding: 2px 2px 6px; }
#debtPanel .debt-summary {
  flex: 0 1 320px;
  min-width: 260px;
  background: linear-gradient(180deg, #fbfbfa, #f6f7f9);
  border: 1px solid #edeae5;
  border-radius: 12px;
  padding: 14px 16px;
}
#debtPanel .ds-head {
  font-size: 12.5px; font-weight: 700; color: #6b625c;
  margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px dashed #e4dfd8;
}
#debtPanel .ds-head b { color: #2f2a27; }
#debtPanel .ds-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  font-size: 13px; color: #6b625c; padding: 5px 0;
}
#debtPanel .ds-row b { font-size: 16px; font-weight: 800; color: #2f2a27; white-space: nowrap; }
#debtPanel .ds-row b.ds-debt { color: #c0392b; }
#debtPanel .ds-sub { font-size: 11.5px; color: #9a9089; padding: 0 0 6px; line-height: 1.6; }
#debtPanel .ds-total {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin-top: 8px; padding-top: 10px; border-top: 1px solid #e4dfd8;
  font-size: 13px; font-weight: 700; color: #2f2a27;
}
#debtPanel .ds-total b { font-size: 22px; font-weight: 800; color: #2f2a27; white-space: nowrap; }
#debtPanel .ds-note { font-size: 11px; color: #a8a09a; margin-top: 8px; line-height: 1.6; }
@media (max-width: 900px) {
  #debtPanel .debt-summary { flex: 1 1 100%; min-width: 0; }
}

/* ============================================================
   2026-10-03：物料工单弹窗
   ① 与设计工单同宽（860px），视觉统一
   ② 几个长标签字段加宽（面积 / 单价 / 成本单价），避免标签换行
   ============================================================ */
.wf-grid .form-item.f170 { flex: 0 0 170px !important; width: 170px !important; min-width: 170px !important; }
#addRecordModal > .modal { max-width: 860px !important; min-width: 720px !important; }

/* ============================================================
   2026-10-03：物料工单弹窗排版（用户要求）
   ① 客户字段要同时放下 select + 「+ 新客户」按钮（74px），故加宽
   ② 部门跟客户/设计师同排，日期独占一行
   ③ 成本总额缩短，交货日期上移与下单日期同排
   ④ 新增宽度档位 g240/g260/f135/f160/f190
   ============================================================ */
.wf-grid .form-item.g240 { flex: 0 0 240px !important; width: 240px !important; min-width: 240px !important; }
.wf-grid .form-item.g260 { flex: 0 0 260px !important; width: 260px !important; min-width: 260px !important; }
.wf-grid .form-item.f135 { flex: 0 0 135px !important; width: 135px !important; min-width: 135px !important; }
.wf-grid .form-item.f160 { flex: 0 0 160px !important; width: 160px !important; min-width: 160px !important; }
.wf-grid .form-item.f190 { flex: 0 0 190px !important; width: 190px !important; min-width: 190px !important; }

/* 客户字段：select 可压缩，按钮不压缩不换行，保证按钮完整可见 */
#materialModal #mfCustomer,
#addRecordModal #arCustomer { min-width: 0 !important; }
#materialModal #btnAddCustomerMf,
#addRecordModal #btnAddCustomerAr { flex: 0 0 auto !important; white-space: nowrap !important; }
/* 部门旁边的提示文字不要撑高整行 */
#materialModal #mfDeptHint { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ============================================================
   2026-10-03：嵌套弹窗层级 —— 新建客户弹窗要盖在工单弹窗之上
   根因：custModal 和 materialModal 的 z-index 都是 99999，
        而 custModal 在 DOM 里更靠前 → 被工单弹窗盖住。
   ============================================================ */
#custModal { z-index: 100010 !important; }
#custModal.open { z-index: 100010 !important; }
.wf-grid .form-item.g236 { flex: 0 0 236px !important; width: 236px !important; min-width: 236px !important; }

/* ============================================================
   物料详情最终配宽（统一 150/128 档，视觉整齐）
   第1行 物料名称(grow→282) + 材质180 + 宽90 + 高150   + 3×10 = 732
   第2行 面积170 + 数量128 + 单位128 + 单价150 + 成本150 + 4×10 = 766 → 超 30，改下面数值
   第3行 物料总价190 + 成本总额190 + 下单153 + 交货153 + 3×10 = 732
   ============================================================ */
.wf-grid .form-item.f128 { flex: 0 0 128px !important; width: 128px !important; min-width: 128px !important; }
/* 第1行：物料名称自适应，其余固定 */
/* 第2行：成本单价吃掉剩余 */
/* 第3行：日期字段吃掉剩余，两半均分 */
/* 物料详情终稿：第2行 面积150 + 数量128 + 单位128 + 单价136 + 成本单价(grow→184) + 4×10 = 736 ✅ */

/* ============================================================
   /* ============================================================
   /* ============================================================
   

/* ============================================================
   2026-10-03【按用户要求：弹窗 960px，字段缩短】
   两个弹窗（设计/物料）统一 960px；字段宽度用内联样式精确控制
   ============================================================ */
#materialModal .form-section, #editRecordModal .form-section { padding: 22px !important; }
#materialModal .wf-grid, #editRecordModal .wf-grid {
  display: flex !important; flex-wrap: wrap !important;
  align-items: flex-start !important; gap: 12px !important;
}
#materialModal .wf-grid > .form-item, #editRecordModal .wf-grid > .form-item {
  display: flex !important; flex-direction: column !important;
  flex-grow: 0 !important; flex-shrink: 0 !important;
  grid-column: auto !important; padding: 0 !important; margin: 0 !important;
}
/* 字段外观（只给输入框/下拉框加高度，不要碰容器） */
#materialModal .wf-grid input, #materialModal .wf-grid select,
#editRecordModal .wf-grid input, #editRecordModal .wf-grid select {
  height: 40px !important; border-radius: 10px !important; font-size: 13px !important;
}
#materialModal .wf-grid label, #editRecordModal .wf-grid label {
  font-size: 12px !important; color: #8a8079 !important; margin-bottom: 6px !important;
}
/* 换行标记：强制物料详情在这里断行（宽度 100% 的不可见元素） */
#materialModal .wf-grid > .row-break { flex: 0 0 100% !important; height: 0 !important; margin: 0 !important; padding: 0 !important; }
@media (max-width: 760px) { #materialModal .wf-grid > .row-break { display: none !important; } }

/* ============================================================================
   2026-10-03【物料详情重新分行 + 每行右侧对齐】
   用户要求：
     第1排  物料名称 | 材质 | 宽（cm）| 高（cm）| 面积（㎡）| 数量 | 单位
     第2排  单价（元）| 成本单价（元）| 物料总价 | 成本总额 | 下单日期 | 交货日期
   做法：给每排最后一个字段 flex:1 1 auto，它自动吃掉剩余宽度 →
        既保证在这一格换行，又保证右边跟卡片对齐。
   物料详情区网格 = 13 个字段（前4个是基本信息，第2..4个属于基本信息区）
   ============================================================================ */
/* 基本信息行（4个：客户 设计师 部门 日期）→ 日期补满 */
/* 物料详情区（13个）*/
#materialModal .wf-grid:has(#mfItemName) > * { min-width: 0 !important; }
/* 第1排最后一个 = 单位（第11个）→ 单位补满，强制其后换行 */
/* 第2排最后一个 = 交货日期（第13个）→ 补满右侧 */
/* 第13个 = 下单日期（固定）*/
/* 第14个 = 交货日期（补满右侧）*/
/* 第12个 = 成本总额（固定）*/
/* 取消之前对第4、第9个的补满（现在它们不是行末了） */
/* 设计工单：基本信息第5个（结束时间）补满；设计详情第4个（金额）补满 */

/* 填充格：只吸收行内剩余宽度，不显示（用于让每行右侧跟卡片边缘对齐、且不产生换行） */
#materialModal .wf-grid > .fill-gap {
  flex: 1 1 0 !important; min-width: 0 !important;
  height: 0 !important; padding: 0 !important; margin: 0 !important;
  border: 0 !important; background: none !important;
}
/* 第一排：数量+单位+填充格 一起吸收剩余宽度，保证第一排铺满且不挤到第二排 */

/* ============================================================================
   2026-10-03【每行末尾加隐形填充格】
   好处：行内字段都是固定宽度 → 拖动不会把行挤崩、不会产生大片空白
        行末填充格自动吸收剩余宽度 → 右边始终跟卡片对齐
   ============================================================================ */
#materialModal .wf-grid > .fill-gap,
#editRecordModal .wf-grid > .fill-gap {
  flex: 1 1 0 !important; min-width: 0 !important;
  height: 0 !important; padding: 0 !important; margin: 0 !important;
  border: 0 !important; background: none !important;
}
/* 取消所有「自动补满」，改固定宽度（间距 12px，容器 822px） */
/* 用用户拖出来的宽度定稿（行末用填充格吸收剩余） */

/* ============================================================================
   2026-10-03【弹窗加宽到 1230px】让「物料行1」七个框能放一排
   宽度依据：用户自己在沙盒里拖出来的数值
   ============================================================================ */
#materialModal .form-section, #editRecordModal .form-section { padding: 22px !important; }

/* ============================================================================
   2026-10-03【定稿】弹窗 1230px；单位固定 90px；部门提示已删
   ============================================================================ */
#materialModal .form-section, #editRecordModal .form-section { padding: 22px !important; }
#mfDeptHint { display: none !important; }

/* ============================================================================
   2026-10-03【定稿 1000px】弹窗收窄，各行按内容宽度铺满
   ============================================================================ */
#materialModal .form-section, #editRecordModal .form-section { padding: 22px !important; }
#mfDeptHint { display: none !important; }
/* 换行标记：宽度占满一行，强制在这里断行（视觉上不可见、不占高度） */
#materialModal .wf-grid > .row-break,
#editRecordModal .wf-grid > .row-break {
  flex: 0 0 100% !important; height: 0 !important; margin: 0 !important;
  padding: 0 !important; border: 0 !important; background: none !important;
}
@media (max-width: 860px) {
  #materialModal .wf-grid > .row-break,
  #editRecordModal .wf-grid > .row-break { display: none !important; }
}
/* 自动换行点（由 form-rowfit.js 动态插入）—— 不可见、不占高度 */
#materialModal .wf-grid > .rb-fit,
#editRecordModal .wf-grid > .rb-fit {
  flex: 0 0 100% !important; height: 0 !important; margin: 0 !important;
  padding: 0 !important; border: 0 !important; background: none !important;
}

/* ============================================================================
   2026-10-04【新增客户弹窗】补上三段式布局：头固定 / 中间可滚 / 按钮栏固定
   原来缺 .modal-body，内容被底部按钮栏压住（结算方式看不到）
   ============================================================================ */
#custModal > .modal > form {
  display: flex !important; flex-direction: column !important;
  overflow: hidden !important; flex: 1 1 auto !important;
  min-height: 0 !important; padding-bottom: 0 !important;
}
#custModal > .modal > form > .modal-body {
  flex: 1 1 auto !important; min-height: 0 !important;
  overflow-y: auto !important; -webkit-overflow-scrolling: touch;
}
#custModal > .modal > form > .modal-foot {
  position: static !important; flex-shrink: 0 !important;
  margin-top: 0 !important; background: #fff;
  border-top: 1px solid #efeae2;
}
#custModal > .modal {
  display: flex !important; flex-direction: column !important;
  max-height: 92vh !important;
}

/* ============================================================================
   2026-10-04【新增客户弹窗】宽度对齐物料弹窗 1000px；字段宽度改由「栏宽调整」控制
   ============================================================================ */
#custModal > .modal {
  width: 1000px !important; max-width: 96vw !important; min-width: 0 !important;
  max-height: 92vh !important;
}
#custModal .modal-body { padding: 22px !important; }
#custModal .form-grid { gap: 15px 18px !important; }
/* 取消之前的 max-width 限制，让拖动说了算 */
#custModal .form-item input, #custModal .form-item select, #custModal .form-item textarea {
  max-width: 100% !important;
}

/* ============================================================================
   2026-10-04【自动补位 · 最终版】
   用 flex 换行：每个格子的宽度跟着里面的框走 →
     拖窄一个框，它占的地方就变小，后面的框自动往前补，不留空洞
     拖宽同理，装不下的自动换到下一行
   ============================================================================ */
#custModal .form-grid {
  display: flex !important; flex-wrap: wrap !important;
  gap: 15px 18px !important; align-items: flex-start !important;
}
#custModal .form-grid > .form-item {
  display: flex !important; flex-direction: column !important;
  flex: 0 0 auto !important; width: auto !important; min-width: 0 !important;
  max-width: 100% !important;
}
/* 整行字段（客户名称、类型、备注等）占满一行 */
#custModal .form-grid > .form-item.full { flex: 0 0 100% !important; width: 100% !important; }
/* 由「栏宽调整」控制每个框的宽度；这里不给字段写死宽度，
   避免跟用户拖出来的宽度打架，也避免误伤「结算方式/固定费用/结算周期」这种分组 */
#custModal .form-item input, #custModal .form-item select, #custModal .form-item textarea {
  width: 100% !important; max-width: 100% !important; box-sizing: border-box !important;
}

/* ============================================================================
   2026-10-04【新增客户弹窗】注释默认隐藏，鼠标移到对应字段时浮出说明
   只作用于 #custModal（灰色小字说明），不影响其它弹窗
   ============================================================================ */
#custModal div[style*="color:#999"][style*="margin-top"] {
  display: none !important;
}

/* ============================================================================
   2026-10-05【设计系统「登记工时」弹窗】
   ① 宽度与三段式布局对齐管理后台（680px → 1000px）
   ② 只登记设计工单：隐藏「记录类型」和「物料详情」
      （物料工单统一到「制作系统 → 物料工单」登记，避免两个入口重复）
   只作用于 #recModal，不影响设计系统其它弹窗
   ============================================================================ */
#recModal > .modal {
  width: 1000px !important; max-width: 98vw !important; min-width: 0 !important;
  max-height: 92vh !important;
}
#recModal > .modal > form {
  display: flex !important; flex-direction: column !important;
  overflow: hidden !important; min-height: 0 !important; padding-bottom: 0 !important;
}
#recModal > .modal > form > .modal-body {
  flex: 1 1 auto !important; min-height: 0 !important; overflow-y: auto !important;
  -webkit-overflow-scrolling: touch;
}
#recModal > .modal > form > .modal-foot {
  position: static !important; flex-shrink: 0 !important; margin-top: 0 !important;
  border-top: 1px solid #efeae2 !important;
}
/* 字段外观对齐管理后台 */
#recModal .wf-grid { gap: 12px !important; }
#recModal .wf-grid > .form-item {
  display: flex !important; flex-direction: column !important;
  padding: 0 !important; margin: 0 !important;
}
#recModal .wf-grid input, #recModal .wf-grid select, #recModal .wf-grid textarea {
  width: 100% !important; max-width: 100% !important; box-sizing: border-box !important;
}
#recModal .wf-grid input, #recModal .wf-grid select {
  height: 40px !important; border-radius: 10px !important; font-size: 13px !important;
}
#recModal .wf-grid label {
  font-size: 12px !important; color: #8a8079 !important; margin-bottom: 6px !important;
}
/* 只保留「设计工单」：记录类型 + 物料详情 一律不显示 */
#recModal .wf-grid > .form-item:has(#rfType) { display: none !important; }
#recModal .material-fields { display: none !important; }

/* ============================================================================
   2026-10-05【财务系统】导航二级项
   「催收」「收款码」挂在「欠账明细」下面：
     · 平时收起来（不展开）
     · 点「欠账明细」右边的 ▸ 箭头才展开
   ============================================================================ */
.fin-page .tabs .nav-sub-wrap { display: none; }
.fin-page .tabs .nav-sub-wrap.open { display: contents; }
.fin-page .tabs .nav-caret {
  display: inline-block;
  margin-left: 4px;
  padding: 4px 6px;              /* 加大点击区域，别让人点不中 */
  margin-right: -6px;
  font-size: 12px;
  color: #b8b0a8;
  transition: transform .15s;
  transform-origin: center;
  cursor: pointer;
}
.fin-page .tabs .nav-caret:hover { color: #fff; }
.fin-page .tabs .nav-caret.open { transform: rotate(90deg); color: #fff; }
.fin-page .tabs .tab.tab-sub {
  position: relative;
  padding-left: 32px !important;
  font-size: 12.5px !important;
  opacity: .9;
}
.fin-page .tabs .tab.tab-sub::before {
  content: '└';
  display: block !important;
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: #b8b0a8;
  line-height: 1;
}
.fin-page .tabs .tab.tab-sub .sico { width: 15px !important; height: 15px !important; }
@media (max-width: 760px) {
  .fin-page .tabs .tab.tab-sub { padding-left: 26px !important; }
  .fin-page .tabs .tab.tab-sub::before { left: 10px; }
}

