/* Panel de evolución. Usa las variables de style.css; móvil primero, sin scroll horizontal a 390 px. */
#p-evolucion { overflow-x: hidden; }
.ev-bloque { min-width: 0; }
.ev-vacio p { margin: 0 0 8px; }

/* Línea temporal semanal */
.ev-linea { list-style: none; margin: 0; padding: 0; position: relative; }
.ev-linea::before { content: ""; position: absolute; left: 7px; top: 14px; bottom: 14px; width: 1px; background: var(--linea); }
.ev-hito { display: grid; grid-template-columns: 15px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 0; }
.ev-nodo { width: 15px; height: 15px; border-radius: 50%; background: var(--fondo); border: 2px solid var(--acento); position: relative; }
.ev-hito:first-child .ev-nodo { background: var(--acento); }
.ev-hito-texto { min-width: 0; }
.ev-hito-texto strong { display: block; font-weight: 500; }
.ev-hito-texto small { color: var(--suave); font-size: 13px; overflow-wrap: anywhere; }
.ev-hito-valor { text-align: right; font: 400 22px var(--serif); white-space: nowrap; }
.ev-hito-valor small { display: block; font: 300 12px var(--sans); color: var(--suave); }
#p-evolucion .mejor { color: var(--ok); }
#p-evolucion .peor { color: var(--mal); }

/* Gráficas */
.ev-graficas { display: grid; gap: 12px; }
.ev-grafica { margin: 0; padding: 16px; min-width: 0; }
.ev-grafica figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; margin-bottom: 6px; }
.ev-grafica figcaption strong { font-weight: 500; }
.ev-resumen { font-size: 14px; color: var(--suave); }
.ev-svg { display: block; width: 100%; height: auto; overflow: visible; }
.ev-rejilla { stroke: var(--linea); stroke-width: 1; }
.ev-eje { stroke: var(--suave); stroke-width: 1; }
.ev-eje-texto { fill: var(--suave); font: 400 11px var(--sans); }
.ev-unidad { font-style: italic; }
.ev-trazo { fill: none; stroke: var(--acento); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.ev-punto { fill: var(--superficie); stroke: var(--acento); stroke-width: 2.5; }
@media (min-width: 600px) { .ev-graficas { grid-template-columns: 1fr 1fr; } }

/* Antes / después */
.ev-controles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ev-controles label { display: grid; gap: 4px; font-size: 13px; color: var(--suave); min-width: 0; }
.ev-controles select { width: 100%; min-width: 0; padding: 10px; border-radius: 12px; border: 1px solid var(--linea); background: var(--superficie); color: var(--texto); font: inherit; font-size: 14px; }
.ev-check { display: flex; align-items: center; gap: 8px; font-size: 14px; margin: 4px 0 12px; }
.ev-lado { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ev-lado figure { margin: 0; min-width: 0; }
.ev-lado figcaption { display: flex; flex-direction: column; margin-top: 6px; font-size: 13px; color: var(--suave); }
.ev-lado figcaption strong { color: var(--texto); font-weight: 500; }
.ev-cambio { font: 400 20px var(--serif); margin: 14px 0 0; }
.ev-sub { font: 400 18px var(--serif); margin: 22px 0 8px; }

.ev-superpuesto { position: relative; border-radius: var(--radio); overflow: hidden; background: #000; touch-action: pan-y; }
.ev-capa canvas { display: block; width: 100%; height: auto; }
.ev-capa-arriba { position: absolute; inset: 0; }
.ev-raya { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: #fff; box-shadow: 0 0 6px rgba(0, 0, 0, .5); pointer-events: none; }
.ev-etq { position: absolute; top: 10px; padding: 3px 10px; border-radius: 999px; background: rgba(30, 30, 28, .65); color: #fff; font-size: 12px; }
.ev-etq-izq { left: 10px; }
.ev-etq-der { right: 10px; }
.ev-rango { display: block; width: 100%; margin: 12px 0 0; accent-color: var(--acento); }

/* Timelapse */
.ev-video video { display: block; width: 100%; max-height: 70vh; margin-top: 12px; border-radius: var(--radio); background: #000; }

/* Simulación */
.ev-aviso { margin: 0 0 8px; }
.ev-sims { display: grid; gap: 10px; margin-top: 10px; }
.ev-sim { padding: 16px; }
.ev-sim-cab { display: grid; gap: 2px; }
.ev-sim-cab strong { font-weight: 500; }
.ev-sim-cab span { font-size: 13px; color: var(--suave); }
.ev-sim-lista { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; }
.ev-sim-lista li { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; border-top: 1px solid var(--linea); padding-top: 6px; }
.ev-sim-lista strong { font-weight: 500; text-align: right; }
.ev-rangos { margin-top: 14px; }
.ev-rangos summary { cursor: pointer; color: var(--acento); font-size: 14px; padding: 6px 0; }
.ev-rejilla-form { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.ev-rejilla-form label { display: grid; gap: 4px; font-size: 12px; color: var(--suave); min-width: 0; }
.ev-rejilla-form input { width: 100%; min-width: 0; padding: 9px 10px; border-radius: 10px; border: 1px solid var(--linea); background: var(--superficie); color: var(--texto); font: inherit; font-size: 15px; }
