/* =====================================================================
   Roman Scaffolding — homepage sections (front-page.php).
   Loaded only on the front page (AssetsService). Site-wide header/footer,
   buttons and type live in global.css.
   ===================================================================== */

/* ---------------- Shared dark photo background ---------------- */
.sp-hero, .sp-latest { position: relative; overflow: hidden; }
.sp-hero::before, .sp-latest::before {
	content: ""; position: absolute; inset: 0;
	background-image: var(--hero-bg); background-size: cover; background-position: center; background-repeat: no-repeat;
	z-index: 0;
}
.sp-latest::after { content: ""; position: absolute; inset: 0; background: rgba(0,0,0,.72); z-index: 1; }
.sp-latest > .container { position: relative; z-index: 2; }

/* ---------------- Hero ---------------- */
/* Full-screen banner: fills the viewport below the sticky header. */
.sp-hero { background: var(--dark); color: #fff; display: flex; align-items: center;
	min-height: calc(100svh - var(--nav-height, 156px)); }
/* Overlay: opaque black on the left fading to fully transparent on the right
   (matches the live site's gradient). */
.sp-hero::after { content: ""; position: absolute; inset: 0; z-index: 1;
	background: linear-gradient(to right, #000, rgba(0,0,0,.9) 30%, rgba(0,0,0,0)); }
/* On mobile the text spans full width, so a left→right fade can't keep it
   legible — use a uniform dark overlay instead. */
@media (max-width: 767.98px) {
	.sp-hero::after { background: linear-gradient(to bottom, rgba(0,0,0,.55), rgba(0,0,0,.72)); }
}
/* Background slider: cross-fading image layers behind the fixed overlay.
   Sits above the ::before base (z0) and below the ::after gradient (z1). */
/* Hero content aligns to the page gutter (4vw) like the live site — no extra
   Bootstrap container padding (the hero has no .row that needs it). */
.sp-hero > .container { padding-inline: 0; }
.sp-hero__slides { position: absolute; inset: 0; z-index: 0; }
.sp-hero__slide {
	position: absolute; inset: 0;
	background-size: cover; background-position: center; background-repeat: no-repeat;
	opacity: 0; transition: opacity 1.2s ease-in-out;
}
.sp-hero__slide.is-active { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .sp-hero__slide { transition: none; } }

.sp-hero__inner { position: relative; z-index: 2; max-width: 760px; min-width: 0; width: 100%; padding-block: clamp(3rem, 8vw, 6rem); }
.sp-hero__title { font-size: clamp(1.9rem, 1rem + 4.2vw, 4.43rem); color: #fff; line-height: 1.04; margin-bottom: 1.1rem; overflow-wrap: break-word; }
.sp-hero__lead { font-weight: 600; color: #fff; margin-bottom: 1rem; max-width: 715px; }
.sp-hero__text { color: rgba(255,255,255,.85); margin-bottom: 1.85rem; max-width: 715px; font-size: 1.0625rem; }
.sp-hero__actions { display: flex; flex-wrap: wrap; gap: 1rem; }

/* ---------------- Who Are We ---------------- */
.sp-about { background: #000; }   /* pure black, matches live */
.sp-about p, .sp-about li { font-size: 1.0625rem; }
.sp-about-list { list-style: none; padding-left: 0; margin: 1.2rem 0 0; display: flex; flex-direction: column; gap: .6rem; }
.sp-about-list li { display: flex; gap: .65rem; align-items: flex-start; }
.sp-about-list .icon { color: var(--primary-color); flex: none; margin-top: 3px; }
.sp-about__media { position: relative; aspect-ratio: 4 / 3.3; }
.sp-about__img { position: absolute; object-fit: cover; box-shadow: 0 16px 38px rgba(0,0,0,.5); }
.sp-about__img--1 { top: 0; left: 0; width: 72%; height: 64%; }
.sp-about__img--2 { bottom: 0; right: 0; width: 62%; height: 64%; border: 6px solid #000; }
@media (max-width: 767.98px) {
	.sp-about__media { aspect-ratio: auto; display: grid; gap: 1rem; }
	.sp-about__img { position: static; width: 100%; height: auto; }
	.sp-about__img--2 { border: 0; }
}

/* ---------------- Services cards ---------------- */
.sp-services { background: #313130; }   /* charcoal, matches live */
.sp-service-card { background: #fff; overflow: hidden; height: 100%;
	display: flex; flex-direction: column; box-shadow: 0 6px 20px rgba(0,0,0,.25);
	border-left: 5px solid transparent; transition: transform .3s ease, border-color .3s ease; }
.sp-service-card:hover { transform: translateY(-4px); border-left-color: var(--primary-color); }
.sp-service-card__media { display: block; aspect-ratio: 4 / 3; overflow: hidden; }
.sp-service-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.sp-service-card:hover .sp-service-card__media img { transform: scale(1.05); }
.sp-service-card__body { padding: 1.75rem 1.5rem 2rem; text-align: center; display: flex; flex-direction: column;
	gap: 1.4rem; flex: 1; justify-content: space-between; align-items: center; }
/* Card body is a white island inside the dark section — keep the title dark
   (outranks .sp-dark h3). */
.sp-service-card .sp-service-card__title { font-size: 1.6rem; color: var(--heading-color); margin: 0; line-height: 1.2; }
.sp-service-card__body .btn { padding: 1.45rem 3rem; font-size: .85rem; }
/* Below the full 1480px layout the service cards narrow, so the See More
   button steps down with them instead of filling the card. */
@media (max-width: 1480px) {
	.sp-service-card__body .btn { padding: 1.05rem 2.1rem; font-size: .8rem; }
}

/* Rich-text content links — match the live site: bold, 1px gradient underline
   (grey/#858585 in light sections, white in dark), hover darkens. */
.sp-about :is(p, li) a, .sp-why :is(p, li) a {
	color: var(--heading-color);
	font-weight: 700;
	background-image: linear-gradient(currentColor, currentColor);
	background-repeat: no-repeat;
	background-position: 0 100%;
	background-size: 100% 1px;
	text-decoration: none;
}
.sp-about :is(p, li) a:hover, .sp-why :is(p, li) a:hover { color: var(--primary-color); }

/* ---------------- Why Choose Us ---------------- */
.sp-why { background: #fff; color: #141414; }
.sp-why .sp-h2, .sp-why p, .sp-why li, .sp-why .sp-strong { color: #141414; }
.sp-why__img { width: 100%; border-radius: 10px; box-shadow: 0 15px 35px rgba(0,0,0,.15); }
/* Tick-icon list, placed right under the heading. */
/* .sp-why-list moved to global.css (reused on the Get A Quote page). */

/* ---------------- Latest Services collage ----------------
   Live layout: one tall image left + two stacked images right, labels overlaid
   bottom-left. */
.sp-latest__grid { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 12px; aspect-ratio: 2.2; }
.sp-tile { position: relative; margin: 0; overflow: hidden; }
.sp-tile img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.sp-tile:hover img { transform: scale(1.05); }
.sp-tile--lg { grid-column: 1; grid-row: 1 / 3; }          /* big left image spans both rows */
.sp-tile__label { position: absolute; left: 0; bottom: 0; background: #fff; color: var(--heading-color);
	padding: .8rem 1.75rem; font-weight: 700; font-size: 1.28rem; font-family: var(--font-head); line-height: 1.2; }
@media (max-width: 575.98px) {
	.sp-latest__grid { grid-template-columns: 1fr; grid-template-rows: none; aspect-ratio: auto; }
	.sp-tile { aspect-ratio: 16 / 10; }
	.sp-tile--lg { grid-column: 1; grid-row: auto; }
}

/* ---------------- Scaffolding Made Easy (steps) ---------------- */
.sp-steps { background: #313130; }   /* charcoal, matches the live section */
.sp-steps__list { display: flex; justify-content: space-between; gap: 1rem; margin: 0; position: relative; flex-wrap: wrap; }
.sp-step { flex: 1; min-width: 180px; text-align: center; position: relative; z-index: 1; }
.sp-step__icon { width: 116px; height: 116px; border-radius: 50%; background: #d3d3d1; display: flex; align-items: center;
	justify-content: center; margin: 0 auto 1.1rem; transition: background-color .3s ease; }
.sp-step__icon img { width: 104px; height: 104px; object-fit: contain; transition: filter .3s ease; }
.sp-step:hover .sp-step__icon { background: var(--primary-color); }
.sp-step:hover .sp-step__icon img { filter: invert(1) brightness(2); }   /* matches live hover */
.sp-step__label { font-weight: 600; color: #fff; font-size: 1rem; margin: 0; }
/* Phones: two steps per row. The 180px min-width could not fit two columns on
   a narrow screen, so every step wrapped onto its own line. */
@media (max-width: 767.98px) {
	.sp-steps__list { justify-content: flex-start; gap: 1.5rem 1rem; }
	.sp-step { flex: 0 0 calc((100% - 1rem) / 2); min-width: 0; }
}
@media (min-width: 768px) {
	/* Thin solid connector between the circle centres. */
	.sp-steps__list::before { content: ""; position: absolute; top: 58px; left: 12%; right: 12%; height: 1px; z-index: 0;
		background: rgba(255,255,255,.3); }
}

/* ---------------- Red CTA band ---------------- */
.sp-cta-red { background: var(--primary-color); color: #fff; padding-block: clamp(2.25rem, 4.5vw, 3.5rem); }
.sp-cta-red__inner { display: flex; align-items: center; justify-content: space-between; gap: 2.5rem; flex-wrap: wrap; }
.sp-cta-red__title { color: #fff; font-size: clamp(1.5rem, 1.05rem + 1.6vw, 2.27rem); margin: 0; flex: 1 1 560px; line-height: 1.12; }
.sp-cta-red__contact { display: flex; align-items: center; gap: 1rem; }
.sp-cta-red__icon { color: #fff; display: inline-flex; flex: none; }
.sp-cta-red__support { text-align: left; }
.sp-cta-red__label { margin: 0 0 .3rem; font-weight: 400; font-size: 1.5rem; color: #fff; line-height: 1.2; }
.sp-cta-red__phone { color: #fff; font-size: 1.5rem; font-weight: 400; text-decoration: underline; text-underline-offset: 3px; line-height: 1.2; }
.sp-cta-red__phone:hover { opacity: .85; color: #fff; }
.sp-cta-red .btn-sp-light { flex: none; }
@media (max-width: 767.98px) { .sp-cta-red__title { flex-basis: 100%; } }

/* The testimonials slider moved to global.css - it is shared with the
   About Us page. */

/* ---------------- Final CTA ("Ready for us to help you?") ---------------- */
/* Match the live section's compact rhythm: ~55px band padding, 38px under the
   heading, 31px under the paragraph. */
/* .sp-final now lives in global.css - it is shared with the Gallery page. */

/* Phones only. The live CTA size (1.55rem 3.3rem, set in global.css) is too
   large for a narrow screen, and the two hero buttons will not share a line
   at it. Desktop keeps the live size untouched. */
@media (max-width: 767.98px) {
	.sp-hero__actions { flex-wrap: nowrap; gap: .75rem; }
	.sp-hero__actions .btn { padding: 1rem clamp(1rem, 4.5vw, 2.1rem); font-size: .9rem; white-space: nowrap; min-width: 0; }
	.sp-cta-red .btn-sp-light { padding: 1.05rem 2.1rem; font-size: .9rem; }
}
