/* Small screens retain the existing sticky chapters with a measured read-through. */
body.nuweb-site #content [data-story].story--compact > .stage {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow: clip;
  isolation: isolate;
}
body.nuweb-site #content [data-story].story--compact > .stage > .scene {
  position: absolute;
  inset: 0 0 auto;
  height: auto;
  min-height: 100%;
  align-items: flex-start;
}

/* The runtime class includes portrait and touch-tablet landscape layouts. */
body.nuweb-site #content .nuweb-home .story--compact :is(.layout-seo,.layout-project,.layout-project.is-reversed) {
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  width: 100%;
  max-width: 640px;
  margin-inline: auto;
}
body.nuweb-site #content .nuweb-home .story--compact :is(.layout-seo,.layout-project) > * {
  grid-column: auto;
  grid-row: auto;
  order: 0;
  min-width: 0;
}
body.nuweb-site #content .nuweb-home .story--compact .scene--hero .hero-composition {
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
  width: 100%;
  max-width: 640px;
  margin-inline: auto;
}
body.nuweb-site #content .nuweb-home .story--compact .scene--hero .hero-message {
  grid-column: 1;
  grid-row: 2;
  max-width: none;
}
body.nuweb-site #content .nuweb-home .story--compact .scene--hero .hero-projects.project-fan {
  grid-column: 1;
  grid-row: 1;
  order: -1;
  justify-self: center;
  width: min(100%, 560px);
  margin-inline: auto;
}

/* Shared copy stays outside each deck; its native cards occupy one panel slot. */
body.nuweb-site #content [data-story].story--compact [data-compact-deck] {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  align-items: center;
  gap: 0;
}
body.nuweb-site #content [data-story].story--compact [data-compact-panel] {
  grid-area: 1 / 1;
  width: 100%;
  min-width: 0;
  margin: 0;
  transition: none;
  transform-origin: center;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content > :is(.section,.subhero) > .section-inner {
  max-width: 640px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content :is(.subhero-grid,.solution-detail-hero-grid,.solution-consulting,.solution-problem-layout,.multilingual-bento,.feature-split,.website-landing-process) {
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content :is(.about-hero .subhero-grid,.contact-hero > .subhero-grid,.sprengel-layout,.sprengel-layout--products,.sprengel-layout--admin,.sprengel-notes-grid) {
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content :is(.subhero-grid,.solution-detail-hero-grid,.solution-consulting,.solution-problem-layout,.multilingual-bento,.feature-split,.website-landing-process,.sprengel-layout) > * {
  grid-column: auto;
  grid-row: auto;
  order: 0;
  min-width: 0;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content :is(.about-hero,.contact-hero) .subhero-grid > :is(.subhero-copy,.subhero-visual),
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .sprengel-layout--products > :is(.sprengel-copy,.sprengel-screen) {
  grid-column: 1;
  grid-row: auto;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .subhero :is(.subhero-copy,.solution-detail-copy) {
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .subhero :is(.subhero-copy,.solution-detail-copy) > * {
  grid-column: 1;
  grid-row: auto;
  justify-self: start;
  width: 100%;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero > .subhero-grid,
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero .subhero-copy {
  display: grid;
  min-height: 0;
  padding-block: 0;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero .subhero-visual,
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero .subhero-media {
  position: relative;
  inset: auto;
  width: 100%;
  height: clamp(220px, 36svh, 380px);
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero .subhero-visual {
  height: auto;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero .solutions-project-credit {
  position: static;
  width: 100%;
  margin-top: 12px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .solutions-hero .subhero-media::after {
  content: none;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content :is(.service-capability-row,.detail-pair,.multilingual-languages,.website-landing-process-grid) {
  grid-template-columns: minmax(0, 1fr);
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content [data-compact-deck] {
  gap: 0;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content [data-compact-deck] > [data-compact-panel] {
  grid-area: 1 / 1;
}
body.nuweb-site #content .page-story.story--compact [data-compact-panel] {
  padding-block: 0;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .about-principle-list article:nth-child(n) {
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .about-type-line {
  white-space: normal;
}
body.nuweb-site #content [data-story].story--compact :is(.software-capabilities,.service-capability-list,.service-capability-row,.detail-pair,.solution-context-step,.solution-concrete-features,.solution-consulting-card,.solution-capabilities,.multilingual-bento > article,.multilingual-language,.website-landing-card-grid > article,.website-landing-process-grid > article) {
  border: 0;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content .service-capability-row {
  padding-inline: 0;
  gap: 20px;
}
body.nuweb-site #content .page-story.story--compact .scene.scene--page .scene-content :is(.contact-hero h1,.about-hero h1) .headline-line {
  white-space: normal;
}

/* Home uses one legible composition per step, with the native content kept once. */
body.nuweb-site #content .nuweb-home .story--compact > .stage > .scene:not(.scene--hero) {
  align-items: center;
  padding-block: calc(var(--header-height) + 28px) 52px;
}
body.nuweb-site #content .nuweb-home .story--compact [data-mobile-home-deck],
body.nuweb-site #content .nuweb-home .story--compact .scene--benefits[data-mobile-home-panels] .benefit-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 0;
}
body.nuweb-site #content .nuweb-home .story--compact [data-mobile-home-panel],
body.nuweb-site #content .nuweb-home .story--compact .scene--benefits[data-mobile-home-panels] .benefit-list {
  grid-area: 1 / 1;
  width: 100%;
  min-width: 0;
  margin: 0;
  transition: none;
  transform-origin: center;
}
body.nuweb-site #content .nuweb-home .story--compact .benefit-list > [data-mobile-home-panel] {
  padding: 0;
  border: 0;
}
body.nuweb-site #content .nuweb-home .story--compact .benefit-list > [data-mobile-home-panel] .benefit-title {
  margin-bottom: 24px;
  font-size: clamp(28px, 7.4vw, 40px);
  line-height: 1.2;
}
body.nuweb-site #content .nuweb-home .story--compact .scene--benefits .benefit-list {padding: 0; border: 0; list-style: none}
body.nuweb-site #content .nuweb-home .story--compact .scene--benefits[data-mobile-home-panels] .benefit-list > li::before,
body.nuweb-site #content .nuweb-home .story--compact .scene--benefits[data-mobile-home-panels] .benefit-list > li::after {content: none}
body.nuweb-site #content .nuweb-home .story--compact :is(.page-heading,.project-title) {
  font-size: clamp(30px, 7.8vw, 44px);
  line-height: 1.2;
}
body.nuweb-site #content .nuweb-home .story--compact :is(.page-copy,.project-copy,.benefit-copy,.solution-copy) {
  font-size: 17px;
  line-height: 1.6;
}
body.nuweb-site #content .nuweb-home .story--compact :is(.solution-grid,.summary-grid,.software-capabilities) {
  margin-block: 28px;
}
body.nuweb-site #content .nuweb-home .story--compact .solution-grid > article,
body.nuweb-site #content .nuweb-home .story--compact .summary-grid > article,
body.nuweb-site #content .nuweb-home .story--compact .software-capabilities > div {
  border: 0;
  padding: 0;
}
body.nuweb-site #content .nuweb-home .story--compact .layout-project {gap: 28px}
body.nuweb-site #content .nuweb-home .story--compact .project-meta {font-size: 14px; margin-block: 16px}
body.nuweb-site #content .nuweb-home .story--compact .project-visual {max-width: 560px; margin-inline: auto; transition: none}
body.nuweb-site #content .nuweb-home .story--compact .scene--hero {padding-bottom: 56px}
