/* ========================================
   OPINÔMETRO - Estilos do Badge Radial
   ======================================== */

:root {
  --op-cold: #3b82f6;      /* Frio (0-24) - Azul */
  --op-warm: #22c55e;      /* Ativo (25-49) - Verde */
  --op-hot: #f59e0b;       /* Quente (50-74) - Amarelo */
  --op-boiling: #f97316;   /* Ebulição (75-89) - Laranja */
  --op-exploding: #ef4444; /* Explodindo (90-100) - Vermelho */
}

/* Badge Radial - Componente Universal */
.opinometro-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.opinometro-badge svg {
  transform: rotate(-90deg); /* Começar do topo */
}

.opinometro-ring-bg {
  fill: none;
  stroke: #e5e7eb;
  stroke-width: 3;
}

.opinometro-ring-fill {
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
  transition: stroke-dasharray 0.6s ease, stroke 0.3s ease;
}

/* Cores por nível */
.opinometro-badge.op-cold .opinometro-ring-fill {
  stroke: var(--op-cold);
}

.opinometro-badge.op-warm .opinometro-ring-fill {
  stroke: var(--op-warm);
}

.opinometro-badge.op-hot .opinometro-ring-fill {
  stroke: var(--op-hot);
}

.opinometro-badge.op-boiling .opinometro-ring-fill {
  stroke: var(--op-boiling);
}

.opinometro-badge.op-exploding .opinometro-ring-fill {
  stroke: var(--op-exploding);
  animation: pulse-exploding 2s ease-in-out infinite;
}

@keyframes pulse-exploding {
  0%, 100% {
    opacity: 1;
    filter: drop-shadow(0 0 4px var(--op-exploding));
  }
  50% {
    opacity: 0.9;
    filter: drop-shadow(0 0 8px var(--op-exploding));
  }
}

/* Score no centro */
.opinometro-score {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

/* Tamanhos */
.op-badge-compact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.85);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.45);
  border: 1px solid rgba(248, 250, 252, 0.25);
}

.opinometro-badge.size-compact {
  width: 24px;
  height: 24px;
}

.opinometro-badge.size-compact svg {
  width: 24px;
  height: 24px;
}

.opinometro-badge.size-compact .opinometro-ring-bg,
.opinometro-badge.size-compact .opinometro-ring-fill {
  stroke-width: 2.6;
}

.opinometro-badge.size-compact .opinometro-score {
  font-size: 9px;
  font-weight: 400;
  color: #fde68a;
  text-shadow: 0 0 4px rgba(15, 23, 42, 0.85);
}

.opinometro-badge.size-mini {
  width: 32px;
  height: 32px;
}

.opinometro-badge.size-mini svg {
  width: 32px;
  height: 32px;
}

.opinometro-badge.size-mini .opinometro-score {
  font-size: 9px;
}

.opinometro-badge.size-normal {
  width: 48px;
  height: 48px;
}

.opinometro-badge.size-normal svg {
  width: 48px;
  height: 48px;
}

.opinometro-badge.size-normal .opinometro-score {
  font-size: 12px;
}

.opinometro-badge.size-large {
  width: 64px;
  height: 64px;
}

.opinometro-badge.size-large svg {
  width: 64px;
  height: 64px;
}

.opinometro-badge.size-large .opinometro-score {
  font-size: 16px;
}

/* Tooltip */
.opinometro-tooltip {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-bottom: 8px;
  padding: 12px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  font-size: 12px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 1000;
}

.opinometro-badge:hover .opinometro-tooltip {
  opacity: 1;
}

.opinometro-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: white;
}

/* Barra de polarização no tooltip */
.opinometro-polarity-bar {
  display: flex;
  width: 100px;
  height: 4px;
  border-radius: 2px;
  overflow: hidden;
  margin: 4px 0;
}

.opinometro-polarity-a {
  background: var(--op-hot);
}

.opinometro-polarity-b {
  background: #94a3b8;
}


