:root {
  --page: #eef3f6;
  --surface: #ffffff;
  --surface-soft: #f7fafb;
  --ink: #17222a;
  --muted: #61707b;
  --line: #d7e1e7;
  --green: #0f7a64;
  --green-soft: #dff2ec;
  --blue: #2f6fc1;
  --amber: #b9701f;
  --red: #b94747;
  --shadow: 0 20px 60px rgba(26, 42, 53, 0.12);
}

* {
  box-sizing: border-box;
}

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

body {
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(238, 243, 246, 0.95)),
    linear-gradient(90deg, rgba(23, 34, 42, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(23, 34, 42, 0.04) 1px, transparent 1px),
    var(--page);
  background-size: auto, 40px 40px, 40px 40px, auto;
  font-family: "Pretendard", "Noto Sans KR", "Segoe UI", sans-serif;
}

a {
  color: inherit;
}

.shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 54px 0 48px;
}

.masthead {
  display: grid;
  justify-items: center;
  text-align: center;
  padding: 18px 0 28px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--green);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.masthead h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(42px, 6vw, 72px);
  font-weight: 820;
  line-height: 1;
  letter-spacing: 0;
}

.lead {
  max-width: 620px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.system-state {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-top: 24px;
  padding: 9px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: #34444d;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 10px 30px rgba(26, 42, 53, 0.08);
}

.state-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px var(--green-soft);
}

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

.summary-item,
.service-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.summary-item {
  min-height: 104px;
  padding: 22px;
  text-align: center;
}

.summary-item span,
.service-code,
.service-index,
dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.summary-item strong {
  display: block;
  margin-top: 10px;
  font-size: 20px;
  line-height: 1.35;
}

.services {
  margin-top: 34px;
}

.section-heading {
  display: grid;
  justify-items: center;
  gap: 8px;
  margin-bottom: 18px;
  text-align: center;
}

.section-heading h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

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

.service-card {
  display: flex;
  flex-direction: column;
  min-height: 300px;
  overflow: hidden;
}

.service-index {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-soft);
}

.service-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  padding: 22px;
  text-align: center;
}

.service-top {
  display: grid;
  justify-items: center;
  gap: 12px;
}

.service-code {
  color: var(--green);
}

.service-card h3 {
  margin: 7px 0 0;
  font-size: 22px;
  line-height: 1.22;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border: 1px solid rgba(15, 122, 100, 0.28);
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 12px;
  font-weight: 850;
}

.service-card[data-state="checking"] .badge {
  border-color: rgba(97, 112, 123, 0.3);
  background: #edf2f5;
  color: var(--muted);
}

.service-card[data-state="offline"] .badge {
  border-color: rgba(185, 71, 71, 0.3);
  background: #f7e6e6;
  color: var(--red);
}

.service-card[data-state="offline"] {
  background: rgba(255, 255, 255, 0.72);
}

.desc {
  min-height: 48px;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.service-meta {
  display: grid;
  gap: 10px;
  margin: auto 0 0;
  padding-top: 20px;
}

dt,
dd {
  margin: 0;
}

dd {
  margin-top: 5px;
}

code {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  color: #21313b;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 20px;
}

.btn-primary,
.link-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 850;
}

.btn-primary {
  gap: 8px;
  min-width: 96px;
  padding: 0 16px;
  border: 1px solid #15262d;
  border-radius: 6px;
  background: #17222a;
  color: #ffffff;
}

.btn-primary:hover {
  background: #263844;
}

.btn-primary[aria-disabled="true"] {
  pointer-events: none;
  border-color: #d3dce2;
  background: #dfe6ea;
  color: #7a8790;
}

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

.link-secondary:hover {
  color: var(--ink);
}

.service-bp .service-index {
  border-top: 4px solid var(--blue);
}

.service-pt .service-index {
  border-top: 4px solid var(--green);
}

.service-se .service-index {
  border-top: 4px solid var(--amber);
}

.service-vg .service-index {
  border-top: 4px solid var(--red);
}

@media (max-width: 1040px) {
  .service-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .shell {
    width: min(100% - 28px, 620px);
    padding-top: 34px;
  }

  .masthead h1 {
    font-size: 42px;
  }

  .lead {
    font-size: 15px;
  }

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

  .summary-item {
    min-height: 88px;
  }

  .service-card {
    min-height: 0;
  }
}
