/* Plataforma de reclutamiento · tokens
   Layout: barra superior fija + navegación por pestañas + vistas de una columna que crecen a rejilla en escritorio. */
:root {
  --brand: #0A8A9E;        /* turquesa Vayam */
  --brand-ink: #056271;
  --brand-soft: #DDF2F4;
  --accent: #D9661A;       /* naranja Vayam */
  --accent-soft: #FBE7D8;
  --bg: #F4F6F6;
  --surface: #FFFFFF;
  --surface-2: #EEF2F2;
  --line: #D6DEDF;
  --ink: #15232A;
  --ink-2: #4A5B63;
  --ink-3: #7B8B92;
  --good: #1E8E4E;
  --good-soft: #DDF3E5;
  --warn: #B7770A;
  --warn-soft: #FBEFD1;
  --bad: #C0392B;
  --bad-soft: #F9DEDA;
  --chart-lab: #0A8A9E;
  --chart-ti: #D9661A;
  --font-display: "Sora", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --font-body: "Manrope", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(21,35,42,.06), 0 4px 16px rgba(21,35,42,.06);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #1FA3B4; --brand-ink: #7FD6E0; --brand-soft: #0F3A41;
    --accent: #D96F22; --accent-soft: #46290F;
    --bg: #121819; --surface: #1A2224; --surface-2: #222C2F; --line: #303D41;
    --ink: #ECF1F2; --ink-2: #B5C2C6; --ink-3: #85959A;
    --good: #4CC278; --good-soft: #163B25; --warn: #E2A93A; --warn-soft: #3F2F0E; --bad: #E86C5E; --bad-soft: #44201C;
    --chart-lab: #1FA3B4; --chart-ti: #D96F22;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 4px 16px rgba(0,0,0,.35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --brand: #1FA3B4; --brand-ink: #7FD6E0; --brand-soft: #0F3A41;
  --accent: #D96F22; --accent-soft: #46290F;
  --bg: #121819; --surface: #1A2224; --surface-2: #222C2F; --line: #303D41;
  --ink: #ECF1F2; --ink-2: #B5C2C6; --ink-3: #85959A;
  --good: #4CC278; --good-soft: #163B25; --warn: #E2A93A; --warn-soft: #3F2F0E; --bad: #E86C5E; --bad-soft: #44201C;
  --chart-lab: #1FA3B4; --chart-ti: #D96F22;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 4px 16px rgba(0,0,0,.35);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font-body); font-size: 15px; line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { font-family: var(--font-display); margin: 0; text-wrap: balance; letter-spacing: -.01em; }
h1 { font-size: 1.15rem; font-weight: 700; }
h2 { font-size: 1.25rem; font-weight: 700; }
h3 { font-size: 1rem; font-weight: 700; }
p { margin: 0; }
a { color: var(--brand-ink); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-3); }
.small { font-size: .85rem; }
.hidden { display: none !important; }

/* ---------- Barra superior ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line);
  padding: 10px 16px; display: flex; align-items: center; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-mark {
  width: 36px; height: 36px; border-radius: 9px; background: var(--brand); color: #fff; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 800; font-size: 1rem; flex: none; position: relative; overflow: hidden;
}
.brand-mark::after { content: ""; position: absolute; right: -8px; bottom: -8px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent); }
.brand-text { min-width: 0; }
.brand-text h1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-text .small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 8px; flex: none; }
.role-pill { font-size: .78rem; padding: 4px 10px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); white-space: nowrap; cursor: pointer; max-width: 46vw; overflow: hidden; text-overflow: ellipsis; }
.role-pill:hover { filter: brightness(.96); }
.role-pill.admin { background: var(--brand-soft); color: var(--brand-ink); border-color: transparent; }
.role-pill.rh { background: var(--accent-soft); color: var(--accent); border-color: transparent; }

/* ---------- Navegación ---------- */
.nav {
  position: sticky; top: 57px; z-index: 19; background: var(--surface); border-bottom: 1px solid var(--line);
  display: flex; gap: 2px; overflow-x: auto; padding: 0 8px; scrollbar-width: none;
}
.nav::-webkit-scrollbar { display: none; }
.nav button {
  background: none; border: 0; border-bottom: 3px solid transparent; padding: 10px 12px; color: var(--ink-2);
  font-weight: 600; font-size: .9rem; white-space: nowrap; display: flex; align-items: center; gap: 6px;
}
.nav button[aria-current="page"] { color: var(--brand-ink); border-bottom-color: var(--brand); }
.nav .badge { background: var(--bad); color: #fff; font-size: .7rem; padding: 1px 6px; border-radius: 999px; }

/* ---------- Avisos ---------- */
.banner { padding: 10px 16px; font-size: .9rem; display: flex; gap: 10px; align-items: center; border-bottom: 1px solid var(--line); }
.banner.info { background: var(--brand-soft); color: var(--brand-ink); }
.banner.warn { background: var(--warn-soft); color: var(--warn); }
.banner.bad { background: var(--bad-soft); color: var(--bad); }
.banner button { margin-left: auto; background: none; border: 1px solid currentColor; border-radius: 6px; padding: 3px 8px; font-size: .8rem; }

/* ---------- Contenido ---------- */
main { padding: 16px; max-width: 1280px; margin: 0 auto; }
.view { display: none; }
.view.active { display: block; }
.view-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 14px; }
.view-head .spacer { flex: 1; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.toolbar > * { flex: 1 1 140px; }
.toolbar > .btn { flex: 0 0 auto; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; }
.card + .card { margin-top: 12px; }
.card h3 { margin-bottom: 8px; }
.grid { display: grid; gap: 12px; }
.grid.cols-2 { grid-template-columns: 1fr; }
.grid.cols-3 { grid-template-columns: 1fr; }
.grid.cols-4 { grid-template-columns: 1fr 1fr; }
@media (min-width: 760px) {
  .grid.cols-2 { grid-template-columns: 1fr 1fr; }
  .grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
  .grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
}

/* Tiles */
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.tile .label { font-size: .78rem; color: var(--ink-3); text-transform: uppercase; letter-spacing: .04em; font-weight: 700; }
.tile .value { font-family: var(--font-display); font-size: 1.9rem; font-weight: 700; line-height: 1.1; margin-top: 4px; }
.tile .sub { font-size: .82rem; color: var(--ink-2); margin-top: 2px; }
.tile.stripe-good { border-left: 4px solid var(--good); }
.tile.stripe-warn { border-left: 4px solid var(--warn); }
.tile.stripe-bad { border-left: 4px solid var(--bad); }
.tile.stripe-brand { border-left: 4px solid var(--brand); }
.meter { height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; margin-top: 8px; }
.meter > span { display: block; height: 100%; background: var(--brand); border-radius: 999px; }
.meter.over > span { background: var(--bad); }

/* Botones */
.btn { border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 8px; padding: 8px 12px; font-weight: 600; font-size: .9rem; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.btn:hover { background: var(--surface-2); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-ink); }
.btn.accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.danger { color: var(--bad); border-color: var(--bad); }
.btn.sm { padding: 5px 9px; font-size: .8rem; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* Formularios */
.field { display: flex; flex-direction: column; gap: 4px; }
.field label { font-size: .8rem; font-weight: 700; color: var(--ink-2); }
input[type="text"], input[type="tel"], input[type="date"], input[type="number"], input[type="datetime-local"], input[type="search"], select, textarea {
  width: 100%; border: 1px solid var(--line); background: var(--surface); border-radius: 8px; padding: 8px 10px; min-height: 38px;
}
textarea { min-height: 70px; resize: vertical; }
input:disabled, select:disabled, textarea:disabled { background: var(--surface-2); color: var(--ink-3); }
.form-grid { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 520px) { .form-grid { grid-template-columns: 1fr; } .form-grid .full { grid-column: auto; } }
.check { display: flex; align-items: center; gap: 8px; font-size: .9rem; padding: 6px 0; }
.check input { width: 18px; height: 18px; accent-color: var(--brand); }
.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 12px; }

/* Chips */
.chip { display: inline-flex; align-items: center; gap: 4px; font-size: .75rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); white-space: nowrap; }
.chip.lab { background: var(--brand-soft); color: var(--brand-ink); }
.chip.ti { background: var(--accent-soft); color: var(--accent); }
.chip.ger { background: var(--surface-2); color: var(--ink); border: 1px solid var(--line); }
.chip.good { background: var(--good-soft); color: var(--good); }
.chip.warn { background: var(--warn-soft); color: var(--warn); }
.chip.bad { background: var(--bad-soft); color: var(--bad); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }

/* Tablas */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: 9px 10px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; white-space: nowrap; }
th { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-3); background: var(--surface-2); position: sticky; top: 0; }
tr:last-child td { border-bottom: 0; }
tr.clickable { cursor: pointer; }
tr.clickable:hover td { background: var(--surface-2); }
td.right, th.right { text-align: right; }
td.wrap { white-space: normal; min-width: 180px; }
.empty { padding: 28px 16px; text-align: center; color: var(--ink-3); }
.empty strong { display: block; color: var(--ink-2); margin-bottom: 4px; }

/* Pipeline */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 1fr); gap: 10px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x proximity; }
.kcol { background: var(--surface-2); border-radius: var(--radius); padding: 8px; min-height: 160px; scroll-snap-align: start; border: 1px solid var(--line); }
.kcol-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 6px 8px; font-weight: 700; font-size: .85rem; }
.kcol-head .count { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 0 8px; font-size: .78rem; }
.kcard { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; margin-bottom: 8px; box-shadow: var(--shadow); }
.kcard .name { font-weight: 700; font-size: .9rem; cursor: pointer; }
.kcard .meta { display: flex; gap: 6px; flex-wrap: wrap; margin: 4px 0 6px; font-size: .78rem; color: var(--ink-2); align-items: center; }
.kcard select { min-height: 30px; padding: 3px 6px; font-size: .8rem; }

/* Gráfica */
.chart { width: 100%; height: auto; display: block; }
.chart text { font-family: var(--font-body); font-size: 11px; fill: var(--ink-2); }
.chart .grid line { stroke: var(--line); stroke-width: 1; }
.chart .axis text { fill: var(--ink-3); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .82rem; color: var(--ink-2); margin-bottom: 6px; }
.legend .sw { width: 12px; height: 12px; border-radius: 3px; display: inline-block; margin-right: 6px; vertical-align: -2px; }
.tip { position: fixed; z-index: 40; pointer-events: none; background: var(--ink); color: var(--bg); padding: 6px 9px; border-radius: 6px; font-size: .8rem; display: none; }

/* Modal */
.modal-bg { position: fixed; inset: 0; background: rgba(10,20,24,.5); z-index: 50; display: none; align-items: flex-end; justify-content: center; }
.modal-bg.open { display: flex; }
.modal { background: var(--surface); width: 100%; max-width: 720px; max-height: 92vh; overflow: auto; border-radius: 16px 16px 0 0; padding: 16px; }
@media (min-width: 760px) { .modal-bg { align-items: center; } .modal { border-radius: 14px; } }
.modal-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.modal-head h2 { flex: 1; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 12px; overflow-x: auto; }
.tabs button { background: none; border: 0; border-bottom: 2px solid transparent; padding: 8px 10px; font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.tabs button.on { color: var(--brand-ink); border-bottom-color: var(--brand); }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { padding: 6px 0 6px 14px; border-left: 2px solid var(--line); position: relative; font-size: .88rem; }
.timeline li::before { content: ""; position: absolute; left: -5px; top: 11px; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }

/* Asistente */
.chat { display: flex; flex-direction: column; gap: 10px; min-height: 300px; max-height: 55vh; overflow: auto; padding: 4px 2px; }
.msg { max-width: 92%; padding: 10px 12px; border-radius: 12px; font-size: .92rem; white-space: pre-wrap; }
.msg.user { align-self: flex-end; background: var(--brand); color: #fff; border-bottom-right-radius: 4px; }
.msg.ai { align-self: flex-start; background: var(--surface-2); border-bottom-left-radius: 4px; }
.chat-input { display: flex; gap: 8px; margin-top: 10px; }
.chat-input input { flex: 1; }
.suggest { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.suggest button { font-size: .8rem; }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 8px; font-size: .9rem; z-index: 60; opacity: 0; transition: opacity .2s; pointer-events: none; max-width: 90vw; }
.toast.show { opacity: 1; }

/* Semáforo contratos */
.sem { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: .85rem; }
.sem .dot { width: 10px; height: 10px; }

/* Dropzone */
.drop { border: 2px dashed var(--line); border-radius: var(--radius); padding: 20px; text-align: center; color: var(--ink-2); background: var(--surface); }
.drop.over { border-color: var(--brand); background: var(--brand-soft); }
.map-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 520px) { .map-grid { grid-template-columns: 1fr; } }
code { background: var(--surface-2); padding: 1px 5px; border-radius: 4px; font-size: .85em; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 4px 10px; font-size: .9rem; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Buscador global ---------- */
.buscar-btn { font-size: .95rem; line-height: 1; padding: 6px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); cursor: pointer; }
.buscar-btn:hover { filter: brightness(.96); }
.buscar-bg { position: fixed; inset: 0; background: rgba(0,0,0,.45); display: none; z-index: 60; padding: 10vh 14px 14px; }
.buscar-bg.open { display: flex; justify-content: center; align-items: flex-start; }
.buscar-panel { width: 100%; max-width: 640px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 18px 50px rgba(0,0,0,.28); overflow: hidden; display: flex; flex-direction: column; max-height: 76vh; }
.buscar-head { display: flex; gap: 8px; padding: 12px 14px 8px; align-items: center; }
.buscar-head input { flex: 1; font-size: 1rem; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); }
.buscar-head input:focus { outline: 2px solid var(--brand); border-color: transparent; }
.buscar-res { overflow: auto; padding: 0 8px 10px; }
.bres { display: flex; flex-direction: column; gap: 4px; padding: 10px 8px; border-radius: 12px; border-bottom: 1px solid var(--line); }
.bres:hover { background: var(--surface-2); }
.bres-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.bres-top a { font-weight: 700; color: var(--ink); text-decoration: none; }
.bres-top a:hover { color: var(--brand); }
.bres-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.bres-act { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }
.bres .motivo { color: var(--bad, #c0392b); font-size: .78rem; }
.bres input.qmot { flex: 1; min-width: 150px; padding: 7px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font-size: .85rem; }
@media (max-width: 480px) { .buscar-bg { padding-top: 6vh; } }

/* ---------- Directorio ---------- */
.dir-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 12px; }
.dir-grid .card + .card { margin-top: 0; }
.dir-head { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.dir-head strong { font-size: 1rem; margin-right: auto; }
.dir-resumen { margin: 4px 0 10px; }
.dir-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 7px 0; border-top: 1px solid var(--line); }
.dir-row a[data-open] { color: var(--ink); font-weight: 600; text-decoration: none; }
.dir-row a[data-open]:hover { color: var(--brand); }
.dir-cta { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }
.dir-tel { font-variant-numeric: tabular-nums; color: var(--ink-2); text-decoration: none; font-size: .82rem; }
.dir-wa { font-size: .75rem; font-weight: 700; color: #fff; background: #1faa59; padding: 3px 9px; border-radius: 999px; text-decoration: none; }
.dir-wa:hover { filter: brightness(.95); }
@media (max-width: 560px) { .dir-row { flex-direction: column; align-items: flex-start; gap: 4px; } }
.pla-det td { background: var(--surface-2); padding: 10px 12px; }
.pla-lista { display: flex; flex-direction: column; gap: 6px; }
.pla-item { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 4px 0; border-bottom: 1px dashed var(--line); }
.pla-item a { color: var(--ink); font-weight: 600; text-decoration: none; }
.pla-item a:hover { color: var(--brand); }

/* ---------- Credenciales ---------- */
.cred-area { display: flex; flex-wrap: wrap; gap: 14px; }
.cred-wrap { position: relative; }
.cred-quitar { position: absolute; top: -8px; right: -8px; z-index: 2; width: 24px; height: 24px; border-radius: 50%; border: none; background: var(--bad, #c0392b); color: #fff; font-weight: 700; cursor: pointer; }
.cred { display: flex; gap: 12px; flex-wrap: wrap; }
.cred-cara { width: 216px; height: 342px; border-radius: 10px; overflow: hidden; background: #fff; color: #1C2B2E; border: 1px solid #D8E2E3; box-shadow: 0 6px 18px rgba(10,60,70,.12); display: flex; flex-direction: column; position: relative; }
.crv-logo { width: 118px; display: block; margin: 11px auto 3px; }
.crv-marca { text-align: center; color: #CF894D; font-weight: 700; letter-spacing: .2em; font-size: .8rem; margin-bottom: 7px; }
.crv-div { height: 4.5px; background: linear-gradient(90deg, #CF894D 0 25%, #2AA7A0 25% 100%); }
.crv-foto { width: 100%; height: 124px; background: #E8EFEF; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #9FB4B6; }
.crv-foto span { font-size: 2.6rem; font-weight: 800; color: #B9CBCD; }
.crv-foto small { font-size: .55rem; letter-spacing: .1em; font-weight: 700; }
.crv-nombre { text-align: center; font-weight: 800; font-size: .95rem; line-height: 1.2; padding: 9px 10px 2px; }
.crv-puesto { text-align: center; color: #237F79; font-weight: 800; font-size: .6rem; letter-spacing: .04em; text-transform: uppercase; padding: 2px 8px; }
.crv-estado { text-align: center; color: #7A8A8D; font-size: .62rem; padding-top: 2px; }
.crv-barra { margin-top: auto; background: #237F79; color: #fff; display: flex; justify-content: space-between; align-items: center; padding: 7px 10px; font-size: .6rem; font-weight: 700; font-family: ui-monospace, Menlo, monospace; }
.cred-reverso { background: #fff; }
.crv-top { height: 9px; background: #237F79; }
.crv-cuerpo { padding: 12px 14px 0; flex: 1; display: flex; flex-direction: column; }
.crv-tag { color: #237F79; font-size: .58rem; font-weight: 800; letter-spacing: .06em; }
.crv-prog { font-weight: 800; font-size: .8rem; margin: 3px 0 8px; }
.crv-hr { border: none; border-top: 1px solid #E3EAEA; margin: 0 0 8px; }
.crv-rh { font-weight: 700; font-size: .68rem; margin-top: 2px; }
.crv-vig { font-weight: 700; font-size: .82rem; font-family: ui-monospace, Menlo, monospace; margin-top: 2px; }
.crv-ley { font-size: .55rem; line-height: 1.5; color: #777; margin-top: 8px; }
.crv-firma { text-align: center; margin-top: 9px; }
.crv-firma span { display: block; width: 100px; height: 4px; background: #3A3A3A; margin: 0 auto 4px; }
.crv-firma small { font-size: .55rem; color: #777; }
.crv-banda { margin-top: auto; border-top: 3px solid #CF894D; background: #237F79; text-align: center; padding: 8px 0 6px; }
.crv-banda img { width: 88px; display: block; margin: 0 auto 3px; }
.crv-bmarca { color: #fff; font-size: .58rem; letter-spacing: .24em; font-weight: 600; }

@media print {
  body.print-cred * { visibility: hidden !important; }
  body.print-cred .cred-area, body.print-cred .cred-area * { visibility: visible !important; }
  body.print-cred .cred-area { position: absolute; left: 0; top: 0; width: 100%; display: flex; flex-wrap: wrap; gap: 6mm; padding: 8mm; }
  body.print-cred .cred-cara { width: 54mm; height: 85.6mm; box-shadow: none; border: 1px solid #bbb; border-radius: 3mm; page-break-inside: avoid; }
  body.print-cred .cred { page-break-inside: avoid; }
  body.print-cred .cred-quitar { display: none !important; }
}


/* ---------- Logo Vayam ---------- */
.brand-logo { background: transparent !important; width: auto !important; height: 30px; padding: 0 2px; display: flex !important; align-items: center; border-radius: 0 !important; overflow: visible !important; }
.brand-logo::after { display: none !important; }
.brand-logo svg { height: 26px; width: auto; display: block; }
.brand-logo img { height: 26px; width: auto; display: block; }
.hero-bienvenida { background: linear-gradient(115deg, #0A8A9E, #0C9DB4 55%, #D9661A 160%); color: #fff; border-radius: 16px; padding: 16px 18px; margin-bottom: 14px; }
.hero-bienvenida h3 { font-size: 1.05rem; margin-bottom: 2px; }
.hero-bienvenida .small { opacity: .92; }
.hero-pend { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.hero-pend .hp { background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.3); border-radius: 999px; padding: 4px 12px; font-size: .78rem; font-weight: 700; }
.hero-pend .hp.alerta { background: rgba(140,30,20,.35); }
@media (max-width: 600px) { .brand-logo + .brand-text h1 { display: none; } .brand-logo + .brand-text .small { max-width: 90px; } }

/* ================= PULIDO EJECUTIVO v2.9 ================= */
.topbar { backdrop-filter: saturate(1.3) blur(8px); border-bottom: 1px solid var(--line); }
.card { border-radius: 14px; box-shadow: 0 1px 3px rgba(13,42,48,.07); transition: box-shadow .18s ease; }
.card:hover { box-shadow: 0 4px 14px rgba(13,42,48,.1); }
.tile .num, .tile strong { letter-spacing: -.02em; }
.btn { transition: transform .12s ease, box-shadow .12s ease; }
.btn:active { transform: scale(.97); }
.nav button[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--brand); font-weight: 800; }
table tbody tr { transition: background .12s; }
table tbody tr:hover { background: rgba(31,181,176,.06); }

/* Campanita */
.alert-badge { position: absolute; top: -4px; right: -4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: #E07B39; color: #fff; font-size: .62rem; font-weight: 800; display: flex; align-items: center; justify-content: center; border: 2px solid var(--bg, #fff); }
.alert-badge.crit { background: #D64545; animation: pulso 2s infinite; }
@keyframes pulso { 0%,100% { transform: scale(1); } 50% { transform: scale(1.18); } }
#btnAlertas { position: relative; }
.alert-panel { position: fixed; top: 58px; right: 10px; z-index: 300; width: min(380px, calc(100vw - 20px)); background: var(--card, #fff); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 14px 40px rgba(10,40,48,.25); overflow: hidden; }
.alert-panel.hidden { display: none; }
.ap-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.ap-item { display: grid; grid-template-columns: 28px 1fr 14px; gap: 8px; align-items: center; width: 100%; text-align: left; padding: 11px 14px; border: none; background: none; cursor: pointer; font-size: .82rem; color: inherit; border-bottom: 1px solid var(--line); }
.ap-item:last-child { border-bottom: none; }
.ap-item:hover { background: rgba(31,181,176,.08); }
.ap-item.crit { box-shadow: inset 3px 0 0 #D64545; }
.ap-ic { font-size: 1.05rem; }
.ap-arrow { color: var(--muted); font-size: 1.1rem; }
.ap-empty { padding: 20px 14px; text-align: center; font-size: .85rem; color: var(--muted); }

/* Accesos directos */
.accesos-card { margin-bottom: 14px; }
.acc-head { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 4px; margin-bottom: 10px; }
.accesos { display: grid; grid-template-columns: repeat(auto-fill, minmax(225px, 1fr)); gap: 10px; }
.acc { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; background: var(--bg2, rgba(31,181,176,.04)); }
.acc-ic { font-size: 1.45rem; line-height: 1.2; }
.acc-t { font-weight: 800; font-size: .83rem; }
.acc-d { line-height: 1.3; margin: 1px 0 7px; }
.acc-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.acc-btn { font-size: .68rem; font-weight: 800; padding: 4px 9px; border-radius: 999px; border: 1px solid var(--brand); color: var(--brand-ink, #0A6A66); background: none; cursor: pointer; text-decoration: none; display: inline-block; }
.acc-btn:hover { background: var(--brand); color: #fff; }
.acc-btn.wa { border-color: #25D366; color: #128C4A; }
.acc-btn.wa:hover { background: #25D366; color: #fff; }
.hp.sync { opacity: .92; }
.crv-bc { width: 168px; height: 19px; display: block; margin: auto auto 5px; }

/* ============ RECLUTIA · Login y pie ============ */
.rc-login { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(1200px 700px at 20% -10%, #123a46 0%, #0b2730 45%, #081d24 100%); padding: 20px; }
.rc-login-card { width: 100%; max-width: 380px; background: var(--surface, #fff); border-radius: 18px;
  padding: 34px 30px 24px; box-shadow: 0 24px 70px rgba(0,0,0,.45); text-align: center;
  font-family: "Manrope", system-ui, sans-serif; animation: rcIn .35s ease; }
@keyframes rcIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.rc-login-logo { width: 58px; height: 58px; margin: 0 auto 12px; border-radius: 16px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--brand, #0A8A9E), #056271); color: #fff; font: 800 30px/1 "Sora", sans-serif; letter-spacing: -1px;
  box-shadow: 0 8px 22px rgba(10,138,158,.35); }
.rc-login-card h1 { font: 800 26px/1.2 "Sora", sans-serif; color: var(--ink, #15232A); margin: 0; letter-spacing: -.5px; }
.rc-login-sub { color: var(--ink-3, #7B8B92); font-size: 13px; margin: 4px 0 20px; }
.rc-login-card form { text-align: left; display: flex; flex-direction: column; gap: 6px; }
.rc-login-card label { font-size: 12px; font-weight: 700; color: var(--ink-2, #4A5B63); margin-top: 6px; }
.rc-login-card input { width: 100%; padding: 11px 12px; border: 1.5px solid var(--line, #D6DEDF); border-radius: 10px;
  font: 500 15px "Manrope", sans-serif; background: var(--surface, #fff); color: var(--ink, #15232A); }
.rc-login-card input:focus { outline: none; border-color: var(--brand, #0A8A9E); box-shadow: 0 0 0 3px rgba(10,138,158,.15); }
.rc-login-card button[type="submit"] { margin-top: 14px; padding: 12px; border: 0; border-radius: 10px; cursor: pointer;
  background: linear-gradient(135deg, var(--brand, #0A8A9E), #056271); color: #fff; font: 700 15px "Manrope", sans-serif;
  box-shadow: 0 6px 16px rgba(10,138,158,.3); transition: transform .12s ease; }
.rc-login-card button[type="submit"]:active { transform: scale(.98); }
.rc-login-msg { min-height: 18px; font-size: 12.5px; margin-top: 8px; text-align: center; color: #6b7280; }
.rc-login-foot { margin-top: 18px; font-size: 11.5px; color: var(--ink-3, #7B8B92); }
.rc-login-foot a { color: var(--brand, #0A8A9E); }
.rc-foot { text-align: center; padding: 22px 10px 30px; font-size: 12px; color: var(--ink-3, #7B8B92); }
.rc-foot a { color: var(--brand, #0A8A9E); text-decoration: none; }
