/* ------------------------------------------------------------------
   Banner de consentimento de cookies (LGPD) — Newsmag Child.
   Minimalista: barra inferior, sem imagens, sem fonte externa.
   ------------------------------------------------------------------ */

.tbt-consent {
	display: none;
	position: fixed;
	inset: auto 0 0 0;
	z-index: 99999;
	background: #fff;
	border-top: 3px solid #4db2ec;
	box-shadow: 0 -6px 24px rgba(0, 0, 0, .12);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	font-size: 14px;
	line-height: 1.5;
	color: #1a1a1a;
	animation: tbt-consent-up .28s ease-out;
}

/* Só aparece quando o <html> marca que ainda não houve escolha. */
.tbt-consent-pending .tbt-consent {
	display: block;
}

.tbt-consent__inner {
	max-width: 1180px;
	margin: 0 auto;
	padding: 14px 20px;
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
}

.tbt-consent__text {
	flex: 1 1 320px;
	margin: 0;
	color: #333;
}

.tbt-consent__text a {
	color: #4db2ec;
	text-decoration: underline;
}

/* ---- Painel de preferências ---- */
.tbt-consent__panel {
	flex: 1 0 100%;
	order: 3;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 24px;
	padding-top: 12px;
	margin-top: 4px;
	border-top: 1px solid #ededed;
}

.tbt-consent__panel[hidden] {
	display: none;
}

.tbt-consent__opt {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	cursor: pointer;
	color: #333;
}

.tbt-consent__opt input {
	width: 16px;
	height: 16px;
	margin: 0;
	accent-color: #4db2ec;
	cursor: pointer;
}

.tbt-consent__opt strong {
	font-weight: 600;
	color: #111;
}

/* ---- Botões ---- */
.tbt-consent__actions {
	display: flex;
	align-items: center;
	gap: 10px;
	flex: 0 0 auto;
	margin-left: auto;
}

.tbt-consent__btn {
	font: inherit;
	font-weight: 600;
	border: 1px solid transparent;
	border-radius: 4px;
	padding: 9px 18px;
	cursor: pointer;
	transition: background-color .15s ease, color .15s ease, border-color .15s ease;
	white-space: nowrap;
}

.tbt-consent__btn:focus-visible {
	outline: 2px solid #4db2ec;
	outline-offset: 2px;
}

.tbt-consent__btn--primary {
	background: #4db2ec;
	color: #fff;
}

.tbt-consent__btn--primary:hover {
	background: #2f9fdc;
}

.tbt-consent__btn--ghost {
	background: #fff;
	color: #444;
	border-color: #ddd;
}

.tbt-consent__btn--ghost:hover {
	background: #f5f5f5;
	border-color: #c9c9c9;
}

.tbt-consent__btn--link {
	background: none;
	color: #6b6b6b;
	padding: 9px 6px;
	text-decoration: underline;
	font-weight: 400;
}

.tbt-consent__btn--link:hover {
	color: #111;
}

.tbt-consent__btn--save {
	background: #1a1a1a;
	color: #fff;
	padding: 7px 16px;
}

.tbt-consent__btn--save:hover {
	background: #333;
}

@keyframes tbt-consent-up {
	from { transform: translateY(100%); }
	to { transform: translateY(0); }
}

/* ---- Mobile ---- */
@media (max-width: 767px) {
	.tbt-consent__inner {
		padding: 12px 14px;
		gap: 10px;
	}

	.tbt-consent__text {
		flex: 1 0 100%;
		font-size: 13px;
	}

	.tbt-consent__actions {
		flex: 1 0 100%;
		margin-left: 0;
		display: grid;
		grid-template-columns: 1fr 1fr;
		gap: 8px;
	}

	.tbt-consent__btn--link {
		grid-column: 1 / -1;
		order: 3;
		padding: 2px 0;
	}

	.tbt-consent__btn--ghost,
	.tbt-consent__btn--primary {
		justify-content: center;
		text-align: center;
	}

	.tbt-consent__panel {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.tbt-consent { animation: none; }
}

/* Reserva de espaço para o rodapé não ficar escondido atrás da barra. */
@media (max-width: 767px) {
	.tbt-consent-pending body { padding-bottom: 190px; }
}

@media (min-width: 768px) {
	.tbt-consent-pending body { padding-bottom: 78px; }
}
