/*
 * Restore FullCalendar's own grid/table presentation inside the site theme.
 *
 * Bootstrap Barrio applies global table/tr/th/td styles after the calendar
 * assets load, which distorts the calendar borders, sizing, and headers.
 * Keep this reset narrowly scoped to the calendar widget itself.
 */

.js-drupal-fullcalendar.fc table {
  width: 100%;
  margin: 0;
  border: 0;
  border-collapse: collapse;
  border-spacing: 0;
  box-sizing: border-box;
  table-layout: fixed;
  font-size: 1em;
}

.js-drupal-fullcalendar.fc tr {
  padding: 0;
  border-bottom: 0;
  background: transparent;
}

.js-drupal-fullcalendar.fc td,
.js-drupal-fullcalendar.fc th {
  padding: 0;
  vertical-align: top;
  border-style: solid;
  border-width: 1px;
}

.js-drupal-fullcalendar.fc th {
  background: transparent;
  color: inherit;
  font-weight: inherit;
  text-align: center;
}

.js-drupal-fullcalendar.fc .fc-row {
  margin: 0;
  border-style: solid;
  border-width: 0;
}

.js-drupal-fullcalendar.fc .fc-row table {
  border-right: 0 hidden transparent;
  border-bottom: 0 hidden transparent;
  border-left: 0 hidden transparent;
}

.js-drupal-fullcalendar.fc .fc-row:first-child table {
  border-top: 0 hidden transparent;
}

/* Match the production toolbar presentation without restyling the grid. */
.js-drupal-fullcalendar.fc {
  padding-left: 8px;
  padding-right: 8px;
  font-size: 1em;
}

.js-drupal-fullcalendar.fc .fc-toolbar.fc-header-toolbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0;
}

.path-frontpage .view-calendar.view-display-id-block_1 .js-drupal-fullcalendar.fc .fc-toolbar.fc-header-toolbar {
  padding-top: 60px;
}

.js-drupal-fullcalendar.fc .fc-toolbar > * {
  display: flex;
  align-items: center;
  min-width: 0;
  margin: 0;
}

.js-drupal-fullcalendar.fc .fc-toolbar .fc-left,
.js-drupal-fullcalendar.fc .fc-toolbar .fc-right {
  white-space: nowrap;
}

.js-drupal-fullcalendar.fc .fc-toolbar .fc-center {
  justify-content: center;
  overflow: hidden;
}

.js-drupal-fullcalendar.fc .fc-toolbar h2 {
  margin: 0;
  padding-bottom: 0;
  font-size: 18px;
  line-height: 1.1;
  white-space: nowrap;
}

.js-drupal-fullcalendar.fc .fc-button,
.js-drupal-fullcalendar.fc .fc-button-primary {
  height: 2.1em;
  padding: 0 0.45em;
  line-height: 2.1em;
  font-size: 0.85em;
  color: #333;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75);
  background-color: #f5f5f5;
  background-image: linear-gradient(to bottom, #fff, #e6e6e6);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-bottom-color: rgba(0, 0, 0, 0.25);
  border-radius: 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
}

.js-drupal-fullcalendar.fc .fc-button-group {
  display: inline-flex;
}

.js-drupal-fullcalendar.fc .fc-toolbar > * > * {
  margin-left: 0.35em;
}

.js-drupal-fullcalendar.fc .fc-toolbar > * > :first-child {
  margin-left: 0;
}

.js-drupal-fullcalendar.fc .fc-button:hover,
.js-drupal-fullcalendar.fc .fc-button-primary:hover {
  color: #333;
  background-color: #e6e6e6;
  background-image: none;
}

.js-drupal-fullcalendar.fc .fc-button:focus,
.js-drupal-fullcalendar.fc .fc-button-primary:focus {
  outline: none;
  box-shadow: none;
}

.js-drupal-fullcalendar.fc .fc-button-primary:not(:disabled).fc-button-active,
.js-drupal-fullcalendar.fc .fc-button-primary:not(:disabled):active {
  color: #333;
  background-color: #ccc;
  background-image: none;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
}

.js-drupal-fullcalendar.fc .fc-button:disabled,
.js-drupal-fullcalendar.fc .fc-button-primary:disabled {
  opacity: 0.65;
  background-image: none;
}

.js-drupal-fullcalendar.fc .fc-button-group > .fc-button:first-child {
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
}

.js-drupal-fullcalendar.fc .fc-button-group > .fc-button:last-child {
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
}

.js-drupal-fullcalendar.fc .fc-icon {
  color: #333;
}
