:root{--bg:#f3f7f9;--surface:#fff;--surface-2:#f8fbfc;--text:#163444;--muted:#6f8491;--line:#dce8ed;--nav:#082d3c;--nav-2:#0a3a4d;--primary:#079b96;--primary-2:#087b85;--blue:#1975a3;--amber:#d99a2b;--danger:#d55555;--success:#168b67;--shadow:0 10px 35px rgba(18,58,77,.08);--radius:18px;font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif;color-scheme:light}html[data-theme=dark]{--bg:#071a24;--surface:#0c2734;--surface-2:#102f3d;--text:#e6f1f5;--muted:#9fb4c0;--line:#1c4658;--nav:#05141c;--nav-2:#0a2835;--shadow:0 12px 38px rgba(0,0,0,.25);color-scheme:dark}@media(prefers-color-scheme:dark){html[data-theme=system]{--bg:#071a24;--surface:#0c2734;--surface-2:#102f3d;--text:#e6f1f5;--muted:#9fb4c0;--line:#1c4658;--nav:#05141c;--nav-2:#0a2835;--shadow:0 12px 38px rgba(0,0,0,.25);color-scheme:dark}}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font-size:14px}a{color:var(--primary);text-decoration:none}button,input,select,textarea{font:inherit}.app-shell{min-height:100vh}.sidebar{position:fixed;inset:0 auto 0 0;width:252px;background:linear-gradient(180deg,var(--nav),#061f2b);color:#dbe9ee;display:flex;flex-direction:column;padding:24px 16px;z-index:30;overflow-y:auto}.brand,.auth-brand{display:flex;align-items:center;gap:12px}.brand{padding:0 10px 22px;border-bottom:1px solid rgba(255,255,255,.09);margin-bottom:14px}.brand-mark{width:40px;height:40px;border-radius:13px;background:linear-gradient(135deg,#13b9ae,#1078a4);display:grid;place-items:center;color:#fff;font-weight:900;font-size:20px;box-shadow:0 8px 18px rgba(4,167,157,.2)}.brand div,.auth-brand div{display:flex;flex-direction:column}.brand strong,.auth-brand strong{font-size:17px;letter-spacing:.06em}.brand small{color:#8db0be}.sidebar nav{display:flex;flex-direction:column;gap:3px;flex:1}.sidebar nav a{color:#b7ccd5;display:flex;align-items:center;gap:11px;padding:10px 12px;border-radius:11px;font-weight:570}.sidebar nav a:hover,.sidebar nav a.active{background:rgba(52,185,179,.13);color:#fff}.sidebar nav a.active{box-shadow:inset 3px 0 #19b6ae}.nav-icon{width:24px;height:24px;display:grid;place-items:center;border:1px solid rgba(255,255,255,.1);border-radius:7px;font-size:10px;color:#69ccc5}.nav-section{margin:18px 12px 6px;color:#658793;font-size:10px;letter-spacing:.15em}.template-link{border:1px solid rgba(255,255,255,.13);padding:11px 12px;border-radius:10px;color:#bfe3df;font-size:12px;margin-top:16px;text-align:center}.workspace{margin-left:252px;min-height:100vh}.topbar{height:78px;position:sticky;top:0;background:color-mix(in srgb,var(--surface) 94%,transparent);backdrop-filter:blur(12px);border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 30px;z-index:20}.top-context{display:flex;flex-direction:column}.top-context small{color:var(--muted);font-size:11px}.top-context strong{font-size:16px}.top-actions{margin-left:auto;display:flex;align-items:center;gap:12px}.theme-select{border:1px solid var(--line);background:var(--surface-2);color:var(--text);border-radius:10px;padding:8px}.user-chip{display:flex;align-items:center;gap:9px;border-left:1px solid var(--line);padding-left:14px}.user-chip>span{width:35px;height:35px;border-radius:50%;display:grid;place-items:center;background:#d9f1ef;color:#087d78;font-weight:800}.user-chip div{display:flex;flex-direction:column}.user-chip small{font-size:10px;color:var(--muted)}.icon-button{border:0;background:transparent;color:var(--muted);font-size:20px;cursor:pointer;padding:7px}.menu-button{display:none}.main-content{padding:30px;max-width:1600px;margin:auto}.page-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;margin-bottom:24px}.page-heading h1{font-size:29px;line-height:1.2;margin:3px 0 7px;letter-spacing:-.025em}.page-heading p{margin:0;color:var(--muted)}.eyebrow{font-size:11px!important;letter-spacing:.14em;color:var(--primary)!important;font-weight:800}.live-pill{background:var(--surface);border:1px solid var(--line);border-radius:999px;padding:9px 13px;color:var(--muted);box-shadow:var(--shadow)}.live-pill i{display:inline-block;width:8px;height:8px;border-radius:50%;background:#25ba84;margin-right:7px;box-shadow:0 0 0 5px rgba(37,186,132,.12)}.kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:20px}.kpi{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:19px;min-height:124px;box-shadow:var(--shadow);position:relative;overflow:hidden}.kpi:after{content:"";position:absolute;right:-25px;bottom:-35px;width:100px;height:100px;border-radius:50%;background:rgba(8,161,154,.055)}.kpi-icon{display:grid;place-items:center;width:30px;height:30px;border-radius:9px;background:rgba(7,155,150,.11);color:var(--primary);font-size:11px;font-weight:900}.kpi p{color:var(--muted);font-size:12px;margin:9px 0 2px}.kpi strong{font-size:25px;letter-spacing:-.03em}.kpi strong small{font-size:11px;color:var(--muted);font-weight:600;margin-left:5px}.dashboard-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(280px,1fr);gap:18px;margin:18px 0}.panel{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:20px;box-shadow:var(--shadow)}.panel h2{font-size:16px;margin:0}.panel p{color:var(--muted)}.panel-head{display:flex;justify-content:space-between;align-items:flex-start;gap:15px;margin-bottom:16px}.panel-head p{margin:4px 0 0;font-size:12px}.chart-panel canvas{height:310px!important;max-height:310px}.trend{border-radius:999px;padding:7px 10px;font-size:11px;background:var(--surface-2)}.trend.up{color:var(--success)}.trend.down{color:var(--danger)}.projection{display:flex;flex-direction:column;align-items:center;text-align:center;padding:22px 4px}.projection strong{font-size:42px;color:var(--primary)}.projection span{font-weight:700}.projection p{margin-bottom:4px}.projection small{color:var(--muted)}.mini-list>div{display:flex;align-items:center;gap:10px;padding:11px 0;border-bottom:1px solid var(--line)}.mini-list>div:last-child{border:0}.mini-list p{display:flex;flex:1;flex-direction:column;margin:0;min-width:0}.mini-list p small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mini-list em{font-size:10px;color:var(--muted);font-style:normal}.status-dot{width:8px;height:8px;border-radius:50%;background:var(--amber)}.status-dot.critical{background:var(--danger)}.compact-empty{text-align:center;color:var(--muted);padding:34px 10px}.empty-state{background:var(--surface);border:1px dashed var(--line);border-radius:var(--radius);padding:58px 20px;text-align:center;margin:18px 0}.empty-state.compact{padding:38px}.empty-state>span{font-size:38px;color:var(--primary)}.empty-state h2{font-size:17px;margin:10px}.empty-state p{color:var(--muted)}.filter-bar{display:flex;align-items:end;gap:12px;padding:14px;background:var(--surface);border:1px solid var(--line);border-radius:14px;margin-bottom:18px}.filter-bar label,.stack-form label,.data-form label{display:flex;flex-direction:column;gap:6px;font-size:12px;font-weight:650}.filter-bar input,input,select,textarea{background:var(--surface-2);border:1px solid var(--line);border-radius:10px;padding:10px 11px;color:var(--text);outline:none}.filter-bar input:focus,input:focus,select:focus,textarea:focus{border-color:var(--primary);box-shadow:0 0 0 3px rgba(7,155,150,.1)}textarea{min-height:88px;resize:vertical}.button{display:inline-flex;justify-content:center;align-items:center;border:0;border-radius:10px;padding:10px 15px;font-weight:700;cursor:pointer}.button.primary{background:linear-gradient(135deg,var(--primary),var(--primary-2));color:#fff}.button.secondary{background:var(--surface-2);border:1px solid var(--line);color:var(--text)}.button.small{font-size:11px;padding:7px 9px}.button.wide{width:100%}.entry-panel{margin-bottom:18px}.data-form{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.data-form .span-2{grid-column:span 2}.form-actions{grid-column:1/-1;display:flex;gap:10px;border-top:1px solid var(--line);padding-top:15px}.table-wrap{overflow:auto}.table-wrap table{width:100%;border-collapse:collapse;min-width:800px}.table-wrap th{text-align:left;font-size:10px;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);padding:11px;border-bottom:1px solid var(--line);white-space:nowrap}.table-wrap td{padding:12px 11px;border-bottom:1px solid var(--line);font-size:12px;vertical-align:top}.table-wrap tbody tr:hover{background:var(--surface-2)}.badge{display:inline-flex;border-radius:999px;padding:4px 8px;background:var(--surface-2);font-size:10px;text-transform:capitalize}.badge.critical,.badge.out_of_range,.badge.fault{color:var(--danger);background:rgba(213,85,85,.1)}.badge.active,.badge.compliant,.badge.completed,.badge.operational{color:var(--success);background:rgba(22,139,103,.1)}.badge.watch,.badge.in_progress,.badge.maintenance{color:var(--amber);background:rgba(217,154,43,.11)}.pagination{display:flex;gap:6px;justify-content:center;padding-top:17px}.pagination a{width:31px;height:31px;display:grid;place-items:center;border:1px solid var(--line);border-radius:8px;color:var(--text)}.pagination a.active{background:var(--primary);color:#fff;border-color:var(--primary)}.metric-list>div{display:flex;justify-content:space-between;padding:12px 0;border-bottom:1px solid var(--line)}.big-status{display:flex;align-items:center;gap:12px;padding:16px 0;border-bottom:1px solid var(--line)}.big-status span{font-size:28px;font-weight:800;color:var(--danger)}.big-status p{margin:0}.alert{padding:12px 14px;border-radius:11px;margin-bottom:15px}.alert.success{background:rgba(22,139,103,.12);color:var(--success)}.alert.danger{background:rgba(213,85,85,.12);color:var(--danger)}.auth-page{min-height:100vh;display:grid;place-items:center;background:radial-gradient(circle at 20% 20%,rgba(19,185,174,.16),transparent 30%),linear-gradient(145deg,#052631,#0a4253)}.auth-shell{width:min(430px,calc(100% - 32px))}.auth-brand{color:#fff;margin-bottom:18px;justify-content:center}.auth-brand small{color:#9bc4d0}.auth-card{background:#fff;color:#173542;border-radius:22px;padding:34px;box-shadow:0 25px 65px rgba(0,0,0,.24)}.auth-card h1{margin:0 0 8px;font-size:25px}.muted{color:#6f8491}.stack-form{display:flex;flex-direction:column;gap:14px;margin:22px 0 15px}.text-link{display:block;text-align:center;font-size:12px}.auth-note{text-align:center;color:#86aeba;font-size:11px}.error-page{text-align:center;color:#fff;max-width:500px;padding:30px}.error-page>span{font-size:80px;font-weight:900;color:#42cbc2}.error-page h1{font-size:30px}.tv-body{background:#051720}.tv-screen{padding:25px;min-height:100vh}.tv-screen>header{display:flex;justify-content:space-between;align-items:center;margin-bottom:24px}.tv-clock{text-align:right}.tv-clock strong{display:block;font-size:32px}.tv-clock span{color:var(--muted)}.tv-kpis{display:grid;grid-template-columns:repeat(7,1fr);gap:12px}.tv-kpis article{background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:17px}.tv-kpis p{color:var(--muted);margin:0 0 9px}.tv-kpis strong{font-size:25px}.tv-kpis small{font-size:11px;margin-left:4px}.tv-bottom{display:grid;grid-template-columns:2fr 1fr;gap:18px;margin-top:18px}.tv-bottom canvas{height:380px!important}.quality-compliant{color:#36c793}.quality-watch{color:#e4a938}.quality-out_of_range{color:#f06565}.executive .kpi{min-height:135px}
@media(max-width:1200px){.kpi-grid{grid-template-columns:repeat(2,1fr)}.tv-kpis{grid-template-columns:repeat(4,1fr)}}@media(max-width:900px){.sidebar{transform:translateX(-100%);transition:.25s}.sidebar.open{transform:none}.workspace{margin-left:0}.menu-button{display:block}.main-content{padding:22px}.user-chip div{display:none}.dashboard-grid{grid-template-columns:1fr}.data-form{grid-template-columns:repeat(2,1fr)}.tv-kpis{grid-template-columns:repeat(3,1fr)}.tv-bottom{grid-template-columns:1fr}}@media(max-width:600px){.topbar{padding:0 14px;height:68px}.top-context small,.theme-select{display:none}.main-content{padding:16px}.page-heading{flex-direction:column}.page-heading h1{font-size:24px}.kpi-grid{grid-template-columns:1fr 1fr;gap:9px}.kpi{padding:14px;min-height:112px}.kpi strong{font-size:20px}.filter-bar{flex-wrap:wrap}.filter-bar label{flex:1;min-width:125px}.data-form{grid-template-columns:1fr}.data-form .span-2{grid-column:auto}.form-actions{grid-column:auto}.auth-card{padding:25px}.tv-kpis{grid-template-columns:1fr 1fr}.tv-screen{padding:12px}}
