/* RECATOOLS — CSV Viewer / Sorter / Converter */
.csv-wrap { padding: 1.25rem; }
.csv-input { width: 100%; min-height: 130px; padding: .75rem .9rem; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85rem; line-height: 1.5; border: 1px solid #ebebeb; border-radius: 10px; resize: vertical; }
.csv-input:focus { outline: none; border-color: #0ea5e9; box-shadow: 0 0 0 3px rgba(14,165,233,.15); }
.csv-controls { display: flex; flex-wrap: wrap; gap: .75rem 1.25rem; align-items: center; margin: .9rem 0; font-size: .85rem; color: #1a1814; }
.csv-controls label { display: inline-flex; align-items: center; gap: .4rem; }
.csv-controls select, .csv-controls input[type="text"] { padding: .35rem .5rem; border: 1px solid #ebebeb; border-radius: 8px; font-size: .82rem; }
.csv-btn { padding: .55rem 1.1rem; font-size: .85rem; font-weight: 700; color: #fff; background: #0ea5e9; border: none; border-radius: 999px; cursor: pointer; }
.csv-btn:hover { background: #0284c7; }
.csv-btn-ghost { padding: .5rem 1rem; font-size: .82rem; font-weight: 600; color: #0369a1; background: #fff; border: 1px solid #0ea5e9; border-radius: 999px; cursor: pointer; }
.csv-actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; margin-bottom: .5rem; }
.csv-file-label { display: inline-flex; align-items: center; gap: .4rem; padding: .5rem 1rem; font-size: .82rem; font-weight: 600; color: #6b6760; background: #fff; border: 1px dashed #cbd5e1; border-radius: 999px; cursor: pointer; }
.csv-file-label input { display: none; }
.csv-status { font-size: .8rem; color: #6b6760; margin: .6rem 0; min-height: 1.1em; }
.csv-table-wrap { overflow-x: auto; border: 1px solid #ebebeb; border-radius: 12px; margin-top: .75rem; max-height: 540px; overflow-y: auto; }
.csv-empty { padding: 2rem 1rem; text-align: center; color: #9b968d; font-size: .9rem; margin: 0; }
.csv-table { border-collapse: collapse; width: 100%; font-size: .85rem; }
.csv-table th, .csv-table td { padding: .5rem .75rem; border-bottom: 1px solid #f0f0ee; text-align: left; white-space: nowrap; }
.csv-table thead th { position: sticky; top: 0; background: #f0f9ff; color: #0c4a6e; font-weight: 700; z-index: 1; }
.csv-th { cursor: pointer; user-select: none; }
.csv-th:hover { background: #e0f2fe; }
.csv-arrow { color: #0ea5e9; font-size: .75rem; }
.csv-rownum { color: #b6b1a8; font-variant-numeric: tabular-nums; text-align: right; background: #fafafa; }
.csv-table tbody tr:hover { background: #f8fafc; }
.csv-export { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid #ebebeb; }
.csv-export-head { font-size: .8rem; font-weight: 700; color: #1a1814; margin-bottom: .6rem; }
.csv-export-btns { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.csv-table-name-wrap { display: inline-flex; align-items: center; gap: .4rem; font-size: .8rem; color: #6b6760; margin-left: auto; }
.csv-output { margin-top: .9rem; padding: .9rem 1rem; background: #1a1814; color: #f3f4f6; border-radius: 10px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .78rem; line-height: 1.5; white-space: pre; overflow-x: auto; max-height: 360px; overflow-y: auto; }
.csv-out-actions { display: flex; gap: .6rem; margin-top: .6rem; }
.csv-download { display: inline-block; padding: .5rem 1rem; font-size: .82rem; font-weight: 700; color: #fff; background: #0ea5e9; border-radius: 999px; text-decoration: none; }
