/* Contrato espacial y de avance de las cards y diapositivas.
   Los números viven aquí. El skill cards-espacial prohíbe repetirlos en línea. */

:root {
  --card-ritmo: clamp(10px, 1.3vh, 18px);
  --card-texto: 720px;
  --card-medio: min(920px, 100%);
  --card-radio: 12px;
  --card-titulo: clamp(22px, 1.8vw + 12px, 36px);
  --card-titulo-portada: clamp(26px, 2.2vw + 14px, 44px);
  --card-cuerpo: clamp(15px, 0.25vw + 13.5px, 17.5px);
  --card-gancho: clamp(15px, 0.25vw + 13.5px, 19px);
  --card-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* El escenario es el hueco real entre cabecera y pie, medido por anclarCromo(). */
.deck-viewport { --deck-cab: 108px; --deck-pie: 84px; }
.deck-main {
  inset: auto;
  top: var(--deck-cab);
  right: 0;
  bottom: var(--deck-pie);
  left: 0;
}
.deck-card {
  gap: var(--card-ritmo);
  padding: clamp(12px, 1.8vh, 22px) max(20px, 4vw) clamp(14px, 2vh, 24px);
}
.deck-card > * {
  width: 100%;
  max-width: var(--card-texto);
  margin-left: auto;
  margin-right: auto;
}
.deck-card > .slot-image-container,
.deck-card > .slot-stage,
.deck-card > .slot-stage-simulator,
.deck-card > .options-grid,
.deck-card > .confidence-selector {
  max-width: var(--card-medio);
}
.deck-card .deck-kicker { margin: 0; }
.deck-card .slot-titulo,
.deck-card .slot-gancho,
.deck-card .slot-idea,
.deck-card .slot-ejemplo,
.deck-card .slot-keybox,
.deck-card .exercise-stem,
.deck-card .slot-image-container,
.deck-card .options-grid,
.deck-card .feedback-panel {
  margin: 0;
}
.deck-card .slot-titulo {
  font-size: var(--card-titulo);
  line-height: 1.15;
  max-width: 1180px;
  overflow-wrap: anywhere;
  text-wrap: balance;
}
.deck-card h1.slot-titulo { font-size: var(--card-titulo-portada); }
.deck-card .slot-gancho { font-size: var(--card-gancho); line-height: 1.45; }
.deck-card .slot-idea,
.deck-card .exercise-stem,
.deck-card .slot-cuerpo {
  font-size: var(--card-cuerpo);
  line-height: 1.55;
  font-weight: 500;
}
.deck-card .slot-ejemplo,
.deck-card .slot-keybox { font-size: clamp(15px, 0.25vw + 13px, 18px); }
.deck-card .slot-ejemplo {
  padding: 16px 18px;
  border-left: 3px solid var(--deck-accent, var(--primary));
  border-radius: 8px;
  background: color-mix(in srgb, var(--on-surface) 4%, transparent);
}
.deck-card[data-card-type="portada"] > .slot-keybox { margin-top: auto; }

.deck-card .slot-image-container {
  height: auto;
  aspect-ratio: 16 / 9;
  max-height: min(34vh, 380px);
  flex-shrink: 0;
}
.deck-card .slot-image-container img,
.deck-card .slot-image-container svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.sin-decorativas .deck-card .slot-image-container {
  aspect-ratio: 16 / 9;
  height: auto;
  max-height: none;
}
.deck-card .slot-stage { height: clamp(220px, 36vh, 420px); }

.slot-stage-simulator {
  margin: 0;
  border-radius: var(--card-radio);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  background: #0B0F19;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}
.sim-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 12px;
  background: #131A26;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono, monospace);
  font-size: 11px;
  color: #8E9A94;
}
.sim-toolbar-marca,
.sim-toolbar-acciones { display: flex; align-items: center; gap: 6px; }
.sim-toolbar-marca span:last-child {
  font-weight: 600;
  color: #E5E7EB;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.sim-vivo { color: #6EE7B7; }
.sim-toolbar button {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #D1D5DB;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10.5px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
}
.slot-stage-simulator iframe {
  width: 100%;
  height: clamp(400px, 52vh, 580px);
  border: none;
  display: block;
  background: #080C14;
}
.slot-stage-simulator.sim-alto iframe { height: clamp(440px, 64vh, 720px); }
@media (max-width: 700px) {
  .slot-stage-simulator.sim-alto iframe { height: clamp(520px, 82vh, 780px); }
}

/* Regla universal de composición: simulador y explicación viven en columnas
   hermanas. Prohibido el scroll vertical dentro de la card: si hay mucho
   contenido se divide la card en cards consecutivas. */
.concept-card-layout {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.85fr);
  gap: clamp(14px, 1.8vw, 24px);
  align-items: stretch;
  flex: 1 1 0;
  min-height: 0;
  height: 100%;
}
.concept-card-layout > * { min-width: 0; min-height: 0; }
.concept-card-layout .slot-stage,
.concept-card-layout .slot-stage-simulator { align-self: stretch; }
.concept-card-layout .slot-stage canvas { width: 100%; height: 100%; display: block; }
.concept-card-visual,
.concept-copy {
  min-width: 0;
  min-height: 0;
}
.concept-card-visual {
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.concept-card-visual > .slot-stage,
.concept-card-visual > .slot-stage-simulator {
  width: 100%;
  max-width: none;
  height: 100%;
  min-height: 0;
}
.concept-card-visual > .slot-stage-simulator iframe {
  height: auto;
  flex: 1 1 0;
  min-height: 0;
}
.concept-copy {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
  padding: clamp(12px, 1.6vh, 20px) clamp(14px, 1.8vw, 22px);
  border: 1px solid color-mix(in srgb, var(--primary, #518A68) 30%, transparent);
  border-radius: var(--card-radio, 12px);
  background: color-mix(in srgb, var(--surface, #101815) 88%, var(--primary, #518A68));
  overflow: hidden;
  align-self: stretch;
}
.concept-copy-pages {
  min-height: 0;
  flex: 1 1 auto;
  overflow: hidden;
  padding-right: 2px;
}
.concept-copy-page { display: none; animation: concept-copy-in 260ms var(--card-ease, ease) both; }
.concept-copy-page.is-visible { display: block; }
.concept-copy-block + .concept-copy-block { margin-top: clamp(8px, 1.1vh, 13px); }
.concept-copy-block h3 {
  margin: 0 0 3px;
  color: var(--primary, #87D3A2);
  font-size: 11px;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.concept-copy-block > div {
  font-size: var(--card-cuerpo, 16px);
  line-height: 1.4;
  font-weight: 500;
}
.concept-copy-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid color-mix(in srgb, var(--on-surface, #fff) 14%, transparent);
  color: var(--on-surface-muted, #9aa5a0);
  font: 600 11.5px var(--font-mono, monospace);
  flex-shrink: 0;
}
.concept-copy-controls button {
  width: 30px;
  height: 26px;
  border: 1px solid color-mix(in srgb, var(--primary, #518A68) 40%, transparent);
  border-radius: 6px;
  background: color-mix(in srgb, var(--primary, #518A68) 12%, transparent);
  color: var(--on-surface, #fff);
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}
.concept-copy-controls button:hover { background: color-mix(in srgb, var(--primary, #518A68) 25%, transparent); }
@keyframes concept-copy-in { from { opacity: 0; transform: translateX(8px); } to { opacity: 1; transform: none; } }

@media (max-width: 820px) {
  .concept-card-layout {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(180px, 1.05fr) minmax(0, 0.95fr);
    flex: 1 1 0;
    height: 100%;
    min-height: 0;
    gap: 10px;
  }
  .concept-card-visual > .slot-stage,
  .concept-card-visual > .slot-stage-simulator { min-height: 0; height: 100%; }
  .concept-card-visual > .slot-stage-simulator iframe { height: 100%; flex: 1 1 0; min-height: 0; }
  .concept-copy { min-height: 0; height: 100%; }
}

/* Las cards que no tienen simulador también respetan el lienzo visible: la
   ilustración ocupa una columna y el texto la otra. El título y las acciones
   siguen a todo el ancho. Así no aparece una segunda pantalla escondida bajo
   la card. */
.deck-card:has(> .concept-copy) {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(270px, .85fr);
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  align-content: stretch;
  overflow: hidden;
}
.deck-card:has(> .concept-copy) > .deck-kicker,
.deck-card:has(> .concept-copy) > .slot-titulo,
.deck-card:has(> .concept-copy) > .slot-keybox {
  grid-column: 1 / -1;
}
.deck-card:has(> .concept-copy) > .slot-image-container {
  grid-column: 1;
  grid-row: 3;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  min-height: 0;
  align-self: center;
}
.deck-card:has(> .concept-copy) > .concept-copy {
  grid-column: 2;
  grid-row: 3;
  width: 100%;
  max-width: none;
  height: 100%;
  min-height: 0;
}
.deck-card:has(> .concept-copy):not(:has(> .slot-image-container)):not(:has(> .sabiduria)) > .concept-copy {
  grid-column: 1 / -1;
}
.deck-card:has(> .concept-copy) > .options-grid,
.deck-card:has(> .concept-copy) > .confidence-selector,
.deck-card:has(> .concept-copy) > .feedback-panel {
  grid-column: 1 / -1;
}
.deck-card[data-card-type="ejercicio"] {
  grid-template-rows: auto auto auto minmax(0, 1fr) auto auto;
}
.deck-card[data-card-type="ejercicio"] > .concept-copy {
  height: auto;
  padding: 10px 16px;
}
.deck-card[data-card-type="ejercicio"] .options-grid {
  gap: clamp(6px, 0.9vh, 10px);
  margin: 2px auto;
}
.deck-card[data-card-type="ejercicio"] .option-btn {
  padding: clamp(8px, 1vh, 12px) 14px;
  min-height: 42px;
}
@media (max-width: 820px) {
  :root {
    --card-ritmo: 8px;
    --card-titulo: clamp(18px, 1.5vw + 11px, 24px);
    --card-titulo-portada: clamp(20px, 1.8vw + 12px, 26px);
    --card-cuerpo: clamp(13.5px, 0.2vw + 12.5px, 15.5px);
    --card-gancho: clamp(13.5px, 0.2vw + 12.5px, 16px);
  }
  .deck-card {
    padding: 10px 14px 12px;
  }
  .deck-card:has(> .concept-copy) {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto minmax(90px, 19vh) minmax(0, 1fr) auto;
  }
  .deck-card[data-card-type="portada"]:has(> .concept-copy) {
    grid-template-rows: auto auto minmax(0, 1fr) minmax(80px, 17vh) auto;
  }
  .deck-card:has(> .concept-copy):not(:has(> .slot-image-container)):not(:has(> .sabiduria)) {
    grid-template-rows: auto auto minmax(0, 1fr) auto;
  }
  .deck-card[data-card-type="ejercicio"]:has(> .concept-copy) {
    grid-template-rows: auto auto auto minmax(0, 1fr) auto auto;
  }
  .deck-card:has(> .concept-copy) > .slot-image-container,
  .deck-card:has(> .concept-copy) > .concept-copy {
    grid-column: 1;
    grid-row: auto;
    height: 100%;
    min-height: 0;
  }
  .deck-card:has(> .concept-copy) > .slot-image-container { max-height: 19vh; }
  .deck-card[data-card-type="portada"]:has(> .concept-copy) > .slot-image-container { max-height: 14vh; }
  .deck-card[data-card-type="ejercicio"] > .slot-image-container { max-height: 14vh; }
  .deck-card[data-card-type="ejercicio"] > .concept-copy {
    height: auto;
    padding: 8px 12px;
  }
  .deck-card[data-card-type="ejercicio"] .options-grid {
    gap: 6px;
    margin: 2px auto;
  }
  .deck-card[data-card-type="ejercicio"] .option-btn {
    padding: 7px 11px;
    min-height: 36px;
    gap: 10px;
  }
  .deck-card[data-card-type="ejercicio"] .option-text {
    font-size: 13.5px;
    line-height: 1.32;
  }
  .concept-copy {
    padding: 10px 12px;
    gap: 6px;
  }
  .concept-copy-block + .concept-copy-block { margin-top: 7px; }
}
.slot-aviso {
  padding: 16px;
  border-radius: var(--card-radio);
  border: 1px dashed #B26A00;
  background: rgba(245, 127, 23, 0.08);
  color: #7A4A00;
  font-size: 14px;
  line-height: 1.5;
}
.slot-aviso button {
  margin-top: 10px;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid #B26A00;
  background: #fff;
  color: #7A4A00;
  font-weight: 600;
  cursor: pointer;
}

/* Video y escarmiento siguen a sangre cuando hay reproductor a sangre. En modo prompt editable siguen la columna canónica. */
.deck-card > .deck-video-prompt-stage {
  max-width: var(--card-medio);
}
.deck-card[data-card-type="video"]:not(.video-prompt-mode),
.deck-card[data-card-type="escarmiento"] {
  padding: 0;
  gap: 0;
  container-type: size;
}
.deck-card[data-card-type="video"]:not(.video-prompt-mode) > *,
.deck-card[data-card-type="escarmiento"] > * {
  width: auto;
  max-width: none;
  margin: 0;
}
.deck-video-texto { top: calc(var(--deck-cab, 88px) + 8px); }
.deck-hint { bottom: calc(var(--deck-pie, 84px) + 8px); }
.deck-video-controles { bottom: calc(var(--deck-pie, 84px) + 12px); }
.deck-video-progreso { bottom: var(--deck-pie, 80px); }
.deck-escarmiento-texto { padding: 0 max(20px, 5vw) 32px; }
@media (orientation: portrait) {
  .deck-video {
    width: min(100cqw, calc(100cqh * 608 / 1080));
    height: min(100cqh, calc(100cqw * 1080 / 608));
  }
}

/* Avance: cada pieza entra en orden y la barra empuja hacia adelante. */
.deck-card.active > * {
  animation: card-entra 520ms var(--card-ease) both;
}
.deck-card.active > *:nth-child(2) { animation-delay: 45ms; }
.deck-card.active > *:nth-child(3) { animation-delay: 90ms; }
.deck-card.active > *:nth-child(4) { animation-delay: 135ms; }
.deck-card.active > *:nth-child(5) { animation-delay: 180ms; }
.deck-card.active > *:nth-child(6) { animation-delay: 225ms; }
.deck-card.active > *:nth-child(7) { animation-delay: 270ms; }
.deck-card.active > *:nth-child(8) { animation-delay: 315ms; }
.deck-card.entra-atras.active > * { animation-name: card-entra-atras; }
.deck-card.active > .slot-stage,
.deck-card.active > .slot-stage-simulator,
.deck-card.active > .deck-video-prompt-stage,
.deck-card.active > .slot-image-container { animation-name: card-entra-opaco; }
.deck-card[data-card-type="video"]:not(.video-prompt-mode).active > *,
.deck-card[data-card-type="escarmiento"].active > * { animation: none; }
.deck-card.active .option-btn { animation: card-entra 420ms var(--card-ease) both; }
.deck-card.active .option-btn:nth-child(2) { animation-delay: 70ms; }
.deck-card.active .option-btn:nth-child(3) { animation-delay: 120ms; }
.deck-card.active .option-btn:nth-child(4) { animation-delay: 170ms; }
.deck-card.active .option-btn:nth-child(5) { animation-delay: 220ms; }
.deck-card.active .slot-image-container img { animation: card-aliento 14s ease-in-out infinite alternate; }
.confidence-selector { animation: card-entra 360ms var(--card-ease); }
.deck-progress-fill {
  position: relative;
  transition: width 520ms var(--card-ease);
}
.deck-progress-fill::after {
  content: "";
  position: absolute;
  right: 0;
  top: -3px;
  bottom: -3px;
  width: 14px;
  border-radius: 99px;
  background: #fff;
  opacity: 0;
}
.deck-progress-fill.avanza::after { animation: card-cometa 560ms ease-out; }
.deck-step-counter.avanza,
.deck-footer.avanza .btn-nav,
.deck-footer.avanza .btn-run { animation: card-cuenta 380ms var(--card-ease); }

@keyframes card-entra {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
@keyframes card-entra-atras {
  from { opacity: 0; transform: translateY(-16px); }
  to { opacity: 1; transform: none; }
}
@keyframes card-entra-opaco {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes card-aliento {
  from { transform: scale(1); }
  to { transform: scale(1.045); }
}
@keyframes card-cometa {
  0% { opacity: 0.95; }
  100% { opacity: 0; transform: scaleX(2.4); }
}
@keyframes card-cuenta {
  0% { transform: translateY(7px); opacity: 0.35; }
  100% { transform: none; opacity: 1; }
}

/* Lección del Árbol: la misma columna, más ancha que el diálogo de 660px. */
.am-leccion-caja { width: min(var(--card-medio), 100%); }
.am-leccion-carta {
  display: flex;
  flex-direction: column;
  gap: var(--card-ritmo);
  padding: 28px 32px 32px;
}
.am-leccion-pos-indicador { margin: 0; }
.am-leccion-carta .am-titulo,
.am-leccion-carta .am-titulo-serif {
  margin: 0;
  font-size: var(--card-titulo);
  line-height: 1.15;
}
.am-leccion-carta .am-texto {
  margin: 0;
  font-size: var(--card-cuerpo);
  line-height: 1.55;
}
.am-leccion-ilustracion {
  margin: 0;
  border-radius: var(--card-radio);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  height: auto;
  max-height: min(32vh, 320px);
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.am-leccion-ilustracion img { width: 100%; height: 100%; object-fit: cover; display: block; }
.am-flip-cara.detras {
  padding: 28px 32px 32px;
  gap: var(--card-ritmo);
}
.am-reverso-cab {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 8px;
}
.am-reverso-titulo {
  font-family: var(--am-serif, var(--font-serif, Georgia, serif));
  font-size: var(--card-titulo);
  color: var(--am-tinta-1, #eef0e6);
  margin: 0;
  line-height: 1.15;
}
.am-reverso-texto {
  font-size: var(--card-cuerpo);
  line-height: 1.55;
  color: var(--am-tinta-2, rgba(238, 240, 230, 0.78));
  margin: 0;
}
.am-reverso-lugar {
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-top: auto;
  font-family: var(--am-mono, monospace);
  font-size: 12px;
  color: var(--acento);
}
.am-leccion-carta > * { animation: card-entra 480ms var(--card-ease) both; }
.am-leccion-carta > *:nth-child(2) { animation-delay: 50ms; }
.am-leccion-carta > *:nth-child(3) { animation-delay: 100ms; }
.am-leccion-carta > *:nth-child(4) { animation-delay: 150ms; }
.am-leccion-carta > *:nth-child(5) { animation-delay: 200ms; }
.am-leccion-carta > *:nth-child(6) { animation-delay: 250ms; }
.am-paso-chip.activo { animation: card-cuenta 360ms var(--card-ease); }
.am-leccion-cuenta strong { display: inline-block; animation: card-cuenta 360ms var(--card-ease); }
.am-leccion-carta .am-leccion-ilustracion img { animation: card-aliento 14s ease-in-out infinite alternate; }

/* Diapositivas de defensa, editor y modo presentación. */
.task-slides {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.task-slide-barra,
.task-notas {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: #fff;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--line, #ddd);
}
.task-slide-thumbs { display: flex; gap: 6px; overflow-x: auto; }
.btn-slide-thumb {
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 700;
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  cursor: pointer;
  white-space: nowrap;
}
.btn-slide-thumb.active {
  border-color: var(--primary, #1F3A2C);
  background: var(--primary, #1F3A2C);
  color: #fff;
  animation: card-cuenta 280ms var(--card-ease);
}
.task-slide {
  aspect-ratio: 16 / 9;
  width: min(100%, calc(62vh * 16 / 9));
  margin-inline: auto;
  background: #1A2621;
  color: #F0F4F1;
  border-radius: var(--card-radio);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.3);
  padding: clamp(20px, 4.5%, 48px) clamp(22px, 6%, 64px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  border: 2px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  box-sizing: border-box;
}
.task-slide-kicker {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: #81C784;
  text-transform: uppercase;
}
.task-slide-kicker span:last-child {
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: #A5D6A7;
  font-family: var(--font-mono, monospace);
}
.task-slide-titulo,
.task-slide h1 {
  width: 100%;
  margin: 0;
  background: transparent;
  border: none;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.3);
  font-size: clamp(22px, 2.4vw, 40px);
  font-weight: 800;
  line-height: 1.15;
  color: #fff;
  font-family: var(--font-serif, Georgia, serif);
  outline: none;
}
.task-slide-sub {
  width: 100%;
  margin: 8px 0 0;
  background: transparent;
  border: none;
  font-size: clamp(14px, 1vw, 18px);
  font-weight: 500;
  color: #A5D6A7;
  outline: none;
}
.task-slide-puntos { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.task-slide-punto { display: flex; align-items: center; gap: 10px; }
.task-slide-punto > span { color: #66BB6A; }
.slide-punto-input {
  flex: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 14px;
  color: #E8F5E9;
  outline: none;
}
.task-slide-cita {
  margin-top: 14px;
  padding: 12px 16px;
  background: rgba(0, 0, 0, 0.3);
  border-left: 3px solid #81C784;
  border-radius: 6px;
  font-size: 14px;
  font-style: italic;
  color: #C8E6C9;
}
.task-slide-pie {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 12px;
  font-size: 12px;
  color: #81C784;
}
.task-slide ul {
  margin: 12px 0 0;
  padding-left: 1.2em;
  font-size: clamp(16px, 1.4vw, 22px);
  line-height: 1.45;
  color: #E8F5E9;
}
.task-slide-entra { animation: task-avanza 460ms var(--card-ease); }
.task-slide-entra .task-slide-punto,
.task-slide-entra li { animation: card-entra 420ms var(--card-ease) both; }
.task-slide-entra .task-slide-punto:nth-child(2),
.task-slide-entra li:nth-child(2) { animation-delay: 60ms; }
.task-slide-entra .task-slide-punto:nth-child(3),
.task-slide-entra li:nth-child(3) { animation-delay: 110ms; }
.task-slide-entra .task-slide-punto:nth-child(4),
.task-slide-entra li:nth-child(4) { animation-delay: 160ms; }
.task-slide-entra .task-slide-punto:nth-child(5),
.task-slide-entra li:nth-child(5) { animation-delay: 210ms; }
.task-slide-entra .task-slide-punto:nth-child(6),
.task-slide-entra li:nth-child(6) { animation-delay: 260ms; }
@keyframes task-avanza {
  from { opacity: 0; transform: translateX(36px); }
  to { opacity: 1; transform: none; }
}
@keyframes task-retrocede {
  from { opacity: 0; transform: translateX(-36px); }
  to { opacity: 1; transform: none; }
}
.task-pres {
  position: fixed;
  inset: 0;
  background: #0A0F0D;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 16px;
  padding: clamp(16px, 3vw, 40px);
  color: #fff;
}
.task-slide--presenta {
  width: min(90vw, calc(85vh * 16 / 9));
  max-width: 1280px;
  background: #141E19;
}
.task-pres-nav { display: flex; gap: 12px; }
.task-pres-nav button {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
}
.task-pres-nav .task-pres-sigue { background: #2E7D32; border: none; font-weight: 700; }
.task-pres-nav .task-pres-salir { color: #FF8A80; }

@media (prefers-reduced-motion: reduce) {
  .deck-card.active > *,
  .deck-card.active .option-btn,
  .deck-card.active .slot-image-container img,
  .am-leccion-carta > *,
  .am-leccion-carta .am-leccion-ilustracion img,
  .am-paso-chip.activo,
  .am-leccion-cuenta strong,
  .task-slide-entra,
  .task-slide-entra .task-slide-punto,
  .task-slide-entra li,
  .btn-slide-thumb.active,
  .deck-step-counter.avanza,
  .deck-footer.avanza .btn-nav,
  .deck-footer.avanza .btn-run,
  .deck-progress-fill,
  .deck-progress-fill::after,
  .confidence-selector {
    animation: none !important;
    transition: none !important;
  }
}
