/* changes implemented by vishwadip: started */
:root {
  --ds-bg: #07111f;
  --ds-bg-soft: #0b1628;
  --ds-panel: #101d31;
  --ds-panel-raised: #14233a;
  --ds-panel-muted: #0d192b;
  --ds-text: #f8fafc;
  --ds-muted: #94a3b8;
  --ds-border: rgba(148, 163, 184, 0.16);
  --ds-blue: #3b82f6;
  --ds-cyan: #06b6d4;
  --ds-purple: #8b5cf6;
  --ds-green: #22c55e;
  --ds-warning: #f59e0b;
  --ds-danger: #ef4444;
  --ds-info: #38bdf8;
  --ds-radius-sm: 0.75rem;
  --ds-radius-md: 1rem;
  --ds-radius-lg: 1.35rem;
  --ds-radius-xl: 1.75rem;
  --ds-shadow-sm: 0 10px 28px rgba(2, 6, 23, 0.2);
  --ds-shadow: 0 24px 60px rgba(2, 6, 23, 0.3);
  --ds-sidebar-width: 282px;
  --ds-topbar-height: 74px;
  --ds-transition: 180ms ease;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--ds-topbar-height) + 1rem);
}

body.dashboard-body {
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--ds-text);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 6% 0%, rgba(59, 130, 246, 0.14), transparent 28rem),
    radial-gradient(circle at 96% 10%, rgba(139, 92, 246, 0.1), transparent 30rem),
    var(--ds-bg);
}

body.dashboard-body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
  background-image: linear-gradient(rgba(148, 163, 184, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.018) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 70%);
}

body.dashboard-body .form-control,
body.dashboard-body .form-select,
body.dashboard-body button {
  font-family: inherit;
}

body.dashboard-body a {
  text-underline-offset: 0.2em;
}

body.dashboard-body ::selection {
  color: #fff;
  background: rgba(59, 130, 246, 0.45);
}

.app-shell {
  min-height: 100vh;
  width: 100%;
  transition: margin-left 0.28s ease, width 0.28s ease;
}

.app-topbar {
  min-height: var(--ds-topbar-height);
  z-index: 1035;
  padding: 0.65rem 1rem;
  background: rgba(7, 17, 31, 0.88) !important;
  border-bottom: 1px solid var(--ds-border);
  box-shadow: 0 12px 36px rgba(2, 6, 23, 0.25);
  backdrop-filter: blur(18px);
}

.app-topbar .container-fluid {
  gap: 0.5rem;
  flex-wrap: nowrap;
}

.sidebar-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--ds-text);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.topbar-page-title {
  min-width: 0;
  display: grid;
  gap: 0.14rem;
  color: var(--ds-text);
  line-height: 1.16;
  text-decoration: none;
}

.topbar-page-title:hover,
.topbar-page-title:focus-visible {
  color: #fff;
}

.topbar-page-title span {
  font-size: 1.14rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.topbar-page-title small {
  overflow: hidden;
  color: var(--ds-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.35;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.sidebar-brand-icon {
  overflow: hidden;
  width: 2.55rem;
  height: 2.55rem;
  flex: 0 0 auto;
  display: inline-grid;
  place-items: center;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 0.9rem;
  background: linear-gradient(135deg, var(--ds-blue), var(--ds-purple));
  box-shadow: 0 10px 24px rgba(59, 130, 246, 0.24);
}

.brand-logo-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  transform: scale(1.02);
}

.sidebar-brand-copy {
  display: grid;
  gap: 0.05rem;
  line-height: 1.08;
}

.sidebar-brand-copy small {
  color: var(--ds-muted);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.topbar-menu-button,
.topbar-icon-button {
  width: 2.7rem;
  min-width: 2.7rem;
  height: 2.7rem;
  display: inline-grid;
  place-items: center;
  padding: 0;
  color: var(--ds-text);
  border: 1px solid var(--ds-border);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.045);
  transition: transform var(--ds-transition), border-color var(--ds-transition), background var(--ds-transition);
}

.topbar-menu-button:hover,
.topbar-icon-button:hover,
.topbar-menu-button:focus-visible,
.topbar-icon-button:focus-visible {
  color: #fff;
  border-color: rgba(96, 165, 250, 0.5);
  background: rgba(59, 130, 246, 0.13);
  transform: translateY(-1px);
}

.topbar-user {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  padding: 0.25rem 0.65rem 0.25rem 0.3rem;
  border: 1px solid var(--ds-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
}

.topbar-user-compact {
  position: relative;
  width: 2.75rem;
  height: 2.75rem;
  justify-content: center;
  padding: 0;
  border-radius: 50%;
}

.topbar-user-compact::after {
  content: attr(data-user-email);
  position: absolute;
  top: calc(100% + 0.6rem);
  right: 0;
  z-index: 1100;
  width: max-content;
  max-width: min(18rem, calc(100vw - 2rem));
  padding: 0.45rem 0.65rem;
  color: #f8fafc;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: right;
  white-space: nowrap;
  background: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 0.6rem;
  box-shadow: var(--ds-shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-0.2rem);
  transition: opacity var(--ds-transition), transform var(--ds-transition);
}

.topbar-user-compact:hover::after,
.topbar-user-compact:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}

.topbar-user-compact .topbar-avatar {
  width: 2.1rem;
  height: 2.1rem;
}

.topbar-avatar {
  width: 2rem;
  height: 2rem;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  color: #dbeafe;
  font-size: 0.78rem;
  font-weight: 800;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.2);
}

.topbar-user-copy {
  min-width: 0;
  display: grid;
  line-height: 1.1;
}

.topbar-user-copy strong {
  font-size: 0.72rem;
}

.topbar-user-copy span {
  max-width: 14rem;
  overflow: hidden;
  color: var(--ds-muted);
  font-size: 0.73rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-sidebar {
  --bs-offcanvas-width: var(--ds-sidebar-width);
  color: var(--ds-text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent 30%),
    #091524 !important;
  border-right: 1px solid var(--ds-border) !important;
  box-shadow: 18px 0 50px rgba(2, 6, 23, 0.32);
}

.app-sidebar .offcanvas-header {
  min-height: var(--ds-topbar-height);
  height: var(--ds-topbar-height);
  padding: 0.65rem 1.1rem;
  border-color: var(--ds-border) !important;
}

.sidebar-brand {
  margin: 0;
  font-size: 1.08rem;
}

.sidebar-brand-icon {
  width: 3.05rem;
  height: 3.05rem;
  border-radius: 1rem;
}

.sidebar-brand-copy small {
  margin-top: 0.08rem;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
}

.app-sidebar .offcanvas-body {
  padding: 1rem;
  overflow-y: auto;
}

.sidebar-label {
  margin: 1rem 0.75rem 0.35rem;
  color: #64748b;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.app-sidebar .sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-height: 2.8rem;
  padding: 0.65rem 0.75rem;
  color: #aebbd0 !important;
  border: 1px solid transparent;
  border-radius: 0.85rem;
  text-decoration: none;
  transition: color var(--ds-transition), background var(--ds-transition), border-color var(--ds-transition), transform var(--ds-transition);
}

.app-sidebar .sidebar-link i {
  width: 1.2rem;
  color: #7f91aa;
  text-align: center;
  transition: color var(--ds-transition);
}

.app-sidebar .sidebar-link:hover,
.app-sidebar .sidebar-link.active {
  color: #fff !important;
  border-color: rgba(96, 165, 250, 0.16);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.16), rgba(139, 92, 246, 0.08));
}

.app-sidebar .sidebar-link:hover {
  transform: translateX(2px);
}

.app-sidebar .sidebar-link.active i,
.app-sidebar .sidebar-link:hover i {
  color: #93c5fd;
}

.sidebar-account {
  margin-top: auto;
  padding-top: 0.85rem;
  border-top: 1px solid var(--ds-border);
}

.dashboard-main {
  width: 100%;
  max-width: 1440px;
  min-height: calc(100vh - var(--ds-topbar-height) - 5rem);
  margin-inline: auto;
  padding: 1.5rem clamp(1rem, 2.2vw, 2rem) 2rem;
}

.dashboard-footer {
  color: var(--ds-muted);
  border-top: 1px solid rgba(148, 163, 184, 0.08);
}

.dashboard-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(1.5rem, 4vw, 2.75rem);
  border: 1px solid rgba(96, 165, 250, 0.2);
  border-radius: var(--ds-radius-xl);
  background:
    radial-gradient(circle at 88% 18%, rgba(139, 92, 246, 0.2), transparent 22rem),
    linear-gradient(135deg, rgba(20, 35, 58, 0.98), rgba(11, 27, 48, 0.98));
  box-shadow: var(--ds-shadow);
}

.dashboard-hero::before {
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  content: "";
  background: linear-gradient(90deg, var(--ds-blue), var(--ds-cyan), var(--ds-purple));
}

.dashboard-hero-content {
  position: relative;
  z-index: 1;
  max-width: 58rem;
}

.dashboard-eyebrow,
.section-eyebrow {
  color: #7dd3fc;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.dashboard-hero h1 {
  max-width: 52rem;
  margin: 0.65rem 0 0.9rem;
  color: #fff;
  font-size: clamp(2rem, 4.3vw, 3.8rem);
  font-weight: 800;
  letter-spacing: -0.055em;
  line-height: 1.04;
}

.dashboard-hero p {
  max-width: 48rem;
  margin-bottom: 1.25rem;
  color: #b5c3d6;
  line-height: 1.75;
}

.hero-actions,
.hero-chips {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.hero-chips {
  margin-top: 1.25rem;
}

.dashboard-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.7rem;
  color: #cbd5e1;
  font-size: 0.76rem;
  font-weight: 650;
  border: 1px solid var(--ds-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
}

.section-icon {
  width: 2.55rem;
  height: 2.55rem;
  flex: 0 0 auto;
  display: inline-grid;
  place-items: center;
  color: #93c5fd;
  border-radius: 0.85rem;
  background: rgba(59, 130, 246, 0.13);
}

.dashboard-section,
.dashboard-card,
.dashboard-main .card {
  scroll-margin-top: calc(var(--ds-topbar-height) + 1rem);
}

.dashboard-card,
.dashboard-main .card {
  color: var(--ds-text);
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.018), transparent 42%),
    var(--ds-panel);
  box-shadow: var(--ds-shadow-sm);
}

.dashboard-main .card-header {
  padding: 1rem 1.25rem;
  color: var(--ds-text);
  border-color: var(--ds-border);
  border-radius: var(--ds-radius-lg) var(--ds-radius-lg) 0 0 !important;
  background: rgba(255, 255, 255, 0.018);
}

.dashboard-main .card-body {
  padding: clamp(1rem, 2vw, 1.35rem);
}

.section-heading-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.2rem;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.section-title h1,
.section-title h2,
.section-title h3 {
  margin: 0;
  color: #fff;
  font-weight: 750;
  letter-spacing: -0.035em;
}

.section-title p {
  margin: 0.25rem 0 0;
  color: var(--ds-muted);
  font-size: 0.84rem;
}

.workflow-step {
  position: relative;
  padding: 1rem;
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-md);
  background: rgba(7, 17, 31, 0.4);
}

.workflow-step + .workflow-step {
  margin-top: 0.9rem;
}

.workflow-step-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  color: #cbd5e1;
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.workflow-step-number {
  width: 1.55rem;
  height: 1.55rem;
  display: inline-grid;
  place-items: center;
  color: #bfdbfe;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.17);
}

.dashboard-body .form-label {
  color: #dbe5f3;
  font-size: 0.82rem;
  font-weight: 650;
}

.dashboard-body .form-text,
.dashboard-body .text-muted {
  color: var(--ds-muted) !important;
}

.dashboard-body .form-control,
.dashboard-body .form-select {
  min-height: 2.8rem;
  color: var(--ds-text);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 0.8rem;
  background-color: #0a1729;
  box-shadow: none;
}

.dashboard-body .form-control::placeholder {
  color: #64748b;
}

.dashboard-body .form-control:focus,
.dashboard-body .form-select:focus {
  color: var(--ds-text);
  border-color: rgba(96, 165, 250, 0.66);
  background-color: #0b192c;
  box-shadow: 0 0 0 0.22rem rgba(59, 130, 246, 0.13);
}

.dashboard-body .form-select option {
  color: var(--ds-text);
  background: #0a1729;
}

.dashboard-body .form-check-input {
  border-color: #53657e;
  background-color: #0a1729;
}

.dashboard-body .form-check-input:checked {
  border-color: var(--ds-blue);
  background-color: var(--ds-blue);
}

.dashboard-body .form-range::-webkit-slider-runnable-track {
  height: 0.42rem;
  border-radius: 999px;
  background: #24344b;
}

.dashboard-body .form-range::-webkit-slider-thumb {
  margin-top: -0.27rem;
  background: var(--ds-blue);
  box-shadow: 0 0 0 0.25rem rgba(59, 130, 246, 0.14);
}

.dashboard-body .btn {
  min-height: 2.55rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border-radius: 0.78rem;
  font-weight: 650;
  transition: transform var(--ds-transition), box-shadow var(--ds-transition), border-color var(--ds-transition), background var(--ds-transition);
}

.dashboard-body .btn-sm {
  min-height: 2.25rem;
}

.dashboard-body .btn-primary {
  border-color: transparent;
  background: linear-gradient(135deg, #2563eb, #4f46e5);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.2);
}

.dashboard-body .btn-primary:hover,
.dashboard-body .btn-success:hover,
.dashboard-body .btn-danger:hover {
  transform: translateY(-1px);
}

.dashboard-body .btn-outline-primary {
  color: #93c5fd;
  border-color: rgba(96, 165, 250, 0.45);
}

.dashboard-body .btn-outline-primary:hover {
  color: #fff;
  background: rgba(59, 130, 246, 0.22);
}

.dashboard-body .btn-outline-secondary {
  color: #cbd5e1;
  border-color: rgba(148, 163, 184, 0.35);
}

.dashboard-body .btn-outline-secondary:hover {
  color: #fff;
  border-color: #64748b;
  background: rgba(148, 163, 184, 0.12);
}

.dashboard-body .btn:disabled {
  cursor: not-allowed;
  opacity: 0.52;
  transform: none;
  box-shadow: none;
}

.dashboard-body .btn.is-loading {
  cursor: wait;
}

.dashboard-body hr {
  border-color: var(--ds-border);
  opacity: 1;
}

.dashboard-body .border {
  border-color: var(--ds-border) !important;
}

.dashboard-body .bg-light,
.route-planner {
  background: rgba(7, 17, 31, 0.42) !important;
}

.dashboard-body .alert {
  color: #e2e8f0;
  border: 1px solid var(--ds-border);
  border-left-width: 4px;
  border-radius: var(--ds-radius-sm);
  background: var(--ds-panel-raised);
  box-shadow: var(--ds-shadow-sm);
}

.dashboard-body .alert-warning {
  color: #fde68a;
  border-left-color: var(--ds-warning);
  background: rgba(120, 74, 10, 0.2);
}

.dashboard-body .alert-danger {
  color: #fecaca;
  border-left-color: var(--ds-danger);
  background: rgba(127, 29, 29, 0.22);
}

.dashboard-body .alert-success {
  color: #bbf7d0;
  border-left-color: var(--ds-green);
  background: rgba(20, 83, 45, 0.22);
}

.dashboard-body .alert-info {
  color: #bae6fd;
  border-left-color: var(--ds-info);
  background: rgba(12, 74, 110, 0.22);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.65rem;
  color: #cbd5e1;
  font-size: 0.72rem;
  font-weight: 700;
  border: 1px solid var(--ds-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
}

.status-pill::before {
  width: 0.45rem;
  height: 0.45rem;
  content: "";
  border-radius: 50%;
  background: var(--ds-info);
}

.chart-shell {
  position: relative;
  height: 20rem;
  min-height: 18rem;
  padding: 0.8rem;
  border: 1px solid rgba(148, 163, 184, 0.1);
  border-radius: var(--ds-radius-md);
  background: rgba(7, 17, 31, 0.34);
}

.chart-shell.chart-shell-compact {
  height: 18rem;
  min-height: 15rem;
}

.chart-shell canvas {
  max-width: 100%;
}

.security-stat {
  padding: 0.55rem;
}

.security-stat > div:first-child {
  margin-bottom: 0.3rem;
}

.security-stat > div:last-child {
  color: #fff;
  font-size: 1.45rem;
  font-weight: 800;
}

.dashboard-body .table-responsive {
  border: 1px solid rgba(148, 163, 184, 0.1);
  border-radius: var(--ds-radius-md);
}

.dashboard-body .table {
  --bs-table-bg: transparent;
  --bs-table-color: #d6e0ee;
  --bs-table-border-color: rgba(148, 163, 184, 0.12);
  --bs-table-striped-bg: rgba(255, 255, 255, 0.025);
  --bs-table-striped-color: #d6e0ee;
  margin-bottom: 0;
  color: #d6e0ee;
}

.dashboard-body .table thead,
.dashboard-body .table-light {
  --bs-table-bg: rgba(255, 255, 255, 0.035);
  --bs-table-color: #94a3b8;
  color: #94a3b8;
}

.dashboard-body .table th {
  padding: 0.8rem 0.75rem;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.dashboard-body .table td {
  padding: 0.75rem;
  vertical-align: middle;
}

.photo-picker {
  min-height: 13rem;
}

.capture-operation-card {
  overflow: hidden;
}

.capture-operation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
}

.capture-operation-copy p {
  max-width: 46rem;
  margin: 0.35rem 0 0;
  color: var(--ds-muted);
}

.coverage-map-shell {
  overflow: hidden;
  padding: 0.4rem;
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  background: #081421;
}

.coverage-map {
  width: 100%;
  min-height: 420px;
  border: 0 !important;
  border-radius: calc(var(--ds-radius-lg) - 0.4rem) !important;
}

.coverage-map .leaflet-bar,
.coverage-map .leaflet-control-layers,
.coverage-map .leaflet-control-attribution,
.coverage-map .leaflet-popup-content-wrapper,
.coverage-map .leaflet-popup-tip {
  color: var(--ds-text);
  border-color: var(--ds-border);
  background: rgba(13, 25, 43, 0.94);
}

.coverage-map .leaflet-bar a {
  color: var(--ds-text);
  border-bottom-color: var(--ds-border);
  background: rgba(13, 25, 43, 0.94);
}

.coverage-map .leaflet-bar a:hover,
.coverage-map .leaflet-bar a:focus {
  color: #fff;
  background: var(--ds-panel-raised);
}

.coverage-map .leaflet-control-attribution a,
.coverage-map .leaflet-popup-content a {
  color: #7dd3fc;
}

.route-strength-value {
  min-width: 2.35rem;
  padding: 0.18rem 0.45rem;
  color: #bfdbfe;
  text-align: center;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.14);
}

#coverageRouteStatus:not(.d-none) {
  padding: 0.65rem 0.8rem;
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-sm);
  background: rgba(255, 255, 255, 0.03);
}

#coverageRouteStatus.text-secondary { color: #cbd5e1 !important; }
#coverageRouteStatus.text-success { color: #86efac !important; }
#coverageRouteStatus.text-danger { color: #fca5a5 !important; }

#legend {
  color: #cbd5e1;
}

#legend .badge {
  padding: 0.42rem 0.65rem;
}

.sos-request-list {
  max-height: 300px;
  overflow-y: auto;
}

#sosRequestScroll thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #142238;
  box-shadow: inset 0 -1px 0 rgba(148, 163, 184, 0.28);
}

.modal-content {
  color: var(--ds-text);
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  background: var(--ds-panel);
  box-shadow: var(--ds-shadow);
}

.modal-header,
.modal-footer {
  border-color: var(--ds-border);
}

.modal-header .btn-close {
  filter: invert(1) grayscale(1) brightness(1.8);
}

.camera-preview-shell {
  position: relative;
  overflow: hidden;
  padding: 0.4rem;
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-md);
  background: #020617;
}

/* changes implemented by vishwadip: started */
.stream-auth-panel {
  position: absolute;
  inset: 0.4rem;
  z-index: 3;
  display: grid;
  place-items: center;
  gap: 1rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  text-align: center;
  border-radius: calc(var(--ds-radius-md) - 0.25rem);
  border: 1px solid rgba(148, 163, 184, 0.2);
  background:
    radial-gradient(circle at 50% 0%, rgba(37, 99, 235, 0.25), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.97), rgba(2, 6, 23, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.stream-auth-icon {
  display: inline-grid;
  place-items: center;
  width: 3.35rem;
  height: 3.35rem;
  color: #bfdbfe;
  border-radius: 1.15rem;
  border: 1px solid rgba(96, 165, 250, 0.35);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.28), rgba(14, 165, 233, 0.12));
  box-shadow: 0 20px 45px rgba(37, 99, 235, 0.22);
}

.stream-auth-icon i {
  font-size: 1.35rem;
}

.stream-auth-copy {
  max-width: 34rem;
}

.stream-auth-copy h6 {
  margin: 0.25rem 0 0.45rem;
  color: var(--ds-text);
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 800;
}

.stream-auth-copy p {
  margin: 0;
  color: var(--ds-muted);
  line-height: 1.6;
}

.stream-auth-panel .btn {
  box-shadow: 0 18px 36px rgba(37, 99, 235, 0.25);
}
/* changes implemented by vishwadip: ended */

.notification-drawer {
  --bs-offcanvas-width: min(340px, 100vw);
  color: var(--ds-text);
  border-left: 1px solid var(--ds-border);
  background:
    linear-gradient(180deg, rgba(59, 130, 246, 0.09), transparent 26rem),
    #0d192b;
  box-shadow: var(--ds-shadow);
}

.notification-drawer .border-bottom {
  border-color: var(--ds-border) !important;
}

.notification-drawer-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.55rem;
  align-items: center;
  min-height: var(--ds-topbar-height);
  padding: 0.75rem 0.85rem;
}

.notification-drawer-title {
  min-width: 0;
}

.notification-drawer-header .section-eyebrow {
  font-size: 0.6rem;
}

.notification-drawer-header h2 {
  font-size: 1.1rem;
}

.notification-drawer-body {
  overflow: hidden;
}

#notificationList {
  height: calc(100vh - var(--ds-topbar-height));
  overflow-y: auto;
}

.notification-item {
  position: relative;
  padding: 0.68rem 0.72rem 0.68rem 0.82rem !important;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 0.55rem !important;
  background: rgba(255, 255, 255, 0.028);
  transition: border-color var(--ds-transition), background var(--ds-transition), transform var(--ds-transition);
}

.notification-item::before {
  position: absolute;
  inset: 0.72rem auto 0.72rem 0;
  width: 3px;
  content: "";
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.72);
}

.notification-item + .notification-item {
  margin-top: 0.38rem;
}

.notification-item-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.45rem;
  align-items: start;
}

.notification-title {
  color: #f8fafc;
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1.25;
}

.notification-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  margin-top: 0.28rem;
  color: #9fb0c6;
  font-size: 0.68rem;
  line-height: 1.25;
}

.notification-status {
  padding: 0.08rem 0.36rem;
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.08);
}

.notification-requester,
.notification-coords {
  margin-top: 0.22rem;
  color: #dbeafe;
  font-size: 0.7rem;
  line-height: 1.25;
}

.notification-coords {
  color: #9fb0c6;
  word-break: break-word;
}

.notification-item .btn-sm {
  margin-top: 0.5rem;
  padding: 0.22rem 0.5rem;
  font-size: 0.68rem;
}

.notification-item .view-location {
  color: #93c5fd;
  border-color: rgba(147, 197, 253, 0.32);
  background: transparent;
}

.notification-item .view-location:hover,
.notification-item .view-location:focus-visible {
  color: #fff;
  border-color: rgba(147, 197, 253, 0.62);
  background: rgba(59, 130, 246, 0.16);
}

.notification-icon-button {
  width: 1.95rem;
  height: 1.95rem;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.38);
  transition: color var(--ds-transition), border-color var(--ds-transition), background var(--ds-transition), transform var(--ds-transition);
}

.notification-icon-button:hover,
.notification-icon-button:focus-visible {
  color: #fff;
  border-color: rgba(148, 163, 184, 0.36);
  background: rgba(148, 163, 184, 0.12);
  transform: translateY(-1px);
}

.dismiss-notification {
  width: 1.65rem;
  height: 1.65rem;
  font-size: 0.82rem;
}

.notification-item:hover {
  border-color: rgba(148, 163, 184, 0.24);
  background: rgba(255, 255, 255, 0.045);
  transform: translateY(-1px);
}

.notification-item.unread {
  border-color: rgba(56, 189, 248, 0.24);
  background: rgba(56, 189, 248, 0.055);
}

.sos-sound-toggle {
  min-width: 58px;
  height: 27px;
  min-height: 27px !important;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem;
  padding: 0.1rem 0.18rem 0.1rem 0.42rem;
  color: #fff !important;
  border-color: #475569 !important;
  border-radius: 999px !important;
  background: #475569 !important;
  font-size: 0.62rem;
  font-weight: 800;
}

.sos-sound-toggle.is-enabled {
  border-color: #15803d !important;
  background: #15803d !important;
}

.sos-toggle-knob {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #f8fafc;
  box-shadow: 0 2px 5px rgba(2, 6, 23, 0.35);
}

.sos-toast-stack {
  position: fixed;
  top: calc(var(--ds-topbar-height) + 0.75rem);
  right: 1rem;
  z-index: 1080;
  width: min(390px, calc(100vw - 2rem));
  pointer-events: none;
}

.sos-toast {
  position: relative;
  overflow: hidden;
  margin-bottom: 0.7rem;
  padding: 0.95rem;
  color: var(--ds-text) !important;
  pointer-events: auto;
  border: 1px solid rgba(96, 165, 250, 0.25) !important;
  border-top: 4px solid var(--ds-info) !important;
  border-radius: var(--ds-radius-md);
  background:
    linear-gradient(180deg, rgba(59, 130, 246, 0.1), transparent 56%),
    #101d31 !important;
  box-shadow: var(--ds-shadow);
}

.sos-toast-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  align-items: start;
}

.sos-toast-title {
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.2;
}

.sos-toast-requester {
  margin-top: 0.25rem;
  color: #dbeafe;
  font-size: 0.82rem;
  font-weight: 700;
}

.sos-toast-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin-top: 0.55rem;
  color: #9fb0c6;
  font-size: 0.75rem;
  line-height: 1.25;
}

.sos-toast-badge {
  padding: 0.12rem 0.45rem;
  color: #fecaca;
  font-size: 0.72rem;
  font-weight: 700;
  border: 1px solid rgba(248, 113, 113, 0.24);
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.12);
}

.sos-toast .dismiss-sos-toast {
  color: #9fb0c6;
}

.sos-toast .view-sos-toast-location {
  margin-top: 0.75rem;
  padding: 0.38rem 0.75rem;
  font-weight: 800;
  border-color: var(--ds-danger);
  background: var(--ds-danger);
}

.auth-page {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.auth-page .app-topbar {
  background: transparent !important;
  border-bottom-color: rgba(148, 163, 184, 0.08);
  box-shadow: none;
}

.auth-main {
  width: 100%;
  max-width: 1120px;
  flex: 1;
  display: grid;
  place-items: center;
  margin-inline: auto;
  padding: 2rem 1rem 3rem;
}

.auth-shell {
  width: min(100%, 34rem);
}

.auth-card {
  overflow: hidden;
  color: var(--ds-text);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: var(--ds-radius-xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent 42%),
    var(--ds-panel-raised);
  box-shadow: var(--ds-shadow);
}

.auth-card .card-body {
  padding: clamp(1.35rem, 5vw, 2.25rem);
}

.auth-card h1 {
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.auth-card-icon {
  width: 3.2rem;
  height: 3.2rem;
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
  color: #bfdbfe;
  font-size: 1.15rem;
  border-radius: 1rem;
  background: rgba(59, 130, 246, 0.15);
}

.auth-step {
  color: #7dd3fc;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.mfa-qr-shell {
  display: grid;
  place-items: center;
}

.mfa-enroll-shell {
  width: min(100%, 29rem);
}

.mfa-enroll-card .card-body {
  padding: clamp(1rem, 3vw, 1.35rem);
}

.mfa-enroll-card .auth-card-icon {
  width: 2.65rem;
  height: 2.65rem;
  margin-bottom: 0.65rem;
}

.mfa-enroll-card h1 {
  font-size: clamp(1.3rem, 2.6vw, 1.55rem);
}

.mfa-enroll-card .text-muted {
  max-width: 25rem;
  margin-bottom: 0.8rem;
}

.mfa-qr-frame {
  width: min(100%, 17rem);
  display: grid;
  place-items: center;
  padding: clamp(0.7rem, 2vw, 0.85rem);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: var(--ds-radius-lg);
  background: #fff;
  box-shadow: 0 18px 36px rgba(2, 6, 23, 0.18);
}

.mfa-qr-frame img {
  width: 100%;
  max-width: 15rem;
  height: auto;
  display: block;
}

.mfa-enroll-card form {
  row-gap: 0.8rem !important;
}

.mfa-enroll-card .form-label {
  margin-bottom: 0.35rem;
}

.mfa-enroll-card .small.mt-3 {
  margin-top: 0.8rem !important;
}

.security-settings-grid {
  display: grid;
  gap: 1rem;
}

.empty-state {
  min-height: 10rem;
  display: grid;
  place-items: center;
  align-content: center;
  padding: 1.5rem;
  color: var(--ds-muted);
  text-align: center;
  border: 1px dashed rgba(148, 163, 184, 0.2);
  border-radius: var(--ds-radius-md);
  background: rgba(7, 17, 31, 0.28);
}

.loading-state {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ds-muted);
}

.loading-state::before {
  width: 0.8rem;
  height: 0.8rem;
  content: "";
  border: 2px solid rgba(148, 163, 184, 0.25);
  border-top-color: var(--ds-blue);
  border-radius: 50%;
  animation: ds-spin 0.8s linear infinite;
}

.reveal {
  opacity: 1;
  transform: none;
}

.reveal-ready .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.reveal-ready .reveal.is-visible {
  opacity: 1;
  transform: none;
}

.dashboard-body :focus-visible {
  outline: 3px solid rgba(56, 189, 248, 0.72);
  outline-offset: 2px;
}

@keyframes ds-spin {
  to { transform: rotate(360deg); }
}

@media (min-width: 1200px) {
  body.authenticated-page .app-shell {
    width: calc(100% - var(--ds-sidebar-width));
    margin-left: var(--ds-sidebar-width);
  }

  body.authenticated-page .app-sidebar.offcanvas {
    visibility: visible !important;
    transform: none !important;
  }

  body.authenticated-page .app-sidebar .btn-close,
  body.authenticated-page .topbar-menu-button {
    display: none;
  }

  body.authenticated-page .app-sidebar {
    z-index: 1040;
  }
}

@media (max-width: 1199.98px) {
  body.sidebar-open .app-shell {
    width: 100%;
    margin-left: 0;
  }
}

@media (max-width: 767.98px) {
  :root {
    --ds-topbar-height: 66px;
  }

  .app-topbar {
    min-height: var(--ds-topbar-height);
    padding-inline: 0.65rem;
  }

  .topbar-user-copy strong {
    display: none;
  }

  .topbar-user {
    max-width: 9rem;
    padding-right: 0.4rem;
  }

  .topbar-user-copy span {
    max-width: 5.5rem;
    font-size: 0.67rem;
  }

  .dashboard-main {
    padding: 1rem 0.75rem 1.5rem;
  }

  .dashboard-hero {
    padding: 1.35rem;
    border-radius: var(--ds-radius-lg);
  }

  .dashboard-hero h1 {
    font-size: 2rem;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }

  .dashboard-main .card-body,
  .dashboard-main .card-header {
    padding: 1rem;
  }

  .capture-operation-layout {
    grid-template-columns: 1fr;
  }

  .capture-operation-layout .btn {
    width: 100%;
  }

  .workflow-step .d-flex.align-items-end,
  #panel-email .d-flex.align-items-end,
  #panel-mfa .d-flex.align-items-end {
    align-items: stretch !important;
    flex-direction: column;
  }

  .workflow-step .text-nowrap,
  #panel-email .text-nowrap,
  #panel-mfa .text-nowrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }

  #panel-email .text-nowrap br {
    display: none;
  }

  .coverage-map {
    min-height: 390px;
    height: 390px !important;
  }

  .sos-toast-stack {
    top: calc(var(--ds-topbar-height) + 0.45rem);
    right: 0.5rem;
    width: calc(100vw - 1rem);
  }

  .notification-drawer {
    --bs-offcanvas-width: min(100vw, 340px);
  }

  .notification-drawer-header {
    padding: 0.75rem;
  }

  #notificationList {
    height: calc(100vh - var(--ds-topbar-height));
  }

  .modal-dialog {
    margin: 0.5rem;
  }

  .chart-shell,
  .chart-shell.chart-shell-compact {
    height: 17rem;
    min-height: 15rem;
  }
}

@media (max-width: 419.98px) {
  .topbar-page-title span {
    font-size: 0.85rem;
  }

  .topbar-page-title small {
    max-width: 9.5rem;
    font-size: 0.56rem;
  }

  .topbar-user-copy {
    display: none;
  }

  .topbar-user {
    padding: 0.25rem;
    border: 0;
    background: transparent;
  }

  .dashboard-chip {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .reveal-ready .reveal {
    opacity: 1;
    transform: none;
  }
}
/* changes implemented by vishwadip: ended */
