/* =========================================================
   COMMUNITY EVENTS
   ========================================================= */

.community-events {
	width: 100%;
	margin: 80px 0;
}


/* =========================================================
   SECTION HEADER
   ========================================================= */

.community-events .section-header {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	gap: 30px;
	margin-bottom: 40px;
}

.community-events .section-title {
	max-width: 750px;
}

.community-events .section-tag {
	display: inline-block;
	background: #EEF2FF;
	color: #24346E;
	padding: 6px 16px;
	border-radius: 30px;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.4;
}

.community-events .section-title h2 {
	margin: 12px 0 10px;
	font-size: 38px;
	line-height: 1.2;
	font-weight: 700;
	color: #111827;
}

.community-events .section-title p {
	margin: 0;
	color: #6B7280;
	font-size: 17px;
	line-height: 1.7;
}


/* =========================================================
   EVENT GRID
   ========================================================= */

.community-events-grid {
	display: grid;
	grid-template-columns: repeat(
		3,
		minmax(0, 1fr)
	);
	gap: 30px;
	width: 100%;
	align-items: stretch;
}


/*
 * When there is only ONE event,
 * make the card use the available width.
 */

.community-events-grid
.community-event-card:only-child {
	grid-column: 1 / -1;
}


/* =========================================================
   EVENT CARD
   ========================================================= */

.community-event-card {
	width: 100%;
	min-width: 0;
	background: #ffffff;
	border: 1px solid #E5E7EB;
	border-radius: 20px;
	overflow: hidden;
	box-sizing: border-box;

	transition:
		transform 0.3s ease,
		box-shadow 0.3s ease,
		border-color 0.3s ease;
}

.community-event-card:hover {
	transform: translateY(-6px);
	box-shadow:
		0 20px 45px rgba(0, 0, 0, 0.08);
	border-color: #D6DAE3;
}


/* =========================================================
   EVENT IMAGE
   ========================================================= */

.community-event-image {
	width: 100%;
	overflow: hidden;
}

.community-event-image a {
	display: block;
}

.community-event-image img {
	display: block;
	width: 100%;
	height: 260px;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.community-event-card:hover
.community-event-image img {
	transform: scale(1.03);
}


/* =========================================================
   EVENT CONTENT
   ========================================================= */

.community-event-content {
	padding: 30px;
}


/* =========================================================
   EVENT DATE
   ========================================================= */

.community-event-date {
	display: inline-flex;
	align-items: center;
	background: #EEF2FF;
	color: #24346E;
	padding: 8px 16px;
	border-radius: 30px;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	margin-bottom: 20px;
}


/* =========================================================
   EVENT TITLE
   ========================================================= */

.community-event-card h3 {
	margin: 0 0 16px;
	font-size: 25px;
	line-height: 1.35;
	font-weight: 700;
	color: #111827;
}

.community-event-card h3 a {
	color: #111827;
	text-decoration: none;
	transition: color 0.25s ease;
}

.community-event-card h3 a:hover {
	color: #24346E;
}


/* =========================================================
   EVENT EXCERPT
   ========================================================= */

.community-event-excerpt {
	margin: 0 0 20px;
	color: #6B7280;
	font-size: 15px;
	line-height: 1.7;
}


/* =========================================================
   EVENT META
   ========================================================= */

.community-event-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 24px;
	margin-bottom: 20px;
	color: #6B7280;
	font-size: 15px;
	line-height: 1.5;
}

.community-event-meta span {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.community-event-meta .event-meta-icon {
	font-size: 15px;
}


/* =========================================================
   VENUE / ORGANIZER / CAPACITY
   ========================================================= */

.community-event-venue,
.community-event-organizer,
.community-event-capacity {
	margin-top: 12px;
	color: #6B7280;
	font-size: 15px;
	line-height: 1.6;
}

.community-event-venue strong,
.community-event-organizer strong,
.community-event-capacity strong {
	color: #111827;
	font-weight: 700;
}


/* =========================================================
   EVENT FOOTER
   ========================================================= */

.community-event-footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;

	margin-top: 25px;
	padding-top: 20px;

	border-top: 1px solid #E5E7EB;
}

.community-event-link {
	color: #24346E;
	font-size: 15px;
	font-weight: 700;
	text-decoration: none;

	transition: color 0.25s ease;
}

.community-event-link:hover {
	color: #EC222A;
}

.community-event-register {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	padding: 10px 18px;

	background: #24346E;
	color: #ffffff;

	border-radius: 8px;

	font-size: 14px;
	font-weight: 600;
	text-decoration: none;

	transition:
		background 0.25s ease,
		transform 0.25s ease;
}

.community-event-register:hover {
	background: #1A2550;
	color: #ffffff;
	transform: translateY(-1px);
}


/* =========================================================
   EMPTY STATE
   ========================================================= */

.community-events
.community-empty-state {
	width: 100%;
	box-sizing: border-box;

	text-align: center;

	padding: 80px 30px;

	background: #ffffff;

	border: 1px solid #E5E7EB;

	border-radius: 20px;
}

.community-events
.community-empty-state .empty-icon {
	font-size: 48px;
	line-height: 1;
	margin-bottom: 20px;
}

.community-events
.community-empty-state h3 {
	margin: 0 0 15px;
	font-size: 24px;
	line-height: 1.3;
	color: #111827;
}

.community-events
.community-empty-state p {
	margin: 0;
	color: #6B7280;
	font-size: 16px;
	line-height: 1.7;
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 1100px) {

	.community-events-grid {
		grid-template-columns:
			repeat(2, minmax(0, 1fr));
	}

}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

	.community-events {
		margin: 60px 0;
	}

	.community-events .section-header {
		flex-direction: column;
		align-items: flex-start;
		margin-bottom: 30px;
	}

	.community-events .section-title h2 {
		font-size: 32px;
	}

	.community-events .section-title p {
		font-size: 16px;
	}

	.community-events-grid {
		grid-template-columns: 1fr;
		gap: 20px;
	}

	.community-event-card:only-child {
		grid-column: auto;
	}

	.community-event-content {
		padding: 24px;
	}

	.community-event-card h3 {
		font-size: 22px;
	}

	.community-event-image img {
		height: 220px;
	}

	.community-event-footer {
		flex-direction: column;
		align-items: flex-start;
	}

}


/* =========================================================
   SMALL MOBILE
   ========================================================= */

@media (max-width: 480px) {

	.community-events .section-title h2 {
		font-size: 28px;
	}

	.community-event-content {
		padding: 20px;
	}

	.community-event-meta {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}

	.community-event-image img {
		height: 200px;
	}

}