:root {
  --bg: #f4f6f8;
  --surface: #ffffff;
  --text: #1d2733;
  --muted: #64707d;
  --line: #dde2e8;
  --brand: var(--brand-primary, #123D66); /* color principal de la agencia (Configuraciones > Imagen) */
  --brand-ink: #ffffff;
  --ok-bg: #e4f4ea; --ok: #1f6b3a;
  --warn-bg: #fff3dc; --warn: #8a5a00;
  --err-bg: #fde8e8; --err: #a32222;
  --info-bg: #e6f0f8; --info: #0f5c8c;
  --radius: 8px;
  --sidebar: 220px;
  color-scheme: light;
}
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--text); background: var(--bg); }
a { color: var(--brand); }
h1 { font-size: 1.45rem; margin: 0 0 1rem; }
h2 { font-size: 1.1rem; margin: 0 0 .75rem; }
.muted { color: var(--muted); font-weight: normal; }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Barra superior y menu ---------- */
.topbar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; display: flex; align-items: center; gap: .75rem;
  height: 52px; padding: 0 1rem; background: var(--brand); color: var(--brand-ink); }
.topbar a { color: var(--brand-ink); text-decoration: none; }
.brand { font-weight: 700; font-size: 1.05rem; }
.who { margin-left: auto; display: flex; align-items: center; gap: .6rem; font-size: .9rem; }
.who .role { opacity: .8; }
.who .link { color: var(--brand-ink); text-decoration: underline; }
.nav-toggle { display: none; background: none; border: 0; color: inherit; font-size: 1.4rem; cursor: pointer; padding: .25rem; }
.shell { display: flex; min-height: calc(100vh - 52px); }
.sidebar { width: var(--sidebar); flex: none; background: var(--surface); border-right: 1px solid var(--line); padding: 1rem 0; }
.sidebar ul { list-style: none; margin: 0 0 .5rem; padding: 0; }
.sidebar a { display: block; padding: .5rem 1.25rem; color: var(--text); text-decoration: none; }
.sidebar a:hover { background: var(--bg); }
.sidebar a.active { background: var(--info-bg); color: var(--brand); font-weight: 600; box-shadow: inset 3px 0 0 var(--brand); }
/* Títulos de sección del menú (Operación, Reportes, Catálogos…): más grandes, en negritas y oscuros para distinguirlos
   de las opciones (usuario, 01/12/2026). */
.nav-head { margin: 1.25rem 1.25rem .35rem; padding-bottom: .25rem; font-size: .9rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .06em; color: var(--text, #1f2933); border-bottom: 1px solid var(--line); }
.sidebar .nav-head:first-child { margin-top: .75rem; }
.main { flex: 1; min-width: 0; padding: 1.5rem; max-width: 1200px; }
.lang-switch { margin: .5rem 0 0; }
.lang-btn { display: flex; align-items: center; gap: .55rem; width: 100%; padding: .5rem 1.25rem; background: none; border: 0;
  font: inherit; color: var(--text); text-align: left; cursor: pointer; }
.lang-btn:hover { background: var(--bg); }
.lang-btn img { width: 21px; height: 12px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,0,0,.18); flex: none; }
.bare .lang-switch { position: absolute; top: calc(env(safe-area-inset-top, 0px) + .75rem); right: 1rem; margin: 0; }
.bare .lang-btn { width: auto; padding: .4rem .7rem; border-radius: 6px; }

/* ---------- Tarjetas, avisos ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1.25rem; }
.card.narrow { max-width: 520px; }
.flash { padding: .7rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; }
.flash-ok { background: var(--ok-bg); color: var(--ok); }
.flash-error { background: var(--err-bg); color: var(--err); }
.flash-info { background: var(--info-bg); color: var(--info); }
.flash-warn { background: var(--warn-bg); color: var(--warn); }
.page-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: 1rem; }
.page-head h1 { margin: 0; }

/* ---------- Botones ---------- */
.btn { display: inline-block; padding: .5rem .95rem; border: 1px solid var(--line); border-radius: 6px; background: var(--surface);
  color: var(--text); font: inherit; text-decoration: none; cursor: pointer; }
.btn:hover { border-color: #b9c2cc; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.block { display: block; width: 100%; }
.btn.small { padding: .3rem .65rem; font-size: .85rem; }
form.driver-off { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; margin: 0; }
form.driver-off select, form.driver-off input { padding: .3rem .45rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; font-size: .85rem; background: #fff; }
form.driver-off input { width: 9rem; }
.link { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
form.inline { display: inline; margin: 0; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-top: 1.25rem; }

/* ---------- Formularios ---------- */
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem 1.25rem; }
.field { display: flex; flex-direction: column; gap: .3rem; }
.field.wide { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: .9rem; }
.field.check label { font-weight: normal; display: flex; align-items: center; gap: .5rem; padding-top: 1.6rem; }
.field input[type=text], .field input[type=email], .field input[type=tel], .field input[type=password], .field select, .field textarea,
.filters input, .filters select {
  width: 100%; padding: .5rem .6rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; background: #fff; color: inherit; }
.field textarea { resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, .filters input:focus { outline: 2px solid var(--brand); outline-offset: 0; border-color: var(--brand); }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.req { color: var(--err); }
.help { color: var(--muted); font-size: .82rem; }
.error { color: var(--err); font-size: .85rem; }
.has-error input, .has-error select, .has-error textarea { border-color: var(--err); }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.25rem 1.25rem; margin: 1.25rem 0 0; }
legend { font-weight: 600; padding: 0 .4rem; }
.rates-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: .75rem; }
.filters { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-bottom: 1rem; }
.filters input[type=search] { width: auto; flex: 1 1 220px; max-width: 360px; }
.filters select { width: auto; }
/* Todo el renglón de filtros a la misma altura y alineado (01/12/2026: la sucursal se veía "flotando" junto a Desde/Hasta) */
.filters label { display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap; margin: 0; }
.filters label input, .filters label select { width: auto; }
.filters input:not([type=checkbox]):not([type=radio]), .filters select, .filters .btn { box-sizing: border-box; height: 2.4rem; padding-top: 0; padding-bottom: 0; margin: 0; vertical-align: middle; }
.filters .btn { display: inline-flex; align-items: center; }
.filters .presets { align-self: center; }
.table td.span-pct { vertical-align: middle; font-weight: 700; border-left: 1px solid var(--line); }

/* ---------- Tablas ---------- */
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.card .table-wrap { border: 0; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th, .table td { padding: .55rem .75rem; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.table th { background: #f8fafb; font-weight: 600; white-space: nowrap; }
.table tbody tr:hover { background: #f8fafb; }
.table tr.inactive td { color: var(--muted); }
.badge { display: inline-block; padding: .1rem .5rem; border-radius: 99px; background: #eceff2; color: var(--muted); font-size: .8rem; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.pager { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .75rem 0; }

/* ---------- Directorio ---------- */
.filters .export { margin-left: auto; }
.clip { max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge.role-superusuario { background: #2d2a5e; color: #fff; }
.badge.role-webmaster { background: #111827; color: #fff; }
.badge.role-dueno { background: #7a4b00; color: #fff; }
.badge.role-gerente { background: var(--info-bg); color: var(--info); }
.badge.role-operador { background: var(--ok-bg); color: var(--ok); }
.badge.role-subgerente { background: #e3f1f4; color: #1d6170; }
.badge.role-administrador { background: #ece7f8; color: #3b2a85; }
.badge.role-consulta { background: var(--warn-bg); color: var(--warn); }
.badge.role-chofer { background: #efe6f7; color: #5b2f86; }
.role-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .75rem; }
.role-item { border: 1px solid var(--line); border-radius: 6px; padding: .65rem .8rem; display: flex; flex-direction: column; gap: .25rem; }
.role-item label { display: flex; align-items: center; gap: .5rem; cursor: pointer; }
.role-item.disabled { opacity: .6; }
.role-item.disabled label { cursor: default; }
.airports { display: flex; flex-direction: column; gap: .3rem; margin-top: .35rem; }
.airports select { width: 100%; padding: .3rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; background: #fff; }
.airports select:disabled { background: var(--bg); }
.airports.has-error select { border-color: var(--err); }
.warn-card { background: var(--warn-bg); border-color: #f0d9a8; }
.danger-card h2 { color: var(--err); }
.btn.danger { background: var(--err); border-color: var(--err); color: #fff; }
.side-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 0 1.25rem; }
.plain { list-style: none; margin: 0; padding: 0; }
.plain li { padding: .3rem 0; border-bottom: 1px solid var(--line); }
.login-links { text-align: center; margin: 1rem 0 0; font-size: .92rem; }
.register-link { border-top: 1px solid var(--line); padding-top: 1rem; color: var(--muted); }
.register-link .btn { margin-top: .5rem; }
.login form .field { margin-bottom: 1rem; }
.support-notice { margin-top: 1.25rem; padding: .9rem 1rem; border-radius: var(--radius); background: var(--info-bg); color: var(--text); font-size: .92rem; }
.support-notice p { margin: 0 0 .5rem; }
.support-notice p:last-child { margin-bottom: 0; }
.support-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin: .6rem 0; }
.btn.whatsapp { background: #1f8f4e; border-color: #1f8f4e; color: #fff; }
.temp-shown { border: 2px solid var(--brand); background: var(--info-bg); }
.temp-code { font: 700 2rem/1.2 ui-monospace, "Cascadia Mono", Consolas, monospace; letter-spacing: .15em; margin: .25rem 0 .75rem; color: var(--brand); }
.temp-steps { margin: 0 0 .5rem; padding-left: 1.25rem; }
.temp-steps li { margin-bottom: .2rem; }
.schedule-table { max-width: 560px; }
.schedule-table th[scope=row] { font-weight: 600; background: none; }
.schedule-table input[type=time] { padding: .35rem .5rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; }
.inline-check { display: inline-flex; align-items: center; gap: .35rem; cursor: pointer; }
fieldset.schedule.has-error { border-color: var(--err); }
.support-notice .badge { white-space: normal; margin-top: .35rem; }
.backups-table select, .backups-table input[type=text] { padding: .3rem .45rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; font-size: .88rem; background: #fff; }
.backups-table input[type=text] { width: 4.5rem; text-align: right; }
.badge.danger { background: var(--err-bg); color: var(--err); }
form.unblock { display: flex; gap: .35rem; align-items: center; margin: 0; }
form.unblock input { width: 9rem; padding: .35rem .5rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; font-size: .85rem; }
code { font-size: .85rem; word-break: break-all; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Inicio ---------- */
.day-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.25rem; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: .75rem; margin: 0; }
.stats div { background: var(--bg); border-radius: 6px; padding: .6rem .75rem; }
.stats div.warn { background: var(--warn-bg); color: var(--warn); }
.stats dt { font-size: .8rem; color: inherit; opacity: .85; }
.stats dd { margin: .1rem 0 0; font-size: 1.35rem; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ---------- Login / paginas sin menu ---------- */
/* Acceso: columna = cuadro centrado en la pantalla + pie de pagina a todo lo ancho, abajo */
body.bare { display: flex; flex-direction: column; align-items: center; min-height: 100vh; padding: 1rem 1rem 0; }
.bare-main { width: 100%; max-width: 380px; margin: auto 0; padding-top: 3rem; }
.bare-brand { text-align: center; font-size: 1.3rem; font-weight: 700; color: var(--brand); margin: 0 0 1rem; }
.login .field { margin-bottom: 1rem; }

/* ---------- Celular ---------- */
@media (max-width: 800px) {
  .nav-toggle { display: block; }
  .who .role, .who a { display: none; }
  .sidebar { position: fixed; top: 52px; bottom: 0; left: 0; z-index: 15; transform: translateX(-100%); transition: transform .2s; overflow-y: auto;
    box-shadow: 2px 0 12px rgba(0,0,0,.12); }
  body.nav-open .sidebar { transform: none; }
  .main { padding: 1rem; }
  .field.check label { padding-top: 0; }
}

/* ---------------- Pagina publica "En construccion" (raiz del dominio) ----------------
   Colores de marca (admin.bajiogoshuttle.com). Mas adelante salen de Configuraciones > Imagen. */
.home { --brand-primary: #123D66; --brand-accent: #DC5B0A; --brand-accent-soft: #FFBF6E;
        margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: #fff; color: var(--brand-primary); }
.home .lang-switch { position: absolute; top: 1rem; right: 1rem; }
.home-main { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
             text-align: center; padding: 2rem 1rem; }
.home-logo { width: min(340px, 80vw); height: auto; }
.home-title { margin: 1.5rem 0 .5rem; font-size: clamp(1.6rem, 4vw, 2.4rem); color: var(--brand-primary); }
.home-text { margin: 0 0 2rem; max-width: 32rem; font-size: 1.1rem; color: #33475b; }
.home-btn { display: inline-block; padding: .85rem 2.2rem; border-radius: 999px; background: var(--brand-primary);
            color: #fff; font-weight: 700; font-size: 1.05rem; text-decoration: none; border: 2px solid var(--brand-primary); }
.home-btn:hover, .home-btn:focus-visible { background: var(--brand-accent); border-color: var(--brand-accent); }
.home-foot { padding: 1rem; text-align: center; font-size: .85rem; color: #6b7c8c; border-top: 4px solid var(--brand-accent); }
/* ---------------- Reservaciones: lista ---------------- */
.tabs { display: flex; gap: .25rem; }
.tabs a { padding: .4rem .9rem; border: 1px solid var(--line); border-radius: 99px; text-decoration: none; color: var(--text); background: var(--surface); }
.tabs a.active { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.inline-field { display: inline-flex; align-items: center; gap: .35rem; white-space: nowrap; }
.res-filters input[type=date] { width: auto; }
.res-table td, .res-table th { padding: .45rem .6rem; }
.res-table a.folio { font-weight: 700; font-variant-numeric: tabular-nums; }
.res-table tr.res-cancelled td { color: #8a929b; background: #f3f4f6; }
.res-table tr.res-cancelled a { color: #6b7280; }
.tag-cxl { display: inline-block; margin-left: .35rem; padding: 0 .4rem; border-radius: 4px; background: #c62828; color: #fff;
  font-size: .7rem; font-weight: 700; letter-spacing: .03em; vertical-align: middle; }
.res-table td.owe { color: var(--brand-accent, #DC5B0A); font-weight: 700; }

/* ---------------- Reservaciones: detalle (mismo acomodo que el sistema obsoleto) ---------------- */
.resv { max-width: 660px; }
.resv-back { margin: 0 0 .5rem; }
.resv-head { text-align: right; font-size: 1.15rem; font-weight: 400; margin: 0 0 .5rem; }
.resv-head strong { font-size: 1.6rem; margin-left: .35rem; color: #000; }
.resv-cxl { color: #c62828; font-weight: 700; }
.resv-lock { display: flex; align-items: center; justify-content: flex-end; gap: .4rem; margin: 0 0 .5rem; font-size: .85rem; color: var(--muted); }
.resv-lock.practice { color: var(--brand-accent, #DC5B0A); font-weight: 700; }
.rb { padding: .45rem .6rem; border: 1px solid rgba(0,0,0,.08); }
.rb-client { background: var(--block-client, #E2FFE5); }
.rb-service { background: var(--block-service, #E1ECFF); }
.rb-round { background: var(--block-round, #EFE3FF); text-align: right; font-size: .9rem; padding: .35rem .6rem; }
.rb-card { background: var(--block-card, #C0C0C0); margin: .3rem -.6rem -.45rem; padding: .35rem .6rem; }
.rb-comments { border: 0; padding: .5rem 0 0; }
.rr { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: .3rem .75rem; padding: .18rem 0; }
.rr label, .rb-comments label { display: inline-flex; align-items: center; gap: .3rem; font-size: .85rem; white-space: nowrap; }
.rb-comments label.wide { display: flex; justify-content: flex-end; align-items: flex-start; margin-bottom: .35rem; }
.rb-comments textarea { width: 78%; font: inherit; font-size: .88rem; padding: .3rem .4rem; border: 1px solid #b9c2cc; border-radius: 3px; background: #fff; resize: vertical; }
.rb-comments .priv { color: #c62828; font-weight: 700; }
.rb-comments .priv textarea { color: #c62828; font-weight: 400; }
.rf { font: inherit; font-size: .88rem; padding: .18rem .35rem; border: 1px solid #b9c2cc; border-radius: 3px; background: #fff; color: #111; }
.rf:focus { outline: 2px solid var(--brand); outline-offset: 0; }
.rf-xs { width: 3.2rem; } .rf-sm { width: 6.5rem; } .rf-md { width: 12rem; } .rf-lg { width: 18rem; }
.resv-sep { text-align: center; margin: .35rem 0; font-size: .85rem; color: var(--muted); }
.round-link { color: #c62828; font-weight: 700; text-decoration: none; }
.round-link:hover { text-decoration: underline; }
.resv-cxl-info { text-align: right; color: #c62828; font-size: .85rem; margin: .35rem 0 0; }
.resv-foot { text-align: right; font-size: .85rem; margin: .6rem 0; color: var(--muted); }
.resv-foot strong { color: var(--text); }

/* Botonera: iconos SVG pintados por CSS (normal = principal, encima = acento, apagado = gris). Sin JavaScript. */
.rbar { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: stretch; gap: .35rem; padding: .45rem;
  border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.rbtn { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem; min-width: 64px;
  padding: .35rem .45rem; border: 1px solid transparent; border-radius: 6px; color: var(--brand-primary, #123D66);
  font-size: .72rem; line-height: 1.1; text-decoration: none; cursor: pointer; background: none; }
.rbtn span { color: var(--text); }
.rbtn:hover, .rbtn:focus-visible { color: var(--brand-accent, #DC5B0A); border-color: var(--brand-accent-soft, #FFBF6E); background: #fffaf3; outline: none; }
.rbtn.ok { color: #1f8f4e; } .rbtn.danger { color: #c62828; }
.rbtn.ok.warn { color: var(--warn); font-weight: 700; }
.th-sort { color: inherit; text-decoration: none; white-space: nowrap; } .th-sort:hover { text-decoration: underline; }
.rcv-sort { display: inline-flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.rbtn[aria-disabled=true] { color: #C0C0C0; cursor: not-allowed; border-color: transparent; background: none; }
.rbtn[aria-disabled=true] span { color: #9aa3ad; }
.rbar-sep { width: 1px; background: var(--line); margin: 0 .25rem; }
.ico { display: block; flex: none; }
.ico-missing { display: inline-block; width: 26px; height: 26px; border: 1px dashed #C0C0C0; border-radius: 4px; }
@media (max-width: 700px) {
  .rr { justify-content: flex-start; }
  .rf-lg, .rf-md { width: 10rem; }
  .rb-comments label.wide { flex-direction: column; align-items: stretch; }
  .rb-comments textarea { width: 100%; }
}

/* ---------------- Papeleta para imprimir ---------------- */
.ticket-body { background: #fff; padding: 1rem; }
.ticket-tools { max-width: 680px; margin: 0 auto .75rem; text-align: right; }
.ticket { max-width: 680px; margin: 0 auto; border: 1px solid var(--line); border-radius: 8px; padding: 1.25rem; }
.ticket-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 3px solid var(--brand-accent, #DC5B0A);
  padding-bottom: .75rem; margin-bottom: .75rem; }
.ticket-logo { width: 170px; height: auto; }
.ticket-no { text-align: right; font-size: 1.05rem; }
.ticket-no strong { font-size: 1.5rem; }
.ticket-table { width: 100%; border-collapse: collapse; }
.ticket-table th, .ticket-table td { text-align: left; padding: .3rem .4rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.ticket-table th { width: 34%; color: var(--brand-primary, #123D66); font-weight: 600; }
.ticket-h2 { margin: 1rem 0 .35rem; font-size: 1rem; color: var(--brand-primary, #123D66); }
.ticket-comments { margin: 0; white-space: normal; }
.ticket-foot { margin-top: 1rem; text-align: center; font-size: .8rem; color: var(--muted); }
@media print {
  .ticket-tools { display: none; }
  .ticket-body { padding: 0; }
  .ticket { border: 0; padding: 0; max-width: none; }
}
/* ---------------- Configuraciones > Imagen ---------------- */
.logo-row { display: flex; flex-wrap: wrap; align-items: center; gap: 1.5rem; }
.logo-preview { max-width: 260px; max-height: 160px; height: auto; padding: .5rem; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
.logo-form { display: flex; flex-direction: column; gap: .5rem; }
.color-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: .6rem 1.25rem; }
.color-item { display: flex; align-items: center; gap: .6rem; }
.swatch { width: 2rem; height: 2rem; flex: none; border-radius: 6px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.2); }
.color-label { flex: 1; display: flex; flex-direction: column; font-size: .88rem; }
.color-label small { font-size: .75rem; }
input.hex { width: 6.2rem; padding: .35rem .45rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; font-size: .88rem;
  font-family: ui-monospace, Consolas, monospace; text-transform: uppercase; }
input.px { width: 3.2rem; padding: .35rem .4rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; font-size: .88rem; text-align: right; }
.color-sample { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: 1rem; }
.color-sample span { padding: .35rem .7rem; border-radius: 4px; font-size: .85rem; border: 1px solid rgba(0,0,0,.08); }
.s-client { background: var(--block-client); } .s-service { background: var(--block-service); }
.s-round { background: var(--block-round); color: #c62828; font-weight: 700; } .s-card { background: var(--block-card); }
.s-primary { background: var(--brand-primary); color: #fff; } .s-accent { background: var(--brand-accent); color: #fff; font-weight: 700; }
.icon-table td { vertical-align: middle; }
.rbtn.demo { min-width: 0; display: inline-flex; }
/* ---------------- Captura de reservaciones (punto 7) ---------------- */
select.rf { padding: .14rem .2rem; }
.rf-svc { width: 15rem; }
.rf-err { border-color: #c62828 !important; outline: 2px solid #f3b3b3; }
.resv-new { color: var(--brand-accent, #DC5B0A); }
.resv-lock.warn { color: #c62828; font-weight: 700; }
.rb-round-full { text-align: left; padding: .45rem .6rem; }
.rr label.chk { gap: .25rem; }
.rr label.small { font-size: .78rem; }
.help.right, .right { text-align: right; }
.resv-foot .owe { color: var(--brand-accent, #DC5B0A); }
.cust-search { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: .4rem; margin: 0 0 .4rem; font-size: .85rem; }
.cust-search label { display: inline-flex; align-items: center; gap: .35rem; }
.cust-matches { list-style: none; margin: 0 0 .6rem; padding: .4rem .6rem; border: 1px solid var(--line); border-radius: 6px; background: var(--surface);
  max-height: 14rem; overflow-y: auto; font-size: .88rem; }
.cust-matches li { padding: .2rem 0; border-bottom: 1px solid var(--line); }
.cust-matches li:last-child { border-bottom: 0; }
button.rbtn { font: inherit; font-size: .72rem; }
.target-box { display: none; margin-top: 1rem; }
.target-box:target { display: block; }
.small-form { margin: .4rem 0 0; font-size: .82rem; }
.small-form .link { color: var(--brand); text-decoration: underline; }
/* Configuraciones > Roles */
.roles-table input[type="text"] { width: 100%; min-width: 10rem; }
.roles-table td { vertical-align: top; }
.roles-table td.has-error input { border-color: var(--err); }
.roles-table small { display: block; margin-top: .2rem; }
/* Un elemento oculto (atributo hidden) SIEMPRE queda oculto, aunque su clase le ponga display (p. ej. la barra de inactividad). */
[hidden] { display: none !important; }
.idle-warn { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .75rem;
  padding: .6rem 1rem; background: var(--warn-bg); color: var(--warn); font-weight: 600; border-bottom: 2px solid var(--brand-accent, #DC5B0A); }
.web-trip { margin-top: 0; margin-bottom: 1rem; }
.inline-selects { display: inline-flex; gap: .3rem; align-items: center; }
.inline-selects select { width: auto !important; }
input.px.wide-px { width: 6rem; }
/* ---------------- Respaldo de reservaciones, Seguridad, saldos (23/11/2026) ---------------- */
.res-table td.credit { color: #1f6b3a; font-weight: 700; }
.archive-modes { display: flex; flex-direction: column; gap: .6rem; }
.mode-opt { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; padding: .6rem .8rem; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; }
.mode-opt:has(input[type=radio]:checked) { border-color: var(--brand); background: var(--info-bg); }
.mode-opt span { flex: 1 1 260px; }
.mode-opt input[type=date] { padding: .35rem .45rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; }
.confirm-card { margin: 1rem auto; }
.confirm-card .field { margin-bottom: .9rem; }/* ---------------- Reportes: Asignación, Cuentas por cobrar, pie de página (25/11/2026) ---------------- */
.small { font-size: .82rem; }
.tag-practice { display: inline-block; margin-left: .3rem; padding: 0 .35rem; border-radius: 4px; background: #fff3dc; color: #8a5a00; font-size: .7rem; font-weight: 700; }
.site-foot { display: flex; flex-wrap: wrap; justify-content: center; gap: .25rem 1rem; padding: 1rem; font-size: .82rem; color: #6b7c8c;
  background: var(--surface); border-top: 4px solid var(--brand-accent, #DC5B0A); text-align: center; }
.site-foot strong { color: var(--text); }
.bare .site-foot, .home .site-foot { position: static; margin-top: 2rem; }
.bare .site-foot { align-self: stretch; margin: 2rem -1rem 0; }
.asg-day input[type=date] { width: auto; }
.asg-title { margin: 0 0 .5rem; }
.asg-table td, .asg-table th { padding: .35rem .5rem; }
.asg-table select { padding: .2rem .3rem; border: 1px solid #c5ccd4; border-radius: 5px; font: inherit; font-size: .88rem; max-width: 15rem; background: #fff; }
.asg-table tr.changed td { background: #eef6ff; }
.asg-table tr.asg-warn td { background: #fff3dc; }
.asg-table tr.asg-err td { background: #fde8e8; }
.asg-table tr.asg-internal td { color: var(--muted); }
.asg-table tr.flight-saved td[data-time-cell] { font-weight: 700; color: var(--ok); }
.asg-icons span { display: inline-block; padding: 0 .3rem; border-radius: 4px; font-size: .7rem; font-weight: 700; cursor: help; }
.asg-com { background: var(--info-bg); color: var(--info); }
.asg-priv { background: var(--err-bg); color: #c62828; }
.asg-flight { color: var(--brand); text-decoration: underline dotted; text-align: left; }
.asg-bar { position: sticky; bottom: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: .75rem;
  padding: .7rem 1rem; margin-top: .75rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 -2px 8px rgba(0,0,0,.06); }
.asg-warnings ul { margin: .4rem 0; padding-left: 1.2rem; }
.asg-warnings a { color: inherit; }
.lock-card h2 { color: var(--warn); }
dialog.dlg { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; width: min(30rem, calc(100vw - 2rem)); box-shadow: 0 10px 30px rgba(0,0,0,.2); }
dialog.dlg::backdrop { background: rgba(15, 30, 45, .45); }
.dlg-form { display: flex; flex-direction: column; gap: .8rem; }
.dlg-form h2 { margin: 0; }
.dlg-form .actions { margin-top: .25rem; }
.rcv-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; }
.rcv-grid input[readonly] { background: var(--bg); font-weight: 700; }
.rcv-alert { padding: .8rem 1rem; border: 2px solid #c62828; border-radius: var(--radius); background: var(--err-bg); color: #7a1414; }
.rcv-alert p { margin: .4rem 0; }
.rcv-folio { max-width: 8rem !important; flex: 0 0 8rem !important; }
.rcv-table tfoot th { background: #f8fafb; }
.rcv-log tr.rcv-charge-changed td { background: #fff3dc; }
/* Impresión del día y papeletas */
.pap-body { font-size: 12px; }
.pap-sheet, .pap { max-width: 900px; margin: 0 auto 1.5rem; }
.pap-agency { display: flex; align-items: center; gap: .8rem; padding-bottom: .5rem; margin-bottom: .6rem; border-bottom: 3px solid var(--brand-accent, #DC5B0A); }
.pap-logo { width: 120px; height: auto; }
.pap-h1 { font-size: 1.1rem; margin: .4rem 0 .6rem; }
.pap-head { text-align: center; margin: .4rem 0 .8rem; }
.pap-head p { margin: .15rem 0; }
.pap-trip { font-size: 1.15rem; }
.pap-table { width: 100%; border-collapse: collapse; }
.pap-table th, .pap-table td { padding: .25rem .35rem; border-bottom: 1px solid #999; text-align: left; vertical-align: top; }
.pap-table thead th { border-bottom: 2px solid #000; }
.pap-table tbody tr:nth-child(even) td { background: #eee; }
.pap-table tfoot td { border-bottom: 0; padding-top: .4rem; }
@media print {
  .pap-sheet, .pap { max-width: none; margin: 0; }
  .pap { break-before: page; }
  .pap-table thead { display: table-header-group; }
  .pap-table tr { break-inside: avoid; }
  .pap-table tbody tr:nth-child(even) td { background: #eee !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ================= Sistema financiero La Lonche ================= */
:root { --pos: var(--money-in, #1E7B34); --neg: var(--money-out, #B3261E); }
.num { text-align: right; font-variant-numeric: tabular-nums; }
td.num input.num, .table input.num { width: 9rem; text-align: right; }
.pos { color: var(--pos); }
.neg { color: var(--neg); font-weight: 600; }
.brand-logo { height: 30px; width: auto; vertical-align: middle; }
.brand-sub { font-weight: 400; opacity: .8; font-size: .9rem; }
.bare-logo { height: 40px; width: auto; vertical-align: middle; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1rem; align-items: start; }
.grid-2 > .card { margin: 0; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .75rem; margin: 0 0 1rem; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .75rem 1rem; display: flex; flex-direction: column; gap: .15rem; }
.kpi span { color: var(--muted); font-size: .85rem; }
.kpi strong { font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.kpi a { font-size: .85rem; }
.kpi .kpi-pct { color: var(--ink, inherit); font-weight: 600; font-size: .9rem; }
.table tfoot tr.avg-row th, .table tfoot tr.avg-row td { background: #f8fafb; border-top: 2px solid var(--line); }
.kpi.alert { border-color: var(--neg); box-shadow: inset 3px 0 0 var(--neg); }
.kpi.alert strong { color: var(--neg); }
.table.compact th, .table.compact td { padding: .35rem .5rem; }
.statement th { text-align: left; font-weight: 400; }
.statement tr.sum th, .statement tr.sum td { font-weight: 700; border-top: 2px solid var(--line); }
.statement tr.sum.big th, .statement tr.sum.big td { font-size: 1.1rem; }
.statement tr.subtotal th, .statement tr.subtotal td { font-weight: 600; }
.statement tr.group th { background: var(--bg); font-weight: 700; text-transform: uppercase; font-size: .8rem; letter-spacing: .03em; }
.statement tr.detail th { padding-left: 1.5rem; }
.total-line { font-size: 1.05rem; margin: .75rem 0 0; }
.sub-card { margin-top: 1rem; padding-top: 1rem; border-top: 1px dashed var(--line); }
.sub-card h3 { font-size: 1rem; margin: 0 0 .5rem; }
.inline-form { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin-top: .75rem; }
.inline-form input, .inline-form select { padding: .35rem .5rem; border: 1px solid #c5ccd4; border-radius: 6px; font: inherit; }
.inline-form input[name=concept], .inline-form input[name=reason] { flex: 1 1 12rem; }
.inline-check { display: inline-flex; align-items: center; gap: .3rem; margin-right: .9rem; }
.branches { display: flex; flex-wrap: wrap; gap: .2rem .4rem; align-items: center; margin-top: .35rem; }
.branches.has-error { outline: 1px solid var(--err); border-radius: 6px; padding: .25rem; }
.presets { display: inline-flex; gap: .6rem; font-size: .85rem; }
.list-lines li { padding: .35rem 0; border-bottom: 1px solid var(--line); }
.list-lines li:last-child { border-bottom: 0; }
ul.plain { list-style: none; margin: 0; padding: 0; }
ul.log { list-style: none; margin: 0; padding: 0; font-size: .9rem; }
ul.log li { padding: .3rem 0; border-bottom: 1px solid var(--line); }
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; margin: 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; }
.badge.info { background: var(--info-bg); color: var(--info); }
.badge.role-cajero { background: #fdf0e1; color: #8a4b0f; }
.badge.role-encargado { background: #e7f1e8; color: #23603a; }

/* Impresion del corte */
.print-page { background: #fff; }
.print-tools { padding: 1rem; text-align: right; }
.print-sheet { max-width: 720px; margin: 0 auto; padding: 0 1rem 2rem; }
.print-head { display: flex; align-items: center; gap: 1rem; border-bottom: 2px solid var(--text); padding-bottom: .5rem; margin-bottom: 1rem; }
.print-logo { height: 56px; width: auto; }
.print-sheet h2 { font-size: 1rem; margin: 1.25rem 0 .4rem; }
.signatures { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; margin-top: 4rem; }
.signatures div { border-top: 1px solid var(--text); padding-top: .3rem; text-align: center; }
.signatures span { display: block; color: var(--muted); font-size: .8rem; }
.print-foot { margin-top: 2rem; font-size: .8rem; }
@media print {
  .no-print, .topbar, .sidebar, .site-foot { display: none !important; }
  body, .print-page { background: #fff; }
  .print-sheet { max-width: none; padding: 0; }
}

/* ---- Ingresos, cortes de efectivo y campana (0.2.0) ---- */
.bell { position: relative; display: inline-flex; align-items: center; color: var(--muted); text-decoration: none; margin-right: .75rem; }
.bell.on { color: var(--err); }
.bell-n { position: absolute; top: -6px; right: -10px; min-width: 18px; padding: 0 4px; border-radius: 99px; background: var(--err); color: #fff;
  font-size: .7rem; line-height: 18px; text-align: center; font-weight: 700; }
.diff-neg { color: #B3261E; font-weight: 700; }   /* ROJO: falta dinero */
.diff-zero { color: #1557B0; font-weight: 700; }  /* AZUL: cuadra exacto */
.diff-pos { color: #1E7B34; font-weight: 700; }   /* VERDE: sobra dinero */
td.diff-neg { background: #fde8e8; } td.diff-zero { background: #e6f0fb; } td.diff-pos { background: #e4f4ea; }
/* Colores del Excel maestro (usuario, 01/12/2026): ABONOS azul, CARGOS ocre; SALDO verde si es positivo, rojo si es
   negativo y azul neutral en 0. Tomados del archivo: abonos #0070C0, cargos "Naranja, Énfasis 2, 25 % más oscuro"
   #C55A11, saldo ≥ 0 #00B050, saldo < 0 #FF0000 (formato condicional de la columna G). */
/* Columnas ocultas a pedido del usuario (siguen en el código y en el CSV; solo no se muestran). */
.col-hide { display: none; }
.center, .table th.center, .table td.center { text-align: center; }
.icon-paid { color: #00B050; vertical-align: middle; }
/* Captura de gastos por bloque (usuario, 01/12/2026): la página usa todo el ancho y las columnas tienen medida fija para
   que no aparezca la barra de desplazamiento horizontal. */
.main:has(table[data-date-cascade]) { max-width: none; }
table[data-date-cascade] { table-layout: fixed; width: 100%; }
table[data-date-cascade] th, table[data-date-cascade] td { padding: .3rem .35rem; }
table[data-date-cascade] input:not([type=checkbox]), table[data-date-cascade] select { width: 100%; min-width: 0; box-sizing: border-box; padding: .3rem .35rem; font-size: .88rem; }
table[data-date-cascade] th:nth-child(1) { width: 2rem; }
table[data-date-cascade] th:nth-child(2) { width: 8.6rem; }
table[data-date-cascade] th:nth-child(4) { width: 10rem; }
table[data-date-cascade] th:nth-child(5) { width: 6.5rem; }
table[data-date-cascade] th:nth-child(6) { width: 6.5rem; }
table[data-date-cascade] th:nth-child(7) { width: 8.5rem; }
table[data-date-cascade] th:nth-child(8) { width: 11rem; }
table[data-date-cascade] th:nth-child(9) { width: 4rem; }
table[data-date-cascade] th { white-space: normal; font-size: .85rem; }
/* Posible duplicado en la captura por bloque (02/12/2026) */
table[data-date-cascade] tr.has-dup td { background: var(--warn-bg); }
.dup-ok { display: flex; gap: .3rem; align-items: center; font-size: .8rem; color: var(--warn); font-weight: 600; margin-top: .2rem; }
.dup-list { margin: .4rem 0 0 1.1rem; padding: 0; }
.dup-list li { margin: .15rem 0; }
input.paid-check { width: 1.15rem; height: 1.15rem; accent-color: #00B050; }
/* IVA desglosado: oculto a pedido del usuario (01/12/2026); el campo sigue en el formulario y en la base. */
.field:has(#f_tax_amount) { display: none; }
.amt-abono { color: #0070C0; }
.amt-venta { color: #00B050; }
.table .pct-col { border-left: 2px solid var(--line); font-weight: 600; color: var(--text); white-space: nowrap; }
.amt-cargo { color: #C55A11; }
.bal-pos { color: #00B050; font-weight: 700; }
.bal-neg { color: #FF0000; font-weight: 700; }
.bal-zero { color: #1557B0; font-weight: 700; }
.table.dense { font-size: .82rem; }
.table.dense th, .table.dense td { padding: .3rem .45rem; white-space: nowrap; }
.table tr.refund td { color: #B3261E; }
.table tr.staff td { color: var(--muted); font-style: italic; }
.table tr.sum th, .table tr.sum td, .table tfoot td, .table tfoot th { font-weight: 700; background: #f8fafb; }
.subnav { display: flex; flex-wrap: wrap; gap: .25rem; margin: 0 0 1rem; }
.subnav a { padding: .35rem .8rem; border: 1px solid var(--line); border-radius: 99px; text-decoration: none; color: var(--text); background: var(--surface); font-size: .9rem; }
.subnav a.active { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.mono { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .85em; }
.notif { border-left: 4px solid var(--line); }
.notif.unread { border-left-color: var(--err); }
.notif pre { white-space: pre-wrap; font-family: inherit; margin: .5rem 0; }
.cut-figures { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .5rem; margin: 0 0 1rem; }
.cut-figures div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: .6rem .8rem; }
.cut-figures span { display: block; color: var(--muted); font-size: .82rem; }
.cut-figures strong { font-size: 1.2rem; font-variant-numeric: tabular-nums; }
.inline-row { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.inline-row input, .inline-row select { width: auto; }
input.w-money { width: 8.5rem; }
.legend span { margin-right: 1rem; }.explain summary { cursor: pointer; }
.explain ol { margin: .6rem 0 0; padding-left: 1.3rem; }
.explain li { margin-bottom: .45rem; line-height: 1.45; }
.cut-figures .step { display: inline-block; min-width: 1.4rem; height: 1.4rem; line-height: 1.4rem; text-align: center; border-radius: 99px; background: var(--brand); color: var(--brand-ink); font-size: .75rem; margin-right: .3rem; }
tr.incident td { background: #fde2e1; }
tr.incident td:first-child { border-left: 4px solid var(--err); }
.badge.err { background: var(--err); color: #fff; }
tr.current td { background: var(--brand-soft, #fbeee3); font-weight: 600; }

/* ---- Estadísticas de ventas: gráficas SVG (tarjeta = azul, efectivo = naranja; paleta validada para daltonismo) */
:root { --s-tarjeta: #257de0; --s-efectivo: #f47230; --chart-grid: #e7e7e7; --chart-base: #c2c2c2; --chart-ink: #666666; }
.stat-filters label { display: inline-flex; flex-direction: column; gap: .15rem; font-size: .8rem; color: var(--muted); }
.stat-filters .presets { flex-basis: 100%; }
.chart-wrap { overflow-x: auto; margin: .5rem 0; }
svg.chart { display: block; max-width: none; font: 11px system-ui, -apple-system, "Segoe UI", sans-serif; }
svg.chart .grid { stroke: var(--chart-grid); stroke-width: 1; }
svg.chart .base { stroke: var(--chart-base); stroke-width: 1; }
svg.chart .tick { fill: var(--chart-ink); font-variant-numeric: tabular-nums; }
svg.chart .peak { fill: var(--text, #191919); font-weight: 600; }
svg.chart .s-tarjeta, .hbar .s-tarjeta, .swatch.s-tarjeta { fill: var(--s-tarjeta); background: var(--s-tarjeta); }
svg.chart .s-efectivo, .hbar .s-efectivo, .swatch.s-efectivo { fill: var(--s-efectivo); background: var(--s-efectivo); }
svg.chart .hit { fill: transparent; cursor: crosshair; }
svg.chart .hit:hover, svg.chart .hit.on { fill: rgba(25, 25, 25, .06); }
.swatch { display: inline-block; width: .7rem; height: .7rem; border-radius: 2px; margin-right: .35rem; vertical-align: -1px; }
.chart-legend { display: flex; gap: 1.2rem; font-size: .85rem; color: var(--chart-ink); margin: 0 0 .75rem; }
.chart-table summary { cursor: pointer; font-size: .85rem; color: var(--brand); margin-top: .25rem; }
.chart-tip { position: fixed; z-index: 50; pointer-events: none; white-space: pre-line; background: #191919; color: #efefef; font-size: .8rem;
  line-height: 1.4; padding: .45rem .6rem; border-radius: 6px; box-shadow: 0 4px 14px rgba(0,0,0,.2); max-width: 260px; font-variant-numeric: tabular-nums; }
.bar-col { width: 28%; min-width: 120px; }
.hbar { display: flex; gap: 2px; height: .75rem; margin-top: .3rem; }
.hbar i { display: block; height: 100%; border-radius: 0 3px 3px 0; min-width: 0; }
@media print { .stat-filters, .chart-table summary { display: none; } .chart-table[open], .chart-table { display: block; } }.table-wrap.tall { max-height: 32rem; overflow-y: auto; }
.table-wrap.tall thead th { position: sticky; top: 0; background: var(--surface); z-index: 1; }
.table td.best { background: #e3f4e6; font-weight: 600; }
.card.person h3, .card h3 { margin: 1.1rem 0 .4rem; font-size: 1rem; }
td.small { font-size: .82rem; }
/* Cortes de caja SIN barra horizontal (usuario, 02/12/2026; es para PC): página a todo lo ancho, la tabla cabe en la pantalla
   (encabezados en varias líneas, celdas más compactas) y no se recorta en un recuadro con scroll. */
.main:has(.table-wrap.no-scroll) { max-width: none; }
.table-wrap.no-scroll { overflow-x: visible; }
.table-wrap.no-scroll .table th { white-space: normal; }
.table-wrap.no-scroll .table th, .table-wrap.no-scroll .table td { padding: .4rem .45rem; }
.table-wrap.no-scroll .table.dense th, .table-wrap.no-scroll .table.dense td { padding: .3rem .35rem; }
/* Editar movimientos de fondos de caja (02/12/2026) */
fieldset.plain { border: 0; padding: 0; margin: 0; min-width: 0; }
details.inline-details { display: inline-block; vertical-align: middle; margin-left: .35rem; }/* Cuadre diario de tarjeta sin barra horizontal (03/12/2026): Cuenta, Fecha y Notas en un renglón chico debajo del día */
.table.cuadre tr.dep-main td { border-bottom: 0; }
.table.cuadre tr.dep-extra td { padding: 0 .45rem .45rem 1.4rem; white-space: normal; font-size: .78rem; color: var(--muted); }
.table.cuadre tr.dep-extra label { display: inline-flex; align-items: center; gap: .3rem; margin-right: 1rem; }
.table.cuadre tr.dep-extra label.grow { min-width: 16rem; }
.table.cuadre tr.dep-extra label.grow input { flex: 1; }
.table.cuadre tr.dep-extra select, .table.cuadre tr.dep-extra input { font-size: .78rem; padding: .15rem .3rem; }
/* Ingresos varios en Estadísticas (03/12/2026) */
:root { --s-varios: #2a9d8f; }
svg.chart .s-varios, .hbar .s-varios, .swatch.s-varios { fill: var(--s-varios); background: var(--s-varios); }
/* Cortes de caja (05/12/2026): comentarios de la columna J del Excel y avisos de entregas que no cuadran */
.table.cortes td.comments { white-space: normal; min-width: 12rem; max-width: 24rem; font-size: .8rem; color: var(--muted); }
.table.cortes tr.row-alert td { background: #fdf1ee; }
.cut-alert { border-left: 4px solid #c0392b; }
/* Captura simple del corte (05/12/2026) */
.cut-capture .capture-grid input { width: 100%; }
.cut-capture .capture-grid td.num { width: 9rem; }
.cut-capture .capture-sum { margin: 1rem 0; }
/* Cifras a la derecha también en los cuadros de resumen (05/12/2026) */
.kpi strong, .cut-figures strong { display: block; text-align: right; }
/* La regla general de las tablas (text-align: left) le ganaba a .num: cifras SIEMPRE a la derecha (05/12/2026) */
.table th.num, .table td.num, .ticket-table th.num, .ticket-table td.num, .pap-table th.num, .pap-table td.num, .statement th.num { text-align: right; }

/* ---------- Lo más vendido (Top Seller de Clip, 06/12/2026) ---------- */
.spark { display: block; }
.spark polyline { fill: none; stroke: var(--brand); stroke-width: 1.5; stroke-linejoin: round; }
.spark circle { fill: var(--brand); }
.ts-up { color: var(--ok); font-weight: 600; }
.ts-down { color: var(--err); font-weight: 600; }
.ts-flat { color: var(--muted); }
.ts-quads { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: .9rem; margin-bottom: 1rem; }
.ts-quad { border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem 1rem; border-top: 4px solid var(--line); }
.ts-quad h3 { margin: 0 0 .3rem; font-size: 1rem; }
.ts-quad ol { margin: .4rem 0 0; padding-left: 1.2rem; }
.ts-estrella { border-top-color: var(--ok); }
.ts-pilar { border-top-color: var(--info); }
.ts-pilar_riesgo { border-top-color: var(--err); }
.ts-promesa { border-top-color: var(--warn); }
.badge.ts-b-ok { background: var(--ok-bg); color: var(--ok); }
.badge.ts-b-info { background: var(--info-bg); color: var(--info); }
.badge.ts-b-err { background: var(--err-bg); color: var(--err); }
.badge.ts-b-warn { background: var(--warn-bg); color: var(--warn); }
.badge.ts-abc-A { background: var(--ok-bg); color: var(--ok); }
.badge.ts-abc-B { background: var(--info-bg); color: var(--info); }
.ts-reco li { margin-bottom: .45rem; }
.ts-table td { vertical-align: middle; }
