:root {
    --clr-primary: #14391F;
    --clr-primary-light: #D6D7E2;
    --clr-secondary: #50A755;
    --clr-tertiary: #D4EAD0;
    --clr-gray: #D9D9D9;
    --black-color: hsl(220, 24%, 12%);
    --black-color-light: hsl(220, 24%, 15%);
    --black-color-lighten: hsl(220, 20%, 18%);
    --white-color: #fff;
    --body-color: hsl(220, 100%, 97%);

    --ff-base: "Rajdhani", sans-serif;
    --ff-accent: 'Arial';

    --fs-100: clamp(0.78rem, calc(0.77rem + 0.03vw), 0.80rem);
    --fs-200: clamp(0.94rem, calc(0.92rem + 0.11vw), 1.00rem);
    --fs-300: clamp(1.13rem, calc(1.08rem + 0.22vw), 1.25rem);
    --fs-400: clamp(1.35rem, calc(1.28rem + 0.37vw), 1.56rem);
    --fs-500: clamp(1.62rem, calc(1.50rem + 0.58vw), 1.95rem);
    --fs-600: clamp(1.94rem, calc(1.77rem + 0.87vw), 2.44rem);
    --fs-700: clamp(2.33rem, calc(2.08rem + 1.25vw), 3.05rem);
    --fs-800: clamp(3rem, calc(3rem + 3vw), 8rem);

    --font-regular: 400;
    --font-semi-bold: 600;
    --z-tooltip: 10;
    --z-fixed: 100;
    --header-height: 3.5rem;
}

/* html > * {
    border: 2px solid red;
} */

*,
*::before,
*::after {
    box-sizing: border-box;
}
* {
    padding: 0;
    margin: 0;
}

body {
    font-family: var(--ff-base);
    font-size: var(--fs-300);
    font-weight: 400;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    /* background-color: var(--body-color); */
}

a {color: var(--clr-tertiary);}
a:hover {text-decoration: none;}

h1, h2, h3 {
    line-height: 1;
    /*text-wrap: balance;*/
}

h1 {
    font-size: var(--fs-800);
}

h2 {
    font-size: var(--fs-700);
}

h3 {
    font-size: var(--fs-600);
    font-weight: 400;
    line-height: 1.2;
}

h4 {
    font-size: var(--fs-500);
    line-height: 1.2;
}

h5 {
    font-size: var(--fs-400);
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: .3rem;
    color: #000;
    text-transform: uppercase;
    margin: 1rem 0;
}

h6 {
    font-size: var(--fs-200);
    font-weight: 800;
    letter-spacing: 10px;
    text-transform: uppercase;
}

p {
    margin: 1rem 0;
}

a {
    color: var(--clr-primary);
}

img {
    max-width: 100%;
    display: block;
    margin: auto;
}

.logo {
    width: 250px;
}

.logo-sub {
    width: 250px;
    margin: 90px 0 0 0;
    position: relative;
    z-index: 99998;
}

.btn-primary {
    display: inline-block;
    align-self: center;
    border-radius: 4px;
    padding: 1rem 3rem;
    background-color: var(--clr-secondary);
    color: #FFF;
    text-decoration: none;
    text-transform: uppercase;
    font-size: var(--fs-200);
    transition: background-color 0.3s ease;
    margin: .5rem 0;
    cursor: pointer;
    border: none;
}

.btn-secondary {
    display: inline-block;
    border-radius: 4px;
    padding: 1rem 3rem;
    background-color: var(--clr-secondary);
    color: #FFF;
    text-transform: uppercase;
    text-decoration: none;
    font-size: var(--fs-200);
    transition: background-color 0.3s ease;
}

.btn-secondary:hover {
    background-color: var(--clr-primary);
}

.btn-primary-small {
    border-radius: 4px;
    padding: 1rem 2rem;
    background-color: var(--clr-primary);
    color: #FFF;
    text-transform: uppercase;
    font-size: var(--fs-100);
    font-weight: 800;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.btn-primary:hover, .btn-primary-small:hover{
    background-color: var(--clr-primary);
}

.btn-black{
    background-color: #000;
    transition: background-color 0.3s ease;
}
.btn-black:hover{
    background-color: gray;
}

.btn {
    background-color: #006D68;
    color: #FFF;
    text-transform: uppercase;
    padding: .3rem 3rem;
    border-radius: 30px;
}

/*=============== HEADER & NAVIGATION ===============*/

.hero-content-wrap {
    position: relative;
    z-index: 3;
    max-width: 1200px;
    margin: 0 auto;
    bottom: -50px;
}

.hero-content {
    background-color: var(--clr-secondary);
    padding: 3rem;
    margin: -10px 0 0 0;
    box-shadow: 0 24px 24px -24px rgba(0, 0, 0, 0.25);
}

.hero-headline{
    color: var(--clr-secondary);
    font-weight: 900;
    line-height: 0; 
    display: inline-block;
    white-space: nowrap;
    word-wrap: break-word; 
    text-align: center;
    margin: 0;
    text-transform: uppercase;
}

.hero-copy{
    font-size: var(--fs-200);
    font-weight: 400;
}

.hero-copy h3{
    color: var(--clr-primary);
    margin: 0 0 1rem 0;
}

.hero-copy p {
    margin: 0;
    font-size: var(--fs-400);
}

/*=============== HOMEPAGE SECTION ===============*/

.stats {
    background-color: var(--clr-gray);
    padding: 3rem 1rem;
}

.stats-container {
    max-width: 1200px;
    margin: auto;
    display: flex;
    justify-content: space-between;
}

.stat-item {
    text-align: center;
    flex: 1;
}

.stat {
    font-size: var(--fs-500);
    font-weight: 800;
}

.lead {
    max-width: 1200px;
    margin: auto;
    display: flex;
    align-items: center;
    gap: 3rem;
    padding: 4rem 1rem;
}

.lead-text, .lead-img {
    flex: 1;
}

.center-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 3rem 0 5rem 0;
}

.news-label {
    text-align: center;
    margin-top: 6rem;
}

.hero-card-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 0;
    margin: 0 1rem;
}

@media screen and (min-width: 1200px) {
    .hero-card-wrapper {
        width: 1000px;
        height: 400px;
    }
}

.hero-card-overlay:after {
    content: "";
    position: absolute;
    z-index: 98;
    bottom: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, black 10%, rgba(0, 0, 0, 0));
}

.hero-card-wrapper img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.hero-card-content {
    width: 100%;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    padding: 1rem;
    color: white;
    z-index: 99;
}

@media screen and (min-width: 1200px) {
    .hero-card-content {
        width: 70%;
        padding: 5rem;
    }
}

.join::before {
    content: '';
    background-color: var(--clr-primary);
    opacity: .5;
    position: absolute;
    height: 100%;
    width: 100%;
    mix-blend-mode: multiply;
    transform: skewY(-3deg);
}

.join {
    position: relative;
    isolation: isolate;
    margin: 4rem 0;
}

.join::after {
    content: '';
    background-image: url("/img/pipefitter2.jpg");
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    position: absolute;
    z-index: -1;
    inset: 0;
    transform: skewY(-3deg);
}

.join-wrapper {
    max-width: 800px; 
    margin: auto;
    position: relative;
    height: 700px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.join-content {
    color: #FFF;
}

.learn-more h3{
    max-width: 1100px;
    margin: auto;
    text-align: center;
    padding: 4rem 1rem;
}

.learn-wrap {
    display: flex;
    gap: 2rem;
    max-width: 1400px;
    margin: auto;
    padding: 3rem 1rem;
    align-items: center;
}

.learn-wrap > * {
    flex: 1;
}

.learn-wrap h4 {
    text-align: center;
    margin-bottom: 1.3rem;
}

.learn-trades ul li {
    font-size: var(--fs-200);
    margin: .7rem;
}

.learn-projects {
    text-align: center;
}

.mission {
    background-image: url('/img/redwoods.jpg');
    background-repeat: no-repeat;
    background-size: cover;
    max-width: 1200px;
    margin: 5rem auto;
    height: 800px;
    display: flex;
    align-items: center;
    color: #FFF;
}
.mission h3 {
    margin: 2rem;
    max-width: 700px;
    text-shadow: 2px 2px 2px #000;
}

.divider {
    background-color: var(--clr-primary-light);
    color: var(--clr-primary);
    text-align: center;
    padding: 2rem 1rem;
    margin: 1rem auto;
    max-width: 1200px;
}

/**************** AFFILIATE LOCALS *******************/

h2.affiliate-head  {
    margin: 2rem 0;
}

.affiliates-container {
    max-width: 1400px;
    margin: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding: 20px;
}

.affiliate-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid #f8f8f8;
    border-radius: 8px;
    overflow: hidden;
    background-color: #fff;
    box-shadow: 0px 2px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.affiliate-card-image {
    width: 100%;
    height: 210px;
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.affiliate-card-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}


/* .affiliate-card-image img {
    width: 100%;
    height: 240px;
    object-fit: cover;
} */

.affiliate-card-content {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.affiliate-card-content h5{
    letter-spacing: normal;
    margin: 0;
}

.affiliate-card-content .long_name{
    font-size: var(--fs-100);
}

.affiliate-card-teaser {
    flex-grow: 1;
    margin-bottom: 16px;
}

.apprenticeship-program {
    width: 100%;
    padding: 1rem 2rem;
    background-color: var(--clr-tertiary);
    border-radius: 10px;
    margin: 5rem 0;
}

.apprenticeship-program > div {
    display: flex;
    gap: 40px;
}
.apprenticeship-program img {
  max-width: 160px;
}

.apprenticeship-program div div {
    flex: 1;
}

/***** ANNOUNCEMENT BOX *****/

.announcement {
padding: 10px;
/* margin: 50px auto;  */
background-color: #f6fda0;
border: 1px solid #ced76d;
text-align: center;
/* Initial state before animation */
opacity: 0;
transform: translateY(200px);


/* Transition for the box */
transition: opacity 0.5s ease, transform 0.5s ease;
}

/* When the announcement becomes visible */
.announcement.animate {
opacity: 1;
transform: translateY(0);
/*   transition-delay: 200ms; */
}

/* Style for the announcement text */
.announcement-text {
/* Initial state before animation */
opacity: 0;
font-size: var(--fs-500);
font-weight: 900;
/* Transition for the text with a delay (so it starts after the box animates in) */
transition: opacity 0.5s ease 0.5s; /* 0.5s delay */
}

/* When the announcement container is animated, also animate the text */
.announcement.animate .announcement-text {
opacity: 1;
}



/**************** FORMS AND WUFOO *******************/

.wufoo input.btTxt {
	@extend %btn;
	background: $red;
	text-decoration: none;
	font-size: 1rem;
	font-weight: 600;
	border: 0;
	transition: background 300ms ease-in-out;
	&:hover {
		background: $darkred;
	}
}

.sidebar-container {
    display: grid;
    grid-template-columns: 1fr 3fr; /* 1 part sidebar, 3 parts content area */
    gap: 20px; /* Adjust the space between sidebar and content area */
    max-width: 1200px;
    margin: 0 auto; /* Center the container */
    padding: 20px; /* Optional padding */
}



/* Responsive design */
@media (max-width: 768px) {
    .sidebar-container {
        grid-template-columns: 1fr; /* Stack sidebar and content area on smaller screens */
    }
}


footer {
    position: relative;
    width: 100%;
    margin-top: 2rem;
    color: #FFF;
}

.sub-footer {
    background-color: var(--clr-gray);
    width: 100%;
    padding: 4rem 1rem;
    text-align: center;
}

.partners {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    max-width: 700px;
    margin: auto;
}

.partners img { 
    width: 230px;
    display: inline;
}
    
.footer {
    background-color: var(--clr-primary);
    padding: 7rem 1rem;
}

.footer-wrap{
    max-width: 1200px;
    margin: auto;
    display: flex;
    align-items: center;
    text-align: left;
    justify-content: space-between;
}

.footer-logo {
    width: 200px;
}

.footer-left, .footer-right {
    width: 300px;
}

.footer-right {
    text-align: right;
}

a#UnionMedia__byLine{
    background: #000;
    cursor: pointer;
    width: 100%;
    text-align: center;
    padding: 2rem 1rem;
    color: #FFF;
    display: block;
    text-decoration: none;
}
.animated-background {
    color: white;
    background: linear-gradient(to right, #ff3c00 50%, #000 50%);
    background-size: 200% 100%;
    background-position: right bottom;
    transition: all 200ms ease-out;
    font-size: 12px;
    display: inline-block;
    padding: 0 0.5rem;
    position: relative;
}

a#UnionMedia__byLine:hover .animated-background {
  background-position: left bottom;
}

.animated-background::before {
    content: '';
    height: 100%;
    width: 1px;
    left: 0;
    top: 0;
    background: #000;
    position: absolute;
}

.main-container {
	max-width: 1200px;
	margin: 70px auto 40px auto;
    padding: 1rem;
}
.main-container h1 {
    color: var(--clr-tertiary);
    text-align: center;
    margin: 0 0 3rem 0;
}

.main-container h2 {
    color: #000;
}

.row {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	width: 100%;
	align-items: center;
}

.col {
	display: flex;
	flex-direction: column;
	flex-basis: 100%;
}

.double-col {
	display: flex;
	flex-direction: column;
	flex-basis: 100%;
}


@media screen and (min-width: 768px) {
	.col {
		flex: 1;
		padding: 3rem 1rem;
	}

	.row .col:first-child {
		padding-left: 0;
	}

	.row .col:last-child {
		padding-right: 0;
	}

	.double-col {
		flex: 2;
	}
}

.columns-three {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.columns-three > * {
    width: 100%;
    padding: 1rem;
}

.columns-three > :nth-child(2){
    text-align: center;
}

.columns-three > :last-child{
    text-align: right;
}

@media (min-width: 992px) {
    .columns-three > * {
        width:calc(100% / 3);
    }
}

@media (max-width: 768px) {
   .lead, .learn-wrap, .partners, .footer-wrap {
        flex-direction: column;
   }
   .hero-card-wrapper img {
        aspect-ratio: 9 / 16;
    }
}