/* --- CSS Variables --- */
:root {
  --color-primary: #00a859; /* Green */
  --color-secondary: #007bff; /* Blue */
  --color-accent: #ec6525; /* Yellow in logo - adjust if needed */
  --color-text-dark: #333;
  --color-text-light: #fff;
  --color-bg-light: #fffcf2; /* Pale yellow background */
  --color-bg-pale-blue: #e8f5e9; /* Very light blueish-green for testimonial bg */
  --color-bg-card: #fff;
  --color-border: #eee;
  --font-family-base: "Lato", sans-serif;
  --section-padding: 4rem 0;
  --container-width: 1140px;
  --border-radius: 8px;
  --box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

/* --- Reset & Base Styles --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px; /* Base font size */
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family-base);
  line-height: 1.6;
  color: var(--color-text-dark);
  background-color: #fff; /* Default background */
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

a {
  text-decoration: none;
  color: var(--color-secondary);
  transition: color 0.3s ease;
}

a:hover {
  color: var(--color-primary);
}

h1,
h2,
h3,
h4 {
  margin-bottom: 1rem;
  line-height: 1.3;
  font-weight: 700;
}

h1 {
  font-size: 3rem;
  font-weight: 900;
}
h2 {
  font-size: 2rem;
  color: var(--color-primary);
}
h3 {
  font-size: 1.25rem;
}
h4 {
  font-size: 1.1rem;
}

p {
  margin-bottom: 1rem;
}

/* --- Utility Classes --- */
.container {
  max-width: var(--container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 15px;
  padding-right: 15px;
}

.bg-light {
  background-color: var(--color-bg-light);
}
.bg-pale-blue {
  background-color: var(--color-bg-pale-blue);
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--border-radius);
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  font-size: 1rem;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-text-light);
}

.btn-primary:hover {
  background-color: #008a48; /* Darker green */
  color: var(--color-text-light);
}

.btn-secondary {
  background-color: var(--color-secondary);
  color: var(--color-text-light);
}

.btn-secondary:hover {
  background-color: #0056b3; /* Darker blue */
  color: var(--color-text-light);
}

.read-more {
  font-weight: 700;
  color: var(--color-text-dark); /* Or primary color */
}
.read-more:hover {
  text-decoration: underline;
}

.text-right {
  text-align: right;
}

/* --- Header --- */
.site-header {
  background-color: #fff;
  padding: 1rem 0;
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: padding 0.3s cubic-bezier(0.4, 2, 0.6, 1);
}

.site-header.scaled {
  padding: 2.5rem 0 2rem 0;
}

.header-container {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 2rem;
}

.logo img {
  height: 50px;
  width: auto;
  transition: height 0.3s cubic-bezier(0.4, 2, 0.6, 1);
}

.logo.scaled img {
  height: 110px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1rem;
  justify-self: end;
}

/* Mobile/Desktop visibility classes */
.desktop-only {
  display: block;
}

.mobile-only {
  display: none;
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  padding: 10px;
  cursor: pointer;
  position: relative;
  z-index: 1001;
}

.hamburger {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-text-dark);
  position: relative;
  transition: background-color 0.3s;
}

.hamburger::before,
.hamburger::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 2px;
  background-color: var(--color-text-dark);
  transition: transform 0.3s;
}

.hamburger::before {
  top: -8px;
}

.hamburger::after {
  top: -8px;
}

.mobile-menu-toggle.active .hamburger {
  background-color: transparent;
}

.mobile-menu-toggle.active .hamburger::before {
  transform: rotate(45deg);
  top: 0;
}

.mobile-menu-toggle.active .hamburger::after {
  transform: rotate(-45deg);
  top: 0;
}

.main-nav {
  justify-self: center;
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.main-nav a {
  color: var(--color-text-dark);
  font-weight: 700;
  padding: 0.5rem 0;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--color-primary);
}

/* Language Switcher Styles */
.lang-switch {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem;
  font-weight: 700;
}

.lang-switch a {
  color: var(--color-text-dark);
  text-decoration: none;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  transition: all 0.3s ease;
  opacity: 0.6;
}

.lang-switch a.active {
  opacity: 1;
  color: var(--color-primary);
}

.lang-switch a:hover {
  opacity: 1;
}

.lang-separator {
  color: var(--color-text-dark);
  opacity: 0.4;
}

/* Mobile Styles */
@media (max-width: 768px) {
  .header-container {
    grid-template-columns: auto 1fr auto;
    gap: 1rem;
  }

  .desktop-only {
    display: none;
  }

  .mobile-only {
    display: block;
  }

  .mobile-menu-toggle {
    display: block;
  }

  .main-nav {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(255, 255, 255, 0.98);
    padding: 80px 20px 20px;
    z-index: 1000;
    justify-self: stretch;
  }

  .main-nav.show {
    display: block;
  }

  .main-nav ul {
    flex-direction: column;
    align-items: center;
    gap: 2rem;
  }

  .main-nav a {
    font-size: 1.2rem;
    padding: 0.75rem;
  }

  .lang-item {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
  }

  /* Optional: Add animation for menu items */
  .main-nav.show ul li {
    animation: fadeInDown 0.3s ease forwards;
    opacity: 0;
  }

  @keyframes fadeInDown {
    from {
      opacity: 0;
      transform: translateY(-20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  /* Animate menu items with delay */
  .main-nav.show ul li:nth-child(1) {
    animation-delay: 0.1s;
  }
  .main-nav.show ul li:nth-child(2) {
    animation-delay: 0.2s;
  }
  .main-nav.show ul li:nth-child(3) {
    animation-delay: 0.3s;
  }
  .main-nav.show ul li:nth-child(4) {
    animation-delay: 0.4s;
  }
  .main-nav.show ul li:nth-child(5) {
    animation-delay: 0.5s;
  }
  .main-nav.show ul li:nth-child(6) {
    animation-delay: 0.6s;
  }

  .lang-switch {
    justify-content: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
  }
}

/* --- Hero Section --- */
.hero {
  min-height: 80vh;
  display: flex;
  align-items: flex-end;
  position: relative;
  text-align: left;
  padding: 0;
  background-color: #222; /* fallback color while image loads */
}

/* Optional: Add overlay for better text readability */
.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4); /* Adjust opacity */
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin-bottom: 3rem;
}

.hero h1 {
  margin-bottom: 2rem;
  color: var(--color-text-light);
  opacity: 0.8;
  text-align: left;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
}

/* --- Content Sections --- */
.content-section {
  padding: var(--section-padding);
}

.section-title {
  margin-bottom: 2rem;
  font-size: 2.3rem;
}

#resumo {
  font-size: 1.7rem;
}

[data-translate="sobreNosDesc"] {
  font-size: 1.25rem;
  line-height: 1.7;
}

.two-col-section {
  display: flex;
  gap: 3rem; /* Space between columns */
  align-items: flex-start; /* Align items to the top */
}

.two-col-section .col {
  flex: 1; /* Each column takes equal space */
  min-width: 0; /* Prevent overflow issues in flex items */
}

/* --- Cards --- */
.card {
  background-color: var(--color-bg-card);
  border-radius: var(--border-radius);
  overflow: hidden; /* To contain image corners */
  box-shadow: var(--box-shadow);
  margin-bottom: 1.5rem; /* Space below cards */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.card img {
  width: 100%;
  height: 180px; /* Fixed height for consistency */
  object-fit: cover; /* Crop images nicely */
}

.card-content {
  padding: 1.5rem;
}

/* --- Specific Component Styles --- */

/* About Section */
.about-section p {
  /* Assuming .about-section is the container div */
  margin-bottom: 1.5rem;
}

/* Events Section */
.events-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 columns */
  gap: 1.5rem;
}

.event-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.event-date {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 0;
}

.section-cta {
  margin-top: 2rem; /* Space above buttons like "View All Events" */
  text-align: center; /* Or right */
}
.section-cta .btn {
  display: inline-block; /* Ensure button takes correct width */
}

/* Testimonials Section */
.testimonial-card {
  background-color: var(
    --color-bg-card
  ); /* Or specific background like #f8f9fa */
  padding: 2rem;
  position: relative;
}

.testimonial-card blockquote p {
  font-size: 1.1rem;
  font-style: italic;
  margin-bottom: 1rem;
}

.testimonial-card blockquote footer {
  font-size: 0.9rem;
  color: #555;
  font-style: normal;
}

.quote-icon {
  position: absolute;
  bottom: 1rem;
  right: 1.5rem;
  font-size: 3rem;
  color: var(--color-secondary); /* Or a lighter blue/gray */
  opacity: 0.6;
}

/* Latest News Section */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.news-card {
  display: flex;
  align-items: center; /* Vertically center content */
  gap: 1.5rem;
  padding: 1rem; /* Padding inside the flex container */
  margin-bottom: 0; /* Remove bottom margin since gap is used */
}

.news-card img {
  width: 100px; /* Fixed width for news image */
  height: 80px;
  object-fit: cover;
  border-radius: var(--border-radius);
  flex-shrink: 0; /* Prevent image from shrinking */
}

.news-card .card-content {
  padding: 0; /* Remove padding as it's on the parent */
  flex-grow: 1;
}

.news-date {
  font-size: 0.85rem;
  color: #777;
  margin-bottom: 0.25rem;
}

.news-card h4 {
  margin-bottom: 0;
  font-size: 1.1rem; /* Match event title size */
}

/* --- Responsiveness --- */

/* Tablet */
@media (max-width: 992px) {
  :root {
    --section-padding: 3rem 0;
  }
  h1 {
    font-size: 2.5rem;
  }
  h2 {
    font-size: 1.75rem;
  }

  .two-col-section {
    gap: 2rem;
  }

  .events-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 columns on tablets */
  }

  .news-card img {
    width: 80px;
    height: 60px;
  }
}

/* Mobile */
@media (max-width: 768px) {
  html {
    font-size: 15px;
  } /* Slightly smaller base font */

  .header-container {
    /* Add styles for mobile menu toggle if implemented */
    /* e.g., hide nav, show burger icon */
  }
  .main-nav {
    display: none;
  } /* Hide nav by default on mobile */
  /* Need JS to toggle nav visibility */

  .hero {
    min-height: 35vh;
    text-align: center;
  }
  .hero-content {
    max-width: 90%;
    margin-bottom: 1.5rem;
  }
  .hero-buttons {
    justify-content: center;
  }

  .two-col-section {
    flex-direction: column; /* Stack columns */
    gap: 2.5rem;
  }

  .events-grid {
    grid-template-columns: 1fr; /* 1 column on mobile */
  }
  .event-card {
    max-width: 350px; /* Limit width on mobile */
    margin-left: auto;
    margin-right: auto;
  }

  .testimonial-card {
    padding: 1.5rem;
  }
  .quote-icon {
    font-size: 2.5rem;
    right: 1rem;
    bottom: 0.5rem;
  }

  .news-card {
    gap: 1rem;
  }
  .news-card img {
    width: 70px;
    height: 55px;
  }

  .section-cta.text-right {
    text-align: center; /* Center buttons/links on mobile */
  }
}

/* --- Header - Active Nav Link --- */
.main-nav a.active {
  color: var(--color-primary);
  /* Optional: Add other active indicators */
  /* border-bottom: 2px solid var(--color-primary); */
  font-weight: 900; /* Make it slightly bolder */
}

/* --- Main Content - Institutional Links List --- */
.institutional-links {
  /* Add some space above the list if needed, though section padding might suffice */
  margin-top: 1rem;
}

.institutional-links ul {
  list-style: none; /* Remove default bullets */
  padding-left: 0; /* Remove default padding */
}

.institutional-links li {
  margin-bottom: 0.8rem; /* Space between main list items */
  font-size: 1.1rem; /* Slightly larger text */
}

/* Style for the "Documentos" text acting as a sub-header */
.institutional-links li strong {
  display: block; /* Make it take its own line */
  margin-bottom: 0.5rem;
  font-weight: 700;
  color: var(--color-text-dark); /* Or var(--color-primary) if preferred */
}

.institutional-links a {
  color: var(--color-secondary); /* Use theme blue for links */
  text-decoration: none;
  transition: color 0.3s ease;
}

.institutional-links a:hover {
  color: var(--color-primary); /* Use theme green for hover */
  text-decoration: underline;
}

/* Nested list styling */
.institutional-links ul.nested-list {
  margin-top: 0.5rem; /* Space below "Documentos" */
  padding-left: 1.5rem; /* Indent nested list */
  list-style: disc; /* Add bullets back for nested items */
  list-style-position: inside; /* Bullets inside padding */
}

.institutional-links ul.nested-list li {
  margin-bottom: 0.5rem; /* Smaller space for nested items */
  font-size: 1rem; /* Slightly smaller font for nested items */
}

/* --- Footer --- */
.site-footer {
  background-color: #f8f9fa; /* Light grey background */
  padding: 2rem 0;
  border-top: 1px solid var(--color-border);
  margin-top: 3rem; /* Space above the footer */
  color: #6c757d; /* Muted text color */
  font-size: 0.9rem;
}

.footer-container {
  display: flex;
  justify-content: space-between; /* Pushes copyright and social links apart */
  align-items: center;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  gap: 1rem; /* Space between items if they wrap */
}

.site-footer p {
  margin-bottom: 0; /* Remove default paragraph margin */
}

.copyright {
  text-align: left;
}

.social-links {
  text-align: right;
}

.social-links a {
  color: var(--color-secondary); /* Use theme blue */
  margin-left: 1rem; /* Space between social icons */
  font-size: 1.3rem; /* Make icons slightly larger */
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: var(--color-primary); /* Use theme green on hover */
}

/* Screen reader only text - for accessibility on icons */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* --- Footer Responsiveness --- */
@media (max-width: 768px) {
  .footer-container {
    flex-direction: column; /* Stack items vertically */
    text-align: center; /* Center text */
  }

  .copyright,
  .social-links {
    text-align: center;
    width: 100%; /* Take full width when stacked */
  }

  .social-links a {
    margin-left: 0.5rem; /* Adjust spacing for mobile */
    margin-right: 0.5rem;
  }
}

/* --- General Page Structure --- */
.page-container {
  padding-top: 2rem; /* Add space below header */
  padding-bottom: 3rem; /* Add space above footer */
}

.page-title {
  font-size: 2.8rem; /* Large title */
  font-weight: 700; /* Or 900 */
  color: var(--color-text-dark); /* Or primary color */
  margin-bottom: 2.5rem;
  text-align: left; /* Or center if preferred */
  /* Adjust alignment based on container */
  /* If container has padding, left alignment works */
}

/* --- Institutional Two-Column Layout --- */
.institutional-layout {
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  gap: 3rem; /* Adjust gap between sidebar and content */
  align-items: flex-start; /* Align items to the top */
}

/* --- Sidebar --- */
.sidebar {
  flex: 0 0 220px; /* Fixed width for sidebar, don't grow or shrink */
  /* Or use flex-basis: 220px; flex-grow: 0; flex-shrink: 0; */
}

.sidebar-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  border: 1px solid var(--color-border); /* Light border around the nav */
  border-radius: var(--border-radius);
  overflow: hidden; /* To contain active background */
  background-color: #fff; /* White background */
}

.sidebar-nav li {
  border-bottom: 1px solid var(--color-border);
}
.sidebar-nav li:last-child {
  border-bottom: none; /* Remove border from last item */
}

.sidebar-nav a {
  display: block;
  padding: 0.9rem 1.2rem;
  color: var(--color-text-dark);
  text-decoration: none;
  font-weight: 400; /* Regular weight for inactive */
  transition: background-color 0.3s ease, color 0.3s ease;
  font-size: 1rem;
}

.sidebar-nav a:hover {
  background-color: #f8f9fa; /* Very light grey on hover */
  color: var(--color-primary);
}

.sidebar-nav a.active {
  background-color: #f1f3f5; /* Light grey background for active */
  font-weight: 700; /* Bold for active */
  color: var(--color-text-dark); /* Dark text for active */
}

/* --- Main Content Area --- */
.main-content {
  flex: 1; /* Takes remaining space */
  min-width: 0; /* Prevent overflow */
}

.content-block {
  margin-bottom: 3rem; /* Space between content sections */
}
.content-block:last-child {
  margin-bottom: 0;
}

.content-block h2 {
  font-size: 1.8rem; /* Slightly smaller than page title */
  color: var(--color-text-dark); /* Standard heading color */
  margin-bottom: 1.5rem;
  font-weight: 700;
  /* Maybe add a border-bottom if desired */
  /* border-bottom: 2px solid var(--color-primary); */
  /* padding-bottom: 0.5rem; */
}

.content-image {
  width: 100%;
  max-width: 600px; /* Limit image width if needed */
  height: auto;
  border-radius: var(--border-radius);
  margin-bottom: 1.5rem;
  box-shadow: var(--box-shadow);
}

.content-block p {
  line-height: 1.7;
  margin-bottom: 1rem;
}

/* --- Values List Styling --- */
.values-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.values-list li {
  display: flex;
  align-items: flex-start; /* Align icon top with text */
  gap: 1.5rem; /* Space between icon and text */
  margin-bottom: 1.8rem; /* Space between list items */
}

.values-list .icon-container {
  flex: 0 0 45px; /* Fixed width for icon container */
  height: 45px;
  /* background-color: #e8f5e9; Light green background, adjust as needed */
  border-radius: 50%; /* Make it circular */
  display: flex;
  justify-content: center;
  align-items: center;
  /* Use FontAwesome icon size/color */
}
.values-list .icon-container i {
  font-size: 1.8rem; /* Icon size */
  color: var(--color-primary); /* Or different colors per icon */
  /* Assign specific colors if needed: */
  /* &.fa-bullseye { color: var(--color-primary); } */
  /* &.fa-users { color: orange; } */
  /* &.fa-people-group { color: red; } */
  /* &.fa-child-reaching { color: var(--color-secondary); } */
}

.values-list .text-content strong {
  display: block; /* Makes title appear on its own line */
  font-weight: 700;
  margin-bottom: 0.3rem;
  font-size: 1.1rem;
}

/* --- Document List Styling --- */
.document-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--border-radius);
  overflow: hidden; /* Helps with borders */
}

.document-list li {
  display: flex;
  justify-content: space-between; /* Pushes info and link apart */
  align-items: center;
  padding: 0.8rem 1.2rem; /* Padding inside list item */
  border-bottom: 1px solid var(--color-border);
  transition: background-color 0.2s ease;
}

.document-list li:last-child {
  border-bottom: none;
}

.document-list li:hover {
  background-color: #f8f9fa; /* Slight hover effect */
}

.document-list .doc-info {
  display: flex;
  align-items: center;
  gap: 0.8rem; /* Space between icon and text */
}

.document-list .doc-info i {
  font-size: 1.2rem; /* Icon size */
  color: var(--color-accent);
  width: 20px; /* Ensure alignment */
  text-align: center;
}

.document-list .pdf-link {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-accent);
  text-decoration: none;
  padding: 0.2rem 0.5rem;
  /* Optional: add border/background for button look */
  /* border: 1px solid var(--color-secondary); */
  /* border-radius: 4px; */
  /* transition: background-color 0.3s ease, color 0.3s ease; */
}

.document-list .pdf-link:hover {
  color: var(--color-primary);
  text-decoration: underline;
  /* Optional hover for button look */
  /* background-color: var(--color-secondary); */
  /* color: white; */
}

/* --- Responsiveness --- */
@media (max-width: 992px) {
  .institutional-layout {
    gap: 2rem; /* Reduce gap */
  }
  .sidebar {
    flex: 0 0 180px; /* Slightly smaller sidebar */
  }
  .page-title {
    font-size: 2.4rem;
    margin-bottom: 2rem;
  }
  .content-block h2 {
    font-size: 1.6rem;
  }
  .values-list li {
    gap: 1rem;
  }
  .values-list .icon-container {
    flex-basis: 40px; /* Adjust icon container size */
    height: 40px;
  }
  .values-list .icon-container i {
    font-size: 1.6rem;
  }
}

@media (max-width: 768px) {
  .institutional-layout {
    flex-direction: column; /* Stack columns */
  }
  .sidebar {
    flex: 1 1 auto; /* Allow sidebar to take full width */
    width: 100%; /* Ensure it takes full width */
    margin-bottom: 2rem; /* Space below sidebar when stacked */
  }
  .main-content {
    width: 100%;
  }
  .page-title {
    font-size: 2rem;
    text-align: center;
  }
  .content-image {
    max-width: 100%; /* Allow image full width */
  }
}

/* --- Sponsors/Supporters Section --- */
.sponsors-section {
  padding: var(--section-padding);
  background-color: white;
}

.sponsors-section .section-title {
  text-align: center;
  margin-bottom: 2.5rem;
}

.carousel-wrapper {
  width: 100%;
  overflow: hidden;
  position: relative;
}

.logos-carousel-dynamic {
  display: flex;
  justify-content: space-around; /* Distribute logos evenly */
  align-items: center;
  flex-wrap: nowrap;
  gap: 2rem;
  padding: 1rem 0;
  min-height: 80px;
}

.logos-carousel-dynamic img {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
  max-height: 60px;
  max-width: 150px;
  width: auto;
  opacity: 0;
  transition: opacity 0.2s ease-in-out; /* Smooth fade */
  object-fit: contain;
}

/* --- Responsiveness for Dynamic Carousel --- */
@media (max-width: 992px) {
  .logos-carousel-dynamic {
    gap: 0.5rem;
  }

  .logos-carousel-dynamic img {
    max-height: 55px;
    max-width: 130px;
  }
}

@media (max-width: 768px) {
  .logos-carousel-dynamic {
    gap: 0.5rem;
  }

  .logos-carousel-dynamic img {
    max-height: 45px;
    max-width: 100px;
  }
}

/* --- Contact Page Specific Styles --- */

.contact-intro {
  text-align: center;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 3rem;
  font-size: 1.1rem;
  color: #555;
}

.contact-layout {
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  gap: 3rem; /* Adjust gap between form and info */
  align-items: flex-start;
}

.contact-form-column {
  flex: 1; /* Takes up available space */
  min-width: 300px; /* Ensure minimum width before wrapping */
}

.contact-info-column {
  flex: 1; /* Takes up available space */
  min-width: 300px; /* Ensure minimum width before wrapping */
}

.contact-form-column h3,
.contact-info-column h3 {
  font-size: 1.5rem; /* Slightly smaller heading */
  margin-bottom: 1.5rem;
  color: var(--color-primary); /* Use primary color */
}

/* --- Contact Form Styling --- */
.contact-form .form-group {
  margin-bottom: 1.5rem;
}

.contact-form label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--color-text-dark);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid #ccc; /* Softer border */
  border-radius: var(--border-radius);
  font-size: 1rem;
  font-family: var(--font-family-base);
  transition: border-color 0.3s ease;
  background-color: #fff; /* Ensure background color */
}

.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--color-primary); /* Highlight focus with primary color */
  box-shadow: 0 0 0 2px rgba(0, 168, 89, 0.2); /* Optional focus ring */
}

.contact-form textarea {
  resize: vertical; /* Allow vertical resizing only */
  min-height: 120px; /* Minimum height for message box */
}

.contact-form .form-submit {
  margin-top: 2rem;
}
.contact-form button[type="submit"] {
  cursor: pointer;
  /* Uses .btn and .btn-primary styles */
}

/* --- Contact Details Styling --- */
.contact-details {
  margin-bottom: 2.5rem; /* Space before map */
}

.contact-details p {
  display: flex; /* Align icon and text */
  align-items: flex-start; /* Align icon top with text */
  margin-bottom: 1.2rem;
  font-size: 1rem;
  line-height: 1.6;
}

.contact-details i {
  color: var(--color-secondary); /* Use secondary color for icons */
  font-size: 1.2rem;
  margin-right: 1rem;
  margin-top: 0.1em; /* Slight adjustment for vertical alignment */
  width: 20px; /* Fixed width for alignment */
  text-align: center;
}

.contact-details a {
  color: var(--color-text-dark); /* Standard text color for links here */
  text-decoration: none;
}
.contact-details a:hover {
  color: var(--color-primary);
  text-decoration: underline;
}

/* --- Map Styling --- */
.map-title {
  /* Use same style as other h3 */
}

.map-container {
  position: relative;
  padding-bottom: 75%; /* Aspect ratio (height/width * 100) - adjust 450/600 = 75% */
  height: 0;
  overflow: hidden;
  border-radius: var(--border-radius); /* Match card radius */
  box-shadow: var(--box-shadow); /* Add subtle shadow */
  border: 1px solid var(--color-border); /* Optional subtle border */
}

.map-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* --- Contact Page Responsiveness --- */
@media (max-width: 992px) {
  .contact-layout {
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .contact-layout {
    flex-direction: column; /* Stack columns */
  }
  /* Optional: Remove min-width if stacking */
  /* .contact-form-column,
    .contact-info-column {
        min-width: unset;
    } */
  .contact-intro {
    margin-bottom: 2rem;
    font-size: 1rem;
  }
}

/* --- News Page Specific Styles --- */

.page-intro {
  /* Optional intro text styling */
  text-align: center;
  max-width: 700px;
  margin: 0 auto 2.5rem auto;
  font-size: 1.1rem;
  color: #555;
}

.loading-indicator,
.no-news,
.error-message {
  text-align: center;
  padding: 3rem 1rem;
  color: #777;
  font-style: italic;
}
.loading-indicator i {
  font-size: 1.5rem;
  display: block;
  margin-top: 0.5rem;
  color: var(--color-primary);
}

/* --- News Grid Layout --- */
.news-grid {
  display: grid;
  /* Adjust columns based on desired layout */
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem; /* Space between cards */
  margin-bottom: 3rem; /* Space before social prompt */
}

/* --- News Card Styling --- */
.news-card {
  background-color: var(--color-bg-card);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  overflow: hidden; /* Contain image corners */
  display: flex;
  flex-direction: column; /* Stack image and content */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid var(--color-border);
}

.news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* Featured Card Styling */
.news-card.featured {
  border-left: 5px solid var(--color-primary); /* Highlight featured */
  /* Or different background, etc */
}

.news-card-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  overflow: hidden;
}

.news-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Crop image nicely */
  transition: transform 0.4s ease;
}
.news-card:hover .news-card-image img {
  transform: scale(1.05); /* Subtle zoom on hover */
}

.news-card-content {
  padding: 1.5rem;
  flex-grow: 1; /* Allow content to fill space if cards have different heights */
  display: flex;
  flex-direction: column;
}

.news-card-category {
  display: inline-block;
  background-color: var(
    --color-secondary
  ); /* Use secondary color for category */
  color: var(--color-text-light);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  align-self: flex-start; /* Align category badge to the start */
  text-transform: uppercase;
}

.news-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--color-text-dark);
  line-height: 1.4;
}

.news-card-date {
  font-size: 0.85rem;
  color: #777;
  margin-bottom: 1rem;
}
.news-card-date i {
  margin-right: 0.4rem;
}

.news-card-summary {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #444;
  flex-grow: 1; /* Push link to bottom */
  margin-bottom: 1rem;
}

.news-card-link {
  margin-top: auto; /* Push to bottom */
  margin-bottom: 0; /* Remove default p margin */
}
.news-card-link .btn-small {
  /* Example custom size */
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
}
.news-card-link i {
  margin-left: 0.5rem;
  transition: transform 0.3s ease;
}
.news-card-link a:hover i {
  transform: translateX(3px);
}

/* --- Social Follow Prompt --- */
.social-follow-prompt {
  text-align: center;
  padding: 2rem 1rem;
  background-color: var(--color-bg-pale-blue); /* Use a light background */
  border-radius: var(--border-radius);
  margin-top: 2rem;
}
.social-follow-prompt p {
  margin-bottom: 1rem;
  font-size: 1.1rem;
  color: var(--color-text-dark);
}

.social-links-inline {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.social-links-inline .social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 700;
  transition: background-color 0.3s ease, color 0.3s ease;
  color: #fff; /* Default text color */
}

.social-links-inline .social-link i {
  font-size: 1.2rem;
}

.social-links-inline .social-link.facebook {
  background-color: #1877f2;
}
.social-links-inline .social-link.facebook:hover {
  background-color: #166fe5;
}
.social-links-inline .social-link.instagram {
  background: #d6249f;
  background: radial-gradient(
    circle at 30% 107%,
    #fdf497 0%,
    #fdf497 5%,
    #fd5949 45%,
    #d6249f 60%,
    #285aeb 90%
  );
}
.social-links-inline .social-link.instagram:hover {
  opacity: 0.9;
}

/* --- News Page Responsiveness --- */
@media (max-width: 768px) {
  .news-grid {
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 1.5rem;
  }
  .news-card-image {
    height: 180px; /* Adjust image height on mobile */
  }
}

/* Override previous institutional list styles if they exist */
/* You might want to remove the old '.institutional-links' styles */
.institutional-links {
  display: none;
} /* Hide the old list if present */

/* --- Events Page Styles --- */

/* Featured Event */
.featured-event {
  margin-bottom: 4rem;
}

.event-card.featured {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  background-color: var(--color-bg-card);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--box-shadow);
}

.event-card.featured .event-image {
  height: 100%;
  min-height: 400px;
}

.event-card.featured .event-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.event-card.featured .event-content {
  padding: 2rem;
}

.event-status {
  display: inline-block;
  padding: 0.5rem 1rem;
  background-color: var(--color-primary);
  color: white;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.event-meta {
  margin: 1rem 0;
}

.event-meta p {
  margin-bottom: 0.5rem;
  color: #666;
}

.event-meta i {
  width: 20px;
  color: var(--color-primary);
  margin-right: 0.5rem;
}

.event-description {
  margin: 1.5rem 0;
  line-height: 1.6;
}

.event-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

/* Event Cards Grid */
.events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.event-card {
  background-color: var(--color-bg-card);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--box-shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.event-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.event-image {
  height: 200px;
  overflow: hidden;
}

.event-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.event-card:hover .event-image img {
  transform: scale(1.05);
}

.event-content {
  padding: 1.5rem;
}

.event-category {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  background-color: var(--color-secondary);
  color: white;
  border-radius: 15px;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.event-card h3 {
  margin-bottom: 0.75rem;
  font-size: 1.2rem;
  line-height: 1.4;
}

/* Past Events */
.event-card.past .event-image.grayscale img {
  filter: grayscale(60%);
  opacity: 0.8;
}

.event-card.past:hover .event-image.grayscale img {
  filter: grayscale(10%);
  opacity: 1;
}

/* Newsletter Signup */
.newsletter-signup {
  background-color: var(--color-bg-pale-blue);
  padding: 3rem;
  border-radius: var(--border-radius);
  text-align: center;
  margin: 4rem 0;
}

.newsletter-content {
  max-width: 600px;
  margin: 0 auto;
}

.newsletter-content h2 {
  margin-bottom: 1rem;
}

.newsletter-content p {
  margin-bottom: 2rem;
  color: #666;
}

.newsletter-form .form-group {
  display: flex;
  gap: 1rem;
  max-width: 500px;
  margin: 0 auto;
}

.newsletter-form input[type="email"] {
  flex: 1;
  padding: 0.8rem 1rem;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  font-size: 1rem;
}

.newsletter-form input[type="email"]:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(0, 168, 89, 0.1);
}

/* Responsive Styles */
@media (max-width: 992px) {
  .event-card.featured {
    grid-template-columns: 1fr;
  }

  .event-card.featured .event-image {
    min-height: 300px;
  }

  .events-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
  }
}

@media (max-width: 768px) {
  .event-actions {
    flex-direction: column;
  }

  .event-actions .btn {
    width: 100%;
    text-align: center;
  }

  .newsletter-form .form-group {
    flex-direction: column;
  }

  .newsletter-signup {
    padding: 2rem 1rem;
  }
}

/* Counter Section Styles */
.counter-section {
  padding: 4rem 0;
  background-color: var(--color-primary);
  color: white;
}

.counter-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.counter-content {
  padding: 2rem;
}

.counter {
  font-size: 4rem;
  font-weight: 900;
  margin-bottom: 1rem;
  font-family: "Lato", sans-serif;
  transition: opacity 0.3s ease;
  min-width: 200px; /* Prevent layout shifts during animation */
  display: inline-block;
}

.counter-content h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
  opacity: 0.9;
}

/* Fun, popping CTA button for 'Vem ser criança!' */
.btn.btn-fun {
  font-size: 2rem;
  padding: 1.2rem 5.5rem 1.2rem 2.5rem; /* Extra right padding for balloon */
  border-radius: 50px;
  background: linear-gradient(
    90deg,
    var(--color-accent) 0%,
    var(--color-primary) 100%
  );
  color: #fff;
  box-shadow: 0 6px 24px rgba(0, 168, 89, 0.18),
    0 1.5px 6px rgba(255, 193, 7, 0.12);
  letter-spacing: 0.03em;
  font-weight: 900;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.18s cubic-bezier(0.4, 2, 0.6, 1), box-shadow 0.18s,
    background 0.3s;
  position: relative;
  overflow: hidden;
  z-index: 1;
  margin: 2rem 0 1rem 0; /* Add margin above and below for spacing */
}
.btn.btn-fun:hover,
.btn.btn-fun:focus {
  transform: scale(1.08) rotate(-2deg);
  box-shadow: 0 10px 32px rgba(0, 168, 89, 0.22),
    0 2px 8px rgba(255, 193, 7, 0.16);
  background: linear-gradient(
    90deg,
    var(--color-primary) 0%,
    var(--color-accent) 100%
  );
  color: #fff;
  text-decoration: none;
}
.btn.btn-fun::after {
  content: "🎈";
  position: absolute;
  right: 1.2rem;
  top: 50%;
  transform: translateY(-50%) scale(1.2) rotate(-10deg);
  font-size: 1.5em;
  pointer-events: none;
  opacity: 0.85;
  transition: transform 0.2s;
}
.btn.btn-fun:hover::after {
  transform: translateY(-60%) scale(1.4) rotate(8deg);
}

#o-que-fazemos .icon-container i {
  color: var(--color-secondary);
}
