/* 小型鞋子仓储管理系统 - 样式表 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #409eff;
    --success: #67c23a;
    --warning: #e6a23c;
    --danger: #f56c6c;
    --info: #909399;
    --dark: #303133;
    --text: #606266;
    --light: #c0c4cc;
    --bg: #f5f7fa;
    --white: #ffffff;
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
}

/* 登录页面 */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-box {
    background: var(--white);
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    width: 400px;
    max-width: 90%;
}

.login-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: var(--dark);
    font-size: 24px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--dark);
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.form-buttons {
    display: flex;
    gap: 10px;
}

.form-buttons button {
    flex: 1;
}

.login-hint {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--bg);
    text-align: center;
    color: var(--info);
    font-size: 12px;
}

.error-message {
    color: var(--danger);
    text-align: center;
    margin-top: 10px;
    font-size: 14px;
}

/* 按钮样式 */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
}

.btn-primary:hover {
    background: #66b1ff;
}

.btn-secondary {
    background: var(--bg);
    color: var(--text);
}

.btn-secondary:hover {
    background: #e4e7ed;
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-success:hover {
    background: #85ce61;
}

.btn-danger {
    background: var(--danger);
    color: var(--white);
}

.btn-danger:hover {
    background: #f78989;
}

.btn-small, .btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.btn-full {
    width: 100%;
}

.btn-large {
    padding: 15px 40px;
    font-size: 16px;
}

/* 主容器 */
.main-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* 顶部导航 */
.top-nav {
    display: flex;
    align-items: center;
    padding: 0 20px;
    height: 60px;
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-title {
    font-size: 20px;
    font-weight: bold;
    color: var(--dark);
    margin-right: 40px;
}

.nav-menu {
    display: flex;
    gap: 5px;
    flex: 1;
}

.nav-menu a {
    padding: 10px 20px;
    color: var(--text);
    text-decoration: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
}

.nav-menu a:hover {
    background: var(--bg);
}

.nav-menu a.active {
    background: var(--primary);
    color: var(--white);
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.role-badge {
    padding: 4px 10px;
    background: var(--success);
    color: var(--white);
    border-radius: 12px;
    font-size: 12px;
}

/* 内容区域 */
.content-area {
    flex: 1;
    padding: 20px;
}

/* 虚拟货架模块 */
.shelf-module {
    display: grid;
    grid-template-columns: 250px 1fr 250px;
    gap: 20px;
    height: calc(100vh - 140px);
}

.shelf-sidebar {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.shelf-sidebar h3 {
    margin-bottom: 15px;
    color: var(--dark);
}

.shelf-search input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--light);
    border-radius: 6px;
    margin-bottom: 15px;
}

.shelf-list {
    max-height: 400px;
    overflow-y: auto;
    margin-bottom: 15px;
}

.shelf-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-radius: 6px;
    cursor: pointer;
    margin-bottom: 5px;
    transition: all 0.3s;
}

.shelf-item:hover {
    background: var(--bg);
}

.shelf-item.active {
    background: var(--primary);
    color: var(--white);
}

.shelf-code {
    font-weight: bold;
}

.shelf-info {
    font-size: 12px;
    opacity: 0.8;
}

.shelf-main {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    overflow: auto;
}

.shelf-visual h3 {
    margin-bottom: 20px;
    color: var(--dark);
}

.shelf-grid {
    display: flex;
    flex-direction: column-reverse;
    gap: 8px;
    padding: 20px;
    background: #f0f0f0;
    border-radius: 8px;
}

.shelf-level {
    display: flex;
    align-items: center;
    gap: 10px;
}

.level-label {
    width: 60px;
    text-align: right;
    font-weight: bold;
    color: var(--dark);
}

.level-cells {
    display: flex;
    gap: 8px;
    flex: 1;
}

.shoe-cell {
    width: 100px;
    height: 60px;
    background: var(--white);
    border: 2px solid #ddd;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.shoe-cell:hover {
    border-color: var(--primary);
    transform: scale(1.05);
}

.shoe-cell.eligible {
    background: #e8f5e9;
    border-color: var(--success);
}

.shoe-cell.not-eligible {
    background: #eeeeee;
    border-color: #bbb;
}

.shoe-cell.selected {
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(64, 158, 255, 0.5);
}

.shoe-cell.blinking {
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% { background: #e8f5e9; }
    50% { background: #fff9c4; }
}

.shoe-icon {
    font-size: 24px;
}

.shoe-size {
    font-size: 12px;
    color: var(--text);
}

.shoe-order-progress {
    position: absolute;
    bottom: 2px;
    right: 4px;
    font-size: 10px;
    font-weight: bold;
    color: #fff;
    background: var(--primary);
    border-radius: 8px;
    padding: 0 4px;
    line-height: 14px;
    opacity: 0.85;
}

.cell-empty {
    font-size: 14px;
    color: var(--light);
}

.shelf-legend {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    padding: 15px;
    background: var(--bg);
    border-radius: 6px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

.legend-color.eligible {
    background: #e8f5e9;
    border: 2px solid var(--success);
}

.legend-color.not-eligible {
    background: #eeeeee;
    border: 2px solid #bbb;
}

.legend-color.selected {
    border: 2px solid var(--primary);
    box-shadow: 0 0 5px rgba(64, 158, 255, 0.5);
}

.legend-color.blinking {
    background: #fff9c4;
    animation: blink 1s infinite;
}

.shelf-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--light);
}

.shelf-hint {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.shelf-hint h4 {
    margin-bottom: 15px;
    color: var(--dark);
}

.shelf-hint p {
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--text);
}

/* 入库管理模块（新版左右布局） */
.inbound-module-new {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 20px;
    height: calc(100vh - 140px);
}

/* 左侧操作区 */
.inbound-left {
    display: flex;
    flex-direction: column;
    gap: 14px;
    overflow-y: auto;
}

.inbound-left h2 {
    font-size: 20px;
    color: var(--dark);
    margin-bottom: 2px;
}

.inbound-card {
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    overflow: visible;  /* 改为 visible，避免内容被遮挡 */
    border: 2px solid transparent;
    transition: border-color 0.3s;
}

.inbound-card.card-active {
    border-color: var(--primary);
}

.inbound-card.card-done {
    border-color: var(--success);
}

.inbound-card.card-disabled {
    opacity: 0.6;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--bg);
    border-bottom: 1px solid #eee;
}

.card-title {
    font-weight: 600;
    color: var(--dark);
    font-size: 15px;
}

.card-hint {
    font-size: 12px;
    color: var(--info);
    margin-left: auto;
}

.step-badge {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 13px;
    flex-shrink: 0;
}

.step-badge.active {
    background: var(--primary);
    color: var(--white);
}

.step-badge.done {
    background: var(--success);
    color: var(--white);
}

.step-badge.inactive {
    background: var(--light);
    color: var(--white);
}

.card-body {
    padding: 14px 16px;
}

.scan-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.scan-input-new {
    flex: 1;
    padding: 10px 14px;
    border: 2px solid var(--light);
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.3s;
    outline: none;
}

.scan-input-new.input-active {
    border-color: var(--primary);
}

.scan-input-new.input-done {
    border-color: var(--success);
    background: #f6fff6;
}

.scan-input-new.input-disabled {
    background: #f5f5f5;
    color: #bbb;
    cursor: not-allowed;
}

.scan-error {
    margin-top: 8px;
    padding: 8px 12px;
    background: #fef0f0;
    color: var(--danger);
    border-radius: 6px;
    font-size: 13px;
}

.location-confirmed {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    padding: 8px 12px;
    background: #e8f5e9;
    border-radius: 6px;
}

.loc-badge {
    font-weight: 600;
    color: #2e7d32;
    font-size: 15px;
}

.loc-remain {
    font-size: 13px;
    color: #555;
}

.shoe-preview {
    margin-top: 10px;
    padding: 10px 12px;
    background: #f0f7ff;
    border-radius: 6px;
    border-left: 3px solid var(--primary);
}

.preview-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    align-items: center;
    font-size: 13px;
}

.preview-label {
    color: var(--info);
    margin-right: 2px;
}

.message {
    padding: 10px 14px;
    border-radius: 6px;
    margin-top: 10px;
    font-size: 14px;
}

.message.success {
    background: #e8f5e9;
    color: var(--success);
}

.message.error {
    background: #fef0f0;
    color: var(--danger);
}

/* 最近入库记录（紧凑版） */
.records-mini {
    max-height: 200px;
    overflow-y: auto;
}

.empty-mini {
    text-align: center;
    color: var(--light);
    padding: 20px;
    font-size: 13px;
}

.record-mini-row {
    display: flex;
    gap: 8px;
    padding: 6px 0;
    border-bottom: 1px solid var(--bg);
    font-size: 13px;
    align-items: center;
}

.rec-code {
    flex: 2;
    font-family: monospace;
    color: var(--dark);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rec-loc {
    flex: 1.2;
    color: var(--primary);
    font-weight: 500;
}

.rec-size {
    width: 36px;
    text-align: center;
    background: var(--bg);
    border-radius: 4px;
    padding: 2px 4px;
    font-size: 12px;
}

.rec-time {
    flex: 0 0 70px;
    color: var(--info);
    font-size: 12px;
    text-align: right;
}

/* 右侧图形化货架预览 */
.inbound-right {
    background: var(--white);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    padding: 20px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.inbound-shelf-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.inbound-shelf-header h3 {
    color: var(--dark);
    font-size: 16px;
}

.shelf-loc-info {
    font-size: 14px;
    color: var(--text);
    background: #e8f5e9;
    padding: 6px 14px;
    border-radius: 20px;
}

.inbound-shelf-visual {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: auto;
}

.inbound-shelf-grid {
    display: flex;
    flex-direction: column-reverse;
    gap: 6px;
    background: #f2f4f8;
    border-radius: 10px;
    padding: 16px;
    flex: 1;
}

.ib-shelf-level {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: 8px;
    transition: all 0.3s;
}

.ib-shelf-level.ib-level-highlight {
    background: #fff3cd;
    box-shadow: 0 0 0 2px #ffc107;
}

.ib-level-label {
    width: 80px;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.ib-lnum {
    width: 28px;
    height: 28px;
    background: var(--white);
    border: 2px solid #ddd;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 13px;
    color: var(--dark);
    flex-shrink: 0;
}

.ib-level-highlight .ib-lnum {
    background: #ffc107;
    border-color: #ffc107;
    color: #fff;
}

.ib-here {
    font-size: 11px;
    color: #e65100;
    font-weight: 600;
    white-space: nowrap;
}

.ib-level-cells {
    display: flex;
    gap: 8px;
    flex: 1;
}

.ib-cell {
    padding-top: 12px;
    width: 76px;
    height: 56px;
    background: var(--white);
    border: 2px solid #ddd;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    cursor: default;
    position: relative;
}

.ib-cell-current {
    background: #fffde7;
    border-color: #ffc107;
}

/* 层已满 - 整行淡红色 */
.ib-level-full {
    background: rgba(255, 235, 238, 0.35);
}

.ib-level-full .ib-cell:not(.ib-cell-current) {
    background: rgba(244, 67, 54, 0.08);
    border-color: rgba(244, 67, 54, 0.2);
}

.ib-level-full .ib-cell.ib-cell-current {
    background: rgba(244, 67, 54, 0.15);
    border-color: rgba(244, 67, 54, 0.4);
}

.ib-cell.eligible {
    background: #e8f5e9;
    border-color: var(--success);
}

.ib-cell.not-eligible {
    background: #eeeeee;
    border-color: #bbb;
}

.ib-shoe-icon {
    font-size: 20px;
    line-height: 1;
}

.ib-shoe-size {
    font-size: 11px;
    color: var(--text);
    margin-top: 2px;
}

.ib-order-progress {
    position: absolute;
    bottom: 1px;
    right: 3px;
    font-size: 9px;
    font-weight: bold;
    color: #fff;
    background: var(--primary);
    border-radius: 7px;
    padding: 0 3px;
    line-height: 12px;
    opacity: 0.85;
}

.ib-order-complete {
    position: absolute;
    top: -2px;
    right: -2px;
    font-size: 11px;
    font-weight: bold;
    color: #fff;
    background: linear-gradient(135deg, #43a047, #66bb6a);
    border-radius: 4px;
    padding: 1px 5px;
    line-height: 15px;
    z-index: 3;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    letter-spacing: 1px;
}

.ib-empty {
    font-size: 16px;
    color: #ccc;
    font-weight: bold;
}

.ib-level-count {
    width: 36px;
    text-align: right;
    font-size: 12px;
    color: var(--info);
    flex-shrink: 0;
}

.ib-legend {
    display: flex;
    gap: 20px;
    margin-top: 14px;
    padding: 10px 14px;
    background: var(--bg);
    border-radius: 6px;
    flex-wrap: wrap;
}

.ib-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
}

.ib-lc {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 2px solid #ddd;
}

.ib-lc.eligible {
    background: #e8f5e9;
    border-color: var(--success);
}

.ib-lc.not-eligible {
    background: #eeeeee;
    border-color: #bbb;
}

.ib-lc.current-level {
    background: #fffde7;
    border-color: #ffc107;
}

.ib-lc.empty-cell {
    background: var(--white);
    border-color: #ddd;
}

/* 未定位时的占位货架示意 */
.inbound-shelf-placeholder {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 20px;
}

.placeholder-icon {
    font-size: 40px;
    margin-bottom: 10px;
}

.inbound-shelf-placeholder p {
    color: var(--info);
    font-size: 15px;
    margin-bottom: 4px;
}

.placeholder-hint {
    font-size: 13px !important;
    color: var(--light) !important;
    margin-bottom: 20px !important;
}

.placeholder-shelf {
    display: flex;
    flex-direction: column-reverse;
    gap: 5px;
    background: #f2f4f8;
    border-radius: 10px;
    padding: 14px 20px;
    width: 100%;
    max-width: 500px;
    opacity: 0.4;
}

.placeholder-level {
    display: flex;
    align-items: center;
    gap: 8px;
}

.ph-lnum {
    width: 24px;
    font-size: 12px;
    color: #999;
    text-align: center;
}

.ph-cells {
    display: flex;
    gap: 6px;
}

.ph-cell {
    width: 60px;
    height: 40px;
    background: var(--white);
    border: 1px solid #ddd;
    border-radius: 6px;
}

/* 旧入库模块兼容（保留不删，以防引用） */
.inbound-module {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.scan-input {
    padding: 12px;
    border: 2px solid var(--light);
    border-radius: 6px;
    font-size: 16px;
    width: 300px;
    margin-right: 10px;
}

.shoe-detail {
    padding: 15px;
    background: var(--white);
    border-radius: 6px;
}

.shoe-detail p {
    margin-bottom: 8px;
}

.location-select {
    display: flex;
    gap: 20px;
}

.location-select .form-group {
    flex: 1;
}

.level-status {
    margin-top: 15px;
    padding: 10px;
    background: var(--white);
    border-radius: 6px;
}

.inbound-records {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.inbound-records h3 {
    margin-bottom: 20px;
    color: var(--dark);
}

/* 订单模块 */
.order-module {
    display: grid;
    grid-template-columns: 7fr 3fr;  /* 订单列表70%，订单详情30% */
    gap: 20px;
}

.order-sidebar {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.order-sidebar h3 {
    margin-bottom: 20px;
    color: var(--dark);
}

.order-sidebar textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light);
    border-radius: 6px;
    font-family: monospace;
    resize: vertical;
}

.order-sidebar small {
    display: block;
    margin-top: 8px;
    color: var(--info);
    font-size: 12px;
}

.order-main {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.order-main h3 {
    margin-bottom: 20px;
    color: var(--dark);
}

.order-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.filter-btn {
    padding: 8px 16px;
    border: 1px solid var(--light);
    border-radius: 20px;
    background: var(--white);
    cursor: pointer;
    transition: all 0.3s;
}

.filter-btn:hover,
.filter-btn.active {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

.order-detail {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.order-detail h3 {
    margin-bottom: 20px;
    color: var(--dark);
}

.detail-content {
    padding: 15px;
    background: var(--bg);
    border-radius: 6px;
}

.detail-content h4 {
    margin: 15px 0 10px;
    color: var(--dark);
}

.detail-content p {
    margin-bottom: 8px;
}

.empty-state {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 200px;
    color: var(--light);
}

/* 设置模块 */
.settings-module {
    max-width: 1200px;
    margin: 0 auto;
}

.settings-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    background: var(--white);
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.tab-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    background: var(--bg);
    cursor: pointer;
    transition: all 0.3s;
}

.tab-btn:hover,
.tab-btn.active {
    background: var(--primary);
    color: var(--white);
}

.settings-content {
    background: var(--white);
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.settings-content h3 {
    margin-bottom: 25px;
    color: var(--dark);
}

.inline-form {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.inline-form input,
.inline-form select {
    padding: 10px;
    border: 1px solid var(--light);
    border-radius: 6px;
}

.form-hint {
    margin-top: 8px;
    color: var(--info);
    font-size: 12px;
}

.backup-actions {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.backup-hint {
    color: var(--info);
    font-size: 14px;
}

/* CDP启动模块 */
.cdp-hint {
    color: var(--info);
    font-size: 14px;
    margin-bottom: 20px;
}

.cdp-form {
    max-width: 500px;
}

.cdp-form .form-group {
    margin-bottom: 20px;
}

.cdp-form .form-group small {
    display: block;
    margin-top: 6px;
    color: var(--info);
    font-size: 12px;
}

.cdp-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.cdp-actions .btn {
    min-width: 120px;
}

.cdp-info {
    margin-top: 30px;
    padding: 20px;
    background: #f0f7ff;
    border-radius: 8px;
    border-left: 4px solid var(--primary);
}

.cdp-info h4 {
    margin-bottom: 15px;
    color: var(--dark);
}

.cdp-info p {
    margin-bottom: 8px;
    font-size: 14px;
}

.cdp-info code {
    background: #e3f2fd;
    padding: 2px 8px;
    border-radius: 4px;
    font-family: Consolas, monospace;
    color: var(--primary);
}

.cdp-tip {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px dashed #b3d7ff;
    color: var(--text);
}

/* CDP连接状态条 */
.cdp-status-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 14px;
}

.cdp-status-bar.cdp-online {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #a5d6a7;
}

.cdp-status-bar.cdp-offline {
    background: #fff3e0;
    color: #e65100;
    border: 1px solid #ffcc80;
}

.cdp-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.cdp-online .cdp-dot {
    background: #4caf50;
    box-shadow: 0 0 6px rgba(76, 175, 80, 0.6);
}

.cdp-offline .cdp-dot {
    background: #ff9800;
}

.cdp-port-info {
    margin-left: auto;
    opacity: 0.7;
    font-size: 12px;
}

/* 查询中动画 */
.query-spinner {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-size: 14px;
}

.spinner {
    width: 18px;
    height: 18px;
    border: 2px solid #e0e0e0;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 鲸蚁查询结果卡片 */
.jingyee-result-card {
    margin-top: 12px;
    border: 2px solid #e3f2fd;
    border-radius: 10px;
    overflow: visible;  /* 改为 visible，避免内容被遮挡 */
    background: #fafbff;
}

.jingyee-result-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: #e3f2fd;
    border-bottom: 1px solid #bbdefb;
}

.jingyee-badge {
    background: #1976d2;
    color: white;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.jingyee-order {
    font-size: 13px;
    color: #1565c0;
    font-weight: 500;
}

.jingyee-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 12px 14px;
}

.ji-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.ji-label {
    font-size: 12px;
    color: #999;
    min-width: 40px;
}

.ji-value {
    font-size: 13px;
    color: var(--dark);
    font-weight: 500;
}

/* 衣物图片预览 */
.jingyee-images {
    display: flex;
    gap: 8px;
    padding: 10px 14px;
    overflow-x: auto;
}

.ji-img {
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
    border: 2px solid #e0e0e0;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.3s;
}

.ji-img:hover {
    border-color: var(--primary);
    transform: scale(1.05);
}

.ji-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 出库提醒 */
.outbound-reminder {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: #fff3e0;
    border-top: 1px solid #ffe0b2;
    font-size: 13px;
    color: #e65100;
    font-weight: 500;
}

.reminder-icon {
    font-size: 18px;
}

/* 订单进度标签 */
.jingyee-order-progress {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    color: #1565c0;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-left: auto;
}

.cache-hit {
    font-size: 10px;
    background: #c8e6c9;
    color: #2e7d32;
    padding: 1px 6px;
    border-radius: 10px;
    font-weight: 600;
}

/* 同订单衣物进度条 */
.order-progress-bar {
    margin: 10px 0;
    padding: 10px 12px;
    background: #f5f7fa;
    border-radius: 8px;
    border: 1px solid #e8ecf0;
}

.opb-label {
    font-size: 12px;
    color: #909399;
    margin-bottom: 8px;
    font-weight: 500;
}

.opb-items {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.opb-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    border: 1.5px solid #dcdfe6;
    background: #fff;
    transition: all 0.2s;
}

.opb-item.opb-done {
    background: #f0f9eb;
    border-color: #b3e19d;
    color: #529b2e;
}

.opb-item.opb-pending {
    background: #fff;
    border-color: #dcdfe6;
    color: #909399;
}

.opb-item.opb-current {
    border-color: #409eff;
    background: #ecf5ff;
    color: #409eff;
    font-weight: 600;
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.2);
}

.opb-idx {
    font-weight: 700;
    font-size: 13px;
    min-width: 16px;
    text-align: center;
}

.opb-type {
    max-width: 80px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.opb-check {
    color: #67c23a;
    font-weight: 700;
    font-size: 14px;
}

.opb-summary {
    font-size: 12px;
    color: #606266;
    font-weight: 500;
}

/* ========== 图片灯箱 ========== */
.lightbox-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0, 0, 0, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: lbFadeIn 0.2s ease;
}

@keyframes lbFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lightbox-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    color: #fff;
    font-size: 36px;
    cursor: pointer;
    z-index: 10001;
    line-height: 1;
    opacity: 0.7;
    transition: opacity 0.2s;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.lightbox-close:hover {
    opacity: 1;
    background: rgba(255,255,255,0.1);
}

.lightbox-counter {
    position: absolute;
    top: 22px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    font-weight: 500;
    z-index: 10001;
    background: rgba(0,0,0,0.5);
    padding: 3px 14px;
    border-radius: 12px;
}

.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    font-size: 48px;
    cursor: pointer;
    z-index: 10001;
    width: 56px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: background 0.2s;
    user-select: none;
    line-height: 1;
}

.lightbox-arrow:hover {
    background: rgba(255,255,255,0.25);
}

.lightbox-arrow-left {
    left: 16px;
}

.lightbox-arrow-right {
    right: 16px;
}

.lightbox-img-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 90vw;
    max-height: 90vh;
    padding: 40px 60px;
}

.lightbox-img-wrap img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 6px;
    user-select: none;
    animation: lbImgIn 0.25s ease;
}

@keyframes lbImgIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.lightbox-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid rgba(255,255,255,0.2);
    border-top-color: #fff;
    border-radius: 50%;
    animation: lbSpin 0.8s linear infinite;
    position: absolute;
}

@keyframes lbSpin {
    to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    .lightbox-arrow {
        width: 40px;
        height: 56px;
        font-size: 36px;
    }
    .lightbox-arrow-left { left: 8px; }
    .lightbox-arrow-right { right: 8px; }
    .lightbox-img-wrap { padding: 40px 44px; }
}

/* 数据表格 */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--bg);
}

.data-table th {
    background: var(--bg);
    font-weight: 600;
    color: var(--dark);
}

.data-table tr:hover {
    background: #fafafa;
}

.data-table tr.selected {
    background: #ecf5ff;
}

.data-table.small th,
.data-table.small td {
    padding: 8px;
    font-size: 13px;
}

/* 状态标签 */
.status-tag {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
}

.status-tag.eligible {
    background: #e8f5e9;
    color: var(--success);
}

.status-tag.not-eligible {
    background: #fef0f0;
    color: var(--danger);
}

.status-tag.completed {
    background: #e8f5e9;
    color: var(--success);
}

.status-tag.pending {
    background: #fdf6ec;
    color: var(--warning);
}

/* 统计栏 */
.stats-bar {
    display: flex;
    justify-content: center;
    gap: 50px;
    padding: 15px;
    background: var(--white);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-label {
    font-size: 12px;
    color: var(--info);
    margin-bottom: 5px;
}

.stat-value {
    font-size: 24px;
    font-weight: bold;
    color: var(--dark);
}

.stat-value.highlight {
    color: var(--primary);
}

/* 模态框 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: var(--white);
    padding: 30px;
    border-radius: 12px;
    width: 450px;
    max-width: 90%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.modal-content h3 {
    margin-bottom: 20px;
    color: var(--dark);
}

.shoe-modal-info p {
    margin-bottom: 10px;
}

/* ========== 鞋子详情模态框增强 ========== */
.shoe-detail-modal {
    width: 600px;
    max-width: 95%;
}

.shoe-modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.shoe-modal-main, .shoe-modal-side {
    min-width: 0;
}

.sm-detail-state {
    color: #888;
    font-size: 12px;
    margin: 0 0 12px;
}

.sm-detail-error {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: #b42318;
    font-size: 13px;
    margin-bottom: 12px;
}

.sm-section {
    margin-bottom: 12px;
}

.sm-section-title {
    font-size: 13px;
    font-weight: 600;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    padding-bottom: 4px;
    border-bottom: 1px solid #eee;
}

.sm-info-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 6px 16px;
}

.sm-info-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3px 0;
}

.sm-label {
    font-size: 12px;
    color: #999;
    white-space: nowrap;
    min-width: 56px;
}

.sm-value {
    font-size: 13px;
    color: var(--dark);
    font-weight: 500;
    min-width: 0;
    overflow-wrap: anywhere;
}

.sm-value.code {
    font-family: monospace;
    color: var(--primary);
    font-size: 13px;
}

.sm-value.size {
    font-weight: 700;
    color: var(--dark);
    font-size: 15px;
}

.sm-value.defect {
    color: #e65100;
    font-weight: 500;
}

.sm-value.accessory-tag {
    color: #6a1b9a;
    font-weight: 500;
    background: #f3e5f5;
    padding: 1px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.sm-value.order-prog-badge {
    background: linear-gradient(135deg, var(--primary), #5c6bc0);
    color: #fff;
    border-radius: 10px;
    padding: 2px 10px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

/* 右侧图片区 */
.shoe-modal-side {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sm-images {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

.sm-img {
    aspect-ratio: 1;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid #eee;
    transition: transform 0.2s;
}

.sm-img:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.sm-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 同订单衣物列表 */
.sm-order-items {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sm-order-item {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 48px;
    gap: 6px;
    padding: 7px 8px;
    border: 1px solid transparent;
    border-radius: 6px;
    font-family: inherit;
    font-size: 12px;
    color: var(--dark);
    text-align: left;
    background: #f5f5f5;
    cursor: pointer;
}

.sm-order-item:hover {
    border-color: var(--primary);
}

.sm-order-item:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.oi-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    gap: 3px;
}

.oi-label {
    font-family: monospace;
    font-size: 10px;
    color: #666;
    overflow-wrap: anywhere;
}

.oi-link {
    flex-shrink: 0;
    color: var(--primary);
    font-size: 11px;
}

.sm-order-item.oi-done {
    background: #e8f5e9;
}

.sm-order-item.oi-current {
    background: #e3f2fd;
    border: 1px solid var(--primary);
    font-weight: 600;
}

.sm-order-item .oi-idx {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    flex-shrink: 0;
}

.oi-done .oi-idx {
    background: var(--success);
    color: #fff;
}

.oi-current .oi-idx {
    background: var(--primary);
    color: #fff;
}

.oi-type {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.oi-size {
    color: #888;
    font-size: 11px;
}

.oi-status {
    font-size: 11px;
    white-space: nowrap;
}

.sm-order-summary {
    font-size: 12px;
    color: #888;
    text-align: center;
    margin-top: 6px;
}

@media (max-width: 600px) {
    .shoe-detail-modal {
        width: 95%;
    }
    .shoe-modal-body {
        grid-template-columns: 1fr;
    }
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 25px;
    justify-content: flex-end;
}

.shoe-detail-modal .modal-actions {
    flex-wrap: wrap;
}

/* ========== 入库预览模式样式 ========== */
.preview-mode {
    border-color: #a5d6a7;
    background: linear-gradient(to bottom, #f1f8e9, #fafbff);
}

.preview-mode .jingyee-result-header {
    background: linear-gradient(135deg, #c8e6c9, #a5d6a7);
    border-bottom-color: #81c784;
}

.already-inbound-tag {
    background: #4caf50;
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

/* 图片预览区 */
.preview-images-section {
    padding: 12px 14px;
    border-top: 1px dashed #e0e0e0;
}

.pis-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.pis-title {
    font-size: 13px;
    font-weight: 600;
    color: #424242;
}

.pis-count {
    font-size: 12px;
    color: #757575;
}

.pis-local-images,
.pis-cos-images {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.pis-img {
    position: relative;
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    border-radius: 6px;
    overflow: hidden;
    border: 2px solid #e0e0e0;
    cursor: pointer;
    transition: all 0.3s;
}

.pis-img:hover {
    border-color: var(--primary);
    transform: scale(1.05);
}

.pis-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pis-img-download {
    position: absolute;
    bottom: 2px;
    right: 2px;
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 10px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s;
}

.pis-img:hover .pis-img-download {
    opacity: 1;
}

.pis-no-image {
    padding: 20px;
    text-align: center;
    color: #9e9e9e;
    font-size: 13px;
    background: #f5f5f5;
    border-radius: 8px;
}

.download-btn {
    margin-top: 10px;
    width: 100%;
}

/* 操作按钮区 */
.preview-actions {
    padding: 12px 14px;
    border-top: 1px dashed #e0e0e0;
    display: flex;
    gap: 10px;
}

.inbound-btn {
    flex: 1;
    font-size: 15px;
    padding: 12px;
    letter-spacing: 2px;
}

/* 待入库提醒 */
.pending-reminder {
    padding: 10px 14px;
    background: #fff8e1;
    border-top: 1px solid #ffe082;
    font-size: 13px;
    color: #f57c00;
}

/* 待入库文字 */
.opb-pending-text {
    font-size: 10px;
    color: #bdbdbd;
    font-style: italic;
}

/* 响应式 */
@media (max-width: 1200px) {
    .shelf-module {
        grid-template-columns: 200px 1fr 200px;
    }
    
    .order-module {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .top-nav {
        flex-wrap: wrap;
        height: auto;
        padding: 10px;
    }
    
    .nav-menu {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 10px;
    }
    
    .shelf-module,
    .inbound-module {
        grid-template-columns: 1fr;
    }
}

/* ========== 调试日志面板 ========== */
.debug-panel {
    background: #1e1e2e;
    color: #cdd6f4;
    font-family: 'Cascadia Code', 'Fira Code', 'Consolas', monospace;
    font-size: 12px;
    border-bottom: 2px solid #45475a;
    transition: max-height 0.3s ease;
    max-height: 260px;
    display: flex;
    flex-direction: column;
}

.debug-panel.debug-collapsed {
    max-height: 36px;
}

.debug-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 14px;
    background: #313244;
    cursor: pointer;
    user-select: none;
    flex-shrink: 0;
    border-bottom: 1px solid #45475a;
}

.debug-header:hover {
    background: #3b3b52;
}

.debug-title {
    font-weight: 600;
    color: #a6e3a1;
    font-size: 13px;
}

.debug-badge {
    background: #f38ba8;
    color: #1e1e2e;
    font-size: 10px;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

.debug-toggle {
    color: #a6adc8;
    font-size: 11px;
}

.debug-clear {
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    padding: 2px 6px;
    border-radius: 4px;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.debug-clear:hover {
    opacity: 1;
    background: rgba(255,255,255,0.1);
}

.debug-body {
    flex: 1;
    overflow-y: auto;
    padding: 4px 0;
    max-height: 222px;
}

.debug-body::-webkit-scrollbar {
    width: 6px;
}

.debug-body::-webkit-scrollbar-thumb {
    background: #585b70;
    border-radius: 3px;
}

.debug-empty {
    text-align: center;
    color: #6c7086;
    padding: 20px;
    font-style: italic;
}

.debug-log-row {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 2px 14px;
    line-height: 1.6;
    border-left: 3px solid transparent;
}

.debug-log-row:hover {
    background: rgba(255,255,255,0.03);
}

.debug-log-row.debug-info {
    border-left-color: #89b4fa;
}

.debug-log-row.debug-success {
    border-left-color: #a6e3a1;
}

.debug-log-row.debug-warn {
    border-left-color: #f9e2af;
}

.debug-log-row.debug-error {
    border-left-color: #f38ba8;
}

.debug-log-row.debug-step {
    border-left-color: #cba6f7;
}

.debug-log-row.debug-data {
    border-left-color: #94e2d5;
}

.debug-time {
    color: #6c7086;
    flex-shrink: 0;
    font-size: 11px;
    min-width: 65px;
}

.debug-level-tag {
    flex-shrink: 0;
    font-size: 10px;
    font-weight: 700;
    padding: 0 5px;
    border-radius: 3px;
    text-transform: uppercase;
    min-width: 40px;
    text-align: center;
}

.tag-info { background: #89b4fa33; color: #89b4fa; }
.tag-success { background: #a6e3a133; color: #a6e3a1; }
.tag-warn { background: #f9e2af33; color: #f9e2af; }
.tag-error { background: #f38ba833; color: #f38ba8; }
.tag-step { background: #cba6f733; color: #cba6f7; }
.tag-data { background: #94e2d533; color: #94e2d5; }

.debug-msg {
    flex: 1;
    word-break: break-all;
    color: #cdd6f4;
}

.debug-log-row.debug-data .debug-msg {
    color: #94e2d5;
    padding-left: 8px;
    border-left: 1px dashed #585b70;
}

.debug-log-row.debug-step .debug-msg {
    color: #cba6f7;
    font-weight: 600;
}


/* 自定义确认对话框 */
.confirm-modal-overlay {
    z-index: 10000;
    background: rgba(0, 0, 0, 0.5);
}
.confirm-dialog {
    max-width: 400px;
    text-align: center;
    padding: 24px;
}
.confirm-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 12px;
    color: #333;
}
.confirm-message {
    font-size: 14px;
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}
.confirm-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}
.confirm-buttons .btn {
    min-width: 80px;
    padding: 8px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
}


/* 订单详情信息网格 */
.detail-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 8px 16px;
    margin-bottom: 16px;
    padding: 12px;
    background: var(--bg-secondary, #f5f5f5);
    border-radius: 8px;
}
.detail-info-grid .detail-info-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.detail-info-grid .detail-info-item .label {
    font-size: 12px;
    color: #888;
}
.detail-info-grid .detail-info-item .value {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary, #333);
}
.detail-info-grid .detail-info-item .value .status-tag {
    font-size: 12px;
}
td.mono {
    font-family: 'Courier New', monospace;
    font-size: 12px;
}


/* 订单位置查看模态框 */
.loc-shelves-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.loc-shelf-section {
    margin-bottom: 0;
}
.loc-shelf-section h4 {
    margin: 0 0 6px 0;
    padding-bottom: 4px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 13px;
}
.loc-shelf-grid {
    display: flex;
    flex-direction: column-reverse;
    gap: 2px;
}
.loc-shelf-level {
    display: flex;
    align-items: center;
    gap: 3px;
}
.loc-level-label {
    width: 36px;
    text-align: right;
    font-size: 10px;
    color: #999;
    flex-shrink: 0;
}
.loc-level-cells {
    display: flex;
    gap: 3px;
}
.loc-cell {
    width: 44px;
    height: 34px;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    transition: transform 0.15s;
    position: relative;
    overflow: hidden;
}
.loc-cell.loc-order {
    background: #e8f5e9;
    border: 2px solid #43a047;
}
.loc-cell.loc-matched {
    background: #c8e6c9;
    border: 2px solid #2e7d32;
    box-shadow: 0 0 8px rgba(46, 125, 50, 0.4);
}
.loc-cell.loc-other {
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
}
.loc-cell.loc-empty {
    background: #fafafa;
    border: 1px dashed #ddd;
}
.loc-match-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #2e7d32;
    color: #fff;
    font-size: 10px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}
.loc-cell-highlight {
    font-size: 12px;
    line-height: 1;
}
.loc-cell-label {
    font-size: 9px;
    color: #555;
    margin-top: 0;
}
.loc-cell-code {
    display: none;
}
.loc-empty-pos {
    font-size: 11px;
    color: #ccc;
}
/* 校验扫码区 */
.verify-section {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 10px 12px;
    margin-bottom: 12px;
}
.verify-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 500;
}
.verify-progress {
    font-size: 12px;
    color: #666;
}
.verify-input-row {
    display: flex;
    gap: 8px;
}
.verify-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}
.verify-input:focus {
    outline: none;
    border-color: #2196f3;
}
/* 打印面单区 */
.print-label-section {
    margin-top: 12px;
    padding: 12px;
    background: #e8f5e9;
    border: 1px solid #a5d6a7;
    border-radius: 6px;
    text-align: center;
}
.print-label-success {
    color: #2e7d32;
    font-weight: 500;
}
.loc-legend {
    margin-top: 8px;
    padding-top: 6px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 11px;
}
.loc-legend .legend-item {
    font-size: 11px;
    gap: 4px;
}
.loc-legend .legend-color {
    width: 14px;
    height: 14px;
    border-radius: 3px;
}
.legend-color.loc-order {
    background: #e8f5e9;
    border: 2px solid #43a047;
}
.legend-color.loc-other {
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
}
.legend-color.loc-empty {
    background: #fafafa;
    border: 1px dashed #ddd;
}
.btn-info {
    background: #2196f3;
    color: #fff;
    border: none;
    padding: 4px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}
.btn-info:hover {
    background: #1976d2;
}

/* Return-destination region, always visible at the top left. */
.region-badge { display:inline-block; border-radius:4px; padding:2px 5px; font-size:10px; font-weight:700; line-height:1.2; white-space:nowrap; vertical-align:middle; }
.region-badge.jjj { background:#dbeafe; color:#1d4ed8; }
.region-badge.non_jjj { background:#ffedd5; color:#9a3412; }
.region-badge.unknown { background:#e5e7eb; color:#4b5563; }
.region-corner { position:absolute; top:3px; left:3px; z-index:2; min-width:18px; text-align:center; font-size:10px; padding:2px 3px; }
.shoe-cell { padding-top:12px; }
.purchase-count { position:absolute; bottom:3px; left:3px; z-index:2; min-width:18px; padding:1px 4px; border-radius:4px; background:#ede9fe; color:#6d28d9; font:700 11px/15px ui-monospace,monospace; text-align:center; }
.purchase-count.unknown { background:#e5e7eb; color:#6b7280; }

/* Shoe detail opens the latest order locations without entering shipment verification. */
.shoe-detail-modal { max-height:calc(100dvh - 28px); overflow-y:auto; }
.distribution-error { margin:12px 0 0; padding:10px 12px; background:#fff4e5; color:#9a661d; border-radius:7px; font-size:12px; line-height:1.7; }
.distribution-dialog { width:860px; max-width:95%; max-height:calc(100dvh - 24px); overflow-y:auto; padding:22px; }
.distribution-summary { padding:13px 15px; margin:14px 0; border:1px solid #dce8df; background:#f3f8f5; border-radius:8px; }
.distribution-summary p { margin:0 0 9px; font-size:12px; overflow-wrap:anywhere; }
.distribution-summary>div { display:flex; flex-wrap:wrap; gap:16px; color:#688674; font-size:12px; }
.distribution-summary b { color:#2b6744; font-size:20px; }
.distribution-summary small { display:block; margin-top:9px; color:#82958b; font-size:11px; line-height:1.6; }
.distribution-summary .distribution-unconfirmed { margin:9px 0 0; color:#a77a34; }
.distribution-dialog .loc-shelf-section { flex:1 1 300px; min-width:0; padding:12px; border:1px solid #e1e7ec; border-radius:9px; }
.distribution-dialog .loc-shelf-section h4 { font-size:17px; margin-bottom:11px; }
.distribution-dialog .loc-level-cells { flex:1; min-width:0; }
.distribution-dialog .loc-cell { flex:1; width:auto; min-width:0; }
.distribution-dialog .loc-cell.loc-current { border:2px solid #e99431; background:#fff0d8; box-shadow:0 0 0 1px #f1b15c; }
.distribution-cell-position { position:absolute; top:1px; right:3px; font-size:8px; color:#678674; }
.distribution-item-list { margin-top:12px; border-top:1px solid #e9edf0; }
.distribution-item { padding:11px 6px; border-bottom:1px solid #edf0f3; }
.distribution-item.current { background:#fff8ec; border-radius:6px; }
.distribution-item>div { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.distribution-item strong { color:#386c4c; font-size:15px; }
.distribution-item code { display:block; overflow-wrap:anywhere; font-size:12px; color:#6f8191; margin-top:6px; }
.distribution-item small { display:block; color:#94a1ac; font-size:11px; margin-top:4px; }
.distribution-current-tag { background:#ffe6bf; color:#a36922; border-radius:4px; padding:2px 5px; font-size:10px; }
.distribution-missing { background:#fff7e9; border:1px solid #eddbbd; padding:13px; border-radius:8px; margin-top:16px; }
.distribution-missing h4 { font-size:13px; color:#aa7939; margin:0 0 8px; }
.distribution-missing>div { display:flex; flex-wrap:wrap; gap:8px; padding:7px 0; font-size:12px; color:#a49074; }
.distribution-missing code { overflow-wrap:anywhere; }
.legend-color.loc-current { background:#fff0d8; border:2px solid #e99431; }
.distribution-dialog .loc-legend { flex-wrap:wrap; gap:12px; }
@media(max-width:480px) { .distribution-dialog { padding:14px; } .distribution-dialog .loc-shelf-section { padding:10px; } .distribution-dialog .loc-level-label { width:29px; } .distribution-summary { padding:11px; } .distribution-dialog .btn-small { padding:6px 8px; font-size:11px; } }

.region-group-row td{background:#edf3fc;color:#345a88;font-weight:700;padding:12px 16px;}
