:root {
  --bg: #f4f6f8;
  --panel: #ffffff;
  --ink: #171a20;
  --muted: #687180;
  --line: #dce1e7;
  --sidebar: #101319;
  --sidebar-2: #1c212b;
  --red: #c92127;
  --red-2: #ef3b3f;
  --gold: #d09b2c;
  --blue: #243f7a;
  --green: #188264;
  --shadow: 0 18px 44px rgba(18, 24, 34, .10);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body.auth-loading{min-height:100vh;overflow:hidden;background:#f4f6f8}
body.auth-loading::before{content:"";position:fixed;inset:0;z-index:99999;background:#f4f6f8 url("assets/auto-centro-celaya-logo.svg") center calc(50% - 32px)/170px auto no-repeat}
body.auth-loading::after{content:"Cargando dashboard…";position:fixed;left:50%;top:calc(50% + 54px);z-index:100000;transform:translateX(-50%);padding-top:18px;color:#334e8b;font-size:12px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;white-space:nowrap;background:linear-gradient(90deg,#334e8b 0 50%,#d9e1ec 50% 100%) left top/200% 3px no-repeat;animation:auth-loading-progress 1.15s ease-in-out infinite}
@keyframes auth-loading-progress{0%{background-position:100% 0}50%{background-position:0 0}100%{background-position:-100% 0}}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--ink);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--sidebar), var(--sidebar-2));
  color: #fff;
  padding: 18px 14px;
  border-right: 1px solid rgba(255, 255, 255, .08);
  transition: width .18s ease;
  z-index: 10;
}

.sidebar.collapsed {
  width: 86px;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
}

.brand-logo {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  padding: 8px;
}

.brand-logo img {
  width: 158px;
  max-width: 100%;
  height: auto;
  display: block;
}

.icon-btn {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .08);
  color: inherit;
  border-radius: var(--radius);
}

.icon-btn svg {
  width: 19px;
  height: 19px;
}

.side-nav {
  display: grid;
  gap: 6px;
  margin-top: 26px;
}

.nav-item {
  height: 44px;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, .78);
  text-align: left;
  padding: 0 12px;
  border-radius: var(--radius);
}

.nav-item svg {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
}

.nav-item.active,
.nav-item:hover {
  background: #fff;
  color: var(--ink);
}

.bottom-nav {
  margin-top: auto;
}


.sidebar.collapsed .brand-logo,
.sidebar.collapsed .nav-item span {
  display: none;
}

.content {
  min-width: 0;
  padding: 24px;
  max-width: 100%;
  overflow-x: hidden;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  margin-bottom: 22px;
}

.mobile-menu {
  display: none;
  background: var(--panel);
  color: var(--ink);
  border-color: var(--line);
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--red);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 28px;
  line-height: 1.12;
}

h2 {
  font-size: 28px;
  line-height: 1.14;
  margin-bottom: 0;
}

h3 {
  font-size: 16px;
  line-height: 1.2;
  margin-bottom: 10px;
}

.top-actions {
  margin-left: auto;
  display: flex;
  gap: 10px;
  align-items: center;
}

.primary-btn,
.ghost-btn,
.text-btn,
.send-btn,
.danger-btn {
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  padding: 0 13px;
  font-weight: 750;
  white-space: nowrap;
}

.primary-btn {
  background: var(--red);
  color: #fff;
}

.ghost-btn {
  background: var(--panel);
  border-color: var(--line);
  color: var(--ink);
}

.text-btn {
  height: auto;
  border: 0;
  padding: 0;
  color: var(--red);
  background: transparent;
}

.send-btn {
  background: var(--ink);
  color: #fff;
}

.danger-btn {
  background: #fff3f3;
  color: #a10f15;
  border-color: #ffd0d0;
}

.primary-btn svg,
.ghost-btn svg,
.text-btn svg,
.send-btn svg,
.danger-btn svg {
  width: 17px;
  height: 17px;
}

.view {
  display: none;
}

.view.active {
  display: block;
  max-width: 100%;
  overflow-x: hidden;
}

.hero {
  min-height: 260px;
  display: flex;
  align-items: flex-end;
  padding: 26px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(13, 16, 22, .92), rgba(13, 16, 22, .48), rgba(13, 16, 22, .16)),
    url("https://spdfc.s3.us-west-2.amazonaws.com/distribuidores/Auto_Centro_de_Celaya/img/fachada.webp") center/cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero h2 {
  max-width: 600px;
  font-size: 38px;
}

.hero-status {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.status-pill,
.priority {
  display: inline-flex;
  align-items: center;
  height: 26px;
  border-radius: var(--radius);
  padding: 0 9px;
  font-size: 12px;
  font-weight: 800;
}

.status-pill.red {
  background: var(--red);
  color: #fff;
}

.status-pill.dark {
  background: #eef1f5;
  color: #394150;
}

.metric-grid,
.module-grid,
.settings-grid {
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

.metric-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.module-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.settings-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.metric-card,
.module-card,
.report-panel,
.insight-panel,
.settings-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(18, 24, 34, .06);
}

.metric-card {
  padding: 18px;
}

.metric-card strong {
  display: block;
  margin: 8px 0 3px;
  font-size: 28px;
}

.metric-label,
.metric-card small,
.kpi-row span,
.kpi-row small,
.clean-list,
.list-subtitle {
  color: var(--muted);
}

.module-card {
  padding: 18px;
}

.module-card p {
  color: var(--muted);
  min-height: 48px;
}

.module-icon {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  margin-bottom: 14px;
}

.module-icon svg {
  width: 22px;
  height: 22px;
}

.module-icon.finance {
  color: #fff;
  background: var(--green);
}

.module-icon.showroom {
  color: #fff;
  background: var(--blue);
}

.module-icon.incentive {
  color: #fff;
  background: var(--gold);
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.report-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.recipient-select {
  height: 38px;
  min-width: 260px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 10px;
  background: #fff;
  color: var(--ink);
}

.report-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
}

.report-panel,
.insight-panel,
.settings-panel {
  padding: 18px;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.panel-head h3 {
  margin-bottom: 0;
}

.kpi-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.kpi-row div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  min-height: 112px;
}

.kpi-row strong {
  display: block;
  margin: 8px 0 6px;
  font-size: 26px;
}

.bar-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.bar-list div {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) 80px;
  align-items: center;
  gap: 10px;
}

.bar-list b {
  height: 12px;
  display: block;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--red), var(--gold));
}

.bar-list em {
  color: var(--muted);
  font-style: normal;
  text-align: right;
}

.funnel {
  display: grid;
  gap: 12px;
}

.funnel div {
  min-height: 62px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 0 14px;
  color: #fff;
  background: linear-gradient(90deg, var(--red), var(--blue));
  border-radius: var(--radius);
  width: calc(var(--value) * 1%);
  min-width: 42%;
}

.funnel strong {
  font-size: 24px;
}

.clean-list {
  margin: 0;
  padding-left: 18px;
  line-height: 1.8;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

th,
td {
  padding: 13px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.priority.high {
  background: #ffe7e8;
  color: #9f1016;
}

.priority.med {
  background: #fff3d9;
  color: #795710;
}

.priority.low {
  background: #e7f6f0;
  color: #11654d;
}

.form-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.form-grid label {
  display: grid;
  gap: 6px;
}

.form-grid label span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.form-grid input,
.form-grid select {
  width: 100%;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 10px;
  background: #fff;
  color: var(--ink);
}

.form-grid button {
  align-self: end;
}

.list-stack {
  display: grid;
  gap: 10px;
}

.list-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
}

.list-title {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 800;
}

.list-subtitle {
  display: block;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  min-width: 280px;
  max-width: calc(100vw - 40px);
  padding: 13px 14px;
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  box-shadow: var(--shadow);
  transform: translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
  z-index: 20;
}

.toast.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1120px) {
  .metric-grid,
  .module-grid,
  .settings-grid,
  .report-layout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 780px) {
  .app-shell {
    display: block;
  }

  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: min(310px, 88vw);
    transform: translateX(-100%);
    transition: transform .18s ease;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .sidebar.collapsed {
    width: min(310px, 88vw);
  }

  .sidebar.collapsed .brand-logo,
  .sidebar.collapsed .nav-item span {
    display: flex;
  }

  .content {
    padding: 18px;
  }

  .mobile-menu {
    display: inline-flex;
  }

  .topbar,
  .section-head {
    align-items: flex-start;
  }

  .top-actions,
  .section-head,
  .report-actions {
    flex-wrap: wrap;
  }

  .top-actions {
    margin-left: 0;
  }

  .hero {
    min-height: 210px;
  }

  .hero h2 {
    font-size: 30px;
  }

  .metric-grid,
  .module-grid,
  .settings-grid,
  .kpi-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .recipient-select {
    min-width: 0;
    width: 100%;
  }

  .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Reportes renderizados desde data/dashboard-data.json */
.eyebrow,
th {
  letter-spacing: 0;
}

.module-card h3 {
  min-height: 58px;
}

.module-card p {
  min-height: 66px;
}

.report-root {
  display: grid;
  gap: 16px;
}

.report-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.report-meta p {
  margin: 0 0 12px;
  color: var(--muted);
  line-height: 1.55;
}

.report-badges,
.update-line,
.auto-refresh {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.update-line,
.auto-refresh {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.update-line svg {
  width: 15px;
  height: 15px;
}

.auto-refresh {
  flex: 0 0 auto;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f8fafc;
  color: #3f4855;
}

.auto-refresh span {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(24, 130, 100, .12);
}

.automation-report-shell {
  border: 1px solid var(--line);
  background: #ffffff;
  min-height: 620px;
  overflow: hidden;
}

.automation-report-shell iframe {
  display: block;
  width: 100%;
  min-height: 780px;
  border: 0;
  background: #ffffff;
}

.automation-report-shell pre {
  margin: 0;
  padding: 22px;
  min-height: 620px;
  white-space: pre-wrap;
  color: #111827;
  font: 14px/1.55 Arial, Helvetica, sans-serif;
}


.report-page-stack {
  display: grid;
  gap: 14px;
  padding: 10px;
  border: 1px solid rgba(197, 20, 12, .24);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(0, 0, 0, .92), rgba(39, 40, 40, .86)),
    linear-gradient(135deg, rgba(197, 20, 12, .18), rgba(83, 71, 65, .14));
  box-shadow: 0 18px 44px rgba(0, 0, 0, .14);
}

.report-page-frame {
  margin: 0 auto;
  width: 100%;
  max-width: 1360px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 6px;
  background: #ffffff;
  box-shadow: 0 16px 38px rgba(0, 0, 0, .20);
}

.report-page-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.pdf-like-report {
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  overflow: auto;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8);
}

.pdf-like-report pre {
  margin: 0;
  min-width: 1180px;
  padding: 20px 22px;
  color: #111827;
  white-space: pre;
  tab-size: 8;
  font: 11px/1.48 Consolas, Monaco, "Courier New", monospace;
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    linear-gradient(90deg, rgba(197,20,12,.08), rgba(51,78,139,.08)) border-box;
}

.section-actions {
  align-self: start;
}

.section-actions .recipient-select {
  min-width: 230px;
}

.section-actions .send-btn {
  background: var(--red);
}

.data-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.data-card {
  min-height: 112px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfe;
}

.section-table table {
  min-width: 760px;
}

.progress-list {
  display: grid;
  gap: 12px;
}

.progress-row {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr) 120px;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.progress-row:last-child {
  border-bottom: 0;
}

.progress-row div {
  min-width: 0;
}

.progress-row span {
  display: block;
  font-weight: 850;
}

.progress-row small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

.progress-row b {
  display: block;
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8edf3;
}

.progress-row b span {
  display: block;
  width: var(--progress);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--red), var(--gold));
}

.progress-row strong {
  text-align: right;
  font-size: 14px;
}

.report-funnel div {
  max-width: 100%;
}

.note-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.note-item {
  min-height: 112px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfe;
}

.note-item p {
  margin: 8px 0 0;
  color: #344052;
  line-height: 1.55;
}

.empty-state {
  padding: 16px;
  color: var(--muted);
}

@media (max-width: 1120px) {
  .report-summary-grid,
  .data-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-section-head,
  .report-meta {
    grid-template-columns: minmax(0, 1fr);
  }

  .report-meta {
    display: grid;
  }
}

@media (max-width: 780px) {
  .module-card h3,
  .module-card p {
    min-height: 0;
  }

  .report-summary-grid,
  .data-card-grid,
  .note-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .report-actions,
  .section-actions {
    width: 100%;
  }

  .report-actions .recipient-select,
  .section-actions .recipient-select,
  .report-actions .send-btn {
    width: 100%;
  }

  .progress-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  .progress-row strong {
    text-align: left;
  }
}


/* Paleta ajustada a chryslercelaya.com.mx */
:root {
  --bg: #f4f4f4;
  --panel: #ffffff;
  --ink: #1f1f1f;
  --muted: #707070;
  --line: #dfdfdf;
  --sidebar: #000000;
  --sidebar-2: #272828;
  --red: #c5140c;
  --red-2: #e30d13;
  --gold: #847770;
  --blue: #334e8b;
  --green: #324b20;
  --brand-brown: #534741;
  --shadow: 0 18px 44px rgba(0, 0, 0, .10);
}

body {
  background: #f4f4f4;
}

.sidebar {
  background: linear-gradient(180deg, #000000, #272828);
}

.nav-item.active,
.nav-item:hover {
  background: #ffffff;
  color: #000000;
}

.eyebrow,
.text-btn {
  color: var(--red);
}

.primary-btn,
.status-pill.red,
.section-actions .send-btn {
  background: var(--red);
}

.ghost-btn,
.metric-card,
.module-card,
.report-meta,
.report-summary-card,
.report-section,
.settings-panel {
  border-color: #dfdfdf;
}

.module-icon.finance {
  background: var(--red);
}

.module-icon.showroom {
  background: var(--brand-brown);
}

.module-icon.incentive {
  background: var(--green);
}

.hero {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .92), rgba(0, 0, 0, .55), rgba(0, 0, 0, .18)),
    url("https://spdfc.s3.us-west-2.amazonaws.com/distribuidores/Auto_Centro_de_Celaya/img/fachada.webp") center/cover;
}

.status-pill.dark,
.auto-refresh {
  background: #f1f1f1;
  color: #534741;
}

.report-summary-card em,
.auto-refresh span {
  color: var(--red);
}

.auto-refresh span {
  background: var(--red);
  box-shadow: 0 0 0 4px rgba(197, 20, 12, .12);
}

.progress-row b span,
.bar-list b {
  background: linear-gradient(90deg, var(--red), var(--brand-brown));
}

.funnel div {
  background: linear-gradient(90deg, var(--red), var(--brand-brown));
}

.priority.high {
  background: #fff0ef;
  color: #880d00;
}

.priority.med {
  background: #f1f1f1;
  color: #534741;
}

.priority.low {
  background: #eef1ec;
  color: #324b20;
}

.section-actions {
  position: relative;
  width: auto;
}

.section-mail-wrap {
  position: relative;
  display: inline-flex;
}

.section-mail-btn {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 12px;
  border: 1px solid #dfdfdf;
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--red);
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .06);
}

.section-mail-btn:hover,
.section-mail-btn:focus-visible {
  border-color: var(--red);
  background: #fff5f4;
  outline: none;
}

.section-mail-btn svg {
  width: 17px;
  height: 17px;
}

.ghost-mini,
.confirm-send-btn {
  height: 34px;
  border-radius: var(--radius);
  padding: 0 11px;
  font-weight: 800;
}

.ghost-mini {
  border: 1px solid #dfdfdf;
  background: #ffffff;
  color: #534741;
}

.confirm-send-btn {
  border: 1px solid var(--red);
  background: var(--red);
  color: #ffffff;
}

@media (max-width: 780px) {
  .section-actions,
  .section-mail-wrap {
    width: auto;
  }
}


/* Ajuste final: gris, negro y azul de chryslercelaya.com.mx */
:root {
  --bg: #f4f4f4;
  --panel: #ffffff;
  --ink: #000000;
  --muted: #707070;
  --line: #dfdfdf;
  --sidebar: #000000;
  --sidebar-2: #272828;
  --red: #334E8B;
  --red-2: #0074E8;
  --gold: #848484;
  --blue: #334E8B;
  --green: #164075;
  --brand-blue: #334E8B;
  --brand-blue-dark: #164075;
  --brand-gray: #707070;
  --brand-gray-soft: #f1f1f1;
  --brand-brown: #424D07;
  --shadow: 0 18px 44px rgba(0, 0, 0, .10);
}

body {
  background: #f4f4f4;
  color: #000000;
}

.sidebar {
  background: linear-gradient(180deg, #000000, #272828);
}

.nav-group {
  display: grid;
  gap: 4px;
}

.nav-parent .submenu-chevron {
  width: 15px;
  height: 15px;
  margin-left: auto;
  transition: transform .16s ease;
}

.nav-parent[aria-expanded="true"] .submenu-chevron {
  transform: rotate(180deg);
}

.submenu {
  display: none;
  gap: 4px;
  margin: 2px 0 4px 20px;
  padding-left: 10px;
  border-left: 1px solid rgba(255, 255, 255, .18);
}

.submenu.open {
  display: grid;
}

.report-section-submenu {
  display: grid;
  gap: 3px;
  margin: -2px 0 6px 36px;
  padding-left: 8px;
  border-left: 1px solid rgba(255, 255, 255, .12);
}

.report-section-submenu[hidden] {
  display: none;
}

.report-section-submenu button {
  min-height: 30px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, .64);
  text-align: left;
  padding: 5px 8px;
  border-radius: var(--radius);
  font-size: 12px;
  line-height: 1.25;
}

.report-section-submenu button:hover {
  background: rgba(255, 255, 255, .09);
  color: #fff;
}

.report-section-submenu button.not-sendable {
  color: rgba(255, 255, 255, .42);
}

.sidebar.collapsed .report-section-submenu {
  display: none;
}

.sub-nav-item {
  min-height: 38px;
  height: auto;
  padding: 9px 10px;
  font-size: 13px;
}

.sub-nav-item svg {
  width: 16px;
  height: 16px;
}

.nav-item.active,
.nav-item:hover,
.nav-parent.active {
  background: #ffffff;
  color: #000000;
}

.sidebar.collapsed .submenu,
.sidebar.collapsed .submenu-chevron {
  display: none;
}

.eyebrow,
.text-btn,
.report-summary-card em,
.section-mail-btn,
.auto-refresh {
  color: var(--brand-blue);
}

.primary-btn,
.status-pill.red,
.send-btn,
.confirm-send-btn {
  background: var(--brand-blue);
  border-color: var(--brand-blue);
}

.primary-btn:hover,
.send-btn:hover,
.confirm-send-btn:hover {
  background: var(--brand-blue-dark);
  border-color: var(--brand-blue-dark);
}

.ghost-btn,
.metric-card,
.module-card,
.report-meta,
.report-summary-card,
.report-section,
.settings-panel,
.data-card,
.note-item,
.list-item,
.recipient-select,
.form-grid input,
.form-grid select,
.ghost-mini {
  border-color: #dfdfdf;
}

.module-icon.finance,
.module-icon.showroom,
.module-icon.incentive,
.module-icon.new-cars {
  background: var(--brand-blue);
  color: #ffffff;
}

.autos-module-grid {
  grid-template-columns: minmax(0, 1fr);
}

.autos-module-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  column-gap: 14px;
}

.autos-module-card .module-icon,
.autos-module-card h3,
.autos-module-card p {
  grid-column: auto;
}

.autos-module-card h3,
.autos-module-card p,
.autos-module-card .report-link-list {
  grid-column: 2;
}

.autos-module-card h3,
.autos-module-card p {
  min-height: 0;
}

.report-link-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.report-link-list button {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid #dfdfdf;
  border-radius: var(--radius);
  background: #ffffff;
  color: #000000;
  padding: 10px;
  font-weight: 800;
  text-align: left;
}

.report-link-list button:hover,
.report-link-list button:focus-visible {
  border-color: var(--brand-blue);
  color: var(--brand-blue);
  outline: none;
}

.report-link-list svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
}

.hero {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .92), rgba(0, 0, 0, .56), rgba(22, 64, 117, .18)),
    url("https://spdfc.s3.us-west-2.amazonaws.com/distribuidores/Auto_Centro_de_Celaya/img/fachada.webp") center/cover;
}

.status-pill.dark,
.auto-refresh {
  background: #f1f1f1;
  color: #343434;
}

.auto-refresh span {
  background: var(--brand-blue);
  box-shadow: 0 0 0 4px rgba(51, 78, 139, .14);
}

.progress-row b span,
.bar-list b,
.funnel div {
  background: linear-gradient(90deg, var(--brand-blue), var(--brand-blue-dark));
}

.priority.high {
  background: #eef3ff;
  color: #164075;
}

.priority.med {
  background: #f1f1f1;
  color: #343434;
}

.priority.low {
  background: #f4f4f4;
  color: #707070;
}

.section-mail-btn:hover,
.section-mail-btn:focus-visible {
  border-color: var(--brand-blue);
  background: #f7f9ff;
  outline: 2px solid rgba(51, 78, 139, .14);
}

@media (max-width: 780px) {
  .submenu {
    margin-left: 18px;
  }

  .autos-module-card,
  .autos-module-card h3,
  .autos-module-card p,
  .autos-module-card .report-link-list {
    display: grid;
    grid-column: 1;
  }

  .report-link-list {
    grid-template-columns: minmax(0, 1fr);
  }
}


/* Envio de reporte completo como popover */
.report-mail-wrap {
  display: inline-flex;
}

.report-mail-btn {
  min-width: 142px;
}

@media (max-width: 780px) {
  .report-mail-wrap,
  .report-mail-btn {
    width: 100%;
  }
}


/* Auth and live backend */
[hidden] {
  display: none !important;
}

.login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    linear-gradient(90deg, rgba(13, 16, 22, .92), rgba(13, 16, 22, .56)),
    url("https://spdfc.s3.us-west-2.amazonaws.com/distribuidores/Auto_Centro_de_Celaya/img/fachada.webp") center/cover;
}

.login-panel {
  width: min(440px, 100%);
  background: rgba(255, 255, 255, .96);
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px;
}

.login-panel img {
  width: 210px;
  max-width: 100%;
  display: block;
  margin-bottom: 24px;
}

.login-panel h1 {
  margin-bottom: 18px;
}

.login-form {
  display: grid;
  gap: 14px;
}

.login-form label {
  display: grid;
  gap: 7px;
}

.login-form label span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.login-form input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 11px;
  background: #fff;
  color: var(--ink);
}

.form-error {
  min-height: 20px;
  margin: 0;
  color: #9f1016;
  font-size: 13px;
  font-weight: 700;
}

.session-chip {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 750;
}

.session-chip svg {
  width: 17px;
  height: 17px;
  color: var(--brand-blue, var(--blue));
}

.confirm-send-btn[disabled],
.primary-btn[disabled],
.ghost-btn[disabled] {
  cursor: wait;
  opacity: .68;
}

@media (max-width: 860px) {
  .session-chip {
    display: none;
  }
}


/* Login contrast pass */
.login-panel {
  background: #ffffff;
  border-color: #c7d0dc;
  box-shadow: 0 22px 60px rgba(0, 0, 0, .28);
}

.login-panel .eyebrow {
  color: #164075;
}

.login-panel h1 {
  color: #101319;
}

.login-form label span {
  color: #263241;
}

.login-form input {
  border-color: #98a4b3;
  color: #101319;
}

.login-form input::placeholder {
  color: #5d6877;
  opacity: 1;
}

.login-form input:focus {
  border-color: #164075;
  outline: 3px solid rgba(51, 78, 139, .18);
}

.login-form .primary-btn {
  background: #164075;
  border-color: #164075;
  color: #ffffff;
}

.login-form .primary-btn:hover,
.login-form .primary-btn:focus-visible {
  background: #0f2d55;
  border-color: #0f2d55;
  outline: 3px solid rgba(22, 64, 117, .22);
}

.view[id^="view-"]:has(.report-root) .section-head {
  margin-bottom: 12px;
}

.report-root:has(.report-page-stack) {
  gap: 10px;
}

.report-root:has(.report-page-stack) .report-meta {
  border-color: rgba(197, 20, 12, .22);
  background: linear-gradient(135deg, #101319, #272828);
  color: #ffffff;
}

.report-root:has(.report-page-stack) .report-meta p,
.report-root:has(.report-page-stack) .update-line,
.report-root:has(.report-page-stack) .auto-refresh {
  color: rgba(255, 255, 255, .78);
}

.report-root:has(.report-page-stack) .auto-refresh {
  background: rgba(255, 255, 255, .08);
  border-color: rgba(255, 255, 255, .18);
}

.report-root:has(.report-page-stack) .report-section {
  padding: 12px;
  border-color: rgba(197, 20, 12, .18);
  background: #ffffff;
}

.report-root:has(.report-page-stack) .report-section-head {
  margin: -12px -12px 10px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(197, 20, 12, .16);
  background: linear-gradient(135deg, #ffffff, #f7f7f7);
}

.report-root:has(.report-page-stack) .report-summary-grid {
  gap: 10px;
}

.report-root:has(.report-page-stack) .report-summary-card {
  border-color: rgba(197, 20, 12, .20);
  background: linear-gradient(180deg, #ffffff, #fafafa);
}

.report-root:not(:has(.report-page-stack)) .report-section {
  padding: 16px;
}

.report-root:not(:has(.report-page-stack)) .section-table {
  overflow-x: auto;
}

.report-root:not(:has(.report-page-stack)) .section-table table {
  min-width: 1080px;
}

.report-root:not(:has(.report-page-stack)) .section-table th {
  background: #101319;
  color: #ffffff;
}

.report-root:not(:has(.report-page-stack)) .section-table td {
  vertical-align: top;
}

.report-root:not(:has(.report-page-stack)) .data-card {
  border-color: rgba(197, 20, 12, .18);
  background: linear-gradient(180deg, #ffffff, #fafafa);
}

.report-root:not(:has(.report-page-stack)) .data-card strong,
.report-root:not(:has(.report-page-stack)) .report-summary-card strong {
  color: #101319;
}

.native-report-document {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(197, 20, 12, .18);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #ffffff, #fafafa);
  overflow-x: auto;
}

.native-report-title {
  margin: 12px 0 4px;
  padding: 9px 11px;
  border-radius: 6px;
  background: linear-gradient(135deg, #101319, #272828);
  color: #ffffff;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 900;
  text-transform: uppercase;
}

.native-report-copy {
  margin: 0;
  max-width: 1120px;
  color: #343434;
  font-size: 13px;
  line-height: 1.55;
}

.native-report-ledger {
  display: flex;
  align-items: stretch;
  width: max-content;
  min-width: min(100%, 980px);
  border: 1px solid #e2e6ec;
  border-radius: 6px;
  background: #ffffff;
  overflow: hidden;
}

.native-report-ledger span {
  display: block;
  min-width: 96px;
  max-width: 240px;
  padding: 7px 8px;
  border-right: 1px solid #e7ebf0;
  color: #222a35;
  font-size: 11px;
  line-height: 1.35;
  word-break: break-word;
}

.native-report-ledger span:last-child {
  border-right: 0;
}

.native-report-ledger.total,
.native-report-line.total {
  border-color: rgba(197, 20, 12, .38);
  background: #fff5f4;
  font-weight: 850;
}

.native-report-line {
  margin: 0;
  width: max-content;
  min-width: min(100%, 980px);
  padding: 7px 8px;
  border: 1px solid #e2e6ec;
  border-radius: 6px;
  background: #ffffff;
  color: #222a35;
  white-space: pre;
  font: 11px/1.45 Consolas, Monaco, "Courier New", monospace;
}

.native-report-spacer {
  height: 8px;
}

.report-root:has(.native-report-document) .report-section {
  padding: 12px;
}

.report-root:has(.native-report-document) .report-section-head {
  margin: -12px -12px 10px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(197, 20, 12, .16);
  background: linear-gradient(135deg, #ffffff, #f7f7f7);
}

/* Native report readability overhaul */
.report-root:has(.native-report-document) {
  gap: 14px;
}

.report-root:has(.native-report-document) .report-meta {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border-color: rgba(197, 20, 12, .18);
  color: #101319;
}

.report-root:has(.native-report-document) .report-meta p,
.report-root:has(.native-report-document) .update-line,
.report-root:has(.native-report-document) .auto-refresh {
  color: #4c5969;
}

.report-root:has(.native-report-document) .auto-refresh {
  background: #ffffff;
  border-color: #d7dee9;
}

.native-report-document {
  gap: 9px;
  width: 100%;
  max-width: 100%;
  padding: 18px;
  overflow: visible;
  border: 1px solid rgba(197, 20, 12, .18);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.96), rgba(250,250,250,.98)),
    linear-gradient(135deg, rgba(197,20,12,.08), rgba(83,71,65,.06));
}

.native-report-title {
  margin: 18px 0 8px;
  padding: 11px 13px;
  border-left: 5px solid var(--red);
  border-radius: 6px;
  background: linear-gradient(90deg, #fff5f4, #ffffff);
  color: #101319;
  font-size: 15px;
  line-height: 1.3;
  font-weight: 900;
  text-transform: none;
  box-shadow: inset 0 -1px 0 rgba(197,20,12,.12);
}

.native-report-copy {
  max-width: 100%;
  margin: 0 0 3px;
  padding: 0 2px;
  color: #2f3742;
  font-size: 14px;
  line-height: 1.65;
}

.native-report-ledger {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  width: 100%;
  min-width: 0;
  border: 1px solid #e0e5ec;
  border-radius: 7px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(16, 19, 25, .045);
}

.native-report-ledger span {
  min-width: 0;
  max-width: none;
  padding: 9px 10px;
  border-right: 1px solid #e7ebf0;
  border-bottom: 1px solid #edf0f4;
  color: #1f2937;
  font-size: 12.5px;
  line-height: 1.45;
  word-break: normal;
  overflow-wrap: anywhere;
}

.native-report-ledger span:last-child {
  border-right: 0;
}

.native-report-ledger.total,
.native-report-line.total {
  border-color: rgba(197, 20, 12, .32);
  background: linear-gradient(90deg, #fff5f4, #ffffff);
  color: #101319;
  font-weight: 850;
}

.native-report-line {
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 9px 10px;
  border: 1px solid #e0e5ec;
  border-radius: 7px;
  background: #ffffff;
  color: #1f2937;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 12.5px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  box-shadow: 0 8px 20px rgba(16, 19, 25, .035);
}

.report-root:has(.native-report-document) .report-section {
  padding: 14px;
  overflow: hidden;
  border-color: rgba(197, 20, 12, .18);
  background: #ffffff;
}

.report-root:has(.native-report-document) .report-section-head {
  margin: -14px -14px 12px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(197, 20, 12, .16);
  background: linear-gradient(135deg, #ffffff, #fafafa);
}

.report-root:has(.native-report-document) .report-section-head h3 {
  color: #101319;
  font-size: 21px;
}

.report-root:has(.native-report-document) .report-section-head p:not(.eyebrow) {
  color: #596372;
  font-size: 14px;
}

.report-root:has(.native-report-document) .report-summary-card {
  border-color: rgba(197,20,12,.18);
  background: linear-gradient(180deg, #ffffff, #fbfbfb);
}

@media (max-width: 920px) {
  .native-report-document { padding: 12px; }
  .native-report-ledger { grid-template-columns: minmax(0, 1fr); }
  .native-report-title { font-size: 14px; }
  .native-report-copy { font-size: 13px; }
}

/* Full report workspace redesign */
.native-report-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  max-width: 100%;
}

.native-report-toc {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 7px;
  max-height: calc(100vh - 36px);
  overflow: auto;
  padding: 14px;
  border: 1px solid rgba(197,20,12,.18);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(16,19,25,.08);
}

.native-report-toc strong {
  display: block;
  margin-bottom: 4px;
  color: #101319;
  font-size: 13px;
  text-transform: uppercase;
}

.native-report-toc a {
  display: block;
  padding: 8px 9px;
  border-left: 3px solid transparent;
  border-radius: 6px;
  color: #485160;
  text-decoration: none;
  font-size: 12.5px;
  line-height: 1.35;
  background: #f8fafc;
}

.native-report-toc a:hover,
.native-report-toc a:focus-visible {
  border-left-color: var(--red);
  color: #101319;
  background: #fff5f4;
  outline: none;
}

.native-report-main {
  min-width: 0;
  display: grid;
  gap: 14px;
}


.native-report-workspace,
.native-report-main,
.native-report-sections,
.native-report-workspace .report-section,
.native-report-workspace .section-body {
  min-width: 0;
  max-width: 100%;
}

.native-report-workspace .report-section,
.native-report-workspace .section-body {
  overflow: hidden;
}

.native-report-workspace .section-table,
.native-report-workspace .report-table-wrap,
.native-report-workspace .table-wrap {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
}

.native-report-workspace .section-table table,
.native-report-workspace .report-table-wrap table,
.native-report-workspace .table-wrap table {
  width: max-content;
  min-width: 1800px;
}

.native-report-workspace .section-table th,
.native-report-workspace .section-table td,
.native-report-workspace .report-table-wrap th,
.native-report-workspace .report-table-wrap td {
  white-space: nowrap;
}

.native-report-workspace .section-table td:first-child,
.native-report-workspace .section-table th:first-child,
.native-report-workspace .report-table-wrap td:first-child,
.native-report-workspace .report-table-wrap th:first-child {
  white-space: normal;
  min-width: 260px;
}


.native-report-kpis {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.native-report-sections {
  gap: 18px;
}

@media (max-width: 1180px) {
  .native-report-workspace { grid-template-columns: minmax(0, 1fr); }
  .native-report-toc { position: static; max-height: none; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
  .native-report-toc strong { grid-column: 1 / -1; }
  .native-report-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .native-report-kpis { grid-template-columns: minmax(0, 1fr); }
}

.automation-missing-panel {
  display: grid;
  gap: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.automation-missing-panel h3 {
  margin: 14px 0 8px;
  font-size: 24px;
  color: var(--ink);
}

.automation-missing-panel p {
  max-width: 920px;
  margin: 0;
  color: #344052;
  font-size: 15px;
  line-height: 1.6;
}

.automation-missing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.automation-missing-grid > div {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 118px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f7f9fc;
}

.automation-missing-grid strong {
  color: var(--ink);
  font-size: 13px;
  text-transform: uppercase;
}

.automation-missing-grid code {
  display: block;
  white-space: normal;
  word-break: break-word;
  color: #164075;
  font-size: 13px;
  line-height: 1.45;
}

.automation-missing-grid span {
  color: #4c5969;
  font-size: 14px;
  line-height: 1.5;
}

@media (max-width: 980px) {
  .automation-missing-grid {
    grid-template-columns: 1fr;
  }
}

.source-pdf-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 7px 10px;
  border: 1px solid rgba(51, 78, 139, .22);
  border-radius: 8px;
  background: #ffffff;
  color: #164075;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.source-pdf-link svg {
  width: 15px;
  height: 15px;
}

.source-pdf-link:hover,
.source-pdf-link:focus-visible {
  border-color: rgba(51, 78, 139, .45);
  background: #eef4ff;
  outline: none;
}

.report-root:has(.report-page-stack) .source-pdf-link {
  border-color: rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .08);
  color: #ffffff;
}

.report-root:has(.report-page-stack) .source-pdf-link:hover,
.report-root:has(.report-page-stack) .source-pdf-link:focus-visible {
  background: rgba(255, 255, 255, .16);
}

.report-action-cluster {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.download-btn {
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.download-btn svg {
  width: 16px;
  height: 16px;
}

.download-btn:hover,
.download-btn:focus-visible {
  border-color: rgba(51, 78, 139, .42);
  background: #eef4ff;
  color: #164075;
  outline: none;
}

.section-actions .report-action-cluster {
  justify-content: flex-end;
}

.section-actions .download-btn,
.section-actions .section-mail-btn {
  height: 34px;
  padding: 0 10px;
  font-size: 12px;
}

@media (max-width: 760px) {
  .report-action-cluster {
    width: 100%;
    justify-content: stretch;
  }

  .download-btn,
  .report-action-cluster .section-mail-wrap,
  .report-action-cluster .section-mail-wrap > button {
    flex: 1 1 150px;
  }
}


.report-section-submenu-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px;
}

.report-section-submenu-row > button {
  min-width: 0;
}

.report-section-submenu .report-action-cluster {
  display: block;
}

.report-section-submenu .section-mail-wrap {
  position: relative;
}

.report-section-submenu .section-mail-btn {
  width: 28px;
  height: 28px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .08);
  color: rgba(255, 255, 255, .72);
  border-radius: var(--radius);
}

.report-section-submenu .section-mail-btn span {
  display: none;
}

.report-section-submenu .section-mail-btn svg {
  width: 14px;
  height: 14px;
}


/* Report sidebar accordion and scroll stability */
.app-shell {
  min-height: 100dvh;
  background: var(--bg);
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 280px;
  height: 100vh;
  height: 100dvh;
  max-height: 100dvh;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  background: #000000;
  background-image: linear-gradient(180deg, #000000, #272828);
  z-index: 30;
  scrollbar-gutter: stable;
}

.sidebar.collapsed {
  width: 86px;
}

.content {
  grid-column: 2;
  min-height: 100dvh;
  background: var(--bg);
}

.sub-nav-item.has-section-menu {
  position: relative;
  padding-right: 8px;
}

.sub-nav-item.has-section-menu > span:not(.report-section-toggle) {
  min-width: 0;
  flex: 1 1 auto;
}

.report-section-toggle {
  width: 26px;
  height: 26px;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 6px;
  color: rgba(255, 255, 255, .68);
  transition: background .16s ease, color .16s ease, transform .16s ease;
}

.report-section-toggle:hover,
.report-section-toggle:focus-visible {
  background: rgba(255, 255, 255, .10);
  color: #ffffff;
  outline: 0;
}

.report-section-toggle svg {
  width: 15px;
  height: 15px;
  transition: transform .16s ease;
}

.sub-nav-item[data-section-expanded="true"] .report-section-toggle svg {
  transform: rotate(180deg);
}

.report-section-submenu {
  display: none;
  overflow: visible;
}

.report-section-submenu.open:not([hidden]) {
  display: grid;
}

.report-section-submenu-row > button span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar.collapsed .report-section-toggle,
.sidebar.collapsed .report-section-submenu {
  display: none;
}

@media (max-width: 780px) {
  .sidebar {
    position: fixed;
    width: min(310px, 88vw);
  }

  .content {
    grid-column: auto;
  }
}


/* Sidebar contrast normalization */
:root {
  --ac-sidebar-bg: #000000;
  --ac-sidebar-text: #f5f5f5;
  --ac-sidebar-muted: #d6d6d6;
  --ac-sidebar-subtle: #b8b8b8;
  --ac-sidebar-active-bg: #ffffff;
  --ac-sidebar-active-text: #111111;
  --ac-sidebar-active-icon: #111111;
  --ac-sidebar-hover-bg: rgba(255, 255, 255, .11);
  --ac-sidebar-hover-text: #ffffff;
  --ac-sidebar-border: rgba(255, 255, 255, .18);
}

.sidebar .nav-item {
  color: var(--ac-sidebar-muted);
}

.sidebar .nav-item svg,
.sidebar .submenu-chevron,
.sidebar .report-section-toggle svg,
.sidebar .section-mail-btn svg {
  color: currentColor;
  stroke: currentColor;
}

.sidebar .nav-item:hover:not(.active):not(.nav-parent.active) {
  background: var(--ac-sidebar-hover-bg);
  color: var(--ac-sidebar-hover-text);
}

.sidebar .nav-item.active,
.sidebar .nav-parent.active {
  background: var(--ac-sidebar-active-bg);
  color: var(--ac-sidebar-active-text);
}

.sidebar .nav-item.active svg,
.sidebar .nav-parent.active svg,
.sidebar .nav-item.active .submenu-chevron,
.sidebar .nav-parent.active .submenu-chevron,
.sidebar .nav-item.active .report-section-toggle,
.sidebar .nav-parent.active .report-section-toggle {
  color: var(--ac-sidebar-active-icon);
  stroke: var(--ac-sidebar-active-icon);
}

.sidebar .nav-item.active:hover,
.sidebar .nav-parent.active:hover {
  background: var(--ac-sidebar-active-bg);
  color: var(--ac-sidebar-active-text);
}

.nav-parent .submenu-chevron,
.report-section-toggle {
  color: var(--ac-sidebar-muted);
}

.sub-nav-item:not(.active) .report-section-toggle {
  color: var(--ac-sidebar-subtle);
}

.sub-nav-item:not(.active):hover .report-section-toggle,
.nav-parent:not(.active):hover .submenu-chevron {
  color: var(--ac-sidebar-hover-text);
}

.report-section-submenu {
  border-left-color: var(--ac-sidebar-border);
}

.report-section-submenu button {
  color: var(--ac-sidebar-subtle);
}

.report-section-submenu button:hover {
  background: var(--ac-sidebar-hover-bg);
  color: var(--ac-sidebar-hover-text);
}

.report-section-submenu button.not-sendable {
  color: rgba(245, 245, 245, .64);
}

.report-section-submenu button.not-sendable:hover {
  color: rgba(245, 245, 245, .78);
}

.report-section-submenu .section-mail-btn {
  border-color: rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .10);
  color: #e6e6e6;
}

.report-section-submenu .section-mail-btn:hover,
.report-section-submenu .section-mail-btn:focus-visible {
  background: rgba(255, 255, 255, .18);
  color: #ffffff;
  border-color: rgba(255, 255, 255, .34);
}

.nav-item.active .report-section-toggle:hover,
.nav-item.active .report-section-toggle:focus-visible {
  background: rgba(0, 0, 0, .08);
  color: var(--ac-sidebar-active-icon);
}


/* Global mail modal */
body.send-modal-open {
  overflow: hidden;
}

.send-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(0, 0, 0, .46);
}

.send-modal {
  width: min(460px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 28px 80px rgba(0, 0, 0, .30);
  padding: 18px;
}

.send-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.send-modal-head h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
}

.send-modal-close {
  flex: 0 0 auto;
  background: #f4f4f4;
  color: #111111;
  border-color: #dfdfdf;
}

.send-modal-context {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 7px 10px;
  margin-bottom: 14px;
  padding: 12px;
  border: 1px solid #e5e5e5;
  border-radius: var(--radius);
  background: #f8f8f8;
}

.send-modal-context span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.send-modal-context strong {
  min-width: 0;
  color: #111111;
  font-size: 13px;
  line-height: 1.35;
}

.send-modal-field {
  display: grid;
  gap: 7px;
}

.send-modal-field span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.send-modal-field input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 11px;
  background: #ffffff;
  color: #111111;
}

.send-modal-field input:focus {
  border-color: var(--brand-blue);
  outline: 3px solid rgba(51, 78, 139, .16);
}

.send-modal-error {
  margin: 10px 0 0;
  padding: 9px 10px;
  border: 1px solid #ffd0d0;
  border-radius: var(--radius);
  background: #fff3f3;
  color: #9f1016;
  font-size: 13px;
  font-weight: 750;
}

.send-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

@media (max-width: 520px) {
  .send-modal-overlay {
    align-items: end;
    padding: 10px;
  }

  .send-modal {
    width: min(100%, calc(100vw - 20px));
    max-height: calc(100vh - 20px);
  }

  .send-modal-context {
    grid-template-columns: minmax(0, 1fr);
  }

  .send-modal-actions {
    flex-direction: column-reverse;
  }

  .send-modal-actions .ghost-btn,
  .send-modal-actions .confirm-send-btn {
    width: 100%;
  }
}

/* Leads dashboard module - preview/controlado */
.leads-dashboard-root {
  display: grid;
  gap: 16px;
}

.module-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.module-breadcrumb i {
  width: 14px;
  height: 14px;
  color: #98a2b3;
}

.module-breadcrumb strong {
  color: var(--ink);
}

.leads-tab-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
}

.lead-tab-btn {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: #394150;
  padding: 0 11px;
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
}

.lead-tab-btn i {
  width: 16px;
  height: 16px;
}

.lead-tab-btn.active {
  border-color: var(--red);
  background: #fff5f5;
  color: var(--red);
}

.lead-tab-btn:hover {
  border-color: var(--red);
  color: var(--red);
}

[data-lead-tab-panel][hidden] {
  display: none !important;
}

.leads-header-panel,
.leads-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: 0 10px 28px rgba(18, 24, 34, .06);
}

.leads-header-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, .8fr);
  gap: 16px;
  align-items: start;
}

.leads-header-panel h3 {
  font-size: 24px;
  margin-bottom: 8px;
}

.leads-header-panel p:not(.eyebrow),
.leads-note {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.45;
}

.leads-context-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.leads-context-row span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #d8e0ed;
  border-radius: var(--radius);
  background: #f6f8fb;
  padding: 0 9px;
  color: #394150;
  font-size: 12px;
  font-weight: 800;
}

.leads-status-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.lead-status,
.lead-alert {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
  background: #f8fafc;
  display: grid;
  gap: 4px;
  min-width: 0;
}

.lead-status b,
.lead-alert span {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 850;
}

.lead-status.ok {
  border-color: #badfd2;
  background: #f0faf6;
}

.lead-status.warn {
  border-color: #ead3a2;
  background: #fff9ea;
}

.lead-status.neutral {
  border-color: #d8e0ed;
  background: #f6f8fb;
}

.leads-kpi-groups {
  display: grid;
  gap: 12px;
}

.lead-kpi-group {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: 0 10px 28px rgba(18, 24, 34, .05);
}

.lead-kpi-group h4 {
  margin: 0 0 10px;
  font-size: 14px;
}

.leads-kpi-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.lead-kpi {
  margin: 0;
}

.leads-action-panel {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid #badfd2;
  border-radius: var(--radius);
  background: #f0faf6;
  padding: 13px 14px;
  color: #11654d;
}

.leads-action-panel strong {
  flex: 0 0 auto;
}

.leads-action-panel span {
  color: #293241;
}

.leads-panel-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.compact-btn {
  height: 30px;
  padding: 0 9px;
  font-size: 12px;
}

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

.leads-panel-head {
  margin-bottom: 14px;
}

.leads-filter-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(5, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.leads-filter-grid label {
  display: grid;
  gap: 6px;
}

.leads-filter-grid span {
  font-size: 12px;
  color: var(--muted);
  font-weight: 800;
}

.leads-filter-grid input,
.leads-filter-grid select {
  height: 38px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 0 10px;
  color: var(--ink);
}

.leads-table-wrap {
  max-height: 560px;
  overflow: auto;
}

.leads-table-wrap.compact {
  max-height: 360px;
}

.leads-table-wrap table {
  min-width: 1320px;
}

.leads-table-wrap th {
  position: sticky;
  top: 0;
  background: #f7f9fc;
  z-index: 1;
}

.leads-two-column {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: 16px;
}

.lead-alert-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.lead-alert strong {
  font-size: 18px;
}

.lead-pending-list {
  margin: 0;
  padding-left: 18px;
  color: #394150;
  display: grid;
  gap: 8px;
  line-height: 1.35;
}

.lead-disclosure {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 0;
}

.lead-disclosure + .lead-disclosure {
  margin-top: 10px;
}

.lead-disclosure summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  font-weight: 850;
  cursor: pointer;
}

.lead-disclosure[open] {
  padding-bottom: 12px;
}

.lead-disclosure[open] summary {
  border-bottom: 1px solid var(--line);
  margin-bottom: 12px;
}

.lead-disclosure .lead-alert-list,
.lead-disclosure .lead-pending-list {
  margin-left: 12px;
  margin-right: 12px;
}

.leads-funnel-panel {
  display: grid;
  gap: 16px;
}

.lead-funnel-warning {
  border: 1px solid #ead3a2;
  background: #fff9ea;
  color: #6f5515;
  border-radius: var(--radius);
  padding: 12px 14px;
  font-weight: 750;
}

.lead-funnel-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.lead-funnel-stage {
  min-height: 158px;
  display: grid;
  align-content: start;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 13px;
  overflow: hidden;
}

.lead-funnel-stage span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.lead-funnel-stage strong {
  font-size: 28px;
  line-height: 1;
}

.lead-funnel-stage b {
  color: var(--red);
}

.lead-funnel-stage small {
  color: #455061;
  line-height: 1.32;
}

.lead-funnel-stage i {
  display: block;
  height: 8px;
  margin-top: auto;
  border-radius: 999px;
  background: #edf1f6;
  overflow: hidden;
}

.lead-funnel-stage i em {
  display: block;
  width: var(--funnel);
  height: 100%;
  background: linear-gradient(90deg, var(--red), var(--gold));
}

.lead-funnel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lead-funnel-actions button {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 0 11px;
  font-weight: 800;
}

.lead-funnel-actions button:hover {
  border-color: var(--red);
  color: var(--red);
}

.funnel-support-grid h4 {
  margin: 0 0 10px;
}

.quality-notes {
  margin-top: 12px;
}

.lead-stage-chip,
.lead-mini-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border: 1px solid #d8e0ed;
  border-radius: 999px;
  background: #f6f8fb;
  padding: 3px 8px;
  color: #293241;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.lead-mini-chip {
  margin: 2px 4px 2px 0;
  border-color: #ead3a2;
  background: #fff9ea;
  color: #6f5515;
}

.lead-meta-panel {
  display: grid;
  gap: 14px;
}

.lead-meta-kpis {
  margin-bottom: 0;
}

.lead-meta-source-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.lead-meta-source-grid div {
  display: grid;
  gap: 5px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f8fafc;
  padding: 11px 12px;
  min-width: 0;
}

.lead-meta-source-grid span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.lead-meta-source-grid strong {
  color: var(--ink);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.lead-meta-breakdown h4 {
  margin: 0 0 10px;
  font-size: 14px;
}

.lead-meta-table table {
  min-width: 1180px;
}

.meta-collapsible-report {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  overflow: hidden;
}

.meta-collapsible-report summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
  background: #f8fafc;
}

.meta-collapsible-report summary::-webkit-details-marker {
  display: none;
}

.meta-collapsible-report summary span {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.meta-collapsible-report summary strong {
  color: var(--ink);
  font-size: 15px;
}

.meta-collapsible-report summary em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.meta-collapsible-report summary small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
  white-space: nowrap;
}

.meta-collapsible-report summary i {
  width: 18px;
  height: 18px;
  color: var(--muted);
  transition: transform 0.16s ease;
}

.meta-collapsible-report[open] summary i {
  transform: rotate(180deg);
}

.meta-collapsible-report__body {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.meta-report-note {
  margin: 0;
}

.meta-collapsible-report .report-table {
  min-width: 1500px;
}

.lead-report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.lead-report-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 14px;
}

.lead-report-card strong,
.lead-report-card span {
  display: block;
}

.lead-report-card strong {
  margin-bottom: 5px;
}

.lead-report-card span {
  color: var(--muted);
  line-height: 1.35;
}

.lead-report-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.leads-next-panel .lead-pending-list {
  max-width: 820px;
}

@media (max-width: 1180px) {
  .leads-kpi-grid,
  .lead-funnel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .leads-filter-grid,
  .leads-header-panel,
  .leads-two-column,
  .lead-meta-source-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .leads-tab-bar {
    margin-left: -2px;
    padding-bottom: 6px;
  }
  .lead-tab-btn {
    min-height: 36px;
    font-size: 12px;
  }
  .leads-kpi-grid,
  .lead-alert-list,
  .leads-status-row,
  .lead-report-grid,
  .lead-report-card {
    grid-template-columns: 1fr;
  }
  .lead-report-badges {
    justify-content: flex-start;
  }
}


.suggested-order-toolbar {
  display: flex;
  justify-content: flex-end;
  margin: 0 0 12px;
}

.save-suggested-orders-btn {
  border: 0;
  border-radius: 8px;
  padding: 10px 18px;
  background: #ffcc00;
  color: #101319;
  font-weight: 900;
  letter-spacing: 0;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(255, 204, 0, .24);
}

.save-suggested-orders-btn:hover,
.save-suggested-orders-btn:focus-visible {
  background: #f1bd00;
  outline: 2px solid rgba(16, 19, 25, .24);
  outline-offset: 2px;
}

.suggested-group-row td {
  position: sticky;
  left: 0;
  z-index: 3;
  padding: 0;
  background: #edf4ff;
}

.suggested-group-toggle {
  display: flex;
  width: min(980px, calc(100vw - 320px));
  min-width: 620px;
  align-items: center;
  gap: 12px;
  border: 0;
  padding: 12px 14px;
  background: linear-gradient(90deg, #0b3f96, #154fd1);
  color: #ffffff;
  text-align: left;
  cursor: pointer;
}

.suggested-group-toggle strong {
  min-width: 150px;
  font-size: 14px;
}

.suggested-group-toggle em {
  color: rgba(255,255,255,.82);
  font-style: normal;
  font-size: 12px;
}

.suggested-group-caret {
  width: 18px;
  font-weight: 900;
}

.suggested-model-cell {
  min-width: 300px;
  white-space: normal !important;
}

.suggested-model-cell strong,
.suggested-model-cell span {
  display: block;
}

.suggested-model-cell strong {
  color: #101319;
  font-size: 13px;
}

.suggested-model-cell span {
  color: #485160;
  font-size: 11px;
  line-height: 1.35;
}

/* Canonical report view recovery */
.report-history-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 18px 0 22px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.report-history-controls > div:first-child {
  display: grid;
  gap: 2px;
  min-width: 220px;
}

.report-history-controls span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.report-history-controls strong {
  color: var(--ink);
  font-size: 16px;
  line-height: 1.2;
}

.report-history-controls small {
  color: #536070;
  font-size: 12px;
}

.report-history-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.view-segment-control {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.segmented-btn {
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid #d6deea;
  border-radius: 999px;
  background: #ffffff;
  color: #10203b;
  font-weight: 800;
  cursor: pointer;
}

.segmented-btn.active,
.segmented-btn[aria-selected="true"] {
  border-color: rgba(197, 20, 12, .48);
  background: #fff3f2;
  color: var(--red);
}

.report-view-panel {
  width: 100%;
  max-width: 1420px;
  margin: 0 auto;
  overflow-x: hidden;
}

.canonical-report {
  display: grid;
  gap: 18px;
  width: 100%;
  max-width: 1420px;
  margin: 0 auto 34px;
  color: #122033;
  overflow-x: hidden;
}

.report-hero {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 28px;
  width: 100%;
  padding: 28px 32px;
  border-radius: 26px;
  background:
    radial-gradient(circle at 92% 86%, rgba(255,255,255,.18) 0 26%, transparent 27%),
    linear-gradient(135deg, #0b3f96 0%, #174bc3 52%, #3474f0 100%);
  color: #ffffff;
  box-shadow: 0 24px 52px rgba(22, 72, 164, .24);
}

.report-hero__brands {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.report-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 12px;
  background: rgba(8, 28, 75, .24);
}

.report-brand--autocentro img {
  display: block;
  width: 150px;
  max-height: 40px;
  object-fit: contain;
}

.report-brand--preneur {
  display: grid;
  gap: 1px;
  text-align: center;
}

.report-brand--preneur strong {
  color: #ffffff;
  font-size: 13px;
  letter-spacing: 2px;
}

.report-brand--preneur small {
  color: rgba(255,255,255,.78);
  font-size: 8px;
  letter-spacing: 1.6px;
}

.report-hero__eyebrow,
.report-section__capsule {
  margin: 0;
  color: #dbeafe;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.report-hero h1 {
  margin: 6px 0 10px;
  color: #ffffff;
  font-size: clamp(32px, 4vw, 44px);
  line-height: 1;
  letter-spacing: 0;
}

.report-hero__description {
  max-width: 760px;
  margin: 0;
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.55;
}

.report-meta-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.report-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid rgba(255,255,255,.38);
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  color: #ffffff;
  font-size: 11px;
}

.report-meta-chip b {
  color: #dbeafe;
  font-size: 9px;
  text-transform: uppercase;
}

.report-section {
  width: 100%;
  padding: 26px 28px;
  border: 1px solid #d9e2ef;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 18px 42px rgba(17, 24, 39, .08);
}

.report-section__capsule {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 14px;
  border-radius: 999px;
  background: #1246b8;
  color: #ffffff;
}

.report-section h2 {
  margin: 14px 0 6px;
  color: #111827;
  font-size: 25px;
  line-height: 1.18;
}

.report-section__description {
  margin: 0 0 20px;
  color: #536070;
  line-height: 1.55;
}

.report-layout-grid,
.report-kpi-grid,
.report-note-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.report-kpi-card,
.report-summary-panel,
.report-note {
  min-width: 0;
  padding: 16px;
  border: 1px solid #dbe4f0;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.report-kpi-card__label {
  display: block;
  color: #17407f;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .5px;
  text-transform: uppercase;
}

.report-kpi-card__value,
.report-summary-panel__value {
  display: block;
  margin-top: 8px;
  color: #0f1a2e;
  font-size: clamp(21px, 1.7vw, 28px);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.report-kpi-card__detail,
.report-summary-panel p,
.report-note p {
  margin: 8px 0 0;
  color: #536070;
  font-size: 12px;
  line-height: 1.45;
}

.report-note strong {
  color: #111827;
}

.report-table-wrap,
.report-table-section {
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid #d8e1ed;
  border-radius: 12px;
  background: #ffffff;
}

.report-table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.report-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 12px 10px;
  background: #123f96;
  color: #ffffff;
  text-align: left;
  font-size: 11px;
  text-transform: uppercase;
}

.report-table td {
  padding: 11px 10px;
  border-bottom: 1px solid #e5ebf3;
  color: #111827;
  vertical-align: top;
}

.report-table tr:nth-child(even) td {
  background: #f7faff;
}

.report-table__total-row td {
  background: #e8f1ff;
  font-weight: 900;
}

.report-table-search {
  position: sticky;
  left: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 280px;
  padding: 10px;
  border-bottom: 1px solid #d8e1ed;
  background: #f8fbff;
}

.report-table-search i {
  width: 16px;
  height: 16px;
  color: #2855a5;
  flex: 0 0 auto;
}

.report-table-search input {
  width: min(460px, 58vw);
  min-width: 220px;
  border: 1px solid #cdd8e8;
  border-radius: 8px;
  padding: 9px 10px;
  font: inherit;
  color: #111827;
  background: #ffffff;
}

.report-table-search input:focus {
  outline: 2px solid rgba(18, 63, 150, .18);
  border-color: #2855a5;
}

.report-table-search span {
  margin-left: auto;
  white-space: nowrap;
  color: #667085;
  font-size: 12px;
  font-weight: 700;
}

.glossary-root .report-table-wrap {
  max-height: calc(100vh - 260px);
}

.glossary-root .report-table {
  min-width: 1100px;
}

.report-footer {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 4px 8px;
  color: #536070;
  font-size: 12px;
}

@media (max-width: 860px) {
  .report-history-controls {
    display: grid;
  }

  .report-history-actions,
  .view-segment-control {
    justify-content: flex-start;
  }

  .report-hero,
  .report-section {
    padding: 20px;
    border-radius: 16px;
  }

  .report-hero__brands {
    display: grid;
  }
}

.content,
.view.active,
.report-root,
.report-view-panel,
.canonical-report,
.canonical-report .report-hero,
.canonical-report .report-section {
  min-width: 0;
  box-sizing: border-box;
}

.content {
  overflow-x: hidden;
}


.incentive-commission-toolbar {
  display: flex;
  justify-content: flex-end;
  margin: 0 0 12px;
}

.incentive-commission-input {
  background: #fff2a8;
  border-color: #d7a900;
  font-weight: 900;
}

[data-incentive-commission-cell],
[data-incentive-commission-total] {
  font-weight: 900;
  color: #101319;
}



/* Criterios globales */
.bottom-nav {
  gap: 10px;
}

.criteria-nav-item {
  position: relative;
  min-height: 48px;
  background: #ffcc00;
  color: #111318;
  box-shadow: 0 10px 22px rgba(255, 204, 0, .22);
}

.criteria-nav-item:hover,
.criteria-nav-item.active {
  background: #ffcc00;
  color: #111318;
}

.sidebar .criteria-nav-item,
.sidebar .criteria-nav-item:hover,
.sidebar .criteria-nav-item.active,
.sidebar .criteria-nav-item.active:hover,
.sidebar .criteria-nav-item span,
.sidebar .criteria-nav-item svg {
  color: #111318;
}

.criteria-nav-item b {
  margin-left: auto;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .36);
}

.sidebar.collapsed .criteria-nav-item b {
  display: none;
}

.criteria-root {
  display: block;
}

.criteria-manual {
  display: grid;
  gap: 16px;
}

.criteria-manual-hero,
.criteria-policy,
.criteria-module,
.criteria-report-card,
.criteria-summary-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 10px 30px rgba(18, 24, 34, .06);
}

.criteria-manual-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: start;
  padding: 24px;
}

.criteria-manual-hero h2 {
  margin-bottom: 8px;
}

.criteria-manual-hero p:not(.eyebrow),
.criteria-module-head p,
.criteria-report-head p,
.criteria-policy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.criteria-manual-meta {
  display: grid;
  gap: 8px;
  justify-items: end;
  color: #394150;
  font-size: 12px;
  font-weight: 850;
}

.criteria-manual-meta span {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f6f8fb;
}

.criteria-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.criteria-summary-card {
  padding: 16px;
}

.criteria-summary-card span,
.criteria-report-head span {
  display: block;
  color: #0f3b86;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.criteria-summary-card strong {
  display: block;
  margin: 6px 0 2px;
  font-size: 28px;
  line-height: 1;
}

.criteria-summary-card small {
  color: var(--muted);
}

.criteria-policy {
  padding: 16px 18px;
  border-left: 5px solid #ffcc00;
}

.criteria-policy strong {
  display: block;
  margin-bottom: 5px;
}

.criteria-module {
  padding: 18px;
}

.criteria-module-head {
  width: 100%;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.criteria-module-head h3 {
  margin: 8px 0 7px;
  font-size: 24px;
}

.criteria-module-head:hover h3,
.criteria-module-head:focus-visible h3 {
  color: #0f3b86;
}

.criteria-module-head:focus-visible {
  outline: 3px solid rgba(15, 59, 134, .22);
  outline-offset: 5px;
  border-radius: var(--radius);
}

.criteria-module-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.criteria-module-actions i {
  width: 20px;
  height: 20px;
  color: #0f3b86;
  transition: transform .18s ease;
}

.criteria-module.is-open .criteria-module-actions i {
  transform: rotate(180deg);
}

.criteria-report-stack,
.criteria-rule-groups {
  display: grid;
  gap: 12px;
}

.criteria-report-stack {
  margin-top: 14px;
}

.criteria-report-card {
  padding: 16px;
  box-shadow: none;
}

.criteria-report-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
}

.criteria-report-head h4 {
  margin: 5px 0 6px;
  font-size: 18px;
}

.criteria-source {
  margin: 12px 0;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: #f6f8fb;
  color: #344052;
  font-size: 13px;
}

.criteria-rule-group {
  border: 1px solid #d8e1ed;
  border-radius: var(--radius);
  background: #fbfcff;
  overflow: hidden;
}

.criteria-rule-group summary {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 12px;
  cursor: pointer;
  font-weight: 900;
}

.criteria-rule-group summary b {
  color: var(--muted);
  font-size: 12px;
}

.criteria-rule-group ol {
  margin: 0;
  padding: 0 14px 14px 34px;
  color: #293241;
  line-height: 1.55;
}

.criteria-rule-group li + li {
  margin-top: 6px;
}

@media (max-width: 1040px) {
  .criteria-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .criteria-manual-hero,
  .criteria-report-head,
  .criteria-module-head,
  .criteria-summary-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .criteria-manual-meta {
    justify-items: start;
  }
}


/* Leads split report layout */
.leads-report-layout {
  display: grid;
  gap: 16px;
}

.leads-report-layout .leads-header-panel,
.leads-report-layout .leads-panel,
.leads-report-layout .lead-kpi-group {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: none;
}

.leads-report-layout .leads-header-panel {
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr);
  padding: 16px 18px;
}

.leads-report-layout .leads-panel,
.leads-report-layout .lead-kpi-group {
  padding: 16px;
}

.leads-report-layout .leads-panel-head,
.leads-report-layout .panel-head {
  margin: -16px -16px 14px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(197, 20, 12, .16);
  background: linear-gradient(135deg, #ffffff, #f7f7f7);
}

.leads-report-layout .leads-kpi-grid {
  gap: 10px;
}

.leads-report-layout .report-summary-card,
.leads-report-layout .lead-kpi,
.leads-report-layout .lead-alert,
.leads-report-layout .lead-funnel-stage,
.leads-report-layout .lead-report-card,
.leads-report-layout .lead-meta-source-grid div {
  border-color: rgba(197, 20, 12, .18);
  background: linear-gradient(180deg, #ffffff, #fafafa);
}

.leads-report-layout .leads-table-wrap th {
  background: #101319;
  color: #ffffff;
}

.leads-report-meta {
  box-shadow: none;
}


/* Leads canonical report alignment: scoped to Leads/Commercial views only. */
.leads-dashboard-root .canonical-report {
  width: 100%;
}

.leads-dashboard-root .canonical-report > .lead-period-panel {
  padding: 20px 24px;
  border: 1px solid #d9e2ef;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(17, 24, 39, .07);
}

.leads-dashboard-root .canonical-report .leads-filter-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin: 0 0 16px;
}

.leads-dashboard-root .canonical-report .leads-panel-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin: 0 0 14px;
}

.leads-dashboard-root .canonical-report .lead-alert-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.leads-dashboard-root .canonical-report .lead-alert {
  border: 1px solid #dbe4f0;
  background: #f8fbff;
}

.leads-dashboard-root .canonical-report .lead-funnel-stage {
  border: 1px solid #dbe4f0;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.leads-dashboard-root .canonical-report .lead-funnel-stage b,
.leads-dashboard-root .canonical-report .lead-stage-chip {
  color: #123f96;
}

.leads-dashboard-root .canonical-report .lead-funnel-actions button,
.leads-dashboard-root .canonical-report .lead-mini-chip {
  border-color: #bfd3f2;
  background: #e8f1ff;
  color: #123f96;
}

.leads-dashboard-root .canonical-report .report-note .lead-report-badges {
  margin-top: 12px;
}

.leads-dashboard-root .canonical-report .status-pill.dark {
  background: #123f96;
  color: #ffffff;
}

.leads-dashboard-root .canonical-report .status-pill.red {
  background: #eef2f7;
  color: #344054;
}

.leads-dashboard-root .canonical-report .link-btn {
  color: #123f96;
  font-weight: 900;
}

/* Leads Web Master report cards readability */
#leads-reportes .lead-report-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  align-items: stretch;
}

#leads-reportes .lead-report-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 178px;
  padding: 16px;
}

#leads-reportes .lead-report-card strong {
  margin: 0;
  color: #111827;
  font-size: 14px;
  line-height: 1.25;
}

#leads-reportes .lead-report-card p {
  margin: 0;
  color: #344054;
  font-size: 13px;
  line-height: 1.5;
}

#leads-reportes .lead-report-badges {
  justify-content: flex-start;
  margin-top: auto;
}

#leads-reportes .lead-report-badges .status-pill {
  max-width: 100%;
  white-space: normal;
  text-align: left;
  line-height: 1.2;
}

/* Scorecard diario advisors dashboard - 2026-06-27 */
.advisor-scorecard-filters {
  grid-template-columns: repeat(6, minmax(150px, 1fr));
}

.advisor-bar-chart {
  display: grid;
  gap: 10px;
  margin: 0 0 16px;
  padding: 14px;
  border: 1px solid var(--line);
  background: #f8fafc;
}

.advisor-bar-chart.empty {
  color: var(--muted);
  font-size: 0.9rem;
}

.advisor-bar-row {
  display: grid;
  grid-template-columns: minmax(110px, 180px) 1fr minmax(32px, auto);
  gap: 12px;
  align-items: center;
  min-height: 28px;
}

.advisor-bar-row span {
  font-size: 0.82rem;
  font-weight: 800;
  color: #111827;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.advisor-bar-row i {
  display: block;
  height: 10px;
  background: #e5e7eb;
  border-radius: 999px;
  overflow: hidden;
}

.advisor-bar-row em {
  display: block;
  height: 100%;
  background: #111827;
  border-radius: inherit;
}

.advisor-bar-row b {
  font-size: 0.82rem;
  color: #374151;
  text-align: right;
}

.advisor-quality-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.advisor-quality-card {
  border: 1px solid var(--line);
  background: #fff;
  padding: 16px;
  display: grid;
  gap: 8px;
  border-left: 6px solid #9ca3af;
}

.advisor-quality-card span {
  font-size: 0.72rem;
  text-transform: uppercase;
  font-weight: 900;
  color: #6b7280;
}

.advisor-quality-card strong {
  font-size: clamp(1.4rem, 2vw, 2rem);
  line-height: 1;
  color: #111827;
}

.advisor-quality-card b {
  font-size: 0.85rem;
  color: #374151;
}

.advisor-quality-card.green { border-left-color: #047857; }
.advisor-quality-card.yellow { border-left-color: #b45309; }
.advisor-quality-card.red { border-left-color: #b91c1c; }

@media (max-width: 980px) {
  .advisor-scorecard-filters,
  .advisor-quality-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .advisor-bar-row {
    grid-template-columns: minmax(90px, 130px) 1fr minmax(28px, auto);
  }
}

@media (max-width: 620px) {
  .advisor-scorecard-filters,
  .advisor-quality-grid {
    grid-template-columns: 1fr;
  }
  .advisor-bar-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .advisor-bar-row b {
    text-align: left;
  }
}

/* Production fix: prevent report status chips from overlapping on long coverage labels. */
.native-report-workspace .report-meta-chips,
.canonical-report .report-meta-chips,
.report-hero__content .report-meta-chips {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  align-items: stretch;
  gap: 10px;
  width: 100%;
  max-width: 100%;
}

.native-report-workspace .report-meta-chips .chip,
.canonical-report .report-meta-chips .chip,
.native-report-workspace .report-meta-chip,
.canonical-report .report-meta-chip {
  min-width: 0;
  width: 100%;
  height: auto;
  min-height: 36px;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
  line-height: 1.35;
  padding-top: 8px;
  padding-bottom: 8px;
}

.native-report-workspace .report-meta-chips .chip b,
.canonical-report .report-meta-chips .chip b,
.native-report-workspace .report-meta-chip b,
.canonical-report .report-meta-chip b {
  flex: 0 0 auto;
  white-space: nowrap;
}

.report-view-metadata {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
  align-items: stretch;
}

.report-view-metadata > * {
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
}

.suggested-order-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.suggested-order-search {
  flex: 1 1 320px;
  margin: 0;
}


/* Compact actions and tables for Pedidos Sugeridos */
.report-section-actions {
  flex: 0 0 auto;
}

#orders-prioridad-compra .report-section-head {
  align-items: center;
}

#orders-prioridad-compra .report-table {
  min-width: 1080px;
  table-layout: auto;
}

#orders-prioridad-compra .report-table th,
#orders-prioridad-compra .report-table td {
  text-align: center;
  vertical-align: middle;
  white-space: normal;
}

#orders-prioridad-compra .report-table th:first-child,
#orders-prioridad-compra .report-table td:first-child {
  min-width: 52px;
  width: 52px;
  max-width: 64px;
  text-align: center;
}

#orders-prioridad-compra .report-table th:nth-child(2),
#orders-prioridad-compra .report-table td:nth-child(2) {
  width: 105px;
}

#orders-prioridad-compra .report-table th:nth-child(3),
#orders-prioridad-compra .report-table td:nth-child(3) {
  min-width: 260px;
  text-align: left;
}

#orders-prioridad-compra .report-table th:nth-child(11),
#orders-prioridad-compra .report-table td:nth-child(11) {
  min-width: 150px;
}

/* Grid report tables for Pedidos Sugeridos and Intercambios */
.managed-grid-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid #d8e1ed;
  border-radius: 8px;
  background: #ffffff;
  -webkit-overflow-scrolling: touch;
}

.managed-grid {
  width: var(--managed-grid-width);
  min-width: var(--managed-grid-width);
  display: block;
  font-size: 11px;
  color: #111827;
}

.managed-grid-head,
.managed-grid-row {
  display: grid;
  grid-template-columns: var(--managed-grid-template);
  width: var(--managed-grid-width);
}

.managed-grid-head {
  position: sticky;
  top: 0;
  z-index: 1;
}

.managed-grid-header,
.managed-grid-cell {
  box-sizing: border-box;
  min-width: 0;
  padding: 8px 7px;
  border-right: 1px solid #e5ebf3;
  border-bottom: 1px solid #e5ebf3;
  line-height: 1.3;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
}

.managed-grid-header {
  background: #123f96;
  color: #ffffff;
  font-weight: 700;
  text-transform: uppercase;
  text-align: center;
}

.managed-grid-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: #ffffff;
}

.managed-grid-row:nth-child(even) .managed-grid-cell {
  background: #f7faff;
}

.managed-grid-model-cell,
.managed-grid-row .managed-grid-cell:nth-child(3),
.managed-grid-row .managed-grid-cell:nth-child(11),
.managed-grid-row .managed-grid-cell:nth-child(13),
.managed-grid-row .managed-grid-cell:nth-child(14) {
  align-items: flex-start;
  justify-content: flex-start;
  text-align: left;
}

.managed-grid-model-cell {
  display: block;
}

.managed-grid-model-cell strong,
.managed-grid-model-cell span {
  display: block;
}

.managed-grid-group-row {
  width: var(--managed-grid-width);
  border-bottom: 1px solid #cfd9e8;
  background: #eef4ff;
}

.managed-grid-group-row .suggested-group-toggle {
  width: 100%;
  min-height: 42px;
  padding: 9px 12px;
  border: 0;
  background: transparent;
  color: #102a55;
  display: flex;
  gap: 10px;
  align-items: center;
  text-align: left;
  cursor: pointer;
}

.managed-grid-group-row .suggested-group-toggle em {
  margin-left: auto;
  color: #536070;
  font-style: normal;
  font-size: 11px;
}

.managed-grid-empty {
  padding: 16px;
  color: #536070;
}

.managed-grid .report-edit-input {
  width: 100%;
  min-width: 0;
}

/* Executive scorecard readability */
#advisor-resumen .lead-kpi-grid,
#advisor-resumen .data-card-grid,
#advisor-resumen .report-layout-grid {
  text-align: center;
}

#advisor-resumen .report-kpi-card,
#advisor-resumen .lead-kpi-card,
#advisor-resumen .data-card {
  align-items: center;
  text-align: center;
}

#advisor-resumen .report-kpi-card__value,
#advisor-resumen strong {
  text-align: center;
}


/* Priority purchase section action visibility */
#orders-prioridad-compra .report-section-actions .section-mail-btn {
  min-width: 148px;
  height: 38px;
  padding: 0 14px;
  background: var(--brand-blue);
  border-color: var(--brand-blue);
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(51, 78, 139, .22);
}

#orders-prioridad-compra .report-section-actions .section-mail-btn span {
  display: inline-flex;
  color: inherit;
  opacity: 1;
  visibility: visible;
  max-width: none;
  white-space: nowrap;
}

#orders-prioridad-compra .report-section-actions .section-mail-btn svg {
  color: inherit;
  flex: 0 0 auto;
}

#orders-prioridad-compra .report-section-actions .section-mail-btn:hover,
#orders-prioridad-compra .report-section-actions .section-mail-btn:focus-visible {
  background: var(--brand-blue-dark);
  border-color: var(--brand-blue-dark);
  color: #ffffff;
}
.module-permissions{border:1px solid #d7dee9;border-radius:10px;padding:12px}.module-permissions legend{font-weight:800;padding:0 6px}.permission-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.permission-grid label{display:flex;align-items:center;gap:7px;font-size:13px}.user-credential{display:flex;gap:6px;align-items:center}.credential-value{font-family:monospace;background:#eef2f6;padding:5px 8px;border-radius:6px}
@media(max-width:700px){.permission-grid{grid-template-columns:1fr}}
/* Configuración: permisos y notificaciones */
.settings-grid{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}.settings-panel{height:auto}.module-permissions{padding:0;overflow:hidden;background:#f8fafc;border:1px solid #d9e0e8;border-radius:14px}.module-permissions summary{list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 16px;background:#fff}.module-permissions summary::-webkit-details-marker{display:none}.module-permissions summary span:first-child{display:grid;gap:3px}.module-permissions summary small{color:#6b7280;font-weight:500}.module-permissions summary:after{content:'⌄';font-size:20px;color:#555}.module-permissions[open] summary:after{transform:rotate(180deg)}.module-count{white-space:nowrap;background:#111;color:#fff;border-radius:999px;padding:5px 9px;font-size:11px;font-weight:800}.module-permissions .permission-grid{padding:12px;grid-template-columns:repeat(2,minmax(0,1fr))}.module-permissions .permission-grid label{padding:10px;background:#fff;border:1px solid #e2e7ed;border-radius:10px;transition:.18s}.module-permissions .permission-grid label:hover{border-color:#111;transform:translateY(-1px)}.module-permissions input{accent-color:#111}.notification-panel{grid-column:1/-1}.notification-panel .panel-head p{margin:4px 0 0;color:#6b7280}.notification-panel form{grid-template-columns:1fr 1fr;align-items:start}.notification-panel textarea{width:100%;border:1px solid #dfdfdf;border-radius:10px;padding:12px;font:inherit;resize:vertical}.notification-panel select[multiple]{min-height:150px;padding:7px}.notification-panel select[multiple] option{padding:8px;border-radius:7px}.notification-panel .primary-btn{grid-column:1/-1;justify-self:start}.notification-summary{margin:12px 0 0;padding:10px 12px;background:#f3f5f7;border-radius:9px;color:#4b5563}@media(max-width:900px){.settings-grid{grid-template-columns:1fr}.notification-panel{grid-column:auto}.notification-panel form{grid-template-columns:1fr}.notification-panel .primary-btn{grid-column:auto}}@media(max-width:560px){.module-permissions .permission-grid{grid-template-columns:1fr}.module-count{display:none}}
/* Configuración autenticada: áreas independientes sin filas vacías */
.settings-grid{display:grid;grid-template-columns:minmax(300px,.78fr) minmax(520px,1.22fr);grid-template-areas:"password users" "contacts users" "notifications notifications";gap:18px;align-items:start}.settings-grid>[data-password-panel]{grid-area:password}.settings-grid>[data-user-admin-panel]{grid-area:users}.settings-grid>[data-contact-panel]{grid-area:contacts}.settings-grid>[data-notification-panel]{grid-area:notifications}.settings-grid>[data-user-admin-panel] .form-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.settings-grid>[data-user-admin-panel] .module-permissions,.settings-grid>[data-user-admin-panel] .primary-btn,.settings-grid>[data-user-admin-panel] .list-stack{grid-column:1/-1}.settings-grid>[data-user-admin-panel] .primary-btn{justify-self:start}.settings-grid>[data-user-admin-panel] .list-stack{margin-top:4px}.settings-grid>[data-password-panel] .form-grid,.settings-grid>[data-contact-panel] .form-grid{grid-template-columns:1fr}.settings-grid .form-grid label>span{font-weight:700}.settings-grid .form-grid small{display:block;margin-top:5px;color:#6b7280;line-height:1.35}
@media(max-width:1120px){.settings-grid{grid-template-columns:1fr;grid-template-areas:"password" "users" "contacts" "notifications"}.settings-grid>[data-user-admin-panel] .form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.settings-grid>[data-user-admin-panel] .form-grid>label:nth-child(3){grid-column:1/-1}}
@media(max-width:650px){.settings-grid>[data-user-admin-panel] .form-grid{grid-template-columns:1fr}.settings-grid>[data-user-admin-panel] .form-grid>label:nth-child(3){grid-column:auto}}
/* Selector de módulos v2 */
.module-picker{background:#f4f6f8;border:1px solid #d9dee5;border-radius:16px;box-shadow:0 10px 28px rgba(17,24,39,.06)}.module-picker>summary{padding:16px 18px;border-radius:16px;background:linear-gradient(135deg,#fff,#f7f8fa)}.module-picker[open]>summary{border-bottom:1px solid #e2e6eb;border-radius:16px 16px 0 0}.module-picker-body{display:grid;gap:16px;padding:14px}.module-picker-actions{display:flex;justify-content:flex-end;gap:8px}.module-picker-actions button{border:1px solid #d6dbe2;background:#fff;color:#303641;border-radius:9px;padding:7px 11px;font:inherit;font-size:12px;font-weight:800;cursor:pointer}.module-picker-actions button:hover{border-color:#111;color:#111;box-shadow:0 4px 12px rgba(0,0,0,.07)}.module-category{display:grid;gap:10px}.module-category+.module-category{padding-top:15px;border-top:1px solid #dfe3e8}.module-category-head{display:flex;align-items:center;gap:10px}.module-category-head>span{display:grid;place-items:center;width:30px;height:30px;border-radius:8px;background:#111;color:#fff;font-size:11px;font-weight:900}.module-category-head>div{display:grid;gap:2px}.module-category-head strong{font-size:13px;letter-spacing:.02em}.module-category-head small{font-size:11px;color:#737b87}.module-picker .permission-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;padding:0}.module-picker .module-option{position:relative;display:grid;grid-template-columns:30px minmax(0,1fr);align-items:center;gap:10px;min-height:84px;margin:0;padding:12px;border:1px solid #dfe4ea;border-radius:12px;background:#fff;cursor:pointer;transition:border-color .16s,box-shadow .16s,transform .16s}.module-picker .module-option:hover{border-color:#8e97a4;box-shadow:0 7px 18px rgba(17,24,39,.08);transform:translateY(-1px)}.module-picker .module-option:has(input:checked){border-color:#111;background:linear-gradient(145deg,#fff,#f2f4f6);box-shadow:inset 0 0 0 1px #111}.module-picker .module-option input{position:absolute;opacity:0;pointer-events:none}.module-option-mark{display:grid;place-items:center;width:28px;height:28px;border:1px solid #cfd5dc;border-radius:8px;background:#f7f8fa;color:transparent;font-size:15px;font-weight:900}.module-option:has(input:checked) .module-option-mark{border-color:#111;background:#111;color:#fff}.module-option>span:last-child{display:grid;align-content:center;gap:4px;min-width:0}.module-option strong{font-size:12px;line-height:1.25;color:#20242b}.module-option small{display:block!important;margin:0!important;font-size:10.5px;line-height:1.3;color:#737b87}.module-picker .module-count{background:#111;padding:6px 10px}.module-picker summary:focus-visible,.module-option:focus-within{outline:3px solid rgba(37,99,235,.25);outline-offset:2px}@media(max-width:650px){.module-picker .permission-grid{grid-template-columns:1fr}.module-picker-actions{justify-content:stretch}.module-picker-actions button{flex:1}.module-picker .module-option{min-height:76px}}
/* Selector amigable de destinatarios */
.notification-recipient-field{display:grid;gap:9px}.notification-field-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.notification-field-head>span{font-weight:800}.notification-field-head>strong{font-size:11px;color:#fff;background:#111;border-radius:999px;padding:5px 9px}.notification-search{position:relative}.notification-search svg{position:absolute;left:11px;top:50%;width:16px;transform:translateY(-50%);color:#707783}.notification-search input{width:100%;padding-left:36px!important}.notification-recipient-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;max-height:250px;padding:8px;overflow:auto;border:1px solid #dce1e7;border-radius:12px;background:#f5f7f9}.notification-recipient-option{position:relative;display:grid!important;grid-template-columns:26px minmax(0,1fr);align-items:center;gap:9px;min-height:62px;margin:0;padding:10px;border:1px solid #e0e4e9;border-radius:10px;background:#fff;cursor:pointer;transition:.16s}.notification-recipient-option:hover{border-color:#8d96a2;box-shadow:0 4px 12px rgba(0,0,0,.06)}.notification-recipient-option:has(input:checked){border-color:#111;box-shadow:inset 0 0 0 1px #111}.notification-recipient-option input{position:absolute;opacity:0}.recipient-check{display:grid;place-items:center;width:25px;height:25px;border:1px solid #cbd1d8;border-radius:7px;color:transparent;background:#f7f8fa;font-weight:900}.notification-recipient-option:has(input:checked) .recipient-check{background:#111;border-color:#111;color:#fff}.notification-recipient-option>span:last-child{display:grid;gap:3px;min-width:0}.notification-recipient-option strong{font-size:11px;text-transform:uppercase;letter-spacing:.04em}.notification-recipient-option small{margin:0!important;font-size:11px;white-space:normal;overflow-wrap:anywhere}.notification-recipient-option[hidden]{display:none!important}@media(max-width:650px){.notification-recipient-list{grid-template-columns:1fr;max-height:320px}}
/* Solicitud visual: brillo de acciones, accesos de cuenta e identidad de sesión */
.sidebar-account-actions{display:flex;align-items:center;gap:8px;margin:8px 12px 0;padding-top:10px;border-top:1px solid rgba(255,255,255,.16)}
.sidebar-account-btn{display:grid;place-items:center;width:38px;height:38px;padding:0;border:1px solid rgba(255,255,255,.2);border-radius:10px;background:rgba(255,255,255,.08);color:#fff;cursor:pointer}
.sidebar-account-btn svg{width:18px;height:18px}
.sidebar-account-btn--logout{border-color:rgba(239,68,68,.52);background:rgba(185,28,28,.18);color:#ff5b5b}
.sidebar-account-btn--logout:hover,.sidebar-account-btn--logout:focus-visible{background:rgba(220,38,38,.28);color:#ff7373}
.sidebar.collapsed .sidebar-account-actions{justify-content:center;margin-inline:0}
.session-user-card{display:grid;grid-template-columns:38px minmax(0,1fr) 7px;gap:9px;align-items:center;min-width:238px;max-width:310px;padding:8px 10px;border:1px solid #dce5ec;border-radius:13px;background:linear-gradient(135deg,#fff,#f5f8fb);box-shadow:0 8px 22px rgba(22,50,59,.08)}
.session-user-avatar{display:grid;width:38px;height:38px;place-items:center;border-radius:10px;background:linear-gradient(145deg,var(--brand-blue),var(--brand-blue-dark));color:#fff;box-shadow:0 6px 15px rgba(51,78,139,.22)}
.session-user-avatar svg{width:18px;height:18px}.session-user-copy{display:grid;min-width:0;gap:2px}.session-user-copy strong,.session-user-copy small,.session-user-copy em{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.session-user-copy strong{color:var(--ink);font-size:12px}.session-user-copy small{color:var(--brand-blue-dark);font-size:9px;font-weight:850;letter-spacing:.035em;text-transform:uppercase}.session-user-copy em{color:#71808d;font-size:9px;font-style:normal}.session-user-status{width:7px;height:7px;border-radius:50%;background:#22c55e;box-shadow:0 0 0 3px rgba(34,197,94,.12),0 0 9px rgba(34,197,94,.62)}
.dashboard-light-action{position:relative;isolation:isolate;overflow:hidden}
.dashboard-light-action>*{position:relative;z-index:1}
.dashboard-light-action::after{content:"";display:block;position:absolute;z-index:0;pointer-events:none;top:-45%;bottom:-45%;left:-58%;width:34%;opacity:0;transform:skewX(-18deg);background:linear-gradient(90deg,transparent,color-mix(in srgb,currentColor 10%,transparent),rgba(255,255,255,.78),color-mix(in srgb,currentColor 12%,transparent),transparent);filter:blur(.8px)}
.dashboard-light-action:not(:disabled):hover::after{animation:autocentro-button-horizontal-light .82s ease-out both}
@keyframes autocentro-button-horizontal-light{0%{left:-58%;opacity:0}18%{opacity:.92}78%{opacity:.92}100%{left:124%;opacity:0}}
.sidebar .nav-item.dashboard-light-action.active::after{animation:autocentro-active-menu-light 3.2s ease-in-out infinite}
@keyframes autocentro-active-menu-light{0%,14%{left:-58%;opacity:0}24%{opacity:.82}58%{left:124%;opacity:.82}68%,100%{left:124%;opacity:0}}
@media(max-width:680px){.session-user-card{display:none}}
@media(prefers-reduced-motion:reduce){.dashboard-light-action:not(:disabled):hover::after,.sidebar .nav-item.dashboard-light-action.active::after{animation:none}.sidebar .nav-item.dashboard-light-action.active::after{left:34%;opacity:.2}}

/* Configurador guiado de notificaciones */
.exchange-report-layout{display:grid;gap:22px}.exchange-report-card{overflow:hidden;border:1px solid #d8e3ef;border-radius:16px;background:#fff;box-shadow:0 12px 28px rgba(15,45,80,.08)}.exchange-report-card>header{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:14px;padding:18px 20px;background:linear-gradient(135deg,#f8fbff,#edf5fd);border-bottom:1px solid #dce6f0}.exchange-report-card>header>div{display:grid;gap:4px}.exchange-report-card h4{margin:0;color:#173f70;font-size:17px;line-height:1.2}.exchange-report-card header p{margin:0;color:#667085;font-size:11px;line-height:1.45}.exchange-section-capsule{display:inline-flex;align-items:center;justify-content:center;min-height:29px;padding:0 11px;border-radius:999px;background:linear-gradient(135deg,#173f70,#2873d1);color:#fff;font-size:9px;font-weight:900;letter-spacing:.09em}.exchange-count{padding:7px 10px;border:1px solid #bdd5ed;border-radius:999px;background:#fff;color:#175a9f;font-size:10px;white-space:nowrap}.exchange-report-card .report-table-wrap{margin:0;border:0;border-radius:0}.exchange-report-card .report-table th{background:linear-gradient(135deg,#173f70,#2873d1)}.exchange-report-card .report-table td{line-height:1.45}.exchange-rules-block{width:100%;max-width:none}.exchange-rules-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:14px;padding:18px 20px}.exchange-rule-item{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0;border:1px solid #dce6f0;border-radius:12px;background:#f8fbff;overflow:hidden}.exchange-rule-field{display:grid;align-content:center;gap:5px;min-height:72px;padding:12px 14px;border-right:1px solid #e1e9f2}.exchange-rule-field:last-child{border-right:0}.exchange-rule-field span{color:#667085;font-size:9px;font-weight:800;letter-spacing:.07em;text-transform:uppercase}.exchange-rule-field strong{color:#173f70;font-size:13px;line-height:1.3;overflow-wrap:anywhere}.exchange-rules-block .report-table{width:100%;min-width:0;table-layout:fixed}.exchange-rules-block .report-table th:nth-child(1),.exchange-rules-block .report-table td:nth-child(1){width:28%}.exchange-rules-block .report-table th:nth-child(2),.exchange-rules-block .report-table td:nth-child(2){width:52%}.exchange-rules-block .report-table th:nth-child(3),.exchange-rules-block .report-table td:nth-child(3){width:20%}.exchange-rules-block .report-table th:nth-child(3),.exchange-rules-block .report-table td:nth-child(3){text-align:right}.exchange-data-grid-wrap{width:100%;overflow-x:auto;overscroll-behavior-inline:contain}.exchange-data-grid{background:#fff}.exchange-grid-row{display:grid;align-items:stretch}.exchange-grid-head{position:sticky;top:0;z-index:1;background:linear-gradient(135deg,#173f70,#2873d1);color:#fff}.exchange-grid-rows .exchange-grid-row:nth-child(even){background:#f8fbff}.exchange-grid-rows .exchange-grid-row:hover{background:#edf5fd}.exchange-grid-cell{box-sizing:border-box;min-width:0;padding:12px 10px;border-right:1px solid #e2e8f0;border-bottom:1px solid #e7edf4;font-size:11px;line-height:1.4;overflow-wrap:anywhere;word-break:normal}.exchange-grid-cell:last-child{border-right:0}.exchange-grid-head .exchange-grid-cell{display:flex;align-items:center;min-height:44px;border-color:rgba(255,255,255,.18);font-size:10px;font-weight:800;letter-spacing:.035em;text-transform:uppercase}.exchange-grid-body .exchange-grid-cell{display:flex;align-items:flex-start;min-height:46px;color:#344054}@media(max-width:760px){.exchange-report-card>header{grid-template-columns:1fr;align-items:start;padding:16px}.exchange-section-capsule{justify-self:start}.exchange-count{justify-self:start}.exchange-report-layout{gap:16px}}
.sidebar-credit .sidebar-credit-logo{display:flex;align-items:center;justify-content:center;width:100%;height:44px;padding:5px;border-radius:10px;background:#fff;overflow:hidden}.sidebar-credit .sidebar-credit-logo img{display:block;width:auto;height:48px;max-width:100%;object-fit:contain}.sidebar.collapsed .sidebar-credit .sidebar-credit-logo{width:38px;height:38px;padding:3px;border-radius:9px}.sidebar.collapsed .sidebar-credit .sidebar-credit-logo img{height:40px}.sidebar.collapsed .sidebar-credit strong{display:none!important}
.sidebar-credit{flex:0 0 auto;display:grid;gap:3px;margin:12px 14px 14px;padding:13px 12px 0;border-top:1px solid rgba(255,255,255,.14);text-align:center;color:rgba(255,255,255,.52)}.sidebar-credit span{font-size:8px;letter-spacing:.12em;text-transform:uppercase}.sidebar-credit strong{color:rgba(255,255,255,.88);font-size:10px;font-weight:900;letter-spacing:.13em}.sidebar.collapsed .sidebar-credit{display:grid;width:42px;margin:10px auto 13px;padding:10px 0 0}.sidebar.collapsed .sidebar-credit span{display:none}.sidebar.collapsed .sidebar-credit strong{font-size:0}.sidebar.collapsed .sidebar-credit strong:after{content:"PL";font-size:9px;letter-spacing:.08em}@media(max-width:760px){.sidebar-credit{margin-bottom:18px}}
.audit-toolbar #refreshAudit{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;min-width:118px;height:40px;padding:0 15px!important;border:1px solid #2873d1!important;border-radius:10px!important;background:#edf5ff!important;color:#175a9f!important;font-weight:900!important;box-shadow:0 5px 14px rgba(40,115,209,.12)!important;cursor:pointer}.audit-toolbar #refreshAudit svg{width:16px!important;height:16px!important}.audit-toolbar #refreshAudit:hover{background:#2873d1!important;color:#fff!important;transform:translateY(-1px);box-shadow:0 8px 18px rgba(40,115,209,.24)!important}.audit-toolbar #refreshAudit:focus-visible{outline:3px solid rgba(40,115,209,.22);outline-offset:2px}.audit-toolbar #refreshAudit:active{transform:translateY(0)}
.audit-panel{grid-column:1/-1!important;padding:0!important;overflow:hidden!important}.audit-disclosure>summary{list-style:none;display:grid;grid-template-columns:42px minmax(0,1fr) auto;align-items:center;gap:14px;padding:18px 20px;cursor:pointer;background:linear-gradient(135deg,#f8fbff,#eef5fc)}.audit-disclosure>summary::-webkit-details-marker{display:none}.audit-disclosure-icon{display:grid;place-items:center;width:42px;height:42px;border-radius:12px;background:#173f70;color:#fff}.audit-disclosure-icon svg{width:20px}.audit-disclosure>summary>span:nth-child(2){display:grid;gap:4px}.audit-disclosure>summary strong{font-size:15px;color:#172033}.audit-disclosure>summary small{color:#667085;font-size:11px}.audit-disclosure-action{display:flex;align-items:center;gap:9px;color:#2873d1}.audit-disclosure-action em{font-size:11px;font-style:normal;font-weight:900}.audit-disclosure-action svg{width:18px;transition:transform .2s}.audit-disclosure[open] .audit-disclosure-action svg{transform:rotate(180deg)}.audit-disclosure[open] .audit-disclosure-action em{font-size:0}.audit-disclosure[open] .audit-disclosure-action em:after{content:"Ocultar";font-size:11px}.audit-disclosure-body{padding:18px 20px 22px;border-top:1px solid #dce5ee;background:#fff}.audit-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px}.audit-toolbar p{margin:0;color:#667085;font-size:12px}.audit-toolbar button{display:inline-flex;align-items:center;gap:7px}.audit-toolbar button svg{width:15px}.audit-list{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px!important;margin:0!important;max-height:430px;overflow:auto;padding:2px}.audit-list .audit-event{min-height:88px;margin:0!important;padding:15px 16px!important;border:1px solid #dce5ee!important;border-radius:12px!important;background:#f8fafc!important;box-shadow:none!important}.audit-list .audit-event>div{display:grid;gap:6px}.audit-list .list-title{color:#173f70;font-size:12px;font-weight:900}.audit-list .list-subtitle{line-height:1.35}.audit-list>p{grid-column:1/-1;margin:0;padding:16px;border-radius:10px;background:#f8fafc;color:#667085}@media(max-width:760px){.audit-disclosure>summary{grid-template-columns:38px 1fr;padding:16px}.audit-disclosure-action{grid-column:2}.audit-disclosure-body{padding:16px}.audit-list{grid-template-columns:1fr}.audit-toolbar{align-items:flex-start;flex-direction:column}.audit-toolbar button{width:100%;justify-content:center}}
.settings-grid>[data-user-admin-panel] .user-admin-toolbar{margin-top:24px!important;padding:20px!important;border:1px solid #dce5ee!important;border-radius:15px!important;background:#f7faff!important;box-shadow:0 8px 20px rgba(15,35,65,.05)!important;gap:32px!important}.settings-grid>[data-user-admin-panel] .user-filter-group{gap:22px!important}.settings-grid>[data-user-admin-panel] .user-admin-toolbar label{gap:10px!important}.settings-grid>[data-user-admin-panel] .user-admin-toolbar label>span{display:block;line-height:1.2}.settings-grid>[data-user-admin-panel] .user-admin-toolbar input,.settings-grid>[data-user-admin-panel] .user-admin-toolbar select{margin:0!important}.settings-grid>[data-user-admin-panel] .user-create-action{padding:0!important;margin:0!important}.settings-grid>[data-user-admin-panel] .user-admin-summary{margin:22px 0 26px!important;gap:16px!important}.settings-grid>[data-user-admin-panel] .user-admin-summary article{min-height:84px!important;padding:18px 20px!important;align-content:center!important;gap:8px!important}.settings-grid>[data-user-admin-panel] .user-admin-summary strong{font-size:26px!important}.settings-grid>[data-user-admin-panel] .user-admin-summary span{line-height:1.25!important}@media(max-width:820px){.settings-grid>[data-user-admin-panel] .user-admin-toolbar{padding:18px!important;gap:18px!important}.settings-grid>[data-user-admin-panel] .user-create-action{padding-top:18px!important}.settings-grid>[data-user-admin-panel] .user-admin-summary{gap:12px!important}}@media(max-width:560px){.settings-grid>[data-user-admin-panel] .user-admin-toolbar{padding:15px!important}.settings-grid>[data-user-admin-panel] .user-filter-group{gap:16px!important}.settings-grid>[data-user-admin-panel] .user-admin-summary{grid-template-columns:1fr!important}.settings-grid>[data-user-admin-panel] .user-admin-summary article{min-height:70px!important}}
.user-admin-toolbar{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;align-items:end!important;gap:28px!important}.user-admin-toolbar .user-filter-group{display:grid;grid-template-columns:minmax(240px,1fr) minmax(150px,190px);align-items:end;gap:14px;min-width:0}.user-admin-toolbar .user-create-action{display:block!important;align-self:end!important;min-height:0!important;margin:0!important;padding:0!important;border:0!important}.user-admin-toolbar .user-create-action #openUserCreate{margin:0!important;white-space:nowrap}.user-admin-toolbar .user-create-action #openUserCreate:before{display:none!important}@media(max-width:820px){.user-admin-toolbar{grid-template-columns:1fr!important;gap:16px!important}.user-admin-toolbar .user-filter-group{grid-template-columns:minmax(0,1fr) minmax(140px,.45fr)}.user-admin-toolbar .user-create-action{padding-top:14px!important;border-top:1px solid #dce4ed!important}.user-admin-toolbar .user-create-action #openUserCreate{width:auto!important}}@media(max-width:560px){.user-admin-toolbar .user-filter-group{grid-template-columns:1fr}.user-admin-toolbar .user-create-action #openUserCreate{width:100%!important}}
.user-admin-toolbar .user-create-action{align-self:end;display:flex;align-items:center;min-height:43px;margin-left:10px;padding-left:28px;border-left:1px solid #cbd8e5}.user-admin-toolbar .user-create-action #openUserCreate{margin:0!important}.user-admin-toolbar .user-create-action #openUserCreate:before{display:none!important}@media(max-width:760px){.user-admin-toolbar .user-create-action{margin:10px 0 0;padding:12px 0 0;border-left:0;border-top:1px solid #dce4ed}.user-admin-toolbar .user-create-action #openUserCreate{width:100%}}
.user-admin-toolbar #openUserCreate{position:relative;margin-left:28px!important}.user-admin-toolbar #openUserCreate:before{content:"";position:absolute;left:-15px;top:5px;bottom:5px;width:1px;background:#d5dee8}.user-admin-toolbar{column-gap:18px!important}@media(max-width:760px){.user-admin-toolbar #openUserCreate{margin-left:0!important;margin-top:10px}.user-admin-toolbar #openUserCreate:before{display:none}}
.user-admin-toolbar #openUserCreate{margin-left:12px}.user-admin-toolbar{column-gap:14px!important}@media(max-width:760px){.user-admin-toolbar #openUserCreate{margin-left:0;margin-top:4px}}
.user-actions{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:9px!important;flex-wrap:wrap}.user-actions .user-icon-action{display:grid!important;place-items:center!important;width:40px!important;min-width:40px!important;height:40px!important;min-height:40px!important;padding:0!important;border-radius:11px!important}.user-actions .user-icon-action svg{width:16px!important;height:16px!important;margin:0!important}.user-admin-toolbar #openUserCreate{display:inline-flex;align-items:center;justify-content:center;gap:8px;height:43px;padding:0 16px;border:1px solid #2873d1!important;border-radius:11px!important;background:linear-gradient(135deg,#173f70,#2873d1)!important;color:#fff!important;font-weight:900!important;box-shadow:0 7px 16px rgba(40,115,209,.2)!important}.user-admin-toolbar #openUserCreate:hover{transform:translateY(-1px);box-shadow:0 10px 22px rgba(40,115,209,.28)!important}.user-admin-toolbar #openUserCreate:focus-visible{outline:3px solid rgba(40,115,209,.24);outline-offset:2px}
.user-admin-toolbar label{display:grid;gap:6px;color:#334155;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.07em}.user-admin-toolbar input,.user-admin-toolbar select{width:100%;height:43px;border:1px solid #cbd8e5;border-radius:11px;background:#f8fbff;color:#172033;padding:0 13px;font:inherit;font-size:12px;box-shadow:inset 0 1px 2px rgba(15,23,42,.04);outline:none}.user-admin-toolbar input:focus,.user-admin-toolbar select:focus{border-color:#2873d1;box-shadow:0 0 0 3px rgba(40,115,209,.14)}.user-actions [data-edit-user],.user-actions [data-toggle-active]{min-height:38px;border:1px solid #bfd0e2!important;border-radius:10px!important;background:#f5f9fd!important;color:#173f70!important;font-weight:900!important}.user-actions [data-edit-user]:hover{border-color:#2873d1!important;background:#eaf3ff!important;color:#165ca9!important}.user-actions [data-toggle-active]{border-color:#f2c7a5!important;background:#fff7ed!important;color:#9a4b0b!important}.user-actions [data-toggle-active]:hover{border-color:#e69754!important;background:#ffedd5!important}.user-actions [data-toggle-active] svg,.user-actions [data-edit-user] svg{width:15px}.notification-enable-btn{display:inline-flex;align-items:center;gap:8px;min-height:42px;padding:0 16px;border:1px solid #efb2b2;border-radius:11px;background:#fff5f5;color:#a51d1d;font:inherit;font-size:12px;font-weight:900;cursor:pointer}.notification-enable-btn:hover{background:#fee2e2}.notification-enable-btn.active{border-color:#efb2b2;background:#b42318;color:#fff}.notification-enable-btn:disabled{opacity:.55;cursor:wait}
.notification-schedule-card{display:grid;grid-template-columns:38px minmax(0,1fr) auto;align-items:center;gap:13px;padding:16px;border:1px solid #bdd6f1;border-radius:14px;background:linear-gradient(135deg,#edf6ff,#fbfdff);color:#173f70}.notification-schedule-card svg{width:25px}.notification-schedule-card>div{display:grid;gap:3px}.notification-schedule-card span{color:#60758d;font-size:11px}.notification-schedule-card em{padding:6px 9px;border-radius:999px;background:#fee2e2;color:#991b1b;font-size:10px;font-style:normal;font-weight:900}.notification-distribution{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.notification-distribution article{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px;border:1px solid #dce4ed;border-radius:10px;background:#fff}.notification-distribution article>span{display:grid;min-width:0;gap:2px}.notification-distribution small{overflow-wrap:anywhere;color:#667085}.notification-distribution em{white-space:nowrap;color:#2873d1;font-size:9px;font-style:normal;font-weight:900}.notification-actions{display:flex;flex-wrap:wrap;gap:10px}.settings-credit{display:flex!important;align-items:center;justify-content:center;gap:10px;min-height:64px;margin-top:22px;padding:12px;border-top:1px solid #dce3ea;color:#6b7280}.settings-credit img{display:block!important;width:120px!important;height:34px!important;object-fit:contain}.user-admin-summary{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:10px!important}.user-admin-summary article{display:grid!important;gap:4px!important;padding:13px!important;border:1px solid #dce3ea!important;border-radius:12px!important;background:#f8fafc!important}.user-admin-summary strong{font-size:22px!important;line-height:1!important}.user-admin-summary span{font-size:10px!important;text-transform:uppercase!important;letter-spacing:.07em!important;color:#6b7280!important}.settings-nav button{border:1px solid #d8e0e8!important;border-radius:11px!important;background:#fff!important;color:#334155!important;box-shadow:0 5px 14px rgba(15,23,42,.06)!important}.settings-nav button.active{border-color:#2873d1!important;background:linear-gradient(135deg,#173f70,#2873d1)!important;color:#fff!important}@media(max-width:700px){.notification-schedule-card{grid-template-columns:34px 1fr}.notification-schedule-card em{grid-column:1/-1}.notification-distribution{grid-template-columns:1fr}}
.notification-panel .form-grid{grid-template-columns:1fr!important}.notification-step{display:grid;grid-template-columns:38px minmax(0,1fr);gap:13px;padding:16px;border:1px solid #dfe4ea;border-radius:14px;background:#f8fafb}.notification-step-number{display:grid;place-items:center;width:34px;height:34px;border-radius:10px;background:#111;color:#fff;font-size:13px;font-weight:900}.notification-step-content{display:grid;gap:10px;min-width:0}.notification-step-content>p{margin:0;color:#66707d;font-size:12px;line-height:1.5}.recipient-add-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px}.recipient-add-row select{width:100%}.selected-recipient-chips{display:flex;flex-wrap:wrap;gap:8px;min-height:42px;padding:9px;border:1px dashed #cbd2da;border-radius:10px;background:#fff}.empty-selection{align-self:center;color:#858d98;font-size:12px}.selected-recipient-chip{display:flex;align-items:center;gap:10px;max-width:100%;padding:7px 8px 7px 10px;border:1px solid #d7dce2;border-radius:10px;background:#f5f7f9}.selected-recipient-chip>span{display:grid;gap:1px;min-width:0}.selected-recipient-chip small{margin:0!important;font-size:9px;text-transform:uppercase;letter-spacing:.08em}.selected-recipient-chip strong{font-size:11px;overflow-wrap:anywhere}.selected-recipient-chip button{display:grid;place-items:center;width:23px;height:23px;border:0;border-radius:7px;background:#e1e5e9;color:#333;font-size:17px;cursor:pointer}.selected-recipient-chip button:hover{background:#111;color:#fff}.notification-all-toggle,.notification-type-grid label{display:grid!important;grid-template-columns:20px minmax(0,1fr);align-items:start;gap:9px;margin:0;padding:11px;border:1px solid #dfe4e9;border-radius:10px;background:#fff;cursor:pointer}.notification-all-toggle{border-color:#111!important;background:#f3f4f5!important}.notification-all-toggle input,.notification-type-grid input{margin-top:2px;accent-color:#111}.notification-all-toggle span,.notification-type-grid label span{display:grid;gap:3px}.notification-all-toggle strong,.notification-type-grid strong{font-size:12px}.notification-type-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.notification-type-grid label.disabled{opacity:.46;cursor:not-allowed}.notification-type-grid small{margin:0!important}.notification-panel .primary-btn{grid-column:auto!important;justify-self:start}@media(max-width:650px){.notification-step{grid-template-columns:1fr}.notification-step-number{width:30px;height:30px}.recipient-add-row{grid-template-columns:1fr}.notification-type-grid{grid-template-columns:1fr}}


.dashboard-dialog{width:min(520px,calc(100% - 2rem));max-width:none;border:0;padding:0;border-radius:20px;background:transparent;box-shadow:0 30px 90px rgba(8,20,40,.36)}.dashboard-dialog::backdrop{background:rgba(9,20,38,.68);backdrop-filter:blur(5px)}.dashboard-dialog-card{overflow:hidden;border:1px solid rgba(40,115,209,.22);border-radius:20px;background:#fff;color:#172033}.dashboard-dialog-card>header{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:.85rem;padding:1.15rem 1.25rem;background:linear-gradient(135deg,#0d1728,#213b60);color:#fff}.dashboard-dialog-card>header .eyebrow{margin:0 0 .2rem;color:#8ec5ff;font-size:.65rem;font-weight:900;letter-spacing:.13em}.dashboard-dialog-card h3{margin:0;font-size:1.2rem}.dashboard-dialog-icon{display:grid;place-items:center;width:42px;height:42px;border:1px solid rgba(255,255,255,.24);border-radius:12px;background:rgba(40,115,209,.28)}.dashboard-dialog-icon svg{width:20px}.dashboard-dialog-close{display:grid;place-items:center;width:36px;height:36px;border:0;border-radius:10px;background:rgba(255,255,255,.1);color:#fff}.dashboard-dialog-message{margin:0;padding:1.25rem 1.25rem .65rem;color:#475569;font-size:.92rem;line-height:1.55;white-space:pre-line}.dashboard-dialog-field{display:grid;gap:.4rem;padding:.35rem 1.25rem .75rem;color:#475569;font-size:.72rem;font-weight:900}.dashboard-dialog-field input{width:100%;border:1px solid #cbd5e1;border-radius:10px;background:#f8fafc;padding:.75rem;color:#172033;font:inherit;font-size:.9rem}.dashboard-dialog-field input:focus{outline:3px solid rgba(40,115,209,.16);border-color:#2873d1}.dashboard-dialog-card>footer{display:flex;justify-content:flex-end;gap:.6rem;padding:1rem 1.25rem 1.2rem}.dashboard-dialog-card>footer button{border:0;border-radius:10px;padding:.7rem 1rem;font-weight:900}.dashboard-dialog-cancel{background:#e8eef5;color:#334155}.dashboard-dialog-confirm{background:#2873d1;color:#fff}.dashboard-dialog-confirm.danger{background:#b91c1c}.dashboard-dialog button{cursor:pointer}.dashboard-dialog button:hover{filter:brightness(.94)}@media(max-width:600px){.dashboard-dialog{width:calc(100% - 1rem)}.dashboard-dialog-card>header{padding:1rem}.dashboard-dialog-message,.dashboard-dialog-field{padding-left:1rem;padding-right:1rem}.dashboard-dialog-card>footer{padding:1rem;flex-direction:column-reverse}.dashboard-dialog-card>footer button{width:100%}}
.login-screen{padding:48px 7vw!important;background:linear-gradient(90deg,rgba(10,13,18,.84) 0%,rgba(10,13,18,.58) 48%,rgba(10,13,18,.22) 100%),url("https://spdfc.s3.us-west-2.amazonaws.com/distribuidores/Auto_Centro_de_Celaya/img/fachada.webp") center/cover!important}
.access-card{width:min(1060px,100%);min-height:560px;display:grid;grid-template-columns:minmax(0,1fr) 420px;overflow:visible}.access-brand{display:flex;flex-direction:column;justify-content:center;padding:40px 70px;color:#fff}.access-brand img{width:250px;margin:0 0 34px;align-self:flex-start;filter:brightness(0) invert(1)!important}.access-brand>span{color:#fff;font-size:12px;font-weight:800;letter-spacing:.16em;text-transform:uppercase;opacity:.78}.access-brand h1{margin:18px 0 14px;color:#fff;font-size:clamp(38px,4vw,48px);line-height:1.04}.access-brand h1 em{color:#e24b52;font-style:normal}.access-brand p{margin:0;color:#e5e7eb}
.access-form-wrap{display:flex;flex-direction:column;justify-content:center;padding:48px 42px;border-radius:18px;background:#fff;color:#111;box-shadow:0 24px 70px rgba(0,0,0,.35)}.access-form-wrap h2{margin:8px 0 28px;color:#111;font-size:28px}.access-form-wrap .login-form{padding:0;border:0;background:transparent}.access-form-wrap .login-form label>span:first-child{color:#303641}.access-form-wrap .login-form input{height:46px;background:#fff;color:#111;border-color:#aeb7c3}.access-form-wrap .primary-btn{width:100%;height:46px;margin-top:10px}.password-field{position:relative;display:block}.password-field input{padding-right:48px}.password-toggle{position:absolute;top:50%;right:7px;display:grid;width:34px;height:34px;padding:0;place-items:center;transform:translateY(-50%);border:0;border-radius:8px;background:transparent;color:#52606f;cursor:pointer}.password-toggle svg{width:18px;height:18px}.access-form-wrap .login-credit{display:flex;align-items:center;justify-content:center;gap:9px;margin-top:34px;color:#707784}.access-form-wrap .login-credit img{width:112px;max-height:52px;object-fit:contain}
@media(max-width:760px){.login-screen{align-items:flex-start;padding:20px!important;overflow-y:auto}.access-card{min-height:0;display:block}.access-brand{display:block;padding:18px 12px 28px;text-align:center}.access-brand img{width:180px;margin:0 auto 22px}.access-brand h1{font-size:34px}.access-form-wrap{padding:30px 24px}}
.advisor-alert-control{display:grid;gap:14px;margin-top:18px;padding:16px;border:1px solid #d8e2ed;border-radius:15px;background:linear-gradient(135deg,#f8fbff,#f2f6fa)}.advisor-alert-control.active{border-color:#8ac7a9;background:linear-gradient(135deg,#f1fbf6,#f8fffb)}.advisor-alert-control-head{display:grid;grid-template-columns:40px minmax(0,1fr) auto;align-items:center;gap:13px}.advisor-alert-icon{display:grid;width:40px;height:40px;place-items:center;border-radius:11px;background:linear-gradient(135deg,#173f70,#2873d1);color:#fff}.advisor-alert-icon svg{width:20px}.advisor-alert-control h4{margin:3px 0;color:#173f70;font-size:16px}.advisor-alert-control-head p,.advisor-alert-footer p{margin:0;color:#667085;font-size:11px;line-height:1.45}.advisor-alert-schedules{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.advisor-alert-schedules article{display:grid;gap:4px;padding:13px;border:1px solid #dce5ef;border-radius:11px;background:#fff}.advisor-alert-schedules strong{font-size:12px;color:#172033}.advisor-alert-schedules span{font-size:11px;font-weight:800;color:#2873d1}.advisor-alert-schedules small{color:#687386;line-height:1.4}.advisor-alert-footer{display:flex;align-items:center;justify-content:space-between;gap:16px;padding-top:13px;border-top:1px solid #dce5ef}.status-pill.green{background:#dcfce7!important;color:#166534!important}@media(max-width:650px){.advisor-alert-control-head{grid-template-columns:40px 1fr}.advisor-alert-control-head>.status-pill{grid-column:1/-1;justify-self:start}.advisor-alert-schedules{grid-template-columns:1fr}.advisor-alert-footer{align-items:stretch;flex-direction:column}.advisor-alert-footer button{justify-content:center}}
