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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  padding: 20px;
}

.container {
  max-width: 800px;
  margin: 0 auto;
}

.container-wide {
  max-width: 1200px;
  margin: 0 auto;
}

h1 {
  color: white;
  text-align: center;
  margin-bottom: 30px;
  font-size: 2em;
}

h2 {
  color: #333;
  margin-bottom: 20px;
  font-size: 1.5em;
}

h3 {
  color: #555;
  margin: 20px 0 10px;
}

.card {
  background: white;
  border-radius: 12px;
  padding: 25px;
  margin-bottom: 20px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

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

.employee-badge {
  background: #667eea;
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-weight: 600;
  margin-right: 10px;
}

.btn-logout {
  background: #f56565;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-logout:hover {
  background: #e53e3e;
}

.form-group {
  margin-bottom: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 8px;
  color: #555;
  font-weight: 500;
}

input[type="text"],
input[type="number"],
input[type="time"],
input[type="password"],
select {
  width: 100%;
  padding: 12px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 16px;
  transition: border-color 0.3s;
}

input:focus,
select:focus {
  outline: none;
  border-color: #667eea;
}

.section-title {
  font-size: 1.2em;
  font-weight: 600;
  color: #333;
  margin: 25px 0 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid #f0f0f0;
}

.activity-row {
  display: grid;
  grid-template-columns: 2fr 1fr 2fr auto;
  gap: 10px;
  margin-bottom: 10px;
  align-items: center;
}

.detail-input {
  padding: 10px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-size: 14px;
}

.activity-select {
  padding: 10px;
}

.qty-input {
  padding: 10px;
}

.btn-primary {
  background: #667eea;
  color: white;
  border: none;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  margin-top: 10px;
  transition: background 0.3s;
}

.btn-primary:hover {
  background: #5568d3;
}

.btn-secondary {
  background: white;
  color: #667eea;
  border: 2px solid #667eea;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s;
  display: inline-block;
}

.btn-secondary:hover {
  background: #667eea;
  color: white;
}

.btn-add {
  background: #48bb78;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 20px;
  transition: background 0.3s;
}

.btn-add:hover {
  background: #38a169;
}

.btn-remove {
  background: #f56565;
  color: white;
  border: none;
  padding: 10px 15px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-remove:hover {
  background: #e53e3e;
}

.btn-delete {
  background: #f56565;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.3s;
}

.btn-delete:hover {
  background: #e53e3e;
}

.checkbox-group {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
}

.checkbox-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: normal;
}

.checkbox-group input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.result {
  margin-top: 25px;
  padding: 20px;
  background: #f7fafc;
  border-radius: 8px;
  border-left: 4px solid #667eea;
}

.result p {
  margin: 8px 0;
  color: #555;
}

.result .total {
  font-size: 1.3em;
  color: #667eea;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 2px solid #e0e0e0;
}

.success-msg {
  color: #48bb78;
  font-weight: 600;
  margin-top: 10px;
}

.admin-link {
  display: block;
  text-align: center;
  color: white;
  text-decoration: none;
  font-weight: 600;
  margin-top: 20px;
  padding: 10px;
  transition: opacity 0.3s;
}

.admin-link:hover {
  opacity: 0.8;
}

.error {
  color: #f56565;
  margin-top: 10px;
  font-weight: 500;
}

/* Table Styles */
.table-container {
  overflow-x: auto;
  margin-bottom: 20px;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
}

.data-table thead {
  background: #667eea;
  color: white;
}

.data-table th {
  padding: 12px;
  text-align: left;
  font-weight: 600;
  white-space: nowrap;
}

.data-table td {
  padding: 12px;
  border-bottom: 1px solid #e0e0e0;
}

.data-table tr:hover {
  background: #f7fafc;
}

.table-input {
  width: 100%;
  padding: 6px 10px;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  font-size: 14px;
}

.table-input:focus {
  outline: none;
  border-color: #667eea;
}

.add-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.add-row input,
.add-row select {
  flex: 1;
  min-width: 150px;
}

.add-row button {
  margin-bottom: 0;
}

ul {
  list-style-position: inside;
  margin-left: 15px;
}

ul li {
  margin: 8px 0;
  color: #555;
}

@media (max-width: 768px) {
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .activity-row {
    grid-template-columns: 1fr;
  }
  
  .btn-remove {
    width: 100%;
  }
  
  .checkbox-group {
    flex-direction: column;
    gap: 10px;
  }

  .header-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .data-table {
    font-size: 14px;
  }

  .data-table th,
  .data-table td {
    padding: 8px;
  }

  .add-row {
    flex-direction: column;
  }

  .add-row input,
  .add-row select {
    width: 100%;
  }
}
