/* Visual styling for the public NAS status homepage. */

:root {
  color-scheme: light;
  --bg: #f7f8fa;
  --panel: #ffffff;
  --text: #17202a;
  --muted: #647184;
  --line: #dfe5ec;
  --online: #168a4a;
  --degraded: #b7791f;
  --offline: #b42318;
  --accent: #2457a6;
}

* {
  box-sizing: border-box;
}

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

.shell {
  width: min(1040px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
}

.status-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: clamp(32px, 6vw, 54px);
  line-height: 1;
}

.summary {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.summary-pill,
.state {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.summary-pill.online,
.state.online {
  background: #e8f5ee;
  color: var(--online);
}

.summary-pill.degraded,
.state.degraded {
  background: #fff6df;
  color: var(--degraded);
}

.summary-pill.offline,
.state.offline {
  background: #fff0ed;
  color: var(--offline);
}

.meta-bar {
  display: flex;
  align-items: center;
  min-height: 42px;
  margin-bottom: 20px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.groups {
  display: grid;
  gap: 28px;
}

.group h2 {
  margin-bottom: 12px;
  font-size: 18px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
}

.service {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 92px;
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.service-main {
  display: flex;
  align-items: flex-start;
  min-width: 0;
  gap: 12px;
}

.dot {
  width: 10px;
  height: 10px;
  margin-top: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
}

.dot.online {
  background: var(--online);
}

.dot.degraded {
  background: var(--degraded);
}

.dot.offline {
  background: var(--offline);
}

.service h3 {
  margin-bottom: 5px;
  font-size: 17px;
}

.service p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.service-actions {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 8px;
}

.service-actions a {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  color: #ffffff;
  background: var(--accent);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 24px, 1040px);
    padding: 24px 0;
  }

  .status-head,
  .service {
    align-items: flex-start;
    flex-direction: column;
  }

  .summary {
    justify-content: flex-start;
  }
}
