/* Kairo Journal - pagina de Soporte */

#kairo-support{font-family:var(--font-ui);color:var(--text);max-width:1180px;margin:0 auto;width:100%}

.ks-eyebrow{font-size:12.5px;font-weight:800;letter-spacing:.1em;text-transform:uppercase;color:var(--primary);line-height:1.2;margin:0}
.ks-title{font-size:34px;font-weight:800;letter-spacing:-.03em;color:var(--text);margin:6px 0 6px;line-height:1.15}
.ks-sub{font-size:14.5px;font-weight:500;color:var(--text-2);margin:0 0 24px;line-height:1.55;max-width:640px}

/* ---------- Canales ---------- */
.ks-chans{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-bottom:18px}
.ks-chan{background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:22px;
box-shadow:var(--shadow);display:flex;flex-direction:column;gap:9px;text-decoration:none!important;
color:inherit;transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}
a.ks-chan:hover{transform:translateY(-2px);border-color:var(--primary)}
.ks-chan-ic{width:38px;height:38px;border-radius:12px;display:flex;align-items:center;justify-content:center;
background:var(--primary-soft);color:var(--primary)}
.ks-chan-ic.is-green{background:var(--green-soft);color:var(--green)}
.ks-chan-ic.is-amber{background:var(--amber-soft);color:var(--amber)}
.ks-chan-ic svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.ks-chan-t{font-size:15.5px;font-weight:800;letter-spacing:-.01em;color:var(--text);line-height:1.25}
.ks-chan-d{font-size:13px;font-weight:500;color:var(--text-2);line-height:1.5}
.ks-chan-v{font-size:13px;font-weight:700;color:var(--primary);word-break:break-word}

/* ---------- Rejilla principal ---------- */
.ks-grid{display:grid;grid-template-columns:minmax(0,1fr) 400px;gap:18px;align-items:start}
.ks-card{background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:24px;
box-shadow:var(--shadow);margin-bottom:16px}
.ks-card:last-child{margin-bottom:0}
.ks-card-t{font-size:17px;font-weight:800;letter-spacing:-.02em;color:var(--text);margin:0 0 4px;line-height:1.25}
.ks-card-s{font-size:13px;font-weight:500;color:var(--text-3);margin:0 0 18px;line-height:1.5}

/* ---------- Buscador ---------- */
.ks-search{position:relative;margin-bottom:16px}
.ks-search input{width:100%;height:46px;padding:0 14px 0 42px;border-radius:12px;border:1px solid var(--border);
background:var(--surface-2);color:var(--text);font-family:inherit;font-size:14px;font-weight:500;
transition:border-color .15s,box-shadow .15s,background .15s}
.ks-search input:focus{outline:none;border-color:var(--primary);background:var(--surface);box-shadow:0 0 0 3px var(--ring)}
.ks-search svg{position:absolute;left:14px;top:50%;margin-top:-9px;width:18px;height:18px;
fill:none;stroke:var(--text-3);stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}

/* ---------- Filtros ---------- */
.ks-tabs{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:16px}
.ks-tab{font-size:12.5px;font-weight:600;padding:7px 14px;border-radius:999px;border:1px solid var(--border);
background:var(--surface-2);color:var(--text-2);cursor:pointer;font-family:inherit;line-height:1.2;
transition:background .14s,border-color .14s,color .14s}
.ks-tab:hover{border-color:var(--text-3);color:var(--text)}
.ks-tab.is-on{background:var(--primary-soft);border-color:var(--primary);color:var(--primary);font-weight:700}

/* ---------- FAQ ---------- */
.ks-faq{display:flex;flex-direction:column;gap:8px}
.ks-q{border:1px solid var(--border);border-radius:14px;background:var(--surface-2);overflow:hidden;transition:border-color .15s}
.ks-q.is-open{border-color:var(--primary);background:var(--surface)}
.ks-q-btn{width:100%;display:flex;align-items:center;gap:12px;padding:15px 16px;border:0;background:transparent;
color:var(--text);font-family:inherit;font-size:14px;font-weight:700;text-align:left;cursor:pointer;line-height:1.4}
.ks-q-btn:hover{color:var(--primary)}
.ks-q-ch{margin-left:auto;width:17px;height:17px;flex:0 0 17px;fill:none;stroke:var(--text-3);
stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round;transition:transform .2s}
.ks-q.is-open .ks-q-ch{transform:rotate(180deg);stroke:var(--primary)}
.ks-q-body{display:none;padding:0 16px 17px 16px;font-size:13.5px;font-weight:500;color:var(--text-2);line-height:1.65}
.ks-q.is-open .ks-q-body{display:block;animation:kfIn .16s ease}
.ks-q-body b{color:var(--text);font-weight:800}
.ks-q-body a{color:var(--primary);font-weight:700}
.ks-q-cat{display:inline-flex;align-items:center;padding:4px 10px;border-radius:999px;background:var(--surface-3);
color:var(--text-3);font-size:10.5px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;margin-bottom:9px}
.ks-empty{padding:34px 16px;text-align:center;color:var(--text-3);font-weight:600;font-size:13.5px;
background:var(--surface-2);border:1px dashed var(--border);border-radius:14px}

/* ---------- Formulario ---------- */
.ks-f{display:flex;flex-direction:column;gap:14px}
.ks-fl{display:block;font-size:13px;font-weight:600;color:var(--text-2);margin:0 0 8px;line-height:1.25}
.ks-in,.ks-sel,.ks-ta{width:100%;border-radius:12px;border:1px solid var(--border);background:var(--surface-2);
color:var(--text);font-family:inherit;font-size:14px;font-weight:500;
transition:border-color .15s,box-shadow .15s,background .15s}
.ks-in,.ks-sel{height:46px;padding:0 14px}
.ks-sel{font-weight:600;cursor:pointer}
.ks-ta{min-height:132px;padding:12px 14px;line-height:1.55;resize:vertical}
.ks-in:focus,.ks-sel:focus,.ks-ta:focus{outline:none;border-color:var(--primary);background:var(--surface);box-shadow:0 0 0 3px var(--ring)}
.ks-send{width:100%;height:50px;border:0;border-radius:14px;background:var(--primary);color:#fff;
font-family:inherit;font-size:14.5px;font-weight:700;cursor:pointer;display:flex;align-items:center;
justify-content:center;gap:9px;box-shadow:0 12px 26px -12px rgba(37,99,235,.8);transition:background .16s,transform .16s}
.ks-send:hover{background:var(--primary-2);transform:translateY(-1px)}
.ks-send svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:2.1;stroke-linecap:round;stroke-linejoin:round}
.ks-note{background:var(--surface-2);border-radius:12px;padding:13px 15px;font-size:12.5px;font-weight:500;
color:var(--text-3);line-height:1.55}
.ks-note b{color:var(--text-2);font-weight:800}
.ks-err{background:var(--red-soft);color:var(--red);border:1px solid var(--red);border-radius:12px;
padding:12px 14px;font-size:13px;font-weight:700}

/* ---------- Enlaces rapidos ---------- */
.ks-links{display:flex;flex-direction:column;gap:2px}
.ks-link{display:flex;align-items:center;gap:11px;padding:11px 12px;border-radius:12px;color:var(--text-2);
text-decoration:none!important;font-size:13.5px;font-weight:600;transition:background .14s,color .14s}
.ks-link:hover{background:var(--surface-2);color:var(--primary)}
.ks-link svg{width:18px;height:18px;flex:0 0 18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.ks-link i{margin-left:auto;font-style:normal;color:var(--text-3);font-size:15px;line-height:1}

/* ---------- Tickets ---------- */
.ks-main-tabs{margin-bottom:20px}
.ks-main-tabs .ks-tab{font-size:13.5px;padding:9px 18px}

.ks-tk-head{display:flex;flex-wrap:wrap;align-items:center;gap:14px;margin-bottom:16px}
.ks-tk-head > div{flex:1 1 240px;min-width:0}
.ks-tk-new{width:auto!important;height:44px!important;padding:0 18px!important;flex:0 0 auto}

.ks-info{display:flex;gap:11px;align-items:flex-start;background:var(--primary-soft);border-radius:12px;
padding:13px 15px;margin-bottom:16px;font-size:12.5px;font-weight:500;color:var(--text-2);line-height:1.55}
.ks-info.is-warn{background:var(--amber-soft);color:var(--amber)}
.ks-info b{color:var(--text);font-weight:800}
.ks-info.is-warn b{color:var(--amber)}
.ks-info svg{width:16px;height:16px;flex:0 0 16px;margin-top:1px;fill:none;stroke:currentColor;
stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round;color:var(--primary)}
.ks-info.is-warn svg{color:var(--amber)}

.ks-tk-list{display:flex;flex-direction:column;gap:8px}
.ks-tk{display:grid;grid-template-columns:110px minmax(0,1fr) auto auto;align-items:center;gap:14px;
width:100%;text-align:left;padding:13px 15px;border-radius:13px;border:1px solid var(--border);
background:var(--surface-2);cursor:pointer;font-family:inherit;transition:border-color .15s,transform .15s}
.ks-tk:hover{border-color:var(--primary);transform:translateY(-1px)}
.ks-tk-st{display:inline-flex;align-items:center;justify-content:center;padding:5px 11px;border-radius:999px;
font-size:10.5px;font-weight:800;letter-spacing:.05em;text-transform:uppercase;white-space:nowrap}
.ks-tk-st.open{background:var(--primary-soft);color:var(--primary)}
.ks-tk-st.ans{background:var(--amber-soft);color:var(--amber)}
.ks-tk-st.cls{background:var(--surface-3);color:var(--text-3)}
.ks-tk-m{min-width:0;display:block}
.ks-tk-t{display:block;font-size:14px;font-weight:800;color:var(--text);line-height:1.3;
overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ks-tk-s{display:block;font-size:11.5px;font-weight:600;color:var(--text-3);margin-top:3px}
.ks-tk-w{font-size:11px;font-weight:700;color:var(--amber);white-space:nowrap}
.ks-tk-d{font-size:11.5px;font-weight:600;color:var(--text-3);white-space:nowrap}

.ks-tk-form{background:var(--surface-2);border-radius:14px;padding:18px;margin-bottom:16px}
.ks-tk-acts{display:flex;gap:10px;justify-content:flex-end}
.ks-tk-acts .ks-send{width:auto;height:44px;padding:0 20px}
.ks-btn{height:44px;padding:0 18px;border-radius:12px;border:1px solid var(--border);background:var(--surface);
color:var(--text-2);font-family:inherit;font-size:13.5px;font-weight:700;cursor:pointer;
display:inline-flex;align-items:center;justify-content:center;gap:8px;transition:all .15s}
.ks-btn:hover{border-color:var(--primary);color:var(--primary)}
.ks-btn.ico{width:44px;padding:0;flex:0 0 44px}
.ks-btn svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}

/* Hilo de conversacion */
.ks-th-head{display:flex;align-items:center;gap:13px;margin-bottom:16px}
.ks-th-m{flex:1 1 auto;min-width:0}
.ks-th-s{font-size:12px;font-weight:600;color:var(--text-3);margin-top:3px}
.ks-th{display:flex;flex-direction:column;gap:12px;padding:4px 0 18px}
.ks-msg{max-width:82%;align-self:flex-end;background:var(--primary-soft);border-radius:14px 14px 4px 14px;padding:12px 15px}
.ks-msg.is-staff{align-self:flex-start;background:var(--surface-2);border-radius:14px 14px 14px 4px}
.ks-msg-h{display:flex;align-items:baseline;gap:10px;font-size:11.5px;font-weight:800;color:var(--primary);margin-bottom:5px}
.ks-msg.is-staff .ks-msg-h{color:var(--text-2)}
.ks-msg-h span{margin-left:auto;font-weight:600;color:var(--text-3);font-size:10.5px;white-space:nowrap}
.ks-msg-b{font-size:13.5px;font-weight:500;color:var(--text);line-height:1.6;white-space:pre-wrap;word-break:break-word}

.ks-th-reply{border-top:1px solid var(--border-2);padding-top:16px;display:flex;flex-direction:column;gap:12px}
.ks-th-closed{border-top:1px solid var(--border-2);padding-top:16px;display:flex;flex-wrap:wrap;
align-items:center;gap:14px;font-size:13.5px;font-weight:700;color:var(--text-3)}
.ks-th-closed .ks-send{width:auto;height:42px;padding:0 20px;margin-left:auto}
.ks-th-note{margin-left:auto;font-size:12.5px;font-weight:500;color:var(--text-3)}

/* Blindaje contra el hover de botones del tema */
#kairo-support button.ks-btn,
#kairo-support button.ks-btn:focus,
#kairo-support button.ks-btn:active{background:var(--surface)!important;background-color:var(--surface)!important;
color:var(--text-2)!important;border:1px solid var(--border)!important;outline:none!important;box-shadow:none!important}
#kairo-support button.ks-btn:hover{border-color:var(--primary)!important;color:var(--primary)!important}
#kairo-support button.ks-send,
#kairo-support button.ks-send:focus,
#kairo-support button.ks-send:active{background:var(--primary)!important;background-color:var(--primary)!important;
color:#fff!important;border:0!important;outline:none!important}
#kairo-support button.ks-send:hover{background:var(--primary-2)!important;background-color:var(--primary-2)!important}
#kairo-support button.ks-send[disabled]{opacity:.6;cursor:default}
#kairo-support button.ks-tk,
#kairo-support button.ks-tk:focus{background:var(--surface-2)!important;background-color:var(--surface-2)!important;
color:var(--text)!important;outline:none!important;box-shadow:none!important}
#kairo-support select.ks-sel,#kairo-support input.ks-in,#kairo-support textarea.ks-ta{
background-color:var(--surface-2)!important;color:var(--text)!important;border:1px solid var(--border)!important;
box-shadow:none!important}
#kairo-support{color-scheme:light}
[data-theme="dark"] #kairo-support{color-scheme:dark}

@media(max-width:720px){
  .ks-tk{grid-template-columns:auto minmax(0,1fr);gap:10px}
  .ks-tk-w,.ks-tk-d{grid-column:2;font-size:11px}
  .ks-msg{max-width:94%}
}

/* ---------- Sugerencias ---------- */
.ks-sg-list{display:flex;flex-direction:column;gap:10px}
.ks-sg{display:flex;gap:14px;padding:15px;border-radius:14px;background:var(--surface-2);border:1px solid var(--border-2)}
.ks-vote{flex:0 0 54px;width:54px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;
height:56px;border-radius:12px;border:1px solid var(--border);background:var(--surface);color:var(--text-3);
font-family:inherit;cursor:pointer;transition:all .15s}
.ks-vote:hover{border-color:var(--primary);color:var(--primary)}
.ks-vote.is-on{background:var(--primary-soft);border-color:var(--primary);color:var(--primary)}
.ks-vote svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:2.4;stroke-linecap:round;stroke-linejoin:round}
.ks-vote span{font-size:13px;font-weight:800;line-height:1}
.ks-sg-m{min-width:0;flex:1 1 auto}
.ks-sg-t{font-size:14.5px;font-weight:800;color:var(--text);line-height:1.35}
.ks-sg-x{font-size:13px;font-weight:500;color:var(--text-2);line-height:1.55;margin-top:5px;white-space:pre-wrap;word-break:break-word}
.ks-sg-f{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin-top:10px}
.ks-sg-a{font-size:11px;font-weight:700;color:var(--text-3);background:var(--surface-3);border-radius:999px;padding:4px 10px}
.ks-sg-a.is-mine{background:var(--primary-soft);color:var(--primary)}
.ks-sg-n{margin-top:11px;background:var(--surface);border-left:3px solid var(--primary);border-radius:0 10px 10px 0;
padding:10px 13px;font-size:12.5px;font-weight:500;color:var(--text-2);line-height:1.55}
.ks-sg-n b{color:var(--text);font-weight:800}
.ks-tk-st.rec{background:var(--surface-3);color:var(--text-3)}
.ks-tk-st.rev{background:var(--amber-soft);color:var(--amber)}
.ks-tk-st.pla{background:var(--primary-soft);color:var(--primary)}
.ks-tk-st.hec{background:var(--green-soft);color:var(--green)}
.ks-tk-st.des{background:var(--red-soft);color:var(--red)}
#kairo-support button.ks-vote,
#kairo-support button.ks-vote:focus{background:var(--surface)!important;background-color:var(--surface)!important;
color:var(--text-3)!important;outline:none!important;box-shadow:none!important}
#kairo-support button.ks-vote:hover{border-color:var(--primary)!important;color:var(--primary)!important}
#kairo-support button.ks-vote.is-on,
#kairo-support button.ks-vote.is-on:hover{background:var(--primary-soft)!important;background-color:var(--primary-soft)!important;
border-color:var(--primary)!important;color:var(--primary)!important}

@media(max-width:1080px){
  .ks-grid{grid-template-columns:1fr}
  .ks-chans{grid-template-columns:1fr}
}
@media(max-width:820px){
  .ks-title{font-size:27px}
  .ks-card{padding:20px}
}
