/* Search results ("Jetzt buchen") — list + map. Section padding/background are set in Elementor. */
/* JS hides cards, promo, "weitere" and the empty note with [hidden]; their own
   display rules (grid/flex) must not bring them back. No !important, so Flip
   can still briefly show a leaving card while it fades out. */
.ra-search-page [hidden] { display: none; }

.ra-sr__intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; margin-bottom: 40px; }
.rw .ra-sr__title { margin: 0; font: 300 clamp(40px, 5.4vw, 88px)/1.05 'Saldo', Georgia, serif; }
.rw .ra-sr__lead { max-width: 400px; margin: 0 0 10px; font-size: 13px; line-height: 1.7; color: var(--ra-stone-text, #6B675F); }

.ra-sr__bar { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.ra-sr__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.rw .rw-chip.ra-chip--select { padding: 0; }
.rw .ra-chip--select select { appearance: none; border: 0; background: transparent; padding: 11px 32px 11px 18px; font: inherit; color: inherit; cursor: pointer;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%232A2926'/%3E%3C/svg%3E");
	background-repeat: no-repeat; background-position: right 14px center; background-size: 9px; }

.ra-sr__view { flex: none; display: flex; padding: 4px; border-radius: 999px; background: var(--ra-linen); }
.rw .ra-sr__view button { padding: 10px 22px; border: 0; border-radius: 999px; background: transparent; color: var(--ra-graphite);
	font: 500 10px/1 'Jost', Arial, sans-serif; letter-spacing: .25em; text-transform: uppercase; cursor: pointer; transition: background-color .3s, color .3s; }
.rw .ra-sr__view button.is-active { background: var(--ra-graphite); color: #fff; }

.ra-sr__sortbar { display: flex; align-items: center; gap: 40px; margin: 24px 0 28px; padding-top: 24px; border-top: 1px solid var(--ra-linen); font-size: 13px; }
.ra-sr__sortbar select { border: 0; background: none; font: inherit; color: inherit; cursor: pointer; }
.ra-sr__note { font-size: 12px; color: var(--ra-stone-text, #6B675F); }

/* Layout: list + sticky map */
.ra-sr__layout { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 18px; align-items: start; }
/* position: relative — cards moving with Flip are absolutely positioned against the list, not the page. */
/* Cards are built by search.js (which may start after the first paint): keep their
   space until then, so the "Weitere anzeigen" block below doesn't jump (layout shift). */
.rw.ra-search-page:not(.is-listed) .ra-sr__list { min-height: 110vh; }
.ra-sr__list { position: relative; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 18px; margin: 0; padding: 0; list-style: none; }
.ra-sr__mapwrap { position: sticky; top: 100px; height: calc(100vh - 124px); border-radius: 14px; overflow: hidden; background: var(--ra-linen); }
.ra-sr__map { position: absolute; inset: 0; }
.ra-sr__mapsearch { position: absolute; top: 16px; left: 16px; z-index: 2; display: flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: var(--ra-ivory); font-size: 12px; box-shadow: 0 4px 14px rgba(0,0,0,.08); }
/* Loading state while Google Maps draws the first tiles (search.js). */
.ra-sr__map.is-loading::after {
	content: 'Karte wird geladen …'; position: absolute; inset: 0; z-index: 3; display: grid; place-items: center;
	background: var(--ra-linen); color: var(--ra-stone-text, #6B675F); font: 400 13px/1 'Jost', Arial, sans-serif; letter-spacing: .05em;
}
.ra-sr__consent { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 10px; padding: 24px; text-align: center; background: var(--ra-linen); }
.rw .ra-sr__consent p { margin: 0; font: 300 28px/1.2 'Saldo', Georgia, serif; }
.ra-sr__consent small { max-width: 280px; color: var(--ra-stone-text, #6B675F); font-size: 12px; margin-bottom: 8px; }

/* Map view (Karte): map takes the whole width */
.ra-search-page.is-map-view .ra-sr__layout { grid-template-columns: 1fr; }
.ra-search-page.is-map-view .ra-sr__listwrap { display: none; }
.ra-search-page.is-map-view .ra-sr__mapwrap { position: relative; top: 0; height: 75vh; }

/* Result card */
.ra-res { position: relative; padding-bottom: 22px; border-bottom: 1px solid var(--ra-linen); }
.ra-res__media { position: relative; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: var(--ra-linen); outline: 2px solid transparent; outline-offset: 3px; transition: outline-color .3s; }
.ra-res.is-highlight .ra-res__media { outline-color: var(--ra-gold); }
.ra-res__gallery { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.ra-res__gallery::-webkit-scrollbar { display: none; }
.rw .ra-res__gallery img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; scroll-snap-align: start; }
/* Photo arrows (doubled classes beat Elementor's global button style: padding, colours, hover) */
.rw .ra-res__nav.ra-res__nav {
	position: absolute; top: 50%; z-index: 2; display: grid; place-items: center;
	width: 32px; height: 32px; min-width: 0; margin: -16px 0 0; padding: 0; border: 0; border-radius: 50%;
	background: rgba(255,255,255,.9); color: var(--ra-graphite); box-shadow: 0 2px 8px rgba(0,0,0,.12);
	font: 400 14px/1 'Jost', Arial, sans-serif; letter-spacing: 0; text-transform: none;
	cursor: pointer; opacity: 0; transition: opacity .25s, background-color .25s;
}
.rw .ra-res__nav.ra-res__nav:hover, .rw .ra-res__nav.ra-res__nav:focus-visible { background: #fff; color: var(--ra-graphite); }
.rw .ra-res__nav--prev.ra-res__nav--prev { left: 10px; right: auto; }
.rw .ra-res__nav--next.ra-res__nav--next { right: 10px; left: auto; }
.rw .ra-res__media:hover .ra-res__nav, .rw .ra-res__nav.ra-res__nav:focus-visible { opacity: 1; }
/* Touch screens have no hover: keep the arrows visible (swiping works too). */
@media (hover: none) { .rw .ra-res__nav.ra-res__nav { opacity: 1; } }
.ra-res__dots { position: absolute; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; gap: 5px; pointer-events: none; }
.ra-res__dots span { width: 5px; height: 5px; border-radius: 3px; background: rgba(255,255,255,.6); transition: width .3s, background-color .3s; }
.ra-res__dots span.is-on { width: 16px; background: #fff; }
.ra-res__placeholder { display: grid; place-content: center; justify-items: center; gap: 10px; width: 100%; height: 100%; color: var(--ra-gold-text, #72664E); font-size: 9px; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; }
.ra-res__placeholder::before { content: ''; width: 46px; height: 46px; border: 1px solid currentColor; border-radius: 50%; }

.rw .ra-res__link { color: inherit; text-decoration: none; }
.rw .ra-res__town { display: block; margin: 18px 0 6px; font-size: 9px; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; color: var(--ra-gold-text, #72664E); }
.rw .ra-res__title { display: block; margin: 0 0 8px; font: 300 24px/1.2 'Saldo', Georgia, serif; }
.rw .ra-res__meta { display: block; margin-bottom: 16px; font-size: 12px; color: var(--ra-stone-text, #6B675F); }
.rw .ra-res__price { font: 300 26px/1 'Saldo', Georgia, serif; }
.rw .ra-res__price small { font: 400 12px 'Jost', Arial, sans-serif; color: var(--ra-stone-text, #6B675F); }

/* Promo card */
.ra-res--promo { position: relative; display: flex; flex-direction: column; padding: 32px; border: 0; border-radius: 12px; overflow: hidden; background: var(--ra-graphite); color: var(--ra-ivory); }
/* Faint logo-mark pattern behind the text (design). */
.ra-res--promo::before {
	content: ''; position: absolute; inset: -20px; pointer-events: none; background: rgba(247, 243, 236, .045);
	-webkit-mask: url(../img/mark.svg) 0 0 / 84px 84px repeat; mask: url(../img/mark.svg) 0 0 / 84px 84px repeat;
}
.ra-res--promo > * { position: relative; }
.ra-res--promo .ra-res__town { margin-top: 0; color: var(--ra-gold); } /* dark card: brand gold reads well */
.rw .ra-res--promo h2 { margin: 6px 0 20px; color: var(--ra-ivory); font: 300 clamp(30px, 2.8vw, 42px)/1.15 'Saldo', Georgia, serif; }
.rw .ra-res--promo p { margin: 0 0 auto; font-size: 13px; line-height: 1.7; color: rgba(247,243,236,.75); }
.rw .ra-res--promo strong { display: block; margin: 28px 0; font: 300 clamp(56px, 6vw, 84px)/1 'Saldo', Georgia, serif; color: var(--ra-gold); }
.ra-res--promo .ra-res__btn { align-self: flex-start; }

.ra-sr__more { display: grid; justify-items: center; gap: 14px; margin-top: 40px; font-size: 12px; color: var(--ra-stone-text, #6B675F); }
.ra-sr__more p { margin: 0; }
.ra-sr__empty { padding: 60px 0; text-align: center; color: var(--ra-stone-text, #6B675F); }
.rw .ra-sr__empty button { border: 0; background: none; color: var(--ra-gold-text, #72664E); text-decoration: underline; cursor: pointer; font: inherit; }

/* Google map pins */
.ra-pin { padding: 7px 12px; border-radius: 999px; background: var(--ra-graphite); color: #fff; font: 500 12px/1 'Jost', Arial, sans-serif; white-space: nowrap; box-shadow: 0 4px 12px rgba(0,0,0,.2); transition: background-color .2s, transform .2s; }
.ra-pin.is-active { background: var(--ra-gold); transform: scale(1.12); }
.ra-pin-card { width: 220px; overflow: hidden; border-radius: 10px; background: var(--ra-ivory); color: var(--ra-graphite); box-shadow: 0 16px 40px rgba(0,0,0,.25); font-family: 'Jost', Arial, sans-serif; }
.rw .ra-pin-card img { display: block; width: 100%; height: 120px; object-fit: cover; }
.ra-pin-card div { padding: 12px 14px; }
.ra-pin-card small { display: block; font-size: 9px; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; color: var(--ra-gold-text, #72664E); }
.ra-pin-card strong { display: block; margin: 4px 0; font: 300 18px/1.2 'Saldo', Georgia, serif; }
.ra-pin-card span { font-size: 12px; }

@media (max-width: 1100px) {
	.ra-sr__layout { grid-template-columns: 1fr; }
	.ra-sr__mapwrap { display: none; }
	.ra-search-page.is-map-view .ra-sr__mapwrap { display: block; }
}
@media (max-width: 767px) {
	.ra-sr__intro { flex-direction: column; align-items: flex-start; gap: 16px; }
	.ra-sr__bar { flex-direction: column-reverse; align-items: stretch; }
	.ra-sr__chips { flex-wrap: nowrap; overflow-x: auto; margin: 0 calc(-1 * var(--ra-gutter)); padding: 0 var(--ra-gutter); scrollbar-width: none; }
	.ra-sr__view { align-self: flex-start; }
	.ra-sr__list { grid-template-columns: 1fr; }
	.ra-sr__sortbar { flex-direction: column; align-items: flex-start; gap: 6px; }
	.ra-search-page.is-map-view .ra-sr__mapwrap { height: 70vh; }
}

/* Phone-only search pill (hidden on larger screens) */
.rw .ra-sr__summary.ra-sr__summary { display: none; }

/* "Mit Balkon" badge on the card photo */
.ra-res__badge { position: absolute; top: 14px; left: 14px; z-index: 2; padding: 7px 12px; border-radius: 999px; background: rgba(173, 155, 119, .92); color: #fff; font: 500 9px/1 'Jost', Arial, sans-serif; letter-spacing: .22em; text-transform: uppercase; pointer-events: none; }

/* Search bar */
.rw .ra-sr__form { display: flex; align-items: center; gap: 4px; width: 100%; margin: 0 0 28px; padding: 8px 8px 8px 28px; border: 1px solid var(--ra-linen); border-radius: 999px; background: #fff; box-shadow: 0 10px 40px rgba(42, 41, 38, .06); }
.rw .ra-sr__form label { flex: 1; display: grid; gap: 2px; min-width: 0; margin: 0; padding: 6px 16px; border-left: 1px solid var(--ra-linen); cursor: pointer; }
.rw .ra-sr__form label:first-of-type { border-left: 0; padding-left: 0; }
.rw .ra-sr__form span { color: var(--ra-gold-text, #72664E); font: 500 9px/1.4 'Jost', Arial, sans-serif; letter-spacing: .25em; text-transform: uppercase; }
.rw .ra-sr__form select, .rw .ra-sr__form input {
	width: 100%; min-width: 0; height: auto; margin: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none; outline: none;
	background: none; color: var(--ra-graphite); font: 400 15px/1.4 'Jost', Arial, sans-serif; -webkit-appearance: none; appearance: none; cursor: pointer;
}
.rw .ra-sr__form label:focus-within { outline: 1px solid var(--ra-gold); outline-offset: 2px; border-radius: 8px; }

/* Gold pill buttons (doubled classes beat Elementor's global button style) */
.rw .ra-sr__submit.ra-sr__submit, .rw .ra-res__btn.ra-res__btn {
	flex: none; display: inline-flex; align-items: center; justify-content: center; margin: 0; padding: 18px 30px; border: 0; border-radius: 999px;
	background: var(--ra-gold); color: #fff; font: 500 12px/1 'Jost', Arial, sans-serif; letter-spacing: .2em; text-transform: uppercase; text-decoration: none; box-shadow: none; cursor: pointer;
	transition: background-color .3s ease;
}
.rw .ra-sr__submit.ra-sr__submit:hover, .rw .ra-res__btn.ra-res__btn:hover { background: var(--ra-graphite); color: #fff; }
.rw .ra-res--promo .ra-res__btn.ra-res__btn:hover { background: var(--ra-ivory); color: var(--ra-graphite); }

/* "Weitere anzeigen" */
.rw .ra-sr__morebtn.ra-sr__morebtn {
	display: inline-flex; align-items: center; margin: 0; padding: 18px 26px; border: 1px solid var(--ra-travertine); border-radius: 999px;
	background: transparent; color: var(--ra-graphite); font: 500 11px/1 'Jost', Arial, sans-serif; letter-spacing: .2em; text-transform: uppercase; box-shadow: none; cursor: pointer;
	transition: border-color .3s, background-color .3s, color .3s;
}
.rw .ra-sr__morebtn.ra-sr__morebtn:hover { background: var(--ra-graphite); border-color: var(--ra-graphite); color: #fff; }

.rw .ra-pin-card { display: block; text-decoration: none; }
.ra-sr__layout--nomap { grid-template-columns: 1fr; }
.ra-sr__layout--nomap .ra-sr__list { grid-template-columns: repeat(3, minmax(0, 1fr)); }

@media (max-width: 1024px) {
	/* Tablet: 2 × 2 fields, button full width below. */
	.rw .ra-sr__form { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-radius: 24px; padding: 8px 24px 20px; }
	.rw .ra-sr__form label { padding: 12px 0; border-left: 0; }
	.rw .ra-sr__form label:nth-of-type(even) { padding-left: 20px; border-left: 1px solid var(--ra-linen); }
	.rw .ra-sr__form label:nth-of-type(n+3) { border-top: 1px solid var(--ra-linen); }
	.rw .ra-sr__submit.ra-sr__submit { grid-column: 1 / -1; margin-top: 12px; }
	.ra-sr__layout--nomap .ra-sr__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
	.rw .ra-sr__form { display: flex; flex-direction: column; align-items: stretch; padding: 16px; }
	.rw .ra-sr__form label, .rw .ra-sr__form label:nth-of-type(even) { border-left: 0; border-top: 1px solid var(--ra-linen); padding: 10px 0; }
	.rw .ra-sr__form label:first-of-type { border-top: 0; }
	.rw .ra-sr__submit.ra-sr__submit { margin-top: 8px; }
	.ra-sr__layout--nomap .ra-sr__list { grid-template-columns: 1fr; }
}

/* Phones (design "Search results — Mobile"): search pill + filter chips first,
   then the title; full-width cards; a floating "Karte" / "Liste" button. */
@media (max-width: 767px) {
	.rw.ra-search-page { display: flex; flex-direction: column; }
	.rw .ra-sr__summary.ra-sr__summary { order: 1; }
	.rw .ra-sr__form { order: 2; }
	.ra-sr__bar { order: 3; }
	.ra-sr__intro { order: 4; }
	.ra-sr__sortbar { order: 5; }
	.ra-sr__layout { order: 6; }

	.rw .ra-sr__summary.ra-sr__summary {
		display: flex; align-items: center; gap: 14px; width: 100%; margin: 0 0 16px; padding: 8px 8px 8px 8px; border: 1px solid var(--ra-linen); border-radius: 999px;
		background: #fff; box-shadow: 0 10px 30px rgba(42, 41, 38, .08); color: var(--ra-graphite); text-align: left; text-transform: none; letter-spacing: 0; cursor: pointer;
	}
	.ra-sr__summary-icon, .ra-sr__summary-edit { position: relative; flex: none; width: 44px; height: 44px; border-radius: 50%; }
	.ra-sr__summary-icon { background: var(--ra-gold) center / 18px no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6'%3E%3Ccircle cx='11' cy='11' r='6'/%3E%3Cpath d='m20 20-4.5-4.5'/%3E%3C/svg%3E"); }
	.ra-sr__summary-edit { border: 1px solid var(--ra-travertine); background: center / 16px no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232A2926' stroke-width='1.6'%3E%3Cpath d='M4 7h16M7 12h10M10 17h4'/%3E%3C/svg%3E"); }
	.ra-sr__summary-text { flex: 1; display: grid; gap: 3px; min-width: 0; }
	.ra-sr__summary-text strong { font: 500 16px/1.2 'Jost', Arial, sans-serif; }
	.ra-sr__summary-text small { overflow: hidden; color: var(--ra-stone-text, #6B675F); font: 400 11px/1.3 'Jost', Arial, sans-serif; text-overflow: ellipsis; white-space: nowrap; }
	/* Full form only after tapping the pill */
	.rw.ra-search-page:not(.is-form-open) .ra-sr__form { display: none; }
	.rw.ra-search-page.is-form-open .ra-sr__summary-edit { background-color: var(--ra-linen); }

	.ra-sr__bar { margin-bottom: 28px; }
	.rw .ra-sr__lead { display: none; }
	.ra-sr__intro { margin-bottom: 16px; }
	.rw .ra-sr__title { font-size: 34px; }
	.ra-sr__sortbar { flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; }
	.ra-sr__note { overflow: hidden; max-width: 50%; text-overflow: ellipsis; white-space: nowrap; }

	/* Liste / Karte: one floating dark pill showing the other view */
	.ra-sr__view.ra-sr__view { position: fixed; z-index: 60; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); padding: 0; background: none; transform: translateX(-50%); }
	.rw .ra-sr__view button.is-active { display: none; }
	.rw .ra-sr__view button { display: inline-flex; align-items: center; gap: 10px; padding: 15px 24px; background: var(--ra-graphite); box-shadow: 0 10px 30px rgba(0, 0, 0, .25); color: #fff; }
	.rw .ra-sr__view button::before { content: ''; width: 16px; height: 16px; background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6'%3E%3Cpath d='M9 4 3 6v14l6-2 6 2 6-2V4l-6 2-6-2zM9 4v14M15 6v14'/%3E%3C/svg%3E"); }
	.rw .ra-sr__view button[data-view="list"]::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.6'%3E%3Cpath d='M8 6h12M8 12h12M8 18h12M4 6h.01M4 12h.01M4 18h.01'/%3E%3C/svg%3E"); }

	/* Promo: compact (design) */
	.ra-res--promo { padding: 24px; }
	.rw .ra-res--promo p { display: none; }
	.rw .ra-res--promo strong { margin: 16px 0 20px; font-size: 64px; }

	/* "Weitere anzeigen" full width, room for the floating button below */
	.ra-sr__more { padding-bottom: 72px; }
	.rw .ra-sr__morebtn.ra-sr__morebtn { justify-content: center; width: 100%; }
}

/* Sort label + select on one line (theme labels are block elements) */
.rw .ra-sr__sortbar label { display: inline-flex; align-items: center; gap: 6px; margin: 0; }
