/* ==================== ESTILOS DE PRODUTOS BANIDOS ==================== */
/* banned-products.css - v1.0 (Visual vermelho/preto - crítico) */

/* ==================== CLASSE PRINCIPAL - PRODUTO BANIDO ==================== */

.result-item.banned-product {
  position: relative;
  border: 3px solid #d32f2f !important; /* Borda vermelha forte */
  transition: all 0.3s ease;
  opacity: 0.7; /* Produto banido fica semi-transparente */
}

/* ==================== TEMA CLARO ==================== */
@media (prefers-color-scheme: light) {
  .result-item.banned-product {
    background: repeating-linear-gradient(
      45deg,
      #ffebee,
      #ffebee 10px,
      #ffcdd2 10px,
      #ffcdd2 20px
    ) !important; /* Fundo listrado vermelho */
  }

  .result-item.banned-product:hover {
    background: repeating-linear-gradient(
      45deg,
      #ffcdd2,
      #ffcdd2 10px,
      #ef9a9a 10px,
      #ef9a9a 20px
    ) !important;
    opacity: 0.9;
    transform: scale(0.98); /* Diminui levemente ao passar mouse */
  }
}

/* ==================== TEMA ESCURO ==================== */
@media (prefers-color-scheme: dark) {
  .result-item.banned-product {
    background: repeating-linear-gradient(
      45deg,
      rgba(211, 47, 47, 0.15),
      rgba(211, 47, 47, 0.15) 10px,
      rgba(244, 67, 54, 0.1) 10px,
      rgba(244, 67, 54, 0.1) 20px
    ) !important; /* Fundo listrado vermelho suave */
  }

  .result-item.banned-product:hover {
    background: repeating-linear-gradient(
      45deg,
      rgba(211, 47, 47, 0.25),
      rgba(211, 47, 47, 0.25) 10px,
      rgba(244, 67, 54, 0.2) 10px,
      rgba(244, 67, 54, 0.2) 20px
    ) !important;
    opacity: 0.9;
  }

  /* .result-item.banned-product .produto .list-item__data {
    color: #ef5350 !important;
    text-decoration: line-through;
  } */
}

/* ==================== INDICADOR VISUAL "BANIDO" ==================== 

.result-item.banned-product::before {
  content: "🚫";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 80px;
  z-index: 5;
  opacity: 0.15;
  pointer-events: none;
}*/

.result-item.banned-product::after {
  content: "BANIDO";
  position: absolute;
  top: 10px;
  right: 10px;
  background: linear-gradient(135deg, #d32f2f 0%, #c62828 100%);
  color: #fff;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: bold;
  letter-spacing: 1px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  z-index: 10;
  animation: bannedPulse 2s infinite;
}

@keyframes bannedPulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(211, 47, 47, 0.6);
  }
}

/* ==================== NOME DO PRODUTO RISCADO ==================== */

@media (prefers-color-scheme: light) {
  .result-item.banned-product .produto .list-item__data {
    text-decoration: line-through;
    color: #c62828 !important;
    font-weight: 600;
  }
}

/* ==================== INFORMAÇÕES DE BANIMENTO ==================== */

/* Badge com data de banimento */
.result-item.banned-product[data-banned-date]::before {
  /* content: "Banido em: " attr(data-banned-date); */
  position: absolute;
  bottom: 10px;
  left: 10px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 10px;
  z-index: 10;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.result-item.banned-product:hover[data-banned-date]::before {
  opacity: 1;
}

/* ==================== CONTADOR DE PRODUTOS BANIDOS ==================== */

#banned-counter {
  position: fixed;
  bottom: 70px; /* Abaixo do contador de validação */
  right: 20px;
  background: linear-gradient(135deg, #d32f2f 0%, #c62828 100%);
  color: #fff;
  padding: 10px 18px;
  border-radius: 25px;
  font-weight: bold;
  font-size: 14px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  display: none;
  align-items: center;
  gap: 8px;
  animation: slideInBanned 0.3s ease-out;
  cursor: pointer;
  transition: all 0.3s ease;
}

#banned-counter:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(211, 47, 47, 0.5);
}

@keyframes slideInBanned {
  from {
    transform: translateY(100px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

#banned-counter::before {
  content: "🚫";
  font-size: 18px;
}

#banned-counter::after {
  content: " produtos banidos";
  font-weight: normal;
  font-size: 12px;
}

/* ==================== FILTROS ==================== */

.hide-banned .result-item.banned-product {
  display: none !important;
}

.show-only-banned .result-item:not(.banned-product) {
  display: none !important;
}

/* ==================== INTERAÇÃO DESABILITADA ==================== */

/* Produtos banidos são menos "clicáveis" */
.result-item.banned-product {
  pointer-events: auto; /* Mantém clicável mas visualmente desabilitado */
  cursor: not-allowed !important;
}

.result-item.banned-product * {
  cursor: not-allowed !important;
}

/* ==================== SOBREPOSIÇÃO COM BAIXA VALIDAÇÃO ==================== */

/* Se um produto for BANIDO E tiver baixa validação, banimento tem prioridade */
.result-item.banned-product.low-validation-product {
  border: 3px solid #d32f2f !important; /* Mantém borda vermelha */
  opacity: 0.7;
}

/* Remove o indicador de baixa validação se produto estiver banido */
.result-item.banned-product.low-validation-product::before {
  font-size: 80px !important;
  left: 50% !important;
  top: 50% !important;
  transform: translate(-50%, -50%) !important;
  opacity: 0.15 !important;
}

/* ==================== RESPONSIVO ==================== */

@media (max-width: 768px) {
  .result-item.banned-product::before {
    font-size: 50px;
  }

  .result-item.banned-product::after {
    font-size: 9px;
    padding: 4px 8px;
    top: 5px;
    right: 5px;
  }

  #banned-counter {
    bottom: 60px;
    right: 10px;
    padding: 8px 14px;
    font-size: 12px;
  }

  #banned-counter::after {
    content: "";
  }
}

/* ==================== MODAL DE INFORMAÇÕES DE BANIMENTO ==================== */

.banned-info-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  z-index: 10001;
  max-width: 500px;
  width: 90%;
  border: 3px solid #d32f2f;
}

@media (prefers-color-scheme: dark) {
  .banned-info-modal {
    background: #2c2c2c;
    color: #fff;
  }
}

.banned-info-modal h3 {
  margin: 0 0 20px 0;
  color: #d32f2f;
  display: flex;
  align-items: center;
  gap: 10px;
}

.banned-info-modal h3::before {
  content: "🚫";
  font-size: 24px;
}

.banned-info-modal .product-name {
  font-weight: bold;
  margin-bottom: 15px;
  text-decoration: line-through;
}

.banned-info-modal .info-row {
  margin-bottom: 10px;
  padding: 10px;
  background: rgba(211, 47, 47, 0.1);
  border-radius: 6px;
}

.banned-info-modal .info-label {
  font-weight: bold;
  color: #d32f2f;
  margin-right: 5px;
}

/* ==================== DEBUG MODE ==================== */

.debug-banned .result-item.banned-product {
  outline: 3px dashed #d32f2f;
  outline-offset: 3px;
}
