/* Simulador "Contactor por dentro" (publicación 118). Prefijo cts- */
.cts { background: var(--card, #fff); color: #0b1f33; border: 1px solid var(--line, #cfdae6); border-radius: 8px; padding: 18px; margin: 26px 0; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.cts * { box-sizing: border-box; }
.cts-head { display: flex; flex-direction: column; gap: 2px; }
.cts-head strong { font-size: 1.1rem; color: #0b1f33; }
.cts-head span { color: #4a5d70; font-size: .92rem; line-height: 1.5; }
.cts-say { border: 1px solid #cfdae6; border-left: 5px solid #2a6fb0; background: #eef5fc; border-radius: 6px; padding: 10px 14px; color: #0b1f33; }
.cts-say-t { font-size: .78rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #2a4560; margin-bottom: 2px; }
.cts-say-main { margin: 0; font-size: 1rem; font-weight: 600; line-height: 1.5; color: #0b1f33; min-height: 3em; }
.cts-say-why { margin: 6px 0 0; font-size: .88rem; line-height: 1.5; color: #35495e; }
.cts-top { display: flex; flex-wrap: wrap; gap: 8px; }
.cts button { font: inherit; font-weight: 600; font-size: .9rem; padding: 9px 14px; border-radius: 4px; border: 1px solid #0b1f33; background: #0b1f33; color: #fff; cursor: pointer; min-height: 42px; }
.cts button.ghost { background: #fff; color: #0b1f33; }
.cts button.small { font-size: .82rem; padding: 7px 10px; min-height: 40px; }
.cts button.big { width: 100%; font-size: 1rem; min-height: 50px; background: #1a7f4b; border-color: #1a7f4b; }
.cts button.big.on, .cts button.on { background: #b42318; border-color: #b42318; color: #fff; }
.cts button:disabled { opacity: .45; cursor: not-allowed; }
.cts button:focus-visible, .cts input:focus-visible, .cts select:focus-visible, .cts summary:focus-visible { outline: 3px solid #e0731a; outline-offset: 2px; }
.cts-demo { border: 2px solid #e0731a; border-radius: 6px; background: #fff7ef; padding: 10px 14px; color: #0b1f33; }
.cts-demo-n { font-size: .78rem; font-weight: 700; color: #9a4a08; text-transform: uppercase; letter-spacing: .04em; }
.cts-demo-t { margin: 4px 0 8px; font-size: .95rem; line-height: 1.5; }
.cts-demo-b { display: flex; flex-wrap: wrap; gap: 8px; }
.cts-demo[hidden] { display: none; }
.cts-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 16px; align-items: start; }
@media (max-width: 880px) { .cts-grid { grid-template-columns: minmax(0, 1fr); } }
.cts-main, .cts-side { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.cts-card { border: 1px solid #e1e8ef; border-radius: 6px; background: #fff; padding: 10px; min-width: 0; color: #0b1f33; }
.cts-ct { font-size: .9rem; font-weight: 700; margin-bottom: 6px; color: #0b1f33; }
.cts-svgbox { background: #fff; border-radius: 4px; max-width: 560px; margin: 0 auto; }
.cts-svgbox.lock { max-width: 520px; }
.cts-svg { display: block; width: 100%; height: auto; max-width: 100%; }
.cts-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.cts-chip { font-size: .8rem; font-weight: 700; padding: 4px 9px; border-radius: 12px; border: 1px solid #cfdae6; background: #eef2f6; color: #0b1f33; }
.cts-chip.ok { background: #effaf2; border-color: #1a7f4b; color: #14532d; }
.cts-chip.warn { background: #fff6e0; border-color: #b7791f; color: #6b4b00; }
.cts-chip.bad { background: #fdecec; border-color: #b42318; color: #721c24; }
.cts-chip.idle { background: #eef2f6; color: #35495e; }
.cts-legend { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 3px 10px; font-size: .82rem; color: #35495e; }
.cts-legend li { display: flex; align-items: center; gap: 6px; }
.cts-legend b { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 50%; background: #0b1f33; color: #fff; font-size: .74rem; flex: 0 0 auto; }
.cts-note { font-size: .84rem; line-height: 1.5; color: #35495e; margin: 6px 0; }
.cts-btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 2px; }
.cts-fs { border: 1px solid #cfdae6; border-radius: 6px; margin: 0; padding: 8px 12px 10px; min-width: 0; background: transparent; }
.cts-fs legend { font-size: .86rem; font-weight: 700; padding: 0 6px; color: #0b1f33; }
.cts-row { display: flex; flex-direction: column; gap: 3px; padding: 5px 0; }
.cts-row label { font-size: .86rem; font-weight: 600; color: #0b1f33; }
.cts-in { display: flex; align-items: center; gap: 10px; }
.cts-in input[type=range] { flex: 1 1 auto; min-width: 0; height: 30px; accent-color: #e0731a; }
.cts-in output { flex: 0 0 auto; min-width: 7.6em; text-align: right; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .82rem; font-weight: 600; color: #0b1f33; }
.cts-vr { background: linear-gradient(to right, #e9b4af 0, #e9b4af 65.38%, #b9dfc7 65.38%, #b9dfc7 84.62%, #f1d79a 84.62%, #f1d79a 100%); border-radius: 6px; height: 18px !important; margin: 6px 0; }
.cts-scale { display: flex; justify-content: space-between; font-size: .72rem; color: #4a5d70; padding: 0 2px; gap: 4px; }
.cts-scale .r { color: #8f2a20; } .cts-scale .g { color: #14532d; font-weight: 700; } .cts-scale .o { color: #6b4b00; }
.cts select { font: inherit; font-size: .9rem; padding: 7px 8px; border: 1px solid #cfdae6; border-radius: 4px; background: #fff; color: #0b1f33; width: 100%; max-width: 100%; min-height: 42px; }
.cts-chk { display: flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 600; padding: 6px 0 2px; color: #0b1f33; }
.cts-chk input { width: 20px; height: 20px; accent-color: #e0731a; flex: 0 0 auto; }
.cts-read { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; border: 1px solid #cfdae6; border-left: 4px solid #e0731a; border-radius: 4px; padding: 10px 12px; background: #fff7ef; color: #0b1f33; }
.cts-read div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.cts-read span { font-size: .74rem; color: #4a5d70; }
.cts-read b { font-size: .9rem; color: #0b1f33; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.cts-bars { margin-top: 8px; display: flex; flex-direction: column; gap: 4px; }
.cts-bar { display: grid; grid-template-columns: minmax(0, 1fr) 70px; grid-template-areas: "n b" "t t" "e e"; gap: 2px 8px; align-items: center; }
.cts-bn { grid-area: n; font-size: .82rem; font-weight: 600; } .cts-bar b { grid-area: b; text-align: right; font-size: .84rem; font-variant-numeric: tabular-nums; }
.cts-bar em { grid-area: e; font-style: normal; font-size: .74rem; color: #4a5d70; }
.cts-bt { grid-area: t; display: block; height: 12px; background: #e3e9f0; border-radius: 6px; overflow: hidden; border: 1px solid #cfdae6; }
.cts-bt i { display: block; height: 100%; background: #1a7f4b; }
.cts-bt i.warn { background: #b7791f; } .cts-bt i.bad { background: #b42318; } .cts-bt i.spring { background: #2a6fb0; }
.cts-warnline { font-size: .82rem; line-height: 1.45; padding: 6px 9px; border-left: 4px solid #b42318; background: #fdecec; color: #721c24; border-radius: 3px; margin-top: 4px; }
.cts-adv { border: 1px solid #cfdae6; border-radius: 6px; padding: 6px 12px; background: #fff; color: #0b1f33; }
.cts-adv summary { cursor: pointer; font-weight: 700; font-size: .92rem; min-height: 40px; display: flex; align-items: center; }
.cts-advin { padding: 4px 0 8px; }
.cts-hl { outline: 3px solid #e0731a; outline-offset: 3px; border-radius: 6px; animation: cts-pulse 1.2s ease-in-out infinite; }
@keyframes cts-pulse { 0%, 100% { outline-color: #e0731a; } 50% { outline-color: #f6c28f; } }
@media (prefers-reduced-motion: reduce) { .cts * { animation: none !important; transition: none !important; } }
