/* CCR Academy 2.5.0 - Settings panel, top bar plant button, and the Futuristic and FLS ECS classic screen styles. */

/* ---------- Top bar ---------- */
.navbtn.plantbtn { border-color: var(--line2); max-width: 260px; }
.navbtn.plantbtn .pn { overflow: hidden; text-overflow: ellipsis; color: var(--text); }
.navbtn.plantbtn:hover, .navbtn.setbtn:hover { border-color: var(--sp); }
@media (max-width: 1500px) { #langBtn span, #unitBtn span, #sndBtn span, #fsBtn span { display: none; } }
@media (max-width: 1150px) { .navbtn.plantbtn { max-width: 150px; } .navbtn.setbtn span { display: none; } }
@media (max-width: 900px) { .navbtn.plantbtn .pn { display: none; } }
.crbar .chip.plantchip { cursor: pointer; }
.crbar .chip.plantchip:hover { border-color: var(--sp); color: var(--sp); }
#crSet { display: inline-flex; align-items: center; gap: 5px; }
#crSet .ico { width: 13px; height: 13px; }
@media (max-width: 1400px) { #crSet span { display: none; } }

/* ---------- Settings panel (slides in from the right) ---------- */
.setbg { position: fixed; inset: 0; z-index: 60; background: rgba(3, 6, 10, 0); transition: background .18s; }
.setbg.in { background: rgba(3, 6, 10, .55); backdrop-filter: blur(2px); }
.setpanel { position: absolute; top: 0; right: 0; bottom: 0; width: min(560px, 100vw); display: grid; grid-template-rows: auto auto minmax(0, 1fr); background: #0d1217; border-left: 1px solid #263140; box-shadow: -30px 0 80px rgba(0, 0, 0, .5); transform: translateX(30px); opacity: 0; transition: transform .18s ease, opacity .18s ease; color: #dde3e8; font-family: var(--sans); }
.setbg.in .setpanel { transform: none; opacity: 1; }
.setpanel header { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px 10px; }
.setpanel .sett { display: flex; align-items: center; gap: 8px; font-size: 16px; }
.setpanel .sett .ico { width: 18px; height: 18px; color: #29e3ff; }
.setx { background: none; border: 1px solid #2c3846; color: #aab6c0; width: 30px; height: 30px; border-radius: 6px; font-size: 18px; cursor: pointer; }
.setx:hover { color: #fff; border-color: #4a5868; }
.settabs { display: flex; gap: 4px; padding: 0 14px 10px; border-bottom: 1px solid #1f2933; overflow-x: auto; }
.settabs button { background: none; border: 1px solid transparent; color: #8d9aa6; padding: 6px 10px; border-radius: 999px; font: 600 12px var(--sans); white-space: nowrap; cursor: pointer; }
.settabs button:hover { color: #dde3e8; }
.settabs button.on { color: #061018; background: #29e3ff; }
.setbody { overflow-y: auto; padding: 6px 18px 40px; scroll-behavior: auto; position: relative; }
.setbody section { padding: 16px 0 18px; border-bottom: 1px solid #1a232c; }
.setbody section:last-child { border-bottom: 0; }
.setbody h3 { margin: 0 0 4px; font-size: 14px; color: #f1f5f8; }
.setbody .sub { color: #8d9aa6; font-size: 12px; line-height: 1.5; margin-bottom: 10px; }
.setbody .hint { color: #6f7c88; font-size: 11px; margin-top: 4px; }
.setnote { background: rgba(41, 227, 255, .08); border: 1px solid rgba(41, 227, 255, .3); color: #bfeffd; border-radius: 8px; padding: 8px 10px; font-size: 12px; margin-bottom: 10px; line-height: 1.45; }
.plist { display: grid; gap: 6px; margin-bottom: 10px; }
.pcard { display: flex; gap: 10px; align-items: flex-start; text-align: left; background: #121a22; border: 1px solid #222d38; border-radius: 9px; padding: 10px 12px; color: inherit; cursor: pointer; font: inherit; }
.pcard:hover { border-color: #3a4a5a; }
.pcard.on { border-color: #29e3ff; background: linear-gradient(90deg, rgba(41, 227, 255, .10), rgba(41, 227, 255, .02)); }
.pcard .radio { flex: none; width: 14px; height: 14px; margin-top: 2px; border-radius: 50%; border: 2px solid #4a5868; }
.pcard.on .radio { border-color: #29e3ff; box-shadow: inset 0 0 0 3px #121a22; background: #29e3ff; }
.pcard .pt { display: grid; gap: 2px; }
.pcard b { font-size: 13px; }
.pcard small { color: #8d9aa6; font-size: 11px; line-height: 1.35; }
.pcard small.dcs { color: #6f7c88; }
.tgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tcard { display: grid; gap: 7px; text-align: left; background: #121a22; border: 1px solid #222d38; border-radius: 10px; padding: 8px; color: inherit; cursor: pointer; font: inherit; }
.tcard:hover { border-color: #3a4a5a; }
.tcard.on { border-color: #29e3ff; box-shadow: 0 0 0 1px #29e3ff, 0 0 18px rgba(41, 227, 255, .18); }
.tcard .thprev, .tcard .tprev { width: 100%; height: auto; aspect-ratio: 120 / 64; display: block; border-radius: 6px; }
.tcard .tprev.match { display: grid; place-content: center; text-align: center; background: repeating-linear-gradient(135deg, #1a232c 0 10px, #151d25 10px 20px); border: 1px dashed #3a4a5a; }
.tcard .tprev.match b { font: 800 16px var(--mono); color: #dde3e8; letter-spacing: .1em; }
.tcard .tprev.match small { color: #8d9aa6; font-size: 10.5px; }
.tcard .tt { display: grid; gap: 2px; }
.tcard .tt b { font-size: 12.5px; }
.tcard .tt em { font-style: normal; font: 700 9.5px var(--mono); color: #061018; background: #29e3ff; border-radius: 4px; padding: 1px 5px; margin-left: 4px; vertical-align: 1px; }
.tcard .tt small { color: #8d9aa6; font-size: 11px; line-height: 1.35; }
.setrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 10px 0 4px; flex-wrap: wrap; }
.setrow label { font-size: 12.5px; color: #c8d1d8; }
.setrow select { background: #121a22; color: #dde3e8; border: 1px solid #2c3846; border-radius: 6px; padding: 6px 8px; font: inherit; }
.seg { display: inline-flex; border: 1px solid #2c3846; border-radius: 8px; overflow: hidden; }
.seg button { background: #121a22; color: #9aa7b2; border: 0; border-right: 1px solid #2c3846; padding: 6px 11px; font: 600 12px var(--sans); cursor: pointer; }
.seg button:last-child { border-right: 0; }
.seg button:hover { color: #fff; }
.seg button.on { background: #29e3ff; color: #061018; }
@media (max-width: 600px) { .tgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .setrow { align-items: flex-start; flex-direction: column; } }

/* ---------- Futuristic ---------- */
.cr.hmi-neo { --bg: #05080f; --bg2: #08101c; --panel: #0b1524; --panel2: #0f1d31; --line: #15283f; --line2: #1e3a59; --text: #e6f6ff; --muted: #8fb3cc; --dim: #5f86a3; --equip: #3fa9d6; --equip-fill: #0a1626; --pipe: #1f4466; --sp: #29e3ff;
  background: radial-gradient(1200px 600px at 75% -10%, rgba(41, 227, 255, .10), transparent 60%), radial-gradient(900px 500px at 0% 110%, rgba(123, 92, 255, .12), transparent 60%), #05080f; color: var(--text); }
.cr.hmi-neo .alarmbar { background: rgba(8, 10, 20, .9); border-bottom: 1px solid #15283f; }
.cr.hmi-neo .mimicwrap { background: linear-gradient(rgba(41, 227, 255, .045) 1px, transparent 1px) 0 0 / 28px 28px, linear-gradient(90deg, rgba(41, 227, 255, .045) 1px, transparent 1px) 0 0 / 28px 28px, radial-gradient(ellipse at 50% 40%, #0b1a2c 0%, #060b14 75%); }
.cr.hmi-neo .mimicwrap .scr.html { background: rgba(6, 11, 20, .94); }
.cr.hmi-neo .log { background: rgba(5, 10, 18, .9); }
.cr.hmi-neo .trendwrap { background: #050a12; }
.cr.hmi-neo .m-eq { fill: rgba(16, 40, 66, .5); stroke: #3fa9d6; }
.cr.hmi-neo .m-eq.run { fill: rgba(20, 48, 78, .55); }
.cr.hmi-neo .m-eq.off { fill: none; stroke: #3d5a74; }
.cr.hmi-neo .m-eq.drv.run { stroke: #38f2b5; stroke-width: 2; filter: drop-shadow(0 0 4px rgba(56, 242, 181, .6)); }
.cr.hmi-neo .m-eq.drv.off { stroke: #4a6a85; }
.cr.hmi-neo .m-eq.trip { filter: drop-shadow(0 0 6px rgba(255, 59, 92, .8)); }
.cr.hmi-neo .m-pipe { stroke: #2a5378; }
.cr.hmi-neo .m-pipe.gas { stroke: #17324d; }
.cr.hmi-neo .m-pipe.meal { stroke: #7a6440; }
.cr.hmi-neo .m-flow { stroke: #29e3ff; opacity: .7; }
.cr.hmi-neo .m-lbl { fill: #7fa7c4; }
.cr.hmi-neo .m-lbl.big { fill: #cdeeff; }
.cr.hmi-neo .m-tag rect { fill: rgba(4, 12, 22, .88); stroke: #1f4c70; }
.cr.hmi-neo .m-tag text.v { fill: #5ff3ff; filter: drop-shadow(0 0 3px rgba(41, 227, 255, .55)); }
.cr.hmi-neo .m-tag text.n { fill: #6f97b5; }
.cr.hmi-neo .m-tag text.u { fill: #4f7896; }
.cr.hmi-neo .m-tag.a1 rect { fill: rgba(80, 10, 24, .9); stroke: #ff3b5c; } .cr.hmi-neo .m-tag.a2 rect { fill: rgba(70, 36, 6, .9); stroke: #ff9f43; } .cr.hmi-neo .m-tag.a3 rect { fill: rgba(60, 52, 8, .9); stroke: #ffd60a; }
.cr.hmi-neo .m-lim-bg { fill: #0b1828; stroke: #1e3a59; }
.cr.hmi-neo .m-lim { fill: #29e3ff; }
.cr.hmi-neo .scr svg rect[fill="#2a3137"], .cr.hmi-neo .scr svg rect[fill="#1e2327"] { fill: #0c1a2b; }
.cr.hmi-neo .scrtabs { background: rgba(5, 10, 18, .92); border-bottom-color: #15283f; }
.cr.hmi-neo .scrtabs button { background: rgba(16, 32, 52, .6); border-color: #1e3a59; color: #a9d4ee; }
.cr.hmi-neo .scrtabs button:hover { color: #fff; border-color: #29e3ff; }
.cr.hmi-neo .scrtabs button.on { background: linear-gradient(90deg, #1fd1ff, #7b5cff); border-color: transparent; color: #031018; box-shadow: 0 0 14px rgba(41, 227, 255, .45); }
.cr.hmi-neo .fp { background: rgba(11, 21, 36, .85); border-color: #1a3350; }
.cr.hmi-neo .fp .ctl button, .cr.hmi-neo .modesel button { background: #0f1d31; border-color: #1e3a59; color: #bfe6ff; }
.cr.hmi-neo .modesel button.on { background: #29e3ff; border-color: #29e3ff; color: #031018; }
.cr.hmi-neo .fp .bar i { background: linear-gradient(90deg, #1fd1ff, #38f2b5); }
.cr.hmi-neo .facepl { background: rgba(8, 16, 28, .94); backdrop-filter: blur(8px); border-color: #1e4a6e; box-shadow: 0 0 0 1px rgba(41, 227, 255, .15), 0 20px 50px rgba(0, 0, 0, .6); }
.cr.hmi-neo .btn { background: #0f1d31; border-color: #1e3a59; color: #cfeaff; }
.cr.hmi-neo .btn:hover { border-color: #29e3ff; }
.cr.hmi-neo .btn.primary { background: linear-gradient(90deg, #1fd1ff, #7b5cff); border-color: transparent; color: #041019; }
.cr.hmi-neo .kpi .v, .cr.hmi-neo .clock { color: #e6f6ff; }
.cr.hmi-neo .hbrow .hbbar i { background: linear-gradient(90deg, #1fd1ff, #7b5cff); }
.cr.hmi-neo .hbcols > div:last-child .hbrow .hbbar i { background: linear-gradient(90deg, #ff9f43, #ff4d8d); }

/* ---------- FLS ECS classic: black screens, bright values, green motors ---------- */
.cr.hmi-fls-classic { --bg: #000; --bg2: #0a0a0a; --panel: #111; --panel2: #1a1a1a; --line: #2c2c2c; --line2: #3a3a3a; --text: #f2f2f2; --muted: #c8c8c8; --dim: #9a9a9a; --equip: #a0a0a0; --equip-fill: #141414; --pipe: #6e6e6e; --sp: #00d7ff; background: #000; color: var(--text); }
.cr.hmi-fls-classic .alarmbar { background: #050505; }
.cr.hmi-fls-classic .mimicwrap, .cr.hmi-fls-classic .mimicwrap .scr.html { background: #000; }
.cr.hmi-fls-classic .log { background: #050505; }
.cr.hmi-fls-classic .m-eq.run { fill: #1a1a1a; }
.cr.hmi-fls-classic .m-eq.drv.run { fill: #0f5e1f; stroke: #2bd84a; stroke-width: 2; }
.cr.hmi-fls-classic .m-eq.drv.off { fill: #2a2a2a; stroke: #8a8a8a; }
.cr.hmi-fls-classic .m-lbl { fill: #d6d6d6; }
.cr.hmi-fls-classic .m-lbl.big { fill: #ffffff; }
.cr.hmi-fls-classic .m-pipe.gas { stroke: #4a4a4a; }
.cr.hmi-fls-classic .m-pipe.meal { stroke: #8a6d3b; }
.cr.hmi-fls-classic .m-tag rect { fill: #000; stroke: #5a5a5a; }
.cr.hmi-fls-classic .m-tag text.v { fill: #4fe3ff; }
.cr.hmi-fls-classic .m-tag text.n, .cr.hmi-fls-classic .m-tag text.u { fill: #bdbdbd; }
.cr.hmi-fls-classic .scr svg rect[fill="#2a3137"], .cr.hmi-fls-classic .scr svg rect[fill="#1e2327"] { fill: #151515; }
.cr.hmi-fls-classic .scrtabs { background: #000; }
.cr.hmi-fls-classic .scrtabs button { background: #1a1a1a; border-color: #444; color: #eee; }
.cr.hmi-fls-classic .scrtabs button.on { background: #00a3ff; border-color: #00a3ff; color: #000; }

/* ---------- Indigo DCS (2.9.0): indigo screens, bright green values, white labels, light grey pipes (from N8's HW Kiln CCR screenshot) ---------- */
.cr.hmi-indigo { --bg: #2c2b55; --bg2: #272650; --panel: #232248; --panel2: #34336a; --line: #46457e; --line2: #5c5b96; --text: #ffffff; --muted: #d4d4ea; --dim: #a6a6c8; --equip: #d0d0dc; --equip-fill: #3a3968; --pipe: #b9bccb; --sp: #3cff3c; background: #2c2b55; color: var(--text); }
.cr.hmi-indigo .alarmbar { background: #262550; border-bottom: 1px solid #46457e; }
.cr.hmi-indigo .mimicwrap, .cr.hmi-indigo .mimicwrap .scr.html { background: #2c2b55; }
.cr.hmi-indigo .log { background: #2a2952; }
.cr.hmi-indigo .m-eq { stroke: #d0d0dc; }
.cr.hmi-indigo .m-eq.run { fill: #3a3968; }
.cr.hmi-indigo .m-eq.off { fill: #2c2b55; stroke: #8a8ab0; }
.cr.hmi-indigo .m-eq.drv.run { fill: #19b81d; stroke: #5cff5c; stroke-width: 2; }
.cr.hmi-indigo .m-eq.drv.off { fill: #4a4970; stroke: #9a9ac0; }
.cr.hmi-indigo .m-lbl { fill: #ececf6; }
.cr.hmi-indigo .m-lbl.big { fill: #ffffff; }
.cr.hmi-indigo .m-pipe { stroke: #b9bccb; }
.cr.hmi-indigo .m-pipe.gas { stroke: #8e90a8; }
.cr.hmi-indigo .m-pipe.meal { stroke: #c9b07a; }
.cr.hmi-indigo .m-flow { stroke: #3cff3c; opacity: .65; }
.cr.hmi-indigo .m-tag rect { fill: #1f1e3d; stroke: #4e4d86; }
.cr.hmi-indigo .m-tag text.v { fill: #3cff3c; }
.cr.hmi-indigo .m-tag text.n, .cr.hmi-indigo .m-tag text.u { fill: #e0e0ee; }
.cr.hmi-indigo .m-lim-bg { fill: #1f1e3d; stroke: #5c5b96; }
.cr.hmi-indigo .m-lim { fill: #3cff3c; }
.cr.hmi-indigo .scr svg rect[fill="#2a3137"], .cr.hmi-indigo .scr svg rect[fill="#1e2327"] { fill: #3a3968; }
.cr.hmi-indigo .scr svg rect[fill="#4a545d"], .cr.hmi-indigo .scr svg path[fill="#4a545d"] { fill: #5c5b96; }
.cr.hmi-indigo .scrtabs { background: #262550; border-bottom: 2px solid #3cff3c; }
.cr.hmi-indigo .scrtabs .scrlbl { color: #a6a6c8; }
.cr.hmi-indigo .scrtabs button { background: #e4e4ea; border: 1px solid #ffffff; border-bottom: 0; color: #111; }
.cr.hmi-indigo .scrtabs button:hover { background: #ffffff; color: #000; }
.cr.hmi-indigo .scrtabs button.on { background: #3cff3c; border-color: #3cff3c; color: #000; box-shadow: none; }
.cr.hmi-indigo .crbar { background: #262550; border-bottom: 1px solid #46457e; }
.cr.hmi-indigo .kpis { background: #2c2b55; }
.cr.hmi-indigo .kpi { background: #302f5e; border-color: #46457e; }
.cr.hmi-indigo .kpi .v, .cr.hmi-indigo .clock { color: #3cff3c; }
.cr.hmi-indigo .crright, .cr.hmi-indigo .rbody { background: #2a2952; }
.cr.hmi-indigo .rtabs button.on { color: #3cff3c; box-shadow: inset 0 -2px 0 #3cff3c; }
.cr.hmi-indigo .btn { background: #3a3970; border-color: #5c5b96; color: #fff; }
.cr.hmi-indigo .btn:hover { border-color: #3cff3c; color: #fff; }
.cr.hmi-indigo .btn.primary { background: #e2601b; border-color: #e2601b; color: #fff; }
.cr.hmi-indigo .fp { background: #302f5e; border-color: #46457e; }
.cr.hmi-indigo .fp .ctl button, .cr.hmi-indigo .modesel button { background: #3a3970; border-color: #5c5b96; color: #f0f0f8; }
.cr.hmi-indigo .modesel button.on { background: #3cff3c; border-color: #3cff3c; color: #000; }
.cr.hmi-indigo .fp .bar i { background: #3cff3c; }
.cr.hmi-indigo .facepl { background: #272650; border-color: #5c5b96; box-shadow: 0 16px 40px rgba(0, 0, 0, .5); }
.cr.hmi-indigo .trendwrap { background: #292850; }
.cr.hmi-indigo .crmenu { background: #232248; border-color: #5c5b96; }
.cr.hmi-indigo .hbrow .hbbar i { background: #3cff3c; }
