/* === Property Flute Data Mapper === */

:root {
    --pf-primary: #2c5282;
    --pf-primary-light: #3182ce;
    --pf-primary-dark: #1a365d;
    --pf-secondary: #4a5568;
    --pf-accent: #ed8936;
    --pf-success: #38a169;
    --pf-warning: #d69e2e;
    --pf-danger: #e53e3e;
    --pf-bg: #f7fafc;
    --pf-card: #ffffff;
    --pf-border: #e2e8f0;
    --pf-text: #2d3748;
    --pf-text-light: #718096;
    --pf-radius: 8px;
    --pf-shadow: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.06);
    --pf-shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);

    /* Multi-owner group colors (alternating) */
    --pf-group-a: #ebf4ff;
    --pf-group-a-hover: #dbeafe;
    --pf-group-b: #f0e6ff;
    --pf-group-b-hover: #e4d5f7;

    /* Row warning tints */
    --pf-row-critical: #fff1f0;
    --pf-row-critical-hover: #ffe4e1;
    --pf-row-soft: #fffceb;
    --pf-row-soft-hover: #fff8d6;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--pf-bg);
    color: var(--pf-text);
    line-height: 1.6;
    min-height: 100vh;
}

/* === Header === */

.app-header {
    background: var(--pf-primary-dark);
    color: white;
    padding: 16px 24px;
    box-shadow: var(--pf-shadow);
}

.app-header h1 {
    font-size: 1.25rem;
    font-weight: 600;
}

.app-header h1 span {
    font-weight: 300;
    opacity: 0.8;
}

/* === Main Layout === */

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 16px;
}

/* === Steps === */

.step {
    display: none;
}

.step.active {
    display: block;
}

.step.hidden {
    display: none;
}

/* === Cards === */

.card {
    background: var(--pf-card);
    border-radius: var(--pf-radius);
    box-shadow: var(--pf-shadow);
    padding: 32px;
    margin-bottom: 20px;
}

.card h2 {
    font-size: 1.5rem;
    color: var(--pf-primary-dark);
    margin-bottom: 4px;
}

.subtitle {
    color: var(--pf-text-light);
    margin-bottom: 24px;
}

.card-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
}

/* === Buttons === */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    font-size: 0.875rem;
    font-weight: 500;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
}

.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 0.8rem;
}

.btn-primary {
    background: var(--pf-primary);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: var(--pf-primary-light);
}

.btn-secondary {
    background: var(--pf-accent);
    color: white;
}

.btn-secondary:hover:not(:disabled) {
    background: #dd6b20;
}

.btn-ghost {
    background: transparent;
    color: var(--pf-secondary);
    border: 1px solid var(--pf-border);
}

.btn-ghost:hover:not(:disabled) {
    background: var(--pf-bg);
}

.hidden {
    display: none !important;
}

/* === Dropzone === */

#dropzone {
    border: 2px dashed var(--pf-border);
    border-radius: var(--pf-radius);
    padding: 48px 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

#dropzone:hover,
#dropzone.dragover {
    border-color: var(--pf-primary-light);
    background: #ebf4ff;
}

.dropzone-icon {
    font-size: 2.5rem;
    color: var(--pf-primary-light);
    margin-bottom: 12px;
}

#dropzone p {
    color: var(--pf-text-light);
}

#dropzone strong {
    color: var(--pf-primary);
}

.dropzone-hint {
    font-size: 0.8rem;
    margin-top: 8px;
}

.import-session {
    text-align: center;
    margin-top: 16px;
}

/* === Mapping Grid === */

#mapping-grid {
    display: grid;
    gap: 12px;
}

.mapping-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    background: var(--pf-bg);
    border-radius: 6px;
}

.mapping-row .source-col {
    font-weight: 500;
    font-size: 0.9rem;
    word-break: break-all;
}

.mapping-row .arrow {
    color: var(--pf-text-light);
    font-size: 1.2rem;
}

.mapping-row select {
    padding: 8px 12px;
    border: 1px solid var(--pf-border);
    border-radius: 6px;
    font-size: 0.875rem;
    background: white;
    cursor: pointer;
}

/* === Warnings Summary Bar === */

#warnings-bar {
    margin-bottom: 16px;
}

.warnings-bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--pf-card);
    border-radius: var(--pf-radius);
    box-shadow: var(--pf-shadow);
    padding: 12px 20px;
}

.warnings-bar-summary {
    display: flex;
    gap: 12px;
    align-items: center;
}

.wbar-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.wbar-badge.critical {
    background: #fff1f0;
    color: #c62828;
    border: 1px solid #ffcdd2;
}

.wbar-badge.soft {
    background: #fffde7;
    color: #f57f17;
    border: 1px solid #fff9c4;
}

/* === Warnings Audit Modal === */

.modal-content.modal-lg {
    max-width: 900px;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--pf-border);
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--pf-text-light);
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
}

.modal-close:hover {
    color: var(--pf-text);
}

.audit-section {
    margin-bottom: 24px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--pf-border);
}

.audit-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    cursor: pointer;
    user-select: none;
    font-weight: 600;
    font-size: 0.9rem;
    border-radius: 0;
}

.audit-section-header.critical {
    background: #c62828;
    color: white;
}

.audit-section-header.soft {
    background: #e65100;
    color: white;
}

.audit-section-header.info {
    background: var(--pf-primary);
    color: white;
}

.audit-section-header .count-pill {
    background: rgba(255,255,255,0.25);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    margin-left: 8px;
}

.audit-section-header .chevron {
    transition: transform 0.2s ease;
    font-size: 0.75rem;
}

.audit-section-header.expanded .chevron {
    transform: rotate(90deg);
}

.audit-detail-list {
    list-style: none;
    padding: 0;
    margin: 0;
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease;
}

.audit-detail-list.expanded {
    max-height: 2000px;
}

.audit-detail-list.critical-list .audit-detail-item {
    background: #fff5f5;
    border-left: 3px solid #e53e3e;
}

.audit-detail-list.critical-list .audit-detail-item:nth-child(even) {
    background: #fff0f0;
}

.audit-detail-list.critical-list .audit-detail-item .audit-sl {
    color: #c62828;
}

.audit-detail-list.soft-list .audit-detail-item {
    background: #fffcf0;
    border-left: 3px solid #ed8936;
}

.audit-detail-list.soft-list .audit-detail-item:nth-child(even) {
    background: #fff8e1;
}

.audit-detail-list.soft-list .audit-detail-item .audit-sl {
    color: #e65100;
}

.audit-detail-list.info-list .audit-detail-item {
    background: #f0f7ff;
    border-left: 3px solid var(--pf-primary-light);
}

.audit-detail-list.info-list .audit-detail-item:nth-child(even) {
    background: #e8f2ff;
}

.audit-detail-list.info-list .audit-detail-item .audit-sl {
    color: var(--pf-primary);
}

.audit-detail-item {
    padding: 10px 18px 10px 18px;
    font-size: 0.84rem;
    color: var(--pf-text);
    border-bottom: 1px solid rgba(0,0,0,0.06);
    display: flex;
    align-items: baseline;
    gap: 10px;
}

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

.audit-sl {
    font-weight: 700;
    font-size: 0.75rem;
    white-space: nowrap;
    min-width: 52px;
}

.audit-msg {
    flex: 1;
}

/* === Preferred Names Modal === */

.pref-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    margin-top: 12px;
    min-width: 580px;
}

.pref-table th {
    text-align: left;
    padding: 8px 10px;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--pf-text-light);
    border-bottom: 2px solid var(--pf-border);
}

.pref-table th:first-child {
    width: 40px;
    text-align: center;
}

.pref-table td {
    padding: 10px 10px;
    border-bottom: 1px solid var(--pf-border);
    vertical-align: middle;
}

.pref-table td:first-child {
    text-align: center;
}

.pref-table tbody tr:nth-child(odd) {
    background: #f8fafc;
}

.pref-table tbody tr:nth-child(even) {
    background: white;
}

.pref-table tbody tr:hover {
    background: #edf2f7;
}

.pref-table tr.pref-unchecked td {
    opacity: 0.4;
}

.pref-table tr.pref-unchecked td:first-child {
    opacity: 1;
}

.pref-table .pref-new-name {
    width: 100%;
    padding: 6px 10px;
    border: 1px solid var(--pf-border);
    border-radius: 4px;
    font-size: 0.85rem;
    font-family: inherit;
}

.pref-table .pref-new-name:focus {
    outline: none;
    border-color: var(--pf-primary-light);
    box-shadow: 0 0 0 2px rgba(49, 130, 206, 0.15);
}

.pref-table .pref-arrow {
    color: var(--pf-text-light);
    font-size: 1rem;
    text-align: center;
}

.pref-name-wrap {
    position: relative;
}

.pref-char-count {
    font-size: 0.7rem;
    text-align: right;
    margin-top: 2px;
    color: var(--pf-text-light);
}

.pref-char-count.over-limit {
    color: var(--pf-danger);
    font-weight: 600;
}

.pref-table .pref-new-name.over-limit {
    border-color: var(--pf-danger);
    background: #fff5f5;
}

.pref-summary {
    padding: 16px 0;
}

.pref-summary-item {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 6px 0;
    font-size: 0.85rem;
    border-bottom: 1px solid var(--pf-border);
}

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

.pref-summary-item .pref-sl-badge {
    font-weight: 700;
    font-size: 0.75rem;
    color: var(--pf-primary);
    min-width: 42px;
}

.pref-summary-item .pref-old {
    text-decoration: line-through;
    color: var(--pf-text-light);
}

.pref-summary-item .pref-arrow-sm {
    color: var(--pf-text-light);
}

.pref-summary-item .pref-new {
    font-weight: 600;
    color: var(--pf-success);
}

.pref-summary-count {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--pf-primary-dark);
    margin-bottom: 12px;
}

/* === Duplicate Voters Modal === */

.dup-group {
    border: 1px solid var(--pf-border);
    border-radius: 8px;
    margin-bottom: 16px;
    overflow: hidden;
}

.dup-group:last-child {
    margin-bottom: 0;
}

.dup-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: #f8fafc;
    border-bottom: 1px solid var(--pf-border);
    cursor: pointer;
    user-select: none;
}

.dup-header label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    flex: 1;
}

.dup-confidence {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dup-confidence.high {
    background: #c8e6c9;
    color: #2e7d32;
}

.dup-confidence.medium {
    background: #fff9c4;
    color: #f57f17;
}

.dup-confidence.low {
    background: #ffcdd2;
    color: #c62828;
}

.dup-body {
    padding: 14px 16px;
}

.dup-reasons {
    font-size: 0.8rem;
    color: var(--pf-text-light);
    margin-bottom: 12px;
    padding-left: 16px;
}

.dup-reasons li {
    margin-bottom: 2px;
}

.dup-profiles {
    margin-bottom: 12px;
}

.dup-profile-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--pf-text-light);
    margin-bottom: 6px;
}

.dup-profile-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 60px;
    gap: 8px;
    padding: 8px 12px;
    font-size: 0.82rem;
    border-bottom: 1px solid var(--pf-border);
}

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

.dup-profile-row span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dup-merged-section {
    background: #f0f7ff;
    border: 1px solid #bee3f8;
    border-radius: 6px;
    padding: 12px;
}

.dup-merged-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--pf-primary);
    margin-bottom: 8px;
}

.dup-merged-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 12px;
    font-size: 0.82rem;
}

.dup-merged-grid .dup-field-label {
    font-weight: 600;
    color: var(--pf-secondary);
    white-space: nowrap;
}

.dup-merged-grid .dup-field-value {
    color: var(--pf-text);
    overflow: hidden;
    text-overflow: ellipsis;
}

.dup-merged-grid input.dup-name-input {
    width: 100%;
    padding: 4px 8px;
    border: 1px solid var(--pf-border);
    border-radius: 4px;
    font-size: 0.82rem;
    font-family: inherit;
}

.dup-merged-grid input.dup-name-input:focus {
    outline: none;
    border-color: var(--pf-primary-light);
    box-shadow: 0 0 0 2px rgba(49, 130, 206, 0.15);
}

.dup-group.dup-unchecked .dup-body {
    opacity: 0.4;
}

#duplicate-modal-body {
    overflow-y: auto;
    overflow-x: auto;
    flex: 1;
    min-height: 0;
}

.dup-summary {
    padding: 16px 0;
}

.dup-summary-count {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--pf-primary-dark);
    margin-bottom: 12px;
}

.dup-summary-item {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 8px 0;
    font-size: 0.85rem;
    border-bottom: 1px solid var(--pf-border);
}

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

.dup-summary-item .dup-sl-badge {
    font-weight: 700;
    font-size: 0.75rem;
    color: var(--pf-primary);
    min-width: 50px;
}

.dup-summary-item .dup-merged-names {
    color: var(--pf-text-light);
}

.dup-summary-item .dup-arrow-sm {
    color: var(--pf-text-light);
}

.dup-summary-item .dup-result-name {
    font-weight: 600;
    color: var(--pf-success);
}

/* === Tabs === */

.tabs {
    display: flex;
    gap: 4px;
    border-bottom: 2px solid var(--pf-border);
    margin-bottom: 16px;
}

.tab {
    padding: 10px 20px;
    background: none;
    border: none;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--pf-text-light);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.15s ease;
}

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

.tab.active {
    color: var(--pf-primary);
    border-bottom-color: var(--pf-primary);
}

/* === Data Tables === */

.table-container {
    overflow-x: auto;
    overflow-y: auto;
    max-height: calc(100vh - 280px);
}

.table-container.hidden {
    display: none;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.data-table th {
    background: var(--pf-primary-dark);
    color: white;
    padding: 10px 14px;
    text-align: left;
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 10;
    white-space: nowrap;
}

.data-table th.th-icon {
    width: 36px;
    text-align: center;
    padding: 10px 4px;
}

.data-table td {
    padding: 8px 14px;
    border-bottom: 1px solid var(--pf-border);
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.data-table td.cell-warn {
    background: #fff3e0 !important;
    border-bottom: 2px solid #ed8936;
    border-top: 2px solid #ed8936;
}

.data-table td.cell-reviewed {
    background: #f0fff4 !important;
    border-bottom: 2px solid var(--pf-success);
    border-top: 2px solid var(--pf-success);
}

.data-table td.cell-overlength {
    background: #fff1f0 !important;
    border-bottom: 2px solid var(--pf-danger);
    border-top: 2px solid var(--pf-danger);
}

.data-table td[contenteditable="true"] {
    cursor: text;
    outline: none;
}

.data-table td[contenteditable="true"]:focus {
    background: #ebf8ff !important;
    box-shadow: inset 0 0 0 2px var(--pf-primary-light);
}

/* Default striping - overridden by group/warning classes */
.data-table tbody tr {
    background: white;
}
.data-table tbody tr:nth-child(even) {
    background: #f8fafc;
}

/* --- Row warning colors (applied via class) --- */
.data-table tr.row-critical {
    background: var(--pf-row-critical) !important;
}
.data-table tr.row-critical:hover {
    background: var(--pf-row-critical-hover) !important;
}
.data-table tr.row-soft {
    background: var(--pf-row-soft) !important;
}
.data-table tr.row-soft:hover {
    background: var(--pf-row-soft-hover) !important;
}

/* --- Multi-owner group colors (voters table) --- */
.data-table tr.group-a {
    background: var(--pf-group-a) !important;
}
.data-table tr.group-a:hover {
    background: var(--pf-group-a-hover) !important;
}
.data-table tr.group-b {
    background: var(--pf-group-b) !important;
}
.data-table tr.group-b:hover {
    background: var(--pf-group-b-hover) !important;
}

/* Warning rows override groups */
.data-table tr.group-a.row-critical,
.data-table tr.group-b.row-critical {
    background: var(--pf-row-critical) !important;
}
.data-table tr.group-a.row-soft,
.data-table tr.group-b.row-soft {
    background: var(--pf-row-soft) !important;
}

/* --- Info icon cell --- */
.td-info {
    text-align: center;
    width: 36px;
    padding: 8px 4px !important;
}

.info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
    font-style: italic;
    cursor: pointer;
    line-height: 1;
    transition: transform 0.15s ease;
}

.info-icon:hover {
    transform: scale(1.2);
}

.info-icon.info-critical {
    background: #ffcdd2;
    color: #c62828;
}

.info-icon.info-soft {
    background: #fff9c4;
    color: #f57f17;
}

/* === Row Info Popover === */

.popover {
    position: fixed;
    z-index: 4000;
    max-width: 360px;
}

.popover.hidden {
    display: none;
}

.popover-content {
    background: var(--pf-primary-dark);
    color: white;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    line-height: 1.5;
    box-shadow: var(--pf-shadow-lg);
}

.popover-content .popover-line {
    margin-bottom: 4px;
}

.popover-content .popover-line:last-child {
    margin-bottom: 0;
}

/* === Actions Bar === */

.actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.actions-left,
.actions-right {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* === Modal === */

.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal.hidden {
    display: none;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: var(--pf-radius);
    box-shadow: var(--pf-shadow-lg);
    padding: 32px;
    width: 90%;
    max-width: 440px;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    z-index: 1;
}

#warnings-modal-body,
#preferred-modal-body {
    overflow-y: auto;
    overflow-x: auto;
    flex: 1;
    min-height: 0;
}

.modal-content h3 {
    font-size: 1.25rem;
    color: var(--pf-primary-dark);
    margin-bottom: 8px;
}

.modal-content p {
    color: var(--pf-text-light);
    font-size: 0.875rem;
    margin-bottom: 20px;
}

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

.form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--pf-secondary);
    margin-bottom: 4px;
}

.form-group input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--pf-border);
    border-radius: 6px;
    font-size: 0.9rem;
}

.form-group input:focus {
    outline: none;
    border-color: var(--pf-primary-light);
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.15);
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
}

/* === Loading Overlay === */

.loading {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.loading.hidden {
    display: none;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--pf-border);
    border-top-color: var(--pf-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* === Toast Notifications === */

#toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 3000;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 12px 20px;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    color: white;
    box-shadow: var(--pf-shadow-lg);
    animation: slideIn 0.3s ease;
    max-width: 380px;
}

.toast.success {
    background: var(--pf-success);
}

.toast.error {
    background: var(--pf-danger);
}

.toast.info {
    background: var(--pf-primary);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* === Responsive === */

@media (max-width: 640px) {
    .card {
        padding: 20px;
    }

    #dropzone {
        padding: 32px 16px;
    }

    .mapping-row {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .mapping-row .arrow {
        transform: rotate(90deg);
    }

    .actions-bar {
        flex-direction: column;
    }

    .actions-left,
    .actions-right {
        width: 100%;
        justify-content: center;
    }

    .data-table td,
    .data-table th {
        padding: 6px 10px;
        font-size: 0.8rem;
    }

    .warnings-bar-inner {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}
