:root {
  color-scheme: dark;
  --bg: #0b1012;
  --surface: #171d20;
  --surface-raised: #1d2428;
  --surface-soft: #222a2e;
  --line: #30393e;
  --line-soft: rgba(126, 145, 151, 0.14);
  --text: #f1f5f3;
  --muted: #9da7aa;
  --faint: #687378;
  --accent: #1fc99b;
  --accent-bright: #5ce8be;
  --accent-deep: #0c8065;
  --font-ui: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-family: var(--font-ui);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 300px;
  min-height: 100%;
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(circle at 36% 22%, rgba(21, 151, 115, 0.15), transparent 28rem),
    radial-gradient(circle at 84% 0%, rgba(38, 75, 133, 0.18), transparent 34rem),
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: auto, auto, 68px 68px, 68px 68px;
  display: flex;
  flex-direction: column;
  font-size: 15px;
  line-height: 1.5;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  top: -80px;
  left: 18px;
  z-index: 20;
  padding: 10px 14px;
  color: var(--bg);
  background: var(--accent-bright);
  border-radius: 7px;
  text-decoration: none;
}

.skip-link:focus {
  top: 14px;
}

.site-header {
  position: relative;
  z-index: 5;
  border-bottom: 1px solid rgba(136, 151, 157, 0.17);
  background: rgba(11, 16, 18, 0.78);
  backdrop-filter: blur(18px);
}

.header-inner,
.app-shell,
footer {
  width: min(1240px, calc(100% - 48px));
  margin-inline: auto;
}

.header-inner {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark,
.app-mark,
.core-mark {
  position: relative;
  display: grid;
  place-items: center;
}

.brand-mark {
  width: 34px;
  height: 34px;
  background: linear-gradient(145deg, var(--accent-bright), var(--accent-deep));
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 10px 17px 10px 17px;
  box-shadow: 0 0 24px rgba(31, 201, 155, 0.18);
  transform: rotate(-8deg);
}

.brand-mark span,
.app-mark span,
.core-mark span {
  width: 42%;
  height: 42%;
  border: 2px solid rgba(255, 255, 255, 0.8);
  border-top-color: transparent;
  border-radius: 50%;
}

.header-meta {
  display: flex;
  align-items: center;
  gap: 26px;
  color: var(--muted);
  font-size: 0.78rem;
}

.header-link {
  white-space: nowrap;
}

.status,
.tile-status,
.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.status {
  padding: 8px 11px;
  color: #b7d5cc;
  background: rgba(31, 201, 155, 0.08);
  border: 1px solid rgba(31, 201, 155, 0.18);
  border-radius: 7px;
}

.status-light,
.tile-status i {
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(31, 201, 155, 0.1), 0 0 12px rgba(31, 201, 155, 0.6);
}

.app-shell {
  flex: 1;
}

.hero {
  min-height: 670px;
  padding: clamp(80px, 11vw, 145px) 0 100px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
  align-items: center;
  gap: clamp(60px, 9vw, 130px);
}

.eyebrow {
  margin: 0 0 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--accent-bright);
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.eyebrow > span {
  width: 26px;
  height: 1px;
  background: var(--accent);
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 28px;
  font-size: clamp(3.35rem, 7.5vw, 7rem);
  font-weight: 650;
  line-height: 0.94;
  letter-spacing: -0.065em;
}

h1 em {
  color: var(--accent-bright);
  font-style: normal;
}

.subtitle {
  max-width: 620px;
  margin-bottom: 34px;
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.16rem);
}

.hero-action {
  display: inline-flex;
  align-items: center;
  gap: 38px;
  padding: 13px 16px;
  color: #082219;
  background: var(--accent);
  border: 1px solid var(--accent-bright);
  border-radius: 7px;
  box-shadow: 0 8px 30px rgba(16, 139, 106, 0.2);
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  transition: transform 160ms ease, background 160ms ease;
}

.hero-action:hover,
.hero-action:focus-visible {
  background: var(--accent-bright);
  transform: translateY(-2px);
  outline: 2px solid rgba(92, 232, 190, 0.34);
  outline-offset: 3px;
}

.system-card {
  position: relative;
  overflow: hidden;
  padding: 18px;
  background: linear-gradient(145deg, rgba(31, 39, 43, 0.94), rgba(19, 25, 28, 0.94));
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.3);
}

.system-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.04), transparent 32%);
  pointer-events: none;
}

.system-card-head,
.metric-row,
.system-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.system-card-head {
  position: relative;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--line);
  color: #dce2e0;
  font-size: 0.82rem;
  font-weight: 600;
}

.live-pill {
  padding: 4px 8px;
  color: var(--accent-bright);
  background: rgba(31, 201, 155, 0.09);
  border: 1px solid rgba(31, 201, 155, 0.18);
  border-radius: 999px;
  font-size: 0.66rem;
  text-transform: uppercase;
}

.live-pill::before {
  content: "";
  width: 5px;
  height: 5px;
  background: currentColor;
  border-radius: 50%;
}

.system-visual {
  position: relative;
  height: 240px;
  display: grid;
  place-items: center;
}

.system-visual::before,
.system-visual::after {
  content: "";
  position: absolute;
  background: rgba(68, 82, 88, 0.36);
}

.system-visual::before {
  width: 1px;
  height: 78%;
}

.system-visual::after {
  width: 78%;
  height: 1px;
}

.orbit {
  position: absolute;
  border: 1px solid rgba(92, 232, 190, 0.2);
  border-radius: 50%;
}

.orbit-one {
  width: 150px;
  height: 150px;
  box-shadow: 0 0 60px rgba(31, 201, 155, 0.08);
}

.orbit-two {
  width: 205px;
  height: 100px;
  transform: rotate(-28deg);
}

.core-mark {
  width: 70px;
  height: 70px;
  z-index: 1;
  background: linear-gradient(145deg, var(--accent-bright), #0ca47b);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 20px 38px 20px 38px;
  box-shadow: 0 0 45px rgba(31, 201, 155, 0.38);
  transform: rotate(-8deg);
}

.metric-row {
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 0.75rem;
}

.metric-row strong {
  color: var(--text);
  font-weight: 600;
}

.meter {
  height: 5px;
  overflow: hidden;
  background: #323b3f;
  border-radius: 99px;
}

.meter span {
  width: 100%;
  height: 100%;
  display: block;
  background: linear-gradient(90deg, var(--accent-deep), var(--accent-bright));
  border-radius: inherit;
}

.system-stats {
  margin-top: 18px;
}

.system-stats > span {
  width: 50%;
  color: var(--faint);
  font-size: 0.68rem;
  text-transform: uppercase;
}

.system-stats > span + span {
  padding-left: 18px;
  border-left: 1px solid var(--line);
}

.system-stats strong {
  margin-bottom: 2px;
  display: block;
  color: #dfe6e4;
  font-size: 1rem;
  font-weight: 600;
  text-transform: none;
}

.directory {
  padding: 90px 0 130px;
  border-top: 1px solid var(--line);
}

.section-heading {
  margin-bottom: 35px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.section-heading .eyebrow {
  margin-bottom: 15px;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 620;
  line-height: 1;
  letter-spacing: -0.045em;
}

.section-index {
  color: var(--faint);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr));
  gap: 22px;
}

.app-tile {
  position: relative;
  min-height: 370px;
  overflow: hidden;
  padding: 22px;
  color: var(--text);
  background:
    radial-gradient(circle at 82% 82%, rgba(31, 201, 155, 0.12), transparent 38%),
    var(--surface);
  border: 1px solid var(--line);
  border-radius: 11px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  text-decoration: none;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.app-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(126, 145, 151, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 145, 151, 0.06) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.7;
  pointer-events: none;
}

.app-tile:hover,
.app-tile:focus-visible {
  z-index: 1;
  border-color: rgba(92, 232, 190, 0.52);
  background-color: var(--surface-raised);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.24);
  transform: translateY(-4px);
  outline: none;
}

.tile-topline,
.tile-content,
.open-label {
  position: relative;
  z-index: 1;
}

.tile-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--faint);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
}

.tile-status {
  color: #83b8a8;
  letter-spacing: 0;
}

.tile-status i {
  width: 5px;
  height: 5px;
  box-shadow: 0 0 9px rgba(31, 201, 155, 0.7);
}

.tile-content {
  align-self: center;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.app-mark {
  width: 58px;
  height: 58px;
  margin-bottom: 24px;
  background: linear-gradient(145deg, var(--accent-bright), var(--accent-deep));
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 15px 29px 15px 29px;
  box-shadow: 0 10px 35px rgba(31, 201, 155, 0.2);
  transform: rotate(-8deg);
}

.app-name {
  margin-bottom: 9px;
  font-size: clamp(1.7rem, 4vw, 2.25rem);
  font-weight: 620;
  line-height: 1;
  letter-spacing: -0.04em;
}

.app-description {
  max-width: 330px;
  color: var(--muted);
  font-size: 0.88rem;
}

.open-label {
  padding-top: 17px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  color: #cbd4d1;
  font-size: 0.78rem;
  font-weight: 600;
}

.open-label span:last-child {
  color: var(--accent-bright);
  font-size: 1rem;
  transition: transform 180ms ease;
}

.app-tile:hover .open-label span:last-child {
  transform: translate(2px, -2px);
}

footer {
  padding-block: 22px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  gap: 20px;
  color: var(--faint);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

footer span:last-child {
  display: flex;
  align-items: center;
  gap: 9px;
}

footer i {
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
}

@media (max-width: 820px) {
  .header-link {
    display: none;
  }

  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 60px;
  }

  .system-card {
    width: min(100%, 520px);
  }
}

@media (max-width: 560px) {
  .header-inner,
  .app-shell,
  footer {
    width: min(100% - 28px, 1240px);
  }

  .header-inner {
    min-height: 66px;
  }

  .status {
    width: 36px;
    height: 36px;
    justify-content: center;
    padding: 0;
    font-size: 0;
  }

  h1 {
    font-size: clamp(3rem, 15vw, 4.5rem);
  }

  .hero {
    padding: 70px 0 80px;
  }

  .system-visual {
    height: 190px;
  }

  .directory {
    padding: 70px 0 90px;
  }

  .section-heading {
    align-items: flex-start;
  }

  .app-tile {
    min-height: 340px;
  }

  footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-action,
  .app-tile,
  .open-label span:last-child {
    transition: none;
  }
}
