/*! NBC v7.419 · Global Runtime & Layout Integrity Pass
 * Runtime stability surfaces, scroll integrity, cascade recovery and page rhythm.
 */

/* ------------------------------------------------------------
   1) HOME PARTICLE HYDRATION — never reveal geometry before it is stable
   ------------------------------------------------------------ */
body.page-home #auftakt[data-operating-model="v7061"] .nbc-particle-field canvas{
  opacity:0!important;
  transition:opacity .22s ease!important;
}
body.page-home #auftakt[data-operating-model="v7061"] .nbc-particle-field__still{
  opacity:1!important;
  visibility:visible!important;
  transition:opacity .22s ease!important;
}
body.page-home #auftakt[data-operating-model="v7061"][data-particle-stable="true"] .nbc-particle-field canvas{
  opacity:1!important;
}
body.page-home #auftakt[data-operating-model="v7061"][data-particle-stable="true"] .nbc-particle-field__still{
  opacity:0!important;
}
body.page-home #auftakt[data-operating-model="v7061"][data-particle-still-hidden="true"] .nbc-particle-field__still{
  visibility:hidden!important;
}
/* Older runtime used data-particle-motion=active as an immediate hide signal. Keep
   the fallback visible until the new stable handoff explicitly completed. */
body.page-home #auftakt[data-operating-model="v7061"]:not([data-particle-still-hidden="true"])[data-particle-motion="active"] .nbc-particle-field__still{
  visibility:visible!important;
}
@media (prefers-reduced-motion:reduce),(prefers-reduced-transparency:reduce),(forced-colors:active),print{
  body.page-home #auftakt[data-operating-model="v7061"] .nbc-particle-field canvas{opacity:0!important}
  body.page-home #auftakt[data-operating-model="v7061"] .nbc-particle-field__still{opacity:1!important;visibility:visible!important}
}

/* ------------------------------------------------------------
   2) OPERATING TWIN — one visible semantic stage, no old-scene ghost
   ------------------------------------------------------------ */
body.page-home #situationen .ts-before-ghost,
body.page-home #situationen .ts-scene-snapshot,
body.page-home .m7h-twin .ts-before-ghost,
body.page-home .m7h-twin .ts-scene-snapshot{
  display:none!important;
  opacity:0!important;
  visibility:hidden!important;
  pointer-events:none!important;
}
body.page-home #situationen .rf-twin-model ~ .operating-twin__visual,
body.page-home .m7h-twin .rf-twin-model ~ .m7h-twin__visual{
  visibility:hidden!important;
  opacity:0!important;
  pointer-events:none!important;
}

/* ------------------------------------------------------------
   3) SCROLL INTEGRITY — large story heads never travel into their content
   ------------------------------------------------------------ */
body.page-industry-hub[data-industry-premium="v7377"] :is(#industry-signature,#industry-start) header.nbc-story-head,
body.page-industry-hub[data-industry-premium="v7377"] :is(#industry-signature,#industry-start) > .wrap > header{
  position:relative!important;
  inset:auto!important;
  top:auto!important;
  bottom:auto!important;
  transform:none!important;
  translate:none!important;
  align-self:start!important;
  height:auto!important;
  min-height:0!important;
  z-index:2!important;
}
body.page-industry-hub[data-industry-premium="v7377"] :is(#industry-signature,#industry-start) .wrap{
  align-items:start!important;
}
body.page-industry-hub[data-industry-premium="v7377"] :is(#industry-signature,#industry-start) :is(.ip-promise-stack,.ip-deviation-field,.ip-c2c-flow,.ip-capacity-field,.nbc-story-visual,.nbc-visual-field){
  position:relative!important;
  z-index:1!important;
  min-width:0!important;
}
body.page-about .abt2-section-head--sticky,
body[data-final-page="about"] .abt2-section-head--sticky{
  position:relative!important;
  inset:auto!important;
  top:auto!important;
  bottom:auto!important;
  transform:none!important;
  translate:none!important;
  align-self:start!important;
  height:auto!important;
  min-height:0!important;
}

/* ------------------------------------------------------------
   4) GÖTTINGEN FAQ — a complete light-surface contract
   ------------------------------------------------------------ */
body.region-goettingen .regional-faq{
  background:#f1eee6!important;
  background-image:none!important;
  color:#101512!important;
}
body.region-goettingen .regional-faq :is(h2,h3,h4,strong,summary){
  color:#101512!important;
  -webkit-text-fill-color:#101512!important;
  text-shadow:none!important;
}
body.region-goettingen .regional-faq :is(p,li){
  color:#526058!important;
  -webkit-text-fill-color:#526058!important;
}
body.region-goettingen .regional-faq :is(.regional-faq-head>span,.mono,.eyebrow){
  color:#28633c!important;
  -webkit-text-fill-color:#28633c!important;
}
body.region-goettingen .regional-faq a{color:#205f36!important;-webkit-text-fill-color:#205f36!important}
body.region-goettingen .regional-faq details{
  border-color:rgba(23,53,35,.18)!important;
  background:transparent!important;
  box-shadow:none!important;
}
body.region-goettingen .regional-faq summary::after{color:#205f36!important;-webkit-text-fill-color:#205f36!important}

/* ------------------------------------------------------------
   5) ERP PROOF — retire the legacy billboard geometry on the paper folio
   ------------------------------------------------------------ */
body.service-erp #projektbeleg.service-case-proof[data-folio]{
  padding-block:clamp(72px,6vw,104px)!important;
  background:#f1eee5!important;
  color:#0b1710!important;
  overflow:hidden!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nf-inner{
  width:min(1280px,calc(100% - 64px))!important;
  max-width:1280px!important;
  margin-inline:auto!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__opening{
  display:grid!important;
  grid-template-columns:minmax(0,1.08fr) minmax(320px,.92fr)!important;
  gap:clamp(36px,5vw,72px)!important;
  align-items:end!important;
  margin:0 0 clamp(30px,3vw,44px)!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__statement{
  max-width:18ch!important;
  margin:0!important;
  font-size:clamp(36px,3.8vw,58px)!important;
  line-height:1.02!important;
  letter-spacing:-.045em!important;
  color:#0b1710!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__lead{
  max-width:56ch!important;
  margin:0!important;
  font-size:clamp(15px,1.25vw,18px)!important;
  line-height:1.58!important;
  color:#4d5a52!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-evidence{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:clamp(24px,3vw,44px)!important;
  padding:clamp(24px,2.5vw,36px) 0 22px!important;
  border-top:1px solid rgba(31,63,43,.16)!important;
  border-bottom:1px solid rgba(31,63,43,.16)!important;
  background:transparent!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-row{
  display:grid!important;
  grid-template-rows:auto auto auto!important;
  align-content:start!important;
  min-height:0!important;
  padding:0!important;
  border:0!important;
  background:transparent!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-row>span{
  color:#456050!important;
  font-size:11px!important;
  letter-spacing:.09em!important;
  text-transform:uppercase!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-row>strong{
  margin:10px 0 16px!important;
  color:#0b1710!important;
  font-size:clamp(46px,5.4vw,76px)!important;
  line-height:.95!important;
  letter-spacing:-.055em!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-row.is-reviewed>strong{color:#1f6a38!important}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-bar{
  height:6px!important;
  border-radius:999px!important;
  background:#d9dfd7!important;
  overflow:hidden!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-bar i{height:100%!important;background:linear-gradient(90deg,#52735c,#2f7243)!important}
body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-evidence figcaption{
  grid-column:1/-1!important;
  margin-top:0!important;
  color:#677269!important;
  font-size:12px!important;
  line-height:1.5!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__metric-label{
  margin:28px 0 12px!important;
  color:#29623c!important;
  font-size:11px!important;
  letter-spacing:.1em!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__ledger{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:0!important;
  margin:0!important;
  border-top:1px solid rgba(31,63,43,.16)!important;
  border-bottom:1px solid rgba(31,63,43,.16)!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row{
  display:block!important;
  min-height:0!important;
  padding:20px clamp(16px,2vw,26px)!important;
  border:0!important;
  border-right:1px solid rgba(31,63,43,.12)!important;
  color:#425047!important;
}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row:first-child{padding-left:0!important}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row:last-child{border-right:0!important;padding-right:0!important}
body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row>span{
  display:block!important;
  margin:0 0 7px!important;
  color:#2c6540!important;
}

/* ------------------------------------------------------------
   6) PROCESS ENTRANCE — preview and caption are one vertical object
   ------------------------------------------------------------ */
body.service-process .te.te-process-premium[data-instrument="process"] .te-visual{
  display:grid!important;
  grid-template-rows:auto minmax(0,1fr) auto!important;
  align-content:start!important;
  row-gap:10px!important;
  min-height:0!important;
  overflow:visible!important;
}
body.service-process .te.te-process-premium[data-instrument="process"] .te-preview-shell{
  min-height:0!important;
  margin:0!important;
  overflow:hidden!important;
}
body.service-process .te.te-process-premium[data-instrument="process"] .te-visual-note{
  position:relative!important;
  inset:auto!important;
  margin:0!important;
  padding:0 2px!important;
  min-height:1.55em!important;
  line-height:1.45!important;
  transform:none!important;
}

/* ------------------------------------------------------------
   7) KI RHYTHM — keep the modes and the Decision Lab connected
   ------------------------------------------------------------ */
body.service-ki #was-muesste-wahr-sein,
body.service-ki #ki-decision-entry{
  scroll-margin-top:calc(var(--header-height,76px) + 20px)!important;
}
body.service-ki #was-muesste-wahr-sein{
  padding-top:clamp(48px,5vw,76px)!important;
}
/* The operating-modes strip is immediately before the lab on the current service page.
   Neutralize legacy viewport-height / oversized end padding without changing its content. */
body.service-ki :is(.ki-operating-modes,.ki-mode-section,.ki-modes,.ki-three-modes,[data-ki-modes]){
  min-height:0!important;
  padding-bottom:clamp(38px,4vw,64px)!important;
  margin-bottom:0!important;
}

/* ------------------------------------------------------------
   8) CASE RETURNS — remove chapter-sized blank bridges
   ------------------------------------------------------------ */
body.case-type-returns .nbc-baro-entry{
  margin-block:clamp(44px,4.5vw,70px)!important;
  padding-block:0!important;
  min-height:0!important;
}
body.case-type-returns #case-next-step{
  padding-top:clamp(58px,5vw,82px)!important;
  padding-bottom:clamp(54px,4.5vw,78px)!important;
  min-height:0!important;
}
body.case-type-returns #case-next-step .case27-related{
  margin-top:clamp(36px,3.5vw,54px)!important;
  margin-bottom:clamp(34px,3vw,52px)!important;
  padding-bottom:0!important;
}
body.case-type-returns #case-next-step :is(.case2-related-grid,.case27-related-grid){margin-bottom:0!important}
body.case-type-returns #case-next-step + :is(.case-signature,.case2-signature,.case-v7357-signature,[data-case-signature]){
  margin-top:0!important;
  padding-top:clamp(24px,3vw,44px)!important;
}

/* ------------------------------------------------------------
   9) ARTICLE COST SIGNATURE — allow the diagram to become an editorial spread
   ------------------------------------------------------------ */
body.page-article[data-article-story="cost-accumulation"] .p3-signature--accumulation{
  position:relative!important;
  left:50%!important;
  width:min(1180px,calc(100vw - 72px))!important;
  max-width:none!important;
  margin:clamp(56px,6vw,86px) 0 clamp(70px,7vw,108px)!important;
  transform:translateX(-50%)!important;
}
body.page-article[data-article-story="cost-accumulation"] .p3-signature--accumulation .p3-signature__inner,
body.page-article[data-article-story="cost-accumulation"] .p3-signature--accumulation > *{
  max-width:none!important;
}

@media (max-width:900px){
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nf-inner{width:min(100% - 36px,720px)!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__opening{grid-template-columns:1fr!important;gap:18px!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-evidence{grid-template-columns:1fr!important;gap:26px!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-evidence figcaption{grid-column:1!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__ledger{grid-template-columns:1fr 1fr!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row:nth-child(2n){border-right:0!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row:nth-child(n+3){border-top:1px solid rgba(31,63,43,.12)!important}
  body.page-article[data-article-story="cost-accumulation"] .p3-signature--accumulation{width:min(100vw - 32px,760px)!important}
}
@media (max-width:600px){
  body.service-erp #projektbeleg.service-case-proof[data-folio]{padding-block:56px!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__statement{font-size:clamp(34px,10vw,46px)!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .erp-scope-row>strong{font-size:clamp(40px,13vw,54px)!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__ledger{grid-template-columns:1fr!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row{border-right:0!important;border-top:1px solid rgba(31,63,43,.12)!important;padding:16px 0!important}
  body.service-erp #projektbeleg.service-case-proof[data-folio] .nbc-folio__row:first-child{border-top:0!important}
  body.case-type-returns .nbc-baro-entry{margin-block:36px!important}
  body.case-type-returns #case-next-step{padding-top:48px!important;padding-bottom:48px!important}
}

/* ------------------------------------------------------------
   10) KI MODES → DECISION LAB — remove the chapter-sized dead zone
   The v7384 runtime inserts .v384-ai-modes directly after the
   service-scope grid. Give that generated component an explicit
   editorial width and reduce the two stacked legacy paddings that
   otherwise create ~150–180px of empty space before the lab.
   ------------------------------------------------------------ */
body.service-ki .service-founder-statement + .wave2-service-scope:has(> .v384-ai-modes){
  padding-bottom:clamp(34px,3.2vw,50px)!important;
}
body.service-ki .wave2-service-scope > .v384-ai-modes{
  width:min(1354px,calc(100% - 64px))!important;
  margin:clamp(30px,3vw,42px) auto 0!important;
  padding-block:16px!important;
}
body.service-ki .wave2-service-scope + .nbc-anchor-compat + #was-muesste-wahr-sein{
  padding-top:clamp(38px,3.8vw,56px)!important;
}
@media (max-width:760px){
  body.service-ki .service-founder-statement + .wave2-service-scope:has(> .v384-ai-modes){
    padding-bottom:30px!important;
  }
  body.service-ki .wave2-service-scope > .v384-ai-modes{
    width:calc(100% - 36px)!important;
    margin-top:26px!important;
    padding-block:14px!important;
  }
  body.service-ki .wave2-service-scope + .nbc-anchor-compat + #was-muesste-wahr-sein{
    padding-top:34px!important;
  }
}

/* ------------------------------------------------------------
   11) GÖTTINGEN FAQ — neutralize inherited WebKit text-fill from
   older dark-surface typography layers. `color` alone is not enough
   because -webkit-text-fill-color wins at paint time.
   ------------------------------------------------------------ */
body.region-goettingen .regional-faq :is(h2,h3,p,summary,a,strong,span){
  -webkit-text-fill-color:currentColor!important;
}
body.region-goettingen .regional-faq h2,
body.region-goettingen .regional-faq summary{
  color:#111711!important;
  -webkit-text-fill-color:#111711!important;
}
body.region-goettingen .regional-faq :is(.regional-faq-head>p,.faq-a p){
  color:rgba(17,23,17,.70)!important;
  -webkit-text-fill-color:rgba(17,23,17,.70)!important;
}
body.region-goettingen .regional-faq summary::after{
  color:#2f6b43!important;
  -webkit-text-fill-color:#2f6b43!important;
}

/* Specificity hardening: older regional dark-surface rules use
   html body#nbc-page... and otherwise win even when this file loads last. */
html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq :is(h2,h3,h4,strong,summary){
  color:#111711!important;
  -webkit-text-fill-color:#111711!important;
}
html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq :is(p,li,.faq-a){
  color:#4f5b53!important;
  -webkit-text-fill-color:#4f5b53!important;
}
html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq :is(a,.mono,.eyebrow){
  color:#28613f!important;
  -webkit-text-fill-color:#28613f!important;
}
html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq summary::after{
  color:#2f6b43!important;
  -webkit-text-fill-color:#2f6b43!important;
}

/* The legacy FAQ contrast lock lives in @layer nbc7375. Important
   declarations reverse layer priority, so this regional light-surface
   correction must join that exact layer rather than sit unlayered. */
@layer nbc7375{
  html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq :is(h2,h3,h4,strong,summary){
    color:#111711!important;
    -webkit-text-fill-color:#111711!important;
  }
  html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq :is(header p,.regional-faq-head p,details p,.faq-a p){
    color:#4f5b53!important;
    -webkit-text-fill-color:#4f5b53!important;
  }
  html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq :is(a,.mono,.eyebrow){
    color:#28613f!important;
    -webkit-text-fill-color:#28613f!important;
  }
  html body#nbc-page.page-regional-gateway.region-goettingen .regional-faq summary::after{
    color:#2f6b43!important;
    -webkit-text-fill-color:#2f6b43!important;
  }
}

/* Final rhythm calibration after visual QA. */
body.service-ki .service-founder-statement + .wave2-service-scope:has(> .v384-ai-modes){
  padding-bottom:clamp(28px,2.4vw,38px)!important;
}
body.service-ki .wave2-service-scope + .nbc-anchor-compat + #was-muesste-wahr-sein{
  padding-top:clamp(32px,2.8vw,44px)!important;
}
body.case-type-returns .nbc-baro-entry{
  margin-block:clamp(34px,3vw,46px)!important;
}
body.case-type-returns #case-next-step{
  padding-top:clamp(44px,3.8vw,56px)!important;
  padding-bottom:clamp(46px,4vw,60px)!important;
}
body.case-type-returns #case-next-step .case27-related{
  margin-top:clamp(34px,3vw,44px)!important;
  margin-bottom:clamp(30px,2.8vw,40px)!important;
}
@media (max-width:760px){
  body.service-ki .service-founder-statement + .wave2-service-scope:has(> .v384-ai-modes){padding-bottom:24px!important}
  body.service-ki .wave2-service-scope + .nbc-anchor-compat + #was-muesste-wahr-sein{padding-top:28px!important}
  body.case-type-returns .nbc-baro-entry{margin-block:28px!important}
  body.case-type-returns #case-next-step{padding-top:40px!important;padding-bottom:42px!important}
}

/* Case close already receives section-level top rhythm. The legacy close
   wrapper adds another 82px and creates the dark 'empty chapter' seen in QA. */
body.case-type-returns #case-next-step .case27-close{
  padding-top:0!important;
}

/* Case premium narratives live in @layer nbc.overrides; important declarations
   inside that layer otherwise outrank unlayered important fixes. */
@layer nbc.overrides{
  body.page-case-detail.case-type-returns[data-case-premium-v7379] #case-next-step .case27-close{
    padding-top:0!important;
  }
}
