/**
 * Parco Auto + form filtri condiviso
 */

body.ak-site.akhp-page,
body.ak-site .akhp--parco,
body.ak-site .akhp--trova-page {
	background: #000000 !important;
	color: #ffffff;
}

body.ak-site.akhp-page #tp_content {
	background: #000000;
	padding: 0;
	margin: 0;
}

.akhp--parco,
.akhp--trova-page {
	--akhp-bg: #000000;
	--akhp-text: #ffffff;
	--akhp-muted: rgba(255, 255, 255, 0.52);
	--akhp-accent: #ff0d19;
	--akhp-border: rgba(255, 255, 255, 0.18);
	--akhp-input-bg: rgba(255, 255, 255, 0.06);
	--akhp-max: 720px;
	--akhp-pad: 20px;
	background: var(--akhp-bg);
	color: var(--akhp-text);
	padding-bottom: 64px;
}

/* —— Parco header —— */
.akhp-parco-head {
	max-width: var(--akhp-max);
	margin: 0 auto;
	padding: 28px var(--akhp-pad) 0;
}

.akhp-parco-head h1 {
	margin: 0 0 6px;
	font-family: "Rajdhani", sans-serif;
	font-size: clamp(1.75rem, 5vw, 2.25rem);
	font-weight: 700;
	color: #ffffff;
}

.akhp-parco-head__sub {
	margin: 0 0 16px;
	font-family: "Rajdhani", sans-serif;
	font-size: 1rem;
	color: var(--akhp-muted);
}

/* —— Menu filtri a tendina —— */
.akhp-filters-dropdown {
	margin-bottom: 20px;
	border-bottom: 1px solid var(--akhp-border);
}

.akhp-filters-dropdown.is-open {
	overflow: visible;
}

.akhp-filters-dropdown__toggle {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	width: 100%;
	padding: 14px 16px;
	border: 1px solid var(--akhp-border);
	border-radius: 8px;
	background: var(--akhp-input-bg);
	color: #ffffff;
	font-family: "Rajdhani", sans-serif;
	font-size: 1rem;
	font-weight: 600;
	letter-spacing: 0.02em;
	cursor: pointer;
	transition: border-color 0.22s ease, background 0.22s ease;
}

.akhp-filters-dropdown__toggle:hover,
.akhp-filters-dropdown.is-open .akhp-filters-dropdown__toggle {
	border-color: rgba(255, 255, 255, 0.35);
}

.akhp-filters-dropdown.is-open .akhp-filters-dropdown__toggle {
	border-bottom-left-radius: 0;
	border-bottom-right-radius: 0;
	border-bottom-color: transparent;
}

.akhp-filters-dropdown__chevron {
	flex-shrink: 0;
	color: var(--akhp-muted);
	transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1), color 0.22s ease;
}

.akhp-filters-dropdown.is-open .akhp-filters-dropdown__chevron {
	transform: rotate(180deg);
	color: #ffffff;
}

.akhp-filters-dropdown__panel {
	overflow: hidden;
	max-height: 0;
	opacity: 0;
	padding: 0;
	border: 1px solid transparent;
	border-top: 0;
	border-radius: 0 0 8px 8px;
	background: var(--akhp-input-bg);
	visibility: hidden;
	pointer-events: none;
	transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.25s ease, padding 0.25s ease, border-color 0.22s ease, visibility 0s linear 0.35s;
}

.akhp-filters-dropdown.is-open .akhp-filters-dropdown__panel {
	max-height: 2000px;
	opacity: 1;
	padding: 16px 16px 20px;
	border-color: var(--akhp-border);
	visibility: visible;
	pointer-events: auto;
	overflow: visible;
	transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.25s ease, padding 0.25s ease, border-color 0.22s ease, visibility 0s;
}

.akhp-filters-dropdown.is-open .akhp-field--select {
	position: relative;
	z-index: 2;
}

.akhp-filters-dropdown.is-open .akhp-field--select:focus-within {
	z-index: 5;
}

.akhp-filters-dropdown .akhp-btn-cerca {
	margin-top: 14px;
}

/* Legacy wrapper (non più usato) */
.akhp-parco-filters {
	display: none;
}

/* —— Form filtri (Parco + Trova) —— */
.akhp-search-form__grid {
	display: grid;
	gap: 12px 14px;
}

.akhp-search-form__grid--selects {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.akhp-search-form__grid--ranges {
	grid-template-columns: minmax(0, 1fr);
	margin-top: 2px;
}

.akhp-range-pair {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px;
	min-width: 0;
}

.akhp-range-pair .akhp-field {
	margin: 0;
	min-width: 0;
}

.akhp-field {
	min-width: 0;
}

.akhp-search-form--parco .akhp-field--compact > label {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	padding: 0 !important;
	margin: -1px !important;
	overflow: hidden !important;
	clip: rect(0, 0, 0, 0) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

.akhp-search-form--parco .akhp-field--neo .akhp-field__label--spacer {
	display: none;
}

.akhp-search-form__grid--selects {
	align-items: end;
}

.akhp-field--dark label:not(.akhp-btn-neo),
.akhp-field--dark .akhp-field__label {
	display: block;
	margin-bottom: 8px;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.8rem;
	font-weight: 600;
	letter-spacing: 0.04em;
	color: #ffffff;
}

label.akhp-btn-neo {
	display: inline-flex !important;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;
	justify-content: center;
	margin-bottom: 0;
	font-size: 0.9rem;
	font-weight: 500;
	letter-spacing: 0.02em;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

.akhp-field--dark select,
.akhp-field--dark input[type="text"] {
	width: 100%;
	min-height: 44px;
	padding: 10px 36px 10px 12px;
	border: 1px solid var(--akhp-border);
	border-radius: 6px;
	background: var(--akhp-input-bg);
	color: #ffffff;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.95rem;
	font-weight: 500;
	appearance: none;
	transition: border-color 0.22s ease, box-shadow 0.22s ease;
}

.akhp-field--dark input::placeholder {
	color: var(--akhp-filter-hint, rgba(255, 255, 255, 0.36));
	opacity: 1;
}

.akhp-field--select.is-empty select {
	color: var(--akhp-filter-hint, rgba(255, 255, 255, 0.36));
}

.akhp-field--dark select {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23FFFFFF' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
}

.akhp-field--dark select option {
	background: var(--akhp-surface, #141414);
	color: #fff;
}

.akhp-field--dark select:focus,
.akhp-field--dark input:focus {
	outline: none;
	border-color: #ffffff;
	box-shadow: 0 0 0 1px rgba(255, 13, 25, 0.35);
}

.akhp-field--neo {
	position: relative;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	height: 100%;
	min-height: 0;
}

.akhp-neo-input {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.akhp-btn-neo {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid var(--akhp-border);
	border-radius: 6px;
	background: var(--akhp-input-bg);
	color: rgba(255, 255, 255, 0.88);
	font-family: "Rajdhani", sans-serif;
	font-size: 0.9rem;
	font-weight: 500;
	letter-spacing: 0.02em;
	line-height: 1;
	cursor: pointer;
	transition: background 0.22s ease, border-color 0.22s ease, color 0.22s ease;
	box-sizing: border-box;
}

.akhp-btn-neo__icon {
	display: block;
	flex-shrink: 0;
	width: 18px;
	height: 18px;
}

.akhp-btn-neo__text {
	line-height: 1;
	white-space: nowrap;
}

.akhp-btn-neo:hover {
	border-color: #ffffff;
	color: #ffffff;
}

.akhp-neo-input:checked + .akhp-btn-neo {
	background: var(--akhp-accent);
	border-color: #ffffff;
	color: #ffffff;
}

.akhp-neo-input:focus-visible + .akhp-btn-neo {
	outline: 2px solid var(--akhp-accent);
	outline-offset: 2px;
}

/* Bottone Cerca — rosso full width */
.akhp-btn-cerca {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	width: 100%;
	margin-top: 18px;
	padding: 14px 20px;
	border: 0;
	border-radius: 8px;
	background: var(--akhp-accent);
	color: #ffffff;
	font-family: "Rajdhani", sans-serif;
	font-size: 1.05rem;
	font-weight: 700;
	letter-spacing: 0.04em;
	cursor: pointer;
	transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.akhp-btn-cerca:hover {
	transform: translateY(-1px);
	box-shadow: 0 8px 24px rgba(255, 13, 25, 0.35);
}

.akhp-btn-cerca svg {
	flex-shrink: 0;
}

/* Toolbar risultati */
.akhp-parco-toolbar {
	max-width: var(--akhp-max);
	margin: 0 auto;
	padding: 16px var(--akhp-pad);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	border-bottom: 1px solid var(--akhp-border);
}

.akhp-parco-toolbar__count {
	margin: 0;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.95rem;
	color: #ffffff;
}

.akhp-parco-sort {
	display: flex;
	align-items: center;
	gap: 10px;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.9rem;
	color: #ffffff;
}

.akhp-parco-sort__label {
	color: #ffffff;
	white-space: nowrap;
}

.akhp-parco-sort__picker {
	position: relative;
	min-width: min(220px, 100%);
}

.akhp-parco-sort__toggle {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	width: 100%;
	min-height: 40px;
	padding: 8px 12px;
	border: 1px solid #ffffff;
	border-radius: 6px;
	background: #414141;
	color: #ffffff;
	font-family: inherit;
	font-size: inherit;
	font-weight: 700;
	line-height: 1.2;
	cursor: pointer;
	transition: background 0.2s ease, border-color 0.2s ease;
	box-sizing: border-box;
}

.akhp-parco-sort__value {
	text-align: left;
}

.akhp-parco-sort__chevron {
	flex-shrink: 0;
	color: var(--akhp-accent);
	transition: transform 0.22s ease;
}

.akhp-parco-sort__picker.is-open .akhp-parco-sort__chevron {
	transform: rotate(180deg);
}

.akhp-parco-sort__picker.is-open .akhp-parco-sort__toggle {
	border-bottom-left-radius: 0;
	border-bottom-right-radius: 0;
	border-bottom-color: transparent;
}

.akhp-parco-sort__menu {
	position: absolute;
	top: 100%;
	right: 0;
	left: 0;
	z-index: 30;
	margin: 0;
	padding: 4px 0;
	list-style: none;
	border: 1px solid #ffffff;
	border-top: 0;
	border-radius: 0 0 6px 6px;
	background: #414141;
	box-shadow: 0 10px 24px rgba(0, 0, 0, 0.45);
	overflow: hidden;
}

.akhp-parco-sort__option {
	display: block;
	width: 100%;
	padding: 10px 12px;
	border: 0;
	background: transparent;
	color: #ffffff;
	font-family: inherit;
	font-size: inherit;
	font-weight: 500;
	line-height: 1.25;
	text-align: left;
	cursor: pointer;
	transition: background 0.18s ease, color 0.18s ease;
}

.akhp-parco-sort__option:hover,
.akhp-parco-sort__option:focus-visible {
	background: var(--akhp-accent);
	color: #ffffff;
	outline: none;
}

.akhp-parco-sort__option.is-selected {
	font-weight: 700;
}

.akhp-parco-sort__native {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Lista card — layout verticale (come mobile), griglia su desktop */
.akhp-parco-list {
	max-width: var(--akhp-max);
	margin: 0 auto;
	padding: 16px var(--akhp-pad) 48px;
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 14px;
}

.akhp-listing-card {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 10px;
	padding: 10px;
	background: var(--akhp-surface, #141414);
	border: 1px solid var(--akhp-border);
	border-radius: 10px;
	min-width: 0;
}

.akhp-listing-card__media {
	position: relative;
	border-radius: 8px;
	overflow: hidden;
	background: var(--akhp-surface, #141414);
	aspect-ratio: 16 / 10;
	min-height: 0;
}

.akhp-listing-card__img-link {
	display: block;
	height: 100%;
}

.akhp-listing-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	min-height: 0;
}

.akhp-listing-card__badge {
	position: absolute;
	top: 8px;
	left: 8px;
	z-index: 2;
	padding: 4px 10px;
	background: var(--akhp-accent);
	border: 0;
	color: #fff;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.65rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	border-radius: 4px;
}

.akhp-listing-card__body {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.akhp-listing-card__title {
	margin: 0 0 8px;
	font-family: "Rajdhani", sans-serif;
	font-size: clamp(1rem, 3.5vw, 1.05rem);
	font-weight: 700;
	line-height: 1.25;
	min-width: 0;
	overflow-wrap: anywhere;
	word-break: break-word;
}

.akhp-listing-card__title a {
	color: #ffffff;
	text-decoration: none;
}

.akhp-listing-card__specs {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 8px 10px;
	margin: 0 0 auto;
}

.akhp-listing-card__specs-col {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
}

.akhp-listing-card__specs li.is-search-match {
	color: #ffffff;
	font-size: 0.98rem;
	font-weight: 800;
	letter-spacing: 0.01em;
}

.akhp-listing-card__specs li.is-search-match .akhp-field-icon,
.akhp-listing-card__specs li.is-search-match .akhp-field-icon.is-accent {
	color: #ffffff;
	opacity: 1;
	transform: scale(1.12);
	transform-origin: left center;
}

.akhp-listing-card__specs li.is-search-match svg {
	opacity: 1;
}

.akhp-listing-card__badge.is-search-match {
	box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.45);
}

.akhp-listing-card__specs .akhp-field-icon {
	flex-shrink: 0;
	opacity: 1;
}

.akhp-field-icon.is-accent {
	color: #ffffff;
}

.akhp-listing-card__specs li {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.86rem;
	font-weight: 500;
	color: var(--akhp-spec-muted, rgba(255, 255, 255, 0.52));
	overflow-wrap: anywhere;
	word-break: break-word;
}

.akhp-listing-card__specs li:not(.is-search-match) .akhp-field-icon {
	color: var(--akhp-spec-muted, rgba(255, 255, 255, 0.52));
}

.akhp-listing-card__specs svg {
	flex-shrink: 0;
	opacity: 1;
}

.akhp-listing-card__price.is-search-match {
	font-weight: 800;
}

.akhp-listing-card__footer {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 8px;
	margin-top: 10px;
}

.akhp-listing-card__price {
	margin: 0;
	font-family: "Rajdhani", sans-serif;
	font-size: clamp(1.15rem, 4vw, 1.35rem);
	font-weight: 700;
	color: #ffffff;
	line-height: 1;
}

.akhp-listing-card__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	padding: 8px 12px;
	border: 1px solid var(--akhp-accent);
	border-radius: 6px;
	background: transparent;
	color: #ffffff;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.8rem;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
	box-sizing: border-box;
	transition: background 0.22s ease, color 0.22s ease;
}

.akhp-listing-card__cta:hover {
	background: rgba(255, 13, 25, 0.12);
}

.akhp-listing-card__cta svg {
	color: #ffffff;
}

/* Empty */
.akhp-parco-empty {
	max-width: var(--akhp-max);
	margin: 24px auto 8px;
	padding: 8px var(--akhp-pad) 24px;
}

.akhp-parco-empty__message {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	margin: 0;
	font-family: "Rajdhani", sans-serif;
	font-size: clamp(1.1rem, 4.5vw, 1.5rem);
	font-weight: 600;
	line-height: 1.35;
	color: #ffffff;
}

.akhp-parco-empty__icon {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-top: 2px;
	color: #ffffff;
}

.akhp-parco-empty__icon .akhp-field-icon {
	display: block;
}

/* Paginazione */
.akhp-parco-pagination {
	max-width: var(--akhp-max);
	margin: 0 auto;
	padding: 8px var(--akhp-pad) 32px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px 24px;
	flex-wrap: wrap;
	background: transparent;
}

.akhp-parco-pagination__summary {
	margin: 0;
	font-family: "Rajdhani", sans-serif;
	font-size: 0.95rem;
	font-weight: 500;
	color: var(--akhp-muted);
	line-height: 1.4;
}

.akhp-parco-pagination__controls {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-left: auto;
}

.akhp-parco-pagination__list {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.akhp-parco-pagination__nav,
.akhp-parco-pagination__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 12px;
	border: 1px solid var(--akhp-border);
	border-radius: 8px;
	background: var(--akhp-surface, #141414);
	color: #ffffff;
	font-family: "Rajdhani", sans-serif;
	font-size: 1rem;
	font-weight: 600;
	text-decoration: none;
	transition: border-color 0.22s ease, background 0.22s ease, color 0.22s ease;
}

.akhp-parco-pagination__nav:hover,
.akhp-parco-pagination__link:hover {
	border-color: #ffffff;
	color: #ffffff;
}

.akhp-parco-pagination__nav.is-disabled {
	opacity: 0.35;
	pointer-events: none;
}

.akhp-parco-pagination__link.is-current {
	border-color: #ffffff;
	background: var(--akhp-accent);
	color: #ffffff;
}

.akhp-parco-pagination__link.is-gap {
	border-color: transparent;
	background: transparent;
	pointer-events: none;
}

/* Qualcosa di diverso */
.akhp-parco-diverso {
	max-width: var(--akhp-max);
	margin: 0 auto;
	padding: 8px var(--akhp-pad) 48px;
	border-top: 1px solid var(--akhp-border);
}

.akhp-parco-diverso__title {
	margin: 28px 0 18px;
	font-family: "Rajdhani", sans-serif;
	font-size: clamp(1.2rem, 4vw, 1.5rem);
	font-weight: 700;
	color: #ffffff;
	letter-spacing: 0.02em;
}

.akhp-parco-list--diverso {
	padding-top: 0;
	padding-bottom: 16px;
}

/* Legacy empty (fallback) */
.akhp-parco-empty h2 {
	font-family: "Rajdhani", sans-serif;
	font-size: 1.35rem;
	margin: 0 0 8px;
	color: #fff;
}

.akhp-parco-empty p:not(.akhp-parco-empty__message) {
	color: var(--akhp-muted);
	font-family: "Rajdhani", sans-serif;
	margin: 0;
}

@media (min-width: 540px) and (max-width: 767px) {
	.akhp-parco-list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px;
	}
}

@media (min-width: 768px) {
	.akhp--parco,
	.akhp--trova-page {
		--akhp-max: 1200px;
	}

	.akhp-search-form__grid--selects {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.akhp-search-form__grid--ranges {
		grid-template-columns: repeat(3, minmax(0, 1fr));
		gap: 12px 14px;
	}

	.akhp-parco-list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 16px;
	}
}

@media (min-width: 1024px) {
	.akhp--parco {
		--akhp-max: 1280px;
	}

	.akhp-parco-list {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.akhp-search-form__grid--selects {
		grid-template-columns: repeat(6, minmax(0, 1fr));
	}
}
