html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
  background: #f5f7fa;
  color: #1f2933;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.navbar-brand {
  font-weight: 700;
}

.auth-card, .panel {
  background: #fff;
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  margin: 3rem auto;
  max-width: 760px;
  padding: 2rem;
}

.page-header {
  align-items: end;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  margin: 2rem 0 1rem;
}

.page-header h1 {
  font-size: 2rem;
  font-weight: 700;
  margin: 0;
}

.eyebrow {
  color: #52606d;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .08em;
  margin: 0 0 .25rem;
  text-transform: uppercase;
}

.summary-strip {
  display: flex;
  gap: .5rem;
}

.summary-strip span {
  background: #ffffff;
  border: 1px solid #d9e2ec;
  border-radius: 6px;
  padding: .55rem .75rem;
}

.device-panel {
  background: #ffffff;
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  overflow: hidden;
}

.device-table {
  border-collapse: collapse;
  width: 100%;
}

.device-table th,
.device-table td {
  border-bottom: 1px solid #e4e7eb;
  padding: .85rem 1rem;
  text-align: left;
  vertical-align: middle;
}

.device-table th {
  background: #f8fafc;
  color: #52606d;
  font-size: .78rem;
  text-transform: uppercase;
}

.device-table tr:last-child td {
  border-bottom: 0;
}

.clickable-row {
  cursor: pointer;
}

.clickable-row:focus,
.clickable-row:hover {
  background: #f8fafc;
  outline: none;
}

.clickable-row:focus td {
  box-shadow: inset 0 0 0 2px #2f80ed;
}

.device-link {
  color: #1f2933;
  font-weight: 700;
  text-decoration: none;
}

.device-link:hover {
  color: #1f6feb;
  text-decoration: underline;
}

.device-id {
  color: #627d98;
  display: block;
  font-size: .84rem;
  margin-top: .15rem;
}

.status-pill {
  border-radius: 999px;
  display: inline-block;
  font-size: .78rem;
  font-weight: 700;
  min-width: 4.6rem;
  padding: .32rem .55rem;
  text-align: center;
}

.status-pill.online {
  background: #e3fcef;
  color: #147d64;
}

.status-pill.offline {
  background: #fcebea;
  color: #b42318;
}

.empty-state {
  padding: 2rem;
}

.empty-state h2 {
  font-size: 1.25rem;
}

.breadcrumb-nav {
  align-items: center;
  color: #627d98;
  display: flex;
  gap: .45rem;
  margin-top: 1.5rem;
}

.breadcrumb-nav a {
  color: #1f6feb;
  text-decoration: none;
}

.breadcrumb-nav a:hover {
  text-decoration: underline;
}

.workspace-header {
  align-items: end;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  margin: 1.25rem 0 1rem;
}

.workspace-header h1 {
  font-size: 2rem;
  font-weight: 700;
  margin: 0;
}

.workspace-subtitle {
  color: #627d98;
  margin: .25rem 0 0;
}

.status-summary {
  font-weight: 700;
}

.status-summary.online {
  color: #147d64;
}

.status-summary.offline {
  color: #b42318;
}

.workspace-tabs {
  border-bottom: 1px solid #d9e2ec;
  display: flex;
  gap: .25rem;
  overflow-x: auto;
}

.workspace-tab {
  border-bottom: 3px solid transparent;
  color: #52606d;
  font-weight: 700;
  padding: .85rem 1rem;
  text-decoration: none;
  white-space: nowrap;
}

.workspace-tab:hover {
  color: #1f2933;
}

.workspace-tab.active {
  border-bottom-color: #1f6feb;
  color: #1f2933;
}

.workspace-panel {
  background: #ffffff;
  border: 1px solid #d9e2ec;
  border-radius: 0 0 8px 8px;
  border-top: 0;
  padding: 1.5rem;
}

.workspace-panel h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 .25rem;
}

.workspace-panel header p {
  color: #52606d;
  margin-bottom: 1.25rem;
}

.summary-sections {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.summary-card,
.module-placeholder {
  background: #f8fafc;
  border: 1px solid #e4e7eb;
  border-radius: 8px;
  padding: 1rem;
}

.summary-card p {
  color: #627d98;
  margin: .35rem 0 0;
}

.summary-card.muted strong,
.summary-card.muted p {
  color: #627d98;
}

.span-two {
  grid-column: span 2;
}

.detail-label {
  color: #627d98;
  display: block;
  font-size: .78rem;
  font-weight: 700;
  margin-bottom: .25rem;
  text-transform: uppercase;
}

.module-placeholder h3 {
  font-size: 1rem;
  font-weight: 700;
}

.placeholder-note {
  color: #627d98;
  font-size: .9rem;
  margin-bottom: 0;
}

@media (max-width: 760px) {
  .page-header {
    align-items: stretch;
    flex-direction: column;
  }

  .summary-strip {
    flex-wrap: wrap;
  }

  .device-panel {
    overflow-x: auto;
  }

  .workspace-header {
    align-items: stretch;
    flex-direction: column;
  }

  .summary-sections {
    grid-template-columns: 1fr;
  }

  .span-two {
    grid-column: auto;
  }
}
