/* Schedule for LibreTime — deliberately light: fonts, sizes and colours come from your theme. */
.sflt {
	--sflt-accent: #d6213f;
	--sflt-accent-text: #fff;
	--sflt-muted: color-mix(in srgb, currentColor 62%, transparent);
	--sflt-line: color-mix(in srgb, currentColor 14%, transparent);
	--sflt-gap: .75rem;
	box-sizing: border-box;
}
.sflt *, .sflt *::before, .sflt *::after { box-sizing: inherit; }
.sflt [hidden] { display: none !important; }

.sflt-title { margin: 0 0 var(--sflt-gap); }

/* Day header: a chip followed by a hairline, like a timeline. */
.sflt-days { display: grid; gap: calc(var(--sflt-gap) * 1.5); }
.sflt-day-title {
	display: flex; align-items: center; gap: .6em;
	margin: 0 0 .25rem; font-size: .875rem; line-height: 1.2; font-weight: 700;
	text-transform: none; letter-spacing: normal;
}
.sflt-day-title::after { content: ""; flex: 1; height: 1px; background: var(--sflt-line); }
.sflt-day-label, .sflt-day-date { white-space: nowrap; }
.sflt-day-title .sflt-day-date::first-letter { text-transform: uppercase; }
.sflt-day-label {
	padding: .25em .55em; border-radius: 4px; border: 1px solid currentColor;
}
.sflt-day.is-today .sflt-day-label { background: var(--sflt-accent); border-color: var(--sflt-accent); color: var(--sflt-accent-text); }

.sflt-items { list-style: none; margin: 0; padding: 0; }
.sflt-item {
	display: flex; gap: var(--sflt-gap); align-items: flex-start;
	margin: 0; padding: .6rem 0; border-bottom: 1px solid var(--sflt-line);
	line-height: 1.35;
}
.sflt-item:last-child { border-bottom: 0; }
.sflt-item::before, .sflt-item::marker { content: none; }
.sflt-body { flex: 1; min-width: 0; }
.sflt-when { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; margin-right: .4em; }
.sflt-sep { margin: 0 .15em; }
.sflt-end { font-weight: 400; color: var(--sflt-muted); }
.sflt-day-short { font-weight: 400; color: var(--sflt-muted); margin-right: .25em; }
.sflt-name a { text-decoration: none; }
.sflt-name a:hover, .sflt-name a:focus { text-decoration: underline; }
.sflt-desc { margin: .25rem 0 0; font-size: .9em; color: var(--sflt-muted); }
.sflt-image { flex: none; width: 56px; height: 56px; object-fit: cover; border-radius: 4px; }
.sflt-empty, .sflt-stale { margin: .4rem 0; color: var(--sflt-muted); font-style: italic; }
.sflt-stale { font-size: .85em; }

/* "On air" badge, only visible on the live show. */
.sflt-badge {
	display: none; vertical-align: middle; margin-left: .35em;
	padding: .15em .5em; border-radius: 999px; font-size: .72em; font-weight: 700;
	text-transform: uppercase; letter-spacing: .04em; line-height: 1.4;
	background: var(--sflt-accent); color: var(--sflt-accent-text);
}
.sflt-item.is-live .sflt-badge { display: inline-block; }
.sflt-item.is-live .sflt-name { font-weight: 700; }

/* Week layout: one column per day, stacking on narrow screens. */
.sflt-layout-week .sflt-days { grid-template-columns: repeat(auto-fit, minmax(min(100%, 8rem), 1fr)); gap: var(--sflt-gap); align-items: start; }
.sflt-layout-week .sflt-day-title { flex-wrap: wrap; }
.sflt-layout-week .sflt-day-title::after { flex-basis: 100%; }
.sflt-layout-week .sflt-item { font-size: .925em; }

/* On air widget. */
.sflt-now { display: flex; gap: var(--sflt-gap); align-items: center; line-height: 1.35; }
.sflt-now-image { flex: none; width: 64px; height: 64px; object-fit: cover; border-radius: 4px; }
.sflt-now-body { min-width: 0; }
.sflt-now-label {
	display: inline-block; padding: .15em .55em; border-radius: 4px; margin-right: .35em;
	font-size: .78em; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
	background: var(--sflt-muted); color: var(--sflt-accent-text);
}
.sflt-now.is-live .sflt-now-label { background: var(--sflt-accent); }
.sflt-now.is-live .sflt-now-label::before {
	content: ""; display: inline-block; width: .5em; height: .5em; margin-right: .4em; vertical-align: .08em;
	border-radius: 50%; background: currentColor; animation: sflt-pulse 1.6s ease-in-out infinite;
}
.sflt-now-show { font-weight: 700; }
.sflt-now-track::before { content: "· "; color: var(--sflt-muted); }
.sflt-now-show:empty + .sflt-now-track::before { content: none; }
.sflt-now-next { display: block; font-size: .875em; color: var(--sflt-muted); margin-top: .15em; }
.sflt-now-next-time { font-variant-numeric: tabular-nums; }

@keyframes sflt-pulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .sflt-now.is-live .sflt-now-label::before { animation: none; } }
@media (max-width: 600px) { .sflt-layout-week .sflt-days { grid-template-columns: 1fr; } }

/* Play button. */
.sflt-play {
	flex: none; display: inline-flex; align-items: center; justify-content: center;
	width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; cursor: pointer;
	background: var(--sflt-accent); color: var(--sflt-accent-text);
}
.sflt-play:hover { filter: brightness(1.1); }
.sflt-play:focus-visible { outline: 2px solid var(--sflt-accent); outline-offset: 2px; }
.sflt-play .sflt-icon-stop, .sflt-play.is-playing .sflt-icon-play { display: none; }
.sflt-play.is-playing .sflt-icon-stop { display: block; }
