/* Webnial Popup Lista v2: cartão flutuante, sem fundo escuro e sem tapar a página.
   Tudo com prefixo .wnlpl; sem ficheiros de letra próprios nem fontes de ícones (SVG embutido). */

.wnlpl,
.wnlpl *,
.wnlpl *::before,
.wnlpl *::after {
	box-sizing: border-box;
}

.wnlpl {
	/* Paleta: topo claro, oferta em azul vivo, texto cinzento-azulado (nunca preto) e um só bloco forte, o botão. */
	--wn-ink: #2b4660;
	--wn-body: #4a5f73;
	--wn-muted: #566c80;
	--wn-link: #0a6ea5;
	--wn-brand: #00a0e0;
	--wn-brand-strong: #0086c9;
	--wn-line: #b9cfdd;
	--wn-cta-1: #0a9de6;
	--wn-cta-2: #0083cf;
	--wn-cta-glow: rgba(0, 131, 207, 0.38);
	position: fixed;
	right: 24px;
	bottom: calc(24px + var(--wnlpl-kb, 0px));
	z-index: 100000;
	width: 400px;
	max-width: calc(100vw - 32px);
	font-family: Lato, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 15px;
	line-height: 1.45;
	color: var(--wn-ink);
	opacity: 0;
	transform: translateY(28px);
	pointer-events: none;
	transition: opacity 0.3s ease, transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Variante para testar o contraste do botão (definições > Cor do botão). A marca Webnial é azul; o laranja é só para A/B. */
.wnlpl--cta-orange {
	--wn-cta-1: #ff8a1f;
	--wn-cta-2: #e8590c;
	--wn-cta-glow: rgba(232, 89, 12, 0.38);
}

.wnlpl[hidden] {
	display: none;
}

.wnlpl.is-in {
	opacity: 1;
	transform: none;
	pointer-events: auto;
}

.wnlpl__card {
	position: relative;
	background: #fff;
	border-radius: 18px;
	box-shadow: 0 24px 60px rgba(8, 38, 66, 0.3), 0 2px 8px rgba(8, 38, 66, 0.12);
}

/* Topo: a oferta em letra grande, sobre o azul da marca */
.wnlpl__banner {
	position: relative;
	padding: 24px 56px 22px 24px;
	border-radius: 18px 18px 0 0;
	color: var(--wn-ink);
	background-color: #d6edfa;
	background-image:
		radial-gradient(circle at 86% 6%, rgba(255, 255, 255, 0.95) 0, rgba(255, 255, 255, 0) 48%),
		radial-gradient(circle at 2% 122%, rgba(0, 160, 224, 0.2) 0, rgba(0, 160, 224, 0) 46%),
		linear-gradient(145deg, #ecf7fd 0%, #cdeaf9 100%);
}

.wnlpl__banner:not(.wnlpl__banner--photo) {
	overflow: hidden;
}

.wnlpl__banner--photo {
	min-height: 176px;
	padding-right: 24px;
}

/* A senhora recortada: a base alinha com o fundo do topo e a cabeça sai do cartão */
.wnlpl .wnlpl__figure {
	position: absolute;
	right: 14px;
	bottom: 0;
	z-index: 0;
	width: 166px;
	height: 215px;
	max-width: none;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	object-fit: contain;
	object-position: bottom center;
	pointer-events: none;
	filter: drop-shadow(0 6px 10px rgba(20, 80, 120, 0.3));
}

.wnlpl__deco {
	position: absolute;
	right: -10px;
	bottom: -22px;
	width: 120px;
	height: 120px;
	opacity: 0.28;
	transform: rotate(-14deg);
	pointer-events: none;
}

.wnlpl .wnlpl__deco path,
.wnlpl .wnlpl__deco circle {
	stroke: var(--wn-brand);
}

.wnlpl__offer {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
}

.wnlpl__banner--photo .wnlpl__offer {
	max-width: 58%;
}

.wnlpl .wnlpl__badge {
	font-family: Montserrat, Lato, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	font-size: 64px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: -1.5px;
	color: var(--wn-brand-strong);
	text-shadow: 0 1px 0 rgba(255, 255, 255, 0.9);
}

.wnlpl .wnlpl__offer-text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 10px;
	min-width: 0;
}

.wnlpl .wnlpl__badge-label {
	max-width: 190px;
	text-wrap: balance;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.25;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--wn-ink);
}

.wnlpl .wnlpl__cond {
	max-width: 215px;
	text-wrap: balance;
	font-size: 12.5px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--wn-ink);
}

.wnlpl .wnlpl__chip {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: 0;
	padding: 4px 12px 4px 10px;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--wn-link);
	background: #fff;
	border: 1px solid #b5dcf2;
	border-radius: 999px;
	box-shadow: 0 1px 3px rgba(20, 80, 120, 0.12);
}

/* Corpo */
.wnlpl__body {
	padding: 20px 22px 16px;
}

.wnlpl .wnlpl__title {
	margin: 0 0 6px;
	padding: 0;
	font-family: Montserrat, Lato, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	font-size: 21px;
	font-weight: 700;
	line-height: 1.25;
	letter-spacing: 0;
	text-transform: none;
	color: var(--wn-ink);
}

.wnlpl .wnlpl__text {
	margin: 0 0 16px;
	font-size: 15px;
	color: var(--wn-body);
}

.wnlpl .wnlpl__form {
	margin: 0;
}

.wnlpl .wnlpl__field {
	position: relative;
	margin: 0 0 10px;
}

.wnlpl .wnlpl__field-icon {
	position: absolute;
	top: 50%;
	left: 14px;
	margin-top: -10px;
	color: #6b8aa0;
	pointer-events: none;
}

.wnlpl .wnlpl__input {
	display: block;
	width: 100%;
	height: 52px;
	margin: 0;
	padding: 0 14px 0 44px;
	font: inherit;
	font-size: 16px; /* 16px evita o zoom automático do iPhone */
	color: var(--wn-ink);
	background: #fff;
	border: 1.5px solid var(--wn-line);
	border-radius: 12px;
	box-shadow: none;
	transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.wnlpl .wnlpl__input::placeholder {
	color: #6e879b;
	opacity: 1;
}

.wnlpl .wnlpl__input:focus {
	background: #fff;
	border-color: var(--wn-brand-strong);
	outline: 0;
	box-shadow: 0 0 0 4px rgba(0, 160, 224, 0.2);
}

.wnlpl .wnlpl__input[aria-invalid="true"] {
	border-color: #c0392b;
	box-shadow: 0 0 0 4px rgba(192, 57, 43, 0.14);
}

.wnlpl .wnlpl__consent {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin: 0 0 12px;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--wn-muted);
	cursor: pointer;
}

.wnlpl .wnlpl__consent input {
	flex: 0 0 auto;
	width: 20px;
	height: 20px;
	margin: 0;
	accent-color: var(--wn-brand-strong);
}

.wnlpl .wnlpl__consent a {
	color: var(--wn-link);
	font-weight: 700;
	text-decoration: underline;
}

.wnlpl .wnlpl__consent.is-error {
	color: #a32a1f;
}

.wnlpl .wnlpl__btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 52px;
	margin: 0;
	padding: 12px 18px;
	font-family: inherit;
	font-size: 18px;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: 0;
	text-transform: none;
	color: #fff;
	background: linear-gradient(180deg, var(--wn-cta-1) 0%, var(--wn-cta-2) 100%);
	border: 0;
	border-radius: 12px;
	box-shadow: 0 10px 22px var(--wn-cta-glow), inset 0 1px 0 rgba(255, 255, 255, 0.28);
	cursor: pointer;
	transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
}

.wnlpl .wnlpl__btn:hover {
	color: #fff;
	filter: brightness(1.06);
	transform: translateY(-1px);
	box-shadow: 0 14px 28px var(--wn-cta-glow), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.wnlpl .wnlpl__btn:active {
	transform: translateY(0);
}

.wnlpl .wnlpl__btn:focus-visible,
.wnlpl .wnlpl__later:focus-visible,
.wnlpl .wnlpl__copy:focus-visible,
.wnlpl .wnlpl__close:focus-visible {
	outline: 3px solid var(--wn-ink);
	outline-offset: 2px;
}

.wnlpl .wnlpl__btn[disabled] {
	opacity: 0.75;
	cursor: progress;
	transform: none;
}

.wnlpl .wnlpl__msg {
	margin: 0 0 12px;
	padding: 9px 12px;
	font-size: 13.5px;
	font-weight: 700;
	color: #8c1d18;
	background: #fdecea;
	border-radius: 8px;
}

.wnlpl .wnlpl__msg[hidden] {
	display: none;
}

.wnlpl__foot {
	display: flex;
	justify-content: center;
	margin: 6px 0 0;
}

.wnlpl .wnlpl__later {
	margin: 0;
	padding: 6px 4px;
	font-family: inherit;
	font-size: 13px;
	font-weight: 400;
	color: var(--wn-muted);
	text-decoration: underline;
	text-transform: none;
	letter-spacing: 0;
	background: none;
	border: 0;
	box-shadow: none;
	cursor: pointer;
}

.wnlpl .wnlpl__later:hover {
	color: var(--wn-ink);
}

/* Fechar: no canto, sobre o azul */
.wnlpl .wnlpl__close {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	margin: 0;
	padding: 0;
	color: var(--wn-ink);
	background: #fff;
	border: 0;
	border-radius: 50%;
	box-shadow: 0 2px 6px rgba(20, 60, 100, 0.25);
	cursor: pointer;
	transition: background 0.15s ease;
}

.wnlpl .wnlpl__close svg {
	display: block;
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	min-width: 16px;
	margin: 0;
}

.wnlpl .wnlpl__btn svg {
	display: block;
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	min-width: 20px;
}

.wnlpl .wnlpl__chip svg {
	display: block;
	flex: 0 0 13px;
	width: 13px;
	height: 13px;
}

.wnlpl .wnlpl__close::after {
	content: "";
	position: absolute;
	top: -5px;
	right: -5px;
	bottom: -5px;
	left: -5px;
}

.wnlpl .wnlpl__close:hover {
	background: #eef7fc;
}

/* Depois de inscrito */
.wnlpl [data-wnlpl-panel="done"] {
	text-align: center;
	outline: 0;
}

.wnlpl .wnlpl__check {
	margin: 0 0 6px;
	line-height: 0;
}

.wnlpl .wnlpl__check-c {
	stroke-dasharray: 145;
	stroke-dashoffset: 145;
	animation: wnlpl-draw 0.6s ease forwards;
}

.wnlpl .wnlpl__check-p {
	stroke-dasharray: 40;
	stroke-dashoffset: 40;
	animation: wnlpl-draw 0.35s ease 0.45s forwards;
}

@keyframes wnlpl-draw {
	to {
		stroke-dashoffset: 0;
	}
}

.wnlpl .wnlpl__codewrap {
	display: flex;
	align-items: stretch;
	margin: 0 0 10px;
	overflow: hidden;
	background: #eaf7fd;
	border: 2px dashed var(--wn-brand);
	border-radius: 12px;
}

.wnlpl .wnlpl__code {
	flex: 1 1 auto;
	padding: 12px 10px;
	font-family: "SFMono-Regular", Menlo, Consolas, monospace;
	font-size: 24px;
	font-weight: 700;
	letter-spacing: 2px;
	text-align: center;
	color: var(--wn-link);
	user-select: all;
}

.wnlpl .wnlpl__copy {
	flex: 0 0 auto;
	margin: 0;
	padding: 0 18px;
	font-family: inherit;
	font-size: 14px;
	font-weight: 700;
	text-transform: none;
	letter-spacing: 0;
	color: #fff;
	background: #0079b8;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	cursor: pointer;
}

.wnlpl .wnlpl__copy:hover {
	background: #006399;
}

.wnlpl .wnlpl__note {
	margin: 0 0 14px;
	font-size: 13px;
	color: var(--wn-muted);
}

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

/* Campo armadilha para robôs: fora do ecrã, sem display:none. */
.wnlpl .wnlpl__hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	opacity: 0;
}

/* Telemóvel: cartão compacto colado ao fundo, sem fundo escuro e sem bloquear o scroll. */
@media (max-width: 640px) {
	.wnlpl {
		right: 10px;
		bottom: calc(10px + env(safe-area-inset-bottom, 0px) + var(--wnlpl-kb, 0px));
		left: 10px;
		width: auto;
		max-width: none;
		transform: translateY(40px);
	}

	.wnlpl__card {
		border-radius: 16px;
	}

	.wnlpl__banner {
		padding: 14px 16px;
		border-radius: 16px 16px 0 0;
	}

	.wnlpl__banner--photo {
		min-height: 104px;
		padding-right: 16px;
	}

	.wnlpl .wnlpl__figure {
		right: 28px;
		width: 100px;
		height: 129px;
	}

	.wnlpl__banner--photo .wnlpl__offer {
		max-width: 66%;
	}

	.wnlpl__deco {
		width: 84px;
		height: 84px;
		bottom: -16px;
	}

	.wnlpl__offer {
		display: grid;
		grid-template-columns: auto 1fr;
		align-items: center;
		column-gap: 8px;
		row-gap: 6px;
	}

	.wnlpl .wnlpl__offer-text {
		display: contents;
	}

	.wnlpl .wnlpl__badge {
		grid-row: 1 / span 2;
		align-self: center;
		font-size: 42px;
	}

	.wnlpl .wnlpl__badge-label {
		grid-column: 2;
		grid-row: 1;
		align-self: end;
	}

	.wnlpl .wnlpl__cond {
		grid-column: 2;
		grid-row: 2;
		align-self: start;
		max-width: none;
		font-size: 11.5px;
	}

	.wnlpl .wnlpl__badge-label {
		max-width: none;
		font-size: 12px;
	}

	.wnlpl .wnlpl__chip {
		grid-column: 1 / -1;
		grid-row: 3;
		justify-self: start;
		white-space: nowrap;
		padding: 3px 10px 3px 8px;
		font-size: 11.5px;
	}

	.wnlpl__body {
		padding: 14px 16px 10px;
	}

	.wnlpl .wnlpl__title {
		margin-bottom: 10px;
		font-size: 18px;
	}

	.wnlpl .wnlpl__text {
		display: none;
	}

	.wnlpl .wnlpl__input {
		height: 48px;
	}

	.wnlpl .wnlpl__consent {
		margin-bottom: 10px;
		font-size: 12.5px;
	}

	.wnlpl .wnlpl__btn {
		min-height: 50px;
	}
}

/* Ecrãs baixos (telemóvel na horizontal): duas colunas e nunca mais alto que o ecrã. */
@media (max-height: 520px) and (orientation: landscape) {
	.wnlpl {
		right: 12px;
		bottom: calc(8px + var(--wnlpl-kb, 0px));
		left: auto;
		width: min(620px, calc(100vw - 24px));
		max-width: none;
		transform: translateY(24px);
	}

	.wnlpl__card {
		display: flex;
		align-items: stretch;
		border-radius: 16px;
	}

	.wnlpl__banner,
	.wnlpl__banner--photo {
		flex: 0 0 47%;
		min-height: 0;
		padding: 14px 10px 14px 16px;
		border-radius: 16px 0 0 16px;
	}

	.wnlpl .wnlpl__figure {
		right: 0;
		width: 90px;
		height: 117px;
	}

	.wnlpl .wnlpl__badge {
		font-size: 40px;
	}

	.wnlpl .wnlpl__chip {
		font-size: 11.5px;
	}

	.wnlpl__banner--photo .wnlpl__offer {
		max-width: none;
	}

	.wnlpl__body {
		display: flex;
		flex: 1 1 auto;
		flex-direction: column;
		justify-content: center;
		min-width: 0;
		padding: 12px 16px 8px;
	}

	.wnlpl .wnlpl__title {
		margin-bottom: 8px;
		padding-right: 34px;
		font-size: 17px;
	}

	.wnlpl .wnlpl__text {
		display: none;
	}

	.wnlpl .wnlpl__input {
		height: 44px;
	}

	.wnlpl .wnlpl__field {
		margin-bottom: 8px;
	}

	.wnlpl .wnlpl__consent {
		margin-bottom: 8px;
		font-size: 12px;
	}

	.wnlpl .wnlpl__btn {
		min-height: 46px;
		font-size: 16px;
	}

	.wnlpl__foot {
		margin-top: 2px;
	}

	.wnlpl .wnlpl__check svg {
		width: 38px;
		height: 38px;
	}

	.wnlpl .wnlpl__code {
		padding: 8px;
		font-size: 20px;
	}

	.wnlpl .wnlpl__note {
		margin-bottom: 8px;
	}
}

/* O chat (JivoChat) abre sozinho e ficava por cima do popup: escondido enquanto o popup está aberto. */
html.wnlpl-open jdiv {
	display: none !important;
}

@media (prefers-reduced-motion: reduce) {
	.wnlpl,
	.wnlpl .wnlpl__btn,
	.wnlpl .wnlpl__input {
		transition: none;
	}

	.wnlpl .wnlpl__check-c,
	.wnlpl .wnlpl__check-p {
		animation: none;
		stroke-dashoffset: 0;
	}
}
