html,
body {
  height: 100%;
  margin: 0;
}

/* Estiloda barra de scroll */
::-webkit-scrollbar {
  width: 16px;
}

::-webkit-scrollbar-track {
  background-color: rgba(34, 68, 34, 0.6);
  border: 2px solid #2d5a2d;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, #4a8f4a 0%, #2d5a2d 100%);
  border: 2px solid #2d5a2d;
  border-right: 2px solid #1a3a1a;
  border-bottom: 2px solid #1a3a1a;
  border-left: 2px solid #6bb66b;
  border-top: 2px solid #6bb66b;
  box-shadow: inset -1px -1px 0 rgba(0, 0, 0, 0.3),
    inset 1px 1px 0 rgba(255, 255, 255, 0.1);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(135deg, #5fa55f 0%, #3d7a3d 100%);
}

/* Scrollbar para Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: #4a8f4a rgba(34, 68, 34, 0.6);
}

body {
  background-image: url("../assets/img/bg.jpg"); /* Atribuição: https://www.freepik.com/free-vector/pixel-art-rural-landscape-background_49685499.htm */
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

body:has(.instrucoes-container) {
  padding-bottom: 80px;
}

/* Animação em CSS efeito respiração */
@keyframes levitacaoBrilho {
  0% {
    transform: translateY(0) scale(1);
    filter: drop-shadow(0 15px 30px rgba(255, 255, 255, 0.5)) brightness(1)
      saturate(1.2);
  }
  50% {
    transform: translateY(-25px) scale(1.25);
    filter: drop-shadow(0 30px 60px rgba(255, 255, 255, 0.9)) brightness(1.3)
      saturate(1.4);
  }
  100% {
    transform: translateY(0) scale(1);
    filter: drop-shadow(0 15px 30px rgba(255, 255, 255, 0.5)) brightness(1)
      saturate(1.2);
  }
}

.logo {
  max-width: 300px;
  padding-top: 15vh;
  height: auto;
  animation: levitacaoBrilho 6s ease-in-out infinite;
  position: relative;
  z-index: 2;
}

/* Movimento horizontal discreto com retorno invisível para nuvem 1 */
@keyframes moveCloud1 {
  0% {
    transform: translateX(-200px);
    opacity: 0;
  }
  5% {
    opacity: 0.7;
  }
  95% {
    opacity: 0.7;
  }
  100% {
    transform: translateX(100vw);
    opacity: 0;
  }
}

/* Movimento horizontal discreto para nuvem 2 */
@keyframes moveCloud2 {
  0% {
    transform: translateX(-300px);
    opacity: 0;
  }
  5% {
    opacity: 0.8;
  }
  95% {
    opacity: 0.8;
  }
  100% {
    transform: translateX(100vw);
    opacity: 0;
  }
}

/* Movimento horizontal discreto para nuvem 3 */
@keyframes moveCloud3 {
  0% {
    transform: translateX(-250px);
    opacity: 0;
  }
  5% {
    opacity: 0.7;
  }
  95% {
    opacity: 0.7;
  }
  100% {
    transform: translateX(100vw);
    opacity: 0;
  }
}

/* Movimento horizontal discreto para nuvem 4 */
@keyframes moveCloud4 {
  0% {
    transform: translateX(-150px);
    opacity: 0;
  }
  5% {
    opacity: 0.6;
  }
  95% {
    opacity: 0.6;
  }
  100% {
    transform: translateX(100vw);
    opacity: 0;
  }
}

.clouds {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 33.33vh;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}

/* Estilos base para nuvens */
.cloud {
  position: absolute;
  top: 0;
  opacity: 0.8;
}

/* Nuvem 1 */
.cloud-1 {
  width: 80px;
  top: 5%;
  animation: moveCloud1 90s linear infinite;
  animation-delay: 0s;
}

/* Nuvem 2 */
.cloud-2 {
  width: 250px;
  top: 35%;
  animation: moveCloud2 85s linear infinite;
  animation-delay: -15s;
}

/* Nuvem 3 */
.cloud-3 {
  width: 180px;
  top: 50%;
  animation: moveCloud3 50s linear infinite;
  animation-delay: -30s;
}

/* Nuvem 4 */
.cloud-4 {
  width: 100px;
  top: 15%;
  animation: moveCloud4 120s linear infinite;
  animation-delay: -45s;
}

/* Menu arcade no terço inferior */
.arcade-menu {
  position: fixed;
  bottom: 20vh;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: 15px;
  align-items: center;
  z-index: 10;
  background-color: rgba(34, 68, 34, 0.8);
  padding: 30px 40px;
  border: 8px solid #2d5a2d;
  box-shadow: inset -4px -4px 0 rgba(0, 0, 0, 0.5),
    inset 4px 4px 0 rgba(255, 255, 255, 0.2), -8px 8px 0 rgba(0, 0, 0, 0.5);
}

.menu-button {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 20px;
  padding: 12px 32px;
  width: 200px;
  text-align: center;
  background: linear-gradient(135deg, #4a8f4a 0%, #2d5a2d 100%);
  color: #e8f5e9;
  border: 4px solid #2d5a2d;
  border-right: 4px solid #1a3a1a;
  border-bottom: 4px solid #1a3a1a;
  border-left: 4px solid #6bb66b;
  border-top: 4px solid #6bb66b;
  cursor: pointer;
  transition: all 0.1s ease;
  letter-spacing: 1px;
  font-weight: bold;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.4), inset -1px -1px 0 rgba(0, 0, 0, 0.3);
}

.menu-button:hover {
  background: linear-gradient(135deg, #5fa55f 0%, #3d7a3d 100%);
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.5), inset -1px -1px 0 rgba(0, 0, 0, 0.4);
  transform: translate(-2px, -2px);
}

.menu-button:active {
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.3), inset 1px 1px 0 rgba(0, 0, 0, 0.5);
  transform: translate(2px, 2px);
  border: 4px solid #1a3a1a;
  border-right: 4px solid #6bb66b;
  border-bottom: 4px solid #6bb66b;
  border-left: 4px solid #2d5a2d;
  border-top: 4px solid #2d5a2d;
}

.menu-link {
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 200px;
  box-sizing: border-box;
}

/* Rodapé */
.arcade-footer {
  font-family: "Pixelify Sans", sans-serif;
  position: fixed;
  bottom: 10px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 12px;
  color: #4a8f4a;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  z-index: 10;
}

/* Página de créditos */
.back-button {
  font-family: "Pixelify Sans", sans-serif;
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 11;
  padding: 10px 20px;
  background: linear-gradient(135deg, #4a8f4a 0%, #2d5a2d 100%);
  color: #e8f5e9;
  border: 4px solid #2d5a2d;
  border-right: 4px solid #1a3a1a;
  border-bottom: 4px solid #1a3a1a;
  border-left: 4px solid #6bb66b;
  border-top: 4px solid #6bb66b;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.1s ease;
  letter-spacing: 1px;
  font-weight: bold;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.4), inset -1px -1px 0 rgba(0, 0, 0, 0.3);
  font-size: 14px;
  display: inline-block;
}

.back-button:hover {
  background: linear-gradient(135deg, #5fa55f 0%, #3d7a3d 100%);
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.5), inset -1px -1px 0 rgba(0, 0, 0, 0.4);
  transform: translate(-2px, -2px);
}

.back-button:active {
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.3), inset 1px 1px 0 rgba(0, 0, 0, 0.5);
  transform: translate(2px, 2px);
  border: 4px solid #1a3a1a;
  border-right: 4px solid #6bb66b;
  border-bottom: 4px solid #6bb66b;
  border-left: 4px solid #2d5a2d;
  border-top: 4px solid #2d5a2d;
}

.credits-container {
  position: relative;
  z-index: 5;
  max-width: 800px;
  margin: 40px auto 120px auto;
  padding: 40px;
  background-color: rgba(34, 68, 34, 0.85);
  border: 8px solid #2d5a2d;
  box-shadow: inset -4px -4px 0 rgba(0, 0, 0, 0.5),
    inset 4px 4px 0 rgba(255, 255, 255, 0.2), -8px 8px 0 rgba(0, 0, 0, 0.5);
  font-family: "Pixelify Sans", sans-serif;
  color: #e8f5e9;
  line-height: 1.8;
  overflow-y: auto;
  max-height: calc(100vh - 200px);
}

.credits-container h1 {
  text-align: center;
  font-size: 32px;
  color: #6bb66b;
  margin-top: 0;
  margin-bottom: 30px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.credits-section {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid #2d5a2d;
}

.credits-section:last-child {
  border-bottom: none;
}

.credits-section h2 {
  font-size: 20px;
  color: #6bb66b;
  margin-top: 0;
  margin-bottom: 15px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.credits-section p {
  margin: 10px 0;
  font-size: 14px;
}

.credits-section ul,
.credits-section ol {
  margin: 10px 0;
  padding-left: 30px;
  font-size: 14px;
}

.credits-section li {
  margin: 8px 0;
}

.credits-section.institution {
  text-align: center;
  border-bottom: none;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 2px solid #2d5a2d;
}

.credits-section.institution p {
  margin: 10px 0;
  font-size: 14px;
  font-weight: bold;
}

/* Página de opções */
.settings-container {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 5;
  width: 600px;
  max-width: 90vw;
  height: auto;
  padding: 40px;
  background-color: rgba(34, 68, 34, 0.85);
  border: 8px solid #2d5a2d;
  box-shadow: inset -4px -4px 0 rgba(0, 0, 0, 0.5),
    inset 4px 4px 0 rgba(255, 255, 255, 0.2), -8px 8px 0 rgba(0, 0, 0, 0.5);
  font-family: "Pixelify Sans", sans-serif;
  color: #e8f5e9;
}

.settings-container h1 {
  text-align: center;
  font-size: 32px;
  color: #6bb66b;
  margin-top: 0;
  margin-bottom: 30px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.settings-content {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.settings-section {
  padding: 20px;
  background-color: rgba(22, 42, 22, 0.6);
  border: 4px solid #2d5a2d;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.settings-section h2 {
  font-size: 20px;
  color: #6bb66b;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.settings-buttons-group {
  display: flex;
  gap: 15px;
  justify-content: center;
  width: 100%;
  flex-wrap: wrap;
}

.settings-buttons-group .menu-button {
  flex: 1;
  min-width: 150px;
  max-width: 220px;
}

.settings-section .menu-button {
  width: 220px;
}

/* Modal de Confirmação Customizado */
.arcade-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 3000;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease-in;
}

.arcade-modal.show {
  display: flex;
}

.arcade-modal-content {
  background-color: rgba(34, 68, 34, 0.95);
  padding: 40px 50px;
  border: 8px solid #2d5a2d;
  box-shadow: inset -4px -4px 0 rgba(0, 0, 0, 0.5),
    inset 4px 4px 0 rgba(255, 255, 255, 0.2), -8px 8px 0 rgba(0, 0, 0, 0.5),
    0 0 50px rgba(0, 255, 0, 0.3);
  text-align: center;
  animation: popupBounce 0.5s ease-out;
  min-width: 400px;
  font-family: "Pixelify Sans", sans-serif;
}

.arcade-modal-content h2 {
  font-size: 36px;
  color: #e8f5e9;
  margin: 0 0 20px 0;
  letter-spacing: 2px;
  font-weight: bold;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.arcade-modal-content p {
  color: #e8f5e9;
  font-size: 18px;
  margin: 20px 0;
  line-height: 1.6;
}

.arcade-modal-buttons {
  display: flex;
  gap: 15px;
  margin-top: 30px;
  justify-content: center;
}

.arcade-modal-buttons button {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 18px;
  padding: 15px 30px;
  cursor: pointer;
  transition: all 0.1s ease;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: bold;
  border: 4px solid #2d5a2d;
}

.arcade-modal-buttons .confirm-btn {
  background: linear-gradient(135deg, #d84444 0%, #b83232 100%);
  color: #e8f5e9;
  border-right: 4px solid #8b1f1f;
  border-bottom: 4px solid #8b1f1f;
  border-left: 4px solid #e74c3c;
  border-top: 4px solid #e74c3c;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.4), inset -1px -1px 0 rgba(0, 0, 0, 0.3);
}

.arcade-modal-buttons .confirm-btn:hover {
  background: linear-gradient(135deg, #e85555 0%, #cc4040 100%);
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.5), inset -1px -1px 0 rgba(0, 0, 0, 0.4);
  transform: translate(-2px, -2px);
}

.arcade-modal-buttons .confirm-btn:active {
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.3), inset 1px 1px 0 rgba(0, 0, 0, 0.5);
  transform: translate(2px, 2px);
}

.arcade-modal-buttons .cancel-btn {
  background: linear-gradient(135deg, #4a8f4a 0%, #2d5a2d 100%);
  color: #e8f5e9;
  border-right: 4px solid #1a3a1a;
  border-bottom: 4px solid #1a3a1a;
  border-left: 4px solid #6bb66b;
  border-top: 4px solid #6bb66b;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.4), inset -1px -1px 0 rgba(0, 0, 0, 0.3);
}

.arcade-modal-buttons .cancel-btn:hover {
  background: linear-gradient(135deg, #5fa55f 0%, #3d7a3d 100%);
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.5), inset -1px -1px 0 rgba(0, 0, 0, 0.4);
  transform: translate(-2px, -2px);
}

.arcade-modal-buttons .cancel-btn:active {
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.3), inset 1px 1px 0 rgba(0, 0, 0, 0.5);
  transform: translate(2px, 2px);
}

@keyframes popupBounce {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

/* Instruções Página */
.instrucoes-container {
  width: 90%;
  max-width: 900px;
  margin: 30px auto;
  background-color: rgba(22, 42, 22, 0.8);
  border: 8px solid #2d5a2d;
  padding: 40px;
  box-shadow: inset -4px -4px 0 rgba(0, 0, 0, 0.5),
    inset 4px 4px 0 rgba(255, 255, 255, 0.1), -8px 8px 0 rgba(0, 0, 0, 0.5),
    0 0 50px rgba(0, 255, 0, 0.2);
}

.instrucoes-container h1 {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 36px;
  color: #6bb66b;
  text-align: center;
  margin: 0 0 30px 0;
  text-shadow: 4px 4px 0 rgba(0, 0, 0, 0.5);
  letter-spacing: 2px;
}

.instrucoes-secao {
  margin-bottom: 30px;
  padding: 20px;
  background-color: rgba(0, 0, 0, 0.2);
  border: 4px solid #2d5a2d;
  border-radius: 4px;
}

.instrucoes-secao h2 {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 22px;
  color: #a5d6a7;
  margin: 0 0 15px 0;
  letter-spacing: 1px;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.5);
  border-bottom: 2px solid #4a8f4a;
  padding-bottom: 8px;
}

.instrucoes-secao h3 {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 16px;
  color: #c8e6c9;
  margin: 15px 0 8px 0;
  letter-spacing: 0.5px;
  font-weight: bold;
}

.instrucoes-secao p,
.instrucoes-secao li {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 14px;
  color: #e8f5e9;
  line-height: 1.6;
  margin: 8px 0;
}

.instrucoes-secao ul,
.instrucoes-secao ol {
  margin: 12px 0;
  padding-left: 25px;
}

.instrucoes-secao li {
  margin: 6px 0;
}

.instrucoes-item {
  background-color: rgba(74, 143, 74, 0.1);
  border-left: 3px solid #4a8f4a;
  padding: 12px;
  margin: 12px 0;
  border-radius: 2px;
  font-size: 14px;
  color: #e8f5e9;
}

.instrucoes-item strong {
  color: #a5d6a7;
  font-weight: bold;
}

.instrucoes-item p {
  color: #e8f5e9;
  margin: 0;
}

.pontos-positivos {
  background-color: rgba(107, 197, 107, 0.1);
  border-left: 3px solid #6bb66b;
}

.pontos-negativos {
  background-color: rgba(255, 68, 68, 0.15);
  border-left: 3px solid #ff4444;
}

.pontos-negativos strong {
  color: #ffaaaa;
  font-weight: bold;
}

.pontos-negativos p {
  color: #ffaaaa;
}

.modo-seletor {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin: 15px 0;
}

.modo-card {
  padding: 15px;
  background-color: rgba(74, 143, 74, 0.15);
  border: 2px solid #2d5a2d;
  border-radius: 3px;
  text-align: center;
}

.modo-card h4 {
  font-family: "Pixelify Sans", sans-serif;
  font-size: 16px;
  color: #6bb66b;
  margin: 0 0 10px 0;
  letter-spacing: 1px;
}

.modo-card p {
  font-size: 13px;
  color: #c8e6c9;
  margin: 0;
}

.tabela-residuos {
  width: 100%;
  border-collapse: collapse;
  margin: 15px 0;
  background-color: rgba(0, 0, 0, 0.3);
  font-size: 13px;
}

.tabela-residuos th,
.tabela-residuos td {
  padding: 10px;
  text-align: center;
  border: 2px solid #2d5a2d;
  color: #e8f5e9;
  font-family: "Pixelify Sans", sans-serif;
}

.tabela-residuos th {
  background-color: rgba(74, 143, 74, 0.3);
  color: #a5d6a7;
  font-weight: bold;
}

.tabela-residuos tr:hover {
  background-color: rgba(74, 143, 74, 0.15);
}

.ecoponto-badge {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 2px;
  font-weight: bold;
  font-size: 11px;
  letter-spacing: 0.5px;
}

.azul {
  background-color: rgba(100, 200, 255, 0.3);
  color: #64c8ff;
  border: 1px solid #64c8ff;
}

.verde {
  background-color: rgba(100, 200, 100, 0.3);
  color: #64c864;
  border: 1px solid #64c864;
}

.amarelo {
  background-color: rgba(255, 200, 100, 0.3);
  color: #ffc864;
  border: 1px solid #ffc864;
}

.cinzento {
  background-color: rgba(150, 150, 150, 0.3);
  color: #b0b0b0;
  border: 1px solid #b0b0b0;
}

.botoes-voltar {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 30px;
  margin-bottom: 80px;
  flex-wrap: wrap;
}

.botoes-voltar a {
  text-decoration: none;
}

@media (max-width: 768px) {
  .instrucoes-container {
    width: 95%;
    padding: 25px 15px;
  }

  .instrucoes-container h1 {
    font-size: 28px;
    margin-bottom: 20px;
  }

  .instrucoes-secao {
    margin-bottom: 20px;
    padding: 15px;
  }

  .instrucoes-secao h2 {
    font-size: 18px;
  }

  .instrucoes-secao p,
  .instrucoes-secao li {
    font-size: 13px;
  }

  .modo-seletor {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .tabela-residuos {
    font-size: 12px;
  }

  .tabela-residuos th,
  .tabela-residuos td {
    padding: 8px 5px;
  }

  .botoes-voltar {
    margin-bottom: 80px;
  }
}
