:root {
  --bg: #0b0f17;
  --card-top: #141a26;
  --card-bottom: #10151f;
  --border: #232c3d;
  --text: #e6ebf4;
  --text-dim: #8a94a8;
  --ok: #34d399;
  --bad: #f87171;
  --pending: #64748b;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Sarabun', system-ui, -apple-system, 'Segoe UI', sans-serif;
  min-height: 100vh;
}

.shell {
  max-width: 900px;
  margin: 0 auto;
  padding: 48px 24px 32px;
}

.masthead h1 {
  font-size: 28px;
  font-weight: 700;
  margin: 0;
  letter-spacing: 0.5px;
}

.masthead .sub {
  margin: 8px 0 0;
  color: var(--text-dim);
  font-size: 15px;
  font-weight: 300;
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 32px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 28px 24px 20px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: linear-gradient(160deg, var(--card-top), var(--card-bottom));
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.card:hover {
  transform: translateY(-2px);
  border-color: #35415a;
}

.card .emoji { font-size: 40px; line-height: 1; }

.card h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
}

.card .desc {
  margin: 0;
  color: var(--text-dim);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.5;
}

.card .link {
  margin-top: auto;
  padding-top: 12px;
  font-size: 13px;
  color: #5eead4;
  font-weight: 500;
}

/* status badge — top-right of each card */
.badge {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-dim);
}

.badge .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--pending);
  animation: pulse 1.2s ease-in-out infinite;
}

.badge.operational { color: var(--ok); }
.badge.operational .dot {
  background: var(--ok);
  animation: none;
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.6);
}

.badge.offline { color: var(--bad); }
.badge.offline .dot {
  background: var(--bad);
  animation: none;
  box-shadow: 0 0 8px rgba(248, 113, 113, 0.5);
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

.foot {
  margin-top: 28px;
  color: var(--text-dim);
  font-size: 12px;
  text-align: right;
}

@media (max-width: 640px) {
  .grid { grid-template-columns: 1fr; }
  .shell { padding: 32px 16px 24px; }
  .masthead h1 { font-size: 22px; }
}
