:root {
  --blue: #3677ff;
  --blue-hover: #5894ff;
  --blue-soft: #f0f5ff;
  --ink: #1d2129;
  --secondary: #4e5969;
  --muted: #86909c;
  --bg: #f5f7fa;
  --line: #f2f3f5;
  --border: #e5e6eb;
  --success: #00b42a;
  --warning: #ff7d00;
  --danger: #f53f3f;
  --shadow: 0 2px 12px rgba(0, 0, 0, .06);
  font-family: "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--ink);
  background: var(--bg);
}

* { box-sizing: border-box; }
html, body, #app { min-width: 1120px; min-height: 100%; margin: 0; }
body { min-height: 100vh; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; border: 0; -webkit-tap-highlight-color: transparent; }
button:active { transform: scale(.98); }

.login-page { min-height: 100vh; display: grid; grid-template-columns: 1.2fr .8fr; background: #eff4ff; }
.login-art { position: relative; overflow: hidden; background: #a81f27; }
.login-art img { width: 100%; height: 100%; object-fit: cover; opacity: .94; }
.login-art-copy { position: absolute; left: 12%; bottom: 13%; width: 420px; color: #fff; }
.login-art-copy span { display: inline-block; padding: 6px 10px; border: 1px solid rgba(255,255,255,.45); border-radius: 4px; font-size: 12px; }
.login-art-copy h1 { margin: 16px 0 10px; font-size: 36px; font-weight: 600; letter-spacing: 0; }
.login-panel { display: grid; place-items: center; padding: 42px; background: #fff; }
.login-card { width: 380px; }
.login-badge { width: 54px; height: 54px; overflow: hidden; border: 2px solid #f2d896; border-radius: 10px; box-shadow: 0 4px 12px rgba(128,23,30,.16); }
.login-badge img { width: 100%; height: 100%; object-fit: cover; }
.login-card h2 { margin: 24px 0 8px; font-size: 26px; font-weight: 600; }
.login-card > p { margin: 0 0 32px; color: var(--muted); font-size: 14px; }
.login-form { display: grid; gap: 16px; }
.login-form label { display: grid; gap: 8px; color: var(--secondary); font-size: 13px; }
.login-error { min-height: 18px; margin: -6px 0 -2px; color: #f53f3f; font-size: 13px; line-height: 18px; }
.login-reset-button { justify-self: end; margin: -8px 0 -2px; padding: 0; color: var(--blue); font-size: 13px; line-height: 18px; background: transparent; }
.login-reset-button:hover { color: #245bdb; }
.public-reset-description { margin: 0; color: #4e5969; font-size: 14px; line-height: 1.7; }
.public-reset-modal .password-form { margin-top: 20px; }

.admin-shell { min-height: 100vh; display: flex; background: var(--bg); }
.sidebar { width: 232px; flex: 0 0 232px; min-height: 100vh; display: flex; flex-direction: column; color: #d7e4ff; background: #172033; }
.side-brand { height: 76px; display: flex; align-items: center; gap: 11px; padding: 0 22px; color: #fff; border-bottom: 1px solid rgba(255,255,255,.08); }
.side-brand-mark { width: 34px; height: 34px; display: grid; place-items: center; overflow: hidden; border-radius: 7px; background: #ab252b; }
.side-brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.side-brand strong { display: block; font-size: 15px; font-weight: 600; }
.side-brand span { display: block; margin-top: 3px; color: #8fa1bf; font-size: 11px; }
.side-nav { flex: 1; padding: 18px 12px; }
.nav-section { margin: 13px 10px 8px; color: #7183a2; font-size: 11px; letter-spacing: 0; }
.nav-item { width: 100%; display: flex; align-items: center; gap: 11px; padding: 11px 12px; border-radius: 7px; color: #bdc9dd; background: transparent; text-align: left; font-size: 14px; }
.nav-item .nav-glyph { width: 18px; color: #8fa1bf; text-align: center; font-size: 16px; }
.nav-item.active { color: #fff; background: var(--blue); box-shadow: 0 3px 10px rgba(54,119,255,.25); }
.nav-item.active .nav-glyph { color: #fff; }
.side-user { display: flex; align-items: center; gap: 9px; padding: 16px 22px; border-top: 1px solid rgba(255,255,255,.08); }
.side-user-avatar { width: 32px; height: 32px; overflow: hidden; border-radius: 50%; }
.side-user-avatar img { width: 100%; height: 100%; object-fit: cover; }
.side-user strong { display: block; color: #fff; font-size: 12px; font-weight: 500; }
.side-user span { display: block; margin-top: 3px; color: #8fa1bf; font-size: 11px; }

.main-area { min-width: 0; flex: 1; }
.topbar { height: 76px; display: flex; align-items: center; justify-content: space-between; padding: 0 28px; background: #fff; border-bottom: 1px solid var(--line); }
.breadcrumb { color: var(--muted); font-size: 13px; }
.breadcrumb b { color: var(--ink); font-weight: 500; }
.top-actions { display: flex; align-items: center; gap: 18px; }
.top-date { color: var(--muted); font-size: 12px; }
.account-menu { position: relative; }
.admin-avatar { width: 42px; height: 42px; flex: 0 0 42px; display: grid; place-items: center; overflow: hidden; padding: 0; border: 0; border-radius: 50%; background: #d9232e; box-shadow: 0 2px 8px rgba(169, 30, 37, .14); transition: transform .16s ease, box-shadow .16s ease; }
.admin-avatar img { width: 100%; height: 100%; display: block; object-fit: cover; border-radius: inherit; }
.avatar-menu-trigger { outline: none; }
.avatar-menu-trigger:hover { transform: translateY(-1px); box-shadow: 0 5px 12px rgba(169, 30, 37, .2); }
.avatar-menu-trigger:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.account-menu-popover { position: absolute; z-index: 12; top: calc(100% + 10px); right: 0; width: 156px; padding: 6px; border: 1px solid var(--line); border-radius: 8px; background: #fff; box-shadow: 0 8px 24px rgba(29,33,41,.14); }
.account-menu-popover button { width: 100%; min-height: 34px; padding: 0 10px; border-radius: 5px; color: var(--secondary); background: transparent; text-align: left; font-size: 13px; }
.account-menu-popover button:hover { color: var(--ink); background: var(--blue-soft); }
.profile-modal { width: 500px; }
.profile-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0 0 22px; padding: 14px; border-radius: 8px; background: #f7f8fa; }
.profile-summary span, .password-form label { display: grid; gap: 6px; color: var(--muted); font-size: 12px; }
.profile-summary b { color: var(--ink); font-size: 14px; font-weight: 500; }
.password-form { display: grid; gap: 14px; }
.password-form h3 { margin: 0; font-size: 16px; }
.password-form label { color: var(--secondary); }
.profile-form-error { min-height: 18px; margin: -4px 0 0; color: var(--danger); font-size: 12px; }
.reset-password-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--line); }
.reset-password-row h3 { margin: 0 0 5px; font-size: 15px; }
.reset-password-row p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.content { padding: 24px 28px 38px; }
.page-heading { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 20px; }
.page-heading h1 { margin: 0; font-size: 20px; font-weight: 600; }
.page-heading p { margin: 7px 0 0; color: var(--muted); font-size: 13px; }
.page-heading-actions { display: flex; align-items: center; gap: 10px; }

.panel { margin-bottom: 20px; padding: 18px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.panel-title { display: flex; align-items: center; justify-content: space-between; margin: 0 0 16px; font-size: 16px; font-weight: 600; }
.panel-title span { color: var(--muted); font-size: 12px; font-weight: 400; }
.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.stat-card { position: relative; overflow: hidden; min-height: 125px; padding: 19px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.stat-card::after { content: ""; position: absolute; right: -16px; bottom: -24px; width: 88px; height: 88px; border: 16px solid rgba(54,119,255,.07); border-radius: 50%; }
.stat-card:nth-child(2)::after { border-color: rgba(0,180,42,.08); }
.stat-card:nth-child(3)::after { border-color: rgba(255,125,0,.08); }
.stat-card:nth-child(4)::after { border-color: rgba(165,31,37,.07); }
.stat-label { color: var(--secondary); font-size: 13px; }
.stat-value { margin: 15px 0 8px; color: var(--blue); font-size: 29px; font-weight: 600; }
.stat-card:nth-child(2) .stat-value { color: var(--success); }
.stat-card:nth-child(3) .stat-value { color: var(--warning); }
.stat-card:nth-child(4) .stat-value { color: #a51f25; }
.stat-note { color: var(--muted); font-size: 12px; }
.dashboard-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 20px; }
.quick-actions { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.quick-action { display: flex; align-items: center; gap: 11px; min-height: 72px; padding: 13px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: #fff; text-align: left; }
.quick-action b { display: block; margin-bottom: 5px; font-size: 13px; font-weight: 500; }
.quick-action span { color: var(--muted); font-size: 11px; }
.quick-symbol { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 8px; color: var(--blue); background: var(--blue-soft); font-size: 19px; }
.rank-list { display: grid; gap: 12px; }
.rank-row { display: grid; grid-template-columns: 25px 1fr 60px; align-items: center; gap: 8px; }
.rank-row i { width: 21px; height: 21px; display: grid; place-items: center; border-radius: 50%; color: var(--secondary); background: #f5f7fa; font-size: 11px; font-style: normal; }
.rank-row:nth-child(1) i { color: #b77a00; background: #fff3d8; }
.rank-row:nth-child(2) i { color: #5e7187; background: #eef2f6; }
.rank-row:nth-child(3) i { color: #ad704a; background: #fff0e7; }
.rank-name { font-size: 13px; }
.rank-bar { height: 7px; margin-top: 6px; overflow: hidden; border-radius: 5px; background: #f2f3f5; }
.rank-bar b { display: block; height: 100%; border-radius: inherit; background: var(--blue); }
.rank-value { color: var(--muted); text-align: right; font-size: 12px; }

.filter-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 20px; }
.filter-bar .spacer { flex: 1; }
.panel:has(#material-search) .batch-toolbar { margin: 0 0 20px; }
.material-filter-bar { min-height: 64px; padding: 14px; border: 1px solid #eef1f5; border-radius: 8px; background: #fafcff; }
.material-filter-bar .search-field { width: 280px; }
.material-filter-bar .date-field { width: 150px; }
.material-filter-bar .date-separator { color: var(--secondary); }
.field, .select, .date-field, .textarea { height: 36px; border: 1px solid var(--border); border-radius: 8px; color: var(--secondary); outline: none; background: #fff; font-size: 13px; }
.field, .select, .date-field { padding: 0 11px; }
.field:focus, .select:focus, .date-field:focus, .textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 2px rgba(54,119,255,.1); }
.field.field-error { border-color: var(--danger); box-shadow: 0 0 0 2px rgba(245,63,63,.1); }
.field-validation-message { color: var(--danger); font-size: 12px; line-height: 1.35; }
.search-field { width: 220px; background: #f5f7fa; }
.date-field { width: 135px; color: var(--muted); }
.textarea { width: 100%; min-height: 94px; height: auto; padding: 10px 11px; resize: vertical; line-height: 1.6; }
.btn { height: 36px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 13px; border-radius: 8px; color: var(--secondary); border: 1px solid #dcdfe6; background: #fff; font-size: 13px; white-space: nowrap; }
.btn.primary { color: #fff; border-color: var(--blue); background: var(--blue); }
.btn.primary:hover { background: var(--blue-hover); }
.btn.danger { color: var(--danger); border-color: #ffd6d6; background: #fff; }
.btn.text { height: auto; padding: 3px 0; border: 0; background: transparent; }
.btn.text.blue { color: var(--blue); }
.btn.text.orange { color: var(--warning); }
.btn.text.red { color: var(--danger); }
.btn:disabled { color: #fff; border-color: #c9cdd4; background: #c9cdd4; cursor: not-allowed; }
.batch-toolbar { min-height: 48px; display: flex; align-items: center; gap: 10px; margin: 16px 0 0; padding: 6px 12px; border-radius: 8px; color: var(--secondary); background: var(--blue-soft); font-size: 13px; }
.batch-toolbar b { color: var(--blue); }

.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table thead { color: var(--secondary); background: #f5f7fa; }
.data-table th { height: 42px; padding: 0 12px; font-weight: 500; text-align: left; white-space: nowrap; }
.data-table td { min-height: 58px; padding: 11px 12px; border-bottom: 1px solid var(--line); color: var(--secondary); vertical-align: middle; }
.data-table tbody tr:hover { background: #f7faff; }
.data-table .align-right { text-align: right; }
.table-thumb { width: 46px; height: 46px; overflow: hidden; border-radius: 6px; }
.material-name { color: var(--ink); font-size: 13px; font-weight: 500; }
.material-code { margin-top: 4px; color: var(--muted); font-size: 11px; }
.tag { display: inline-block; margin: 2px 3px 2px 0; padding: 3px 6px; border-radius: 4px; color: var(--blue); background: var(--blue-soft); font-size: 11px; white-space: nowrap; }
.tag.success { color: var(--success); background: #e8fff0; }
.tag.warning { color: var(--warning); background: #fff5e8; }
.tag.danger { color: var(--danger); background: #fff2f2; }
.action-group { display: inline-flex; gap: 12px; align-items: center; white-space: nowrap; }
.check-box { width: 15px; height: 15px; accent-color: var(--blue); }
.pagination { display: flex; align-items: center; justify-content: space-between; padding-top: 16px; color: var(--muted); font-size: 12px; }
.pager { display: flex; gap: 5px; }
.pager button { width: 28px; height: 28px; border: 1px solid var(--border); border-radius: 4px; color: var(--secondary); background: #fff; }
.pager button.active { color: #fff; border-color: var(--blue); background: var(--blue); }
.pager button:disabled { cursor: not-allowed; opacity: .45; }

.form-layout { display: grid; grid-template-columns: minmax(0, 1fr) 310px; gap: 20px; align-items: start; }
.material-form-layout { grid-template-columns: minmax(0, 1fr); }
.form-panel { padding: 20px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.form-section + .form-section { margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--line); }
.form-section h2 { margin: 0 0 18px; font-size: 16px; font-weight: 600; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid.one { grid-template-columns: 1fr; }
.form-label { display: grid; gap: 8px; color: var(--secondary); font-size: 13px; }
.required::before { content: "*"; margin-right: 4px; color: var(--danger); }
.material-form-layout .required::before { display: none; }
.form-label-title { color: var(--secondary); }
.material-form-layout .form-label.required .form-label-title::before { content: "*"; margin-right: 4px; color: var(--danger); }
.form-label .field, .form-label .select { width: 100%; }
.checkbox-group { display: flex; flex-wrap: wrap; gap: 8px; }
.check-tag { display: inline-flex; align-items: center; gap: 5px; padding: 7px 9px; border: 1px solid var(--border); border-radius: 5px; color: var(--secondary); font-size: 12px; }
.check-tag input { accent-color: var(--blue); }
.upload-zone { min-height: 150px; display: grid; place-items: center; padding: 18px; border: 1px dashed #bfc4ce; border-radius: 8px; color: var(--muted); background: #fafbfc; text-align: center; }
.upload-zone { position: relative; cursor: pointer; transition: .16s ease; }
.upload-zone.drag-over { border-color: var(--blue); background: var(--blue-soft); box-shadow: inset 0 0 0 2px rgba(54,119,255,.1); }
.upload-zone.upload-error { border-color: var(--danger); background: #fff7f7; }
.upload-zone b { display: block; margin-bottom: 7px; color: var(--secondary); font-size: 13px; font-weight: 500; }
.upload-zone span { font-size: 12px; }
.preview-row { display: flex; gap: 9px; margin-top: 12px; }
.preview-card { width: 80px; height: 80px; overflow: hidden; border: 1px solid var(--line); border-radius: 6px; }
.pattern-image-input { position: absolute; z-index: 2; inset: 0; display: block; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.upload-zone > div { position: relative; z-index: 3; pointer-events: none; }
.upload-zone .preview-remove { z-index: 3; pointer-events: auto; }
.upload-feedback { min-height: 16px; margin: 7px 0 0; color: var(--danger); font-size: 12px; line-height: 1.4; }
.uploaded-preview { position: relative; background: #fff; }
.uploaded-preview img { width: 100%; height: 100%; object-fit: cover; }
.preview-remove { position: absolute; top: 3px; right: 3px; width: 18px; height: 18px; padding: 0; border-radius: 50%; color: #fff; background: rgba(29,33,41,.72); font-size: 15px; line-height: 16px; opacity: 0; transition: opacity .16s ease; }
.uploaded-preview:hover .preview-remove, .preview-remove:focus { opacity: 1; }
.product-art.uploaded-art::before, .product-art.uploaded-art .art-body { display: none; }
.product-art.uploaded-art img { width: 100%; height: 100%; display: block; object-fit: cover; }
.preview-trigger { padding: 0; border: 0; cursor: zoom-in; appearance: none; }
.preview-trigger:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.detail-main-art .product-art, .detail-thumbnail .product-art { height: 100%; }
.side-help { padding: 18px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.side-help h3 { margin: 0 0 12px; font-size: 15px; }
.side-help p, .side-help li { color: var(--muted); font-size: 12px; line-height: 1.75; }
.side-help ul { margin: 0; padding-left: 18px; }
.form-footer { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }

.material-detail-grid { display: grid; grid-template-columns: minmax(360px, .9fr) minmax(0, 1.1fr); gap: 20px; align-items: stretch; }
.material-detail-grid .panel { margin-bottom: 0; }
.detail-gallery-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; color: var(--secondary); font-size: 13px; }
.detail-gallery-title b { color: var(--muted); font-size: 12px; font-weight: 400; }
.detail-main-art { height: 390px; overflow: hidden; border-radius: 8px; background: #f5f7fa; }
.detail-gallery-strip { display: flex; gap: 10px; margin-top: 12px; }
.detail-thumbnail { width: 64px; height: 64px; overflow: hidden; border: 2px solid transparent; border-radius: 7px; opacity: .65; }
.detail-thumbnail.active { border-color: var(--blue); opacity: 1; }
.detail-overview { display: flex; flex-direction: column; }
.detail-overview-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding-bottom: 19px; border-bottom: 1px solid var(--line); }
.detail-eyebrow { display: block; margin-bottom: 8px; color: var(--muted); font-size: 12px; }
.detail-overview h2 { margin: 0; color: var(--ink); font-size: 25px; font-weight: 600; }
.detail-overview-header p { margin: 8px 0 0; color: var(--muted); font-size: 13px; }
.detail-meta-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 24px; margin: 22px 0; }
.detail-meta-grid dt, .detail-display-panel dt { margin-bottom: 8px; color: var(--muted); font-size: 12px; }
.detail-meta-grid dd, .detail-display-panel dd { margin: 0; color: var(--secondary); font-size: 14px; }
.detail-introduction { margin-top: auto; padding-top: 19px; border-top: 1px solid var(--line); }
.detail-introduction h3 { margin: 0 0 10px; color: var(--ink); font-size: 15px; }
.detail-introduction p { margin: 0; color: var(--secondary); font-size: 14px; line-height: 1.75; }
.detail-display-panel { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 20px; }
.detail-display-panel h2 { margin: 0 0 8px; color: var(--ink); font-size: 16px; }
.detail-display-panel p { margin: 0; color: var(--muted); font-size: 13px; }
.detail-display-panel dl { display: flex; gap: 36px; margin: 0; flex: 0 0 auto; }


.notice { display: grid; gap: 4px; margin-bottom: 18px; padding: 11px 13px; border: 1px solid #ffd8d8; border-radius: 8px; color: #c53434; background: #fff6f6; font-size: 13px; line-height: 1.5; }
.notice b, .notice span { display: block; }
.import-grid { display: grid; grid-template-columns: .75fr 1.25fr; gap: 20px; }
.import-template { min-height: 248px; padding: 28px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.import-template h2 { margin: 0 0 10px; font-size: 17px; }
.import-template p { color: var(--muted); font-size: 13px; line-height: 1.7; }
.import-template .btn { margin-top: 28px; }
.zip-upload { min-height: 248px; padding: 24px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.zip-drop { min-height: 155px; display: grid; place-items: center; border: 1px dashed #aeb8ca; border-radius: 8px; color: var(--muted); background: #fafcff; text-align: center; }
.zip-drop { cursor: pointer; }
.zip-drop.drag-over { border-color: var(--blue); background: #f0f5ff; }
.zip-drop b { display: block; margin: 6px 0; color: var(--secondary); font-size: 14px; }
.zip-drop input { display: none; }
.duplicate-policy-hint { display: block; margin-top: 8px; color: var(--blue); font-size: 12px; font-style: normal; }
.import-result { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 20px; }
.import-result > div { padding: 13px; border-radius: 8px; background: #fff; box-shadow: var(--shadow); }
.import-result b { display: block; margin-top: 7px; color: var(--ink); font-size: 22px; }
.import-result span { color: var(--muted); font-size: 12px; }
.import-result .success-num b { color: var(--success); }
.import-result .danger-num b { color: var(--danger); }
.import-policy-result { margin: 12px 0 0; color: var(--secondary); font-size: 13px; }

.order-user { display: flex; align-items: center; gap: 8px; }
.tiny-avatar { width: 28px; height: 28px; overflow: hidden; border-radius: 50%; }
.tiny-avatar img { width: 100%; height: 100%; object-fit: cover; }
.order-detail-layout { display: block; }
.order-info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 13px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.order-info-grid div span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 12px; }
.order-info-grid div b { color: var(--secondary); font-size: 13px; font-weight: 500; }
.order-group-block + .order-group-block { margin-top: 20px; padding-top: 19px; border-top: 1px solid var(--line); }
.order-group-block h3 { display: flex; align-items: center; gap: 9px; margin: 0 0 11px; font-size: 14px; }
.order-group-block h3 span { color: var(--muted); font-size: 12px; font-weight: 400; }
.order-product-row { display: flex; align-items: center; gap: 11px; padding: 9px 0; }
.order-product-row + .order-product-row { border-top: 1px solid var(--line); }
.order-product-row .table-thumb { width: 54px; height: 54px; }
.order-product-row b { display: block; color: var(--ink); font-size: 13px; }
.order-product-row p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.order-product-row > span { margin-left: auto; color: var(--secondary); font-size: 13px; }
.order-status-panel { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 24px; padding: 18px 0 0; border-top: 1px solid var(--line); }
.order-status-panel > [data-action="export-order-images"] { flex: 0 0 180px; width: 180px; margin-top: 0; }
.order-status-panel h2 { margin: 0 0 7px; font-size: 16px; }
.order-status-panel p { display: flex; align-items: center; gap: 5px; margin: 0; color: var(--muted); font-size: 12px; }
.status-actions { display: flex; align-items: center; gap: 10px; }
.status-actions .select { min-width: 130px; }

.vi-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.config-image { height: 188px; overflow: hidden; border: 1px solid var(--border); border-radius: 8px; background: #fafbfc; }
.config-image img { width: 100%; height: 100%; object-fit: cover; }
.config-image.qr-preview { display: grid; place-items: center; }
.config-image.qr-preview img { width: 160px; height: 160px; object-fit: contain; }
.config-block { padding: 18px; border-radius: 12px; background: #fff; box-shadow: var(--shadow); }
.config-block h2 { margin: 0 0 17px; font-size: 16px; }
.config-block .form-label + .form-label { margin-top: 14px; }
.required-star { color: var(--danger); font-style: normal; margin-right: 4px; }
.vi-upload-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; }
.vi-upload-row span { min-width: 0; color: var(--muted); font-size: 12px; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vi-file-button { display: inline-flex; align-items: center; flex: 0 0 auto; }
.vi-file-input { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }
.brand-mark-editor { display: flex; align-items: center; gap: 13px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.brand-mark-preview { width: 56px; height: 56px; flex: 0 0 auto; overflow: hidden; border: 1px solid var(--border); border-radius: 8px; background: #fafbfc; }
.brand-mark-preview img { width: 100%; height: 100%; object-fit: cover; }
.brand-mark-editor > div:last-child { min-width: 0; display: flex; flex: 1; flex-wrap: wrap; align-items: center; gap: 7px 10px; }
.brand-mark-editor b { color: var(--ink); font-size: 13px; }
.brand-mark-editor span { flex-basis: 100%; color: var(--muted); font-size: 12px; line-height: 1.5; }

.product-art { position: relative; width: 100%; height: 100%; overflow: hidden; background: #ead9d3; }
.product-art::before { content: ""; position: absolute; inset: 14% 15%; border: 3px solid #d4a24c; box-shadow: inset 0 0 0 1px #9f2029, 0 2px 7px rgba(86,36,27,.14); }
.product-art .art-body { position: absolute; inset: 24% 14%; overflow: hidden; background: var(--art-bg, #ead4c2); }
.product-art.round::before, .product-art.round .art-body { border-radius: 50%; }
.petal { position: absolute; width: 42%; height: 56%; border-radius: 52% 48% 58% 42%; background: var(--petal, #b6242f); border: 1px solid #d8a85c; }
.petal.p1 { left: 29%; top: -4%; }
.petal.p2 { right: -2%; top: 22%; transform: rotate(90deg); }
.petal.p3 { left: 29%; bottom: -4%; transform: rotate(180deg); }
.petal.p4 { left: -2%; top: 22%; transform: rotate(270deg); }
.flower-center { position: absolute; left: 37%; top: 37%; width: 26%; height: 26%; border: 2px solid #9e1724; border-radius: 50%; background: #e1b46e; z-index: 2; }
.product-art[data-theme="jade"] { --art-bg: #cbd9d4; --petal: #226c62; }
.product-art[data-theme="indigo"] { --art-bg: #ced3e3; --petal: #384b91; }
.product-art[data-theme="cinnabar"] { --art-bg: #efd3c9; --petal: #b0262c; }
.product-art[data-theme="ochre"] { --art-bg: #e5d5b5; --petal: #a96922; }
.product-art[data-theme="ink"] { --art-bg: #d7d6d4; --petal: #4c535a; }

.modal-layer { position: fixed; z-index: 30; inset: 0; display: grid; place-items: center; padding: 24px; background: rgba(0,0,0,.5); }
.modal { width: min(620px, 100%); max-height: calc(100vh - 48px); overflow: auto; padding: 22px; border-radius: 12px; background: #fff; box-shadow: 0 4px 20px rgba(0,0,0,.1); }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.modal-head h2 { margin: 0; font-size: 17px; }
.modal-close { width: 28px; height: 28px; color: var(--muted); border-radius: 4px; background: #f5f7fa; font-size: 18px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }
.image-preview-modal { width: min(920px, 100%); padding: 18px; border-radius: 8px; overflow: hidden; }
.image-preview-modal .modal-head { margin-bottom: 14px; }
.image-preview-stage { display: grid; height: min(66vh, 600px); min-height: 280px; place-items: center; overflow: hidden; border-radius: 8px; background: #f5f7fa; }
.image-preview-stage img { display: block; max-width: 100%; max-height: 100%; object-fit: contain; transform-origin: center; transition: transform .16s ease; }
.image-preview-controls { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 14px; }
.image-zoom-controls { display: flex; align-items: center; gap: 8px; }
.icon-btn { width: 34px; min-width: 34px; padding: 0; font-size: 20px; line-height: 32px; }
.zoom-value { min-width: 50px; color: var(--secondary); text-align: center; font-size: 13px; }
.modal-description { margin: 0; color: var(--secondary); font-size: 13px; line-height: 1.65; }
.duplicate-options { display: grid; gap: 10px; margin-top: 16px; }
.duplicate-option { display: flex; align-items: flex-start; gap: 10px; padding: 13px; border: 1px solid var(--border); border-radius: 8px; cursor: pointer; }
.duplicate-option:has(input:checked) { border-color: var(--blue); background: var(--blue-soft); }
.duplicate-option input { margin: 3px 0 0; accent-color: var(--blue); }
.duplicate-option b, .duplicate-option small { display: block; }
.duplicate-option b { color: var(--ink); font-size: 14px; }
.duplicate-option small { margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.55; }
.choice-error { min-height: 18px; margin: 10px 0 0; color: var(--danger); font-size: 12px; }
.toast { position: fixed; z-index: 40; top: 22px; left: 50%; padding: 11px 15px; border-radius: 7px; color: #fff; background: rgba(29,33,41,.92); box-shadow: 0 4px 12px rgba(0,0,0,.12); transform: translateX(-50%); font-size: 13px; }
.toast.success { background: rgba(0,180,42,.92); }
.toast.danger { background: rgba(245,63,63,.92); }

@media (max-width: 1180px) {
  .content { padding: 22px; }
  .dashboard-grid, .material-detail-grid { grid-template-columns: 1fr; }
  .stat-grid { gap: 12px; }
  .vi-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .image-preview-modal { padding: 14px; }
  .image-preview-stage { min-height: 220px; }
  .image-preview-controls { align-items: flex-end; flex-wrap: wrap; }
}

/* qiyi-order-information-export-v1 */
.order-status-panel { flex-wrap: wrap; }
.order-status-panel > div:first-child { flex: 1 1 300px; }
.order-export-actions { display: flex; flex: 0 0 auto; flex-wrap: wrap; align-items: center; gap: 10px; }
.order-export-actions > .btn { min-width: 160px; }
@media (max-width: 900px) {
  .order-export-actions { flex: 1 1 100%; }
  .order-export-actions > .btn { flex: 1 1 160px; }
}
