/* =======================
   Global Styles
======================= */
body {
  font-family: 'Arial', sans-serif;
  margin: 0;
  padding: 0;
  background: #f4f7f6;
  color: #1b5e20;
  line-height: 1.6;
}

/* =======================
   Navbar
======================= */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #2e7d32;
  padding: 0.5rem 2rem;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* Make navbar full width on all devices */
.navbar {
  width: 100%;
  box-sizing: border-box; /* ensures padding doesn't shrink width */
  padding: 0.8rem 1rem;    /* adjust padding as needed */
}

/* Remove any default body margin/padding that affects full-width */
body, html {
  margin: 0;
  padding: 0;
  width: 100%;
}

/* Optional: ensure navbar content wraps nicely on small screens */
@media screen and (max-width: 450px) {
  .navbar {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }

  .nav-logo {
    text-align: center;
    margin-bottom: 0.4rem;
  }

  .nav-links {
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 0.4rem;
  }

  .nav-links li a {
    width: 100%;
    display: block;
    text-align: center;
    padding: 0.5rem 0;
  }
}


.nav-logo {
  font-size: 1.4rem;
  font-weight: bold;
  letter-spacing: 0.5px;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

.nav-links li a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  transition: background 0.2s, transform 0.2s;
}

.nav-links li a:hover {
  background: #1b5e20;
  transform: translateY(-1px);
}

/* =======================
   Main Content
======================= */
.main-content {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem;
  text-align: center;
}

/* Headings */
h2 {
  font-size: 2.2rem;
  font-weight: bold;
  margin-bottom: 15px;
  color: #2e7d32;
}

h3 {
  margin-top: 25px;
  margin-bottom: 10px;
  font-size: 1.4rem;
  font-weight: bold;
  color: #2e7d32;
}

/* Status messages */
#userStatus, #status {
  font-weight: 600;
  margin-bottom: 20px;
  font-size: 1.1rem;
  color: #1b5e20;
}

/* =======================
   Table Styling
======================= */
table {
  width: 100%;
  max-width: 700px;
  border-collapse: collapse;
  margin-bottom: 20px;
  background: #ffffff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

thead {
  background-color: #2e7d32;
  color: #fff;
}

th, td {
  padding: 12px 15px;
  text-align: center;
  font-size: 1rem;
}

tbody tr:nth-child(even) {
  background-color: #f1fdf1;
}

tbody tr:hover {
  background-color: #dcedc8;
  transition: background 0.2s;
}

/* Highlight Total Points and Total Images */
#totalPoints, #totalImages {
  font-size: 1.2rem;
  font-weight: bold;
  color: #1b5e20;
}

/* =======================
   Progress Bars Styling
======================= */
.progress-container {
  margin: 12px 0;
}

.progress-container span {
  font-weight: 600;
  display: block;
  margin-bottom: 5px;
}

.progress-bar-bg {
  width: 100%;
  background: #e0e0e0;
  height: 20px;
  border-radius: 10px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  border-radius: 10px;
  transition: width 0.5s ease-in-out;
}

/* Different colors for each bar */
#moduleProgressBar {
  background-color: #4caf50; /* green */
}

#uploadProgressBar {
  background-color: #2196f3; /* blue */
}

#pointsProgressBar {
  background-color: #ff9800; /* orange */
}

/* =======================
   Responsive
======================= */
@media screen and (max-width: 600px) {
  body {
    padding: 15px;
  }

  h2 {
    font-size: 1.6rem;
  }

  h3 {
    font-size: 1.2rem;
  }

  th, td {
    font-size: 0.9rem;
    padding: 8px 10px;
  }

  #userStatus, #status {
    font-size: 1rem;
  }

  .progress-bar-bg {
    height: 16px;
  }
}

