/* Prevengames — estilos de compartir ranking + popup MiQuiz
   Añadir después de styles.css. Ajusta las variables a tu paleta real. */

:root {
  --pg-share-accent: #f4b942;
  --pg-share-dark: #073f3a;
  --pg-share-text: #f5f7fa;
}

/* Botón "Compartir en LinkedIn" (colócalo junto al podio) */
.pg-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.4rem;
  border: 0;
  border-radius: 999px;
  background: #0a66c2; /* azul LinkedIn: reconocimiento instantáneo */
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(10, 102, 194, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.pg-share-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(10, 102, 194, 0.45); }
.pg-share-btn:active { transform: translateY(0); }
.pg-share-btn:focus-visible { outline: 3px solid var(--pg-share-accent); outline-offset: 2px; }

/* Toast informativo tras descargar la imagen */
.pg-toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  transform: translate(-50%, 20px);
  max-width: min(92vw, 480px);
  padding: 0.9rem 1.2rem;
  border-radius: 12px;
  background: var(--pg-share-dark);
  color: var(--pg-share-text);
  font-size: 0.95rem;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 1200;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}
.pg-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* Popup MiQuiz */
.pg-modal { position: fixed; inset: 0; z-index: 1300; display: grid; place-items: center; padding: 1rem; }
.pg-modal__backdrop { position: absolute; inset: 0; background: rgba(8, 14, 24, 0.7); backdrop-filter: blur(3px); }
.pg-modal.is-instant .pg-modal__backdrop { opacity: 1; }

.pg-modal__card {
  position: relative;
  width: min(92vw, 420px);
  background: #fff;
  color: #0b2f2b;
  border-radius: 20px;
  padding: 2.2rem 1.8rem 1.6rem;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}
.pg-modal__emoji { font-size: 2.6rem; line-height: 1; margin-bottom: 0.6rem; }
.pg-modal__card h2 { margin: 0 0 0.5rem; font-size: 1.35rem; }
.pg-modal__card p { margin: 0 0 1.4rem; font-size: 0.98rem; color: #4a6360; }

.pg-modal__cta {
  display: block;
  padding: 0.95rem 1.2rem;
  border-radius: 999px;
  background: var(--pg-share-accent);
  color: #0b2f2b;
  font-weight: 800;
  text-decoration: none;
  transition: transform 0.15s ease, filter 0.15s ease;
}
.pg-modal__cta:hover { transform: translateY(-2px); filter: brightness(1.05); }
.pg-modal__cta:focus-visible { outline: 3px solid #0b2f2b; outline-offset: 2px; }

.pg-modal__later {
  margin-top: 0.8rem;
  background: none;
  border: 0;
  color: #8b98a9;
  font-size: 0.88rem;
  cursor: pointer;
  text-decoration: underline;
}

.pg-modal__x {
  position: absolute;
  top: 0.6rem;
  right: 0.8rem;
  background: none;
  border: 0;
  font-size: 1.6rem;
  line-height: 1;
  color: #8b98a9;
  cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
  .pg-share-btn, .pg-modal__cta, .pg-toast { transition: none; }
}
