:root {
  --bg: #f6f5f1;
  --fg: #2b2a27;
  --muted: #76736c;
  --card: #ffffff;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 24px rgba(0, 0, 0, 0.04);
  --green: #82b970;
  --yellow: #d6b14a;
  --red: #c97464;
  --grey: #b8b5ac;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1a1a18;
    --fg: #ece9e2;
    --muted: #8a877f;
    --card: #232220;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.3);
  }
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue",
    Helvetica, "Segoe UI", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6vh 1.25rem env(safe-area-inset-bottom);
}

.card {
  background: var(--card);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 2.5rem 1.75rem 1.75rem;
  width: 100%;
  max-width: 22rem;
  text-align: center;
}

.dot {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  margin: 0 auto 1.25rem;
  background: var(--grey);
  transition: background-color 600ms ease;
  position: relative;
}

.dot::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1px solid currentColor;
  opacity: 0.18;
  color: inherit;
}

.dot[data-status="green"]   { background: var(--green);  color: var(--green); }
.dot[data-status="yellow"]  { background: var(--yellow); color: var(--yellow); }
.dot[data-status="red"]     { background: var(--red);    color: var(--red); }
.dot[data-status="unknown"],
.dot[data-status="loading"] { background: var(--grey);   color: var(--grey); }

.dot[data-status="green"] {
  animation: breathe 4s ease-in-out infinite;
}

@keyframes breathe {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.04); }
}

.headline {
  font-size: 1.35rem;
  font-weight: 500;
  margin: 0 0 0.4rem;
  letter-spacing: -0.01em;
}

.sub {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
}

.msg {
  margin: 1rem 0 0;
  padding: 0.75rem 0.9rem;
  background: rgba(0, 0, 0, 0.03);
  border-radius: 10px;
  color: var(--fg);
  font-size: 0.9rem;
  line-height: 1.4;
}

@media (prefers-color-scheme: dark) {
  .msg { background: rgba(255, 255, 255, 0.04); }
}

.foot {
  margin: 1.5rem 0 0;
  color: var(--muted);
  font-size: 0.78rem;
}

@media (prefers-reduced-motion: reduce) {
  .dot { animation: none; transition: none; }
}
