/*
 * Compatibilidade com o Tainacan Interface 4.x: devolve o leiaute que o site
 * tinha com a 3.0.3. Só é carregado com o tema pai na 4.x (inc/compat-v4.php).
 * As medidas vêm da página da 3.0.3 medida no navegador (16/11/2026).
 */

/* ---------- Cabeçalho do site: logo à esquerda, menu à direita ---------- */

body.mi-tema.tt2-modern #topNavbar {
	padding: 0 4.1667vw !important;
	gap: 0 24px;
}
body.mi-tema.tt2-modern .navbar-box {
	justify-content: flex-end;
}
body.mi-tema.tt2-modern .menu-belowheader {
	flex: 0 1 auto;
}
body.mi-tema.tt2-modern nav.navbar .navbar-nav > li > a {
	padding: 8px !important;
	font-weight: 400;
	border-radius: 0;
}
body.mi-tema.tt2-modern nav.navbar #menubelowHeader .navbar-nav > li {
	padding-left: 42px !important;
}
body.mi-tema.tt2-modern.tt2-header-colored nav.navbar .navbar-nav > li > a {
	color: var(--mi-papel) !important;
}
body.mi-tema.tt2-modern.tt2-header-colored nav.navbar .navbar-nav > li:is(.current-menu-item, .current-menu-ancestor, :hover) > a {
	color: var(--mi-ouro-claro) !important;
	text-decoration: underline;
	text-decoration-color: var(--mi-ouro);
	text-underline-offset: 6px;
	text-decoration-thickness: 2px;
}
body.mi-tema.tt2-modern > nav.navbar {
	border-bottom: 3px solid var(--mi-ouro) !important;
}

/* ---------- Trilha: pílulas de papel, "›" dourado, página atual em negrito ---------- */

body.mi-tema.tt2-modern .tt2-crumbs {
	margin: 0;
	padding: 10px 4.1667vw;
	font-size: 0.86rem;
}
body.mi-tema.tt2-modern .tt2-crumbs ol,
body.mi-tema.tt2-modern.tt2-crumbs-pills .tt2-crumbs ol {
	gap: 4px;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
}
body.mi-tema.tt2-modern .tt2-crumbs li + li::before {
	content: none;
}
body.mi-tema.tt2-modern .tt2-crumbs a {
	display: inline-flex;
	align-items: center;
	padding: 4px 12px;
	border: 1px solid var(--mi-papel-2);
	border-radius: 999px;
	background: var(--mi-papel);
	color: var(--mi-verde-2) !important;
	font-weight: 400;
	line-height: 1.5;
	text-decoration: none !important;
}
body.mi-tema.tt2-modern .tt2-crumbs a::after {
	content: "›";
	margin-left: 10px;
	color: var(--mi-ouro);
	font-weight: 700;
}
body.mi-tema.tt2-modern .tt2-crumbs a:hover {
	border-color: var(--mi-verde);
	background: var(--mi-verde);
	color: var(--mi-papel) !important;
}
body.mi-tema.tt2-modern .tt2-crumbs__current span,
body.mi-tema.tt2-modern.tt2-crumbs-pills .tt2-crumbs__current span {
	padding: 4px 12px 4px 6px;
	border-radius: 0;
	background: none;
	color: var(--mi-tinta) !important;
	line-height: 1.5;
	max-width: 60ch;
}
/* Trilha clássica (páginas e buscas): o ">" solto entre os links fica escondido, como antes. */
body.mi-tema.tt2-modern .tainacan-interface-breadcrumbs {
	color: transparent !important;
}

/* ---------- Cabeçalho de coleção: banner, faixa verde, ícone redondo dourado ---------- */

body.mi-tema.tt2-modern .tt2-head {
	margin-bottom: 0;
	background: var(--mi-verde);
	border-bottom: 3px solid var(--mi-ouro);
	color: #fff;
}
body.mi-tema.tt2-modern .tt2-head__banner {
	border-radius: 0;
	box-shadow: none;
}
body.mi-tema.tt2-modern .tt2-head__banner::after,
body.mi-tema.tt2-modern .tt2-head__banner .tt2-band {
	display: none;
}
body.mi-tema.tt2-modern .tt2-head--left .tt2-head__body,
body.mi-tema.tt2-modern .tt2-head--full .tt2-head__body {
	position: relative;
	max-width: none;
	min-height: 185px;
	margin: 0;
	padding: 20px 4.1667vw 0;
	gap: clamp(24px, 7.2vw, 104px);
}
body.mi-tema.tt2-modern .tt2-head__icon {
	flex: none;
	border: 4px solid var(--mi-ouro);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}
body.mi-tema.tt2-modern .tt2-head__text {
	position: static;
	max-width: 836px;
	padding-bottom: 20px;
}
body.mi-tema.tt2-modern .tt2-head__title,
body.mi-tema.tt2-modern h1.tt2-head__title {
	margin: 0 0 8px !important;
	padding: 0 !important;
	color: #fff !important;
	font-size: 24px !important;
	line-height: 1.2 !important;
}
body.mi-tema.tt2-modern .tt2-head__description,
body.mi-tema.tt2-modern .tt2-head__description--plain {
	max-width: none;
	margin-top: 0;
	color: #fff;
	font-family: Roboto, system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
	font-size: 14px;
	line-height: 21px;
}
body.mi-tema.tt2-modern .tt2-head__description p {
	margin: 0 0 21px;
}
body.mi-tema.tt2-modern .tt2-head__description a {
	color: #fff;
}
/* "Mostrar mais" (assets/mi-v4.js): cinco linhas, como o recorte da 3.0.3. */
body.mi-tema.tt2-modern .tt2-head__description.mi-recolhida {
	max-height: 105px;
	overflow: hidden;
}
body.mi-tema.tt2-modern .mi-mostrar-mais {
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	color: rgba(255, 255, 255, 0.65);
	font: inherit;
	font-size: 14px;
	cursor: pointer;
}
body.mi-tema.tt2-modern .mi-mostrar-mais:hover {
	color: #fff;
}
/* Compartilhar: círculo branco no alto da faixa, à direita. */
body.mi-tema.tt2-modern .tt2-head__actions {
	position: absolute;
	top: -18px;
	right: calc(4.1667vw - 3px);
	margin: 0;
}
body.mi-tema.tt2-modern .tt2-head__actions .tt2-pill-button {
	width: 35px;
	height: 35px;
	justify-content: center;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #fff;
	color: transparent;
	font-size: 0;
}
body.mi-tema.tt2-modern .tt2-head__actions .tt2-pill-button::before {
	content: "share";
	color: #2c2d2d;
	font-family: TainacanIcons;
	font-size: 20px;
	line-height: 1;
	-webkit-font-feature-settings: "liga";
	font-feature-settings: "liga";
}
body.mi-tema.tt2-modern .tt2-head__actions .tt2-share__links {
	right: 0;
	left: auto;
	transform: none;
}

/* Lista de itens logo abaixo da faixa, como antes. */
body.mi-tema.tt2-modern .tt2-head + * {
	margin-top: 0;
}

/* ---------- Página do item: modelos da 3.0.3 (template-parts do tema filho) ---------- */




/* Margem do conteúdo como na 3.0.3 (o primeiro bloco fica 48px abaixo da trilha). */
body.mi-tema.tt2-modern .tt2-crumbs ~ main.max-large.mt-5,
body.mi-tema.tt2-modern main.max-large.mt-5 {
	margin-top: 48px !important;
}

/* Títulos das partes ("Documento", "Anexos", "Metadados", "Continuar navegando"). */
body.mi-tema.tt2-modern:not(.tt2-label-document) #single-item-document-label,
body.mi-tema.tt2-modern:not(.tt2-label-attachments) #single-item-attachments-label {
	display: inline-block;
}
body.mi-tema.tt2-modern .tainacan-single-post .title-content-items,
body.mi-tema.tt2-modern .tainacan-single-post:has(> .title-content-items + *) .title-content-items {
	display: inline-block;
	margin: 0 4.1667vw 32px;
	padding: 0 0 4px;
	border-bottom: 3px solid var(--tt2-accent) !important;
	color: #1d1d1d !important;
	font-size: 18px !important;
	font-weight: 500 !important;
	line-height: 1.2;
}
body.mi-tema.tt2-modern #single-item-navigation-label {
	display: block;
	width: fit-content;
	margin: 0 4.1667vw;
}
body.mi-tema.tt2-modern .single-item-data-section .tainacan-single-post.mt-3 {
	margin-top: 1rem !important;
}
/* Margens em vw, como as classes margin-one/two-column da 3.0.3. */
body.mi-tema.tt2-modern main.max-large.margin-one-column {
	padding-inline: 4.1667vw;
}
body.mi-tema.tt2-modern .single-item-collection.margin-two-column {
	margin-inline: 4.1667vw !important;
}
@media (min-width: 769px) {
	body.mi-tema.tt2-modern .single-item-collection.margin-two-column {
		margin-inline: 8.3333vw !important;
	}
}
body.mi-tema.tt2-modern .single-item-data-section .my-5.border-bottom {
	display: block;
}
body.mi-tema.tt2-modern .tt2-item-body {
	margin-top: 0;
}

/* Ficha: nome em versal acima do valor, fio entre os campos, termos em pílulas. */
body.mi-tema.tt2-modern .s-item-collection--metadata > div[class*="metadata-type-"] {
	margin: 0 !important;
	padding: 10px 0 12px !important;
	border-bottom: 1px solid var(--tt2-line) !important;
}
body.mi-tema.tt2-modern .s-item-collection--metadata > div.card {
	margin: 0 0 1rem !important;
}
body.mi-tema.tt2-modern .s-item-collection--metadata > div[class*="metadata-type-"] > h3 {
	display: inline-block;
	margin: 0 0 4px;
	padding: 6.4px 16px 0 0;
	color: var(--tt2-label) !important;
	font-family: inherit;
	font-size: 14px !important;
	font-weight: 600 !important;
	letter-spacing: 0.05em !important;
	line-height: 1.35;
	text-transform: uppercase !important;
}
body.mi-tema.tt2-modern .s-item-collection--metadata .tainacan-metadata-value {
	margin: 0 0 16px !important;
	color: #2b2629;
	font-size: 1rem;
	line-height: 1.5;
}
body.mi-tema.tt2-modern .s-item-collection--metadata .tainacan-metadata-value a[data-linkto="term"],
body.mi-tema.tt2-modern.tt2-chips-plain .s-item-collection--metadata .tainacan-metadata-value a[data-linkto="term"] {
	display: inline-block;
	margin: 2px 4px 2px 0;
	padding: 2px 10px;
	border-radius: 999px;
	background: var(--tt2-soft);
	color: var(--tt2-ink);
	font-size: 0.92em;
	text-decoration: none;
}
body.mi-tema.tt2-modern .s-item-collection--metadata .tainacan-metadata-value a[data-linkto="term"]:hover {
	background: var(--tt2-accent);
	color: #fff;
}
body.mi-tema.tt2-modern.tt2-chips-plain .s-item-collection--metadata .tainacan-metadata-value:has(a[data-linkto="term"]) .multivalue-separator {
	display: none;
}
body.mi-tema.tt2-modern .s-item-collection--metadata :is(.metadata-type-textarea, .metadata-type-core_description) .tainacan-metadata-value {
	max-width: 72ch;
	font-family: inherit;
	font-size: 1rem;
	line-height: 1.6;
}

/* "Continue explorando" sem sombra, como antes. */
body.mi-tema.tt2-modern .tt2-aside {
	margin-top: 16px;
	border-radius: 12px;
	box-shadow: none;
}

/* ---------- Banner do topo (páginas, posts, buscas, listas) ---------- */

body.mi-tema.tt2-modern .page-header.header-filter:not(.page-header--image-full) {
	min-height: 0 !important;
	height: 400px;
	padding-block: 0;
	align-items: flex-end;
	background-blend-mode: normal;
	background-color: var(--mi-verde);
}
@media only screen and (max-width: 576px) {
	body.mi-tema.tt2-modern .page-header.header-filter:not(.page-header--image-full) {
		height: 200px;
	}
}
body.mi-tema.tt2-modern .page-header.header-filter:not(.page-header--image-full)::before {
	background: none;
}
body.mi-tema.tt2-modern .ph-title-description {
	max-width: none;
	margin: 0 0 3.75rem;
	padding-inline: 0 !important;
}
body.mi-tema.tt2-modern .page-header .ph-title-description .title-header h1 {
	font-size: 3rem !important;
	font-weight: 800 !important;
	line-height: 1.2 !important;
}
@media only screen and (max-width: 768px) {
	body.mi-tema.tt2-modern .page-header .ph-title-description .title-header h1 {
		font-size: 2rem !important;
		line-height: 2rem !important;
	}
}
@media only screen and (max-width: 576px) {
	body.mi-tema.tt2-modern .ph-title-description {
		margin-bottom: 1.5625rem;
	}
	body.mi-tema.tt2-modern .page-header .ph-title-description .title-header h1 {
		font-size: 1.5rem !important;
		line-height: 1.5rem !important;
	}
}

/* ---------- Rodapé: fio, margens e espaço da 3.0.3 ---------- */

body.mi-tema.tt2-modern footer.tainacan-footer {
	margin-top: 48px;
	padding: 48px 48px 0;
}
body.mi-tema.tt2-modern footer.tainacan-footer > hr.tainacan-footer-area-separator {
	display: block;
	margin: 16px 0;
}
body.mi-tema.tt2-modern footer.tainacan-footer .tainacan-footer-info {
	margin: 0 120px;
	padding: 16px 0 24px;
}
@media (max-width: 767.98px) {
	body.mi-tema.tt2-modern footer.tainacan-footer {
		padding: 24px 24px 0;
	}
	body.mi-tema.tt2-modern footer.tainacan-footer .tainacan-footer-info {
		margin: 0;
	}
}

/* ---------- Busca e blog com a coluna lateral: proporção da 3.0.3 ---------- */

@media (min-width: 992px) {
	body.mi-tema.tt2-modern.tt2-has-sidebar main > .row {
		grid-template-columns: minmax(0, 67fr) minmax(0, 22.7fr);
		column-gap: 10.3%;
	}
}

/* ---------- Página não encontrada: a tela inteira, como antes (texto legível) ---------- */

body.mi-tema.tt2-modern .page-header.page-404 {
	height: 100vh;
	min-height: 0 !important;
	align-items: center;
}

/* ---------- Cabeçalho de coleção em telas menores (medidas da 3.0.3) ---------- */

@media (max-width: 991.98px) {
	body.mi-tema.tt2-modern .tt2-head {
		--tt2-icon-size: 120px;
	}
	body.mi-tema.tt2-modern .tt2-head--left .tt2-head__body,
	body.mi-tema.tt2-modern .tt2-head--full .tt2-head__body {
		flex-direction: row;
		align-items: flex-start;
		gap: 71px;
	}
	body.mi-tema.tt2-modern .tt2-head__text {
		align-items: flex-start;
		text-align: start;
	}
	body.mi-tema.tt2-modern .tt2-head__title,
	body.mi-tema.tt2-modern h1.tt2-head__title {
		font-size: 18px !important;
		text-align: start;
	}
	body.mi-tema.tt2-modern .tt2-head__description,
	body.mi-tema.tt2-modern .tt2-head__description--plain {
		text-align: start;
	}
}
@media (max-width: 576px) {
	body.mi-tema.tt2-modern .tt2-head {
		--tt2-icon-size: 90px;
	}
	body.mi-tema.tt2-modern .tt2-head--left .tt2-head__body,
	body.mi-tema.tt2-modern .tt2-head--full .tt2-head__body {
		gap: 35px;
	}
	body.mi-tema.tt2-modern .tt2-head__banner {
		height: 330px;
	}
}

/* ---------- Página do Programa Dami: coluna de leitura de 72rem (functions.php) ---------- */

body.mi-tema.tt2-modern.mi-pagina-dami main.max-large.margin-one-column {
	box-sizing: border-box;
	width: min(var(--mi-dami-largura), calc(100% - 2 * var(--mi-dami-margem))) !important;
	max-width: none !important;
	margin-inline: auto !important;
	padding-inline: 0 !important;
}
