/* ==================================================================
   METRIQ 2.0 // Komponenten für Startseite & Unterseiten
   Ergänzt metriq.css (Basis-Design aus Version 1)
   ================================================================== */

/* --- Navigation: Dropdown --- */
.nav-group { position: relative; }
.nav-group > a::after {
    content: "\203A";
    display: inline-block;
    transform: rotate(90deg);
    margin-left: 6px;
    font-size: 0.9em;
    opacity: 0.5;
}
.nav-dropdown {
    position: absolute;
    top: calc(100% + 14px);
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 10px;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s;
    z-index: 1200;
}
.nav-group:hover .nav-dropdown,
.nav-group:focus-within .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.nav-dropdown::before {
    content: "";
    position: absolute;
    top: -14px; left: 0; right: 0; height: 14px;
}
.nav-dropdown a {
    text-transform: none;
    letter-spacing: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
    padding: 10px 12px;
    border-radius: 8px;
    line-height: 1.35;
}
.nav-dropdown a span {
    display: block;
    font-weight: 400;
    font-size: 0.78rem;
    color: #64748b;
    margin-top: 2px;
}
.nav-dropdown a:hover { background: var(--bg-gray); }
nav a.is-current { color: var(--color-primary); }

/* Das Mobilmenue aus Version 1 war fuer vier Eintraege gebaut. Mit den
   Unterseiten sind es vierzehn, deshalb kleinere Schrift, linksbuendig
   und scrollbar statt zentriert. */
.mobile-nav {
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: 88px 26px 40px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.mobile-nav a:not(.btn) {
    font-size: 1rem;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}
.mobile-nav a:not(.btn):last-of-type { border-bottom: none; }
.mobile-nav .btn {
    margin-top: 22px;
    padding: 14px 18px;
    font-size: 0.95rem;
}
.mobile-nav-sub {
    font-size: 0.92rem !important;
    font-weight: 500 !important;
    padding-left: 16px !important;
    color: #475569 !important;
}
.mobile-nav-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #94a3b8;
    font-weight: 800;
    margin: 24px 0 4px;
}
.mobile-nav-label:first-child { margin-top: 0; }

/* --- Seiten-Hero (Unterseiten) ---
   Leichter Wei&szlig;schleier: Das Hintergrundbild bleibt sp&uuml;rbar,
   die Headline und der Lead-Text bleiben trotzdem gut lesbar. */
.page-hero {
    padding: 76px 0 56px;
    border-bottom: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.82);
}
.page-hero-inner { max-width: 810px; }
.page-hero h1 {
    font-size: 2.7rem;
    line-height: 1.14;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
}
.page-hero .lead {
    font-size: 1.12rem;
    color: #334155;
    max-width: 720px;
}
.page-hero .btn { margin-top: 28px; margin-right: 10px; }

.breadcrumb {
    font-size: 0.8rem;
    color: #64748b;
    margin-bottom: 20px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}
.breadcrumb a { color: #64748b; }
.breadcrumb a:hover { color: var(--color-primary); }
.breadcrumb span { opacity: 0.45; }

.eyebrow {
    display: inline-block;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-primary);
    margin-bottom: 14px;
}

/* --- Sektionen ---
   Das fixierte Hintergrundbild bleibt dem Hero vorbehalten. Inhaltssektionen
   bekommen einen deckenden Grund, sonst steht Flie&szlig;text auf dem Splash
   und wird unleserlich. */
.section {
    padding: 84px 0;
    background: var(--bg-white);
}

.section-alt {
    background: var(--bg-light);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}
.section-dark {
    background: var(--bg-slate);
    color: var(--text-light);
}
.section-dark h2, .section-dark h3 { color: #ffffff; }
.section-dark p { color: #cbd5e1; }
.section-dark .section-head p { color: #cbd5e1; }

.section-head {
    max-width: 770px;
    margin-bottom: 44px;
}
.section-head h2 {
    font-size: 2.05rem;
    line-height: 1.2;
    letter-spacing: -0.015em;
    margin-bottom: 16px;
}
.section-head p { color: #475569; font-size: 1.02rem; }

/* --- Kennzahlen-Board --- */

.footnote {
    font-size: 0.79rem;
    color: #64748b;
    line-height: 1.6;
    margin-top: 18px;
    max-width: 860px;
}
.footnote a { color: inherit; text-decoration: underline; }

/* --- Raster --- */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }

/* --- Helle Karte --- */
.card {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px 26px;
    box-shadow: var(--shadow-md);
}
.card h3 { font-size: 1.12rem; margin-bottom: 10px; line-height: 1.3; }
.card p { font-size: 0.94rem; color: #475569; }
.card-icon {
    width: 44px; height: 44px;
    display: block;
    margin-bottom: 16px;
}

/* --- Branchen-Einstieg --- */
.branch-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 34px 32px;
    box-shadow: var(--shadow-card);
    transition: transform 0.2s ease;
}
.branch-card:hover { transform: translateY(-4px); }
.branch-card h3 { font-size: 1.45rem; line-height: 1.22; margin-bottom: 14px; letter-spacing: -0.01em; }
.branch-card p { color: #475569; font-size: 0.98rem; }
.branch-card .btn { margin-top: auto; align-self: flex-start; }

/* --- Bausteine-Karten --- */
.baustein-card {
    display: flex;
    flex-direction: column;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px 26px;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s;
}
.baustein-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card);
    border-color: #cbd5e1;
}
.baustein-card img.card-icon { width: 46px; height: 46px; }
.baustein-card h3 { font-size: 1.15rem; margin-bottom: 4px; line-height: 1.3; }
.baustein-tech {
    font-size: 0.78rem;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 12px;
    display: block;
}
.baustein-card p { font-size: 0.93rem; color: #475569; margin-bottom: 16px; }
.baustein-card h3 + p { margin-top: 10px; }
.baustein-value {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--bg-slate);
    border-top: 1px solid var(--border-color);
    padding-top: 14px;
    margin-top: auto;
}
.baustein-value strong { color: var(--color-primary); }
.baustein-link {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-top: 14px;
    display: inline-block;
}
.baustein-link:hover { text-decoration: underline; }

/* --- Ablauf-Stufen --- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 26px 22px;
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
}
.step-num {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-primary);
    margin-bottom: 10px;
    display: block;
}
.step h3 { font-size: 1.05rem; margin-bottom: 8px; line-height: 1.3; }
.step p { font-size: 0.9rem; color: #475569; }
.step-meta {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--bg-slate);
}
.step-meta em { font-style: normal; font-weight: 400; color: #64748b; display: block; margin-top: 3px; font-size: 0.8rem; }

/* --- Checkliste --- */
.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 13px;
    font-size: 0.96rem;
    color: #334155;
    line-height: 1.55;
}
.checklist li::before {
    content: "";
    position: absolute;
    left: 0; top: 5px;
    width: 18px; height: 18px;
    border-radius: 50%;
    background-color: var(--color-primary);
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'><polyline points='20 6 9 17 4 12'/></svg>");
    background-size: 11px 11px;
    background-position: center;
    background-repeat: no-repeat;
}
.section-dark .checklist li { color: #cbd5e1; }

/* --- Schmerz-Liste --- */
.painlist { list-style: none; padding: 0; margin: 0; }
.painlist li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 13px;
    font-size: 0.96rem;
    color: #334155;
    line-height: 1.55;
}
.painlist li::before {
    content: "";
    position: absolute;
    left: 0; top: 5px;
    width: 18px; height: 18px;
    border-radius: 50%;
    background-color: #dc2626;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='4' stroke-linecap='round'><line x1='18' y1='6' x2='6' y2='18'/><line x1='6' y1='6' x2='18' y2='18'/></svg>");
    background-size: 10px 10px;
    background-position: center;
    background-repeat: no-repeat;
}
.section-dark .painlist li { color: #cbd5e1; }

/* --- Callout --- */
.callout {
    background: var(--bg-gray);
    border-left: 3px solid var(--color-primary);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 22px 26px;
    margin: 28px 0;
}
.callout p { font-size: 0.96rem; color: #334155; }
.callout p + p { margin-top: 10px; }
.callout strong { color: var(--bg-slate); }
.callout-title {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-primary);
    margin-bottom: 8px;
}
.section-dark .callout {
    background: rgba(255,255,255,0.06);
    border-left-color: var(--color-secondary);
}
.section-dark .callout p { color: #cbd5e1; }
.section-dark .callout strong { color: #ffffff; }
.section-dark .callout-title { color: var(--color-secondary); }

/* --- Plattform-Stack --- */
.stack { max-width: 940px; margin: 0 auto; }
.stack-layer {
    border-radius: var(--radius-lg);
    padding: 22px 26px;
    margin-bottom: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-white);
}
.stack-layer-label {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 12px;
}
.stack-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.stack-chip {
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 9px 14px;
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--text-main);
}
.stack-layer.is-core {
    background: var(--bg-slate);
    border-color: var(--bg-slate);
    color: #ffffff;
    box-shadow: var(--shadow-card);
}
.stack-layer.is-core .stack-layer-label { color: var(--color-secondary); }
.stack-layer.is-core .stack-chip {
    background: rgba(255,255,255,0.09);
    border-color: rgba(255,255,255,0.16);
    color: #f8fafc;
}
.stack-core-title { font-size: 1.2rem; font-weight: 700; margin-bottom: 6px; }
.stack-core-sub { font-size: 0.88rem; color: #94a3b8; margin-bottom: 16px; }
.stack-arrow {
    text-align: center;
    color: #94a3b8;
    font-size: 2.4rem;
    font-weight: 700;
    line-height: 1;
    margin: 4px 0 12px;
}

/* --- FAQ / Akkordeon --- */
.faq { max-width: 860px; }
.faq-item { border-bottom: 1px solid var(--border-color); }
.faq-item:first-child { border-top: 1px solid var(--border-color); }
.faq-q {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 20px 44px 20px 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    position: relative;
    font-family: inherit;
    line-height: 1.4;
}
.faq-q::after {
    content: "+";
    position: absolute;
    right: 6px; top: 50%;
    transform: translateY(-50%);
    font-size: 1.4rem;
    font-weight: 400;
    color: var(--color-primary);
}
.faq-item.is-open .faq-q::after { content: "\2013"; }
.faq-a {
    display: none;
    padding: 0 44px 22px 0;
    font-size: 0.95rem;
    color: #475569;
    line-height: 1.65;
}
.faq-item.is-open .faq-a { display: block; }
.faq-a p + p { margin-top: 12px; }
.faq-a ul { margin: 10px 0 0 20px; }
.faq-a li { margin-bottom: 6px; }

/* --- Tabelle --- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.datatable {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
    min-width: 640px;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.datatable th {
    background: var(--bg-slate);
    color: #ffffff;
    text-align: left;
    padding: 14px 18px;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700;
}
.datatable td {
    padding: 15px 18px;
    border-top: 1px solid var(--border-color);
    color: #334155;
    vertical-align: top;
}
.datatable tbody tr:nth-child(even) { background: var(--bg-light); }
.datatable strong { color: var(--bg-slate); }

/* --- Tags --- */
.tag-row { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.tag {
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 100px;
    padding: 6px 14px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
}
.section-dark .tag {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.14);
    color: #e2e8f0;
}

/* --- Split-Layout --- */
.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: center;
}
.split.wide-left { grid-template-columns: 1.12fr 0.88fr; }
.split.top { align-items: start; }
.split h2 { font-size: 1.9rem; line-height: 1.22; margin-bottom: 16px; letter-spacing: -0.015em; }
.split h3 { font-size: 1.22rem; margin-bottom: 12px; }
.split p { color: #475569; margin-bottom: 14px; }
.section-dark .split p { color: #cbd5e1; }
.split-visual img {
    width: 100%; height: auto; display: block;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
}

/* --- In-Page-Navigation --- */
.anchor-nav-wrap {
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-white);
    position: sticky;
    top: 109px;
    z-index: 900;
}
.anchor-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    padding: 14px 0;
}
.anchor-nav a {
    font-size: 0.82rem;
    font-weight: 600;
    color: #475569;
    padding: 7px 14px;
    border-radius: 100px;
    background: var(--bg-gray);
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}
.anchor-nav a:hover { background: var(--bg-slate); color: #ffffff; }

/* --- Vignetten (anonymisierte Projekte) --- */
.vignette {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--color-primary);
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
    padding: 26px 28px;
    box-shadow: var(--shadow-md);
}
.vignette-meta {
    font-size: 0.74rem;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    font-weight: 800;
    color: var(--color-primary);
    margin-bottom: 12px;
}
.vignette h3 { font-size: 1.08rem; margin-bottom: 10px; line-height: 1.35; }
.vignette p { font-size: 0.93rem; color: #475569; }
.vignette dl {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
    font-size: 0.87rem;
}
.vignette dt { font-weight: 700; color: var(--bg-slate); float: left; margin-right: 8px; }
.vignette dd { margin: 0 0 7px 0; color: #475569; overflow: hidden; }

/* --- Footer-Ergänzung: Sitemap über dem bestehenden Footer-Block --- */
.footer-nav {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    text-align: left;
    padding-bottom: 40px;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
}
.footer-nav h3 {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 800;
    color: #64748b;
    margin-bottom: 14px;
}
.footer-nav a {
    display: block;
    font-size: 0.88rem;
    color: #475569;
    margin-bottom: 9px;
    transition: color 0.15s;
}
.footer-nav a:hover { color: var(--color-primary); }

/* Kompaktere Navigation, da fünf Menüpunkte statt vier */
header nav { gap: 26px; }

/* --- Abstände --- */

.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-40 { margin-top: 40px; }
.mb-0 { margin-bottom: 0 !important; }

/* ==================================================================
   Responsive
   ================================================================== */
@media (max-width: 980px) {
    
    .steps { grid-template-columns: repeat(2, 1fr); }
    
    
    .split, .split.wide-left { grid-template-columns: 1fr; gap: 36px; }
    .anchor-nav-wrap { top: 0; }
    .footer-nav { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}

@media (max-width: 860px) {
    .grid-2 { grid-template-columns: 1fr; }
    
    .page-hero h1 { font-size: 2.05rem; }
    .section-head h2 { font-size: 1.65rem; }
    .split h2 { font-size: 1.55rem; }
    .section { padding: 60px 0; }
    .page-hero { padding: 48px 0 40px; }
    
}

@media (max-width: 560px) {
    
    .steps { grid-template-columns: 1fr; }
    
    
    
    .page-hero .btn { display: flex; margin-right: 0; margin-bottom: 10px; }
    .footer-nav { grid-template-columns: 1fr; }
}

/* Der Header muss ueber dem geoeffneten Mobilmenue liegen, sonst ist der
   Schliessen-Button verdeckt und das Menue laesst sich am Handy nicht zumachen. */
header { z-index: 1100; }

/* --- Ansprechpartner im Kontaktformular --- */
.cta-person {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    transition: background 0.15s, border-color 0.15s;
}
.cta-person:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.22);
}
.cta-person img {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center top;
    flex-shrink: 0;
    border: 2px solid rgba(255, 255, 255, 0.25);
}
.cta-person-text {
    font-size: 0.82rem;
    line-height: 1.5;
    color: #cbd5e1;
}
.cta-person-text strong {
    display: block;
    font-size: 0.95rem;
    color: #ffffff;
    margin-bottom: 2px;
}

/* --- Einmalkosten-Block in den Preiskacheln --- */
.price-onetime {
    margin-top: 18px;
    padding: 14px 16px;
    border: 1px dashed var(--border-color);
    border-radius: 8px;
    background: var(--bg-gray);
}
.price-card.featured .price-onetime {
    border-color: rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.06);
}
.price-onetime-title {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 10px;
}
.price-card.featured .price-onetime-title { color: #94a3b8; }
.price-onetime-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    font-size: 0.85rem;
    color: var(--text-muted);
    padding: 4px 0;
}
.price-onetime-row strong {
    color: var(--text-main);
    white-space: nowrap;
}
.price-card.featured .price-onetime-row { color: #cbd5e1; }
.price-card.featured .price-onetime-row strong { color: #ffffff; }

/* --- Rechenbeispiel unter den Preiskacheln --- */
.price-example {
    margin-top: 56px;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 38px 34px;
    box-shadow: var(--shadow-card);
}
.price-example-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 8px;
}
.price-example-lead {
    font-size: 0.92rem;
    color: var(--text-muted);
    max-width: 760px;
}
.price-example-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    margin-top: 28px;
}
.price-example-col h3 {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-primary);
    margin-bottom: 14px;
}
.price-example-row,
.price-example-sum {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    font-size: 0.88rem;
    padding: 7px 0;
    border-bottom: 1px solid var(--border-color);
}
.price-example-row span { color: var(--text-muted); }
.price-example-row strong { color: var(--text-main); white-space: nowrap; font-weight: 600; }
.price-example-sum {
    border-bottom: none;
    border-top: 2px solid var(--text-main);
    margin-top: 6px;
    font-weight: 700;
    color: var(--text-main);
}
.price-example-sum strong { white-space: nowrap; }
.price-example-note {
    font-size: 0.79rem;
    color: #64748b;
    margin-top: 24px;
    line-height: 1.45;
}
@media (max-width: 860px) {
    .price-example-grid { grid-template-columns: 1fr; gap: 22px; }
    .price-example { padding: 30px 24px; }
}

/* --- Hinweis unter dem Stufenblock --- */
.steps-note {
    margin-top: 30px;
    max-width: 820px;
    font-size: 0.88rem;
    line-height: 1.6;
    color: #cbd5e1;
    padding: 16px 20px;
    border-left: 3px solid var(--color-secondary);
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0 8px 8px 0;
}
.steps-note strong { color: #ffffff; }

/* --- Buttonpaar in der Einstiegs-Kachel --- */
.branch-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 24px;
}

/* --- Kontaktblock: breiter und luftiger --- */
.cta-section { padding: 116px 0; }
.cta-section .container { max-width: 1425px; }
.cta-inner {
    grid-template-columns: 1fr 460px;
    gap: 92px;
}
.cta-card { padding: 48px 44px; gap: 28px; }
.cta-text h2 { font-size: 2.45rem; }
.cta-text p { font-size: 1.06rem; line-height: 1.75; max-width: 46em; }
.cta-person { gap: 18px; padding: 18px 20px; }
.cta-person img { width: 86px; height: 86px; border-width: 3px; }
.cta-person-text { font-size: 0.88rem; }
.cta-person-text strong { font-size: 1.02rem; margin-bottom: 4px; }

@media (max-width: 1480px) {
    .cta-section .container { max-width: 1140px; }
}
@media (max-width: 1180px) {
    .cta-inner { grid-template-columns: 1fr 400px; gap: 64px; }
}
@media (max-width: 968px) {
    .cta-section { padding: 80px 0; }
    .cta-inner { grid-template-columns: 1fr; gap: 48px; }
    .cta-text h2 { font-size: 1.9rem; }
    .cta-card { padding: 36px 28px; }
    .cta-person img { width: 72px; height: 72px; }
}

/* --- Breite Baustein-Karte fuer die Simulation in der letzten Zeile --- */
.baustein-card--wide {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: flex-start;
    gap: 26px;
}
.baustein-card--wide > div { flex: 1; }
.baustein-card--wide img.card-icon { flex-shrink: 0; }
.baustein-card--wide p { max-width: 68ch; }
@media (max-width: 968px) {
    .baustein-card--wide { flex-direction: column; gap: 0; }
}

/* Die hervorgehobene Preiskachel wird um 3 % skaliert. Im schmalen Dreispalter
   ragt sie damit ueber den Viewport und erzeugt horizontales Scrollen. */
@media (max-width: 1100px) {
    .price-card.featured { transform: none; }
    .price-card.featured.reveal { transform: translateY(110px); }
    .price-card.featured.reveal.is-visible { transform: none; }
}

/* Schmale Schluessel-Wert-Tabellen in einer Spalte des .split-Grids.
   .datatable bringt min-width: 640px mit, das sprengt am Handy den Viewport.
   table-layout: fixed sorgt zusaetzlich dafuer, dass lange Zellinhalte
   umbrechen, statt die Spaltenbreite hochzutreiben. */
.datatable--kv {
    min-width: 0;
    table-layout: auto;
}
/* Beschriftung links: so breit wie ihr laengstes Wort, nie mitten im Wort umbrechen */
.datatable--kv td:first-child { width: 1%; white-space: nowrap; }
.datatable--kv td:last-child { overflow-wrap: break-word; hyphens: auto; }
/* Schmale Handys: Beschriftung ueber dem Wert statt zweier zu enger Spalten */
@media (max-width: 560px) {
    .datatable--kv,
    .datatable--kv tbody,
    .datatable--kv tr,
    .datatable--kv td { display: block; width: 100%; }
    .datatable--kv td:first-child { width: 100%; white-space: normal; hyphens: auto; padding-bottom: 2px; }
    .datatable--kv td:last-child { border-top: 0; padding-top: 0; }
}

/* Grid- und Flex-Kinder schrumpfen von sich aus nicht unter ihre
   min-content-Breite. Lange deutsche Komposita und das groessere Portraitbild
   treiben diese Breite hoch und sprengen am Handy den Viewport. */
.cta-inner > * { min-width: 0; }
.cta-person-text { min-width: 0; }
.pricing-grid > * { min-width: 0; }
.price-onetime-row span,
.price-example-row span,
.price-example-sum span { min-width: 0; overflow-wrap: anywhere; }

@media (max-width: 420px) {
    .cta-person { padding: 14px; gap: 12px; }
    .cta-person img { width: 60px; height: 60px; }
}

/* Lange deutsche Komposita ("Produktionsprozessen", "Zustandsueberwachung")
   passen auf schmalen Displays in keine Ueberschriftenzeile und werden sonst
   abgeschnitten. <html lang="de"> liefert die Trennstellen. */
@media (max-width: 560px) {
    h1, h2, h3, .baustein-tech, .metric-label {
        overflow-wrap: break-word;
        hyphens: auto;
    }
}

/* Zwei gleichwertige Kacheln nebeneinander: gleiche Spaltenbreite und gleiche
   Hoehe, damit die kuerzere nicht abgeschnitten neben der laengeren steht. */
.split--cards {
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
}
.split--cards > .branch-card { display: flex; flex-direction: column; }
.split--cards > .branch-card > .branch-actions { margin-top: auto; }
@media (max-width: 980px) {
    .split--cards { grid-template-columns: 1fr; }
}

/* Weisse Karten in dunklen Sektionen: .section-dark faerbt h3 weiss, .card h3
   setzt keine eigene Farbe. Ergebnis war weisse Schrift auf weissem Grund. */
.section-dark .card h3 { color: var(--bg-slate); }
.section-dark .step h3 { color: var(--bg-slate); }
.section-dark .baustein-card h3 { color: var(--bg-slate); }
.section-dark .card strong { color: var(--bg-slate); }
.card p + p { margin-top: 12px; }

/* Karten ohne Hinweiszeile: Der Link uebernimmt das margin-top: auto der
   frueheren .baustein-value, damit er in jeder Kartenreihe buendig unten sitzt. */
.baustein-card > p + .baustein-link {
    margin-top: auto;
    align-self: flex-start;
}

/* Links im Fliesstext: Farbe des umgebenden Texts statt Browser-Blau.
   :where() haelt die Prioritaet bei null, bewusst gestylte Links (Navigation, Breadcrumb, Buttons) bleiben unveraendert. */
:where(main a:not([class])) { color: inherit; }
:where(main a:not([class])):hover { color: var(--color-primary); }
:where(.section-dark a:not([class])) { color: var(--color-secondary); }
:where(.section-dark a:not([class])):hover { color: #ffffff; }

/* Blau auf dunklen Flaechen: hellere Koenigsblau-Stufe statt #0052ff */
.section-dark .checklist li::before { background-color: var(--color-secondary); }

/* Textbereich ohne Bildspalte: volle Breite, lesbare Zeilenlaenge */
.split.single { grid-template-columns: 1fr; max-width: 820px; }

/* --- Galerie: Einblick in die Werkzeuge --- */
.galerie { max-width: 1040px; margin: 0 auto; }
.galerie-fenster {
    position: relative;
    aspect-ratio: 16 / 9;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    overflow: hidden;
}
.galerie-slide { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; padding: 16px 64px; }
.galerie-slide.is-active,
.galerie:not(.js-aktiv) .galerie-slide:first-of-type { display: flex; }
.galerie-slide img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; border-radius: 6px; box-shadow: 0 6px 22px rgba(15, 23, 42, 0.12); }
.galerie-pfeil {
    position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
    width: 44px; height: 44px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--border-color); background: rgba(255, 255, 255, 0.94);
    color: var(--bg-slate); font-size: 28px; line-height: 1; cursor: pointer;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.15);
}
.galerie-pfeil:hover { background: #ffffff; color: var(--color-primary); }
.galerie-zurueck { left: 12px; }
.galerie-weiter { right: 12px; }
.galerie:not(.js-aktiv) .galerie-pfeil,
.galerie:not(.js-aktiv) .galerie-leiste { display: none; }
.galerie-caption { display: none; max-width: 760px; margin: 20px auto 0; text-align: center; }
.galerie-caption.is-active,
.galerie:not(.js-aktiv) .galerie-caption:first-of-type { display: block; }
.galerie-caption strong { display: block; font-size: 1.02rem; margin-bottom: 4px; }
.galerie-caption strong a { color: var(--bg-slate); }
.galerie-caption strong a:hover { color: var(--color-primary); }
.galerie-caption p { color: #475569; font-size: 0.95rem; margin: 0; }
.galerie-leiste { display: flex; align-items: center; gap: 16px; margin-top: 22px; }
.galerie-zaehler { font-size: 0.82rem; font-weight: 700; color: #64748b; white-space: nowrap; min-width: 44px; }
.galerie-thumbs { display: flex; gap: 10px; overflow-x: auto; padding: 4px 2px; flex: 1; scrollbar-width: thin; }
.galerie-thumb {
    flex: 0 0 auto; width: 112px; height: 64px; padding: 0;
    border: 2px solid transparent; border-radius: 8px; overflow: hidden;
    background: var(--bg-light); cursor: pointer; opacity: 0.6;
    transition: opacity 0.2s ease, border-color 0.2s ease;
}
.galerie-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.galerie-thumb:hover,
.galerie-thumb.is-active { opacity: 1; }
.galerie-thumb.is-active { border-color: var(--color-primary); }
@media (max-width: 560px) {
    .galerie-fenster { aspect-ratio: 4 / 3; }
    .galerie-slide { padding: 10px 44px; }
    .galerie-pfeil { width: 36px; height: 36px; font-size: 24px; }
    .galerie-zurueck { left: 6px; }
    .galerie-weiter { right: 6px; }
    .galerie-leiste { gap: 10px; }
    .galerie-thumb { width: 84px; height: 50px; }
}

/* Lightbox: Blaettern innerhalb der Galerie */
.lightbox-nav {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 52px; height: 52px; border-radius: 50%; border: 0;
    display: none; align-items: center; justify-content: center;
    background: rgba(255, 255, 255, 0.16); color: #ffffff;
    font-size: 34px; line-height: 1; cursor: pointer;
}
.lightbox.has-nav .lightbox-nav { display: flex; }
.lightbox-nav:hover { background: rgba(255, 255, 255, 0.3); }
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

/* Drei Schritte statt vier (z. B. Kamera-Intelligenz) */
.steps.steps--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 980px) { .steps.steps--3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .steps.steps--3 { grid-template-columns: 1fr; } }

/* Aktuelles auf der Startseite: Workshop- und Newsletter-Kachel */
.aktuelles-section { background: var(--bg-white); }
.aktuelles-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 24px; align-items: stretch; }
.ws-teaser, .nl-teaser {
    display: flex; align-items: center; min-height: 300px;
    padding: 36px; border-radius: var(--radius-lg);
}
.ws-teaser { background: var(--bg-gray); border: 1px solid var(--border-color); }
.nl-teaser { background: var(--bg-gray); border: 1px solid var(--border-color); }
.ws-teaser-text { max-width: 400px; color: var(--bg-slate); line-height: 1.55; }
.ws-teaser-text .eyebrow { margin-bottom: 10px; }
.ws-teaser-text strong { display: block; font-size: 1.35rem; line-height: 1.3; letter-spacing: -0.01em; }
.ws-teaser-text p { margin: 12px 0 0; color: #334155; }
.ws-teaser-meta { display: block; margin-top: 14px; font-size: 0.92rem; font-weight: 600; color: #475569; }
.ws-teaser .btn, .nl-teaser .btn { margin-top: 22px; }

/* Foto des Workshopraums, dezent im Hintergrund (Startseiten-Hinweis und Workshop-Kopf) */
.ws-foto { position: relative; overflow: hidden; isolation: isolate; }
.ws-foto::before {
    content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 58%;
    background: url('../../images/workshop-raum.webp') center 42% / cover no-repeat;
    opacity: 0.5;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 72%);
    mask-image: linear-gradient(to right, transparent 0%, #000 72%);
    z-index: -1; pointer-events: none;
}
.ws-teaser.ws-foto::before {
    width: 50%; background-position: center 58%; opacity: 0.55;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 40%);
    mask-image: linear-gradient(to right, transparent 0%, #000 40%);
}
.page-hero.ws-foto::before {
    width: 52%; opacity: 0.34;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 85%);
    mask-image: linear-gradient(to right, transparent 0%, #000 85%);
}
@media (max-width: 1100px) {
    .page-hero.ws-foto::before { opacity: 0.2; }
    .aktuelles-grid { grid-template-columns: 1fr; }
    .ws-teaser, .nl-teaser { min-height: 0; padding: 30px; }
    .ws-teaser-text { max-width: 60%; }
    .ws-teaser.ws-foto::before { width: 46%; }
}
@media (max-width: 760px) {
    .ws-foto::before, .page-hero.ws-foto::before {
        width: 100%; opacity: 0.16;
        -webkit-mask-image: none; mask-image: none;
    }
    /* Startseiten-Hinweis: Foto als Band oben, Text darunter */
    .ws-teaser { display: block; min-height: 0; padding: 190px 22px 28px; }
    .nl-teaser { padding: 26px 22px; }
    .ws-teaser-text { max-width: none; }
    .ws-teaser-text strong { font-size: 1.3rem; }
    .ws-teaser.ws-foto::before {
        width: 100%; bottom: auto; height: 200px; opacity: 0.85;
        background-position: center 60%;
        -webkit-mask-image: linear-gradient(to bottom, #000 45%, transparent 100%);
        mask-image: linear-gradient(to bottom, #000 45%, transparent 100%);
    }
}

/* Branchen-Kennzeichen auf den Baustein-Karten */
.branchen { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.branche {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 0.74rem; font-weight: 600; color: #334155;
    background: var(--bg-gray); border: 1px solid var(--border-color);
    border-radius: 999px; padding: 3px 10px; white-space: nowrap;
}
.branchen-legende { font-size: 0.85rem; color: #64748b; margin-top: 12px; }.branchen--hero { margin: 0 0 18px; }

/* Portraet auf "Ueber uns" rund wie im Kontaktbereich */
.trust-photo-wrap img { border-radius: 50%; aspect-ratio: 1 / 1; }

/* --- Blog --- */
.blog-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.blog-card {
    display: flex; flex-direction: column; overflow: hidden;
    background: var(--bg-white); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-md); color: inherit;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-card); border-color: #cbd5e1; }
.blog-card img { width: 100%; height: auto; display: block; border-bottom: 1px solid var(--border-color); }
.blog-card-text { padding: 24px 26px 26px; display: flex; flex-direction: column; gap: 10px; }
.blog-card-meta { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--color-primary); }
.blog-card h3 { font-size: 1.15rem; line-height: 1.3; margin: 0; }
.blog-card p { font-size: 0.93rem; color: #475569; margin: 0; }
.blog-card .baustein-link { margin-top: 4px; }
.blog-bild {
    width: 100%; height: auto; display: block; border-radius: var(--radius-lg);
    border: 1px solid var(--border-color); margin-bottom: 34px;
}
.blog-text { max-width: 760px; margin: 0 auto; }
.blog-text p { color: #334155; margin-bottom: 16px; }
.blog-meta { font-size: 0.88rem; color: #64748b; margin-top: 18px; }
@media (max-width: 860px) {
    .blog-grid { grid-template-columns: 1fr; }
}
.blog-text h2 { margin: 44px 0 14px; font-size: 1.55rem; line-height: 1.25; }
.blog-text > .callout:first-child { margin-top: 0; }
.blog-text h2:first-child { margin-top: 0; }
.blog-text .callout { margin: 28px 0; }

/* Nur fuer Screenreader und Suchmaschinen sichtbar */
.visually-hidden {
    position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* --- Videos (Simulation) --- */
.video-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; margin-top: 8px; }
.video-karte { margin: 0; background: var(--bg-white); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); }
.video-karte video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: #0f172a; }
.video-karte figcaption { padding: 18px 22px 22px; display: flex; flex-direction: column; gap: 6px; }
.video-karte figcaption strong { font-size: 1.05rem; color: var(--bg-slate); }
.video-karte figcaption span { font-size: 0.92rem; color: #475569; line-height: 1.55; }
@media (max-width: 860px) { .video-grid { grid-template-columns: 1fr; } }

/* --- Baustein-Slider (Startseite) --- */
.slider-spur {
    display: flex; gap: 24px; overflow-x: auto; overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory; scroll-padding-inline: 12px; scrollbar-width: none;
    margin: 0 -12px; padding: 10px 12px 22px; cursor: grab;
}
.slider-spur::-webkit-scrollbar { display: none; }
.slider-spur:focus-visible { outline: 2px solid var(--color-secondary); outline-offset: 2px; }
.slider-spur.is-ziehen { cursor: grabbing; scroll-snap-type: none; user-select: none; }
.slider-spur.is-ziehen a { pointer-events: none; }
.slider-spur > .baustein-card { flex: 0 0 calc((100% - 48px) / 3); scroll-snap-align: start; }
.slider-spur img { -webkit-user-drag: none; }
.slider-steuerung { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 14px; }
.slider-pfeil {
    width: 44px; height: 44px; border-radius: 50%; flex: 0 0 auto;
    display: flex; align-items: center; justify-content: center; padding: 0 0 3px;
    border: 1px solid rgba(255, 255, 255, 0.3); background: transparent; color: #ffffff;
    font-size: 28px; line-height: 1; cursor: pointer; transition: background 0.2s, border-color 0.2s, opacity 0.2s;
}
.slider-pfeil:hover:not(:disabled) { background: var(--color-secondary); border-color: var(--color-secondary); color: var(--bg-slate); }
.slider-pfeil:disabled { opacity: 0.3; cursor: default; }
.slider-punkte { display: flex; gap: 8px; }
.slider-punkte span { width: 8px; height: 8px; border-radius: 999px; background: rgba(255, 255, 255, 0.3); transition: width 0.25s, background 0.25s; }
.slider-punkte span.is-aktiv { width: 24px; background: var(--color-secondary); }
@media (max-width: 1024px) { .slider-spur > .baustein-card { flex-basis: calc((100% - 24px) / 2); } }
@media (max-width: 640px) {
    .slider-spur { gap: 16px; }
    .slider-spur > .baustein-card { flex-basis: 85%; }
}

/* --- Fotos in den Baustein-Kacheln (Startseite) --- */
.slider-spur > .baustein-card { overflow: hidden; }
.baustein-foto {
    display: block; width: calc(100% + 52px); max-width: none; height: auto;
    aspect-ratio: 16 / 9; object-fit: cover; margin: -28px -26px 22px;
}

/* --- Titelbild Startseite --- */
.hero--foto { position: relative; isolation: isolate; overflow: hidden; background: #ffffff; }
.hero--foto::before {
    content: ""; position: absolute; inset: 0; z-index: -2;
    background: url("../../images/bausteine/titelbild-fertigung.webp") center 40% / cover no-repeat;
    opacity: 0.6;
}
.hero--foto::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: radial-gradient(ellipse 60% 70% at 50% 50%, rgba(255,255,255,0.78) 0%, rgba(255,255,255,0.4) 60%, rgba(255,255,255,0) 100%);
}
@media (max-width: 480px) {
    .hero h1 { font-size: 2.3rem; hyphens: auto; -webkit-hyphens: auto; }
}

/* Foto der jeweiligen Startseiten-Kachel im Kopf der Baustein-Seiten */
.hero-bild { position: relative; overflow: hidden; isolation: isolate; }
.hero-bild::before {
    content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 55%;
    background: linear-gradient(rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.3)), var(--hero-bild) center / cover no-repeat;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 70%);
    mask-image: linear-gradient(to right, transparent 0%, #000 70%);
    z-index: -1; pointer-events: none;
}
@media (max-width: 1100px) {
    .hero-bild::before { width: 70%; background: linear-gradient(rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.55)), var(--hero-bild) center / cover no-repeat; }
}
