/* Lets Cookies — banner e preferências.
 * Os três botões usam a mesma classe de propósito: o Guia da ANPD pede que
 * recusar e configurar tenham o mesmo destaque que aceitar. */

.lets-ck-banner,
.lets-ck-prefs,
.lets-ck-float,
.lets-ck-embed {
	--lets-ck-radius: 8px;
	box-sizing: border-box;
	font-family: inherit;
	line-height: 1.45;
}

.lets-ck-banner *,
.lets-ck-prefs * {
	box-sizing: border-box;
}

[hidden].lets-ck-banner,
[hidden].lets-ck-overlay,
[hidden].lets-ck-float {
	display: none !important;
}

/* ---------- Banner (1º nível) ---------- */

.lets-ck-banner {
	position: fixed;
	z-index: 2147483000;
	bottom: 16px;
	max-width: 440px;
	width: calc(100% - 32px);
	padding: 20px;
	background: var(--lets-ck-bg, #fff);
	color: var(--lets-ck-text, #1f1f1f);
	border-radius: var(--lets-ck-radius);
	box-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
	font-size: 14px;
}

.lets-ck-pos-bottom-right { right: 16px; }
.lets-ck-pos-bottom-left { left: 16px; }
.lets-ck-pos-bottom-bar {
	left: 0;
	right: 0;
	bottom: 0;
	max-width: none;
	width: 100%;
	border-radius: 0;
}

.lets-ck-title {
	margin: 0 0 8px;
	font-size: 16px;
	font-weight: 700;
	color: var(--lets-ck-text, #1f1f1f);
}

.lets-ck-text,
.lets-ck-cat-desc,
.lets-ck-browser {
	margin: 0 0 12px;
	color: var(--lets-ck-text, #1f1f1f);
}

.lets-ck-links {
	margin: 0 0 16px;
	font-size: 13px;
}

.lets-ck-links a {
	color: var(--lets-ck-primary, #55693c);
	text-decoration: underline;
}

.lets-ck-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

/* Mesmo estilo para Rejeitar, Personalizar/Salvar e Aceitar. */
.lets-ck-btn {
	flex: 1 1 120px;
	min-height: 44px;
	padding: 10px 14px;
	border: 2px solid var(--lets-ck-primary, #55693c);
	border-radius: var(--lets-ck-radius);
	background: var(--lets-ck-primary, #55693c);
	color: #fff;
	font: inherit;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
}

.lets-ck-btn:hover { filter: brightness(1.08); }

.lets-ck-btn:focus-visible,
.lets-ck-close:focus-visible,
.lets-ck-float:focus-visible,
.lets-ck-switch:focus-visible,
.lets-ck-embed__btn:focus-visible,
.lets-ck-cookies summary:focus-visible {
	outline: 3px solid var(--lets-ck-text, #1f1f1f);
	outline-offset: 2px;
}

/* ---------- Preferências (2º nível) ---------- */

.lets-ck-overlay {
	position: fixed;
	inset: 0;
	z-index: 2147483001;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	background: rgba(0, 0, 0, 0.5);
}

html.lets-ck-open { overflow: hidden; }

.lets-ck-prefs {
	position: relative;
	width: 100%;
	max-width: 640px;
	max-height: calc(100vh - 32px);
	overflow-y: auto;
	padding: 24px;
	background: var(--lets-ck-bg, #fff);
	color: var(--lets-ck-text, #1f1f1f);
	border-radius: var(--lets-ck-radius);
	font-size: 14px;
}

.lets-ck-prefs .lets-ck-title { font-size: 18px; padding-right: 32px; }

.lets-ck-close {
	position: absolute;
	top: 12px;
	right: 12px;
	width: 36px;
	height: 36px;
	border: 0;
	background: transparent;
	color: var(--lets-ck-text, #1f1f1f);
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.lets-ck-cat {
	padding: 14px 0;
	border-top: 1px solid rgba(0, 0, 0, 0.12);
}

.lets-ck-cat-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 6px;
}

.lets-ck-cat-name { font-weight: 700; }

.lets-ck-always {
	font-size: 13px;
	font-weight: 600;
	color: var(--lets-ck-primary, #55693c);
}

/* Interruptor acessível feito com o próprio checkbox. */
.lets-ck-switch {
	appearance: none;
	-webkit-appearance: none;
	position: relative;
	flex: 0 0 auto;
	width: 44px;
	height: 24px;
	margin: 0;
	border-radius: 12px;
	background: #b5b5b5;
	cursor: pointer;
	transition: background 0.15s;
}

.lets-ck-switch::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 18px;
	height: 18px;
	border-radius: 50%;
	background: #fff;
	transition: transform 0.15s;
}

.lets-ck-switch:checked { background: var(--lets-ck-primary, #55693c); }
.lets-ck-switch:checked::after { transform: translateX(20px); }

.lets-ck-cookies summary {
	cursor: pointer;
	font-size: 13px;
	color: var(--lets-ck-primary, #55693c);
}

.lets-ck-cookies table {
	width: 100%;
	margin-top: 8px;
	border-collapse: collapse;
	font-size: 12px;
}

.lets-ck-cookies th,
.lets-ck-cookies td {
	padding: 6px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.08);
	text-align: left;
	vertical-align: top;
}

.lets-ck-browser { font-size: 13px; opacity: 0.85; }
.lets-ck-browser p { margin: 0 0 6px; }
.lets-ck-browser-links { margin: 0 0 12px; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px 16px; }
.lets-ck-browser-links a { color: var(--lets-ck-primary, #55693c); text-decoration: underline; }

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

.lets-ck-float {
	position: fixed;
	z-index: 2147482999;
	left: 16px;
	bottom: 16px;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: 50%;
	background: var(--lets-ck-primary, #55693c);
	color: #fff;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* ---------- Conteúdo incorporado bloqueado ---------- */

.lets-ck-embed {
	position: relative;
	width: 100%;
	margin: 1.5em 0;
	overflow: hidden;
	background: #eee;
	border-radius: var(--lets-ck-radius);
}

.lets-ck-embed iframe {
	position: absolute;
	inset: 0;
	width: 100% !important;
	height: 100% !important;
	border: 0;
}

.lets-ck-embed__box {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 20px;
	text-align: center;
	color: #444;
	font-size: 15px;
}

.lets-ck-embed__box p { margin: 0; max-width: 520px; }

.lets-ck-embed__btn {
	padding: 10px 22px;
	border: 0;
	border-radius: var(--lets-ck-radius);
	background: var(--lets-ck-primary, #55693c);
	color: #fff;
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

.lets-ck-embed__note { font-size: 13px; color: #666; }
.lets-ck-embed__note a { color: inherit; }

@media (max-width: 480px) {
	.lets-ck-banner { bottom: 0; left: 0; right: 0; width: 100%; max-width: none; border-radius: 0; }
	.lets-ck-btn { flex-basis: 100%; }
}

@media (prefers-reduced-motion: reduce) {
	.lets-ck-switch,
	.lets-ck-switch::after { transition: none; }
}
