* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f9f9f9;
}

.container {
  width: 90%;
  max-width: 1100px;
  margin: auto;
}

/* HEADER */

header {
  background: #2c3e50;
  color: #fff;
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

header h1 {
  font-size: 1.5rem;
}

header nav ul {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  flex-wrap: wrap;
}

header nav a {
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s;
}

header nav a:hover {
  color: #1abc9c;
}

/* SEÇÕES  */

section {
  padding: 4rem 0;
}

section .container {
  text-align: center;
}

/* HERO */

#hero {
  background: #ecf0f1;
  padding: 5rem 0;
}

#hero .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
}

#hero h2 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  color: #2c3e50;
}

.foto-perfil {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #1abc9c;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* SOBRE */

#sobre p {
  margin: 1rem 0;
}

#sobre ul {
  list-style: none;
  padding: 0;
}

#sobre li {
  background: #eaeaea;
  margin: 0.5rem 0;
  padding: 0.7rem;
  border-radius: 5px;
}

/* PROJETOS */

.grid-projetos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  text-align: left;
}

.projeto {
  background: #fff;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  transition: transform 0.2s ease;
}

.projeto:hover {
  transform: translateY(-5px);
}

#projetos h3 {
  margin-bottom: 0.5rem;
  color: #2c3e50;
}

#projetos a {
  color: #1abc9c;
  text-decoration: none;
  font-weight: bold;
}

#projetos a:hover {
  text-decoration: underline;
}

/* CONTATO  */

#contato .container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#contato ul {
  list-style: none;
  margin-top: 1rem;
}

#contato li {
  margin: 0.5rem 0;
}

#contato a {
  color: #2c3e50;
  text-decoration: none;
  font-weight: bold;
}

#contato a:hover {
  color: #1abc9c;
}

/* FOOTER */

footer {
  background: #2c3e50;
  color: #fff;
  text-align: center;
  padding: 1.5rem 0;
  margin-top: 2rem;
}

footer a {
  color: #1abc9c;
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

/* BOTÃO TOPO */

#btn-topo {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #1abc9c;
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 45px;
  height: 45px;
  font-size: 20px;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  transition: background 0.3s, transform 0.2s;
  z-index: 9999;
}

#btn-topo:hover {
  background: #16a085;
  transform: translateY(-3px);
}

/* MEDIA QUERIES */

@media (max-width: 768px) {
  header .container {
    flex-direction: column;
    text-align: center;
  }

  header nav ul {
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 1rem;
  }

  #hero h2 {
    font-size: 1.5rem;
  }
}

@media (min-width: 768px) {
  #hero .container {
    flex-direction: row;
    justify-content: center;
    text-align: left;
  }

  #hero img {
    margin-right: 2rem;
  }
}
