/**
 * Eventide front-end styles.
 *
 * Deliberately lightweight: inherits the theme's fonts and sizing, sets only
 * structure, spacing and colour. Brand colour comes from --eventide-accent;
 * per-event colour from --evt-cat-color (falls back to the accent).
 */

.evt-wrap {
	--evt-color: var( --evt-cat-color, var( --eventide-accent, #4b6b5b ) );
}

/* ---------- Shared meta lines ---------- */
.evt-meta-line {
	display: flex;
	align-items: flex-start;
	gap: 0.5em;
	margin: 0 0 0.5em;
}

.evt-icon {
	flex: 0 0 auto;
	line-height: 1.4;
	color: var( --eventide-accent, #4b6b5b );
}

.evt-venue {
	display: block;
	font-weight: 600;
}

.evt-address {
	display: block;
	color: inherit;
	text-decoration: none;
}

a.evt-address:hover {
	text-decoration: underline;
}

/* ---------- Categories ---------- */
.evt-cats {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
}

.evt-cat {
	--c: var( --evt-cat-color, var( --eventide-accent, #4b6b5b ) );
	display: inline-flex;
	align-items: center;
	gap: 0.4em;
	text-decoration: none;
	line-height: 1.2;
}

.evt-cats--pill .evt-cat {
	padding: 0.25em 0.75em;
	border-radius: 999px;
	background: var( --c );
	color: #fff;
	font-size: 0.85em;
}

.evt-cats--dot .evt-cat {
	color: inherit;
}

.evt-cat-dot {
	width: 0.7em;
	height: 0.7em;
	border-radius: 50%;
	background: var( --c );
}

.evt-cats--text .evt-cat {
	color: var( --c );
}

/* ---------- Cost + button ---------- */
.evt-event-meta {
	margin: 1em 0;
}

.evt-cost {
	margin: 0 0 0.75em;
}

.evt-cost-label {
	font-weight: 600;
}

.evt-button {
	display: inline-block;
	padding: 0.7em 1.4em;
	background: var( --eventide-accent, #4b6b5b );
	color: #fff;
	text-decoration: none;
	border-radius: 6px;
	line-height: 1.2;
	transition: opacity 0.15s ease;
}

.evt-button:hover {
	opacity: 0.9;
	color: #fff;
}

/* ---------- Map ---------- */
.evt-map {
	width: 100%;
	border-radius: 8px;
	overflow: hidden;
}

.evt-map--leaflet {
	min-height: 240px;
	background: #eef1f0;
}

.evt-map--custom iframe {
	display: block;
	width: 100%;
	border: 0;
}

/* ---------- List ---------- */
.evt-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.evt-list-item {
	--c: var( --evt-cat-color, var( --eventide-accent, #4b6b5b ) );
	border: 1px solid rgba( 0, 0, 0, 0.08 );
	border-left: 4px solid var( --c );
	border-radius: 8px;
	background: #fff;
	transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.evt-list-item:hover {
	box-shadow: 0 6px 20px rgba( 0, 0, 0, 0.08 );
}

.evt-list-link {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1rem 1.25rem;
	text-decoration: none;
	color: inherit;
}

.evt-list-date {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: 8px;
	background: var( --c );
	color: #fff;
	line-height: 1;
}

.evt-list-day {
	font-size: 1.5em;
	font-weight: 700;
}

.evt-list-mon {
	font-size: 0.7em;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.evt-list-body {
	flex: 1 1 auto;
	min-width: 0;
}

.evt-list-title {
	display: block;
	font-weight: 600;
	font-size: 1.1em;
	margin-bottom: 0.25em;
}

.evt-list-meta {
	display: block;
	font-size: 0.9em;
	opacity: 0.8;
}

.evt-list-venue {
	display: block;
}

.evt-list--empty p {
	margin: 0;
	padding: 1.5rem;
	text-align: center;
	opacity: 0.7;
}

/* ---------- Calendar ---------- */
.evt-calendar {
	border: 1px solid rgba( 0, 0, 0, 0.08 );
	border-radius: 10px;
	overflow: hidden;
	background: #fff;
	transition: opacity 0.15s ease;
}

.evt-calendar--loading {
	opacity: 0.5;
	pointer-events: none;
}

.evt-cal-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 0.85rem 1rem;
	background: var( --eventide-accent, #4b6b5b );
	color: #fff;
}

.evt-cal-title {
	margin: 0;
	font-size: 1.15em;
	color: #fff;
}

.evt-cal-nav {
	width: 2em;
	height: 2em;
	border: 0;
	border-radius: 6px;
	background: rgba( 255, 255, 255, 0.18 );
	color: #fff;
	font-size: 1.1em;
	line-height: 1;
	cursor: pointer;
	transition: background 0.15s ease;
}

.evt-cal-nav:hover {
	background: rgba( 255, 255, 255, 0.32 );
}

.evt-cal-grid {
	display: grid;
	grid-template-columns: repeat( 7, 1fr );
}

.evt-cal-dow {
	padding: 0.5rem;
	text-align: center;
	font-size: 0.75em;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	opacity: 0.6;
	border-bottom: 1px solid rgba( 0, 0, 0, 0.06 );
}

.evt-cal-cell {
	min-height: 96px;
	padding: 0.4rem;
	border-right: 1px solid rgba( 0, 0, 0, 0.05 );
	border-bottom: 1px solid rgba( 0, 0, 0, 0.05 );
}

.evt-cal-cell:nth-child(7n) {
	border-right: 0;
}

.evt-cal-cell--muted {
	background: rgba( 0, 0, 0, 0.02 );
}

.evt-cal-cell--muted .evt-cal-num {
	opacity: 0.35;
}

.evt-cal-cell--today .evt-cal-num {
	background: var( --eventide-accent, #4b6b5b );
	color: #fff;
}

.evt-cal-num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.7em;
	height: 1.7em;
	border-radius: 50%;
	font-size: 0.85em;
	font-weight: 600;
}

.evt-cal-events {
	list-style: none;
	margin: 0.25rem 0 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 3px;
}

.evt-cal-event {
	--c: var( --evt-cat-color, var( --eventide-accent, #4b6b5b ) );
	display: block;
	padding: 2px 5px;
	border-radius: 4px;
	background: color-mix( in srgb, var( --c ) 14%, #fff );
	border-left: 3px solid var( --c );
	font-size: 0.74em;
	line-height: 1.25;
	text-decoration: none;
	color: inherit;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.evt-cal-event:hover {
	background: color-mix( in srgb, var( --c ) 24%, #fff );
}

.evt-cal-event-time {
	font-weight: 600;
	margin-right: 0.25em;
}

/* ---------- Placeholder (editor) ---------- */
.evt-placeholder {
	display: inline-block;
	padding: 0.2em 0.6em;
	border: 1px dashed rgba( 0, 0, 0, 0.25 );
	border-radius: 4px;
	font-size: 0.85em;
	opacity: 0.6;
}

/* ---------- Responsive ---------- */
@media ( max-width: 640px ) {
	.evt-cal-cell {
		min-height: 64px;
		padding: 0.25rem;
	}

	.evt-cal-event-title {
		display: none;
	}

	.evt-cal-event {
		height: 8px;
		padding: 0;
		font-size: 0;
	}

	.evt-cal-dow {
		font-size: 0.65em;
		padding: 0.4rem 0.1rem;
	}
}

/* Cancelled occurrences on the calendar */
.evt-cal-event--cancelled {
	opacity: 0.65;
}

.evt-cal-event--cancelled .evt-cal-event-title {
	text-decoration: line-through;
}

.evt-cal-event-flag {
	display: inline-block;
	margin-left: 0.25em;
	font-size: 0.85em;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	opacity: 0.8;
}
