/* HISAB_SALMAN_AGENT_FRONTEND_V7 */
.salman-v7-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: fit-content;
  margin-top: 5px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #065f46;
  background: #d1fae5;
  border: 1px solid #a7f3d0;
  font-size: .62rem;
  font-weight: 850;
  letter-spacing: .08em;
}

.salman-v7-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #10b981;
  box-shadow: 0 0 0 4px rgba(16,185,129,.12);
}

.salman-v7-chat {
  scroll-behavior: smooth;
}

.salman-v7-thinking p {
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 22px;
}

.salman-v7-thinking i {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #16a34a;
  animation: salman-v7-dot 1s ease-in-out infinite;
}

.salman-v7-thinking i:nth-child(2) { animation-delay: .14s; }
.salman-v7-thinking i:nth-child(3) { animation-delay: .28s; }

@keyframes salman-v7-dot {
  0%, 80%, 100% { transform: translateY(0); opacity: .35; }
  40% { transform: translateY(-5px); opacity: 1; }
}

#voiceButton.salman-v7-connecting,
#voiceButton.salman-v7-live {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

#voiceButton.salman-v7-connecting::before,
#voiceButton.salman-v7-live::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset: -70%;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    rgba(16,185,129,.12),
    rgba(59,130,246,.75),
    rgba(168,85,247,.72),
    rgba(16,185,129,.82),
    rgba(16,185,129,.12)
  );
  animation: salman-v7-orbit 1.6s linear infinite;
}

#voiceButton.salman-v7-live {
  box-shadow:
    0 0 0 1px rgba(255,255,255,.2) inset,
    0 0 0 5px rgba(16,185,129,.10),
    0 14px 35px rgba(5,150,105,.22);
}

#voiceButton.salman-v7-live .voice-mic-shell {
  animation: salman-v7-mic-pulse 1.15s ease-in-out infinite;
}

body.salman-v7-user-speaking #voiceButton.salman-v7-live {
  box-shadow:
    0 0 0 1px rgba(255,255,255,.25) inset,
    0 0 0 8px rgba(34,197,94,.13),
    0 0 38px rgba(59,130,246,.28),
    0 18px 45px rgba(5,150,105,.26);
}

@keyframes salman-v7-orbit {
  to { transform: rotate(360deg); }
}

@keyframes salman-v7-mic-pulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 0 rgba(255,255,255,0)); }
  50% { transform: scale(1.12); filter: drop-shadow(0 0 10px rgba(255,255,255,.75)); }
}

.salman-v7-confirm-actions {
  margin-top: 10px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.salman-v7-confirm-actions button {
  min-width: 110px;
}

#voiceStatus.processing .voice-status-dot {
  background: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245,158,11,.13);
  animation: salman-v7-status-pulse 1s ease-in-out infinite;
}

#voiceStatus.listening .voice-status-dot {
  background: #3b82f6;
  box-shadow: 0 0 0 4px rgba(59,130,246,.13);
  animation: salman-v7-status-pulse .7s ease-in-out infinite;
}

#voiceStatus.error .voice-status-dot {
  background: #dc2626;
  box-shadow: 0 0 0 4px rgba(220,38,38,.10);
}

@keyframes salman-v7-status-pulse {
  0%, 100% { transform: scale(.9); opacity: .6; }
  50% { transform: scale(1.25); opacity: 1; }
}

@media (max-width: 700px) {
  .salman-v7-badge {
    font-size: .56rem;
    padding: 3px 7px;
  }

  #voiceButton.salman-v7-live {
    min-height: 74px;
  }

  .salman-v7-confirm-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .salman-v7-confirm-actions button {
    width: 100%;
    min-width: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .salman-v7-thinking i,
  #voiceButton.salman-v7-connecting::before,
  #voiceButton.salman-v7-live::before,
  #voiceButton.salman-v7-live .voice-mic-shell,
  #voiceStatus .voice-status-dot {
    animation: none !important;
  }
}
