/* Portal de Paquetes Educativos. Hereda la estructura de lumbre.lat
   (estilo.css) y la recolorea con el verde azulado del icono de la app
   y el ámbar de la llama de Lumbre. */

:root {
  --navy: #1b7f79;
  --navy-hi: #22948c;
  --navy-lo: #073b37;
  --free: #0f8a4f;
  --free-hi: #0c7543;
  --ambar: #ffb648;
  --ink: #16211f;
  --muted: #5b6b67;
  --line: #dbe4e2;
  --bg: #f4f7f6;
  --card: #ffffff;
  --bg-alt: #edf3f1;
  --bg-alt2: #e7efec;
  --bg-alt3: #e0eae7;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(7, 59, 55, .08), 0 8px 24px rgba(7, 59, 55, .08);
}

html.tema-oscuro {
  --navy: #6cc2ba;
  --navy-hi: #8ad5cd;
  --navy-lo: #06110f;
  --free: #35b57f;
  --free-hi: #2b9d6c;
  --ink: #e9efec;
  --muted: #a4b2ad;
  --line: #334240;
  --bg: #151d1b;
  --card: #1f2725;
  --bg-alt: #242d2b;
  --bg-alt2: #283230;
  --bg-alt3: #2c3735;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 22px rgba(0, 0, 0, .45);
}

.hero {
  background:
    radial-gradient(circle at 86% 8%, rgba(255, 182, 72, .18), transparent 42%),
    linear-gradient(120deg, var(--navy-lo), var(--navy) 62%, var(--navy-hi));
}

/* La rejilla del hero comparte el div con .envoltura; sin este padding el
   shorthand de la rejilla anula el margen lateral y el texto toca el borde. */
.hero__rejilla { padding: 44px 20px 48px; }

.btn--descarga { background: var(--free); color: #fff; }
.btn--descarga:hover { background: var(--free-hi); }

.hero__nota { color: #d6e8e3; font-size: 13px; margin: 16px 0 0; }

.icono-app {
  width: 84px;
  height: 84px;
  border-radius: 20px;
  flex: none;
  box-shadow: var(--shadow);
}

/* ---------- Captura dentro de un marco de ventana ---------- */
.marco-app {
  background: #0b1311;
  padding: 10px;
  border-radius: 14px;
  box-shadow: 0 22px 55px rgba(0, 0, 0, .38);
}
.marco-app__barra {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 2px 4px 9px;
}
.marco-app__barra i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #3d4a47;
  display: block;
}
.marco-app__barra i:nth-child(1) { background: #e06c5a; }
.marco-app__barra i:nth-child(2) { background: #e0a75a; }
.marco-app__barra i:nth-child(3) { background: #6fbf73; }
.marco-app__barra span {
  margin-left: 8px;
  color: #9db4ae;
  font-size: 11px;
  font-family: ui-monospace, Consolas, monospace;
}
.marco-app img { border-radius: 5px; }
.marco-app__leyenda {
  margin: 10px 0 0;
  color: #c6dbd5;
  font-size: 12px;
  text-align: center;
}
.hero__captura { justify-self: center; width: 100%; }

/* ---------- Catálogo ---------- */
.ficha__plataformas {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  padding: 3px 10px;
  background: var(--bg-alt3);
  color: var(--navy);
  font-size: 12px;
  font-weight: 600;
}
.chip--ambar { background: #fff2dc; color: #8a5a12; }
html.tema-oscuro .chip { background: var(--bg-alt3); color: var(--navy-hi); }
html.tema-oscuro .chip--ambar { background: #33291a; color: #f0c37a; }

.ficha__botones { display: grid; gap: 8px; }
.ficha--futura {
  background: var(--bg-alt);
  border-style: dashed;
  box-shadow: none;
  color: var(--muted);
  align-items: flex-start;
  justify-content: center;
}
.ficha--futura .ficha__nombre { color: var(--muted); }
.ficha--futura .icono { background: var(--bg-alt3); color: var(--muted); }

/* ---------- Ficha del paquete ---------- */
.paquete__cuerpo h2 { font-size: 21px; margin: 30px 0 10px; }
.paquete__cuerpo h3 { font-size: 17px; margin: 22px 0 8px; }
.paquete__cuerpo p { margin: 0 0 14px; }

.cursos {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 12px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}
.cursos li {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}
.cursos strong { display: block; font-size: 15px; }
.cursos span { color: var(--muted); font-size: 13.5px; }

.galeria {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 8px 0 4px;
}
.galeria figure { margin: 0; }
.galeria figure img { border: 1px solid var(--line); border-radius: 8px; }
.galeria figcaption { margin-top: 7px; font-size: 13px; color: var(--muted); }
.galeria figcaption strong { display: block; color: var(--ink); font-size: 14px; }

.requisitos {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  font-size: 14.5px;
  margin: 0 0 16px;
}
.requisitos th,
.requisitos td { text-align: left; padding: 10px 14px; border-top: 1px solid var(--line); }
.requisitos tr:first-child th { border-top: 0; }
.requisitos th { color: var(--muted); font-weight: 600; width: 34%; }
html.tema-oscuro .requisitos th { color: var(--muted); }

.aviso-legal {
  border-left: 4px solid var(--ambar);
  background: #fffaf1;
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 14px;
  color: #6f4a12;
}
html.tema-oscuro .aviso-legal { background: #2b2418; color: #e8cb9c; }

/* ---------- Descargas ---------- */
.descargas {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
}
.descarga-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.descarga-card__cab { display: flex; align-items: center; gap: 12px; }
.descarga-card__icono {
  width: 46px;
  height: 46px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: var(--bg-alt2);
  color: var(--navy);
  flex: none;
}
.descarga-card__icono svg { width: 26px; height: 26px; }
.descarga-card h3 { margin: 0; font-size: 18px; }
.descarga-card__meta { margin: 0; color: var(--muted); font-size: 13.5px; }
.descarga-card__boton { margin-top: auto; }
.descarga-card .nota--hash code { font-size: 11.5px; }

/* ---------- Pasos y preguntas ---------- */
.pasos {
  list-style: none;
  margin: 0 0 14px;
  padding: 0;
  counter-reset: paso;
  display: grid;
  gap: 10px;
}
.pasos li {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 13px 16px 13px 52px;
}
.pasos li::before {
  counter-increment: paso;
  content: counter(paso);
  position: absolute;
  left: 15px;
  top: 14px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
}
.pasos strong { display: block; margin-bottom: 3px; }
.pasos span { color: #3d4b47; font-size: 15px; }
html.tema-oscuro .pasos span { color: var(--muted); }

.faq {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 12px 16px;
  margin: 0 0 10px;
}
.faq summary { cursor: pointer; font-weight: 600; }
.faq summary:hover { color: var(--navy); }
.faq p { margin: 8px 0 0; color: #3d4b47; font-size: 14.5px; }
html.tema-oscuro .faq p { color: var(--muted); }

html.tema-oscuro .producto__cuerpo p,
html.tema-oscuro dd,
html.tema-oscuro .lista--rasgos span,
html.tema-oscuro .cursos span { color: var(--muted); }
html.tema-oscuro .lista--rasgos li { border-color: var(--line); }
html.tema-oscuro .nota--hash code { background: var(--bg-alt3); color: var(--ink); }
html.tema-oscuro .miga a { color: var(--muted); }
html.tema-oscuro .btn--fant { color: var(--ink); }
html.tema-oscuro .btn--fant:hover { color: #fff; background: var(--navy); border-color: var(--navy); }
html.tema-oscuro .baner span { color: rgba(255, 255, 255, .85); }
html.tema-oscuro .icono-app { box-shadow: 0 8px 22px rgba(0, 0, 0, .5); }

/* La base fija el fondo de .marco en blanco; en tema oscuro el texto es
   claro y quedaría ilegible. */
.marco { background: var(--card); }

/* El hash y los nombres de archivo no tienen espacios: sin esto su ancho
   mínimo ensancha la columna y desborda en móvil. */
.nota--hash code { overflow-wrap: anywhere; }
.compra__datos span:last-child { overflow-wrap: anywhere; }

/* ---------- Tabla de descargas del catálogo ---------- */
.tabla-descargas {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  font-size: 14.5px;
}
.tabla-descargas th,
.tabla-descargas td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.tabla-descargas thead th {
  background: var(--bg-alt3);
  color: var(--navy);
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: .4px;
  white-space: nowrap;
}
.tabla-descargas tbody tr:last-child th,
.tabla-descargas tbody tr:last-child td { border-bottom: 0; }
.tabla-descargas tbody th { font-weight: 700; }
.tabla-descargas tbody th a { color: var(--navy); }
.tabla-descargas td { color: var(--muted); }

@media (max-width: 640px) {
  .tabla-descargas { font-size: 13px; }
  .tabla-descargas th, .tabla-descargas td { padding: 10px 11px; }
}
html.tema-oscuro .tabla-descargas thead th { color: var(--navy-hi); }
html.tema-oscuro .tabla-descargas tbody th a { color: var(--navy-hi); }

@media (max-width: 940px) {
  .hero__captura { margin-top: 8px; }
  .producto { grid-template-columns: minmax(0, 1fr); }
  .producto__cuerpo, .compra { min-width: 0; }
  .galeria { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .compra__botones .btn { width: 100%; }
  .producto__cab { align-items: flex-start; }
  .producto__cab h1 { font-size: 26px; }
  .hero h1 { font-size: 27px; }
}
