/* 
 * External CSS for the Speaker Fees Table
 * This file is loaded asynchronously when the table is about to be viewed
 */

/* Base Styles */
.foster-table-container {
  --color-blue-light: #c3d8e4;
  --color-blue-dark: #475e93;
  --font-size-fluid-0: clamp(0.75rem, 1.5vw, 1rem);
  max-width: 100%;
  position: relative;
}

.foster-speaker-table {
  font-size: var(--font-size-fluid-0);
  border-collapse: collapse;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  width: 100%;
}

.foster-speaker-table th,
.foster-speaker-table td {
  padding: 0.5em 0.75em;
  text-align: left;
  border: 1px solid #ddd;
}

.foster-speaker-table>thead>tr>th {
  background-color: var(--color-blue-dark);
  color: #FFFFFF;
  font-weight: bold;
}

.foster-speaker-table tr:nth-child(even) {
  background-color: #F5F5F5;
}

.foster-speaker-table>tbody>tr:hover {
  background-color: var(--color-blue-light);
}

.foster-speaker-table td {
  color: #333333;
}

.foster-attribution {
  text-align: right;
}

.foster-attribution a {
  color: var(--color-blue-dark);
  text-decoration: none;
}

.foster-attribution a:hover {
  text-decoration: underline;
}

/* Mobile cards are hidden by default */
.foster-mobile-view {
  display: none;
}

/* Medium screens - hide lower priority columns */
@media screen and (max-width: 767px) and (min-width: 481px) {
  .foster-lower-priority {
    display: none;
  }
}

/* Small screens - accessible card layout */
@media screen and (max-width: 480px) {

  /* Hide the original table visually but keep it for screen readers */
  .foster-speaker-table {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
  }

  /* Show the mobile card layout */
  .foster-mobile-view {
    display: block !important;
  }

  .foster-card {
    margin-bottom: 1em;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  }

  .foster-card-header {
    background-color: var(--color-blue-dark);
    color: white;
    font-weight: bold;
    padding: 10px 15px;
    border-radius: 4px 4px 0 0;
    border-bottom: 1px solid #ddd;
  }

  .foster-card dl {
    margin: 0;
    padding: 0;
  }

  .foster-card .foster-row {
    display: flex;
    padding: 10px 15px;
    border-bottom: 1px solid #eee;
  }

  .foster-card .foster-row:last-child {
    border-bottom: none;
  }

  .foster-card dt {
    flex: 0 0 40%;
    font-weight: bold;
    color: var(--color-blue-dark);
    padding-right: 10px;
  }

  .foster-card dd {
    flex: 0 0 60%;
    margin: 0;
  }
}

/* Fade-in animation for the table */
.foster-table-container {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.foster-table-container.table-visible {
  opacity: 1;
  transform: translateY(0);
}