:root {
	--jim-lila: #621a6b;
	--jim-grau: #727272;
	--jim-hellgrau: #a1a1a1;
}

/* Multi-day events */
.fc-event.jcal-multiday { border-width: 3px 3px 3px 6px !important; }
.fc-event.jcal-multiday .fc-event-main { color: var(--jim-grau) !important; }
.fc-event.jcal-multiday:hover .fc-event-main { color: #000 !important; }
.fc-event-main-frame { padding-left: 3px !important; }

/* Two-line event display: time on first line, title on second */
.fc-daygrid-event:not(.fc-daygrid-dot-event) .fc-event-main-frame {
	flex-direction: column !important;
	flex-wrap: nowrap !important;
	align-items: flex-start !important;
	height: auto !important;
	gap: 0;
}
.fc-direction-ltr .fc-daygrid-event .fc-event-time {
	display: block !important;
	font-size: 1em;
	font-weight: 400;
	line-height: 1.3;
	opacity: 1;
}
.fc-daygrid-event:not(.fc-daygrid-dot-event) .fc-event-title-container {
	width: 100%;
	line-height: 1.3;
}
.fc-event-title {
	font-weight: 700;
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
}
.fc-event:hover .fc-event-title,
.fc-event:hover .fc-event-time { color: #000 !important; }

/* Calendar toggles */
.jcal-toggles {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 14px;
}

.jcal-toggle-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 5px 14px 5px 10px;
	border-radius: 5px;
	border: 2px solid transparent;
	cursor: pointer;
	font-size: 0.85em;
	font-weight: 600;
	font-family: inherit;
	line-height: 1.4;
	transition: background-color 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.jcal-toggle-btn.inactive {
	opacity: 0.55;
}

.jcal-toggle-dot {
	width: 9px;
	height: 9px;
	border-radius: 50%;
	flex-shrink: 0;
}

/* Modal */
.jcal-overlay {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.5);
	z-index: 9999;
	align-items: center;
	justify-content: center;
}

.jcal-box {
	background: #fff;
	border-radius: 6px;
	padding: 28px;
	max-width: 1200px;
	width: 100%;
	position: relative;
	max-height: 90vh;
	overflow-y: auto;
}

.jcal-close {
	position: absolute;
	top: 12px;
	right: 16px;
	background: transparent;
	border: none;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	color: var(--jim-lila);
	padding: 0;
}
.jcal-close:hover,
.jcal-close:focus,
.jcal-close:active {
	color: #888;
	background: transparent;
}

#jcal-title {
	margin: 0 0 14px;
	font-size: 1.2em;
	padding-right: 28px;
}

.jcal-meta {
	margin: 0 0 6px;
	color: #555;
	font-size: 0.9em;
}

#jcal-body {
	margin-top: 14px;
	font-size: 0.95em;
}

.jcal-footer {
	margin-top: 22px;
	display: flex;
	gap: 8px;
	justify-content: flex-end;
}

.jcal-btn {
	padding: 8px 16px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 0.9em;
	text-decoration: none;
}
.jcal-btn-primary {
	background: var(--jim-lila);
	border-color: var(--jim-lila);
	color: #fff;
}
.jcal-btn-primary:hover,
.jcal-btn-primary:focus,
.jcal-btn-primary:active {
	background: var(--jim-grau);
	border-color: var(--jim-grau);
	color: #fff;
}
#jcal-close-btn {
	background: var(--jim-hellgrau);
	#fff;
}
#jcal-close-btn:hover,
#jcal-close-btn:focus,
#jcal-close-btn:active {
	color: #fff;
	background: var(--jim-grau);
}