:root {
  color-scheme: dark;
  --bg: #000;
  --card-bg: #111;
  --fg: #fff;
  --muted: #999;
  --accent: #fff;
  --border: #333;
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
  margin: 0;
}

body {
  min-height: 100%;
  margin: 0;
  background-color: #232821;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  display: flex;
  justify-content: center;
}

.card {
  width: 100%;
  max-width: 386px;
  margin: 16px;
  padding: 48px 24px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: #232821;
  border-radius: 20px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55);
}

.logo {
  width: 60px;
  height: auto;
  object-fit: contain;
  margin-bottom: 12px;
}

h1 {
  font-size: 1.75rem;
  margin: 0 0 4px;
}

.tagline {
  color: var(--muted);
  margin: 0 0 32px;
  font-size: 0.95rem;
}

.links {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.link-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.section-label {
  margin: 0;
  padding: 0;
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-align: center;
}

.link-row {
  display: flex;
  gap: 12px;
}

.link-row .link-btn {
  width: auto;
  flex: 1;
}

.link-row .link-btn:last-child {
  flex-direction: row-reverse;
  justify-content: flex-start;
}

.link-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--fg);
  text-decoration: none;
  font-weight: 500;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.link-btn:hover {
  background: var(--card-bg);
  border-color: var(--fg);
}

.link-btn .icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--card-bg);
  flex-shrink: 0;
}

.link-btn .icon svg {
  width: 16px;
  height: 16px;
}

.link-btn.secondary {
  color: var(--muted);
}

.server-dot {
  display: block;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--muted);
}

.server-dot.awake    { background: #4caf6e; box-shadow: 0 0 6px #4caf6e; }
.server-dot.starting { background: #e0a83b; box-shadow: 0 0 6px #e0a83b; }
.server-dot.asleep   { background: var(--muted); }

.projects {
  width: 100%;
  list-style: none;
  margin: 0 0 32px;
  padding: 0;
  text-align: left;
}

.project {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.project a {
  color: var(--fg);
  font-weight: 600;
  text-decoration: none;
}

.project a:hover {
  text-decoration: underline;
}

.project p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

footer {
  margin-top: 40px;
  color: var(--border);
  font-size: 0.8rem;
}

.game-box {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 5;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  pointer-events: none;
}

.game-box.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.game-box canvas {
  display: block;
  width: 240px;
  height: 128px;
  background: #000;
  border: 1px solid var(--border);
  border-radius: 8px;
  image-rendering: pixelated;
}

.game-credits {
  width: 240px;
  margin: 4px 0 0;
  font-size: 0.7rem;
  color: var(--muted);
  text-align: right;
}

.game-credits a {
  color: var(--muted);
}

.game-credits a:hover {
  color: var(--fg);
}
