/**
 * 拣货端页面样式
 */

/* 全局：禁止左右滑动、禁止双击放大 */
html,
body {
  -webkit-text-size-adjust: 100%;
  /* manipulation：保留滚动，多数浏览器会禁用双击缩放，减轻依赖 JS 里 touchend preventDefault */
  touch-action: manipulation;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

/* 防止横向溢出，但不在 html/body 上设置 overflow，避免破坏 fixed 定位 */
#appContainer {
  overflow-x: hidden;
}

/* 允许输入框和文本区域的选择 */
input,
textarea {
  -webkit-user-select: auto;
  user-select: auto;
}

/* 登录页面 */
.login-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  padding: 16px;
  background: #f0f4f8;
}

.login-card {
  background: white;
  border-radius: 20px;
  width: 100%;
  max-width: 380px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.login-brand {
  background: linear-gradient(135deg, #1976d2 0%, #1565c0 100%);
  padding: 36px 24px 28px;
  text-align: center;
  color: white;
}

.login-brand-icon {
  width: 56px;
  height: 56px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin-bottom: 14px;
}

.login-brand h1 {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 4px;
  letter-spacing: 1px;
  white-space: nowrap;
}

.login-brand p {
  font-size: 13px;
  margin: 0;
  opacity: 0.75;
}

.login-form {
  padding: 24px 24px 16px;
}

.login-input-wrap {
  position: relative;
  margin-bottom: 14px;
}

.login-input-wrap input {
  width: 100%;
  height: 48px;
  padding: 0 14px 0 42px;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  font-size: 15px;
  background: #fafafa;
  box-sizing: border-box;
  outline: none;
  transition: all 0.2s;
  -webkit-appearance: none;
}

.login-input-wrap input:focus {
  background: white;
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

.login-input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 18px;
  color: #999;
  pointer-events: none;
}

.login-input-wrap:focus-within .login-input-icon {
  color: #2196f3;
}

.login-remember {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 13px;
  color: #666;
  margin-bottom: 18px;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.login-remember input[type='checkbox'] {
  display: none;
}

.login-remember .checkmark {
  width: 18px;
  height: 18px;
  border: 2px solid #ccc;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
  background: white;
}

.login-remember .checkmark::after {
  content: '';
  width: 4px;
  height: 8px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0);
  transition: transform 0.15s;
}

.login-remember input[type='checkbox']:checked + .checkmark {
  background: #2196f3;
  border-color: #2196f3;
}

.login-remember input[type='checkbox']:checked + .checkmark::after {
  transform: rotate(45deg) scale(1);
}

.login-btn {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}

.login-btn:active {
  transform: translateY(1px);
  box-shadow: 0 2px 6px rgba(33, 150, 243, 0.3);
}

.login-btn:disabled,
.login-btn.is-busy,
.login-btn[aria-disabled='true'] {
  opacity: 0.65;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none;
}

.login-btn:disabled:active,
.login-btn.is-busy:active {
  transform: none;
}

.login-error {
  margin-top: 10px;
  padding: 8px 12px;
  background: #ffebee;
  color: #c62828;
  border-radius: 8px;
  font-size: 13px;
  text-align: center;
  display: none;
}

.login-footer {
  padding: 0 24px 20px;
  text-align: center;
}

.login-hint {
  display: block;
  font-size: 12px;
  color: #aaa;
  margin-bottom: 10px;
}

.login-version {
  display: block;
  font-size: 11px;
  color: #888;
  margin-bottom: 8px;
  font-family: monospace;
}

.web-module-chooser-overlay {
  z-index: 10050;
}

.web-module-chooser-modal {
  width: min(92vw, 360px);
  padding: 24px 20px 16px;
  border-radius: 16px;
  text-align: center;
}

.web-module-chooser-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  border-radius: 14px;
  background: linear-gradient(135deg, #1976d2, #1565c0);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
}

.web-module-chooser-title {
  margin: 0 0 6px;
  font-size: 20px;
  color: #1565c0;
}

.web-module-chooser-hint {
  margin: 0 0 18px;
  font-size: 13px;
  color: #757575;
}

.web-module-chooser-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.web-module-btn {
  width: 100%;
  min-height: 46px;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.web-module-logout {
  width: 100%;
  margin-top: 12px;
  color: #888;
}

.login-config-btn {
  width: 100%;
  padding: 8px;
  font-size: 12px;
  color: #bbb;
  background: transparent;
  border: 1px dashed #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.2s;
}

.login-config-btn:hover {
  color: #2196f3;
  border-color: #bbdefb;
  background: #f0f7ff;
}

/* 主应用 */
.app-container {
  display: none;
  background: #f0f4f8;
  min-height: 100vh;
}

.app-header {
  background: white;
  padding: 12px 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto auto;
  align-items: center;
  min-height: 56px;
  column-gap: 2.5%;
}

.app-header-menu {
  grid-column: 1;
  flex-shrink: 0;
  min-width: 0;
  display: flex;
  align-items: center;
}

.app-header-title-wrap {
  grid-column: 2;
  display: flex;
  align-items: center;
  min-width: 0;
  overflow: hidden;
  justify-self: start;
}

.app-header-switch {
  grid-column: 3;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.app-header-sync {
  grid-column: 4;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.app-header-end {
  grid-column: 5;
  justify-self: end;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
  min-height: 40px;
}

.app-header-title-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 44px;
  min-height: 44px;
  max-height: 44px;
  gap: 1px;
  min-width: 0;
  overflow: hidden;
}

.app-header h2 {
  color: #333;
  font-size: 18px;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  line-height: 1.35;
  min-height: 1.35em;
  white-space: nowrap;
  flex: 0 0 auto;
  flex-shrink: 0;
}

.app-header-title-block h2 {
  font-size: 16px;
  gap: 6px;
  line-height: 1.15;
  min-height: 0;
  flex: 0 0 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.order-source-type {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  padding: 1px 6px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  flex-shrink: 0;
}

.order-source-type.is-local {
  background: #fff3e0;
  color: #e65100;
}

.order-source-type.is-online {
  background: #e8f5e9;
  color: #2e7d32;
}

.order-switch-mode {
  display: inline-flex;
  align-items: stretch;
  padding: 3px;
  border-radius: 10px;
  background: #e2e8f0;
  border: 1px solid #cfd8e3;
  flex-shrink: 0;
  width: 124px;
  min-width: 124px;
  height: 40px;
  min-height: 40px;
  box-sizing: border-box;
}

.order-switch-mode-btn {
  border: none;
  background: transparent;
  color: #78909c;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  padding: 0;
  border-radius: 7px;
  cursor: pointer;
  flex: 1 1 0;
  min-width: 0;
  width: 58px;
  height: 32px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.order-switch-mode-btn.active {
  background: linear-gradient(180deg, #42a5f5 0%, #1976d2 100%);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(25, 118, 210, 0.35);
}

.order-source-sync-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 40px;
  min-width: 72px;
  max-width: 72px;
  min-height: 40px;
  max-height: 40px;
  border: 1px solid #cfd8e3;
  border-radius: 10px;
  background: #fff;
  color: #1976d2;
  font-size: 18px;
  line-height: 1;
  padding: 0 8px;
  cursor: pointer;
  flex-shrink: 0;
  box-sizing: border-box;
}

.app-header-sync .order-source-sync-btn {
  margin: 0;
}

.order-source-sync-btn:active {
  background: #e3f2fd;
}

.order-source-sync-btn.is-syncing {
  pointer-events: none;
  opacity: 0.7;
}

.order-source-sync-btn.is-syncing .bi {
  animation: spin 1s linear infinite;
}

.order-source-sync-manual {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.order-source-sync-manual .bi {
  font-size: 24px;
  line-height: 1;
  color: #1976d2;
}

.order-source-sync-auto {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.order-source-sync-btn.is-countdown {
  border-color: #90caf9;
  background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%);
  box-shadow: 0 1px 4px rgba(25, 118, 210, 0.12);
}

.order-source-sync-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.order-source-sync-btn.is-countdown .bi {
  font-size: 18px;
  color: #1976d2;
  line-height: 1;
}

.order-source-sync-countdown-wrap {
  display: inline-flex;
  align-items: baseline;
  line-height: 1;
}

.order-source-sync-countdown {
  font-size: 14px;
  font-weight: 700;
  color: #1565c0;
  font-variant-numeric: tabular-nums;
  min-width: 1.2em;
  text-align: right;
}

.order-source-sync-unit {
  font-size: 10px;
  font-weight: 600;
  color: #607d8b;
  margin-left: 1px;
}

/* 顶栏菜单：圆角方块 + 蓝色系，与切换/刷新控件风格一致 */
.app-header .btn-menu-header {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
  border-radius: 10px;
  background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%);
  border: 1px solid #90caf9;
  color: #1565c0;
  box-shadow: 0 2px 6px rgba(25, 118, 210, 0.14);
}

.app-header .btn-menu-header:active {
  background: #e3f2fd;
  border-color: #64b5f6;
  transform: translateY(1px);
  box-shadow: 0 1px 3px rgba(25, 118, 210, 0.12);
}

body.picking-menu-open .app-header .btn-menu-header {
  background: linear-gradient(180deg, #42a5f5 0%, #1976d2 100%);
  border-color: #1976d2;
  color: #fff;
  box-shadow: 0 3px 8px rgba(25, 118, 210, 0.35);
}

.app-header-switch .order-switch-mode {
  flex-shrink: 0;
}

/* 同步状态指示器 */
.sync-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 12px;
  background: #f5f5f5;
  color: #666;
  transition: all 0.3s;
  white-space: nowrap;
}

.sync-status.sync-online {
  background: #e8f5e9;
  color: #2e7d32;
}

.sync-status.sync-offline {
  background: #fff3e0;
  color: #e65100;
}

.sync-status.sync-standalone {
  background: #f3e5f5;
  color: #7b1fa2;
}

.sync-status.sync-checking {
  background: #f5f5f5;
  color: #757575;
}

.sync-status.sync-syncing {
  background: #e3f2fd;
  color: #1565c0;
}

.sync-status.sync-done {
  background: #e8f5e9;
  color: #2e7d32;
}

.sync-status.sync-error {
  background: #ffebee;
  color: #c62828;
}

.sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
}

.sync-status.sync-syncing .sync-dot {
  animation: sync-pulse 1s infinite;
}

@keyframes sync-pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.4;
    transform: scale(0.7);
  }
}

/* 头部图标按钮 */
.btn-icon {
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: 50%;
  background: white;
  border: 1px solid #e0e0e0;
  color: #666;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-icon:hover {
  background: #f5f5f5;
  border-color: #bdbdbd;
  color: #333;
}

.btn-icon:active {
  background: #eeeeee;
}

/* 拣货菜单下拉 */
.menu-dropdown-wrap {
  position: relative;
}

.picking-menu-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  background: transparent;
}

body.picking-menu-open .menu-dropdown-wrap {
  z-index: 10001;
}

.menu-dropdown-panel {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  min-width: 150px;
  padding: 6px;
  z-index: 200;
  animation: menuFadeIn 0.15s ease;
}
@keyframes menuFadeIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.menu-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: #333;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
}
.menu-dropdown-item:hover {
  background: #f5f5f5;
}
.menu-dropdown-item:active {
  background: #eeeeee;
}
.menu-dropdown-item i {
  font-size: 16px;
  color: #666;
}

.app-content {
  padding: 20px;
  max-width: 1200px;
  margin: 0 auto;
}

/* 统计卡片：三列等宽 + space-between 自动留白，内外间距均按容器百分比缩放 */
.stats-grid {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: space-between;
  margin-bottom: 1.2%;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

/* 子分类标签行（放在已完成下方） */
.stats-sub-grid {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-bottom: 12px;
  padding-right: 0;
}

.stat-sub-card {
  background: white;
  border-radius: 10px;
  padding: 10px 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  transition: all 0.2s;
  border: 2px solid transparent;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 100px;
  user-select: none;
}

.stat-sub-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.stat-sub-card.active {
  border-color: #1976d2;
  background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
}

.stat-sub-card.active h4,
.stat-sub-card.active .value {
  color: #1976d2;
}

.stat-sub-card h4 {
  color: #666;
  font-size: 13px;
  font-weight: normal;
}

.stat-sub-card .value {
  font-size: 18px;
  font-weight: bold;
  color: #333;
}

.last-sync-time {
  font-size: clamp(10px, 2.8vw, 12px);
  line-height: 1.2;
  color: #999;
  text-align: right;
  padding: 0 2% 0.2em 0;
  margin-bottom: 0.15em;
  border-bottom: 1px solid #f0f0f0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stat-card {
  flex: 0 0 30%;
  width: 30%;
  max-width: 30%;
  min-width: 0;
  box-sizing: border-box;
  background: white;
  border-radius: 0.65em;
  padding: 3.5% 5%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: all 0.2s;
  border: 2px solid transparent;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: clamp(9px, 2.4vw, 13px);
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.stat-card.active {
  border-color: #1976d2;
  background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
}

.stat-card.active h3 {
  color: #1976d2;
}

.stat-card.active .value {
  color: #1976d2;
}

.stat-card h3 {
  color: #666;
  font-size: 1em;
  margin-bottom: 0.28em;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.stat-card .value {
  font-size: 2em;
  font-weight: bold;
  color: #333;
  line-height: 1;
}

/* ========== 订单列表 ========== */
.order-list {
  background: white;
  border-radius: 15px;
  padding: 0.55em 1em 1.15em;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  touch-action: pan-y;
  -ms-touch-action: pan-y;
}

#orderListContainer {
  touch-action: pan-y;
  -ms-touch-action: pan-y;
}

/* 与统计卡一致用 div；列表委托见 index.js ensureOrderListDelegation（INC-2026-015：旧 WebView target 常为文本节点） */
.order-card {
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  padding: 0.85em 0.85em 0.45em;
  margin-bottom: 15px;
  font-size: clamp(12px, 3.2vw, 14px);
  transition:
    box-shadow 0.2s,
    transform 0.1s;
  cursor: default;
  background: white;
  display: block;
  width: 100%;
  box-sizing: border-box;
  text-align: left;
  font: inherit;
  font-family: inherit;
  color: inherit;
  user-select: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.06);
}

/* 仅「开始拣货」按钮接收触摸，卡片其它区域不响应（INC-2026-129） */
.order-card > * {
  pointer-events: none;
}

.order-card .order-card-open-btn {
  pointer-events: auto;
}

a.order-card {
  text-decoration: none;
  color: inherit;
  outline: none;
  -webkit-user-drag: none;
}

.order-card:hover {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
  transform: translateY(-1px);
}

.order-card.order-done {
  opacity: 0.7;
}

.order-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 4px;
  min-width: 0;
}

.order-header-main {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.order-no-id {
  display: block;
  font-weight: bold;
  color: #333;
  font-size: 16px;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  max-width: 100%;
}

.order-header-sub {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.order-create-time {
  font-size: 11px;
  color: #888;
  font-weight: normal;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 0;
}

.order-sync-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 10px;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
  background: #e8f5e9;
  color: #2e7d32;
}

.order-sync-status.sync-realtime {
  background: #e8f5e9;
  color: #2e7d32;
}

.order-sync-status.sync-standalone {
  background: #f3e5f5;
  color: #7b1fa2;
}

.order-sync-status.sync-syncing {
  background: #e3f2fd;
  color: #1565c0;
}

.order-sync-status.sync-syncing .sync-dot {
  animation: sync-pulse 1s infinite;
}

.order-detail-sync-wrap {
  flex-shrink: 0;
  min-width: 72px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.order-detail-sync-wrap .order-sync-status {
  font-size: 12px;
  padding: 3px 8px;
}

.task-status {
  white-space: nowrap;
  flex-shrink: 0;
}

.order-card-info {
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed #eee;
}

.order-org {
  font-size: 13px;
  color: #555;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  gap: 4px;
}

.order-org i {
  color: #2196f3;
  font-size: 13px;
}

.order-demand-date {
  font-size: 13px;
  color: #e65100;
  display: flex;
  align-items: center;
  gap: 4px;
}

.order-demand-date i {
  color: #e65100;
  font-size: 13px;
}

.order-complete-time {
  font-size: 13px;
  color: #4caf50;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
}

.order-complete-time i {
  color: #4caf50;
  font-size: 13px;
}

.order-card-body {
  margin-bottom: 0.3em;
}

.order-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}

.order-stat {
  text-align: center;
  padding: 8px;
  background: #f8f9fa;
  border-radius: 8px;
}

.order-stat-value {
  font-size: 20px;
  font-weight: bold;
  color: #333;
}

.order-stat-label {
  font-size: 12px;
  color: #666;
  margin-top: 2px;
}

.order-progress-wrap {
  margin-bottom: 0.25em;
}

.order-exception-hint {
  color: #c62828;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.order-card-open-btn {
  border: none;
  background: transparent;
  padding: 0.15em 0.1em;
  margin: 0;
  margin-left: auto;
  flex: 0 0 auto;
  width: auto;
  max-width: 100%;
  font: inherit;
  font-size: 1em;
  line-height: 1.2;
  color: #1976d2;
  cursor: pointer;
  -webkit-tap-highlight-color: rgba(25, 118, 210, 0.12);
  touch-action: manipulation;
  -ms-touch-action: manipulation;
  pointer-events: auto;
}

.order-card-open-btn:active {
  opacity: 0.75;
}

.order-card-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding-top: 0.3em;
  border-top: 1px solid #f0f0f0;
  pointer-events: none;
}

/* ========== 订单详情页 ========== */
.order-detail-page {
  --order-detail-max-w: 800px;
  --order-detail-gutter: clamp(0.65em, 3.5vw, 0.94em);
  --order-detail-block-gap: clamp(0.55em, 3.2vh, 1em);
  display: none;
  flex-direction: column;
  background: #f0f4f8;
  height: 100vh;
  min-height: 100vh;
  padding-top: 0;
  box-sizing: border-box;
  overflow: hidden;
}

.order-detail-page:not(.order-detail-hidden) {
  display: flex !important;
}

/* 顶栏 + 扫描框 + 筛选：文档流纵向三块，等比间距（避免 PDA fixed 估算不足叠盖 tabs） */
.sticky-top-wrap {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: var(--order-detail-block-gap);
  width: 100%;
  max-width: var(--order-detail-max-w);
  margin: 0 auto;
  padding: clamp(0.3em, 1.2vh, 0.55em) var(--order-detail-gutter) clamp(0.45em, 2.2vh, 0.8em);
  font-size: clamp(13px, 3.6vw, 16px);
  background: transparent;
  box-sizing: border-box;
}

.sticky-top-wrap .filter-tabs {
  margin-bottom: 0;
  width: 100%;
  box-sizing: border-box;
}

/*
 * 部分 Android WebView：父级 display:none 时，内部 position:fixed（如 .order-detail-header）
 * 仍参与触摸命中，透明盖住下方订单列表；统计区在更上方故仍可点。
 * 隐藏态为整棵子树强制 pointer-events:none（见 INC-2026-009）。
 */
.order-detail-page.order-detail-hidden,
.order-detail-page.order-detail-hidden * {
  pointer-events: none !important;
}

.order-detail-page.order-detail-hidden {
  visibility: hidden !important;
}

/* 订单列表前台：再套一层 body 类，挡住仍可能泄漏的 fixed 层；与 index.js picking-order-list-mode 同步（INC-2026-010） */
body.picking-order-list-mode #orderDetailPage,
body.picking-order-list-mode #orderDetailPage * {
  pointer-events: none !important;
}

body.picking-order-list-mode #orderDetailPage {
  visibility: hidden !important;
}

body.picking-order-list-mode #containerListPage,
body.picking-order-list-mode #containerListPage * {
  pointer-events: none !important;
}

body.picking-order-list-mode #containerListPage {
  visibility: hidden !important;
}

.order-detail-header {
  position: relative;
  flex-shrink: 0;
  width: 100%;
  background: white;
  color: #333;
  padding: 0 0.75em;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid #e8eef3;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  height: 3rem;
  box-sizing: border-box;
}

.order-detail-header.header-hidden {
  display: none;
}

.order-detail-header h2 {
  font-size: 15px;
  margin: 0;
  color: #1976d2;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  text-align: center;
  min-width: 0;
}

.order-detail-header h2 .header-divider {
  opacity: 0.4;
  margin: 0 3px;
}

.order-detail-header button {
  background: #f0f4f8;
  color: #1976d2;
  border: 1px solid #e3f2fd;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.order-detail-header button:hover {
  background: #e3f2fd;
  border-color: #1976d2;
}

.order-detail-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  max-width: var(--order-detail-max-w);
  width: 100%;
  margin: 0 auto;
  padding: 0 var(--order-detail-gutter) 0;
  box-sizing: border-box;
  overflow: hidden;
}

.order-detail-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 calc(-1 * var(--order-detail-gutter));
  padding: 0 var(--order-detail-gutter);
}

.order-detail-page.order-detail-actions-visible .order-detail-scroll {
  padding-bottom: calc(68px + env(safe-area-inset-bottom, 0px));
}

/* 扫描框 */
.scan-box {
  display: none;
  align-items: center;
  gap: 8px;
  background: white;
  border-radius: 12px;
  padding: 0.5em 0.8em;
  margin: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  position: relative;
  flex-shrink: 0;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.scan-box > i:first-child {
  font-size: 20px;
  color: #2196f3;
  flex-shrink: 0;
  width: 22px;
  text-align: center;
}

.scan-box .scan-input {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  font-size: 1em;
  background: transparent;
  padding: 0.25em 0.15em;
  border-radius: 4px;
  min-width: 0;
  cursor: text;
  min-height: 2em;
}

.scan-box .scan-input:focus {
  background: rgba(33, 150, 243, 0.08);
}

/* 透明input覆盖在div上，接收扫描枪输入 */
.scan-box .scan-input input[type='text'] {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  border: none;
  outline: none;
  background: transparent;
  cursor: text;
  z-index: 2;
  padding: 0;
  margin: 0;
  color: transparent;
  caret-color: transparent;
}

/* value 和 placeholder 绝对定位叠放，切换时不影响布局 */
.scan-box .scan-value,
.scan-box .scan-placeholder {
  position: absolute;
  left: 2px;
  right: 2px;
  top: 50%;
  transform: translateY(-50%);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  pointer-events: none;
  z-index: 1;
}

.scan-box .scan-placeholder {
  color: #999;
}

.scan-box .scan-value {
  color: #333;
}

/* 扫描框焦点高亮 */
.scan-box:focus-within,
.scan-box.focused {
  box-shadow:
    0 0 0 3px rgba(33, 150, 243, 0.3),
    0 2px 12px rgba(33, 150, 243, 0.15);
  border: 1px solid #2196f3;
}

.scan-box:focus-within i,
.scan-box.focused i {
  color: #1976d2;
}

/* 订单信息卡片 */
.order-info-card {
  background: white;
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.offline-badge {
  display: inline-block;
  background: #ff9800;
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  margin-left: 8px;
  vertical-align: middle;
  letter-spacing: 0.5px;
}

/* 筛选标签 */
.filter-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 10px;
  background: white;
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  overflow-x: auto;
}

.filter-tab {
  flex: 0 0 auto;
  text-align: center;
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  position: relative;
  border: none;
  background: transparent;
}

.filter-tab:hover {
  background: #f3f4f6;
}

.filter-tab.active {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.tab-count {
  display: inline-block;
  margin-left: 4px;
  padding: 1px 6px;
  border-radius: 10px;
  font-size: 12px;
  background: rgba(0, 0, 0, 0.08);
  color: inherit;
}

.filter-tab.active .tab-count {
  background: rgba(255, 255, 255, 0.3);
}

/* 异常状态独立筛选 */
.exception-filter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px 24px;
  margin-bottom: 15px;
  padding: 0 4px;
}
.exception-checkbox {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: #666;
  cursor: pointer;
  user-select: none;
  transition: color 0.2s ease;
}
.exception-checkbox input[type='checkbox'] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: #f44336;
  margin: 0;
}
.exception-checkbox.checked {
  color: #f44336;
  font-weight: 500;
}
.unsubmitted-checkbox input[type='checkbox'] {
  accent-color: #1976d2;
}
.unsubmitted-checkbox.checked {
  color: #1976d2;
  font-weight: 500;
}

/* 商品列表 */
.product-list {
  margin-bottom: 0;
  padding-bottom: 8px;
}

.product-item {
  background: white;
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: box-shadow 0.2s;
  border-left: 4px solid #e0e0e0;
}

.product-item:hover {
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.product-item.product-done {
  border-left-color: #4caf50;
  background: #f8fff8;
}

.product-item.product-exception {
  border-left-color: #f44336;
  background: #fff8f8;
}

.product-item.product-highlight {
  border-left: 5px solid #00bcd4;
  background: linear-gradient(90deg, rgba(0, 188, 212, 0.14) 0%, transparent 100%);
  box-shadow:
    0 0 0 3px rgba(0, 188, 212, 0.35),
    0 6px 20px rgba(0, 188, 212, 0.18);
  transform: scale(1.02);
  transition: all 0.3s ease;
  z-index: 1;
  position: relative;
}

.product-item.product-selected {
  background: #e3f2fd;
  border-left-color: #2196f3;
  box-shadow: 0 4px 16px rgba(33, 150, 243, 0.2);
  transform: scale(1.01);
  transition: all 0.2s ease;
}

.product-main {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 6px;
}

.product-info {
  flex: 1;
}

.product-name {
  font-size: 16px;
  font-weight: bold;
  color: #333;
  margin-bottom: 6px;
}

.product-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #666;
  flex-wrap: nowrap;
  white-space: nowrap;
  overflow: hidden;
}

.product-meta-sep {
  flex-shrink: 0;
  display: inline-block;
  width: 1px;
  height: 0.9em;
  min-height: 10px;
  background: #d0d5dd;
  margin: 0 1px;
}

.product-code,
.product-location,
.product-dept {
  flex-shrink: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-dept {
  max-width: 42%;
}

.product-diff {
  flex-shrink: 0;
  font-size: 12px;
  color: #666;
}

.product-diff strong {
  font-size: 13px;
}

.product-meta i {
  color: #999;
  margin-right: 0.12em;
  font-size: 0.95em;
}

.pack-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #e8f3ff;
  color: #1565c0;
  font-size: 12px;
  font-weight: 600;
}

.product-status-wrap {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
  margin-left: 8px;
}

.product-status {
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

/* 数量行：字号随父级宽度等比缩放 */
.product-qty-row {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  font-size: clamp(14px, 4vw, 18px);
  padding: 0.35em 0;
  border-top: 1px solid #f0f0f0;
  border-bottom: 1px solid #f0f0f0;
  margin-bottom: 0.65em;
  box-sizing: border-box;
}

.qty-task-block,
.qty-picked-block {
  flex: 0 1 auto;
  min-width: 0;
  white-space: nowrap;
  padding: 0;
  line-height: 1.2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.qty-task-block {
  align-items: flex-start;
}

.qty-picked-block {
  margin-left: auto;
  text-align: right;
  align-items: flex-end;
}

.qty-task-block.qty-task-matched,
.qty-picked-block.qty-picked-editable {
  gap: 0.1em;
}

.qty-picked-block.qty-picked-editable {
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(25, 118, 210, 0.12);
  user-select: none;
  -webkit-user-select: none;
  padding: 0.15em 0.3em;
  margin: -0.15em -0.3em;
  border-radius: 0.45em;
  box-sizing: border-box;
}

.qty-picked-block.qty-picked-editable:active .qty-inline-display.editable {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.2);
  background: #e3f2fd;
}

.qty-task-spacer {
  visibility: hidden;
  pointer-events: none;
}

.qty-edit-hint {
  font-size: 0.65em;
  color: #1976d2;
  line-height: 1.1;
  white-space: nowrap;
  margin-top: 0;
}

.qty-edit-hint .bi {
  font-size: 1em;
  margin-right: 0.2em;
}

.qty-label {
  font-size: 1em;
  color: #666;
  flex-shrink: 0;
}

.qty-label strong {
  color: #333;
  font-size: 1.55em;
  line-height: 1.1;
}

.qty-pieces {
  font-size: 0.72em;
  color: #888;
  font-weight: normal;
  margin-left: 0.15em;
  white-space: nowrap;
}

.qty-controls {
  display: flex;
  gap: 12px;
}

.qty-btn {
  width: 44px;
  height: 44px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: 18px;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
}

/* 行内数量输入框（包裹在 .qty-input-group 中） */
.qty-input-group {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 0 4px;
  background: #f0f7ff;
  border: 1px solid #bbdefb;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s;
  vertical-align: middle;
  flex-shrink: 0;
}

.qty-input-group:hover {
  background: #e3f2fd;
  border-color: #2196f3;
}

.qty-input-group:active {
  transform: scale(0.97);
}

.qty-input-group .qty-inline-input {
  width: 60px;
  min-width: 60px;
  border: none;
  background: transparent;
  padding: 0;
  height: 28px;
  line-height: 28px;
  font-size: 18px;
  font-weight: bold;
  color: #1976d2;
  cursor: pointer;
  text-align: center;
  outline: none;
}

.qty-input-group .qty-inline-input:focus {
  box-shadow: none;
}

.qty-input-group .qty-inline-input:disabled {
  background: transparent;
  color: #999;
  cursor: not-allowed;
}

.qty-edit-icon {
  font-size: 12px;
  color: #64b5f6;
}

/* 独立行内数量输入框（遗留兼容） */
.qty-inline-input {
  width: 60px;
  height: 32px;
  text-align: center;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  color: #333;
  outline: none;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
  padding: 0 4px;
}

.qty-inline-input:focus {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.2);
}

/* readonly 状态看起来和可编辑的一样（通过数字键盘修改，不触发系统输入法） */
.qty-inline-input[readonly] {
  background: white;
  color: #333;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
}

.qty-inline-input:disabled {
  background: #f5f5f5;
  color: #999;
  border-color: #ddd;
  cursor: not-allowed;
}

/* 已提交状态 */
.product-item.product-submitted {
  border-left-color: #9c27b0;
  background: #faf5ff;
  opacity: 0.85;
}

/* 重置按钮 */
.btn-warning {
  background: #ff9800;
  color: white;
  border: none;
}

.btn-warning:hover {
  background: #f57c00;
}

/* 提交按钮 */
.btn-primary {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  border: none;
}

/* 商品操作按钮统一样式 */
.product-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.product-actions .btn-action {
  flex: 0 0 auto;
  min-width: 72px;
  height: 40px;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
  color: white;
  padding: 0 12px;
  white-space: nowrap;
}

.product-actions .btn-action:active {
  transform: translateY(1px);
}

/* 颜色变体 */
.product-actions .btn-action.btn-success {
  background: linear-gradient(135deg, #4caf50 0%, #388e3c 100%);
  box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}
.product-actions .btn-action.btn-success:active {
  box-shadow: 0 2px 6px rgba(76, 175, 80, 0.3);
}

.product-actions .btn-action.btn-success:disabled,
.product-actions .btn-action.btn-success.is-finishing {
  opacity: 0.65;
  cursor: not-allowed;
  pointer-events: none;
  transform: none;
  box-shadow: none;
}

.product-actions .btn-action.btn-danger {
  background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
  box-shadow: 0 4px 12px rgba(244, 67, 54, 0.3);
}
.product-actions .btn-action.btn-danger:active {
  box-shadow: 0 2px 6px rgba(244, 67, 54, 0.3);
}

.product-actions .btn-action.btn-primary {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}
.product-actions .btn-action.btn-primary:active {
  box-shadow: 0 2px 6px rgba(33, 150, 243, 0.3);
}

.product-actions .btn-action.btn-warning {
  background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%);
  box-shadow: 0 4px 12px rgba(255, 152, 0, 0.3);
}
.product-actions .btn-action.btn-warning:active {
  box-shadow: 0 2px 6px rgba(255, 152, 0, 0.3);
}

/* 次要文字按钮（重置等） */
.product-actions .btn-action.btn-text {
  background: transparent;
  color: #999;
  font-size: 13px;
  font-weight: 400;
  box-shadow: none;
  border: 1px dashed #ddd;
  height: 36px;
}
.product-actions .btn-action.btn-text:active {
  color: #2196f3;
  border-color: #bbdefb;
  background: #f0f7ff;
}

/* 将按钮推到最右侧 */
.product-actions .btn-push-right {
  margin-left: auto;
}

/* 底部操作：固定底栏，仅「全部」标签由 JS 展示 */
.order-actions {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 95;
  padding: 12px 15px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  background: #fff;
  border-top: 1px solid #e8e8e8;
  box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.06);
  margin: 0;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.order-actions .btn {
  width: 100%;
  min-height: 44px;
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  border-radius: 10px;
}

.order-actions.order-actions-pending,
.order-actions.order-actions-tab-hidden {
  display: none;
  pointer-events: none;
}

/* 弹窗 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.modal-content {
  background: white;
  border-radius: 0;
  padding: 24px;
  width: 100vw;
  max-width: none;
  height: 100vh;
  max-height: none;
  overflow-y: auto;
  box-sizing: border-box;
  word-break: break-word;
  box-shadow: none;
}

/* 异常弹窗：放大 + 内容区滚动 + 按钮固定底部 */
.modal-exception {
  width: 100vw;
  max-width: none;
  max-height: none;
  height: 100vh;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-exception h3 {
  margin: 0;
  padding: 20px 24px 12px;
  font-size: 18px;
  flex-shrink: 0;
}

.modal-exception .modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 0 24px;
  -webkit-overflow-scrolling: touch;
}

.modal-exception .modal-footer {
  padding: 16px 24px 20px;
  flex-shrink: 0;
  border-top: 1px solid #f0f0f0;
}

.modal-content h3 {
  margin: 0 0 16px 0;
  font-size: 18px;
}

/* 一键提交订单确认：居中卡片（覆盖通用全屏 .modal-content） */
.complete-confirm-overlay {
  padding: 20px 16px;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.complete-confirm-modal.modal-content {
  width: 100%;
  max-width: 400px;
  height: auto;
  max-height: calc(100vh - 40px);
  margin: 0;
  padding: 0;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 16px 48px rgba(15, 23, 42, 0.22);
}

.complete-confirm-header {
  padding: 28px 20px 8px;
  text-align: center;
  flex-shrink: 0;
}

.complete-confirm-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #1565c0;
  line-height: 1;
}

.complete-confirm-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #1a237e;
  line-height: 1.35;
}

.complete-confirm-body {
  padding: 12px 22px 20px;
  flex: 0 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.complete-confirm-msg {
  margin: 0;
  font-size: 15px;
  line-height: 1.65;
  color: #455a64;
  text-align: center;
}

.complete-confirm-msg .complete-confirm-stat {
  font-weight: 700;
  color: #e65100;
  font-size: 17px;
}

.complete-confirm-msg strong {
  font-weight: 600;
  color: #37474f;
}

.complete-confirm-footer {
  flex-shrink: 0;
  display: flex;
  flex-direction: row;
  gap: 12px;
  padding: 16px 18px 18px;
  padding-bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid #e8ecf0;
  background: #f8fafc;
}

.complete-confirm-footer .btn {
  flex: 1 1 0;
  min-width: 0;
  min-height: 44px;
  margin: 0;
  padding: 10px 12px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  line-height: 1.3;
  box-sizing: border-box;
}

.complete-confirm-footer .btn-outline {
  background: #fff;
  border: 1px solid #cfd8e3;
  color: #546e7a;
}

.complete-confirm-footer .btn-primary {
  border: none;
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.32);
  color: #fff;
}

.complete-confirm-footer .btn-primary:active {
  transform: translateY(1px);
  box-shadow: 0 2px 6px rgba(33, 150, 243, 0.28);
}

/* 提交订单进度弹窗 */
.submit-progress-overlay {
  padding: 0;
  align-items: stretch;
  justify-content: stretch;
}

.submit-progress-modal.modal-content {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #f4f8fc;
}

.submit-progress-header {
  flex-shrink: 0;
  padding: 14px 18px;
  background: #fff;
  border-bottom: 1px solid #e8ecf0;
}

.submit-progress-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #263238;
  line-height: 1.4;
}

.submit-progress-title .bi {
  color: #1976d2;
  margin-right: 6px;
}

.submit-progress-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  padding: 0 20px 12px;
}

.submit-progress-hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 28px 8px 20px;
  min-height: 220px;
}

.submit-progress-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  line-height: 1;
  margin-bottom: 18px;
}

.submit-progress-icon--pending {
  background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
  color: #1565c0;
}

.submit-progress-icon--success {
  background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
  color: #2e7d32;
}

.submit-progress-icon--partial {
  background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
  color: #ef6c00;
}

.submit-progress-count {
  font-size: 32px;
  font-weight: 700;
  color: #1565c0;
  line-height: 1.2;
  letter-spacing: 0.02em;
}

.submit-progress-count.is-done {
  color: #2e7d32;
}

.submit-progress-count.is-partial {
  color: #ef6c00;
}

.submit-progress-status {
  margin-top: 10px;
  font-size: 14px;
  color: #607d8b;
  line-height: 1.5;
  max-width: 280px;
  word-break: break-all;
}

.submit-progress-bar-wrap {
  width: 100%;
  max-width: 280px;
  margin-top: 22px;
}

.submit-progress-bar {
  width: 100%;
  height: 8px;
  background: #dce4ec;
  border-radius: 4px;
  overflow: hidden;
}

.submit-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #42a5f5, #1976d2);
  border-radius: 4px;
  transition: width 0.25s ease;
}

.submit-progress-bar-fill.is-done {
  background: linear-gradient(90deg, #66bb6a, #43a047);
}

.submit-progress-bar-fill.is-partial {
  background: linear-gradient(90deg, #ffb74d, #f57c00);
}

.submit-progress-fail-list {
  flex-shrink: 0;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
  background: #fff;
  border-radius: 10px;
  padding: 4px 14px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.submit-progress-fail-list:empty {
  display: none;
}

.submit-progress-fail-item {
  padding: 10px 0;
  border-bottom: 1px solid #f0f4f8;
  font-size: 13px;
  line-height: 1.45;
  color: #c62828;
  text-align: left;
}

.submit-progress-fail-item:last-child {
  border-bottom: none;
}

.submit-progress-fail-item .fail-name {
  color: #37474f;
  font-weight: 600;
}

.submit-progress-footer {
  flex-shrink: 0;
  padding: 14px 18px;
  padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  background: #fff;
  border-top: 1px solid #e8ecf0;
}

.submit-progress-footer .btn {
  width: 100%;
  min-height: 48px;
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  border-radius: 10px;
  border: none;
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.28);
  color: #fff;
}

.submit-progress-footer .btn:active {
  transform: translateY(1px);
  box-shadow: 0 2px 6px rgba(33, 150, 243, 0.24);
}

/* 批量处理中遮罩 */
.batch-process-overlay {
  background: rgba(0, 0, 0, 0.55);
  z-index: 2000;
}

.batch-process-content {
  background: white;
  border-radius: 0;
  padding: 32px 28px;
  width: 100vw;
  max-width: none;
  height: 100vh;
  text-align: center;
}

.batch-spinner {
  font-size: 36px;
  color: #2196f3;
  margin-bottom: 16px;
}

.batch-process-title {
  font-size: 17px;
  font-weight: 600;
  color: #333;
  margin-bottom: 8px;
}

.batch-process-desc {
  font-size: 13px;
  color: #666;
  margin-bottom: 16px;
}

.batch-progress-bar {
  width: 100%;
  height: 6px;
  background: #e0e0e0;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 8px;
}

.batch-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #42a5f5, #1976d2);
  border-radius: 3px;
  transition: width 0.3s ease;
}

.batch-progress-text {
  font-size: 12px;
  color: #999;
}

/* 批量结果列表 */
.batch-result-list {
  max-height: 50vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.batch-result-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 14px;
}

.batch-result-item:last-child {
  border-bottom: none;
}

.batch-result-item .idx {
  color: #999;
  font-size: 12px;
  min-width: 28px;
  flex-shrink: 0;
}

.batch-result-item .name {
  color: #333;
  flex: 1;
  word-break: break-all;
}

.batch-result-item .reason {
  color: #f44336;
  font-size: 12px;
  margin-top: 2px;
}

/* 工具类 */
.text-success {
  color: #4caf50;
}
.text-danger {
  color: #f44336;
}
.text-primary {
  color: #2196f3;
}
.text-dark {
  color: #333;
}
.text-gray {
  color: #666;
}
.text-sm {
  font-size: 13px;
}

.flex {
  display: flex;
}
.flex-between-center {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.flex-1 {
  flex: 1;
}
.gap-10 {
  gap: 10px;
}
.mt-10 {
  margin-top: 10px;
}
.mt-15 {
  margin-top: 15px;
}
.mt-20 {
  margin-top: 20px;
}
.mb-10 {
  margin-bottom: 10px;
}
.mb-15 {
  margin-bottom: 15px;
}

/* 状态样式 */
.status-pending {
  background: #e3f2fd;
  color: #1976d2;
}
.status-processing {
  background: #fff3e0;
  color: #f57c00;
}
.status-completed {
  background: #e8f5e9;
  color: #388e3c;
}
.status-packed {
  background: #e8f4fd;
  color: #1565c0;
}
.status-exception {
  background: #ffebee;
  color: #c62828;
}

/* 进度条 */
.progress-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.progress-bar {
  flex: 1;
  height: 16px;
  background: #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #42a5f5, #1976d2);
  transition: width 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 11px;
  font-weight: bold;
}

.progress-text {
  font-size: 12px;
  color: #666;
  font-weight: 600;
  min-width: 36px;
  text-align: right;
}

/* 提示 */
.hint {
  text-align: center;
  margin-top: 20px;
  color: #999;
  font-size: 14px;
  padding: 30px;
}

/* 订单列表分批渲染底部加载（INC-2026-119） */
.order-list-batch-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px 12px 28px;
  color: #666;
  font-size: 14px;
  text-align: center;
}

.order-list-batch-loading .spin {
  font-size: 18px;
  color: #1976d2;
}

/* 加载动画 */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #f3f3f3;
  border-top: 3px solid #2196f3;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* 刷新按钮旋转动画 */
.spin-anim,
.spin {
  display: inline-block;
  animation: spin 0.6s linear infinite;
}

/* ========== 骨架屏加载动画 ========== */
@keyframes skeleton-shine {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.skeleton-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 15px;
}

.skeleton-stat {
  height: 88px;
  border-radius: 15px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-shine 1.5s infinite;
}

.skeleton-order {
  height: 130px;
  border-radius: 12px;
  margin-bottom: 12px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-shine 1.5s infinite;
}

/* 异常原因多选列表 */
.exception-reason-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}
.exception-reason-list label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: #f8f9fa;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  color: #333;
  transition: all 0.2s;
  border: 1px solid transparent;
}
.exception-reason-list label:hover {
  background: #e3f2fd;
  border-color: #bbdefb;
}
.exception-reason-list input[type='checkbox'] {
  width: 18px;
  height: 18px;
  accent-color: #2196f3;
  cursor: pointer;
}

/* 商品异常原因提示 */
.product-exception-reason {
  font-size: 12px;
  color: #c62828;
  margin-top: 6px;
  padding: 4px 10px;
  background: #ffebee;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* 响应式 */
@media (max-width: 768px) {
  .skeleton-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stat-card {
    flex-basis: 29%;
    width: 29%;
    max-width: 29%;
    padding: 3.5% 4%;
  }

  .app-content {
    padding: 10px;
  }

  .order-stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .product-status-wrap {
    margin-left: 6px;
  }

  .product-qty-row {
    flex-direction: row;
    align-items: center;
    gap: 6px;
    padding: 8px 0;
  }

  .qty-task-block,
  .qty-picked-block {
    min-width: 0;
  }

  .qty-controls {
    flex-shrink: 0;
    gap: 8px;
  }

  .qty-btn {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
}

/* 手机屏幕（<=480px） */
@media (max-width: 480px) {
  .app-header {
    padding: 8px 12px;
    min-height: 48px;
    column-gap: 2%;
  }

  .app-header-end {
    min-height: 36px;
  }

  .app-header-title-block {
    height: 40px;
    min-height: 40px;
    max-height: 40px;
  }

  .app-header-title-block h2 {
    font-size: 14px;
    gap: 4px;
  }

  .order-source-type {
    font-size: 9px;
    padding: 1px 5px;
  }

  .order-switch-mode {
    width: 112px;
    min-width: 112px;
    height: 36px;
    min-height: 36px;
    padding: 2px;
  }

  .order-switch-mode-btn {
    font-size: 11px;
    width: 54px;
    height: 30px;
    min-height: 30px;
  }

  .order-source-sync-btn {
    width: 64px;
    height: 36px;
    min-width: 64px;
    max-width: 64px;
    min-height: 36px;
    max-height: 36px;
    font-size: 16px;
    padding: 0 6px;
  }

  .order-source-sync-manual .bi {
    font-size: 20px;
  }

  .order-source-sync-btn.is-countdown .bi {
    font-size: 16px;
  }

  .order-source-sync-countdown {
    font-size: 13px;
  }

  .app-header .btn-menu-header {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    font-size: 20px;
    border-radius: 9px;
  }

  .btn-icon {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }

  .login-container {
    padding: 12px;
    align-items: flex-start;
    padding-top: 24px;
  }

  .login-card {
    border-radius: 16px;
  }

  .login-brand {
    padding: 24px 16px 18px;
  }

  .login-brand-icon {
    width: 48px;
    height: 48px;
    font-size: 24px;
    margin-bottom: 10px;
  }

  .login-brand h1 {
    font-size: 18px;
  }

  .login-form {
    padding: 16px 16px 12px;
  }

  .login-input-wrap {
    margin-bottom: 10px;
  }

  .login-input-wrap input {
    height: 44px;
    font-size: 14px;
    border-radius: 10px;
  }

  .login-input-icon {
    font-size: 16px;
  }

  .login-remember {
    font-size: 12px;
    margin-bottom: 14px;
  }

  .login-btn {
    height: 44px;
    font-size: 15px;
    border-radius: 10px;
  }

  .login-footer {
    padding: 0 16px 16px;
  }

  .login-config-btn {
    padding: 6px;
  }

  .product-item {
    padding: 10px;
    margin-bottom: 8px;
  }

  .product-name {
    font-size: 14px;
    margin-bottom: 4px;
  }

  .product-meta {
    flex-wrap: wrap;
    gap: 4px 8px;
    font-size: 11px;
  }

  .product-diff {
    font-size: 11px;
  }

  .product-diff strong {
    font-size: 12px;
  }

  .product-status-wrap {
    margin-left: 4px;
  }

  .product-status {
    font-size: 10px;
    padding: 1px 6px;
  }

  .product-qty-row {
    flex-direction: row;
    align-items: stretch;
    gap: 6px;
    font-size: clamp(13px, 3.8vw, 16px);
    padding: 0.3em 0;
    margin-bottom: 0.55em;
  }

  .qty-task-block,
  .qty-picked-block {
    min-width: 0;
  }

  .qty-label {
    white-space: nowrap;
    flex-shrink: 0;
  }

  .qty-controls {
    flex-shrink: 0;
    gap: 6px;
  }

  .qty-btn {
    width: 32px;
    height: 32px;
    font-size: 14px;
    padding: 0;
  }

  .qty-input-group .qty-inline-input {
    width: 56px;
    min-width: 56px;
    font-size: 16px;
    height: 26px;
    line-height: 26px;
  }

  .qty-inline-display {
    width: 3.4em;
    height: 2em;
    line-height: 1.8em;
  }

  .product-actions {
    gap: 6px;
  }

  .product-actions .btn-action {
    height: 36px;
    font-size: 13px;
    border-radius: 8px;
    gap: 4px;
  }

  .product-actions .btn-action.btn-text {
    height: 32px;
    font-size: 12px;
  }
}

/* ========== 自定义数字键盘 ========== */
.num-keyboard {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #f5f5f5;
  border-top: 1px solid #ddd;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  padding: 10px 12px 16px;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

/* 列表页：避免 fixed 键盘层在部分 WebView 上仍参与命中，挡住底部订单区 */
#numKeyboard.num-keyboard-hidden {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
}

.num-keyboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 8px 10px;
  margin-bottom: 6px;
  border-bottom: 1px solid #e0e0e0;
}

.num-keyboard-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
  padding-right: 8px;
}

.num-keyboard-info span:first-child {
  font-size: 14px;
  color: #666;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.num-keyboard-task-qty {
  font-size: 12px;
  color: #e65100;
  font-weight: 600;
}

.num-keyboard-value {
  font-size: 24px;
  font-weight: bold;
  color: #1976d2;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, monospace;
  min-width: 60px;
  text-align: right;
  transition: all 0.2s;
  border-radius: 4px;
  padding: 2px 8px;
}

.num-keyboard-value.selected {
  background: #e3f2fd;
  box-shadow: 0 0 0 2px #2196f3;
}

.num-keyboard-hint {
  text-align: center;
  font-size: 12px;
  color: #999;
  padding: 0 8px 8px;
  min-height: 18px;
}

.num-keyboard-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 8px;
}

.num-key {
  height: 56px;
  border: none;
  border-radius: 10px;
  background: white;
  color: #333;
  font-size: 22px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
  transition: all 0.1s;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  touch-action: manipulation;
}

.num-key:active,
.num-key.active {
  background: #e3f2fd;
  transform: scale(0.96);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.num-key-action {
  background: #eceff1;
  color: #546e7a;
  font-size: 18px;
}

.num-key-action:active,
.num-key-action.active {
  background: #cfd8dc;
}

.num-key-confirm {
  width: 100%;
  height: 52px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #42a5f5 0%, #1976d2 100%);
  color: white;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(25, 118, 210, 0.3);
  transition: all 0.1s;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  touch-action: manipulation;
}

.num-key-confirm:active,
.num-key-confirm.active {
  transform: scale(0.98);
  box-shadow: 0 1px 4px rgba(25, 118, 210, 0.2);
}

/* 键盘显示时给页面底部增加间距 */
body.keyboard-open {
  padding-bottom: 340px;
}

/* 行内数量显示（点击打开数字键盘） */
.qty-inline-display {
  display: inline-block;
  width: 3.6em;
  height: 2.15em;
  line-height: 1.95em;
  text-align: center;
  border: 2px solid #e0e0e0;
  border-radius: 0.45em;
  font-size: 1.1em;
  font-weight: bold;
  color: #333;
  background: white;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  vertical-align: middle;
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background 0.2s;
}

.qty-inline-display.editable {
  position: relative;
  border-color: #64b5f6;
  background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%);
  box-shadow: 0 1px 5px rgba(25, 118, 210, 0.18);
  color: #1565c0;
}

.qty-inline-display .qty-edit-icon {
  position: absolute;
  right: 0.25em;
  top: 0.2em;
  font-size: 0.62em;
  line-height: 1;
  color: #1976d2;
  opacity: 0.9;
  pointer-events: none;
}

.qty-inline-display.qty-inline-readonly {
  border-color: #dce4ec;
  background: #f5f7fa;
  color: #333;
  cursor: default;
  box-shadow: none;
}

.qty-inline-display.editable:active {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.2);
  background: #e3f2fd;
}

.qty-picked-block.qty-picked-editable .qty-inline-display.editable {
  cursor: inherit;
}

.qty-picked-block.qty-picked-editable .qty-inline-display.editable:active {
  border-color: #64b5f6;
  box-shadow: 0 1px 5px rgba(25, 118, 210, 0.18);
  background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%);
}

.qty-inline-display:not(.editable):not(.qty-inline-readonly) {
  background: #f5f5f5;
  color: #999;
  border-color: #ddd;
  cursor: not-allowed;
}

/* 扫描框数字键盘按钮 */
.btn-numkey {
  width: 38px;
  height: 38px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: #eceff1;
  color: #546e7a;
  border: 1px solid #cfd8dc;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.btn-numkey:active {
  background: #cfd8dc;
  transform: scale(0.95);
}

.btn-numkey i {
  font-size: 18px !important;
  color: #546e7a !important;
}

/* ========== 服务器设置 ========== */
.server-config-modal {
  max-width: none;
  width: 100vw;
  height: 100vh;
}

.server-config-modal h3 {
  display: flex;
  align-items: center;
  gap: 8px;
}

.current-server-info {
  background: #f0f4f8;
  border-radius: 8px;
  padding: 10px 12px;
  margin-top: 12px;
  font-size: 13px;
  word-break: break-all;
}

.current-server-info .label {
  color: #666;
}

.current-server-info .value {
  color: #2196f3;
  font-weight: 600;
}

/* 服务器地址输入行：输入框 + 扫一扫按钮 */
.server-input-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.server-input-row input {
  flex: 1;
  min-width: 0;
}

.btn-scan {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-scan:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

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

.saved-servers-section {
  margin-top: 15px;
}

.saved-servers-section label {
  display: block;
  font-size: 13px;
  color: #666;
  margin-bottom: 8px;
}

.saved-servers-list {
  max-height: 160px;
  overflow-y: auto;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  background: #fafafa;
}

.saved-server-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background 0.15s;
}

.saved-server-item:last-child {
  border-bottom: none;
}

.saved-server-item:hover {
  background: #f0f4f8;
}

.saved-server-item.active {
  background: #e3f2fd;
}

.saved-server-item.active .server-url {
  color: #1976d2;
  font-weight: 600;
}

.saved-server-item .server-url {
  font-size: 13px;
  color: #333;
  flex: 1;
  word-break: break-all;
  padding-right: 8px;
}

.saved-server-item .btn-delete {
  background: none;
  border: none;
  color: #ccc;
  font-size: 14px;
  cursor: pointer;
  padding: 4px;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  flex-shrink: 0;
}

.saved-server-item .btn-delete:hover {
  color: #ef4444;
  background: #fee;
}

/* ========== 版本信息（内嵌页） ========== */
.version-info-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.version-info-body {
  padding: 4px 0 8px;
}

.version-info-list {
  background: #f8f9fa;
  border-radius: 10px;
  padding: 12px;
}

.version-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 10px 0;
  border-bottom: 1px solid #e8e8e8;
  gap: 12px;
}

.version-item:last-child {
  border-bottom: none;
}

.version-label {
  font-size: 13px;
  color: #666;
  flex-shrink: 0;
  white-space: nowrap;
}

.version-value {
  font-size: 13px;
  color: #333;
  font-weight: 600;
  text-align: right;
  word-break: break-all;
}

.version-value.version-value-stale {
  color: #e65100;
}

.version-download-link {
  color: #1976d2;
  text-decoration: underline;
  cursor: pointer;
}

.version-download-link:active {
  opacity: 0.85;
}

.version-mismatch-hint {
  font-size: 12px;
  color: #e65100;
  line-height: 1.5;
  padding: 4px 0 10px;
  border-bottom: 1px solid #ffe0b2;
  margin-bottom: 4px;
}

.version-info-tools {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 12px 0 4px;
}

.version-info-tool-btn {
  display: flex;
  flex-direction: row;
  align-items: center;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
  color: #37474f;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  box-sizing: border-box;
}

.version-info-tool-btn:active {
  background: #eef2f7;
}

.version-info-tool-btn .bi-trash,
.version-info-tool-btn .bi-journal-text {
  font-size: 16px;
  color: #546e7a;
  margin-right: 10px;
}

.version-info-tool-label {
  flex: 1;
  text-align: left;
}

.version-info-tool-chevron {
  font-size: 14px;
  color: #90a4ae;
}

/* 版本信息弹窗底部：双按钮百分比等宽 + space-between 留白（PDA WebView 不依赖 gap） */
.version-info-footer {
  flex-shrink: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: stretch;
  padding: 0.75em 4%;
  padding-bottom: calc(0.75em + env(safe-area-inset-bottom, 0px));
  background: #fff;
  border-top: 1px solid #e8ecf0;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.06);
  box-sizing: border-box;
}

.version-info-footer .btn {
  flex: 0 0 47%;
  width: 47%;
  max-width: 47%;
  min-width: 0;
  min-height: 44px;
  margin: 0;
  padding: 0.55em 0.35em;
  font-size: clamp(12px, 3.5vw, 14px);
  font-weight: 600;
  border-radius: 8px;
  line-height: 1.3;
  white-space: nowrap;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.version-info-footer .btn i {
  font-size: 1.05em;
  margin-right: 0.35em;
}

.version-info-footer .btn-outline {
  background: #f0f4f8;
  border: 1px solid #cfd8e3;
  color: #455a64;
}

.version-info-footer .btn-outline:active {
  background: #e2e8f0;
}

.version-info-footer .btn-primary {
  border: none;
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.32);
  color: #fff;
}

.version-info-footer .btn-primary:active {
  transform: translateY(1px);
  box-shadow: 0 2px 6px rgba(33, 150, 243, 0.28);
}

.version-info-footer-inline {
  justify-content: center;
  margin-top: 8px;
  border-top: none;
  box-shadow: none;
  padding-left: 0;
  padding-right: 0;
}

.version-info-footer-inline .btn {
  flex: 1 1 auto;
  width: 100%;
  max-width: 100%;
}

/* 修改密码弹窗 */
.change-password-overlay {
  z-index: 10050;
}

.change-password-body {
  text-align: left;
}

.change-password-modal .form-group input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.2s;
}

.change-password-modal .form-group input:focus {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.15);
}

/* 用户信息（内嵌页，INC-2026-186） */
.user-info-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.user-info-body {
  padding: 4px 0 8px;
}

.user-info-footer {
  padding-top: 8px;
}

.user-info-footer .btn {
  width: 100%;
  min-height: 44px;
}

.user-info-list {
  background: #f8f9fa;
  border-radius: 10px;
  padding: 12px;
}

/* 表单输入框统一 */
.user-info-panel .form-group input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.2s;
}

.user-info-panel .form-group input:focus {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.15);
}

/* 我的设备列表 */
.my-device-list {
  background: #f8f9fa;
  border-radius: 10px;
  padding: 8px 12px;
}

.my-device-list.is-expanded {
  max-height: 200px;
  overflow-y: auto;
}

.my-login-log-list.is-expanded {
  max-height: 250px;
  overflow-y: auto;
}

.user-info-list-item-hidden {
  display: none;
}

.my-device-list.is-expanded .user-info-list-item-hidden,
.my-login-log-list.is-expanded .user-info-list-item-hidden {
  display: block;
}

.user-info-list-more-btn {
  display: block;
  width: 100%;
  margin-top: 0.5em;
  padding: 0.45em 0;
  border: none;
  background: transparent;
  color: #1976d2;
  font-size: clamp(12px, 3.2vw, 13px);
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
  cursor: pointer;
}

.user-info-list-more-btn:active {
  opacity: 0.75;
}

.my-device-item {
  padding: 10px 0;
  border-bottom: 1px solid #e8e8e8;
  font-size: 13px;
}

.my-device-item:last-child {
  border-bottom: none;
}

.my-device-name {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #333;
  font-weight: 500;
  margin-bottom: 3px;
}

.my-device-current {
  font-size: 11px;
  color: #fff;
  background: #4caf50;
  padding: 1px 6px;
  border-radius: 10px;
  font-weight: normal;
}

.my-device-id {
  font-size: 11px;
  color: #999;
  word-break: break-all;
  margin-bottom: 2px;
}

.my-device-time {
  font-size: 11px;
  color: #999;
}

/* 登录记录列表 */
.my-login-log-list {
  background: #f8f9fa;
  border-radius: 10px;
  padding: 8px 12px;
}

.my-login-log-item {
  padding: 10px 0;
  border-bottom: 1px solid #e8e8e8;
  font-size: 13px;
}

.my-login-log-item:last-child {
  border-bottom: none;
}

.my-login-log-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.my-login-log-time {
  color: #333;
  font-weight: 500;
  font-size: 12px;
}

.my-login-log-status {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 10px;
}

.log-success .my-login-log-status {
  color: #2e7d32;
  background: #e8f5e9;
}

.log-fail .my-login-log-status {
  color: #c62828;
  background: #ffebee;
}

.my-login-log-detail {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: #666;
  margin-bottom: 2px;
}

.my-login-log-device {
  font-size: 11px;
  color: #999;
}

/* 管理员专用：天数筛选控件 */
.admin-days-filter {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  padding: 8px 12px;
}

.sync-days-row {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.sync-content-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-left: 26px;
}

.sync-opt-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: #666;
  cursor: pointer;
}

.sync-opt-label input[type="checkbox"] {
  margin: 0;
  width: 14px;
  height: 14px;
  cursor: pointer;
}

.days-input {
  width: 44px;
  height: 32px;
  padding: 0 4px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 13px;
  text-align: center;
  background: white;
  color: #333;
  outline: none;
}

.days-input:focus {
  border-color: #1976d2;
}

/* 隐藏数字输入框的上下箭头 */
.days-input::-webkit-outer-spin-button,
.days-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.days-input[type='number'] {
  -moz-appearance: textfield;
}

.version-info-extra-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-top: 0.5em;
  padding: 0.75em 0.85em;
  border: 1px solid #cfd8e3;
  border-radius: 8px;
  background: #f0f7ff;
  color: #1565c0;
  font-size: clamp(12px, 3.5vw, 14px);
  font-weight: 600;
  line-height: 1.3;
  cursor: pointer;
  box-sizing: border-box;
}

.version-info-extra-toggle:active {
  background: #e3f2fd;
}

.version-info-extra-toggle-label {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
}

.version-info-extra {
  margin-top: 0.5em;
}

.version-item-stack {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35em;
}

.version-value-block {
  text-align: left;
  width: 100%;
  font-weight: 500;
  line-height: 1.45;
}

/* 版本信息弹窗中的二维码 */
.version-qr-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0;
  margin: 8px 0;
  background: #f8f9fa;
  border-radius: 8px;
}

.version-qr-label {
  font-size: 13px;
  color: #666;
  margin-bottom: 8px;
}

.version-qr-canvas {
  width: 160px;
  height: 160px;
  border-radius: 4px;
}

/* 菜单项中的天数输入框微调 */
.menu-dropdown-item.admin-days-filter .days-input {
  height: 28px;
  width: 40px;
  font-size: 13px;
  margin: 0 2px;
}

.menu-dropdown-item.admin-days-filter span {
  font-size: 14px;
  color: #333;
}

/* 整单提交成功提示 */
.batch-result-success {
  font-size: 18px;
  font-weight: 700;
  color: #2e7d32;
  margin: 8px 0 6px;
}

.batch-result-exception-note {
  font-size: 13px;
  color: #d32f2f;
  margin: 0 0 4px;
}

.batch-result-complete-note {
  font-size: 13px;
  color: #2e7d32;
  margin: 0;
}

/* ========== 恢复联网按钮 ========== */
.reconnect-btn {
  color: #ff9800 !important;
  animation: reconnect-pulse 2s infinite;
}

@keyframes reconnect-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* ========== 登录失败 → 单机模式确认（居中卡片） ========== */
.standalone-confirm-overlay {
  padding: 20px 16px;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  background: rgba(15, 23, 42, 0.45);
}

.standalone-confirm-modal.modal-content {
  width: 100%;
  max-width: 360px;
  height: auto;
  max-height: calc(100vh - 40px);
  margin: 0;
  padding: 0;
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.28);
}

.standalone-confirm-header {
  padding: 26px 22px 6px;
  text-align: center;
  flex-shrink: 0;
}

.standalone-confirm-icon {
  width: 58px;
  height: 58px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #e65100;
  line-height: 1;
}

.standalone-confirm-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #1a237e;
  line-height: 1.35;
}

.standalone-confirm-body {
  padding: 10px 22px 18px;
  flex: 0 1 auto;
}

.standalone-confirm-msg {
  margin: 0 0 14px;
  font-size: 14px;
  line-height: 1.65;
  color: #546e7a;
  text-align: center;
}

.standalone-confirm-tips {
  margin: 0;
  padding: 12px 14px;
  list-style: none;
  background: #f5f9fc;
  border-radius: 10px;
  border: 1px solid #e3edf5;
}

.standalone-confirm-tips li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  line-height: 1.5;
  color: #455a64;
}

.standalone-confirm-tips li + li {
  margin-top: 8px;
}

.standalone-confirm-tips li i {
  color: #1976d2;
  font-size: 15px;
  margin-top: 2px;
  flex-shrink: 0;
}

.standalone-confirm-footer {
  flex-shrink: 0;
  padding: 14px 18px 18px;
  border-top: 1px solid #eef2f6;
  background: #fafbfc;
}

.standalone-confirm-footer .btn-primary {
  font-weight: 600;
}

/* ========== 恢复联网悬浮登录窗口 ========== */
.reconnect-login-modal {
  max-width: none;
  width: 100vw;
  height: 100vh;
}

.reconnect-login-modal h3 {
  margin-bottom: 16px;
}

.reconnect-login-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.reconnect-login-form .login-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.reconnect-login-form .login-input-icon {
  position: absolute;
  left: 12px;
  color: #999;
  font-size: 16px;
  z-index: 1;
}

.reconnect-login-form input {
  width: 100%;
  padding: 12px 12px 12px 40px;
  border: 1px solid #ddd;
  border-radius: 10px;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.reconnect-login-form input:focus {
  border-color: #1976d2;
}

.reconnect-login-form .login-error {
  color: #ef4444;
  font-size: 13px;
  text-align: center;
  padding: 4px 0;
  min-height: 22px;
}

/* ========== 筛选页签切换性能优化：CSS 控制显示/隐藏（INC-2026-029） ========== */
/* all: 默认全部显示，无需额外规则 */

/* pending: 只显示 status=0（待拣货） */
#orderListContainer.filter-pending .order-card[data-status='1'],
#orderListContainer.filter-pending .order-card[data-status='2'] {
  display: none !important;
}

/* processing: 只显示 status=1（进行中） */
#orderListContainer.filter-processing .order-card[data-status='0'],
#orderListContainer.filter-processing .order-card[data-status='2'] {
  display: none !important;
}

/* completed: 只显示 status=2（已完成） */
#orderListContainer.filter-completed .order-card[data-status='0'],
#orderListContainer.filter-completed .order-card[data-status='1'] {
  display: none !important;
}

/* completed-exception: 只显示 status=2 且有异常 */
#orderListContainer.filter-completed-exception .order-card:not([data-status='2']),
#orderListContainer.filter-completed-exception .order-card[data-status='2']:not([data-has-exception='true']) {
  display: none !important;
}

/* completed-normal: 只显示 status=2 且无异常 */
#orderListContainer.filter-completed-normal .order-card:not([data-status='2']),
#orderListContainer.filter-completed-normal .order-card[data-has-exception='true'] {
  display: none !important;
}

/* ========== 清除缓存（内嵌页，INC-2026-184） ========== */
.clear-cache-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.clear-cache-body {
  padding: 4px 0 8px;
}

.clear-cache-footer {
  padding-top: 8px;
}

.clear-cache-footer .btn {
  width: 100%;
  min-height: 44px;
}

/* ========== 全量同步（内嵌页，INC-2026-185） ========== */
.full-sync-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.full-sync-body {
  padding: 4px 0 8px;
}

.full-sync-footer {
  padding-top: 8px;
}

.full-sync-footer .btn {
  width: 100%;
  min-height: 44px;
}

.clear-cache-subtitle {
  text-align: center;
  color: #888;
  font-size: 13px;
  margin: 0 0 12px 0;
}

.clear-cache-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.clear-cache-more-btn {
  display: block;
  width: 100%;
  margin-top: 2px;
  padding: 8px 0;
  border: none;
  background: transparent;
  color: #1976d2;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
  cursor: pointer;
}

.clear-cache-more-btn:active {
  opacity: 0.75;
}

.clear-cache-more-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cache-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #f8f9fa;
  cursor: pointer;
  transition: background 0.15s;
}

.cache-option:active {
  background: #e9ecef;
}

.cache-option input[type='checkbox'] {
  display: none;
}

.cache-option .checkmark {
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid #ccc;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
  transition: all 0.15s;
}

.cache-option .checkmark::after {
  content: '';
  width: 5px;
  height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0);
  transition: transform 0.15s;
}

.cache-option input[type='checkbox']:checked + .checkmark {
  background: #2196f3;
  border-color: #2196f3;
}

.cache-option input[type='checkbox']:checked + .checkmark::after {
  transform: rotate(45deg) scale(1);
}

.cache-option.cache-option-warning input[type='checkbox']:checked + .checkmark {
  background: #ef4444;
  border-color: #ef4444;
}

.cache-option-text {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.cache-option-text strong {
  font-size: 14px;
  color: #333;
  font-weight: 500;
}

.cache-option-text small {
  font-size: 12px;
  color: #888;
  margin-top: 2px;
}

/* 抢单 / 日志管理内嵌页 */
.grab-order-panel,
.log-manager-panel,
.version-info-panel,
.clear-cache-panel,
.full-sync-panel,
.user-info-panel {
  padding: 8px 12px 16px;
}

.log-manager-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.log-manager-panel .log-tab-bar {
  border-radius: 8px 8px 0 0;
  margin-bottom: 0;
}

.log-panel-inline {
  flex: none;
  overflow: visible;
  padding: 10px 0 0;
}

.grab-order-toolbar {
  display: flex;
  justify-content: flex-start;
  margin-bottom: 10px;
}

.grab-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 13px;
  border-radius: 8px;
  color: #1976d2;
  border-color: #bbdefb;
  background: #fff;
}

.grab-back-btn:active {
  background: #e3f2fd;
}

.grab-eligibility-wrap {
  margin-bottom: 12px;
}

.grab-hint {
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.4;
  background: #f8f9fa;
  color: #444;
}

.grab-hint-ok {
  background: #e8f5e9;
  color: #2e7d32;
}

.grab-hint-warn {
  background: #fff3e0;
  color: #e65100;
}

.grab-reason-list {
  margin: 8px 0 0 18px;
  padding: 0;
  font-size: 13px;
  color: #666;
}

.grab-pool-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.grab-org-group-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  margin-top: 4px;
  border-radius: 12px;
  background: #e3f2fd;
  border: 1px solid #bbdefb;
}

.grab-org-group-main {
  flex: 1;
  min-width: 0;
}

.grab-org-group-name {
  font-size: 15px;
  font-weight: 600;
  color: #1565c0;
}

.grab-org-group-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 4px;
  font-size: 12px;
  color: #5c6bc0;
}

.grab-pool-card-sub {
  margin-left: 8px;
  border-left: 3px solid #e3f2fd;
  box-shadow: none;
}

.grab-pool-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #e8e8e8;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.grab-pool-card-main {
  flex: 1;
  min-width: 0;
}

.grab-pool-order {
  font-size: 15px;
  font-weight: 600;
  color: #222;
  word-break: break-all;
}

.grab-pool-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 4px;
  font-size: 12px;
  color: #888;
}

.grab-claim-btn {
  flex-shrink: 0;
  min-width: 64px;
}

/* 木托码放 3D 透视视图（Web 优先） */
.pack-layout-view {
  width: 100%;
}
.pack-layout-3d .pack-layout-meta,
.pack-layout-25d .pack-layout-meta {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
}
.pack-layout-warn {
  margin: 0 0 8px;
  font-size: 12px;
  color: #b45309;
}
.pack-layout-canvas-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #eef2f8;
}
.pack-layout-canvas {
  display: block;
  width: 100%;
  height: auto;
  min-height: 320px;
  max-height: 68vh;
  touch-action: none;
  cursor: grab;
}
.pack-layout-canvas:active {
  cursor: grabbing;
}
.pack-layout-view-dirs {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
}
.pack-layout-view-dir.is-active {
  font-weight: 700;
}
.pack-layout-hint {
  position: absolute;
  left: 8px;
  bottom: 6px;
  padding: 2px 8px;
  font-size: 11px;
  color: #64748b;
  background: rgba(255, 255, 255, 0.82);
  border-radius: 4px;
  pointer-events: none;
}
.pack-layout-detail {
  margin: 10px 0 8px;
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.5;
  background: #f0f4ff;
  border-radius: 6px;
  min-height: 52px;
}
.pack-layout-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.pack-layout-layer-label {
  flex: 1 1 100%;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  text-align: center;
}
.container-panel-meta .btn-pack-layout {
  margin-left: 8px;
}
.container-panel-row .container-height,
.container-panel-row .container-volume {
  font-size: 12px;
  color: #475569;
  white-space: nowrap;
}
