:root {
  color-scheme: light;
  --stage-blue: #009cca;
  --stage-action: #007fa3;
  --stage-action-dark: #006985;
  --stage-dark: #26323b;
  --stage-muted: #667681;
  --stage-border: #dce3e8;
  --stage-bg: #f4f7f9;
  --stage-ok: #159447;
  --stage-off: #8a969e;
}

* { box-sizing: border-box; }

html, body {
  min-height: 100%;
  width: 100%;
  margin: 0;
  background: var(--stage-bg);
  color: var(--stage-dark);
  font-family: "Open Sans", Arial, sans-serif;
  font-size: 16px;
}

a { color: var(--stage-action); }

a, button, input, select { -webkit-tap-highlight-color: rgba(0, 127, 163, .18); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 2px;
  box-shadow: 0 0 0 6px #005a70;
}

.login-shell {
  position: relative;
  width: 100%;
  max-width: none;
  min-height: 100vh;
  display: grid;
  place-items: center;
  margin: 0;
  padding: 2rem 1rem;
  background:
    linear-gradient(rgba(0, 9, 12, .88), rgba(0, 9, 12, .88)),
    url('/assets/img/login-hero.jpg') center / cover no-repeat fixed;
}

.login-card {
  position: relative;
  width: min(100%, 760px);
  padding: 2.5rem;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 8px;
  background: rgba(3, 20, 25, .42);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .3);
  color: #fff;
}

.login-brand { position: absolute; top: 1rem; left: 1rem; display: block; z-index: 1; }
.login-brand img { display: block; width: 104px; height: auto; }
.login-close {
  position: absolute; top: .65rem; right: .75rem; display: grid; width: 44px; height: 44px;
  place-items: center; border-radius: 50%; color: #fff; font-size: 2rem; line-height: 1; text-decoration: none;
}
.login-close:hover { background: rgba(255, 255, 255, .14); }
.login-card h1 { margin: 0 3rem .55rem 0; text-align: left; font-size: 1.9rem; }
.login-card label { display: block; margin: 1rem 0 .35rem; font-weight: 600; }
.login-card input[type="text"], .login-card input[type="password"] {
  width: 100%; min-height: 45px; padding: .8rem .9rem; border: 1px solid #647680; border-radius: 5px;
  background: rgba(255, 255, 255, .86); color: #17242b; font: inherit;
}
.login-card input:focus { border-color: #fff; }
.login-card .remember-row { display: flex; min-height: 44px; align-items: center; gap: .55rem; font-weight: 400; cursor: pointer; }
.login-card .remember-row input { width: 1.1rem; height: 1.1rem; margin: 0; accent-color: #0b806d; }

.stage-pill, .eyebrow {
  margin: 0;
  color: var(--stage-action);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.stage-pill { text-align: center; }
.muted, .scope-note { color: var(--stage-muted); line-height: 1.55; text-align: center; }
.login-card .muted { color: #d8e4e7; text-align: left; }
.login-card .scope-note { color: #d8e4e7; }
.scope-note { margin: 1.25rem 0 0; font-size: .82rem; }
.notice { margin: 1rem 0; padding: .75rem; border-radius: 4px; }
.notice.error { border: 1px solid #e7a4a4; background: #fff0f0; color: #8a2323; }
.notice.success { border: 1px solid #93c9a5; background: #effaf2; color: #176b35; }

.primary-button, .primary-link, .logout-form button {
  display: inline-block; border: 0; border-radius: 4px; background: var(--stage-action); color: #fff; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
}
.primary-button { width: 100%; margin-top: 1.25rem; padding: .85rem 1rem; }
.login-card .primary-button { background: #0b806d; }
.login-card .primary-button:hover { background: #096b5c; }
.primary-link { padding: .65rem 1rem; }
.primary-button:hover, .primary-link:hover, .logout-form button:hover { background: var(--stage-action-dark); }

html.embed-login,
body.embed-login {
  min-height: 0;
  background: transparent;
}

body.embed-login {
  overflow: hidden;
  color: #fff;
  font-family: "Roboto", Arial, sans-serif;
  font-size: 16px;
}

.embed-login-shell {
  width: 100%;
  margin: 0;
  padding: 0 1px 1px;
  background: transparent;
}

.embed-login-form h1,
.embed-login-ready h1 {
  margin: 0 0 .5em;
  color: #333;
  font-family: "Roboto Slab", Georgia, serif;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
}

.embed-login-form input[type="text"],
.embed-login-form input[type="password"] {
  display: block;
  width: 100%;
  min-height: 45px;
  margin: .3em 0;
  padding: 0 0 0 1em;
  border: 0;
  border-radius: 4px;
  outline: 0;
  background: rgba(255, 255, 255, .5);
  color: #fff;
  font: inherit;
  font-size: 87.5%;
  cursor: text;
  transition: border-radius .4s ease-in;
}

.embed-login-form input[type="text"]:focus,
.embed-login-form input[type="password"]:focus { border-radius: 1.5em; }
.embed-login-form input::placeholder { color: #fff; opacity: 1; }
.embed-login-form input:focus::placeholder { color: transparent; }

.embed-remember {
  display: flex;
  min-height: 44px;
  align-items: center;
  gap: .45rem;
  color: #fff;
  line-height: 1.25;
  cursor: pointer;
}

.embed-remember input {
  width: auto;
  margin: 0;
  accent-color: #1bb89b;
}

.embed-login-form button {
  width: 100%;
  min-height: 45px;
  margin: .3em 0;
  border: 1px solid #1bb89b;
  border-radius: .2em;
  background: #1bb89b;
  color: #fff;
  font: inherit;
  font-size: 87.5%;
  cursor: pointer;
  transition: all .4s ease-in;
}

.embed-login-form button:hover,
.embed-login-form button:focus-visible {
  border-radius: 1.5em;
  background: transparent;
  color: #1bb89b;
}

.embed-login-error {
  margin: 0 0 .35rem;
  padding: .4rem .55rem;
  border: 1px solid rgba(255, 95, 95, .85);
  border-radius: 4px;
  background: rgba(255, 95, 95, .45);
  color: #fff;
  font-size: .82rem;
  line-height: 1.25;
}

.embed-login-ready { text-align: center; }
.embed-login-ready a { display: inline-block; padding: .8rem 1rem; color: #fff; }

.stage-sidebar {
  position: fixed; inset: 0 auto 0 0; width: 272px; max-width: none; overflow-y: auto; border-right: 1px solid var(--stage-border); background: #f0f3f5; z-index: 10;
}
.stage-sidebar .brand { display: block; padding: 1rem 1.25rem .4rem; text-align: center; }
.stage-sidebar .brand img { width: 104px; height: auto; }
.stage-sidebar nav { position: static; width: 100%; }
.stage-sidebar nav ul { display: grid; gap: .25rem; width: 100%; padding: .5rem .75rem; }
.stage-sidebar nav li { border-radius: 6px; background: transparent; }
.stage-sidebar nav a { display: block; width: 100%; padding: .8rem 1rem; box-sizing: border-box; border-radius: 6px; color: var(--stage-dark); line-height: 1.35; text-decoration: none; }
.stage-sidebar nav li:hover a { background: #e1eaee; color: var(--stage-action-dark); }
.stage-sidebar nav li.active a { background: var(--stage-action); color: #fff; font-weight: 700; }
.logout-form { margin: 1.25rem; }
.logout-form button { width: 100%; padding: .7rem; }

.dashboard-shell { width: auto; min-height: 100vh; margin: 0 0 0 272px; padding: 2rem; background: var(--stage-bg); }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.4rem; }
.topbar h1 { margin: .35rem 0 0; font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 700; }
.role-badge { padding: .55rem .8rem; border: 1px solid #9bd2e3; border-radius: 999px; background: #e8f7fb; color: #087697; font-weight: 600; }

.summary-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.summary-card, .panel { border: 1px solid var(--stage-border); border-radius: 8px; background: #fff; box-shadow: 0 4px 16px rgba(38, 50, 59, .05); }
.summary-card { padding: 1.2rem; }
.summary-card span { display: block; margin-bottom: .6rem; color: var(--stage-muted); font-size: .82rem; }
.summary-card strong { color: var(--stage-action); font-size: 2rem; }
.summary-card .date-value { font-size: 1rem; }
.panel { margin: 1rem 0; padding: 1.25rem; }
.panel-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.panel-heading h2, .safety-panel h2 { margin: .25rem 0 0; font-size: 1.35rem; font-weight: 700; }
.panel-heading > span { color: var(--stage-muted); font-size: .8rem; }
.table-scroll { overflow-x: auto; }
.device-table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.device-table th, .device-table td { padding: .72rem .6rem; border-bottom: 1px solid #edf1f3; text-align: left; white-space: nowrap; }
.device-table th { background: #eef2f4; color: #4e5c65; font-weight: 600; }
.status { display: inline-flex; align-items: center; gap: .35rem; }
.status::before { content: ""; width: .55rem; height: .55rem; border-radius: 50%; background: var(--stage-off); }
.status.online::before { background: var(--stage-ok); box-shadow: 0 0 0 3px rgba(21, 148, 71, .13); }

.tariff-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: .85rem; }
.tariff-card { padding: 1rem; border: 1px solid var(--stage-border); border-radius: 6px; }
.tariff-card h3 { margin: 0 0 .4rem; color: var(--stage-action); font-weight: 700; }
.tariff-card p { min-height: 2.5rem; color: var(--stage-muted); font-size: .86rem; line-height: 1.45; }
.tariff-card dl { display: grid; grid-template-columns: 1fr auto; gap: .35rem .8rem; margin: .8rem 0 0; font-size: .82rem; }
.tariff-card dt { color: var(--stage-muted); }
.tariff-card dd { margin: 0; font-weight: 600; }
.safety-panel { border-left: 4px solid var(--stage-ok); }
.safety-panel p:last-child { line-height: 1.6; }

.filter-bar {
  display: grid;
  grid-template-columns: minmax(220px, 2fr) repeat(2, minmax(130px, 1fr)) auto auto;
  align-items: end;
  gap: .75rem;
  margin-bottom: .8rem;
  padding: .9rem;
  border: 1px solid var(--stage-border);
  border-radius: 6px;
  background: #f8fafb;
}
.filter-bar label { color: var(--stage-muted); font-size: .78rem; font-weight: 600; }
.filter-bar input, .filter-bar select {
  display: block;
  width: 100%;
  margin-top: .3rem;
  padding: .62rem .65rem;
  border: 1px solid #bcc9d0;
  border-radius: 4px;
  background: #fff;
  color: var(--stage-dark);
  font: inherit;
}
.filter-bar button {
  padding: .68rem .9rem;
  border: 0;
  border-radius: 4px;
  background: var(--stage-action);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.filter-bar > a { padding: .65rem .3rem; text-align: center; }
.result-count { margin: .6rem 0; color: var(--stage-muted); font-size: .82rem; }
.description-cell { max-width: 260px; overflow: hidden; text-overflow: ellipsis; }
.pagination { position: static; display: flex; width: 100%; align-items: center; justify-content: center; flex-wrap: wrap; gap: 1.25rem; margin-top: 1rem; }
.pagination a { display: inline-flex; width: auto; padding: .45rem .7rem; border: 1px solid var(--stage-border); border-radius: 4px; color: var(--stage-action); line-height: 1.4; text-decoration: none; overflow: visible; }
.pagination a::before { display: none; }
.pagination span { color: var(--stage-muted); font-size: .86rem; }
.detail-panel dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; margin: 0; }
.detail-panel dl > div { display: grid; grid-template-columns: minmax(120px, .8fr) minmax(0, 1.2fr); gap: 1rem; padding: .8rem; border-bottom: 1px solid #edf1f3; }
.detail-panel dt { color: var(--stage-muted); }
.detail-panel dd { margin: 0; overflow-wrap: anywhere; font-weight: 600; }

.secondary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .55rem .8rem;
  border: 1px solid #91bdca;
  border-radius: 5px;
  color: var(--stage-action-dark);
  font-weight: 700;
  text-decoration: none;
}
.secondary-link:hover { border-color: var(--stage-action); background: #edf8fb; }
.muted-left { margin-top: .8rem; color: var(--stage-muted); line-height: 1.5; }
.location-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: .9rem; }
.location-card { display: grid; gap: 1rem; padding: 1rem; border: 1px solid var(--stage-border); border-radius: 7px; background: #fbfcfd; }
.location-card h3 { margin-top: .25rem; overflow-wrap: anywhere; font-size: 1rem; font-weight: 700; }
.location-card dl { display: grid; grid-template-columns: 1fr auto; gap: .35rem .8rem; }
.location-card dt { color: var(--stage-muted); }
.location-card dd { margin: 0; font-variant-numeric: tabular-nums; font-weight: 700; }
.empty-state { padding: 2rem 1rem; border: 1px dashed #b9c7ce; border-radius: 7px; text-align: center; }
.empty-state h3 { margin-bottom: .5rem; font-size: 1.1rem; font-weight: 700; }
.empty-state p { color: var(--stage-muted); line-height: 1.5; }

@media (max-width: 820px) {
  .stage-sidebar { position: static; width: 100%; }
  .stage-sidebar nav ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .35rem; padding: .5rem 1rem; overflow: visible; }
  .stage-sidebar nav li { min-width: 0; }
  .stage-sidebar nav a { padding: .7rem .45rem; overflow: hidden; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
  .logout-form { margin: .6rem 1rem 1rem; }
  .dashboard-shell { margin: 0; padding: 1rem; }
  .summary-grid { grid-template-columns: 1fr; }
  .topbar { align-items: flex-start; flex-direction: column; }
  .filter-bar { grid-template-columns: 1fr; }
  .detail-panel dl { grid-template-columns: 1fr; }
  .table-scroll { overflow: visible; }
  .device-table, .device-table tbody, .device-table tr, .device-table td { display: block; width: 100%; }
  .device-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
  .device-table tr { margin-bottom: .75rem; padding: .65rem .8rem; border: 1px solid var(--stage-border); border-radius: 7px; background: #fff; }
  .device-table td { display: grid; grid-template-columns: minmax(96px, .8fr) minmax(0, 1.2fr); gap: .75rem; padding: .5rem 0; border-bottom: 1px solid #edf1f3; white-space: normal; }
  .device-table td:last-child { border-bottom: 0; }
  .device-table td::before { content: attr(data-label); color: var(--stage-muted); font-size: .78rem; font-weight: 700; }
  .device-table td:nth-child(1),
  .device-table td:nth-child(4),
  .device-table td:nth-child(7),
  .device-table td:nth-child(8),
  .device-table td:nth-child(10),
  .device-table td:nth-child(11) { display: none; }
  .description-cell { max-width: none; overflow: visible; text-overflow: initial; }
}

@media (max-width: 430px) {
  .login-shell { padding: 1rem .75rem; }
  .login-brand { top: .55rem; left: .75rem; }
  .login-brand img { width: 82px; }
  .login-card { width: min(100%, 360px); padding: 1.25rem 1.1rem; }
  .login-card h1 { margin-top: 1.4rem; font-size: 1.55rem; }
  .login-card label { margin-top: .72rem; }
  .login-card .primary-button { margin-top: .9rem; }
  .login-card .scope-note { margin-top: .85rem; }
  .dashboard-shell { padding: .75rem; }
  .panel { padding: 1rem .75rem; }
  .panel-heading { align-items: flex-start; flex-direction: column; }
  .role-badge { max-width: 100%; }
  .detail-panel dl > div { grid-template-columns: 1fr; gap: .3rem; }
  .location-grid { grid-template-columns: 1fr; }
}

@media (max-width: 340px), (max-height: 620px) {
  .login-shell { padding-top: .65rem; padding-bottom: .65rem; }
  .login-brand { position: static; justify-self: start; margin: 0 0 .35rem .2rem; }
  .login-brand img { width: 70px; }
  .login-card { padding: .85rem 1rem; }
  .login-card h1 { margin-top: 1rem; font-size: 1.4rem; }
  .login-card .muted { margin: .25rem 0; font-size: .88rem; }
  .login-card label { margin-top: .55rem; }
  .login-card .remember-row { margin-top: .3rem; }
  .login-card input[type="text"], .login-card input[type="password"] { min-height: 44px; padding: .65rem .75rem; }
  .login-card .primary-button { margin-top: .5rem; }
  .login-card .scope-note { margin-top: .45rem; }
}

/* Legacy LK visual parity. The login page above deliberately keeps its own rules. */
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  border: 0 !important;
  white-space: nowrap !important;
}

.stage-sidebar.legacy-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 48px;
  max-width: 272px;
  overflow-x: hidden;
  overflow-y: auto;
  border: 0;
  background: #e6e9ee;
  font-size: 16px;
  transition: width .4s cubic-bezier(1, 0, 0, 1);
  z-index: 30;
}

.stage-sidebar.legacy-sidebar.menu-open { width: 272px; }

.legacy-sidebar .menu-button {
  position: absolute;
  top: 0;
  left: 0;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #e6e9ee url('/assets/img/dealer-icons.png') 0 -288px no-repeat;
  cursor: pointer;
  z-index: 2;
}

.legacy-sidebar.menu-open .menu-button {
  background-color: #009cca;
  background-position: -48px -288px;
}

.stage-sidebar.legacy-sidebar nav { position: relative; width: 272px; }
.stage-sidebar.legacy-sidebar nav ul {
  display: block;
  width: 272px;
  margin: 0;
  padding: 48px 0 0;
}
.stage-sidebar.legacy-sidebar nav li {
  position: relative;
  min-height: 48px;
  border-radius: 0;
  background: #e6e9ee;
  transition: background .4s cubic-bezier(1, 0, 0, 1);
}
.stage-sidebar.legacy-sidebar nav a,
.legacy-sidebar .logout-form button {
  position: relative;
  display: block;
  width: 272px;
  min-height: 48px;
  padding: 0 12px 0 48px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #4a4a4a;
  font: inherit;
  line-height: 48px;
  text-align: left;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: color .4s cubic-bezier(1, 0, 0, 1);
}
.stage-sidebar.legacy-sidebar nav li:hover,
.stage-sidebar.legacy-sidebar nav li.active { background: #009cca; }
.stage-sidebar.legacy-sidebar nav li:hover > a,
.stage-sidebar.legacy-sidebar nav li.active > a,
.legacy-sidebar #lk-exit:hover button { color: #fff; background: transparent; }
.legacy-sidebar .logout-form { width: 272px; margin: 0; }

.stage-sidebar.legacy-sidebar nav a::before,
.legacy-sidebar .logout-form button::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 48px;
  height: 48px;
  content: '';
  background: url('/assets/img/dealer-icons.png') 0 0 no-repeat;
}
.legacy-sidebar #lk-table a::before { background-position: 0 0; }
.legacy-sidebar #lk-map a::before { background-position: 0 -48px; }
.legacy-sidebar #lk-pay a::before { background-position: 0 -96px; }
.legacy-sidebar #lk-add a::before { background-position: 0 -144px; }
.legacy-sidebar #lk-relat a::before { background-position: 0 -192px; }
.legacy-sidebar #lk-settings a::before,
.legacy-sidebar #lk-subaccounts a::before,
.legacy-sidebar #lk-billing a::before,
.legacy-sidebar #lk-testcase a::before,
.legacy-sidebar #lk-testdevice a::before { background-position: 0 -480px; }
.legacy-sidebar #lk-exit button::before { background-position: 0 -240px; }
.legacy-sidebar #lk-table:hover a::before,
.legacy-sidebar #lk-table.active a::before { background-position: -48px 0; }
.legacy-sidebar #lk-map:hover a::before,
.legacy-sidebar #lk-map.active a::before { background-position: -48px -48px; }
.legacy-sidebar #lk-pay:hover a::before { background-position: -48px -96px; }
.legacy-sidebar #lk-add:hover a::before { background-position: -48px -144px; }
.legacy-sidebar #lk-relat:hover a::before { background-position: -48px -192px; }
.legacy-sidebar #lk-settings:hover a::before,
.legacy-sidebar #lk-settings.active a::before,
.legacy-sidebar #lk-subaccounts:hover a::before,
.legacy-sidebar #lk-billing:hover a::before,
.legacy-sidebar #lk-testcase:hover a::before,
.legacy-sidebar #lk-testdevice:hover a::before { background-position: -48px -480px; }
.legacy-sidebar #lk-access-log a::before {
  background: #555;
  -webkit-mask: url('/assets/img/access-log.svg') center / 24px 24px no-repeat;
  mask: url('/assets/img/access-log.svg') center / 24px 24px no-repeat;
}
.legacy-sidebar #lk-access-log:hover a::before,
.legacy-sidebar #lk-access-log.active a::before { background-color: #fff; }
.legacy-sidebar #lk-exit:hover button::before { background-position: -48px -240px; }

.legacy-sidebar + .dashboard-shell,
.dashboard-shell.legacy-dashboard {
  width: calc(100% - 48px);
  min-height: 100vh;
  margin: 0 0 0 48px;
  padding: 0 0 48px;
  background: #fafafa;
  color: #4a4a4a;
}

.legacy-table-section { position: relative; min-height: 100vh; background: #fafafa; }
.legacy-table-toolbar {
  display: flex;
  min-height: 28px;
  align-items: center;
  padding: 3px 10px;
  border-bottom: 1px solid #c9c9c9;
  background: #fafafa;
  color: #737373;
  font-size: 12px;
}
.legacy-table-toolbar #show-all {
  position: fixed;
  right: 116px;
  bottom: 24px;
  z-index: 30;
  display: inline-flex;
  height: 36px;
  align-items: center;
  padding: 0 13px;
  border-radius: 1px;
  background: #009cca;
  color: #fff;
  font-size: 12px;
  text-decoration: none;
  opacity: .42;
  box-shadow: 0 2px 7px rgb(0 0 0 / 22%);
  transition: opacity .3s;
}
.legacy-table-toolbar #show-all:hover,
.legacy-table-toolbar #show-all:focus-visible { opacity: 1; }
.legacy-warning { margin: 0; padding: 6px 10px; background: #fff4d9; font-size: 12px; }

.legacy-table-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: visible;
  scrollbar-width: none;
  background: #fafafa;
}
.legacy-table-scroll::-webkit-scrollbar { display: none; }
.legacy-table-scroll:focus-visible { outline: 2px solid var(--stage-action); outline-offset: -2px; }
.device-table.legacy-device-table {
  width: 100%;
  /* Sticky cells must paint their own borders, including after deep scrolling. */
  border-collapse: separate;
  border-spacing: 0;
  border-top: 1px solid #c9c9c9;
  background: #fafafa;
  color: #4a4a4a;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}
.device-table.legacy-device-table th,
.device-table.legacy-device-table td {
  height: 64px;
  padding: 6px 8px;
  border: 1px solid #c9c9c9;
  border-width: 0 0 1px 1px;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}
.device-table.legacy-device-table th:last-child,
.device-table.legacy-device-table td:last-child { border-right-width: 1px; }
.device-table.legacy-device-table .legacy-desktop-hidden { display: none !important; }
.device-table.legacy-device-table th {
  position: sticky;
  top: 0;
  z-index: 4;
  height: 64px;
  background: #e6e9ee;
  color: #303030;
  font-weight: 400;
}
.legacy-device-table .column-id { width: 44px; min-width: 44px; max-width: 44px; }
.legacy-device-table .column-status { min-width: 130px; }
.legacy-device-table .column-imei { min-width: 140px; }
.legacy-device-table .column-network { min-width: 90px; }
.legacy-device-table .column-station { min-width: 110px; }
.legacy-device-table .column-temperature { min-width: 135px; }
.legacy-device-table .column-description { min-width: 250px; }
.legacy-device-table .column-installation { min-width: 130px; }
.device-table.legacy-device-table .column-dealer { width: auto; min-width: 210px; max-width: 240px; }
.device-table.legacy-device-table td.column-dealer { line-height: 1.25; overflow-wrap: anywhere; white-space: normal; }
.legacy-device-table .dealer-label { display: block; contain: inline-size; max-width: 223px; margin-inline: auto; }
.legacy-device-table .dealer-text { display: block; }
.legacy-device-table.dealer-fit .dealer-label { max-width: none; margin-inline: 0; }
.legacy-device-table.dealer-fit .dealer-text {
  width: var(--dealer-label-width);
  transform: translateX(var(--dealer-label-offset));
}
.legacy-device-table .column-serial {
  position: sticky;
  right: 92px;
  z-index: 2;
  width: 120px;
  min-width: 120px;
  max-width: 120px;
  box-shadow: none;
}
.legacy-device-table .column-serial:last-child { right: 0; }
.legacy-device-table .column-more {
  position: sticky;
  right: 0;
  z-index: 3;
  width: 92px;
  min-width: 92px;
  max-width: 92px;
  padding: 6px;
  box-shadow: none;
}
.legacy-device-table th.column-serial,
.legacy-device-table th.column-more { z-index: 6; }
.legacy-device-table .table-sort { display: block; color: inherit; text-decoration: none; }
.legacy-device-table .offline-row td { background: #ffe6e6; }
.legacy-device-table .online-row td { background: #fafafa; }
.legacy-device-table .description-cell {
  max-width: 340px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.legacy-device-table .signal-good { color: #0d9b2e; font-weight: 600; }
.legacy-device-table .signal-medium { color: #f0a000; font-weight: 600; }
.legacy-device-table .signal-poor { color: #d22b2b; font-weight: 600; }
.legacy-device-table .more-button {
  display: inline-flex;
  width: 100%;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  background: #009cca;
  color: #fff;
  text-decoration: none;
}
.infinite-scroll-sentinel {
  position: relative;
  width: 100%;
  height: 1px;
}
.infinite-scroll-sentinel .infinite-next {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  border: 0;
  white-space: nowrap;
}
.infinite-scroll-sentinel.is-loading::after {
  position: absolute;
  top: 0;
  left: 50%;
  width: 22px;
  height: 22px;
  margin: 7px 0 0 -11px;
  border: 2px solid #c9c9c9;
  border-top-color: #009cca;
  border-radius: 50%;
  content: '';
  animation: legacy-infinite-spin .7s linear infinite;
}
.infinite-scroll-sentinel.has-error {
  display: flex;
  height: auto;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 6px;
}
.infinite-scroll-sentinel.has-error .infinite-next {
  position: static;
  display: inline-flex;
  width: auto;
  height: 32px;
  align-items: center;
  padding: 0 12px;
  margin: 0;
  overflow: visible;
  clip: auto;
  clip-path: none;
  background: #009cca;
  color: #fff;
  font-size: 12px;
  text-decoration: none;
  white-space: nowrap;
}
@keyframes legacy-infinite-spin { to { transform: rotate(360deg); } }

.legacy-settings-page { padding: 0 0 48px !important; }
.legacy-settings-panel {
  width: 100%;
  margin: 0;
  color: #4a4a4a;
}
.legacy-settings-table { width: 100%; border-collapse: collapse; background: #fafafa; }
.legacy-settings-table th,
.legacy-settings-table td {
  height: 64px;
  padding: 0 8px;
  border: 1px solid #c9c9c9;
  font-weight: 400;
}
.legacy-settings-table thead th { background: #e6e9ee; text-align: center; }
.legacy-settings-table tbody th { width: 50%; text-align: center; }
.legacy-settings-table td { width: 25%; text-align: center; }
.legacy-settings-table label {
  display: inline-grid;
  width: 48px;
  height: 48px;
  place-items: center;
  cursor: pointer;
}
.legacy-settings-table input[type="checkbox"] {
  width: 48px;
  height: 48px;
  margin: 0;
  border: 0;
  border-radius: 0;
  appearance: none;
  background: url('/assets/img/dealer-icons.png') 0 -432px no-repeat;
  cursor: pointer;
}
.legacy-settings-table input[type="checkbox"]:checked { background-position: -48px -432px; }
.legacy-settings-panel > .notice {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 1000;
  margin: 0;
}

.dashboard-shell.legacy-dashboard.legacy-detail-page {
  width: calc(100% - 48px);
  max-width: none;
  min-height: 0;
  margin-left: 48px;
  padding: 12px 16px 10px !important;
  background: #f4f5f7;
  color: #3e515b;
  font-size: 14px;
}
.legacy-device-card {
  width: 100%;
  max-width: 1024px;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid #e4e6eb;
  border-radius: 4px;
  background: #fff;
}
.legacy-device-card-header {
  display: flex;
  min-height: 39px;
  align-items: center;
  gap: 9px;
  padding: 9px 14px;
  border-bottom: 1px solid #e4e6eb;
  background: #f0f2f7;
  color: #3e515b;
  font-weight: 600;
}
.legacy-device-card-icon {
  position: relative;
  display: inline-block;
  width: 14px;
  height: 12px;
  border-top: 2px solid #536c79;
  border-bottom: 2px solid #536c79;
}
.legacy-device-card-icon::after {
  position: absolute;
  top: 3px;
  right: 0;
  left: 0;
  border-top: 2px solid #536c79;
  content: '';
}
.legacy-device-card-body { padding: 12px; background: #fff; }
.legacy-field-table,
.legacy-profile-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  background: transparent;
}
.legacy-paired-field-table .legacy-field-cell {
  width: 50%;
  height: 28px;
  padding: 4px 10px;
  border: 0;
  border-bottom: 1px solid #e4e6eb;
  font-weight: 400;
  vertical-align: middle;
}
.legacy-paired-field-table tr:nth-child(odd) .legacy-field-cell { background: rgba(0, 0, 0, .05); }
.legacy-field-entry {
  display: grid;
  min-width: 0;
  grid-template-columns: minmax(112px, 38%) minmax(0, 62%);
  align-items: center;
  gap: 10px;
}
.legacy-field-label { min-width: 0; color: #3e515b; overflow-wrap: anywhere; }
.legacy-field-value {
  min-width: 0;
  color: #3e515b;
  text-align: right;
  overflow-wrap: anywhere;
}
.legacy-profile-table { margin-top: 12px; border: 1px solid #e4e6eb; }
.legacy-profile-table th,
.legacy-profile-table td {
  height: 34px;
  padding: 4px 10px;
  border-right: 1px solid #e4e6eb;
  border-bottom: 1px solid #e4e6eb;
  font-weight: 400;
  vertical-align: middle;
}
.legacy-profile-table tr:last-child > * { border-bottom: 0; }
.legacy-profile-table tr > *:last-child { border-right: 0; }
.legacy-profile-table th { width: 18%; background: #f0f2f7; text-align: left; }
.legacy-profile-table td { width: 32%; background: #fff; text-align: right; overflow-wrap: anywhere; }
.legacy-profile-table .offline-row > * { background: #ffe6e6; }
.legacy-metric-cell {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  white-space: nowrap;
}
.legacy-metric-text { flex: 0 0 auto; }
.legacy-signal-meter {
  width: auto;
  min-width: 44px;
  max-width: 260px;
  height: 14px;
  margin: 0;
  flex: 1 1 auto;
  border: 0;
  border-radius: 0;
  background: #bdbdbd;
}
.legacy-signal-meter::-webkit-progress-bar { background: #bdbdbd; }
.legacy-signal-meter.poor::-webkit-progress-value { background: #f00; }
.legacy-signal-meter.medium::-webkit-progress-value { background: #ff8100; }
.legacy-signal-meter.fair::-webkit-progress-value { background: #ffec00; }
.legacy-signal-meter.good::-webkit-progress-value { background: #34d800; }
.legacy-signal-meter.poor::-moz-progress-bar { background: #f00; }
.legacy-signal-meter.medium::-moz-progress-bar { background: #ff8100; }
.legacy-signal-meter.fair::-moz-progress-bar { background: #ffec00; }
.legacy-signal-meter.good::-moz-progress-bar { background: #34d800; }

html.legacy-map-page,
body.legacy-map-page { height: 100%; overflow: hidden; background: #fafafa; }
.legacy-sidebar + .legacy-map-wrap,
.legacy-map-wrap {
  position: relative;
  width: calc(100% - 48px);
  height: 100vh;
  margin: 0 0 0 48px;
  padding: 0;
  background: #fafafa;
}
.legacy-map-wrap #map { width: 100%; height: 100%; background: #e3ede5; }
.legacy-device-map-wrap {
  position: relative;
  width: calc(100% - 48px);
  margin: 0 0 0 48px;
}
#mapOneUser {
  position: relative;
  width: 100%;
  height: 50vh;
  min-height: 320px;
  margin: 0;
  background: #e3ede5;
}
.legacy-map-empty,
.legacy-device-map-empty {
  position: absolute;
  z-index: 500;
  top: 50%;
  left: calc(50% + 24px);
  margin: 0;
  padding: 8px 12px;
  transform: translate(-50%, -50%);
  border: 1px solid #c9c9c9;
  background: rgba(250, 250, 250, .9);
}
.legacy-device-map-empty { top: 50%; left: 50%; bottom: auto; }
.leaflet-container { font-family: "Open Sans", Arial, sans-serif; }
.legacy-map-marker {
  border: 0;
  background: transparent;
  cursor: pointer;
}
.legacy-map-marker::before {
  position: absolute;
  bottom: 7px;
  left: 50%;
  width: 21px;
  height: 30px;
  transform: translateX(-50%);
  background-position: center;
  background-repeat: no-repeat;
  background-size: 21px 30px;
  content: '';
}
.legacy-map-marker-online::before { background-image: url('/assets/img/Img-lk/iconOnline.png'); }
.legacy-map-marker-offline::before { background-image: url('/assets/img/Img-lk/iconOffline.png'); }
.legacy-map-marker-count {
  position: absolute;
  z-index: 1;
  top: 0;
  right: 0;
  min-width: 19px;
  height: 19px;
  padding: 0 4px;
  border: 2px solid #fff;
  border-radius: 10px;
  background: #007fa5;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 15px;
  text-align: center;
  pointer-events: none;
}
.leaflet-marker-icon.legacy-map-marker:focus-visible {
  outline: 2px solid #009cca;
  outline-offset: -5px;
  border-radius: 50%;
}
.legacy-map-popup { min-width: 190px; color: #4a4a4a; font-size: 13px; line-height: 1.35; }
.legacy-map-popup h2,
.legacy-map-popup h3 { margin: 0 0 5px; font-size: 15px; font-weight: 700; }
.legacy-map-popup a { display: block; margin-top: 8px; padding: 7px 10px; background: #009cca; color: #fff; text-align: center; text-decoration: none; }
.legacy-map-popup-device + .legacy-map-popup-device { margin-top: 10px; padding-top: 10px; border-top: 1px solid #c9c9c9; }

.legacy-access-log-page { padding: 24px 24px 48px; background: #fafafa; }
.legacy-access-log-panel { max-width: 1500px; margin: 0 auto; }
.legacy-access-log-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 18px;
}
.legacy-access-log-heading h1 { margin: 0 0 5px; font-size: 28px; font-weight: 600; }
.legacy-access-log-heading p { margin: 0; color: #747474; }
.legacy-time-zone-form { display: flex; align-items: flex-end; gap: 8px; }
.legacy-time-zone-form label { display: grid; gap: 4px; color: #555; font-size: 12px; font-weight: 600; }
.legacy-time-zone-form select {
  min-width: 230px;
  height: 38px;
  padding: 0 32px 0 10px;
  border: 1px solid #c9c9c9;
  background: #fff;
}
.legacy-time-zone-form button {
  height: 38px;
  padding: 0 16px;
  border: 0;
  background: #009cca;
  color: #fff;
  cursor: pointer;
}
.legacy-access-log-scroll { overflow-x: auto; border: 1px solid #d1d1d1; background: #fff; }
.legacy-access-log-table { width: 100%; min-width: 1050px; border-collapse: collapse; font-size: 13px; }
.legacy-access-log-table th,
.legacy-access-log-table td { padding: 10px 12px; border-right: 1px solid #ddd; border-bottom: 1px solid #ddd; text-align: left; vertical-align: top; }
.legacy-access-log-table th:last-child,
.legacy-access-log-table td:last-child { border-right: 0; }
.legacy-access-log-table thead th { background: #e6e9ee; color: #4a4a4a; font-weight: 600; white-space: nowrap; }
.legacy-access-log-table tbody tr:last-child td { border-bottom: 0; }
.legacy-access-log-table small { display: block; margin-top: 3px; color: #7a7a7a; font-size: 11px; }
.legacy-access-log-table .access-event-company { color: #39728a; font-weight: 600; }
.legacy-access-log-table .access-event-time,
.legacy-access-log-table .access-event-ip { white-space: nowrap; }
.legacy-access-log-table .access-event-agent { min-width: 320px; max-width: 520px; overflow-wrap: anywhere; }
.legacy-access-log-table .access-event-login_success td:first-child { border-left: 4px solid #33a852; }
.legacy-access-log-table .access-event-login_failure td:first-child { border-left: 4px solid #d8443a; }
.legacy-access-log-table .access-event-rate_limited td:first-child { border-left: 4px solid #f0a000; }
.legacy-access-log-table .access-event-logout td:first-child { border-left: 4px solid #8b969d; }
.legacy-access-log-empty { padding: 40px !important; color: #777; text-align: center !important; }
.legacy-access-log-pagination { display: flex; justify-content: center; gap: 18px; margin-top: 16px; }
.legacy-access-log-pagination a { color: #008bb4; text-decoration: none; }

@media (max-width: 820px) {
  .stage-sidebar.legacy-sidebar { position: fixed; width: 48px; }
  .legacy-access-log-page { padding: 16px 12px 40px; }
  .legacy-access-log-heading { display: block; }
  .legacy-time-zone-form { margin-top: 14px; align-items: flex-end; }
  .legacy-time-zone-form label { flex: 1; }
  .legacy-time-zone-form select { width: 100%; min-width: 0; }
  .legacy-sidebar + .dashboard-shell,
  .dashboard-shell.legacy-dashboard { width: calc(100% - 48px); margin-left: 48px; padding: 0 0 48px; }
  .legacy-table-scroll { overflow-x: auto; overflow-y: visible; }
  .device-table.legacy-device-table { display: table; width: 100%; }
  .device-table.legacy-device-table tbody { display: table-row-group; width: auto; min-width: 0; }
  .device-table.legacy-device-table thead {
    position: static;
    display: table-header-group;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
    clip-path: none;
    white-space: normal;
  }
  .device-table.legacy-device-table tr { display: table-row; width: auto; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; }
  .device-table.legacy-device-table th,
  .device-table.legacy-device-table td {
    display: table-cell !important;
    width: auto;
    padding: 6px 8px;
    border: 1px solid #c9c9c9;
    border-width: 0 0 1px 1px;
    white-space: nowrap;
  }
  .device-table.legacy-device-table td::before { display: none; content: none; }
  .device-table.legacy-device-table .column-serial { width: 120px; }
  .device-table.legacy-device-table .column-more { width: 92px; }
  .device-table.legacy-device-table .legacy-desktop-hidden { display: table-cell !important; }
  .device-table.legacy-device-table .legacy-mobile-hidden { display: none !important; }
  .legacy-table-toolbar #show-all { right: 108px; bottom: 16px; }
  .dashboard-shell.legacy-dashboard.legacy-detail-page {
    width: calc(100% - 48px);
    max-width: none;
    min-height: 0;
    padding: 8px !important;
    overflow: visible;
  }
  .legacy-device-card { max-width: none; }
  .legacy-device-card-body { padding: 8px; }
  .legacy-paired-field-table,
  .legacy-paired-field-table tbody,
  .legacy-paired-field-table tr { display: block; width: 100%; }
  .legacy-paired-field-table .legacy-field-cell {
    display: block;
    width: 100%;
    height: auto;
    min-height: 34px;
    padding: 6px 9px;
  }
  .legacy-paired-field-table .legacy-field-cell-empty { display: none; }
  .legacy-field-entry { grid-template-columns: minmax(104px, 42%) minmax(0, 58%); }
  .legacy-profile-table { min-width: 0; }
  .legacy-profile-table,
  .legacy-profile-table tbody { display: block; width: 100%; }
  .legacy-profile-table tr {
    display: grid;
    width: 100%;
    grid-template-columns: minmax(104px, 38%) minmax(0, 62%);
  }
  .legacy-profile-table th,
  .legacy-profile-table td {
    display: flex;
    width: auto;
    height: auto;
    min-height: 36px;
    align-items: center;
    padding: 5px 9px;
    text-align: left;
  }
  .legacy-profile-table td { justify-content: flex-end; text-align: right; }
  #mapOneUser { height: 45vh; min-height: 280px; }
}

@media (max-width: 430px) {
  .legacy-detail-toolbar { align-items: flex-start; flex-direction: column; padding: 7px 0; }
  .legacy-device-card-header { min-height: 36px; padding: 8px 10px; }
  .legacy-field-entry { grid-template-columns: minmax(94px, 44%) minmax(0, 56%); gap: 7px; }
  .legacy-paired-field-table .legacy-field-cell,
  .legacy-profile-table th,
  .legacy-profile-table td { padding-right: 7px; padding-left: 7px; font-size: 12px; }
  .legacy-profile-table tr { grid-template-columns: minmax(94px, 42%) minmax(0, 58%); }
}

.legacy-table-toolbar {
  height: 0;
  min-height: 0;
  padding: 0;
  border: 0;
}
.legacy-table-toolbar > span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

/* Device history extends the existing LK card and preserves its radio-series colors. */
.legacy-device-table .device-history-entry { min-height: 44px; flex-direction: column; line-height: 1.2; gap: 2px; }
.device-history-entry span:last-child { font-size: 12px; }
.device-detail-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; max-width: 1024px; margin: 0 auto 8px; }
.device-detail-nav a { display: inline-flex; min-height: 44px; align-items: center; }
.device-history { --history-power: #f7931e; --history-quality: #35b7ab; margin-top: 16px; scroll-margin-top: 12px; }
.device-history h2 { margin: 0; font-size: 14px; font-weight: 600; }
.device-history-body { padding: 12px; }
.device-history-form { margin: 0; }
.device-history-periods, .device-history-dates { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; }
.device-history-periods { margin-bottom: 12px; }
.device-history button, .device-history input { min-height: 44px; padding: 8px 12px; border: 1px solid var(--stage-border); border-radius: 3px; background: #fff; color: var(--stage-dark); font: inherit; }
.device-history button { cursor: pointer; }
.device-history button:hover { border-color: var(--stage-action); }
.device-history button[aria-pressed="true"], .device-history .device-history-submit { border-color: var(--stage-action); background: var(--stage-action); color: #fff; }
.device-history button:disabled { cursor: wait; opacity: .65; }
.device-history-dates label { display: flex; flex: 1 1 210px; min-width: 0; flex-direction: column; gap: 4px; }
.device-history-dates input { display: block; width: 100%; min-width: 0; font-variant-numeric: tabular-nums; }
.device-history input[aria-invalid="true"] { border-color: #b12a2a; }
.device-history-note { margin: 8px 0 0; color: #596972; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.device-history-status { margin: 16px 0; min-height: 20px; color: #596972; line-height: 1.5; }
.device-history-status.is-error { color: #982727; }
.device-history-plot-group + .device-history-plot-group { margin-top: 16px; }
.device-history h3 { margin: 0 0 8px; font-size: 14px; font-weight: 600; line-height: 1.5; }
.device-history h3 span { color: #596972; font-weight: 400; white-space: nowrap; }
.device-history-plot { width: 100%; min-width: 0; min-height: 200px; }
.device-history-plot svg { display: block; width: 100%; height: 200px; overflow: visible; touch-action: pan-y; }
.device-history-plot text { fill: #596972; font-size: 11px; font-family: inherit; font-variant-numeric: tabular-nums; }
.device-history-grid { stroke: #e4e6eb; stroke-width: 1; }
.device-history-line { fill: none; stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.device-history-power { stroke: var(--history-power); }
.device-history-quality { stroke: var(--history-quality); }
.device-history-dot.device-history-power { fill: var(--history-power); }
.device-history-dot.device-history-quality { fill: var(--history-quality); }
.device-history-cursor { stroke: #6a7b84; stroke-width: 1; stroke-dasharray: 3 3; }
.device-history-empty-metric { display: grid; min-height: 200px; place-items: center; margin: 0; border: 1px solid #e4e6eb; color: #596972; }
.device-history-inspector { margin-top: 12px; padding: 12px 0; border-top: 1px solid #e4e6eb; border-bottom: 1px solid #e4e6eb; }
.device-history-inspector label { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; }
.device-history-inspector output { font-weight: 600; font-variant-numeric: tabular-nums; }
.device-history-inspector input { width: 100%; margin: 4px 0 0; padding: 0; accent-color: var(--stage-action); cursor: pointer; }
.device-history-inspector p { margin: 0; line-height: 1.6; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.device-history-traffic { width: 100%; margin: 16px 0 0; border-collapse: collapse; table-layout: fixed; }
.device-history-traffic caption { margin-bottom: 8px; text-align: left; font-weight: 600; }
.device-history-traffic th, .device-history-traffic td { padding: 8px 4px; border: 1px solid #e4e6eb; text-align: center; font-weight: 400; overflow-wrap: anywhere; }
.device-history-traffic th { background: #f0f2f7; }
.device-history-traffic td { font-variant-numeric: tabular-nums; }
.device-history [hidden] { display: none !important; }
@media (max-width: 600px) {
  .device-detail-nav { gap: 0 12px; font-size: 13px; }
  .device-history-body { padding: 10px 8px; }
  .device-history-periods { gap: 6px; }
  .device-history-periods button { flex: 1 1 auto; padding: 8px; }
  .device-history-dates label { flex-basis: 100%; }
  .device-history-submit { width: 100%; }
  .device-history h3 span { display: block; font-size: 12px; }
}


/* Inactivity warning follows the current LK card and action styles. */
.session-warning {box-sizing:border-box;width:420px;max-width:calc(100vw - 32px);padding:22px;border:1px solid #cbd5df;border-top:3px solid #f7931e;background:#fff;color:#435360;box-shadow:0 12px 40px #162c4650;font:inherit;}
.session-warning::backdrop {background:#152b4680;}
.session-warning h2 {margin:0 0 14px;font-size:20px;line-height:1.3;}
.session-warning p {margin:12px 0;line-height:1.5;}
.session-warning-timer {font-weight:600;}
.session-warning-timer output {font-variant-numeric:tabular-nums;}
.session-warning-actions {display:flex;flex-wrap:wrap;gap:10px;margin-top:20px;}
.session-warning-actions form {margin:0;}
.session-warning-actions button {min-height:44px;padding:10px 18px;border:1px solid #cbd5df;border-radius:3px;background:#fff;color:#435360;font:inherit;cursor:pointer;}
.session-warning-actions #session-continue {border-color:#008aac;background:#008aac;color:#fff;}
.session-warning-actions button:focus-visible {outline:3px solid #f7931e;outline-offset:3px;}
.session-warning-actions button:disabled {opacity:.55;cursor:wait;}
