.modal.data-management-modal {
    box-sizing: border-box;
    width: min(1320px, calc(100vw - 24px));
    max-width: none;
    height: min(940px, calc(100dvh - 24px));
    max-height: none;
    overflow: hidden;
}
.data-management-shell { display: grid; grid-template-rows: auto minmax(0, 1fr); height: 100%; min-height: 0; }
.data-management-header { padding: 25px 64px 18px 28px; border-bottom: 1px solid var(--line); background: #fffdf8; }
.data-management-header h2 { margin: 0; font-family: Georgia, serif; font-size: 30px; }
.data-management-header > p:last-child { max-width: 850px; margin: 7px 0 0; color: var(--ink-soft); font-size: 12px; line-height: 1.5; }
.data-management-content { min-height: 0; padding: 20px 28px 36px; overflow: auto; overscroll-behavior: contain; }
.data-overview { margin-bottom: 18px; }
.data-count-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.data-count-grid > div { display: grid; gap: 3px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 12px; background: #f8f7f2; }
.data-count-grid span { color: var(--ink-soft); font-size: 9px; font-weight: 850; text-transform: uppercase; }
.data-count-grid strong { color: var(--navy); font-size: 23px; }
.data-count-grid small { color: #737b8a; font-size: 9px; }
.data-current-source { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 9px; padding: 12px 15px; border: 1px solid #d3dceb; border-radius: 12px; background: #f4f7fc; }
.data-current-source > div { display: grid; gap: 2px; }
.data-current-source strong { font-size: 12px; }
.data-current-source span { color: var(--ink-soft); font-size: 10px; }
.data-current-source b { flex: 0 0 auto; color: var(--green); font-size: 11px; }
.data-section { padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.data-section + .data-section { margin-top: 18px; }
.data-section > p { max-width: 900px; margin: 8px 0 16px; color: var(--ink-soft); font-size: 12px; line-height: 1.55; }
.data-section-heading { display: flex; align-items: start; justify-content: space-between; gap: 16px; }
.data-section-heading h3 { margin: 0; font-size: 19px; }
.local-processing-badge { padding: 6px 9px; border: 1px solid #b8d7ca; border-radius: 999px; color: #246e50; background: #eef9f4; font-size: 9px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.listone-upload-grid { display: grid; grid-template-columns: minmax(260px, 1fr) 170px auto; gap: 10px; align-items: end; }
.listone-upload-grid .button { min-height: 46px; }
.listone-progress { margin-top: 16px; padding: 14px 16px; border: 1px solid #cad6e8; border-radius: 13px; background: #f3f7fd; }
.listone-progress > div { display: flex; justify-content: space-between; gap: 12px; font-size: 11px; }
.listone-progress progress { display: block; width: 100%; height: 12px; margin: 9px 0 6px; accent-color: var(--green); }
.listone-progress small { color: var(--ink-soft); font-size: 9px; }
.listone-preview { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--line); }
.listone-preview-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.listone-preview-head h3 { margin: 0; font-size: 18px; }
.listone-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 12px 0; }
.listone-summary-grid > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; background: #f7f7f3; }
.listone-summary-grid span { color: var(--ink-soft); font-size: 9px; font-weight: 800; text-transform: uppercase; }
.listone-summary-grid strong { font-size: 18px; }
.listone-summary-grid .ok { border-color: #bad8cb; background: #f0faf5; }
.listone-summary-grid .warn { border-color: #e4cf9d; background: #fff8e8; }
.listone-summary-grid .danger { border-color: #e5b9b5; background: #fff1ef; }
.listone-preview .alert ul { margin: 7px 0 0; padding-left: 20px; }
.listone-review-note { display: grid; gap: 3px; margin: 12px 0; padding: 12px 14px; border: 1px solid #dfc986; border-radius: 11px; color: #76510d; background: #fff8e7; }
.listone-review-note.ready { border-color: #b5d7c8; color: #246e50; background: #effaf5; }
.listone-review-note strong { font-size: 11px; }
.listone-review-note span { font-size: 9px; line-height: 1.45; }
.listone-table-wrap { max-height: 480px; overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.listone-table { width: 100%; min-width: 1220px; border-collapse: collapse; font-size: 10px; }
.listone-table th { position: sticky; z-index: 2; top: 0; padding: 8px 6px; color: #fff; background: var(--navy-2); text-align: left; white-space: nowrap; }
.listone-table td { padding: 6px; border-top: 1px solid #ecece7; vertical-align: top; }
.listone-table tr.invalid { background: #fff0ee; }
.listone-table tr.unresolved { background: #fff8e8; }
.listone-table tr.low-confidence { background: #f5f7fb; }
.listone-table input, .listone-table select { min-height: 34px; padding: 5px 6px; font-size: 10px; }
.listone-table td:nth-child(1) { width: 32px; text-align: center; }
.listone-table td:nth-child(2) { width: 56px; }
.listone-table td:nth-child(3) { width: 57px; }
.listone-table td:nth-child(4) { min-width: 145px; }
.listone-table td:nth-child(5) { min-width: 105px; }
.listone-table td:nth-child(n+6):nth-child(-n+9) { width: 72px; }
.listone-table td:nth-child(10) { min-width: 260px; }
.listone-table td:last-child { width: 40px; text-align: center; }
.row-error, .confidence-note { display: block; margin-top: 4px; color: var(--red); font-size: 8px; font-weight: 800; line-height: 1.3; }
.confidence-note { color: #7b668d; }
.match-pill { display: inline-flex; padding: 6px 8px; border-radius: 999px; font-size: 8px; font-weight: 900; text-transform: uppercase; }
.match-pill.exact { color: #246e50; background: #e8f6ef; }
.listone-row-remove { display: inline-grid; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 8px; color: #fff; background: var(--red); font-size: 18px; font-weight: 900; line-height: 1; place-items: center; cursor: pointer; }
.listone-row-remove:hover { filter: brightness(.9); }
.listone-empty-ok { padding: 25px; color: var(--green); font-size: 12px; font-weight: 850; text-align: center; }
.listone-preview-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 13px; }
.warning-like { color: #76510d; border: 1px solid #e4cf9d; background: #fff8e8; }
.backup-action-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; margin-top: 14px; }
.backup-action-card { padding: 16px; border: 1px solid var(--line); border-radius: 13px; background: #f8f8f5; }
.backup-action-card.danger-zone { border-color: #e1bdb9; background: #fff8f7; }
.backup-action-card h4, .repair-auction-box h4 { margin: 0; font-size: 14px; }
.backup-action-card p, .repair-auction-box p { margin: 6px 0 12px; color: var(--ink-soft); font-size: 10px; line-height: 1.5; }
.backup-action-card input { margin-bottom: 9px; background: #fff; }
.repair-auction-box { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 14px; padding: 16px; border: 1px solid #e0c37c; border-radius: 13px; background: #fff9eb; }
.repair-auction-box p { margin-bottom: 0; }
.repair-auction-box .button { flex: 0 0 auto; }

@media (max-width: 760px) {
    .modal.data-management-modal { width: calc(100vw - 10px); height: calc(100dvh - 10px); border-radius: 14px; }
    .data-management-header { padding: 18px 52px 13px 16px; }
    .data-management-header h2 { font-size: 24px; line-height: 1.05; }
    .data-management-content { padding: 13px 11px 24px; }
    .data-count-grid, .listone-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .data-current-source { align-items: start; flex-direction: column; }
    .data-section { padding: 14px 11px; }
    .listone-upload-grid, .backup-action-grid { grid-template-columns: 1fr; }
    .listone-preview-head, .repair-auction-box { align-items: stretch; flex-direction: column; }
    .listone-preview-actions { display: grid; grid-template-columns: 1fr; }
    .listone-preview-actions .button, .repair-auction-box .button { width: 100%; }
}
