:root {
  color-scheme: dark;
  --bg: #101214;
  --panel: #181c20;
  --panel-strong: #1f2429;
  --text: #f8fafc;
  --muted: #aeb7c2;
  --line: #2d343b;
  --accent: #2dd4bf;
  --accent-2: #f8c14a;
  --accent-3: #ef6f6c;
  --shadow: 0 24px 70px rgb(0 0 0 / 35%);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    linear-gradient(120deg, rgb(45 212 191 / 12%), transparent 34%),
    linear-gradient(240deg, rgb(248 193 74 / 12%), transparent 32%),
    var(--bg);
}

a {
  color: inherit;
}

.shell {
  width: min(1120px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 56px) 0;
  display: grid;
  align-content: center;
  gap: 24px;
}

.masthead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(3.6rem, 12vw, 8.5rem);
  line-height: 0.88;
  letter-spacing: 0;
}

.coolify-link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgb(24 28 32 / 82%);
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow);
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgb(45 212 191 / 14%);
}

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

.overview article {
  min-height: 104px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgb(24 28 32 / 82%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.metric {
  font-size: 2rem;
  font-weight: 850;
}

.label,
.app-card small,
.app-card em {
  color: var(--muted);
}

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

.app-card {
  min-height: 142px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: 1fr auto;
  gap: 18px;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.app-card:hover,
.app-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgb(45 212 191 / 70%);
  background: var(--panel-strong);
  outline: none;
}

.app-icon {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #111418;
  font-size: 0.92rem;
  font-weight: 900;
}

.app-icon.gold {
  background: var(--accent-2);
}

.app-icon.teal {
  background: var(--accent);
}

.app-icon.red {
  background: var(--accent-3);
}

.app-icon.violet {
  background: #a78bfa;
}

.app-icon.blue {
  background: #60a5fa;
}

.app-icon.green {
  background: #86efac;
}

.app-icon.steel {
  background: #cbd5e1;
}

.app-card span {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.app-card strong {
  font-size: clamp(1.2rem, 3vw, 1.85rem);
  line-height: 1.02;
}

.app-card small,
.app-card em {
  font-size: 0.95rem;
  font-style: normal;
}

.app-card em {
  grid-column: 1 / -1;
  align-self: end;
  overflow-wrap: anywhere;
}

.app-card.primary {
  border-color: rgb(248 193 74 / 45%);
}

.app-card.utility {
  border-color: rgb(239 111 108 / 45%);
}

@media (max-width: 720px) {
  .shell {
    align-content: start;
  }

  .masthead {
    align-items: flex-start;
    flex-direction: column;
  }

  .overview,
  .apps {
    grid-template-columns: 1fr;
  }

  .overview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .overview article {
    min-height: 84px;
    padding: 14px;
  }

  .metric {
    font-size: 1.55rem;
  }

  .label {
    font-size: 0.82rem;
  }
}

@media (max-width: 430px) {
  .shell {
    width: min(100% - 20px, 1120px);
  }

  .overview {
    gap: 8px;
  }

  .app-card {
    min-height: 132px;
    padding: 16px;
    gap: 14px;
  }
}
