/* =========================================================
   Colégio Imaculado Coração de Maria — Design System
   ========================================================= */


:root {
  /* Palette — extraída do brasão e dos banners oficiais */
  --navy:        #0d1c39;
  --navy-2:      #16294f;
  --navy-3:      #1f3a6e;
  --maroon:      #7a1f2c;
  --maroon-2:    #96222e;
  --gold:        #b8923f;
  --gold-light:  #d9be82;
  --parchment:   #f4ead0;
  --parchment-2: #ece0bf;
  --paper:       #fbf6e9;
  --ink:         #26201a;
  --ink-soft:    #4d4436;
  --white:       #fffdf7;

  --font-display: 'Cormorant Garamond', 'Georgia', serif;
  --font-body:    'Lora', 'Georgia', serif;

  --max-width: 1180px;
  --gutter: clamp(1.25rem, 4vw, 3rem);

  --rule: 1px solid rgba(184, 146, 63, 0.45);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip; /* nunca deixa o conteúdo vazar para fora da janela */
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--navy);
  line-height: 1.15;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); font-weight: 700; }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.6rem); }

p { margin: 0 0 1.1em; max-width: 66ch; text-align: justify; text-justify: inter-word; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section {
  padding: clamp(3.5rem, 7vw, 6rem) 0;
}

.section--navy {
  background: var(--navy);
  background-image: radial-gradient(ellipse at top left, var(--navy-3) 0%, var(--navy) 55%);
  color: var(--parchment);
}
.section--navy h2, .section--navy h3 { color: var(--white); }
.section--navy p { color: rgba(244, 234, 208, 0.86); }

.section--parchment { background: var(--parchment); }

/* Kicker / eyebrow used sparingly — only when labeling a category, not decoration */
.kicker {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--maroon-2);
  letter-spacing: 0.02em;
  display: block;
  margin-bottom: 0.4em;
}
.section--navy .kicker { color: var(--gold-light); }

/* Ornamental divider — small fleur mark, echoes the banner artwork */
.divider {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin: 1.4rem 0 1.8rem;
}
.divider::before, .divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
}
.divider svg { flex-shrink: 0; width: 16px; height: 16px; color: var(--gold); }
.divider--left { justify-content: flex-start; }
.divider--left::after { flex: 1; }
.divider--left::before { display: none; }

/* =============== Buttons =============== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-body);
  font-size: 0.96rem;
  font-weight: 600;
  padding: 0.85rem 1.7rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color .25s ease, color .25s ease, border-color .25s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--maroon);
  color: var(--white);
  border-color: var(--maroon);
}
.btn-primary:hover { background: var(--maroon-2); }

.btn-gold {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
}
.btn-gold:hover { background: var(--gold-light); }

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: rgba(244, 234, 208, 0.55);
}
.btn-outline:hover { border-color: var(--gold-light); color: var(--gold-light); }

.btn-outline-dark {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn-outline-dark:hover { background: var(--navy); color: var(--white); }

/* =========================================================
   Header
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  border-bottom: 2px solid var(--gold);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 0.7rem;
  padding-bottom: 0.7rem;
  max-width: 1600px; /* cabeçalho mais largo que o corpo: em telas grandes o menu + botão sempre cabem */
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-shrink: 1;
  min-width: 0;
}
.brand img { width: 52px; height: 52px; flex-shrink: 0; }
.brand-text {
  font-family: var(--font-display);
  line-height: 1.15;
  min-width: 0;
}
.brand-text .name-top {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: 0.01em;
}
.brand-text .name-bottom {
  display: block;
  font-size: 0.78rem;
  font-style: italic;
  color: var(--gold-light);
}
/* Acima do ponto de quebra do menu (desktop, com o menu horizontal
   completo visível): protege o nome do Colégio para nunca ser
   espremido pelo menu — ele fica sempre em uma linha só */
@media (min-width: 1211px) {
  .brand { flex-shrink: 0; }
  .brand-text { white-space: nowrap; }
  .main-nav { flex-shrink: 0; }
}

.main-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.8rem, 1.1vw, 1.05rem);
}
.main-nav > a {
  font-size: 0.93rem;
  color: rgba(244, 234, 208, 0.9);
  padding: 0.3rem 0.1rem;
  border-bottom: 1px solid transparent;
  transition: color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.main-nav > a:hover,
.main-nav > a[aria-current="page"] {
  color: var(--gold-light);
  border-color: var(--gold);
}

/* ---- Submenus (Formações / Contribua) ---- */
.nav-dropdown { position: relative; }
.nav-dropdown > summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.93rem;
  color: rgba(244, 234, 208, 0.9);
  padding: 0.3rem 0.1rem;
  border-bottom: 1px solid transparent;
  white-space: nowrap;
}
.nav-dropdown > summary::-webkit-details-marker { display: none; }
.nav-dropdown > summary::after {
  content: "▾";
  font-size: 0.65em;
  color: var(--gold);
  transition: transform .2s ease;
}
.nav-dropdown[open] > summary::after { transform: rotate(180deg); }
.nav-dropdown:hover > summary,
.nav-dropdown.is-active-group > summary { color: var(--gold-light); border-color: var(--gold); }

.nav-dropdown-menu {
  display: flex;
  flex-direction: column;
  background: var(--navy);
  border: 1px solid var(--gold);
  min-width: 230px;
  padding: 0.4rem 0;
  z-index: 60;
}
.nav-dropdown-menu a {
  display: block;
  padding: 0.6rem 1.1rem;
  font-size: 0.9rem;
  color: rgba(244, 234, 208, 0.88);
}
.nav-dropdown-menu a:hover,
.nav-dropdown-menu a[aria-current="page"] { color: var(--gold-light); background: rgba(184,146,63,0.12); }

/* ---- Variante "linkada": o próprio rótulo é um link (ex.: Formações) ---- */
.nav-dropdown-linked { position: relative; }
.nav-dropdown-linked > a {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.93rem;
  color: rgba(244, 234, 208, 0.9);
  padding: 0.3rem 0.1rem;
  border-bottom: 1px solid transparent;
  white-space: nowrap;
}
.nav-dropdown-linked > a .caret { font-size: 0.65em; color: var(--gold); }
.nav-dropdown-linked > a:hover,
.nav-dropdown-linked > a[aria-current="page"] { color: var(--gold-light); border-color: var(--gold); }
.nav-dropdown-linked.is-active-group > a { color: var(--gold-light); border-color: var(--gold); }
.nav-dropdown-linked .nav-dropdown-menu { display: none; }

@media (min-width: 1211px) {
  .nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    box-shadow: 0 12px 24px rgba(0,0,0,0.3);
  }
  .nav-dropdown-linked:hover .nav-dropdown-menu,
  .nav-dropdown-linked.is-open .nav-dropdown-menu { display: flex; }
  /* "Ponte" invisível que cobre o espaço entre o link e o menu, para o
     mouse não "perder" o hover ao descer até a lista */
  .nav-dropdown-linked::after {
    content: "";
    position: absolute;
    left: 0;
    top: 100%;
    width: 100%;
    height: 10px;
  }
}
@media (max-width: 1210px) {
  .nav-dropdown-menu { border: none; background: none; padding: 0.3rem 0 0.3rem 1rem; }
  .nav-dropdown-menu a { padding: 0.45rem 0; }
  .nav-dropdown-linked .nav-dropdown-menu { display: flex; }
}

.header-actions { display: flex; align-items: center; gap: 1rem; flex-shrink: 0; }
.header-actions .btn-gold {
  gap: 0.45rem;
  padding: 0.5rem 1.05rem;   /* botão compacto: mesma altura visual do menu */
  font-size: 0.88rem;
  line-height: 1.2;
}
.header-actions .btn-gold svg { width: 16px; height: 16px; flex-shrink: 0; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--gold);
  color: var(--gold-light);
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.nav-toggle svg { width: 20px; height: 20px; }

@media (max-width: 1210px) {
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--navy);
    border-bottom: 2px solid var(--gold);
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem var(--gutter) 1.5rem;
    gap: 0.9rem;
    display: none;
  }
  .main-nav.is-open { display: flex; }
  .nav-toggle { display: inline-flex; }
  .header-actions .btn-gold-label { display: none; }
  .header-actions .btn-gold svg { display: block; }
  .header-actions .btn-gold { padding: 0.7rem; }
}

@media (max-width: 480px) {
  .brand-text .name-bottom { display: none; }
  .brand-text .name-top { font-size: 0.88rem; }
  .brand img { width: 42px; height: 42px; }
  .site-header .container { gap: 0.8rem; }
}

/* =========================================================
   Hero carousel (banners oficiais)
   ========================================================= */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--navy);
}
.hero-track {
  display: flex;
  transition: transform .7s cubic-bezier(.65,0,.35,1);
}
.hero-slide {
  min-width: 100%;
  aspect-ratio: 1920 / 640;
}
.hero-slide img { width: 100%; height: 100%; object-fit: cover; }

.hero-dots {
  position: absolute;
  bottom: clamp(0.8rem, 3vw, 1.6rem);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.6rem;
}
.hero-dots button {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1px solid var(--gold-light);
  background: rgba(244, 234, 208, 0.25);
  padding: 0;
  cursor: pointer;
}
.hero-dots button[aria-current="true"] { background: var(--gold-light); }

.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(13, 28, 57, 0.55);
  border: 1px solid var(--gold);
  color: var(--gold-light);
  width: 40px;
  height: 40px;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.hero:hover .hero-arrow { display: flex; }
.hero-arrow.prev { left: 1rem; }
.hero-arrow.next { right: 1rem; }
.hero-arrow svg { width: 18px; height: 18px; }

/* Ribbon strip under the hero — classical-education statement */
.ribbon {
  background: var(--navy-2);
  border-bottom: 2px solid var(--gold);
  padding: 1.1rem 0;
  text-align: center;
}
.ribbon p {
  margin: 0;
  max-width: none;
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--gold-light);
  letter-spacing: 0.01em;
}
/* Só no mobile: a frase é longa e, no tamanho padrão, quebra em duas
   linhas de forma desarmônica. Reduz suavemente conforme a tela
   estreita, o suficiente para caber em uma linha só. */
@media (max-width: 600px) {
  .ribbon p {
    font-size: clamp(0.5625rem, calc(2.92vw - 1.5px), 1rem);
    letter-spacing: 0;
  }
}
.ribbon p strong {
  font-style: normal;
  font-weight: 700;
  color: var(--white);
}

/* Simple page hero (subpages) */
.page-hero {
  position: relative;
  background: var(--navy);
  color: var(--white);
}
.page-hero img { width: 100%; height: 100%; object-fit: cover; opacity: 0.9; }
.page-hero .aspect { aspect-ratio: 1920 / 640; }

/* Text-only page hero, for pages without a dedicated banner image */
.page-hero-plain {
  background: var(--navy);
  background-image: radial-gradient(ellipse at top left, var(--navy-3) 0%, var(--navy) 60%);
  border-bottom: 3px solid var(--gold);
  padding: clamp(3rem, 8vw, 5rem) 0 clamp(2.4rem, 6vw, 3.6rem);
  text-align: center;
  color: var(--white);
}
.page-hero-plain .kicker { color: var(--gold-light); }
.page-hero-plain h1 { color: var(--white); }
.page-hero-plain .lede { color: rgba(244,234,208,0.85); margin-left: auto; margin-right: auto; }
.page-hero-plain .divider { justify-content: center; max-width: 300px; margin-left: auto; margin-right: auto; }

/* Hero das páginas de Formações — título + gravura completa, sem cortes */
.page-hero-illustration .illustration-wrap {
  max-width: 920px;
  margin: 2rem auto 0;
  border: 1px solid rgba(184, 146, 63, 0.5);
  padding: 0.6rem;
  background: rgba(0,0,0,0.15);
}
.page-hero-illustration .illustration-wrap img { width: 100%; height: auto; display: block; }

/* =========================================================
   Intro / split layout
   ========================================================= */
.split {
  display: grid;
  grid-template-columns: 0.85fr 1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.split.reverse { grid-template-columns: 1fr 0.85fr; }
.split.reverse .split-media { order: 2; }
.text-justify p { text-align: justify; }
.text-justify .lede { text-align: justify; }
.split-media {
  position: relative;
  border: var(--rule);
  padding: 0.6rem;
  background: var(--paper);
}
.split-media img { width: 100%; height: 100%; object-fit: cover; }
.split-media::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid var(--gold);
  pointer-events: none;
}

/* Variante usada em Adote um Aluno: a imagem estica para acompanhar
   exatamente a altura do texto ao lado (qualquer que seja o tamanho da tela).
   A imagem é posicionada de forma absoluta para não "ditar" a altura da
   linha com sua própria proporção — quem manda na altura é o texto. */
.split--stretch { align-items: stretch; grid-template-columns: 1.6fr 1fr; }
.split--stretch .split-media { height: 100%; position: relative; }
.split--stretch .split-media img {
  position: absolute;
  inset: 0.6rem;
  width: calc(100% - 1.2rem);
  height: calc(100% - 1.2rem);
  object-fit: cover;
}

@media (max-width: 860px) {
  .split, .split.reverse { grid-template-columns: 1fr; }
  .split.reverse .split-media { order: 0; }
  .split--stretch .split-media { height: auto; }
  .split--stretch .split-media img {
    position: static;
    width: 100%;
    height: auto;
    inset: auto;
  }
}

/* =========================================================
   Pillars (símbolos do brasão)
   ========================================================= */
.pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 2.5rem;
  border-top: var(--rule);
}
.pillar {
  padding: 2.1rem 1.4rem 1.6rem;
  border-right: var(--rule);
  text-align: left;
}
.pillar:last-child { border-right: none; }
.pillar svg {
  width: 34px;
  height: 34px;
  color: var(--gold);
  margin: 0 auto 1rem;
  display: block;
}
.pillar h3 { font-size: 1.15rem; margin-bottom: 0.4em; text-align: center; }
.pillar p { font-size: 0.94rem; color: var(--ink-soft); margin-bottom: 0; }
.section--navy .pillar p { color: rgba(244, 234, 208, 0.8); }

@media (max-width: 860px) {
  .pillars { grid-template-columns: 1fr 1fr; }
  .pillar { border-bottom: var(--rule); }
  .pillar:nth-child(2n) { border-right: none; }
}
@media (max-width: 520px) {
  .pillars { grid-template-columns: 1fr; }
}

/* =========================================================
   Timeline (Quem Somos)
   ========================================================= */
.timeline { position: relative; margin: 2.5rem auto 0; max-width: 740px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 84px;
  top: 6px;
  bottom: 6px;
  width: 1px;
  background: linear-gradient(to bottom, var(--gold), rgba(184,146,63,0.15));
}
.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: clamp(1.2rem, 3vw, 2.5rem);
  padding-bottom: 3rem;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-year {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--maroon);
  text-align: right;
  position: relative;
}
.timeline-year::after {
  content: "";
  position: absolute;
  right: -33px;
  top: 8px;
  width: 11px;
  height: 11px;
  background: var(--paper);
  border: 2px solid var(--gold);
  border-radius: 50%;
}
.timeline-content h3 { margin-bottom: 0.5em; }
.timeline-content p { color: var(--ink-soft); }

@media (max-width: 640px) {
  .timeline::before { left: 34px; }
  .timeline-item { grid-template-columns: 34px 1fr; }
  .timeline-year { font-size: 0; }
  .timeline-year::after { right: -18px; }
}

/* =========================================================
   Gallery (Quem Somos)
   ========================================================= */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
  margin-top: 1rem;
}
.gallery figure {
  margin: 0;
}
.gallery .gallery-img {
  overflow: hidden;
  border: var(--rule);
  cursor: zoom-in;
}
.gallery img { width: 100%; height: auto; display: block; }
.gallery figcaption {
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-top: 0.5rem;
  text-align: center;
}
@media (max-width: 760px) {
  .gallery { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .gallery { grid-template-columns: 1fr; }
}

/* Visualizador em tela cheia (lightbox) — abre ao clicar em qualquer
   foto de uma galeria (notícias e Nossa Sede) */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(13, 28, 57, 0.94);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
}
.lightbox-overlay.is-open { display: flex; }
.lightbox-overlay img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border: 5px solid var(--paper);
  box-shadow: 0 25px 70px rgba(0,0,0,0.55);
}
.lightbox-close {
  position: absolute;
  top: 1.2rem;
  right: 1.5rem;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.4);
  color: var(--white);
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease;
}
.lightbox-close:hover { background: rgba(255,255,255,0.28); }
@media (max-width: 560px) {
  .lightbox-overlay { padding: 4.5rem 1rem 1.5rem; }
  .lightbox-close { top: 0.8rem; right: 0.8rem; width: 40px; height: 40px; }
}

/* =========================================================
   Panels / plaques (donation teasers, causes)
   ========================================================= */
.panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.8rem;
  margin-top: 2rem;
}
.panel {
  border: 1px solid rgba(184, 146, 63, 0.55);
  background: rgba(255, 253, 247, 0.03);
  display: flex;
  flex-direction: column;
}
.section--parchment .panel { background: var(--paper); }
.panel-media { aspect-ratio: 1 / 1; overflow: hidden; }
.panel-media img { width: 100%; height: 100%; object-fit: cover; }
.panel-body { padding: 1.8rem 1.9rem 2rem; flex: 1; display: flex; flex-direction: column; }
.panel-body h3 { margin-bottom: 0.5em; text-align: center; }
.panel-body p { color: inherit; opacity: 0.92; font-size: 0.97rem; flex: 1; }
.panel-body .btn { align-self: flex-start; margin-top: 0.6rem; }

@media (max-width: 760px) {
  .panels { grid-template-columns: 1fr; }
}

/* Celular: mantém as duas causas lado a lado, em cartões compactos,
   em vez de empilhar em largura total (só nesta faixa de tela estreita) */
@media (max-width: 560px) {
  .panels { grid-template-columns: 1fr 1fr; gap: 0.8rem; }
  .panel-body { padding: 1rem 0.9rem 1.1rem; }
  .panel-body h3 { font-size: 0.92rem; margin-bottom: 0.35em; }
  .panel-body p { display: none; }
  .panel-body .btn {
    align-self: stretch;
    justify-content: center;
    text-align: center;
    font-size: 0.76rem;
    padding: 0.55rem 0.6rem;
    margin-top: 0.5rem;
  }
}

/* =========================================================
   Formações (ofertas) — grid de 4 cartões
   ========================================================= */
.offerings {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  margin-top: 2rem;
}
.offering-card {
  display: block;
  background: var(--paper);
  border: 1px solid rgba(184, 146, 63, 0.5);
  padding: 0;
  overflow: hidden;
  transition: border-color .2s ease, transform .2s ease;
  text-align: center;
}
.offering-card:hover { border-color: var(--maroon); transform: translateY(-3px); }
.offering-media { width: 100%; aspect-ratio: 1400 / 763; overflow: hidden; background: var(--parchment-2); }
.offering-media svg, .offering-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.offering-body { padding: 1.5rem 1.5rem 1.8rem; }
.section--navy .offering-card h3 { color: var(--navy); }
.offering-card h3 { font-size: 1.1rem; margin-bottom: 0.4em; }
.offering-card p { font-size: 0.92rem; color: var(--ink-soft); margin-bottom: 0.9em; }
.offering-card .link-arrow {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--maroon);
}
.offering-card:hover .link-arrow { color: var(--maroon-2); }

@media (max-width: 900px) {
  .offerings { grid-template-columns: 1fr 1fr; }
}
/* Celular: em vez de empilhar os 6 cartões (rolagem vertical longa),
   vira um carrossel horizontal — arrasta com o dedo, mostrando todos */
@media (max-width: 560px) {
  .offerings {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 1rem;
    margin: 2rem calc(-1 * var(--gutter)) 0;
    padding: 0 var(--gutter) 0.6rem;
  }
  .offerings::-webkit-scrollbar { display: none; }
  .offering-card { flex: 0 0 76%; scroll-snap-align: start; }
}

/* Utilitário: elemento visível apenas no celular */
.mobile-only-btn { display: none; }
@media (max-width: 560px) {
  .mobile-only-btn { display: block; }
}

/* =========================================================
   Notícias
   ========================================================= */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.8rem;
  margin-top: 2rem;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}
.news-card {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid rgba(184, 146, 63, 0.4);
}
.section--navy .news-card { background: var(--navy-2); border-color: rgba(184,146,63,0.35); }
.news-card-media { aspect-ratio: 16/10; overflow: hidden; background: var(--parchment-2); }
.news-card-media img { width: 100%; height: 100%; object-fit: cover; }
.news-card-body { padding: 1.4rem 1.5rem 1.6rem; flex: 1; display: flex; flex-direction: column; }
.news-card-date {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 0.85rem;
  color: var(--maroon-2);
  margin-bottom: 0.5em;
}
.section--navy .news-card-date { color: var(--gold-light); }
.news-card-body h3 { font-size: 1.12rem; margin-bottom: 0.5em; }
.news-card-body p { font-size: 0.92rem; color: var(--ink-soft); flex: 1; }
.section--navy .news-card-body p { color: rgba(244,234,208,0.8); }
.news-card-body .link-arrow {
  font-weight: 600;
  font-size: 0.87rem;
  color: var(--maroon);
  align-self: flex-start;
  margin-top: -0.1rem;      /* 0.4rem originais − 0.5rem de área de toque */
}
.section--navy .news-card-body .link-arrow { color: var(--gold-light); }

@media (max-width: 900px) {
  .news-grid { grid-template-columns: 1fr 1fr; }
}
/* Celular: mesmo tratamento de carrossel horizontal das Formações —
   mas só na prévia da home; a listagem completa (.news-grid--list)
   continua empilhada normalmente, para facilitar navegar por todas */
@media (max-width: 560px) {
  .news-grid:not(.news-grid--list) {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 1rem;
    margin: 2rem calc(-1 * var(--gutter)) 0;
    padding: 0 var(--gutter) 0.6rem;
  }
  .news-grid:not(.news-grid--list)::-webkit-scrollbar { display: none; }
  .news-grid:not(.news-grid--list) .news-card { flex: 0 0 80%; scroll-snap-align: start; }
  .news-grid--list { grid-template-columns: 1fr; }
}

/* Single news article */
.article-meta {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--maroon-2);
  margin-bottom: 0.6em;
}
.article-body img { border: var(--rule); padding: 0.4rem; margin: 1.6rem 0; background: var(--paper); }
.article-body p { color: var(--ink-soft); max-width: 72ch; }
.article-body ul { margin: 0 0 1.1em; padding-left: 1.4em; max-width: 72ch; }
.article-body ul li { color: var(--ink-soft); margin-bottom: 0.5em; text-align: justify; }

/* =========================================================
   Stat strip
   ========================================================= */
.stats-caption {
  text-align: center;
  margin-bottom: 1.6rem;
}
.stats-caption .kicker { margin-bottom: 0; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  text-align: center;
}
.stat .figure {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.2rem, 5vw, 3.1rem);
  color: var(--gold-light);
  display: block;
}
.stat .label {
  font-size: 0.92rem;
  letter-spacing: 0.02em;
  color: rgba(244,234,208,0.78);
}
.section--parchment .stat .figure { color: var(--maroon); }
.section--parchment .stat .label { color: var(--ink-soft); }
@media (max-width: 640px) {
  .stats { grid-template-columns: 1fr; gap: 2rem; }
}

/* =========================================================
   Contribution / PIX block
   ========================================================= */
.pix-block {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.6rem;
  align-items: center;
  border: 1px solid rgba(184,146,63,0.5);
  padding: 1.6rem 1.8rem;
  background: var(--paper);
  margin-top: 1rem;
}
.pix-block .qr {
  width: 108px;
  height: 108px;
  border: 1px solid var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: 0.7rem;
  text-align: center;
  color: var(--ink-soft);
  padding: 0.3rem;
  overflow: hidden;
}
.pix-block .qr img { width: 100%; height: 100%; object-fit: contain; }
.pix-block .pix-label { font-family: var(--font-display); font-weight: 700; color: var(--navy); font-size: 1.1rem; }
.pix-block .pix-cnpj { font-size: 0.95rem; color: var(--ink-soft); }
@media (max-width: 520px) {
  .pix-block { grid-template-columns: 1fr; text-align: center; justify-items: center; }
}

/* =========================================================
   Contact page
   ========================================================= */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
}
.contact-grid > * { min-width: 0; }
.contact-info dl { margin: 0; }
.contact-info .item { margin-bottom: 1.6rem; }
.contact-info dt {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--navy);
  font-size: 1.05rem;
  margin-bottom: 0.2em;
}
.contact-info dd { margin: 0; color: var(--ink-soft); overflow-wrap: break-word; }

.form-field { margin-bottom: 1.3rem; }
.form-field label {
  display: block;
  font-size: 0.88rem;
  color: var(--navy);
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.form-field input,
.form-field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.75rem 0.85rem;
  border: 1px solid rgba(38, 32, 26, 0.3);
  background: var(--white);
  color: var(--ink);
}
.form-field input:focus,
.form-field textarea:focus {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
}
.form-note { font-size: 0.85rem; color: var(--ink-soft); margin-top: 0.8rem; }

@media (max-width: 800px) {
  .contact-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
  background: var(--navy);
  color: rgba(244, 234, 208, 0.85);
  border-top: 3px solid var(--gold);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 2.5rem;
  padding: clamp(2.5rem, 6vw, 4rem) 0 2.5rem;
}
.footer-brand { display: flex; gap: 1rem; }
.footer-brand img { width: 62px; height: 62px; flex-shrink: 0; }
.footer-brand h4 { color: var(--white); font-size: 1.05rem; margin-bottom: 0.5em; }
.footer-brand p { font-size: 0.92rem; color: rgba(244,234,208,0.75); margin-bottom: 1rem; }

.footer-col h4 {
  color: var(--gold-light);
  font-size: 1rem;
  font-family: var(--font-display);
  margin-bottom: 0.9em;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 0.6em; font-size: 0.93rem; }
.footer-col a:hover { color: var(--gold-light); }

/* Chamada de doação no rodapé (com QR Code), no lugar do menu de navegação */
.footer-give p { font-size: 0.9rem; color: rgba(244, 234, 208, 0.78); margin-bottom: 1.1rem; }
.footer-qr {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 0.9rem;
}
.footer-qr img {
  width: 68px;
  height: 68px;
  background: var(--white);
  padding: 4px;
  border: 1px solid var(--gold);
  flex-shrink: 0;
}
.footer-qr-label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--gold-light);
  font-size: 0.98rem;
}
.footer-qr-cnpj {
  display: block;
  font-size: 0.8rem;
  color: rgba(244, 234, 208, 0.65);
  margin-top: 0.2em;
}
.footer-give-link {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--gold-light);
  border-bottom: 1px solid var(--gold);
  padding-bottom: 2px;
}
.footer-give-link:hover { color: var(--white); }

.social-row { display: flex; gap: 0.7rem; margin-top: 0.4rem; }
.social-row a {
  width: 36px; height: 36px;
  border: 1px solid var(--gold);
  display: flex; align-items: center; justify-content: center;
}
.social-row svg { width: 16px; height: 16px; color: var(--gold-light); }
.social-row a:hover { background: var(--gold); }
.social-row a:hover svg { color: var(--navy); }

.footer-bottom {
  border-top: 1px solid rgba(184,146,63,0.3);
  padding: 1.2rem 0;
  font-size: 0.82rem;
  color: rgba(244,234,208,0.6);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
}

@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   Utilities
   ========================================================= */
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.lede { font-size: 1.12rem; color: var(--ink-soft); max-width: 62ch; }
.section--navy .lede { color: rgba(244,234,208,0.85); }
.section-head { max-width: 720px; margin-bottom: 2.2rem; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center p { max-width: none; }
.mt-lg { margin-top: 2.5rem; }

.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* Textos curtos e centralizados não devem ser justificados
   (faixa de identidade, chamadas centrais) */
.ribbon p,
.lede.mx-auto,
.text-center .lede,
.stat p {
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-track { transition: none; }
  html { scroll-behavior: auto; }
}

/* Texto só para leitores de tela / buscadores (ex.: <h1> da página inicial) */
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
/* Área de toque confortável nos links "Saiba mais →" (celular) */
.link-arrow { display:inline-block; padding:0.5rem 0; margin-top:-0.5rem; margin-bottom:-0.5rem; }  /* área de toque maior sem mudar o layout */
.footer-give-link { display:inline-block; padding:0.55rem 0; margin-top:-0.55rem; margin-bottom:-0.55rem; }

/* =========================================================
   Menu recolhido automaticamente (JS: classe nav-collapsed no <html>)
   Usado quando, em telas largas, o menu horizontal não cabe ao lado
   do nome do Colégio e do botão (ex.: fontes maiores no Mac).
   ========================================================= */
html.nav-collapsed .main-nav {
  position: absolute; top: 100%; left: 0; right: 0;
  background: var(--navy); border-bottom: 2px solid var(--gold);
  flex-direction: column; align-items: flex-start;
  padding: 1rem var(--gutter) 1.5rem; gap: 0.9rem; display: none;
}
html.nav-collapsed .main-nav.is-open { display: flex; }
html.nav-collapsed .nav-toggle { display: inline-flex; }
html.nav-collapsed .nav-dropdown-menu {
  position: static; box-shadow: none; border: none; background: none;
  padding: 0.3rem 0 0.3rem 1rem;
}
html.nav-collapsed .nav-dropdown-menu a { padding: 0.45rem 0; }
html.nav-collapsed .nav-dropdown-linked .nav-dropdown-menu { display: flex; }
html.nav-collapsed .nav-dropdown-linked::after { display: none; }
