/* === BASE GERAL === */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Arial', sans-serif;
  background: #3B85B4; /* Azul do logo */
  color: white;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
}

/* === CONTEÚDO CENTRAL === */
.tela-centro {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  flex: 1;
  width: 100%;
  padding: 2rem 1rem;
}

/* === LOGO === */
.logo {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 1.2rem;
}

.logo img {
  width: 220px;
  height: auto;
  max-width: 90%;
}

/* === NAVEGAÇÃO === */
nav {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

nav a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  transition: opacity 0.2s ease;
}

nav a:hover {
  opacity: 0.8;
}

/* === FORMULÁRIO DE PESQUISA === */
#searchForm {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* === CAIXA BRANCA === */
.search-bar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  width: 90%;
  max-width: 800px;
  padding: 1.2rem;
}

/* === LINHAS === */
.linha {
  display: flex;
  gap: 0.8rem;
  justify-content: center;
  flex-wrap: wrap;
  width: 100%;
}

.linha-principal input {
  width: 100%;
  max-width: 100%;
}

/* === FILTROS IGUAIS === */
.linha-filtros {
  display: flex;
  gap: 0.8rem;
  justify-content: center;
  width: 100%;
  flex-wrap: wrap;
}

.linha-filtros input,
.linha-filtros select {
  flex: 1 1 0;
  min-width: 0;
  width: 100%;
  max-width: none;
}

/* === INPUTS E SELECTS === */
.search-bar input,
.search-bar select {
  height: 45px;
  padding: 0.8rem 1rem;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  color: #333;
  transition: all 0.2s ease;
}

.search-bar input:focus,
.search-bar select:focus {
  outline: none;
  border-color: #007acc;
  box-shadow: 0 0 0 2px rgba(0,122,204,0.2);
}

/* === BOTÃO === */
.botao-pesquisar {
  background: #ffffff;
  color: #3B85B4;
  font-weight: bold;
  border: none;
  border-radius: 8px;
  padding: 0.8rem 1.6rem;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.1s ease;
  margin-top: 1rem;
}

.botao-pesquisar:hover {
  background: #e9f3fa;
}

.botao-pesquisar:active {
  transform: scale(0.98);
}

/* === FOOTER === */
footer {
  text-align: center;
  background-color: #2F6E93;
  padding: 1rem;
  font-size: 0.9rem;
  width: 100%;
  color: white;
  box-shadow: 0 -2px 6px rgba(0,0,0,0.1);
}

/* === RESPONSIVIDADE === */

/* Tablets (até 900px) */
@media (max-width: 900px) {
  .search-bar {
    max-width: 600px;
    gap: 1rem;
  }

  .linha-filtros {
    flex-wrap: nowrap;
  }

  .linha-filtros input,
  .linha-filtros select {
    width: 100%;
  }

  .botao-pesquisar {
    width: 100%;
    max-width: 300px;
  }

  nav {
    gap: 1rem;
    font-size: 0.95rem;
  }
}

/* Smartphones (até 600px) */
@media (max-width: 600px) {
  body {
    justify-content: flex-start;
    padding-top: 2rem;
  }

  .tela-centro {
    padding-top: 1.5rem;
  }

  .logo img {
    width: 150px;
  }

  nav {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
  }

  nav a {
    font-size: 0.9rem;
  }

  .search-bar {
    padding: 0.8rem;
    gap: 0.8rem;
    border-radius: 12px;
    max-width: 340px;
  }

  .linha-filtros {
    flex-direction: column;
    gap: 0.6rem;
  }

  .search-bar input,
  .search-bar select {
    border-radius: 6px;
    font-size: 0.95rem;
    padding: 0.7rem;
    height: auto;
  }

  .botao-pesquisar {
    width: 100%;
    max-width: 340px;
    font-size: 0.95rem;
  }

  footer {
    font-size: 0.75rem;
    padding: 0.8rem;
  }
}
