/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background: #f9f9f9;
  color: #222;
  transition: background 0.3s, color 0.3s;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* Header */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #0077cc;
  color: white;
  padding: 15px;
}

header h1 {
  font-size: 20px;
}

header button {
  background: none;
  border: none;
  color: white;
  font-size: 22px;
  cursor: pointer;
}

/* Sidebar */
.sidebar {
  position: fixed;
  left: -260px;
  top: 0;
  width: 225px;
  height: 100%;
  background: #0077cc;
  color: white;
  transition: left 0.3s ease;
  padding-top: 60px;
  z-index: 1000;
  box-shadow: 2px 0 8px rgba(0,0,0,0.3);
}

.sidebar.active {
  left: 0;
}

.sidebar nav ul {
  list-style: none;
}

.sidebar nav ul li {
  margin: 20px 0;
}

.sidebar nav ul li a {
  color: white;
  text-decoration: none;
  font-size: 18px;
  display: block;
  padding: 10px;
  transition: background 0.2s;
}

.sidebar nav ul li a:hover,
.sidebar nav ul li a.active {
  background: rgba(255, 255, 255, 0.3);
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 22px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
}

/* Main content */
main {
  flex: 1;
  padding: 20px;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Dark mode */
body.dark {
  background: #1e1e1e;
  color: #f0f0f0;
}

body.dark header {
  background: #333;
}

body.dark .sidebar {
  background: #222;
}

/* Light mode tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
}

th, td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: left;
}

th {
  background: #f0f0f0;
  color: #222;
}

/* Dark mode tables */
body.dark table {
  border-color: #555;
}

body.dark th, 
body.dark td {
  border: 1px solid #555;
  color: #fff;
}

body.dark th {
  background: #333;
}

body.dark tr:nth-child(even) {
  background: #2a2a2a;
}

body.dark tr:nth-child(odd) {
  background: #1e1e1e;
}


