/* ════════════════════════════════════════════════════════════════════
   KONOOS OS · kbar.css
   Barra pública "Cápsula" (Bar D) + 4 overlays (voice/chat/agenda/login).
   Chrome dark Konoos inyectado sobre la página light del tenant.
   Consume los tokens canónicos de tokens.css (--k-*). NO redefine paleta.
   Selectores de overlay scopeados bajo .kov para no contaminar el HTML
   del tenant (que puede traer .field/.slot/.msg propios).
   Diseño base: .design/DS konoos OS/bar/Bar D · Cápsula.html (2026-05-27).
   ════════════════════════════════════════════════════════════════════ */

/* Tokens locales del componente (no en tokens.css aún): serif DS + grad 135deg */
.k-bar, .kov, .kov-backdrop {
  --kb-font-serif: 'Fraunces', Georgia, serif;
  --kb-grad-d: linear-gradient(135deg, #00CC22 0%, #00B050 54%, #0081E2 100%);
}

/* Reset border-box scopeado: el k-shell-lite no aplica el reset global que
   asumía Bar D, así height incluye padding+border (px = altura total). */
.k-bar, .k-bar *, .k-bar *::before, .k-bar *::after,
.kov, .kov *, .kov *::before, .kov *::after { box-sizing:border-box; }

/* ──────────────────────────────────────────────────────────────────
   BAR · cápsula flotante → strip full-width
   ────────────────────────────────────────────────────────────────── */
.k-bar{
  position:fixed; left:0; right:0; bottom:0;
  z-index:var(--k-z-overlay);
  pointer-events:none;
  padding-bottom:env(safe-area-inset-bottom);
  font-family:var(--k-font-ui);
}
.k-bar > *{pointer-events:auto}

.k-bar__strip{
  position:absolute; left:0; right:0; bottom:0;
  height:24px;
  background:rgba(10,10,11,.96);
  backdrop-filter:blur(16px); -webkit-backdrop-filter:blur(16px);
  border-top:1px solid var(--k-c-border);
  transform:translateY(100%);
  transition:transform var(--k-m-slow) var(--k-ease-out);
  display:flex; align-items:center;
  padding:0 32px; gap:24px;
}
.k-bar__strip::before{
  content:""; position:absolute; top:-1px; left:0; right:0; height:1px;
  background:var(--k-grad-h); opacity:.5;
}
.k-bar:hover .k-bar__strip,
.k-bar[data-overlay] .k-bar__strip{transform:translateY(0)}

.k-bar__pwr{
  display:inline-flex; align-items:center; gap:8px;
  font-family:var(--k-font-mono); font-size:11px; font-weight:500;
  letter-spacing:.04em; color:var(--k-c-fg-subtle);
  transition:color var(--k-m-fast);
}
.k-bar__pwr:hover{color:var(--k-c-fg-muted)}
.k-bar__pwr-logo{height:14px; width:auto; display:block; opacity:.92}

.k-bar__tag{
  flex:1; text-align:center;
  font-family:var(--kb-font-serif); font-style:italic;
  font-size:14px; font-weight:400;
  color:var(--k-c-fg-dim); letter-spacing:.01em;
}

.k-bar__cluster{
  position:absolute; right:24px; bottom:8px;
  display:flex; align-items:center; gap:8px;
  height:38px; padding:3px 5px;
  background:#0A0A0B;
  border:1px solid var(--k-c-border);
  border-radius:var(--k-r-full);
  box-shadow:0 12px 32px -10px rgba(15,23,42,.30);
  transition:right var(--k-m-slow) var(--k-ease-out),
             bottom var(--k-m-slow) var(--k-ease-out),
             border-color var(--k-m-base),
             box-shadow var(--k-m-base);
}
.k-bar:hover .k-bar__cluster,
.k-bar[data-overlay] .k-bar__cluster{
  right:32px; bottom:8px;
  border-color:transparent; box-shadow:none;
}

.kb-btn{
  display:inline-flex; align-items:center; gap:7px;
  height:32px; padding:0 12px;
  border-radius:var(--k-r-full);
  font-size:13px; font-weight:600;
  color:var(--k-c-fg);
  border:1px solid transparent; background:transparent;
  transition:all var(--k-m-fast);
  position:relative; white-space:nowrap;
}
.kb-btn:hover{background:var(--k-c-bg-3); color:var(--k-c-fg)}
.kb-btn[data-active]{background:var(--k-c-bg-3); border-color:var(--k-c-border-strong)}
.kb-btn[data-active]::before{
  content:""; position:absolute; inset:-3px;
  border-radius:var(--k-r-full); background:var(--kb-grad-d);
  z-index:-1; filter:blur(8px); opacity:.4;
}
.kb-btn svg{width:13px; height:13px}

.kb-btn--primary{
  background:var(--k-grad-h); color:#fff;
  box-shadow:0 4px 14px -2px rgba(0,129,226,.5), 0 0 24px -8px rgba(0,204,34,.6);
}
.kb-btn--primary:hover{filter:brightness(1.08); transform:translateY(-1px)}
.kb-btn--primary[data-active]{transform:translateY(0)}
.kb-btn--primary[data-active]::before{opacity:.6; background:var(--kb-grad-d)}

.kb-btn--ghost{color:var(--k-c-fg-muted); border-color:var(--k-c-border-strong)}
.kb-btn--ghost:hover{color:var(--k-c-fg); background:var(--k-c-bg-3); border-color:var(--k-c-border-strong)}

.kb-mic{
  width:32px; height:32px; padding:0;
  border-radius:50%;
  background:linear-gradient(135deg,#00CC22 0%,#00B050 100%); color:#fff;
  display:flex; align-items:center; justify-content:center;
  box-shadow:0 4px 12px -2px rgba(0,176,80,.5), 0 0 16px -6px rgba(0,204,34,.6);
  transition:all var(--k-m-fast);
}
.kb-mic:hover{filter:brightness(1.08); transform:translateY(-1px)}
.kb-mic svg{width:14px; height:14px}
.kb-mic[data-active]{background:var(--k-danger); box-shadow:0 4px 14px -2px rgba(255,71,87,.5)}
.kb-mic[data-active]::after{
  content:""; position:absolute; inset:-4px;
  border:2px solid rgba(255,71,87,.5); border-radius:50%;
  animation:kb-pulse-ring 1.4s ease-out infinite;
}
@keyframes kb-pulse-ring{0%{transform:scale(.85);opacity:.85}100%{transform:scale(1.5);opacity:0}}

.k-bar__hint{
  position:absolute; right:48px; bottom:54px;
  width:140px; height:2px; border-radius:1px;
  background:var(--k-grad-h); opacity:.5;
  pointer-events:none; transition:opacity var(--k-m-fast);
  animation:kb-hint 2.8s ease-in-out infinite;
}
.k-bar:hover .k-bar__hint,
.k-bar[data-overlay] .k-bar__hint{opacity:0}
@keyframes kb-hint{0%,100%{opacity:.3;filter:brightness(1)}50%{opacity:.6;filter:brightness(1.3)}}

@media (max-width:768px){
  .k-bar__cluster{right:12px; height:42px; padding:3px 5px 3px 12px; gap:6px}
  .k-bar:hover .k-bar__cluster,
  .k-bar[data-overlay] .k-bar__cluster{right:20px}
  .k-bar__strip{padding:0 20px; height:54px}
  .kb-btn{padding:0 12px; font-size:12.5px; height:34px}
  .kb-btn--ghost span{display:none}
  .kb-btn--ghost{padding:0 10px}
  .kb-mic{width:34px; height:34px}
  .k-bar__pwr span{display:none}
  .k-bar__pwr-logo{height:12px}
  .k-bar__tag{display:none}
}
@media (max-width:480px){
  .k-bar__cluster{right:8px}
  .k-bar:hover .k-bar__cluster,
  .k-bar[data-overlay] .k-bar__cluster{right:12px}
  .kb-btn--primary span{display:none}
  .kb-btn--primary{padding:0 12px}
}

/* ──────────────────────────────────────────────────────────────────
   OVERLAY · base compartida
   ────────────────────────────────────────────────────────────────── */
.kov-backdrop{
  position:fixed; inset:0;
  background:rgba(10,10,11,.72);
  backdrop-filter:blur(10px); -webkit-backdrop-filter:blur(10px);
  z-index:calc(var(--k-z-modal) - 5);
  opacity:0; pointer-events:none;
  transition:opacity var(--k-m-slow);
}
.kov-backdrop[data-on]{opacity:1; pointer-events:auto}

.kov{
  position:fixed; left:50%; top:50%;
  transform:translate(-50%, calc(-50% + 16px));
  z-index:var(--k-z-modal);
  background:var(--k-c-bg-1);
  border:1px solid var(--k-c-border-strong);
  border-radius:18px; color:var(--k-c-fg);
  box-shadow:0 32px 80px -16px rgba(0,0,0,.7),
             0 0 0 1px rgba(255,255,255,.04),
             0 0 120px -40px rgba(0,129,226,.4);
  opacity:0; pointer-events:none;
  transition:opacity var(--k-m-slow), transform var(--k-m-slow) var(--k-ease-out);
  display:none; flex-direction:column; overflow:hidden;
  max-width:calc(100vw - 24px); max-height:calc(100dvh - 80px);
  font-family:var(--k-font-ui);
}
.kov[data-on], .kov[data-leaving]{display:flex}
.kov[data-on]{opacity:1; pointer-events:auto; transform:translate(-50%, -50%)}
.kov::before{
  content:""; position:absolute; top:0; left:24px; right:24px; height:1px;
  background:var(--k-grad-h); opacity:.6; pointer-events:none; z-index:1;
}
.kov__close{
  position:absolute; top:14px; right:14px;
  width:34px; height:34px; border-radius:10px;
  background:transparent; color:var(--k-c-fg-subtle);
  display:flex; align-items:center; justify-content:center;
  z-index:5; transition:all var(--k-m-fast);
}
.kov__close:hover{background:var(--k-c-bg-3); color:var(--k-c-fg)}
.kov__close svg{width:14px; height:14px}
.kov .mono{font-family:var(--k-font-mono); font-variant-numeric:tabular-nums}

/* ── OVERLAY 1 · VOICE (orb) ── */
.kov--voice{width:560px; padding:48px 40px 36px; align-items:center; text-align:center}
.kov .voice__lbl{
  font-family:var(--k-font-mono); font-size:11px;
  text-transform:uppercase; letter-spacing:.16em; font-weight:600;
  color:var(--k-c-fg-subtle);
  display:inline-flex; align-items:center; gap:8px; margin-bottom:32px;
}
.kov .voice__lbl-dot{width:6px; height:6px; border-radius:50%; background:var(--k-success-fg); box-shadow:0 0 4px var(--k-success-fg)}
.kov .voice__lbl[data-state="listening"] .voice__lbl-dot{background:var(--k-danger); box-shadow:0 0 6px var(--k-danger); animation:kb-rec 1.2s ease-in-out infinite}
.kov .voice__lbl[data-state="thinking"] .voice__lbl-dot{background:var(--k-warning-fg)}
@keyframes kb-rec{0%,100%{opacity:1;transform:scale(1)}50%{opacity:.4;transform:scale(.65)}}

.kov .voice__orb{position:relative; width:280px; height:280px; margin-bottom:32px; display:flex; align-items:center; justify-content:center}
.kov .voice__orb-glow{position:absolute; inset:-30px; background:conic-gradient(from 0deg,#00CC22,#00B050 33%,#0081E2 66%,#00CC22); filter:blur(60px); opacity:.6; border-radius:50%; animation:kb-spin 16s linear infinite}
.kov .voice__orb-ring{position:absolute; inset:18px; border-radius:50%; background:conic-gradient(from 180deg,transparent 0deg,#00CC22 90deg,transparent 180deg,#0081E2 270deg,transparent 360deg); filter:blur(20px); opacity:.85; animation:kb-spin 9s linear infinite reverse}
.kov .voice__orb-mass{
  position:absolute; inset:46px; border-radius:50%;
  background:radial-gradient(circle at 35% 30%,#1F1F25,#0A0A0B 70%);
  box-shadow:inset 0 0 60px rgba(0,204,34,.18), inset 30px -30px 80px rgba(0,129,226,.22), 0 8px 40px rgba(0,129,226,.30);
  animation:kb-breathe 4s ease-in-out infinite;
}
.kov .voice__orb-mass::before{content:""; position:absolute; inset:0; border-radius:50%; background:radial-gradient(ellipse at 35% 30%,rgba(255,255,255,.12),transparent 50%)}
.kov .voice__orb-core{position:relative; font-family:var(--kb-font-serif); font-size:80px; font-weight:300; line-height:1; color:#fff; letter-spacing:-.04em; text-shadow:0 0 24px rgba(255,255,255,.4); z-index:2}
.kov .voice__iso{position:absolute; left:50%; top:50%; transform:translate(-50%,-50%); width:96px; height:96px; z-index:3; pointer-events:none; filter:drop-shadow(0 0 18px rgba(0,204,34,.45)) drop-shadow(0 0 24px rgba(0,129,226,.3))}
.kov .voice__osc{position:absolute; left:50%; top:50%; transform:translate(-50%,-50%); width:200px; height:80px; display:flex; align-items:center; justify-content:center; gap:3px; z-index:4; pointer-events:none; mix-blend-mode:screen}
.kov .voice__osc span{flex:1; max-width:5px; border-radius:2px; background:linear-gradient(180deg,#00CC22 0%,#00B050 50%,#0081E2 100%); height:18%; box-shadow:0 0 8px rgba(0,204,34,.5); animation:kb-osc 1.2s ease-in-out infinite; transform-origin:center}
@keyframes kb-osc{0%,100%{height:12%}50%{height:72%}}
.kov .voice__osc span:nth-child(1){animation-duration:1.1s;animation-delay:-.50s}
.kov .voice__osc span:nth-child(2){animation-duration:1.4s;animation-delay:-.20s}
.kov .voice__osc span:nth-child(3){animation-duration:.9s;animation-delay:-.70s}
.kov .voice__osc span:nth-child(4){animation-duration:1.3s;animation-delay:-.15s}
.kov .voice__osc span:nth-child(5){animation-duration:1.0s;animation-delay:-.55s}
.kov .voice__osc span:nth-child(6){animation-duration:1.5s;animation-delay:-.30s}
.kov .voice__osc span:nth-child(7){animation-duration:.85s;animation-delay:-.65s;height:80%}
.kov .voice__osc span:nth-child(8){animation-duration:1.25s;animation-delay:-.10s;height:80%}
.kov .voice__osc span:nth-child(9){animation-duration:.95s;animation-delay:-.45s}
.kov .voice__osc span:nth-child(10){animation-duration:1.35s;animation-delay:-.25s}
.kov .voice__osc span:nth-child(11){animation-duration:1.1s;animation-delay:-.60s}
.kov .voice__osc span:nth-child(12){animation-duration:.9s;animation-delay:-.35s}
.kov .voice__osc span:nth-child(13){animation-duration:1.4s;animation-delay:-.50s}
.kov .voice__osc span:nth-child(14){animation-duration:1.05s;animation-delay:-.18s}
.kov .voice__osc span:nth-child(15){animation-duration:1.3s;animation-delay:-.40s}
.kov .voice__osc span:nth-child(16){animation-duration:.95s;animation-delay:-.55s}
@keyframes kb-spin{to{transform:rotate(360deg)}}
@keyframes kb-breathe{0%,100%{transform:scale(1);filter:brightness(1)}50%{transform:scale(.95);filter:brightness(1.12)}}
.kov--voice[data-vstate="speaking"] .voice__orb-glow{animation-duration:8s;opacity:.85}
.kov--voice[data-vstate="speaking"] .voice__orb-ring{animation-duration:5s;opacity:1}
.kov--voice[data-vstate="speaking"] .voice__orb-mass{animation-duration:1.6s}
.kov--voice[data-vstate="listening"] .voice__orb-mass{animation:kb-listen 1.2s ease-in-out infinite}
@keyframes kb-listen{0%,100%{transform:scale(1);box-shadow:inset 0 0 60px rgba(255,71,87,.20),0 8px 40px rgba(255,71,87,.30)}50%{transform:scale(.92);box-shadow:inset 0 0 60px rgba(255,71,87,.35),0 8px 40px rgba(255,71,87,.45)}}

.kov .voice__transcript{font-family:var(--kb-font-serif); font-size:24px; font-weight:400; line-height:1.4; color:var(--k-c-fg); letter-spacing:-.015em; min-height:64px; max-width:440px; text-wrap:balance}
.kov .voice__transcript em{font-style:italic}
.kov .voice__transcript-caret{display:inline-block; width:2px; height:1em; background:var(--k-brand-green); margin-left:3px; vertical-align:-2px; animation:kb-blink 1s steps(1) infinite}
@keyframes kb-blink{50%{opacity:0}}
.kov .voice__ctrls{display:flex; gap:14px; align-items:center; justify-content:center; margin-top:32px}
.kov .voice__ctrl{width:48px; height:48px; border-radius:50%; background:var(--k-c-bg-3); border:1px solid var(--k-c-border); color:var(--k-c-fg-muted); display:flex; align-items:center; justify-content:center; transition:all var(--k-m-fast)}
.kov .voice__ctrl:hover{background:var(--k-c-bg-4); color:var(--k-c-fg); border-color:var(--k-c-border-strong)}
.kov .voice__ctrl svg{width:18px; height:18px}
.kov .voice__ctrl--end{background:var(--k-danger); color:#fff; border-color:transparent; width:56px; height:56px; box-shadow:0 6px 20px -4px rgba(255,71,87,.5)}
.kov .voice__ctrl--end:hover{background:var(--k-danger-fg)}
.kov .voice__ctrl--end svg{width:22px; height:22px}
.kov .voice__foot{margin-top:24px; display:flex; gap:7px; flex-wrap:wrap; align-items:center; justify-content:center; font-family:var(--k-font-mono); font-size:11px; color:var(--k-c-fg-dim); letter-spacing:.04em}

/* ── OVERLAY 2 · CHAT ── */
.kov--chat{width:720px; max-width:calc(100vw - 24px); height:640px; max-height:calc(100dvh - 100px)}
.kov .chat__head{display:flex; align-items:center; gap:12px; padding:14px 16px 12px 18px; border-bottom:1px solid var(--k-c-border); background:var(--k-c-bg-1); position:relative}
.kov .chat__av{width:36px; height:36px; border-radius:50%; background:radial-gradient(circle at 30% 30%,#00CC22 0%,#0081E2 100%); display:flex; align-items:center; justify-content:center; color:#fff; position:relative; flex-shrink:0}
.kov .chat__av::after{content:""; position:absolute; inset:-3px; border:1px solid rgba(0,204,34,.4); border-radius:50%; animation:kb-pulse-ring 2.8s ease-out infinite}
.kov .chat__av svg{width:16px; height:16px}
.kov .chat__av img{width:20px; height:20px; display:block}
.kov .chat__id{display:flex; flex-direction:column; gap:3px; min-width:0; flex:1}
.kov .chat__title{font-family:var(--k-font-ui); font-size:14px; font-weight:700; letter-spacing:.06em; color:var(--k-success-fg); line-height:1}
.kov .chat__sub{display:inline-flex; align-items:center; gap:6px; font-family:var(--k-font-mono); font-size:11px; color:var(--k-c-fg-subtle); letter-spacing:.02em}
.kov .chat__sub-dot{width:6px; height:6px; border-radius:50%; background:#FF8C42; box-shadow:0 0 4px rgba(255,140,66,.6)}
.kov .chat__head-ic{width:32px; height:32px; border-radius:8px; display:flex; align-items:center; justify-content:center; color:var(--k-c-fg-subtle); flex-shrink:0; transition:all var(--k-m-fast)}
.kov .chat__head-ic:hover{background:var(--k-c-bg-3); color:var(--k-c-fg)}
.kov .chat__head-ic svg{width:14px; height:14px}
.kov .chat__body{flex:1; overflow-y:auto; padding:20px 22px; display:flex; flex-direction:column; gap:14px; scrollbar-width:thin; scrollbar-color:rgba(255,255,255,.18) transparent}
.kov .chat__body::-webkit-scrollbar{width:6px}
.kov .chat__body::-webkit-scrollbar-thumb{background:rgba(255,255,255,.18); border-radius:3px}
.kov .msg{display:flex; gap:10px; max-width:88%}
.kov .msg--user{align-self:flex-end; flex-direction:row-reverse}
.kov .msg__av{width:24px; height:24px; border-radius:50%; background:radial-gradient(circle at 30% 30%,#00CC22 0%,#0081E2 100%); flex-shrink:0; display:flex; align-items:center; justify-content:center; color:#fff}
.kov .msg__av svg{width:10px; height:10px}
.kov .msg__av img{width:14px; height:14px; display:block}
.kov .msg__bubble{padding:12px 16px; border-radius:14px; font-size:14.5px; line-height:1.55; color:var(--k-c-fg)}
.kov .msg--bot .msg__bubble{background:var(--k-c-bg-2); border:1px solid var(--k-c-border)}
.kov .msg--user .msg__bubble{background:var(--k-c-bg-3); border:1px solid var(--k-c-border-strong); border-radius:14px 14px 4px 14px}
.kov .msg__bubble b{color:var(--k-c-fg); font-weight:600}
.kov .msg__bubble p+p{margin-top:8px}
.kov .msg__cite{display:inline-flex; align-items:center; gap:6px; margin-top:10px; padding:6px 10px; border-radius:6px; background:rgba(0,176,80,.10); border:1px solid rgba(0,176,80,.28); font-family:var(--k-font-mono); font-size:11px; color:var(--k-success-fg); font-weight:500}
.kov .msg__cite svg{width:10px; height:10px}
.kov .msg__audit{margin-top:6px; font-family:var(--k-font-mono); font-size:10.5px; color:var(--k-c-fg-dim); display:flex; gap:10px; flex-wrap:wrap}
.kov .chat__sugs{display:flex; gap:8px; flex-wrap:wrap; padding:14px 22px 4px; border-top:1px solid var(--k-c-border)}
.kov .chat__sug{display:inline-flex; align-items:center; gap:5px; padding:6px 12px; border-radius:var(--k-r-full); background:var(--k-c-bg-2); border:1px solid var(--k-c-border); font-size:12px; color:var(--k-c-fg-muted); transition:all var(--k-m-fast)}
.kov .chat__sug:hover{background:var(--k-c-bg-3); color:var(--k-c-fg); border-color:var(--k-c-border-strong)}
.kov .chat__comp{padding:12px 22px 16px; display:flex; flex-direction:column; gap:6px}
.kov .chat__input-row{display:flex; align-items:flex-end; gap:8px; padding:10px 12px; background:var(--k-c-bg-2); border:1px solid var(--k-c-border); border-radius:12px; transition:border var(--k-m-fast)}
.kov .chat__input-row:focus-within{border-color:var(--k-c-border-strong)}
.kov .chat__ta{flex:1; background:transparent; border:0; outline:none; resize:none; color:var(--k-c-fg); font:inherit; font-size:14px; line-height:1.5; min-height:22px; max-height:120px; padding:1px 0}
.kov .chat__ta::placeholder{color:var(--k-c-fg-dim)}
.kov .chat__btn{width:32px; height:32px; border-radius:8px; display:flex; align-items:center; justify-content:center; flex-shrink:0; transition:all var(--k-m-fast)}
.kov .chat__btn--mic{color:var(--k-c-fg-muted); background:var(--k-c-bg-3)}
.kov .chat__btn--mic:hover{background:var(--k-c-bg-4); color:var(--k-c-fg)}
.kov .chat__btn--send{background:var(--k-grad-h); color:#fff}
.kov .chat__btn--send:hover{filter:brightness(1.08)}
.kov .chat__btn--send:disabled{opacity:.45; cursor:not-allowed}
.kov .chat__btn svg{width:14px; height:14px}
.kov .chat__hint{display:flex; gap:7px; flex-wrap:wrap; align-items:center; justify-content:center; font-family:var(--k-font-mono); font-size:11px; color:var(--k-c-fg-dim); letter-spacing:.04em; padding-top:8px}
.kov .chat__hint-logo{height:13px; width:auto; display:block; opacity:.92}
.kov .chat__hint kbd{display:inline-block; padding:1px 5px; border-radius:3px; background:var(--k-c-bg-3); border:1px solid var(--k-c-border); color:var(--k-c-fg-subtle); font-family:inherit; font-size:9.5px; margin-right:2px}

/* ── OVERLAY 3 · AGENDA (calendario + slots + form) ── */
.kov--agenda{width:920px; max-width:calc(100vw - 24px)}
.kov .agenda__head{display:grid; grid-template-columns:auto 1fr auto; gap:14px; align-items:center; padding:20px 22px 16px; border-bottom:1px solid var(--k-c-border); flex-shrink:0}
.kov .agenda__intro{flex-shrink:0; padding:12px 24px; font-family:var(--k-font-mono); font-size:11.5px; letter-spacing:.04em; color:var(--k-c-fg-subtle); border-bottom:1px solid var(--k-c-border)}
.kov .agenda__head-mark{width:36px; height:36px; border-radius:10px; background:var(--k-grad-soft); border:1px solid rgba(0,204,34,.25); display:flex; align-items:center; justify-content:center; color:var(--k-success-fg)}
.kov .agenda__head-mark svg{width:18px; height:18px}
.kov .agenda__head-title{font-family:var(--kb-font-serif); font-size:22px; font-weight:500; letter-spacing:-.01em; line-height:1}
.kov .agenda__head-sub{display:flex; gap:14px; align-items:center; flex-wrap:wrap; margin-top:5px; font-family:var(--k-font-mono); font-size:11px; color:var(--k-c-fg-subtle); letter-spacing:.04em}
.kov .agenda__head-sub b{color:var(--k-c-fg-muted); font-weight:500}
.kov .agenda__body{display:grid; grid-template-columns:1.05fr 1fr; gap:0; flex:1; min-height:0; overflow:hidden}
.kov .agenda__left{padding:20px 24px; border-right:1px solid var(--k-c-border); overflow-y:auto}
.kov .agenda__right{padding:20px 24px; display:flex; flex-direction:column; gap:14px; min-height:0}
.kov .cal__head{display:flex; align-items:center; gap:8px; margin-bottom:14px}
.kov .cal__title{font-family:var(--kb-font-serif); font-size:20px; font-weight:500; letter-spacing:-.01em; flex:1}
.kov .cal__title em{font-style:italic; color:var(--k-c-fg-muted); margin-left:6px; font-weight:400; font-size:.8em}
.kov .cal__nav{width:32px; height:32px; border-radius:8px; display:flex; align-items:center; justify-content:center; color:var(--k-c-fg-muted); transition:all var(--k-m-fast)}
.kov .cal__nav:hover{background:var(--k-c-bg-3); color:var(--k-c-fg)}
.kov .cal__nav svg{width:14px; height:14px}
.kov .cal__weekdays{display:grid; grid-template-columns:repeat(7,1fr); font-family:var(--k-font-mono); font-size:10px; font-weight:600; text-transform:uppercase; letter-spacing:.08em; color:var(--k-c-fg-dim); margin-bottom:6px; text-align:center}
.kov .cal__weekdays span{padding:6px 0}
.kov .cal__days{display:grid; grid-template-columns:repeat(7,1fr); gap:2px}
.kov .cal__day{aspect-ratio:1/1; display:flex; flex-direction:column; align-items:center; justify-content:center; border-radius:8px; font-family:var(--k-font-mono); font-size:13px; font-weight:500; color:var(--k-c-fg-muted); position:relative; transition:all var(--k-m-fast); cursor:pointer}
.kov .cal__day:hover{background:var(--k-c-bg-3); color:var(--k-c-fg)}
.kov .cal__day--out{color:var(--k-c-fg-dim); opacity:.5; cursor:default}
.kov .cal__day--out:hover{background:transparent; color:var(--k-c-fg-dim)}
.kov .cal__day--past{color:var(--k-c-fg-dim); text-decoration:line-through; opacity:.5; cursor:default}
.kov .cal__day--past:hover{background:transparent; color:var(--k-c-fg-dim)}
.kov .cal__day--today{color:var(--k-c-fg); font-weight:700}
.kov .cal__day--today::after{content:""; position:absolute; bottom:5px; width:4px; height:4px; border-radius:50%; background:var(--k-brand-blue)}
.kov .cal__day[data-selected]{background:var(--k-grad-h); color:#fff; font-weight:700}
.kov .cal__day[data-selected]::after{display:none}
.kov .cal__day-slots{position:absolute; top:3px; right:5px; font-size:8.5px; color:var(--k-brand-green); font-weight:700; letter-spacing:0}
.kov .cal__day[data-selected] .cal__day-slots{color:rgba(255,255,255,.85)}
.kov .cal__legend{display:flex; gap:14px; align-items:center; flex-wrap:wrap; margin-top:18px; padding-top:14px; border-top:1px solid var(--k-c-border); font-family:var(--k-font-mono); font-size:10.5px; color:var(--k-c-fg-subtle); letter-spacing:.02em}
.kov .cal__legend-item{display:inline-flex; align-items:center; gap:5px}
.kov .cal__legend-dot{width:6px; height:6px; border-radius:50%}
.kov .cal__legend-dot--avail{background:var(--k-brand-green)}
.kov .cal__legend-dot--today{background:var(--k-brand-blue)}
.kov .cal__legend-dot--sel{background:var(--k-grad-h)}
.kov .slots{display:flex; flex-direction:column; gap:6px; flex:1; min-height:0; overflow-y:auto; padding-right:4px; scrollbar-width:thin; scrollbar-color:rgba(255,255,255,.18) transparent}
.kov .slots::-webkit-scrollbar{width:6px}
.kov .slots::-webkit-scrollbar-thumb{background:rgba(255,255,255,.18); border-radius:3px}
.kov .slots__head{position:sticky; top:0; z-index:1; background:var(--k-c-bg-1); font-family:var(--k-font-mono); font-size:10px; text-transform:uppercase; letter-spacing:.14em; font-weight:700; color:var(--k-c-fg-subtle); padding-bottom:6px; margin-bottom:0}
.kov .slots__head b{color:var(--k-c-fg)}
.kov .slot{display:flex; align-items:center; padding:9px 14px; border-radius:8px; background:var(--k-c-bg-2); border:1px solid var(--k-c-border); font-family:var(--k-font-mono); font-size:13px; font-weight:600; color:var(--k-c-fg); cursor:pointer; transition:all var(--k-m-fast)}
.kov .slot:hover{background:var(--k-c-bg-3); border-color:var(--k-c-border-strong)}
.kov .slot[data-selected]{background:var(--k-c-bg-3); border-color:var(--k-brand-green); box-shadow:0 0 0 1px rgba(0,204,34,.3)}
.kov .slot__time{flex:1}
.kov .slot__tz{font-size:10px; font-weight:500; color:var(--k-c-fg-dim); letter-spacing:.04em}
.kov .agenda__form{display:flex; flex-direction:column; gap:10px; padding-top:14px; border-top:1px solid var(--k-c-border); margin-top:6px; flex-shrink:0}
.kov .field{display:flex; flex-direction:column; gap:5px}
.kov .field__row{display:grid; grid-template-columns:1fr 1fr; gap:10px}
.kov .field__lbl{font-family:var(--k-font-mono); font-size:10px; text-transform:uppercase; letter-spacing:.12em; font-weight:600; color:var(--k-c-fg-subtle)}
.kov .field input, .kov .field select{padding:10px 12px; background:var(--k-c-bg-2); border:1px solid var(--k-c-border); border-radius:8px; color:var(--k-c-fg); font:inherit; font-size:13.5px; transition:border var(--k-m-fast)}
.kov .field input:focus, .kov .field select:focus{outline:none; border-color:var(--k-c-border-strong)}
.kov .field input::placeholder{color:var(--k-c-fg-dim)}
.kov .field select{appearance:none; background-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%2385858C" stroke-width="2" stroke-linecap="round"><path d="M6 9l6 6 6-6"/></svg>'); background-position:right 12px center; background-repeat:no-repeat; background-size:12px; padding-right:32px}
.kov .agenda__submit{display:flex; align-items:center; gap:10px; padding:14px 24px; border-top:1px solid var(--k-c-border); flex-shrink:0}
.kov .agenda__foot{flex-shrink:0; display:flex; gap:7px; flex-wrap:wrap; align-items:center; justify-content:center; padding:10px 24px 14px; font-family:var(--k-font-mono); font-size:11px; color:var(--k-c-fg-dim); letter-spacing:.04em; border-top:1px solid var(--k-c-border)}
.kov .agenda__summary{flex:1; font-family:var(--k-font-mono); font-size:11.5px; color:var(--k-c-fg-subtle); letter-spacing:.02em}
.kov .agenda__summary b{color:var(--k-c-fg); font-weight:600}
.kov .agenda__btn{display:inline-flex; align-items:center; gap:7px; padding:11px 20px; border-radius:8px; background:var(--k-grad-h); color:#fff; font-size:13.5px; font-weight:600; transition:all var(--k-m-fast)}
.kov .agenda__btn:hover{filter:brightness(1.08); transform:translateY(-1px)}
.kov .agenda__btn svg{width:12px; height:12px}

/* ── OVERLAY 4 · LOGIN (iframe a indexlog.php embed) ── */
.kov--login{width:420px; padding:0; overflow:hidden}
.kov .login__frame{width:100%; height:580px; max-height:calc(100dvh - 110px); border:0; display:block; background:transparent}
/* legacy login__* (form a mano) reemplazado por iframe — reglas abajo quedan inertes */
.kov .login__brand{display:flex; justify-content:center; margin-bottom:6px}
.kov .login__brand-mark{width:52px; height:52px; border-radius:14px; background:var(--kb-grad-d); display:flex; align-items:center; justify-content:center; color:#fff; font-family:var(--kb-font-serif); font-size:32px; font-weight:500; line-height:1; letter-spacing:-.04em; font-style:italic; box-shadow:0 8px 24px -8px rgba(0,129,226,.55), 0 0 0 1px rgba(255,255,255,.10) inset}
.kov .login__title{font-family:var(--kb-font-serif); font-size:28px; font-weight:500; text-align:center; letter-spacing:-.02em; line-height:1.1; margin-top:18px}
.kov .login__sub{text-align:center; font-size:13px; color:var(--k-c-fg-muted); margin-top:6px}
.kov .login__sub a{color:var(--k-brand-blue); font-weight:500}
.kov .login__sub a:hover{text-decoration:underline}
.kov .login__form{display:flex; flex-direction:column; gap:10px; margin-top:28px}
.kov .login__field{position:relative}
.kov .login__field-lbl{position:absolute; top:-7px; left:12px; padding:0 6px; font-family:var(--k-font-mono); font-size:10px; text-transform:uppercase; letter-spacing:.12em; font-weight:600; color:var(--k-c-fg-subtle); background:var(--k-c-bg-1)}
.kov .login__field input{width:100%; padding:14px; background:var(--k-c-bg-2); border:1px solid var(--k-c-border); border-radius:9px; color:var(--k-c-fg); font:inherit; font-size:14px; transition:border var(--k-m-fast)}
.kov .login__field input:focus{outline:none; border-color:var(--k-c-border-strong)}
.kov .login__field input::placeholder{color:var(--k-c-fg-dim)}
.kov .login__field--password input{padding-right:48px}
.kov .login__field-toggle{position:absolute; right:10px; top:50%; transform:translateY(-50%); width:32px; height:32px; border-radius:7px; display:flex; align-items:center; justify-content:center; color:var(--k-c-fg-subtle)}
.kov .login__field-toggle:hover{color:var(--k-c-fg); background:var(--k-c-bg-3)}
.kov .login__field-toggle svg{width:14px; height:14px}
.kov .login__row{display:flex; align-items:center; justify-content:space-between; font-size:12.5px; color:var(--k-c-fg-muted); margin-top:4px}
.kov .login__remember{display:inline-flex; align-items:center; gap:6px; cursor:pointer}
.kov .login__remember input{accent-color:var(--k-brand-green)}
.kov .login__forgot{color:var(--k-brand-blue); font-weight:500}
.kov .login__forgot:hover{text-decoration:underline}
.kov .login__submit{width:100%; display:inline-flex; align-items:center; justify-content:center; gap:7px; margin-top:14px; padding:14px 18px; border-radius:9px; background:var(--k-grad-h); color:#fff; font-size:14px; font-weight:600; transition:all var(--k-m-fast)}
.kov .login__submit:hover{filter:brightness(1.08); transform:translateY(-1px)}
.kov .login__submit svg{width:13px; height:13px}
.kov .login__or{display:flex; align-items:center; gap:12px; margin:18px 0 14px; font-family:var(--k-font-mono); font-size:10px; text-transform:uppercase; letter-spacing:.14em; color:var(--k-c-fg-dim); font-weight:600}
.kov .login__or::before, .kov .login__or::after{content:""; flex:1; height:1px; background:var(--k-c-border)}
.kov .login__sso{display:grid; grid-template-columns:1fr 1fr 1fr; gap:8px}
.kov .login__sso-btn{display:flex; align-items:center; justify-content:center; gap:6px; padding:11px 12px; border-radius:8px; background:var(--k-c-bg-2); border:1px solid var(--k-c-border); color:var(--k-c-fg-muted); font-size:12px; font-weight:500; transition:all var(--k-m-fast)}
.kov .login__sso-btn:hover{background:var(--k-c-bg-3); color:var(--k-c-fg); border-color:var(--k-c-border-strong)}
.kov .login__sso-btn svg{width:14px; height:14px; flex-shrink:0}
.kov .login__foot{display:flex; align-items:center; gap:7px; justify-content:center; flex-wrap:wrap; margin-top:22px; padding-top:18px; border-top:1px solid var(--k-c-border); font-family:var(--k-font-mono); font-size:11px; color:var(--k-c-fg-dim); letter-spacing:.04em}
.kov .login__foot-logo{height:13px; width:auto; display:block; opacity:.92}

/* ── OVERLAY responsive ── */
@media (max-width:840px){
  .kov--agenda{width:calc(100vw - 24px); overflow-y:auto}
  .kov .agenda__body{display:block; flex:none; overflow:visible}
  .kov .agenda__left{border-right:0; border-bottom:1px solid var(--k-c-border)}
  /* días del calendario más pequeños (capados y centrados) */
  .kov .cal__days, .kov .cal__weekdays{max-width:300px; margin-left:auto; margin-right:auto}
  .kov .cal__day{font-size:12px}
  /* franja de horas el doble de alto, con scroll propio */
  .kov .slots{flex:none; height:240px; overflow-y:auto}
}
@media (max-width:600px){
  .kov{max-height:calc(100dvh - 100px); width:calc(100vw - 16px) !important}
  .kov--voice{padding:32px 22px 22px}
  .kov .voice__orb{width:220px; height:220px; margin-bottom:24px}
  .kov .voice__orb-core{font-size:60px}
  .kov .voice__transcript{font-size:19px}
  .kov--chat{height:calc(100dvh - 100px)}
  .kov--login{padding:32px 24px 22px}
  .kov .login__sso{grid-template-columns:1fr 1fr}
  .kov .login__sso-btn:nth-child(3){grid-column:1/-1}
}
