/* Events: list (templates/page-events.php) and single event (single-scs_event.php) */

.scs-events__hero { display: flex; flex-direction: column; gap: 12px; padding-top: clamp(40px, 6vw, 80px); padding-bottom: 28px; }
.scs-events__hero .scs-lead { max-width: 640px; }
.scs-events__list { display: flex; flex-direction: column; gap: 28px; padding-bottom: clamp(56px, 6vw, 88px); }

/* Cut-paper scenes: a background drawing with cast members on top. */
.scs-scene { position: relative; overflow: hidden; background: #FFF5E5; line-height: 0; }
.scs-scene--thumb { aspect-ratio: 3 / 2; }
.scs-scene--wide { aspect-ratio: 3 / 1; }
.scs-scene__bg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.scs-scene__cast { position: absolute; }
.scs-scene--wide .scs-scene__cast { transform: scale(.62); transform-origin: 50% 100%; }
.scs-scene--photo img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* List */
.ev-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 18px; }
.ev-card {
	position: relative; display: grid; grid-template-columns: minmax(180px, 260px) minmax(0, 1fr); gap: 22px; align-items: center;
	background: var(--scs-paper); border: var(--scs-border); border-radius: 18px; padding: 14px; box-shadow: 4px 6px 0 var(--scs-ink);
}
.ev-card__pic { position: relative; display: block; border-radius: 12px; overflow: hidden; border: var(--scs-border); }
.ev-date {
	position: absolute; left: 8px; top: 8px; display: flex; flex-direction: column; align-items: center; min-width: 46px; padding: 4px 6px 5px;
	background: var(--scs-paper); border: var(--scs-border); border-radius: 10px; line-height: 1; color: var(--scs-ink);
}
.ev-date__m { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--scs-red-text); }
.ev-date__d { font-family: var(--scs-font-display); font-weight: 600; font-size: 24px; margin-top: 2px; }
.ev-card__body { display: flex; flex-direction: column; gap: 8px; min-width: 0; padding-right: 8px; }
.ev-card__title { font-size: clamp(21px, .6vw + 18px, 26px); line-height: 1.15; }
.ev-card__title a { color: var(--scs-ink); text-decoration: none; }
.ev-card__title a::after { content: ""; position: absolute; inset: 0; border-radius: 16px; }
.ev-card__title a:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.ev-card__title a:focus-visible { outline: none; }
.ev-card__title a:focus-visible::after { outline: 3px solid var(--scs-teal); outline-offset: -4px; }
.ev-card__meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 15px; color: var(--scs-ink-soft); }
.ev-card__meta span { display: inline-flex; align-items: center; gap: 6px; }
.ev-card__summary { font-size: 16px; line-height: 1.5; }
.ev-badges { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.ev-badges li { font-size: 13px; font-weight: 700; padding: 3px 11px; border-radius: var(--scs-pill); border: 1.5px solid var(--scs-ink); background: var(--scs-cream); }
.ev-status { align-self: flex-start; font-size: 13px; font-weight: 700; padding: 3px 10px; border-radius: 8px; background: #FCE3B0; color: #6E4210; }
.ev-status--canceled { background: #F7D6D3; color: var(--scs-red-text); }
.ev-card.is-canceled .ev-card__title a { text-decoration: line-through; }
.ev-flag { align-self: flex-start; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--scs-red-text); }

/* Featured: a red frame and a strand of twinkling lights. */
.ev-card.is-featured { border-color: var(--scs-red); box-shadow: 4px 6px 0 var(--scs-red); padding-top: 36px; background: #FFF8EC; }
.ev-lights { position: absolute; left: 10px; right: 10px; top: -6px; width: calc(100% - 20px); height: 40px; pointer-events: none; }
/* events.js gives each bulb its own speed, start and style: a slow glow or a quick blink. */
.ev-bulb { animation: ev-glow 1.8s ease-in-out infinite alternate; }
@keyframes ev-glow { 0% { opacity: .3; } 100% { opacity: 1; } }
@keyframes ev-blink { 0%, 60%, 100% { opacity: 1; } 68%, 88% { opacity: .2; } }

.ev-empty { font-size: 18px; padding: 28px; border: 2px dashed var(--scs-rule); border-radius: 16px; background: var(--scs-paper); }
.ev-past summary { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-family: var(--scs-font-display); font-weight: 600; font-size: 20px; color: var(--scs-red-text); list-style: none; min-height: 44px; }
.ev-past summary::-webkit-details-marker { display: none; }
.ev-past summary .scs-icon { transition: transform .2s ease; }
.ev-past[open] summary .scs-icon { transform: rotate(180deg); }
.ev-list--past { margin-top: 14px; }
.ev-card.is-past { box-shadow: none; opacity: .85; }

/* Single event */
.scs-event__inner { display: flex; flex-direction: column; gap: 22px; padding-top: clamp(28px, 4vw, 48px); padding-bottom: clamp(56px, 6vw, 88px); }
.scs-event .scs-back { align-self: flex-start; min-height: 44px; }
.ev-notice > div { display: flex; gap: 12px; align-items: flex-start; }
.ev-hero { position: relative; border: var(--scs-border); border-radius: 18px; overflow: hidden; box-shadow: 4px 6px 0 var(--scs-ink); }
.scs-event.is-featured .ev-hero { border-color: var(--scs-red); box-shadow: 4px 6px 0 var(--scs-red); overflow: visible; }
.scs-event.is-featured .ev-hero > .scs-scene { border-radius: 16px; }
.scs-event.is-featured .ev-lights { top: -18px; z-index: 2; }
.ev-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(260px, 1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.ev-main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ev-title { line-height: 1.05; }
.ev-content { font-size: 18px; line-height: 1.7; }
.ev-content > * + * { margin-top: 12px; }
.ev-facts { position: sticky; top: 24px; display: flex; flex-direction: column; gap: 18px; background: var(--scs-paper); border: var(--scs-border); border-radius: 18px; padding: 22px; box-shadow: 4px 6px 0 var(--scs-ink); }
.ev-facts dl { margin: 0; display: flex; flex-direction: column; gap: 14px; }
.ev-facts dt { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--scs-green); }
.ev-facts dd { margin: 2px 0 0; font-size: 17px; line-height: 1.5; }
.ev-facts__soft { color: var(--scs-ink-soft); font-size: 15px; }
.ev-facts dd a { font-weight: 700; }
.ev-facts__actions { display: flex; flex-direction: column; gap: 10px; }
.ev-facts__actions .scs-btn { justify-content: center; }

/* W and O: one of five gags, picked at random. */
.scs-wo { margin-top: 12px; }
.scs-wo__gag { margin: 0; display: grid; grid-template-columns: minmax(0, 260px) minmax(0, 1fr); gap: 18px; align-items: end; padding: 16px; border: 2px dashed var(--scs-rule); border-radius: 16px; background: var(--scs-paper); }
.scs-wo__art { display: flex; align-items: flex-end; justify-content: center; gap: 4px; }
.scs-wo__cast { position: relative; }
.scs-wo__bow { position: absolute; left: 30%; top: -6%; width: 40%; z-index: 1; }
.scs-wo .scs-caption { align-self: center; font-size: 16px; }

@media (max-width: 760px) {
	.ev-card { grid-template-columns: minmax(0, 1fr); gap: 14px; }
	.ev-card__body { padding: 0 4px 4px; }
	.scs-scene--wide { aspect-ratio: 3 / 2; }
	.scs-scene--wide .scs-scene__cast { transform: none; }
	.ev-grid { grid-template-columns: minmax(0, 1fr); }
	.ev-facts { position: static; }
	.scs-wo__gag { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .ev-bulb { animation: none; } }
