/**
 * Botão, selo, modal e faixa de confirmação.
 *
 * As cores acompanham a paleta v7 pelas mesmas variáveis do theme.json usadas
 * pelos blocos, com fallback para quem renderizar fora do tema (a vitrine do
 * WooCommerce, por exemplo).
 */

.aa-interesse-btn,
.aa-interesse-modal {
	--aai-primary: var( --wp--preset--color--primary, #4f46e5 );
	--aai-secondary: var( --wp--preset--color--secondary, #7c3aed );
	--aai-border: var( --wp--preset--color--border, #e5e7f5 );
	--aai-text: var( --wp--preset--color--text-primary, #0f172a );
	--aai-muted: var( --wp--preset--color--text-muted, #64748b );
	--aai-gradient: linear-gradient( 135deg, #4f46e5 0%, #7c3aed 100% );
}

/* ---------- Botão ---------- */

.aa-interesse-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: var( --aai-gradient );
	color: #fff;
	border: 0;
	border-radius: 12px;
	padding: 11px 20px;
	font: inherit;
	font-weight: 600;
	font-size: 0.9rem;
	line-height: 1.2;
	cursor: pointer;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.aa-interesse-btn:hover {
	transform: translateY( -1px );
	box-shadow: 0 8px 24px rgba( 79, 70, 229, 0.28 );
	color: #fff;
}

.aa-interesse-btn:focus-visible {
	outline: 2px solid var( --aai-primary );
	outline-offset: 2px;
}

.aa-interesse-btn--loop {
	width: 100%;
	justify-content: center;
}

.aa-interesse-btn--lg {
	padding: 14px 28px;
	font-size: 1rem;
}

.aa-interesse-btn--bloco {
	display: flex;
	width: 100%;
	justify-content: center;
}

/* ---------- Selo ---------- */

.aa-interesse-selo {
	display: inline-block;
	background: #fff7ed;
	color: #c2410c;
	border: 1px solid #fed7aa;
	border-radius: 999px;
	padding: 4px 12px;
	font-family: 'JetBrains Mono', ui-monospace, monospace;
	font-size: 0.7rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	line-height: 1.4;
}

/* Sobre a imagem do card na vitrine do WooCommerce. */
.aa-interesse-selo--loop {
	position: absolute;
	top: 12px;
	left: 12px;
	z-index: 2;
	background: var( --aai-gradient, linear-gradient( 135deg, #4f46e5, #7c3aed ) );
	color: #fff;
	border-color: transparent;
}

.woocommerce ul.products li.product {
	position: relative;
}

.aa-interesse-preco-breve {
	color: #c2410c;
	font-weight: 700;
}

.aa-interesse-single {
	margin: 20px 0;
}

.aa-interesse-single-texto {
	margin: 10px 0 14px;
	color: var( --wp--preset--color--text-muted, #64748b );
	font-size: 0.92rem;
}

/* ---------- Modal ---------- */

.aa-interesse-modal {
	width: min( 460px, calc( 100vw - 32px ) );
	padding: 0;
	border: 1px solid var( --aai-border );
	border-radius: 20px;
	box-shadow: 0 24px 64px rgba( 15, 23, 42, 0.24 );
	color: var( --aai-text );
	font-family: Inter, -apple-system, 'Segoe UI', sans-serif;
	overflow: visible;
}

.aa-interesse-modal::backdrop {
	background: rgba( 15, 23, 42, 0.55 );
	backdrop-filter: blur( 2px );
}

.aa-interesse-fechar {
	position: absolute;
	top: 10px;
	right: 12px;
	background: none;
	border: 0;
	font-size: 1.6rem;
	line-height: 1;
	color: var( --aai-muted );
	cursor: pointer;
	padding: 4px 8px;
}

.aa-interesse-conteudo {
	padding: 32px 28px 28px;
}

.aa-interesse-conteudo h3 {
	margin: 12px 0 6px;
	font-size: 1.25rem;
	font-weight: 700;
	letter-spacing: -0.01em;
}

.aa-interesse-sub {
	margin: 0 0 20px;
	color: var( --aai-muted );
	font-size: 0.9rem;
	line-height: 1.55;
}

.aa-interesse-form label {
	display: block;
	font-size: 0.82rem;
	font-weight: 600;
	margin-bottom: 6px;
}

.aa-interesse-form input[ type='text' ],
.aa-interesse-form input[ type='email' ] {
	width: 100%;
	box-sizing: border-box;
	padding: 11px 14px;
	margin-bottom: 16px;
	border: 1px solid var( --aai-border );
	border-radius: 12px;
	font: inherit;
	font-size: 0.95rem;
	background: #fff;
	color: var( --aai-text );
}

.aa-interesse-form input:focus {
	outline: none;
	border-color: var( --aai-primary );
	box-shadow: 0 0 0 3px rgba( 79, 70, 229, 0.15 );
}

.aa-interesse-consent {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	font-weight: 400;
	font-size: 0.82rem;
	color: var( --aai-muted );
	line-height: 1.5;
	margin-bottom: 18px;
}

.aa-interesse-consent input {
	margin-top: 2px;
	flex-shrink: 0;
}

.aa-interesse-consent a {
	color: var( --aai-primary );
}

.aa-interesse-enviar {
	width: 100%;
	background: var( --aai-gradient );
	color: #fff;
	border: 0;
	border-radius: 12px;
	padding: 13px 20px;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
}

.aa-interesse-enviar:disabled {
	opacity: 0.6;
	cursor: progress;
}

.aa-interesse-feedback {
	margin: 14px 0 0;
	font-size: 0.86rem;
	line-height: 1.5;
	min-height: 1em;
}

.aa-interesse-feedback.is-ok {
	color: #15803d;
}

.aa-interesse-feedback.is-erro {
	color: #b91c1c;
}

/* Honeypot: fora da tela, mas presente no DOM para o robô encontrar.
   `display:none` seria pulado por parte dos bots — daí o deslocamento. */
.aa-interesse-hp {
	position: absolute;
	left: -9999px;
	top: -9999px;
	height: 0;
	overflow: hidden;
}

/* ---------- Faixa de retorno da confirmação ---------- */

.aa-interesse-aviso {
	padding: 14px 20px;
	text-align: center;
	font-family: Inter, -apple-system, 'Segoe UI', sans-serif;
	font-size: 0.92rem;
	font-weight: 500;
}

.aa-interesse-aviso--confirmado {
	background: #dcfce7;
	color: #15803d;
}

.aa-interesse-aviso--invalido {
	background: #fee2e2;
	color: #b91c1c;
}
