:root {
    --bg: #f6f2eb;
    --paper: #fffdf9;
    --surface: #ffffff;
    --text: #1f2933;
    --muted: #5d6b78;
    --line: #d5c7b7;
    --brand: #9b5c2e;
    --brand-dark: #6f3f1c;
    --accent: #264653;
    --success: #e8f5ec;
    --error: #fdecec;
    --shadow: 0 20px 45px rgba(31, 41, 51, 0.08);
    --radius: 18px;
    --radius-sm: 12px;
    --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: Georgia, "Times New Roman", serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(155, 92, 46, 0.12), transparent 30%),
        linear-gradient(180deg, #f7f3ee 0%, #f4efe8 40%, #faf8f4 100%);
    line-height: 1.65;
}
a { color: var(--brand-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }
.container { width: min(var(--container), calc(100% - 2rem)); margin: 0 auto; }
.skip-link {
    position: absolute; left: -999px; top: 0; background: var(--brand-dark); color: #fff; padding: 0.75rem 1rem; z-index: 50;
}
.skip-link:focus { left: 1rem; top: 1rem; }
.site-header {
    position: sticky; top: 0; z-index: 40;
    backdrop-filter: blur(18px);
    background: rgba(250, 248, 244, 0.9);
    border-bottom: 1px solid rgba(111, 63, 28, 0.12);
}
.nav-open { overflow: hidden; }
.header-inner, .footer-bottom, .content-grid, .footer-grid, .admin-header-row {
    display: flex; gap: 1.5rem; align-items: center; justify-content: space-between;
}
.header-inner { min-height: 78px; }
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(20, 23, 26, 0.34);
    z-index: 120;
}
.nav-overlay[hidden] { display: none; }
.brand { display: flex; align-items: center; gap: 0.85rem; }
.brand small { display: block; color: var(--muted); }
.brand > span:last-child { min-width: 0; }
.brand strong {
    display: block;
    line-height: 1.08;
}
.brand-mark {
    display: grid; place-items: center;
    width: 3rem; height: 3rem; border-radius: 14px;
    background: linear-gradient(135deg, var(--brand), #d58d51);
    color: #fff; font-weight: 700;
}
.main-nav { display: flex; gap: 1rem; flex-wrap: wrap; }
.main-nav-brand {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}
.main-nav-brand small {
    display: block;
    color: var(--muted);
    font-size: 0.78rem;
}
.nav-toggle {
    display: none;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0.55rem;
    border-radius: 999px;
    border: 1px solid rgba(111, 63, 28, 0.14);
    background: rgba(255, 253, 249, 0.96);
    color: var(--brand-dark);
}
.nav-toggle svg { width: 1.45rem; height: 1.45rem; }
.nav-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.45rem;
    height: 2.45rem;
    border: 0;
    border-radius: 999px;
    background: rgba(20, 23, 26, 0.14);
    color: #fff;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.18);
}
.nav-close svg {
    width: 1.2rem;
    height: 1.2rem;
}
.mobile-nav-drawer {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(340px, 84vw);
    z-index: 130;
    transform: translateX(-102%);
    visibility: hidden;
    pointer-events: none;
    transition: transform 180ms ease, visibility 180ms ease;
}
.mobile-nav-panel {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #fffdf9;
    border-top-right-radius: 1rem;
    border-bottom-right-radius: 1rem;
    box-shadow: 24px 0 40px rgba(31, 41, 51, 0.12);
    overflow-y: auto;
    padding: 1rem 1rem 1.5rem;
}
.mobile-nav-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 0.9rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid rgba(111, 63, 28, 0.12);
}
.mobile-nav-links {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.4rem;
}
.mobile-nav-links a {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 0.92rem 0.85rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 0.85rem;
    color: #3f4a58;
}
.mobile-nav-links a.is-active {
    background: rgba(111, 63, 255, 0.06);
    color: #5a48ff;
}
.nav-open .mobile-nav-drawer {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.hero {
    position: relative;
    overflow: hidden;
    padding: 2.4rem 0 1.5rem;
}
.hero-showcase { isolation: isolate; }
.hero-backdrop {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: -1;
}
.hero-grid-svg {
    position: absolute;
    inset: -4rem 0 auto;
    width: 100%;
    height: 42rem;
    stroke: rgba(31, 41, 51, 0.12);
    mask-image: radial-gradient(32rem 32rem at center, white, transparent);
}
.hero-blob {
    position: absolute;
    top: -3rem;
    left: 52%;
    width: min(32rem, 46vw);
    aspect-ratio: 0.78;
    background: linear-gradient(180deg, rgba(214, 130, 74, 0.34), rgba(111, 63, 28, 0.18));
    filter: blur(46px);
    opacity: 0.85;
    clip-path: polygon(63.1% 29.5%, 100% 17.1%, 76.6% 3%, 48.4% 0%, 44.6% 4.7%, 54.5% 25.3%, 59.8% 49%, 55.2% 57.8%, 44.4% 57.2%, 27.8% 47.9%, 35.1% 81.5%, 0% 97.7%, 39.2% 100%, 35.2% 81.4%, 97.2% 52.8%, 63.1% 29.5%);
}
.hero-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
    gap: 2rem;
    align-items: center;
}
.hero-copy,
.hero-visual { min-width: 0; }
.hero-card, .article-card, .sidebar-card, .card, .tool-card, .form-card, .admin-login, .admin-sidebar, .admin-main, .consent-card {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(111, 63, 28, 0.12);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.hero-card, .article-card, .sidebar-card, .tool-card, .form-card, .card, .admin-main { padding: 1.35rem; }
.eyebrow, .small { color: var(--muted); font-size: 0.95rem; }
h1, h2, h3 { line-height: 1.15; margin-top: 0; font-weight: 700; }
h1 { font-size: clamp(1.8rem, 3vw, 2.8rem); letter-spacing: -0.03em; margin-bottom: 0.6rem; }
.hero .hero-title {
    font-size: clamp(2.5rem, 5vw, 5rem) !important;
    line-height: 0.95;
    max-width: 10ch;
    margin-bottom: 0.75rem;
    text-wrap: balance;
}
.hero .hero-title.hero-title-long {
    font-size: clamp(1.9rem, 3.4vw, 3.6rem) !important;
    line-height: 1;
    max-width: 14ch;
}
h2 { font-size: clamp(1.5rem, 2vw, 2rem); }
.hero-summary { font-size: 1.12rem; max-width: 58ch; color: #314252; margin-bottom: 1rem; }
.hero-actions, .trust-strip, .consent-actions, .admin-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; align-items: center; }
.hero-actions { gap: 0.75rem; }
.trust-strip { margin-top: 0.65rem; color: var(--muted); font-size: 0.94rem; gap: 0.75rem; }
.button, button, input, textarea, select {
    font: inherit;
}
.button, button[type="submit"] {
    display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
    border: 0; border-radius: 999px; cursor: pointer;
    background: var(--brand-dark); color: #fff; padding: 0.8rem 1.2rem;
}
.button-secondary { background: transparent; color: var(--brand-dark); border: 1px solid rgba(111, 63, 28, 0.25); }
.content-grid { align-items: flex-start; }
.content-grid > article { flex: 2.2; }
.content-grid > aside { flex: 1; position: sticky; top: 92px; }
.body-block, .faq-block, .calculator-result, .tool-card, .related-card { margin-top: 2rem; }
.cards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.cards-grid-admin .card { min-height: 120px; }
.card strong { display: block; font-size: 2rem; }
.footer-grid { align-items: flex-start; padding: 2rem 0 0.8rem; }
.site-footer { margin-top: 4rem; background: #f1e6da; border-top: 1px solid rgba(111, 63, 28, 0.12); }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li + li { margin-top: 0.4rem; }
.footer-bottom { padding: 1rem 0 2rem; border-top: 1px solid rgba(111, 63, 28, 0.12); }
.link-button {
    background: transparent;
    color: var(--brand-dark);
    padding: 0;
    border: 0;
    box-shadow: none;
    text-decoration: underline;
    text-underline-offset: 0.12em;
}
.stack-form { display: grid; gap: 1rem; }
label { display: grid; gap: 0.45rem; font-weight: 600; }
input, textarea, select {
    width: 100%; padding: 0.8rem 0.95rem; border-radius: 14px;
    border: 1px solid rgba(31, 41, 51, 0.16); background: var(--paper);
}
input:focus, textarea:focus, select:focus, a:focus, button:focus {
    outline: 3px solid rgba(38, 70, 83, 0.24); outline-offset: 2px;
}
.honeypot { position: absolute; left: -9999px; opacity: 0; }
.notice { padding: 0.9rem 1rem; border-radius: 14px; margin-bottom: 1rem; }
.notice.success { background: var(--success); }
.notice.error { background: var(--error); }
.breadcrumbs { margin-bottom: 0.7rem; font-size: 0.9rem; }
.eyebrow { display: inline-block; margin-bottom: 0.35rem; font-size: 0.88rem; }
.hero-visual {
    position: relative;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding: 1.1rem;
    border-radius: 1.75rem;
    background:
        linear-gradient(180deg, rgba(22, 24, 28, 0.28), rgba(22, 24, 28, 0.1)),
        url("../../images/bad-fliesen.jpg") center/cover no-repeat;
    box-shadow: 0 24px 50px rgba(31, 41, 51, 0.12);
    overflow: hidden;
    width: fit-content;
    max-width: 100%;
    margin-left: auto;
}
.hero-visual.hero-visual-stuttgart {
    background:
        linear-gradient(180deg, rgba(22, 24, 28, 0.28), rgba(22, 24, 28, 0.1)),
        url("../../images/stuttgart.jpg") center/cover no-repeat;
}
.hero-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 253, 249, 0.08), rgba(255, 253, 249, 0));
    pointer-events: none;
}
.hero-visual-column {
    width: 11rem;
    display: flex;
    flex: none;
    flex-direction: column;
    gap: 1rem;
}
.hero-visual-column-1 { padding-top: 8rem; }
.hero-visual-column-2 { padding-top: 3.5rem; }
.hero-visual-column-3 { padding-top: 0.25rem; }
.hero-visual.hero-visual-count-1 {
    display: block;
    width: min(100%, 14rem);
}
.hero-visual.hero-visual-count-2,
.hero-visual.hero-visual-count-3 {
    display: grid;
    justify-content: stretch;
    gap: 0.9rem;
}
.hero-visual.hero-visual-count-2 { grid-template-columns: repeat(2, minmax(0, 11rem)); }
.hero-visual.hero-visual-count-3 { grid-template-columns: repeat(3, minmax(0, 10rem)); }
.hero-visual.hero-visual-count-1 .hero-visual-column,
.hero-visual.hero-visual-count-2 .hero-visual-column,
.hero-visual.hero-visual-count-3 .hero-visual-column {
    width: auto;
}
.hero-visual.hero-visual-count-1 .hero-visual-column-1,
.hero-visual.hero-visual-count-2 .hero-visual-column-1,
.hero-visual.hero-visual-count-2 .hero-visual-column-2,
.hero-visual.hero-visual-count-3 .hero-visual-column-1,
.hero-visual.hero-visual-count-3 .hero-visual-column-2,
.hero-visual.hero-visual-count-3 .hero-visual-column-3 {
    padding-top: 0;
}
.hero-tile {
    position: relative;
    z-index: 1;
    display: block;
    padding: 1rem;
    min-height: 12.5rem;
    border-radius: 1.25rem;
    background: rgba(255, 253, 249, 0.92);
    border: 1px solid rgba(31, 41, 51, 0.08);
    box-shadow: 0 16px 34px rgba(31, 41, 51, 0.08);
    color: var(--text);
}
.hero-tile:hover { text-decoration: none; transform: translateY(-2px); }
.hero-tile strong {
    display: block;
    font-size: 1rem;
    line-height: 1.15;
    margin-bottom: 0.55rem;
}
.hero-tile span:last-child {
    display: block;
    font-size: 0.84rem;
    line-height: 1.45;
    color: var(--muted);
}
.hero-tile-kicker {
    display: inline-block;
    margin-bottom: 0.65rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--brand-dark);
}
.eyebrow { display: none; }
.page-inline-header {
    margin-bottom: 1rem;
}
.page-inline-header h1 {
    margin-bottom: 0.5rem;
}
.image-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}
.image-card {
    border-radius: 1.25rem;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(111, 63, 28, 0.12);
    box-shadow: var(--shadow);
}
.image-card a {
    display: block;
    color: inherit;
}
.image-card a:hover { text-decoration: none; }
.image-card img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}
.image-card-copy {
    padding: 1rem;
}
.image-card-copy strong {
    display: block;
    font-size: 1.02rem;
    margin-bottom: 0.4rem;
}
.image-card-copy span {
    display: block;
    color: var(--muted);
    font-size: 0.9rem;
}
.reference-media {
    margin: 1.5rem 0 0;
}
.reference-media img {
    display: block;
    width: 100%;
    border-radius: 1.25rem;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    box-shadow: 0 16px 34px rgba(31, 41, 51, 0.1);
}
#cc-main {
    --cc-font-family: Georgia, "Times New Roman", serif;
    --cc-modal-border-radius: 18px;
    --cc-btn-border-radius: 999px;
    --cc-bg: #fffdf9;
    --cc-primary-color: #1f2933;
    --cc-secondary-color: #5d6b78;
    --cc-btn-primary-bg: #6f3f1c;
    --cc-btn-primary-color: #fff;
    --cc-btn-primary-hover-bg: #8a5329;
    --cc-btn-secondary-bg: #f2ebe3;
    --cc-btn-secondary-color: #6f3f1c;
    --cc-btn-secondary-hover-bg: #e9ddd0;
    --cc-separator-border-color: rgba(111, 63, 28, 0.12);
}
.content-section { padding-bottom: 3rem; }
.content-section-no-hero { padding-top: 2rem; }
.result-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.result-grid > div { background: #f8f1e9; padding: 1rem; border-radius: 14px; }
.breadcrumbs { display: flex; gap: 0.5rem; flex-wrap: wrap; color: var(--muted); margin-bottom: 1rem; font-size: 0.95rem; }
.sticky-cta {
    position: sticky; bottom: 0; z-index: 30; display: flex; justify-content: center;
    padding: 0.8rem; background: linear-gradient(180deg, rgba(246, 242, 235, 0), rgba(246, 242, 235, 0.95));
}
.admin-body { background: #f4efe7; }
.admin-shell { display: grid; grid-template-columns: 260px 1fr; min-height: 100vh; }
.admin-sidebar { padding: 1.5rem; }
.admin-sidebar nav { display: grid; gap: 0.5rem; }
.admin-main { margin: 1.25rem; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th, .admin-table td { padding: 0.8rem; text-align: left; border-bottom: 1px solid rgba(31, 41, 51, 0.1); vertical-align: top; }
.admin-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.log-box { overflow: auto; background: #1e2630; color: #f7f7f7; padding: 1rem; border-radius: 14px; }
.phone-link { display: inline-block; margin-top: 1rem; font-weight: 700; }
.search-form, .search-results, .archive-page, .reference-page, .search-page { padding: 2rem 0; }
details summary { cursor: pointer; font-weight: 700; }
details[open] summary { margin-bottom: 0.75rem; }
.embed-placeholder, .embed-frame {
    margin-top: 1rem; padding: 1.25rem; border-radius: 16px; background: #f2ebe3; border: 1px dashed rgba(111, 63, 28, 0.25);
}
.embed-frame iframe { width: 100%; min-height: 360px; border: 0; border-radius: 12px; }

@media (max-width: 900px) {
    .header-inner, .footer-grid, .footer-bottom, .content-grid, .admin-header-row { flex-direction: column; align-items: stretch; }
    .header-inner { flex-direction: row; align-items: center; gap: 1rem; }
    .nav-toggle { display: inline-flex; flex-direction: column; justify-content: center; }
    .main-nav { display: none; }
    .brand {
        gap: 0.7rem;
        max-width: calc(100% - 3.4rem);
    }
    .brand small {
        display: none;
    }
    .brand strong {
        font-size: 0.98rem;
        overflow-wrap: anywhere;
    }
    .hero { padding: 1.25rem 0 0.7rem; }
    .hero-shell { grid-template-columns: 1fr; gap: 1.2rem; align-items: start; }
    .content-grid > aside { position: static; }
    .admin-shell { grid-template-columns: 1fr; }
    .result-grid { grid-template-columns: 1fr; }
    .hero .hero-title { font-size: clamp(1.9rem, 6vw, 3rem) !important; max-width: 100%; }
    .hero .hero-title.hero-title-long { font-size: clamp(1.55rem, 4.8vw, 2.5rem) !important; max-width: 100%; }
    .hero-summary { max-width: 100%; font-size: 1rem; }
    .hero-visual {
        justify-content: flex-start;
        gap: 0.85rem;
        overflow-x: auto;
        padding-bottom: 0.35rem;
        background-position: center;
        width: 100%;
        margin-left: 0;
    }
    .hero-visual.hero-visual-count-1,
    .hero-visual.hero-visual-count-2,
    .hero-visual.hero-visual-count-3 {
        display: flex;
    }
    .hero-visual-column {
        width: 10.5rem;
        gap: 0.85rem;
    }
    .hero-visual-column-1,
    .hero-visual-column-2,
    .hero-visual-column-3 { padding-top: 0; }
    .content-grid.content-grid-rechner > aside {
        order: -1;
    }
    .content-section-no-hero { padding-top: 1.25rem; }
}

@media (min-width: 901px) {
    .mobile-nav-drawer { display: none; }
    .nav-close { display: none; }
}

@media (max-width: 640px) {
    h1 { font-size: 1.45rem; }
    .hero .hero-title { font-size: 2.1rem !important; max-width: 100%; }
    .hero .hero-title.hero-title-long { font-size: 1.7rem !important; max-width: 100%; }
    .hero-card, .article-card, .sidebar-card, .tool-card, .form-card, .card, .admin-main { padding: 1rem; }
    .hero-actions .button, .sticky-cta .button { width: 100%; justify-content: center; }
    .hero-summary { max-width: 100%; font-size: 0.96rem; }
    .trust-strip { gap: 0.45rem; font-size: 0.82rem; }
    .hero-visual {
        display: block !important;
        overflow: visible;
        padding: 0;
        background: none;
        box-shadow: none;
    }
    .hero-visual::after { display: none; }
    .hero-visual-column {
        display: none;
        width: 100%;
    }
    .hero-visual-column:first-child {
        display: flex;
    }
    .hero-visual-column:first-child .hero-tile:first-child {
        width: 100%;
    }
    .hero-visual-column:first-child .hero-tile:not(:first-child) {
        display: none;
    }
    .hero-tile {
        min-height: auto;
        width: 100%;
        padding: 1rem;
        border-radius: 1rem;
        background: rgba(255, 253, 249, 0.96);
    }
    .brand {
        max-width: calc(100% - 3rem);
    }
    .brand-mark {
        width: 2.65rem;
        height: 2.65rem;
        border-radius: 12px;
    }
    .brand strong {
        font-size: 0.9rem;
    }
    .image-card-grid {
        grid-template-columns: 1fr;
    }
}
