/* ============================================================
   About Factory — Section 04（Factory Interior 照片网格）
   Figma 746:1107 区域
   白底，min-height 1064px
   居中 header：Anton 48px 标题 + Montserrat Medium 16px 副标题
   3 列 × 2 行，列间蓝色竖线（border: 1px solid #719bd1），行间水平线
   每格：图片 370×306px + 标题 Montserrat Bold 24px #013f92 + "Get a Quote" 链接
   设计基准 1280px
   ============================================================ */

.sparta-about-factory {
	width: 100%;
	background: #ffffff;
	padding: 80px 0 100px;
}

.sparta-about-factory__inner {
	max-width: 1280px;
	margin: 0 auto;
	padding: 0 39px;
}

/* ── 居中 header ── */
.sparta-about-factory__header {
	text-align: center;
	margin-bottom: 56px;
}

.sparta-about-factory__header-title {
	font-family: 'Anton', sans-serif;
	font-size: 48px;
	font-weight: 400;
	line-height: 60px;
	color: #012f73;
	margin: 0 0 20px;
}

.sparta-about-factory__header-desc {
	font-family: 'Montserrat', sans-serif;
	font-size: 16px;
	font-weight: 500;
	line-height: 28px;
	color: #012f73;
	max-width: 760px;
	margin: 0 auto;
}

/* ── 3 列网格 ── */
/* 外边框由 grid 容器负责（top + left），每个 cell 提供 border-right + border-bottom */
/* 这样拼合成完整的四边围框 + 内部分隔线，不会出现只有中间有线的问题 */
.sparta-about-factory__grid {
	display: grid;
	grid-template-columns: repeat( 3, 1fr );
	border-top: 1px solid #719bd1;
	border-left: 1px solid #719bd1;
}

/* ── 单格 ── */
/* 上方加 padding-top 24px，让图片与分隔线之间有喘息空间，行间视觉对称 */
.sparta-about-factory__cell {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 24px 28px 36px;
	border-right: 1px solid #719bd1;
	border-bottom: 1px solid #719bd1;
	box-sizing: border-box;
}

/* 图片容器：370×306px */
.sparta-about-factory__cell-image {
	width: 100%;
	max-width: 370px;
	height: 306px;
	overflow: hidden;
	margin-bottom: 24px;
	flex-shrink: 0;
}

.sparta-about-factory__cell-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* 无图时占位 */
.sparta-about-factory__cell-image--placeholder {
	background: rgba(113, 155, 209, 0.12);
}

/* 格子标题：Montserrat Bold 24px #013f92 居中 */
.sparta-about-factory__cell-title {
	font-family: 'Montserrat', sans-serif;
	font-size: 24px;
	font-weight: 700;
	line-height: 32px;
	color: #013f92;
	text-align: center;
	margin: 0 0 14px;
}

/* "Get a Quote" 链接：18px Bold #054fbd 带下划线 */
/* !important 覆盖 Elementor reset 对 text-decoration 的清除 */
.sparta-about-factory__cell-link {
	font-family: 'Montserrat', sans-serif;
	font-size: 18px;
	font-weight: 700;
	line-height: 24px;
	color: #054fbd;
	text-decoration: underline !important;
	text-underline-offset: 3px;
	transition: opacity 0.2s;
}

.sparta-about-factory__cell-link:hover {
	color: #ffd739;
	opacity: 1;
}

/* ── 响应式 ── */
@media ( min-width: 1800px ) {
	.sparta-about-factory__inner {
		max-width: 1600px;
	}
	.sparta-about-factory__header-title {
		font-size: 56px;
	}
}

/* 平板：2 列 */
@media ( min-width: 768px ) and ( max-width: 1279px ) {
	.sparta-about-factory__grid {
		grid-template-columns: repeat( 2, 1fr );
	}
	/* 恢复全部 cell 的 border-right + border-bottom（覆盖桌面端的 nth-child 特殊情况） */
	.sparta-about-factory__cell {
		border-right: 1px solid #719bd1;
		border-bottom: 1px solid #719bd1;
	}
	/* 2 列：每行最后一格无右边线 */
	.sparta-about-factory__cell:nth-child(2n) {
		border-right: none;
	}
	/* 最后两格无下边线 */
	.sparta-about-factory__cell:nth-last-child(-n+2) {
		border-bottom: none;
	}
	.sparta-about-factory__cell-image {
		height: 240px;
	}
	.sparta-about-factory__header-title {
		font-size: 36px;
	}
}

/* 手机：单列 */
@media ( max-width: 767px ) {
	.sparta-about-factory {
		padding: 48px 0 64px;
	}
	.sparta-about-factory__inner {
		padding: 0 16px;
	}
	.sparta-about-factory__grid {
		grid-template-columns: 1fr;
		border-left: none;
		border-top: none;
	}
	/* 单列：只保留 border-bottom，无右边线 */
	.sparta-about-factory__cell,
	.sparta-about-factory__cell:nth-child(2n),
	.sparta-about-factory__cell:nth-last-child(-n+2) {
		border-right: none;
		border-bottom: 1px solid #719bd1;
		padding: 20px 0 28px;
	}
	.sparta-about-factory__cell:last-child {
		border-bottom: none;
	}
	.sparta-about-factory__cell-image {
		max-width: 100%;
		height: 220px;
	}
	.sparta-about-factory__header-title {
		font-size: 30px;
		line-height: 38px;
	}
}
