/* Carclass Core v2 · estilo de navegación tipo Asisma, verde Rolex y dorado */
:root {
  --brand: #006039; --brand-600: #004f2f; --brand-700: #003d24; --brand-050: #e8f3ee; --brand-100: #cfe6db;
  --gold: #A37E2C; --gold-050: #f7f1e4;
  --bg: #f4f6f5; --surface: #ffffff; --surface-2: #f8faf9; --border: #e3e8e5; --border-2: #d3dbd6;
  --fg: #14201b; --muted: #5b6a63; --faint: #8b9892;
  --ok: #1a7f4b; --ok-bg: #e5f4ec; --warn: #9a6a00; --warn-bg: #fbf2dc; --bad: #c0362c; --bad-bg: #fbe9e7; --info: #2563a8; --info-bg: #e7eff9;
  --u-blackgps: #1d2a24; --u-somosb2b: #5b4fb3; --u-carclass: #006039; --u-carwash: #2a86b8; --u-nom: #A37E2C; --u-grupo: #6b7a73;
  --shadow: 0 1px 2px rgba(16,32,24,.05), 0 1px 3px rgba(16,32,24,.06);
  --shadow-lg: 0 12px 40px rgba(16,32,24,.18);
  --r: 12px; --r-sm: 8px;
  --side-w: 256px;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --brand: #1f8a5c; --brand-600: #24a06b; --brand-700: #0f5a3a; --brand-050: #12261e; --brand-100: #1a3a2c;
  --gold: #c9a24f; --gold-050: #2a2416;
  --bg: #0c1310; --surface: #121b17; --surface-2: #17221d; --border: #22302a; --border-2: #2c3d35;
  --fg: #e5ece8; --muted: #9aaba3; --faint: #6c7d75;
  --ok: #4cc58a; --ok-bg: #10291d; --warn: #e0b24a; --warn-bg: #2b2412; --bad: #f0786c; --bad-bg: #2e1513; --info: #7fb0ea; --info-bg: #142336;
  --u-blackgps: #c7d2cc; --u-carclass: #2fae74; --u-nom: #c9a24f;
  --shadow: 0 1px 2px rgba(0,0,0,.3); --shadow-lg: 0 16px 48px rgba(0,0,0,.5);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 14px/1.5 "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -.01em; }
button { font: inherit; color: inherit; }
.num, .mono { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); } .faint { color: var(--faint); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- botones e inputs ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: var(--r-sm); border: 1px solid var(--border-2); background: var(--surface); color: var(--fg); font-weight: 600; font-size: 13.5px; cursor: pointer; white-space: nowrap; text-decoration: none !important; transition: background .15s, border-color .15s, box-shadow .15s; }
.btn:hover { background: var(--surface-2); border-color: var(--faint); }
.btn:focus-visible, .input:focus-visible, .chip:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-600); border-color: var(--brand-600); }
.btn.gold { background: var(--gold); border-color: var(--gold); color: #fff; }
.btn.danger { color: var(--bad); }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.sm { height: 32px; padding: 0 12px; font-size: 12.5px; }
.btn.icon { width: 38px; padding: 0; }
.btn.sm.icon { width: 32px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.input { width: 100%; height: 40px; padding: 0 12px; border: 1px solid var(--border-2); border-radius: var(--r-sm); background: var(--surface); color: var(--fg); font: inherit; }
textarea.input { height: auto; min-height: 92px; padding: 10px 12px; resize: vertical; }
select.input { padding-right: 28px; }
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent); outline: none; }
.field { display: grid; gap: 6px; flex: 1 1 200px; min-width: 0; }
.field > label, .lbl { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.row { display: flex; flex-wrap: wrap; gap: 12px; }
.err { color: var(--bad); font-size: 13px; min-height: 0; }
.err:empty { display: none; }
.check-row { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); cursor: pointer; }
.check-row input { width: 16px; height: 16px; accent-color: var(--brand); }

/* ---------- login ---------- */
.login { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); min-height: 100vh; }
.login-brand { position: relative; overflow: hidden; background: radial-gradient(120% 90% at 0% 0%, #0a7a4b 0%, #006039 45%, #003d24 100%); color: #fff; padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.login-brand::after { content: ""; position: absolute; right: -180px; bottom: -180px; width: 520px; height: 520px; border-radius: 50%; border: 1px solid rgba(255,255,255,.12); box-shadow: 0 0 0 60px rgba(255,255,255,.03), 0 0 0 120px rgba(255,255,255,.025); }
.login-brand .logo-row { display: flex; align-items: center; gap: 14px; }
.logo-disc { width: 52px; height: 52px; border-radius: 50%; background: #fff; display: grid; place-items: center; overflow: hidden; flex: none; box-shadow: 0 2px 10px rgba(0,0,0,.15); }
.logo-disc img { width: 100%; height: 100%; object-fit: contain; }
.login-brand .logo-row b { font-size: 18px; display: block; }
.login-brand .logo-row small { opacity: .75; font-size: 12.5px; }
.login-brand h1 { font-size: clamp(28px, 3.2vw, 40px); line-height: 1.15; max-width: 16ch; letter-spacing: -.02em; }
.login-brand h1 em { font-style: normal; color: #e9cf8f; }
.login-brand p.lead { opacity: .85; max-width: 44ch; margin: 14px 0 0; padding: 0; text-indent: 0; font-size: 15px; }
.benefits { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; }
.benefits li { display: flex; gap: 12px; align-items: flex-start; font-size: 14.5px; }
.benefits .ck { width: 24px; height: 24px; border-radius: 50%; background: rgba(255,255,255,.14); display: grid; place-items: center; flex: none; color: #e9cf8f; }
.benefits b { display: block; }
.benefits span.s { opacity: .75; font-size: 13px; }
.login-brand .foot { font-size: 12px; opacity: .6; position: relative; z-index: 1; }
.login-form { display: grid; place-items: center; padding: 40px 24px; background: var(--surface); }
.login-form form { width: 100%; max-width: 400px; display: grid; gap: 18px; }
.login-form h2 { font-size: 26px; }
.login-form .sub { color: var(--muted); margin-top: -10px; }
.pass-wrap { position: relative; }
.pass-wrap .input { padding-right: 44px; }
.pass-wrap button { position: absolute; right: 4px; top: 4px; }
.login-opts { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.login-opts a { font-size: 13px; font-weight: 600; }
.login-form .btn.primary { height: 44px; font-size: 14.5px; }
.login-note { font-size: 12px; color: var(--faint); text-align: center; }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; background: var(--surface); border-right: 1px solid var(--border); display: flex; flex-direction: column; z-index: 30; }
.side-top { padding: 18px 16px 12px; display: grid; gap: 14px; border-bottom: 1px solid var(--border); }
.side .brand { display: flex; align-items: center; gap: 10px; }
.side .brand .logo-disc { width: 40px; height: 40px; border: 1px solid var(--border); box-shadow: none; }
.side .brand b { display: block; font-size: 15px; }
.side .brand small { color: var(--muted); font-size: 12px; }
.btn.notify { width: 100%; height: 36px; font-size: 12.5px; background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.notify.on { background: var(--brand-050); color: var(--brand); border-color: var(--brand-100); }
.nav { flex: 1; overflow-y: auto; padding: 8px 10px 16px; }
.nav h6 { margin: 16px 10px 6px; font-size: 10.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; font-variant: small-caps; color: var(--faint); }
.nav a { display: flex; align-items: center; gap: 11px; padding: 8px 10px; border-radius: var(--r-sm); color: var(--muted); font-weight: 600; font-size: 13.5px; text-decoration: none; position: relative; }
.nav a:hover { background: var(--surface-2); color: var(--fg); }
.nav a.on { background: var(--brand-050); color: var(--brand); }
.nav a.on::before { content: ""; position: absolute; left: -10px; top: 7px; bottom: 7px; width: 3px; border-radius: 0 3px 3px 0; background: var(--brand); }
.nav a .badge { margin-left: auto; }
.nav a .soon { margin-left: auto; font-size: 10px; font-weight: 700; color: var(--gold); background: var(--gold-050); padding: 1px 6px; border-radius: 99px; }
.side-foot { border-top: 1px solid var(--border); padding: 12px 14px; display: flex; align-items: center; gap: 10px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--gold); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 12.5px; flex: none; }
.who { flex: 1; min-width: 0; line-height: 1.25; }
.who b { display: block; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who span { font-size: 12px; color: var(--muted); }
.main { min-width: 0; display: flex; flex-direction: column; }
.scrim { display: none; }
.top { position: sticky; top: 0; z-index: 20; height: 64px; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; padding: 0 24px; }
.crumbs { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 8px; white-space: nowrap; overflow: hidden; }
.crumbs .org { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.crumbs .sep { color: var(--faint); }
.crumbs b { font-size: 16px; overflow: hidden; text-overflow: ellipsis; }
.top .search { position: relative; width: min(280px, 30vw); }
.top .search .input { height: 38px; padding-left: 36px; background: var(--surface-2); }
.top .search svg { position: absolute; left: 12px; top: 11px; color: var(--faint); }
.bell { position: relative; }
.bell .dot { position: absolute; top: 4px; right: 4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 99px; background: var(--bad); color: #fff; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--surface); }
.menu-btn { display: none; }
.page { padding: 24px; max-width: 1440px; width: 100%; margin: 0 auto; display: grid; gap: 20px; align-content: start; }
.page > * { min-width: 0; }
.page > div[id] { display: grid; gap: 20px; align-content: start; }
.side-top .btn { width: 100%; min-width: 0; }
.side-top { min-width: 0; }
.btn.notify { white-space: normal; height: auto; min-height: 36px; padding: 8px 10px; line-height: 1.25; font-size: 12px; }
.grid-main > *, .grid2 > *, .stack > *, .card-b > * { min-width: 0; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.page-head h1 { font-size: 24px; }
.page-head p { margin: 4px 0 0; color: var(--muted); max-width: 70ch; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- tarjetas ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); box-shadow: var(--shadow); min-width: 0; }
.card-h { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--border); }
.card-h h3 { font-size: 14.5px; }
.card-h .r { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.card-b { padding: 18px; }
.empty { padding: 36px 20px; text-align: center; color: var(--muted); display: grid; gap: 4px; justify-items: center; }
.empty b { color: var(--fg); font-size: 14.5px; }
.empty .ic { width: 44px; height: 44px; border-radius: 50%; background: var(--brand-050); color: var(--brand); display: grid; place-items: center; margin-bottom: 6px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.grid-main { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(300px, 1fr); gap: 20px; align-items: start; }
.stack { display: grid; gap: 20px; align-content: start; }

.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 18px; display: grid; gap: 6px; box-shadow: var(--shadow); position: relative; color: inherit; text-decoration: none !important; }
a.kpi:hover { border-color: var(--brand-100); }
.kpi .top-row { display: flex; align-items: center; justify-content: space-between; }
.kpi .l { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.kpi .ki { width: 34px; height: 34px; border-radius: 10px; background: var(--brand-050); color: var(--brand); display: grid; place-items: center; }
.kpi .ki.gold { background: var(--gold-050); color: var(--gold); }
.kpi .v { font-size: 28px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi .s { font-size: 12.5px; color: var(--muted); }
.kpi .v.bad { color: var(--bad); } .kpi .v.warn { color: var(--warn); }

.pill { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 9px; border-radius: 99px; font-size: 11.5px; font-weight: 600; background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); white-space: nowrap; }
.pill.ok { background: var(--ok-bg); color: var(--ok); border-color: transparent; }
.pill.warn { background: var(--warn-bg); color: var(--warn); border-color: transparent; }
.pill.bad { background: var(--bad-bg); color: var(--bad); border-color: transparent; }
.pill.info { background: var(--info-bg); color: var(--info); border-color: transparent; }
.pill.gold { background: var(--gold-050); color: var(--gold); border-color: transparent; }
.pill.u { background: color-mix(in srgb, var(--c) 12%, transparent); color: var(--c); border-color: transparent; }
.pill.u::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; font-size: 11px; font-weight: 700; background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); }
.badge.bad { background: var(--bad); color: #fff; border-color: transparent; }
.badge.brand { background: var(--brand); color: #fff; border-color: transparent; }
.badge:empty { display: none; }

/* filtros */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { height: 32px; padding: 0 13px; border-radius: 99px; border: 1px solid var(--border-2); background: var(--surface); font-size: 12.5px; font-weight: 600; color: var(--muted); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; text-decoration: none !important; }
.chip:hover { color: var(--fg); }
.chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.daterange { display: flex; align-items: center; gap: 6px; background: var(--surface); border: 1px solid var(--border-2); border-radius: var(--r-sm); padding: 0 8px; height: 38px; }
.daterange input { border: 0; background: transparent; color: var(--fg); font: inherit; font-size: 13px; height: 34px; }
.daterange input:focus { outline: none; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); overflow-x: auto; }
.tabs button, .tabs a { background: none; border: 0; padding: 10px 14px; font-weight: 600; font-size: 13.5px; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; text-decoration: none !important; }
.tabs .on { color: var(--brand); border-bottom-color: var(--brand); }
.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 3px; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 7px; font-size: 12.5px; font-weight: 600; color: var(--muted); cursor: pointer; }
.seg button.on { background: var(--surface); color: var(--brand); box-shadow: var(--shadow); }

/* barras */
.bars { display: grid; gap: 10px; }
.bar-row { display: grid; grid-template-columns: minmax(110px, 180px) minmax(0, 1fr) 64px; gap: 12px; align-items: center; font-size: 13px; color: inherit; text-decoration: none !important; }
.bar-row .lab { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-track { height: 10px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--border); overflow: hidden; }
.bar-track i { display: block; height: 100%; border-radius: 99px; background: var(--brand); min-width: 3px; }
.bar-row .n { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.legend { display: flex; gap: 16px; font-size: 12px; color: var(--muted); }
.legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--c); margin-right: 6px; vertical-align: -1px; }
.chart { width: 100%; height: auto; display: block; }
.chart text { fill: var(--faint); font-family: inherit; }
.chart .grid { stroke: var(--border); }
.sla { display: grid; gap: 8px; }
.sla-bar { display: flex; height: 12px; border-radius: 99px; overflow: hidden; background: var(--surface-2); }

/* tablas */
.tbl-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
.tbl th { text-align: left; font-size: 11.5px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; padding: 10px 14px; background: var(--surface-2); border-bottom: 1px solid var(--border); white-space: nowrap; }
.tbl td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .num { text-align: right; white-space: nowrap; }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: var(--surface-2); }
.tbl .name { font-weight: 600; }
.tbl .sub { font-size: 12px; color: var(--muted); }
.pager { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--border); font-size: 12.5px; color: var(--muted); }
.pager span { margin-right: auto; }

/* bandeja */
.inbox { display: grid; gap: 12px; }
.lead { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: start; padding: 16px 18px; }
.lead + .lead { border-top: 1px solid var(--border); }
.clock { width: 64px; height: 64px; border-radius: 14px; display: grid; place-items: center; text-align: center; line-height: 1; background: var(--ok-bg); color: var(--ok); }
.clock b { font-size: 20px; display: block; }
.clock small { font-size: 10.5px; font-weight: 600; }
.clock.warn { background: var(--warn-bg); color: var(--warn); }
.clock.bad { background: var(--bad-bg); color: var(--bad); animation: pulse 2s infinite; }
.clock.done { background: var(--surface-2); color: var(--muted); }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--bad) 15%, transparent); } }
.lead .t { font-weight: 700; font-size: 14.5px; }
.lead .meta { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.lead .msg { margin-top: 8px; padding: 10px 12px; background: var(--surface-2); border-radius: 10px; border: 1px solid var(--border); font-size: 13px; }
.lead .acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }

/* kanban */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(272px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 8px; align-items: start; }
.col { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r); display: flex; flex-direction: column; max-height: calc(100vh - 260px); min-height: 200px; }
.col-h { padding: 12px 14px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--border); }
.col-h b { font-size: 13px; }
.col-h .m { margin-left: auto; font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.col-b { padding: 10px; display: grid; gap: 8px; overflow-y: auto; align-content: start; flex: 1; }
.col.drop { outline: 2px dashed var(--brand); outline-offset: -2px; background: var(--brand-050); }
.kcard { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 11px 12px; cursor: grab; box-shadow: var(--shadow); display: grid; gap: 6px; }
.kcard:hover { border-color: var(--brand-100); }
.kcard.drag { opacity: .45; }
.kcard { min-width: 0; }
.kcard b { font-size: 13px; overflow-wrap: anywhere; }
.kcard .meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 11.5px; color: var(--muted); }
.kcard .next { display: flex; gap: 6px; align-items: center; font-size: 12px; color: var(--muted); }
.kcard .next span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.col-more { font-size: 12px; color: var(--faint); text-align: center; padding: 6px; }
.dropbar { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.dropzone { border: 2px dashed var(--border-2); border-radius: var(--r); padding: 14px; text-align: center; font-weight: 700; font-size: 13px; color: var(--muted); }
.dropzone.win.drop { border-color: var(--ok); background: var(--ok-bg); color: var(--ok); }
.dropzone.lose.drop { border-color: var(--bad); background: var(--bad-bg); color: var(--bad); }

/* ficha */
.ficha-head { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.ficha-head .av { width: 56px; height: 56px; border-radius: 16px; background: var(--brand); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 19px; flex: none; }
.ficha-head .info { flex: 1; min-width: 240px; }
.ficha-head h1 { font-size: 24px; }
.facts { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 6px; color: var(--muted); font-size: 13px; }
.opp { border: 1px solid var(--border); border-radius: 10px; padding: 14px; display: grid; gap: 10px; }
.opp-top { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.steps { display: flex; gap: 4px; }
.steps i { flex: 1; height: 6px; border-radius: 99px; background: var(--border); }
.steps i.done { background: var(--c, var(--brand)); }
.steps-lab { display: flex; justify-content: space-between; font-size: 11px; color: var(--faint); }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 16px; margin: 0; font-size: 13px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.composer { display: grid; gap: 10px; }
.timeline { display: grid; gap: 0; }
.tl { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 10px; padding: 10px 0; position: relative; }
.tl::before { content: ""; position: absolute; left: 15px; top: 40px; bottom: -10px; width: 1px; background: var(--border); }
.tl:last-child::before { display: none; }
.tl .ic { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-050); color: var(--brand); }
.tl.sys .ic { background: var(--surface-2); color: var(--faint); }
.tl .t { font-size: 13px; }
.tl .d { font-size: 11.5px; color: var(--faint); margin-top: 2px; }

/* agenda */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-top: 1px solid var(--border); border-left: 1px solid var(--border); }
.cal .dow { padding: 8px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); background: var(--surface-2); border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.cal .day { min-height: 112px; padding: 6px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); display: grid; gap: 3px; align-content: start; min-width: 0; }
.cal .day.out { background: var(--surface-2); }
.cal .day.out .n { color: var(--faint); }
.cal .day .n { font-size: 12px; font-weight: 700; color: var(--fg); text-decoration: none; justify-self: start; }
.cal .day.today .n { background: var(--brand); color: #fff; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; }
.ev { display: block; font-size: 11.5px; padding: 3px 6px; border-radius: 6px; background: color-mix(in srgb, var(--c, var(--brand)) 12%, transparent); color: var(--fg); border-left: 3px solid var(--c, var(--brand)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-decoration: none !important; }
.ev.tarea { --c: var(--gold); }
.ev.past { opacity: .75; }
.cal.week .day { min-height: 340px; }
.dayview { display: grid; gap: 8px; }
.dayview .ev { white-space: normal; padding: 10px 12px; font-size: 13px; }
.sug { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 12px 16px; }
.sug + .sug { border-top: 1px solid var(--border); }
.sug .ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--gold-050); color: var(--gold); }

/* tareas */
.task { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; padding: 12px 18px; align-items: start; }
.task + .task { border-top: 1px solid var(--border); }
.check { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--border-2); background: var(--surface); cursor: pointer; display: grid; place-items: center; color: #fff; margin-top: 1px; }
.check:hover { border-color: var(--brand); }
.task.hecha .check { background: var(--brand); border-color: var(--brand); }
.task.hecha .t { text-decoration: line-through; color: var(--faint); }

/* notificaciones */
.notif { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; padding: 14px 18px; align-items: start; color: inherit; text-decoration: none !important; }
.notif + .notif { border-top: 1px solid var(--border); }
.notif:hover { background: var(--surface-2); }
.notif .ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--brand-050); color: var(--brand); }
.notif .ic.bad { background: var(--bad-bg); color: var(--bad); }
.notif .ic.warn { background: var(--warn-bg); color: var(--warn); }
.notif.unread .t { font-weight: 700; }
.notif.unread::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); margin-top: 6px; }
.notif .d { font-size: 12px; color: var(--faint); }

/* aviso */
.alert { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r); background: var(--warn-bg); color: var(--fg); border: 1px solid color-mix(in srgb, var(--warn) 25%, transparent); font-size: 13px; }
.alert svg { color: var(--warn); flex: none; margin-top: 1px; }
.alert.info { background: var(--info-bg); border-color: color-mix(in srgb, var(--info) 25%, transparent); }
.alert.info svg { color: var(--info); }
.alert.brand { background: var(--brand-050); border-color: var(--brand-100); }
.alert.brand svg { color: var(--brand); }

/* modal */
.modal-bg { position: fixed; inset: 0; background: rgba(8,20,14,.48); z-index: 100; display: grid; place-items: center; padding: 16px; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } }
.modal { width: 100%; max-width: 580px; max-height: calc(100vh - 32px); display: flex; flex-direction: column; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-lg); border: 1px solid var(--border); }
.modal.wide { max-width: 760px; }
.modal-h { display: flex; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.modal-h h3 { flex: 1; font-size: 16px; }
.modal form { display: flex; flex-direction: column; min-height: 0; }
.modal-b { padding: 20px; display: grid; gap: 14px; overflow-y: auto; }
.modal-f { padding: 14px 20px; border-top: 1px solid var(--border); display: flex; gap: 8px; justify-content: flex-end; }
.onb { text-align: center; display: grid; gap: 12px; justify-items: center; padding: 10px 6px; }
.onb .big { width: 64px; height: 64px; border-radius: 18px; background: var(--brand-050); color: var(--brand); display: grid; place-items: center; }
.onb h4 { font-size: 19px; }
.onb p { margin: 0; color: var(--muted); max-width: 46ch; }
.dots { display: flex; gap: 6px; justify-content: center; }
.dots i { width: 8px; height: 8px; border-radius: 99px; background: var(--border-2); transition: width .2s; }
.dots i.on { width: 22px; background: var(--brand); }

#toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; background: var(--fg); color: var(--surface); padding: 11px 18px; border-radius: 10px; font-weight: 600; font-size: 13.5px; z-index: 200; transition: .2s; box-shadow: var(--shadow-lg); max-width: calc(100vw - 32px); }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
#toast.bad { background: var(--bad); color: #fff; }
.skel { height: 14px; border-radius: 6px; background: linear-gradient(90deg, var(--surface-2), var(--border), var(--surface-2)); background-size: 200% 100%; animation: sk 1.2s infinite; }
@keyframes sk { to { background-position: -200% 0; } }
.proc { white-space: pre-wrap; font-size: 13.5px; line-height: 1.6; }
.proc h4 { margin: 0 0 8px; }
.perm td, .perm th { text-align: center; }
.perm td:first-child, .perm th:first-child { text-align: left; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) { .grid-main, .grid2 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 900px) {
  .login { grid-template-columns: 1fr; }
  .login-brand { padding: 28px 22px; gap: 18px; }
  .login-brand .benefits, .login-brand .foot { display: none; }
  .login-brand h1 { font-size: 26px; }
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: fixed; left: 0; top: 0; bottom: 0; width: min(290px, 86vw); transform: translateX(-100%); transition: transform .2s; }
  .side.open { transform: none; box-shadow: var(--shadow-lg); }
  .scrim { position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 25; }
  .side.open + .scrim { display: block; }
  .menu-btn { display: inline-flex; }
  .top { padding: 0 12px; gap: 6px; }
  .top .search { display: none; }
  .top .nl span { display: none; }
  .top .nl { width: 38px; padding: 0; }
  .crumbs .org, .crumbs .sep { display: none; }
  .page { padding: 16px; }
  .lead { grid-template-columns: auto minmax(0, 1fr); }
  .lead .acts { grid-column: 1 / -1; justify-content: flex-start; }
  .cal .day { min-height: 74px; }
  .ev { font-size: 10.5px; padding: 2px 4px; }
  .bar-row { grid-template-columns: 96px minmax(0, 1fr) 44px; }
  .kanban { grid-auto-columns: 82vw; }
}

/* ---------- v2.1 · líneas de negocio ---------- */
:root { --u-blackgps: #9A7300; --u-nom: #4A5058; --u-carwash: #1F7FB0; --lc: var(--brand); }
:root[data-theme="dark"] { --u-blackgps: #FFD54A; --u-nom: #B4BCC6; --u-carwash: #5BB4E5; }
:root[data-linea="carclass"] { --lc: var(--u-carclass); }
:root[data-linea="nom"] { --lc: var(--u-nom); }
:root[data-linea="carwash"] { --lc: var(--u-carwash); }
:root[data-linea="blackgps"] { --lc: var(--u-blackgps); }
:root[data-linea]:not([data-linea="grupo"]) .top { box-shadow: inset 0 -3px 0 var(--lc); }
.linea-pick { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 6px 0 12px; border: 1px solid var(--border-2); border-radius: 99px; background: var(--surface); flex: none; }
.linea-pick select { border: 0; background: transparent; font: inherit; font-weight: 700; font-size: 13px; color: var(--fg); height: 34px; cursor: pointer; }
.linea-pick select:focus { outline: none; }
.linea-pick:focus-within { border-color: var(--lc); }
.ldot { width: 10px; height: 10px; border-radius: 50%; background: var(--c, var(--lc)); flex: none; }
.linea-pick .ldot { background: var(--lc); }
.ltabs { display: flex; gap: 6px; flex-wrap: wrap; }
.ltabs button { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--border-2); background: var(--surface); font-weight: 700; font-size: 13px; color: var(--muted); cursor: pointer; }
.ltabs button:hover { color: var(--fg); }
.ltabs button.on { border-color: var(--c); color: var(--fg); box-shadow: inset 0 -3px 0 var(--c); }
.ucards { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 16px; }
.ucard { display: grid; gap: 14px; align-content: start; background: var(--surface); border: 1px solid var(--border); border-top: 4px solid var(--c); border-radius: var(--r); padding: 16px 18px; color: inherit; text-decoration: none !important; box-shadow: var(--shadow); min-width: 0; }
.ucard:hover { border-color: var(--c); }
.uc-h { display: flex; gap: 10px; align-items: center; }
.uc-h b { display: block; font-size: 15.5px; }
.uc-h .faint { font-size: 12px; }
.uc-h .go { margin-left: auto; color: var(--faint); }
.uc-h .ldot { width: 12px; height: 12px; background: var(--c); }
.ucard .meta-t i { background: var(--c); }
.minis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.mini { display: grid; gap: 1px; min-width: 0; }
.mini .l { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.mini b { font-size: 18px; font-variant-numeric: tabular-nums; }
.mini .s { font-size: 11.5px; color: var(--faint); }
.uc-al { display: grid; gap: 6px; font-size: 12.5px; border-top: 1px solid var(--border); padding-top: 10px; }
.uc-al > div { display: flex; gap: 8px; align-items: flex-start; }
.uc-al svg { color: var(--warn); flex: none; margin-top: 2px; }
.uc-al.ok { display: flex; gap: 8px; color: var(--muted); }
.uc-al.ok svg { color: var(--ok); }
.meta { display: grid; gap: 5px; min-width: 0; }
.meta-k { font-size: 12px; font-weight: 600; color: var(--muted); }
.meta-l { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; font-variant-numeric: tabular-nums; }
.meta-t { height: 8px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--border); overflow: hidden; }
.meta-t i { display: block; height: 100%; background: var(--c, var(--lc)); border-radius: 99px; min-width: 2px; }
.ok-t { color: var(--ok); font-weight: 700; }
.bad-t { color: var(--bad); font-weight: 700; }
.uband { background: linear-gradient(90deg, color-mix(in srgb, var(--c) 10%, var(--surface)), var(--surface) 70%); border: 1px solid var(--border); border-left: 5px solid var(--c); border-radius: var(--r); padding: 16px 20px; }
.ub-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px 28px; }
h2.sec { font-size: 15px; margin: 10px 0 -6px; }
h2.sec .faint { font-weight: 500; font-size: 13px; }
.funnel { display: grid; gap: 8px; }
.fstep { display: grid; grid-template-columns: 22px minmax(110px, 170px) minmax(0, 1fr) 50px; gap: 10px; align-items: center; font-size: 13px; }
.fi { width: 22px; height: 22px; border-radius: 50%; background: var(--surface-2); border: 1px solid var(--border); display: grid; place-items: center; font-size: 11px; font-weight: 700; color: var(--muted); }
.fstep .n { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.fstep .lab { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fstep .bar-track i { background: var(--lc); }
.pick { display: grid; gap: 2px; width: 100%; text-align: left; padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); cursor: pointer; margin-bottom: 6px; }
.pick:hover { border-color: var(--brand); }
.input.sm { height: 32px; font-size: 13px; padding: 0 8px; }
.qtbl td { vertical-align: middle; padding: 8px 10px; }
.qtbl tfoot td { border-bottom: 0; padding-top: 12px; }
.xbox { display: grid; gap: 10px; padding: 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--border); }
.hint { font-size: 12px; color: var(--muted); }

/* documento de cotización (pantalla, link público y PDF) */
.qdoc { background: #fff; color: #14201b; max-width: 820px; width: 100%; margin: 0 auto; border-radius: 14px; border: 1px solid #e3e8e5; box-shadow: var(--shadow); padding: 40px 44px; display: grid; gap: 24px; border-top: 6px solid var(--c); }
.qdoc .logo-disc { border: 1px solid #e3e8e5; }
.qd-h { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; align-items: flex-start; }
.qd-brand { display: flex; gap: 12px; align-items: center; }
.qd-brand b { display: block; font-size: 20px; }
.qd-brand small { color: #5b6a63; }
.qd-meta { display: grid; text-align: right; gap: 2px; font-size: 13px; color: #5b6a63; }
.qd-meta b { color: #14201b; font-size: 15px; }
.qd-cli { display: flex; gap: 32px; flex-wrap: wrap; padding: 14px 16px; background: #f4f6f5; border-radius: 10px; }
.qd-cli .lbl { display: block; color: #5b6a63; }
.qd-items { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.qd-items th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: #5b6a63; border-bottom: 2px solid #14201b; padding: 8px 6px; }
.qd-items td { padding: 12px 6px; border-bottom: 1px solid #e3e8e5; vertical-align: top; }
.qd-items .num { text-align: right; white-space: nowrap; }
.qd-items .sub { font-size: 12px; color: #5b6a63; }
.qd-tot { justify-self: end; min-width: 280px; display: grid; gap: 6px; font-size: 13.5px; }
.qd-tot div { display: flex; justify-content: space-between; gap: 20px; }
.qd-tot .big { font-size: 20px; font-weight: 800; border-top: 2px solid #14201b; padding-top: 8px; }
.qd-notas h4 { margin: 0 0 6px; font-size: 13px; }
.qd-notas p { margin: 0; font-size: 12.5px; color: #3a4741; white-space: pre-wrap; }
.qd-f { font-size: 11.5px; color: #8b9892; border-top: 1px solid #e3e8e5; padding-top: 12px; text-align: center; }
.pub { min-height: 100vh; background: #eef1ef; padding: 24px 16px; display: grid; gap: 16px; align-content: start; --u-carclass: #006039; --u-carwash: #1F7FB0; --u-nom: #4A5058; --u-blackgps: #9A7300; }
.pub-bar { max-width: 820px; width: 100%; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; font-weight: 700; color: #14201b; }
.pub-cta { max-width: 820px; width: 100%; margin: 0 auto; text-align: center; display: grid; gap: 10px; justify-items: center; color: #3a4741; }
.pub-cta p { margin: 0; }
@media print {
  body { background: #fff !important; }
  .side, .top, .scrim, .no-print, #toast, .pub-bar, .pub-cta, #modal-root { display: none !important; }
  .shell, .main, .page, .pub { display: block !important; padding: 0 !important; margin: 0 !important; background: #fff !important; max-width: none !important; }
  .qdoc { box-shadow: none; border: 0; border-top: 6px solid var(--c); max-width: none; padding: 0; border-radius: 0; }
  @page { margin: 16mm; }
}
@media (max-width: 900px) {
  .linea-pick { padding-left: 10px; }
  .linea-pick select { max-width: 104px; }
  .qdoc { padding: 24px 18px; }
  .qd-meta { text-align: left; }
  .fstep { grid-template-columns: 22px 96px minmax(0, 1fr) 40px; }
  .minis { gap: 8px 10px; }
}

/* ---------- v2.2 · finanzas ---------- */
.eerr { font-size: 12.5px; }
.eerr th:first-child, .eerr td:first-child { position: sticky; left: 0; background: var(--surface); z-index: 1; min-width: 220px; }
.eerr thead th:first-child { background: var(--surface-2); }
.eerr td { padding: 8px 12px; white-space: nowrap; }
.eerr .e-sec td { background: var(--surface-2); font-weight: 800; text-transform: uppercase; font-size: 11px; letter-spacing: .06em; color: var(--muted); padding-top: 12px; }
.eerr .e-sub td { font-weight: 700; }
.eerr .e-det td { color: var(--muted); }
.eerr .e-det td:first-child { padding-left: 32px; }
.eerr .e-tot td { font-weight: 700; border-top: 1px solid var(--border-2); }
.eerr .e-big td { font-weight: 800; font-size: 13.5px; background: var(--brand-050); border-top: 2px solid var(--brand); }
.eerr .e-big td:first-child { background: var(--brand-050); }
.eerr .e-pct td { color: var(--muted); font-style: italic; }
.eerr .neg { color: var(--bad); }
.eerr .ldot { display: inline-block; width: 8px; height: 8px; margin-right: 4px; }
@media print { .eerr-card, .card { box-shadow: none !important; border: 1px solid #ddd !important; break-inside: avoid; } .kpis { grid-template-columns: repeat(4, 1fr) !important; } .tbl-wrap { overflow: visible !important; max-height: none !important; } .eerr td, .eerr th { font-size: 9.5px; padding: 4px 6px; } body { -webkit-print-color-adjust: exact; print-color-adjust: exact; } }

/* v2.5 · inspecciones IPC */
.tbl.click tbody tr { cursor: pointer; }
.tbl.click tbody tr:hover, .tbl.click tbody tr:focus { background: var(--surface-2); outline: none; }
.ins-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px 16px; font-size: 13.5px; }
.ins-capa { border: 1px solid var(--border); border-radius: var(--r-sm); margin-bottom: 8px; }
.ins-capa summary { padding: 10px 12px; cursor: pointer; }
.ins-capa .tbl { margin: 0; }
.solo-obs .ins-ok { display: none; }
.ins-gal { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 10px; }
.ins-gal figure { margin: 0; }
.ins-gal img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: var(--r-sm); border: 1px solid var(--border); display: block; }
.ins-gal figcaption { font-size: 12px; color: var(--muted); margin-top: 4px; }
@media (max-width: 640px) { #ins-q { width: 100% !important; } .ins-capa td { width: auto !important; padding-left: 6px; padding-right: 6px; } }
/* v2.5.2 · modales que no se salen de la pantalla en el celular, y botón «Mover» del embudo */
.modal form, .modal-b > * { min-width: 0; }
.modal-b { grid-template-columns: minmax(0, 1fr); }
.kcard .kmove { margin-left: auto; height: 24px; padding: 0 8px; font-size: 11.5px; flex: none; }
.qtot { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: baseline; gap: 4px 16px; font-size: 13px; padding: 4px 10px 0; }
.mover-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
@media (max-width: 640px) {
  .modal-bg { padding: 8px; }
  .modal { max-height: calc(100dvh - 16px); }
  .modal-h, .modal-b, .modal-f { padding-left: 14px; padding-right: 14px; }
  .modal-f { flex-wrap: wrap; }
  .modal-f .btn { flex: 1 1 auto; }
  .qtbl thead th:nth-child(4), .qtbl tbody td:nth-child(4) { display: none; }
  .qtbl tbody td:first-child { min-width: 110px; }
  .qtbl td { padding-left: 4px !important; padding-right: 4px !important; }
  .qtbl input[data-f="cantidad"] { width: 46px !important; }
  .qtbl input[data-f="precio"] { width: 92px !important; }
}
/* v2.6.0 · Conversaciones de WhatsApp */
.chat-layout { display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); gap: 16px; align-items: start; }
.chat-list { max-height: calc(100vh - 210px); overflow-y: auto; }
.chat-item { display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--border); color: inherit; text-decoration: none; }
.chat-item:hover { background: var(--surface-2); }
.chat-item.on { background: var(--brand-50, var(--surface-2)); box-shadow: inset 3px 0 0 var(--brand); }
.chat-item .avatar { width: 38px; height: 38px; color: #fff; }
.ell { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-pane { display: flex; flex-direction: column; min-height: 420px; }
.chat-h { gap: 10px; align-items: center; }
.chat-state { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 10px 16px; border-bottom: 1px solid var(--border); font-size: 13px; background: var(--surface-2); }
.chat-msgs { display: flex; flex-direction: column; gap: 8px; padding: 16px; max-height: 52vh; overflow-y: auto; }
.bub { max-width: 78%; padding: 8px 12px; border-radius: 12px; font-size: 13.5px; white-space: pre-wrap; overflow-wrap: anywhere; background: var(--surface-2); align-self: flex-start; }
.bub.out { align-self: flex-end; background: var(--brand-100); }
.bub.ia { border: 1px dashed var(--brand); }
.bub .bt { display: block; font-size: 11px; color: var(--muted); margin-top: 3px; text-align: right; }
.borrador { margin: 0 16px 12px; padding: 12px; border: 1px solid var(--gold); border-radius: 12px; display: grid; gap: 8px; background: color-mix(in srgb, var(--gold) 7%, var(--surface)); }
.bub.propuesta { max-width: 100%; align-self: stretch; }
.chat-foot { padding: 12px 16px; border-top: 1px solid var(--border); margin-top: auto; display: flex; justify-content: flex-end; }
.solo-movil { display: none; }
@media (max-width: 900px) {
  .chat-layout { grid-template-columns: minmax(0, 1fr); }
  .chat-layout.con-chat .chat-list { display: none; }
  .chat-layout:not(.con-chat) .chat-pane { display: none; }
  .solo-movil { display: inline-flex; }
  .chat-list { max-height: none; }
  .bub { max-width: 88%; }
}
.chat-item, .chat-item * { text-decoration: none !important; }
/* v2.7.0 · pestañas y modo del asesor en Conversaciones */
.cv-modos { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
.cv-modo { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; border: 1px solid var(--border); border-radius: 999px; padding: 3px 4px 3px 10px; background: var(--surface); }
.cv-modo select { border: 0; background: var(--surface-2); border-radius: 999px; font: inherit; font-weight: 500; padding: 3px 6px; color: inherit; }
.clasificar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--border); }
#cv-tabs .badge:empty { display: none; }
/* v2.8.0 · enviar desde Core y ventas con margen */
.chat-foot { flex-direction: column; align-items: stretch; gap: 6px; }
.chat-compose { display: flex; gap: 8px; align-items: flex-end; }
.chat-compose textarea { flex: 1; min-height: 44px; resize: vertical; }
.bor-acc { display: flex; flex-wrap: wrap; gap: 6px; }
.bor-ed { font-size: 13.5px; }
.venta-row { display: grid; gap: 2px; padding-bottom: 6px; border-bottom: 1px solid var(--border); }
.venta-row:last-child { border-bottom: 0; }
/* v2.8.2 · clasificar o derivar cualquier chat */
.clasificar-d { border-bottom: 1px solid var(--border); }
.clasificar-d > summary { padding: 9px 16px; font-size: 12.5px; color: var(--muted); cursor: pointer; }
.clasificar-d .clasificar { border-bottom: 0; padding-top: 0; }
/* v2.8.3 · playbook comercial en Ayuda */
details.pb { border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px; background: var(--surface); }
details.pb > summary { cursor: pointer; font-weight: 600; font-size: 13.5px; }
