:root {
  --bg: #0b1220;
  --bg-2: #0f172a;
  --surface: rgba(15, 23, 42, 0.92);
  --surface-2: rgba(17, 24, 39, 0.96);
  --surface-3: rgba(10, 17, 32, 0.84);
  --line: rgba(148, 163, 184, 0.16);
  --line-strong: rgba(214, 187, 24, 0.34);
  --text: #e5edf7;
  --muted: #98a7bd;
  --muted-2: #74849d;
  --brand: #d6bb18;
  --brand-soft: rgba(214, 187, 24, 0.14);
  --accent: #38bdf8;
  --ok: #22c55e;
  --warn: #f59e0b;
  --danger: #ef4444;
  --ok-bg: rgba(34, 197, 94, 0.14);
  --warn-bg: rgba(245, 158, 11, 0.16);
  --danger-bg: rgba(239, 68, 68, 0.16);
  --info-bg: rgba(56, 189, 248, 0.14);
  --shadow-soft: 0 18px 40px rgba(2, 6, 23, 0.34);
  --shadow-hard: 0 26px 80px rgba(2, 6, 23, 0.5);
  --radius: 18px;
  --radius-lg: 24px;
  --radius-sm: 14px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  width: 100%;
  background:
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.08), transparent 24%),
    radial-gradient(circle at top left, rgba(214, 187, 24, 0.08), transparent 22%),
    linear-gradient(180deg, #0b1220, #111827 48%, #0b1220);
  color: var(--text);
  font-family: "Aptos", "Segoe UI Variable", "Trebuchet MS", sans-serif;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
code { font-family: "Cascadia Mono", "Consolas", monospace; font-size: 13px; }
img,
video {
  max-width: 100%;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: max(18px, env(safe-area-inset-top)) 16px max(18px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 14px;
  background:
    linear-gradient(180deg, rgba(11, 18, 32, 0.98), rgba(11, 18, 32, 0.92)),
    radial-gradient(circle at top, rgba(214, 187, 24, 0.08), transparent 28%);
  border-right: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.content {
  min-width: 0;
  padding: max(18px, env(safe-area-inset-top)) 20px max(22px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.content-appbar,
.brand-card,
.profile-card,
.panel,
.stat-card,
.login-panel,
.list-card,
.notification-popover,
.account-popover,
.camera-fold,
.recorder-fold {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.04), transparent 28%),
    linear-gradient(180deg, var(--surface), var(--surface-2));
  box-shadow: var(--shadow-soft);
}

.content-appbar {
  position: sticky;
  top: 10px;
  z-index: 12;
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  backdrop-filter: blur(12px);
}

.content-appbar__main {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.content-appbar__eyebrow {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.content-appbar__title {
  font-size: 20px;
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: .01em;
}

.content-appbar__meta {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.content-appbar__side {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  align-items: center;
}

.notification-menu,
.account-menu {
  position: relative;
}

.notification-menu summary,
.account-menu summary {
  list-style: none;
}

.notification-menu summary::-webkit-details-marker,
.account-menu summary::-webkit-details-marker {
  display: none;
}

.is-hidden {
  display: none !important;
}

.shell-pill,
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(214, 187, 24, 0.24);
  background: rgba(214, 187, 24, 0.1);
  color: #f7e79a;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .03em;
}

.shell-pill--accent {
  border-color: rgba(56, 189, 248, 0.24);
  background: rgba(56, 189, 248, 0.12);
  color: #b9ebff;
}

.shell-pill--warning {
  border-color: rgba(245, 158, 11, 0.28);
  background: rgba(245, 158, 11, 0.14);
  color: #fde68a;
}

.notification-chip,
.account-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
  cursor: pointer;
}

.notification-chip:hover,
.account-chip:hover {
  transform: translateY(-1px);
  border-color: rgba(214, 187, 24, 0.28);
  background: rgba(255, 255, 255, 0.07);
}

.notification-menu[open] .notification-chip,
.account-menu[open] .account-chip {
  border-color: rgba(214, 187, 24, 0.28);
  background: rgba(255, 255, 255, 0.08);
}

.notification-chip {
  position: relative;
}

.notification-chip__icon {
  width: 22px;
  height: 22px;
  color: var(--text);
}

.notification-chip__icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.notification-chip__badge {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ef4444, #f97316);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 18px rgba(239, 68, 68, 0.4);
}

.account-chip__avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(214, 187, 24, 0.94), rgba(56, 189, 248, 0.72));
  color: #08111e;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .08em;
  overflow: hidden;
}

.account-chip__avatar img,
.account-popover__avatar img,
.profile-hero__avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.account-chip__avatar--logo,
.account-popover__avatar.account-chip__avatar--logo,
.profile-hero__avatar.account-chip__avatar--logo {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.notification-popover,
.account-popover {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(320px, calc(100vw - 32px));
  padding: 16px;
  display: grid;
  gap: 14px;
  z-index: 30;
  max-height: min(78vh, 720px);
  overflow: auto;
}

.notification-popover {
  display: grid;
  gap: 12px;
}

.notification-popover__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.notification-popover__title {
  font-size: 15px;
  font-weight: 900;
}

.notification-popover__meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.notification-popover__list {
  display: grid;
  gap: 8px;
  max-height: 360px;
  overflow: auto;
  padding-right: 2px;
}

.notification-empty {
  padding: 16px;
  border-radius: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.08);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
  font-size: 13px;
}

.notification-item {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}

.notification-item:hover {
  transform: translateY(-1px);
  border-color: rgba(214, 187, 24, 0.24);
  background: rgba(255, 255, 255, 0.07);
}

.notification-item--unread {
  border-color: rgba(214, 187, 24, 0.22);
  background: rgba(214, 187, 24, 0.08);
}

.notification-item__title {
  font-size: 13px;
  font-weight: 900;
  line-height: 1.35;
}

.notification-item__body,
.notification-item__meta {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.notification-popover__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}

.notification-popover__footer a:hover {
  color: var(--text);
}

.link-button {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.link-button:hover {
  color: #f7e79a;
}

.account-popover__header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.account-popover__avatar {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(214, 187, 24, 0.94), rgba(56, 189, 248, 0.72));
  color: #08111e;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: .08em;
  overflow: hidden;
}

.account-popover__name {
  font-size: 15px;
  font-weight: 900;
  line-height: 1.3;
}

.account-popover__meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.account-popover__links {
  display: grid;
  gap: 8px;
}

.account-popover__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 14px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  font-weight: 800;
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}

.account-popover__link:hover {
  transform: translateY(-1px);
  border-color: rgba(214, 187, 24, 0.24);
  background: rgba(255, 255, 255, 0.07);
}

.account-popover__logout {
  margin: 0;
}

.brand-card {
  padding: 14px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.brand-icon,
.brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
}

.hero-dashboard-slim {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, .9fr);
  gap: 18px;
  align-items: start;
}

.hero-dashboard-slim__main {
  display: grid;
  gap: 12px;
}

.hero-dashboard-slim__side {
  min-width: 0;
}

.dashboard-priority-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px;
}

.dashboard-priority-card {
  padding: 16px 18px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background:
    radial-gradient(circle at top left, rgba(56, 189, 248, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(8, 13, 24, 0.98));
  display: grid;
  gap: 8px;
  min-width: 0;
}

.dashboard-priority-card--interactive {
  border-color: rgba(214, 187, 24, 0.16);
}

.dashboard-priority-card__action {
  appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  background: none;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font-size: 22px;
  line-height: 1.1;
  font-weight: 900;
}

.dashboard-priority-card__action:hover {
  color: var(--accent);
}

.dashboard-priority-card__label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.dashboard-priority-card__value {
  font-size: 22px;
  line-height: 1.1;
  font-weight: 900;
}

.dashboard-priority-card__note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.dashboard-photo-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.dashboard-photo-fact {
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(255, 255, 255, 0.03);
}

.dashboard-photo-fact span {
  display: block;
  margin-bottom: 5px;
  color: rgba(148, 163, 184, 0.84);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.dashboard-photo-fact strong {
  display: block;
  color: #f8fafc;
  font-size: 15px;
  line-height: 1.35;
}

.dashboard-quick-strip .panel-header {
  margin-bottom: 8px;
}

.dashboard-quick-strip .button-row {
  gap: 10px;
}

.dashboard-ops-band {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) repeat(3, minmax(180px, 1fr));
  gap: 12px;
}

.dashboard-ops-card {
  padding: 16px 18px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.04), transparent 28%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.95), rgba(8, 13, 24, 0.98));
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 10px;
}

.dashboard-ops-card--primary {
  background:
    radial-gradient(circle at top left, rgba(214, 187, 24, 0.12), transparent 24%),
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(8, 13, 24, 1));
}

.dashboard-ops-card__eyebrow {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.dashboard-ops-card h2,
.dashboard-ops-card strong {
  margin: 0;
  font-size: 24px;
  line-height: 1.05;
}

.dashboard-ops-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.stats-grid--compact {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.compact-feed {
  display: grid;
  gap: 10px;
}

.compact-feed__item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}

.compact-feed__item:hover {
  transform: translateY(-1px);
  border-color: rgba(214, 187, 24, 0.24);
  background: rgba(255, 255, 255, 0.07);
}

.compact-feed__main {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.compact-feed__title {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.35;
}

.compact-feed__meta,
.compact-feed__hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.compact-feed__side {
  display: grid;
  gap: 6px;
  justify-items: end;
  text-align: right;
}

.health-feed {
  display: grid;
  gap: 12px;
}

.health-item {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
}

.health-item__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.health-item__title {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.35;
}

.health-item__meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.health-item__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1.5;
}

.health-item__facts span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.health-item__issues {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.health-issue {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.health-issue--ok {
  color: #bbf7d0;
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.28);
}

.health-issue--warning {
  color: #fde68a;
  background: rgba(245, 158, 11, 0.14);
  border-color: rgba(245, 158, 11, 0.3);
}

.health-issue--danger {
  color: #fecaca;
  background: rgba(239, 68, 68, 0.14);
  border-color: rgba(239, 68, 68, 0.3);
}

.detail-list {
  display: grid;
  gap: 10px;
}

.detail-list__item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
}

.detail-list__item strong {
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
  letter-spacing: .04em;
  text-transform: uppercase;
}

.detail-list__item span {
  flex: 1 1 auto;
  text-align: right;
  font-size: 13px;
  line-height: 1.45;
  color: var(--text);
}

.device-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.device-strip__item {
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
  display: grid;
  gap: 6px;
}

.device-strip__item span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.device-strip__item strong {
  font-size: 14px;
  line-height: 1.35;
}

.device-section {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  margin-top: 12px;
  overflow: hidden;
}

.device-section__summary {
  list-style: none;
  padding: 14px 16px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
}

.device-section__summary::-webkit-details-marker {
  display: none;
}

.device-section__summary strong {
  display: block;
  font-size: 14px;
  line-height: 1.35;
}

.device-section__summary span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.device-section__meta {
  white-space: nowrap;
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
}

.device-section__body {
  padding: 0 16px 16px;
}

.compact-table-wrap table {
  min-width: 640px;
}

.toggle-field {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.toggle-field input {
  margin-top: 2px;
}

.settings-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.settings-toggle__copy {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.settings-toggle__copy strong {
  font-size: 14px;
  line-height: 1.35;
}

.settings-toggle__copy small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.settings-toggle__switch {
  position: relative;
  flex: 0 0 auto;
}

.settings-toggle__switch input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.settings-toggle__slider {
  width: 56px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 4px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.22);
  border: 1px solid rgba(148, 163, 184, 0.18);
  transition: background .16s ease, border-color .16s ease;
}

.settings-toggle__slider::after {
  content: "";
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 6px 14px rgba(2, 6, 23, 0.34);
  transition: transform .16s ease;
}

.settings-toggle__switch input:checked + .settings-toggle__slider {
  background: rgba(214, 187, 24, 0.34);
  border-color: rgba(214, 187, 24, 0.28);
}

.settings-toggle__switch input:checked + .settings-toggle__slider::after {
  transform: translateX(24px);
}

.notification-settings-note {
  margin-top: 14px;
  padding: 14px;
  border-radius: 16px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.16);
  color: #c5efff;
  font-size: 13px;
  line-height: 1.5;
}

.settings-summary-grid,
.company-overview__stats,
.profile-stat-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.settings-summary-card,
.company-stat-card,
.profile-stat-chip {
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.04), transparent 26%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(8, 13, 24, 0.98));
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 6px;
}

.settings-summary-card strong,
.company-stat-card strong,
.profile-stat-chip strong {
  font-size: 20px;
  line-height: 1.1;
}

.settings-summary-card span,
.company-stat-card span,
.profile-stat-chip span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 800;
}

.settings-action-row {
  padding-top: 6px;
}

.surface-list {
  display: grid;
  gap: 10px;
}

.brand-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.26), transparent 48%),
    linear-gradient(135deg, rgba(214, 187, 24, 0.92), rgba(125, 211, 252, 0.48));
  color: #0b1220;
  font-weight: 900;
  letter-spacing: .08em;
}

.brand-logo {
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.brand-logo--site {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  background: #020202;
  object-fit: contain;
  padding: 6px;
}

.brand-title {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.3;
}

.hero-logo {
  width: min(100%, 280px);
  height: auto;
  display: block;
  margin-bottom: 8px;
  filter: drop-shadow(0 18px 40px rgba(245, 179, 0, 0.16));
}

.brand-subtitle {
  margin-top: 4px;
  font-size: 14px;
  line-height: 1.35;
  color: var(--text);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.profile-card { padding: 16px; }
.profile-name { font-size: 16px; font-weight: 900; }
.profile-meta { margin-top: 6px; color: var(--muted); font-size: 13px; line-height: 1.45; }

.profile-hero {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.profile-hero__avatar {
  width: 56px;
  height: 56px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(214, 187, 24, 0.94), rgba(56, 189, 248, 0.72));
  color: #08111e;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: .08em;
  overflow: hidden;
}

.profile-hero__name {
  font-size: 16px;
  font-weight: 900;
}

.profile-hero__meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.profile-panel-actions {
  margin-top: 14px;
}

.profile-overview,
.company-overview {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}

.profile-overview__hero,
.company-overview__hero {
  display: grid;
  gap: 14px;
}

.profile-hero--large {
  padding: 18px;
  gap: 16px;
}

.profile-hero--large .profile-hero__avatar {
  width: 72px;
  height: 72px;
}

.profile-stat-chip {
  min-width: 0;
}

.company-overview__brand {
  display: grid;
  grid-template-columns: minmax(88px, 112px) minmax(0, 1fr);
  gap: 16px;
  align-items: center;
}

.company-overview__logo {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(8, 13, 24, 0.98));
  overflow: hidden;
}

.company-overview__logo .logo-preview {
  width: 100%;
  height: 100%;
  min-height: 88px;
  object-fit: cover;
  border: 0;
  border-radius: 0;
}

.company-overview__logo-empty {
  color: var(--brand);
  font-size: 24px;
  font-weight: 900;
  letter-spacing: .08em;
}

.company-overview__copy {
  display: grid;
  gap: 6px;
}

.company-overview__eyebrow {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.company-overview__copy h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.08;
}

.company-overview__copy p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.menu {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.menu-item {
  padding: 11px 13px;
  border-radius: 14px;
  color: var(--muted);
  font-weight: 800;
  border: 1px solid transparent;
  transition: transform .16s ease, border-color .16s ease, background .16s ease, color .16s ease;
}

.menu-item:hover {
  transform: translateX(2px);
  color: var(--text);
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.menu-item.active {
  color: #f8f1bf;
  border-color: rgba(214, 187, 24, 0.26);
  background:
    linear-gradient(90deg, rgba(214, 187, 24, 0.16), rgba(214, 187, 24, 0.04)),
    rgba(255, 255, 255, 0.02);
  box-shadow: inset 3px 0 0 rgba(214, 187, 24, 0.9);
}

.hero,
.panel { padding: 18px; }

.hero {
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(214, 187, 24, 0.16), transparent 26%),
    radial-gradient(circle at bottom left, rgba(56, 189, 248, 0.12), transparent 32%),
    linear-gradient(140deg, rgba(11, 18, 32, 0.98), rgba(15, 23, 42, 0.95));
  border: 1px solid rgba(214, 187, 24, 0.14);
  box-shadow: var(--shadow-hard);
}

.hero.compact { padding: 16px 18px; }
.hero h1 { margin: 10px 0 8px; font-size: clamp(28px, 3vw, 38px); line-height: 1.02; letter-spacing: -.03em; }
.hero p { margin: 0; color: #c7d3e4; max-width: 860px; line-height: 1.72; }

.hero-dashboard { overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.9fr); gap: 18px; }
.hero-main { display: flex; flex-direction: column; gap: 18px; }
.hero-rail { display: grid; gap: 12px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.photo-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 18px;
}

.photo-card {
  overflow: hidden;
  border-radius: 0;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(6, 10, 18, 0.98), rgba(10, 15, 27, 0.98));
  box-shadow: var(--shadow-soft);
}

.photo-card__media {
  display: block;
  aspect-ratio: 16 / 10;
  background: #000;
  position: relative;
}

.photo-card__media-button {
  width: 100%;
  padding: 0;
  border: 0;
  cursor: zoom-in;
}

.photo-card__media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .24s ease;
}

.photo-card__badges {
  position: absolute;
  left: 12px;
  top: 12px;
  right: 12px;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
  pointer-events: none;
}

.photo-card__badge {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 8px 10px;
  background: rgba(2, 6, 23, 0.82);
  border: 1px solid rgba(214, 187, 24, 0.26);
  color: #f8e58d;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  pointer-events: none;
}

.photo-card__badge--secondary {
  background: rgba(6, 95, 70, 0.78);
  border-color: rgba(52, 211, 153, 0.28);
  color: #d1fae5;
}

.photo-card:hover .photo-card__media img {
  transform: scale(1.02);
}

.photo-card__body {
  display: grid;
  gap: 10px;
  padding: 14px 15px 15px;
}

.photo-card__title {
  font-size: 16px;
  font-weight: 900;
  line-height: 1.25;
}

.photo-card__meta {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.photo-card .button-row {
  gap: 8px;
}

.photo-card .table-action-link {
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.photo-card .table-action-link--primary {
  background: rgba(214, 187, 24, 0.12);
  border-color: rgba(214, 187, 24, 0.24);
}

.photo-dialog {
  width: min(820px, 100%);
}

.photo-dialog__media {
  overflow: hidden;
  border-radius: 0;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: #000;
}

.photo-dialog__media img {
  width: 100%;
  max-height: 62vh;
  display: block;
  object-fit: contain;
  background: #020617;
}

.range-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 16px;
}

.range-chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  transition: transform .16s ease, border-color .16s ease, background .16s ease, color .16s ease;
}

.range-chip:hover {
  transform: translateY(-1px);
  border-color: rgba(214, 187, 24, 0.24);
  color: var(--text);
}

.range-chip--active {
  border-color: rgba(214, 187, 24, 0.3);
  background: rgba(214, 187, 24, 0.12);
  color: #f7e79a;
}

.metric-chip-row { display: flex; flex-wrap: wrap; gap: 12px; }
.metric-chip {
  min-width: 160px;
  padding: 14px 16px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
}

.metric-chip strong { display: block; font-size: 23px; line-height: 1.05; }
.metric-chip span { display: block; margin-top: 6px; color: #b4c3d8; font-size: 13px; }

.insight-card {
  padding: 16px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 18px 40px rgba(2, 6, 23, 0.24);
}

.insight-label {
  display: block;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: #b9c7da;
}

.insight-card strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
  line-height: 1.08;
}

.insight-card p {
  margin: 8px 0 0;
  color: #c7d3e4;
  line-height: 1.6;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.stat-card {
  padding: 16px;
  border-radius: 22px;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--brand), rgba(214, 187, 24, 0));
  opacity: .9;
}

.stat-label { color: var(--muted); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.stat-value { margin-top: 10px; font-size: clamp(28px, 3vw, 34px); font-weight: 900; line-height: 1; letter-spacing: -.04em; }
.stat-note { margin-top: 10px; color: var(--muted); font-size: 13px; line-height: 1.5; }

.panel-grid.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.panel-grid.two-col > * {
  min-width: 0;
}

.panel-header { margin-bottom: 16px; }
.panel-header h2 { margin: 0 0 6px; font-size: 20px; line-height: 1.2; }
.panel-header p { margin: 0; color: var(--muted); line-height: 1.55; }
.panel-header.between,
.between { display: flex; justify-content: space-between; gap: 14px; align-items: center; }

.list-stack,
.chart-stack { display: grid; gap: 12px; }

.list-row,
.list-card,
.activity-row {
  border-radius: 18px;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.03), transparent 26%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.84), rgba(11, 18, 32, 0.96));
}

.list-row,
.list-card {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  color: var(--muted);
}

.list-card {
  flex-direction: column;
  align-items: flex-start;
}

.list-card span,
.list-row span,
.table-subtext {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.list-card strong,
.list-row strong,
.activity-title { color: var(--text); }

.client-card-link { transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.client-card-link:hover {
  transform: translateY(-2px);
  border-color: rgba(214, 187, 24, 0.28);
  box-shadow: 0 20px 34px rgba(2, 6, 23, 0.32);
}

.link-hint { color: #f2de77; font-weight: 800; }
.muted-link { color: #8adfff; text-decoration: underline; }

.chart-row {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) 70px;
  gap: 12px;
  align-items: center;
}

.chart-label,
.chart-value { font-size: 14px; }
.chart-value { color: var(--text); font-weight: 800; text-align: right; }

.chart-bar {
  height: 12px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.14);
  overflow: hidden;
}

.chart-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), #facc15);
  box-shadow: 0 0 18px rgba(214, 187, 24, 0.24);
}

.signal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.signal-card {
  padding: 14px 15px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.96), rgba(11, 18, 32, 0.92));
}

.signal-card span { display: block; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.signal-card strong { display: block; margin-top: 8px; font-size: 20px; line-height: 1.2; }

.activity-list { display: grid; gap: 12px; }

.activity-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  padding: 15px 16px;
}

.activity-main { min-width: 0; display: grid; gap: 6px; }
.activity-title { font-size: 15px; font-weight: 900; line-height: 1.4; }
.activity-meta { color: var(--muted); font-size: 13px; line-height: 1.55; }

.camera-live-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.monitoring-select-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
}

.monitoring-selection-tools {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
}

.monitoring-selection-search {
  display: grid;
  gap: 8px;
  max-width: 520px;
}

.monitoring-selection-search span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.monitoring-selection-search input {
  width: 100%;
}

.monitoring-selection-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.monitoring-selection-filters .btn.is-active {
  border-color: rgba(214, 187, 24, 0.34);
  background: rgba(214, 187, 24, 0.14);
  color: #f7e79a;
}

.monitoring-selection-bulk {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
}

.monitoring-selection-bulk strong {
  font-size: 13px;
  line-height: 1.45;
}

[data-monitor-chip][hidden] {
  display: none !important;
}

.monitoring-select-chip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
}

.monitoring-select-chip input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--brand);
}

.monitoring-select-chip__copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.monitoring-select-chip__copy strong {
  font-size: 14px;
  line-height: 1.35;
  color: var(--text);
}

.monitoring-select-chip__copy small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.monitoring-select-chip__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  grid-column: 1 / -1;
}

.monitoring-select-chip--visual {
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 12px;
}

.monitoring-select-chip__preview {
  grid-column: 1 / -1;
  width: 100%;
  height: 220px;
  overflow: hidden;
  border-radius: 0;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: #020617;
}

.monitoring-select-chip__preview img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.monitoring-select-chip__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  text-align: center;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  line-height: 1.5;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.9), rgba(15, 23, 42, 0.92));
}

.monitoring-select-chip__state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
}

.monitoring-select-chip--visual input {
  grid-column: 1;
  grid-row: 1;
}

.monitoring-select-chip--visual .monitoring-select-chip__copy {
  grid-column: 2;
  grid-row: 1;
  align-self: center;
}

.monitoring-select-chip.is-selected {
  border-color: rgba(214, 187, 24, 0.28);
  background: rgba(214, 187, 24, 0.08);
}

.monitoring-select-chip.is-selected .monitoring-select-chip__state {
  color: #f7e79a;
  border-color: rgba(214, 187, 24, 0.24);
  background: rgba(214, 187, 24, 0.12);
}

.monitoring-toolbar {
  margin-top: 12px;
}

.monitoring-selected-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.monitoring-layout-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.monitoring-layout-card {
  padding: 16px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(8, 13, 24, 0.96);
  display: grid;
  gap: 10px;
}

.monitoring-layout-card.is-active {
  border-color: rgba(214, 187, 24, 0.28);
  box-shadow: 0 18px 34px rgba(214, 187, 24, 0.08);
}

.monitoring-layout-card__eyebrow {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.monitoring-layout-card h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.1;
}

.monitoring-layout-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.subsection-block {
  display: grid;
  gap: 14px;
}

.subsection-block + .subsection-block {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.subsection-block__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.subsection-block__header h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
}

.monitoring-recorder-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.device-subdetails {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.device-subdetails summary {
  cursor: pointer;
  padding: 12px 14px;
  font-weight: 700;
}

.device-subdetails .monitoring-layout-grid {
  padding: 0 14px 14px;
}

.monitoring-layout-save {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: end;
  padding-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.monitoring-layout-save label {
  flex: 1 1 260px;
  display: grid;
  gap: 6px;
}

.monitoring-layout-save label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.monitoring-layout-save input {
  width: 100%;
}

.monitoring-ready-strip {
  display: grid;
  gap: 12px;
}

.monitoring-ready-strip__summary {
  display: grid;
  gap: 4px;
}

.monitoring-ready-strip__summary strong {
  font-size: 18px;
  line-height: 1.1;
}

.monitoring-ready-strip__summary span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.inline-form {
  margin: 0;
}

.monitoring-selected-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
}

.monitoring-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
}

.monitoring-tile {
  padding: 14px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at top left, rgba(56, 189, 248, 0.08), transparent 24%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.94), rgba(8, 13, 24, 0.98));
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 12px;
}

.monitoring-tile__head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}

.monitoring-tile__head h2 {
  margin: 6px 0 4px;
  font-size: 18px;
  line-height: 1.15;
}

.monitoring-tile__head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.monitoring-tile__eyebrow {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.monitoring-tile__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.monitoring-stage {
  position: relative;
  width: 100%;
  display: block;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0;
  background: #020617;
  aspect-ratio: 16 / 9;
  cursor: default;
}

.monitoring-stage__video,
.monitoring-stage__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.monitoring-stage__empty {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-align: center;
  color: #d7e6f7;
  font-size: 13px;
  line-height: 1.5;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.36));
}

.monitoring-stage__overlay {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.66);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.monitoring-tile__toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.monitoring-tile__meta {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}


.anpr-review-list {
  display: grid;
  gap: 16px;
}

.anpr-review-card {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  gap: 16px;
  padding: 16px;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.04), transparent 28%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.94), rgba(9, 14, 25, 0.98));
  box-shadow: var(--shadow-soft);
}

.anpr-review-card__visual {
  min-height: 220px;
  background: #0f172a;
  overflow: hidden;
  border-radius: 18px;
}

.anpr-review-card__visual img,
.anpr-review-card__visual-empty {
  width: 100%;
  height: 100%;
  display: block;
}

.anpr-review-card__visual img {
  object-fit: cover;
}

.anpr-review-card__visual-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 700;
}

.anpr-review-card__copy {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.anpr-review-card__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
}

.anpr-review-card__head h3 {
  margin: 4px 0 6px;
  font-size: 28px;
  line-height: 1.05;
}

.anpr-review-card__head p,
.anpr-review-card__eyebrow {
  margin: 0;
}

.anpr-review-card__eyebrow {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.anpr-review-card__head p {
  color: var(--muted);
}

.anpr-review-card__badges,
.anpr-review-card__facts,
.history-plate-chip-row,
.history-timeline__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.anpr-review-card__facts span,
.history-timeline__facts span {
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #d7e6f7;
  font-size: 12px;
  line-height: 1.35;
}

.anpr-review-form {
  display: grid;
  grid-template-columns: minmax(180px, 220px) minmax(0, 1fr);
  gap: 12px;
}

.anpr-review-form .button-row {
  grid-column: 1 / -1;
}

.history-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
}

.history-photo-card {
  display: grid;
  gap: 8px;
  text-decoration: none;
  color: inherit;
}

.history-photo-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  display: block;
  object-fit: cover;
  border-radius: 0;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.history-photo-card span {
  font-size: 12px;
  color: var(--muted);
}

.history-timeline {
  display: grid;
  gap: 12px;
}

.history-timeline__item {
  display: grid;
  grid-template-columns: 144px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.04), transparent 28%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.94), rgba(9, 14, 25, 0.98));
}

.history-timeline__thumb {
  width: 144px;
  aspect-ratio: 4 / 3;
  border-radius: 14px;
  object-fit: cover;
  background: #0f172a;
}

.history-timeline__thumb--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.82);
  font-weight: 700;
}

.history-timeline__copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.history-timeline__head {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.history-timeline__meta {
  color: var(--muted);
  font-size: 13px;
}

.history-timeline__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.camera-fold-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.camera-live-card {
  padding: 16px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.04), transparent 26%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.92), rgba(11, 18, 32, 0.98));
  box-shadow: var(--shadow-soft);
  min-width: 0;
  overflow: hidden;
}

.camera-live-card__head {
  align-items: flex-start;
  margin-bottom: 12px;
}

.camera-live-card__head h3 {
  margin: 0 0 6px;
  font-size: 17px;
  line-height: 1.2;
}

.camera-live-card__head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.camera-fold {
  padding: 14px;
}

.camera-fold + .camera-fold {
  margin-top: 0;
}

.camera-fold__summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
}

.camera-fold__summary::-webkit-details-marker {
  display: none;
}

.camera-fold__summary-side {
  display: grid;
  justify-items: end;
  gap: 8px;
  flex: 0 0 auto;
}

.camera-fold__summary-actions {
  justify-content: flex-end;
}

.camera-fold__toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  border: 1px solid rgba(56, 189, 248, 0.18);
  background: rgba(56, 189, 248, 0.08);
  color: #b9ebff;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .03em;
}

.camera-fold__toggle::before {
  content: "+";
  font-size: 15px;
  line-height: 1;
}

.camera-fold__toggle-open {
  display: none;
}

.camera-fold[open] .camera-fold__toggle::before {
  content: "-";
}

.camera-fold[open] .camera-fold__toggle-closed {
  display: none;
}

.camera-fold[open] .camera-fold__toggle-open {
  display: inline;
}

.camera-fold__body {
  margin-top: 12px;
  display: grid;
  gap: 12px;
}

.camera-fold__content {
  grid-template-columns: minmax(240px, 0.92fr) minmax(0, 1.08fr);
  align-items: start;
  gap: 12px;
}

.device-summary {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(145px, 193px) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.device-summary__visual {
  min-height: 124px;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.device-summary__visual--camera {
  background:
    radial-gradient(circle at 22% 20%, rgba(255, 255, 255, 0.38), transparent 36%),
    linear-gradient(145deg, rgba(248, 250, 252, 0.96), rgba(226, 232, 240, 0.82));
  padding: 0;
  border-radius: 0;
}

.device-summary__visual--has-thumb {
  padding: 0;
  border: none;
  box-shadow: none;
  background: transparent;
}

.device-summary__visual--recorder {
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.08), transparent 28%),
    linear-gradient(145deg, rgba(31, 41, 55, 0.96), rgba(11, 18, 32, 0.96));
}

.device-illustration {
  width: 100%;
  height: auto;
  max-width: 170px;
  display: block;
  filter: drop-shadow(0 16px 24px rgba(2, 6, 23, 0.22));
}

.device-illustration--camera {
  max-width: 132px;
}

.device-illustration--recorder {
  max-width: 156px;
  filter: drop-shadow(0 18px 26px rgba(2, 6, 23, 0.34));
}

.device-summary__thumb {
  width: 100%;
  height: 100%;
  min-height: 124px;
  display: block;
  object-fit: cover;
  border-radius: 0;
  box-shadow: none;
}

.device-summary__copy {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.device-summary__title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.device-summary__eyebrow {
  color: var(--brand);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.device-summary__copy h3 {
  margin: 0;
  font-size: 19px;
  line-height: 1.1;
}

.device-summary__rename {
  flex: 0 0 auto;
}

.device-summary__copy p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.device-summary__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.device-summary__chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 9px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.camera-live-shell {
  width: 100%;
  max-width: 100%;
  padding: 8px;
  border-radius: 18px;
  border: 1px solid rgba(214, 187, 24, 0.12);
  background:
    radial-gradient(circle at top left, rgba(56, 189, 248, 0.1), transparent 26%),
    linear-gradient(180deg, rgba(8, 13, 24, 0.96), rgba(15, 23, 42, 0.92));
  box-shadow: var(--shadow-soft);
}

.camera-live-shell__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.camera-live-shell__label {
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.camera-live-shell__hint {
  color: var(--muted);
  font-size: 11px;
  text-align: right;
}

.camera-live-frame {
  overflow: hidden;
  border-radius: 0;
  border: 1px solid rgba(214, 187, 24, 0.16);
  background: linear-gradient(180deg, rgba(8, 13, 24, 0.96), rgba(15, 23, 42, 0.92));
  aspect-ratio: 16 / 9;
}

.camera-live-frame--compact {
  max-width: 100%;
  min-height: 152px;
}

.camera-live-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.event-image-panel .panel-header p {
  max-width: 520px;
}

.event-image-card {
  width: min(560px, 100%);
  margin: 0 auto;
  padding: 10px;
  border-radius: 0;
}

.event-image-card__image {
  width: 100%;
  height: auto;
  max-height: 360px;
  object-fit: contain;
  background: #000;
}

.camera-live-meta {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.camera-live-actions {
  margin-top: 10px;
}

.camera-edit-panel {
  border-style: solid;
}

.camera-edit-panel__meta {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.03), transparent 24%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.9), rgba(11, 18, 32, 0.98));
}

.recorder-fold {
  padding: 18px;
}

.recorder-fold + .recorder-fold {
  margin-top: 14px;
}

.recorder-fold__summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
}

.recorder-fold__summary::-webkit-details-marker {
  display: none;
}

.recorder-fold__summary-side {
  display: grid;
  justify-items: end;
  gap: 10px;
  flex: 0 0 auto;
}

.recorder-fold__toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  border: 1px solid rgba(214, 187, 24, 0.2);
  background: rgba(214, 187, 24, 0.08);
  color: #f7e79a;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .03em;
}

.recorder-fold__toggle::before {
  content: "+";
  font-size: 15px;
  line-height: 1;
}

.recorder-fold__toggle-open {
  display: none;
}

.recorder-fold[open] .recorder-fold__toggle::before {
  content: "-";
}

.recorder-fold[open] .recorder-fold__toggle-closed {
  display: none;
}

.recorder-fold[open] .recorder-fold__toggle-open {
  display: inline;
}

.recorder-fold__body {
  margin-top: 18px;
  display: grid;
  gap: 18px;
}

table { width: 100%; border-collapse: collapse; min-width: 760px; }
thead { background: rgba(255, 255, 255, 0.03); }
th, td {
  text-align: left;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-size: 11px;
}

tbody tr:hover { background: rgba(255, 255, 255, 0.025); }

.table-subtext {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.table-action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid rgba(214, 187, 24, 0.22);
  color: #f6e588;
  font-weight: 800;
  background: rgba(214, 187, 24, 0.08);
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.table-action-link:hover {
  border-color: rgba(214, 187, 24, 0.36);
  background: rgba(214, 187, 24, 0.14);
  transform: translateY(-1px);
}

.table-action-link--primary {
  border-color: rgba(56, 189, 248, 0.26);
  background: rgba(56, 189, 248, 0.12);
  color: #b9ebff;
}

.table-action-link--primary:hover {
  border-color: rgba(56, 189, 248, 0.4);
  background: rgba(56, 189, 248, 0.18);
}

.recorder-panel-shell {
  position: relative;
  overflow: hidden;
  padding: 14px;
  border-radius: 20px;
  border: 1px solid rgba(71, 85, 105, 0.22);
  background: linear-gradient(180deg, rgba(4, 8, 14, 0.99), rgba(1, 4, 8, 1));
  box-shadow: 0 20px 54px rgba(2, 6, 23, 0.34);
}

.recorder-panel-shell::before {
  display: none;
}

.recorder-panel-shell > * {
  position: relative;
  z-index: 1;
}

.recorder-panel-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(260px, 0.95fr);
  gap: 14px;
  align-items: end;
  margin-bottom: 12px;
}

.recorder-panel-intro__eyebrow {
  display: inline-flex;
  margin-bottom: 6px;
  color: #7dd3fc;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.recorder-panel-intro h2 {
  margin: 0 0 4px;
  font-size: clamp(24px, 2.7vw, 30px);
  line-height: 1.05;
}

.recorder-panel-intro p {
  margin: 0;
  max-width: 70ch;
  color: rgba(203, 213, 225, 0.82);
  line-height: 1.5;
  font-size: 14px;
}

.recorder-panel-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.recorder-panel-kpi {
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(71, 85, 105, 0.22);
  background: rgba(7, 12, 22, 0.9);
}

.recorder-panel-kpi span {
  display: block;
  margin-bottom: 6px;
  color: rgba(148, 163, 184, 0.82);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.recorder-panel-kpi strong {
  display: block;
  color: #f8fafc;
  font-size: 17px;
  line-height: 1.15;
}

.recorder-panel-toolbar {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.recorder-panel-toolbar__group {
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(71, 85, 105, 0.2);
  background: rgba(6, 11, 20, 0.92);
}

.recorder-panel-toolbar__label {
  display: inline-flex;
  margin-bottom: 8px;
  color: rgba(186, 230, 253, 0.84);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.recorder-panel-toolbar__options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.recorder-panel-toolbar__options--presets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
}

.recorder-panel-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(71, 85, 105, 0.24);
  background: rgba(10, 16, 28, 0.74);
  color: #dbeafe;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
  transition: transform 140ms ease, border-color 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.recorder-panel-chip:hover {
  transform: translateY(-1px);
  border-color: rgba(125, 211, 252, 0.34);
  background: rgba(14, 165, 233, 0.16);
  box-shadow: 0 12px 28px rgba(2, 6, 23, 0.22);
}

.recorder-panel-chip--active {
  border-color: rgba(214, 187, 24, 0.34);
  background:
    linear-gradient(180deg, rgba(214, 187, 24, 0.18), rgba(214, 187, 24, 0.1)),
    rgba(15, 23, 42, 0.72);
  color: #fff7d1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.recorder-panel-chip--stacked {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 82px;
  border-radius: 22px;
  text-align: center;
}

.recorder-panel-chip--stacked small {
  display: block;
  margin-top: 5px;
  color: rgba(191, 219, 254, 0.72);
  font-size: 11px;
  font-weight: 600;
}

.recorder-panel-stage {
  padding: 10px;
  border-radius: 16px;
  border: 1px solid rgba(71, 85, 105, 0.18);
  background: rgba(2, 5, 10, 0.96);
  box-shadow: 0 12px 34px rgba(2, 6, 23, 0.18);
}

.recorder-panel-stage__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.recorder-panel-stage__eyebrow {
  color: #facc15;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.recorder-panel-stage__head h3 {
  margin: 4px 0 4px;
  font-size: 18px;
  line-height: 1.1;
}

.recorder-panel-stage__head p {
  margin: 0;
  max-width: 62ch;
  color: rgba(203, 213, 225, 0.82);
  font-size: 12px;
  line-height: 1.45;
}

.recorder-panel-stage__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.recorder-panel-monitor {
  margin-top: 0;
  border-radius: 10px;
  border: 1px solid rgba(71, 85, 105, 0.26);
  background: #000;
  box-shadow: 0 12px 28px rgba(2, 6, 23, 0.2);
  overflow: hidden;
}

.recorder-panel-monitor__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  padding: 4px 6px;
  border-bottom: 1px solid rgba(71, 85, 105, 0.28);
  background: rgba(7, 10, 16, 0.98);
}

.recorder-panel-monitor__status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #f8fafc;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
  white-space: nowrap;
}

.recorder-panel-monitor__dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #ef4444;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.65);
}

.recorder-panel-monitor__meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 4px;
  flex: 1 1 360px;
}

.recorder-panel-monitor__meta span {
  display: inline-flex;
  align-items: center;
  min-height: 21px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid rgba(71, 85, 105, 0.24);
  background: rgba(10, 16, 28, 0.78);
  color: rgba(226, 232, 240, 0.82);
  font-size: 10px;
  font-weight: 700;
}

.recorder-panel-monitor__fullscreen {
  flex: 0 0 auto;
}

.recorder-panel-stream-shell {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  padding: 0;
  border-radius: 0 0 10px 10px;
  border-top: 0;
  background: #000;
  aspect-ratio: var(--recorder-monitor-ratio, 16 / 9);
  box-shadow: none;
}

.recorder-panel-stream-shell {
  isolation: isolate;
}

.recorder-panel-stream-shell::before {
  display: none;
}

.recorder-panel-stream-shell::after {
  display: none;
}

.recorder-panel-stream {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  border-radius: 0;
  background: #000;
  cursor: zoom-in;
}

.recorder-panel-stream-shell:fullscreen {
  padding: 10px;
  border-radius: 0;
  min-height: 100vh;
  max-height: none;
  background: #000;
}

.recorder-panel-stream-shell:fullscreen::before,
.recorder-panel-stream-shell:fullscreen::after {
  inset: 10px;
  border-radius: 0;
}

.recorder-panel-stream-shell:fullscreen .recorder-panel-stream {
  border-radius: 0;
  object-fit: contain;
}

.recorder-panel-stage__foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 12px;
  margin-top: 8px;
  color: rgba(148, 163, 184, 0.86);
  font-size: 11px;
  line-height: 1.45;
}

.recorder-live-dialog {
  width: min(1680px, calc(100vw - 24px));
  padding: 10px;
  border-radius: 12px;
}

.recorder-live-dialog__media {
  aspect-ratio: 16 / 9;
  max-height: calc(100vh - 110px);
}

.recorder-live-dialog__frame {
  min-height: min(82vh, 980px);
}

.recorder-playback-shell {
  display: grid;
  gap: 18px;
}

.recorder-playback-toolbar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  align-items: end;
}

.recorder-playback-toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.recorder-playback-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.recorder-playback-timeline {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background: linear-gradient(180deg, rgba(7, 12, 22, 0.96), rgba(4, 8, 15, 0.98));
}

.recorder-playback-timeline__head h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.recorder-playback-timeline__head p {
  margin: 0;
  color: rgba(203, 213, 225, 0.76);
  font-size: 13px;
}

.recorder-playback-axis {
  position: relative;
  height: 24px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}

.recorder-playback-axis span {
  position: absolute;
  top: 6px;
  transform: translateX(-50%);
  color: rgba(148, 163, 184, 0.82);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
}

.recorder-playback-tracks {
  display: grid;
  gap: 12px;
}

.recorder-playback-track-row {
  display: grid;
  gap: 8px;
}

.recorder-playback-track-row__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.recorder-playback-track-row__head strong {
  display: block;
  margin: 0 0 2px;
  font-size: 14px;
}

.recorder-playback-track-row__head p {
  margin: 0;
  color: rgba(148, 163, 184, 0.82);
  font-size: 12px;
}

.recorder-playback-track {
  position: relative;
  width: 100%;
  height: 54px;
  border: 1px solid rgba(71, 85, 105, 0.34);
  border-radius: 14px;
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(7, 12, 20, 0.98)),
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent calc((100% / 24) - 1px),
      rgba(71, 85, 105, 0.22) calc((100% / 24) - 1px),
      rgba(71, 85, 105, 0.22) calc(100% / 24)
    );
  cursor: pointer;
  overflow: hidden;
}

.recorder-playback-track.is-selected {
  border-color: rgba(214, 187, 24, 0.52);
  box-shadow: inset 0 0 0 1px rgba(214, 187, 24, 0.18);
}

.recorder-playback-track__segment {
  position: absolute;
  top: 9px;
  bottom: 9px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(34, 197, 94, 0.9), rgba(59, 130, 246, 0.82));
  box-shadow: 0 0 16px rgba(34, 197, 94, 0.16);
}

.recorder-playback-track__cursor {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background: rgba(248, 250, 252, 0.96);
  box-shadow: 0 0 0 3px rgba(248, 250, 252, 0.1);
  transform: translateX(-50%);
}

.recorder-playback-channel-card--active {
  border-color: rgba(214, 187, 24, 0.46);
  box-shadow:
    inset 0 0 0 1px rgba(214, 187, 24, 0.16),
    0 14px 34px rgba(2, 6, 23, 0.18);
}

.recorder-panel-channel-map {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.recorder-panel-channel-map__head {
  margin-bottom: 14px;
}

.recorder-panel-channel-map__head h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.recorder-panel-channel-map__head p {
  margin: 0;
  color: rgba(203, 213, 225, 0.76);
  font-size: 13px;
  line-height: 1.55;
}

.recorder-panel-channel-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(260px, 292px);
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
}

.recorder-panel-channel-card {
  min-height: 196px;
  padding: 18px;
  border-radius: 26px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background:
    radial-gradient(circle at top left, rgba(214, 187, 24, 0.08), transparent 24%),
    linear-gradient(180deg, rgba(14, 20, 34, 0.92), rgba(7, 12, 22, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 14px 34px rgba(2, 6, 23, 0.18);
  cursor: grab;
  user-select: none;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    opacity 160ms ease;
}

.recorder-panel-channel-card.is-dragging {
  opacity: 0.42;
  transform: scale(0.985);
  cursor: grabbing;
}

.recorder-panel-channel-card.is-drop-target {
  border-color: rgba(214, 187, 24, 0.54);
  box-shadow:
    inset 0 0 0 1px rgba(214, 187, 24, 0.28),
    0 16px 34px rgba(2, 6, 23, 0.22);
  transform: translateY(-2px);
}

.recorder-panel-channel-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.recorder-panel-channel-card__slot {
  color: rgba(186, 230, 253, 0.88);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.recorder-panel-channel-card h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.2;
}

.recorder-panel-channel-card p {
  margin: 0;
  min-height: 48px;
  color: rgba(203, 213, 225, 0.78);
  font-size: 13px;
  line-height: 1.55;
}

.recorder-panel-channel-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.recorder-panel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(var(--recorder-panel-min, 340px), 1fr));
  align-items: stretch;
  gap: 12px;
}

.recorder-panel-grid--monitor {
  grid-template-columns: repeat(var(--recorder-panel-columns, 4), minmax(0, 1fr));
  gap: 10px;
}

.recorder-panel-grid--cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.recorder-panel-grid--cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.recorder-panel-grid--cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.recorder-panel-grid--cols-5 {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.recorder-panel-tile {
  position: relative;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.08);
  min-height: var(--recorder-panel-tile-height, 236px);
  height: clamp(220px, 25vh, 320px);
  overflow: hidden;
}

.recorder-panel-tile--monitor {
  min-height: 0;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: 0;
  background: #000;
}

.recorder-panel-tile__frame {
  display: block;
  width: 100%;
  height: 100%;
  min-height: var(--recorder-panel-tile-height, 236px);
  border: 0;
  background: #000;
}

.recorder-panel-tile__image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center center;
  background: #000;
}

.recorder-panel-tile__label {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 8px 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.86) 100%);
  pointer-events: none;
}

.recorder-panel-tile__status {
  position: absolute;
  inset: auto 10px 10px 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.58);
  color: rgba(255, 255, 255, 0.9);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.recorder-panel-tile.is-live .recorder-panel-tile__status {
  display: none;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 800;
}

.badge-success { color: #bbf7d0; background: var(--ok-bg); border-color: rgba(34, 197, 94, 0.34); }
.badge-warning { color: #fde68a; background: var(--warn-bg); border-color: rgba(245, 158, 11, 0.36); }
.badge-danger { color: #fecaca; background: var(--danger-bg); border-color: rgba(239, 68, 68, 0.36); }
.badge-default { color: #bae6fd; background: var(--info-bg); border-color: rgba(56, 189, 248, 0.28); }

.wireguard-card {
  gap: 14px;
}

.wireguard-status-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
}

.wireguard-actions {
  margin-bottom: 12px;
}

.wireguard-runtime-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.wireguard-helper-copy {
  margin: 0 0 12px;
}

.btn.is-disabled,
.btn[aria-disabled="true"],
.btn:disabled {
  opacity: 0.56;
  pointer-events: none;
}

.btn-danger-outline {
  border-color: rgba(239, 68, 68, 0.38);
  color: #fecaca;
  background: rgba(127, 29, 29, 0.18);
}

.btn-danger-outline:hover {
  border-color: rgba(248, 113, 113, 0.56);
  background: rgba(127, 29, 29, 0.28);
}

.filters-grid,
.three-col-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
}

.filters-grid label,
.form-stack label,
.three-col-form label {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .07em;
}

.checkbox-field { justify-content: flex-end; }
.checkbox-field input { width: 18px; height: 18px; margin-top: 6px; accent-color: var(--brand); }
.form-actions-span { display: flex; align-items: end; }
.form-span-3 { grid-column: 1 / -1; }
.panel-narrow { max-width: 760px; }

input,
select,
textarea {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(8, 13, 24, 0.78);
  color: var(--text);
  padding: 13px 14px;
  font-size: 14px;
  outline: none;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

input::placeholder,
textarea::placeholder { color: var(--muted-2); }

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(214, 187, 24, 0.44);
  box-shadow: 0 0 0 3px rgba(214, 187, 24, 0.12);
}

input[type="date"],
input[type="datetime-local"] {
  min-width: 0;
  max-width: 100%;
  display: block;
  line-height: 1.2;
}

input[type="date"]::-webkit-date-and-time-value,
input[type="datetime-local"]::-webkit-date-and-time-value {
  min-height: 1.4em;
  text-align: left;
}

input[type="date"]::-webkit-calendar-picker-indicator,
input[type="datetime-local"]::-webkit-calendar-picker-indicator {
  margin: 0;
}

.filters-actions,
.button-row {
  display: flex;
  gap: 10px;
  align-items: end;
  flex-wrap: wrap;
}

.button-row { align-items: center; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 16px;
  padding: 11px 16px;
  border: 1px solid transparent;
  font-weight: 900;
  letter-spacing: .02em;
  cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
}

.btn:hover { transform: translateY(-1px); }

.btn-dark {
  background: linear-gradient(135deg, var(--brand), #caa510);
  color: #0b1220;
  box-shadow: 0 12px 24px rgba(214, 187, 24, 0.18);
}

.btn-dark:hover { box-shadow: 0 18px 28px rgba(214, 187, 24, 0.24); }

.btn-outline {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  border-color: var(--line);
}

.btn-outline:hover { border-color: rgba(214, 187, 24, 0.28); background: rgba(255, 255, 255, 0.06); }
.btn-outline.is-active {
  border-color: rgba(214, 187, 24, 0.34);
  background: rgba(214, 187, 24, 0.14);
  color: #f7e79a;
}
.btn-full { width: 100%; }

.btn-compact {
  min-height: 38px;
  padding: 9px 12px;
  border-radius: 12px;
  font-size: 12px;
}

.code-block {
  background: rgba(2, 6, 23, 0.96);
  color: #d7e6f7;
  border: 1px solid rgba(56, 189, 248, 0.16);
  padding: 18px;
  border-radius: 22px;
  overflow-x: auto;
}

.code-block pre { margin: 0; font-family: "Cascadia Mono", "Consolas", monospace; font-size: 13px; line-height: 1.7; white-space: pre-wrap; }
.helper-text { color: var(--muted); line-height: 1.7; }

.empty-state {
  padding: 26px;
  border: 1px dashed rgba(148, 163, 184, 0.24);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  text-align: center;
}

.picture-info-grid {
  display: grid;
  gap: 12px;
}

.picture-info-card {
  min-width: 0;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.03), transparent 26%),
    linear-gradient(180deg, rgba(15, 23, 42, 0.84), rgba(11, 18, 32, 0.96));
  display: grid;
  gap: 8px;
}

.picture-info-card__title {
  color: var(--text);
  line-height: 1.4;
}

.picture-info-card__meta,
.picture-info-card__link {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.picture-info-card__link {
  color: #8adfff;
  text-decoration: underline;
}

.plate-editor-card {
  scroll-margin-top: 96px;
}

.plate-editor-banner {
  margin-top: 10px;
  padding: 14px 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  border-radius: 18px;
  border: 1px solid rgba(56, 189, 248, 0.24);
  background: rgba(56, 189, 248, 0.1);
}

.plate-editor-banner strong {
  font-size: 16px;
  color: #dff7ff;
}

.plate-editor-banner span {
  color: #b9ebff;
  font-size: 13px;
  line-height: 1.5;
}

.live-overlay {
  position: fixed;
  inset: 0;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.84);
  backdrop-filter: blur(6px);
  z-index: 60;
}

.live-overlay[hidden] {
  display: none;
}

.live-modal-open {
  overflow: hidden;
}

.live-dialog {
  width: min(960px, 100%);
  padding: 14px;
  border-radius: 0;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background:
    linear-gradient(180deg, rgba(3, 7, 18, 0.98), rgba(2, 6, 23, 0.995));
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.55);
}

.live-dialog--player {
  width: min(1380px, 100%);
}

.live-dialog__header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
}

.live-dialog__eyebrow {
  color: #f2d34f;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.live-dialog__header h2 {
  margin: 6px 0 4px;
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: .01em;
}

.live-dialog__header p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.live-dialog__window-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.live-dialog__action,
.live-dialog__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 0;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-weight: 800;
  cursor: pointer;
}

.live-dialog__close {
  width: 40px;
  min-width: 40px;
  padding: 0;
  font-size: 18px;
  line-height: 1;
}

.live-dialog__media {
  overflow: hidden;
  border-radius: 0;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: #000;
  aspect-ratio: 16 / 9;
}

.live-dialog__body {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, 360px);
  gap: 12px;
  align-items: start;
}

.live-dialog__stage {
  display: grid;
  gap: 12px;
}

.live-dialog__media--player {
  position: relative;
}

.live-dialog__media--player:fullscreen {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #000;
}

.live-dialog__video,
.live-dialog__image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  background: #000;
}

.live-dialog__frame {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  background: #000;
}

.live-dialog__empty {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  text-align: center;
  color: var(--muted);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.82), rgba(2, 6, 23, 0.28));
  z-index: 1;
}

.live-dialog__empty[hidden],
.live-dialog__video[hidden],
.live-dialog__image[hidden],
.live-dialog__frame[hidden] {
  display: none;
}

.live-dialog--monitoring {
  max-width: min(1100px, 96vw);
}

.live-dialog__body--solo {
  grid-template-columns: minmax(0, 1fr);
}

.live-dialog__footnote {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.live-dialog__footnote .shell-pill {
  border-radius: 0;
  min-height: 30px;
}

.live-rail {
  min-width: 0;
  padding: 14px;
  border-radius: 0;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background:
    linear-gradient(180deg, rgba(4, 9, 20, 0.98), rgba(2, 6, 18, 0.99));
  display: grid;
  gap: 14px;
  max-height: 72vh;
  overflow: auto;
}

.live-rail__header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.live-rail__header strong {
  display: block;
  font-size: 15px;
}

.live-rail__header span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  margin-top: 4px;
}

.live-rail__group {
  display: grid;
  gap: 8px;
}

.live-rail__group-label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.live-rail__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.live-rail__ranges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.live-filter-chip,
.live-range-chip {
  padding: 8px 11px;
  border-radius: 0;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.live-filter-chip.is-active,
.live-range-chip.is-active {
  border-color: rgba(214, 187, 24, 0.42);
  background: rgba(214, 187, 24, 0.12);
  color: #fff4bb;
}

.live-rail__range-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.live-rail__list {
  display: grid;
  gap: 10px;
  overflow: auto;
  padding-right: 4px;
  min-width: 0;
}

.live-rail__item {
  display: grid;
  gap: 6px;
  padding: 12px 13px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  text-decoration: none;
  min-width: 0;
}

.live-rail__item strong {
  font-size: 14px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.live-rail__item span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.live-rail__badge {
  justify-self: start;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.live-rail__badge--vehicle {
  background: rgba(56, 189, 248, 0.16);
  color: #b6efff;
}

.live-rail__badge--person {
  background: rgba(234, 88, 12, 0.16);
  color: #ffd1ad;
}

.live-rail__badge--event {
  background: rgba(148, 163, 184, 0.16);
  color: #e2e8f0;
}

.live-rail__empty {
  padding: 14px;
  border-radius: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.08);
  color: var(--muted);
  font-size: 13px;
}


.logo-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 150px;
  margin-bottom: 14px;
  border-radius: 22px;
  border: 1px dashed rgba(214, 187, 24, 0.22);
  background: rgba(255, 255, 255, 0.03);
  overflow: hidden;
}

.logo-preview { max-width: 100%; max-height: 150px; object-fit: contain; }
.logo-upload-form {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: end;
}

.logo-upload-field {
  flex: 1 1 260px;
  max-width: 360px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-inline-input {
  padding: 10px 12px;
  font-size: 13px;
}

.upload-hint { margin-top: 10px; font-size: 12px; }

.alert {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid transparent;
  margin-top: 18px;
}

.alert-danger { color: #fecaca; border-color: rgba(239, 68, 68, 0.28); background: rgba(127, 29, 29, 0.18); }
.alert-success { color: #bbf7d0; border-color: rgba(34, 197, 94, 0.28); background: rgba(20, 83, 45, 0.18); }

.login-body {
  min-height: 100vh;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at top left, rgba(214, 187, 24, 0.12), transparent 22%),
    radial-gradient(circle at bottom right, rgba(56, 189, 248, 0.1), transparent 24%),
    linear-gradient(180deg, #0b1220, #111827);
}

.login-shell {
  width: min(520px, 100%);
}

.login-grid {
  width: min(1160px, 100%);
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 18px;
}

.login-panel { padding: 34px; }
.login-panel--compact {
  display: grid;
  gap: 20px;
}
.login-panel--compact .form-stack {
  margin-top: 0;
}
.login-panel--compact .btn {
  width: 100%;
  justify-content: center;
}
.login-brand-lockup {
  display: grid;
  gap: 16px;
  justify-items: center;
}
.login-brand-copy {
  display: grid;
  gap: 8px;
  justify-items: center;
  text-align: center;
}
.login-brand-lockup .hero-logo {
  width: min(100%, 238px);
  margin-bottom: 4px;
}
.login-brand-copy h1 {
  margin: 0;
  font-size: 36px;
  line-height: 1.02;
  letter-spacing: -.03em;
}
.login-brand-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}
.login-support-note {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  display: grid;
  gap: 4px;
}
.login-support-note strong {
  font-size: 14px;
}
.login-support-note span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.hero-panel { background: linear-gradient(145deg, rgba(15, 23, 42, 0.96), rgba(11, 18, 32, 0.92)); }
.hero-panel h1 { margin: 18px 0 12px; font-size: 42px; line-height: 1.02; letter-spacing: -.03em; }
.hero-panel p,
.hero-list { color: #c7d3e4; line-height: 1.78; }
.hero-list { display: grid; gap: 10px; margin-top: 22px; }

.form-panel { background: linear-gradient(180deg, rgba(17, 24, 39, 0.98), rgba(11, 18, 32, 0.94)); }
.form-title { font-size: 30px; font-weight: 900; line-height: 1.05; }
.form-subtitle { margin-top: 8px; color: var(--muted); line-height: 1.7; }
.form-stack { margin-top: 22px; display: grid; gap: 14px; }

.subtle-panel { background: linear-gradient(180deg, rgba(15, 23, 42, 0.86), rgba(11, 18, 32, 0.98)); }
.compact-header h3 { margin: 0 0 4px; }
.wrap-row { flex-wrap: wrap; }
.tight-stack { gap: 8px; margin-top: 14px; }
.small-code pre { font-size: 12px; line-height: 1.55; word-break: break-word; }

.attention-grid {
  display: grid;
  gap: 12px;
}

.attention-card {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.72), rgba(11, 18, 32, 0.92));
}

.attention-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.attention-card__meta {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.attention-card__hint {
  margin-top: 8px;
  font-size: 13px;
  color: #cbd5e1;
}

.camera-secondary-grid {
  margin-top: 14px;
}

.panel--compact .attention-grid {
  gap: 10px;
}

.panel--compact .attention-card {
  padding: 12px 14px;
}

.panel--compact .attention-card__meta,
.panel--compact .attention-card__hint {
  font-size: 12px;
}

body.role-client .content {
  gap: 12px;
}

body.role-client .content-appbar__meta,
body.role-client .hero p,
body.role-client .panel-header p,
body.role-client .stat-note,
body.role-client .dashboard-priority-card__note {
  max-width: 62ch;
  line-height: 1.45;
}

body.role-client .hero.compact,
body.role-client .panel,
body.role-client .stat-card,
body.role-client .camera-fold,
body.role-client .recorder-fold {
  border-radius: 20px;
}

body.role-client .hero.compact {
  padding: 18px 20px;
}

body.role-client .panel {
  padding: 18px;
}

body.role-client .panel-header {
  margin-bottom: 12px;
}

body.role-client .panel-header h2 {
  font-size: 18px;
}

body.role-client .dashboard-priority-grid {
  gap: 12px;
}

body.role-client .monitoring-layout-card {
  border-radius: 16px;
}

body.role-client .dashboard-priority-card {
  padding: 14px 16px;
  border-radius: 18px;
}

body.role-client .metric-chip {
  min-width: 148px;
  padding: 12px 14px;
  border-radius: 18px;
}

body.role-client .compact-feed__item,
body.role-client .health-item,
body.role-client .detail-list__item,
body.role-client .history-timeline__item,
body.role-client .history-photo-card,
body.role-client .monitoring-select-chip {
  border-radius: 16px;
}

body.role-client .photo-card,
body.role-client .photo-card__media,
body.role-client .photo-card__media img {
  border-radius: 0;
}

body.role-client .hero-actions,
body.role-client .button-row.wrap-row {
  gap: 8px;
}

body.role-client .subtle-panel {
  background: linear-gradient(180deg, rgba(12, 18, 32, 0.9), rgba(10, 15, 27, 0.98));
}

@media (max-width: 1180px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .stats-grid,
  .panel-grid.two-col,
  .filters-grid,
  .three-col-form,
  .login-grid,
  .hero-grid,
  .hero-dashboard-slim,
  .signal-grid,
  .camera-live-grid { grid-template-columns: 1fr; }
  .dashboard-ops-band { grid-template-columns: 1fr; }
  .content-appbar,
  .panel-header.between,
  .between { flex-direction: column; align-items: flex-start; }
  .content-appbar__side { justify-content: flex-start; }
  .device-summary {
    width: 100%;
    grid-template-columns: 148px minmax(0, 1fr);
  }
  .camera-fold__summary,
  .camera-fold__summary-side { align-items: flex-start; }
  .camera-fold__summary-side { justify-items: flex-start; }
  .recorder-fold__summary,
  .recorder-fold__summary-side { align-items: flex-start; }
  .recorder-fold__summary-side { justify-items: flex-start; }
  .camera-live-shell { width: 100%; }
  .chart-row { grid-template-columns: 1fr; }
  .metric-chip-row { flex-direction: column; }
}

@media (max-width: 980px) {
  .app-shell {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 100%;
  }
  .sidebar,
  .content,
  .content-appbar,
  .hero,
  .panel,
  .camera-fold,
  .recorder-fold,
  .photo-card,
  .monitoring-layout-card,
  .monitoring-select-chip,
  .live-dialog {
    width: 100%;
    max-width: 100%;
  }
  .device-section__meta {
    white-space: normal;
  }
  .metric-chip,
  body.role-client .metric-chip {
    min-width: 0;
  }
  .menu {
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
  }
  .menu-item {
    flex: 0 0 auto;
    white-space: nowrap;
  }
  .content-appbar__side {
    width: 100%;
    justify-content: space-between;
  }
  .camera-fold-list { grid-template-columns: 1fr; }
  .anpr-review-card,
  .history-timeline__item { grid-template-columns: 1fr; }
  .anpr-review-form { grid-template-columns: 1fr; }
  .history-timeline__thumb { width: 100%; }
  .company-overview__brand { grid-template-columns: 1fr; }
  .company-overview__logo { min-height: 140px; }
  .recorder-panel-intro {
    grid-template-columns: 1fr;
  }
  .recorder-panel-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .recorder-panel-stage__head,
  .recorder-panel-stage__foot {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 680px) {
  .brand-card {
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 10px;
    padding: 12px;
  }
  .brand-icon,
  .brand-logo {
    width: 44px;
    height: 44px;
    border-radius: 12px;
  }
  .dashboard-priority-grid,
  .dashboard-ops-band,
  .stats-grid,
  .signal-grid,
  .monitoring-layout-grid,
  .recorder-panel-grid,
  .monitoring-select-grid {
    grid-template-columns: 1fr;
  }
  .hero-dashboard-slim,
  .profile-hero,
  .company-overview__hero {
    grid-template-columns: 1fr;
  }
  .profile-hero--large .profile-hero__avatar,
  .company-overview__logo {
    justify-self: start;
  }
  .recorder-panel-shell {
    padding: 18px 16px;
    border-radius: 24px;
  }
  .recorder-panel-kpis {
    grid-template-columns: 1fr;
  }
  .dashboard-photo-facts {
    grid-template-columns: 1fr;
  }
  .recorder-panel-toolbar__options--presets {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .recorder-panel-channel-strip {
    grid-auto-columns: minmax(240px, 84vw);
  }
  .recorder-panel-monitor__bar,
  .recorder-panel-monitor__meta {
    justify-content: flex-start;
  }
  .recorder-panel-monitor__bar {
    flex-direction: column;
    align-items: flex-start;
  }
  .live-dialog__window-actions {
    width: 100%;
    justify-content: flex-start;
  }
  .recorder-panel-stream-shell {
    padding: 3px;
    border-radius: 0 0 22px 22px;
  }
  .recorder-panel-stream {
    border-radius: 14px;
  }
  .monitoring-layout-save,
  .button-row,
  .filters-actions,
  .hero-actions {
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
  }
  .button-row > *,
  .filters-actions > *,
  .hero-actions > * {
    width: 100%;
    justify-content: center;
  }
  .monitoring-layout-save label,
  .form-actions-span {
    width: 100%;
  }
  .dashboard-quick-strip .button-row {
    grid-template-columns: 1fr;
  }
  .panel-header.between,
  .between {
    gap: 10px;
  }
  table { min-width: 640px; }
}

@media (max-width: 760px) {
  .sidebar { padding: 12px; }
  .content { padding: 14px; }
  .content-appbar {
    position: static;
    top: auto;
    padding: 14px 15px;
  }
  .content-appbar__title { font-size: 20px; }
  .notification-chip,
  .account-chip { width: 48px; height: 48px; }
  .account-chip__avatar { width: 34px; height: 34px; flex-basis: 34px; }
  input,
  select,
  textarea {
    font-size: 16px;
  }
  .notification-popover,
  .account-popover { right: auto; left: 0; width: min(320px, calc(100vw - 28px)); }
  .health-item__head { flex-direction: column; }
  .detail-list__item { flex-direction: column; }
  .detail-list__item span { text-align: left; }
  .camera-fold { padding: 16px; }
  .camera-fold__summary { flex-direction: column; }
  .recorder-fold { padding: 16px; }
  .recorder-fold__summary { flex-direction: column; }
  .device-summary { grid-template-columns: 1fr; gap: 14px; }
  .device-summary__visual { min-height: 104px; }
  .device-illustration--camera { max-width: 148px; }
  .device-illustration--recorder { max-width: 160px; }
  .settings-summary-grid,
  .company-overview__stats,
  .profile-stat-strip { grid-template-columns: 1fr 1fr; }
  .monitoring-selection-bulk {
    flex-direction: column;
    align-items: stretch;
  }
  .monitoring-selection-search {
    max-width: 100%;
  }
  .monitoring-select-chip--visual { grid-template-columns: auto 1fr; }
  .monitoring-select-chip--visual .monitoring-select-chip__copy {
    grid-column: 2;
    grid-row: 1;
  }
  .monitoring-select-chip__preview {
    grid-column: 1 / -1;
    width: 100%;
    height: 190px;
  }
  .monitoring-select-chip__state {
    grid-column: 1 / -1;
    grid-row: auto;
    justify-self: start;
  }
  .camera-live-shell { width: 100%; }
  .login-body { padding: 16px; }
  .login-shell { width: 100%; }
  .login-panel { padding: 22px; }
  .login-brand-copy h1 { font-size: 30px; }
  .login-brand-lockup .hero-logo { width: min(100%, 187px); }
  .hero h1 { font-size: 28px; }
  .hero-panel h1 { font-size: 34px; }
  .activity-row,
  .list-row { flex-direction: column; align-items: flex-start; }
  .compact-feed__item,
  .device-section__summary,
  .settings-toggle { flex-direction: column; align-items: flex-start; }
  .compact-feed__side { justify-items: flex-start; text-align: left; }
  .live-overlay { padding: 12px; }
  .live-dialog { padding: 14px; }
  .live-dialog__header { flex-direction: column; }
  .live-dialog__body { grid-template-columns: 1fr; }
  .live-dialog__footnote { flex-direction: column; align-items: flex-start; }
  .live-rail { max-height: none; }
  .company-overview__copy h2 { font-size: 24px; }
  .profile-hero--large .profile-hero__avatar { width: 64px; height: 64px; }
}

@supports (-webkit-touch-callout: none) {
  @media (max-width: 760px) {
    .filters-grid,
    .three-col-form,
    .form-stack {
      width: 100%;
      max-width: 100%;
      overflow-x: hidden;
    }
    input[type="date"],
    input[type="datetime-local"] {
      -webkit-appearance: none;
      appearance: none;
      inline-size: 100%;
      min-inline-size: 0;
      max-inline-size: 100%;
      width: -webkit-fill-available;
      font-size: 16px;
      box-sizing: border-box;
      padding-right: 12px;
      overflow: hidden;
    }
    .filters-grid label,
    .three-col-form label,
    .form-stack label {
      width: 100%;
      min-width: 0;
      max-width: 100%;
      overflow: hidden;
    }
    input[type="date"]::-webkit-datetime-edit,
    input[type="datetime-local"]::-webkit-datetime-edit {
      padding: 0;
      margin: 0;
      min-width: 0;
    }
    input[type="date"]::-webkit-datetime-edit-fields-wrapper,
    input[type="datetime-local"]::-webkit-datetime-edit-fields-wrapper {
      padding: 0;
      min-width: 0;
    }
    input[type="date"]::-webkit-calendar-picker-indicator,
    input[type="datetime-local"]::-webkit-calendar-picker-indicator {
      flex: 0 0 auto;
      margin: 0 0 0 8px;
      padding: 0;
    }
  }
}

@media (max-width: 560px) {
  .content { padding: 12px; }
  .content-appbar {
    top: 0;
    padding: 12px 13px;
    gap: 12px;
  }
  .content-appbar__title { font-size: 18px; }
  .content-appbar__meta { font-size: 12px; }
  .settings-summary-grid,
  .company-overview__stats,
  .profile-stat-strip { grid-template-columns: 1fr; }
  .panel,
  .camera-fold,
  .recorder-fold { padding: 14px; }
  .login-panel { padding: 18px; }
  .login-brand-copy h1 { font-size: 28px; }
  .login-brand-lockup .hero-logo { width: min(100%, 170px); }
  .menu-item { padding: 10px 12px; }
  .notification-popover,
  .account-popover {
    position: fixed;
    top: calc(12px + env(safe-area-inset-top));
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    max-height: calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
  }
  .live-dialog {
    width: min(calc(100vw - 12px), 100%);
    padding: 12px;
    border-radius: 0;
  }
  .live-dialog__media {
    aspect-ratio: 4 / 3;
    border-radius: 0;
  }
  .table-wrap { border-radius: 16px; }
  .panel-header h2 { font-size: 18px; }
  .stat-value { font-size: 30px; }
}
