/* =========================================================================
   MegaBrain — enhance.css
   Regras que ligam as opções do tema ao front-end (consome as variáveis de
   inc/dynamic-css.php e classes do body adicionadas em functions.php).
   ========================================================================= */

/* ---- Cores do cabeçalho (opção) ---- */
body .mb-header{ background:var(--header-bg); }
body .mb-header__in{ color:var(--header-text); }
body .mb-header .mb-menu > li > a,
body .mb-brand__text,
body .mb-search{ color:var(--header-text); }
body .mb-search:hover{ color:var(--blue); }

/* ---- Raio dos botões (opção) ---- */
body .mb-btn,
body .mb-gov-btn,
body .mb-search{ border-radius:var(--btn-radius); }

/* ---- Peso dos títulos (opção) ---- */
.mb-prose h2, .mb-prose h3, .mb-article__title, .mb-card__title, .mb-page__title, .mb-head__title{ font-weight:var(--hw); }

/* ---- Altura da linha de leitura (opção) ---- */
.mb-prose{ line-height:var(--lh); }

/* ---- Largura do texto da matéria (opção) ---- */
.mb-single .mb-article,
.mb-single .mb-article__tags,
.mb-single .mb-comments{ max-width:var(--content-width); }

/* ---- Sombras desligadas (opção) ---- */
body.mb-noshadow{ --shadow:none; --shadow-lg:none; }

/* ---- Layout em caixa (boxed) ---- */
body.mb-layout-boxed{ background:var(--bg-soft-2); }
.mb-layout-boxed .mb-site{
	max-width:calc(var(--wrap) + 140px); margin:26px auto; background:var(--bg);
	border-radius:20px; overflow:hidden; box-shadow:var(--shadow-lg);
}
@media(max-width:1100px){ .mb-layout-boxed .mb-site{ margin:0; border-radius:0; } }

/* ---- Logo centralizado (opção) ---- */
.mb-head-center .mb-header__in{ flex-wrap:wrap; justify-content:center; text-align:center; height:auto; padding:14px 0; gap:10px 24px; }
.mb-head-center .mb-brand{ flex:1 0 100%; display:flex; justify-content:center; }
.mb-head-center .mb-nav{ flex:1 0 100%; display:flex; justify-content:center; }
.mb-head-center .mb-search{ position:absolute; right:0; top:16px; }

/* ---- Colunas de cards (home/arquivo) ---- */
body.mb-cols-2 .mb-grid--3{ grid-template-columns:repeat(2,minmax(0,1fr)); }
body.mb-cols-4 .mb-grid--3{ grid-template-columns:repeat(4,minmax(0,1fr)); }
@media(max-width:900px){ body.mb-cols-4 .mb-grid--3, body.mb-cols-3 .mb-grid--3{ grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:560px){ body[class*="mb-cols-"] .mb-grid--3{ grid-template-columns:1fr; } }

/* Override garantido por variável inline na própria grade (--mb-cols) */
.mb-grid[style*="--mb-cols"]{ grid-template-columns:repeat(var(--mb-cols,3),minmax(0,1fr)); }
@media(max-width:900px){ .mb-grid[style*="--mb-cols"]{ grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:560px){ .mb-grid[style*="--mb-cols"]{ grid-template-columns:1fr; } }

/* ---- Colunas do rodapé (opção) ---- */
body.mb-foot-2 .mb-footer__grid{ grid-template-columns:repeat(2,1fr); }
body.mb-foot-3 .mb-footer__grid{ grid-template-columns:1.4fr 1fr 1fr; }
@media(max-width:860px){ body[class*="mb-foot-"] .mb-footer__grid{ grid-template-columns:1fr 1fr; } }
@media(max-width:560px){ body[class*="mb-foot-"] .mb-footer__grid{ grid-template-columns:1fr; } }

/* ---- Variações do hero (primeira seção) ---- */
.mb-hero--solo .mb-lead{ min-height:520px; }
.mb-hero--duo .mb-grid--2, .mb-hero--quad .mb-grid--2{ gap:24px; }
@media(max-width:760px){ .mb-hero--solo .mb-lead{ min-height:360px; } }

/* ---- Ícones sociais ---- */
.mb-social{ display:flex; flex-wrap:wrap; gap:10px; margin-top:18px; }
.mb-social a{ width:38px; height:38px; border-radius:11px; display:grid; place-items:center;
	background:rgba(255,255,255,.08); color:#cdd9f0; transition:.16s; }
.mb-social a:hover{ background:var(--gold); color:var(--navy); transform:translateY(-2px); }
.mb-social svg{ width:18px; height:18px; }

/* ---- Barra de progresso de leitura ---- */
.mb-progress{ position:fixed; top:0; left:0; height:3px; width:0; z-index:300;
	background:linear-gradient(90deg,var(--blue),var(--gold)); transition:width .08s linear; }

/* ---- Voltar ao topo ---- */
.mb-totop{ position:fixed; right:22px; bottom:22px; width:46px; height:46px; border-radius:50%;
	background:var(--navy); color:#fff; border:0; cursor:pointer; display:grid; place-items:center;
	opacity:0; visibility:hidden; transform:translateY(12px); transition:.25s; z-index:120; box-shadow:var(--shadow-lg); }
.mb-totop.show{ opacity:1; visibility:visible; transform:none; }
.mb-totop:hover{ background:var(--blue); }
.mb-totop svg{ width:20px; height:20px; }
