:root {
  --bg-deep: #020f2e;
  --bg-mid: #05214d;
  --ink-main: #e6f2ff;
  --ink-muted: #9fb7d6;
  --stroke: rgba(194, 219, 255, 0.25);
  --ok: #2fd177;
  --warn: #f3be3b;
  --bad: #f95066;
  --card: rgba(8, 22, 53, 0.86);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'IBM Plex Sans', 'Segoe UI', sans-serif;
  color: var(--ink-main);
  background: radial-gradient(circle at 22% 10%, #0a2d66 0%, transparent 28%),
    radial-gradient(circle at 80% 78%, #06285f 0%, transparent 30%),
    linear-gradient(140deg, var(--bg-deep), var(--bg-mid));
  min-height: 100vh;
}

h1,
h2,
h3,
h4 {
  font-family: 'Space Grotesk', sans-serif;
  margin: 0;
  letter-spacing: 0.01em;
}

p {
  margin: 0;
}

.public-body {
  position: relative;
  overflow-x: hidden;
}

.bg-orb {
  position: fixed;
  border-radius: 999px;
  filter: blur(55px);
  pointer-events: none;
  opacity: 0.32;
}

.bg-orb-one {
  width: 360px;
  height: 360px;
  left: -90px;
  top: 90px;
  background: #26b2ff;
}

.bg-orb-two {
  width: 280px;
  height: 280px;
  right: -60px;
  bottom: 120px;
  background: #27da9b;
}

.page-shell {
  width: min(1060px, calc(100vw - 36px));
  margin: 50px auto;
  position: relative;
  z-index: 1;
  animation: appear 460ms ease-out;
}

.hero {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  margin-bottom: 28px;
}

.logo-block {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo-mark {
  width: clamp(56px, 7vw, 82px);
  height: clamp(56px, 7vw, 82px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.logo-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 0 18px rgba(61, 152, 255, 0.38));
}

.logo-block h1 {
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
}

.logo-block p {
  margin-top: 4px;
  color: var(--ink-muted);
}

.subscribe-btn {
  border: 1px solid rgba(81, 180, 255, 0.7);
  background: linear-gradient(180deg, #4eb4ff, #308edf);
  color: #eef7ff;
  border-radius: 8px;
  padding: 12px 18px;
  letter-spacing: 0.15em;
  font-size: 0.73rem;
  cursor: not-allowed;
  opacity: 0.86;
}

.overall-card {
  border-radius: 10px;
  padding: 22px;
  margin-bottom: 30px;
  font-size: clamp(1.1rem, 1.9vw, 1.6rem);
  border: 1px solid transparent;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
}

.status-operational {
  color: var(--ok);
}

.status-degraded,
.status-maintenance {
  color: var(--warn);
}

.status-partial_outage,
.status-major_outage {
  color: var(--bad);
}

.overall-card.status-operational {
  background: linear-gradient(120deg, #2cc06f, #3ae183);
  color: #003215;
}

.overall-card.status-degraded,
.overall-card.status-maintenance {
  background: linear-gradient(120deg, #d2a52d, #f4ca62);
  color: #2a1700;
}

.overall-card.status-partial_outage,
.overall-card.status-major_outage {
  background: linear-gradient(120deg, #be3148, #ff5f7f);
  color: #fff1f4;
}

.component-board,
.incident-card,
.embed-help {
  border: 1px solid var(--stroke);
  background: var(--card);
  backdrop-filter: blur(4px);
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 24px;
}

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

.board-head p {
  color: var(--ink-muted);
}

.component-group + .component-group {
  margin-top: 20px;
}

.component-group > h3 {
  font-size: 1.05rem;
  color: #78c7ff;
  margin-bottom: 8px;
}

.component-row {
  border: 1px solid var(--stroke);
  border-radius: 10px;
  padding: 14px;
  background: rgba(6, 19, 44, 0.9);
}

.component-row + .component-row {
  margin-top: 10px;
}

.component-row-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: baseline;
}

.component-row-head h4 {
  font-size: 1.02rem;
}

.component-row-head p {
  margin-top: 3px;
  color: var(--ink-muted);
  font-size: 0.92rem;
}

.component-status {
  font-weight: 600;
  white-space: nowrap;
}

.uptime-bars {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(90, minmax(2px, 1fr));
  gap: 2px;
}

.uptime-bar {
  display: block;
  height: 26px;
  border-radius: 2px;
  opacity: 0.94;
  cursor: pointer;
}

.bar-operational {
  background: #31d07a;
}

.bar-degraded {
  background: #f0c349;
}

.bar-partial_outage,
.bar-major_outage {
  background: #f9536b;
}

.uptime-foot {
  margin-top: 7px;
  display: flex;
  justify-content: space-between;
  color: var(--ink-muted);
  font-size: 0.85rem;
}

.uptime-foot strong {
  color: #b6ddff;
}

.uptime-tooltip {
  --arrow-x: 140px;
  position: absolute;
  z-index: 50;
  min-width: 280px;
  max-width: min(380px, calc(100vw - 16px));
  padding: 14px 16px;
  border-radius: 4px;
  border: 1px solid rgba(168, 211, 255, 0.6);
  background: #031737;
  box-shadow: 0 14px 26px rgba(1, 7, 22, 0.52);
  pointer-events: none;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 110ms ease, transform 110ms ease;
}

.uptime-tooltip.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.uptime-tooltip::before {
  content: '';
  position: absolute;
  left: var(--arrow-x);
  bottom: -8px;
  transform: translateX(-50%);
  border-style: solid;
  border-width: 8px 8px 0 8px;
  border-color: rgba(168, 211, 255, 0.6) transparent transparent transparent;
}

.uptime-tooltip::after {
  content: '';
  position: absolute;
  left: var(--arrow-x);
  bottom: -6px;
  transform: translateX(-50%);
  border-style: solid;
  border-width: 7px 7px 0 7px;
  border-color: #031737 transparent transparent transparent;
}

.uptime-tooltip.below::before {
  top: -8px;
  bottom: auto;
  border-width: 0 8px 8px 8px;
  border-color: transparent transparent rgba(168, 211, 255, 0.6) transparent;
}

.uptime-tooltip.below::after {
  top: -6px;
  bottom: auto;
  border-width: 0 7px 7px 7px;
  border-color: transparent transparent #031737 transparent;
}

.uptime-tooltip-date {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.7rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.15;
}

.uptime-tooltip-row {
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #f2f8ff;
  font-size: 1.05rem;
}

.uptime-tooltip-icon {
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1;
}

.uptime-tooltip[data-tone='operational'] .uptime-tooltip-icon {
  color: #2fd177;
}

.uptime-tooltip[data-tone='degraded'] .uptime-tooltip-icon,
.uptime-tooltip[data-tone='maintenance'] .uptime-tooltip-icon {
  color: #f3be3b;
}

.uptime-tooltip[data-tone='partial_outage'] .uptime-tooltip-icon,
.uptime-tooltip[data-tone='major_outage'] .uptime-tooltip-icon {
  color: #f95066;
}

.incident-item + .incident-item {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(195, 219, 255, 0.15);
}

.incident-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.incident-head h3 {
  font-size: 1rem;
}

.incident-status {
  color: #a7d2ff;
  font-size: 0.82rem;
  border: 1px solid rgba(120, 190, 255, 0.5);
  border-radius: 999px;
  padding: 3px 8px;
}

.incident-item p {
  margin-bottom: 4px;
  color: #d9eaff;
}

.incident-components {
  color: #9fc6e7;
  font-size: 0.9rem;
}

.incident-item small {
  color: #8eb1d3;
}

.past-incidents > h2 {
  margin-bottom: 8px;
}

.past-day {
  border-top: 1px solid rgba(195, 219, 255, 0.45);
  padding-top: 12px;
}

.past-day + .past-day {
  margin-top: 18px;
}

.past-day h3 {
  font-size: clamp(1.2rem, 2.4vw, 2rem);
  margin-bottom: 8px;
}

.past-empty {
  color: #b4cae3;
}

.past-event {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 9px;
  background: rgba(5, 17, 40, 0.66);
  border: 1px solid rgba(195, 219, 255, 0.18);
}

.past-event + .past-event {
  margin-top: 8px;
}

.past-event h4 {
  font-size: 1rem;
}

.embed-help pre {
  background: rgba(3, 14, 36, 0.9);
  border: 1px solid var(--stroke);
  border-radius: 8px;
  padding: 12px;
  overflow-x: auto;
}

.embed-help code {
  color: #b7ddff;
}

.widget-body {
  margin: 0;
  background: transparent;
}

.widget-shell {
  border: 1px solid rgba(95, 164, 244, 0.4);
  background: linear-gradient(168deg, rgba(3, 17, 45, 0.98), rgba(7, 29, 67, 0.96));
  border-radius: 12px;
  padding: 14px;
  color: #eaf5ff;
  height: 100vh;
}

.widget-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: baseline;
  margin-bottom: 8px;
}

.widget-head h1 {
  font-size: 0.95rem;
}

.widget-overall {
  font-size: 0.74rem;
  font-weight: 700;
}

.widget-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.widget-list li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid rgba(161, 203, 252, 0.2);
  padding: 8px 0;
  font-size: 0.85rem;
}

.widget-list li strong {
  white-space: nowrap;
}

.widget-incident {
  margin-top: 10px;
  color: #ffc67a;
  font-size: 0.82rem;
}

.simple-center {
  display: grid;
  place-items: center;
}

.simple-center main {
  background: rgba(7, 20, 48, 0.9);
  border: 1px solid var(--stroke);
  border-radius: 12px;
  padding: 26px;
}

.simple-center a {
  color: #77c4ff;
}

@keyframes appear {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .subscribe-btn {
    width: 100%;
  }

  .component-row-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .uptime-bars {
    height: auto;
  }

  .uptime-bar {
    height: 18px;
  }

  .uptime-foot {
    font-size: 0.78rem;
  }
}
