* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
  
body {
  font-family: Arial, sans-serif;
  background: #f5f5f5;
  min-height: 100vh;
}

.wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.container {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.controles {
  text-align: center;
  margin-bottom: 30px;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

input {
  padding: 10px;
  font-size: 16px;
  width: 250px;
  border: 1px solid #ccc;
  border-radius: 3px;
  outline: none;
  background: white;
}

input:focus {
  border-color: #888;
}

button {
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;
  border: 1px solid #ccc;
  border-radius: 3px;
  background: #e0e0e0;
  color: #333;
}

#btnBuscar {
  background: #e0e0e0;
}

#btnListar {
  background: #e0e0e0;
}

#btnLimpar {
  background: #e0e0e0;
}

.resultado {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.card {
  background: white;
  border: 1px solid #ddd;
  border-radius: 3px;
  padding: 20px;
  width: 250px;
  text-align: center;
  box-shadow: none;
}

.card img {
  width: 150px;
  height: 150px;
}

.card h3 {
  margin: 10px 0;
  text-transform: capitalize;
  font-size: 18px;
  color: #333;
}

.card p {
  margin: 5px 0;
  color: #666;
  font-size: 14px;
}

.erro {
  color: #d32f2f;
  text-align: center;
  padding: 20px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 3px;
}

.loading {
  text-align: center;
  padding: 20px;
  font-size: 18px;
  color: #666;
}

/* Estilos para a lista de Pokémon */
.lista-container {
  background: white;
  border: 1px solid #ddd;
  border-radius: 3px;
  padding: 20px;
  width: 100%;
  max-width: 350px;
  margin: 0 auto;
}

.lista-container h3 {
  text-align: center;
  margin-bottom: 20px;
  color: #333;
  font-size: 18px;
  font-weight: normal;
}

.pokemon-lista {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 200px;
  overflow-y: auto;
}

.pokemon-item {
  display: flex;
  align-items: center;
  padding: 10px;
  border-bottom: 1px solid #eee;
}

.pokemon-id {
  font-weight: normal;
  color: #888;
  min-width: 60px;
  font-family: monospace;
  font-size: 14px;
}

.pokemon-nome {
  flex: 1;
  text-transform: capitalize;
  cursor: pointer;
  color: #555;
  font-size: 14px;
}

.pokemon-nome:hover {
  color: #000;
  text-decoration: underline;
}

.contador {
  background: #e0e0e0;
  color: #333;
  padding: 8px 15px;
  border-radius: 3px;
  font-size: 14px;
  text-align: center;
  margin-top: 10px;
  border: 1px solid #ccc;
}

/* Scrollbar para a lista */
.pokemon-lista::-webkit-scrollbar {
  width: 8px;
}

.pokemon-lista::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.pokemon-lista::-webkit-scrollbar-thumb {
  background: #ccc;
}

.pokemon-lista::-webkit-scrollbar-thumb:hover {
  background: #aaa;
}

/* Rodapé */
.rodape {
  background: #e0e0e0;
  color: #333;
  text-align: left;
  padding: 15px;
  margin-top: 40px;
  border-top: 1px solid #ccc;
}

.rodape p {
  font-size: 14px;
}

.rodape strong {
  color: #555;
}

/* Responsividade */
@media (max-width: 768px) {
  .controles {
    flex-direction: column;
    align-items: center;
  }

  input,
  button {
    width: 100%;
    max-width: 300px;
  }

  .card {
    width: 100%;
    max-width: 280px;
  }

  .lista-container {
    max-width: 95%;
  }
}