:root {
  color-scheme: light;
  --bg: #f5f7f9;
  --surface: #ffffff;
  --surface-soft: #eef3f7;
  --text: #17202a;
  --muted: #637183;
  --line: #d8e0e7;
  --accent: #1f7a6d;
  --accent-dark: #155b52;
  --accent-soft: #dff4ef;
  --warning: #9a6a13;
  --shadow: 0 18px 50px rgba(32, 43, 54, 0.12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(31, 122, 109, 0.1), transparent 34%),
    radial-gradient(circle at 92% 8%, rgba(68, 102, 139, 0.14), transparent 30%),
    var(--bg);
  color: var(--text);
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
  padding: 0 42px;
  border-bottom: 1px solid rgba(216, 224, 231, 0.86);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 850;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.site-nav a,
.portal-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 700;
}

.site-nav a:hover,
.site-nav a.active {
  background: var(--surface-soft);
  color: var(--text);
}

.portal-link {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
}

.hero,
.section,
.content-page {
  width: min(1160px, calc(100% - 48px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 460px);
  gap: 48px;
  align-items: center;
  min-height: calc(100vh - 72px);
  padding: 54px 0;
}

.hero-copy {
  max-width: 680px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  font-size: clamp(40px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: 0;
}

.content-page h1 {
  font-size: clamp(36px, 5vw, 58px);
}

h2 {
  font-size: 26px;
  line-height: 1.14;
}

h3 {
  font-size: 18px;
}

.hero-copy > p:not(.eyebrow),
.page-heading > p,
.section p,
.feature-grid p,
.docs-grid p,
.status-stack p,
.contact-card p,
.incident-log p {
  color: var(--muted);
  line-height: 1.65;
}

.hero-copy > p:not(.eyebrow) {
  max-width: 620px;
  margin-top: 22px;
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 800;
  cursor: pointer;
}

.button.primary {
  background: var(--accent);
  color: #fff;
}

.button.primary:hover {
  background: var(--accent-dark);
}

.button.secondary {
  border-color: var(--line);
  background: var(--surface);
  color: var(--text);
}

.service-panel,
.feature-grid article,
.docs-grid article,
.contact-form,
.contact-card,
.status-stack article,
.incident-log,
.error-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 10px 34px rgba(32, 43, 54, 0.08);
}

.service-panel {
  padding: 18px;
}

.panel-bar {
  display: flex;
  gap: 7px;
  padding-bottom: 18px;
}

.panel-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line);
}

.terminal-line {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 42px;
  gap: 12px;
  align-items: center;
  min-height: 44px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

.terminal-line code {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.terminal-line strong {
  color: var(--accent);
  text-align: right;
}

.routing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.routing-grid div,
.stats-list div {
  padding: 16px;
  border-radius: 8px;
  background: var(--surface-soft);
}

.routing-grid small,
.stats-list dt {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.routing-grid b,
.stats-list dd {
  display: block;
  margin: 8px 0 0;
  font-size: 27px;
  line-height: 1;
}

.section {
  padding: 42px 0;
}

.section-heading {
  max-width: 680px;
  margin-bottom: 20px;
}

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

.feature-grid article,
.docs-grid article {
  padding: 22px;
}

.feature-grid h3,
.docs-grid h2 {
  margin-bottom: 10px;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  gap: 28px;
  align-items: start;
  padding-bottom: 72px;
}

.split > div:first-child {
  max-width: 660px;
}

.split h2 {
  margin-bottom: 14px;
}

.stats-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.content-page {
  padding: 56px 0 78px;
}

.page-heading {
  max-width: 760px;
  margin-bottom: 26px;
}

.page-heading h1 {
  margin-bottom: 14px;
}

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

pre {
  overflow: auto;
  margin: 16px 0 0;
  padding: 14px;
  border-radius: 8px;
  background: #14202a;
  color: #dff4ef;
}

.status-stack {
  display: grid;
  gap: 12px;
}

.status-stack article {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 18px;
}

.status-stack h2,
.incident-log h2,
.contact-card h2 {
  font-size: 18px;
  margin-bottom: 4px;
}

.status-stack strong {
  color: var(--accent);
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #25a46b;
  box-shadow: 0 0 0 5px rgba(37, 164, 107, 0.13);
}

.incident-log {
  margin-top: 16px;
  padding: 22px;
}

.incident-log div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 14px;
  padding-top: 16px;
  margin-top: 16px;
  border-top: 1px solid var(--line);
}

.incident-log time {
  color: var(--muted);
  font-weight: 750;
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 16px;
  align-items: start;
}

.contact-form {
  display: grid;
  gap: 14px;
  padding: 22px;
}

.contact-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-weight: 750;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text);
  background: #fff;
}

.contact-form textarea {
  resize: vertical;
}

.contact-form button {
  justify-self: start;
}

.contact-card {
  padding: 22px;
}

.contact-card hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 20px 0;
}

.error-page {
  display: grid;
  place-items: center;
  min-height: calc(100vh - 72px);
  padding: 24px;
}

.error-panel {
  width: min(100%, 540px);
  padding: 34px;
}

.error-panel h1 {
  margin-bottom: 12px;
}

.error-panel p:not(.eyebrow) {
  margin-bottom: 22px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
  padding: 28px 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.7);
}

.site-footer span {
  color: var(--text);
  font-weight: 800;
}

.site-footer a {
  text-decoration: none;
}

@media (max-width: 900px) {
  .site-header {
    padding: 0 24px;
  }

  .portal-link {
    display: none;
  }

  .hero,
  .split,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .site-header {
    position: initial;
    flex-wrap: wrap;
    gap: 12px;
    padding: 16px 20px;
  }

  .site-nav {
    width: 100%;
    justify-content: space-between;
  }

  .hero,
  .section,
  .content-page {
    width: min(100% - 32px, 1160px);
  }

  .docs-grid,
  .routing-grid {
    grid-template-columns: 1fr;
  }

  .status-stack article,
  .incident-log div {
    grid-template-columns: 1fr;
  }

  h1,
  .content-page h1 {
    font-size: 38px;
  }
}
