/* Reacciones químicas — estilo sobrio para secundaria.
   Fondo blanco, títulos #1F5C8B, Arial, mucho aire. */

:root {
  --azul: #1F5C8B;
  --azul-claro: #E8F0F6;
  --gris: #4A4A4A;
  --gris-suave: #767676;
  --linea: #D9E2EA;
  --ambar: #C77A0A;
  --rojo: #C0392B;
  --verde: #2E7D5B;
}

.reveal {
  font-family: Arial, Helvetica, sans-serif;
  color: var(--gris);
  font-size: 34px;
}
.reveal .slides section {
  text-align: left;
  padding: 0 2.5rem;
}

.reveal h1 { font-size: 1.9em; color: var(--azul); font-weight: bold; letter-spacing: -0.5px; }
.reveal h2 { font-size: 1.25em; color: var(--azul); font-weight: bold; margin-bottom: 1.4rem; }
.reveal h3 { font-size: 0.95em; color: var(--azul); font-weight: bold; margin-bottom: 0.8rem; }
.reveal h1, .reveal h2, .reveal h3 { text-transform: none; text-shadow: none; }

.reveal p { line-height: 1.5; }
.reveal ul { list-style: none; margin-left: 0; }
.reveal ul li {
  margin: 0.75em 0;
  padding-left: 1.5em;
  position: relative;
  line-height: 1.35;
}
.reveal ul li::before {
  content: '';
  position: absolute;
  left: 0; top: 0.52em;
  width: 0.42em; height: 0.42em;
  border-radius: 50%;
  background: var(--azul);
}

.reveal strong { color: var(--azul); }
.reveal em { font-style: normal; color: var(--ambar); font-weight: bold; }

/* --- Portada --- */
.portada { display: flex; flex-direction: column; justify-content: center; height: 100%; }
.portada .franja { width: 120px; height: 8px; background: var(--azul); margin-bottom: 2rem; }
.portada .bajada { color: var(--gris-suave); font-size: 0.8em; margin-top: 1.2rem; }

/* --- Rótulos y notas --- */
.rotulo {
  display: inline-block;
  font-size: 0.55em;
  letter-spacing: 1.5px;
  color: var(--gris-suave);
  border-bottom: 3px solid var(--linea);
  padding-bottom: 0.35rem;
  margin-bottom: 1.6rem;
}
.nota { font-size: 0.62em; color: var(--gris-suave); margin-top: 1.4rem; }
.destacado {
  background: var(--azul-claro);
  border-left: 6px solid var(--azul);
  padding: 1.1rem 1.5rem;
  font-size: 0.85em;
}

/* --- Grillas --- */
.grilla { display: grid; gap: 2rem; align-items: center; }
.g2 { grid-template-columns: 1fr 1fr; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g5 { grid-template-columns: repeat(5, 1fr); gap: 1.2rem; }

.tarjeta {
  border: 2px solid var(--linea);
  border-radius: 10px;
  padding: 1.3rem;
  text-align: center;
  font-size: 0.66em;
  line-height: 1.3;
}
.tarjeta .titulo { color: var(--azul); font-weight: bold; display: block; margin-bottom: 0.4rem; }
.tarjeta svg.icono { width: 74px; height: 74px; display: block; margin: 0 auto 0.7rem; }

/* --- Moléculas --- */
.ecuacion {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.1rem;
  flex-wrap: wrap;
  margin: 1.6rem 0;
}
.mol { width: 130px; height: 130px; }
.mol.chica { width: 96px; height: 96px; }
.mol svg { width: 100%; height: 100%; }
.mol svg text { font-family: Arial, Helvetica, sans-serif; font-weight: bold; }

.op { font-size: 1.5em; color: var(--gris-suave); }
.op.flecha { color: var(--azul); }
.coef { font-size: 1.1em; color: var(--ambar); font-weight: bold; }

.pie-mol { text-align: center; font-size: 0.55em; color: var(--gris-suave); margin-top: -0.6rem; }

/* --- Fórmulas escritas --- */
.formula {
  font-size: 1.15em;
  letter-spacing: 1px;
  text-align: center;
  margin: 1.5rem 0;
}
.formula .c { color: var(--ambar); font-weight: bold; }
.formula .s { color: var(--rojo); font-weight: bold; }
.formula .fl { color: var(--azul); padding: 0 0.5rem; }

/* --- Tabla de conteo --- */
table.conteo {
  margin: 1.2rem auto;
  border-collapse: collapse;
  font-size: 0.68em;
}
table.conteo th, table.conteo td {
  border: 1px solid var(--linea);
  padding: 0.55rem 1.5rem;
  text-align: center;
}
table.conteo th { background: var(--azul-claro); color: var(--azul); }
table.conteo td.ok { color: var(--verde); font-weight: bold; }
table.conteo td.mal { color: var(--rojo); font-weight: bold; }

/* --- Detectá el error --- */
.error-caja {
  border: 2px dashed var(--rojo);
  border-radius: 10px;
  padding: 1.2rem 1.6rem;
  margin: 1.2rem 0;
  font-size: 0.85em;
}
.respuesta {
  border-left: 6px solid var(--verde);
  background: #F1F8F4;
  padding: 1.1rem 1.5rem;
  font-size: 0.75em;
  line-height: 1.4;
}
.respuesta .etiqueta { color: var(--verde); font-weight: bold; display: block; margin-bottom: 0.3rem; }

/* --- Tres niveles (Johnstone) --- */
.nivel { border-top: 5px solid var(--azul); padding-top: 1rem; font-size: 0.62em; line-height: 1.35; }
.nivel .titulo { color: var(--azul); font-weight: bold; display: block; margin-bottom: 0.5rem; font-size: 1.15em; }

/* --- Balanceador interactivo --- */
.balanceador { display: flex; align-items: center; justify-content: center; gap: 0.9rem; margin: 1.4rem 0; }
.balanceador .sustancia { display: flex; align-items: center; gap: 0.5rem; font-size: 1.15em; }

.paso {
  display: flex; flex-direction: column; align-items: center;
  border: 2px solid var(--linea); border-radius: 9px; overflow: hidden;
}
.paso button {
  font-family: Arial, sans-serif; font-size: 0.5em; font-weight: bold; line-height: 1;
  color: #fff; background: var(--azul); border: 0; width: 100%;
  padding: 0.28rem 0.7rem; cursor: pointer;
}
.paso button:hover { background: #17456a; }
.paso .n {
  font-size: 0.85em; font-weight: bold; color: var(--ambar);
  padding: 0.2rem 0.9rem; min-width: 2.2rem; text-align: center;
}

.veredicto {
  margin-top: 1.2rem; padding: 0.9rem 1.4rem; border-radius: 9px;
  font-size: 0.75em; font-weight: bold; text-align: center;
}
.veredicto.mal { background: #FBEFEE; color: var(--rojo); }
.veredicto.bien { background: #F1F8F4; color: var(--verde); }

/* --- Clasificador interactivo --- */
.opciones { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.7rem; margin: 1.5rem 0; }
.opciones button {
  font-family: Arial, sans-serif; font-size: 0.52em; font-weight: bold; line-height: 1.25;
  color: var(--azul); background: #fff; border: 2px solid var(--linea);
  border-radius: 9px; padding: 0.9rem 0.4rem; cursor: pointer;
}
.opciones button:hover:not(:disabled) { border-color: var(--azul); background: var(--azul-claro); }
.opciones button:disabled { cursor: default; }
.opciones button.acierto { border-color: var(--verde); background: #F1F8F4; color: var(--verde); }
.opciones button.fallo { border-color: var(--rojo); background: #FBEFEE; color: var(--rojo); }

.progreso { font-size: 0.55em; color: var(--gris-suave); letter-spacing: 1px; }
.siguiente {
  font-family: Arial, sans-serif; font-size: 0.6em; font-weight: bold;
  color: #fff; background: var(--azul); border: 0; border-radius: 8px;
  padding: 0.7rem 1.6rem; cursor: pointer; margin-top: 0.4rem;
}

/* ================= Framework de actividades ================= */

.consigna { font-size: 0.68em; color: var(--azul); font-weight: bold; margin-bottom: 0.9rem; }

.devolucion {
  font-size: 0.6em; line-height: 1.4; margin-top: 1rem;
  padding: 0.8rem 1.2rem; border-radius: 8px; display: none;
}
.devolucion.visible { display: block; }
.devolucion.bien { background: #F1F8F4; border-left: 5px solid var(--verde); }
.devolucion.mal  { background: #FBEFEE; border-left: 5px solid var(--rojo); }
.devolucion .etiqueta { font-weight: bold; display: block; margin-bottom: 0.2rem; }
.devolucion.bien .etiqueta { color: var(--verde); }
.devolucion.mal  .etiqueta { color: var(--rojo); }

/* --- Botonera de opciones (2 a 5 opciones) --- */
.actividad .opciones { display: grid; gap: 0.7rem; }
.actividad .opciones.dos    { grid-template-columns: 1fr 1fr; }
.actividad .opciones.tres   { grid-template-columns: repeat(3, 1fr); }
.actividad .opciones.cuatro { grid-template-columns: repeat(4, 1fr); }
.actividad .opciones.cinco  { grid-template-columns: repeat(5, 1fr); }

.actividad .opciones button {
  font-family: Arial, sans-serif; font-size: 0.55em; font-weight: bold; line-height: 1.3;
  color: var(--azul); background: #fff; border: 2px solid var(--linea);
  border-radius: 9px; padding: 1rem 0.8rem; cursor: pointer; text-align: center;
}
.actividad .opciones button:hover:not(:disabled) { border-color: var(--azul); background: var(--azul-claro); }
.actividad .opciones button:disabled { cursor: default; }
.actividad .opciones button.acierto { border-color: var(--verde); background: #F1F8F4; color: var(--verde); }
.actividad .opciones button.fallo   { border-color: var(--rojo);  background: #FBEFEE; color: var(--rojo); }

/* --- Clic para revelar --- */
.revelable {
  font-family: Arial, sans-serif; font-size: 1em; text-align: left;
  background: #fff; border: 2px dashed var(--linea); border-radius: 9px;
  padding: 0.9rem 1.2rem; cursor: pointer; width: 100%;
  color: var(--gris); line-height: 1.35;
}
.revelable:hover { border-color: var(--azul); }
.revelable.abierta { border-style: solid; border-color: var(--azul); background: var(--azul-claro); cursor: default; }
.revelable .rotulo-r { color: var(--azul); font-weight: bold; display: block; font-size: 0.62em; }
.revelable .contenido { display: none; font-size: 0.56em; margin-top: 0.5rem; }
.revelable.abierta .contenido { display: block; }
.revelable .pista-clic { font-size: 0.5em; color: var(--gris-suave); }
.revelable.abierta .pista-clic { display: none; }

.pila { display: grid; gap: 0.7rem; }
.pila.dos { grid-template-columns: 1fr 1fr; }
.pila.tres { grid-template-columns: repeat(3, 1fr); }
.pila.cinco { grid-template-columns: repeat(5, 1fr); }
.pila .revelable { text-align: center; }

/* Escenas de dos estados, para los interruptores */
.escena > .cuadro { display: none; }
.escena.uno > .cuadro.uno,
.escena.dos > .cuadro.dos { display: flex; }
.eco { font-size: 0.6em; color: var(--gris); margin-top: 0.9rem; line-height: 1.4; }
.eco b { color: var(--azul); }

/* --- Clasificar en dos grupos --- */
.fichas { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.7rem; margin-bottom: 1rem; }
.ficha {
  font-family: Arial, sans-serif; font-size: 0.55em; line-height: 1.3;
  border: 2px solid var(--linea); border-radius: 9px; background: #fff;
  padding: 0.8rem 0.6rem; cursor: pointer; color: var(--gris); text-align: center;
}
.ficha .grupo { display: block; font-weight: bold; color: var(--gris-suave); margin-top: 0.35rem; }
.ficha[data-estado="0"] .grupo { color: var(--azul); }
.ficha[data-estado="1"] .grupo { color: var(--ambar); }
.ficha.acierto { border-color: var(--verde); background: #F1F8F4; }
.ficha.fallo   { border-color: var(--rojo);  background: #FBEFEE; }

.comprobar {
  font-family: Arial, sans-serif; font-size: 0.6em; font-weight: bold;
  color: #fff; background: var(--azul); border: 0; border-radius: 8px;
  padding: 0.65rem 1.5rem; cursor: pointer;
}
.comprobar:disabled { background: #A9B7C2; cursor: default; }

/* --- Interruptor de dos estados --- */
.interruptor { display: inline-flex; border: 2px solid var(--azul); border-radius: 9px; overflow: hidden; }
.interruptor button {
  font-family: Arial, sans-serif; font-size: 0.55em; font-weight: bold;
  background: #fff; color: var(--azul); border: 0; padding: 0.6rem 1.4rem; cursor: pointer;
}
.interruptor button.activo { background: var(--azul); color: #fff; }

/* --- Panel de modo y marcador --- */
#barra-modo {
  position: fixed; top: 14px; right: 18px; z-index: 60;
  display: flex; align-items: center; gap: 0.8rem;
  font-family: Arial, sans-serif; font-size: 14px;
}
#barra-modo button {
  font-family: Arial, sans-serif; font-size: 13px; font-weight: bold;
  border: 2px solid var(--linea); background: #fff; color: var(--azul);
  border-radius: 20px; padding: 0.35rem 1rem; cursor: pointer;
}
#barra-modo button:hover { border-color: var(--azul); }
#marcador { color: var(--gris-suave); }
#marcador b { color: var(--verde); }
body.modo-clase #marcador { display: none; }

/* --- Resumen final --- */
.resumen-nota { font-size: 3.2em; font-weight: bold; color: var(--azul); }
.barra-progreso { height: 14px; background: var(--linea); border-radius: 7px; overflow: hidden; margin: 1.2rem 0; }
.barra-progreso div { height: 100%; background: var(--verde); width: 0; transition: width 0.4s; }

/* --- Numeración --- */
.reveal .slide-number { font-size: 15px; color: var(--gris-suave); background: none; }

/* ================= Deck de atmósfera ================= */

.reveal sub { font-size: 0.62em; vertical-align: -0.28em; letter-spacing: 0; }
.reveal sup { font-size: 0.62em; vertical-align: 0.5em; }

.mol.mini { width: 40px; height: 40px; }
.rot-mini {
  display: block; font-size: 0.4em; letter-spacing: 1.2px;
  color: var(--gris-suave); text-transform: uppercase; margin-bottom: 0.4rem;
}
.dato { font-size: 0.5em; line-height: 1.45; margin: 0.25rem 0; }
.dato b { color: var(--azul); }
.dato .chico { font-size: 0.82em; color: var(--gris-suave); }
.aviso-escala { font-size: 0.48em; color: var(--ambar); margin-top: 0.6rem; }

/* --- Widget 1: columna de atmósfera --- */
.columna-grilla {
  display: grid; grid-template-columns: 185px 335px 1fr;
  gap: 1.2rem; align-items: start;
}
.caja-aire { width: 100%; height: auto; display: block; }
.muestra .caja-cont { width: 168px; }
.muestra .leyenda { font-size: 0.42em; color: var(--gris-suave); margin-top: 0.5rem; }
.muestra .leyenda b { font-size: 1.3em; }

/* Ancho tope: el SVG escala con el contenedor y sin este límite la columna
   se estira hasta desbordar los 720 px de alto de la diapositiva. */
.corte { max-width: 330px; }
.svg-corte { width: 100%; height: auto; }
.svg-corte text { font-family: Arial, Helvetica, sans-serif; font-size: 9px; fill: var(--gris); }
.svg-corte text.cap { font-size: 10px; font-weight: bold; fill: var(--azul); opacity: 0.75; }
.svg-corte .nivel-actual { stroke: var(--rojo); stroke-width: 2.4; }
.svg-corte .hito circle { fill: #FFFFFF; stroke: var(--gris-suave); stroke-width: 1.4; }
.svg-corte .hito text { fill: var(--gris-suave); }
.svg-corte .hito.encendido circle { fill: var(--ambar); stroke: var(--ambar); }
.svg-corte .hito.encendido text { fill: var(--ambar); font-weight: bold; }

.slider-alt { width: 100%; margin: 0.2rem 0 0.7rem; accent-color: var(--azul); }

/* En la versión puntuada el corte y las fichas van lado a lado, y la caja de
   muestra se oculta: esa parte ya se trabajó en la exploración libre. */
.widget-columna[data-puntuada] { display: grid; grid-template-columns: 470px 1fr; gap: 1.4rem; }
.widget-columna[data-puntuada] .muestra { display: none; }
.widget-columna[data-puntuada] .columna-grilla { grid-template-columns: 290px 1fr; }
.widget-columna[data-puntuada] .corte { max-width: 285px; }
.widget-columna[data-puntuada] .dato { font-size: 0.44em; }

.hitos-consigna { margin-top: 0; }
.hitos-fichas { display: grid; gap: 0.25rem; }
.hito-ficha {
  display: grid; grid-template-columns: 185px 160px 1fr; gap: 0.6rem; align-items: center;
  border: 2px solid var(--linea); border-radius: 8px; padding: 0.15rem 0.6rem;
}
.hito-ficha .texto { font-size: 0.44em; font-weight: bold; color: var(--azul); }
.hito-ficha select {
  font-family: Arial, sans-serif; font-size: 13px; padding: 0.2rem;
  border: 1px solid var(--linea); border-radius: 6px; color: var(--gris); background: #fff;
}
.hito-ficha .veredicto-hito { font-size: 0.36em; line-height: 1.25; color: var(--gris-suave); }
.hito-ficha.acierto { border-color: var(--verde); background: #F1F8F4; }
.hito-ficha.fallo   { border-color: var(--rojo);  background: #FBEFEE; }
.hitos-consigna .comprobar { margin-top: 0.5rem; font-size: 0.5em; padding: 0.45rem 1.2rem; }
.hitos-consigna .consigna { font-size: 0.55em; margin-bottom: 0.5rem; }

/* --- Widget 2: composición --- */
.comp-grilla { display: grid; grid-template-columns: 320px 1fr; gap: 2rem; align-items: start; }
.grilla-100 {
  display: grid; grid-template-columns: repeat(10, 1fr); gap: 3px;
  width: 300px; border: 2px solid var(--linea); border-radius: 6px; padding: 5px;
}
.grilla-100 i { display: block; aspect-ratio: 1; border-radius: 2px; background: #EDF1F4; }
.comp-fila { display: flex; align-items: center; gap: 0.5rem; font-size: 0.52em; margin-bottom: 0.5rem; }
.comp-fila .punto { width: 0.9em; height: 0.9em; border-radius: 50%; flex: 0 0 auto; }
.comp-fila .nom { flex: 1; }
.comp-fila .n { min-width: 2.2em; text-align: center; font-weight: bold; color: var(--azul); }
.comp-fila button {
  font-family: Arial, sans-serif; font-weight: bold; font-size: 0.85em; line-height: 1;
  color: #fff; background: var(--azul); border: 0; border-radius: 6px;
  padding: 0.3rem 0.6rem; cursor: pointer;
}
.comp-controles .comprobar { margin-top: 0.6rem; font-size: 0.52em; padding: 0.5rem 1.3rem; }
.desglose { margin-top: 0.6rem; }

/* --- Widget 3: caja del carbono --- */
.carbono-grilla { display: grid; grid-template-columns: 210px 250px 1fr; gap: 1.1rem; align-items: start; }
.palanca {
  display: block; width: 100%; text-align: left; margin-bottom: 0.4rem;
  font-family: Arial, sans-serif; font-size: 0.46em; font-weight: bold; line-height: 1.2;
  border: 2px solid var(--linea); border-radius: 8px; background: #fff;
  color: var(--gris-suave); padding: 0.45rem 0.7rem; cursor: pointer;
}
.palanca .sig { display: block; font-size: 0.8em; font-weight: normal; }
.palanca.on { border-color: var(--azul); background: var(--azul-claro); color: var(--azul); }

.caja-atm { border: 3px solid var(--azul); border-radius: 10px; padding: 0.7rem 0.9rem; }
.caja-atm .flechas { display: flex; flex-direction: column; gap: 0.15rem; margin-bottom: 0.4rem; }
.flecha { font-size: 0.4em; font-weight: bold; }
.flecha.entra { color: var(--rojo); }
.flecha.sale  { color: var(--verde); }
.flecha.fosil { color: #7B2D26; }
.contador { font-size: 1.1em; font-weight: bold; color: var(--azul); margin: 0.2rem 0; }
.contador span { font-size: 0.42em; font-weight: normal; color: var(--gris-suave); }
.tendencia { font-size: 0.42em; line-height: 1.3; }
.tendencia.estable { color: var(--verde); }
.tendencia.sube { color: var(--rojo); font-weight: bold; }
.tendencia.baja { color: var(--ambar); }

.ec-fila {
  display: grid; grid-template-columns: 1fr 110px; gap: 0.4rem;
  align-items: center; border-top: 1px solid var(--linea); padding: 0.1rem 0;
}
.carbono-grilla .mol.mini { width: 30px; height: 30px; }
.carbono-grilla .ec-sim { font-size: 0.4em; }
.carbono-grilla .ec-macro { font-size: 0.35em; }
.caja-atm .contador { font-size: 0.85em; }
.carbono-grilla .caja-atm { padding: 0.5rem 0.8rem; }
.carbono-grilla .ec-fila { padding: 0; }
.ec-nom { grid-column: 1; font-size: 0.42em; font-weight: bold; color: var(--azul); }
.ec-sim { grid-column: 1; font-size: 0.44em; }
.ec-macro { grid-column: 1; font-size: 0.38em; color: var(--gris-suave); }
.ec-mol { grid-column: 2; grid-row: 1 / span 3; display: flex; gap: 0.2rem; }
.consigna-carbono { margin-top: 0.6rem; }
.consigna-carbono .consigna { font-size: 0.5em; margin-bottom: 0.3rem; }
.consigna-carbono .opciones button { font-size: 0.46em; padding: 0.5rem 0.4rem; }
.consigna-carbono .devolucion { font-size: 0.46em; margin-top: 0.5rem; padding: 0.6rem 1rem; }

/* --- Cajas de partículas dibujadas a mano en las diapositivas --- */
.caja-part { border: 2px solid var(--azul); border-radius: 8px; background: #fff; }
.caja-part text { font-family: Arial, Helvetica, sans-serif; }
.par-rot { font-size: 0.45em; color: var(--gris-suave); text-align: center; margin-top: 0.3rem; }

/* --- Tabla de gases (ficha) --- */
table.gases { width: 100%; border-collapse: collapse; font-size: 0.52em; margin-top: 0.6rem; }
table.gases th, table.gases td { border-bottom: 1px solid var(--linea); padding: 0.4rem 0.7rem; text-align: left; }
table.gases th { color: var(--azul); background: var(--azul-claro); }
table.gases td.f { white-space: nowrap; font-weight: bold; color: var(--gris); }
table.gases .mol { width: 46px; height: 46px; display: inline-block; vertical-align: middle; margin-right: 0.4rem; }
