body {
  font-family: Arial, sans-serif;
  max-width: 1200px;
  margin: 20px auto;
  padding: 10px;
  background-color: #f5f5f5;
}

@media (max-width: 768px) {
  body {
  margin: 10px;
  padding: 5px;
  }
}
.container {
  background-color: white;
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  margin-bottom: 20px;
}

@media (max-width: 768px) {
  .container {
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 6px;
  }
}
h1 {
  text-align: center;
  color: #333;
  margin-bottom: 30px;
  font-size: 2.2em;
}

h2 {
  color: #444;
  border-bottom: 2px solid #4CAF50;
  padding-bottom: 10px;
  font-size: 1.5em;
}

@media (max-width: 768px) {
  h1 {
    font-size: 1.8em;
    margin-bottom: 20px;
  }
  
  h2 {
    font-size: 1.3em;
    padding-bottom: 8px;
  }
}
.section {
  margin-bottom: 30px;
}
.input-group {
  margin-bottom: 15px;
}
label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  color: #555;
}
input, select {
  width: 100%;
  padding: 8px;
  border: 2px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
}
input:focus, select:focus {
  border-color: #4CAF50;
  outline: none;
}
.subject-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 80px;
  gap: 10px;
  align-items: end;
  margin-bottom: 10px;
}

@media (max-width: 768px) {
  .subject-row {
    grid-template-columns: 1fr;
    gap: 8px;
    margin-bottom: 15px;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 6px;
  }
}
.timetable {
  display: grid;
  grid-template-columns: 100px repeat(4, 1fr);
  gap: 5px;
  margin-bottom: 20px;
  overflow-x: auto;
}

@media (max-width: 768px) {
  .timetable {
    grid-template-columns: 80px repeat(4, minmax(80px, 1fr));
    gap: 3px;
    font-size: 12px;
    margin-bottom: 15px;
  }
}

@media (max-width: 480px) {
  .timetable {
    grid-template-columns: 60px repeat(4, minmax(60px, 1fr));
    gap: 2px;
    font-size: 11px;
  }
}
.timetable-header {
  font-weight: bold;
  text-align: center;
  padding: 10px 5px;
  background-color: #4CAF50;
  color: white;
  border-radius: 4px;
}

.timetable-day {
  font-weight: bold;
  text-align: center;
  padding: 10px 5px;
  background-color: #e8f5e8;
  border-radius: 4px;
}

.timetable-cell select {
  font-size: 12px;
  padding: 5px;
  width: 100%;
}

@media (max-width: 768px) {
  .timetable-header {
    padding: 8px 2px;
    font-size: 11px;
  }
  
  .timetable-day {
    padding: 8px 2px;
    font-size: 11px;
  }
  
  .timetable-cell select {
    font-size: 10px;
    padding: 3px;
  }
}
.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  margin: 5px;
  transition: background-color 0.3s;
}

/* Mobile buttons */
@media (max-width: 768px) {
  .btn {
    padding: 12px 16px;
    font-size: 14px;
    margin: 3px;
    min-height: 44px;
  }
}

.button-container {
  text-align: center;
  margin: 20px 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

@media (max-width: 768px) {
  .button-container {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }
  
  .button-container .btn {
    width: 90%;
    max-width: 300px;
    margin: 0;
  }
}
.btn-primary {
  background-color: #4CAF50;
  color: white;
}
.btn-secondary {
  background-color: #2196F3;
  color: white;
}
.btn-danger {
  background-color: #f44336;
  color: white;
}
.results {
  margin-top: 20px;
}
.subject-result {
  margin-bottom: 20px;
  padding: 15px;
  background-color: #f9f9f9;
  border-radius: 5px;
  border-left: 4px solid #4CAF50;
}
.low-attendance {
  color: #d32f2f;
  border-left-color: #d32f2f;
}
.good-attendance {
  color: #388e3c;
}
.summary {
  background-color: #e3f2fd;
  padding: 20px;
  border-radius: 8px;
  margin-top: 20px;
}
.weekly-classes {
  font-size: 14px;
  color: #666;
  margin-top: 10px;
}