/* Kilometraje semanal: scoped to the report to preserve existing DANFER forms. */
.km-report-dialog { width:min(1500px,96vw);max-width:96vw;max-height:92dvh;overflow:auto;padding:24px;border:1px solid var(--border-color,#40506b);border-radius:16px;background:var(--panel-bg,#0c1b32);color:var(--text-primary,#eef3fc); }
.km-report-dialog::backdrop {background:#020914bb;}
.km-report-head {display:flex;align-items:center;justify-content:space-between;gap:16px;}
.km-filters {display:grid;grid-template-columns:1fr 1fr 2fr auto;align-items:end;gap:12px;margin:20px 0;}
.km-filters label,.km-row-actions label {display:grid;gap:6px;}
.km-report-dialog input,.km-report-dialog select,.km-report-dialog textarea {width:100%;min-width:0;padding:10px;border:1px solid #58677f;border-radius:8px;background:#10223d;color:#fff;box-sizing:border-box;}
.km-summary {display:flex;flex-wrap:wrap;gap:12px;}
.km-summary article {display:grid;gap:6px;padding:14px;border:1px solid #536783;border-radius:12px;flex:1 1 210px;}
.km-table small,.km-warning {display:block;}.km-warning {color:#ffcc70;}.km-row-actions {display:grid;gap:8px;min-width:190px;}.km-row-actions textarea{min-height:70px;resize:vertical;}
.km-report-dialog .table-wrap {max-width:100%;overflow:auto;}.km-report-dialog th,.km-report-dialog td{white-space:normal;min-width:100px;vertical-align:top;}.km-report-dialog details{padding:10px 0;}
@media(max-width:700px){.km-report-dialog{width:96vw;padding:12px;}.km-filters{grid-template-columns:1fr;}.km-report-head h2{font-size:1.2rem;}.km-table thead{display:none;}.km-table,.km-table tbody,.km-table tr,.km-table td{display:block;width:100%;box-sizing:border-box;}.km-table tr{border:1px solid #536783;border-radius:12px;margin:12px 0;padding:8px;}.km-table td{border:0;min-width:0;padding:8px;}.km-table td::before{content:attr(data-label);display:block;font-weight:700;color:#a9c3e8;}.km-row-actions{min-width:0;}}
html body #kmReportDialog .km-warning { color:#a31930 !important; }
html[data-theme="dark"] body #kmReportDialog .km-warning {color:#ffcc70 !important;}
@media(max-width:700px){
  html body #kmReportDialog .km-table td {width:100% !important;max-width:none !important;min-width:0 !important;font-size:14px !important;padding:10px !important;}
  html body #kmReportDialog .km-table td::before {color:inherit !important;opacity:.8;font-size:13px !important;}
  html body #kmReportDialog .km-table small {font-size:12px !important;}
  html body #kmReportDialog .km-table button {min-height:44px;}
}
