* { box-sizing: border-box; }

html {
  overflow-x: hidden;
  scroll-behavior: smooth;
  scrollbar-gutter: stable;
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  color: var(--atonal-ink);
  background: var(--atonal-paper);
  font-family: var(--atonal-mono);
}

.atlas-topbar {
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(16px);
}

main { overflow: hidden; }

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  min-height: calc(100svh - 64px);
  grid-template-columns: minmax(0, 1fr) minmax(420px, .7fr);
  align-items: center;
  gap: clamp(32px, 6vw, 84px);
  padding: clamp(74px, 9vh, 112px) max(5vw, calc((100vw - 1240px) / 2)) 124px;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background: url("/assets/network-poster.jpg") center / cover no-repeat;
  pointer-events: none;
}

.hero-media video,
.hero-wash {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-media video {
  object-fit: cover;
  object-position: center;
  filter: saturate(.9) contrast(1.05) brightness(.62);
}

.hero-wash {
  background:
    linear-gradient(90deg, rgba(7, 19, 51, .98) 0%, rgba(7, 19, 51, .79) 45%, rgba(7, 19, 51, .67) 100%),
    linear-gradient(180deg, rgba(7, 19, 51, .22), rgba(7, 19, 51, .9));
}

.hero-copy,
.network-console { min-width: 0; }

.eyebrow {
  margin: 0 0 17px;
  color: #aeb9ff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .15em;
}

h1 {
  margin: 0;
  color: white;
  font-family: var(--atonal-display);
  font-size: clamp(64px, 7vw, 108px);
  font-weight: 400;
  letter-spacing: -.035em;
  line-height: .88;
}

h1 span { color: #5970ff; }

.lede {
  max-width: 650px;
  margin: 25px 0 28px;
  color: #d8def0;
  font-size: 17px;
  line-height: 1.7;
}

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

.network-console {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 24px;
  background: rgba(7, 19, 51, .62);
  box-shadow: 0 28px 80px rgba(0, 0, 0, .34), 0 0 0 1px rgba(89, 112, 255, .08);
  backdrop-filter: blur(20px) saturate(1.15);
}

.window-bar {
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  border-bottom: 1px solid rgba(255, 255, 255, .14);
  color: white;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
}

.window-bar b { color: #72e6b5; }
.network-body { padding: 25px; }

.network-body > p {
  margin: 0 0 18px;
  color: #91a2ff;
  font-size: 12px;
}

.network-body dl {
  margin: 0;
  border: 1px solid rgba(255, 255, 255, .15);
  background: rgba(255, 255, 255, .045);
}

.network-body dl div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
}

.network-body dl div:last-child { border-bottom: 0; }
.network-body dt { color: #99a4c1; font-size: 11px; letter-spacing: .08em; }
.network-body dd { margin: 0; color: white; font-size: 12px; font-weight: 700; text-align: right; }

.route {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 21px;
  color: #a7b0c9;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
}

.route b { color: #91a2ff; }

.hero .atlas-link-button.primary {
  border-color: white;
  color: var(--atonal-blue);
  background: white;
}

.hero .atlas-link-button:not(.primary) {
  border-color: rgba(255, 255, 255, .58);
  color: white;
}

.hero .atlas-link-button:hover { box-shadow: 5px 5px 0 rgba(89, 112, 255, .32); }

.market-route {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 0;
  padding: 0 max(5vw, calc((100vw - 1240px) / 2));
  border-top: 1px solid rgba(255, 255, 255, .18);
  color: white;
  background: rgba(18, 51, 245, .9);
  list-style: none;
  backdrop-filter: blur(16px);
}

.market-route li {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 78px;
  grid-template-columns: auto 1fr;
  align-content: center;
  column-gap: 10px;
  padding: 12px 18px;
  border-right: 1px solid rgba(255, 255, 255, .16);
}

.market-route li:first-child { border-left: 1px solid rgba(255, 255, 255, .16); }
.market-route li:not(:last-child)::after { content: "→"; position: absolute; z-index: 1; top: 29px; right: -7px; color: white; }
.market-route small { grid-row: 1 / 3; align-self: center; color: #b9c3ff; font-size: 10px; }
.market-route span { font-size: 12px; font-weight: 700; letter-spacing: .1em; }
.market-route b { overflow: hidden; color: #dce1ff; font-size: 10px; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }

.product-grid {
  display: grid;
  width: min(1180px, calc(100% - 40px));
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 14px;
  margin: 64px auto 82px;
}

.product-card {
  display: flex;
  position: relative;
  min-height: 260px;
  flex-direction: column;
  padding: 30px;
  border: 1px solid var(--atonal-line);
  border-radius: 22px;
  color: var(--atonal-ink);
  background: white;
  text-decoration: none;
  transition: border-color .2s, transform .2s cubic-bezier(.2,.8,.2,1), box-shadow .2s;
}

.product-card:hover {
  transform: translateY(-5px);
  border-color: var(--atonal-blue);
  box-shadow: 0 24px 58px rgba(7, 19, 51, .11);
}

.product-card > span { color: var(--atonal-blue); font-size: 11px; font-weight: 700; letter-spacing: .12em; }
.product-card h2 { margin: 24px 0 15px; color: var(--atonal-navy); font-family: var(--atonal-display); font-size: 40px; font-weight: 400; line-height: .93; }
.product-card p { margin: 0; color: var(--atonal-muted); font-size: 14px; line-height: 1.6; }
.product-card > b { margin-top: auto; padding-top: 25px; color: var(--atonal-blue); font-size: 11px; letter-spacing: .08em; }
.product-card::after { content: "↗"; position: absolute; top: 25px; right: 27px; color: var(--atonal-line); font-size: 22px; }
.product-card:hover::after { color: var(--atonal-blue); }
.product-card.feature { color: white; border-color: var(--atonal-blue); background: var(--atonal-blue); }
.product-card.feature > span,.product-card.feature h2,.product-card.feature p,.product-card.feature > b { color: white; }
.product-card.feature::after { color: rgba(255,255,255,.5); }
.product-card.feature::before,
.product-card.provider::before {
  content: "";
  position: absolute;
  width: 180px;
  height: 180px;
  right: -54px;
  bottom: -70px;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 50%;
  box-shadow: 0 0 0 22px rgba(255, 255, 255, .04), 0 0 0 44px rgba(255, 255, 255, .03);
  pointer-events: none;
}
.product-card:nth-child(1) { grid-column: span 7; min-height: 330px; }
.product-card:nth-child(2) { grid-column: span 5; }
.product-card:nth-child(n + 3) { grid-column: span 4; }
.product-card:nth-child(1) h2 { font-size: 58px; }
.product-card.provider { color: white; border-color: var(--atonal-navy); background: var(--atonal-navy); }
.product-card.provider > span,.product-card.provider h2,.product-card.provider p,.product-card.provider > b { color: white; }
.product-card > b { transition: transform .15s ease; }
.product-card:hover > b { transform: translateX(4px); }

/* Shared ATONAL typography scale. */
.network-body dt,
.route,
.product-card > span,
.product-card > b { font-size: var(--atonal-type-xs); }
.network-body dd { font-size: var(--atonal-type-sm); }
.product-card p { font-size: var(--atonal-type-base); }

@media (max-width: 980px) {
  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    padding: 70px max(24px, 5vw) 128px;
  }

  .hero-copy,
  .network-console { max-width: 720px; }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .product-card:nth-child(n) { grid-column: auto; }
  .product-card:nth-child(1) { grid-column: 1 / -1; }
  .market-route { grid-template-columns: repeat(5, minmax(150px, 1fr)); overflow-x: auto; padding-inline: 24px; }
}

@media (max-width: 600px) {
  .hero { gap: 40px; padding: 52px 20px 120px; }
  .hero-wash { background: rgba(7, 19, 51, .82); }
  h1 { font-size: clamp(58px, 18vw, 76px); }
  .network-body { padding: 18px; }
  .product-grid { width: calc(100% - 28px); grid-template-columns: 1fr; margin-block: 38px 54px; }
  .product-card:nth-child(n) { grid-column: auto; }
  .product-card { min-height: 214px; }
  .product-card:nth-child(1) { min-height: 238px; }
  .product-card:nth-child(1) h2 { font-size: 46px; }
  .market-route { padding-inline: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-media video { display: none; }
}
