:root {
    --engel-red: #8d1d1d;
    --engel-red-dark: #681010;
    --engel-dark: #161616;
    --engel-cream: #f6efe6;
    --engel-sand: #e9ddcf;
    --engel-gold: #d7a75a;
}

body {
    background: #ffffff;
    color: #1f2937;
}

.py-lg-6 {
    padding-top: 5.5rem;
    padding-bottom: 5.5rem;
}

.bg-cream {
    background: var(--engel-cream);
}

.site-nav {
    background: rgba(22, 22, 22, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.hero-section {
    position: relative;
    background: linear-gradient(135deg, rgba(14,14,14,.92), rgba(79,16,16,.82)),
                url('../images/cover-hero.png') center/cover no-repeat;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(215,167,90,0.18), transparent 35%);
}

.badge-soft {
    background: rgba(255,255,255,0.14);
    border: 1px solid rgba(255,255,255,0.18);
    color: #fff;
    padding: .55rem .85rem;
    border-radius: 999px;
}

.hero-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
}

.hero-highlights span {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.14);
    padding: .55rem .8rem;
    border-radius: 999px;
}

.hero-card {
    background: rgba(255,255,255,0.95);
    border-radius: 1.5rem;
    overflow: hidden;
}

.hero-card img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    display: block;
}

.hero-card-body {
    padding: 1.25rem 1.25rem 1.4rem;
    color: var(--engel-dark);
}

.section-kicker {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: .78rem;
    font-weight: 700;
    color: var(--engel-red);
    margin-bottom: .5rem;
}

.section-title {
    color: var(--engel-dark);
}

.sticky-offset {
    top: 5.8rem;
}

.object-cover {
    object-fit: cover;
}

.weekly-image {
    min-height: 320px;
    width: 100%;
}

.weekly-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .85rem;
}

.weekly-grid div,
.info-grid div {
    background: #fff;
    border-radius: 1rem;
    padding: .95rem 1rem;
    border: 1px solid rgba(0,0,0,0.05);
}

.weekly-grid .wide {
    grid-column: 1 / -1;
}

.weekly-grid span,
.info-grid span {
    display: block;
    font-size: .82rem;
    color: #6b7280;
}

.weekly-grid strong,
.info-grid strong {
    display: block;
    margin-top: .2rem;
}

.advisor-card,
.info-tile,
.empty-state,
.product-card {
    border: 1px solid rgba(0,0,0,0.05);
}

.product-card img {
    min-height: 100%;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .75rem;
}

.footer-dark {
    background: var(--engel-dark);
}

.footer-links a {
    color: #fff;
    text-decoration: none;
}

.footer-links a:hover {
    text-decoration: underline;
}

.form-select:focus,
.form-control:focus {
    border-color: rgba(141,29,29,.5);
    box-shadow: 0 0 0 .25rem rgba(141,29,29,.14);
}

.btn-danger {
    background-color: var(--engel-red);
    border-color: var(--engel-red);
}

.btn-danger:hover,
.btn-danger:focus {
    background-color: var(--engel-red-dark);
    border-color: var(--engel-red-dark);
}

.btn-outline-danger {
    color: var(--engel-red);
    border-color: var(--engel-red);
}

.btn-outline-danger:hover {
    background-color: var(--engel-red);
    border-color: var(--engel-red);
}

.legal-page {
    background: linear-gradient(180deg, #fff, #faf7f3);
    min-height: 100vh;
}

.legal-box {
    background: #fff;
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 1.5rem;
}

@media (max-width: 991px) {
    .sticky-offset {
        top: 1rem;
    }
}

@media (max-width: 767px) {
    .info-grid,
    .weekly-grid {
        grid-template-columns: 1fr;
    }

    .weekly-grid .wide {
        grid-column: auto;
    }
}


.brand-logo-link {
    display: inline-flex;
    align-items: center;
    padding-top: .15rem;
    padding-bottom: .15rem;
}

.brand-logo {
    height: 46px;
    width: auto;
    display: block;
}

.footer-brand {
    display: flex;
    flex-direction: column;
}

.footer-logo {
    height: 42px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

@media (max-width: 991px) {
    .brand-logo {
        height: 40px;
    }
}

@media (max-width: 575px) {
    .brand-logo {
        height: 34px;
    }
    .footer-logo {
        height: 36px;
    }
}


.selection-summary {
    background: linear-gradient(180deg, #fff, #fcfaf7);
    border: 1px solid rgba(0,0,0,0.06);
}

.criteria-chips {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
}

.criteria-chip {
    display: inline-flex;
    gap: .35rem;
    align-items: center;
    background: var(--engel-cream);
    border: 1px solid rgba(141,29,29,.12);
    color: var(--engel-dark);
    padding: .55rem .8rem;
    border-radius: 999px;
    font-size: .92rem;
}

.mini-summary {
    background: #faf7f3;
    border: 1px solid rgba(0,0,0,0.05);
    border-radius: 1rem;
    padding: .85rem 1rem;
    font-size: .95rem;
}

.compact-summary .criteria-chip {
    font-size: .88rem;
}

.site-nav {
    z-index: 1080;
    overflow: visible;
}

.site-nav .navbar-collapse {
    z-index: 1081;
}

.results-toolbar {
    margin-top: .25rem;
}

.quick-contact-box {
    border: 1px solid rgba(0,0,0,0.05);
    background: linear-gradient(180deg, #fff, #fcfaf7);
}

.form-intro {
    padding-top: .25rem;
    border-top: 1px solid rgba(0,0,0,0.08);
}

@media (max-width: 991px) {
    .site-nav .navbar-collapse {
        margin-top: .75rem;
        background: rgba(22, 22, 22, 0.98);
        border: 1px solid rgba(255,255,255,0.08);
        border-radius: 1rem;
        padding: .9rem;
        box-shadow: 0 14px 32px rgba(0,0,0,0.28);
    }

    .site-nav .navbar-nav {
        align-items: stretch !important;
    }

    .site-nav .nav-link,
    .site-nav .btn {
        width: 100%;
    }

    .site-nav .btn {
        margin-left: 0 !important;
    }

    .sticky-offset {
        top: 0;
    }
}


.product-select-bar{padding:.85rem 1rem;background:#fff7f7;border-bottom:1px solid rgba(0,0,0,.06)}
.product-select-bar .form-check-input{width:1.2rem;height:1.2rem;margin-top:.15rem}
.selection-action-bar{position:sticky;bottom:1rem;z-index:20}
.quick-contact-box{background:#faf7f2}


.results-scroll {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

@media (min-width: 992px) {
    .results-scroll {
        max-height: calc(100vh - 15rem);
        overflow-y: auto;
        padding-right: .35rem;
    }

    .results-scroll::-webkit-scrollbar {
        width: 10px;
    }

    .results-scroll::-webkit-scrollbar-thumb {
        background: rgba(0,0,0,.18);
        border-radius: 999px;
    }
}


@media (min-width: 992px) {
    .results-column {
        display: flex;
        flex-direction: column;
    }

    .results-column .results-scroll {
        max-height: calc(100vh - 16rem);
        overflow-y: auto;
    }
}


.results-column,
.results-column form,
.results-column .selection-action-bar,
.results-column .selection-action-bar .card-body,
.results-column .product-card {
    width: 100%;
    min-width: 0;
}

.results-column form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.results-scroll {
    padding-bottom: .75rem;
}

.results-scroll .product-card,
.product-card .card-body {
    overflow: visible;
}

.product-card p,
.product-card h3,
.product-card .info-grid,
.product-card .badge,
.product-card strong {
    overflow-wrap: anywhere;
}

.selection-action-bar {
    width: 100%;
    left: 0;
    right: 0;
}

@media (min-width: 992px) {
    .results-column,
    .results-column form {
        min-height: 0;
    }

    .results-scroll {
        flex: 1 1 auto;
        max-height: calc(100vh - 17rem);
        overflow-y: auto;
        padding-right: .5rem;
        padding-bottom: 8rem;
    }

    .selection-action-bar {
        position: sticky;
        bottom: 0;
        margin-top: .25rem;
    }

    .selection-action-bar .card-body {
        width: 100%;
    }
}


@media (min-width: 992px) {
    .advisor-layout {
        display: grid;
        grid-template-columns: minmax(340px, 40%) minmax(0, 60%);
        align-items: start;
    }

    .advisor-layout > [class*="col-"] {
        width: auto;
        max-width: none;
        flex: 0 0 auto;
    }

    .results-column {
        min-width: 0;
    }

    .results-scroll {
        max-height: calc(100vh - 18rem);
        overflow-y: auto;
        padding-right: .35rem;
    }

    .product-card {
        width: 100%;
    }
}

.product-card .card-body p:last-child {
    margin-bottom: 0;
}

.product-card .row {
    align-items: stretch;
}

.product-card img {
    width: 100%;
    height: 100%;
    min-height: 240px;
    object-fit: cover;
    display: block;
}

.product-select-bar {
    padding: .9rem 1rem;
    background: #f8f3f1;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.selection-action-bar {
    width: 100%;
    margin-top: .25rem;
}

#multiWhatsAppButton:disabled,
#multiRequestButton:disabled {
    opacity: .65;
    cursor: not-allowed;
}

@media (max-width: 991px) {
    .results-scroll {
        max-height: none;
        overflow: visible;
    }
}

/* v9 layout fixes */
@media (min-width: 992px) {
    .advisor-layout {
        display: grid;
        grid-template-columns: minmax(360px, 40%) minmax(0, 1fr);
        gap: 1.5rem;
        align-items: start;
    }

    .advisor-layout > [class*="col-"] {
        width: auto;
        max-width: none;
        flex: 0 0 auto;
    }

    .results-column {
        display: flex;
        flex-direction: column;
        min-width: 0;
    }

    .results-column form {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        min-width: 0;
    }

    .results-scroll {
        max-height: 980px;
        overflow-y: auto;
        padding-right: .45rem;
        padding-bottom: .25rem;
    }
}

.results-column,
.results-column form,
.results-column .product-card,
.results-column .selection-action-bar,
.results-column .selection-action-bar .card-body {
    width: 100%;
    min-width: 0;
}

.results-scroll {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.results-scroll .product-card {
    flex: 0 0 auto;
}

.product-card {
    overflow: hidden;
}

.product-card .row {
    align-items: stretch;
}

.product-card img {
    width: 100%;
    height: 100%;
    min-height: 220px;
    object-fit: cover;
    display: block;
}

.product-card .card-body,
.product-card p,
.product-card h3,
.product-card .info-grid,
.product-card .badge,
.product-card strong {
    overflow: visible;
    word-break: normal;
}

.selection-action-bar {
    position: static !important;
    width: 100%;
    margin-top: .25rem;
}

.selection-action-bar .card-body {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.info-row > [class*="col-"] {
    display: flex;
}

.info-row .card {
    width: 100%;
}

@media (max-width: 991px) {
    .results-scroll {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

/* v10 expert refinements: robust advisor layout, scrollable recommendations, reliable selection state */
@media (min-width: 992px) {
    #berater .advisor-layout {
        display: grid !important;
        grid-template-columns: minmax(360px, 39%) minmax(0, 61%);
        gap: 1.75rem;
        align-items: start;
    }

    #berater .advisor-layout > .col-lg-5,
    #berater .advisor-layout > .col-lg-7 {
        width: auto !important;
        max-width: none !important;
        flex: none !important;
        min-width: 0;
    }

    #berater .results-column {
        min-width: 0;
        display: flex;
        flex-direction: column;
    }

    #berater .recommendations-form {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    #berater .results-scroll {
        max-height: min(940px, calc(100vh - 13rem));
        overflow-y: auto;
        overflow-x: hidden;
        padding-right: .55rem;
        padding-bottom: .75rem;
        scroll-behavior: smooth;
    }
}

#berater .results-scroll {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

#berater .product-card {
    width: 100%;
    min-width: 0;
    overflow: hidden;
    transition: box-shadow .18s ease, transform .18s ease, border-color .18s ease;
}

#berater .product-card.is-selected {
    box-shadow: 0 0 0 3px rgba(141,29,29,.16), 0 .5rem 1.25rem rgba(0,0,0,.08) !important;
}

#berater .product-card .row {
    min-width: 0;
}

#berater .product-card .card-body {
    overflow: visible;
}

#berater .product-card p {
    margin-bottom: .75rem;
}

#berater .product-card img {
    width: 100%;
    min-height: 235px;
    height: 100%;
    object-fit: cover;
}

#berater .selection-action-bar {
    width: 100%;
    min-width: 0;
    position: static !important;
}

#berater .selection-action-bar .card-body {
    width: 100%;
}

#berater .product-select-bar {
    background: #fff6f6;
}

#berater .product-select-bar .form-check-label {
    cursor: pointer;
}

#berater .product-checkbox {
    cursor: pointer;
}

#berater .btn:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.info-row {
    align-items: stretch;
}

.info-row > [class*="col-"] {
    display: flex;
}

.info-row .info-tile {
    width: 100%;
}

@media (min-width: 992px) {
    .info-row .info-tile .card-body {
        min-height: 190px;
        display: flex;
        flex-direction: column;
    }
}

@media (max-width: 991px) {
    #berater .results-scroll {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }

    #berater .product-card img {
        min-height: 200px;
        max-height: 280px;
    }
}

/* v17: reine Direktkontakt-Ansicht ohne Server-Mailformular */
.direct-contact-grid .direct-contact-card {
    background: linear-gradient(180deg, #ffffff, #fcfaf7);
    transition: transform .18s ease, box-shadow .18s ease;
}
.direct-contact-grid .direct-contact-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 1.25rem 2.5rem rgba(0,0,0,.12) !important;
}
.direct-contact-icon {
    width: 3rem;
    height: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(139, 23, 23, .09);
    font-size: 1.45rem;
    margin-bottom: 1rem;
}
.contact-whatsapp .direct-contact-icon {
    background: rgba(25, 135, 84, .10);
}
.prepared-message {
    white-space: pre-wrap;
    word-break: break-word;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: .92rem;
    line-height: 1.5;
    background: #fff;
    border: 1px solid rgba(0,0,0,.08);
    border-radius: 1rem;
    padding: 1rem;
    max-height: 20rem;
    overflow: auto;
}
