/**
 * Place Oversea — integração Elementor com design tokens.
 * Overrides progressivos — não altera layouts, apenas tokens visuais.
 */

body.po-site {
	/* Mapear cores globais Elementor → tokens Place Oversea */
	--e-global-color-primary: var(--po-primary);
	--e-global-color-secondary: var(--po-accent);
	--e-global-color-text: var(--po-text);
	--e-global-color-accent: var(--po-accent);
}

/* Tipografia global Elementor → Inter */
body.po-site .elementor-heading-title,
body.po-site .elementor-widget-text-editor,
body.po-site .elementor-widget-text-editor p,
body.po-site .elementor-widget-text-editor li {
	font-family: var(--po-font-family) !important;
}

/* Headings */
body.po-site .elementor-widget-heading h1.elementor-heading-title {
	font-size: var(--po-font-size-h1) !important;
	font-weight: var(--po-font-weight-bold) !important;
	line-height: var(--po-line-height-tight) !important;
	color: var(--po-primary) !important;
}

body.po-site .elementor-widget-heading h2.elementor-heading-title {
	font-size: var(--po-font-size-h2) !important;
	font-weight: var(--po-font-weight-bold) !important;
	line-height: var(--po-line-height-heading) !important;
	color: var(--po-primary) !important;
}

body.po-site .elementor-widget-heading h3.elementor-heading-title,
body.po-site .elementor-widget-heading h4.elementor-heading-title {
	font-weight: var(--po-font-weight-semibold) !important;
	color: var(--po-text) !important;
}

body.po-site .elementor-widget-text-editor p,
body.po-site .elementor-widget-text-editor li {
	color: var(--po-muted);
	line-height: var(--po-line-height-body);
	font-size: var(--po-font-size-body);
}

/* Botões Elementor → design system */
body.po-site .elementor:not(.elementor-location-footer) .elementor-button.elementor-button-link,
body.po-site .elementor:not(.elementor-location-footer) .elementor-button {
	font-family: var(--po-font-family) !important;
	border-radius: var(--po-radius-pill) !important;
	font-weight: var(--po-font-weight-bold) !important;
	transition:
		transform var(--po-transition-base),
		box-shadow var(--po-transition-base),
		background-color var(--po-transition-base) !important;
}

body.po-site .elementor:not(.elementor-location-footer) .elementor-button.elementor-button-link:not(:hover):not(:focus),
body.po-site .elementor:not(.elementor-location-footer) .elementor-button:not(.elementor-button-info):not(:hover):not(:focus) {
	background-color: var(--po-accent) !important;
	color: var(--po-text) !important;
	border: none !important;
	box-shadow: var(--po-shadow-accent) !important;
}

body.po-site .elementor:not(.elementor-location-footer) .elementor-button.elementor-button-link:hover,
body.po-site .elementor:not(.elementor-location-footer) .elementor-button.elementor-button-link:focus,
body.po-site .elementor:not(.elementor-location-footer) .elementor-button:not(.elementor-button-info):hover,
body.po-site .elementor:not(.elementor-location-footer) .elementor-button:not(.elementor-button-info):focus {
	background-color: var(--po-accent-dark) !important;
	color: var(--po-text) !important;
	transform: translateY(-2px);
	box-shadow: var(--po-shadow-accent-hover) !important;
}

/* Botão secundário (classe CSS personalizada no Elementor) */
body.po-site .elementor-button.po-btn--secondary,
body.po-site .elementor-button.elementor-button-info {
	background-color: var(--po-primary) !important;
	color: var(--po-white) !important;
	box-shadow: var(--po-shadow-soft) !important;
}

body.po-site .elementor-button.po-btn--secondary:hover,
body.po-site .elementor-button.elementor-button-info:hover {
	background-color: var(--po-primary-dark) !important;
	color: var(--po-white) !important;
}

/* Campos de formulário Elementor */
body.po-site .elementor:not(.elementor-location-footer) .elementor-field-group .elementor-field {
	font-family: var(--po-font-family) !important;
	border-color: var(--po-muted-border) !important;
	border-radius: var(--po-radius-md) !important;
	color: var(--po-text) !important;
}

body.po-site .elementor:not(.elementor-location-footer) .elementor-field-group .elementor-field:focus {
	border-color: var(--po-primary) !important;
	box-shadow: 0 0 0 3px var(--po-primary-soft) !important;
}

/* CTA Elementor — texto sobre imagem em preto */
body.po-site .elementor-cta__title,
body.po-site .elementor-cta__description {
	font-family: var(--po-font-family) !important;
	color: var(--po-text) !important;
	text-shadow:
		0 0 10px rgba(255, 255, 255, 0.9),
		0 1px 3px rgba(255, 255, 255, 0.8) !important;
}

body.po-site .elementor-cta,
body.po-site .elementor-cta__bg {
	border-radius: var(--po-radius-lg) !important;
}

/* Ícones Elementor → cor primária */
body.po-site .elementor-widget-icon .elementor-icon {
	color: var(--po-primary) !important;
}

/* Nav menu — item activo */
body.po-site .elementor-nav-menu--main .elementor-item.elementor-item-active,
body.po-site .elementor-nav-menu--dropdown .elementor-item.elementor-item-active {
	color: var(--po-primary) !important;
}

/* Imagens */
body.po-site .elementor:not(.elementor-location-header):not(.elementor-location-footer) .elementor-widget-image img {
	border-radius: var(--po-radius-md);
}

/* Google Maps */
body.po-site .elementor-widget-google_maps iframe {
	border-radius: var(--po-radius-lg);
	border: 1px solid var(--po-border);
}

/* Harmonização — azul legado (#6999cf) → Azul Oceano (#0F4C81) */
body.po-site {
	--e-global-color-primary: var(--po-primary) !important;
	--e-global-color-secondary: var(--po-accent) !important;
	--e-global-color-accent: var(--po-accent) !important;
}

body.po-site .elementor-widget-heading h1.elementor-heading-title,
body.po-site .elementor-widget-heading h2.elementor-heading-title,
body.po-site .elementor-widget-heading h3.elementor-heading-title,
body.po-site .elementor-widget-heading h4.elementor-heading-title {
	color: var(--po-primary) !important;
}

body.po-site .po-carousel__arrow {
	background: rgba(15, 76, 129, 0.92) !important;
}

body.po-site .po-carousel__arrow:hover,
body.po-site .po-carousel__arrow:focus-visible {
	background: var(--po-primary) !important;
}

body.po-site .po-carousel__progress {
	background: rgba(15, 76, 129, 0.18) !important;
}

body.po-site .po-carousel__progress span {
	background: var(--po-primary) !important;
}

body.po-site .po-property-detail__kicker,
body.po-site .po-property-detail__section-kicker,
body.po-property-has-detail .po-property-detail__headline {
	color: var(--po-primary) !important;
}

body.po-site .swiper-button-next,
body.po-site .swiper-button-prev,
body.po-site .elementor-swiper-button,
body.po-site .ha-slick-prev,
body.po-site .ha-slick-next {
	background-color: var(--po-primary) !important;
	color: var(--po-white) !important;
}

body.po-site .swiper-pagination-progressbar .swiper-pagination-progressbar-fill,
body.po-site .elementor-pagination-progressbar-fill {
	background: var(--po-primary) !important;
}

/* Texto sobre imagens / heroes / fundos fotográficos — preto legível */
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) .elementor-heading-title,
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) h1,
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) h2,
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) h3,
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) h4,
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) .elementor-widget-text-editor,
body.po-site .elementor .e-con:has(> .elementor-background-slideshow) p,
body.po-site .elementor .e-con.e-parent[style*="background-image"] .elementor-heading-title,
body.po-site .elementor .e-con.e-parent[style*="background-image"] h1,
body.po-site .elementor .e-con.e-parent[style*="background-image"] h2,
body.po-site .elementor-element-7b83d4e .elementor-heading-title,
body.po-site .elementor-element-7b83d4e h1,
body.po-site .elementor-element-7b83d4e h1 strong,
body.po-site .elementor-element-22f7782 .elementor-heading-title,
body.po-site .elementor-element-22f7782 h1,
body.po-site .elementor-widget-image-box .elementor-image-box-title,
body.po-site .elementor-widget-image-box .elementor-image-box-description,
body.po-site .elementor-widget-ha-slider .ha-slider-title,
body.po-site .elementor-widget-ha-slider .ha-slider-subtitle {
	color: var(--po-text) !important;
	text-shadow:
		0 0 10px rgba(255, 255, 255, 0.9),
		0 1px 3px rgba(255, 255, 255, 0.8) !important;
}
