/**
 * Digicore homepage sections.
 * Follows the Figma "After hero design" frame (7:48). The type scale below is
 * the design's own: H1 40/40, H2 32/32, H3 24/24, H4 20/20, Body Lrg 20/23,
 * Body Med 16/18, all Circular Std.
 *
 * One deviation, flagged to Chris: the design sets the quick action card text
 * in Lato, and nothing else in the file uses Lato. Rather than load a whole
 * family for three lines, it uses Body Med like every other body style. Say the
 * word and it becomes a webfont.
 */

.dc-home {
	--dc-orange: #d8592e;
	--dc-charcoal: #262626;
	--dc-salt: #ebebe5;
	--dc-ink: #1a1d21;
	--dc-grey: #6b7280;
	--dc-line: #d5d8dc;
	--dc-ground: #fffffb;
	--dc-r: 6px;
	--dc-ui: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
	--dc-display: "Circular Std", "Inter", system-ui, sans-serif;

	font-family: var(--dc-display);
	color: var(--dc-charcoal);
}

.dc-home *,
.dc-home *::before,
.dc-home *::after { box-sizing: border-box; }

.dc-home__section {
	max-width: var(--dc-max, 1440px);
	margin-inline: auto;
	padding: 64px 20px;
}

/* ---- Section headings ---- */

.dc-home__head { margin-bottom: 32px; }
.dc-home__head--centre { text-align: center; }

.dc-home__title {
	margin: 0;
	color: var(--dc-orange);
	font-family: var(--dc-display);
	font-size: 40px;
	font-weight: 700;
	line-height: 1;
}

.dc-home__intro {
	max-width: 76ch;
	margin: 12px 0 0;
	color: var(--dc-charcoal);
	font-size: 20px;
	font-weight: 450;
	line-height: 23px;
}

.dc-home__head--centre .dc-home__intro { margin-inline: auto; }

/* Sections below the opening one step down a size, per the design. */
.dc-home__section--solutions .dc-home__title,
.dc-home__section--support .dc-home__title,
.dc-home__section--trusted .dc-home__title { font-size: 32px; }

.dc-home__section--solutions .dc-home__intro,
.dc-home__section--support .dc-home__intro { font-size: 16px; line-height: 18px; }

/* ---- Buttons ---- */

.dc-home .dc-home__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 14px 20px;
	border: 1px solid transparent;
	border-radius: var(--dc-r);
	font-family: var(--dc-display);
	font-size: 16px;
	font-weight: 500;
	line-height: 16px;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

/* Sits on photography, so it is an outline in salt rather than a fill. */
.dc-home .dc-home__btn--ghost {
	border-color: var(--dc-salt);
	color: var(--dc-salt);
}

.dc-home .dc-home__btn--ghost:hover {
	background: var(--dc-salt);
	color: var(--dc-charcoal);
}

.dc-home .dc-home__btn--light {
	padding: 16px 24px;
	border-color: var(--dc-salt);
	background: var(--dc-salt);
	color: var(--dc-charcoal);
	font-size: 20px;
	line-height: 20px;
}

.dc-home .dc-home__btn--light:hover { background: #fff; border-color: #fff; }

.dc-home .dc-home__btn--quiet {
	padding: 16px 24px;
	border-color: rgba(235, 235, 229, 0.5);
	color: var(--dc-salt);
	font-size: 20px;
	line-height: 20px;
}

.dc-home .dc-home__btn--quiet:hover { border-color: var(--dc-salt); }

.dc-home__more {
	color: var(--dc-orange);
	font-family: var(--dc-display);
	font-size: 16px;
	font-weight: 500;
	line-height: 16px;
	text-decoration: none;
}

.dc-home__more:hover { text-decoration: underline; }

/* ---- Quick actions ---- */

.dc-home__actions {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
}

.dc-home__action {
	position: relative;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	gap: 16px;
	min-height: 572px;
	padding: 32px;
	overflow: hidden;
	border-radius: 8px;
	background-color: var(--dc-charcoal);
	background-position: center;
	background-size: cover;
	color: #fff;
}

/* The gradient is what makes the copy readable, so it belongs to the card
   rather than to the image, and it holds even while the image is loading. */
.dc-home__action::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(to bottom, rgba(38, 38, 38, 0) 50%, var(--dc-charcoal) 100%);
	pointer-events: none;
}

.dc-home__action.is-imageless { background-color: var(--dc-grey); }

.dc-home__action-body {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 16px;
}

.dc-home__action-title {
	margin: 0;
	font-size: 24px;
	font-weight: 700;
	line-height: 24px;
}

.dc-home__action-text {
	margin: 0;
	font-size: 16px;
	font-weight: 450;
	line-height: 18px;
}

/* ---- Solution cards ---- */

.dc-home__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
}

.dc-home__card {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border-radius: 16px;
	background: var(--dc-salt);
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.04);
	transition: box-shadow 0.25s cubic-bezier(0.32, 0.72, 0, 1), transform 0.25s cubic-bezier(0.32, 0.72, 0, 1);
}

.dc-home__card:hover {
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
	transform: translateY(-2px);
}

.dc-home__card-image {
	aspect-ratio: 400 / 168;
	background-color: var(--dc-line);
	background-position: center;
	background-size: cover;
}

/* Until Digicore supply solution imagery, the panel is the brand tint rather
   than a broken frame. */
.dc-home__card-image.is-empty {
	background: linear-gradient(160deg, #f0c1b1, #e6d9d2);
}

.dc-home__card-body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	align-items: flex-start;
	gap: 12px;
	padding: 16px;
}

.dc-home__card-title {
	margin: 0;
	font-size: 20px;
	font-weight: 700;
	line-height: 20px;
}

.dc-home__card-text {
	flex: 1 1 auto;
	margin: 0;
	font-size: 16px;
	font-weight: 450;
	line-height: 18px;
}

/* ---- Closing band ---- */

.dc-home__section--cta { padding-inline: 0; max-width: none; }

.dc-home__band {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	max-width: var(--dc-max, 1440px);
	margin-inline: auto;
	padding: 64px 96px;
	background: var(--dc-charcoal);
	color: var(--dc-salt);
}

.dc-home__band-copy { flex: 1 1 420px; }

.dc-home__band-title {
	margin: 0;
	font-size: 32px;
	font-weight: 700;
	line-height: 32px;
}

.dc-home__band-text {
	max-width: 68ch;
	margin: 16px 0 0;
	font-size: 16px;
	font-weight: 450;
	line-height: 18px;
	opacity: 0.8;
}

.dc-home__band-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

/* ---- Support ---- */

.dc-home__support {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
}

.dc-home__support-card {
	display: flex;
	gap: 16px;
	padding: 16px;
	border-radius: 16px;
	background: var(--dc-salt);
}

.dc-home__support-icon {
	flex: 0 0 auto;
	width: 64px;
	height: 64px;
	border-radius: 8px;
	background: linear-gradient(160deg, #f0c1b1, #e6d9d2);
}

.dc-home__support-body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
}

.dc-home__support-title {
	margin: 0;
	font-size: 20px;
	font-weight: 700;
	line-height: 20px;
}

.dc-home__support-text {
	margin: 0;
	font-size: 16px;
	font-weight: 450;
	line-height: 18px;
}

/* ---- Trusted by ---- */

.dc-home__logos {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 16px;
}

.dc-home__logo {
	display: grid;
	place-items: center;
	width: 160px;
	height: 80px;
	padding: 16px;
	border-radius: 8px;
	background: var(--dc-salt);
}

.dc-home__logo img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}

.dc-home__notice {
	margin: 0;
	padding: 16px;
	border: 1px dashed var(--dc-line);
	border-radius: var(--dc-r);
	color: var(--dc-grey);
	font-family: var(--dc-ui);
	font-size: 14px;
	text-align: center;
}

/* ---- Responsive ---- */

@media (max-width: 1024px) {
	.dc-home__section { padding: 48px 20px; }
	.dc-home__title { font-size: 32px; }
	.dc-home__section--solutions .dc-home__title,
	.dc-home__section--support .dc-home__title,
	.dc-home__section--trusted .dc-home__title { font-size: 28px; }
	.dc-home__intro { font-size: 18px; }

	.dc-home__actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.dc-home__action { min-height: 420px; }
	.dc-home__grid,
	.dc-home__support { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.dc-home__band { padding: 48px 32px; }
}

@media (max-width: 700px) {
	.dc-home__section { padding: 40px 16px; }
	.dc-home__title { font-size: 28px; }
	.dc-home__intro { font-size: 16px; line-height: 22px; }

	.dc-home__actions,
	.dc-home__grid,
	.dc-home__support { grid-template-columns: minmax(0, 1fr); }
	.dc-home__action { min-height: 340px; padding: 24px; }
	.dc-home__band { padding: 32px 20px; }
	.dc-home__band-title { font-size: 26px; line-height: 30px; }
	.dc-home .dc-home__btn--light,
	.dc-home .dc-home__btn--quiet { font-size: 16px; line-height: 16px; padding: 14px 20px; }
	.dc-home__logo { width: 132px; height: 68px; }
}

/* ---- Prose block ---- */

.dc-home__prose {
	max-width: 72ch;
	font-size: 17px;
	line-height: 1.65;
}

.dc-home__prose p { margin: 0 0 16px; }
.dc-home__prose p:last-child { margin-bottom: 0; }
.dc-home__prose a { color: var(--dc-orange); }

/* ---- Products in a range ---- */

.dc-home__products {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
	gap: 24px;
}

.dc-home__product {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border-radius: 16px;
	background: var(--dc-salt);
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.04);
}

.dc-home__product-image {
	aspect-ratio: 16 / 9;
	background-color: var(--dc-line);
	background-position: center;
	background-size: cover;
}

.dc-home__product-image.is-empty { background: linear-gradient(160deg, #f0c1b1, #e6d9d2); }

.dc-home__product-body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	align-items: flex-start;
	gap: 10px;
	padding: 20px;
}

/* The part number, which is what a fleet manager actually quotes back at us. */
.dc-home__model {
	margin: 0;
	color: var(--dc-grey);
	font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
	font-size: 12px;
	letter-spacing: 0.04em;
}

.dc-home__product-title {
	margin: 0;
	font-size: 22px;
	font-weight: 700;
	line-height: 1.15;
}

.dc-home__product-text {
	margin: 0;
	font-size: 16px;
	font-weight: 450;
	line-height: 1.4;
}

.dc-home__product-feats {
	margin: 0;
	padding-left: 18px;
	font-size: 14px;
	line-height: 1.5;
	color: var(--dc-charcoal);
}

.dc-home__product-feats li { margin-bottom: 4px; }

.dc-home__product .dc-home__more { margin-top: auto; padding-top: 6px; }

/* ---- Spec comparison ---- */

/* A wide table has to scroll inside its own box, never push the page sideways. */
.dc-home__table-scroll {
	overflow-x: auto;
	border-radius: 16px;
	background: var(--dc-salt);
}

.dc-home__table {
	width: 100%;
	border-collapse: collapse;
	font-size: 15px;
}

.dc-home__table th,
.dc-home__table td {
	padding: 12px 16px;
	text-align: left;
	vertical-align: top;
	border-bottom: 1px solid rgba(26, 29, 33, 0.08);
}

.dc-home__table thead th {
	background: var(--dc-charcoal);
	color: var(--dc-salt);
	font-size: 14px;
	white-space: nowrap;
}

.dc-home__table thead th:first-child { border-top-left-radius: 16px; }
.dc-home__table thead th:last-child  { border-top-right-radius: 16px; }

.dc-home__table tbody th {
	width: 30%;
	min-width: 190px;
	font-weight: 600;
	color: var(--dc-charcoal);
}

.dc-home__table tbody tr:last-child th,
.dc-home__table tbody tr:last-child td { border-bottom: 0; }

@media (max-width: 700px) {
	.dc-home__products { grid-template-columns: minmax(0, 1fr); }
	.dc-home__table { font-size: 14px; }
	.dc-home__table th, .dc-home__table td { padding: 10px 12px; }
	.dc-home__table tbody th { min-width: 150px; }
}

/* ---- Hero with product imagery ---- */

.dc-home__hero {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
	gap: 48px;
	align-items: center;
}

.dc-home__hero-title {
	margin: 0;
	color: var(--dc-orange);
	font-size: 44px;
	font-weight: 700;
	line-height: 1.05;
}

.dc-home__hero-stand {
	margin: 12px 0 20px;
	font-size: 20px;
	font-weight: 700;
	line-height: 1.25;
}

.dc-home__hero-media {
	border-radius: 16px;
	overflow: hidden;
	background: var(--dc-salt);
}

.dc-home__hero-media img {
	display: block;
	width: 100%;
	height: auto;
}

.dc-home .dc-home__btn--solid {
	margin-top: 24px;
	border-color: var(--dc-orange);
	background: var(--dc-orange);
	color: var(--dc-salt);
}

.dc-home .dc-home__btn--solid:hover { background: #c44e26; border-color: #c44e26; }

/* ---- Capability pillars ---- */

.dc-home__pillars {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 24px;
}

.dc-home__pillar {
	padding: 24px;
	border-radius: 16px;
	background: var(--dc-salt);
}

.dc-home__pillar-title {
	margin: 0 0 12px;
	color: var(--dc-orange);
	font-size: 18px;
	font-weight: 700;
	line-height: 1.2;
}

.dc-home__pillar-list {
	margin: 0;
	padding-left: 18px;
	font-size: 15px;
	line-height: 1.5;
}

.dc-home__pillar-list li { margin-bottom: 8px; }
.dc-home__pillar-list li:last-child { margin-bottom: 0; }

/* ---- Checklist ---- */

.dc-home__checks {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 10px 24px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.dc-home__checks li {
	position: relative;
	padding-left: 26px;
	font-size: 16px;
	line-height: 1.4;
}

/* A tick drawn in CSS rather than an icon file, so it inherits the brand colour. */
.dc-home__checks li::before {
	content: "";
	position: absolute;
	top: 5px;
	left: 4px;
	width: 6px;
	height: 11px;
	border: solid var(--dc-orange);
	border-width: 0 2px 2px 0;
	transform: rotate(45deg);
}

.dc-home__footnote {
	margin: 24px 0 0;
	color: var(--dc-grey);
	font-size: 14px;
}

@media (max-width: 900px) {
	.dc-home__hero { grid-template-columns: minmax(0, 1fr); gap: 28px; }
	.dc-home__hero-media { order: -1; }
	.dc-home__hero-title { font-size: 32px; }
	.dc-home__hero-stand { font-size: 18px; }
}

/* ---- Placeholder artwork ----
 * The tint alone reads as a design choice, which makes an unfinished page look
 * finished in a review. These say what they are.
 */

.dc-home__placeholder {
	display: grid;
	place-items: center;
	width: 100%;
	height: 100%;
	color: rgba(38, 38, 38, 0.5);
	font-family: var(--dc-ui);
	font-size: 13px;
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.dc-home__hero-media.is-empty,
.dc-home__card-image.is-empty,
.dc-home__product-image.is-empty {
	display: grid;
	place-items: center;
	background: repeating-linear-gradient(
		135deg,
		#f0c1b1 0 14px,
		#e9d3c8 14px 28px
	);
}

.dc-home__hero-media.is-empty { aspect-ratio: 4 / 3; }
