/* Maestro visual: ImaCash/WebReports. El ambito y la gestion siguen siendo de BO. */
:root {
  --bo-bg: #f3f6f8;
  --bo-surface-soft: #f5f8fb;
  --bo-border: #dce5eb;
  --bo-line: #e3ebf0;
  --bo-text: #15202b;
  --bo-title: #151515;
  --bo-text-soft: #5d6b78;
  --bo-brand: #0077a9;
  --bo-brand-strong: #144d7f;
  --bo-brand-soft: #eaf5f9;
  --bo-dark: #3f3f3f;
  --bo-dark-2: #151515;
  --bo-radius-xl: 8px;
  --bo-radius-lg: 8px;
  --bo-radius-md: 8px;
  --bo-radius-sm: 6px;
  --bo-shadow: none;
  --bo-shadow-soft: none;
}
body { background: var(--bo-bg); }
.bo-shell { min-width: 0; }
.bo-header {
  position: relative;
  flex-wrap: wrap;
  align-items: center;
  margin: 18px 18px 0;
  padding: 16px 18px;
  gap: 14px;
  border: 0;
  border-bottom: 4px solid var(--bo-brand-strong);
  border-radius: 8px;
  background: var(--bo-brand);
  box-shadow: none;
}
.bo-brand-wrap { flex: 1 1 280px; align-items: center; }
.bo-brand { padding: 0; border: 0; background: none; border-radius: 0; min-width: 0; }
.bo-brand-mark { width: 56px; height: 44px; border-radius: 6px; flex: 0 0 56px; }
.bo-brand-copy { min-width: 0; overflow-wrap: anywhere; }
.bo-brand-copy strong { font-size: 24px; }
.bo-brand-copy small { font-size: 13px; }
.bo-header-actions { min-width: 0; }
.bo-header .bo-link-chip { border-radius: 8px; box-shadow: none; }
.bo-header .bo-link-chip-ghost { background: #d94747; border-color: transparent; color: #fff; }
.bo-header-machine-tools { min-width: 0; }
.bo-header .bo-inline-form-header { min-width: 0; }
.bo-header .bo-select-compact { max-width: 300px; }
.bo-main { width: calc(100% - 36px); max-width: none; padding: 16px 0 28px; }
.bo-main-nav {
  display: grid;
  grid-template-columns: repeat(10, minmax(0, 1fr));
  flex: 1 0 100%;
  flex-wrap: wrap;
  overflow: visible;
  gap: 8px;
  padding: 14px 0 0;
  border-top: 1px solid #ffffff40;
}
.bo-main-nav .bo-nav-link {
  flex: 1 1 100px;
  min-width: 0;
  min-height: 40px;
  padding: 9px 12px;
  border-radius: 6px;
  border-color: #ffffff45;
  background: #ffffffeb;
  color: var(--bo-title);
  white-space: normal;
  text-align: center;
  line-height: 1.3;
  box-shadow: none;
}
.bo-main-nav .bo-nav-link:hover,
.bo-main-nav .bo-nav-link.is-active {
  background: #3f3f3f;
  border-color: #151515;
  color: #fff;
  box-shadow: none;
  transform: none;
}
.bo-page-hero {
  padding: 0;
  margin-bottom: 14px;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  min-height: 0;
}
.bo-page-hero::after { display: none; }
.bo-page-hero h1, .bo-panel h1 { font-size: 26px; letter-spacing: 0; line-height: 1.2; }
.bo-kicker { margin: 0 0 5px; font-size: 13px; letter-spacing: 0; text-transform: none; color: var(--bo-brand-strong); }
.bo-page-hero .bo-subtitle { display: none; }
.bo-surface, .bo-panel { padding: 16px; }
.bo-surface { margin-bottom: 16px; }
.bo-surface h2, .bo-card-head h2, .bo-shifts-panel h2 { font-size: 18px; letter-spacing: 0; }
.bo-card-head { margin-bottom: 12px; gap: 12px; }
.bo-card-head p, .bo-subtitle { font-size: 13px; line-height: 1.45; }
.bo-panel { border-top: 4px solid var(--bo-brand); }
.bo-auth { padding-top: 24px; }
.bo-form label > span, .bo-filter-grid label > span { font-size: 13px; letter-spacing: 0; text-transform: none; font-weight: 600; }
.bo-filter-grid, .bo-filter-grid-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.bo-filter-grid > *, .bo-filter-grid label { min-width: 0; }
.bo-filter-grid input, .bo-select, .bo-input, .bo-form input {
  padding: 10px 12px;
  min-height: 42px;
  border-radius: 8px;
  border-color: #c8d6df;
  background: #fff;
  box-shadow: none;
}
.bo-filter-actions { grid-column: 1 / -1; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.bo-button, .bo-link-chip, .bo-icon-button {
  min-height: 38px;
  padding: 9px 14px;
  border-radius: 8px;
  font-size: 13px;
  letter-spacing: 0;
  line-height: 1.3;
  white-space: normal;
  text-align: center;
  box-shadow: none;
}
.bo-button:hover, .bo-link-chip:hover { transform: none; box-shadow: none; }
.bo-button-primary { background: var(--bo-brand); border-color: var(--bo-brand); color: #fff; }
.bo-button-primary:hover { background: var(--bo-brand-strong); }
.bo-button-secondary { background: #3f3f3f; border-color: #3f3f3f; color: #fff; }
.bo-button-secondary:hover { background: #696969; }
.bo-button-link { background: #f5f8fb; color: #15202b; border-color: #c8d6df; }
.bo-icon-button { width: 40px; height: 40px; padding: 0; flex: 0 0 40px; }
.bo-header .bo-icon-button { background: #fff; color: var(--bo-brand-strong); border-color: #c8d6df; }
.bo-flag-chip { width: 38px; height: 38px; border-radius: 6px; padding: 6px; }
.bo-kpi-grid { gap: 12px; margin-bottom: 16px; }
.bo-kpi-card { padding: 12px 14px; border-radius: 8px; background: #fff; box-shadow: none; min-width: 0; }
.bo-kpi-card::after { display: none; }
.bo-kpi-card span { font-size: 12px; letter-spacing: 0; text-transform: none; }
.bo-kpi-card strong { font-size: 22px; letter-spacing: 0; overflow-wrap: anywhere; }
.bo-kpi-card small { font-size: 12px; }
.bo-table-wrap { max-width: 100%; border: 1px solid var(--bo-border); border-radius: 8px; }
.bo-table { min-width: 760px; background: #fff; }
.bo-table th { background: #151515; color: #fff; font-size: 13px; font-weight: 700; letter-spacing: 0; text-transform: none; padding: 12px; }
.bo-table td { padding: 11px 12px; font-size: 14px; color: var(--bo-text); overflow-wrap: anywhere; }
.bo-table tbody tr:nth-child(even) { background: #f9fbfc; }
.bo-chip, .bo-pill { border-radius: 6px; letter-spacing: 0; white-space: normal; overflow-wrap: anywhere; }
.bo-sales-table { min-width: 1250px; }
.bo-sales-table .bo-sales-row td { background: transparent; }
.bo-sales-table .bo-sales-row.is-expanded td:first-child { box-shadow: inset 4px 0 var(--bo-brand); }
.bo-sales-table .bo-sales-row.kind-manual { background: #e7ebef; }
.bo-sales-table .bo-sales-row.kind-refund { background: #ffd7e8; }
.bo-sales-table .bo-sales-row.kind-pending { background: #fff7dc; }
.bo-sales-table .bo-sales-row.kind-postponed { background: #fff0b8; }
.bo-sales-table .bo-sales-row.kind-grouped { background: #dcecff; }
.bo-sales-table .bo-sales-row.kind-card { background: #dff6ff; }
.bo-sales-table .bo-sales-row.kind-cancel { background: #ff0000; }
.bo-sales-table .bo-sales-row.kind-cancel-refund { background: #ff00ff; }
.bo-sales-table .kind-cancel td, .bo-sales-table .kind-cancel-refund td,
.bo-sales-table .kind-cancel small, .bo-sales-table .kind-cancel-refund small { color: #000; font-weight: 700; }
.bo-sales-detail-panel { border: 0; border-radius: 0; box-shadow: none; background: #fff; padding: 14px 0; gap: 14px; }
.bo-sales-detail-head { padding-bottom: 12px; }
.bo-sales-detail-head h2 { font-size: 18px; }
.bo-sales-detail-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.bo-sales-detail-card { border: 0; border-left: 2px solid var(--bo-line); padding: 0 12px; background: none; box-shadow: none; border-radius: 0; }
.bo-sales-detail-card span { font-size: 12px; letter-spacing: 0; text-transform: none; }
.bo-sales-amount-grid { grid-template-columns: 1fr; gap: 6px; }
.bo-sales-amount-grid div { padding: 0; border: 0; background: none; border-radius: 0; }
.bo-sales-amount-grid small { text-transform: none; }
.bo-sales-detail-payload { border-radius: 6px; background: #f5f8fb; }
.bo-sales-detail-toggle { min-width: 0; border-radius: 6px; }
.bo-sales-pagination { padding: 10px 12px; margin-top: 12px; background: #f5f8fb; border: 1px solid var(--bo-border); border-radius: 8px; }
.bo-sales-mix-track { height: 8px; }
.bo-report-detail summary { cursor: pointer; color: var(--bo-brand-strong); font-weight: 600; }
.bo-report-detail .bo-breakdown-grid { min-width: 0; gap: 12px; margin-top: 12px; }
.bo-report-detail .bo-breakdown-grid > section { padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; }
.bo-report-detail h4 { font-size: 13px; margin: 0 0 6px; }
.bo-report-detail .bo-chip-wrap { gap: 6px; }
.bo-report-count { color: var(--bo-text-soft); margin: 0 0 12px; font-size: 13px; }
.bo-report-table td.bo-number { font-variant-numeric: tabular-nums; }
.bo-empty-state { padding: 16px; border-radius: 8px; background: #f5f8fb; }
:is(button, a, input, select, summary):focus-visible { outline: 3px solid #2aa1d3; outline-offset: 3px; }
@media (max-width: 1100px) {
  .bo-main-nav { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .bo-header { flex-direction: row; }
  .bo-brand-wrap { flex-direction: row; width: auto; }
  .bo-header-actions { justify-content: flex-start; }
  .bo-sales-detail-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bo-filter-grid, .bo-filter-grid-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .bo-header { margin: 10px 10px 0; padding: 12px; gap: 12px; }
  .bo-brand-wrap { flex-basis: 100%; }
  .bo-brand-copy strong { font-size: 20px; }
  .bo-brand-copy small { display: none; }
  .bo-header > .bo-main-nav { display: none; }
  .bo-main { width: calc(100% - 20px); padding: 12px 0 24px; }
  .bo-page-hero { padding: 0; }
  .bo-page-hero h1, .bo-panel h1 { font-size: 22px; }
  .bo-surface, .bo-panel, .bo-kpi-card { padding: 12px; }
  .bo-filter-grid, .bo-filter-grid-stats, .bo-sales-detail-grid { grid-template-columns: 1fr; }
  .bo-filter-actions { justify-content: flex-start; }
  .bo-filter-actions > .bo-button { flex: 1 1 120px; }
  .bo-mobile-menu-toggle, .bo-mobile-menu-close { border-radius: 6px; }
  .bo-mobile-drawer .bo-nav-link { border-radius: 6px; }
  .bo-sales-pagination-controls { flex-wrap: wrap; }
  .bo-report-table-wrap { overflow: visible; border: 0; border-radius: 0; }
  .bo-report-table, .bo-report-table tbody, .bo-report-table tr, .bo-report-table td { display: block; width: 100%; min-width: 0; }
  .bo-report-table { table-layout: auto; background: transparent; }
  .bo-report-table thead { display: none; }
  .bo-report-table tbody > tr { border: 1px solid var(--bo-border); border-radius: 8px; overflow: hidden; margin-bottom: 10px; }
  .bo-report-table tbody > tr[hidden] { display: none; }
  .bo-report-table tbody > tr > td { display: grid; grid-template-columns: minmax(90px, 34%) minmax(0, 1fr); align-items: start; gap: 8px; padding: 9px 10px; }
  .bo-report-table td::before { content: attr(data-label); font-size: 12px; font-weight: 700; color: var(--bo-text-soft); }
  .bo-report-table td > * { min-width: 0; }
  .bo-report-table td small { grid-column: 2; }
  .bo-report-table .bo-sales-detail-row > td { display: block; }
  .bo-report-table .bo-sales-detail-row > td::before { display: none; }
  .bo-report-table .bo-sales-detail-head { flex-direction: column; }
  .bo-report-table .bo-sales-detail-card { padding: 8px 0; border-left: 0; border-bottom: 1px solid var(--bo-line); }
  .bo-report-table .kind-cancel td::before, .bo-report-table .kind-cancel-refund td::before { color: #000; }
}
@media (max-width: 380px) {
  .bo-report-table tbody > tr > td { grid-template-columns: 1fr; gap: 4px; }
  .bo-report-table td small { grid-column: auto; }
}
.bo-report-tools { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin: 0 0 14px; }
.bo-report-tools .bo-button { display: inline-flex; gap: 6px; align-items: center; }
.bo-report-tools [role="status"] { font-size: 13px; flex: 1 1 220px; }
.bo-report-columns { position: relative; }
.bo-report-columns summary { list-style: none; cursor: pointer; }
.bo-report-columns > div { position: absolute; z-index: 20; top: 100%; right: 0; width: 190px; max-width: calc(100vw - 32px); padding: 10px; border: 1px solid var(--bo-border); border-radius: 4px; background: #fff; box-shadow: 0 3px 10px #0002; }
.bo-report-columns label { display: flex; align-items: center; gap: 8px; padding: 5px; font-size: 13px; }
.bo-report-columns input { width: 16px; height: 16px; margin: 0; }
.bo-report-page-form label { display: flex; gap: 8px; align-items: center; }
.bo-report-page-form select { width: 80px; min-height: 32px; }
.bo-report-table [hidden], .bo-report-columns[hidden] { display: none !important; }
@media (min-width: 1050px) {
  .bo-filter-grid, .bo-filter-grid-stats { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
  .bo-filter-surface { padding: 12px; }
  .bo-filter-grid input, .bo-filter-grid select { min-height: 36px; padding: 7px 9px; }
}
.bo-inventory-part { margin-top: 12px; }
.bo-inventory-part + .bo-inventory-part { padding-top: 10px; border-top: 1px solid #dce3e8; }
