/* General styles */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f4f4f4;
  color: #333;
}

.container {
  max-width: 400px;
  margin: 80px auto;
  padding: 20px;
  background-color: #ffffff;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  text-align: center;
}

h1 {
  font-size: 24px;
  color: #fdfdfd;
  margin-bottom: 20px;
}

/* Input styles */
.input-group {
  margin-bottom: 20px;
  text-align: left;
}

.input-group label {
  font-size: 14px;
  display: block;
  margin-bottom: 6px;
  color: #555;
}

.input-group input {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
  font-size: 16px;
}

.input-group input:focus {
  border-color: #6200ee;
  outline: none;
  box-shadow: 0 0 4px rgba(98, 0, 238, 0.2);
}

/* Button styles */
button {
  padding: 12px;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

/* Gray button styling for the buttons in the app bar */
.gray-button {
  background-color: #888;
}

.gray-button:hover {
  background-color: #666;
}

/* Button container for side-by-side buttons */
.button-container {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 10px;
}

/* App bar styles */
.app-bar {
  background-color: #6200ee;
  color: white;
  padding: 16px;
  text-align: center;
  font-size: 24px;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); /* Adds a subtle shadow */
}
.date-filter {
  margin: 10px 0;
  display: flex;
  gap: 10px;
  align-items: center;
}


/* Loader styles */
.loader {
  margin: 100px auto;
  width: 50px;
  height: 50px;
  border: 8px solid #f3f3f3;
  border-top: 8px solid #6200ee;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Ensure the container holds the table with both scrolls */
.table-container {
  position: relative;
  height: calc(100vh - 200px); /* Adjust based on app-bar height */
  display: flex;
  flex-direction: column;
}

/* Table styles */
.form-table-container {
  max-width: 100%;
  overflow-x: auto;
  padding: 16px;
  white-space: nowrap;
  border-top: 1px solid #ddd;
}
/* Bottom scroll area for horizontal sync */
.bottom-scroll {
  height: 20px; /* Enough height for the scrollbar */
  overflow-x: auto;
  overflow-y: hidden; /* Only horizontal scrolling */
}
.bottom-scroll .scroll-sync {
  height: 1px; /* Invisible sync bar */
}
/* Styling for the table header and search rows */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
}

th, td {
  padding: 12px;
  border: 1px solid #010101;
  text-align: left;
  font-size: 14px;
  color: #333; /* Text color for table headers and cells */
}

th {
  background-color: #6200ee;
  color: white;
}

td {
  background-color: #fff; /* Background remains white */
}

td[contenteditable="true"] {
  background-color: #f9f9f9;
}

td:focus {
  outline: 2px solid #6200ee;
}

/* Search input styles in the second header row */
table th input[type="text"] {
  width: 100%;
  padding: 8px;
  box-sizing: border-box;
  font-size: 14px;
  color: #333;
  background-color: #ffffff;
  border: 1px solid #ddd;
  border-radius: 4px;
  outline: none;
}

/* Sticky headers for both rows */
table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
}

/* First row of header titles */
table thead tr:first-child th {
  background-color: #6200ee;
  color: white;
}

/* Second row for search inputs */
table thead tr:nth-child(2) th {
  background-color: #f4f4f4;
}

/* Placeholder styling for input fields */
table th input[type="text"]::placeholder {
  color: #888;
  opacity: 1;
}

/* Optional hover and focus effect for search inputs */
table th input[type="text"]:hover {
  border-color: #6200ee;
}

table th input[type="text"]:focus {
  border-color: #6200ee;
  box-shadow: 0 0 4px rgba(98, 0, 238, 0.2);
}
/* Add subtle background gradient for body */
body {
  background: linear-gradient(to right, #f4f4f4, #eaeaea);
}

/* Enhance the form-item look in form-list */
.form-item {
  padding: 12px;
  margin: 8px 0;
  background-color: #ffffff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.form-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* Make the container more responsive */
.container {
  max-width: 90%;
  margin: 40px auto;
  padding: 20px;
}

/* Slightly enhance button appearance */
button {
  background-color: #6200ee;
}

button:hover {
  background-color: #4500b5;
}

/* Additional styling for loader */
.loader {
  display: block;
  margin: 40px auto;
  width: 60px;
  height: 60px;
  border-width: 6px;
}

/* Improve table styles on small screens */


table th, table td {
  padding: 12px 8px;
}

/* Subtle effect for editable table cells */
td[contenteditable="true"]:hover {
  background-color: #f2f2f2;
  cursor: text;
}

/* Improve overall look of sticky table headers */
table thead th {
  border-bottom: 2px solid #ddd;
}

/* Container styling for centering and spacing */
.container {
  max-width: 350px;
  margin: 100px auto;
  padding: 20px;
  background-color: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  text-align: center;
}

/* Title styling */
h1 {
  font-size: 24px;
  color: #333;
  margin-bottom: 24px;
}

/* Input group styling */
.input-group {
  margin-bottom: 20px;
  text-align: left;
}

.input-group label {
  font-size: 14px;
  color: #333;
  margin-bottom: 6px;
  display: block;
}

.input-group input {
  width: 100%;
  padding: 10px;
  font-size: 16px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.input-group input:focus {
  border-color: #6200ee;
  outline: none;
  box-shadow: 0 0 4px rgba(98, 0, 238, 0.2);
}




/* Login button styling */
button#login-button {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  color: #fff;
  background-color: #6200ee;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button#login-button:hover {
  background-color: #4500b5;
}

/* Message box for errors and access messages */
.message {
  margin-top: 16px;
  padding: 10px;
  color: #b00020;
  background-color: #fce4e4;
  border-radius: 4px;
  display: none;
  font-size: 14px;
  line-height: 1.4;
  text-align: center;
}

/* Small screen adjustments */
@media (max-width: 400px) {
  .container {
    width: 90%;
    margin: 60px auto;
  }

  h1 {
    font-size: 20px;
  }

  .input-group input,
  button#login-button {
    font-size: 14px;
  }
}
