/* ===== Reportar enlace caído (botón del reproductor + ventana) ===== */

/* --- Botón en la barra del reproductor --- */
.cf-report-open {
  display: inline-grid;
  grid-auto-flow: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-shrink: 0;
  border: none;
  border-radius: 999px;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1;
  transition: background 0.2s, transform 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.cf-report-open svg { width: 18px; height: 18px; flex-shrink: 0; }
.cf-report-open span { display: none; }
.cf-report-open:active { transform: scale(0.94); }

/* Películas: barra flotante sobre el video (igual que PiP y cerrar) */
.cf-report-open--movie {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.15);
}
.cf-report-open--movie:hover { background: var(--accent, #e50914); }

/* Series: cabecera fija del reproductor */
.cf-report-open--bar {
  width: 30px;
  height: 30px;
  background: var(--bg-elevated, #1a1a24);
  border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
  color: var(--text, #f0f0f5);
}
.cf-report-open--bar svg { width: 15px; height: 15px; }
.cf-report-open--bar:hover {
  background: var(--accent, #e50914);
  border-color: var(--accent, #e50914);
}

/* En pantallas grandes se muestra con texto */
@media (min-width: 769px) {
  .cf-report-open span { display: inline; }
  .cf-report-open--movie { width: auto; padding: 0 16px; }
  .cf-report-open--bar { width: auto; padding: 0 12px; }
}

/* --- Ventana de reporte --- */
.cf-report-dialog {
  /* El reset global del sitio quita el margin:auto del <dialog>: lo restauramos para centrarlo. */
  margin: auto;
  width: min(440px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  padding: 0;
  border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
  border-radius: 16px;
  background: var(--bg-card, #12121a);
  color: var(--text, #f0f0f5);
  box-shadow: var(--shadow, 0 8px 32px rgba(0, 0, 0, 0.5));
}
.cf-report-dialog[open] { z-index: 2100; }
.cf-report-dialog::backdrop { background: rgba(0, 0, 0, 0.72); }

.cf-report-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
}

.cf-report-title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
}

.cf-report-resumen {
  margin: -4px 0 0;
  font-size: 0.85rem;
  color: var(--text-muted, #a0a0b0);
  overflow-wrap: anywhere;
}

.cf-report-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cf-report-chip {
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
  background: var(--bg-elevated, #1a1a24);
  color: var(--text, #f0f0f5);
  font: inherit;
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.cf-report-chip:hover,
.cf-report-chip:focus-visible {
  border-color: var(--accent, #e50914);
  outline: none;
}

.cf-report-text {
  width: 100%;
  min-height: 88px;
  resize: vertical;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
  background: var(--bg-elevated, #1a1a24);
  color: var(--text, #f0f0f5);
  font: inherit;
  font-size: 16px; /* 16px evita el zoom automático de iOS al enfocar */
  box-sizing: border-box;
}
.cf-report-text:focus {
  outline: 2px solid var(--accent, #e50914);
  outline-offset: 1px;
}

.cf-report-count {
  margin-top: -8px;
  text-align: right;
  font-size: 0.72rem;
  color: var(--text-muted, #a0a0b0);
}

/* Campo trampa anti-bots: fuera de pantalla */
.cf-report-hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.cf-report-estado {
  min-height: 1.2em;
  margin: 0;
  font-size: 0.85rem;
}
.cf-report-estado[data-tipo="ok"] { color: #46d369; }
.cf-report-estado[data-tipo="error"] { color: #ff6b6b; }

.cf-report-acciones {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.cf-report-btn-pri,
.cf-report-btn-sec {
  padding: 10px 18px;
  border-radius: 10px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, opacity 0.2s;
}
.cf-report-btn-pri {
  border: none;
  background: var(--accent, #e50914);
  color: #fff;
}
.cf-report-btn-pri:hover:not(:disabled) { background: var(--accent-hover, #f40612); }
.cf-report-btn-pri:disabled { opacity: 0.6; cursor: default; }
.cf-report-btn-sec {
  border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
  background: transparent;
  color: var(--text, #f0f0f5);
}
.cf-report-btn-sec:hover { background: var(--bg-elevated, #1a1a24); }
