/* Fase 43 — OracleVoiceOverlay + Orbe Neural (dock inferior) */
.omni-voice-dock {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9970;
  display: flex;
  justify-content: center;
  padding: 0.5rem 0.75rem max(0.5rem, env(safe-area-inset-bottom));
  pointer-events: none;
}

.omni-voice-dock__inner {
  pointer-events: auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: end;
  gap: 0.35rem;
  width: min(24rem, 100%);
  padding: 0.45rem 0.65rem;
  border-radius: 1.25rem 1.25rem 0 0;
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-bottom: none;
  background: rgba(10, 12, 16, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.45);
}

[data-theme='pearl'] .omni-voice-dock__inner {
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(37, 99, 235, 0.15);
}

.omni-voice-dock__link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  padding: 0.35rem;
  font-size: 0.55rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  text-decoration: none;
}

.omni-voice-dock__link--active {
  color: #22d3ee;
}

.omni-neural-orb-wrap {
  display: flex;
  justify-content: center;
  margin-top: -1.75rem;
}

.omni-neural-orb {
  width: 4.25rem;
  height: 4.25rem;
  border-radius: 50%;
  border: 2px solid rgba(34, 211, 238, 0.45);
  background: radial-gradient(circle at 35% 30%, #1e293b 0%, #020617 65%, #000 100%);
  box-shadow:
    0 0 24px rgba(34, 211, 238, 0.35),
    0 0 48px rgba(251, 191, 36, 0.12),
    inset 0 0 20px rgba(34, 211, 238, 0.15);
  cursor: pointer;
  touch-action: manipulation;
  animation: omniOrbPulse 2.4s ease-in-out infinite;
  position: relative;
}

.omni-neural-orb::before {
  content: '';
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.35), transparent 70%);
}

.omni-neural-orb.is-listening {
  animation: omniOrbListen 0.8s ease-in-out infinite;
  border-color: rgba(251, 191, 36, 0.7);
  box-shadow:
    0 0 36px rgba(251, 191, 36, 0.45),
    0 0 64px rgba(34, 211, 238, 0.35);
}

.omni-neural-orb.is-speaking {
  border-color: rgba(52, 211, 153, 0.6);
  box-shadow: 0 0 40px rgba(52, 211, 153, 0.35);
}

@keyframes omniOrbPulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.04);
  }
}

@keyframes omniOrbListen {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.08);
  }
}

.oracle-voice-overlay {
  position: fixed;
  inset: 0;
  z-index: 9988;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 1rem;
  padding-bottom: 6.5rem;
  background: rgba(2, 6, 23, 0.75);
  backdrop-filter: blur(6px);
}

.oracle-voice-overlay.hidden {
  display: none;
}

.oracle-voice-panel {
  width: min(26rem, 100%);
  max-height: min(70vh, 32rem);
  overflow-y: auto;
  border-radius: 1.25rem;
  border: 1px solid rgba(34, 211, 238, 0.25);
  background: rgba(15, 23, 42, 0.95);
  padding: 1rem;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}

[data-theme='pearl'] .oracle-voice-panel {
  background: rgba(255, 255, 255, 0.97);
  color: #0f172a;
}

.oracle-voice-panel__title {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #22d3ee;
}

.oracle-voice-panel__transcript {
  margin-top: 0.75rem;
  min-height: 2.5rem;
  font-size: 0.85rem;
  color: #e2e8f0;
  line-height: 1.45;
}

[data-theme='pearl'] .oracle-voice-panel__transcript {
  color: #334155;
}

.oracle-voice-panel__triage {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.25);
  font-size: 0.8rem;
}

.oracle-voice-panel__triage--critico {
  border-color: rgba(244, 63, 94, 0.45);
  background: rgba(127, 29, 29, 0.35);
}

.oracle-voice-panel__auxilios {
  margin-top: 0.5rem;
  padding-left: 1rem;
  font-size: 0.75rem;
  color: #fecdd3;
}

.oracle-voice-panel__actions {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.oracle-voice-panel__btn {
  flex: 1;
  min-height: 2.75rem;
  border-radius: 0.75rem;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  border: 1px solid rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.12);
  color: #a5f3fc;
}

.oracle-voice-panel__btn--sos {
  border-color: rgba(244, 63, 94, 0.5);
  background: linear-gradient(135deg, #7f1d1d, #be123c);
  color: #fff;
}

.oracle-voice-panel__btn--ghost {
  background: transparent;
  color: #94a3b8;
}

body.omni-has-voice-dock {
  padding-bottom: 5.5rem;
}

body.omni-has-voice-dock [data-emergencia-247],
body.omni-has-voice-dock .omni-sos-panico.is-visible {
  bottom: 6.25rem;
}

body.omni-has-voice-dock .omni-health-fab {
  bottom: 6.5rem;
}

@media (min-width: 640px) {
  body.omni-has-voice-dock {
    padding-bottom: 4.5rem;
  }
}
