/* Events Widget: layout defaults, with no site-specific palette or font assets.
 * Edit these variables, or override them in your theme's custom CSS.
 * Sizes use rem so the layout follows the reader's font-size preference.
 * Publii theme font variables are optional; otherwise fonts inherit normally.
 */
.tlh-events {
    /* Desktop layout and typography. */
    --events-date-column: 4.5rem;
    --events-column-gap: 1.75rem;
    --events-row-space: 2rem;
    --events-day-size: 3.6rem;
    --events-title-size: 1.45rem;
    --events-detail-size: .8125rem;
    --events-description-size: 1rem;
    --events-description-width: 40rem;
    --events-past-size: .75rem;
    --events-section-gap: 3rem;
    /* Phone layout (used below 600px). */
    --events-mobile-date-column: 3.25rem;
    --events-mobile-column-gap: 1.125rem;
    --events-mobile-row-space: 1.6rem;
    --events-mobile-day-size: 2.8rem;
    --events-mobile-title-size: 1.2rem;
    /* Neutral rules and secondary text derive from the theme's text color. */
    --tlh-rule: color-mix(in srgb, currentColor 18%, transparent);
    --tlh-soft-rule: color-mix(in srgb, currentColor 10%, transparent);
    --tlh-muted: color-mix(in srgb, currentColor 68%, transparent);
    color: inherit;
    font-family: var(--font-body, inherit);
    margin-top: 2.4rem;
}
.tlh-events *, .tlh-events *::before, .tlh-events *::after { box-sizing: border-box; }
.tlh-events .tlh-events__section-header {
    display: flex; align-items: baseline; justify-content: space-between; gap: 1rem;
    padding: 0 0 1rem; border-bottom: 1px solid var(--tlh-rule);
}
.tlh-events .tlh-events__section-header > h2 {
    margin: 0; font-family: var(--font-body, inherit); font-size: .8125rem; font-weight: 600;
    line-height: 1.4; letter-spacing: .07em; text-transform: uppercase;
}
.tlh-events .tlh-events__year-range {
    font-size: 1.625rem; font-weight: 400; line-height: 1; letter-spacing: -.055em;
    font-variant-numeric: tabular-nums;
}
.tlh-events .tlh-event {
    display: grid; grid-template-columns: var(--events-date-column) minmax(0, 1fr); gap: var(--events-column-gap);
    margin: 0; padding: var(--events-row-space) 0; border-bottom: 1px solid var(--tlh-rule);
}
.tlh-events .tlh-event__date {
    display: flex; flex-direction: column; align-items: flex-start; padding-top: .12rem;
    font-variant-numeric: tabular-nums;
}
.tlh-events .tlh-event__month {
    font-size: .75rem; font-weight: 600; line-height: 1.4; text-transform: uppercase; letter-spacing: .12em;
}
.tlh-events .tlh-event__day { margin: .22rem 0 .35rem; font-size: var(--events-day-size); font-weight: 450; line-height: 1; letter-spacing: -.075em; }
.tlh-events .tlh-event__year { font-size: .75rem; line-height: 1.5; color: var(--tlh-muted); }
.tlh-events .tlh-event__body { min-width: 0; }
.tlh-events .tlh-event__body > h3 {
    margin: 0 0 .65rem; font-family: var(--font-heading, inherit); font-size: var(--events-title-size);
    font-weight: 600; line-height: 1.3; letter-spacing: -.028em; overflow-wrap: anywhere;
}
.tlh-events .tlh-event__schedule {
    margin: 0; font-family: var(--font-body, inherit); font-size: var(--events-detail-size); font-weight: 400;
    line-height: 1.7; color: var(--tlh-muted);
}
.tlh-events .tlh-event__timezone { font-size: .85em; white-space: nowrap; }
.tlh-events .tlh-event__description {
    max-width: var(--events-description-width); margin: 1rem 0 0; font-family: var(--font-entry, inherit);
    font-size: var(--events-description-size); font-weight: 400; line-height: 1.65;
}
.tlh-events .tlh-event__footer {
    display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between;
    gap: 1rem 1.5rem; margin-top: 1.25rem;
}
.tlh-events .tlh-event__location { min-width: 0; flex: 1 1 14rem; }
.tlh-events .tlh-event__venue {
    margin: 0 0 .3rem; font-family: var(--font-body, inherit); font-size: var(--events-detail-size); font-weight: 600; line-height: 1.55;
}
.tlh-events .tlh-event__location address {
    margin: 0; font-family: var(--font-body, inherit); font-style: normal; font-size: var(--events-detail-size);
    font-weight: 400; line-height: 1.7; color: var(--tlh-muted);
}
.tlh-events .tlh-event .tlh-event__body .tlh-event__location address a { color: inherit; text-decoration: none; border: 0; background: none; }
.tlh-events .tlh-event__map-hint {
    display: block; width: fit-content; margin-top: .3rem; font-size: .6875rem;
    text-decoration: underline; text-decoration-color: var(--tlh-rule); text-underline-offset: .25em;
}
.tlh-events .tlh-event .tlh-event__body .tlh-event__location address a:hover { color: inherit; }
.tlh-events .tlh-event__location address a:hover .tlh-event__map-hint { text-decoration-color: currentColor; }
.tlh-events .tlh-event__website { margin: 0; flex: 0 0 auto; }
.tlh-events .tlh-event .tlh-event__body .tlh-event__footer .tlh-event__website a {
    display: inline-flex; align-items: center; justify-content: space-between; gap: 1rem;
    min-height: 2.75rem; padding: .625rem .875rem; border: 1px solid var(--tlh-rule); border-radius: 0;
    background: transparent; color: inherit; font-family: var(--font-body, inherit); font-size: .75rem;
    font-weight: 500; line-height: 1.5; text-decoration: none;
    transition: background-color .15s ease, border-color .15s ease;
}
.tlh-events .tlh-event .tlh-event__body .tlh-event__footer .tlh-event__website a:hover { color: inherit; border-color: currentColor; background: var(--tlh-soft-rule); }
.tlh-events .tlh-events__past { margin-top: var(--events-section-gap); }
.tlh-events .tlh-events__past .tlh-events__section-header { color: var(--tlh-muted); }
.tlh-events .tlh-events__past .tlh-events__year-range { font-size: 1.25rem; }
.tlh-events .tlh-events__past ul { list-style: none; margin: 0; padding: 0; }
.tlh-events .tlh-events__past li {
    margin: 0; padding: .875rem 0; border-bottom: 1px solid var(--tlh-soft-rule);
    font-family: var(--font-body, inherit); font-size: var(--events-past-size); line-height: 1.7; color: var(--tlh-muted);
}
.tlh-events .tlh-past-event__name { font-weight: 600; }
.tlh-events .tlh-past-event__date { white-space: normal; }
.tlh-events a { overflow-wrap: anywhere; }
.tlh-events a:focus-visible { outline: 2px solid currentColor; outline-offset: 5px; }
@media (max-width: 600px) {
    .tlh-events { margin-top: 2rem; }
    .tlh-events .tlh-event { grid-template-columns: var(--events-mobile-date-column) minmax(0, 1fr); gap: var(--events-mobile-column-gap); padding: var(--events-mobile-row-space) 0; }
    .tlh-events .tlh-event__day { font-size: var(--events-mobile-day-size); }
    .tlh-events .tlh-event__month, .tlh-events .tlh-event__year { font-size: .6875rem; }
    .tlh-events .tlh-event__body > h3 { font-size: var(--events-mobile-title-size); }
    .tlh-events .tlh-event__footer { align-items: flex-start; flex-direction: column; gap: .875rem; margin-top: 1rem; }
    .tlh-events .tlh-event__location { flex: 0 1 auto; }
    .tlh-events .tlh-events__past { margin-top: 2.2rem; }
}
@media (prefers-reduced-motion: reduce) { .tlh-events .tlh-event .tlh-event__body .tlh-event__footer .tlh-event__website a { transition: none; } }
