html, body, div, p, h1, h2, h3, header, footer, section, article {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}


body {
  font-family: Arial, sans-serif;
  background-color: #F7F7F7; /* Putih Bersih */
  color: #3A5A40; /* Hijau Gelap */
  display: flex;
  flex-direction: column;
  align-items: center;
}

header {
  background-color: #5BA973; /* Hijau Daun */
  width: 100%;
  padding: 1rem;
  text-align: center;
  color: white;
}

h1 {
  font-size: 1.5rem;
}

.controls {
  margin: 1rem 0;
}

button {
  background-color: #5BA973; /* Hijau Daun */
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 5px;
  cursor: pointer;
  margin: 0 0.5rem;
  font-size: 1rem;
}

button:hover {
  background-color: #3A5A40; /* Hijau Gelap */
}

.section-title h2 {
  margin: 2rem 0 0.5rem;
  text-align: center;
  color: #3A5A40; /* Hijau Gelap */
}

.rak-heading {
  margin: 0.5rem 0;
  text-align: center;
  font-size: 1.2rem;
  color: #D9D2C2; /* Krem Tanah */
}

/* Layout for the dashboard section with four cards in a row */
.dashboard {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* Four equal columns in one row */
  gap: 1rem;
  width: 100%;
  max-width: 800px; /* Adjusted width */
}

.card {
  background-color: white;
  padding: 1rem;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.card h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
  color: #3A5A40; /* Hijau Gelap */
}

.card p {
  font-size: 1.5rem;
  font-weight: bold;
  color: #3A5A40; /* Hijau Gelap */
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
  .dashboard {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); /* Auto layout for smaller screens */
  }
}

@media (max-width: 600px) {
  h1 {
    font-size: 1.2rem;
  }

  .card h3 {
    font-size: 0.9rem;
  }

  .card p {
    font-size: 1.2rem;
  }
}

.greenhouse-monitoring {
  margin-top: 2rem;
  text-align: center;
}

#monitorGreenhouse {
  background-color: #9AC9E3; /* Biru Air */
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 5px;
  font-size: 1rem;
  cursor: pointer;
}

#monitorGreenhouse:hover {
  background-color: #5BA973; /* Hijau Daun */
}

.back-home {
  margin: 2rem 0 1rem 0; /* Adds top margin */
  text-align: center;
}

#backHome {
  background-color: #9AC9E3; /* Biru Air */
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 5px;
  font-size: 1rem;
  cursor: pointer;
}

#backHome:hover {
  background-color: #5BA973; /* Hijau Daun */
}

.charts-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
}

canvas {
  height: 150px;
  width: 100%;
}
