.stitch-home {
  --home-paper: #fbf8ff;
  --home-ink: #1a1b25;
  --home-dark: #11131c;
  --home-line: #c4c5d9;
  --home-primary: #002dd2;
  background: var(--home-paper);
  color: var(--home-ink);
}

:root:is([data-palette="sage"], [data-palette="slate"]) .stitch-home {
  --home-paper: var(--paper);
  --home-ink: var(--ink);
  --home-line: var(--line);
  --home-primary: var(--blue);
}

.stitch-home .showroom-hero.home-hero {
  background: linear-gradient(#11131c60, #11131cce), url('assets/aurora.jpg') center 48% / cover;
  padding-block: clamp(64px, 8vw, 112px) clamp(88px, 10vw, 144px);
  text-align: center;
}

.stitch-home .showroom-hero-copy { padding-top: 0; }
.stitch-home .showroom-hero h1 {
  color: #fff;
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.22;
  margin: 0 auto 20px;
  max-width: 18ch;
  text-wrap: balance;
}
.stitch-home .hero-title-accent { color: #e3e6ff; white-space: normal; }
.stitch-home .showroom-hero-copy > p { color: #f1effe; margin-inline: auto; max-width: 42rem; }
.stitch-home .showroom-hero-copy > .home-brand-title { color: #f1effe; font-weight: 700; letter-spacing: .14em; margin-bottom: 10px; }
.stitch-home .showroom-hero .hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 26px;
}
.stitch-home .showroom-hero .hero-buttons :is(.btn, .hero-secondary) {
  align-items: center;
  background: var(--home-primary);
  border: 1px solid #7292ff;
  border-radius: 8px;
  color: #fff;
  display: inline-flex;
  font-size: 1rem;
  font-weight: 700;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  text-decoration: none;
}
.stitch-home .showroom-hero .hero-buttons .hero-secondary { background: #11131cbb; border-color: #c4c5d9; }
.stitch-home .showroom-hero .hero-buttons :is(.btn, .hero-secondary):hover { background: #2447f9; }

.stitch-home .home-destinations {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: -42px;
  padding-block: 0 50px;
  position: relative;
}
.stitch-home .home-destinations .destination-card {
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--home-line);
  border-radius: 14px;
  color: var(--home-ink);
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  padding: 22px;
  text-align: left;
}
.stitch-home .home-destinations .destination-card:hover { border-color: var(--home-primary); }
.stitch-home .home-destinations .destination-card h2 { color: inherit; font-size: clamp(19px, 2.1vw, 25px); }
.stitch-home .home-destinations .destination-card p { color: #444656; font-size: .95rem; margin: 7px 0 0; }
.stitch-home .home-gateway-icon {
  background: #dee0ff;
  border-radius: 8px;
  color: var(--home-primary);
  display: grid;
  height: 40px;
  place-items: center;
  width: 40px;
}

.home-demo-band { background: var(--home-dark); color: #f1effe; padding-block: clamp(40px, 6vw, 76px); }
.home-demo { scroll-margin-top: 105px; }
.home-demo-heading, .home-section-heading {
  align-items: flex-end;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 26px;
  justify-content: space-between;
  margin-bottom: 18px;
}
.home-demo-heading h2, .home-section-heading h2, .stitch-portfolio h2, .home-project h2 {
  font-size: clamp(24px, 3vw, 40px);
  letter-spacing: -.025em;
  line-height: 1.25;
  margin: 0;
}
.home-demo-heading p { color: #c4c5d9; margin: 7px 0 0; }
.home-demo-viewports, .home-demo-step-controls, .home-demo-links {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.home-demo-viewports button, .home-demo-step-controls button, .home-demo-links .stage-preview {
  background: #282934;
  border: 1px solid #747688;
  border-radius: 7px;
  color: #f1effe;
  min-height: 42px;
  padding: 7px 12px;
}
.home-demo-step-controls button:disabled { opacity: .45; }
.home-demo-viewports button[aria-pressed="true"] { background: #bbc3ff; color: #001d93; }
.stitch-home .product-stage-controls { margin-bottom: 12px; }
.stitch-home .product-stage-controls button[aria-selected="true"] { background: #bbc3ff; color: #001d93; }
.home-demo-frame {
  align-items: center;
  background: #1e1f29;
  border: 1px solid #444656;
  border-radius: 18px;
  display: grid;
  gap: clamp(16px, 3vw, 34px);
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  margin-inline: auto;
  padding: clamp(16px, 2.4vw, 28px);
  width: 100%;
}
.home-demo-frame[data-viewport="mobile"] { grid-template-columns: 1fr; max-width: 460px; }
.home-demo-art { min-width: 0; }
.home-demo-art img { border-radius: 10px; display: block; height: auto; width: 100%; }
.home-demo-art .usage-stage { margin: 0; min-height: 220px; }
.home-demo-art .thinking-path span { color: #203b32; }
.home-demo-copy { min-width: 0; overflow-wrap: anywhere; }
.home-demo-copy h2 { color: #fff; font-size: clamp(20px, 3vw, 29px); margin: 0 0 9px; }
.home-demo-copy p { color: #d8daeb; margin: 0 0 12px; }
.home-demo-step-controls { color: #d8daeb; margin-bottom: 14px; }
.home-demo-links .btn { background: #bbc3ff; border-color: transparent; color: #001d93; min-height: 42px; }

.stitch-products { padding-block: clamp(44px, 6vw, 82px); }
.stitch-products .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stitch-home .home-section-heading a, .stitch-portfolio a, .home-project a {
  color: var(--home-primary);
  font-weight: 700;
  text-underline-offset: 4px;
}
.stitch-portfolio {
  align-items: center;
  background: #fff;
  border: 1px solid var(--home-line);
  border-radius: 14px;
  display: grid;
  gap: 26px;
  grid-template-columns: 1fr 1fr;
  padding: clamp(18px, 3vw, 30px);
}
.stitch-portfolio img { aspect-ratio: 16 / 9; border-radius: 9px; display: block; height: auto; object-fit: cover; width: 100%; }
.stitch-portfolio p { color: #444656; margin: 12px 0; }
.home-project { padding-block: 36px 54px; }
.home-project h2 { font-size: 1.5rem; margin-bottom: 7px; }

@media (max-width: 760px) {
  .stitch-home .home-destinations, .home-demo-frame, .stitch-products .product-grid, .stitch-portfolio {
    grid-template-columns: 1fr;
  }
  .stitch-home .home-destinations { gap: 10px; margin-top: -36px; padding-bottom: 32px; }
  .stitch-home .home-destinations .destination-card { align-items: center; flex-direction: row; padding: 14px; }
  .stitch-home .home-gateway-icon { flex-shrink: 0; }
  .home-section-heading { align-items: flex-start; flex-direction: column; }
  .home-demo { scroll-margin-top: 70px; }
  .home-demo-viewports { display: none; }
}
