#kenzaFab {
  position: fixed;
  left: 24px;
  right: auto;
  bottom: 24px;
  width: 68px;
  height: 68px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #111827, #2563eb);
  color: #fff;
  font-size: 28px;
  cursor: pointer;
  z-index: 99999;
  box-shadow: 0 14px 34px rgba(0,0,0,.25);
  transition: transform .2s ease, box-shadow .2s ease;
}
#kenzaFab:hover { transform: scale(1.04); }
#kenzaFab.active {
  background: linear-gradient(135deg, #b91c1c, #ef4444);
  box-shadow: 0 0 0 8px rgba(239,68,68,.14), 0 14px 34px rgba(0,0,0,.3);
}

#kenzaPanel {
  position: fixed;
  left: 24px;
  right: auto;
  bottom: 104px;
  width: 390px;
  max-width: calc(100vw - 32px);
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 16px 44px rgba(0,0,0,.18);
  z-index: 99998;
  display: none;
}
#kenzaPanel.open { display: block; }

.kenza-head {
  padding: 14px 16px;
  background: #111827;
  color: #fff;
  font-weight: 700;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.kenza-close {
  background: transparent;
  color: #fff;
  border: none;
  font-size: 20px;
  cursor: pointer;
}
.kenza-body {
  padding: 14px;
}
.kenza-status {
  font-size: 13px;
  color: #4b5563;
  margin-bottom: 10px;
}
.kenza-transcript {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 12px;
  min-height: 120px;
  max-height: 220px;
  overflow: auto;
  font-size: 14px;
  line-height: 1.5;
}
.kenza-line { margin-bottom: 8px; }
.kenza-line strong { color: #2563eb; }
.kenza-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.kenza-btn {
  border: none;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  font-size: 13px;
}
.kenza-btn-primary {
  background: #2563eb;
  color: #fff;
}
.kenza-btn-secondary {
  background: #e5e7eb;
  color: #111827;
}
.kenza-results {
  margin-top: 12px;
  max-height: 300px;
  overflow: auto;
}
.kenza-card {
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 10px;
  background: #fff;
}
.kenza-card img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 8px;
}
.kenza-card h4 {
  margin: 0 0 6px;
  font-size: 15px;
}
.kenza-meta {
  font-size: 13px;
  color: #4b5563;
}
.kenza-card-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}
.kenza-link-btn {
  display: inline-block;
  padding: 8px 10px;
  border-radius: 10px;
  text-decoration: none;
  background: #111827;
  color: #fff;
  font-size: 13px;
}
.kenza-link-btn.alt {
  background: #2563eb;
}
@media (max-width: 768px) {
  #kenzaFab {
    left: 16px;
    bottom: 16px;
    width: 62px;
    height: 62px;
    font-size: 24px;
  }

  #kenzaPanel {
    left: 16px;
    right: 16px;
    bottom: 88px;
    width: auto;
    max-width: none;
  }
}
.kenza-live-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 150px;
  justify-content: center;
  position: relative;
  transition: all .25s ease;
}

.kenza-live-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffffff;
  position: relative;
  flex: 0 0 12px;
}

.kenza-live-label {
  font-weight: 600;
  letter-spacing: .2px;
}

.kenza-live-btn.is-live {
  background: linear-gradient(135deg, #b91c1c, #ef4444);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(239, 68, 68, 0.12);
}

.kenza-live-btn.is-live .kenza-live-dot {
  background: #fff;
  box-shadow: 0 0 0 0 rgba(255,255,255,.7);
  animation: kenzaPulse 1.2s infinite;
}

.kenza-live-btn.is-live::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 14px;
  border: 1px solid rgba(239, 68, 68, 0.25);
  animation: kenzaRing 1.8s infinite;
  pointer-events: none;
}

.kenza-live-btn.is-busy {
  opacity: .75;
  pointer-events: none;
}

#kenzaStopBtn:disabled,
#kenzaStartBtn:disabled {
  opacity: .6;
  cursor: not-allowed;
}

@keyframes kenzaPulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(255,255,255,.75);
  }
  70% {
    transform: scale(1.08);
    box-shadow: 0 0 0 10px rgba(255,255,255,0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(255,255,255,0);
  }
}

@keyframes kenzaRing {
  0% {
    transform: scale(1);
    opacity: .5;
  }
  100% {
    transform: scale(1.08);
    opacity: 0;
  }
}
#kenzaFab.active {
  background: linear-gradient(135deg, #b91c1c, #ef4444);
  box-shadow: 0 0 0 8px rgba(239,68,68,.15), 0 14px 34px rgba(0,0,0,.3);
  animation: kenzaFabPulse 1.4s infinite;
}

@keyframes kenzaFabPulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.06); }
  100% { transform: scale(1); }
}