/* Property detail redesign – kompakt, mobil-first */
body { background: #f4f6f9; }

/* Kopfbereich */
.property-hero.pd-head {
    min-height: 0;
    margin-bottom: 0;
    padding: 1.1rem 0 1.4rem;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    display: block;
}
.pd-head .hero-content { color: #111827; padding: 0 1rem; }
.pd-crumbs {
    display: flex; flex-wrap: wrap; gap: .4rem; align-items: center;
    font-size: .8rem; color: #6b7280; margin-bottom: .6rem;
}
.pd-crumbs a { color: #6b7280; text-decoration: none; }
.pd-crumbs a:hover { color: var(--primary, #1a56a4); }
.pd-crumb-current { color: #111827; max-width: 40ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pd-badges { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .5rem; }
.pd-badge {
    font-size: .72rem; font-weight: 600; letter-spacing: .02em; text-transform: uppercase;
    padding: .25rem .6rem; border-radius: 999px; background: #eef2f7; color: #374151;
}
.pd-badge-offer { background: var(--primary, #1a56a4); color: #fff; }
.pd-badge-top { background: #fef3c7; color: #92400e; }
.pd-head .property-title h1 {
    color: #111827; text-shadow: none; margin: 0 0 .35rem;
    font-size: clamp(1.35rem, 2.6vw, 1.9rem); line-height: 1.25;
}
.pd-head .property-location { color: #4b5563; font-size: .95rem; display: flex; align-items: center; gap: .3rem; }
.pd-head .property-location svg { flex: none; margin-right: 4px !important; }
.pd-head .loading-message, .pd-head .error-message { color: #374151; padding: 1rem 0; }

/* Layout */
.pd-grid {
    max-width: 1200px; margin: 1.25rem auto 2rem; padding: 0 1rem;
    display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 1.5rem; align-items: start;
}
.pd-grid .property-content-left { display: flex; flex-direction: column; gap: 1rem; min-width: 0; }
.pd-grid .property-sidebar { position: sticky; top: 96px; display: flex; flex-direction: column; gap: 1rem; }

/* Galerie */
.pd-grid .property-gallery { margin: 0; }
.pd-grid .gallery-main { height: clamp(260px, 46vw, 520px); border-radius: 14px; overflow: hidden; background: #e5e7eb; }
.pd-grid .gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.pd-grid .gallery-thumbnails {
    display: flex; gap: .5rem; overflow-x: auto; padding: .5rem 0 .25rem; scroll-snap-type: x proximity;
}
.pd-grid .gallery-thumbnails .thumbnail {
    flex: 0 0 88px; height: 64px; border-radius: 8px; object-fit: cover; scroll-snap-align: start; cursor: pointer;
}

/* Eckdaten als Chips */
.pd-grid .key-facts {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .6rem;
    background: transparent; padding: 0; box-shadow: none; margin: 0;
}
.pd-grid .fact-item {
    display: flex; align-items: center; gap: .65rem; background: #fff; border: 1px solid #e5e7eb;
    border-radius: 12px; padding: .7rem .85rem;
}
.pd-grid .fact-item svg { flex: none; width: 22px; height: 22px; color: var(--primary, #1a56a4); }
.pd-grid .fact-item strong { display: block; font-size: .95rem; color: #111827; line-height: 1.2; }
.pd-grid .fact-item span { font-size: .75rem; color: #6b7280; }

/* Karten */
.pd-grid .content-card, .pd-grid .property-features-section {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; padding: 1.25rem 1.4rem; box-shadow: none; margin: 0;
}
.pd-grid .content-card h2, .pd-grid .property-features-section h2 {
    font-size: 1.15rem; margin: 0 0 .8rem; color: #111827;
}
.pd-grid .property-features-section .container { padding: 0; max-width: none; }
.pd-grid .description-text p { color: #374151; line-height: 1.7; margin: 0 0 .8rem; max-width: 70ch; }
.pd-sub { font-size: 1rem; margin: 1.4rem 0 .7rem; color: #111827; }
.pd-data-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }
.pd-data-group { background: #f9fafb; border-radius: 12px; padding: .9rem 1rem; }
.pd-data-group h4 { margin: 0 0 .4rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--primary, #1a56a4); }
.pd-data-group dl { margin: 0; }
.pd-data-group dl > div { display: flex; justify-content: space-between; gap: 1rem; padding: .45rem 0; border-bottom: 1px solid #eceff3; font-size: .9rem; }
.pd-data-group dl > div:last-child { border-bottom: 0; }
.pd-data-group dt { color: #6b7280; }
.pd-data-group dd { margin: 0; color: #111827; font-weight: 600; text-align: right; }
.pd-grid .features-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .5rem .9rem; }
.pd-grid .feature-item { display: flex; align-items: center; gap: .5rem; font-size: .92rem; color: #374151; }
.pd-grid .feature-item svg { color: #16a34a; flex: none; }
#property-map { height: 320px; border-radius: 10px; overflow: hidden; z-index: 0; }
.map-disclaimer { font-size: .8rem; color: #9ca3af; margin: .5rem 0 0; }

/* Sidebar */
.pd-grid .sidebar-card {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 14px; padding: 1.25rem; box-shadow: 0 6px 20px rgba(17, 24, 39, .05);
}
.pd-grid .price-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; color: #6b7280; }
.pd-grid .property-price { font-size: 1.9rem; font-weight: 800; color: #111827; line-height: 1.15; margin: .15rem 0 .8rem; }
.pd-toolbar { display: flex; gap: .4rem; }
.pd-toolbar button {
    flex: 1; padding: .5rem .3rem; border: 1px solid #e5e7eb; background: #fff; border-radius: 10px;
    font-size: .8rem; color: #374151; cursor: pointer; transition: background .15s, border-color .15s;
}
.pd-toolbar button:hover { background: #f3f4f6; }
.pd-toolbar .fav-active { color: #dc2626; border-color: #fecaca; background: #fef2f2; }
.pd-grid .contact-agent { display: flex; align-items: center; gap: .75rem; margin-bottom: .9rem; }
.pd-grid .agent-avatar { width: 48px; height: 48px; border-radius: 50%; background: #f3f4f6; padding: 4px; object-fit: contain; }
.pd-grid .agent-info h4 { font-size: 1rem; }
.pd-grid .agent-info p { font-size: .8rem; color: #16a34a; }
.pd-quick { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-bottom: .9rem; }
.pd-quick a {
    display: flex; align-items: center; justify-content: center; gap: .4rem; padding: .65rem;
    border-radius: 10px; font-weight: 600; font-size: .9rem; text-decoration: none; color: #fff;
}
.pd-quick-call { background: #111827; }
.pd-quick-wa { background: #25d366; }
.pd-form { display: grid; gap: .55rem; }
.pd-form input, .pd-form textarea {
    width: 100%; box-sizing: border-box; padding: .7rem .8rem; border: 1px solid #d1d5db; border-radius: 10px;
    font: inherit; font-size: 16px; background: #fff;
}
.pd-form input:focus, .pd-form textarea:focus { outline: 2px solid var(--primary, #1a56a4); outline-offset: 0; border-color: transparent; }
.pd-form .btn-primary {
    display: flex; align-items: center; justify-content: center; gap: .5rem; width: 100%; padding: .85rem;
    border: 0; border-radius: 10px; background: var(--primary, #1a56a4); color: #fff; font-weight: 700; font-size: 1rem; cursor: pointer;
}
.pd-form .btn-primary:disabled { opacity: .7; cursor: wait; }
.pd-privacy { font-size: .72rem; color: #9ca3af; margin: 0; line-height: 1.4; }
.pd-privacy a { color: inherit; text-decoration: underline; }

/* Mobile Sticky-Leiste */
.pd-sticky-cta { display: none; }

@media (max-width: 960px) {
    .pd-grid { grid-template-columns: 1fr; }
    .pd-grid .property-sidebar { position: static; order: -1; }
    .pd-grid .property-sidebar .contact-card { order: 2; }
    .pd-grid .gallery-main { height: clamp(240px, 62vw, 420px); }
    .pd-sticky-cta {
        display: grid; grid-template-columns: 1fr 1fr 1.3fr; gap: .5rem; position: fixed; left: 0; right: 0; bottom: 0; z-index: 900;
        padding: .6rem .75rem calc(.6rem + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid #e5e7eb;
        box-shadow: 0 -6px 20px rgba(0, 0, 0, .08);
    }
    .pd-sticky-cta a {
        display: flex; align-items: center; justify-content: center; gap: .35rem; padding: .7rem .4rem;
        border-radius: 10px; background: #f3f4f6; color: #111827; font-weight: 600; font-size: .88rem; text-decoration: none;
    }
    .pd-sticky-cta .pd-cta-main { background: var(--primary, #1a56a4); color: #fff; }
    body { padding-bottom: 70px; }
    #contact-form { scroll-margin-top: 90px; }
}
@media (max-width: 520px) {
    .pd-grid { padding: 0 .6rem; }
    .pd-grid .content-card, .pd-grid .property-features-section { padding: 1rem; }
    .pd-grid .key-facts { grid-template-columns: 1fr 1fr; }
}

/* Druck: Exposé */
@media print {
    header, nav, footer, .pd-sticky-cta, .pd-toolbar, .pd-form, .pd-quick, .gallery-nav, .gallery-thumbnails, .gallery-fullscreen-btn, #property-map-section { display: none !important; }
    body { background: #fff; padding: 0; }
    .pd-grid { display: block; margin: 0; }
    .pd-grid .property-sidebar { position: static; }
    .pd-grid .sidebar-card, .pd-grid .content-card { box-shadow: none; break-inside: avoid; }
}
