/* Cabeçalho mesclado */

.header.header-v2 {
  gap: 14px;
  padding: 10px clamp(16px, 3vw, 25px);
}

.header-brand {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  justify-self: start;
  min-width: 0;
  line-height: 1;
}

.header-hero {
  justify-self: center;
  width: max-content;
  max-width: min(100%, 600px);
  padding: 4px 10px;
  border-radius: 9px;
  background: var(--hero-mes-gradiente, linear-gradient(135deg, var(--azul), var(--azul-hover)));
  color: #fff;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--hero-mes-cor, var(--azul)) 24%, transparent);
}

.header-hero-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.header-hero-saudacao-unificada {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.6vw, 14px);
  min-width: 0;
  width: 100%;
}

.header-hero-saudacao-unificada.modo-imagem {
  flex-direction: row;
  align-items: center;
  gap: clamp(8px, 1.6vw, 14px);
  width: 100%;
}

.header-hero--img-saudacao {
  max-width: min(100%, 520px);
}

.header-hero-welcome {
  margin: 0;
  flex: 0 1 auto;
  font-size: clamp(0.8rem, 1.55vw, 0.94rem);
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  overflow-wrap: anywhere;
  white-space: nowrap;
}

.header-hero-saudacao-unificada.modo-imagem .header-hero-welcome {
  flex-shrink: 0;
}

.header-hero-campanha {
  flex: 0 0 auto;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: #fff;
}

.header-hero-saudacao-unificada.modo-imagem .header-hero-campanha {
  display: none;
}

.header-hero-campanha-banner {
  display: none;
  height: clamp(50px, 6.5vw, 62px);
  width: auto;
  max-width: min(340px, 78vw);
  object-fit: contain;
  border-radius: 6px;
}

.header-hero-saudacao-unificada.modo-imagem .header-hero-campanha-banner {
  display: block;
  height: clamp(44px, 5.2vw, 52px);
  max-width: min(260px, 44vw);
  flex-shrink: 0;
}

.header-hero[data-mes="janeiro"] {
  background: #eef2f6 !important;
  box-shadow: 0 4px 14px rgba(100, 116, 139, 0.18) !important;
}

.header-hero[data-mes="janeiro"] .header-hero-welcome {
  color: #334155 !important;
}

.header-hero[data-mes="fevereiro"] {
  background: linear-gradient(135deg, #9333ea 0%, #ea580c 100%) !important;
  box-shadow: 0 4px 14px rgba(147, 51, 234, 0.35) !important;
}

.header-hero[data-mes="fevereiro"] .header-hero-welcome {
  color: #fff !important;
}

.header-hero[data-mes="março"] {
  background: linear-gradient(135deg, #f5f0ff 0%, #e9d5ff 55%, #ddd6fe 100%) !important;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.22) !important;
}

.header-hero[data-mes="março"] .header-hero-welcome {
  color: #6b21a8 !important;
}

.header-hero[data-mes="abril"] {
  background: #06b6d4 !important;
  box-shadow: 0 4px 14px rgba(8, 145, 178, 0.35) !important;
}

.header-hero[data-mes="abril"] .header-hero-welcome {
  color: #fff !important;
}

.header-hero[data-mes="maio"] {
  background: #facc15 !important;
  box-shadow: 0 4px 14px rgba(234, 179, 8, 0.35) !important;
}

.header-hero[data-mes="maio"] .header-hero-welcome {
  color: #1a1a1a !important;
}

.header-hero[data-mes="julho"] {
  background: #f4c400 !important;
  box-shadow: 0 4px 14px rgba(234, 179, 8, 0.35) !important;
}

.header-hero[data-mes="julho"] .header-hero-welcome {
  color: #1a1a1a !important;
}

.header-hero[data-mes="agosto"] {
  background: #faf7f0 !important;
  box-shadow: 0 4px 14px rgba(200, 146, 10, 0.18) !important;
}

.header-hero[data-mes="agosto"] .header-hero-welcome {
  color: #5c4a1f !important;
}

.header-hero[data-mes="setembro"] {
  background: #f5de7a !important;
  box-shadow: 0 4px 14px rgba(238, 209, 92, 0.35) !important;
}

.header-hero[data-mes="setembro"] .header-hero-welcome {
  color: #1a1a1a !important;
}

.header-hero[data-mes="outubro"] {
  background: #fdf2f8 !important;
  box-shadow: 0 4px 14px rgba(219, 39, 119, 0.2) !important;
}

.header-hero[data-mes="outubro"] .header-hero-welcome {
  color: #831843 !important;
}

.header-hero[data-mes="novembro"] {
  background: #f8fcff !important;
  box-shadow: 0 4px 14px rgba(14, 165, 233, 0.22) !important;
}

.header-hero[data-mes="novembro"] .header-hero-welcome {
  color: #1e3a8a !important;
}

.header-hero[data-mes="dezembro"] {
  background: #dc2626 !important;
  box-shadow: 0 4px 14px rgba(185, 28, 28, 0.35) !important;
}

.header-hero[data-mes="dezembro"] .header-hero-welcome {
  color: #fff !important;
}

.header-hero[data-mes="junho"] {
  background: linear-gradient(135deg, #9d4edd 0%, #6b21a8 100%) !important;
  box-shadow: 0 4px 14px rgba(107, 33, 168, 0.35) !important;
}

.header-hero[data-mes="junho"] .header-hero-welcome {
  color: #fff !important;
}

.header-hero-ribbon {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  min-height: 50px;
}

.header-hero-ribbon-img {
  width: 46px;
  height: auto;
  max-height: 56px;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.18));
}

.header-hero-ribbon-svg {
  width: 44px;
  height: 44px;
  display: block;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.15));
}

.header-hero-campanha-texto {
  text-align: left;
  min-width: 0;
  max-width: 175px;
}

.header-hero-campanha-titulo {
  margin: 0;
  line-height: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
}

.header-hero-mes-nome {
  font-size: clamp(0.6rem, 1.05vw, 0.7rem);
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #fff;
}

.header-hero-campanha-destaque {
  font-family: "Great Vibes", "Segoe Script", cursive;
  font-size: clamp(0.98rem, 1.95vw, 1.28rem);
  font-weight: 400;
  line-height: 1;
  margin-top: -1px;
  color: #fff;
}

.header-hero-mes {
  margin: 2px 0 0;
  font-size: clamp(0.42rem, 0.8vw, 0.52rem);
  font-weight: 600;
  line-height: 1.2;
  color: rgba(255, 255, 255, 0.92);
  overflow-wrap: anywhere;
}

/* Toolbar — menu em barras, avisos centralizado */
.toolbar-inner {
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  justify-content: unset !important;
  padding: 0 clamp(42px, 5vw, 72px) !important;
  gap: 16px;
}

.menu-toggle {
  width: auto !important;
  height: auto !important;
  padding: 10px 8px !important;
  background: transparent !important;
  color: var(--azul) !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  font-size: inherit !important;
  font-weight: 400 !important;
  flex: 0 0 auto;
  justify-self: start;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.menu-toggle:hover,
.menu-toggle:focus-visible {
  background: transparent !important;
  color: var(--laranja) !important;
}

.menu-bars {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  width: 40px;
  pointer-events: none;
}

.menu-bars span {
  display: block;
  height: 5px;
  border-radius: 3px;
  background: #06245c;
  transition: background 0.2s ease;
}

.menu-toggle:hover .menu-bars span,
.menu-toggle:focus-visible .menu-bars span {
  background: #ff6b00;
}

/* Quadro de avisos — sem ícone, alinhado ao centro dos cards */
.notice-board {
  flex: unset !important;
  justify-self: center;
  width: min(100%, 700px);
  min-width: 0;
  max-width: 700px;
  gap: 10px;
  padding: 7px 12px;
  border-radius: 12px;
}

.notice-board-head {
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  min-width: auto;
  gap: 8px;
  padding: 0 10px 0 4px;
  border-right: 1px solid rgba(6, 36, 92, 0.08);
}

.notice-board-icon {
  display: none !important;
}

.notice-board-title {
  font-size: 10px;
  white-space: nowrap;
}

.notice-carousel-wrap {
  gap: 5px;
  padding: 0;
}

.notice-carousel-track {
  min-height: 48px;
}

.notice-item {
  padding: 7px 10px;
  border-radius: 10px;
  gap: 8px;
}

.notice-item-accent {
  min-height: 28px;
}

.toolbar-whatsapp {
  justify-self: end;
}

/* Cards — visual clássico, retangular e moderno */
.grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  justify-content: center;
}

.grid.card-section-corpo.portal-secao-fechada {
  display: none !important;
}

.card {
  width: auto !important;
  max-width: none !important;
  flex: none !important;
  aspect-ratio: unset !important;
  min-height: 172px;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: space-between !important;
  text-align: center !important;
  border-radius: 14px;
  padding: clamp(16px, 4cqi, 22px) clamp(14px, 3.5cqi, 18px);
  border: 1px solid rgba(6, 36, 92, 0.12);
  box-shadow: 0 8px 22px rgba(16, 24, 40, 0.06);
}

.card:hover,
.card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--azul);
  box-shadow: 0 16px 32px rgba(6, 36, 92, 0.15);
}

.card-top {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  width: 100%;
  gap: clamp(8px, 2.5cqi, 12px);
  margin: 0 0 clamp(8px, 2cqi, 10px) !important;
}

.card-figure {
  width: clamp(46px, 14cqi, 54px) !important;
  height: clamp(46px, 14cqi, 54px) !important;
  border-radius: 12px;
  background: #eef4ff;
  color: var(--azul);
}

.card-figure svg {
  display: block !important;
  width: clamp(22px, 7cqi, 27px) !important;
  height: clamp(22px, 7cqi, 27px) !important;
}

.card-title {
  text-align: center !important;
  font-size: clamp(12px, 4cqi, 15px);
  line-height: 1.15;
  -webkit-line-clamp: 2;
}

.card-desc {
  text-align: center !important;
  font-size: clamp(11px, 3.4cqi, 12px);
  line-height: 1.3;
  flex: 1 1 auto !important;
  -webkit-line-clamp: 2;
}

.card-btn {
  width: 100% !important;
  max-width: 100%;
  margin-top: auto;
  border-radius: 10px;
  background: var(--azul);
  color: #fff;
  padding: clamp(9px, 2.2cqi, 11px) clamp(10px, 1.8cqi, 12px);
  font-size: clamp(11px, 3.2cqi, 12px);
  font-weight: 900;
  white-space: nowrap;
}

.card:hover .card-btn,
.card:focus-visible .card-btn {
  background: var(--laranja);
  color: #fff;
}

@media (max-width: 900px) {
  .header.header-v2 {
    grid-template-columns: 1fr;
    justify-items: stretch;
    text-align: center;
  }

  .header-brand {
    justify-self: center;
    justify-items: center;
  }

  .header-hero {
    width: 100%;
    max-width: 100%;
  }

  .header-v2 .header-actions {
    justify-self: center;
    justify-content: center;
  }

  .toolbar-inner {
    grid-template-columns: auto 1fr auto;
    padding: 0 clamp(18px, 4vw, 28px) !important;
  }

  .notice-board {
    width: 100%;
    max-width: none;
  }
}

@media (max-width: 720px) {
  .grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
}

@media (max-width: 520px) {
  .portal-brand-art {
    height: 25px;
  }

  .portal-brand-meta {
    font-size: 0.5rem;
  }

  .header-hero {
    padding: 4px 8px;
  }

  .header-hero-saudacao-unificada.modo-imagem {
    flex-wrap: wrap;
    justify-content: center;
  }

  .header-hero-saudacao-unificada.modo-imagem .header-hero-welcome {
    white-space: normal;
    text-align: center;
    width: 100%;
  }

  .header-hero-saudacao-unificada.modo-imagem .header-hero-campanha-banner {
    height: clamp(40px, 11vw, 50px);
    max-width: min(280px, 90vw);
  }

  .menu-bars {
    width: 34px;
    gap: 6px;
  }

  .menu-bars span {
    height: 4px;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .card {
    min-height: 160px;
  }

  .toolbar-inner {
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
  }

  .notice-board {
    grid-column: 1 / -1;
    order: 2;
  }

  .toolbar-whatsapp {
    grid-column: 2;
    grid-row: 1;
  }
}

@media (min-width: 1101px) {
  .header-hero {
    padding: 5px 12px;
  }
}
