/* General body styling */
body {
  font-family: Arial, sans-serif;
  background-color: #f9f9f9;
  margin: 0;
  padding: 0;
}

/* Main container for dashboard, deleted, analytics pages */
.container {
  max-width: 900px;
  margin: 40px auto;
  padding: 30px;
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

/* Card layout for create/edit forms */
.card {
  max-width: 600px;
  margin: 30px auto;
  background: #ffffff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Flex row for Save/Back buttons */
.button-row {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}

/* General button styling */
.button {
  padding: 10px 20px;
  background-color: #0077cc;
  color: white;
  border: none;
  border-radius: 5px;
  text-decoration: none;
  font-size: 16px;
  margin: 4px 4px 4px 0;
  cursor: pointer;
  display: inline-block;
  text-align: center;
}

.button.primary {
  background-color: #0077cc;
}

.button.secondary {
  background-color: #6c757d;
}

.button.primary:hover {
  background-color: #005fa3;
}

.button.secondary:hover {
  background-color: #5a6268;
}

.button.success {
  background-color: #28a745; /* Green */
}

.button.success:hover {
  background-color: #218838; /* Slightly darker green on hover */
}

/* Form inputs for create/edit pages */
input[type="url"], input[type="text"], input[type="password"], textarea {
  width: 100%;
  padding: 10px;
  margin-top: 8px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 16px;
  box-sizing: border-box;
}

/* Table styling for dashboard, deleted, analytics */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

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

th {
  background-color: #eee;
}

/* Modal styling for Scan History popup */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.4);
}

.modal-content {
  background-color: #fefefe;
  margin: 10% auto;
  padding: 20px;
  border: 1px solid #888;
  width: 80%;
  border-radius: 8px;
}

.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
}

.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/* Alerts for errors and successes */
.alert-error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
  padding: 10px;
  border-radius: 6px;
  margin-bottom: 20px;
}

.alert-success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
  padding: 10px;
  border-radius: 6px;
  margin-bottom: 20px;
}

/* QR Code Status Row Colors */
.highlight-white {
  background-color: #ffffff;
}

.highlight-green {
  background-color: #d4edda;
}

.highlight-yellow {
  background-color: #fff3cd;
}

.highlight-red {
  background-color: #f8d7da;
}

/* dashboard menu */
.top-menu {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.button.danger {
  background-color: #dc3545;
}

.button.danger:hover {
  background-color: #c82333;
}