:root {
  --bg: #fff;
  --text: #222;
  --accent: #f2b705;
  --focus: rgba(242, 183, 5, 0.35);
  --radius: 1rem;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* LINKS E BOTÕES */
a,
button {
  cursor: pointer;
  transition: var(--transition);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.btn {
  background-color: var(--accent);
  color: #000;
  border: none;
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius);
  font-weight: bold;
}

.btn:hover {
  filter: brightness(1.1);
}

/* CABEÇALHO E MENU */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background-color: var(--accent);
  color: #000;
}

.nav-toggle {
  background: none;
  border: none;
  font-size: 1.6rem;
  display: none;
}

.primary-menu {
  display: flex;
  gap: 1rem;
  list-style: none;
}

.primary-menu a {
  text-decoration: none;
  color: #000;
  font-weight: 600;
  padding: 0.4rem 0.8rem;
}

.primary-menu a:hover {
  color: var(--bg);
}

/* MENU MOBILE */
@media (max-width: 599px) {
  .nav-toggle {
    display: inline-block;
  }

  .primary-menu {
    display: none;
    flex-direction: column;
    background: var(--accent);
    width: 100%;
    text-align: center;
    padding: 1rem 0;
  }

  .primary-menu.open {
    display: flex;
  }
}

@media (min-width: 600px) {
  .nav-toggle {
    display: none;
  }

  .primary-menu {
    display: flex !important;
  }
}

/* HERO */
.hero {
  text-align: center;
  padding: 3rem 1rem;
  background: url("../img/banner.jpg") center/cover no-repeat;
  color: #fff;
}

.hero h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
  text-shadow: 1px 1px 3px #000;
}

/* CONTEÚDO PRINCIPAL */
main {
  padding: 2rem;
}

/* FORMULÁRIOS */
form {
  display: grid;
  gap: 1rem;
  max-width: 500px;
  margin: 2rem auto;
}

fieldset {
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  padding: 1rem;
}

legend {
  font-weight: bold;
  color: var(--accent);
}

input,
select,
textarea {
  width: 100%;
  padding: 0.6rem;
  border: 1px solid #ccc;
  border-radius: var(--radius);
  transition: var(--transition);
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid var(--focus);
}

/* FEEDBACK DE FORMULÁRIO */
#form-message {
  text-align: center;
  padding: 1rem;
  font-weight: bold;
}

#form-message.success {
  color: green;
}

#form-message.error {
  color: red;
}

/* SKIP LINK */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--accent);
  color: #000;
  padding: 0.5rem 1rem;
  border-radius: 0 0 var(--radius) var(--radius);
  transition: var(--transition);
}

.skip-link:focus {
  top: 0;
}

/* IMAGENS */
img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
}

/* RODAPÉ */
footer {
  text-align: center;
  background: var(--accent);
  color: #000;
  padding: 1rem;
  margin-top: 3rem;
}
canvas#graficoGastos,
canvas#graficoDoacoes {
  width: 100%;
  max-width: 600px;
  height: 400px; 
  margin: 20px auto;
  display: block;
}

