/* =====================================================================
   Deudas y Cobros TMS - estilos del portal (celular primero, 380 px)
   Base sacada de HelpDesk TMS (hd.css v54): misma letra, colores, barra, tarjetas y formularios.
   El color --acc sale del espacio (espacios.color).
   Semáforo: verde a tiempo/pagado, azul en curso, ámbar en riesgo, rojo vencido, gris pendiente, violeta en pausa.
   ===================================================================== */
:root {
  --acc: #2563EB;
  --tinta: #16181d; --tinta-2: #525866; --tinta-3: #8a909c;
  --fondo: #e9edf3; --tarj: #ffffff; --borde: #e4e7ec; --barra: #14161b;
  --ok: #16a34a; --ok-suave: #e7f6ec; --no: #dc2626; --no-suave: #fdecec; --av: #d97706; --av-suave: #fff4e0;
  --rad: 16px; --sombra: 0 1px 2px rgba(16,24,40,.05), 0 6px 20px rgba(16,24,40,.06);
  --fuente: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--fuente); color: var(--tinta); background: var(--fondo); line-height: 1.45; font-size: 15px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--acc); }
[hidden] { display: none !important; }
.opc { color: var(--tinta-3); font-weight: 400; font-size: .85em; }
.muted { color: var(--tinta-3); }

/* ---------- Barra superior ---------- */
.barra { position: sticky; top: 0; z-index: 20; background: var(--barra); color: #fff; display: flex; align-items: center;
  justify-content: space-between; gap: 10px; padding: 10px 16px; flex-wrap: wrap; }
.barra-izq { display: flex; align-items: center; gap: 10px; min-width: 0; flex-wrap: wrap; }
.logo { color: var(--acc); font-weight: 800; text-decoration: none; font-size: 1.05rem; filter: brightness(1.35); }
.barra-tit { font-weight: 700; }
.barra-esp, .barra-yo { color: #b9bec9; font-size: .85rem; }
.barra-yo { background: rgba(255,255,255,.08); border-radius: 999px; padding: 3px 10px; }
.barra-yo b { color: #fff; font-weight: 600; }
.sel-esp { width: auto; max-width: 220px; background: rgba(255,255,255,.1); color: #fff; border: 1px solid rgba(255,255,255,.2); border-radius: 8px; padding: 4px 8px; font-size: .85rem; }
.sel-esp option { color: #000; }
.barra-menu { display: none; background: none; border: 0; color: #fff; font-size: 1.4rem; padding: 2px 6px; }
.barra-nav { display: flex; gap: 4px; flex-wrap: wrap; }
.barra-nav a { color: #e6e8ec; text-decoration: none; padding: 7px 12px; border-radius: 10px; font-weight: 600; font-size: .92rem; }
.barra-nav a:hover { background: rgba(255,255,255,.08); }
.barra-nav a.act { background: var(--acc); color: #fff; }
.barra-nav a.salir { color: #fca5a5; }
@media (max-width: 760px) {
  .barra-menu { display: block; }
  .barra-nav { display: none; width: 100%; flex-direction: column; }
  .nav-abierta .barra-nav { display: flex; }
  .barra-yo { display: none; }
}

/* ---------- Contenedor ---------- */
.cont { max-width: 1180px; margin: 0 auto; padding: 16px; }
.simple { max-width: 520px; margin: 60px auto; padding: 24px; text-align: center; }
.pie { text-align: center; color: var(--tinta-3); font-size: .78rem; padding: 18px 8px 28px; }
h1, h2, h3 { letter-spacing: -.01em; }
.tit-sec { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 22px 0 10px; flex-wrap: wrap; }
.tit-sec h2 { margin: 0; font-size: 1.15rem; }

/* ---------- Saludo ---------- */
.hola { background: linear-gradient(120deg, #14161b 0%, color-mix(in srgb, var(--acc) 70%, #14161b) 100%);
  color: #fff; border-radius: 22px; padding: 22px 22px; position: relative; overflow: hidden; }
.hola::after { content: ''; position: absolute; right: -60px; top: -80px; width: 260px; height: 260px; border-radius: 50%;
  background: rgba(255,255,255,.07); }
.hola h1 { margin: 0; font-size: 1.45rem; }
.hola p { margin: 4px 0 0; opacity: .85; }
.hola .fecha { position: absolute; right: 18px; top: 16px; background: rgba(255,255,255,.14); border-radius: 999px; padding: 4px 12px;
  font-size: .82rem; font-weight: 600; z-index: 1; }
@media (max-width: 520px) { .hola .fecha { position: static; display: inline-block; margin-top: 10px; } }

/* ---------- Indicadores ---------- */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; margin-top: 14px; }
@media (max-width: 520px) { .kpis { grid-template-columns: repeat(2, 1fr); } }
.kpi { background: var(--tarj); border-radius: var(--rad); padding: 14px 16px; box-shadow: var(--sombra); border-left: 4px solid var(--c, var(--acc));
  text-decoration: none; color: inherit; display: block; }
.kpi span { color: var(--tinta-2); font-size: .85rem; font-weight: 600; }
.kpi b { display: block; font-size: 1.9rem; font-weight: 800; line-height: 1.15; margin-top: 2px; }
.kpi small { color: var(--tinta-3); font-size: .8rem; }

/* ---------- Tarjetas ---------- */
.grid2 { display: grid; grid-template-columns: 1.6fr 1fr; gap: 14px; }
@media (max-width: 900px) { .grid2 { grid-template-columns: 1fr; } }
.grid2 > *, .col > * { min-width: 0; }
.col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
html, body { overflow-x: hidden; }
.tarj { background: var(--tarj); border-radius: var(--rad); box-shadow: var(--sombra); padding: 16px 18px; }
.tarj h3 { margin: 0 0 2px; font-size: 1.02rem; }
.tarj .sub { margin: 0 0 12px; color: var(--tinta-3); font-size: .85rem; }
.vacio { color: var(--tinta-3); text-align: center; padding: 22px 10px; font-size: .92rem; }

/* ---------- Proyectos (avance general) ---------- */
.proys { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.proy { background: var(--tarj); border-radius: var(--rad); box-shadow: var(--sombra); padding: 14px 16px; text-decoration: none; color: inherit;
  display: flex; flex-direction: column; gap: 8px; border-top: 4px solid var(--c, var(--acc)); }
.proy-cab { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.proy-cab b { font-size: 1rem; }
.ver { background: #eef2ff; color: #3730a3; border-radius: 6px; font-size: .72rem; font-weight: 800; padding: 2px 6px; white-space: nowrap; }
.proy-pct { display: flex; align-items: center; gap: 10px; }
.proy-pct strong { font-size: 1.35rem; font-weight: 800; min-width: 56px; }
.proy-meta { display: flex; gap: 10px; flex-wrap: wrap; color: var(--tinta-2); font-size: .82rem; }
.bloq { background: var(--no-suave); color: #991b1b; border-radius: 10px; padding: 6px 10px; font-size: .82rem; }
.avance { flex: 1; height: 12px; background: #e9edf3; border-radius: 999px; overflow: hidden; }
.avance.chica { height: 7px; }
.avance-in { height: 100%; background: var(--c, var(--acc)); border-radius: 999px; transition: width .4s; }

/* ---------- Listas ---------- */
.lista { list-style: none; margin: 0; padding: 0; }
.lista li { display: flex; gap: 10px; align-items: center; padding: 10px 2px; border-bottom: 1px solid var(--borde); }
.lista li:last-child { border-bottom: 0; }
.lista .tx { flex: 1; min-width: 0; }
.lista .tx b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-weight: 600; overflow: hidden; }
.lista .tx small { color: var(--tinta-3); }
.vence { font-size: .78rem; font-weight: 700; border-radius: 8px; padding: 3px 8px; white-space: nowrap; background: #eef1f5; color: var(--tinta-2); }
.vence.tarde { background: var(--no-suave); color: #b91c1c; }
.vence.hoy { background: var(--av-suave); color: #92400e; }
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: .76rem; font-weight: 700; border-radius: 999px; padding: 2px 9px;
  background: color-mix(in srgb, var(--c) 14%, #fff); color: color-mix(in srgb, var(--c) 75%, #000); white-space: nowrap; }
.pill i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.prio { font-size: .72rem; font-weight: 800; border-radius: 6px; padding: 2px 6px; }
.prio-CRITICA { background: #fee2e2; color: #991b1b; } .prio-ALTA { background: #ffedd5; color: #9a3412; }
.prio-MEDIA { background: #e0f2fe; color: #075985; } .prio-BAJA { background: #f1f5f9; color: #475569; }

/* ---------- Mensajes ---------- */
.flash { border-radius: 12px; padding: 10px 14px; margin: 0 0 12px; font-weight: 600; }
.flash-ok { background: var(--ok-suave); color: #14532d; }
.flash-error { background: var(--no-suave); color: #7f1d1d; }

/* ---------- Pestañas ---------- */
.tabs { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 10px; margin-bottom: 6px; scrollbar-width: none; }
.tabs a { flex: none; text-decoration: none; color: var(--tinta-2); font-weight: 600; font-size: .9rem; padding: 8px 14px; border-radius: 999px;
  background: var(--tarj); border: 1px solid var(--borde); }
.tabs a.act { background: var(--tinta); color: #fff; border-color: var(--tinta); }

/* ---------- Formularios y tablas de configuración ---------- */
.form { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 12px; align-items: end; }
.form label, .campo { display: flex; flex-direction: column; gap: 4px; font-size: .82rem; font-weight: 600; color: var(--tinta-2); }
.form .ancho { grid-column: 1 / -1; }
input[type=text], input[type=email], input[type=number], input[type=password], input[type=tel], input[type=date], select, textarea {
  border: 1px solid var(--borde); border-radius: 10px; padding: 8px 10px; background: #fff; font-size: .92rem; width: 100%; min-width: 0; }
input[type=color] { width: 44px; height: 36px; border: 1px solid var(--borde); border-radius: 10px; padding: 2px; background: #fff; }
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid color-mix(in srgb, var(--acc) 40%, transparent); border-color: var(--acc); }
.chk { flex-direction: row !important; align-items: center; gap: 6px; font-weight: 600; }
.btn { border: 0; border-radius: 10px; padding: 9px 16px; font-weight: 700; background: var(--acc); color: #fff; text-decoration: none; display: inline-block; }
.btn-2 { background: #eef1f5; color: var(--tinta); }
.btn-no { background: var(--no-suave); color: #991b1b; }
.btn-chico { padding: 5px 10px; font-size: .82rem; border-radius: 8px; }
.tabla { width: 100%; border-collapse: collapse; font-size: .9rem; }
.tabla th { text-align: left; color: var(--tinta-3); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; padding: 6px 6px; border-bottom: 1px solid var(--borde); }
.tabla td { padding: 6px; border-bottom: 1px solid var(--borde); vertical-align: middle; }
.tabla td input[type=text], .tabla td select, .tabla td input[type=number] { padding: 6px 8px; }
.tabla .acc { white-space: nowrap; text-align: right; }
.tabla .hijo td:first-child { padding-left: 26px; }
.scroll-x { overflow-x: auto; }
.ayuda { color: var(--tinta-3); font-size: .85rem; margin: 0 0 12px; }
.grupo-tit { margin: 18px 0 8px; font-size: .95rem; display: flex; align-items: center; gap: 8px; }
.grupo-tit:first-child { margin-top: 0; }
.punto { width: 10px; height: 10px; border-radius: 50%; display: inline-block; background: var(--c); }
@media (max-width: 640px) {
  .tabla.resp thead { display: none; }
  .tabla.resp tr { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--borde); }
  .tabla.resp td { border: 0; padding: 2px 0; }
  .tabla.resp td[data-l]::before { content: attr(data-l); display: block; font-size: .72rem; color: var(--tinta-3); font-weight: 600; }
  .tabla.resp td.acc { grid-column: 1 / -1; text-align: left; }
}

@media (max-width: 520px) {
  .lista .pill { display: none; }
  .form.fila-cel { grid-template-columns: 1fr 1fr !important; }
  .form.fila-cel input[type=text] { grid-column: 1 / -1; }
}


/* ---------- Avisos ---------- */
.aviso { background: var(--av-suave); border: 1px solid #fcd9a0; color: #7a4b00; border-radius: 12px; padding: 10px 14px; margin-bottom: 12px; font-size: .92rem; }
.aviso.info { background: #eff6ff; border-color: #bfdbfe; color: #1e3a8a; }
.aviso.error { background: #fef2f2; border-color: #fecaca; color: #991b1b; }

/* ---------- Paso 34: ingreso, invitaciones, contraseña y perfil ---------- */
.ing { min-height: 100vh; display: flex; background: var(--fondo); }
.ing-izq { flex: 1 1 56%; position: relative; overflow: hidden; color: #fff; padding: 56px 64px; display: flex; flex-direction: column; justify-content: space-between;
  background: linear-gradient(130deg, #14161b 0%, #172554 55%, #2563EB 130%); }
.ing-izq::before, .ing-izq::after { content: ''; position: absolute; border-radius: 50%; background: rgba(255,255,255,.06); }
.ing-izq::before { right: -120px; top: -140px; width: 460px; height: 460px; }
.ing-izq::after { right: 80px; bottom: -200px; width: 380px; height: 380px; background: rgba(255,255,255,.05); }
.ing-marca, .acc-marca { display: flex; align-items: center; gap: 12px; position: relative; z-index: 1; }
.ing-marca b { font-size: 1.25rem; font-weight: 800; letter-spacing: -.01em; }
.ing-logo { width: 42px; height: 42px; border-radius: 12px; background: #2563EB; display: grid; place-items: center; box-shadow: 0 6px 18px rgba(37,99,235,.45); }
.ing-logo svg, .acc-marca .rg-logo svg { width: 22px; height: 22px; fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; }
.ing-txt { position: relative; z-index: 1; max-width: 520px; }
.ing-txt h1 { margin: 0; font-size: 2.4rem; line-height: 1.12; letter-spacing: -.02em; }
.ing-items { list-style: none; padding: 0; margin: 30px 0 0; display: flex; flex-direction: column; gap: 14px; color: #dbe4ff; }
.ing-items li { display: flex; gap: 12px; align-items: center; }
.ing-items i { width: 36px; height: 36px; border-radius: 10px; background: rgba(255,255,255,.1); display: grid; place-items: center; flex: none; }
.ing-items svg { width: 18px; height: 18px; fill: none; stroke: #c7d2fe; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ing-pie { position: relative; z-index: 1; color: #a5b4fc; }
.ing-der { flex: 1 1 44%; display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.ing-tarj, .acc-tarj { width: 100%; max-width: 400px; background: #fff; border-radius: 22px; padding: 34px 32px; box-shadow: 0 1px 2px rgba(16,24,40,.05), 0 18px 48px rgba(16,24,40,.12); }
.ing-tarj h2 { margin: 0; font-size: 1.5rem; letter-spacing: -.01em; }
.ing-tarj > .muted { margin: 4px 0 18px; }
.ing-form, .acc-form { display: flex; flex-direction: column; gap: 14px; }
.ing-form label, .acc-form label { display: flex; flex-direction: column; gap: 6px; font-size: .85rem; font-weight: 600; color: var(--tinta-2); }
.ing-form label small, .acc-form label small { font-weight: 500; color: var(--tinta-3); }
.ing-form input, .acc-form input { border: 1px solid #d5dae3; border-radius: 12px; padding: 12px 14px; font: inherit; font-size: 1rem; color: var(--tinta); background: #fff; width: 100%; box-sizing: border-box; }
.ing-form input:focus, .acc-form input:focus { outline: none; border: 2px solid #2563EB; padding: 11px 13px; }
.ing-clave { position: relative; display: block; }
.ing-clave input { padding-right: 46px; }
.ing-ver { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; background: none; color: var(--tinta-3); display: grid; place-items: center; }
.ing-ver svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ing-btn, .acc-btn { width: 100%; padding: 14px; font-size: 1.02rem; border-radius: 12px; box-shadow: 0 6px 16px rgba(37,99,235,.3); text-align: center; justify-content: center; }
.ing-err, .acc-err { background: #fdecec; color: #991b1b; border-radius: 12px; padding: 10px 12px; font-size: .9rem; font-weight: 600; }
.ing-chico, .acc-chico { margin: 10px 0 0; font-size: .82rem; color: var(--tinta-3); text-align: center; }
.ing-olvido { margin-top: 16px; font-size: .88rem; color: var(--tinta-2); }
.ing-olvido summary { cursor: pointer; color: #2563EB; font-weight: 600; text-align: center; list-style: none; }
.ing-olvido summary::-webkit-details-marker { display: none; }
.ing-olvido p { background: #f6f8fb; border-radius: 12px; padding: 10px 12px; margin: 10px 0 0; }
@media (max-width: 860px) {
  .ing { flex-direction: column; }
  .ing-izq { padding: 28px 22px; flex: none; }
  .ing-txt h1 { font-size: 1.5rem; }
  .ing-items, .ing-pie { display: none; }
  .ing-der { padding: 22px 16px 40px; align-items: flex-start; }
  .ing-tarj { padding: 26px 22px; }
}
.acc-pag { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 30px 16px;
  background: linear-gradient(160deg, #14161b 0%, #172554 45%, var(--fondo) 45.1%); }
.acc-marca { color: #fff; }
.acc-marca b { font-size: 1.15rem; font-weight: 800; }
.acc-marca .rg-logo { width: 38px; height: 38px; border-radius: 11px; }
.acc-tarj { max-width: 480px; }
.acc-tarj h1 { margin: 2px 0 6px; font-size: 1.45rem; letter-spacing: -.01em; }
.acc-de { margin: 0; font-size: .85rem; font-weight: 700; color: #2563EB; text-transform: uppercase; letter-spacing: .05em; }
.acc-tabs { display: grid; grid-template-columns: 1fr 1fr; background: #eef1f5; border-radius: 12px; padding: 4px; margin: 16px 0; }
.acc-tabs button { border: 0; background: none; padding: 9px; border-radius: 9px; font-weight: 700; color: var(--tinta-2); }
.acc-tabs button.act { background: #fff; color: var(--tinta); box-shadow: 0 1px 3px rgba(16,24,40,.1); }
.acc-dos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 480px) { .acc-dos { grid-template-columns: 1fr; } }
.perfil-cab { display: flex; align-items: center; gap: 14px; margin: 6px 0 14px; }
.perfil-cab h1 { margin: 0; font-size: 1.4rem; }
.perfil-cab p { margin: 2px 0 0; }
.perfil-ini { width: 56px; height: 56px; border-radius: 50%; background: var(--acc); color: #fff; font-weight: 800; font-size: 1.2rem; display: grid; place-items: center; flex: none; }
.perfil-grid { grid-template-columns: 1fr 1fr; }
@media (max-width: 760px) { .perfil-grid { grid-template-columns: 1fr; } }
.perfil-form { grid-template-columns: 1fr; }
a.barra-yo { text-decoration: none; }
a.barra-yo:hover { background: rgba(255,255,255,.16); }
.barra-nav a.solo-cel { display: none; }
@media (max-width: 760px) { .barra-nav a.solo-cel { display: block; } }

/* ---------- Paso 35: logo de la empresa (chiquito, siempre en su recuadro blanco) ---------- */
.logo-emp { display: inline-flex; align-items: center; justify-content: center; background: #fff; border-radius: 8px; padding: 3px 6px; height: 28px;
  box-shadow: 0 0 0 1px rgba(16,24,40,.08); flex: none; vertical-align: middle; }
.logo-emp img { max-height: 22px; max-width: 110px; object-fit: contain; display: block; }

/* ---------- Semáforo (paso 04) ---------- */
:root { --sem-verde: #16a34a; --sem-azul: #2563eb; --sem-ambar: #d97706; --sem-rojo: #dc2626; --sem-gris: #94a3b8; --sem-violeta: #8B5CF6; }

/* ---------- Paso 04b: identidad propia «Verde billete» (opción A elegida por Pablo) ----------
   Mismo armado que HelpDesk, pero en verde: barra y lado izquierdo del ingreso en verde muy oscuro,
   acento esmeralda. El color de cada espacio (espacios.color) sigue mandando en --acc. */
:root { --barra: #052e2b; --acc: #059669; }
.hola { background: linear-gradient(120deg, #052e2b 0%, color-mix(in srgb, var(--acc) 70%, #052e2b) 100%); }
.ing-izq { background: linear-gradient(140deg, #03201d 0%, #064e46 55%, #10b981 140%); }
.ing-logo { background: #10b981; box-shadow: 0 6px 18px rgba(16,185,129,.45); }
.ing-items { color: #d1fae5; }
.ing-items svg { stroke: #6ee7b7; }
.ing-pie { color: #6ee7b7; }
.ing { background: #eef5f2; }
.ing-btn, .acc-btn { background: #059669; box-shadow: 0 6px 16px rgba(5,150,105,.3); }
.ing-form input:focus, .acc-form input:focus { border-color: #059669; }
.ing-olvido summary, .acc-de { color: #059669; }

/* ---------- Paso 05: botón flotante y ventanitas (de HelpDesk paso 41) ---------- */
.fab { position: fixed; right: 22px; bottom: 22px; z-index: 40; display: inline-flex; align-items: center; gap: 8px; height: 58px; padding: 0 22px 0 18px;
  border: 0; border-radius: 999px; background: var(--acc); color: #fff; font-weight: 800; font-size: .95rem;
  box-shadow: 0 8px 24px rgba(5,150,105,.35), 0 2px 6px rgba(16,24,40,.2); transition: transform .15s, box-shadow .15s; }
.fab span { font-size: 1.7rem; line-height: 1; font-weight: 400; }
.fab em { font-style: normal; }
.fab:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 12px 30px rgba(5,150,105,.42), 0 2px 6px rgba(16,24,40,.2); }
@media (max-width: 600px) { .fab { width: 58px; padding: 0; justify-content: center; right: 16px; bottom: 16px; } .fab em { display: none; } }
body:has(.fab) .cont { padding-bottom: 90px; }
.app-dlg { border: 0; padding: 0; border-radius: 20px; width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 40px); box-shadow: 0 24px 70px rgba(16,24,40,.35); color: var(--tinta); }
.app-dlg::backdrop { background: rgba(16,24,40,.5); backdrop-filter: blur(2px); }
.app-dlg[open] { animation: dlg-in .18s ease-out; }
@keyframes dlg-in { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
.app-dlg > form { padding: 18px 20px 20px; display: grid; gap: 12px; }
.app-dlg .campo { display: flex; flex-direction: column; gap: 4px; font-size: .82rem; font-weight: 600; color: var(--tinta-2); }
.app-dlg .campo input, .app-dlg .campo textarea { border: 1px solid var(--borde); border-radius: 10px; padding: 9px 10px; font: inherit; font-size: .92rem; width: 100%; }
.dlg-cab { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tk-alta .dlg-cab, .tk-alta .dlg-pie { grid-column: 1 / -1; }
.dlg-cab h2 { margin: 0; font-size: 1.15rem; }
.dlg-x { border: 0; background: #eef1f5; width: 34px; height: 34px; border-radius: 50%; font-size: .95rem; color: var(--tinta-2); }
.dlg-pie { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
.dlg-tk { margin: -4px 0 0; color: var(--tinta-2); font-weight: 600; }
@media (max-width: 600px) {
  .app-dlg { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 20px 20px 0 0; max-height: 92vh; }
  .app-dlg[open] { animation: dlg-sube .2s ease-out; }
  @keyframes dlg-sube { from { transform: translateY(40px); opacity: .4; } to { transform: none; opacity: 1; } }
  .app-dlg .tk-alta { grid-template-columns: 1fr; }
  .dlg-pie .btn { flex: 1; }
}
.btn-ok { background: #16a34a; color: #fff; }
.btn-wa { background: #25d366; color: #fff; }

/* ---------- Paso 05: bloques con franja de color (de HelpDesk paso 07) ---------- */
.tarj.bloque { border-top: 4px solid var(--c); }
.tarj.bloque h3 { display: flex; align-items: center; gap: 8px; }
.tarj.bloque .ico { font-style: normal; width: 26px; height: 26px; border-radius: 8px; display: inline-grid; place-items: center; font-size: .85rem;
  background: color-mix(in srgb, var(--c) 14%, #fff); color: var(--c); flex: none; }
.tarj.bloque.compacto { padding-top: 12px; padding-bottom: 12px; }

/* ---------- Paso 05: Clientes del sistema ---------- */
.rojo { color: #b91c1c; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .92em; }
.dlg-dos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 600px) { .dlg-dos { grid-template-columns: 1fr; } }
.app-dlg .campo small { font-weight: 500; }
.acceso { margin-bottom: 14px; }
.acc-datos { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 4px 0 14px; background: #f0fdf7; border: 1px solid #bbf0d6; border-radius: 12px; padding: 12px 14px; }
.acc-datos dt { color: var(--tinta-2); font-size: .82rem; font-weight: 700; align-self: center; }
.acc-datos dd { margin: 0; word-break: break-all; }
.acc-datos .clave { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 1.15rem; letter-spacing: .12em; color: #065f46; }
.acc-btns { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 600px) { .acc-btns .btn { flex: 1; text-align: center; } }
.sis-lista { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
@media (max-width: 400px) { .sis-lista { grid-template-columns: 1fr; } }
.sis { border-top: 4px solid var(--c, var(--acc)); display: flex; flex-direction: column; gap: 10px; }
.sis.pausa { border-top-color: var(--sem-violeta); opacity: .85; }
.sis-cab { display: flex; align-items: center; gap: 10px; }
.sis-ini { width: 42px; height: 42px; font-size: .95rem; background: var(--c, var(--acc)); }
.sis-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sis-tx b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sis-tx small { color: var(--tinta-3); }
.p-ok { background: var(--ok-suave); color: #15803d; }
.p-pausa { background: #f3effe; color: #6d28d9; }
.sis-num { display: flex; flex-wrap: wrap; gap: 6px 14px; color: var(--tinta-2); font-size: .86rem; }
.sis-num b { color: var(--tinta); }
.sis .ayuda { margin: 0; }
.sis-acc { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--borde); }
.sis-acc form { display: contents; }
