@tailwind base;
@tailwind components;
@tailwind utilities;

/* Form validation styles */
.field-valid {
  @apply border-green-300 ring-green-500 focus:border-green-500 focus:ring-green-500;
}

.field-invalid {
  @apply border-red-300 ring-red-500 focus:border-red-500 focus:ring-red-500;
}

.field-error .field-error-message {
  animation: slideDown 0.3s ease-out;
}

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

/*

@layer components {
  .btn-primary {
    @apply py-2 px-4 bg-blue-200;
  }
}

*/
/* Attendance Reports - Daily Table Styles */
.daily-attendance-table-container {
  max-height: 600px;
  overflow: auto;
  position: relative;
}

/* Smooth scrolling */
.daily-attendance-table-container {
  scroll-behavior: smooth;
}

/* Custom scrollbar styling */
.daily-attendance-table-container::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.daily-attendance-table-container::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

.daily-attendance-table-container::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}

.daily-attendance-table-container::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* Sticky column shadows on scroll */
.daily-attendance-table-container table th.sticky,
.daily-attendance-table-container table td.sticky {
  position: sticky;
  background-clip: padding-box;
}

/* Left sticky columns shadow */
.daily-attendance-table-container table th.sticky.left-0::after,
.daily-attendance-table-container table td.sticky.left-0::after,
.daily-attendance-table-container table th.sticky.left-\[200px\]::after,
.daily-attendance-table-container table td.sticky.left-\[200px\]::after {
  content: '';
  position: absolute;
  top: 0;
  right: -8px;
  bottom: 0;
  width: 8px;
  background: linear-gradient(to right, rgba(0, 0, 0, 0.08), transparent);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

/* Right sticky column shadow */
.daily-attendance-table-container table th.sticky.right-0::before,
.daily-attendance-table-container table td.sticky.right-0::before {
  content: '';
  position: absolute;
  top: 0;
  left: -8px;
  bottom: 0;
  width: 8px;
  background: linear-gradient(to left, rgba(0, 0, 0, 0.08), transparent);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

/* Show shadows when scrolling */
.daily-attendance-table-container.scrolled-right table th.sticky.left-0::after,
.daily-attendance-table-container.scrolled-right table td.sticky.left-0::after,
.daily-attendance-table-container.scrolled-right table th.sticky.left-\[200px\]::after,
.daily-attendance-table-container.scrolled-right table td.sticky.left-\[200px\]::after {
  opacity: 1;
}

.daily-attendance-table-container.scrolled-left table th.sticky.right-0::before,
.daily-attendance-table-container.scrolled-left table td.sticky.right-0::before {
  opacity: 1;
}

/* Hover effect transition */
.daily-attendance-table-container tbody tr {
  transition: background-color 0.15s ease;
}

/* Status icon animation */
.daily-attendance-table-container tbody td span[title] {
  transition: transform 0.15s ease;
}

.daily-attendance-table-container tbody td span[title]:hover {
  transform: scale(1.15);
}

/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */
