:root {
  color-scheme: dark;
  --bg: #07100d;
  --panel: #0d1814;
  --panel-2: #111f19;
  --line: rgba(185, 222, 202, .13);
  --text: #eef7f1;
  --muted: #8fa69a;
  --accent: #42d7c5;
  --ok: #57db8b;
  --warn: #f1c75b;
  --bad: #f07d78;
  --radius: 18px;
}

* { box-sizing: border-box; }
html { background: var(--bg); scroll-behavior: smooth; }
body { margin: 0; background: radial-gradient(circle at 75% 0, rgba(39, 123, 103, .12), transparent 32rem), var(--bg); color: var(--text); font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }

.site-header { min-height: 76px; padding: 0 max(24px, calc((100vw - 1180px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 1px solid var(--line); background: rgba(7, 16, 13, .92); position: sticky; top: 0; z-index: 10; backdrop-filter: blur(14px); }
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand img { width: 44px; height: 44px; object-fit: contain; }
.brand span { display: grid; line-height: 1.05; }
.brand strong { font-size: 17px; letter-spacing: .02em; }
.brand small { margin-top: 5px; color: var(--accent); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
nav { display: flex; align-items: center; gap: 8px; }
nav a { padding: 10px 13px; border-radius: 10px; color: var(--muted); font-size: 14px; font-weight: 650; }
nav a:hover, nav a.active { color: var(--text); background: rgba(255,255,255,.055); }

main, footer { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }
.hero { padding: 76px 0 42px; display: flex; align-items: end; justify-content: space-between; gap: 36px; }
.eyebrow { margin: 0 0 10px; color: var(--accent); font-size: 11px; font-weight: 850; letter-spacing: .16em; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 14px; max-width: 760px; font-size: clamp(36px, 5vw, 64px); line-height: .98; letter-spacing: -.045em; }
.hero-copy { max-width: 680px; margin-bottom: 0; color: #b9c9c0; font-size: clamp(16px, 2vw, 19px); line-height: 1.7; }
.refresh-panel { min-width: 230px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,255,255,.025); }
.refresh-panel p { margin-bottom: 5px; color: var(--muted); font-size: 12px; }
.refresh-panel strong { display: block; margin-bottom: 14px; font-size: 15px; }
.refresh-panel button, .copy-address { border: 0; border-radius: 9px; cursor: pointer; font-weight: 800; }
.refresh-panel button { width: 100%; padding: 10px 14px; color: #04110d; background: var(--accent); }
.refresh-panel button:disabled { cursor: wait; opacity: .65; }

.overview { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 22px; padding: 26px; border: 1px solid rgba(87, 219, 139, .27); border-radius: var(--radius); background: linear-gradient(110deg, rgba(87, 219, 139, .095), rgba(255,255,255,.025)); }
.overview.partial { border-color: rgba(241, 199, 91, .32); background: linear-gradient(110deg, rgba(241, 199, 91, .095), rgba(255,255,255,.025)); }
.overview.down { border-color: rgba(240, 125, 120, .32); background: linear-gradient(110deg, rgba(240, 125, 120, .09), rgba(255,255,255,.025)); }
.overview-light { width: 14px; height: 14px; border-radius: 999px; background: var(--ok); box-shadow: 0 0 0 8px rgba(87, 219, 139, .1); }
.partial .overview-light { background: var(--warn); box-shadow: 0 0 0 8px rgba(241, 199, 91, .1); }
.down .overview-light { background: var(--bad); box-shadow: 0 0 0 8px rgba(240, 125, 120, .1); }
.loading .overview-light { background: var(--muted); animation: pulse 1.2s infinite; }
.overview h2 { margin-bottom: 5px; font-size: 24px; }
.overview p:last-child { margin-bottom: 0; color: var(--muted); }
.overview-count { text-align: right; }
.overview-count strong { display: block; font-size: 28px; }
.overview-count span { color: var(--muted); font-size: 12px; }
.notice { margin-top: 18px; padding: 16px 18px; border: 1px solid rgba(240, 125, 120, .3); border-radius: 12px; color: #ffd1ce; background: rgba(240, 125, 120, .08); }
.notice span { margin-left: 8px; color: #d9b1ae; }

.status-section { padding-top: 56px; }
.section-heading { margin-bottom: 18px; display: flex; align-items: end; justify-content: space-between; gap: 20px; }
.section-heading h2 { margin-bottom: 0; font-size: 28px; letter-spacing: -.025em; }
.section-summary { padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); font-size: 12px; }
.status-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.status-card { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 15px; background: var(--panel); transition: border-color .18s, transform .18s; }
.status-card:hover { transform: translateY(-2px); border-color: rgba(66, 215, 197, .28); }
.status-card.offline { opacity: .82; }
.card-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: start; gap: 11px; }
.state-dot { width: 9px; height: 9px; margin-top: 6px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 5px rgba(87, 219, 139, .08); }
.offline .state-dot { background: var(--bad); box-shadow: 0 0 0 5px rgba(240, 125, 120, .08); }
.service-name { margin-bottom: 5px; overflow: hidden; font-size: 16px; text-overflow: ellipsis; white-space: nowrap; }
.service-address { margin-bottom: 0; overflow: hidden; color: var(--muted); font-family: ui-monospace, "Cascadia Code", monospace; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.state-label { color: var(--ok); font-size: 10px; font-weight: 850; letter-spacing: .12em; }
.offline .state-label { color: var(--bad); }
.metrics { margin-top: 22px; display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.metrics > div { padding: 12px; border-radius: 10px; background: var(--panel-2); }
.metrics span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .09em; }
.metrics strong { font-size: 16px; }
.service-detail { min-height: 39px; margin: 15px 0 0; color: #afc1b7; font-size: 12px; line-height: 1.55; }
.card-actions { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.copy-address { padding: 7px 9px; color: var(--text); background: rgba(255,255,255,.065); font-size: 11px; }
.copy-address:hover { background: rgba(66, 215, 197, .14); }
.copy-address.copied { color: var(--accent); }
.service-updated { color: var(--muted); font-size: 10px; }

.skeleton-grid::before, .skeleton-grid::after { content: ""; min-height: 250px; border: 1px solid var(--line); border-radius: 15px; background: linear-gradient(100deg, var(--panel) 25%, #14231d 38%, var(--panel) 52%); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
footer { margin-top: 72px; padding: 28px 0 38px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 20px; color: var(--muted); font-size: 12px; }
footer div { display: flex; gap: 18px; }
footer a:hover { color: var(--accent); }

@keyframes shimmer { to { background-position-x: -200%; } }
@keyframes pulse { 50% { opacity: .45; } }
@media (max-width: 900px) { .status-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 700px) {
  .site-header { min-height: auto; padding: 13px 18px; align-items: flex-start; }
  nav { display: none; }
  main, footer { width: min(100% - 30px, 1180px); }
  .hero { padding-top: 48px; align-items: stretch; flex-direction: column; }
  .refresh-panel { min-width: 0; }
  .overview { grid-template-columns: auto 1fr; }
  .overview-count { grid-column: 2; text-align: left; }
  .status-grid { grid-template-columns: 1fr; }
  .section-heading { align-items: start; }
  footer { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; } }
