/* Resetting default browser styles for consistency */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Body Styling */
body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background-color: #e9ecef;
  color: #212529;
  line-height: 1.6;
  padding-bottom: 100px; /* Increased to prevent footer overlap */
}

/* Container Styling */
.container {
  max-width: 1200px;
  margin: 40px auto;
  padding: 30px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  padding-bottom: 100px; /* Increased to prevent footer overlap */
}

/* Headings */
h1,
h2,
h3,
h4,
h5,
h6 {
  color: #343a40;
  margin-bottom: 20px;
}

/* Button Group */
.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 25px;
  align-items: center; /* Ensures vertical alignment */
}

/* Specific Spacing for Search and Home Button */
.button-group .search-form {
  margin-bottom: 15px; /* Add space below the search form */
}

.button-group .home-button {
  /* Additional styles if needed */
}

.home-button {
  margin-top: 12px;
}

/* General Button Styles */
.action-button,
.home-button,
.logout-button,
.click {
  display: inline-block;
  padding: 12px 25px;
  font-size: 1rem;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Primary Buttons */
.action-button,
.home-button {
  background-color: #17a2b8; /* Teal color */
  color: #ffffff; /* White text */
}

.action-button:hover,
.home-button:hover {
  background-color: #138496; /* Darker teal on hover */
  transform: translateY(-2px); /* Slight upward movement */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* Shadow effect */
}

/* Logout Button */
.logout-button {
  background-color: #dc3545; /* Red background */
  color: #ffffff; /* White text */
  font-size: 1.1rem;
}

.logout-button:hover {
  background-color: #c82333; /* Darker red on hover */
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Click Button */
.click {
  background-color: #28a745; /* Green background */
  color: #ffffff; /* White text */
}

.click:hover {
  background-color: #218838; /* Darker green on hover */
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Table Styling */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 25px;
  overflow-x: auto;
}

th,
td {
  padding: 12px 15px;
  border: 1px solid #dee2e6;
  text-align: left;
}

th {
  background-color: #f8f9fa;
  color: #495057;
  font-weight: 600;
}

tr:nth-child(even) {
  background-color: #f1f3f5;
}

tr:hover {
  background-color: #e9ecef;
}

/* Form Group */
.form-group {
  margin-bottom: 20px;
}

/* Labels */
label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #495057;
}

/* Input Fields */
input[type="text"],
input[type="number"],
input[type="password"] {
  width: 100%;
  padding: 10px 15px;
  border: 1px solid #ced4da;
  border-radius: 5px;
  font-size: 1rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input[type="text"]:focus,
input[type="number"]:focus,
input[type="password"]:focus {
  border-color: #80bdff;
  outline: none;
  box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
}

/* Form Actions */
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 24px;
  margin-top: 25px;
}

/* Footer Styling */
.footer {
  background-color: #343a40;
  color: #adb5bd;
  padding: 20px 20px;
  position: fixed;
  bottom: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

/* Footer Links */
.footer a {
  color: #adb5bd; /* Link color matches footer text */
  text-decoration: none; /* Remove underline */
  margin: 0 12px; /* Spacing between links */
  transition: color 0.2s ease; /* Smooth color transition on hover */
}

/* Add vertical margin to footer buttons */
.footer .logout-button,
.footer .action-button,
.footer .home-button {
  margin-top: 8px;
  margin-bottom: 8px;
}

.footer a:hover {
  color: #ffffff; /* White color on hover */
}

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    width: 90%;
    padding: 20px;
  }

  .button-group {
    flex-direction: column;
  }

  .form-actions {
    flex-direction: column;
  }
}
