/* Reset e estilos gerais */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Ubuntu", sans-serif;

}

html{
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

:root {
  --primary: #006f9e;
  --primary_hover: #0097cc;
  --secondary: #e8ae1e;
  --accent: #80281a;
  --accent_hover: #cc3a2b;
  --green: #005f27;
  --dark: #222;
  --light: #eee;
  --gray: #888;
}

body {
  color: var(--dark);
  line-height: 1.6;
  overflow-x: hidden;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

section {
  padding: 60px 0;
}

h1,
h2,
h3 {
  margin-bottom: 1rem;
  line-height: 1.2;
}

h1 {
  font-size: clamp(2rem, 5vw, 2.5rem);
}

h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  text-align: center;
  margin-bottom: 2rem;
}

h3 {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
}

p {
  margin-bottom: 1rem;
  font-size: clamp(0.9rem, 2.5vw, 1rem);
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  background-color: var(--accent);
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 600;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  font-size: clamp(0.9rem, 2.5vw, 1rem);
  text-align: center;
}

.btn:hover {
  background-color: var(--accent_hover);
  transform: translateY(-2px);
}

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

.btn-secondary:hover {
  background-color: var(--accent_hover);
}

/* Header Mobile-First */
header {
  background-color: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: fixed;
  width: 100%;
  z-index: 1000;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
}

.logo {
  height: 60px;
}

.logo img {
  height: 100%;
  width: auto;
}

/* Menu Mobile */
.menu-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  z-index: 1001;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--primary);
  margin: 3px 0;
  transition: 0.3s;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 20px;
}

nav li {
  margin: 0;
}

nav a {
  text-decoration: none;
  color: var(--dark);
  font-weight: 500;
  transition: color 0.3s;
  font-size: clamp(0.9rem, 2.5vw, 1rem);
}

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

.header-btn {
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
  padding: 10px 20px;
}

/* Hero Section */
.hero {
  background: linear-gradient(rgba(0, 111, 158, 0.7), rgba(0, 79, 107, 0.7)),
    url(img/background4.webp);
  background-size: cover;
  background-position: center center;
  color: white;
  text-align: center;
  padding: 140px 0 80px;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero h1 {
  font-size: clamp(2rem, 6vw, 3rem);
  margin-bottom: 1.5rem;
}

.hero p {
  font-size: clamp(1rem, 3vw, 1.2rem);
  max-width: 700px;
  margin: 0 auto 2rem;
}

/* Services Section */
.services {
  background-color: white;
}

.services h3{
  text-align: center;
    margin-bottom: 3rem;

}

.services h2 {
  color: var(--primary);
}

.service-card h3 {
  color: var(--dark);
  margin-bottom: 1rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 20px;
}

.service-card {
  background: white;
  border: 2px solid var(--primary);
  padding: 25px;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  text-align: center;
  /*transition: transform 0.3s;*/
}

.service-card ul {
  padding: 0 20px;
  /*transition: transform 0.3s;*/
}

.service-card li {
  text-align: left;
  /*transition: transform 0.3s;*/
}


/*
.service-card:hover {
  transform: translateY(-5px);
}*/

.service-icon {
  font-size: clamp(2rem, 6vw, 2.5rem);
  color: var(--primary);
  margin-bottom: 15px;
}

/* Projects Section */

.projects {
  background: var(--light);
}

.projects h2 {
  color: var(--primary);
}

.projects h3 {
  text-align: center;
}

.projects-grid {
  margin-top: 50px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
  gap: 20px;
}

.project-card a:link, .project-card a:visited {
  text-decoration: none;
  color: inherit;
}

.project-card:hover {
  transform: translateY(-5px);
}

.project-card {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--primary);

  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s;
}

.project-content {
  padding: 20px;
}

.project-card figure {
  margin: 0;
  height: 300px;
}

figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 5px;
}

.project-card h3 {
  color: var(--dark);
  margin: 15px 0 0 0;
  text-align: left;
}

.project-card h4 {
  text-align: left;
  margin-top: 10px;
}

.project-card h5 {
  text-align: left;
  color: var(--primary);
  margin-top: 10px;
}
/* noticias Section */

.noticias {
  background-color: white;
}

.noticias h2 {
  color: var(--primary);
}

.testimonial span{
  font-size: clamp(0.8rem, 2.5vw, 0.7rem);
  color: var(--primary);
}

.testimonial a:link{
  text-decoration: none;
  color: var(--primary);
}

.testimonial {
  background-color: rgb(172, 208, 230);
  border: 2px solid var(--primary);

  padding: 10px;
  border-radius: 8px;
  margin-top: 30px;
  text-align: left;
  display: grid;
  grid-template-columns: 200px 1fr;
  align-items: center;
  gap: 20px;
}

.testimonial .imageNews{
  width: 100%;
  height: auto;
}

.testimonial .imageNews img{
  width: 100%;
  object-fit: cover;
  border-radius: 8px;
  margin-right: 15px;
}

/* About Section */
.about {
  background-color: var(--light);
}

.about-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: center;
}

.about-text h2 {
  text-align: left;
  color: var(--primary);
}

.about-image {
  border-radius: 8px;
  border: 2px solid var(--primary);

  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  order: -1;
}

.about-image img {
  width: 100%;
  height: auto;
  display: block;
}

.noticia_interna{
  padding-top: 150px;
}

.noticia_interna h2, .noticia_interna h3, .noticia_interna h4{
  text-align: center;
  margin-bottom: 20px;
}

h4 a:link, h4 a:visited{
  text-decoration: none;
  color: var(--primary);
}

/* CTA Section */
.cta {
  background: linear-gradient(to right, var(--primary), var(--accent));
  color: white;
  text-align: center;
  padding: 60px 0;
}

.cta h2 {
  color: white;
  margin-bottom: 1rem;
}

.cta p {
  margin-bottom: 2rem;
}
/* Footer */
footer {
  background-color: var(--dark);
  color: white;
  padding: 50px 0 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-bottom: 30px;
}

.footer-column h3 {
  margin-bottom: 15px;
  font-size: clamp(1.1rem, 3vw, 1.2rem);
}

.footer-column ul {
  list-style: none;
}

.footer-column li {
  margin-bottom: 8px;
  font-size: clamp(0.85rem, 2.5vw, 0.9rem);
}

.footer-column a {
  color: #ccc;
  text-decoration: none;
  transition: color 0.3s;
}

.footer-column a:hover {
  color: white;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px;
  margin-bottom: 15px;
  border: none;
  border-radius: 4px;
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: clamp(0.85rem, 2.5vw, 0.9rem);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #ccc;
}

.copyright {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #ccc;
  font-size: clamp(0.8rem, 2.5vw, 0.9rem);
}

/* Media Queries para Responsividade */

/* Tablets */
@media (min-width: 768px) {
  section {
    padding: 80px 0;
  }

  .about-content {
    grid-template-columns: 1fr 1fr;
    gap: 50px;
  }

  .about-image {
    order: 0;
  }

  .hero {
    padding: 160px 0 100px;
  }

  h2 {
    margin-bottom: 3rem;
  }

  .about-content{
    display: flex;
    flex-direction: column;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .services-grid,
  .projects-grid {
    gap: 30px;
  }

  .service-card {
    padding: 30px;
  }

  .project-content {
    padding: 25px;
  }

  .testimonial {
    padding: 40px;
    margin-top: 40px;
  }
}

/* Mobile - Menu Hamburguer */
@media (max-width: 767px) {
  .logo {
    margin: 10px 0;
  }
  .menu-toggle {
    display: flex;
  }

  nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    height: 100vh;
    background: white;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    transition: 0.3s;
    z-index: 1000;
    padding: 80px 20px 20px;
  }

  nav.active {
    right: 0;
  }

  nav ul {
    flex-direction: column;
    gap: 0;
  }

  nav li {
    margin: 0;
    border-bottom: 1px solid #eee;
  }

  nav a {
    display: block;
    padding: 15px 0;
    font-size: 1.1rem;
  }

  .header-btn {
    display: none;
  }

  /* Overlay quando menu está aberto */
  .overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
  }

  .overlay.active {
    display: block;
  }

  /* Animação do menu hamburguer */
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }
}

/* Mobile Pequeno */
@media (max-width: 480px) {
  .logo {
    margin: 10px 0;
  }
  .container {
    width: 95%;
    padding: 0 10px;
  }

  section {
    padding: 40px 0;
  }

  .hero {
    padding: 120px 0 60px;
    min-height: 80vh;
  }

  .services-grid,
  .projects-grid {
    grid-template-columns: 1fr;
  }

  .service-card,
  .project-card {
    padding: 20px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .btn {
    width: 100%;
    max-width: 300px;
  }

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

/* Estilos para o sistema de formulário */
.form-group {
  margin-bottom: 20px;
  position: relative;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  font-size: clamp(0.85rem, 2.5vw, 0.9rem);
  transition: all 0.3s ease;
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
  margin-bottom: 5px;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: #4caf50;
  box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
  background-color: rgba(255, 255, 255, 0.15);
}

/* Estilo para campos com erro */
.contact-form input.error,
.contact-form textarea.error {
  border-color: #f44336;
  box-shadow: 0 0 0 3px rgba(244, 67, 54, 0.1);
  animation: shake 0.5s ease-in-out;
}

/* Estilo para campos válidos */
.contact-form input.valid,
.contact-form textarea.valid {
  border-color: #4caf50;
}

.error-message {
  color: #f44336;
  font-size: 12px;
  margin-top: 5px;
  display: block;
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  font-weight: 500;
}

.error-message.show {
  opacity: 1;
  transform: translateY(0);
}

#submitBtn {
  position: relative;
  overflow: hidden;
  width: 100%;
}

.btn-loading {
  display: none;
}

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

.modal-content {
  background-color: white;
  margin: 15% auto;
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 400px;
  text-align: center;
  position: relative;
  animation: slideIn 0.3s ease;
  color: var(--dark);
}

.modal-icon {
  font-size: 48px;
  color: #4caf50;
  margin-bottom: 20px;
  font-weight: bold;
}

.close {
  position: absolute;
  right: 15px;
  top: 15px;
  font-size: 24px;
  cursor: pointer;
  color: #999;
}

.close:hover {
  color: #333;
}

.btn-modal {
  margin-top: 20px;
  background: var(--accent);
  color: white;
}

.btn-modal:hover {
  background: var(--accent_hover);
}

/* Animações */
@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px);
  }
  75% {
    transform: translateX(5px);
  }
}

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

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

/* Efeito de brilho para erro */
@keyframes glowError {
  0% {
    box-shadow: 0 0 5px rgba(244, 67, 54, 0.5);
  }
  50% {
    box-shadow: 0 0 20px rgba(244, 67, 54, 0.8);
  }
  100% {
    box-shadow: 0 0 5px rgba(244, 67, 54, 0.5);
  }
}

.contact-form input.error-glow,
.contact-form textarea.error-glow {
  animation: glowError 0.5s ease-in-out;
}

/* Placeholder com cor melhorada */
.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #ccc;
  opacity: 1;
}

.contact-form input:focus::placeholder,
.contact-form textarea:focus::placeholder {
  color: #eee;
}

@media (prefers-color-scheme: dark) {
  .logo { /* Use o seletor correto do seu logotipo */
    filter: none !important;
    /* 
      brightness(0.7): Reduz o brilho para 70%.
      contrast(1.1): Aumenta um pouco o contraste para não ficar lavado.
      Ajuste esses valores (0.5 a 0.9) até ficar agradável.
    */
  }
}