/* ---------- Event Calendar Pro : front-end ---------- */
.ecp-calendar {
	--ecp-radius: 10px;
	--ecp-border: #e5e7eb;
	--ecp-bg: #ffffff;
	--ecp-text: #1f2937;
	--ecp-muted: #6b7280;
	--ecp-surface: #f3f4f6;
	--ecp-cell-bg: #fafafa;
	--ecp-cell-active-bg: #f5f6ff;
	--ecp-cell-text: #1f2937;
	--ecp-today-border: #4f46e5;
	--ecp-meta-bg: #f4f4f6;
	--ecp-meta-text: #1f2937;
	--ecp-title-color: #1f2937;
	--ecp-nav-color: #4f46e5;
	--ecp-agenda-accent: #4f46e5;
	--ecp-day-height: 46px;
	--ecp-content-font: inherit;
	--ecp-content-size: 13px;
	font-family: inherit;
	color: var(--ecp-text);
	max-width: 720px;
	margin: 0 auto 1.5em;
	border: 1px solid var(--ecp-border);
	border-radius: var(--ecp-radius);
	overflow: hidden;
	background: var(--ecp-bg);
}

.ecp-hidden { display: none !important; }

.ecp-calendar__toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 14px 16px;
	border-bottom: 1px solid var(--ecp-border);
}
.ecp-calendar__nav { display: flex; align-items: center; gap: 10px; }
.ecp-calendar__title { font-weight: 700; font-size: 1.05rem; min-width: 140px; text-align: center; text-transform: capitalize; color: var(--ecp-text); }

.ecp-btn {
	border: 1px solid var(--ecp-border);
	background: var(--ecp-surface);
	color: var(--ecp-nav-color);
	border-radius: 8px;
	width: 34px;
	height: 34px;
	font-size: 16px;
	font-weight: 700;
	line-height: 1;
	cursor: pointer;
	transition: background .15s ease, opacity .15s ease;
}
.ecp-btn:hover { opacity: .75; }

.ecp-calendar__legend { display: flex; flex-wrap: wrap; gap: 10px; font-size: .8rem; font-weight: 500; color: var(--ecp-muted); }
.ecp-legend-item { display: inline-flex; align-items: center; gap: 5px; }
.ecp-legend-item i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }

.ecp-calendar__viewswitch { display: inline-flex; border: 1px solid var(--ecp-border); border-radius: 8px; overflow: hidden; }
.ecp-view-btn {
	border: none;
	background: var(--ecp-surface);
	color: var(--ecp-text);
	font-weight: 600;
	padding: 6px 12px;
	font-size: .8rem;
	cursor: pointer;
}
.ecp-view-btn.is-active { background: var(--ecp-agenda-accent); color: #fff; }

.ecp-calendar__weekdays {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	text-align: center;
	font-size: .72rem;
	font-weight: 600;
	color: var(--ecp-muted);
	padding: 8px 8px 0;
}

.ecp-calendar__grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 4px;
	padding: 8px;
}

.ecp-day {
	position: relative;
	height: var(--ecp-day-height);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	border-radius: 8px;
	cursor: default;
	font-size: .85rem;
	color: var(--ecp-cell-text);
	background: var(--ecp-cell-bg);
}
.ecp-day--empty { background: transparent; }
.ecp-day.has-events { cursor: pointer; background: var(--ecp-cell-active-bg); font-weight: 600; }
.ecp-day.has-events:hover, .ecp-day.has-events:focus { filter: brightness(0.96); outline: none; }
.ecp-day.is-today .ecp-day__number { color: var(--ecp-today-border); }
.ecp-day.is-today { box-shadow: inset 0 0 0 2px var(--ecp-today-border); }
.ecp-day.is-selected { background: var(--ecp-today-border); color: #fff; }
.ecp-day.is-selected .ecp-day__number,
.ecp-day.is-selected.is-today .ecp-day__number { color: #fff; }

.ecp-day__dots { display: flex; gap: 3px; margin-top: 3px; }
.ecp-day__dots i { width: 5px; height: 5px; border-radius: 50%; display: inline-block; }

.ecp-calendar__detail {
	border-top: 1px solid var(--ecp-border);
	padding: 14px 16px;
	background: var(--ecp-bg);
}
.ecp-calendar__detail-placeholder { color: var(--ecp-muted); font-size: .85rem; margin: 0; }
.ecp-calendar__detail .ecp-detail-date { font-weight: 700; margin-bottom: 8px; color: var(--ecp-text); }

.ecp-event-card {
	display: flex;
	gap: 12px;
	background: var(--ecp-bg);
	border: 1px solid var(--ecp-border);
	border-radius: 8px;
	overflow: hidden;
	margin-bottom: 8px;
}
.ecp-event-card__thumb { width: 72px; flex: 0 0 72px; background-size: cover; background-position: center; }
.ecp-event-card__body { position: relative; padding: 10px 12px 10px 16px; flex: 1; }
.ecp-event-card__bar { position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--ecp-color, var(--ecp-agenda-accent)); }
.ecp-event-card__title { margin: 0 0 4px; font-size: .95rem; color: var(--ecp-title-color); }
.ecp-event-card__summary { margin: 0 0 8px; font-size: .84rem; color: var(--ecp-text); opacity: .9; line-height: 1.45; display: block; }
.ecp-event-card__meta {
	list-style: none;
	margin: 0 0 6px;
	padding: 6px 10px;
	border-radius: 6px;
	background: var(--ecp-meta-bg);
	display: flex;
	flex-wrap: wrap;
	gap: 8px 14px;
	font-family: var(--ecp-content-font);
	font-size: var(--ecp-content-size);
	color: var(--ecp-meta-text);
}
.ecp-event-card__link { font-size: .8rem; font-weight: 600; color: var(--ecp-agenda-accent); text-decoration: none; }
.ecp-event-card__link:hover { text-decoration: underline; }

.ecp-agenda { padding: 14px 16px; }
.ecp-agenda__day { margin-bottom: 16px; }
.ecp-agenda__date { font-weight: 700; margin-bottom: 8px; text-transform: capitalize; color: var(--ecp-agenda-accent); }
.ecp-agenda-empty { color: var(--ecp-muted); font-size: .85rem; padding: 16px; text-align: center; margin: 0; }

.ecp-upcoming-list {
	--ecp-list-link-color: #4f46e5;
	--ecp-list-date-font: inherit;
	--ecp-list-meta-font: inherit;
	max-width: 480px;
}
.ecp-upcoming-list__title { margin: 0 0 10px; }
.ecp-upcoming-list__items { list-style: none; margin: 0; padding: 0; }
.ecp-upcoming-item {
	display: flex;
	gap: 12px;
	padding: 10px 0;
	border-bottom: 1px solid var(--ecp-border, #e5e7eb);
}
.ecp-upcoming-item:last-child { border-bottom: none; }
.ecp-upcoming-item__date {
	flex: 0 0 52px;
	height: 52px;
	border-radius: 8px;
	background: var(--ecp-color, var(--ecp-list-link-color));
	color: #fff;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	line-height: 1.1;
	font-family: var(--ecp-list-date-font);
}
.ecp-upcoming-item__day { font-size: 1.1rem; font-weight: 700; }
.ecp-upcoming-item__month { font-size: .68rem; text-transform: uppercase; }
.ecp-upcoming-item__body h4 { margin: 0 0 4px; font-size: .95rem; }
.ecp-upcoming-item__summary { display: block; margin: 0 0 6px; font-size: .82rem; color: inherit; opacity: .85; line-height: 1.45; }
.ecp-upcoming-item__meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-family: var(--ecp-list-meta-font); font-size: .78rem; color: inherit; opacity: .72; font-weight: 500; margin-bottom: 4px; }
.ecp-upcoming-item__body a { font-size: .8rem; font-weight: 600; color: var(--ecp-list-link-color); text-decoration: none; }
.ecp-upcoming-item__body a:hover { text-decoration: underline; }

@media (max-width: 560px) {
	.ecp-calendar { border-radius: 0; margin-left: -4px; margin-right: -4px; max-width: 100vw; }
	.ecp-calendar__toolbar { padding: 10px 12px; }
	.ecp-calendar__title { min-width: auto; font-size: .95rem; }
	.ecp-btn { width: 30px; height: 30px; font-size: 15px; }
	.ecp-calendar__legend { display: none; }
	.ecp-calendar__grid { gap: 2px; padding: 4px; }
	.ecp-day { font-size: .72rem; border-radius: 6px; }
	.ecp-day__dots i { width: 4px; height: 4px; }
	.ecp-event-card__thumb { display: none; }
	.ecp-calendar__viewswitch { order: 3; width: 100%; justify-content: center; }
	.ecp-calendar__viewswitch .ecp-view-btn { flex: 1; }
}
