:root{--bg:#0f1216;--panel:#171b21;--panel-2:#1e232b;--line:#2a313b;--text:#e6e9ee;--muted:#8b95a3;--accent:#e5333b;--accent-2:#ff5a61;--ok:#2ecc71;--bad:#e5533b;--lightningcss-light: ;--lightningcss-dark:initial;color-scheme:dark}*{box-sizing:border-box}html,body{height:100%;margin:0}body{background:var(--bg);color:var(--text);font:14px/1.45 -apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}button,input,select{font:inherit;color:var(--text);background:var(--panel-2);border:1px solid var(--line);border-radius:6px;padding:6px 12px}button{cursor:pointer}button:hover:not(:disabled){border-color:#3c4652}button:disabled{opacity:.5;cursor:default}button.primary{background:var(--accent);border-color:var(--accent);color:#fff}button.primary:hover:not(:disabled){background:var(--accent-2)}button.ghost{background:0 0}button.danger{color:var(--bad)}button.active{background:#2b323c;border-color:#4a5563}input:focus,select:focus{outline-offset:-1px;outline:2px solid #3d6df2}code{background:var(--panel-2);border-radius:4px;padding:1px 6px}h1,h2{margin:0 0 8px}h2{font-size:17px}table{border-collapse:collapse;width:100%}td{border-top:1px solid var(--line);vertical-align:middle;padding:6px 8px}small{margin-top:4px;display:block}.app{flex-direction:column;height:100vh;display:flex}header{background:var(--panel);border-bottom:1px solid var(--line);align-items:center;gap:16px;padding:8px 16px;display:flex}.brand{color:var(--accent);white-space:nowrap;font-weight:700}nav{flex:1;gap:4px;display:flex;overflow-x:auto}.tab{color:var(--muted);white-space:nowrap;background:0 0;border-color:#0000}.tab.active{color:var(--text);background:var(--panel-2);border-color:var(--line)}.user{color:var(--muted)}main{flex:1;padding:16px;overflow:auto}.banner{color:#ffb4b4;background:#3a1d1d;border-bottom:1px solid #5a2a2a;padding:8px 16px}.row{flex-wrap:wrap;align-items:center;display:flex}.gap{gap:8px}.grow{flex:1;min-width:0}.muted{color:var(--muted)}.error{color:#ff8a8a}.ok-box{color:var(--ok)}.nowrap{white-space:nowrap}.center{place-items:center;min-height:100vh;padding:16px;display:grid}.empty{color:var(--muted);text-align:center;padding:40px}.toolbar{margin-bottom:12px}.card{background:var(--panel);border:1px solid var(--line);border-radius:10px;margin-bottom:12px;padding:14px}.login{flex-direction:column;gap:12px;width:100%;max-width:360px;display:flex}.login h1{color:var(--accent)}label{color:var(--muted);flex-direction:column;gap:4px;font-size:13px;display:flex}label input,label select{color:var(--text)}label.check{color:var(--text);white-space:nowrap;flex-direction:row;align-items:center;gap:6px}input.inline{background:0 0;border-color:#0000;width:100%;padding:2px 6px}input.inline:hover,input.inline:focus{border-color:var(--line)}input.small{width:70px}.form{flex-direction:column;gap:12px;max-width:820px;display:flex}.cols{grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:12px;display:grid}.seg{flex-wrap:wrap;gap:4px;display:inline-flex}.found{flex-wrap:wrap;align-items:center;gap:6px;display:flex}.dot{background:#59626e;border-radius:50%;flex:none;width:8px;height:8px;margin-right:6px;display:inline-block}.dot.ok{background:var(--ok);box-shadow:0 0 6px var(--ok)}.dot.bad{background:var(--bad)}.dot.off{background:#333a44}.rec{color:var(--accent);border:1px solid var(--accent);border-radius:3px;padding:0 3px;font-size:10px;font-weight:700}.live{gap:12px;height:100%;display:flex}.cam-list{flex-direction:column;flex:none;gap:2px;width:220px;display:flex;overflow:auto}.cam-item{text-align:left;background:0 0;border-color:#0000;align-items:center;gap:6px;display:flex}.cam-item:hover{background:var(--panel-2)}.grid{gap:4px;display:grid}.pager{margin-left:auto}.player{aspect-ratio:16/9;cursor:pointer;background:#000;border-radius:6px;position:relative;overflow:hidden}.player video{object-fit:contain;background:#000;width:100%;height:100%;display:block}.player.big{cursor:default;width:100%;max-height:calc(100vh - 230px)}.player-overlay{color:var(--muted);place-items:center;display:grid;position:absolute;inset:0}.player-label{pointer-events:none;background:#0000008c;border-radius:4px;align-items:center;gap:4px;padding:2px 8px;font-size:12px;display:flex;position:absolute;top:6px;left:6px}.mode{color:var(--muted);margin-left:6px;font-size:10px}.player-tools{opacity:0;z-index:2;align-items:center;gap:4px;transition:opacity .15s;display:flex;position:absolute;top:6px;right:6px}.player:hover .player-tools,.player-tools.show,.player-tools:focus-within{opacity:1}.player-tools button{background:#000000a6;border-color:#fff3;padding:3px 8px;font-size:13px}.zoom-level{background:#000000a6;border-radius:4px;padding:2px 6px;font-size:12px}.rec-live{color:#ff6b6b;margin-left:6px;font-weight:700}.player-note{background:#000000bf;border-radius:4px;padding:4px 10px;font-size:12px;position:absolute;bottom:10px;left:50%;transform:translate(-50%)}.player.zoomed{cursor:grab}.player.zoomed:active{cursor:grabbing}.player video{transform-origin:50%}@media (hover:none){.player-tools{opacity:1}}.indoor-units{flex-direction:column;flex-basis:100%;gap:4px;margin-top:6px;display:flex}.indoor-units td{padding:3px 8px}.timeline .ev-mark{background:var(--warn,#f0b429);cursor:pointer;z-index:2;border-radius:1px;width:3px;height:14px;margin-left:-1px;position:absolute}.timeline .ev-mark:hover{width:5px;margin-left:-2px}.timeline .ev-mark.ev-human,.timeline .ev-mark.ev-intrusion,.timeline .ev-mark.ev-line_crossing{background:#ff6b6b}.timeline .ev-mark.ev-vehicle{background:#4dabf7}.timeline .ev-mark.ev-doorbell_ring,.timeline .ev-mark.ev-door_unlocked{background:#b197fc}.nvr-channels{flex-direction:column;gap:6px;max-height:50vh;display:flex;overflow:auto}.nvr-channels td{padding:4px 8px;font-size:13px}.cam-chip{align-items:center;gap:2px;display:inline-flex}.clock{font-variant-numeric:tabular-nums;min-width:170px}.playback .player.big{max-height:none}.playback .grid .player.big{max-height:calc(50vh - 150px)}.playback .grid:has(>:only-child) .player.big{max-height:calc(100vh - 300px)}.cal{display:inline-block;position:relative}.cal-pop{z-index:20;width:280px;padding:10px;position:absolute;top:calc(100% + 4px);left:0;box-shadow:0 8px 30px #00000080}.cal-head{margin-bottom:6px}.cal-grid{grid-template-columns:repeat(7,1fr);gap:3px;display:grid}.cal-w{color:var(--muted);text-align:center;font-size:11px}.cal-d{background:0 0;border-color:#0000;padding:5px 0;font-size:13px}.cal-d.has{background:#1f4d33;border-color:#2f7d4f}.cal-d.sel{outline:2px solid var(--accent)}.cal-foot{align-items:center;gap:6px;margin-top:8px;font-size:12px;display:flex}.cal-key{background:#1f4d33;border:1px solid #2f7d4f;border-radius:3px;width:12px;height:12px;display:inline-block}.tile{position:relative}.group-pick{border-bottom:1px solid var(--line);flex-direction:column;gap:6px;margin-bottom:4px;padding-bottom:8px;display:flex}.small-btn{padding:2px 8px;font-size:12px}.pick-list{grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:6px;max-height:50vh;display:grid;overflow:auto}.tile-actions{position:absolute;bottom:6px;right:6px}.unlocks{flex-wrap:wrap;align-items:center;gap:6px;display:inline-flex}.unlocks.compact button{background:#000000a6;border-color:#fff3;padding:3px 8px;font-size:12px}.unlocks.compact .unlock-msg{background:#000000a6;border-radius:4px;padding:2px 6px;font-size:12px}.unlock-msg{color:var(--muted)}.live-single{flex-direction:column;gap:10px;display:flex}.spinner{border:3px solid #333;border-top-color:var(--accent);border-radius:50%;width:22px;height:22px;animation:.8s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}.playback{flex-direction:column;gap:12px;display:flex}.timeline{background:var(--panel);border:1px solid var(--line);cursor:crosshair;border-radius:6px;height:46px;position:relative;overflow:hidden}.timeline .span{background:#2f7d4f;border-radius:2px;height:20px;position:absolute;top:6px}.timeline .cursor{background:var(--accent);width:2px;position:absolute;top:0;bottom:0}.timeline .tick{border-left:1px solid var(--line);height:14px;color:var(--muted);padding-left:3px;font-size:10px;position:absolute;bottom:0}.doorbell-panel{flex-wrap:wrap;align-items:center;gap:12px;padding:10px 0;display:flex}.modal-back{z-index:10;background:#0009;place-items:center;padding:16px;display:grid;position:fixed;inset:0}.modal{background:var(--panel);border:1px solid var(--line);border-radius:12px;flex-direction:column;gap:12px;width:min(760px,100%);padding:16px;display:flex}.modal-head{justify-content:space-between;align-items:flex-start;display:flex}.ring-title{font-size:20px;font-weight:700}.modal.doorbell{border-color:var(--accent);animation:1.2s ease-in-out 3 pulse;box-shadow:0 0 40px #e5333b59}@keyframes pulse{50%{box-shadow:0 0 60px #e5333bb3}}.settings{flex-direction:column;max-width:560px;display:flex}@media (max-width:720px){main{padding:10px}.live{flex-direction:column}.cam-list{width:100%;max-height:140px}.user,.devices table td:nth-child(4){display:none}}.users{flex-direction:column;max-width:820px;display:flex}.user-card h3{margin:4px 0 0;font-size:15px}.access-table td{padding:4px 8px}.access-device td{background:var(--panel-2)}.access-cam{padding-left:20px!important}.qr{background:#fff;border-radius:8px;width:200px;height:200px;padding:6px}.codes{background:var(--panel-2);letter-spacing:1px;border-radius:8px;margin:0;padding:10px 14px;font-size:15px}code.key{letter-spacing:1px;-webkit-user-select:all;user-select:all}.badge{background:var(--accent);color:#fff;text-align:center;border-radius:9px;min-width:18px;margin-left:6px;padding:0 5px;font-size:11px;line-height:18px;display:inline-block}.ev-list{flex-direction:column;gap:6px;display:flex}.ev{background:var(--panel);border:1px solid var(--line);border-radius:10px;align-items:center;gap:12px;padding:8px;display:flex}.ev.unread{background:#1a2029;border-color:#3d4a5c}.ev-thumb{background:#0b0d10;flex:none;place-items:center;width:160px;height:90px;padding:0;font-size:28px;display:grid;overflow:hidden}.ev-thumb img{object-fit:cover;width:100%;height:100%;display:block}.ev-body{cursor:default}.ev-msg{color:var(--muted);text-overflow:ellipsis;white-space:nowrap;font-size:12px;overflow:hidden}.ev-dot{background:#3d8df2;border-radius:50%;flex:none;width:8px;height:8px}.ev-actions{flex:none;gap:6px;display:flex}.ev-more{align-self:center;margin:8px}.ev-modal{width:min(1100px,100%)}.ev-big{object-fit:contain;background:#000;border-radius:8px;width:100%;max-height:70vh}button.day{color:var(--muted);background:0 0;padding:3px 7px;font-size:12px}button.day.active{color:#fff;background:#24406e;border-color:#3d6df2}.toasts{z-index:20;flex-direction:column;gap:8px;width:min(360px,100vw - 32px);display:flex;position:fixed;bottom:16px;right:16px}.toast{background:var(--panel);border:1px solid var(--line);border-left:3px solid var(--accent);cursor:pointer;border-radius:10px;align-items:center;gap:10px;padding:8px;display:flex;box-shadow:0 6px 24px #0006}.toast img{object-fit:cover;border-radius:6px;flex:none;width:96px;height:54px}.toast-icon{text-align:center;width:54px;font-size:26px}@media (max-width:640px){.ev{flex-wrap:wrap}.ev-thumb{width:100%;height:180px}}.ptz{background:var(--panel);border:1px solid var(--line);border-radius:8px;flex-wrap:wrap;align-items:center;gap:18px;padding:10px;display:flex}.ptz-pad{grid-template-columns:repeat(3,44px);grid-auto-rows:44px;gap:4px;display:grid}.ptz-btn{touch-action:none;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;padding:0;font-size:18px}.ptz-btn.active{background:var(--accent);border-color:var(--accent);color:#fff}.ptz-stop{color:var(--muted);font-size:13px}.ptz-side{flex-direction:column;gap:10px;display:flex}.ptz-side .ptz-btn{width:44px;height:36px}.ptz-speed input{width:160px;padding:0}.talk{flex-wrap:wrap;align-items:center;gap:6px;display:inline-flex}.talk button.talking{animation:1.2s ease-in-out infinite talk-pulse}.talk button{touch-action:none;-webkit-user-select:none;user-select:none}@keyframes talk-pulse{50%{opacity:.7}}.hl-info{grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:10px 16px;margin:6px 0 4px;display:grid}.hl-info .muted{font-size:12px}.hl-section{margin-top:16px}.hl-section h3{margin:0 0 8px;font-size:15px}.hl-count,.hl-kind{font-size:13px;font-weight:400}.hl-sub{margin:4px 0 8px;font-size:13px}.hl-strong{color:var(--text)}.hl-disk{background:var(--panel-2);border:1px solid var(--line);border-radius:8px;margin-bottom:8px;padding:10px 12px}.hl-bar{background:#0b0d10;border-radius:4px;height:8px;margin-top:8px;overflow:hidden}.hl-bar>div{background:var(--ok);height:100%}.hl-bar.warn>div{background:#e5a33b}.hl-bar.bad>div{background:var(--bad)}.hl-warnings{flex-direction:column;gap:4px;margin:0;padding-left:18px;display:flex}.hl-warnings .bad{color:#ff8a8a}.hl-warnings .warn,.hl-warn-text{color:#f0c27a}.hl-table-wrap{overflow-x:auto}.hl-table td{padding:5px 8px;font-size:13px}.hl-table thead td{color:var(--muted);border-top:none;font-size:12px}.hl-log{max-height:60vh;overflow-y:auto}.hl-desc{white-space:pre-line;min-width:260px}.hl-serial{word-break:break-all}.call-taken{color:#ffb020;background:#ffaa0026;border-radius:8px;padding:8px 12px;font-weight:600}.call-taken.mine{color:#3ccf8e;background:#28c87826}.ds{flex-direction:column;gap:16px;padding-bottom:80px;display:flex}.ds-head{align-items:center;gap:14px;display:flex}.ds-head>button{border-radius:50%;width:36px;height:36px;padding:0;font-size:18px}.ds-title h1{letter-spacing:-.01em;margin:0;font-size:20px}.ds-title .muted{font-size:13px}.ds-body{grid-template-columns:230px 1fr;align-items:start;gap:20px;display:grid}.ds-nav{background:var(--panel);border:1px solid var(--line);border-radius:12px;flex-direction:column;gap:14px;padding:12px 8px;display:flex;position:sticky;top:0}.ds-group{flex-direction:column;gap:1px;display:flex}.ds-group-title{text-transform:uppercase;letter-spacing:.06em;color:var(--muted);align-items:center;gap:6px;padding:2px 10px 6px;font-size:11px;font-weight:600;display:flex}.ds-item{text-align:left;color:var(--text);background:0 0;border:0;border-radius:8px;align-items:center;gap:6px;padding:7px 10px;display:flex;position:relative}.ds-item:hover{background:var(--panel-2)}.ds-item.active{color:#fff;background:#e5333b1f}.ds-item.active:before{content:"";background:var(--accent);border-radius:3px;width:3px;position:absolute;top:7px;bottom:7px;left:0}.ds-item .tag{color:var(--muted);border:1px solid var(--line);border-radius:999px;padding:0 6px;font-size:10px}.ds-main{flex-direction:column;gap:14px;min-width:0;display:flex}.ds-sec-head{flex-wrap:wrap;align-items:flex-end;gap:16px;display:flex}.ds-sec-head h2{letter-spacing:-.01em;margin:0 0 2px;font-size:22px}.ds-sec-head p{margin:0}.ds-picker{flex-direction:column;gap:4px;min-width:260px}.ds-picker span{text-transform:uppercase;letter-spacing:.06em;font-size:11px}.ds-picker select{border-radius:8px;padding:8px 12px}.ds-note{color:#b8c8ff;background:#3d6df21a;border:1px solid #3d6df24d;border-radius:10px;padding:9px 12px;font-size:13px}.ds-error{color:#ffb0a0;background:#e5533b1a;border:1px solid #e5533b59;border-radius:10px;padding:9px 12px}.ds-ok{color:#a9f0c6;background:#2ecc711a;border:1px solid #2ecc7159;border-radius:10px;padding:9px 12px}.ds-grid{grid-template-columns:1fr;gap:14px;display:grid}.ds-grid.with-preview{grid-template-columns:minmax(0,1.25fr) minmax(300px,1fr)}.ds-grid.with-preview .ds-details{grid-column:1/-1}.ds-card{background:var(--panel);border:1px solid var(--line);border-radius:12px;padding:16px}.ds-card.empty{color:var(--muted);text-align:center;padding:32px}.ds-card-title{text-transform:uppercase;letter-spacing:.06em;color:var(--muted);margin-bottom:10px;font-size:12px;font-weight:600}.ds-preview{padding:10px}.ds-video{border-radius:8px;position:relative;overflow:hidden}.ds-video .player{cursor:default;border-radius:8px}.ds-video .overlay{pointer-events:none;width:100%;height:100%;position:absolute;inset:0}.ds-video .overlay .cell{fill:#e5333b47;stroke:#ff78788c;stroke-width:.04px}.ds-video .overlay .shape{stroke-width:.6px;vector-effect:non-scaling-stroke}.ds-video .overlay .shape.on{fill:#f0b4292e;stroke:#f0b429;stroke-width:2.5px}.ds-video .overlay .shape.off{fill:#ffffff0f;stroke:#ffffff8c;stroke-width:1.5px;stroke-dasharray:6 4}.ds-video .overlay .shape.line{fill:none}.ds-legend{flex-wrap:wrap;align-items:center;gap:8px;padding:8px 4px 2px;font-size:12px;display:flex}.ds-legend .key{border-radius:3px;width:12px;height:12px;display:inline-block}.ds-legend .key.cell{background:#e5333b73}.ds-legend .key.shape-on{background:#f0b429}.ds-legend .key.shape-off{border:1.5px dashed #fff9}.ds-row{border-top:1px solid var(--line);border-radius:8px;align-items:center;gap:16px;margin:0 -10px;padding:12px 10px;display:flex}.ds-row:first-of-type{border-top:0}.ds-row.changed{background:#f0b42914}.ds-row-label{flex:1;min-width:140px}.ds-row-label .small{font-size:12px}.ds-row .ctl{border-radius:8px;min-width:200px;padding:8px 10px}.ds-row .ctl-wide{flex:1.4}.switch{background:#3a414c;border:0;border-radius:999px;flex:none;width:44px;height:24px;padding:0;transition:background .15s;position:relative}.switch .knob{background:#fff;border-radius:50%;width:18px;height:18px;transition:transform .15s;position:absolute;top:3px;left:3px;box-shadow:0 1px 3px #0006}.switch.on{background:var(--ok)}.switch.on .knob{transform:translate(20px)}.switch:focus-visible{outline-offset:2px;outline:2px solid #3d6df2}.slider{align-items:center;gap:10px;min-width:220px;display:flex}.slider input[type=range]{accent-color:var(--accent);background:0 0;border:0;flex:1;padding:0}.slider output{text-align:center;font-variant-numeric:tabular-nums;background:var(--panel-2);border:1px solid var(--line);border-radius:6px;min-width:38px;padding:2px 6px}.ds-details dl{grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:0 18px;margin:0;display:grid}.ds-detail-group+.ds-detail-group{margin-top:12px}.ds-detail-title{color:#c9d1dc;margin:4px 0;font-size:13px;font-weight:600}.ds-kv{border-bottom:1px solid #ffffff0a;justify-content:space-between;gap:12px;padding:6px 0;font-size:13px;display:flex}.ds-kv dt{color:var(--muted)}.ds-kv dd{text-align:right;word-break:break-word;margin:0}.pill{border-radius:999px;padding:1px 8px;font-size:11px;font-weight:600;display:inline-block}.pill.on{color:#6ee7a3;background:#2ecc7126}.pill.off{color:var(--muted);background:#ffffff12}.ds-savebar{z-index:30;background:#1f252e;border:1px solid #39424e;border-radius:12px;align-items:center;gap:10px;width:min(720px,100% - 32px);padding:10px 12px 10px 16px;display:flex;position:fixed;bottom:18px;left:50%;transform:translate(-50%);box-shadow:0 10px 40px #0000008c}.skel{background:linear-gradient(90deg, var(--panel-2) 25%, #262c35 50%, var(--panel-2) 75%);background-size:200% 100%;border-radius:8px;animation:1.2s ease-in-out infinite skel}.skel-line{height:28px}.skel-box{height:220px}@keyframes skel{to{background-position:-200% 0}}@media (max-width:900px){.ds-body{grid-template-columns:1fr}.ds-nav{flex-direction:row;gap:8px;position:static;overflow-x:auto}.ds-group{flex-direction:row;align-items:center}.ds-group-title{display:none}.ds-item{white-space:nowrap}.ds-grid.with-preview{grid-template-columns:1fr}.ds-row{flex-wrap:wrap}.ds-row .ctl,.slider{width:100%;min-width:0}}
