/* ==========================================================================
   AUM Event Row

   A schedule row rather than a card. Deliberately denser than the session
   cards: an event is a fixed date and the reader is scanning for when and
   where, so several rows should be readable at once.
   ========================================================================== */

.aum-event-row {
  display: grid;
  grid-template-columns: var(--aum-erow-date-w, 118px) 1fr auto;
  gap: 32px;
  align-items: center;
  padding: var(--aum-erow-pad, 26px) 0;
  border-bottom: 1px solid var(--aum-erow-divider, var(--aum-border, #e8e8e8));
  font-family: var(--aum-font, Lato, sans-serif);
  transition: background var(--aum-transition, .25s ease);
}

.aum-event-row:first-of-type {
  border-top: 1px solid var(--aum-erow-divider, var(--aum-border, #e8e8e8));
}

.aum-event-row.has-no-divider { border-bottom: 0; }
.aum-event-row.has-no-divider:first-of-type { border-top: 0; }

.aum-event-row:hover { background: rgba(0, 0, 0, .015); }

/* --- Date block ----------------------------------------------------------- */

.aum-event-row__date {
  background: var(--aum-erow-date-bg, var(--aum-black, #000));
  color: var(--aum-erow-date-color, #fff);
  text-align: center;
  padding: 16px 8px 18px;
  line-height: 1;
  display: block;
}

.aum-event-row__month {
  display: block;
  font-size: var(--aum-erow-month, 12px);
  letter-spacing: .18em;
  text-transform: uppercase;
  opacity: .85;
}

.aum-event-row__day {
  display: block;
  font-size: var(--aum-erow-day, 36px);
  font-weight: 300;
  margin: 7px 0 5px;
}

.aum-event-row__year {
  display: block;
  font-size: var(--aum-fs-2xs);
  letter-spacing: .2em;
  opacity: .55;
}

/* A run of dates reads as one event rather than two. */
.aum-event-row__range {
  display: block;
  font-size: var(--aum-fs-2xs);
  letter-spacing: .14em;
  text-transform: uppercase;
  opacity: .7;
  margin-top: 7px;
  padding-top: 7px;
  border-top: 1px solid currentColor;
  border-top-color: color-mix(in srgb, currentColor 25%, transparent);
}

/* --- Detail --------------------------------------------------------------- */

.aum-event-row__kind {
  font-size: var(--aum-fs-2xs);
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--aum-erow-kind-color, var(--aum-accent-deep, #7b6a58));
  margin: 0 0 8px;
}

.aum-event-row__title {
  font-size: var(--aum-erow-title, 21px);
  font-weight: 400;
  letter-spacing: var(--aum-erow-title-track, .12em);
  text-transform: uppercase;
  color: var(--aum-erow-title-color, var(--aum-gray, #9b9b9b));
  line-height: 1.3;
  margin: 0 0 12px;
}

.aum-event-row__meta {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
}

.aum-event-row__meta li {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: var(--aum-erow-meta, 14px);
  color: rgba(0, 0, 0, .6);
  letter-spacing: .02em;
}

.aum-event-row__meta svg {
  width: 13px;
  height: 13px;
  flex: 0 0 auto;
  color: var(--aum-erow-icon-color, var(--aum-accent-deep, #7b6a58));
}

/* --- Action --------------------------------------------------------------- */

.aum-event-row__action { text-align: right; }

.aum-event-row__note {
  font-size: var(--aum-fs-2xs);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--aum-accent-deep, #7b6a58);
  white-space: nowrap;
  margin: 0 0 10px;
}

.aum-event-row__btn {
  display: inline-block;
  white-space: nowrap;
  text-decoration: none;
  font-size: var(--aum-fs-xs);
  letter-spacing: .18em;
  text-transform: uppercase;
  line-height: 1;
  padding: 16px 32px;
  border-radius: 0;
  border: 1px solid var(--aum-border, #e8e8e8);
  color: var(--aum-gray, #9b9b9b);
  transition: background var(--aum-transition, .25s ease),
              color var(--aum-transition, .25s ease),
              border-color var(--aum-transition, .25s ease);
}

.aum-event-row__btn:hover,
.aum-event-row__btn:focus-visible {
  background: var(--aum-black, #000);
  border-color: var(--aum-black, #000);
  color: #fff;
}

/* --- Sold out ------------------------------------------------------------- */

.aum-event-row.is-full { opacity: .55; }
.aum-event-row.is-full .aum-event-row__date { background: var(--aum-gray, #9b9b9b); }
.aum-event-row.is-full .aum-event-row__btn { pointer-events: none; }

/* --- Responsive -----------------------------------------------------------
   Below lg the button drops beneath the detail. On a phone the date block
   turns horizontal, so it does not eat a third of the screen height.
   -------------------------------------------------------------------------- */

@media (max-width: 991.98px) {
  .aum-event-row {
    grid-template-columns: 96px 1fr;
    gap: 24px;
    row-gap: 18px;
  }

  .aum-event-row__action { grid-column: 2; text-align: left; }
  .aum-event-row__day { font-size: calc(var(--aum-erow-day, 36px) * .82); }
}

@media (max-width: 575.98px) {
  .aum-event-row {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .aum-event-row__date {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 12px;
    padding: 12px;
  }

  .aum-event-row__month,
  .aum-event-row__day,
  .aum-event-row__year { display: inline-block; margin: 0; }

  .aum-event-row__day { font-size: calc(var(--aum-erow-day, 36px) * .66); }

  .aum-event-row__range {
    border-top: 0;
    border-left: 1px solid currentColor;
    margin: 0 0 0 4px;
    padding: 0 0 0 12px;
  }

  .aum-event-row__action { grid-column: 1; }
  .aum-event-row__btn { display: block; text-align: center; }
  .aum-event-row__note { text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .aum-event-row, .aum-event-row__btn { transition: none; }
}

/* --- Following a section heading ------------------------------------------
   A run of rows usually sits under a heading. Giving the first row its own
   top margin means the spacing does not depend on a margin collapsing out of
   the heading's row and column, which is fragile and differs between the
   editor and the front end.
   -------------------------------------------------------------------------- */

.aum-bootstrap-row-block + .aum-event-row,
.aum-container-block__inner > * + .aum-event-row {
  margin-top: var(--aum-erow-lead, 8px);
}

.aum-event-row + .aum-event-row { margin-top: 0; }
