/* =====================================================================
   Amala — community classes calendar + upcoming events list
   Uses the scheme variables from amala-theme.css (--accent, --accent-dark,
   --accent-light, --accent-lighter) so it follows the site scheme.
   Card borders/hover mirror the Core Values boxes (1px #e6e6e6, 4px radius,
   0 0 10px 5px #ebebeb hover shadow).
   ===================================================================== */

/* ---------------- month grid ----------------
   Unused since Oct 2 2026 (grid container removed from events.html);
   kept so the calendar can be restored without rework. */
.amala-calendar-wrap { margin-top: 2.2rem; }
.amala-cal-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; margin-bottom: 1.25rem;
}
.amala-cal-month {
  margin: 0 !important;
  font-family: "Libre Baskerville", Georgia, serif !important;
  font-weight: 700; text-transform: none;
}
/* fixed 44px square; template button rules add padding/width, so pin it */
.amala-cal-nav {
  cursor: pointer; border: 1px solid var(--accent); background: #fff;
  color: var(--accent-dark); border-radius: 4px;
  flex: 0 0 44px; width: 44px !important; min-width: 44px; max-width: 44px;
  height: 44px; padding: 0 !important; box-sizing: border-box;
  font-size: 26px; line-height: 1;
  transition: background 200ms ease, color 200ms ease;
}
.amala-cal-nav:hover,
.amala-cal-nav:focus-visible {
  background: var(--accent); color: #fff;
}
.amala-cal-nav:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }

.amala-cal-table {
  width: 100%; border-collapse: collapse; table-layout: fixed;
  border: 1px solid #e6e6e6; background: #fff;
}
.amala-cal-table th {
  background: var(--accent-dark); color: #fff;
  padding: .65rem .25rem; text-align: center;
  font-size: 13px; letter-spacing: .06em; text-transform: uppercase;
}
.amala-cal-table th abbr { text-decoration: none; border: 0; }
.amala-cal-table td {
  border: 1px solid #e6e6e6; vertical-align: top;
  height: 92px; padding: .35rem .4rem;
}
.amala-cal-empty { background: #fafafa; }
.amala-cal-daynum { display: block; font-size: 14px; color: #6a6a6a; margin-bottom: .25rem; }
.amala-cal-today { background: var(--accent-light); }
.amala-cal-today .amala-cal-daynum {
  color: var(--accent-dark); font-weight: 700;
}
.amala-cal-event {
  display: block; background: var(--accent); color: #fff !important;
  border-radius: 3px; padding: .2rem .4rem; margin-bottom: .2rem;
  font-size: 12.5px; line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis;
  transition: background 200ms ease;
}
.amala-cal-event:hover,
.amala-cal-event:focus-visible { background: var(--accent-dark); }
.amala-cal-event:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 1px; }

/* ---------------- upcoming events list ---------------- */
.amala-upcoming-wrap { margin-top: 3rem; }
.amala-event-card {
  display: flex; gap: 1.5rem; align-items: flex-start;
  border: 1px solid #e6e6e6; border-radius: 4px; background: #fff;
  padding: 1.6rem 1.5rem; margin-bottom: 1.5rem;
  transition: box-shadow 300ms ease;
  scroll-margin-top: 110px; /* land below the sticky nav when jumped to */
}
.amala-event-card:hover { box-shadow: 0 0 10px 5px #ebebeb; }
.amala-event-card:target { box-shadow: 0 0 0 3px var(--accent-lighter); }

.amala-event-date {
  flex: 0 0 auto; min-width: 84px; text-align: center;
  background: var(--accent-light); border-radius: 4px; padding: .8rem .6rem;
}
.amala-event-month {
  display: block; font-size: 13px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent-dark); font-weight: 700;
}
.amala-event-day {
  display: block; font-size: 34px; line-height: 1.1; font-weight: 700;
  color: var(--accent-dark);
  font-family: "Libre Baskerville", Georgia, serif;
}
.amala-event-year { display: block; font-size: 12px; color: #6a6a6a; }

.amala-event-body { flex: 1 1 auto; }
.amala-event-title {
  margin: 0 0 .35rem !important;
  font-family: "Libre Baskerville", Georgia, serif !important;
  font-weight: 700; text-transform: none; font-size: 21px;
}
.amala-event-meta { color: #6a6a6a; margin: 0 0 .6rem; font-size: 15px !important; }
.amala-event-desc { margin: 0 0 .9rem; }
.amala-event-link { margin-top: .2rem; }
.amala-events-none { text-align: center; color: #6a6a6a; }

/* ---------------- small screens ---------------- */
@media (max-width: 767px) {
  .amala-cal-month { font-size: 20px; }
  .amala-cal-table th {
    font-size: 10px; letter-spacing: 0; padding: .5rem .1rem;
  }
  .amala-cal-table td { height: 64px; padding: .25rem; }
  .amala-cal-event {
    font-size: 0; padding: 0; width: 10px; height: 10px;
    border-radius: 50%; margin: 0 auto .2rem; /* dot instead of chip */
  }
  .amala-event-card { flex-direction: column; gap: .9rem; }
  .amala-event-date { min-width: 72px; }
}
