:root {
  color-scheme: dark;
  --bg: #090c17;
  --bg-soft: #0e1322;
  --panel: rgba(20, 27, 47, 0.82);
  --panel-strong: #151d32;
  --line: rgba(172, 186, 220, 0.18);
  --text: #f5f7ff;
  --muted: #a8b1c7;
  --purple: #8d7bff;
  --purple-bright: #b8a9ff;
  --cyan: #56d8ff;
  --green: #4ee6a8;
  --amber: #ffbf69;
  --shadow: 0 32px 90px rgba(0, 0, 0, 0.38);
  --radius: 24px;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 12% 5%, rgba(122, 91, 255, 0.18), transparent 28rem),
    radial-gradient(circle at 88% 14%, rgba(63, 201, 255, 0.12), transparent 30rem),
    var(--bg);
  color: var(--text);
  font-family: "Segoe UI", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 48px 48px;
  content: "";
  mask-image: linear-gradient(to bottom, black, transparent 78%);
  pointer-events: none;
}

img {
  display: block;
  height: auto;
  max-width: 100%;
}

a {
  color: inherit;
}

.container {
  width: min(calc(100% - 40px), var(--container));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--text);
  color: var(--bg);
  font-weight: 700;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(9, 12, 23, 0.78);
  backdrop-filter: blur(18px);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--text);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid rgba(184, 169, 255, 0.5);
  border-radius: 10px;
  background: linear-gradient(145deg, rgba(141, 123, 255, 0.3), rgba(86, 216, 255, 0.1));
  color: #d8d0ff;
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  box-shadow: inset 0 0 24px rgba(141, 123, 255, 0.18);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
}

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

.site-nav a:hover {
  color: var(--text);
}

.site-nav .nav-cta {
  padding: 9px 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(420px, 1.12fr);
  gap: 64px;
  align-items: center;
  padding-block: 92px 72px;
}

.eyebrow,
.section-label,
.showcase-number {
  margin: 0 0 18px;
  color: var(--purple-bright);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(3rem, 6.2vw, 5.7rem);
  font-weight: 790;
  letter-spacing: -0.065em;
  line-height: 0.99;
}

.gradient-text {
  background: linear-gradient(100deg, #c6bbff 5%, var(--purple) 42%, var(--cyan) 100%);
  background-clip: text;
  color: transparent;
}

.hero-summary {
  max-width: 680px;
  margin: 28px 0 0;
  color: #c0c8da;
  font-size: 1.1rem;
  line-height: 1.75;
}

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

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border-radius: 12px;
  font-size: 0.92rem;
  font-weight: 750;
  text-decoration: none;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: linear-gradient(120deg, var(--purple), #6a5deb);
  color: white;
  box-shadow: 0 14px 40px rgba(115, 92, 255, 0.28);
}

.button-secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: #dfe4f3;
}

.button-secondary:hover {
  border-color: rgba(184, 169, 255, 0.58);
}

.safety-note {
  max-width: 670px;
  margin-top: 28px;
  padding: 17px 18px;
  border: 1px solid rgba(255, 191, 105, 0.22);
  border-radius: 14px;
  background: rgba(255, 191, 105, 0.06);
  color: #c8cfde;
  font-size: 0.88rem;
}

.safety-note strong {
  color: #ffd39a;
}

.hero-figure,
.showcase-figure {
  margin: 0;
}

.screen-shell {
  overflow: hidden;
  border: 1px solid rgba(181, 193, 224, 0.2);
  border-radius: 22px;
  background: #eaf1f5;
  box-shadow: var(--shadow), 0 0 0 1px rgba(141, 123, 255, 0.08);
}

.screen-toolbar {
  display: flex;
  height: 42px;
  align-items: center;
  gap: 7px;
  padding: 0 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: #151b2a;
}

.screen-toolbar span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #566079;
}

.screen-toolbar span:first-child {
  background: #ff7b72;
}

.screen-toolbar span:nth-child(2) {
  background: #ffbf69;
}

.screen-toolbar span:nth-child(3) {
  background: #4ee6a8;
}

.screen-toolbar p {
  overflow: hidden;
  margin: 0 0 0 6px;
  color: #8993aa;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-figure figcaption,
.showcase-figure figcaption {
  margin: 16px 8px 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.metrics {
  border-block: 1px solid var(--line);
  background: rgba(14, 19, 34, 0.7);
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.metrics-grid div {
  display: flex;
  min-height: 130px;
  flex-direction: column;
  justify-content: center;
  padding: 24px 34px;
  border-left: 1px solid var(--line);
}

.metrics-grid div:last-child {
  border-right: 1px solid var(--line);
}

.metrics-grid strong {
  font-size: 2.3rem;
  letter-spacing: -0.05em;
}

.metrics-grid span {
  color: var(--muted);
  font-size: 0.82rem;
}

.section {
  padding-block: 112px;
  border-bottom: 1px solid var(--line);
}

.scenario-grid {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  gap: 64px;
  align-items: start;
}

.scenario-grid h2,
.editorial-heading,
.showcase-copy h2,
.cta-inner h2 {
  margin: 0;
  font-size: clamp(2.35rem, 4.6vw, 4.4rem);
  font-weight: 760;
  letter-spacing: -0.055em;
  line-height: 1.04;
}

.scenario-grid blockquote {
  margin: 0;
  padding-left: 28px;
  border-left: 2px solid var(--purple);
  color: #d9deeb;
  font-size: clamp(1.2rem, 2.2vw, 1.75rem);
  font-weight: 520;
  line-height: 1.55;
}

.section-intro {
  max-width: 760px;
  margin: 56px 0 0 auto;
  color: var(--muted);
  font-size: 1.05rem;
}

.editorial-heading {
  max-width: 860px;
}

.concept-intro {
  max-width: 790px;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.concept-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-top: 54px;
}

.concept-card {
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--panel);
  box-shadow: 0 20px 52px rgba(0, 0, 0, 0.24);
}

.concept-card a {
  display: block;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #0b0d18;
}

.concept-card img {
  width: 100%;
  transition: transform 180ms ease, filter 180ms ease;
}

.concept-card a:hover img {
  filter: brightness(1.05);
  transform: scale(1.012);
}

.concept-card figcaption {
  display: grid;
  gap: 8px;
  padding: 22px 24px 24px;
}

.concept-card figcaption strong {
  color: var(--purple-bright);
  font-size: 0.76rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.concept-card figcaption span {
  color: var(--muted);
  font-size: 0.88rem;
}

.layer-list {
  margin-top: 62px;
  border-top: 1px solid var(--line);
}

.layer-row {
  display: grid;
  grid-template-columns: 0.72fr 1.3fr 0.62fr;
  gap: 32px;
  align-items: center;
  min-height: 156px;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
}

.layer-name {
  display: flex;
  align-items: baseline;
  gap: 22px;
}

.layer-name h3 {
  margin: 0;
  font-size: 1.65rem;
  letter-spacing: -0.035em;
}

.layer-index {
  color: #69748f;
  font-family: ui-monospace, "Cascadia Code", monospace;
  font-size: 0.75rem;
}

.layer-row p {
  margin: 0;
  color: #b9c1d3;
}

.layer-detail {
  justify-self: end;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  text-align: center;
}

.layer-foundry h3 {
  color: #b3a4ff;
}

.layer-fabric h3 {
  color: #58e2cf;
}

.layer-work h3 {
  color: #ffbd66;
}

.layer-web h3 {
  color: #91a4c8;
}

.process-layout {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 80px;
}

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

.process-list li {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 18px;
  padding: 0 0 30px;
}

.process-list li > span {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(141, 123, 255, 0.35);
  border-radius: 12px;
  background: rgba(141, 123, 255, 0.09);
  color: var(--purple-bright);
  font-family: ui-monospace, "Cascadia Code", monospace;
  font-size: 0.72rem;
}

.process-list strong {
  display: block;
  margin-top: 2px;
  font-size: 1.05rem;
}

.process-list p {
  margin: 5px 0 0;
  color: var(--muted);
}

.showcase-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.58fr) minmax(0, 1.42fr);
  gap: 64px;
  align-items: center;
}

.showcase-grid-reverse {
  grid-template-columns: minmax(0, 1.22fr) minmax(280px, 0.78fr);
}

.showcase-grid-reverse .showcase-copy {
  grid-column: 2;
  grid-row: 1;
}

.showcase-grid-reverse .showcase-figure {
  grid-column: 1;
  grid-row: 1;
}

.showcase-copy h2 {
  font-size: clamp(2.2rem, 4vw, 3.85rem);
}

.showcase-copy > p:not(.showcase-number) {
  margin: 26px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.check-list {
  display: grid;
  gap: 13px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 26px;
  color: #d3d9e7;
}

.check-list li::before {
  position: absolute;
  top: 0.62em;
  left: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--purple), var(--cyan));
  content: "";
}

.screen-shell-tall img,
.screen-shell-portrait img {
  width: 100%;
}

.status-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}

.status-stack span {
  padding: 8px 11px;
  border: 1px solid rgba(255, 191, 105, 0.27);
  border-radius: 999px;
  background: rgba(255, 191, 105, 0.07);
  color: #ffd29a;
  font-size: 0.75rem;
  font-weight: 750;
}

.boundary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.boundary-grid article {
  min-height: 310px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(150deg, rgba(141, 123, 255, 0.08), transparent 45%),
    var(--panel);
}

.boundary-icon {
  display: inline-flex;
  margin-bottom: 54px;
  color: var(--purple-bright);
  font-family: ui-monospace, "Cascadia Code", monospace;
  font-size: 0.78rem;
}

.boundary-grid h3 {
  margin: 0;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}

.boundary-grid p {
  margin: 16px 0 0;
  color: var(--muted);
}

.cta-section {
  padding-block: 116px;
  background:
    radial-gradient(circle at 50% 0%, rgba(141, 123, 255, 0.2), transparent 38rem),
    var(--bg-soft);
}

.cta-inner {
  text-align: center;
}

.cta-inner h2 {
  max-width: 850px;
  margin-inline: auto;
}

.cta-inner > p:not(.section-label) {
  max-width: 700px;
  margin: 24px auto 0;
  color: var(--muted);
}

.cta-inner .hero-actions {
  justify-content: center;
}

.site-footer {
  padding-block: 46px;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
}

.footer-brand {
  margin-bottom: 13px;
}

.footer-inner p {
  margin: 0;
  color: #7f899f;
  font-size: 0.82rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  color: var(--muted);
  font-size: 0.84rem;
}

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

.footer-links a:hover {
  color: var(--text);
}

a:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 4px;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 70px;
  }

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

  .scenario-grid,
  .process-layout,
  .showcase-grid,
  .showcase-grid-reverse {
    grid-template-columns: 1fr;
    gap: 46px;
  }

  .showcase-grid-reverse .showcase-copy,
  .showcase-grid-reverse .showcase-figure {
    grid-column: auto;
    grid-row: auto;
  }

  .showcase-grid-reverse .showcase-copy {
    order: 1;
  }

  .showcase-grid-reverse .showcase-figure {
    order: 2;
  }

  .layer-row {
    grid-template-columns: 0.8fr 1.2fr;
  }

  .layer-detail {
    display: none;
  }

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

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

  .boundary-grid article {
    min-height: 0;
  }

  .boundary-icon {
    margin-bottom: 30px;
  }
}

@media (max-width: 720px) {
  .container {
    width: min(calc(100% - 28px), var(--container));
  }

  .site-nav > a:not(.nav-cta) {
    display: none;
  }

  .hero {
    gap: 46px;
    padding-block: 60px;
  }

  .hero h1 {
    font-size: clamp(2.8rem, 14vw, 4.2rem);
  }

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

  .metrics-grid div:nth-child(odd) {
    border-left: 1px solid var(--line);
  }

  .metrics-grid div {
    min-height: 112px;
    border-bottom: 1px solid var(--line);
  }

  .section {
    padding-block: 82px;
  }

  .scenario-grid {
    gap: 34px;
  }

  .layer-row {
    grid-template-columns: 1fr;
    gap: 16px;
    padding-block: 26px;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

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

  .button {
    transition: none;
  }
}
