/* Reset e Estilos Gerais */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body,
html {
  font-family: "Lato", sans-serif;
  scroll-behavior: smooth;
  color: #333;
  overflow-x: hidden;
}

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Menu de Navegação */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 20px;
}

nav .logo {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 45px;
  width: auto;
  max-width: 250px;
  object-fit: contain;
}

nav .nav-links {
  list-style: none;
  display: flex;
}

nav .nav-links li {
  margin: 0 15px;
  position: relative;
}

nav .nav-links li a {
  color: #fff;
  font-size: 1.2em;
  text-transform: uppercase;
  transition: color 0.3s;
  display: flex;
  align-items: center;
  gap: 5px;
}

nav .nav-links li a:hover {
  color: #64b5f6;
}

/* Dropdown menu styles */
.dropdown {
  position: relative;
}

.dropdown-toggle {
  cursor: pointer;
  transition: all 0.3s ease;
}

.dropdown-toggle i {
  font-size: 12px;
  transition: transform 0.3s ease;
}

.dropdown:hover .dropdown-toggle i {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  min-width: 220px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  z-index: 1001;
  border: 1px solid #e0e0e0;
  list-style: none;
  padding: 0;
  margin: 0;
}

.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-menu li {
  border-bottom: 1px solid #f0f0f0;
  margin: 0;
}

.dropdown-menu li:last-child {
  border-bottom: none;
}

.dropdown-menu a {
  display: block;
  padding: 12px 20px;
  color: #333 !important;
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 14px;
  text-transform: none;
}

.dropdown-menu a:hover {
  background: #f8f9fa;
  color: #007bff !important;
  padding-left: 25px;
}

.dropdown-menu a[target="_blank"]::after {
  content: " ↗";
  font-size: 12px;
  opacity: 0.7;
  margin-left: 5px;
}

nav .burger {
  display: none;
  cursor: pointer;
}

nav .burger div {
  width: 25px;
  height: 3px;
  background-color: #fff;
  margin: 5px;
  transition: all 0.3s ease;
}

/* Seção Título Principal */
.titulo-principal {
  padding: 120px 0 60px 0;
  background-image: url("img/background_header.jpg");
  text-align: center;
}

.main-title {
  font-size: 3.5rem;
  color: #2c3e50;
  margin-bottom: 1rem;
  font-weight: bold;
}

.main-subtitle {
  font-size: 1.4rem;
  color: #666;
  max-width: 600px;
  margin: 0 auto;
}

/* Blocos de História */
.historia-bloco {
  padding: 80px 0;
}

.bloco-azul {
  background-color: #dbdbdb;
}

.bloco-verde {
  background-color: #fff;
}

.bloco-roxo {
  background-color: #dbdbdb;
}


.bloco-laranja {
  background-color: #fff;
}

.historia-content {
  display: flex;
  align-items: center;
  gap: 3rem;
}

.historia-content.invertido {
  flex-direction: row-reverse;
}

.historia-texto {
  flex: 1;
  min-width: 300px;
}

.historia-texto h2 {
  font-size: 2.2rem;
  margin-bottom: 1.5rem;
  padding-left: 1rem;
  position: relative;
}

/* Cores das barras laterais */
.titulo-azul {
  border-left: 6px solid #007bff;
  color: #2c3e50;
}

.titulo-verde {
  border-left: 6px solid #28a745;
  color: #2c3e50;
}

.titulo-roxo {
  border-left: 6px solid #6f42c1;
  color: #2c3e50;
}

.titulo-laranja {
  border-left: 6px solid #fd7e14;
  color: #2c3e50;
}

.historia-texto p {
  font-size: 1.1rem;
  line-height: 1.7;
  margin-bottom: 1rem;
  color: #555;
  text-align: justify;
}

.historia-imagem {
  flex: 1;
  min-width: 300px;
  text-align: center;
}

.historia-imagem img {
  width: 100%;
  max-width: 500px;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  cursor: pointer;
}

.historia-imagem img:hover {
  transform: scale(1.05);
}

.imagem-caption {
  margin-top: 1rem;
  font-style: italic;
  color: #666;
  font-size: 0.9rem;
}

/* Imagens clicáveis */
.clickable-image {
  cursor: pointer;
  transition: all 0.3s ease;
}

.clickable-image:hover {
  transform: scale(1.05);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

/* Modal para Imagens */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  animation: fadeIn 0.3s ease;
}

.modal-content {
  position: relative;
  margin: auto;
  padding: 20px;
  width: 90%;
  max-width: 1000px;
  top: 50%;
  transform: translateY(-50%);
  text-align: center;
}

.modal-content img {
  width: 100%;
  height: auto;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.close {
  position: absolute;
  top: 10px;
  right: 25px;
  color: #fff;
  font-size: 35px;
  font-weight: bold;
  cursor: pointer;
  z-index: 2001;
}

.close:hover {
  color: #ccc;
}

#modalCaption {
  color: #fff;
  font-size: 1.2rem;
  margin-top: 15px;
  padding: 10px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Seção Números */
.numeros-section {
  padding: 5rem 0;
  background: linear-gradient(135deg, #007bff, #0056b3);
  color: white;
}

.numeros-section .section-title {
  color: white;
  font-size: 3rem;
  text-align: center;
  margin-bottom: 3rem;
}

.numeros-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  text-align: center;
}

.numero-item {
  padding: 2rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  backdrop-filter: blur(10px);
  transition: transform 0.3s ease;
}

.numero-item:hover {
  transform: translateY(-10px);
}

.numero {
  font-size: 4rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.numero-label {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.numero-desc {
  font-size: 1rem;
  opacity: 0.9;
}

/* Seção Galeria */
.galeria-section {
  padding: 5rem 0;
  background-color: #fff;
}

.section-title {
  font-size: 3rem;
  text-align: center;
  margin-bottom: 1rem;
  color: #2c3e50;
}

.section-subtitle {
  font-size: 1.3rem;
  text-align: center;
  margin-bottom: 3rem;
  color: #666;
}

.galeria-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.galeria-item {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  cursor: pointer;
}

.galeria-item:hover {
  transform: translateY(-10px);
}

.galeria-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform 0.3s ease;
  cursor: pointer;
}

.galeria-item:hover img {
  transform: scale(1.1);
}

.galeria-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none; /* Importante: permite que o clique passe através do overlay */
}

.galeria-item:hover .galeria-overlay {
  opacity: 1;
}

.galeria-overlay span {
  font-size: 1.2rem;
  font-weight: bold;
  pointer-events: none; /* Garante que o texto não interfira no clique */
}

/* Seção Polos */
.polos-section {
  padding: 5rem 0;
  background-color: #f8f9fa;
}

.polos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.polo-item {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.polo-item:hover {
  transform: translateY(-10px);
}

.polo-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  cursor: pointer;
}

.polo-info {
  padding: 1.5rem;
  text-align: center;
}

.polo-info h3 {
  font-size: 1.5rem;
  color: #2c3e50;
  margin-bottom: 1rem;
}

.polo-info p {
  color: #666;
  line-height: 1.6;
}

/* Rodapé */
.msd-footer {
  background-color: #020743;
  color: #ffffff;
  padding: 3rem 0;
}

.msd-footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.msd-footer-main {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.msd-footer-logo,
.msd-footer-links,
.msd-footer-contact,
.msd-footer-social {
  flex: 1;
  min-width: 200px;
  margin-bottom: 1rem;
}

.msd-footer-logo-img {
  max-width: 220px;
  margin-bottom: 1rem;
}

.msd-footer h3 {
  color: #64b5f6;
  margin-bottom: 1rem;
}

.msd-footer ul {
  list-style: none;
  padding: 0;
}

.msd-footer ul li {
  margin-bottom: 0.5rem;
}

.msd-footer a {
  color: #ffffff;
  text-decoration: none;
  transition: color 0.3s ease;
}

.msd-footer a:hover {
  color: #64b5f6;
}

.msd-social-icons {
  display: flex;
  gap: 1rem;
}

.msd-social-icons a {
  font-size: 1.5rem;
}

.msd-footer-branches {
  margin-bottom: 2rem;
}

.msd-branches-list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.msd-branch {
  flex: 1;
  min-width: 200px;
  background-color: rgba(255, 255, 255, 0.1);
  padding: 1rem;
  border-radius: 5px;
}

.msd-branch h4 {
  color: #64b5f6;
  margin-bottom: 0.5rem;
}

.msd-footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1rem;
}

.msd-footer-legal {
  display: flex;
  gap: 1rem;
}

/* Responsividade */
@media (max-width: 1024px) {
  .main-title {
    font-size: 2.8rem;
  }

  .section-title {
    font-size: 2.5rem;
  }

  .historia-texto h2 {
    font-size: 1.8rem;
  }
}

@media (max-width: 768px) {
  /* Menu Mobile */
  nav .nav-links {
    position: absolute;
    right: 0;
    height: 100vh;
    top: 0;
    background-color: rgba(0, 0, 0, 0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 60%;
    transform: translateX(100%);
    transition: transform 0.5s ease-in;
    padding-top: 80px;
  }

  nav .nav-links li {
    opacity: 0;
    margin: 10px 0;
  }

  nav.active .nav-links {
    transform: translateX(0%);
  }

  nav.active .nav-links li {
    opacity: 1;
    transition: opacity 0.5s ease-in;
  }

  nav .burger {
    display: block;
  }

  /* Dropdown Mobile */
  .dropdown-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    background: transparent;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .dropdown.active .dropdown-menu {
    max-height: 300px;
  }

  .dropdown-menu a {
    padding-left: 40px !important;
    color: white !important;
    font-size: 16px;
  }

  .dropdown-menu a:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #64b5f6 !important;
  }

  /* Títulos Mobile */
  .main-title {
    font-size: 2rem;
  }

  .main-subtitle {
    font-size: 1.1rem;
  }

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

  .section-subtitle {
    font-size: 1.1rem;
  }

  /* História Mobile */
  .historia-content {
    flex-direction: column;
    gap: 2rem;
  }

  .historia-content.invertido {
    flex-direction: column;
  }

  .historia-texto h2 {
    font-size: 1.5rem;
  }

  .historia-texto p {
    font-size: 1rem;
  }

  /* Números Mobile */
  .numeros-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .numero {
    font-size: 3rem;
  }

  /* Galeria Mobile */
  .galeria-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  /* Polos Mobile */
  .polos-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  /* Modal Mobile */
  .modal-content {
    width: 95%;
    padding: 10px;
  }

  .close {
    font-size: 28px;
    right: 15px;
  }

  /* Footer Mobile */
  .msd-footer-main,
  .msd-branches-list {
    flex-direction: column;
  }

  .msd-footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .msd-footer-legal {
    margin-top: 1rem;
  }
}

/* Animações */
@keyframes navLinkFade {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.burger.toggle .linha1 {
  transform: rotate(-45deg) translate(-5px, 6px);
}

.burger.toggle .linha2 {
  opacity: 0;
}

.burger.toggle .linha3 {
  transform: rotate(45deg) translate(-5px, -6px);
}
