/* A név és a téma mindig a teljes kártyaszélességet kapja. */
.calendar-event {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto auto auto auto;
    align-items: start;
    justify-content: stretch;
    gap: 4px;
    min-width: 0;
    height: auto;
    padding: 8px 7px;
}

.calendar-event > strong {
    display: block;
    grid-column: 1;
    grid-row: 1;
    align-self: center;
    margin: 0;
    line-height: 1.3;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.calendar-event > .calendar-event-title {
    display: block;
    grid-column: 1 / -1;
    grid-row: 2;
    min-width: 0;
    width: 100%;
    overflow: visible;
    overflow-wrap: break-word;
    word-break: normal;
    white-space: normal;
    text-overflow: clip;
    font-size: 11px;
    line-height: 1.35;
}

.calendar-event .calendar-event-mobile-name { display: none; }

.calendar-event > .calendar-event-theme {
    display: block;
    grid-column: 1 / -1;
    grid-row: 3;
    min-width: 0;
    width: 100%;
    margin: 0;
    overflow: visible;
    overflow-wrap: break-word;
    word-break: normal;
    white-space: normal;
    text-overflow: clip;
    font-size: 11px;
    font-style: normal;
    font-weight: 500;
    line-height: 1.35;
}

.calendar-event > small {
    display: block;
    grid-column: 1 / -1;
    grid-row: 4;
    min-width: 0;
    margin: 1px 0 0;
    white-space: normal;
    line-height: 1.3;
}

/* Az átlátszó illusztrációs kép hat önálló motívuma. */
.program-art {
    display: block;
    flex: none;
    width: 40px;
    height: 40px;
    background-image: url("program-illustrations-v1.png");
    background-repeat: no-repeat;
    background-size: 300% 200%;
}

.program-art--story { background-position: 0% 0%; }
.program-art--sensory { background-position: 50% 0%; }
.program-art--baby { background-position: 100% 0%; }
.program-art--yoga { background-position: 0% 100%; }
.program-art--macrame { background-position: 50% 100%; }
.program-art--craft { background-position: 100% 100%; }

.calendar-event > .program-art {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    align-self: center;
    width: 32px;
    height: 32px;
}

.session-illustrated-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 14px;
}

.session-illustrated-heading h2 {
    flex: 1;
    min-width: 0;
    margin: 0;
}

.session-illustrated-heading .program-art { width: 68px; height: 68px; }
.calendar-session-chip > .program-art { width: 34px; height: 34px; margin: 4px 0; }

.calendar-session-chip .calendar-session-name,
.calendar-session-chip .calendar-session-theme {
    white-space: normal;
    overflow: visible;
    overflow-wrap: break-word;
    word-break: normal;
    text-overflow: clip;
}

.calendar-session-chip .calendar-session-theme {
    display: block;
    margin: 3px 0 6px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.35;
}

@media (max-width: 620px) {
    .calendar-months { width: 784px; min-width: 784px; max-width: none; }
    .calendar-month { width: 784px; min-width: 784px; max-width: none; grid-template-columns: repeat(7, 112px); }
    .calendar-day { min-width: 112px; }
    .calendar-event { display: grid; gap: 3px; padding: 5px; text-align: left; }
    .calendar-event > strong { font-size: 11px; }
    .calendar-event > .program-art { width: 28px; height: 28px; }
    .calendar-event > .calendar-event-theme { font-size: 10px; line-height: 1.3; }
    .calendar-event > small { font-size: 9px; }
    .session-illustrated-heading .program-art { width: 58px; height: 58px; }
}
