:root {
  color-scheme: light;
  --bg: #f3f7fb;
  --bg-soft: #eef4ff;
  --card: rgba(255, 255, 255, 0.88);
  --card-strong: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --border: rgba(148, 163, 184, 0.22);
  --accent: #2563eb;
  --accent-soft: rgba(37, 99, 235, 0.12);
  --up: #047857;
  --degraded: #b45309;
  --down: #be123c;
  --shadow: 0 20px 50px rgba(15, 23, 42, 0.08);
}

* { box-sizing: border-box; }

html, body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(96, 165, 250, 0.18), transparent 28%),
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.14), transparent 24%),
    linear-gradient(180deg, #f8fbff 0%, var(--bg) 100%);
  color: var(--text);
  position: relative;
}

a {
  color: inherit;
  text-decoration: none;
}

.page-glow {
  position: fixed;
  width: 420px;
  height: 420px;
  border-radius: 999px;
  filter: blur(80px);
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}

.page-glow-a {
  top: -120px;
  left: -80px;
  background: rgba(59, 130, 246, 0.22);
}

.page-glow-b {
  right: -120px;
  top: 120px;
  background: rgba(14, 165, 233, 0.16);
}

.shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding-top: 28px;
  padding-bottom: 20px;
}

.brand-wrap,
.login-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: white;
  background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
  box-shadow: 0 16px 35px rgba(37, 99, 235, 0.28);
}

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

.nav a {
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  font-weight: 600;
  color: #1e293b;
}

.main {
  padding-bottom: 48px;
}

.login-main {
  min-height: calc(100vh - 20px);
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 26px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 24px;
}

.hero-card {
  overflow: hidden;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hero-text {
  max-width: 48rem;
  line-height: 1.65;
}

.grid {
  display: grid;
  gap: 20px;
  margin-top: 20px;
}

.cards {
  grid-template-columns: repeat(auto-fit, minmax(285px, 1fr));
}

.two-columns {
  grid-template-columns: minmax(320px, 1.08fr) minmax(300px, 0.92fr);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin-top: 28px;
}

.compact-head {
  margin-top: 8px;
}

.section-title {
  margin-top: 2px;
}

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

.stat {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 22px;
  padding: 16px 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(248,250,252,0.92));
}

.stat-main {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(14, 165, 233, 0.08));
}

.stat span,
.eyebrow,
.muted,
.small,
.panel-copy,
.app-link,
.app-list-url,
.login-copy,
.app-url,
 dt {
  color: var(--muted);
}

.stat span {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.stat strong {
  display: block;
  margin-top: 8px;
  font-size: 34px;
  line-height: 1;
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 0.16em;
  font-weight: 700;
  text-transform: uppercase;
  margin: 0;
}

.accent {
  color: var(--accent);
}

h1, h2, h3, p {
  margin: 0;
}

h1 {
  font-size: 31px;
  line-height: 1.1;
}

h2 {
  font-size: 31px;
  line-height: 1.1;
}

h3 {
  font-size: 20px;
  line-height: 1.2;
}

.badge,
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.pill {
  background: var(--accent-soft);
  color: var(--accent);
}

.status-up {
  background: #ecfdf5;
  color: var(--up);
}

.status-degraded {
  background: #fffbeb;
  color: var(--degraded);
}

.status-down {
  background: #fff1f2;
  color: var(--down);
}

.status-unknown {
  background: #e2e8f0;
  color: #334155;
}

.up {
  color: var(--up);
}

.degraded {
  color: var(--degraded);
}

.down {
  color: var(--down);
}

.app-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 100%;
}

.app-card-header {
  display: block;
}

.app-title-block {
  min-width: 0;
}

.app-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.app-link,
.app-url,
.app-details dd,
.app-list-url {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.app-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
}

.app-status {
  flex-shrink: 0;
}

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

.app-details {
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}

.app-details > div {
  padding: 12px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.app-details > div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.app-details > div:first-child {
  padding-top: 14px;
}

dt {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
}

dd {
  margin: 6px 0 0 0;
  font-weight: 600;
  line-height: 1.5;
}

.panel-card {
  padding-top: 24px;
}

.panel-copy {
  margin-top: 8px;
}

.form-grid {
  display: grid;
  gap: 14px;
}

.form-grid-spaced {
  margin-top: 18px;
}

label span {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
}

input,
select,
button {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 16px;
  padding: 13px 14px;
  font: inherit;
  background: rgba(255, 255, 255, 0.94);
}

input:focus,
select:focus {
  outline: 2px solid rgba(37, 99, 235, 0.18);
  border-color: rgba(37, 99, 235, 0.35);
}

button {
  background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
  color: white;
  font-weight: 700;
  cursor: pointer;
  border-color: transparent;
  box-shadow: 0 14px 26px rgba(37, 99, 235, 0.2);
}

.alert {
  border-radius: 16px;
  padding: 12px 14px;
  font-size: 14px;
}

.alert-error {
  background: #fff1f2;
  color: var(--down);
  border: 1px solid #fecdd3;
}

.login-shell {
  min-height: calc(100vh - 48px);
  display: grid;
  place-items: center;
}

.login-card {
  width: 100%;
  max-width: 460px;
  padding: 32px;
}

.login-copy {
  margin-top: 14px;
}

.login-form {
  margin-top: 18px;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
}

.checkbox input {
  width: auto;
}

.list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.list-item {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 15px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.app-list-item:first-child {
  padding-top: 4px;
}

.small {
  font-size: 13px;
}

.empty-state {
  min-height: 180px;
  display: grid;
  place-items: center;
  text-align: center;
}

@media (max-width: 860px) {
  .header,
  .hero,
  .two-columns {
    grid-template-columns: 1fr;
    display: grid;
  }

  .header {
    align-items: start;
  }

  .nav {
    width: 100%;
  }

  .nav a {
    flex: 1 1 auto;
    text-align: center;
  }

  .app-title-row {
    flex-direction: column;
    align-items: start;
  }

  .login-shell {
    min-height: auto;
    padding-top: 48px;
  }
}
