:root {
  --navy: #12233d; --navy2: #1d3557; --sky: #8fd3f0; --orange: #f07c22; --orange-d: #c95f0e;
  --bg: #f4f6f9; --card: #fff; --ink: #1b2633; --ink2: #3c4a5c; --mute: #6b7787; --line: #e2e7ee; --line2: #eef1f5;
  --ok: #2a9d6f; --warn: #c98a12; --alert: #d93f3f; --info: #2f6fdf;
  --r: 14px; --shadow: 0 1px 2px rgba(18,35,61,.06), 0 6px 24px rgba(18,35,61,.06);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink); background: var(--bg); line-height: 1.45;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); }
main { flex: 1; }
.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }
main.wrap.wide { width: min(1600px, 100% - 32px); }
h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 .4em; letter-spacing: -.01em; }
h2 { font-size: 1.45rem; } h3 { font-size: 1.05rem; } h4 { font-size: .86rem; text-transform: uppercase; letter-spacing: .05em; color: var(--mute); margin-top: 1em; }
p { margin: 0 0 .7em; }
a { color: var(--navy2); }
.muted { color: var(--mute); } .small { font-size: .82rem; } .grow { flex: 1; }
.err { color: var(--alert); font-weight: 600; } .warn { color: var(--warn); }
[hidden] { display: none !important; }

/* Cabecera */
.top { background: var(--navy); color: #fff; position: sticky; top: 0; z-index: 20; }
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand span { display: flex; flex-direction: column; line-height: 1.1; } .brand small { color: var(--sky); font-size: .75rem; }
.who { display: flex; align-items: center; gap: 10px; font-size: .88rem; }
.who small { display: block; color: #b8c6d8; font-size: .75rem; }
.avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .8rem; color: #fff; }
.badge { background: var(--orange); color: #fff; padding: 3px 10px; border-radius: 99px; font-weight: 800; font-size: .78rem; }
.top .btn.ghost { color: #fff; border-color: rgba(255,255,255,.3); }
.foot { color: var(--mute); font-size: .8rem; padding: 22px 0; }

/* Botones y controles */
.btn { font: inherit; font-weight: 650; border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 10px; padding: 9px 16px; cursor: pointer; transition: .15s; }
.btn:hover { border-color: var(--navy2); } .btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--orange); border-color: var(--orange); color: #fff; } .btn.primary:hover { background: var(--orange-d); }
.btn.ghost { background: transparent; } .btn.small { padding: 5px 10px; font-size: .82rem; } .btn.big { padding: 13px 26px; font-size: 1.05rem; }
.btn.danger { color: var(--alert); border-color: #f1c4c4; } .btn.danger:hover { background: var(--alert); color: #fff; }
.icon { font: inherit; border: 1px solid var(--line); background: #fff; border-radius: 8px; width: 32px; height: 32px; cursor: pointer; display: inline-grid; place-items: center; color: var(--ink2); }
.icon:hover { border-color: var(--navy2); color: var(--navy); } .icon:disabled { opacity: .35; }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 2px; }
input, select, textarea { font: inherit; border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; background: #fff; color: var(--ink); width: 100%; }
input:focus, select:focus, textarea:focus { border-color: var(--navy2); outline: none; box-shadow: 0 0 0 3px rgba(143,211,240,.45); }
input[type=checkbox], input[type=radio] { width: auto; accent-color: var(--orange); }
input[type=range] { padding: 0; accent-color: var(--orange); }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: #fff; flex-wrap: nowrap; }
.seg.wrap { flex-wrap: wrap; border: 0; gap: 6px; overflow: visible; background: none; }
.seg button, .seg label span { font: inherit; font-size: .86rem; border: 0; background: none; padding: 7px 12px; cursor: pointer; color: var(--ink2); white-space: nowrap; }
.seg > button + button { border-left: 1px solid var(--line); }
.seg.wrap button, .seg.wrap label span { border: 1px solid var(--line); border-radius: 99px; background: #fff; display: inline-block; }
.seg button[aria-pressed=true], .seg label input:checked + span { background: var(--navy); color: #fff; border-color: var(--navy); }
.seg label input { position: absolute; opacity: 0; pointer-events: none; }
.seg label { position: relative; }
.seg.mini button { padding: 5px 9px; font-size: .8rem; }
.seg button:disabled { opacity: .35; cursor: not-allowed; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-size: .86rem; cursor: pointer; white-space: nowrap; }
.ctl { display: inline-flex; align-items: center; gap: 6px; font-size: .82rem; color: var(--mute); white-space: nowrap; }
.ctl select { width: auto; padding: 6px 8px; font-size: .85rem; color: var(--ink); }
.tag { display: inline-block; background: #eef3fb; color: var(--navy2); border-radius: 99px; padding: 2px 8px; font-size: .74rem; font-weight: 650; margin: 2px 4px 2px 0; }
.tag.light { background: #f2f4f7; color: var(--mute); margin-left: 6px; }

/* Tarjetas y portada */
.card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); padding: 24px; margin: 18px 0; }
.hero { padding: 38px 0 8px; }
.hero h1 { font-size: clamp(1.9rem, 4.5vw, 3rem); font-weight: 850; color: var(--navy); }
.hero p { font-size: 1.08rem; color: var(--ink2); max-width: 720px; }
.eyebrow { text-transform: uppercase; letter-spacing: .09em; font-size: .74rem; font-weight: 800; color: var(--orange-d); margin: 0 0 6px; }

/* Acceso */
.login { max-width: 760px; } .login.narrow { max-width: 420px; margin: 60px auto; }
.field { display: flex; flex-direction: column; gap: 5px; font-size: .86rem; font-weight: 650; color: var(--ink2); margin-bottom: 14px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.radios { border: 0; padding: 0; margin: 4px 0 14px; } .radios legend { font-size: .86rem; font-weight: 650; color: var(--ink2); margin-bottom: 6px; padding: 0; }
.privacy { background: var(--line2); border-radius: 10px; padding: 10px 14px; margin: 8px 0 12px; font-size: .88rem; } .privacy summary { cursor: pointer; font-weight: 650; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 10px 0 16px; cursor: pointer; }

/* Sala de espera */
.wait { text-align: center; }
.big-count b { font-size: 4.5rem; font-weight: 900; color: var(--navy); display: block; line-height: 1; }
.big-count span { color: var(--mute); }
.dept-cloud { display: flex; flex-wrap: wrap; gap: 18px; justify-content: center; margin: 24px 0; text-align: left; }
.dept-col h4 { margin: 0 0 6px; } .dept-col > div { display: flex; flex-wrap: wrap; gap: 5px; max-width: 260px; }
.pchip { border: 2px solid; border-radius: 99px; padding: 2px 9px; font-size: .82rem; background: #fff; animation: pop .4s ease-out; }
.pchip.me { background: var(--navy); color: #fff; }
@keyframes pop { from { transform: scale(.6); opacity: 0; } }
.pulse-dot::before { content: ""; display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--orange); margin-right: 8px; animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .2; } }

/* Entrevista */
.step-head { display: flex; justify-content: space-between; align-items: baseline; }
.progress { height: 6px; background: var(--line2); border-radius: 99px; overflow: hidden; margin: 6px 0 22px; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--sky), var(--orange)); border-radius: 99px; transition: width .4s; }
.progress.big { height: 10px; margin: 4px 0 16px; }
.qtext { font-size: 1.05rem; color: var(--ink2); } .hint { font-size: .88rem; color: var(--mute); }
.note { background: #fff7ef; border-left: 4px solid var(--orange); padding: 10px 14px; border-radius: 6px; }
.blocks li { margin-bottom: 6px; }
.nav { display: flex; justify-content: space-between; margin-top: 24px; gap: 12px; }
.empty-pick { padding: 14px; border: 2px dashed var(--line); border-radius: 12px; text-align: center; }
.picked { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 8px; }
.picked li { border: 1px solid var(--line); border-radius: 12px; padding: 8px 10px; background: #fbfcfe; animation: pop .25s ease-out; }
.prow { display: flex; align-items: center; gap: 10px; }
.rk { font-weight: 900; color: var(--orange-d); min-width: 30px; }
.pname { flex: 1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .pname small { color: var(--mute); }
.bar { display: inline-block; width: 5px; height: 26px; border-radius: 4px; flex: none; }
td .bar { height: 14px; margin-right: 8px; vertical-align: -2px; }
.mv { display: flex; gap: 4px; }
.pextra { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin: 8px 0 2px 15px; }
.picker { border-top: 1px solid var(--line); padding-top: 14px; }
.picker-tools { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; } .picker-tools input { max-width: 340px; }
.dept-filter { margin-bottom: 12px; }
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; max-height: 420px; overflow: auto; padding: 2px; }
.pcard { font: inherit; text-align: left; display: grid; grid-template-columns: 6px 1fr; column-gap: 10px; border: 1px solid var(--line); border-radius: 12px; background: #fff; padding: 9px 10px; cursor: pointer; transition: .12s; }
.pcard .bar { grid-row: 1 / 4; height: 100%; } .pcard b { font-size: .92rem; } .pcard small { font-size: .76rem; color: var(--ink2); }
.pcard:hover { border-color: var(--navy2); transform: translateY(-1px); }
.pcard.on { border-color: var(--orange); background: #fff4ea; box-shadow: inset 0 0 0 1px var(--orange); }
.pcard:disabled { opacity: .35; cursor: not-allowed; transform: none; }
.dtable { display: grid; gap: 8px; }
.drow { display: grid; grid-template-columns: 180px auto auto; gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line2); }
.drow.head { font-size: .78rem; color: var(--mute); text-transform: uppercase; letter-spacing: .05em; border: 0; padding: 0; }
.dname { display: flex; align-items: center; gap: 8px; font-weight: 650; }
.stars.off { opacity: .35; }
.likert { display: grid; gap: 14px; }
.lrow p { font-weight: 600; margin-bottom: 6px; }
.seg.scale { display: grid; grid-template-columns: repeat(5, 1fr); width: 100%; }
.seg.scale button { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px; } .seg.scale small { font-size: .7rem; opacity: .8; }
textarea { resize: vertical; }
.review { display: grid; gap: 8px; margin-bottom: 16px; }
.rv { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; } .rv p { margin: 4px 0 0; font-size: .9rem; }
.rv-h { display: flex; justify-content: space-between; align-items: center; }
.done { text-align: center; }
.check-big { width: 74px; height: 74px; margin: 0 auto 14px; border-radius: 50%; background: var(--ok); color: #fff; font-size: 2.4rem; display: grid; place-items: center; animation: pop .5s; }
.sg-holder .sg-mount { height: 720px; }

/* Panel RRHH */
.adm-head { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; padding: 22px 0 8px; }
.adm-head h1 { font-size: 1.8rem; color: var(--navy); margin: 0; }
.adm-kpis { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.adm-ctl { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; }
.kpi { background: #fff; border-radius: 12px; box-shadow: var(--shadow); padding: 10px 16px; min-width: 120px; }
.kpi b { display: block; font-size: 1.5rem; font-weight: 850; color: var(--navy); line-height: 1.1; } .kpi span { font-size: .76rem; color: var(--mute); }
.kpi.ok b { color: var(--ok); } .kpi.warn b { color: var(--warn); } .kpi.alert b { color: var(--alert); }
.tabs { display: flex; gap: 4px; border-bottom: 2px solid var(--line); margin: 8px 0 0; overflow-x: auto; }
.tabs button { font: inherit; font-weight: 650; border: 0; background: none; padding: 10px 16px; cursor: pointer; color: var(--mute); border-bottom: 3px solid transparent; margin-bottom: -2px; white-space: nowrap; }
.tabs button[aria-selected=true] { color: var(--navy); border-color: var(--orange); }
.pane { padding-top: 6px; }
.grid-sesion { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 0 18px; align-items: start; }
.grid-sesion > :nth-child(3) { grid-column: 1; }
.grid-sesion > :nth-child(2) { grid-row: span 2; }
.projector { background: var(--navy); color: #fff; }
.projector .url { font-size: 1.5rem; font-weight: 850; color: var(--sky); word-break: break-all; margin: 4px 0 12px; }
.projector .code span { display: block; font-size: .78rem; color: #b8c6d8; text-transform: uppercase; letter-spacing: .08em; }
.projector .code b { font-size: 2.4rem; letter-spacing: .08em; color: var(--orange); }
.steps-mini { display: grid; gap: 8px; margin-top: 14px; font-size: .88rem; color: #b8c6d8; }
.steps-mini div { display: flex; gap: 10px; align-items: center; } .steps-mini b { width: 24px; height: 24px; border-radius: 50%; border: 1px solid #4b5d78; display: grid; place-items: center; flex: none; }
.steps-mini .on { color: #fff; font-weight: 700; } .steps-mini .on b { background: var(--orange); border-color: var(--orange); }
.status { font-size: .8rem; font-weight: 650; } .status.ok { color: var(--ok); } .status.warn { color: var(--warn); }
.btns { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.danger-h { margin-top: 22px; color: var(--alert); }
.table-wrap { overflow: auto; max-height: 640px; }
.tbl { width: 100%; border-collapse: collapse; font-size: .86rem; }
.tbl th { text-align: left; font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; color: var(--mute); padding: 8px; border-bottom: 2px solid var(--line); position: sticky; top: 0; background: #fff; white-space: nowrap; }
.tbl.sortable th { cursor: pointer; } .tbl.sortable th[aria-sort=descending]::after { content: " ↓"; } .tbl.sortable th[aria-sort=ascending]::after { content: " ↑"; }
.tbl td { padding: 7px 8px; border-bottom: 1px solid var(--line2); vertical-align: middle; }
.tbl td.n { text-align: right; font-variant-numeric: tabular-nums; } .tbl tr.nr td { color: var(--mute); } .tbl td.warn { color: var(--warn); font-weight: 700; }
.tbl tbody tr:hover { background: #f8fafc; }
.mbar { display: inline-flex; align-items: center; gap: 6px; width: 90px; } .mbar i { display: block; height: 6px; background: var(--navy2); border-radius: 4px; } .mbar small { color: var(--mute); }
.plink { font: inherit; border: 0; background: none; padding: 0; color: var(--navy2); cursor: pointer; font-weight: 650; text-align: left; }
.plink:hover { color: var(--orange-d); text-decoration: underline; }
.grid-res { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 18px; align-items: start; } .span2 { grid-column: 1 / -1; }
.grid-res > *, .grid-sesion > * { min-width: 0; }
.concl { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 10px; }
.cc { border-radius: 12px; padding: 12px 14px; border-left: 5px solid var(--info); background: #f4f8ff; color: var(--ink); } .cc p { font-size: .88rem; margin: 4px 0 8px; }
.cc.ok { border-color: var(--ok); background: #f0faf5; } .cc.warn { border-color: var(--warn); background: #fffaf0; } .cc.alert { border-color: var(--alert); background: #fff4f4; } .cc.key { border-color: var(--orange); background: #fff6ee; }
.kgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; } .kgrid .kpi { box-shadow: none; border: 1px solid var(--line); }
.climate, .homo { display: grid; gap: 8px; margin-bottom: 18px; }
.crow, .hrow { display: grid; grid-template-columns: 150px 1fr 44px; gap: 10px; align-items: center; font-size: .88rem; } .crow b, .hrow b { text-align: right; }
.cbar { background: var(--line2); border-radius: 99px; height: 12px; overflow: hidden; } .cbar i { display: block; height: 100%; border-radius: 99px; }
.cbar i.good { background: var(--ok); } .cbar i.mid { background: #e0b440; } .cbar i.bad { background: var(--alert); }
.hscale { position: relative; height: 22px; background: linear-gradient(90deg, #fde3cf, #f4f6f9 50%, #d6e6fb); border-radius: 99px; font-size: .7rem; color: var(--mute); }
.hscale .l { position: absolute; left: 8px; top: 3px; } .hscale .r { position: absolute; right: 8px; top: 3px; }
.hscale .mark { position: absolute; top: -3px; width: 4px; height: 28px; background: var(--navy); border-radius: 2px; transform: translateX(-2px); }
.heat { display: grid; gap: 3px; margin-top: 14px; overflow-x: auto; }
.hc { min-height: 40px; display: grid; place-items: center; border-radius: 6px; background: #f6f8fa; font-size: .84rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.hc.head, .hc.rowh, .hc.corner { background: none; font-size: .78rem; } .hc.rowh { justify-content: end; padding-right: 8px; } .hc.corner { color: var(--mute); font-weight: 500; }
.hc.self { background: repeating-linear-gradient(45deg, #f1f3f6, #f1f3f6 4px, #fff 4px, #fff 8px); }
.chord { display: grid; place-items: center; } .chord-svg { width: 100%; max-width: 460px; }
.row-ctl { display: flex; gap: 16px; margin: 8px 0 12px; }
.matrix-wrap { overflow: auto; max-height: 78vh; position: relative; }
.matrix-svg text { fill: var(--ink2); }
.exp { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line2); } .exp p { margin: 2px 0 0; }

/* Sociograma */
.sg { display: flex; flex-direction: column; gap: 10px; height: 100%; background: var(--bg); }
.pane[data-socio], .pane:has(> .sg) { padding-top: 12px; }
.sg-bar { background: #fff; border-radius: var(--r); box-shadow: var(--shadow); padding: 10px 14px; display: grid; gap: 8px; }
.sg-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.sg-row .lbl { font-size: .74rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--mute); min-width: 44px; }
.sg-row input[type=search] { width: 200px; padding: 6px 10px; }
.sg-row input[type=range] { width: 70px; }
.chip { font: inherit; font-size: .84rem; font-weight: 650; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 5px 11px; cursor: pointer; color: var(--ink2); transition: .12s; }
.chip .dot { width: 10px; height: 10px; border-radius: 50%; }
.chip[aria-pressed=true] { background: var(--navy); color: #fff; border-color: var(--navy); }
.chip.ghost { border-style: dashed; }
.hint { margin-left: 4px; }
.sg-main { display: grid; grid-template-columns: 1fr 320px; gap: 10px; min-height: 0; }
.sg-canvas { position: relative; background: #fff; border-radius: var(--r); box-shadow: var(--shadow); height: calc(100vh - 330px); min-height: 480px; overflow: hidden; background-image: radial-gradient(#e7ebf0 1px, transparent 1px); background-size: 22px 22px; }
.sg-holder .sg-canvas { height: 600px; min-height: 0; }
.sg-svg { display: block; width: 100%; height: 100%; cursor: grab; } .sg-svg:active { cursor: grabbing; }
.sg-svg text { font-family: inherit; }
.sg-svg .node { cursor: pointer; transition: opacity .2s; }
.sg-svg .node .lbl { font-size: 11px; font-weight: 650; fill: #22303f; paint-order: stroke; stroke: #fff; stroke-width: 3.5px; stroke-linejoin: round; pointer-events: none; }
.sg-svg .node.dim { opacity: .13; }
.sg-svg .node.sel .body { stroke: var(--orange) !important; stroke-width: 4px !important; }
.sg-svg .link { transition: opacity .2s; } .sg-svg .link .vis { stroke-opacity: .55; }
.sg-svg .link .hit { stroke: transparent; stroke-width: 9px; fill: none; cursor: help; }
.sg-svg .link.dim { opacity: .05; } .sg-svg .link.hl .vis { stroke-opacity: .95; }
.sg-svg .pulse { pointer-events: none; }
.sg-tip { position: absolute; z-index: 5; background: rgba(18,35,61,.96); color: #fff; padding: 9px 12px; border-radius: 10px; font-size: .82rem; max-width: 260px; pointer-events: none; box-shadow: 0 8px 24px rgba(0,0,0,.2); }
.sg-tip .muted { color: #b8c6d8; } .sg-tip .tdot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; } .sg-tip .tag { background: rgba(255,255,255,.15); color: #fff; }
.sg-legend { position: absolute; left: 12px; bottom: 54px; background: rgba(255,255,255,.9); border: 1px solid var(--line); border-radius: 12px; padding: 7px 9px; font-size: .74rem; max-width: 250px; max-height: 40%; overflow: auto; }
.lg-title { font: inherit; font-weight: 800; font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; color: var(--mute); margin-bottom: 4px; border: 0; background: none; padding: 0; cursor: pointer; }
.sg-legend.closed > :not(.lg-title) { display: none; }
.lg-item { font: inherit; display: flex; align-items: center; gap: 6px; border: 0; background: none; padding: 2px 4px; cursor: pointer; border-radius: 6px; width: 100%; text-align: left; }
.lg-item:hover, .lg-item.on { background: #eef3fb; } .lg-item i { width: 11px; height: 11px; border-radius: 50%; flex: none; }
.lg-edges { display: flex; flex-wrap: wrap; gap: 4px 10px; border-top: 1px solid var(--line2); margin-top: 6px; padding-top: 6px; font-size: .72rem; }
.lg-edges span { display: inline-flex; align-items: center; gap: 4px; } .lg-edges .ln { width: 16px; height: 3px; border-radius: 2px; }
.sg-live { position: absolute; top: 12px; left: 12px; background: rgba(255,255,255,.94); border: 1px solid var(--line); border-radius: 99px; padding: 4px 12px; font-size: .8rem; }
.sg-live::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); margin-right: 6px; animation: blink 1.6s infinite; }
.sg-tools { position: absolute; top: 12px; right: 12px; display: flex; flex-direction: column; gap: 6px; }
.sg-timeline { position: absolute; left: 12px; right: 12px; bottom: 10px; display: flex; align-items: center; gap: 10px; background: rgba(255,255,255,.94); border: 1px solid var(--line); border-radius: 99px; padding: 4px 14px 4px 4px; }
.sg-timeline input { flex: 1; } .sg-timeline span { white-space: nowrap; color: var(--ink2); }
.sg-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--mute); pointer-events: none; text-align: center; padding: 40px; }
.sg-side { background: #fff; border-radius: var(--r); box-shadow: var(--shadow); padding: 16px; overflow: auto; height: calc(100vh - 330px); min-height: 480px; font-size: .88rem; }
.sg-holder .sg-side { height: 600px; min-height: 0; }
.sg-side h3 { font-size: 1.15rem; }
.fhead { position: relative; padding-right: 30px; } .fhead .close { position: absolute; right: 0; top: 0; }
.mini-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(64px, 1fr)); gap: 6px; margin: 10px 0; }
.mini-kpis div { background: var(--line2); border-radius: 10px; padding: 6px 8px; } .mini-kpis b { display: block; font-size: 1rem; color: var(--navy); } .mini-kpis span { font-size: .7rem; color: var(--mute); }
.rank { padding-left: 20px; } .rank li { display: flex; justify-content: space-between; margin-bottom: 3px; }
ol.rank li { display: list-item; } ol.rank li .muted { float: right; }
.rel { margin-top: 8px; } .relrow { display: grid; grid-template-columns: 110px 1fr; gap: 6px; padding: 3px 0; border-bottom: 1px dashed var(--line2); }
.rc { display: inline-flex; align-items: center; gap: 6px; color: var(--mute); font-size: .8rem; } .rc i { width: 8px; height: 8px; border-radius: 50%; }
.help { margin-top: 14px; border-top: 1px solid var(--line2); padding-top: 10px; }
.sg:fullscreen { padding: 14px; } .sg:fullscreen .sg-canvas, .sg:fullscreen .sg-side { height: calc(100vh - 150px); }

/* Aviso */
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; padding: 11px 20px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.25); z-index: 100; font-weight: 600; }
.toast.warn { background: var(--warn); } .toast.err { background: var(--alert); }

/* Metodología */
.doc { max-width: 860px; } .doc table { border-collapse: collapse; width: 100%; font-size: .9rem; margin: 10px 0 18px; }
.doc th, .doc td { border-bottom: 1px solid var(--line); padding: 7px 8px; text-align: left; vertical-align: top; } .doc th { background: var(--line2); }
.doc h2 { margin-top: 1.4em; color: var(--navy); }

/* Responsive */
@media (max-width: 1100px) {
  .sg-main { grid-template-columns: 1fr; } .sg-side { height: auto; min-height: 0; }
  .adm-head { grid-template-columns: 1fr; } .adm-ctl { align-items: flex-start; } .adm-kpis { justify-content: flex-start; }
  .grid-sesion, .grid-res { grid-template-columns: 1fr; } .grid-sesion > * { grid-column: auto !important; grid-row: auto !important; }
}
@media (max-width: 680px) {
  .grid2 { grid-template-columns: 1fr; } .card { padding: 18px 16px; }
  .drow { grid-template-columns: 1fr; gap: 6px; } .drow.head { display: none; }
  .seg.scale small { display: none; }
  .sg-canvas { height: 70vh; min-height: 380px; } .sg-legend { display: none; }
  .crow, .hrow { grid-template-columns: 110px 1fr 36px; } .kgrid { grid-template-columns: 1fr; }
  .who small { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
