:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --border: #e2e4e9;
  --text: #14161a;
  --text-muted: #62666f;
  --accent: #3b6ef6;
  --up: #1f9d55;
  --down: #d64545;
  --unknown: #9a9ea6;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115;
    --surface: #17191f;
    --border: #262931;
    --text: #eceef1;
    --text-muted: #8b8f98;
    --accent: #6d93ff;
    --up: #3ecb75;
    --down: #f0645f;
    --unknown: #6c7078;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 48px 20px 32px;
}

header {
  margin-bottom: 32px;
}

h1 {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 4px;
}

.ip {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.vitals {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 28px;
}

.vital {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
}

.vital .label {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.vital .value {
  font-size: 1.1rem;
  font-weight: 600;
}

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

.app-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 18px;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.15s ease;
}

.app-card:hover {
  border-color: var(--accent);
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--unknown);
  flex-shrink: 0;
}

.dot.up { background: var(--up); }
.dot.down { background: var(--down); }

.app-info { flex: 1; }

.app-name {
  font-weight: 600;
  font-size: 0.98rem;
}

.app-desc {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 2px;
}

.app-status-text {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
}

footer {
  margin-top: 28px;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
}

@media (max-width: 480px) {
  .vitals { grid-template-columns: 1fr; }
}
