@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

/* ========= Base ========= */
html, body {
  height: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Poppins', sans-serif;
  color: #fff;
  /* El fondo real va en las clases body.*-page */
  background: #000; /* fallback por si no carga la imagen */
  position: relative;      /* crea contexto de apilado para el overlay */
  z-index: 0;              /* asegura que ::before quede justo debajo del contenido */
}

/* Capa oscura encima del fondo, pero debajo del contenido */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 0;
  pointer-events: none;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ========= Helpers ========= */
.container {
  max-width: 1024px;
  margin: 0 auto;
  padding: 2rem;
}

/* ========= Hero (index) ========= */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #fff !important;
}

.hero h2 {
  font-size: 1.3rem;
  font-weight: 400;
  margin-bottom: 2rem;
  opacity: 0.9;
  color: #fff !important;}

.btn-primary {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid #fff;
  color: #fff;
  font-weight: 600;
  transition: background 0.3s, color 0.3s;
}

.btn-primary:hover {
  background: #fff;
  color: #0e613e;
}

/* ========= Generator ========= */
.gen-wrapper {
  max-width: 600px;
  margin: 4rem auto;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  backdrop-filter: blur(4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  position: relative;
  color: #fff;
  z-index: 1; /* por encima del overlay */
}

.gen-header {
  text-align: center;
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.version-info {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.7rem;
  opacity: 0.8;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

input[type="text"], select {
  width: 100%;
  padding: 0.6rem 1rem;
  border: none;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: 1rem;
  color: #333;
}

input[type="text"]::placeholder {
  color: #777;
}

.error-message {
  background: rgba(220, 53, 69, 0.9);
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  display: none;
}

/* Consola */
.console {
  background: #010d10;
  color: #00ff66;
  padding: 1rem;
  border-radius: 6px;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  display: none;
  max-height: 300px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: 0 0 10px rgba(0, 255, 102, 0.6);
}

.activities {
  background: rgba(255, 255, 255, 0.05);
  padding: 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
}

.activities h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.activity-item {
  font-size: 0.85rem;
  margin-bottom: 0.3rem;
  color: #e6e6e6;
}

/* Comentarios (bloque genérico) */
.comments {
  background: rgba(255, 255, 255, 0.05);
  padding: 1rem;
  border-radius: 6px;
}

.comment {
  margin-bottom: 0.8rem;
}

.comment .author {
  font-weight: 600;
  margin-right: 0.5rem;
}

.comment .time {
  font-size: 0.75rem;
  opacity: 0.7;
}

.comment p {
  margin: 0.4rem 0 0 0;
  font-size: 0.9rem;
}

/* Botón principal */
.btn-generate {
  width: 100%;
  padding: 1rem 1.5rem;
  border: none;
  border-radius: 40px;
  background: linear-gradient(135deg, #007bff, #0056b3);
  color: #fff;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 1rem;
  transition: transform 0.2s ease, box-shadow 0.3s ease, background 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-generate:hover {
  background: linear-gradient(135deg, #0056b3, #004080);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

/* ========= Modal ========= */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content {
  background: #fff;
  padding: 2rem;
  border-radius: 8px;
  max-width: 400px;
  color: #333;
  text-align: center;
}

.modal-content h2 {
  margin-top: 0;
  color: #c82333;
}

.btn-verify {
  margin-top: 1rem;
  padding: 0.7rem 1.5rem;
  background: #c82333;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
}

.btn-verify:hover {
  background: #a71d2a;
}

/* ========= Fondos por página ========= */
/* Importante: usa rutas relativas; si sirves desde subcarpeta, no 404 */
body.hero-page {
  background-image: url('images/background1.jpg');
  background-position: center;
  background-repeat: repeat;
  background-size: cover;
  /* En iOS/Android, background-attachment: fixed falla; se simula con position:fixed en ::before */
  background-attachment: scroll;
}

body.generator-page {
  background-image: url('images/background.jpg');
  background-position: center;
  background-repeat: nrepeat;
  background-size: cover;
  background-attachment: scroll;
}

/* Iconos junto a labels */
.icon {
  vertical-align: middle;
  margin-right: 0.5rem;
  width: 32px;
  height: 32px;
}

/* ========= Comentarios estilo “FB-like” ========= */
.comment-section {
  background: rgba(255, 255, 255, 0.9);
  color: #333;
  padding: 1rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  z-index: 1;
  position: relative;
}

.comment-section .comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.comment-section .comment-header select {
  background: transparent;
  color: inherit;
  border: none;
}

.comment-section .comment-input textarea {
  width: 100%;
  border-radius: 6px;
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  padding: 0.6rem;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  resize: vertical;
}

.comment-section .comment {
  display: flex;
  margin-bottom: 1rem;
}

.comment-section .comment .avatar {
  width: 40px;
  height: 40px;
  margin-right: 0.5rem;
  border-radius: 50%;
  flex-shrink: 0;
}

.comment-section .comment .content {
  flex-grow: 1;
}

.comment-section .comment .header {
  font-weight: 600;
  font-size: 0.9rem;
}

.comment-section .comment .meta {
  font-size: 0.7rem;
  opacity: 0.7;
}

.comment-section .comment .message {
  margin-top: 0.2rem;
  font-size: 0.9rem;
}

.comment-section .comment .actions {
  margin-top: 0.3rem;
  font-size: 0.7rem;
  color: #007bff;
  cursor: pointer;
}

.comment-section .comment .actions span {
  margin-right: 0.5rem;
}

.comment-section .reply {
  margin-left: 2rem;
}

.comment-section .load-more {
  text-align: center;
  font-size: 0.9rem;
  padding: 0.6rem;
  background: #f5f5f5;
  border-radius: 6px;
  cursor: pointer;
  color: #007bff;
}

/* ========= Responsive ========= */
@media (max-width: 600px) {
  .gen-wrapper {
    margin: 2rem;
    padding: 1.5rem;
  }
  .hero h1 {
    font-size: 2.3rem;
    color: #fff !important;  }
  .hero h2 {
    font-size: 1rem;
    color: #fff !important;  }
}