/* Gemelo /demo (WEB4-4). Usa marca.css y estilos.css de la página; aquí solo lo propio. */
.demo-principal { padding-block: 2.5rem 4rem; }
.demo-principal h1 { font-size: clamp(2rem, 1.4rem + 2.4vw, 3.2rem); letter-spacing: -0.03em; max-width: 22ch; }
.demo-entrada > p:first-child { margin-top: 1rem; max-width: 60ch; color: var(--texto-suave); font-size: 1.15rem; }
.demo-entrada p + p { margin-top: 1.5rem; }
.demo-sin-js { margin-top: 1.5rem; font-weight: 600; }

/* Franja fija de datos de prueba, con el mismo tono que usa la plataforma en su entorno de prueba. */
.demo-franja {
  position: sticky;
  top: var(--alto-cabecera, 4.5rem);
  z-index: 45;
  background: #7a5a12;
  color: #fff;
  font-size: 0.95rem;
}
.demo-franja-fila { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.25rem 1rem; padding-block: 0.55rem; }
.demo-franja[hidden] { display: none; }

.demo-recorrido { margin-top: 2rem; }
.demo-panel { margin-top: 2rem; }
.demo-panel .rol-texto h2 { font-size: clamp(1.6rem, 1.25rem + 1.4vw, 2.3rem); letter-spacing: -0.03em; }
.demo-ventanas { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: 0.6rem; }
.demo-abrir {
  width: 100%;
  justify-content: flex-start;
  text-align: left;
  border-color: var(--linea);
  background: var(--superficie);
  color: var(--texto);
}
.demo-abrir:hover { border-color: var(--texto); }

/* Rótulo de las capturas: va dentro del marco claro, con contraste fijo en ambos temas. */
.demo-pantalla figcaption, .demo-ventana-cuerpo figcaption {
  padding: 0.45rem 0.9rem;
  background: #f2f6f4;
  color: #475467;
  font-size: 0.85rem;
  font-weight: 600;
}
.demo-celular { width: min(20rem, 80vw); }

.demo-fin { margin-top: 2rem; max-width: 46rem; }
.demo-fin h2 { font-size: clamp(1.6rem, 1.25rem + 1.4vw, 2.3rem); letter-spacing: -0.03em; }
.demo-fin p { margin-top: 1rem; color: var(--texto-suave); font-size: 1.1rem; }
.demo-acciones { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.demo-boton-secundario { border-color: var(--linea); color: var(--texto); background: var(--superficie); }
.demo-boton-secundario:hover { border-color: var(--texto); }
.demo-aviso:empty { display: none; }
.demo-aviso {
  position: fixed;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  z-index: 60;
  max-width: calc(100vw - 2rem);
  padding: 0.75rem 1.2rem;
  border-radius: var(--radio-medio);
  background: #7a5a12;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 10px 30px rgba(16, 24, 40, 0.3);
}

/* Ventana con el reporte de prueba */
.demo-ventana {
  width: min(64rem, calc(100vw - 2rem));
  max-height: calc(100dvh - 2rem);
  padding: 0;
  border: 1px solid var(--linea);
  border-radius: var(--radio-grande);
  background: var(--superficie);
  color: var(--texto);
  overflow: hidden;
}
.demo-ventana[open] { display: flex; flex-direction: column; }
.demo-ventana::backdrop { background: rgba(13, 23, 20, 0.6); }
.demo-ventana-cabeza { display: flex; align-items: center; gap: 0.75rem; padding: 0.75rem 0.75rem 0.75rem 1.25rem; border-bottom: 1px solid var(--linea); }
.demo-ventana-cabeza h2 { margin: 0 auto 0 0; font: 600 1.1rem/1.3 var(--fuente-titulos); }
.demo-rotulo { padding: 0.2rem 0.65rem; border-radius: var(--radio-chip); background: #7a5a12; color: #fff; font-size: 0.8rem; font-weight: 600; white-space: nowrap; }
.demo-ventana-cuerpo { margin: 0; overflow: auto; min-height: 0; background: #fff; }
.demo-ventana-cuerpo img { display: block; width: 100%; height: auto; }
.demo-ventana-cuerpo img.demo-angosta { max-width: 24.375rem; margin-inline: auto; }
@media (max-width: 40rem) {
  .demo-ventana { width: 100vw; max-width: none; height: 100dvh; max-height: none; margin: 0; border: 0; border-radius: 0; }
  .demo-ventana-cuerpo img.demo-ancha { width: 45rem; max-width: none; }
  .demo-ventana-cuerpo figcaption { position: sticky; left: 0; }
}
/* Solo en el celular, donde la captura ancha se desliza. */
.demo-deslizar { margin: 0; padding: 0.5rem 1.25rem; font-size: 0.9rem; color: var(--texto-suave); border-bottom: 1px solid var(--linea); }
@media (min-width: 40.01rem) { .demo-deslizar { display: none; } }
.demo-deslizar[hidden] { display: none; }
#demo-fin-titulo:focus { outline: none; } /* recibe el foco por programa al terminar; no es un control */
