/**
 * Custom styles for the Our Work archive, sector term archives, and
 * project cards.
 * SAVE AS: inc/our-work/assets/css/our-work.css
 *
 * Enqueued only on those templates -- see dhg_enqueue_our_work_assets()
 * in inc/our-work/templates-our-work.php.
 *
 * Colors are approximate from the design reference -- swap
 * --dhg-green for the exact brand hex before launch.
 */

:root {
	--dhg-green: #2A9E61;
	--dhg-dark: #1c1c1c;
	--dhg-text-light: #f5f5f5;
}

.container {
    width: 100%;
    max-width: 1528px;
    margin: 0 auto;
    padding: 0 20px;
}

#dhg-sector-tabs {
	scroll-margin-top: 100px; 
}

/* Hero banner */
.dhg-hero-banner {
	position: relative;
	background-color: var(--dhg-dark);
	background-size: cover;
	background-position: center;
	color: var(--dhg-text-light);
	padding: 50px 0 10px 0;
    min-height: 638px;
	display: flex;
	margin-bottom: 70px;
}

.dhg-hero-banner::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.74);
	pointer-events: none;
}

.dhg-hero-banner .container {
  display: flex;
  flex-direction: column;
  height: auto;                 /* replace height: 100% with this */
  align-self: stretch;               /* fill the section's padded height */
}

.dhg-hero-banner__inner {
	position: relative;
    width: 100%;
    max-width: 661px;
	display: flex;
	flex-direction: column;
	justify-content: center;      /* centers title + paragraph */
	flex: 1;
	padding-bottom: 50px;
}

.dhg-hero-banner__inner h1 {
	margin-bottom: 30px;
    position: relative;
    padding-bottom: 25px;
}

.dhg-hero-banner__inner h1:after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 200px;
	height: 2px;
	background-color: var(--dhg-green);
}

.dhg-hero-banner__inner h1 span {
    color: var(--dhg-green);
}

.dhg-hero-banner__content {
	margin-bottom: 32px;
	font-size: 20px;
	line-height: 1.6;
	color: #fff;
}

/* Sector tabs */
.dhg-sector-tabs {
	position: relative;
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    margin-top: 0;
    align-items: stretch;
    justify-content: space-evenly;
}

.dhg-sector-tab {
	padding: 17px 10px;
    border: 2px solid var(--dhg-green);
    color: #fff !important;
    text-decoration: none;
    font-size: 18px;
	line-height: 120%;
    text-align: center;
    transition: background-color 0.15s ease, border-color 0.15s ease;
	width: 100%;
    display: flex;
	align-items: center;
	justify-content: center;
}

.dhg-sector-tab.is-active,
.dhg-sector-tab:hover {
	background-color: var(--dhg-green);
	border-color: var(--dhg-green);
}

/* Featured "latest project" banner -- shown above the grid, the post
   it displays is excluded from the grid itself (see
   dhg_get_featured_our_work_post() in cpt-our-work.php). */
.dhg-featured-project {
	margin-bottom: 70px;
}

.dhg-featured-project__card {
	position: relative;
    display: flex;
    min-height: 725px;
    background-size: cover;
    background-position: center;
    background-color: var(--dhg-dark);
    overflow: hidden;
    text-decoration: none;
    align-items: center;
}

.dhg-featured-project__card::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
	pointer-events: none;
}

.dhg-featured-project__overlay {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	height: 100%;
	max-width: 950px;
	padding: 50px;
	color: #fff;
}

.dhg-featured-project__partner-logo {
	min-height: 63px;
	width: auto;
}

.dhg-featured-project__title {
	font-size: 70px !important;
	font-weight: 700;
	color: #fff;
	margin-bottom: 25px;
}

.dhg-featured-project__excerpt {
	font-size: 20px;
	line-height: 1.5;
	margin-bottom: 50px;
}

.dhg-featured-project__button {
	display: inline-block;
    align-self: flex-start;
    min-width: 200px;
    color: #fff !important;
    text-align: center;
    font-size: 16px;
    font-weight: 300;
    border-radius: 4px;
    background-color: var(--dhg-green);
    transition: all ease-in-out 0.3s;
    text-transform: uppercase;
    padding: 16px 10px;
    letter-spacing: 0.5px;
}

.dhg-featured-project__button:hover {
	background-color: #fff;
	color: var(--dhg-green) !important;
}

/* Project grid */


.dhg-projects-grid__items {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 50px 20px;
}

.dhg-sector-tabs-mobile {
	display: none;
}

.dhg-project-card {
	display: flex;
	flex-direction: column;
}

.dhg-project-card__image {
	display: block;
	aspect-ratio: 4 / 4;
	overflow: hidden;
	margin-bottom: 16px;
	background-color: #eee;
}

.dhg-project-card__image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.dhg-project-card__sector {
	display: block;
    font-size: 16px;
    color: var(--e-global-color-784cc7d);
    margin-bottom: 8px;
}

.dhg-project-card__title {
	margin: 0 0 8px;
	font-size: 26px !important;
}

.dhg-project-card__title a {
	color: var(--dhg-green) !important;
}

.dhg-project-card__title a {
	color: inherit;
	text-decoration: none;
}

.dhg-project-card-content {
	padding-left: 20px;
	border-left: 2px solid var(--dhg-green);
	margin-bottom: 20px;
	flex-grow: 1;
}

.dhg-project-card__excerpt {
	font-size: 16px;
    line-height: 1.5;
    color: var(--e-global-color-784cc7d);
}

.dhg-project-card__excerpt p {
	margin: 0;
}

.dhg-project-card__link {
	font-size: 16px;
    font-weight: 700;
    color: var(--dhg-green) !important;
    text-decoration: none;
    margin-top: auto;
    border-top: 2px solid var(--dhg-green);
    padding: 20px 0 0 15px;
	display: flex;
	gap: 12px;
}

.dhg-project-card__arrow {
	transition: all ease-in-out 0.3s;
	transform: rotate(0);
}

.dhg-project-card__arrow svg {
	width: 15px;
    height: 15px;
}

.dhg-project-card__link:hover .dhg-project-card__arrow  {
	transform: rotate(45deg);
}

/* Pagination (core the_posts_pagination() output) */
.dhg-pagination {
	margin-top: 60px;
	text-align: center;
}

.dhg-pagination .dhg-load-more__button {
	padding: 18px 12px !important;
}

.dhg-pagination .page-numbers {
	display: inline-block;
	padding: 10px 24px;
	border: 1px solid var(--dhg-green);
	border-radius: 4px;
	color: var(--dhg-green);
	text-decoration: none;
	font-size: 13px;
	text-transform: uppercase;
	margin: 0 4px;
}

.dhg-pagination .page-numbers.current,
.dhg-pagination .page-numbers:hover {
	background-color: var(--dhg-green);
	color: #fff;
}

/* CTA banner */
.dhg-cta-banner {
	background-color: var(--dhg-green);
	display: grid;
	grid-template-columns: 1fr 1fr;
	margin-top: 100px;
	gap: 80px;
	min-height: 932px;
}


.dhg-cta-banner__content {
	color: #fff;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: end;
	padding: 50px 20px;
}

.dhg-cta-banner__content__inner {
	width: 100%;
	max-width: 705px;
}

.dhg-cta-banner__logo {
	width: 100%;
    height: 49px;
    margin-bottom: 20px;
    object-fit: contain;
    object-position: left;
}

.dhg-cta-banner__content h2 {
	font-size: 40px;
    margin-bottom: 30px;
    color: #fff;
    position: relative;
    width: 100%;
    max-width: 450px;
    padding-bottom: 30px
}

.dhg-cta-banner__content h2:after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 200px;
	height: 2px;
	background-color: var(--e-global-color-784cc7d);
}

.dhg-cta-banner__text {
	margin-bottom: 24px;
	font-size: 19px;
	line-height: 1.6;
}

.dhg-cta-banner__buttons {
	display: flex;
	flex-wrap: wrap;
	margin-top: 50px;
	gap: 12px;
}

.dhg-cta-banner__button {
	padding: 14px 10px;
    border: 2px solid #fff;
    border-radius: 4px;
    color: #fff !important;
    text-decoration: none;
    font-size: 16px;
    text-transform: uppercase;
    transition: background-color 0.15s ease, color 0.15s ease;
    background-color: transparent !important;
    min-width: 200px;
    text-align: center;
}

.dhg-cta-banner__button:hover {
	background-color: #fff !important;
	color: var(--dhg-green) !important;
}

.dhg-cta-banner__image {
	overflow: hidden;
}

.dhg-cta-banner__image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.dhg-featured-project__partner-logos {
	display: flex;
    align-items: center;
    width: 100%;
    max-width: 629px;
    border-bottom: 2px solid var(--dhg-green);
    padding-bottom: 20px;
    margin-bottom: 15px;
    gap: 40px;
}

.dhg-sector-tabs-mobile {
	z-index: 0;
	outline: none;
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	background-color: var(--dhg-green);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' viewBox='0 0 14 8' fill='none'%3E%3Cpath d='M1 1L7 7L13 1' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: calc(50% + 80px) center;
	background-size: 14px 8px;
	color: #fff;
	border: none;
	font-size: 18px;
	font-weight: 500;
	text-align: center;
	text-align-last: center;
	-moz-text-align-last: center;
	padding: 20px;
	width: 100%;
	border-radius: 0;
	cursor: pointer;
}


@media (max-width: 1366px) {
	.dhg-sector-tab {
		font-size: 16px;
	}

	.dhg-cta-banner {
		min-height: 600px;
	}
}

@media (max-width: 1024px) {
	.dhg-hero-banner {
		padding-bottom: 0;
		min-height: 500px;
	}

	.dhg-sector-tabs {
		display: none;
	}

	.dhg-sector-tabs-mobile {
		display: block;
	}

	.dhg-hero-banner .container {
		padding: 0;
	}

	.dhg-hero-banner__inner {
		padding-left: 20px;
		padding-right: 20px;
		padding-bottom: 50px;
	}

	.dhg-projects-grid__items {
		grid-template-columns: repeat(2, 1fr);
	}

	.dhg-featured-project__title {
    	font-size: 50px !important;
	}

	.dhg-featured-project__card {
		min-height: 600px;
	}

	.dhg-cta-banner {
		grid-template-columns: repeat(1, 1fr);
		gap: 0;
		margin-top: 50px;
	}

	.dhg-cta-banner__content__inner {
		max-width: 100%;
	}

	.dhg-cta-banner__content h2 {
		max-width: 100%;
	}
}

@media (max-width: 900px) {
	.dhg-projects-grid__items {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 767px) {
	.dhg-featured-project__title {
		font-size: 40px !important;
	}

	.dhg-hero-banner {
		min-height: 444px;
		margin-bottom: 20px;
	}

	.dhg-featured-project {
		margin-bottom: 20px;
	}

	.dhg-featured-project__overlay {
		padding: 30px 20px;
	}

	.dhg-featured-project__excerpt {
		margin-bottom: 30px;
	}

	.dhg-featured-project__title {
		margin-bottom: 15px;
	}

	.dhg-featured-project__card {
        min-height: 500px;
    }

	.dhg-projects-grid__items {
		gap: 35px;
	}

	.dhg-cta-banner__image {
		padding-left: 20px;
    	padding-right: 20px;
	}
}

@media (max-width: 600px) {
	.dhg-projects-grid__items {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 800px) {
	.dhg-cta-banner {
		grid-template-columns: 1fr;
	}
}