.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
  font-family: Arial, sans-serif;
  color: #1f2937;
  background: #f8fafc;
}

.page--detail {
  max-width: 1800px;
}

body {
  margin: 0;
  background: #f8fafc;
}

.login-page {
  min-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.login-page__content {
  margin: 0 auto;
  flex: 1;
  display: flex;
  align-items: center;
}

.login-panel {
  width: min(100%, 420px);
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 24px;
}

.version-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.login-page .version-strip {
  width: 100%;
  justify-content: center;
  margin-top: auto;
}

.version-chip {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid #dbe3ee;
  border-radius: 999px;
  background: #fff;
  font-size: 0.9rem;
}

.version-chip__label {
  color: #64748b;
  font-weight: 700;
}

.version-chip__value {
  color: #1f2937;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.nav-links a {
  color: #2563eb;
  text-decoration: none;
}

.nav-logout-form {
  margin: 0;
}

.nav-logout-button {
  border: 0;
  background: transparent;
  color: #2563eb;
  cursor: pointer;
  padding: 0;
  font: inherit;
}

.flash-stack {
  margin-bottom: 16px;
}

.flash {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 8px;
}

.flash--error {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.panel {
  background: #ffffff;
  border: 1px solid #dbe3ee;
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 20px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.grid {
  display: grid;
  gap: 20px;
}

.two-column {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.two-column--wide {
  align-items: start;
}

.maintenance-layout {
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  align-items: start;
}

.maintenance-alert-panel {
  border-width: 2px;
  position: sticky;
  top: 16px;
}

.muted {
  color: #64748b;
}

.issue-reason {
  color: #dc2626;
  font-weight: 700;
}

.state-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.4;
}

.state-badge--warning {
  background: #fef3c7;
  color: #92400e;
}

.state-badge--info {
  background: #dbeafe;
  color: #1d4ed8;
}

.state-badge--success {
  background: #dcfce7;
  color: #166534;
}

.state-badge--danger {
  background: #fee2e2;
  color: #b91c1c;
}

.state-badge--neutral {
  background: #e2e8f0;
  color: #334155;
}

.state-badge--purple {
  background: #f3e8ff;
  color: #7e22ce;
}

.stack-list,
.key-value-list {
  margin: 0;
  padding-left: 20px;
}

.dense-list li + li {
  margin-top: 12px;
}

.table-scroll {
  overflow-x: auto;
}

.overview-stats-table th,
.overview-stats-table td {
  text-align: center;
  white-space: nowrap;
}

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

.data-table th,
.data-table td {
  padding: 10px;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: top;
}

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

.filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-grid__full-width {
  grid-column: 1 / -1;
}

.filter-grid input,
.filter-grid select,
.filter-grid button {
  width: 100%;
  box-sizing: border-box;
  padding: 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
}

.filter-grid button {
  background: #2563eb;
  color: #ffffff;
  cursor: pointer;
}

.file-picker-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.secondary-button {
  width: auto;
  white-space: nowrap;
  background: #ffffff;
  color: #1f2937;
  border: 1px solid #cbd5e1;
}

.secondary-button--link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  padding: 10px 16px;
}

.actions {
  display: flex;
  align-items: end;
}

.applied-filters {
  margin-top: 16px;
}

.meta-grid {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 8px 16px;
  margin: 0;
}

.meta-grid dt {
  font-weight: 700;
}

.meta-grid dd {
  margin: 0;
}

.code-block {
  background: #0f172a;
  color: #e2e8f0;
  padding: 16px;
  border-radius: 8px;
  overflow-x: auto;
}

.pagination {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

.danger-panel {
  border-color: #fecaca;
  background: #fff1f2;
}

.danger-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.secondary-danger-actions {
  margin-top: 12px;
}

.danger-button {
  background: #dc2626;
  color: #ffffff;
  border: 0;
  border-radius: 8px;
  padding: 10px 16px;
  cursor: pointer;
}

.danger-button--small {
  padding: 6px 10px;
  font-size: 0.875rem;
}

.inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.inline-actions form {
  margin: 0;
}

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

.summary-card {
  background: #ffffff;
  border: 1px solid #dbe3ee;
  border-radius: 10px;
  padding: 12px;
}