/* SCADA Comercial 2.0 -- Monitor de mercado para televisión (2026-11-10). Escala con el alto de la pantalla (vh) para
   verse igual en una TV de 1080p o 4K; misma línea gráfica que la 2.0, sin logotipos. */
:root {
    --fondo: #031627; --panel: #08223B; --panel-2: #0B2A47; --linea: #143A5E; --texto: #E8F1FA; --tenue: #8FA6BD;
    --acento: #2386D0; --celeste: #5FB0E8; --verde: #7BAA3F; --verde-claro: #9CCB5E; --ambar: #F5A524; --ambar-claro: #F7C873;
    --rojo: #FF8A80; --num: 'Barlow Condensed', 'Montserrat', sans-serif;
    --franja: linear-gradient(90deg, #00589A 0%, #2386D0 45%, #4C9AC9 70%, #7BAA3F 100%);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--fondo); color: var(--texto); font-family: 'Montserrat', sans-serif; overflow: hidden; }
body.mn-sin-cursor, body.mn-sin-cursor * { cursor: none !important; }
#monitor { height: 100vh; display: grid; grid-template-rows: 10vh 1fr 7vh; background: radial-gradient(120vh 80vh at 85% -10%, rgba(35, 134, 208, .18), transparent 60%), var(--fondo); }
.mn-num { font-family: var(--num); font-variant-numeric: tabular-nums; }
.mn-tenue { color: var(--tenue); }
.mn-eyebrow { font-size: 1.35vh; font-weight: 700; letter-spacing: .35vh; text-transform: uppercase; color: var(--verde-claro); }

.mn-cab { display: grid; grid-template-columns: 1fr auto; align-items: center; padding: 0 3vh; position: relative; }
.mn-cab::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: .35vh; background: var(--franja); opacity: .85; }
.mn-marca h1 { margin: .4vh 0 0; font-size: 3.6vh; font-weight: 800; letter-spacing: -.02em; }
.mn-puntos { display: flex; gap: 1vh; position: absolute; left: 50%; bottom: 1.2vh; transform: translateX(-50%); }
.mn-puntos span { width: 1.1vh; height: 1.1vh; border-radius: 50%; background: var(--linea); transition: background .3s, transform .3s; }
.mn-puntos span.activo { background: var(--celeste); transform: scale(1.35); }
.mn-hora { justify-self: end; display: grid; justify-items: end; line-height: 1.05; }
.mn-hora #mn_reloj { font-size: 5.4vh; font-weight: 700; }
.mn-hora #mn_fecha { font-size: 1.7vh; }
.mn-hora #mn_actualizado { font-size: 1.35vh; margin-top: .3vh; }

.mn-escena { padding: 2.2vh 3vh 1.4vh; min-height: 0; position: relative; }
.mn-cargando, .mn-aviso { display: grid; place-items: center; height: 100%; font-size: 2.6vh; color: var(--tenue); }
.mn-aviso { height: 100vh; text-align: center; }
.mn-vista { height: 100%; display: grid; gap: 2vh; animation: mn-entrar .7s ease both; min-height: 0; }
@keyframes mn-entrar { from { opacity: 0; transform: translateY(1.2vh); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .mn-vista { animation: none; } .mn-cinta-pista { animation: none !important; } }
.mn-col-2 { grid-template-columns: 1fr 1fr; }
.mn-col-38 { grid-template-columns: 3fr 5fr; }
.mn-col-53 { grid-template-columns: 5fr 3fr; }

.mn-panel { background: linear-gradient(180deg, var(--panel-2), var(--panel)); border: 1px solid var(--linea); border-radius: 1.6vh; padding: 2vh 2.4vh; display: flex; flex-direction: column; gap: 1.2vh; min-height: 0; min-width: 0; }
.mn-panel h2 { margin: 0; font-size: 2.3vh; font-weight: 700; }
.mn-panel h2 small { font-weight: 500; color: var(--tenue); font-size: 1.55vh; margin-left: .8vh; }
.mn-graf { flex: 1; min-height: 0; }
.mn-nota { font-size: 1.45vh; color: var(--tenue); margin: 0; }

.mn-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(16vh, 1fr)); gap: 1.4vh; }
.mn-kpi { background: rgba(3, 22, 39, .45); border: 1px solid var(--linea); border-radius: 1.2vh; padding: 1.3vh 1.6vh; display: grid; gap: .3vh; border-left: .55vh solid var(--k, var(--acento)); }
.mn-kpi span { font-size: 1.35vh; text-transform: uppercase; letter-spacing: .18vh; color: var(--tenue); font-weight: 600; }
.mn-kpi b { font-family: var(--num); font-size: 5vh; font-weight: 700; line-height: 1; }
.mn-kpi b small { font-size: 2vh; color: var(--tenue); font-weight: 600; margin-left: .5vh; }
.mn-kpi em { font-style: normal; font-size: 1.5vh; color: var(--tenue); }
.mn-grande b { font-size: 9vh; }

.mn-plantas { display: grid; grid-template-columns: repeat(auto-fit, minmax(22vh, 1fr)); gap: 1.4vh; }
.mn-planta { background: rgba(3, 22, 39, .45); border: 1px solid var(--linea); border-radius: 1.2vh; padding: 1.4vh 1.6vh; display: grid; gap: .5vh; }
.mn-planta h3 { margin: 0; font-size: 1.9vh; display: flex; justify-content: space-between; gap: 1vh; }
.mn-planta h3 i { font-style: normal; font-size: 1.35vh; color: var(--tenue); font-weight: 500; }
.mn-planta .mn-mw { font-family: var(--num); font-size: 5.2vh; font-weight: 700; line-height: 1; }
.mn-planta .mn-mw small { font-size: 2vh; color: var(--tenue); margin-left: .5vh; }
.mn-barra { height: .9vh; border-radius: .9vh; background: var(--linea); overflow: hidden; }
.mn-barra span { display: block; height: 100%; border-radius: .9vh; background: var(--c, var(--celeste)); }
.mn-planta p { margin: 0; font-size: 1.5vh; color: var(--tenue); display: flex; justify-content: space-between; gap: 1vh; }
.mn-planta p b { color: var(--texto); font-weight: 600; }

.mn-arriba { color: var(--celeste); } .mn-abajo { color: var(--ambar-claro); }
.mn-comb { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2vh; height: 100%; min-height: 0; }
.mn-comb .mn-panel { justify-content: space-between; }
.mn-comb .mn-valor { font-family: var(--num); font-size: 9vh; font-weight: 700; line-height: 1; }
.mn-comb .mn-valor small { font-size: 2.2vh; color: var(--tenue); margin-left: .6vh; font-weight: 600; }
.mn-comb .mn-cambio { font-size: 2.2vh; font-weight: 700; }
.mn-barras-h { display: grid; gap: 1.3vh; }
.mn-barras-h div { display: grid; grid-template-columns: 22vh 1fr 9vh; align-items: center; gap: 1.2vh; font-size: 1.8vh; }
.mn-barras-h i { display: block; height: 2.6vh; border-radius: .6vh; background: var(--c, var(--acento)); }
.mn-barras-h b { font-family: var(--num); font-size: 2.6vh; text-align: right; }
.mn-dias { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1vh; }
.mn-dia { background: rgba(3, 22, 39, .45); border: 1px solid var(--linea); border-radius: 1vh; padding: 1.1vh .8vh; text-align: center; display: grid; gap: .4vh; }
.mn-dia span { font-size: 1.4vh; color: var(--tenue); text-transform: capitalize; }
.mn-dia b { font-family: var(--num); font-size: 3.4vh; }
.mn-dia em { font-style: normal; font-size: 1.4vh; color: var(--tenue); }

.mn-pie { display: grid; grid-template-rows: .5vh 1fr; }
.mn-avance { background: var(--linea); }
.mn-avance span { display: block; height: 100%; width: 0; background: var(--franja); }
.mn-cinta { overflow: hidden; display: flex; align-items: center; background: rgba(8, 34, 59, .85); border-top: 1px solid var(--linea); }
.mn-cinta-pista { display: flex; gap: 6vh; white-space: nowrap; padding-left: 3vh; animation: mn-cinta 60s linear infinite; }
@keyframes mn-cinta { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.mn-cinta-item { font-size: 2.1vh; display: inline-flex; gap: 1vh; align-items: baseline; }
.mn-cinta-item span { color: var(--tenue); text-transform: uppercase; letter-spacing: .15vh; font-size: 1.5vh; font-weight: 700; }
.mn-cinta-item b { font-family: var(--num); font-size: 3vh; font-weight: 700; }
.mn-cinta-item em { font-style: normal; font-weight: 700; }
.mn-alerta { position: absolute; right: 3vh; top: .8vh; font-size: 1.4vh; color: var(--ambar-claro); }

.mn-lista { gap: 0; padding: 1vh 2.2vh; justify-content: space-around; }
.mn-fila { display: grid; grid-template-columns: 1.2fr 1.4fr .8fr .8fr; align-items: center; gap: 1.6vh; padding: 1.2vh 0; border-bottom: 1px solid var(--linea); }
.mn-fila:last-child { border-bottom: 0; }
.mn-fila h3 { margin: 0; font-size: 2.2vh; }
.mn-fila em { font-style: normal; font-size: 1.35vh; color: var(--tenue); }
.mn-fila-mw { font-family: var(--num); font-size: 4.6vh; font-weight: 700; line-height: 1; display: grid; gap: .6vh; }
.mn-fila-mw small { font-size: 1.8vh; color: var(--tenue); margin-left: .5vh; }
.mn-fila-mw .mn-tenue { font-family: 'Montserrat', sans-serif; font-size: 1.6vh; font-weight: 500; }
.mn-fila-dato { display: grid; text-align: right; }
.mn-fila-dato b { font-family: var(--num); font-size: 3.2vh; }
.mn-barras-h small { font-size: 1.3vh; }
.mn-barras-h .mn-nuestro span, .mn-barras-h .mn-nuestro b { color: var(--verde-claro); font-weight: 700; }
.mn-barras-h .mn-nuestro { background: rgba(123, 170, 63, .12); border-radius: .8vh; padding: .3vh .8vh; margin: 0 -.8vh; }
.mn-hidros { gap: .35vh; }
.mn-hidros div { grid-template-columns: 24vh 1fr 13vh; font-size: 1.6vh; }
.mn-hidros i { height: 1.5vh; }
.mn-hidros b { font-size: 2.2vh; }
.mn-hidros b small { font-family: 'Montserrat', sans-serif; font-size: 1.25vh; }
.mn-matriz-der { gap: 1vh; }
.mn-matriz-der > .mn-barras-h:not(.mn-hidros) { gap: .6vh; }
.mn-matriz-der > .mn-barras-h:not(.mn-hidros) div { font-size: 1.6vh; }
.mn-matriz-der > .mn-barras-h:not(.mn-hidros) i { height: 2.2vh; }
.mn-hidros .mn-nuestro { padding: .15vh .8vh; }
.mn-cab { grid-template-columns: 1fr auto auto; column-gap: 2.4vh; }
.mn-completa { display: inline-flex; align-items: center; gap: .9vh; padding: .9vh 1.5vh; white-space: nowrap;
    font: 600 1.45vh 'Montserrat', sans-serif; color: var(--texto); background: rgba(8, 34, 59, .92); border: 1px solid var(--acento); border-radius: 1vh;
    cursor: pointer; opacity: 0; pointer-events: none; transition: opacity .3s; }
.mn-completa.visible { opacity: 1; pointer-events: auto; }
.mn-completa:hover, .mn-completa:focus-visible { background: var(--acento); outline: none; }
.mn-completa svg { width: 2.2vh; height: 2.2vh; }
.mn-clima .mn-panel { gap: 1vh; }
.mn-clima-datos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1vh; }
.mn-clima-datos div { background: rgba(3, 22, 39, .45); border: 1px solid var(--linea); border-radius: 1vh; padding: .8vh 1vh; display: grid; gap: .2vh; }
.mn-clima-datos span { font-size: 1.2vh; text-transform: uppercase; letter-spacing: .12vh; color: var(--tenue); font-weight: 600; }
.mn-clima-datos b { font-family: var(--num); font-size: 3.2vh; font-weight: 700; line-height: 1; }
.mn-clima-datos b small { font-size: 1.4vh; color: var(--tenue); margin-left: .3vh; }
.mn-clima-datos em { font-style: normal; font-size: 1.2vh; color: var(--tenue); }
.mn-clima .mn-dias { gap: .5vh; }
.mn-clima .mn-dia { padding: .7vh .2vh; gap: .2vh; }
.mn-clima .mn-dia span { font-size: 1.15vh; }
.mn-clima .mn-dia b { font-size: 2.4vh; }
.mn-clima .mn-dia em { font-size: 1.1vh; }
.mn-atraso { display: block; color: var(--ambar-claro) !important; font-weight: 600; margin-top: .3vh; }
.mn-nota-comun { color: var(--ambar-claro); margin-top: -.6vh; }
