/* Reinwarth Metallverarbeitung – finales Layoutsystem */
:root{
  --v3-container:1280px;
  --v3-section:clamp(72px,8vw,112px);
  --v3-gap:clamp(18px,2vw,28px);
  --v3-radius:18px;
}
html,body.layout-v2{overflow-x:clip}
body.layout-v2 main,body.layout-v2 section,body.layout-v2 .container,
body.layout-v2 [class*="grid"],body.layout-v2 [class*="card"],
body.layout-v2 [class*="copy"],body.layout-v2 [class*="media"]{min-width:0}
body.layout-v2 .container{width:min(calc(100% - 48px),var(--v3-container))}
body.layout-v2 h1,body.layout-v2 h2,body.layout-v2 h3{overflow-wrap:normal;word-break:normal;text-wrap:balance}
body.layout-v2 p,body.layout-v2 li,body.layout-v2 small,body.layout-v2 a,body.layout-v2 span,body.layout-v2 strong{overflow-wrap:break-word}
body.layout-v2 .section{padding-block:var(--v3-section)}
body.layout-v2 .section-heading{align-items:flex-end;gap:32px;margin-bottom:clamp(36px,5vw,64px)}
body.layout-v2 .section-heading>div:first-child{min-width:0}
body.layout-v2 .section-heading h2{max-width:18ch}
body.layout-v2 .section-heading p{max-width:68ch}
body.layout-v2 .btn,body.layout-v2 .text-link,body.layout-v2 .card-link{max-width:100%}

/* Navigation */
body.layout-v2 .nav-shell{min-height:82px;gap:24px}
body.layout-v2 .brand-logo{width:clamp(174px,15vw,205px)}
body.layout-v2 .nav-links{min-width:0}
body.layout-v2 .nav-links>a{padding-inline:9px;font-size:.82rem}
body.layout-v2 .nav-actions{flex:0 0 auto}

/* Hero */
body.layout-v2 .home-hero-grid{grid-template-columns:minmax(0,1.02fr) minmax(430px,.86fr);gap:clamp(44px,6vw,86px);align-items:center}
body.layout-v2 .hero-copy h1{max-width:13ch;font-size:clamp(3.35rem,5.4vw,5.65rem);line-height:.99}
body.layout-v2 .hero-copy h1 em{display:block}
body.layout-v2 .hero-lead,body.layout-v2 .page-hero-copy>p{max-width:67ch}
body.layout-v2 .hero-media{min-height:600px}
body.layout-v2 .hero-image-main{inset:0 10% 8% 0}
body.layout-v2 .hero-image-secondary{width:40%;height:35%}
body.layout-v2 .page-hero-grid{grid-template-columns:minmax(0,1.08fr) minmax(380px,.72fr);gap:clamp(44px,7vw,92px);align-items:center}
body.layout-v2 .page-hero-copy h1{max-width:13ch;font-size:clamp(3.2rem,5.2vw,5.35rem)}
body.layout-v2 .page-hero-image{width:100%;min-height:0;aspect-ratio:4/3}
body.layout-v2 .page-hero-image img{width:100%;height:100%;object-fit:cover}
body.layout-v2 .service-detail-hero .page-hero-copy h1{max-width:18ch}

/* Schnellnavigation */
body.layout-v2 .service-rail{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));overflow:hidden}
body.layout-v2 .service-rail a{min-width:0;min-height:76px;justify-content:center;padding:15px 12px;text-align:center}
body.layout-v2 .service-rail span{max-width:100%;font-size:.72rem}

/* Startseite – Leistungsraster */
body.layout-v2 .portfolio-grid{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:var(--v3-gap)}
body.layout-v2 .portfolio-card{min-width:0;border-radius:var(--v3-radius)}
body.layout-v2 .portfolio-card.portfolio-featured{grid-column:span 8;grid-template-columns:minmax(0,1.08fr) minmax(300px,.92fr);min-height:420px}
body.layout-v2 .portfolio-card.portfolio-standard{grid-column:span 4}
body.layout-v2 .portfolio-card-media{min-width:0;min-height:250px}
body.layout-v2 .portfolio-card-body{min-width:0;padding:clamp(24px,2.6vw,34px)}
body.layout-v2 .portfolio-card-body h3{max-width:18ch;font-size:clamp(1.45rem,2vw,2rem)}
body.layout-v2 .portfolio-card-body p{max-width:50ch}
body.layout-v2 .portfolio-card.is-text-only,body.layout-v2 .portfolio-card.is-text-only .portfolio-card-body{min-height:100%}

/* Argumente und Karten */
body.layout-v2 .buyer-reasons,body.layout-v2 .values-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--v3-gap)}
body.layout-v2 .buyer-reason,body.layout-v2 .value-card{min-width:0;min-height:100%;padding:clamp(26px,3vw,36px);border-radius:var(--v3-radius)}

/* Text-Bild-Bereiche */
body.layout-v2 .spotlight-grid,body.layout-v2 .feature-grid,body.layout-v2 .feature-grid.reverse,
body.layout-v2 .portfolio-section-grid{grid-template-columns:minmax(0,.92fr) minmax(420px,1.08fr);gap:clamp(44px,7vw,92px);align-items:center}
body.layout-v2 .spotlight-media,body.layout-v2 .feature-media,body.layout-v2 .portfolio-media{min-width:0;min-height:0;aspect-ratio:4/3}
body.layout-v2 .spotlight-media img,body.layout-v2 .feature-media img,body.layout-v2 .portfolio-media img{width:100%;height:100%;object-fit:cover}
body.layout-v2 .bell-teaser{grid-template-columns:minmax(380px,.9fr) minmax(0,1.1fr);align-items:stretch}
body.layout-v2 .bell-teaser-image{min-height:0;aspect-ratio:4/3}

/* Leistungsübersicht */
body.layout-v2 .leistung-overview-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--v3-gap)}
body.layout-v2 .leistung-overview-card{min-width:0;min-height:100%;padding:clamp(28px,3vw,40px);border-radius:var(--v3-radius)}
body.layout-v2 .leistung-overview-card h2{max-width:22ch}
body.layout-v2 .leistung-overview-card>p{max-width:68ch}
body.layout-v2 .leistung-overview-card li{min-width:0}

/* Leistungsdetailseiten */
body.layout-v2.page-service-detail .service-detail-hero .page-hero-simple-grid{display:block!important}
body.layout-v2.page-service-detail .service-detail-hero .page-hero-copy{max-width:980px}
body.layout-v2.page-service-detail .service-single-section .portfolio-section-grid{grid-template-columns:minmax(0,.92fr) minmax(400px,1.08fr);align-items:center}
body.layout-v2.page-service-detail .portfolio-section.is-text-only .portfolio-section-grid{grid-template-columns:minmax(0,960px);justify-content:start}
body.layout-v2 .buyer-detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--v3-gap)}
body.layout-v2 .buyer-detail-card{min-width:0;min-height:100%;padding:clamp(28px,3vw,40px);border-radius:var(--v3-radius)}

/* Unternehmensgeschichte */
body.layout-v2 .history-intro-grid{grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:clamp(44px,7vw,96px)}
body.layout-v2 .history-stage{grid-template-columns:minmax(340px,.82fr) minmax(0,1.18fr);gap:clamp(32px,6vw,80px)}
body.layout-v2 .history-image{min-height:560px}
body.layout-v2 .history-milestone{grid-template-columns:92px minmax(0,1fr)}

/* Unternehmen – Leistungsübersicht ohne alte Nummernspalte */
body.layout-v2 .about-services-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--v3-gap);overflow:visible;background:transparent;border:0;border-radius:0}
body.layout-v2 .about-services-list>a{display:grid!important;grid-template-columns:minmax(0,1fr) 24px!important;align-items:start;gap:20px;min-width:0;min-height:170px;padding:clamp(26px,3vw,36px);background:linear-gradient(145deg,rgba(255,255,255,.052),rgba(255,255,255,.018));border:1px solid var(--line)!important;border-radius:var(--v3-radius)}
body.layout-v2 .about-services-list>a:last-child{border-bottom:1px solid var(--line)!important}
body.layout-v2 .about-services-list>a>span{grid-column:1;min-width:0;display:flex;flex-direction:column;gap:12px}
body.layout-v2 .about-services-list>a>svg{grid-column:2;justify-self:end;margin-top:2px;color:var(--accent-bright)}
body.layout-v2 .about-services-list strong{max-width:22ch;font-size:clamp(1.25rem,1.8vw,1.65rem);line-height:1.18}
body.layout-v2 .about-services-list small{max-width:54ch;font-size:.9rem;line-height:1.65}

/* Glocken */
body.layout-v2 .bells-intro-grid,body.layout-v2 .dark-panel{grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:clamp(40px,6vw,82px)}
body.layout-v2 .horizontal-card{grid-template-columns:64px minmax(0,1fr)}
body.layout-v2 .component-grid,body.layout-v2 .roadmap-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--v3-gap)}

/* Referenzen */
body.layout-v2 .gallery-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
body.layout-v2 .gallery-item,body.layout-v2 .gallery-item img{min-width:0}

/* Kontakt */
body.layout-v2 .contact-hero-grid{grid-template-columns:minmax(0,1fr) minmax(360px,.72fr);gap:clamp(44px,7vw,92px)}
body.layout-v2 .contact-main-grid{grid-template-columns:minmax(0,1fr) minmax(370px,.82fr);gap:clamp(40px,6vw,76px)}
body.layout-v2 .contact-action{grid-template-columns:52px minmax(0,1fr) 22px}
body.layout-v2 .service-selector a{grid-template-columns:minmax(0,1fr) 22px!important}
body.layout-v2 .service-selector a>span{min-width:0}
body.layout-v2 .contact-details{grid-template-columns:repeat(2,minmax(0,1fr))}
body.layout-v2 .checklist-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--v3-gap)}
body.layout-v2 .map-layout.map-layout-simple{grid-template-columns:minmax(0,1fr)}

/* CTA und Footer */
body.layout-v2 .cta-band{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:38px;align-items:center;padding:clamp(34px,5vw,58px)}
body.layout-v2 .cta-band h2{max-width:15ch}
body.layout-v2 .cta-band p{max-width:70ch}
body.layout-v2 .cta-actions{align-items:center;flex-wrap:wrap;justify-content:flex-end}
body.layout-v2 .footer-grid{grid-template-columns:minmax(260px,1.25fr) minmax(180px,.85fr) minmax(190px,1fr) minmax(170px,.8fr);gap:clamp(26px,4vw,58px)}
body.layout-v2 .footer-grid .footer-column:last-child,body.layout-v2 .footer-brand{grid-column:auto}

@media(max-width:1160px){
  body.layout-v2 .nav-phone,body.layout-v2 .nav-actions .btn-small{display:none!important}
  body.layout-v2 .menu-toggle{display:block!important}
  body.layout-v2 .nav-links{display:none!important;position:fixed;z-index:999;top:var(--header-height);right:0;bottom:0;width:min(430px,100vw);flex-direction:column;align-items:stretch;gap:0;padding:24px 22px 110px;overflow-y:auto;background:rgba(9,13,16,.99);border-left:1px solid var(--line-strong);box-shadow:-28px 0 70px rgba(0,0,0,.34)}
  body.layout-v2 .nav-shell.is-open .nav-links{display:flex!important}
  body.layout-v2 .nav-links>a{padding:16px 8px;font-size:1rem;border-bottom:1px solid var(--line);border-radius:0}
  body.layout-v2 .nav-mobile-contact{display:grid}
  body.layout-v2 .home-hero-grid,body.layout-v2 .page-hero-grid,body.layout-v2 .spotlight-grid,
  body.layout-v2 .feature-grid,body.layout-v2 .feature-grid.reverse,body.layout-v2 .portfolio-section-grid,
  body.layout-v2.page-service-detail .service-single-section .portfolio-section-grid,body.layout-v2 .bell-teaser,
  body.layout-v2 .contact-hero-grid,body.layout-v2 .contact-main-grid,body.layout-v2 .history-intro-grid,
  body.layout-v2 .history-stage,body.layout-v2 .bells-intro-grid,body.layout-v2 .dark-panel{grid-template-columns:minmax(0,1fr)}
  body.layout-v2 .hero-copy,body.layout-v2 .page-hero-copy,body.layout-v2 .spotlight-copy,body.layout-v2 .portfolio-section-copy{max-width:820px}
  body.layout-v2 .hero-media{width:min(100%,860px);min-height:620px}
  body.layout-v2 .page-hero-image,body.layout-v2 .spotlight-media,body.layout-v2 .portfolio-media,body.layout-v2 .bell-teaser-image{width:min(100%,860px)}
  body.layout-v2 .portfolio-card.portfolio-featured{grid-column:span 12}
  body.layout-v2 .portfolio-card.portfolio-standard{grid-column:span 6}
  body.layout-v2 .service-rail{grid-template-columns:repeat(3,minmax(0,1fr))}
  body.layout-v2 .component-grid,body.layout-v2 .roadmap-grid,body.layout-v2 .checklist-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  body.layout-v2 .footer-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  body.layout-v2 .footer-brand{grid-column:1/-1}
}

@media(max-width:860px){
  body.layout-v2 .container{width:min(calc(100% - 34px),var(--v3-container))}
  body.layout-v2 .leistung-overview-grid,body.layout-v2 .buyer-detail-grid,body.layout-v2 .buyer-reasons,
  body.layout-v2 .values-grid,body.layout-v2 .about-services-list{grid-template-columns:minmax(0,1fr)}
  body.layout-v2 .history-image{min-height:500px}
  body.layout-v2 .gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  body.layout-v2 .gallery-large,body.layout-v2 .gallery-wide{grid-column:auto;grid-row:auto}
  body.layout-v2 .cta-band{grid-template-columns:minmax(0,1fr)}
  body.layout-v2 .cta-actions{justify-content:flex-start}
}

@media(max-width:640px){
  :root{--v3-section:64px}
  body.layout-v2 .container{width:min(calc(100% - 26px),var(--v3-container))}
  body.layout-v2 .nav-shell{min-height:72px}
  body.layout-v2 .brand-logo{width:164px}
  body.layout-v2 h1,body.layout-v2 .page-hero-copy h1,body.layout-v2 .hero-copy h1{max-width:100%;font-size:clamp(2.35rem,11.7vw,3.45rem);line-height:1}
  body.layout-v2 h2,body.layout-v2 .portfolio-section-head h2{max-width:100%;font-size:clamp(2rem,9.6vw,2.85rem)}
  body.layout-v2 .section-heading{align-items:flex-start;flex-direction:column}
  body.layout-v2 .hero-actions,body.layout-v2 .cta-actions,body.layout-v2 .contact-buttons,body.layout-v2 .map-actions{display:grid;grid-template-columns:minmax(0,1fr);width:100%}
  body.layout-v2 .hero-actions .btn,body.layout-v2 .cta-actions .btn,body.layout-v2 .contact-buttons .btn,body.layout-v2 .map-actions .btn{width:100%}
  body.layout-v2 .hero-media{min-height:0;display:grid;grid-template-columns:minmax(0,1fr);gap:12px}
  body.layout-v2 .hero-image-main,body.layout-v2 .hero-image-secondary{position:relative;inset:auto;width:100%;height:auto;border:1px solid var(--line);border-radius:16px}
  body.layout-v2 .hero-image-main{aspect-ratio:4/3}
  body.layout-v2 .hero-image-secondary{aspect-ratio:16/9}
  body.layout-v2 .hero-stamp{top:12px;right:12px;width:96px}
  body.layout-v2 .service-rail{grid-template-columns:repeat(2,minmax(0,1fr))}
  body.layout-v2 .portfolio-card,body.layout-v2 .portfolio-card.portfolio-featured,body.layout-v2 .portfolio-card.portfolio-standard{grid-column:span 12;display:flex;min-height:0}
  body.layout-v2 .portfolio-card.portfolio-featured{grid-template-columns:minmax(0,1fr)}
  body.layout-v2 .portfolio-card-media,body.layout-v2 .portfolio-featured .portfolio-card-media{min-height:0;aspect-ratio:16/10}
  body.layout-v2 .about-services-list>a{min-height:0;padding:24px}
  body.layout-v2 .history-image{min-height:390px}
  body.layout-v2 .history-milestone{grid-template-columns:72px minmax(0,1fr);gap:16px}
  body.layout-v2 .history-milestone::before{left:35px}
  body.layout-v2 .history-year{width:72px}
  body.layout-v2 .component-grid,body.layout-v2 .roadmap-grid,body.layout-v2 .checklist-grid,
  body.layout-v2 .contact-details,body.layout-v2 .gallery-grid{grid-template-columns:minmax(0,1fr)}
  body.layout-v2 .gallery-grid{grid-auto-rows:340px}
  body.layout-v2 .contact-action{grid-template-columns:46px minmax(0,1fr) 18px;gap:12px}
  body.layout-v2 .cta-band{padding:28px 24px}
  body.layout-v2 .footer-grid{grid-template-columns:minmax(0,1fr)}
  body.layout-v2 .footer-brand{grid-column:auto}
  body.layout-v2 .footer-bottom{align-items:flex-start;flex-direction:column}
}

@media(max-width:420px){
  body.layout-v2 .container{width:min(calc(100% - 20px),var(--v3-container))}
  body.layout-v2 .portfolio-card-body,body.layout-v2 .leistung-overview-card,body.layout-v2 .buyer-detail-card,
  body.layout-v2 .buyer-reason,body.layout-v2 .value-card,body.layout-v2 .about-services-list>a{padding:22px}
  body.layout-v2 .service-rail span{font-size:.66rem}
}

/* Finale Bereinigung verwaister Alt-Raster */
body.layout-v2 .portfolio-section-head{
  display:block!important;
  width:100%;
  grid-template-columns:minmax(0,1fr)!important;
}
body.layout-v2 .portfolio-section-head>div{width:100%;min-width:0}
body.layout-v2 .legal-card{min-width:0;overflow:hidden}
body.layout-v2 .legal-contact a,body.layout-v2 .legal-contact a span{min-width:0;overflow-wrap:anywhere}
body.layout-v2 .legal-card .btn{max-width:100%;white-space:normal}
body.layout-v2 .btn{min-width:0;white-space:normal}

@media(max-width:640px){
  body.layout-v2 .leistung-overview-card h2,
  body.layout-v2 .buyer-detail-card h2,
  body.layout-v2 .legal-card h2{
    font-size:clamp(1.55rem,7.2vw,2rem);
    overflow-wrap:anywhere;
  }
}

/* Referenz-Hero: bei mittleren Breiten sauber untereinander statt gequetscht */
@media(max-width:1120px){
  body.layout-v2 .page-hero-simple-grid{
    grid-template-columns:minmax(0,1fr)!important;
    align-items:start;
    gap:32px;
  }
  body.layout-v2 .page-hero-aside{
    width:min(100%,820px);
    max-width:none;
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
  body.layout-v2 .page-hero-aside span{
    min-width:0;
    overflow-wrap:anywhere;
  }
}
@media(max-width:640px){
  body.layout-v2 .page-hero-aside{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  body.layout-v2 .page-hero-aside span{padding:14px 10px;font-size:.67rem;letter-spacing:.045em}
}

/* Glocken-Teaser – klare Trennung von Bild und Inhalt */
body.layout-v2 .bell-teaser-section{
  padding-top:clamp(28px,4vw,52px);
}
body.layout-v2 .bell-teaser{
  display:grid;
  grid-template-columns:minmax(0,1.04fr) minmax(420px,.96fr);
  min-height:520px;
  overflow:hidden;
  isolation:isolate;
  background:#121619;
  border:1px solid var(--line-strong);
  border-radius:22px;
}
body.layout-v2 .bell-teaser-image{
  position:relative;
  width:100%;
  min-width:0;
  min-height:520px;
  aspect-ratio:auto;
  overflow:hidden;
  background:#0c1013;
}
body.layout-v2 .bell-teaser-image::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:linear-gradient(90deg,transparent 72%,rgba(18,22,25,.24) 100%);
}
body.layout-v2 .bell-teaser-image img{
  display:block;
  width:100%;
  height:100%;
  max-width:none;
  object-fit:cover;
  object-position:center 47%;
}
body.layout-v2 .bell-teaser-copy{
  position:relative;
  z-index:2;
  align-self:stretch;
  display:flex;
  flex-direction:column;
  justify-content:center;
  min-width:0;
  padding:clamp(44px,5vw,72px);
  background:#121619;
}
body.layout-v2 .bell-teaser-copy .portfolio-meta{
  margin-bottom:20px;
}
body.layout-v2 .bell-teaser-copy h2{
  max-width:12ch;
  margin-bottom:24px;
  font-size:clamp(2.8rem,4.35vw,4.6rem);
  line-height:1.02;
  letter-spacing:-.045em;
  overflow-wrap:normal;
  word-break:normal;
}
body.layout-v2 .bell-teaser-copy p{
  max-width:55ch;
  margin-bottom:32px;
  color:#c4cbd0;
  font-size:clamp(1rem,1.2vw,1.08rem);
  line-height:1.72;
}
body.layout-v2 .bell-teaser-copy .btn{
  align-self:flex-start;
}
@media(max-width:1160px){
  body.layout-v2 .bell-teaser{
    grid-template-columns:minmax(0,1fr);
    min-height:0;
  }
  body.layout-v2 .bell-teaser-image{
    width:100%;
    min-height:0;
    aspect-ratio:16/9;
  }
  body.layout-v2 .bell-teaser-image::after{
    background:linear-gradient(180deg,transparent 72%,rgba(18,22,25,.28) 100%);
  }
  body.layout-v2 .bell-teaser-copy{
    padding:clamp(34px,6vw,58px);
  }
  body.layout-v2 .bell-teaser-copy h2{
    max-width:16ch;
  }
}
@media(max-width:640px){
  body.layout-v2 .bell-teaser{
    border-radius:16px;
  }
  body.layout-v2 .bell-teaser-image{
    aspect-ratio:4/3;
  }
  body.layout-v2 .bell-teaser-copy{
    padding:28px 24px 30px;
  }
  body.layout-v2 .bell-teaser-copy h2{
    max-width:100%;
    font-size:clamp(2rem,10vw,2.85rem);
  }
  body.layout-v2 .bell-teaser-copy p{
    font-size:.98rem;
    line-height:1.65;
  }
  body.layout-v2 .bell-teaser-copy .btn{
    width:100%;
  }
}
