/* small additions beyond Tailwind for sticky header and zebra rows */
.sticky-header th {
  position: sticky;
  /* Ensures the table header sticks 56px below the fixed navbar */
  top: 56px; 
  background: white;
  /* High z-index to ensure it sits above all other scrolling content */
  z-index: 40; 
  border-bottom: 1px solid #e5e7eb;
  
  /* --- FIX FOR PADDING/SPACING IN TABLES --- */
  /* Increase padding on the sticky header cells for better visual separation and height consistency. */
  padding-top: 0.75rem; /* Equivalent to Tailwind py-3 */
  padding-bottom: 0.75rem; /* Equivalent to Tailwind py-3 */
}

/* --- BOTTOM NAV BAR SHADOW --- */
/* Required to make the fixed bottom nav bar look professional and separate from the content */
.shadow-top {
    box-shadow: 0 -1px 3px 0 rgba(0, 0, 0, 0.1), 0 -1px 2px 0 rgba(0, 0, 0, 0.06);
}




/* ensure table cells align nicely on very narrow screens */
table td, table th {
  /* Aligns content to the top so row height is dynamic */
  vertical-align: top; 
  /* Standard padding for all cells, matches Tailwind's py-2 */
  padding-top: 0.5rem; 
  padding-bottom: 0.5rem;
}

/* FIX: Creates a new stacking context for sticky elements within (Added to .bg-white wrapper in HTML) */
.isolate-z {
  transform: translateZ(0);
}

/* --- Atlas Line Clamping Utility Classes --- */

/* Limits text to 5 lines for narrative summary */
.italic-clamp-5 {
  font-style: italic;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 5;
  line-clamp: 5; /* Future support */
  max-height: calc(1.2em * 5);
}

/* Limits text to 3 lines for a shorter summary */
.italic-clamp-3 {
  font-style: italic;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3; /* Future support */
  max-height: calc(1.2em * 3);
  position: relative; /* Needed for the ::after gradient */
  line-height: 1.4; /* optional: avoids clipping descenders */
}

/* Adds a soft fade at the bottom for clean cutoff */
.italic-clamp-3::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1.5em;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0), white 90%);
}
