/* ============================================================
   Tour guiado in-app — estilos compartilhados (index + admin)
   Paleta do app: accent #e94560, texto #1a1a2e, fundo card #fff
   z-index: acima de tudo (maior do app é 10000 = lightbox)
   ============================================================ */

/* ---- Botão "?" no header ---- */
.tour-help-btn {
  width: 30px;
  height: 30px;
  min-width: 30px;
  border-radius: 50%;
  border: 1px solid #555;
  background: none;
  color: #999;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: border-color 0.15s, color 0.15s;
}
.tour-help-btn:hover {
  border-color: #e94560;
  color: #e94560;
}
/* variante menor para dentro de drawers/painéis claros */
.tour-help-btn--light {
  border-color: #ccc;
  color: #888;
}

/* ---- Overlay raiz ---- */
#site-tour-root {
  position: fixed;
  inset: 0;
  z-index: 20000;
  animation: tourFadeIn 0.2s ease;
}
@keyframes tourFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
#site-tour-root.tour-closing {
  opacity: 0;
  transition: opacity 0.18s ease;
}

/* Camada que bloqueia cliques na página durante o tour */
.tour-click-guard {
  position: absolute;
  inset: 0;
}

/* ---- Spotlight ----
   Caixa transparente sobre o elemento-alvo; o box-shadow gigante
   escurece todo o resto da tela. */
.tour-spotlight {
  position: fixed;
  border-radius: 10px;
  box-shadow: 0 0 0 200vmax rgba(15, 17, 32, 0.62);
  transition: top 0.25s ease, left 0.25s ease, width 0.25s ease, height 0.25s ease;
  pointer-events: none;
}
/* Passo sem alvo (intro): spotlight some, só escurece */
.tour-spotlight.tour-spotlight--none {
  top: 50% !important;
  left: 50% !important;
  width: 0 !important;
  height: 0 !important;
  border-radius: 50%;
}

/* ---- Card do passo ---- */
.tour-card {
  position: fixed;
  width: 340px;
  max-width: calc(100vw - 24px);
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  padding: 18px 20px 14px;
  color: #1a1a2e;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  transition: top 0.25s ease, left 0.25s ease;
}
.tour-card--center {
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: none;
}
.tour-card-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 26px;
  height: 26px;
  border: none;
  background: #f0f2f5;
  border-radius: 50%;
  color: #666;
  font-size: 0.85rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tour-card-close:hover { background: #e2e5ea; color: #1a1a2e; }
.tour-card-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: #e94560;
  margin-bottom: 6px;
}
.tour-card-title {
  margin: 0 18px 8px 0;
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.3;
}
.tour-card-text {
  margin: 0 0 14px;
  font-size: 0.86rem;
  line-height: 1.5;
  color: #444;
}
.tour-card-text b { color: #1a1a2e; }

/* rodapé: contador + botões */
.tour-card-footer {
  display: flex;
  align-items: center;
  gap: 8px;
}
.tour-card-count {
  font-size: 0.75rem;
  color: #999;
  margin-right: auto;
  white-space: nowrap;
}
.tour-btn {
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 7px 14px;
  cursor: pointer;
  font-family: inherit;
}
.tour-btn-prev {
  background: #fff;
  border: 1px solid #d0d3d9;
  color: #555;
}
.tour-btn-prev:hover { border-color: #999; color: #1a1a2e; }
.tour-btn-prev:disabled { opacity: 0.4; cursor: default; }
.tour-btn-next {
  background: #e94560;
  border: 1px solid #e94560;
  color: #fff;
}
.tour-btn-next:hover { background: #d63851; border-color: #d63851; }

/* ---- Balão de dica (1ª visita) ---- */
.tour-hint {
  position: fixed;
  z-index: 19000;
  background: #1a1a2e;
  color: #fff;
  border-radius: 12px;
  padding: 10px 34px 10px 14px;
  font-size: 0.8rem;
  line-height: 1.4;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
  max-width: 240px;
  cursor: pointer;
  animation: tourHintIn 0.3s ease;
}
@keyframes tourHintIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
/* setinha apontando para o botão "?" acima */
.tour-hint::before {
  content: '';
  position: absolute;
  top: -6px;
  right: 18px;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: 6px solid #1a1a2e;
}
.tour-hint-close {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 20px;
  height: 20px;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  color: #ccc;
  font-size: 0.7rem;
  line-height: 1;
  cursor: pointer;
}

/* ---- Mobile (≤768px): card vira bottom sheet ---- */
@media (max-width: 768px) {
  .tour-card,
  .tour-card--center {
    top: auto !important;
    left: 0 !important;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 100%;
    transform: none;
    border-radius: 14px 14px 0 0;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
    transition: none;
  }
  .tour-hint {
    left: 12px !important;
    right: 12px;
    max-width: none;
  }
  .tour-hint::before { right: 30px; }
}
