/* ============================================================================
   FLAG OS V1.9 — HUD (FASE 2)
   Tactical components: cards, rarities, micro-interactions
   ============================================================================ */

/* ============================================================================
   Dashboard — Agent Tiles (grid nativo, 4x3)
   ============================================================================ */

.agent-tiles {
  margin-top: 18px;
  margin-bottom: 18px;
}

.agent-tiles-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.agent-tiles-title {
  font-family: var(--font-secondary);
  font-weight: 900;
  letter-spacing: -0.02em;
}

.agent-tiles-subtitle {
  color: var(--text-tertiary);
  font-size: 13px;
}

/* T9: Espaçamento maior entre agent tiles */
.agent-tiles-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px; /* T9: Aumentado de 22px para 28px */
  width: 100%;
}

@media (max-width: 860px) {
  .agent-tiles-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .agent-tiles-grid {
    grid-template-columns: 1fr;
  }
}

/* T9+T10: Tiles menores, bordas padronizadas, animação de entrada */
.agent-tile.config-card {
  position: relative;
  width: 100%;
  aspect-ratio: 1.1 / 1; /* T9: Mais retangular = menor altura */
  border-radius: 16px; /* T10: Bordas mais arredondadas padronizadas */
  padding: 12px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;

  /* T10: Borda gradiente padronizada para todos os cards */
  background:
    linear-gradient(180deg, rgba(20, 20, 25, 0.95), rgba(15, 15, 20, 0.9)) padding-box,
    linear-gradient(135deg,
      rgba(var(--color-primary-rgb), 0.3),
      rgba(var(--color-secondary-rgb), 0.2),
      rgba(var(--color-primary-rgb), 0.25)
    ) border-box;
  border: 1px solid transparent;

  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.40),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  cursor: pointer;
  text-align: center;
  align-items: center;

  transition:
    transform 250ms cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1),
    border-color 250ms ease,
    background 250ms ease,
    opacity 400ms ease;

  /* T9: Animação staggered de entrada alternada */
  opacity: 0;
  transform: translateY(20px);
  animation: tile-slide-in 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Light mode */
body[data-mode="light"] .agent-tile.config-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(250, 250, 252, 0.95)) padding-box,
    linear-gradient(135deg,
      rgba(var(--color-primary-rgb), 0.25),
      rgba(var(--color-secondary-rgb), 0.15),
      rgba(var(--color-primary-rgb), 0.2)
    ) border-box;
}

/* Animações staggered - cada tile entra com delay */
.agent-tile.config-card:nth-child(1) { animation-delay: 0ms; }
.agent-tile.config-card:nth-child(2) { animation-delay: 50ms; }
.agent-tile.config-card:nth-child(3) { animation-delay: 100ms; }
.agent-tile.config-card:nth-child(4) { animation-delay: 150ms; }
.agent-tile.config-card:nth-child(5) { animation-delay: 200ms; }
.agent-tile.config-card:nth-child(6) { animation-delay: 250ms; }
.agent-tile.config-card:nth-child(7) { animation-delay: 300ms; }
.agent-tile.config-card:nth-child(8) { animation-delay: 350ms; }

@keyframes tile-slide-in {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.agent-tile.config-card:hover {
  transform: translateY(-3px);
  border-color: rgba(var(--color-primary-rgb), 0.28);
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.5),
    var(--glow-soft),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

/* Microparallax (feature-flagged, desktop only) */
@media (pointer: fine) {
  body[data-ux="v1"] .agent-tile.config-card:hover {
    /* Evita “blur”/texto embaçado causado por transform 3D no hover */
    transform: translateY(-3px) scale(1.01);
  }
}

.agent-tile.config-card:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px rgba(var(--color-secondary-rgb), 0.35),
    0 0 0 6px rgba(var(--color-primary-rgb), 0.12),
    0 22px 70px rgba(0, 0, 0, 0.55);
}

.agent-tile-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  position: relative;
  overflow: hidden;
  margin-bottom: 6px;
}

body[data-ux="v1"] .agent-avatar-slot {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0.95;
  pointer-events: none;
  filter:
    drop-shadow(0 0 10px rgba(var(--color-secondary-rgb), 0.16))
    drop-shadow(0 0 16px rgba(var(--color-primary-rgb), 0.12));
}

body[data-ux="v1"] .agent-avatar-slot img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0.9;
}

.agent-tile-icon svg {
  width: 22px;
  height: 22px;
}

.agent-tile-title {
  font-family: var(--font-secondary);
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
  line-height: 1.05;
  font-size: 18px;
}

.agent-tile-subtitle {
  margin-top: 2px;
  font-size: 14px;
  color: var(--text-tertiary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============================================================================
   P2 — Agent Presence (mensagens vivas + FX + cockpit + neural lines)
   ============================================================================ */

.agent-presence-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: calc(var(--z-modal) - 1);
}

/* ============================================================================
   System Pulse (feature-flagged)
   ============================================================================ */

.system-pulse {
  position: fixed;
  left: calc(50% + (var(--sidebar-w) * 0.5));
  right: auto;
  bottom: 14px;
  height: 48px;
  border-radius: 999px;
  width: min(980px, calc(100vw - var(--sidebar-w) - 36px));
  background: rgba(10, 10, 12, 0.55);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 18px 60px rgba(0,0,0,0.45), var(--glow-soft);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  overflow: hidden;
  z-index: calc(var(--z-modal-backdrop) - 2);
  transform: translateX(-50%);
  /* 🚫 Desativado por enquanto (estava interferindo com cliques no ZEUS) */
  display: none !important;
  pointer-events: none;
}

.sidebar-collapsed .system-pulse {
  left: calc(50% + (var(--sidebar-w-collapsed) * 0.5));
  width: min(980px, calc(100vw - var(--sidebar-w-collapsed) - 36px));
}

@media (max-width: 860px) {
  .system-pulse {
    left: 50%;
    width: min(980px, calc(100vw - 36px));
  }
}

.system-pulse-track {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(var(--color-primary-rgb), 0.10),
    rgba(var(--color-secondary-rgb), 0.10),
    rgba(var(--color-primary-rgb), 0.10)
  );
  opacity: 0.55;
  filter: blur(10px);
  transform: translateX(-30%);
  animation: pulseTrack 6s linear infinite;
}

@keyframes pulseTrack {
  from { transform: translateX(-40%); }
  to { transform: translateX(40%); }
}

.system-pulse-text {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  align-items: center;
  padding: 0 18px;
  font-family: var(--font-primary);
  font-size: 14px;
  letter-spacing: 0.04em;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}


.agent-live-message {
  position: fixed;
  left: 50%;
  top: calc(var(--topbar-h) + 12px);
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(10, 10, 12, 0.55);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 18px 60px rgba(0,0,0,0.45), var(--glow-soft);
  backdrop-filter: blur(10px) saturate(150%);
  -webkit-backdrop-filter: blur(10px) saturate(150%);
}

.agent-live-message.hidden { display: none; }

.alm-chip {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 800;
  color: #000;
  background: var(--gradient-primary);
  box-shadow: 0 0 0 1px rgba(var(--color-primary-rgb), 0.22), var(--glow-soft);
}

.alm-text {
  font-size: 13px;
  color: var(--text-secondary);
  max-width: min(740px, calc(100vw - 140px));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Vox: wave bars - apenas no tile do VOX */
.vox-wave {
  position: absolute;
  right: 10px;
  bottom: 10px;
  display: grid;
  grid-auto-flow: column;
  gap: 3px;
  opacity: 0.9;
}

/* Ocultar vox-wave em tiles que não são VOX */
.agent-tile:not([data-pilar="vox"]) .vox-wave {
  display: none !important;
}
.vox-wave span {
  width: 3px;
  height: 8px;
  border-radius: 3px;
  background: rgba(var(--color-primary-rgb), 0.9);
  box-shadow: 0 0 10px rgba(var(--color-primary-rgb), 0.25);
}

/* Atlas: radial glow layer - apenas no tile do ATLAS */
.atlas-radial {
  position: absolute;
  inset: -40%;
  border-radius: 999px;
  background: radial-gradient(circle at 40% 30%, rgba(var(--color-secondary-rgb), 0.22), transparent 60%);
  opacity: 0.65;
  pointer-events: none;
  filter: blur(12px);
  z-index: 0;
}

/* Ocultar atlas-radial em tiles que não são ATLAS */
.agent-tile:not([data-pilar="atlas"]) .atlas-radial {
  display: none !important;
}

.agent-tile { position: relative; overflow: hidden; }
.agent-tile > * { position: relative; z-index: 1; }

/* Cockpit panel (direita) */
.cockpit-panel {
  position: fixed;
  right: 18px;
  top: calc(var(--topbar-h) + 18px);
  width: 280px;
  border-radius: 22px;
  padding: 14px;
  background:
    radial-gradient(900px 420px at 0% 0%, rgba(var(--color-primary-rgb), 0.10), transparent 55%),
    linear-gradient(180deg, rgba(10,10,12,0.62), rgba(10,10,12,0.34));
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 20px 70px rgba(0,0,0,0.45);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  z-index: calc(var(--z-sticky) + 1);
}

.cockpit-header {
  display: flex;
  gap: 12px;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.cockpit-avatar {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  overflow: hidden;
}

.avatar-orb {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.95), rgba(var(--color-primary-rgb),0.55) 55%, rgba(0,0,0,0) 70%);
  filter: blur(0.2px);
  box-shadow: 0 0 18px rgba(var(--color-primary-rgb), 0.28);
}

.cockpit-client {
  font-family: var(--font-secondary);
  font-weight: 900;
  letter-spacing: -0.02em;
  font-size: 14px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

.cockpit-plan-row {
  display: flex;
  gap: 8px;
  align-items: baseline;
  margin-top: 2px;
}
.cockpit-plan-label { font-size: 11px; color: var(--text-tertiary); letter-spacing: 0.12em; text-transform: uppercase; }
.cockpit-plan { font-size: 12px; color: var(--color-primary); }

.cockpit-body { padding-top: 12px; }
.cockpit-active-agent {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: baseline;
  margin-bottom: 10px;
}
.cockpit-agent-label { font-size: 11px; color: var(--text-tertiary); letter-spacing: 0.12em; text-transform: uppercase; }
.cockpit-agent { font-family: var(--font-secondary); font-weight: 900; letter-spacing: 0.12em; font-size: 12px; color: var(--text-primary); }

.cockpit-progress { display: grid; gap: 10px; }
.cp-row { display: grid; grid-template-columns: 50px 1fr; gap: 10px; align-items: center; }
.cp-row span { font-size: 12px; color: var(--text-secondary); }
.cp-bar {
  height: 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  overflow: hidden;
}
.cp-fill {
  height: 100%;
  border-radius: 999px;
  width: 0%;
  background: linear-gradient(90deg, rgba(var(--color-primary-rgb),0.85), rgba(var(--color-secondary-rgb),0.85));
  box-shadow: 0 0 14px rgba(var(--color-primary-rgb), 0.18);
  transition: width 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Hide cockpit on smaller screens (não atrapalhar) */
@media (max-width: 1200px) {
  .cockpit-panel { display: none; }
}

/* Neural links SVG - DESABILITADO (causava bugs) */
.neural-links {
  display: none !important; /* Oculto completamente */
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
}
.neural-links path {
  display: none !important; /* Oculto completamente */
  fill: none;
  stroke: rgba(var(--color-primary-rgb), 0.55);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 10px rgba(var(--color-primary-rgb), 0.22));
}
.neural-links path[data-hot="1"] {
  display: none !important; /* Oculto completamente */
  stroke: rgba(var(--color-secondary-rgb), 0.75);
  filter: drop-shadow(0 0 14px rgba(var(--color-secondary-rgb), 0.32));
}

.agent-tile.active-engine {
  box-shadow:
    0 18px 36px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(var(--color-primary-rgb), 0.3);
}

/* Power ring (feature-flagged) */
@keyframes powerSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

body[data-ux="v1"] .agent-tile.active-engine::before,
body[data-ux="v1"] .agent-tile[data-state="processing"]::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: conic-gradient(
    from 0deg,
    transparent 0deg,
    rgba(var(--color-secondary-rgb), 0.0) 70deg,
    rgba(var(--color-secondary-rgb), 0.9) 120deg,
    rgba(var(--color-primary-rgb), 0.85) 160deg,
    transparent 220deg,
    transparent 360deg
  );
  opacity: 0.55;
  filter: blur(0.4px);
  animation: powerSpin 4200ms linear infinite;
  pointer-events: none;
  z-index: 0;
}

body[data-ux="v1"] .agent-tile.active-engine::after,
body[data-ux="v1"] .agent-tile[data-state="processing"]::after {
  content: "";
  position: absolute;
  inset: 1px; /* espessura da borda */
  border-radius: 9px;
  background: rgba(10, 10, 12, 0.92);
  pointer-events: none;
  z-index: 1;
}

/* garante que texto/ícones do tile sempre fiquem acima das camadas FX */
body[data-ux="v1"] .agent-tile > * {
  position: relative;
  z-index: 2;
}

/* CRONOS: remove radar/scan + “borda interna grossa” (mantém HUD border externo) */
body[data-ux="v1"] .agent-tile[data-pilar="cronos"].active-engine::before,
body[data-ux="v1"] .agent-tile[data-pilar="cronos"][data-state="processing"]::before,
body[data-ux="v1"] .agent-tile[data-pilar="cronos"].active-engine::after,
body[data-ux="v1"] .agent-tile[data-pilar="cronos"][data-state="processing"]::after {
  content: none;
}

/* CRONOS: remover também o hud-border (ele vira um “retângulo interno”) */
body[data-ux="v1"] .agent-tile[data-pilar="cronos"] .hud-border {
  display: none !important;
}

/* Unified “active power” language (feature-flagged) */
body[data-ux="v1"] .agent-tile.active-engine,
body[data-ux="v1"] .agent-tile[data-state="processing"] {
  border-color: rgba(var(--color-secondary-rgb), 0.22);
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(var(--color-secondary-rgb), 0.14),
    var(--glow-soft);
}

.hud-border {
  position: absolute;
  inset: 0;
  pointer-events: none;
  width: 100%;
  height: 100%;
  overflow: visible;
  z-index: 3;
}

/* Ocultar hud-border quando não necessário (pode causar problemas visuais) */
.agent-tile:not(.active-engine) .hud-border {
  display: none;
}

.hud-border svg {
  width: 100%;
  height: 100%;
}

.hud-border rect {
  fill: none;
  stroke: var(--color-primary);
  stroke-width: 2;
  rx: 12;
  ry: 12;
  filter:
    drop-shadow(0 0 12px rgba(var(--color-primary-rgb), 0.6))
    drop-shadow(0 0 32px rgba(var(--color-secondary-rgb), 0.35));
}

/* Cronos processing overlay (P2) */
.cronos-processing {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  gap: 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 4;
}

.cronos-processing.active { opacity: 1; }

.cronos-processing::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(600px 300px at 50% 0%, rgba(var(--color-primary-rgb), 0.16), transparent 60%),
    radial-gradient(500px 260px at 50% 100%, rgba(var(--color-secondary-rgb), 0.12), transparent 65%),
    rgba(0,0,0,0.28);
  backdrop-filter: blur(6px) saturate(140%);
  -webkit-backdrop-filter: blur(6px) saturate(140%);
}

.cronos-ring {
  width: 120px;
  height: 120px;
  z-index: 1;
  filter:
    drop-shadow(0 0 14px rgba(var(--color-primary-rgb), 0.25))
    drop-shadow(0 0 26px rgba(var(--color-secondary-rgb), 0.16));
}

.cronos-ring-track {
  fill: none;
  stroke: rgba(255,255,255,0.10);
  stroke-width: 8;
}

.cronos-ring-fill {
  fill: none;
  stroke: url(#cronosGrad);
  stroke-width: 8;
  stroke-linecap: round;
  transform: rotate(-90deg);
  transform-origin: 60px 60px;
}

.cronos-processing-text {
  z-index: 1;
  text-align: center;
}

.cpt-title {
  font-family: var(--font-secondary);
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--text-primary);
}

.cpt-sub {
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-tertiary);
}

/* ============================================================================
   Plans modal (RPG rarity)
   ============================================================================ */

.plans-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 16px;
}

@media (max-width: 1024px) {
  .plans-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
}

.plan-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: var(--space-lg);
  border-radius: var(--radius-2xl);
  background: rgba(var(--bg-secondary-rgb), 0.6);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(var(--border-color-rgb), 0.55);
  box-shadow:
    0 12px 32px rgba(0, 0, 0, 0.45),
    inset 0 0 0 1px rgba(var(--color-primary-rgb), 0.05);
  min-height: 360px;
  position: relative;
  overflow: hidden;
}

/* Permitir que o badge “MAIS COMPLETO” apareça fora do card */
.plan-card.plan-card-legendary {
  overflow: visible;
}

.plan-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at top right, rgba(var(--color-primary-rgb), 0.11), transparent 40%),
    radial-gradient(circle at bottom left, rgba(var(--color-secondary-rgb), 0.11), transparent 45%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.plan-card:hover::before {
  opacity: 1;
}

.plan-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.plan-label {
  font-size: var(--text-sm);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--text-tertiary);
}

.plan-name {
  font-family: var(--font-secondary);
  font-size: 1.5rem;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.plan-price-block {
  text-align: right;
}

.plan-price {
  font-size: 3rem;
  font-weight: var(--font-heading-weight);
  display: block;
  line-height: 1;
}

.plan-term {
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: var(--font-normal);
}

.plan-setup {
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-tertiary);
  letter-spacing: 0.02em;
}

.plan-losses {
  margin-top: 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
}

body[data-mode="light"] .plan-losses {
  background: rgba(255,255,255,0.55);
  border-color: rgba(0,0,0,0.08);
}

.plan-loss-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}

.plan-losses ul {
  margin: 0;
  padding-left: 18px;
  color: var(--text-secondary);
  font-size: 12px;
  display: grid;
  gap: 6px;
}

.plan-callout {
  font-size: var(--text-base);
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.4;
}

/* Tagline em itálico */
.plan-tagline {
  font-size: var(--text-sm);
  font-style: italic;
  color: var(--text-tertiary);
  margin: 0.5rem 0 1.5rem 0;
  text-align: center;
}

.plan-subtitle {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  margin: 0.25rem 0 0.5rem 0;
  text-align: center;
  font-weight: var(--font-semibold);
}

.plan-matrix {
  display: grid;
  gap: 10px;
}

.plan-matrix-item {
  display: flex;
  justify-content: space-between;
  font-size: var(--text-sm);
  padding: 10px 0;
  border-bottom: 1px solid rgba(var(--border-color-rgb), 0.25);
}

.plan-matrix-item:last-child {
  border-bottom: 0;
}

.plan-matrix-label {
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.7rem;
}

.plan-matrix-item strong {
  font-weight: var(--font-cta-weight);
}

/* Features como checklist */
.plan-features {
  display: grid;
  gap: 16px;
  margin: 1.5rem 0;
}

.plan-feature-item {
  display: grid;
  grid-template-columns: 24px 1fr auto;
  align-items: center;
  gap: 12px;
  font-size: var(--text-sm);
  padding: 0;
}

.plan-feature-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  font-size: 1rem;
  font-weight: var(--font-bold);
  flex-shrink: 0;
}

.plan-card-rare .plan-feature-icon {
  color: var(--color-primary);
}

.plan-card-legendary .plan-feature-icon {
  color: var(--color-secondary);
}

.plan-feature-label {
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.75rem;
  font-weight: var(--font-medium);
  min-width: 120px;
}

.plan-feature-item strong {
  color: var(--text-primary);
  font-weight: var(--font-semibold);
  text-align: right;
}

.plan-quotas {
  font-size: var(--text-sm);
  color: var(--text-primary);
  background: rgba(var(--color-primary-rgb), 0.08);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(var(--color-primary-rgb), 0.2);
}

.plan-benefit {
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: rgba(var(--color-secondary-rgb), 0.08);
  border: 1px dashed rgba(var(--color-secondary-rgb), 0.4);
}

.plan-benefit-title {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  display: block;
  color: var(--text-tertiary);
}

.plan-benefit p {
  margin: 0.35rem 0 0;
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-primary);
}

.plan-footer {
  display: flex;
  justify-content: space-between;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  border-top: 1px solid rgba(var(--border-color-rgb), 0.25);
  padding-top: 8px;
}

.plan-spark {
  color: var(--color-primary);
  font-weight: var(--font-semibold);
}

.plan-card.plan-card-common {
  border-color: rgba(var(--color-primary-rgb), 0.2);
}

.plan-card.plan-card-rare {
  border-color: rgba(var(--color-primary-rgb), 0.35);
  box-shadow:
    0 16px 36px rgba(0, 0, 0, 0.55),
    inset 0 0 0 1px rgba(var(--color-primary-rgb), 0.07);
}

.plan-card.plan-card-legendary {
  border-color: rgba(var(--color-secondary-rgb), 0.5);
  transform: scale(1.05);
  box-shadow:
    0 0 0 2px rgba(255, 215, 0, 0.4),
    0 0 40px rgba(255, 215, 0, 0.3),
    0 20px 50px rgba(0, 0, 0, 0.6),
    inset 0 0 0 1px rgba(var(--color-secondary-rgb), 0.1);
  position: relative;
  z-index: 1;
}

/* Badge "MAIS COMPLETO" no Empire */
.plan-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
  color: #000;
  font-size: 0.7rem;
  font-weight: var(--font-bold);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  padding: 0.4rem 1rem;
  border-radius: 999px;
  box-shadow: 0 4px 16px rgba(255, 215, 0, 0.5);
  z-index: 10;
}

body[data-mode="light"] .plan-card {
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow:
    0 18px 45px rgba(0, 0, 0, 0.12),
    inset 0 0 0 1px rgba(0, 0, 0, 0.04);
}

/* ============================================================================
   BOTÕES CTA DOS PLANOS
   ============================================================================ */

.plan-cta {
  width: 100%;
  padding: 1rem 2rem;
  margin-top: auto;
  border-radius: var(--radius-lg);
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 2px solid transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.plan-cta-outline {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.3);
  color: var(--text-primary);
}

.plan-cta-outline:hover {
  border-color: rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.plan-cta-primary {
  background: var(--gradient-primary);
  color: #000;
  border-color: transparent;
  box-shadow: 0 8px 24px rgba(255, 69, 0, 0.4);
}

.plan-cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(255, 69, 0, 0.5);
  filter: brightness(1.1);
}

.plan-cta-gold {
  background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
  color: #000;
  border-color: transparent;
  box-shadow: 0 8px 24px rgba(255, 215, 0, 0.4);
}

.plan-cta-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(255, 215, 0, 0.5);
  filter: brightness(1.1);
}

/* ============================================================================
   PÁGINA DE PLANOS (Landing interna premium)
   ============================================================================ */

.plans-page-header {
  max-width: 1200px;
  margin: 0 auto 3rem;
  padding-top: 1rem;
}

.plans-hero {
  text-align: center;
  padding: 2rem 0;
}

.plans-hero-title {
  font-family: var(--font-secondary);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  margin: 0 0 1rem 0;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.plans-hero-subtitle {
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 700px;
  margin: 0 auto 1.5rem;
}

.plans-current-info {
  font-size: var(--text-sm);
  color: var(--text-tertiary);
  padding: 0.75rem 1.5rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  display: inline-block;
  margin-top: 1rem;
}

.plans-current-info strong {
  color: var(--color-primary);
  font-weight: var(--font-semibold);
}

.plans-page-grid-wrapper {
  max-width: 1200px;
  margin: 0 auto;
}

.pilar-page[data-pilar="planos"] .plans-grid {
  margin-top: 0;
  margin-bottom: 3rem;
}

.plans-page-footer {
  max-width: 1200px;
  margin: 2rem auto 0;
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.plans-page-footer .btn {
  padding: 1rem 2.5rem;
  font-size: var(--text-lg);
}

/* Responsivo: página de planos */
@media (max-width: 768px) {
  .plans-hero {
    padding: 1.5rem 0;
  }

  .plans-hero-title {
    font-size: 2rem;
  }

  .plans-hero-subtitle {
    font-size: 1rem;
  }

  .plans-page-grid-wrapper {
    padding: 0 1rem;
  }

  .plans-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  /* Mobile: Empire em destaque (terceiro na ordem visual) */
  .plan-card-common {
    order: 1;
  }

  .plan-card-rare {
    order: 2;
  }

  .plan-card-legendary {
    order: 3;
    transform: scale(1.02);
  }

  .plan-price {
    font-size: 2.5rem;
  }

  .plan-features {
    gap: 14px;
  }

  .plan-feature-item {
    grid-template-columns: 20px 1fr auto;
    gap: 10px;
    font-size: 0.875rem;
  }

  .plan-feature-label {
    min-width: 100px;
    font-size: 0.7rem;
  }

  .plan-cta {
    padding: 0.875rem 1.5rem;
    font-size: 0.875rem;
  }
}

/* ============================================================================
   Soft Gate (plan differences inside the agent screen)
   ============================================================================ */

.pilar-softgate {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  max-width: 800px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;

  background:
    radial-gradient(900px 400px at 20% 0%, rgba(var(--color-primary-rgb), 0.10), transparent 55%),
    linear-gradient(180deg, rgba(15, 15, 25, 0.55), rgba(15, 15, 25, 0.34));
  border: 1px solid rgba(255,255,255,0.10);
  backdrop-filter: blur(8px) saturate(140%);
  -webkit-backdrop-filter: blur(8px) saturate(140%);
  box-shadow: 0 16px 60px rgba(0,0,0,0.35);
}

.pilar-softgate .psg-left {
  min-width: 0;
}

.pilar-softgate .psg-title {
  font-family: var(--font-secondary);
  font-weight: 900;
  letter-spacing: -0.02em;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pilar-softgate .psg-desc {
  margin-top: 2px;
  font-size: 13px;
  color: var(--text-tertiary);
  max-width: 70ch;
}

.pilar-softgate .psg-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pilar-softgate .psg-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.pilar-softgate .psg-pill {
  font-size: 11px;
  font-weight: 900;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.04);
  color: var(--text-secondary);
}

.pilar-softgate .psg-actions {
  display: flex;
  gap: 10px;
}

.pilar-softgate .psg-req-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  background: var(--gradient-primary);
  color: #0b0b0b;
  box-shadow: 0 14px 42px rgba(0,0,0,0.40), var(--hud-glow-1);
  transition: transform var(--hud-motion-fast), box-shadow var(--hud-motion-fast), filter var(--hud-motion-fast);
}
.pilar-softgate .psg-req-btn:hover {
  transform: translateY(-1px);
  filter: saturate(1.06);
  box-shadow: 0 18px 56px rgba(0,0,0,0.50), var(--hud-glow-2);
}
.pilar-softgate .psg-req-label {
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  opacity: 0.82;
}
.pilar-softgate .psg-required {
  font-family: var(--font-secondary);
  font-weight: 900;
  letter-spacing: 0.06em;
}

.soft-locked {
  opacity: 0.82;
  border-color: rgba(255,255,255,0.10) !important;
  box-shadow: none !important;
  filter: saturate(0.9);
}

.soft-locked:hover {
  transform: none !important;
}

@media (max-width: 720px) {
  .pilar-softgate { align-items: stretch; flex-direction: column; }
  .pilar-softgate .psg-right { justify-content: flex-start; }
  .pilar-softgate .psg-actions { width: 100%; }
  .pilar-softgate .psg-actions .btn { flex: 1; }
}

/* ============================================================================
   FX Layer (particles)
   ============================================================================ */

.fx-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: calc(var(--z-modal, 2000) + 5);
}

.fx-particle {
  position: absolute;
  width: 6px;
  height: 6px;
  margin-left: -3px;
  margin-top: -3px;
  border-radius: 999px;
  background: rgba(var(--color-primary-rgb), 0.95);
  box-shadow:
    0 0 14px rgba(var(--color-primary-rgb), 0.35),
    0 0 24px rgba(var(--color-secondary-rgb), 0.22);
  opacity: 0;
}

/* ============================================================================
   MIKAEL RAG PANEL - Componentes Específicos
   ============================================================================ */

/* Info Timeline (histórico de atualizações) */
.info-timeline {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.info-timeline h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-secondary);
}

.timeline-item {
  position: relative;
  padding-left: 32px;
  padding-bottom: 20px;
  border-left: 2px solid rgba(255,255,255,0.1);
}

.timeline-item:last-child {
  border-left-color: transparent;
  padding-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -6px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-primary);
  box-shadow: 0 0 12px rgba(255,200,0,0.5);
}

.timeline-content {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 12px 14px;
  transition: all 0.2s ease;
}

.timeline-content:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.12);
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.timeline-date {
  font-size: 11px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.timeline-text {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-primary);
}

.timeline-empty {
  padding: 20px;
  text-align: center;
  font-size: 13px;
  color: var(--text-tertiary);
}

/* Knowledge List (documentos RAG) */
.knowledge-list {
  margin-top: 24px;
}

.knowledge-list h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-secondary);
}

.knowledge-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  margin-bottom: 8px;
  transition: all 0.2s ease;
}

.knowledge-item:hover {
  background: rgba(255,255,255,0.05);
  border-color: rgba(255,255,255,0.12);
  transform: translateX(2px);
}

.knowledge-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,200,0,0.1);
  border-radius: 8px;
  color: var(--color-primary);
  flex-shrink: 0;
}

.knowledge-meta {
  flex: 1;
  min-width: 0;
}

.knowledge-meta h5 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.knowledge-stats {
  font-size: 11px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.knowledge-actions {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.knowledge-empty {
  padding: 24px;
  text-align: center;
  font-size: 13px;
  color: var(--text-tertiary);
  border: 1px dashed rgba(255,255,255,0.1);
  border-radius: 8px;
}

/* Audio Test Box */
.audio-test-box {
  margin-top: 24px;
  padding: 20px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
}

.audio-test-box h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--text-secondary);
}

.audio-test-actions {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Weekdays Selector */
.weekdays-selector {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.weekday-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 44px;
  cursor: pointer;
  user-select: none;
}

.weekday-btn input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.weekday-btn span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.weekday-btn:hover span {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.15);
}

.weekday-btn input:checked + span {
  background: rgba(255,200,0,0.15);
  border-color: var(--color-primary);
  color: var(--color-primary);
  box-shadow: 0 0 16px rgba(255,200,0,0.2);
}

/* Blacklist Container */
.blacklist-container {
  margin-bottom: 12px;
  max-height: 200px;
  overflow-y: auto;
  padding: 8px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
}

.blacklist-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  margin-bottom: 6px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.blacklist-item:last-child {
  margin-bottom: 0;
}

.blacklist-empty {
  padding: 20px;
  text-align: center;
  font-size: 13px;
  color: var(--text-tertiary);
}

/* Pilar Footer Sticky (botões de salvar fixos) */
.pilar-footer-sticky {
  position: sticky;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 24px;
  background: rgba(5,5,5,0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 -4px 24px rgba(0,0,0,0.3);
}

.pilar-footer-sticky .footer-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pilar-footer-sticky .footer-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.auto-save-indicator {
  font-size: 12px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.auto-save-indicator.saving {
  color: var(--color-warning);
}

.auto-save-indicator.saved {
  color: var(--color-success);
}

/* Botões de ação específicos */
.btn-icon-delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 6px;
  color: #ef4444;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-icon-delete:hover {
  background: rgba(239,68,68,0.2);
  border-color: rgba(239,68,68,0.4);
  transform: scale(1.05);
}

.btn-icon-delete:active {
  transform: scale(0.95);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .pilar-footer-sticky {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  
  .pilar-footer-sticky .footer-left,
  .pilar-footer-sticky .footer-right {
    justify-content: center;
  }
  
  .pilar-footer-sticky .footer-right {
    flex-direction: column;
    width: 100%;
  }
  
  .pilar-footer-sticky .footer-right button {
    width: 100%;
  }
  
  .timeline-item {
    padding-left: 24px;
  }
  
  .weekdays-selector {
    justify-content: space-between;
  }
  
  .weekday-btn {
    flex: 1;
    min-width: 40px;
  }
}

/* ============================================================================
   MICAEL 1.5 - VOICE CARDS & NEW CONTROLS
   ========================================================================= */

/* Voice Cards Grid */
.voice-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

/* Voice Card */
.voice-card {
  position: relative;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,200,0,0.1);
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.voice-card:hover {
  border-color: rgba(255,200,0,0.3);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(255,200,0,0.15);
}

.voice-card.active {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.05);
  box-shadow: 0 0 30px rgba(255,200,0,0.2);
}

.voice-card-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.voice-card h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.voice-card-description {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
  min-height: 60px;
}

.voice-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin-bottom: 16px;
}

.voice-tag {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(255,200,0,0.1);
  border: 1px solid rgba(255,200,0,0.2);
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.voice-tag-empire {
  background: linear-gradient(135deg, #9333ea, #c084fc);
  border-color: #9333ea;
  color: #ffffff;
}

.voice-card-select-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  background: linear-gradient(135deg, #ffc800, #ff8c00);
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  color: #050505;
  cursor: pointer;
  transition: all 0.3s ease;
}

.voice-card-select-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 20px rgba(255,200,0,0.4);
}

.voice-card-select-btn:active {
  transform: scale(0.98);
}

.voice-card.active .voice-card-select-btn {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff;
}

.voice-card-select-btn-disabled {
  background: rgba(255,255,255,0.05);
  color: var(--text-tertiary);
  cursor: not-allowed;
  opacity: 0.6;
}

.voice-card-select-btn-disabled:hover {
  transform: none;
  box-shadow: none;
}

/* Premium Card */
.voice-card-premium {
  border-color: rgba(147,51,234,0.3);
  background: linear-gradient(135deg, rgba(147,51,234,0.05), rgba(192,132,252,0.05));
}

.voice-card-premium:hover {
  border-color: rgba(147,51,234,0.5);
  box-shadow: 0 8px 24px rgba(147,51,234,0.2);
}

/* Empire Badge */
.empire-badge {
  display: inline-block;
  padding: 4px 12px;
  background: linear-gradient(135deg, #9333ea, #c084fc);
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-left: 10px;
}

/* Config Card Empire */
.config-card-empire {
  border-color: rgba(147,51,234,0.3);
  background: linear-gradient(135deg, rgba(147,51,234,0.02), rgba(192,132,252,0.02));
}

/* Voice Pace Buttons */
.voice-pace-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 8px;
}

.voice-pace-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 12px;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.voice-pace-btn:hover {
  border-color: rgba(255,200,0,0.4);
  transform: translateY(-2px);
}

.voice-pace-btn.active {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.08);
  box-shadow: 0 0 20px rgba(255,200,0,0.2);
}

.pace-icon {
  font-size: 28px;
}

.pace-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.voice-pace-btn small {
  font-size: 11px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

/* Voice Style Buttons */
.voice-style-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 8px;
}

.voice-style-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 16px 12px;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.voice-style-btn:hover {
  border-color: rgba(255,200,0,0.4);
  transform: translateY(-2px);
}

.voice-style-btn.active {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.08);
  box-shadow: 0 0 20px rgba(255,200,0,0.2);
}

.style-icon {
  font-size: 28px;
}

.style-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.voice-style-btn small {
  font-size: 11px;
  color: var(--text-tertiary);
}

/* Responsive Voice Cards */
@media (max-width: 768px) {
  .voice-cards-grid {
    grid-template-columns: 1fr;
  }
  
  .voice-pace-buttons,
  .voice-style-buttons {
    grid-template-columns: 1fr;
  }
}

/* ============================================================================
   MICAEL 1.5 - GOAL CARDS & INITIATIVE LEVELS
   ========================================================================= */

/* Goal Cards Grid */
.goal-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

/* Goal Card */
.goal-card {
  position: relative;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,200,0,0.1);
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.goal-card:hover {
  border-color: rgba(255,200,0,0.3);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(255,200,0,0.15);
}

.goal-card.active {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.05);
  box-shadow: 0 0 30px rgba(255,200,0,0.2);
}

.goal-card-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.goal-card h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.goal-card-description {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
  min-height: 60px;
}

.goal-card-features {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.goal-feature {
  font-size: 12px;
  color: var(--text-tertiary);
  text-align: left;
}

.goal-card-select-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  background: linear-gradient(135deg, #ffc800, #ff8c00);
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  color: #050505;
  cursor: pointer;
  transition: all 0.3s ease;
}

.goal-card-select-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 20px rgba(255,200,0,0.4);
}

.goal-card-select-btn:active {
  transform: scale(0.98);
}

.goal-card.active .goal-card-select-btn {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff;
}

/* Initiative Level Buttons */
.initiative-level-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.initiative-btn {
  position: relative;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.initiative-btn:hover {
  border-color: rgba(255,200,0,0.3);
  transform: translateY(-2px);
}

.initiative-btn.active {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.05);
  box-shadow: 0 0 30px rgba(255,200,0,0.2);
}

.initiative-icon {
  font-size: 36px;
  margin-bottom: 10px;
}

.initiative-btn h4 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.initiative-description {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 12px;
  min-height: 50px;
}

.initiative-config {
  padding: 8px 12px;
  background: rgba(255,200,0,0.05);
  border: 1px solid rgba(255,200,0,0.1);
  border-radius: 6px;
  margin-bottom: 12px;
}

.initiative-config small {
  font-size: 11px;
  color: var(--color-primary);
  font-family: var(--font-mono);
  font-weight: 600;
}

.initiative-select-btn {
  width: 100%;
  padding: 10px 16px;
  background: rgba(255,200,0,0.1);
  border: 1px solid rgba(255,200,0,0.2);
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-primary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.initiative-select-btn:hover {
  background: rgba(255,200,0,0.15);
  border-color: rgba(255,200,0,0.3);
}

.initiative-btn.active .initiative-select-btn {
  background: linear-gradient(135deg, #10b981, #059669);
  border-color: #10b981;
  color: #ffffff;
}

/* Responsive Goal & Initiative Cards */
@media (max-width: 768px) {
  .goal-cards-grid,
  .initiative-level-buttons {
    grid-template-columns: 1fr;
  }
}

/* ============================================================================
   MICAEL 1.5 - KNOWLEDGE BASE & COLLAPSIBLE CARDS
   ========================================================================= */

/* Textarea Large (Knowledge Base) */
.textarea-large {
  min-height: 400px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.6;
  resize: vertical;
}

/* Config Card Collapsed */
.config-card-collapsed {
  border-color: rgba(255,255,255,0.05);
}

.config-card-collapsed .card-header {
  cursor: pointer;
}

.config-card-collapsed.expanded {
  border-color: rgba(255,200,0,0.2);
}

/* Card Header Collapsible */
.card-header-collapsible {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  cursor: pointer;
  user-select: none;
}

.card-header-collapsible:hover {
  background: rgba(255,200,0,0.02);
}

.collapse-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  background: rgba(255,200,0,0.1);
  border: 1px solid rgba(255,200,0,0.2);
  border-radius: 6px;
  color: var(--color-primary);
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.collapse-toggle-btn:hover {
  background: rgba(255,200,0,0.15);
  transform: scale(1.1);
}

.config-card-collapsed.expanded .collapse-toggle-btn {
  transform: rotate(180deg);
}

.config-card-collapsed.expanded .collapse-toggle-btn:hover {
  transform: rotate(180deg) scale(1.1);
}

/* Card Body Collapsible */
.card-body-collapsible {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s ease, opacity 0.3s ease;
  opacity: 0;
}

.card-body-collapsible.expanded {
  max-height: 2000px;
  opacity: 1;
}

/* ============================================================================
   MICAEL 1.5 - GUARDRAIL CHIPS
   ========================================================================= */

/* Guardrail Category */
.guardrail-category {
  margin-bottom: 24px;
}

.guardrail-category-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Guardrail Chips Container */
.guardrail-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Guardrail Chip (Button) */
.guardrail-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.guardrail-chip:hover {
  border-color: rgba(255,200,0,0.3);
  background: rgba(255,200,0,0.05);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.guardrail-chip.active {
  background: rgba(255,200,0,0.15);
  border-color: var(--color-primary);
  color: var(--color-primary);
  box-shadow: 0 0 15px rgba(255,200,0,0.2);
}

.guardrail-chip.active::before {
  content: '✓ ';
  font-weight: 700;
}

/* Guardrails Active List */
.guardrails-active-list {
  min-height: 80px;
  padding: 16px;
  background: rgba(26,26,26,0.4);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 8px;
}

.guardrails-empty {
  text-align: center;
  padding: 20px;
  color: var(--text-tertiary);
  font-size: 13px;
}

.guardrail-active-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  background: rgba(255,200,0,0.05);
  border: 1px solid rgba(255,200,0,0.1);
  border-radius: 8px;
  margin-bottom: 8px;
  transition: all 0.2s ease;
}

.guardrail-active-item:last-child {
  margin-bottom: 0;
}

.guardrail-active-item:hover {
  border-color: rgba(255,200,0,0.2);
  background: rgba(255,200,0,0.08);
}

.guardrail-active-text {
  flex: 1;
  font-size: 13px;
  color: var(--text-primary);
  line-height: 1.4;
}

.guardrail-remove-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  padding: 0;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 50%;
  color: #ef4444;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.guardrail-remove-btn:hover {
  background: rgba(239,68,68,0.2);
  transform: scale(1.1);
}

/* Responsive Guardrails */
@media (max-width: 768px) {
  .guardrail-chips {
    gap: 6px;
  }
  
  .guardrail-chip {
    font-size: 11px;
    padding: 6px 10px;
  }
}

/* ============================================================================
   MICAEL 1.5 - CRM KANBAN COMPLETO
   ========================================================================= */

/* CRM Header */
.crm-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.crm-header-left h2 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.crm-subtitle {
  font-size: 13px;
  color: var(--text-tertiary);
}

.crm-header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* CRM Search Box */
.crm-search-box {
  position: relative;
  width: 280px;
}

.crm-search-input {
  width: 100%;
  padding: 10px 40px 10px 14px;
  background: rgba(26,26,26,0.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 14px;
  transition: all 0.2s ease;
}

.crm-search-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 20px rgba(255,200,0,0.15);
}

.crm-search-box i {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  width: 18px;
  height: 18px;
}

/* CRM Filters */
.crm-filters {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 24px;
  padding: 16px 20px;
  background: rgba(26,26,26,0.4);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 10px;
}

.crm-filter-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.crm-filter-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-tertiary);
  margin-right: 6px;
}

.crm-filter-chip {
  padding: 6px 14px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.crm-filter-chip:hover {
  border-color: rgba(255,200,0,0.3);
  background: rgba(255,200,0,0.05);
  color: var(--text-primary);
}

.crm-filter-chip.active {
  background: linear-gradient(135deg, rgba(255,200,0,0.15), rgba(255,140,0,0.15));
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.crm-sort-select {
  padding: 6px 12px;
  background: rgba(26,26,26,0.6);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  color: var(--text-primary);
  font-size: 13px;
  cursor: pointer;
}

/* Kanban Board */
.crm-kanban-board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  min-height: 600px;
}

/* CRM Column */
.crm-column {
  display: flex;
  flex-direction: column;
  background: rgba(26,26,26,0.3);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.crm-column-success {
  border-color: rgba(16,185,129,0.2);
  background: linear-gradient(180deg, rgba(16,185,129,0.05), rgba(26,26,26,0.3));
}

.crm-column-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.crm-column-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.crm-column-icon {
  font-size: 20px;
}

.crm-column-title h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.crm-column-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  padding: 0 10px;
  background: rgba(255,200,0,0.15);
  border: 1px solid rgba(255,200,0,0.2);
  border-radius: 14px;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-primary);
}

.crm-column-body {
  flex: 1;
  padding: 12px;
  overflow-y: auto;
  min-height: 400px;
}

/* Empty State */
.crm-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
}

.crm-empty-state i {
  width: 48px;
  height: 48px;
  color: var(--text-tertiary);
  opacity: 0.3;
  margin-bottom: 12px;
}

.crm-empty-state p {
  font-size: 13px;
  color: var(--text-tertiary);
  margin: 0;
}

/* Lead Card */
.crm-lead-card {
  position: relative;
  padding: 14px;
  margin-bottom: 10px;
  background: rgba(26,26,26,0.8);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  cursor: grab;
  transition: all 0.2s ease;
}

.crm-lead-card:active {
  cursor: grabbing;
}

.crm-lead-card:hover {
  border-color: rgba(255,200,0,0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.crm-lead-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.crm-lead-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.crm-lead-phone {
  font-size: 12px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.crm-lead-score {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.crm-lead-score-value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, rgba(255,200,0,0.2), rgba(255,140,0,0.2));
  border: 1px solid rgba(255,200,0,0.3);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-primary);
}

.crm-lead-score-label {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-tertiary);
}

.crm-lead-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.crm-lead-tag {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.crm-lead-tag[data-tag="hotmart"] {
  background: rgba(255,99,71,0.15);
  border: 1px solid rgba(255,99,71,0.3);
  color: #ff6347;
}

.crm-lead-tag[data-tag="whatsapp"] {
  background: rgba(37,211,102,0.15);
  border: 1px solid rgba(37,211,102,0.3);
  color: #25d366;
}

.crm-lead-tag[data-tag="site"] {
  background: rgba(66,133,244,0.15);
  border: 1px solid rgba(66,133,244,0.3);
  color: #4285f4;
}

.crm-lead-tag[data-tag="manual"] {
  background: rgba(155,89,182,0.15);
  border: 1px solid rgba(155,89,182,0.3);
  color: #9b59b6;
}

.crm-lead-intent {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.crm-lead-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.05);
}

.crm-lead-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: var(--text-tertiary);
}

.crm-lead-meta i {
  width: 14px;
  height: 14px;
}

.crm-lead-actions {
  display: flex;
  gap: 4px;
}

.crm-lead-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.crm-lead-action-btn:hover {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.1);
  color: var(--color-primary);
}

.crm-lead-action-btn i {
  width: 14px;
  height: 14px;
}

/* Sortable Ghost */
.sortable-ghost {
  opacity: 0.4;
}

.sortable-drag {
  opacity: 1;
  transform: rotate(2deg);
}

/* CRM Modal */
.crm-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.crm-modal.active {
  display: flex;
}

.crm-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
}

.crm-modal-content {
  position: relative;
  width: 100%;
  max-width: 700px;
  max-height: 90vh;
  background: #1a1a1a;
  border: 1px solid rgba(255,200,0,0.2);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  overflow: hidden;
  animation: modalFadeIn 0.3s ease;
}

.crm-modal-small {
  max-width: 500px;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.crm-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 28px;
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.crm-modal-header h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.crm-modal-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.crm-modal-close:hover {
  background: rgba(239,68,68,0.1);
  border-color: rgba(239,68,68,0.3);
  color: #ef4444;
}

.crm-modal-body {
  padding: 28px;
  max-height: calc(90vh - 100px);
  overflow-y: auto;
}

/* Lead Info (Modal) */
.crm-lead-info {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 24px;
  padding: 20px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px;
}

.crm-lead-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, rgba(255,200,0,0.2), rgba(255,140,0,0.2));
  border: 2px solid rgba(255,200,0,0.3);
  border-radius: 50%;
  color: var(--color-primary);
}

.crm-lead-avatar i {
  width: 32px;
  height: 32px;
}

.crm-lead-details {
  flex: 1;
}

.crm-lead-details h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.crm-lead-details p {
  font-size: 13px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  margin-bottom: 10px;
}

.crm-lead-score {
  text-align: center;
}

.score-label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-tertiary);
  margin-bottom: 6px;
}

.score-value {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, rgba(255,200,0,0.2), rgba(255,140,0,0.2));
  border: 2px solid rgba(255,200,0,0.3);
  border-radius: 50%;
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
}

/* Lead Stats */
.crm-lead-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.crm-stat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 10px;
}

.crm-stat-item i {
  width: 20px;
  height: 20px;
  color: var(--color-primary);
}

.stat-label {
  display: block;
  font-size: 11px;
  color: var(--text-tertiary);
  margin-bottom: 4px;
}

.stat-value {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

/* CRM Section */
.crm-section {
  margin-bottom: 24px;
}

.crm-section h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
}

/* Messages Timeline */
.crm-messages-timeline {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 300px;
  overflow-y: auto;
  padding: 12px;
  background: rgba(0,0,0,0.2);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 8px;
}

.crm-message-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 8px;
  max-width: 80%;
}

.crm-message-in {
  align-self: flex-start;
  background: rgba(66,133,244,0.1);
  border: 1px solid rgba(66,133,244,0.2);
}

.crm-message-out {
  align-self: flex-end;
  background: rgba(16,185,129,0.1);
  border: 1px solid rgba(16,185,129,0.2);
}

.message-time {
  font-size: 10px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
}

.message-text {
  font-size: 13px;
  color: var(--text-primary);
  line-height: 1.4;
  margin: 0;
}

/* Actions Grid */
.crm-actions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.btn-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-action:hover {
  border-color: var(--color-primary);
  background: rgba(255,200,0,0.05);
  color: var(--color-primary);
}

.btn-action i {
  width: 16px;
  height: 16px;
}

.btn-block {
  width: 100%;
}

/* Responsive CRM */
@media (max-width: 1400px) {
  .crm-kanban-board {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .crm-header {
    flex-direction: column;
  }
  
  .crm-header-right {
    width: 100%;
    flex-direction: column;
  }
  
  .crm-search-box {
    width: 100%;
  }
  
  .crm-filters {
    flex-direction: column;
    align-items: stretch;
  }
  
  .crm-filter-group {
    flex-wrap: wrap;
  }
  
  .crm-kanban-board {
    grid-template-columns: 1fr;
  }
  
  .crm-lead-stats {
    grid-template-columns: 1fr;
  }
  
  .crm-actions-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================================
   ARGUS Multi-idioma & ODIN Blog - Novos Componentes
   ============================================================================ */

/* ----------------------------------------------------------------------------
   Glossário PT-ES
   ---------------------------------------------------------------------------- */

.glossary-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.glossary-item {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 48px 16px 16px;
  background: rgba(26, 26, 26, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.glossary-item:hover {
  background: rgba(26, 26, 26, 0.8);
  border-color: rgba(255, 200, 0, 0.3);
  transform: translateY(-2px);
}

.glossary-terms {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.glossary-pt {
  font-family: var(--font-primary);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.glossary-arrow {
  font-size: 18px;
  color: var(--color-primary);
  opacity: 0.8;
}

.glossary-es {
  font-family: var(--font-primary);
  font-size: 15px;
  font-weight: 600;
  color: var(--color-primary);
}

.glossary-context {
  font-size: 12px;
  color: var(--text-secondary);
  font-style: italic;
  padding-left: 32px;
}

.glossary-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--text-tertiary);
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
}

.glossary-remove:hover {
  background: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

.glossary-remove svg {
  width: 16px;
  height: 16px;
}

.input-group-glossary {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 8px;
  margin-top: 12px;
}

@media (max-width: 768px) {
  .input-group-glossary {
    grid-template-columns: 1fr;
  }
}

/* ----------------------------------------------------------------------------
   Clusters (Categorias Blog)
   ---------------------------------------------------------------------------- */

.field-hint-above {
  display: block;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 8px;
  line-height: 1.5;
}

/* ----------------------------------------------------------------------------
   ODIN - Histórico de Artigos
   ---------------------------------------------------------------------------- */

.odin-filters {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 16px;
  background: rgba(26, 26, 26, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  font-family: var(--font-primary);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-btn:hover {
  background: rgba(26, 26, 26, 0.8);
  border-color: rgba(255, 200, 0, 0.3);
  color: var(--text-primary);
}

.filter-btn.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: #050505;
  font-weight: 600;
}

.odin-history-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 24px;
}

.odin-history-item {
  padding: 20px;
  background: rgba(26, 26, 26, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.odin-history-item:hover {
  background: rgba(26, 26, 26, 0.8);
  border-color: rgba(255, 200, 0, 0.3);
  transform: translateY(-2px);
}

.history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.history-header h4 {
  font-family: var(--font-primary);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  flex: 1;
  line-height: 1.4;
}

.history-lang {
  font-size: 14px;
  font-weight: 600;
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  white-space: nowrap;
}

.history-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.history-category {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 4px;
}

.history-status {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  letter-spacing: 0.05em;
}

.history-status.published {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.history-status.draft {
  background: rgba(255, 200, 0, 0.1);
  color: var(--color-primary);
}

.history-status.failed {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.history-date {
  font-size: 13px;
  color: var(--text-tertiary);
}

.history-seo-score {
  font-size: 13px;
  font-weight: 600;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 4px;
}

.history-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-primary);
  text-decoration: none;
  transition: all 0.2s ease;
}

.history-link:hover {
  color: #fff;
  transform: translateX(4px);
}

.odin-history-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.stat-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  background: rgba(26, 26, 26, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  text-align: center;
}

.stat-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stat-value {
  font-size: 28px;
  font-weight: 900;
  color: var(--color-primary);
  font-family: var(--font-secondary);
}

/* ----------------------------------------------------------------------------
   ODIN - Conexão WordPress
   ---------------------------------------------------------------------------- */

.connection-status {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  margin-top: 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
}

.connection-status svg {
  width: 20px;
  height: 20px;
}

.connection-status.loading {
  background: rgba(255, 200, 0, 0.1);
  border: 1px solid rgba(255, 200, 0, 0.3);
  color: var(--color-primary);
}

.connection-status.loading svg {
  animation: spin 1s linear infinite;
}

.connection-status.success {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #10b981;
}

.connection-status.error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* ----------------------------------------------------------------------------
   ODIN - Template Preview
   ---------------------------------------------------------------------------- */

.template-preview {
  padding: 20px;
  background: rgba(26, 26, 26, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  margin-bottom: 20px;
}

.template-preview h4 {
  font-family: var(--font-primary);
  font-size: 15px;
  font-weight: 700;
  color: var(--color-primary);
  margin: 0 0 16px 0;
}

.template-structure-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.template-structure-list li {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  padding-left: 24px;
  position: relative;
}

.template-structure-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--color-primary);
  opacity: 0.8;
}

.template-structure-list li strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* ----------------------------------------------------------------------------
   Empty State
   ---------------------------------------------------------------------------- */

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
  color: var(--text-tertiary);
  gap: 12px;
}

.empty-state p {
  font-size: 15px;
  color: var(--text-secondary);
  margin: 0;
}

.empty-state small {
  font-size: 13px;
  color: var(--text-tertiary);
  max-width: 400px;
  line-height: 1.5;
}

/* ----------------------------------------------------------------------------
   Responsive Adjustments
   ---------------------------------------------------------------------------- */

@media (max-width: 768px) {
  .glossary-item {
    padding: 12px 40px 12px 12px;
  }
  
  .glossary-terms {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  .history-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .history-meta {
    gap: 8px;
  }
  
  .odin-history-stats {
    grid-template-columns: 1fr 1fr;
  }
}

/* ============================================================================
   DANTE + HERMES - Estilos
   ============================================================================ */

/* DANTE grids (remove inline styles do HTML) */
.stats-grid-dante {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.dante-grid {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}

.dante-grid--connections {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.dante-grid--posts {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.btn-block { width: 100%; }
.config-item--full { grid-column: 1 / -1; }

/* Connection Card (DANTE) */
.connection-card {
  background: rgba(26, 26, 26, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.connection-card:hover {
  transform: translateY(-2px);
  border-color: var(--color-primary);
  box-shadow: 0 4px 16px rgba(255, 200, 0, 0.2);
}

.connection-card.connected {
  border-color: var(--color-success, #10b981);
  background: rgba(16, 185, 129, 0.05);
}

.platform-icon {
  font-size: 32px;
  margin-bottom: 8px;
}

.platform-name {
  font-weight: 600;
  margin-bottom: 8px;
  color: #fff;
}

.platform-status {
  font-size: 12px;
  margin-bottom: 12px;
  opacity: 0.7;
}

.platform-status.connected {
  color: var(--color-success, #10b981);
  opacity: 1;
}

.btn-small {
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 600;
  width: 100%;
}

.btn-connect,
.btn-reconnect {
  background: var(--color-primary);
  color: #000;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-connect:hover,
.btn-reconnect:hover {
  filter: brightness(1.2);
  transform: scale(1.05);
}

.btn-reconnect {
  background: rgba(255, 200, 0, 0.2);
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
}

/* Post Card (DANTE) */
.post-card {
  background: rgba(26, 26, 26, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 16px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.post-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 200, 0, 0.3);
}

.post-platform-icon {
  font-size: 24px;
  margin-bottom: 8px;
}

.post-title {
  font-weight: 600;
  margin-bottom: 8px;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.post-status {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.post-status.pending {
  background: rgba(255, 200, 0, 0.2);
  color: var(--color-primary);
}

.post-status.uploading,
.post-status.processing {
  background: rgba(59, 130, 246, 0.2);
  color: #3b82f6;
}

.post-status.published {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
}

.post-status.failed {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.post-date {
  font-size: 12px;
  opacity: 0.6;
  margin-bottom: 8px;
}

.post-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 12px 0;
  gap: 8px;
  flex-wrap: wrap;
}

.post-stats {
  display: flex;
  gap: 16px;
  font-size: 13px;
  opacity: 0.7;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.post-stats span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.post-platform {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 8px;
  opacity: 0.9;
}

.btn-view {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(255, 200, 0, 0.1);
  border: 1px solid var(--color-primary);
  color: var(--color-primary);
  text-decoration: none;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  transition: all 0.2s;
}

.btn-view:hover {
  background: var(--color-primary);
  color: #000;
}

/* Sandbox Results (DANTE) */
#sandboxResults {
  animation: fadeInResults 0.3s ease;
}

@keyframes fadeInResults {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.validation-list {
  list-style: none;
  padding: 0;
  margin: 16px 0;
}

.validation-list li {
  padding: 8px 12px;
  margin-bottom: 4px;
  border-radius: 4px;
  font-size: 14px;
}

.validation-list li.pass {
  background: rgba(16, 185, 129, 0.1);
  border-left: 3px solid #10b981;
  color: #10b981;
}

.validation-list li.fail {
  background: rgba(239, 68, 68, 0.1);
  border-left: 3px solid #ef4444;
  color: #ef4444;
}

/* Stat Card */
.stat-card {
  background: rgba(26, 26, 26, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 200, 0, 0.3);
  box-shadow: 0 4px 16px rgba(255, 200, 0, 0.15);
}

.stat-card--fire {
  background: linear-gradient(135deg, rgba(255, 107, 53, 0.1) 0%, rgba(255, 200, 0, 0.05) 100%);
  border-color: rgba(255, 107, 53, 0.3);
}

.stat-card--fire:hover {
  border-color: rgba(255, 107, 53, 0.6);
  box-shadow: 0 4px 16px rgba(255, 107, 53, 0.3);
}

.stat-card--success {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(16, 185, 129, 0.05) 100%);
  border-color: rgba(16, 185, 129, 0.3);
}

.stat-card--success:hover {
  border-color: rgba(16, 185, 129, 0.6);
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.3);
}

.stat-icon {
  font-size: 32px;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.stat-label {
  font-size: 12px;
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Recipe Card (HERMES) */
.recipe-card {
  background: rgba(26, 26, 26, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.recipe-card:hover {
  border-color: rgba(255, 200, 0, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.recipe-header {
  background: rgba(255, 200, 0, 0.05);
  border-bottom: 1px solid rgba(255, 200, 0, 0.2);
  padding: 16px 20px;
}

.recipe-header h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
}

.recipe-body {
  padding: 20px;
}

/* Chat Window (HERMES) */
.chat-window {
  display: flex;
  flex-direction: column;
  gap: 12px;
  scroll-behavior: smooth;
}

.chat-message {
  display: flex;
  flex-direction: column;
  max-width: 75%;
  animation: messageSlideIn 0.3s ease;
}

@keyframes messageSlideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.chat-message.user {
  align-self: flex-end;
}

.chat-message.bot {
  align-self: flex-start;
}

.message-content {
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.5;
  word-wrap: break-word;
}

.chat-message.user .message-content {
  background: var(--color-primary);
  color: #000;
  border-bottom-right-radius: 4px;
}

.chat-message.bot .message-content {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-bottom-left-radius: 4px;
}

.message-time {
  font-size: 11px;
  opacity: 0.5;
  margin-top: 4px;
  padding: 0 4px;
}

.chat-message.user .message-time {
  text-align: right;
}

/* Typing Indicator */
.typing-indicator {
  display: flex;
  gap: 4px;
  padding: 12px 16px;
}

.typing-indicator span {
  width: 8px;
  height: 8px;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  animation: typingBounce 1.4s infinite ease-in-out;
}

.typing-indicator span:nth-child(1) {
  animation-delay: 0s;
}

.typing-indicator span:nth-child(2) {
  animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes typingBounce {
  0%, 60%, 100% {
    transform: translateY(0);
  }
  30% {
    transform: translateY(-8px);
  }
}

/* Chat Input Area */
.chat-input-area {
  display: flex;
  gap: 8px;
  align-items: center;
}

.chat-input-area input {
  flex: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  transition: all 0.2s;
}

.chat-input-area input:focus {
  outline: none;
  border-color: var(--color-primary);
  background: rgba(255, 255, 255, 0.08);
}

.chat-input-area button {
  padding: 12px 24px;
  white-space: nowrap;
}

/* Config Grid */
.config-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.config-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.config-item label {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
}

.config-item small {
  font-size: 12px;
  opacity: 0.6;
  margin-top: 4px;
}

/* Responsive (DANTE + HERMES) */
@media (max-width: 768px) {
  .stats-grid-dante,
  .stats-grid-hermes {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .chat-message {
    max-width: 85%;
  }
}

/* ============================================================================
   TOGGLE SWITCHES (DANTE + HERMES + GLOBAL)
   ========================================================================= */

.toggle-label {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  user-select: none;
  position: relative;
  padding: 8px 0;
  font-size: 14px;
  color: var(--color-text);
  transition: color 0.2s ease;
}

.toggle-label:hover {
  color: var(--color-primary);
}

/* Esconder checkbox nativo */
.toggle-label input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

/* Container do Toggle - iOS Style */
.toggle-slider {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 28px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
  cursor: pointer;
}

/* Remover qualquer pseudo-elemento ::after que possa causar bolinha dupla */
.toggle-slider::after {
  content: none !important;
  display: none !important;
}

/* Bolinha do Toggle - Única */
.toggle-slider::before {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.25s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

/* Estado CHECKED */
.toggle-label input[type="checkbox"]:checked + .toggle-slider {
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  border-color: var(--color-primary);
}

.toggle-label input[type="checkbox"]:checked + .toggle-slider::before {
  transform: translateX(20px);
  box-shadow: 0 2px 8px rgba(var(--color-primary-rgb), 0.4);
}

/* Hover */
.toggle-label:hover .toggle-slider {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(var(--color-primary-rgb), 0.12);
}

/* Light mode: trilho precisa aparecer (evita “toggle invisível” em ATLAS/GRAPHOS) */
body[data-mode="light"] .toggle-slider {
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.14);
}

body[data-mode="light"] .toggle-label:hover .toggle-slider {
  box-shadow: 0 0 0 4px rgba(var(--color-primary-rgb), 0.14);
}

/* Focus (acessibilidade) */
.toggle-label input[type="checkbox"]:focus + .toggle-slider {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Disabled */
.toggle-label input[type="checkbox"]:disabled + .toggle-slider {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.toggle-label input[type="checkbox"]:disabled {
  cursor: not-allowed;
}

/* ============================================================================
   ECHO - Email Marketing
   ============================================================================ */

.metrics-cards-echo {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

@media (max-width: 1024px) {
  .metrics-cards-echo {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .metrics-cards-echo {
    grid-template-columns: 1fr;
  }
}

.metric-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.metric-card:hover {
  transform: translateY(-2px);
  border-color: var(--color-primary);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.metric-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.metric-value {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 0.25rem;
}

.metric-label {
  font-size: 0.875rem;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.campaigns-section {
  margin-top: 2rem;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.section-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.campaigns-table-wrapper {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
}

.data-table thead {
  background: rgba(255, 200, 0, 0.05);
}

.data-table th {
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.data-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.data-table tbody tr:hover {
  background: rgba(255, 200, 0, 0.03);
}

.campaign-status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.campaign-status-badge.draft {
  background: rgba(255, 255, 255, 0.1);
  color: #999;
}

.campaign-status-badge.sending {
  background: rgba(255, 200, 0, 0.2);
  color: #ffc800;
}

.campaign-status-badge.sent {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
}

.campaign-status-badge.failed {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.campaign-actions {
  display: flex;
  gap: 0.5rem;
}

.campaign-actions button {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.5rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.campaign-actions button:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: rgba(255, 200, 0, 0.05);
}

