/* Gateway Estates — armor layer
 *
 * Themes routinely style every <button>, <select> and <input> on the page with
 * !important. When that happens the search bar renders as generic theme buttons.
 * This file re-asserts the plugin's own design.
 *
 * Two things make it win:
 *   1. High specificity — every rule is scoped through .ge-searchbar / .ge-detail
 *      etc., so even against a theme's `button { ... !important }` these rules
 *      have more specificity and take precedence.
 *   2. !important on the properties themes actually touch.
 *
 * Loaded after frontend.css. If you need to restyle the plugin yourself, edit
 * frontend.css and raise specificity here rather than fighting this file.
 */

/* ------------------------------------------------------------------ *
 * 1. Neutralise inherited control styling
 * ------------------------------------------------------------------ */

.ge-searchbar .ge-searchbar__form button,
.ge-searchbar .ge-searchbar__form select,
.ge-searchbar .ge-searchbar__form input,
.ge-results .ge-results__bar select,
.ge-detail .ge-agent-card button,
.ge-detail .ge-agent-card input,
.ge-detail .ge-agent-card textarea,
.ge-results .ge-pagination button,
.ge-results .ge-empty button {
	-webkit-appearance: none !important;
	-moz-appearance: none !important;
	appearance: none !important;
	box-shadow: none !important;
	text-shadow: none !important;
	text-transform: none !important;
	min-height: 0 !important;
	max-width: none !important;
	margin: 0 !important;
	transform: none !important;
	text-decoration: none !important;
	background-image: none !important;
	font-family: var(--ge-sans) !important;
	width: auto;
}

/* Themes love decorative pseudo elements on buttons. */
.ge-searchbar .ge-searchbar__form button::before,
.ge-searchbar .ge-searchbar__form button::after,
.ge-detail .ge-agent-card button::before,
.ge-detail .ge-agent-card button::after,
.ge-results .ge-pagination button::before,
.ge-results .ge-pagination button::after {
	content: none !important;
	display: none !important;
}

.ge-searchbar .ge-searchbar__form button:hover,
.ge-detail .ge-agent-card button:hover {
	transform: none !important;
}

/* ------------------------------------------------------------------ *
 * 2. Search bar
 * ------------------------------------------------------------------ */

.ge-searchbar .ge-searchbar__form {
	display: block !important;
	background: var(--ge-white) !important;
	border: 0 !important;
	border-radius: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
}

.ge-searchbar .ge-searchbar__form .ge-tabs {
	display: flex !important;
	gap: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	background: transparent !important;
	border: 0 !important;
	border-bottom: 1px solid var(--ge-line) !important;
	list-style: none !important;
}

.ge-searchbar .ge-searchbar__form .ge-tabs button.ge-tab {
	display: inline-block !important;
	background: transparent !important;
	background-color: transparent !important;
	color: var(--ge-muted) !important;
	border: 0 !important;
	border-bottom: 3px solid transparent !important;
	border-radius: 0 !important;
	outline: 0 !important;
	padding: 18px 29px !important;
	font-size: 13px !important;
	font-weight: 500 !important;
	line-height: 1.2 !important;
	letter-spacing: .12em !important;
	text-transform: uppercase !important;
	width: auto !important;
	height: auto !important;
	flex: 0 0 auto !important;
}

.ge-searchbar .ge-searchbar__form .ge-tabs button.ge-tab:hover {
	background: transparent !important;
	color: var(--ge-green) !important;
}

.ge-searchbar .ge-searchbar__form .ge-tabs button.ge-tab.is-active,
.ge-searchbar .ge-searchbar__form .ge-tabs button.ge-tab[aria-selected="true"] {
	background: transparent !important;
	background-color: transparent !important;
	color: var(--ge-green) !important;
	font-weight: 600 !important;
	border: 0 !important;
	border-bottom: 3px solid var(--ge-gold) !important;
	outline: 0 !important;
}

.ge-searchbar .ge-searchbar__form .ge-tabs button.ge-tab:focus-visible {
	outline: 2px solid var(--ge-gold) !important;
	outline-offset: -4px !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr)) 170px !important;
	gap: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields .ge-field {
	padding: 22px 29px 19px !important;
	margin: 0 !important;
	background: transparent !important;
	border: 0 !important;
	border-left: 1px solid var(--ge-line) !important;
	border-radius: 0 !important;
	min-width: 0 !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields .ge-field:first-child {
	border-left: 0 !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields .ge-field label.ge-field__label {
	display: block !important;
	font-family: var(--ge-sans) !important;
	font-size: 12px !important;
	font-weight: 400 !important;
	line-height: 1.2 !important;
	letter-spacing: .07em !important;
	text-transform: uppercase !important;
	color: var(--ge-muted) !important;
	margin: 0 0 8px 0 !important;
	padding: 0 !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields .ge-select select,
.ge-searchbar .ge-searchbar__form .ge-fields input.ge-input {
	display: block !important;
	width: 100% !important;
	height: auto !important;
	background: transparent !important;
	background-color: transparent !important;
	background-image: none !important;
	border: 0 !important;
	border-radius: 0 !important;
	outline: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	font-family: var(--ge-serif) !important;
	font-size: 18px !important;
	font-weight: 400 !important;
	line-height: 1.3 !important;
	letter-spacing: 0 !important;
	color: var(--ge-green) !important;
	text-transform: none !important;
	cursor: pointer !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields input.ge-input {
	font-family: var(--ge-sans) !important;
	font-size: 16px !important;
	cursor: text !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields .ge-chevron {
	display: none !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields button.ge-submit {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 9px !important;
	width: 100% !important;
	height: auto !important;
	background: var(--ge-green) !important;
	background-color: var(--ge-green) !important;
	color: #fff !important;
	border: 0 !important;
	border-radius: 0 !important;
	outline: 0 !important;
	padding: 20px 10px !important;
	margin: 0 !important;
	font-family: var(--ge-sans) !important;
	font-size: 12px !important;
	font-weight: 600 !important;
	line-height: 1.2 !important;
	letter-spacing: .16em !important;
	text-transform: uppercase !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields button.ge-submit:hover {
	background: #0F2322 !important;
	background-color: #0F2322 !important;
	color: #fff !important;
}

.ge-searchbar .ge-searchbar__form .ge-fields button.ge-submit .ge-icon {
	display: block !important;
	stroke: currentColor !important;
	fill: none !important;
}

/* ------------------------------------------------------------------ *
 * 3. Results
 * ------------------------------------------------------------------ */

.ge-results .ge-grid-cards .ge-card {
	background: var(--ge-white) !important;
	border: 1px solid var(--ge-line) !important;
	border-radius: 0 !important;
	padding: 0 !important;
	box-shadow: none !important;
}

.ge-results .ge-grid-cards .ge-card .ge-card__title a,
.ge-results .ge-grid-cards .ge-card a.ge-card__media {
	text-decoration: none !important;
	box-shadow: none !important;
	border: 0 !important;
}

.ge-results .ge-grid-cards .ge-card .ge-card__title a {
	color: var(--ge-green) !important;
	font-family: var(--ge-serif) !important;
}

.ge-results .ge-grid-cards .ge-card .ge-badge {
	background: var(--ge-gold) !important;
	color: #fff !important;
	border-radius: 0 !important;
}

.ge-results .ge-pagination button.ge-page {
	background: transparent !important;
	color: var(--ge-green) !important;
	border: 1px solid var(--ge-line) !important;
	border-radius: 0 !important;
	padding: 10px 14px !important;
	font-size: 13px !important;
	text-transform: none !important;
}

.ge-results .ge-pagination button.ge-page.is-current,
.ge-results .ge-pagination button.ge-page:hover:not(:disabled) {
	background: var(--ge-green) !important;
	color: #fff !important;
	border-color: var(--ge-green) !important;
}

/* ------------------------------------------------------------------ *
 * 4. Detail page
 * ------------------------------------------------------------------ */

.ge-detail .ge-agent-card {
	background: var(--ge-white) !important;
	border: 1px solid var(--ge-line) !important;
	border-radius: 0 !important;
}

.ge-detail .ge-agent-card .ge-enquiry input,
.ge-detail .ge-agent-card .ge-enquiry textarea {
	display: block !important;
	width: 100% !important;
	background: #fdfcfa !important;
	border: 1px solid var(--ge-line) !important;
	border-radius: 0 !important;
	padding: 11px 12px !important;
	font-family: var(--ge-sans) !important;
	font-size: 13px !important;
	color: var(--ge-ink) !important;
}

.ge-detail .ge-agent-card .ge-enquiry button.ge-btn--gold {
	background: var(--ge-gold) !important;
	background-color: var(--ge-gold) !important;
	color: #fff !important;
	border: 0 !important;
	border-radius: 0 !important;
	width: 100% !important;
	padding: 14px 22px !important;
	font-family: var(--ge-sans) !important;
	font-size: 12px !important;
	font-weight: 600 !important;
	letter-spacing: .14em !important;
	text-transform: uppercase !important;
}

.ge-detail .ge-agent-card .ge-agent-card__actions button.ge-chip {
	background: transparent !important;
	color: var(--ge-green) !important;
	border: 1px solid var(--ge-line) !important;
	border-radius: 0 !important;
	padding: 10px !important;
	font-size: 12px !important;
	letter-spacing: .1em !important;
	text-transform: uppercase !important;
	flex: 1 !important;
}

.ge-detail .ge-agent-card .ge-agent-card__actions button.ge-chip.is-saved {
	background: var(--ge-green) !important;
	color: #fff !important;
	border-color: var(--ge-green) !important;
}

.ge-detail .ge-agent-card .ge-agent-card__links a {
	color: var(--ge-gold) !important;
	text-decoration: none !important;
}

.ge-detail .ge-headline .ge-headline__title,
.ge-detail .ge-section .ge-section__title {
	font-family: var(--ge-serif) !important;
	color: var(--ge-green) !important;
	text-transform: none !important;
}

.ge-detail .ge-stats .ge-stats__value,
.ge-detail .ge-headline .ge-headline__price {
	font-family: var(--ge-serif) !important;
}

/* Bullets and icons must survive a theme list reset. */
.ge-detail .ge-findings {
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

.ge-detail .ge-findings li::before {
	content: "" !important;
	display: block !important;
	position: absolute !important;
	background: var(--ge-gold) !important;
}

.ge-detail .ge-amenities {
	list-style: none !important;
	margin: 0 !important;
}

.ge-detail .ge-amenities .ge-icon {
	display: block !important;
	stroke: currentColor !important;
	fill: none !important;
}

/* ------------------------------------------------------------------ *
 * 5. Responsive — the armor grid must collapse too
 * ------------------------------------------------------------------ */

@media (max-width: 1024px) {
	.ge-searchbar .ge-searchbar__form .ge-fields {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-fields .ge-field {
		border-top: 1px solid var(--ge-line) !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-fields .ge-field:nth-child(odd) {
		border-left: 0 !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-fields .ge-field:nth-child(1),
	.ge-searchbar .ge-searchbar__form .ge-fields .ge-field:nth-child(2) {
		border-top: 0 !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-fields button.ge-submit {
		grid-column: 1 / -1 !important;
	}
}

@media (max-width: 767px) {
	.ge-searchbar .ge-searchbar__form .ge-fields {
		grid-template-columns: 1fr !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-fields .ge-field {
		border-left: 0 !important;
		padding: 16px 20px !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-fields .ge-field:first-child {
		border-top: 0 !important;
	}
	.ge-searchbar .ge-searchbar__form .ge-tabs button.ge-tab {
		padding: 16px 18px !important;
		font-size: 11.5px !important;
	}
}

/* ------------------------------------------------------------------ *
 * 6. Detail page hover guard
 *
 * Some themes fade images or paint link backgrounds on :hover, which
 * used to reveal a green tint behind the gallery and media blocks.
 * These rules pin every image on the detail views to full opacity and
 * keep gallery links/figures on a neutral surface, hover or not.
 * ------------------------------------------------------------------ */

.ge-detail .ge-gallery,
.ge-detail .ge-gallery__main,
.ge-detail .ge-gallery__thumb,
.ge-pp .ge-pp__hero,
.ge-pp .ge-pp__thumb {
	background: var(--ge-cream) !important;
}

.ge-detail .ge-gallery a,
.ge-detail .ge-gallery a:hover,
.ge-pp .ge-pp__thumbs button,
.ge-pp .ge-pp__thumbs button:hover {
	background: transparent !important;
	background-color: transparent !important;
	box-shadow: none !important;
	border: 0 !important;
}

.ge-detail img,
.ge-detail a:hover img,
.ge-detail .ge-gallery__img:hover,
.ge-pp img,
.ge-pp a:hover img,
.ge-pp button:hover img {
	opacity: 1 !important;
	filter: none !important;
	mix-blend-mode: normal !important;
}

.ge-detail .ge-gallery a::before,
.ge-detail .ge-gallery a::after,
.ge-detail .ge-gallery figure::before,
.ge-detail .ge-gallery figure::after,
.ge-pp .ge-pp__hero::before,
.ge-pp .ge-pp__thumb::before,
.ge-pp .ge-pp__thumb::after {
	content: none !important;
	display: none !important;
}

/* Keep detail-page hover accents on gold/neutral rather than green. */
.ge-detail .ge-agent-card .ge-agent-card__actions button.ge-chip:hover {
	background: transparent !important;
	border-color: var(--ge-gold) !important;
	color: var(--ge-gold) !important;
}

/* ------------------------------------------------------------------
 * Gallery armour
 *
 * Loads after frontend.css, so this is the last word on the gallery's
 * buttons. Themes commonly paint every <button> with a brand colour,
 * which showed through as blocks behind the hero and thumbnails.
 * ------------------------------------------------------------------ */

.ge-gal .ge-gal__zoom,
.ge-gal .ge-gal__zoom:hover,
.ge-gal .ge-gal__zoom:focus,
.ge-gal .ge-gal__zoom:active {
	background: transparent !important;
	background-color: transparent !important;
	background-image: none !important;
	border: 0 !important;
	box-shadow: none !important;
	color: inherit !important;
	padding: 0 !important;
	min-height: 0 !important;
	text-shadow: none !important;
}

.ge-gal .ge-gal__thumb,
.ge-gal .ge-gal__thumb:hover,
.ge-gal .ge-gal__thumb:focus,
.ge-gal .ge-gal__thumb:active {
	background-image: none !important;
	background-color: #eceae7 !important;
	color: inherit !important;
	padding: 0 !important;
	min-height: 0 !important;
	min-width: 0 !important;
	text-shadow: none !important;
	box-shadow: none !important;
	letter-spacing: normal !important;
	text-transform: none !important;
}

.ge-gal .ge-gal__nav,
.ge-gal .ge-gal__nav:hover,
.ge-gal .ge-gal__nav:focus {
	background-image: none !important;
	background-color: rgba(255, 255, 255, .94) !important;
	color: #1c1b1a !important;
	padding: 0 !important;
	min-height: 0 !important;
	min-width: 0 !important;
	text-shadow: none !important;
	letter-spacing: normal !important;
	text-transform: none !important;
}

.ge-gal .ge-gal__slide img,
.ge-gal .ge-gal__thumb img {
	max-width: none !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	margin: 0 !important;
}

.ge-gal .ge-gal__track {
	gap: 0 !important;
}
