/* SPIDER R07 - production layout hardening */
html,body{max-width:100%;overflow-x:hidden}
img,svg,video,canvas,iframe{max-width:100%}
.container,.header .container.header-inner{min-width:0}
.card,.pill,.btn,.pp-r04-domain,.pp-r04-engine,.pp-r04-source-flow>*{min-width:0}

/* Header: keep enterprise navigation stable and prevent collisions */
.header{isolation:isolate}
.header .header-inner{min-height:72px}
.header .brand{flex:0 0 auto}
.header .nav{min-width:0}
.header .nav>a,.header .nav-group-trigger{white-space:nowrap}
.header-actions{flex:0 0 auto}
.pp-r04-platform-menu{min-width:260px;max-width:min(360px,calc(100vw - 32px))}

/* Home hero */
.hero-grid{align-items:center}
.hero-copy,.hero-visual-wrap{min-width:0}
.hero-copy h1,.hero-copy .lead{overflow-wrap:break-word}
.hero-points{grid-template-columns:repeat(4,minmax(0,1fr))!important;max-width:none!important}
.hero-points .pill{min-width:0;overflow-wrap:anywhere}
.hero-card{isolation:isolate;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px!important;align-content:end!important;padding:24px!important;overflow:hidden!important}
.hero-card .hero-image{position:absolute!important;inset:0!important;overflow:hidden;border-radius:inherit;z-index:0;opacity:.42}
.hero-card .hero-image:after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(3,8,18,.18),rgba(3,8,18,.86));z-index:1}
.hero-card .float-card,.hero-card .float-card.card-a,.hero-card .float-card.card-b,.hero-card .float-card.card-c,.hero-card .float-card.card-d{position:relative!important;inset:auto!important;top:auto!important;right:auto!important;bottom:auto!important;left:auto!important;z-index:2;max-width:none!important;min-width:0!important;width:auto!important;margin:0!important;animation:none!important;transform:none!important}
.hero-card .float-card p,.hero-card .float-card strong{overflow-wrap:anywhere}

/* Enterprise end-to-end architecture: no horizontal overflow */
.pp-r04-e2e{display:grid!important;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px!important;overflow:visible!important}
.pp-r04-e2e li{min-width:0!important;width:auto!important;overflow-wrap:anywhere}
.pp-r04-e2e li:after{display:none!important}
.pp-r04-engine,.pp-r04-domain-grid,.pp-r04-intent-grid,.pp-r04-source-flow{min-width:0}
.pp-r04-pipeline li{overflow-wrap:anywhere}
.pp-r04-control{overflow-wrap:anywhere;white-space:normal}

/* Global R03 blocks */
.pp-global-network,.pp-global-network-inputs,.pp-global-roles-grid,.pp-global-scenarios-grid,.pp-content-cluster-grid{min-width:0}
.pp-global-node,.pp-global-flow,.pp-global-role-card,.pp-global-scenario-card,.pp-content-cluster-card{min-width:0;overflow-wrap:anywhere}

/* Existing product/process panels */
.pp-process-layout,.pp-product-panel,.pp-stage-panel,.pp-panel-top,.pp-flow-line,.pp-transaction-map{min-width:0}
.pp-panel-top strong{overflow-wrap:anywhere}
.pp-flow-line span{min-width:0;overflow-wrap:anywhere}
.pp-stage-card,.pp-module-card,.pp-industry-card,.pp-case-card,.pp-governance-card{min-width:0;overflow:hidden}
.pp-stage-card p,.pp-module-card p,.pp-industry-card p,.pp-case-card p,.pp-governance-card p{overflow-wrap:anywhere}

/* Process visual hardening */
.pp-process-section .pp-product-panel{overflow:hidden!important;height:auto!important;min-height:420px!important}
.pp-process-section .pp-panel-grid{display:none!important}
.pp-process-section .pp-stage-panel{padding:22px!important;min-width:0!important}
.pp-process-section .pp-flow-line{width:100%!important;max-width:100%!important;grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr) 24px minmax(0,1fr)!important;gap:8px!important}
.pp-process-section .pp-flow-line span{min-width:0!important;font-size:12px!important;line-height:1.3!important;padding:12px!important}
.pp-process-section .pp-flow-line i{min-width:0!important}

/* Articles */
.articles-hero-grid,.articles-grid,.article-reading,.article-sidecard,.pp-content-cluster-grid{min-width:0}
.articles-card,.article-sidecard{overflow:hidden}
.articles-card h2,.articles-card h3,.articles-card p,.article-reading h1,.article-reading h2,.article-reading h3,.article-reading p{overflow-wrap:anywhere}

/* Contact / forms */
.contact-form,.pp-contact-layout,.pp-demo-form-card,.pp-demo-preview-card{min-width:0}
.contact-form input,.contact-form textarea,.contact-form select{max-width:100%;min-width:0}

/* Footer */
.footer-grid>*{min-width:0}
.footer a,.footer p{overflow-wrap:anywhere}

@media (max-width:1200px){
  .header .container.header-inner{width:min(100% - 36px,1180px)!important}
  .header .nav{gap:6px!important}
  .header .nav>a,.header .nav-group-trigger{font-size:.78rem!important;padding-inline:7px!important}
  .language-combo{min-width:150px!important}
  .pp-r04-e2e{grid-template-columns:repeat(3,minmax(0,1fr))}
}

@media (max-width:1024px){
  .header .nav,.header .header-actions{display:none!important}
  .mobile-toggle,.nav-toggle{display:grid!important;place-items:center}
  .hero-grid{grid-template-columns:1fr!important;gap:28px!important}
  .hero-copy{padding-top:10px!important}
  .hero-visual-wrap{min-height:0!important}
  .hero-card{width:100%!important;max-width:none!important;min-height:0!important;height:auto!important;padding:18px!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px!important;overflow:hidden!important;background:linear-gradient(145deg,rgba(11,23,43,.9),rgba(14,31,60,.58))!important}
  .hero-card .hero-image{display:none!important}
  .hero-card .float-card,.hero-card .float-card.card-a,.hero-card .float-card.card-b,.hero-card .float-card.card-c,.hero-card .float-card.card-d{position:relative!important;inset:auto!important;top:auto!important;right:auto!important;bottom:auto!important;left:auto!important;max-width:none!important;width:auto!important;margin:0!important;animation:none!important;transform:none!important}
  .hero-points{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .pp-r04-e2e{grid-template-columns:repeat(2,minmax(0,1fr))}
}

@media (max-width:768px){
  .container,.header .container.header-inner,.content .container,.pp-page-section,.doc-shell{width:min(100% - 28px,1200px)!important;max-width:calc(100vw - 28px)!important;margin-inline:auto!important}
  .header .header-inner{min-height:64px!important}
  .brand span{font-size:.95rem}
  .brand img{width:36px!important;height:36px!important}
  .hero{padding:36px 0 44px!important}
  .hero h1{font-size:clamp(2.25rem,11.5vw,3.6rem)!important;line-height:1.02!important;letter-spacing:-.045em!important}
  .hero .lead{font-size:1rem!important;line-height:1.6!important}
  .hero-actions{display:grid!important;grid-template-columns:1fr!important;gap:10px!important}
  .hero-actions .btn{width:100%!important;min-width:0!important;white-space:normal!important;text-align:center}
  .hero-points{grid-template-columns:1fr 1fr!important;gap:10px!important}
  .hero-card{grid-template-columns:1fr!important;padding:14px!important}
  .hero-card .float-card{padding:15px!important}
  .hero-card .float-card p{font-size:.9rem!important}
  .grid-2,.grid-3,.grid-4,.footer-grid,.pp-r04-domain-grid,.pp-r04-intent-grid,.pp-r04-engine,.pp-r04-source-flow,.pp-global-network,.pp-global-roles-grid,.pp-global-scenarios-grid,.pp-content-cluster-grid{grid-template-columns:1fr!important}
  .pp-r04-e2e{grid-template-columns:1fr!important;gap:8px!important}
  .pp-r04-domain,.pp-r04-trust .grid-3 .card,.pp-r04-detail-grid .card{min-height:0!important}
  .pp-r04-engine,.pp-r04-ai,.pp-r04-outreach{padding:18px!important}
  .pp-r04-pipeline{grid-template-columns:1fr!important}
  .pp-process-section .pp-product-panel{min-height:0!important}
  .pp-process-section .pp-flow-line{grid-template-columns:1fr!important}
  .pp-process-section .pp-flow-line i{width:2px!important;height:18px!important;justify-self:center!important}
  .pp-r04-ai{display:grid!important;grid-template-columns:1fr!important}
  .pp-r04-control{width:100%!important;min-width:0!important}
  .pp-global-network-inputs{grid-template-columns:1fr!important}
  .pp-global-flow:before{display:none!important}
  .section{padding:44px 0!important}
  .section-header{display:block!important}
  .section h2,.section-header h2{font-size:clamp(1.65rem,8vw,2.4rem)!important}
  .page-hero{padding:36px 0 28px!important}
  .page-hero h1{max-width:none!important;font-size:clamp(2rem,10vw,3rem)!important}
  .footer{padding:42px 0 88px!important}
  .footer-grid{gap:18px!important}
}

@media (max-width:430px){
  .container,.header .container.header-inner,.content .container,.pp-page-section,.doc-shell{width:calc(100% - 24px)!important;max-width:calc(100vw - 24px)!important}
  .hero h1{font-size:clamp(2.05rem,12vw,3rem)!important}
  .hero-points{grid-template-columns:1fr!important}
  .eyebrow{max-width:100%;white-space:normal!important;line-height:1.35!important}
  .card,.pp-r04-domain,.pp-r04-engine,.pp-r04-ai,.pp-r04-outreach{padding:16px!important}
  .pp-r04-kicker{margin-bottom:14px!important}
  .articles-card,.article-sidecard{border-radius:18px!important}
}
