#about .intro-text {
	max-width: 800px;
	margin: 0 auto 60px;
	text-align: center;
}

#about .intro-text h3 {
	color: var(--color-text);
	font-size: 1.3rem;
	font-weight: 600;
	margin-top: 8px;
}

#about .intro-text p {
	margin-top: 24px;
	line-height: 1.8;
	text-align: justify;
}

.masonry-gallery {
	display: flex;
	gap: 24px;
	align-items: stretch;
}

.masonry-column {
	display: flex;
	flex-direction: column;
	gap: 24px;
	flex: 1;
}

.masonry-item {
	position: relative;
	border-radius: 24px;
	overflow: hidden;
	width: 100%;
	background: #fff;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
	display: flex;
	flex-direction: column;
}

.masonry-item .main-img {
	width: 100%;
	height: 100%;
	min-height: 250px;
	object-fit: cover;
	display: block;
}

.masonry-overlay {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: auto;
	max-height: 50%;
	overflow: hidden;
	z-index: 1;
}

.masonry-column:first-child .masonry-item {
	flex: 1;
}

.masonry-column:nth-child(2) .masonry-item:nth-child(1) {
	flex: 1;
}

.masonry-column:nth-child(2) .masonry-item:nth-child(2) {
	flex: 1;
}

.masonry-column:nth-child(2) .masonry-item:nth-child(3) {
	flex: 1;
}

.masonry-column:last-child .masonry-item {
	flex: 1;
}

.overlay-gradient {
	background: var(--background-overlay);
}

.masonry-caption {
	position: relative;
	padding: 30px 24px;
	z-index: 2;
	color: #fff;
}

.masonry-caption .cap-year {
	font-size: 1.2rem;
	font-weight: 700;
	line-height: 1;
	margin-bottom: 3px;
}

.masonry-caption .cap-category {
	font-size: 1.2rem;
	font-weight: 800;
	letter-spacing: 1px;
	margin-bottom: 5px;
}

.masonry-caption .cap-title {
	font-family: var(--font-heading);
	font-size: 1rem;
	font-weight: 800;
	line-height: 1.3;
}

.cert-img {
	position: absolute;
	z-index: 3;
	border-radius: 6px;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Align container width with vesak-theme */
#about .container {
    max-width: 900px;
    margin: 0 auto;
}

/* Cert image variants
   Replaces: style="right: 20px; bottom: 24px; width: 30%" (2023, 2025 certs) */
.cert-img--lg {
    right: 20px;
    bottom: 24px;
    width: 30%;
}

/* Replaces: style="right: 20px; bottom: 24px; width: 20%; height: auto; object-fit: contain"
   (2024, silver, golden certs) */
.cert-img--sm {
    right: 20px;
    bottom: 24px;
    width: 20%;
    height: auto;
    object-fit: contain;
}

/* Compact overlay for smaller masonry items
   Replaces: style="height: 35%;" on three .masonry-overlay elements */
.masonry-overlay--compact {
    height: 35%;
}

/* Compact caption padding
   Replaces: style="padding: 10px 24px;" on three .masonry-caption elements */
.masonry-caption--compact {
    padding: 10px 24px;
}

.masonry-caption--compact .cap-year,
.masonry-caption--compact .cap-category {
    font-size: 0.8rem;
}

/* Replaces: style="width: 60%; font-size: 0.7rem;" on compact .cap-title elements */
.masonry-caption--compact .cap-title {
    width: 60%;
    font-size: 0.7rem;
}

/* Replaces: style="width: 65%" on main (2023 / 2025) .cap-title elements */
.cap-title--wide {
    width: 65%;
}