.task-cell.live-cell{grid-template-columns:1fr 1fr;grid-template-rows:28px minmax(0,1fr) 27px}.store-strip{grid-column:1/-1;min-width:0;display:flex;align-items:center;gap:5px;padding:0 5px;background:#050913;border-bottom:1px solid #9da9ba}.store-title{font-size:9px;color:#fff;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.store-mark{width:170px;max-width:24%;height:20px;flex:none;border:1px solid #8993a4;border-radius:3px;background:#060a13;color:#fff;padding:0 6px;font-size:8px}.store-mark::placeholder{color:#9ca6b8}.store-quick-actions{margin-left:auto;display:flex;gap:4px}.store-quick-actions button{width:27px;height:21px;border:0;border-radius:4px;background:#5c79ed;color:#fff;font-size:10px;cursor:pointer}.camera{grid-row:2}.camera-info{top:5px;left:5px;display:flex;align-items:center;gap:5px;font-size:8px}.camera-info b{background:#e2565d;color:white;padding:3px 5px;border-radius:2px}.camera-info span{background:#1118;padding:3px 4px}.camera-time{top:24px;bottom:auto;left:42px}.camera.second-camera .camera-time{left:auto;right:5px;bottom:5px;top:auto}.camera-bottom-tools{position:absolute;z-index:1;left:7px;bottom:6px;display:flex;gap:5px}.camera-bottom-tools button{border:0;border-radius:5px;background:#ff575d;color:#fff;padding:5px 9px;font-size:8px;cursor:pointer}.camera-switch-label{position:absolute;z-index:1;right:6px;top:5px;border:0;background:#1119;color:#fff;padding:4px 7px;border-radius:3px;font-size:8px;cursor:pointer}.device-lines{position:absolute;z-index:1;left:9px;top:44px;display:grid;gap:4px;color:#e3e8f0;text-shadow:0 1px 2px #000;font-size:8px}.device-lines i{color:#73df87;font-style:normal}.camera-mid-tools{position:absolute;z-index:1;left:50%;bottom:26px;transform:translateX(-50%);display:flex;gap:7px}.camera-mid-tools button{width:48px;height:48px;border:1px solid #fff5;border-radius:50%;background:#171b20a8;color:#fff;display:grid;place-content:center;justify-items:center;font-size:15px;cursor:pointer}.camera-mid-tools button small{font-size:7px;white-space:nowrap}.task-status{grid-row:3;background:#819b82;font-size:8px}.status-left{display:flex;align-items:center;gap:5px;white-space:nowrap}.status-left i{width:8px;height:8px;border-radius:50%;background:#52e08c;border:1px solid #d4ffe2}.task-status .status-actions{gap:5px}.task-status button{height:20px;padding:0 8px;border-radius:5px;background:#5d7bf1;font-size:8px;white-space:nowrap}.task-status button.control-active,.camera-bottom-tools button.control-active,.camera-mid-tools button.control-active{background:#22a77e;color:#fff}@media(max-width:800px){.task-cell.live-cell{grid-template-rows:25px minmax(0,1fr) 25px}.store-title{font-size:7px}.store-mark{max-width:22%;height:17px}.store-quick-actions{gap:2px}.store-quick-actions button{width:22px;height:18px;font-size:8px}.camera-info{font-size:6px}.camera-info b{padding:2px 3px}.camera-bottom-tools{left:4px;bottom:4px;gap:3px}.camera-bottom-tools button{padding:4px 5px;font-size:6px}.camera-mid-tools{bottom:20px;gap:3px}.camera-mid-tools button{width:36px;height:36px;font-size:12px}.camera-mid-tools button small{font-size:6px}.device-lines{top:34px;left:5px;font-size:6px}.camera-switch-label{font-size:6px;padding:3px}.task-status .status-actions{gap:2px}.task-status button{height:17px;padding:0 4px;font-size:6px}.status-left{font-size:6px;gap:2px}}@media(max-width:520px){.task-cell.live-cell{grid-template-rows:26px minmax(0,1fr) 25px}.store-mark{display:none}.store-title{max-width:52%}.camera-info{gap:2px;font-size:6px}.camera-info span{display:none}.camera-mid-tools{bottom:24px}.camera-mid-tools button{width:32px;height:32px}.status-left{display:none}.task-status{justify-content:flex-end}}
.task-grid{grid-template-rows:repeat(2,minmax(0,1fr))}.task-grid.density-six{grid-template-rows:repeat(3,minmax(0,1fr))}@media(max-width:520px){.task-grid{grid-template-rows:repeat(4,minmax(175px,1fr))}.task-grid.density-six{grid-template-rows:repeat(6,minmax(175px,1fr))}}
.task-grid{overflow-y:auto;align-content:start;grid-auto-rows:calc((100vh - 52px)/2);grid-template-rows:repeat(2,calc((100vh - 52px)/2))}.task-grid.density-six{grid-auto-rows:calc((100vh - 52px)/3);grid-template-rows:repeat(3,calc((100vh - 52px)/3))}@media(max-width:520px){.task-grid{grid-auto-rows:175px;grid-template-rows:repeat(4,175px)}.task-grid.density-six{grid-auto-rows:175px;grid-template-rows:repeat(6,175px)}}
@media(max-width:520px){.task-grid{grid-auto-rows:175px;grid-template-rows:repeat(4,175px)}.task-grid.density-six{grid-auto-rows:175px;grid-template-rows:repeat(6,175px)}}

.utility-overlay{position:fixed;z-index:10;inset:0;background:#030817dc;display:grid;place-items:center;padding:18px}.utility-card{width:min(820px,100%);max-height:min(88vh,760px);overflow:auto;background:#f7faf9;color:#263a35;border:1px solid #40534d;border-radius:8px;box-shadow:0 20px 70px #0009}.voice-card{width:min(620px,100%)}.utility-header{height:66px;padding:0 18px;display:flex;align-items:center;justify-content:space-between;background:#fff;border-bottom:1px solid #e3eae7}.utility-header small{font-size:9px;color:#7c8c85}.utility-header h2{margin:3px 0 0;font-size:17px}.utility-header>button{height:28px;width:28px;border:1px solid #e1e8e4;border-radius:4px;background:#fff;color:#697a73;font-size:19px;cursor:pointer}.utility-body{padding:16px 18px}.field-label{display:grid;gap:6px;color:#61726b;font-size:9px}.field-label input{height:32px;padding:0 9px;border:1px solid #dce5e0;border-radius:4px;background:#fff;color:#344840;font-size:10px}.voice-scene-list{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:13px}.voice-scene{border:1px solid #e0e8e3;border-radius:5px;background:#fff;padding:10px}.scene-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:7px}.scene-heading label{display:flex;align-items:center;gap:6px;color:#40564c;font-size:10px}.scene-heading button,.voice-tools button,.customer-toolbar>button,.bulk-tools button,.customer-table td button{height:25px;padding:0 8px;border:1px solid #d9e4dd;border-radius:4px;background:#fff;color:#4b7060;font-size:8px;cursor:pointer}.voice-scene textarea{resize:vertical;width:100%;min-height:49px;padding:7px;border:1px solid #e2e9e5;border-radius:4px;color:#354b41;font:9px/1.5 inherit}.voice-tools{display:flex;align-items:center;gap:8px;margin-top:12px}.voice-tools span{flex:1;color:#91a099;font-size:8px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.voice-tools #voice-test{background:#eef6f0}.utility-footer{display:flex;align-items:center;justify-content:space-between;gap:10px;border-top:1px solid #e4ebe7;padding:12px 18px;background:#fff;color:#89978f;font-size:8px}.primary-utility{height:29px;padding:0 11px;border:1px solid #237d65;border-radius:4px;background:#237d65;color:white;font-size:9px;cursor:pointer}.customer-toolbar{display:flex;gap:8px;padding:12px 16px 8px}.customer-search{height:30px;flex:1;display:flex;align-items:center;gap:7px;padding:0 9px;border:1px solid #dce5e0;border-radius:4px;background:#fff;color:#87968f}.customer-search input{border:0;outline:0;flex:1;min-width:0;color:#354a41;font-size:9px}.bulk-tools{display:flex;align-items:center;gap:7px;padding:5px 16px 11px;color:#63746c;font-size:8px}.bulk-tools label{display:flex;align-items:center;gap:4px;margin-right:auto}.bulk-tools select{height:25px;border:1px solid #dce5e0;border-radius:4px;background:#fff;color:#586b61;font-size:8px}.customer-table-wrap{max-height:48vh;overflow:auto;background:#fff;border-top:1px solid #e5ece8;border-bottom:1px solid #e5ece8}.customer-table{width:100%;border-collapse:collapse;min-width:650px}.customer-table th{text-align:left;background:#f5f8f6;color:#809087;font-size:8px;font-weight:500;padding:9px 8px}.customer-table td{border-top:1px solid #edf1ef;padding:8px;color:#53645c;font-size:8px;vertical-align:middle}.customer-table td small{display:block;color:#9ba69f;font-size:7px;margin-top:3px}.customer-tag{display:inline-block;margin:1px 2px 1px 0;padding:3px 5px;border-radius:3px;background:#eaf3ed;color:#478064;font-size:7px;white-space:nowrap}.note-input{width:125px;height:24px;border:1px solid #e0e7e3;border-radius:3px;padding:0 5px;font-size:8px;color:#55655e}.muted{color:#a2aca6}.no-customers{text-align:center!important;padding:28px!important;color:#9aa69f!important}.customer-popover{position:fixed;z-index:9;right:18px;top:54px;width:min(290px,calc(100vw - 24px));padding:13px;background:#fff;color:#34483e;border:1px solid #cbd9d0;border-radius:6px;box-shadow:0 12px 38px #0008}.customer-popover-head{display:flex;justify-content:space-between;align-items:center;font-size:9px;color:#7c8982}.customer-popover-head button{border:0;background:none;color:#728078;font-size:18px;cursor:pointer}.customer-popover>strong{display:block;font:600 20px Arial,sans-serif;margin:8px 0}.popover-tags{min-height:18px;margin-bottom:8px}.customer-popover>label{display:grid;gap:5px;font-size:8px;color:#74837a}.customer-popover textarea{resize:vertical;border:1px solid #dce5e0;border-radius:4px;padding:6px;font:9px/1.4 inherit;color:#405348}.popover-actions{display:flex;justify-content:flex-end;gap:6px;margin-top:9px}.popover-actions>button:not(.primary-utility){height:28px;padding:0 9px;border:1px solid #dce5e0;background:#fff;color:#62756b;border-radius:4px;font-size:8px;cursor:pointer}.extra-camera-list{display:grid;gap:4px}.control-active{filter:brightness(1.2);outline:1px solid #a5e5bc}@media(max-width:620px){.utility-overlay{padding:8px}.utility-header{height:56px;padding:0 12px}.utility-body{padding:11px}.voice-scene-list{grid-template-columns:1fr}.utility-footer{padding:10px 12px}.customer-toolbar{padding:9px}.bulk-tools{flex-wrap:wrap;padding:5px 9px 9px}.bulk-tools label{width:100%}.customer-table-wrap{max-height:52vh}.customer-card .utility-footer{padding:9px 12px}.customer-popover{right:8px;top:50px}}

.store-quick-actions{position:relative}.refresh-menu{position:absolute;z-index:9;right:0;top:25px;width:174px;padding:5px;background:#fff;border-radius:8px;box-shadow:0 8px 26px #0008;display:grid}.refresh-menu button{height:38px;background:#fff!important;color:#45556b!important;text-align:left;padding:0 12px!important;font-size:12px!important;border-radius:5px}.refresh-menu button:hover{background:#f0f2f7!important}.channel-menu{position:absolute;z-index:5;right:12px;top:34px;bottom:15px;width:min(310px,85%);overflow:auto;background:#fff;border-radius:8px;padding:8px;box-shadow:0 12px 35px #0009;display:flex;flex-direction:column;gap:3px}.channel-menu button{flex:none;min-height:38px;border:0;border-radius:5px;background:#fff;color:#42526a;text-align:left;padding:0 12px;font-size:12px;cursor:pointer}.channel-menu button:hover,.channel-menu button.current-channel{background:#eff1f5}.channel-menu button.current-channel{color:#597af0}.phone-link{height:auto!important;padding:0!important;background:transparent!important;color:#fff!important;text-decoration:underline;font-size:8px!important}.task-history-modal,.mark-modal{position:fixed;inset:0;z-index:12;background:#03081780;display:grid;place-items:center;padding:24px}.history-dialog,.mark-dialog{width:min(1120px,96vw);height:min(760px,90vh);background:#fff;color:#434b57;border-radius:14px;box-shadow:0 20px 70px #0004;overflow:hidden}.history-dialog>header,.mark-dialog>header{height:76px;padding:0 30px;display:flex;align-items:center;justify-content:space-between;font-size:21px;border-bottom:0}.history-dialog>header button,.mark-dialog>header button{border:0;background:none;color:#8b96a9;font-size:23px;cursor:pointer}.history-tabs{height:47px;margin:18px 28px 0;border-bottom:2px solid #e7eaf0;display:flex;gap:34px}.history-tabs button{position:relative;border:0;background:none;color:#50545c;font-size:14px;cursor:pointer}.history-tabs button.selected{color:#597af0}.history-tabs button.selected:after{content:"";position:absolute;bottom:-2px;left:0;right:0;height:3px;background:#6480ff}.history-content{height:calc(100% - 150px);display:grid;place-content:center;justify-items:center;gap:14px;color:#a4a7ad;font-size:15px;overflow:auto;padding:20px}.history-content:has(.record-row){display:block;padding:20px 30px}.record-row{display:grid;grid-template-columns:1fr 1fr 1fr;padding:15px;border-bottom:1px solid #edf0f4;color:#59677a;font-size:12px}.record-row span{color:#34475d}.history-content label{display:grid;gap:5px;color:#667484;font-size:11px}.history-content input{padding:7px;border:1px solid #d9e0e8;border-radius:5px}.history-content>button{height:32px;padding:0 18px;background:#607fff;border:0;color:#fff;border-radius:5px;cursor:pointer}.playback-placeholder{color:#758496}.mark-dialog{height:min(590px,88vh);padding:0 22px}.mark-dialog>header{height:78px;padding:0}.mark-groups{display:grid;grid-template-columns:1fr 1fr 1fr;gap:13px 20px;align-items:center;padding:7px 0 14px}.mark-group{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.mark-group>b{font-size:13px;color:#68717d}.mark-group label,.behavior-tags label{display:flex;align-items:center;gap:5px;color:#737c87;font-size:12px;white-space:nowrap}.mark-dialog input[type=checkbox]{width:15px;height:15px;accent-color:#6682ff}.behavior-tags{grid-column:1/-1;border:1px solid #dce2e9;border-radius:5px;padding:14px;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:15px 9px}.mark-dialog>textarea{display:block;width:100%;height:92px;resize:vertical;border:1px solid #d8e0e8;border-radius:8px;padding:10px;font-size:12px;color:#495764}.mark-footer{height:76px;display:flex;align-items:center;justify-content:flex-end;gap:12px;color:#6983ed;font-size:11px}.mark-footer button{height:36px;padding:0 20px;border:1px solid #d8e1ed;border-radius:7px;background:#fff;color:#6983ed;cursor:pointer}.mark-footer .primary-mark{background:#6280fa;color:#fff;border-color:#6280fa}@media(max-width:700px){.task-history-modal,.mark-modal{padding:8px}.history-dialog,.mark-dialog{width:100%;height:92vh;border-radius:9px}.history-dialog>header,.mark-dialog>header{height:58px;padding:0 14px;font-size:15px}.history-tabs{margin:8px 12px 0;height:40px;gap:14px}.history-tabs button{font-size:10px}.mark-dialog{padding:0 12px}.mark-groups{grid-template-columns:1fr;gap:9px}.behavior-tags{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.mark-group label,.behavior-tags label{font-size:10px}.mark-dialog>textarea{height:76px}}

/* Keep the refresh popover options horizontal instead of inheriting the 27px toolbar button width. */
.store-quick-actions .refresh-menu {
  grid-template-columns: 1fr;
  gap: 2px;
}
.store-quick-actions .refresh-menu button {
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  white-space: nowrap;
  line-height: 1;
  writing-mode: horizontal-tb;
}

/* Six-task view: always fit two columns and three complete rows inside the viewport. */
.task-grid,
.task-grid.density-six {
  width: 100%;
  max-width: 100vw;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.task-grid.density-six {
  overflow-x: hidden;
}

.task-grid.density-six .task-cell {
  width: 100%;
  min-width: 0;
}

.task-grid.density-six .task-cell.live-cell {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: 22px minmax(0, 1fr) 22px;
}

.task-grid.density-six .store-strip {
  min-width: 0;
  gap: 3px;
  padding: 0 4px;
}

.task-grid.density-six .store-title {
  max-width: 34%;
  font-size: 7px;
}

.task-grid.density-six .store-mark {
  width: 120px;
  max-width: 25%;
  height: 17px;
  font-size: 7px;
}

.task-grid.density-six .store-quick-actions { gap: 2px; }
.task-grid.density-six .store-quick-actions > button {
  width: 20px;
  height: 17px;
  padding: 0;
  font-size: 7px;
}

.task-grid.density-six .camera-info {
  top: 3px;
  left: 3px;
  right: 3px;
  gap: 2px;
  font-size: 6px;
}

.task-grid.density-six .camera-info b {
  padding: 2px 3px;
  margin-right: 2px;
}

.task-grid.density-six .camera-time {
  top: 20px;
  left: 34px;
  font-size: 6px;
}

.task-grid.density-six .camera.second-camera .camera-time {
  right: 3px;
  bottom: 3px;
}

.task-grid.density-six .camera-bottom-tools {
  left: 4px;
  bottom: 4px;
  gap: 3px;
}

.task-grid.density-six .camera-bottom-tools button {
  padding: 3px 5px;
  border-radius: 3px;
  font-size: 6px;
}

.task-grid.density-six .camera-switch-label {
  right: 3px;
  top: 3px;
  max-width: 58%;
  overflow: hidden;
  padding: 3px 4px;
  font-size: 6px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-grid.density-six .device-lines {
  left: 5px;
  top: 27px;
  gap: 2px;
  font-size: 6px;
}

.task-grid.density-six .device-lines > span:not(.maglock-state) { display: none; }
.task-grid.density-six .device-lines .maglock-state { padding: 1px 3px; }
.task-grid.density-six .maglock-state .maglock-led { width: 5px; height: 5px; }

.task-grid.density-six .camera-mid-tools {
  bottom: 16px !important;
  gap: 3px;
}

.task-grid.density-six .camera-mid-tools button {
  width: 31px;
  height: 31px;
  font-size: 10px;
}

.task-grid.density-six .camera-mid-tools button small { font-size: 5px; }
.task-grid.density-six .speech-caption { display: none; }

.task-grid.density-six .task-status {
  min-width: 0;
  padding: 0 3px;
  font-size: 6px;
}

.task-grid.density-six .status-left {
  min-width: 0;
  max-width: 42%;
  gap: 2px;
  overflow: hidden;
  font-size: 6px;
}

.task-grid.density-six .status-left .entry-count { display: none; }
.task-grid.density-six .task-status .status-actions { gap: 2px; }
.task-grid.density-six .task-status .status-actions button {
  height: 16px;
  padding: 0 4px;
  font-size: 5px;
}

.task-grid.density-six .task-status .footer-door-button {
  min-width: 44px;
  height: 17px;
  font-size: 6px;
}

.task-grid.density-six .stopped-content { gap: 5px; padding: 6px; }
.task-grid.density-six .stopped-content strong { font-size: 9px; }
.task-grid.density-six .stopped-content p { font-size: 6px; }
.task-grid.density-six .stopped-actions button { height: 21px; padding: 0 7px; font-size: 6px; }

@media (max-width: 760px) {
  .task-grid.density-six .store-mark,
  .task-grid.density-six .status-left { display: none; }
  .task-grid.density-six .store-title { max-width: 55%; }
  .task-grid.density-six .task-status { justify-content: flex-end; }
}
