/* ARLS Libertas 35 - estilo do site público */
:root {
  --azul: #184465;
  --azul-escuro: #0e2b42;
  --azul-claro: #e8f0f6;
  --ouro: #e39b18;
  --ouro-escuro: #b8780a;
  --texto: #1f2a33;
  --texto-suave: #5b6873;
  --fundo: #f4f6f8;
  --branco: #fff;
  --borda: #dde3e8;
  --raio: 10px;
  --sombra: 0 1px 2px rgba(14, 43, 66, .06), 0 4px 16px rgba(14, 43, 66, .06);
  --serif: Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 16px/1.6 var(--sans);
  color: var(--texto);
  background: var(--fundo);
}
img { max-width: 100%; height: auto; }
a { color: var(--azul); text-underline-offset: .15em; }
a:hover { color: var(--ouro-escuro); }
h1, h2, h3 { font-family: var(--serif); color: var(--azul-escuro); line-height: 1.25; margin: 0 0 .6em; }
h1 { font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.2rem); }
h2 { font-size: 1.35rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--ouro); outline-offset: 2px; }

.pular { position: absolute; left: -999px; top: 0; background: var(--azul-escuro); color: #fff; padding: .6em 1em; z-index: 100; }
.pular:focus { left: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- topo ---------- */
.topo { background: var(--branco); border-bottom: 4px solid var(--ouro); box-shadow: var(--sombra); }
.topo__marca { max-width: 1140px; margin: 0 auto; padding: 8px 16px 0; text-align: center; }
.topo__logo { display: inline-block; }
.topo__logo img { display: block; width: 760px; max-width: 100%; }

.menu { background: var(--azul); }
.menu__itens { list-style: none; margin: 0 auto; padding: 0 8px; display: flex; flex-wrap: wrap; justify-content: center; max-width: 1140px; }
.menu__itens a { display: block; padding: .8em 1em; color: #fff; text-decoration: none; font-weight: 500; letter-spacing: .01em; }
.menu__itens a:hover, .menu__itens a.ativo { background: var(--azul-escuro); color: #fff; box-shadow: inset 0 -3px 0 var(--ouro); }
.menu__botao { display: none; }

/* ---------- estrutura ---------- */
.pagina { max-width: 1140px; margin: 28px auto; padding: 0 16px; display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); }
.pagina--com-lateral { grid-template-columns: minmax(0, 1fr) 200px; }
.conteudo { background: var(--branco); border-radius: var(--raio); box-shadow: var(--sombra); padding: clamp(20px, 3vw, 40px); min-height: 50vh; }

.lateral__titulo { font: 600 .75rem/1 var(--sans); text-transform: uppercase; letter-spacing: .12em; color: var(--texto-suave); margin: 4px 0 12px; }
.banners { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.banners li { background: var(--branco); border-radius: 8px; box-shadow: var(--sombra); padding: 8px; text-align: center; }
.banners img { display: block; margin: 0 auto; max-height: 120px; object-fit: contain; }

/* ---------- componentes ---------- */
.introducao { color: var(--texto-suave); font-size: 1.05rem; }
.vazio { color: var(--texto-suave); background: var(--fundo); padding: 1.2em; border-radius: 8px; text-align: center; }
.contagem, .data { color: var(--texto-suave); font-size: .95rem; }
.trilha { margin-bottom: .8em; font-size: .95rem; }
.trilha a { text-decoration: none; }
.titulo-acoes { display: flex; justify-content: space-between; align-items: baseline; gap: 1em; flex-wrap: wrap; }
.titulo-acoes a { font-size: .9rem; }

.botao { display: inline-block; background: var(--azul); color: #fff; border: 0; border-radius: 8px; padding: .7em 1.3em; font: 600 1rem var(--sans); cursor: pointer; text-decoration: none; transition: background .15s; }
.botao:hover { background: var(--azul-escuro); color: #fff; }
.botao--secundario { background: var(--azul-claro); color: var(--azul-escuro); }
.botao--secundario:hover { background: #d4e3ee; color: var(--azul-escuro); }

.alerta { border-radius: 8px; padding: .9em 1.1em; margin-bottom: 1.2em; border-left: 5px solid; }
.alerta ul { margin: 0; padding-left: 1.2em; }
.alerta--ok { background: #eaf7ee; border-color: #2e8b57; color: #1d5c39; }
.alerta--erro { background: #fdecec; border-color: #c0392b; color: #85261c; }
.alerta--aviso { background: #fff6e0; border-color: var(--ouro); color: #6d4a06; }

.destaque { border-bottom: 1px solid var(--borda); padding-bottom: 1.2em; margin-bottom: 1.6em; }
.texto-rico { overflow-wrap: anywhere; }
.texto-rico img { border-radius: 6px; }
.texto-rico table { border-collapse: collapse; max-width: 100%; }
.texto-rico td, .texto-rico th { border: 1px solid var(--borda); padding: .4em .6em; }
.texto-rico iframe { max-width: 100%; }

.secao { margin-top: 2em; }
.secao__cabecalho { display: flex; justify-content: space-between; align-items: baseline; border-bottom: 2px solid var(--ouro); margin-bottom: 1em; }
.secao__cabecalho h2 { margin-bottom: .3em; }

/* cartões de evento */
.cartoes { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.cartao-evento { display: flex; gap: 14px; align-items: center; padding: 14px; border: 1px solid var(--borda); border-radius: var(--raio); text-decoration: none; color: inherit; background: var(--branco); transition: transform .15s, box-shadow .15s, border-color .15s; }
.cartao-evento:hover { transform: translateY(-2px); box-shadow: var(--sombra); border-color: var(--ouro); color: inherit; }
.selo-data { flex: 0 0 62px; height: 66px; border-radius: 8px; background: var(--azul); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; }
.selo-data__dia { font: 700 1.6rem var(--serif); }
.selo-data__mes { font-size: .75rem; letter-spacing: .1em; color: #ffd27a; margin-top: 4px; }
.cartao-evento__corpo { display: flex; flex-direction: column; min-width: 0; }
.cartao-evento__titulo { font-weight: 700; color: var(--azul-escuro); }
.cartao-evento__info { font-size: .9rem; color: var(--texto-suave); }

.busca { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 1em 0 1.4em; }
.busca input { flex: 1 1 240px; }

/* detalhe */
.ficha { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; background: var(--fundo); border-radius: var(--raio); padding: 16px; margin: 0 0 1.2em; }
.ficha dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--texto-suave); }
.ficha dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.cartaz { margin: 1.5em 0 0; text-align: center; }
.cartaz img { border-radius: 8px; box-shadow: var(--sombra); }

/* história */
.linha-tempo { list-style: none; margin: 0; padding: 0 0 0 22px; border-left: 3px solid var(--azul-claro); }
.linha-tempo li { position: relative; padding: 0 0 1.4em 10px; }
.linha-tempo li::before { content: ""; position: absolute; left: -32px; top: .45em; width: 14px; height: 14px; border-radius: 50%; background: var(--ouro); border: 3px solid var(--branco); box-shadow: 0 0 0 2px var(--ouro); }
.linha-tempo time { font-size: .85rem; color: var(--texto-suave); }
.linha-tempo h2 { font-size: 1.2rem; margin: .1em 0 .3em; }
.linha-tempo h2 a { text-decoration: none; }

/* recados */
.recados { display: grid; gap: 14px; }
.recado { border: 1px solid var(--borda); border-radius: var(--raio); padding: 16px 18px; }
.recado header { display: flex; justify-content: space-between; gap: 1em; flex-wrap: wrap; margin-bottom: .4em; }
.recado time { color: var(--texto-suave); font-size: .85rem; }
.recado__resposta { margin-top: .8em; background: var(--azul-claro); border-radius: 8px; padding: .7em 1em; }
.recado__resposta span { display: block; font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--azul); font-weight: 700; }

/* formulários */
.formulario { margin-top: 2em; border-top: 1px solid var(--borda); padding-top: 1.5em; }
.contato .formulario { margin-top: 0; border-top: 0; padding-top: 0; }
form label { display: block; font-weight: 600; margin-bottom: 1em; font-size: .95rem; }
form label small { font-weight: 400; color: var(--texto-suave); }
input[type=text], input[type=email], input[type=tel], input[type=search], input[type=password], textarea, select {
  display: block; width: 100%; margin-top: .35em; padding: .65em .8em; font: 1rem var(--sans); color: var(--texto);
  background: #fff; border: 1px solid #c8d1d9; border-radius: 8px; transition: border-color .15s, box-shadow .15s;
}
.busca input { margin-top: 0; }
input:focus, textarea:focus, select:focus { border-color: var(--azul); box-shadow: 0 0 0 3px rgba(24, 68, 101, .15); outline: none; }
.campos-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 16px; }
.obrig { color: #c0392b; }
.nota { font-size: .9rem; color: var(--texto-suave); }

.contato { display: grid; grid-template-columns: 260px 1fr; gap: 32px; align-items: start; }
.contato__endereco { font-style: normal; background: var(--fundo); border-radius: var(--raio); padding: 18px; line-height: 1.7; }
.contato__endereco strong { display: block; font-family: var(--serif); color: var(--azul-escuro); font-size: 1.1rem; }
.contato__endereco .botao { margin-top: .8em; }

.caixa-login { max-width: 420px; margin: 2em auto; text-align: center; }
.caixa-login form { text-align: left; }
.caixa-login .botao { width: 100%; }

/* galerias */
.galerias { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); }
.galeria { display: flex; flex-direction: column; text-decoration: none; color: inherit; border-radius: var(--raio); overflow: hidden; background: var(--branco); border: 1px solid var(--borda); transition: transform .15s, box-shadow .15s; }
.galeria:hover { transform: translateY(-3px); box-shadow: var(--sombra); color: inherit; }
.galeria__capa { aspect-ratio: 4 / 3; background: var(--azul-claro); display: block; overflow: hidden; }
.galeria__capa img { width: 100%; height: 100%; object-fit: cover; display: block; }
.galeria__titulo { font-weight: 700; padding: 10px 12px 0; color: var(--azul-escuro); }
.galeria__info { font-size: .85rem; color: var(--texto-suave); padding: 0 12px 12px; }

.grade-fotos { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.grade-fotos a { display: block; border-radius: 6px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--azul-claro); }
.grade-fotos img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s; }
.grade-fotos a:hover img { transform: scale(1.05); }

.videos { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.video { text-decoration: none; color: inherit; }
.video__capa { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: var(--raio); overflow: hidden; background: var(--azul); }
.video__capa img { width: 100%; height: 100%; object-fit: cover; display: block; }
.video__play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 2.2rem; color: #fff; text-shadow: 0 2px 10px rgba(0,0,0,.5); }
.video__titulo { display: block; font-weight: 600; margin-top: .5em; color: var(--azul-escuro); }

.campanhas { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); align-items: center; }
.campanhas li { text-align: center; }
.campanhas img { border-radius: 6px; }

.paginacao ul { list-style: none; margin: 1.6em 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.paginacao a, .paginacao span { display: block; min-width: 2.4em; padding: .45em .8em; border-radius: 8px; text-align: center; text-decoration: none; border: 1px solid var(--borda); }
.paginacao span[aria-current] { background: var(--azul); color: #fff; border-color: var(--azul); }
.paginacao .reticencias { padding: .45em .2em; color: var(--texto-suave); }

.erro { text-align: center; padding: 2em 0; }
.erro__codigo { font: 700 4rem/1 var(--serif); color: var(--ouro); margin: 0 0 .2em; }
.erro__detalhe { text-align: left; background: #222; color: #eee; padding: 1em; border-radius: 8px; overflow: auto; font-size: .8rem; }

/* Obreiro Livre */
.ol-cabecalho { text-align: center; margin-bottom: 1.6em; }
.ol-cabecalho h1 { font-size: clamp(2rem, 1.4rem + 2.5vw, 3rem); margin-bottom: .2em; }
.ol-sobretitulo { text-transform: uppercase; letter-spacing: .14em; font-size: .78rem; color: var(--ouro-escuro); font-weight: 700; margin: 0; }
.ol-atual { display: grid; grid-template-columns: minmax(180px, 280px) 1fr; gap: 28px; align-items: center; background: linear-gradient(135deg, var(--azul-escuro), var(--azul)); color: #dbe6ee; border-radius: var(--raio); padding: 24px; }
.ol-atual h2 { color: #fff; font-size: 1.8rem; margin: .3em 0 .2em; }
.ol-atual .data { color: #c9d6e0; }
.ol-tema { font: italic 1.25rem var(--serif); color: #ffd27a; margin: 0 0 .4em; }
.ol-atual__capa img { display: block; width: 100%; border-radius: 6px; box-shadow: 0 12px 30px rgba(0,0,0,.4); transition: transform .2s; }
.ol-atual__capa:hover img { transform: scale(1.02); }
.ol-atual .botao { background: var(--ouro); color: var(--azul-escuro); margin: 0 6px 6px 0; }
.ol-atual .botao:hover { background: #f2b23c; }
.ol-atual .botao--secundario { background: rgba(255,255,255,.14); color: #fff; }
.ol-atual .botao--secundario:hover { background: rgba(255,255,255,.25); color: #fff; }
.ol-selo { display: inline-block; background: var(--ouro); color: var(--azul-escuro); font-weight: 700; font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; padding: .25em .7em; border-radius: 99px; }
.ol-filtro input { margin: 0 0 .4em; width: 220px; padding: .45em .7em; }
.ol-grupo { margin-bottom: 1.6em; }
.ol-grupo h3 { font-size: 1.05rem; margin: 0 0 .6em; }
.ol-grupo h3 small { display: block; font: 400 .9rem var(--sans); color: var(--texto-suave); }
.ol-edicoes { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px 16px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.ol-edicoes li[hidden] { display: none; }
.ol-edicoes a { display: block; text-decoration: none; color: inherit; }
.ol-capa { display: block; aspect-ratio: 7 / 10; border-radius: 6px; overflow: hidden; background: var(--azul-claro); box-shadow: var(--sombra); transition: transform .15s, box-shadow .15s; }
.ol-capa img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ol-capa__vazia { display: flex; height: 100%; align-items: center; justify-content: center; font: 700 1.4rem var(--serif); color: var(--azul); }
.ol-edicoes a:hover .ol-capa { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(14, 43, 66, .18); }
.ol-numero { display: block; font-weight: 700; color: var(--azul-escuro); margin-top: .45em; font-size: .95rem; }
.ol-meta { display: block; font-size: .8rem; color: var(--texto-suave); line-height: 1.35; }

/* ---------- rodapé ---------- */
.rodape { background: var(--azul-escuro); color: #c9d6e0; margin-top: 40px; font-size: .95rem; }
.rodape a { color: #fff; }
.rodape__conteudo { max-width: 1140px; margin: 0 auto; padding: 28px 16px 12px; display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.rodape__conteudo strong { color: #fff; font-family: var(--serif); font-size: 1.05rem; }
.rodape__links { list-style: none; margin: 0; padding: 0; }
.rodape__links li { margin-bottom: .4em; }
.rodape__copy { text-align: center; margin: 0; padding: 12px 16px 20px; border-top: 1px solid rgba(255,255,255,.1); font-size: .85rem; }

/* ---------- lightbox ---------- */
.lb { position: fixed; inset: 0; background: rgba(5, 15, 25, .94); z-index: 1000; display: flex; align-items: center; justify-content: center; }
.lb[hidden] { display: none; }
.lb__img { max-width: 94vw; max-height: 86vh; object-fit: contain; box-shadow: 0 10px 40px rgba(0,0,0,.6); border-radius: 4px; user-select: none; }
.lb__legenda { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: #dbe4ea; font-size: .95rem; }
.lb button { position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0; border-radius: 50%; width: 48px; height: 48px; font-size: 1.5rem; cursor: pointer; }
.lb button:hover { background: rgba(255,255,255,.25); }
.lb__fechar { top: 14px; right: 14px; }
.lb__play { top: 14px; right: 72px; font-size: 1rem !important; }
.lb__ant { left: 14px; top: 50%; transform: translateY(-50%); }
.lb__prox { right: 14px; top: 50%; transform: translateY(-50%); }
body.lb-aberto { overflow: hidden; }

/* ---------- responsivo ---------- */
@media (max-width: 900px) {
  .pagina--com-lateral { grid-template-columns: minmax(0, 1fr); }
  .banners { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
  .contato { grid-template-columns: 1fr; }
  .ol-atual { grid-template-columns: 1fr; text-align: center; }
  .ol-atual__capa { max-width: 260px; margin: 0 auto; }
}
@media (max-width: 700px) {
  .menu__botao { display: flex; align-items: center; gap: .6em; width: 100%; background: none; border: 0; color: #fff; font: 600 1rem var(--sans); padding: .85em 16px; cursor: pointer; }
  .menu__icone, .menu__icone::before, .menu__icone::after { display: block; width: 22px; height: 2px; background: #fff; position: relative; }
  .menu__icone::before, .menu__icone::after { content: ""; position: absolute; }
  .menu__icone::before { top: -7px; } .menu__icone::after { top: 7px; }
  .menu__itens { display: none; flex-direction: column; padding: 0 0 8px; }
  .menu.aberto .menu__itens { display: flex; }
  .menu__itens a { padding: .75em 16px; }
  .pagina { margin: 14px auto; gap: 18px; padding: 0 10px; }
  .grade-fotos { grid-template-columns: repeat(3, 1fr); gap: 4px; }
  .lb__ant, .lb__prox { top: auto; bottom: 50px; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
@media print {
  .menu, .lateral, .rodape, .busca, .formulario { display: none; }
  .conteudo { box-shadow: none; }
}
