/* Lestu Core — site: banners, aviso de cookies e convite de instalação (PWA). */

/* ---------- Banners entre seções ---------- */
.lestu-banner { padding-block: 1.25rem; }
.lestu-banner__rotulo { margin: 0 0 .35rem; font-size: .6875rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #6f695d; text-align: center; }
.lestu-banner__palco { position: relative; display: grid; max-width: 1200px; margin-inline: auto; }
.lestu-banner__item { grid-area: 1 / 1; display: block; opacity: 0; visibility: hidden; transition: opacity 500ms ease, visibility 0s 500ms; border-radius: 8px; overflow: hidden; }
.lestu-banner__item.esta-ativo { opacity: 1; visibility: visible; transition: opacity 500ms ease; }
.lestu-banner__item img, .lestu-banner__item video { display: block; width: 100%; height: auto; }
.lestu-banner__item:focus-visible { outline: 3px solid #111010; outline-offset: 3px; box-shadow: 0 0 0 2px #e6ad0f; }
@media (prefers-reduced-motion: reduce) { .lestu-banner__item, .lestu-banner__item.esta-ativo { transition: none; } }

/* ---------- Banner institucional "leque de livros" (lestu-banner-conhecimento) ----------
   Referência de composição: seção "Preservando Memórias" (Bienal Editora). Capas = imagem
   destacada dos livros escolhidos no banner (mockups 3D com transparência). */
.lestu-banner--largo { padding-block: 0; }
.lestu-banner--largo > .container { max-width: none; padding-inline: 0; }
.lestu-banner--largo .lestu-banner__rotulo { display: none; }
.lestu-banner--largo .lestu-banner__palco { max-width: none; }
.lestu-banner--largo .lestu-banner__item { border-radius: 0; }

.lestu-banner-conhecimento {
	--lbc-preto: var(--lestu-preto, #111010);
	--lbc-ouro: var(--lestu-ouro, #e6ad0f);
	--lbc-ouro-hover: var(--lestu-ouro-hover, #f1bb22);
	--lbc-marfim: var(--lestu-marfim, #fbf8f1);
	--lbc-capa: min(210px, 16vw);
	--lbc-sobrepor: 92px;
	--lbc-ease: cubic-bezier(.16, 1, .3, 1);
	width: 100%;
	background: var(--lbc-preto);
	color: #fff;
	font-family: var(--lestu-fonte, "Montserrat", system-ui, sans-serif);
	overflow: hidden;
}
.lestu-banner-conhecimento__interno {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: end;
	gap: 32px;
	min-height: 230px;
}
.lestu-banner-conhecimento__texto { align-self: center; padding-block: 2.75rem; }
.lestu-banner-conhecimento__titulo {
	margin: 0 0 1rem;
	font-size: var(--fs-2xl, clamp(1.625rem, 1.2rem + 1.6vw, 2.25rem));
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -0.02em;
	color: #fff;
}
.lestu-banner-conhecimento__destaque { color: var(--lbc-ouro); }
.lestu-banner-conhecimento__descricao {
	max-width: 520px;
	margin: 0 0 1.5rem;
	font-size: var(--fs-base, 1.0625rem);
	font-weight: 500;
	line-height: 1.6;
	color: var(--lbc-marfim);
}
.lestu-banner-conhecimento__botao {
	display: inline-flex;
	align-items: center;
	gap: .5rem;
	min-height: 48px;
	padding: .75rem 1.35rem;
	font-size: .9375rem;
	font-weight: 700;
	line-height: 1.2;
	color: var(--lbc-preto);
	background: var(--lbc-ouro);
	border-radius: var(--raio, 6px);
	text-decoration: none;
	transition: background-color 160ms ease;
}
.lestu-banner-conhecimento__botao svg { flex: none; transition: transform 160ms ease; }
.lestu-banner-conhecimento__botao:hover { color: var(--lbc-preto); background: var(--lbc-ouro-hover); }
.lestu-banner-conhecimento__botao:hover svg { transform: translateX(3px); }
.lestu-banner-conhecimento__botao:focus-visible { outline: 3px solid var(--lbc-marfim); outline-offset: 3px; box-shadow: 0 0 0 6px var(--lbc-preto); }

/* Leque de capas */
.lestu-banner-conhecimento__capas {
	display: flex;
	align-items: flex-end;
	align-self: end;
	/* Respiro inferior: as capas giradas (até 13°) e deslocadas não encostam na base. */
	padding: 1.75rem 1.75rem 3rem;
}
.lestu-banner-conhecimento__capa {
	position: relative;
	flex: none;
	width: var(--lbc-capa);
	background: transparent;
	transform-origin: 50% 90%;
	transition: transform 450ms var(--lbc-ease);
	filter: drop-shadow(0 14px 16px rgba(0, 0, 0, .45)) drop-shadow(0 3px 4px rgba(0, 0, 0, .35));
	will-change: transform;
}
.lestu-banner-conhecimento__capa + .lestu-banner-conhecimento__capa { margin-left: calc(-1 * var(--lbc-sobrepor)); }
.lestu-banner-conhecimento__capa img { display: block; width: 100%; height: auto; object-fit: contain; background: transparent; }
.lestu-banner-conhecimento__capa:nth-child(1) { z-index: 1; transform: rotate(-8deg) translateY(10px); }
.lestu-banner-conhecimento__capa:nth-child(2) { z-index: 2; transform: rotate(-2deg); }
.lestu-banner-conhecimento__capa:nth-child(3) { z-index: 3; transform: rotate(4deg) translateY(2px); }
.lestu-banner-conhecimento__capa:nth-child(4) { z-index: 4; transform: rotate(10deg) translateY(14px); }

/* Abre o leque ao passar o mouse em qualquer área do banner (só com mouse/trackpad) */
@media (hover: hover) and (pointer: fine) {
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(1) { transform: rotate(-12deg) translate(-14px, 8px); }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(2) { transform: rotate(0deg) translateY(0); }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(3) { transform: rotate(0deg) translateY(0); }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(4) { transform: rotate(13deg) translate(14px, 10px); }
}

@media (max-width: 992px) {
	.lestu-banner-conhecimento__interno { grid-template-columns: 1fr; min-height: 0; }
	.lestu-banner-conhecimento__capas { display: none; }
	.lestu-banner-conhecimento__texto { padding-block: 2.25rem; }
}
@media (max-width: 480px) {
	.lestu-banner-conhecimento__titulo { font-size: 1.5rem; }
	.lestu-banner-conhecimento__descricao { font-size: 1rem; }
	.lestu-banner-conhecimento__botao { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
	.lestu-banner-conhecimento__capa,
	.lestu-banner-conhecimento__botao svg { transition: none; }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(1) { transform: rotate(-8deg) translateY(10px); }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(2) { transform: rotate(-2deg); }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(3) { transform: rotate(4deg) translateY(2px); }
	.lestu-banner-conhecimento:hover .lestu-banner-conhecimento__capa:nth-child(4) { transform: rotate(10deg) translateY(14px); }
}

/* ---------- Aviso de cookies (LGPD) ---------- */
.lestu-cookies {
	position: fixed; z-index: 9999; left: 1rem; right: 1rem; bottom: 1rem;
	max-width: 980px; margin-inline: auto; padding: 1.25rem 1.5rem;
	background: #111010; color: #fff; border-top: 4px solid #e6ad0f; border-radius: 10px;
	box-shadow: 0 18px 50px rgba(17, 16, 16, .35);
	font-family: inherit; font-size: .9375rem; line-height: 1.5;
	animation: lestu-sobe 260ms ease both;
}
@keyframes lestu-sobe { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .lestu-cookies { animation: none; } }
.lestu-cookies__interno { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 1rem 2rem; }
.lestu-cookies__texto { flex: 1 1 28rem; }
.lestu-cookies__titulo { margin: 0 0 .25rem; font-weight: 800; font-size: 1.0625rem; color: #e6ad0f; }
.lestu-cookies p { margin: 0; }
.lestu-cookies a { color: #fff; text-decoration-color: #e6ad0f; text-underline-offset: .2em; }
.lestu-cookies__opcoes { display: grid; gap: .6rem; margin-top: .9rem; }
.lestu-cookies__opcoes[hidden], .lestu-banner[hidden], .lestu-instalar[hidden] { display: none; }
.lestu-cookies__opcoes label { display: flex; gap: .6rem; align-items: flex-start; font-size: .875rem; color: rgba(255, 255, 255, .85); }
.lestu-cookies__opcoes input { width: 18px; height: 18px; margin-top: .15rem; accent-color: #e6ad0f; flex: none; }
.lestu-cookies__acoes { display: flex; flex-wrap: wrap; gap: .5rem; }
.lestu-cookies__botao { min-height: 44px; padding: .55rem 1.1rem; font: inherit; font-size: .875rem; font-weight: 700; color: #fff; background: transparent; border: 1px solid rgba(255, 255, 255, .45); border-radius: 6px; cursor: pointer; }
.lestu-cookies__botao:hover { border-color: #e6ad0f; color: #e6ad0f; }
.lestu-cookies__botao--principal { color: #111010; background: #e6ad0f; border-color: #e6ad0f; }
.lestu-cookies__botao--principal:hover { color: #111010; background: #f1bb22; }
.lestu-cookies__botao--link { border-color: transparent; text-decoration: underline; text-decoration-color: #e6ad0f; text-underline-offset: .2em; }
.lestu-cookies__botao:focus-visible { outline: 3px solid #e6ad0f; outline-offset: 2px; }
@media (max-width: 600px) {
	.lestu-cookies { left: .5rem; right: .5rem; bottom: .5rem; padding: 1rem; }
	.lestu-cookies__acoes { width: 100%; }
	.lestu-cookies__botao { flex: 1 1 auto; }
}

/* Link no rodapé */
.rodape__cookies { padding: 0; font: inherit; font-size: .8125rem; color: inherit; background: none; border: 0; text-decoration: underline; text-decoration-color: #e6ad0f; text-underline-offset: .2em; cursor: pointer; }
.rodape__cookies:hover { color: #e6ad0f; }

/* ---------- Convite para instalar (PWA) ---------- */
.lestu-instalar {
	position: fixed; z-index: 9998; left: .75rem; right: .75rem; bottom: .75rem;
	display: flex; align-items: center; gap: .75rem; padding: .75rem .75rem .75rem .9rem;
	background: #fff; color: #111010; border: 1px solid #ddd6c4; border-left: 4px solid #e6ad0f; border-radius: 10px;
	box-shadow: 0 12px 34px rgba(17, 16, 16, .22); font-size: .875rem; line-height: 1.4;
	animation: lestu-sobe 260ms ease both;
}
.lestu-instalar img { flex: none; border-radius: 8px; background: #111010; }
.lestu-instalar p { flex: 1; margin: 0; }
.lestu-instalar__sim { flex: none; min-height: 40px; padding: .4rem .9rem; font: inherit; font-weight: 700; color: #111010; background: #e6ad0f; border: 0; border-radius: 6px; cursor: pointer; }
.lestu-instalar__fechar { flex: none; width: 36px; height: 36px; font-size: 22px; line-height: 1; color: #3b3833; background: none; border: 0; border-radius: 50%; cursor: pointer; }
.lestu-instalar button:focus-visible { outline: 3px solid #111010; outline-offset: 2px; }
