:root {
  --bg: #eef2f7;
  --card: #ffffff;
  --text: #2c3e50;
  --primary: #3498db;
  --highlight: #2ecc71;
}

body.dark {
  --bg: #121212;
  --card: #1e1e1e;
  --text: #f1f1f1;
  --primary: #2980b9;
}

body {
  font-family: 'Roboto', sans-serif;
  background: var(--bg);
  margin: 0;
  padding: 20px;
  color: var(--text);
  transition: 0.3s;
}

.container {
  max-width: 1000px;
  margin: auto;
  background: var(--card);
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

h1 {
  text-align: center;
  margin-bottom: 10px;
}

.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

button {
  padding: 8px 14px;
  border: none;
  border-radius: 6px;
  background: var(--primary);
  color: white;
  cursor: pointer;
  font-size: 14px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

th, td {
  padding: 12px;
  text-align: center;
  border-bottom: 1px solid #ccc;
}

th {
  background: var(--primary);
  color: white;
  position: sticky;
  top: 0;
}

tr:nth-child(even) {
  background: rgba(0,0,0,0.03);
}

tr:hover {
  background: rgba(52,152,219,0.15);
}

.highlight {
  background: var(--highlight) !important;
  color: white;
  font-weight: 600;
}

/* =========================
   Mobile Responsive Design
========================= */

@media (max-width: 768px) {

  body {
    padding: 10px;
  }

  .container {
    padding: 15px;
  }

  .top-bar {
    flex-direction: column;
    gap: 10px;
  }

  .top-bar h1 {
    font-size: 20px;
  }

  button {
    width: 100%;
  }

  table, tbody, tr, td {
    display: block;
  }

  table {
    border: none;
  }

  tr {
    background: var(--card);
    margin-bottom: 15px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    padding: 10px;
  }

  tr.highlight {
    border-left: 5px solid var(--highlight);
  }

  td {
    display: flex;
    justify-content: space-between;
    padding: 8px 10px;
    border: none;
    border-bottom: 1px solid #eee;
    font-size: 14px;
  }

  /* Day name */
  td:first-child {
    font-weight: 700;
    color: var(--primary);
    justify-content: center;
    font-size: 16px;
    border-bottom: 2px solid var(--primary);
    margin-bottom: 5px;
  }

  /* Period label */
  td::before {
    content: attr(data-label);
    font-weight: 500;
    color: #666;
  }

  /* FIX: Day cell e label show hobe na */
  td:first-child::before {
    content: "";
  }

  td:last-child {
    border-bottom: none;
  }
}
