/* ZAP GFibra - acabamento visual além do Tailwind CDN */
:root {
  --ww-green-dark: #075e54;
  --ww-green: #25d366;
  --ww-soft-bg: #eef7f4;
  --ww-chat-pattern: rgba(7, 94, 84, 0.055);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  overflow: hidden;
}

button,
input,
textarea,
select {
  font: inherit;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(37, 211, 102, 0.35);
  outline-offset: 2px;
}

.app-h {
  height: 100vh;
  height: 100dvh;
}

.chat-pattern {
  background-color: #eef7f4;
  background-image:
    radial-gradient(circle at 12px 12px, var(--ww-chat-pattern) 1.8px, transparent 2px),
    radial-gradient(circle at 40px 40px, rgba(37, 211, 102, 0.045) 1.8px, transparent 2px);
  background-size: 52px 52px;
}

.dark .chat-pattern {
  background-color: #0f172a;
  background-image:
    radial-gradient(circle at 12px 12px, rgba(37, 211, 102, 0.08) 1.8px, transparent 2px),
    radial-gradient(circle at 40px 40px, rgba(18, 140, 126, 0.08) 1.8px, transparent 2px);
}

.scrollbar-thin {
  scrollbar-width: thin;
  scrollbar-color: rgba(20, 184, 166, 0.45) transparent;
}

.scrollbar-thin::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.scrollbar-thin::-webkit-scrollbar-track {
  background: transparent;
}

.scrollbar-thin::-webkit-scrollbar-thumb {
  background: rgba(20, 184, 166, 0.38);
  border-radius: 999px;
}

.glass {
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(18px);
}

.dark .glass {
  background: rgba(15, 23, 42, 0.76);
}

.safe-bottom {
  padding-bottom: max(1rem, env(safe-area-inset-bottom));
}

.message-tail-me::after {
  content: "";
  position: absolute;
  right: -7px;
  top: 12px;
  width: 14px;
  height: 14px;
  background: inherit;
  transform: rotate(45deg);
  border-radius: 2px;
}

.message-tail-other::after {
  content: "";
  position: absolute;
  left: -7px;
  top: 12px;
  width: 14px;
  height: 14px;
  background: inherit;
  transform: rotate(45deg);
  border-radius: 2px;
}

.file-drop {
  border: 1.5px dashed rgba(20, 184, 166, 0.35);
  transition: border-color .2s ease, background .2s ease, transform .2s ease;
}

.file-drop:hover {
  border-color: rgba(37, 211, 102, 0.75);
  background: rgba(16, 185, 129, 0.06);
  transform: translateY(-1px);
}

.status-ring {
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(135deg, #25D366, #128C7E, #6EE7B7) border-box;
  border: 3px solid transparent;
}

.dark .status-ring {
  background:
    linear-gradient(#0f172a, #0f172a) padding-box,
    linear-gradient(135deg, #25D366, #128C7E, #6EE7B7) border-box;
}

@media (max-width: 767px) {
  body {
    overflow: hidden;
  }
}


/* -------------------------------------------------------------------------- */
/* Correções de responsividade do header principal                            */
/* Mantém logo, ações e abas dentro da tela em celulares pequenos.             */
/* -------------------------------------------------------------------------- */
html,
body,
#app {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

.dashboard-shell,
#sidebar,
#chat-panel {
  min-width: 0;
  max-width: 100vw;
}

.dashboard-header {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  padding: 1rem;
}

.dashboard-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  min-width: 0;
}

.dashboard-brand {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 0.75rem;
}

.dashboard-logo {
  width: 3rem;
  height: 3rem;
  flex: 0 0 auto;
}

.dashboard-title {
  min-width: 0;
}

.dashboard-title h1 {
  font-size: 1.25rem;
}

.dashboard-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: flex-end;
  gap: 0.375rem;
}

.dashboard-icon-btn {
  width: 2.5rem;
  height: 2.5rem;
  flex: 0 0 auto;
}

.dashboard-profile-btn {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
}

.dashboard-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.375rem;
  width: 100%;
  min-width: 0;
  margin-top: 1rem;
  border-radius: 1.5rem;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.5rem;
}

.dashboard-tab {
  min-width: 0;
  overflow: hidden;
  padding: 0.75rem 0.5rem;
  line-height: 1;
}

.dashboard-tab-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-tab-indicator {
  bottom: -0.25rem;
  height: 0.25rem;
  width: 2.5rem;
}

@media (max-width: 430px) {
  .dashboard-header {
    padding: 0.875rem;
  }

  .dashboard-logo {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 1rem;
  }

  .dashboard-title h1 {
    font-size: 1.125rem;
  }

  .dashboard-actions {
    gap: 0.35rem;
  }

  .dashboard-icon-btn {
    width: 2.35rem;
    height: 2.35rem;
    border-radius: 1rem;
  }

  .dashboard-tabs {
    gap: 0.25rem;
    padding: 0.4rem;
    border-radius: 1.35rem;
  }

  .dashboard-tab {
    gap: 0.35rem;
    padding: 0.72rem 0.35rem;
    border-radius: 1rem;
    font-size: 0.78rem;
  }
}

@media (max-width: 360px) {
  .dashboard-header {
    padding: 0.75rem;
  }

  .dashboard-top {
    gap: 0.5rem;
  }

  .dashboard-brand {
    gap: 0.55rem;
  }

  .dashboard-logo {
    width: 2.45rem;
    height: 2.45rem;
    font-size: 1.2rem;
  }

  .dashboard-title h1 {
    font-size: 1rem;
  }

  .dashboard-title p {
    display: none;
  }

  .dashboard-icon-btn {
    width: 2.15rem;
    height: 2.15rem;
    font-size: 0.95rem;
  }

  .dashboard-profile-btn .relative {
    width: 2.15rem;
    height: 2.15rem;
  }

  .dashboard-tabs {
    margin-top: 0.85rem;
  }

  .dashboard-tab {
    gap: 0.25rem;
    padding-inline: 0.25rem;
    font-size: 0.72rem;
  }

  .dashboard-tab-indicator {
    width: 2rem;
  }
}

@media (max-width: 320px) {
  .dashboard-tab-icon {
    display: none;
  }

  .dashboard-tab {
    font-size: 0.7rem;
  }
}


/* Áudios e transcrição */
.audio-player {
  min-width: 210px;
  height: 38px;
  border-radius: 999px;
}

@media (max-width: 430px) {
  .audio-player {
    min-width: 180px;
  }

  #chat-start-audio {
    width: 2.75rem;
    height: 2.75rem;
  }
}

/* -------------------------------------------------------------------------- */
/* Identidade GFibra: logo oficial carregada em splash, login, header e avatar */
/* -------------------------------------------------------------------------- */
.gfibra-brand-logo,
.gfibra-avatar-g {
  display: grid;
  place-items: center;
  overflow: hidden;
  background: transparent;
}

.gfibra-brand-logo {
  border-radius: 1.5rem;
}

.gfibra-avatar-g {
  border-radius: 999px;
  background: #1e3a5a;
}

.gfibra-brand-logo-image,
.gfibra-avatar-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.gfibra-avatar-image {
  object-fit: contain;
}

.dashboard-tabs {
  grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
}

/* -------------------------------------------------------------------------- */
/* Botões centrais das ações IXC: segunda via e liberação por confiança         */
/* -------------------------------------------------------------------------- */
.ixc-action-only-panel {
  width: 100%;
  min-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1.25rem, 4vw, 3rem);
}

.ixc-action-center-box {
  width: min(86vw, 760px);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
}


.ixc-fixed-welcome-message {
  margin-bottom: clamp(1rem, 3vw, 1.5rem);
}

.ixc-fixed-welcome-message > .flex {
  justify-content: flex-start;
}

.ixc-fixed-welcome-message article {
  max-width: min(100%, 720px);
}

.ixc-main-action-button {
  width: 100%;
  min-height: clamp(7.5rem, 18vh, 11rem);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: clamp(2rem, 5vw, 3.5rem);
  background: #128c7e;
  padding: clamp(1.6rem, 4.5vw, 3rem) clamp(1.5rem, 6vw, 4rem);
  color: #ffffff;
  text-align: center;
  font-size: clamp(1.35rem, 3.3vw, 2.4rem);
  font-weight: 950;
  line-height: 1.18;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.22);
  cursor: pointer;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease;
}

.ixc-main-action-button:hover {
  background: #075e54;
  transform: translateY(-2px);
  box-shadow: 0 24px 55px rgba(15, 23, 42, 0.28);
}

.ixc-main-action-button:active {
  transform: translateY(0);
}

.ixc-main-action-button:disabled {
  cursor: wait;
  opacity: .78;
  transform: none;
}

@media (max-width: 480px) {
  .ixc-action-only-panel {
    padding: 1rem;
  }

  .ixc-action-center-box {
    width: 100%;
  }

  
.ixc-fixed-welcome-message {
  margin-bottom: clamp(1rem, 3vw, 1.5rem);
}

.ixc-fixed-welcome-message > .flex {
  justify-content: flex-start;
}

.ixc-fixed-welcome-message article {
  max-width: min(100%, 720px);
}

.ixc-main-action-button {
    min-height: 7rem;
    padding: 1.35rem 1.1rem;
    border-radius: 2rem;
    font-size: clamp(1.15rem, 6vw, 1.55rem);
  }
}


/* -------------------------------------------------------------------------- */
/* Visualização interna do boleto IXC dentro do ZAP GFibra                     */
/* -------------------------------------------------------------------------- */
.ixc-boleto-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: clamp(0.5rem, 2vw, 1.25rem);
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(10px);
}

.ixc-boleto-modal {
  width: min(1180px, 100%);
  height: min(94dvh, 920px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border-radius: clamp(1rem, 2.5vw, 2rem);
  background: #f8fafc;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.38);
}

.ixc-boleto-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(15, 23, 42, 0.12);
  background: #ffffff;
}

.ixc-boleto-modal-header h2 {
  margin: 0;
  color: #0f172a;
  font-size: 1rem;
  font-weight: 950;
}

.ixc-boleto-modal-header p {
  margin: 0.15rem 0 0;
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 700;
}

.ixc-boleto-modal-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
}

.ixc-boleto-modal-actions button {
  border: 0;
  border-radius: 999px;
  padding: 0.7rem 0.95rem;
  background: #128c7e;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 950;
  cursor: pointer;
}

.ixc-boleto-modal-actions button[data-ixc-close-boleto] {
  background: #e2e8f0;
  color: #0f172a;
}

.ixc-boleto-frame {
  width: 100%;
  height: 100%;
  border: 0;
  background: #eef2f7;
}

@media (max-width: 640px) {
  .ixc-boleto-overlay {
    padding: 0;
  }

  .ixc-boleto-modal {
    width: 100%;
    height: 100dvh;
    border-radius: 0;
  }

  .ixc-boleto-modal-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .ixc-boleto-modal-actions {
    width: 100%;
  }

  .ixc-boleto-modal-actions button {
    flex: 1 1 auto;
  }
}

/* -------------------------------------------------------------------------- */
/* Identidade visual final dos temas                                           */
/* Tema claro: Roxo / Violeta Cyber. Tema escuro: Antracite / Grafite.         */
/* -------------------------------------------------------------------------- */
:root {
  --cyber-950: #1e063f;
  --cyber-900: #2e1065;
  --cyber-850: #3b0f7f;
  --cyber-800: #4c1d95;
  --cyber-700: #5b21b6;
  --cyber-600: #7c3aed;
  --cyber-500: #8b5cf6;
  --cyber-400: #a78bfa;
  --cyber-300: #c4b5fd;
  --cyber-200: #ddd6fe;
  --cyber-100: #ede9fe;
  --cyber-50: #f5f3ff;
  --cyber-cyan: #22d3ee;
  --cyber-pink: #ec4899;

  --graphite-950: #09090b;
  --graphite-925: #101012;
  --graphite-900: #18181b;
  --graphite-850: #1f1f23;
  --graphite-800: #27272a;
  --graphite-750: #303034;
  --graphite-700: #3f3f46;
  --graphite-600: #52525b;
  --graphite-400: #a1a1aa;
  --graphite-300: #d4d4d8;
  --graphite-200: #e4e4e7;

  --ww-green-dark: var(--cyber-900);
  --ww-green: var(--cyber-600);
  --ww-soft-bg: var(--cyber-50);
  --ww-chat-pattern: rgba(124, 58, 237, 0.08);
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline-color: rgba(124, 58, 237, 0.36);
}

/* Ajusta as classes utilitárias principais do sistema para o tema claro cyber. */
html:not(.dark) .bg-whats-500,
html:not(.dark) .bg-whats-600,
html:not(.dark) .bg-whats-700,
html:not(.dark) .bg-whats-800,
html:not(.dark) .bg-whats-900 {
  background-color: var(--cyber-700) !important;
}

html:not(.dark) .hover\:bg-whats-700:hover,
html:not(.dark) .hover\:bg-whats-800:hover {
  background-color: var(--cyber-800) !important;
}

html:not(.dark) .bg-whats-50,
html:not(.dark) .bg-emerald-50 {
  background-color: var(--cyber-50) !important;
}

html:not(.dark) .bg-whats-100,
html:not(.dark) .bg-emerald-100 {
  background-color: var(--cyber-100) !important;
}

html:not(.dark) .text-whats-600,
html:not(.dark) .text-whats-700,
html:not(.dark) .text-whats-800 {
  color: var(--cyber-700) !important;
}

html:not(.dark) .border-whats-200\/70,
html:not(.dark) .border-emerald-100,
html:not(.dark) .border-emerald-200 {
  border-color: rgba(124, 58, 237, 0.22) !important;
}

html:not(.dark) .focus\:border-whats-500:focus {
  border-color: rgba(124, 58, 237, 0.68) !important;
}

html:not(.dark) .focus\:ring-emerald-100:focus {
  --tw-ring-color: rgba(124, 58, 237, 0.18) !important;
}

html:not(.dark) .from-whats-900 {
  --tw-gradient-from: #2e1065 var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgb(46 16 101 / 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

html:not(.dark) .from-whats-800 {
  --tw-gradient-from: #3b0f7f var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgb(59 15 127 / 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

html:not(.dark) .from-whats-700 {
  --tw-gradient-from: #5b21b6 var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgb(91 33 182 / 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

html:not(.dark) .to-whats-500,
html:not(.dark) .to-whats-600,
html:not(.dark) .to-whats-700 {
  --tw-gradient-to: #8b5cf6 var(--tw-gradient-to-position) !important;
}

html:not(.dark) body {
  background:
    radial-gradient(circle at 10% 8%, rgba(139, 92, 246, 0.28), transparent 30%),
    radial-gradient(circle at 88% 14%, rgba(34, 211, 238, 0.18), transparent 32%),
    radial-gradient(circle at 76% 88%, rgba(236, 72, 153, 0.12), transparent 30%),
    linear-gradient(135deg, #f5f3ff 0%, #eef2ff 42%, #faf5ff 100%);
}

html:not(.dark) .dashboard-shell {
  background:
    radial-gradient(circle at top left, rgba(124, 58, 237, 0.30), transparent 31%),
    radial-gradient(circle at bottom right, rgba(34, 211, 238, 0.20), transparent 34%),
    linear-gradient(135deg, #f3e8ff 0%, #eef2ff 48%, #fdf4ff 100%) !important;
}

html:not(.dark) .dashboard-shell > section {
  background: rgba(255, 255, 255, 0.94) !important;
  border: 1px solid rgba(124, 58, 237, 0.18);
  box-shadow: 0 30px 90px rgba(46, 16, 101, 0.18), 0 0 0 1px rgba(255, 255, 255, 0.70) inset;
}

html:not(.dark) .dashboard-header {
  background:
    radial-gradient(circle at 84% 16%, rgba(34, 211, 238, 0.26), transparent 27%),
    radial-gradient(circle at 18% 92%, rgba(236, 72, 153, 0.16), transparent 28%),
    linear-gradient(135deg, #2e1065 0%, #5b21b6 46%, #7c3aed 100%) !important;
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.16), 0 16px 38px rgba(46, 16, 101, 0.22);
}

html:not(.dark) .dashboard-tabs {
  background: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

html:not(.dark) .dashboard-tab.bg-white,
html:not(.dark) .dashboard-tab[class*="bg-white"] {
  background: linear-gradient(135deg, #ffffff 0%, #f5f3ff 100%) !important;
  color: var(--cyber-800) !important;
  box-shadow: 0 12px 26px rgba(46, 16, 101, 0.18);
}

html:not(.dark) .dashboard-tab-indicator {
  background: linear-gradient(90deg, var(--cyber-cyan), var(--cyber-500), var(--cyber-pink)) !important;
  box-shadow: 0 0 18px rgba(139, 92, 246, 0.60);
}

html:not(.dark) .dashboard-icon-btn {
  background: rgba(255, 255, 255, 0.16) !important;
  color: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.13);
}

html:not(.dark) .dashboard-icon-btn:hover {
  background: rgba(255, 255, 255, 0.28) !important;
}

html:not(.dark) #sidebar {
  background: linear-gradient(180deg, #ffffff 0%, #fbfaff 45%, #f5f3ff 100%) !important;
  border-right-color: rgba(124, 58, 237, 0.20) !important;
}

html:not(.dark) #list-content {
  background:
    radial-gradient(circle at 94% 5%, rgba(34, 211, 238, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(250, 245, 255, 0.96) 100%);
}

html:not(.dark) #list-content [data-conversation-id] {
  border: 1px solid transparent;
}

html:not(.dark) #list-content [data-conversation-id]:hover,
html:not(.dark) .hover\:bg-slate-50:hover {
  background: linear-gradient(135deg, #f5f3ff 0%, #eff6ff 100%) !important;
  border-color: rgba(124, 58, 237, 0.16);
  box-shadow: 0 12px 28px rgba(46, 16, 101, 0.09);
}

html:not(.dark) #list-content [data-conversation-id].bg-emerald-50 {
  background:
    radial-gradient(circle at 92% 16%, rgba(34, 211, 238, 0.12), transparent 28%),
    linear-gradient(135deg, #ede9fe 0%, #f5f3ff 55%, #eef2ff 100%) !important;
  border-color: rgba(124, 58, 237, 0.34);
  box-shadow: 0 16px 34px rgba(91, 33, 182, 0.16);
}

html:not(.dark) #sidebar footer {
  background: rgba(255, 255, 255, 0.78);
  border-top-color: rgba(124, 58, 237, 0.18) !important;
  color: #7c6b9e !important;
}

html:not(.dark) #chat-panel {
  background: #f3efff !important;
}

html:not(.dark) #chat-panel > header {
  background:
    radial-gradient(circle at 94% 12%, rgba(34, 211, 238, 0.12), transparent 22%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, #f5f3ff 58%, #ede9fe 100%) !important;
  border-bottom-color: rgba(124, 58, 237, 0.20) !important;
  box-shadow: 0 12px 30px rgba(46, 16, 101, 0.08);
}

html:not(.dark) .chat-pattern {
  background-color: #f4efff;
  background-image:
    radial-gradient(circle at 12px 12px, rgba(91, 33, 182, 0.10) 1.9px, transparent 2px),
    radial-gradient(circle at 40px 40px, rgba(34, 211, 238, 0.09) 1.9px, transparent 2px),
    radial-gradient(circle at 80% 14%, rgba(236, 72, 153, 0.07), transparent 28%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.56), rgba(221, 214, 254, 0.24));
  background-size: 52px 52px, 52px 52px, auto, auto;
}

html:not(.dark) .message-tail-me {
  background:
    radial-gradient(circle at 92% 12%, rgba(34, 211, 238, 0.22), transparent 24%),
    linear-gradient(135deg, #5b21b6 0%, #7c3aed 54%, #9333ea 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 16px 32px rgba(91, 33, 182, 0.26), 0 0 0 1px rgba(255, 255, 255, 0.10) inset;
}

html:not(.dark) .message-tail-other {
  background: linear-gradient(135deg, #ffffff 0%, #faf5ff 100%) !important;
  color: #24143d !important;
  border: 1px solid rgba(124, 58, 237, 0.12);
  box-shadow: 0 12px 30px rgba(46, 16, 101, 0.08);
}

html:not(.dark) #chat-panel > footer {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.97) 0%, #fbfaff 100%) !important;
  border-top-color: rgba(124, 58, 237, 0.20) !important;
  box-shadow: 0 -14px 34px rgba(46, 16, 101, 0.08);
}

html:not(.dark) #message-form label[for="message-file"],
html:not(.dark) #chat-start-audio {
  background: linear-gradient(135deg, #ffffff 0%, #f3e8ff 100%) !important;
  color: var(--cyber-700) !important;
  border: 1px solid rgba(124, 58, 237, 0.20);
  box-shadow: 0 10px 24px rgba(46, 16, 101, 0.10);
}

html:not(.dark) #message-form label[for="message-file"]:hover,
html:not(.dark) #chat-start-audio:hover {
  background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%) !important;
  transform: translateY(-1px);
}

html:not(.dark) #message-text,
html:not(.dark) #global-search,
html:not(.dark) #contact-search,
html:not(.dark) #broadcast-search,
html:not(.dark) textarea,
html:not(.dark) input[type="search"],
html:not(.dark) input[type="text"],
html:not(.dark) input[type="email"],
html:not(.dark) input[type="password"] {
  background: #ffffff !important;
  border-color: rgba(124, 58, 237, 0.22) !important;
  color: #24143d !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 10px 26px rgba(46, 16, 101, 0.08);
}

html:not(.dark) #message-text::placeholder,
html:not(.dark) #global-search::placeholder,
html:not(.dark) #contact-search::placeholder,
html:not(.dark) #broadcast-search::placeholder,
html:not(.dark) textarea::placeholder,
html:not(.dark) input::placeholder {
  color: #9f8fbc !important;
}

html:not(.dark) #message-text:focus,
html:not(.dark) #global-search:focus,
html:not(.dark) #contact-search:focus,
html:not(.dark) #broadcast-search:focus,
html:not(.dark) textarea:focus,
html:not(.dark) input:focus {
  border-color: rgba(124, 58, 237, 0.68) !important;
  box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.16), 0 14px 30px rgba(46, 16, 101, 0.10);
}

html:not(.dark) #message-form button[type="submit"],
html:not(.dark) .ixc-main-action-button,
html:not(.dark) .ixc-boleto-modal-actions button:not([data-ixc-close-boleto]) {
  background:
    radial-gradient(circle at 86% 15%, rgba(34, 211, 238, 0.24), transparent 28%),
    linear-gradient(135deg, #5b21b6 0%, #7c3aed 55%, #9333ea 100%) !important;
  box-shadow: 0 15px 30px rgba(91, 33, 182, 0.28);
}

html:not(.dark) #message-form button[type="submit"]:hover,
html:not(.dark) .ixc-main-action-button:hover,
html:not(.dark) .ixc-boleto-modal-actions button:not([data-ixc-close-boleto]):hover {
  background:
    radial-gradient(circle at 86% 15%, rgba(34, 211, 238, 0.30), transparent 28%),
    linear-gradient(135deg, #6d28d9 0%, #8b5cf6 55%, #a855f7 100%) !important;
}

html:not(.dark) [data-flowchat-option] {
  background: linear-gradient(135deg, #ede9fe 0%, #f5f3ff 100%) !important;
  border-color: rgba(124, 58, 237, 0.30) !important;
  color: var(--cyber-800) !important;
}

html:not(.dark) [data-flowchat-option]:hover {
  background: linear-gradient(135deg, #ddd6fe 0%, #ede9fe 100%) !important;
}

html:not(.dark) .status-ring {
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    linear-gradient(135deg, var(--cyber-cyan), var(--cyber-600), var(--cyber-pink)) border-box;
}

html:not(.dark) .scrollbar-thin {
  scrollbar-color: rgba(124, 58, 237, 0.52) rgba(124, 58, 237, 0.08);
}

html:not(.dark) .scrollbar-thin::-webkit-scrollbar-thumb {
  background: rgba(124, 58, 237, 0.52);
}

html:not(.dark) .scrollbar-thin::-webkit-scrollbar-track {
  background: rgba(124, 58, 237, 0.08);
  border-radius: 999px;
}

/* Tema escuro grafite / antracite: neutro, profundo e com alto contraste. */
.dark body,
.dark .dashboard-shell {
  background:
    radial-gradient(circle at 12% 10%, rgba(63, 63, 70, 0.28), transparent 30%),
    radial-gradient(circle at 88% 20%, rgba(82, 82, 91, 0.16), transparent 28%),
    linear-gradient(135deg, var(--graphite-950) 0%, var(--graphite-900) 48%, #0c0c0f 100%) !important;
  color: var(--graphite-200);
}

.dark .dashboard-shell > section {
  background: var(--graphite-900) !important;
  border: 1px solid rgba(82, 82, 91, 0.48);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.52), 0 0 0 1px rgba(255, 255, 255, 0.035) inset;
}

.dark #sidebar,
.dark #list-content,
.dark #chat-panel {
  background: var(--graphite-900) !important;
}

.dark .dashboard-header {
  background:
    radial-gradient(circle at 86% 14%, rgba(113, 113, 122, 0.18), transparent 28%),
    linear-gradient(135deg, #111113 0%, #1f1f23 52%, #303034 100%) !important;
  color: #ffffff;
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.07), 0 16px 36px rgba(0, 0, 0, 0.34);
}

.dark .dashboard-tabs {
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.045);
}

.dark .dashboard-tab.bg-slate-900,
.dark .dashboard-tab[class*="dark:bg-slate-900"] {
  background: linear-gradient(135deg, #303034 0%, #1f1f23 100%) !important;
  color: #f4f4f5 !important;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.34);
}

.dark .dashboard-tab-indicator {
  background: linear-gradient(90deg, #d4d4d8, #71717a) !important;
  box-shadow: 0 0 18px rgba(212, 212, 216, 0.18);
}

.dark .dashboard-icon-btn {
  background: rgba(255, 255, 255, 0.07) !important;
  color: #f4f4f5 !important;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07);
}

.dark .dashboard-icon-btn:hover {
  background: rgba(255, 255, 255, 0.12) !important;
}

.dark #sidebar {
  border-right-color: rgba(82, 82, 91, 0.55) !important;
}

.dark #list-content [data-conversation-id] {
  border: 1px solid transparent;
}

.dark #list-content [data-conversation-id]:hover,
.dark .dark\:hover\:bg-slate-900:hover,
.dark .dark\:hover\:bg-slate-800:hover {
  background: linear-gradient(135deg, #232327 0%, #2c2c31 100%) !important;
  border-color: rgba(113, 113, 122, 0.28);
}

.dark #list-content [data-conversation-id].dark\:bg-emerald-950\/30,
.dark #list-content [data-conversation-id][class*="emerald-950"] {
  background: linear-gradient(135deg, #2b2b30 0%, #202024 100%) !important;
  border-color: rgba(161, 161, 170, 0.24) !important;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
}

.dark #sidebar footer,
.dark #chat-panel > header,
.dark #chat-panel > footer {
  background: rgba(24, 24, 27, 0.96) !important;
  border-color: rgba(82, 82, 91, 0.55) !important;
  box-shadow: none;
}

.dark .chat-pattern {
  background-color: #141417;
  background-image:
    radial-gradient(circle at 12px 12px, rgba(161, 161, 170, 0.075) 1.7px, transparent 2px),
    radial-gradient(circle at 40px 40px, rgba(82, 82, 91, 0.10) 1.7px, transparent 2px),
    linear-gradient(135deg, rgba(39, 39, 42, 0.62), rgba(9, 9, 11, 0.70));
  background-size: 52px 52px, 52px 52px, auto;
}

.dark .message-tail-me {
  background: linear-gradient(135deg, #52525b 0%, #3f3f46 52%, #27272a 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.32), 0 0 0 1px rgba(255, 255, 255, 0.055) inset;
}

.dark .message-tail-other {
  background: linear-gradient(135deg, #202024 0%, #18181b 100%) !important;
  color: #f4f4f5 !important;
  border: 1px solid rgba(82, 82, 91, 0.56);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
}

.dark #message-form label[for="message-file"],
.dark #chat-start-audio,
.dark .dark\:bg-slate-800,
.dark .dark\:bg-slate-900,
.dark .dark\:bg-slate-950 {
  background-color: var(--graphite-850) !important;
  color: var(--graphite-200) !important;
  border-color: rgba(82, 82, 91, 0.58) !important;
}

.dark #message-form label[for="message-file"]:hover,
.dark #chat-start-audio:hover,
.dark .dark\:hover\:bg-slate-700:hover,
.dark .dark\:hover\:bg-slate-800:hover {
  background-color: var(--graphite-750) !important;
}

.dark #message-text,
.dark #global-search,
.dark #contact-search,
.dark #broadcast-search,
.dark textarea,
.dark input[type="search"],
.dark input[type="text"],
.dark input[type="email"],
.dark input[type="password"] {
  background: #121214 !important;
  border-color: rgba(82, 82, 91, 0.62) !important;
  color: #f4f4f5 !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 10px 26px rgba(0, 0, 0, 0.22);
}

.dark #message-text::placeholder,
.dark #global-search::placeholder,
.dark #contact-search::placeholder,
.dark #broadcast-search::placeholder,
.dark textarea::placeholder,
.dark input::placeholder {
  color: #71717a !important;
}

.dark #message-text:focus,
.dark #global-search:focus,
.dark #contact-search:focus,
.dark #broadcast-search:focus,
.dark textarea:focus,
.dark input:focus {
  border-color: rgba(161, 161, 170, 0.76) !important;
  box-shadow: 0 0 0 4px rgba(113, 113, 122, 0.20), 0 14px 30px rgba(0, 0, 0, 0.26);
}

.dark #message-form button[type="submit"],
.dark .ixc-main-action-button,
.dark .ixc-boleto-modal-actions button:not([data-ixc-close-boleto]),
.dark .bg-whats-500,
.dark .bg-whats-600,
.dark .bg-whats-700,
.dark .bg-whats-800,
.dark .bg-whats-900 {
  background: linear-gradient(135deg, #52525b 0%, #3f3f46 55%, #27272a 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.34);
}

.dark #message-form button[type="submit"]:hover,
.dark .ixc-main-action-button:hover,
.dark .ixc-boleto-modal-actions button:not([data-ixc-close-boleto]):hover,
.dark .hover\:bg-whats-700:hover,
.dark .hover\:bg-whats-800:hover {
  background: linear-gradient(135deg, #63636d 0%, #52525b 55%, #303034 100%) !important;
}

.dark .text-whats-300,
.dark .text-whats-500,
.dark .text-whats-600,
.dark .text-whats-700,
.dark .text-whats-800,
.dark [class*="dark:text-whats"] {
  color: #d4d4d8 !important;
}

.dark .bg-whats-50,
.dark .bg-whats-100,
.dark .bg-emerald-50,
.dark .bg-emerald-100,
.dark .dark\:bg-emerald-950\/40,
.dark .dark\:bg-emerald-950\/30 {
  background-color: rgba(63, 63, 70, 0.42) !important;
}

.dark .border-whats-200\/70,
.dark .dark\:border-whats-500\/30,
.dark .dark\:border-emerald-900\/40 {
  border-color: rgba(113, 113, 122, 0.42) !important;
}

.dark [data-flowchat-option] {
  background: linear-gradient(135deg, #27272a 0%, #202024 100%) !important;
  border-color: rgba(113, 113, 122, 0.48) !important;
  color: #f4f4f5 !important;
}

.dark [data-flowchat-option]:hover {
  background: linear-gradient(135deg, #303034 0%, #27272a 100%) !important;
}

.dark .glass {
  background: rgba(24, 24, 27, 0.80) !important;
}

.dark .status-ring {
  background:
    linear-gradient(var(--graphite-900), var(--graphite-900)) padding-box,
    linear-gradient(135deg, #a1a1aa, #52525b, #27272a) border-box;
}

.dark .scrollbar-thin {
  scrollbar-color: rgba(113, 113, 122, 0.62) rgba(39, 39, 42, 0.62);
}

.dark .scrollbar-thin::-webkit-scrollbar-thumb {
  background: rgba(113, 113, 122, 0.62);
}

.dark .scrollbar-thin::-webkit-scrollbar-track {
  background: rgba(39, 39, 42, 0.62);
  border-radius: 999px;
}



/* -------------------------------------------------------------------------- */
/* Correção final: tema claro sem áreas brancas                               */
/* O modo claro agora usa superfícies Roxo/Violeta Cyber em todo o layout.     */
/* Mantém o tema escuro grafite/antracite intacto usando apenas :not(.dark).   */
/* -------------------------------------------------------------------------- */
html:not(.dark) {
  color-scheme: light;
}

html:not(.dark) body,
html:not(.dark) .dashboard-shell {
  background:
    radial-gradient(circle at 8% 8%, rgba(236, 72, 153, 0.22), transparent 28%),
    radial-gradient(circle at 88% 12%, rgba(34, 211, 238, 0.20), transparent 30%),
    radial-gradient(circle at 54% 86%, rgba(124, 58, 237, 0.30), transparent 38%),
    linear-gradient(135deg, #d8c7ff 0%, #c7b2ff 42%, #e2ccff 100%) !important;
  color: #23103f;
}

html:not(.dark) .dashboard-shell > section {
  background:
    radial-gradient(circle at 92% 2%, rgba(34, 211, 238, 0.16), transparent 24%),
    linear-gradient(135deg, #e4d8ff 0%, #d8c7ff 48%, #cdb7ff 100%) !important;
  border-color: rgba(91, 33, 182, 0.34) !important;
  box-shadow: 0 30px 90px rgba(46, 16, 101, 0.24), 0 0 0 1px rgba(167, 139, 250, 0.24) inset !important;
}

html:not(.dark) #sidebar {
  background:
    radial-gradient(circle at 12% 0%, rgba(236, 72, 153, 0.14), transparent 26%),
    linear-gradient(180deg, #e7dcff 0%, #dccdff 46%, #cbb6ff 100%) !important;
  border-right-color: rgba(91, 33, 182, 0.34) !important;
}

html:not(.dark) #list-content {
  background:
    radial-gradient(circle at 92% 8%, rgba(34, 211, 238, 0.14), transparent 26%),
    radial-gradient(circle at 14% 92%, rgba(236, 72, 153, 0.10), transparent 28%),
    linear-gradient(180deg, #e6dbff 0%, #d9c9ff 52%, #cdb8ff 100%) !important;
}

html:not(.dark) #chat-panel {
  background:
    radial-gradient(circle at 92% 8%, rgba(34, 211, 238, 0.13), transparent 25%),
    linear-gradient(180deg, #e4d8ff 0%, #d6c5ff 100%) !important;
}

html:not(.dark) #chat-panel > header,
html:not(.dark) #chat-panel > footer,
html:not(.dark) #sidebar footer {
  background:
    radial-gradient(circle at 94% 8%, rgba(34, 211, 238, 0.16), transparent 24%),
    linear-gradient(135deg, #e1d4ff 0%, #d2bfff 58%, #c4adff 100%) !important;
  border-color: rgba(91, 33, 182, 0.32) !important;
  box-shadow: 0 12px 30px rgba(46, 16, 101, 0.12) !important;
}

html:not(.dark) .chat-pattern {
  background-color: #dacaff !important;
  background-image:
    radial-gradient(circle at 12px 12px, rgba(91, 33, 182, 0.20) 1.9px, transparent 2px),
    radial-gradient(circle at 40px 40px, rgba(34, 211, 238, 0.18) 1.9px, transparent 2px),
    radial-gradient(circle at 84% 10%, rgba(236, 72, 153, 0.13), transparent 28%),
    linear-gradient(135deg, #e7dcff 0%, #d5c3ff 48%, #cbb6ff 100%) !important;
  background-size: 52px 52px, 52px 52px, auto, auto;
}

html:not(.dark) #list-content [data-conversation-id] {
  background: transparent !important;
  border: 1px solid transparent;
}

html:not(.dark) #list-content [data-conversation-id]:hover,
html:not(.dark) .hover\:bg-slate-50:hover,
html:not(.dark) .hover\:bg-slate-100:hover,
html:not(.dark) .hover\:bg-slate-200:hover {
  background:
    radial-gradient(circle at 92% 16%, rgba(34, 211, 238, 0.16), transparent 28%),
    linear-gradient(135deg, #d8c7ff 0%, #c5afff 100%) !important;
  border-color: rgba(91, 33, 182, 0.28) !important;
  box-shadow: 0 14px 30px rgba(46, 16, 101, 0.12) !important;
}

html:not(.dark) #list-content [data-conversation-id].bg-emerald-50,
html:not(.dark) #list-content [data-conversation-id][class*="bg-emerald-50"] {
  background:
    radial-gradient(circle at 92% 16%, rgba(34, 211, 238, 0.20), transparent 28%),
    linear-gradient(135deg, #d7c5ff 0%, #c2a8ff 52%, #b99cff 100%) !important;
  border-color: rgba(91, 33, 182, 0.48) !important;
  box-shadow: 0 18px 38px rgba(91, 33, 182, 0.20) !important;
}

html:not(.dark) .bg-white,
html:not(.dark) .bg-slate-50,
html:not(.dark) .bg-slate-100,
html:not(.dark) .bg-emerald-50,
html:not(.dark) .bg-whats-50 {
  background-color: #e1d4ff !important;
}

html:not(.dark) .bg-white\/95,
html:not(.dark) .bg-white\/90,
html:not(.dark) .bg-white\/80,
html:not(.dark) .bg-white\/70,
html:not(.dark) .glass {
  background: rgba(225, 212, 255, 0.92) !important;
  backdrop-filter: blur(18px);
}

html:not(.dark) .focus\:bg-white:focus {
  background-color: #eadfff !important;
}

html:not(.dark) .message-tail-other {
  background:
    radial-gradient(circle at 12% 8%, rgba(34, 211, 238, 0.10), transparent 24%),
    linear-gradient(135deg, #eadfff 0%, #dccdff 100%) !important;
  color: #23103f !important;
  border-color: rgba(91, 33, 182, 0.22) !important;
  box-shadow: 0 14px 30px rgba(46, 16, 101, 0.12) !important;
}

html:not(.dark) .message-tail-me {
  background:
    radial-gradient(circle at 92% 12%, rgba(34, 211, 238, 0.26), transparent 24%),
    linear-gradient(135deg, #4c1d95 0%, #7c3aed 54%, #a855f7 100%) !important;
}

html:not(.dark) #message-form label[for="message-file"],
html:not(.dark) #chat-start-audio,
html:not(.dark) #message-text,
html:not(.dark) #global-search,
html:not(.dark) #contact-search,
html:not(.dark) #broadcast-search,
html:not(.dark) textarea,
html:not(.dark) input[type="search"],
html:not(.dark) input[type="text"],
html:not(.dark) input[type="email"],
html:not(.dark) input[type="password"] {
  background: linear-gradient(135deg, #eadfff 0%, #ddceff 100%) !important;
  border-color: rgba(91, 33, 182, 0.30) !important;
  color: #241046 !important;
  box-shadow: inset 0 1px 0 rgba(196, 181, 253, 0.42), 0 10px 26px rgba(46, 16, 101, 0.12) !important;
}

html:not(.dark) #message-text::placeholder,
html:not(.dark) #global-search::placeholder,
html:not(.dark) #contact-search::placeholder,
html:not(.dark) #broadcast-search::placeholder,
html:not(.dark) textarea::placeholder,
html:not(.dark) input::placeholder {
  color: #8062b6 !important;
}

html:not(.dark) [data-flowchat-option] {
  background: linear-gradient(135deg, #dfd0ff 0%, #cbb6ff 100%) !important;
  border-color: rgba(91, 33, 182, 0.36) !important;
  color: #2e1065 !important;
}

html:not(.dark) [data-flowchat-option]:hover {
  background: linear-gradient(135deg, #cdb8ff 0%, #b99cff 100%) !important;
}

html:not(.dark) .status-ring {
  background:
    linear-gradient(#e1d4ff, #e1d4ff) padding-box,
    linear-gradient(135deg, var(--cyber-cyan), var(--cyber-600), var(--cyber-pink)) border-box !important;
}

html:not(.dark) .dashboard-tab.bg-white,
html:not(.dark) .dashboard-tab[class*="bg-white"] {
  background: linear-gradient(135deg, #d8c7ff 0%, #c4adff 100%) !important;
  color: #2e1065 !important;
}

html:not(.dark) #sidebar footer {
  color: #5b3f93 !important;
}

html:not(.dark) .text-slate-900,
html:not(.dark) .text-slate-800,
html:not(.dark) .text-slate-700 {
  color: #20103a !important;
}

html:not(.dark) .text-slate-500,
html:not(.dark) .text-slate-400 {
  color: #6d5896 !important;
}
