/* ==========================================================================
   VOARDRONE &bull; WIDGET DE ANÚNCIOS FLUTUANTE (AFILIADOS & MONETIZAÇÃO)
   ========================================================================== */

:root {
  --vd-ad-cyan: #00e5ff;
  --vd-ad-cyan-glow: rgba(0, 229, 255, 0.28);
  --vd-ad-green: #10b981;
  --vd-ad-amber: #f59e0b;
  --vd-ad-bg: rgba(14, 23, 42, 0.94);
  --vd-ad-border: rgba(0, 229, 255, 0.32);
  --vd-ad-radius: 14px;
}

/* Container Flutuante */
.vd-ad-floating-host {
  position: fixed;
  z-index: 9995;
  pointer-events: none; /* Apenas o card e o modal recebem clique */
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.vd-ad-floating-host.pos-bottom-right {
  bottom: 20px;
  right: 20px;
}

.vd-ad-floating-host.pos-bottom-left {
  bottom: 20px;
  left: 20px;
}

.vd-ad-floating-host.pos-bottom-center {
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
}

.vd-ad-floating-host.pos-center {
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

/* Card do Anúncio (Quadrado / Proporção Compacta) */
.vd-ad-card {
  pointer-events: auto;
  width: 340px;
  max-width: calc(100vw - 32px);
  background: var(--vd-ad-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--vd-ad-border);
  border-radius: var(--vd-ad-radius);
  padding: 12px 14px 10px 14px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 24px rgba(0, 229, 255, 0.12);
  color: #f1f5f9;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  animation: vdAdSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.vd-ad-card:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 229, 255, 0.6);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.85), 0 0 30px rgba(0, 229, 255, 0.2);
}

@keyframes vdAdSlideUp {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Linha Superior: Selo Patrocinado + Plataforma + Botão Fechar */
.vd-ad-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  gap: 8px;
}

.vd-ad-labels {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.vd-ad-tag-sponsored {
  color: #94a3b8;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.vd-ad-tag-platform {
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--vd-ad-cyan);
}

.vd-ad-tag-platform.meli { background: rgba(255, 230, 0, 0.15); color: #ffe600; }
.vd-ad-tag-platform.amz { background: rgba(255, 153, 0, 0.15); color: #ff9900; }
.vd-ad-tag-platform.shp { background: rgba(238, 77, 45, 0.15); color: #ee4d2d; }

/* Botão Fechar (X) - Amplo, Acessível e Confortável para Dedo */
.vd-ad-close {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: all 0.18s ease;
  outline: none;
}

.vd-ad-close svg {
  width: 16px;
  height: 16px;
  stroke-width: 2.5;
}

.vd-ad-close:hover, .vd-ad-close:focus {
  background: #ef4444;
  border-color: #ef4444;
  color: #ffffff;
  transform: scale(1.1);
}

/* Corpo do Card */
.vd-ad-body {
  display: flex;
  gap: 12px;
  align-items: center;
}

/* Imagem do Produto */
.vd-ad-thumb-wrap {
  width: 90px;
  height: 90px;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.vd-ad-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.vd-ad-card:hover .vd-ad-thumb-wrap img {
  transform: scale(1.05);
}

.vd-ad-deal-badge {
  position: absolute;
  top: 4px;
  left: 4px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #000;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 5px;
  border-radius: 3px;
  letter-spacing: 0.3px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

/* Textos e Detalhes */
.vd-ad-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.vd-ad-title {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.vd-ad-desc {
  font-size: 11px;
  color: #94a3b8;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.vd-ad-pricing {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-top: 2px;
}

.vd-ad-old-price {
  font-size: 11px;
  color: #64748b;
  text-decoration: line-through;
}

.vd-ad-current-price {
  font-family: 'JetBrains Mono', monospace, sans-serif;
  font-size: 15px;
  font-weight: 800;
  color: var(--vd-ad-green);
  letter-spacing: -0.3px;
}

/* Botão CTA Principal */
.vd-ad-cta-btn {
  margin-top: 8px;
  width: 100%;
  padding: 8px 12px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, #00c6ff, #0072ff);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 4px 14px rgba(0, 198, 255, 0.35);
  transition: all 0.2s ease;
  text-decoration: none;
}

.vd-ad-card:hover .vd-ad-cta-btn {
  filter: brightness(1.15);
  box-shadow: 0 4px 18px rgba(0, 198, 255, 0.5);
}

.vd-ad-cta-btn svg {
  width: 14px;
  height: 14px;
  transition: transform 0.2s ease;
}

.vd-ad-card:hover .vd-ad-cta-btn svg {
  transform: translateX(3px);
}

/* Rodapé do Card */
.vd-ad-footer {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 10px;
  color: #64748b;
}

.vd-ad-link-advertise {
  color: var(--vd-ad-cyan);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
}

.vd-ad-link-advertise:hover {
  color: #ffffff;
}

/* ==========================================================================
   MODAL PÚBLICO "ANUNCIE AQUI"
   ========================================================================== */
.vd-adv-modal-backdrop {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.vd-adv-modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.vd-adv-modal {
  width: 100%;
  max-width: 520px;
  background: #0e172a;
  border: 1px solid rgba(0, 229, 255, 0.35);
  border-radius: 18px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9), 0 0 35px rgba(0, 229, 255, 0.15);
  padding: 24px;
  color: #f1f5f9;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  transform: translateY(20px) scale(0.96);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.vd-adv-modal-backdrop.open .vd-adv-modal {
  transform: translateY(0) scale(1);
}

.vd-adv-close-btn {
  position: absolute;
  top: 18px;
  right: 18px;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #94a3b8;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  transition: all 0.18s ease;
}

.vd-adv-close-btn:hover {
  background: #ef4444;
  color: #ffffff;
}

.vd-adv-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.vd-adv-pill {
  background: rgba(0, 229, 255, 0.15);
  color: var(--vd-ad-cyan);
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1px;
}

.vd-adv-title {
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 4px;
}

.vd-adv-subtitle {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.4;
  margin-bottom: 16px;
}

.vd-adv-highlights {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 18px;
}

.vd-adv-highlights ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.vd-adv-highlights li {
  font-size: 12px;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 8px;
}

.vd-adv-highlights li::before {
  content: '✓';
  color: var(--vd-ad-cyan);
  font-weight: 800;
}

/* Formulário de Contato / Lead */
.vd-adv-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.vd-adv-form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.vd-adv-form-group label {
  font-size: 12px;
  font-weight: 600;
  color: #cbd5e1;
}

.vd-adv-input, .vd-adv-select, .vd-adv-textarea {
  width: 100%;
  padding: 9px 12px;
  background: #070b14;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #f1f5f9;
  font-family: inherit;
  font-size: 13px;
  transition: all 0.2s ease;
}

.vd-adv-input:focus, .vd-adv-select:focus, .vd-adv-textarea:focus {
  outline: none;
  border-color: var(--vd-ad-cyan);
  box-shadow: 0 0 10px var(--vd-ad-cyan-glow);
}

.vd-adv-btn-submit {
  margin-top: 6px;
  padding: 12px 16px;
  border: none;
  border-radius: 10px;
  background: #25d366;
  color: #070b14;
  font-size: 14px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.35);
}

.vd-adv-btn-submit:hover {
  filter: brightness(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

.vd-adv-btn-submit svg {
  width: 18px;
  height: 18px;
}

/* Honeypot anti-spam invisível */
.vd-adv-hp {
  display: none !important;
  visibility: hidden !important;
}

/* ==========================================================================
   RESPONSIVIDADE MOBILE
   ========================================================================== */
@media (max-width: 600px) {
  .vd-ad-floating-host.pos-bottom-right,
  .vd-ad-floating-host.pos-bottom-left,
  .vd-ad-floating-host.pos-bottom-center {
    bottom: 14px;
    left: 12px;
    right: 12px;
    transform: none;
  }

  .vd-ad-card {
    width: 100%;
    max-width: 100%;
    padding: 12px;
  }

  .vd-ad-thumb-wrap {
    width: 76px;
    height: 76px;
  }

  .vd-ad-title {
    font-size: 12px;
  }

  .vd-ad-desc {
    display: none; /* Em telas muito pequenas oculta a descrição secundária para manter compacto */
  }

  .vd-ad-close {
    width: 36px;
    height: 36px; /* Aumenta a área de clique para o dedo */
  }
}
