/* Case Studies - Hero Overlay on Video */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

.casestudies-video-container-relative{
    --dm-nav-height: 80px;
    --dm-hero-offset: 250px;
    position: relative;
    min-height: 108vh;
    height: fit-content;
    /* tuck hero under nav */
    margin-top: calc(-1 * var(--dm-nav-height));
    margin-bottom: 80px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.casestudies-hero-section{
    /* overlay filling the video container */
    --dm-hero-offset: 250px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: calc(var(--dm-nav-height) + var(--dm-hero-offset)) 75px 120px;
    background-color: #ffffffcc;
    z-index: 2;
    width: 100%;
    box-sizing: border-box;
}

h1.casestudies-hero-section-bottom-header{
    font-family: "Poppins", sans-serif;
    color:#000;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight: 600;
    font-size: 64px;
    line-height: 1.05;
    margin: 0;
}

p.casestudies-hero-section-paragraph{
    color:#374754;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight: 400;
    font-size: 30px;
    font-family: "DM Sans", sans-serif;
    line-height: 1.4;
    padding: 10px 0;
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    margin-bottom: 20px;
}

.casestudies-hero-section-button-group{
    display: flex;
    width: fit-content;
    align-items: center;
    gap: 10px;
    padding: 25px 0;
    margin-bottom: 20px;
}

.casestudies-hero-section-button.get-in-touch-button{
    background-color: #53A2E8;
    border: 2px solid #53A2E8;
    color: #F5FCFF;
    padding: 10px 20px;
    border-radius: 10px;
    text-decoration: none;
    font-size: 15px;
    font-family: "Poppins", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight: 600;
}

.casestudies-hero-section-button.get-in-touch-button:hover{
    background-color: transparent;
    border: 2px solid #53A2E8;
    color: #53A2E8;
}

.casestudies-hero-section-button.learn-more-button{
    background-color: transparent;
    border: 2px solid #53A2E8;
    color: #53A2E8;
    padding: 10px 20px;
    border-radius: 10px;
    text-decoration: none;
    font-size: 15px;
    font-family: "Poppins", sans-serif;
    font-optical-sizing: auto;
    font-style: normal;
    font-weight: 600;
}

.casestudies-hero-section-button.learn-more-button:hover{
    background-color: #53A2E8;
    border: 2px solid #53A2E8;
    color: #F5FCFF;
}

/* Video Container */
.casestudies-video-container {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    text-align: start;
}

.casestudies-video-iframe, .casestudies-video {
    width: 100%;
    height: 100%;
    min-height: 200px;
    border: none;
    display: block;
    object-fit: cover;
}

/* Responsive */
@media (max-width: 1200px) {
    .casestudies-hero-section { --dm-hero-offset: 200px; padding: calc(var(--dm-nav-height) + var(--dm-hero-offset)) 50px 100px 50px; height: auto; min-height: 500px; }
    h1.casestudies-hero-section-bottom-header { font-size: 48px; }
    p.casestudies-hero-section-paragraph { font-size: 24px; max-width: 700px; }
    .casestudies-video-iframe, .casestudies-video { height: 100%; min-height: 350px; }
}

@media (max-width: 768px) {
    .casestudies-hero-section { --dm-hero-offset: 150px; padding: calc(var(--dm-nav-height) + var(--dm-hero-offset)) 30px 30px 30px; height: auto; min-height: 400px; }
    h1.casestudies-hero-section-bottom-header { font-size: 36px; margin: 20px 0; }
    p.casestudies-hero-section-paragraph { font-size: 18px; max-width: 100%; padding: 10px 0; }
    .casestudies-hero-section-button-group { flex-direction: column; gap: 15px; padding: 30px 0; }
    .casestudies-hero-section-button { width: 100%; max-width: 250px; text-align: start; }
    .casestudies-video-iframe, .casestudies-video { height: 100%; min-height: 220px; }
}

@media (max-width: 480px) {
    .casestudies-hero-section { --dm-hero-offset: 120px; padding: calc(var(--dm-nav-height) + var(--dm-hero-offset)) 20px 60px 20px; }
    h1.casestudies-hero-section-bottom-header { font-size: 28px; margin: 15px 0; }
    p.casestudies-hero-section-paragraph { font-size: 16px; padding: 8px 0; }
    .casestudies-video-iframe, .casestudies-video { height: 100%; min-height: 160px; }
}


.dm-casestudies-list-container{
    width: 100%;
    margin: 0 auto;
    max-width: 1800px;
}

.dm-casestudies-list-container-inner{

    width: 100%;
    padding: 75px 75px;
    margin: 0 auto;

}

.dm-casestudies-list{
    width: 100%;
    margin: 0 auto;
    justify-content: center;
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    grid-auto-flow: dense;
}

.dm-casestudies-card{
    width: 100%;
    height: 400px;
    /* background-color: #F5F8FE; */
    /* border: 2px solid #E2E8F0; */
    /* border-radius: 12px; */
    overflow: hidden;
    position: relative;
    display: block;
    transition: box-shadow 0.2s ease-in-out;
}

.dm-casestudies-card-inner{
    width: 100%;
    height: 350px;
    background-color: #F5F8FE;
    border: 2px solid #E2E8F0; 
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    display: block;
}

.dm-casestudies-card-title{
    width: 100%;
    justify-content: space-between;
    align-items: center;
    align-content: center;
    display: flex;
    padding: 5px 5px;
}

.dm-casestudies-card-title h5{
    margin-bottom: 0px
}


.dm-casestudies-card img{
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* object-position: top; */
    display: block;
    transition: transform 0.3s ease;
}


.dm-casestudies-card-inner-link{
    position: absolute;
    /* bottom: 2%; */
    width: 90%;
    bottom: 5%;
    margin: 0 auto;
    left: 50%;
    transform: translateX(-50%);
}

.dm-casestudies-card-inner-link-container{
    display: flex;
    align-items: center;
    border-radius: 12px;
    padding: 15px 15px;
    justify-content: space-between;
    transition-duration: 0.3s;
    transition-timing-function: ease-in-out;
    transform: translateY(150%);
    background-color: #fff;
}

.dm-casestudies-card:hover .dm-casestudies-card-inner-link-container{
    transform: translateY(0%);
    transition-duration: 0.4s;
    transition-timing-function: ease-in-out;
}

.dm-casestudies-card-inner-link-container p{
    margin-bottom: 0px;
    color: #53A2E8;
}


.dm-casestudies-card-inner-link-container i{
    margin-bottom: 0px;
    color: #53A2E8;
}

.dm-casestudies-card-title svg{
    color: #53A2E8;
    font-size: 10px;
    height: 20px;
}

.dm-casestudies-card-title > div{
    display: flex;
    align-items: center;
}



.dm-casestudies-card:hover img{
    transform: scale(1.05);
}

/* Responsive grid: 1 -> 2 -> 3 -> 4 columns */
@media (min-width: 768px){
    .dm-casestudies-list{grid-template-columns: repeat(2, 1fr)}
}
@media (min-width: 1024px){
    .dm-casestudies-list{grid-template-columns: repeat(3, 1fr)}
}
@media (min-width: 1280px){
    .dm-casestudies-list{grid-template-columns: repeat(4, 1fr)}
}

/* Parallax Case Studies - Full Width Cards */
.dm-casestudies-parallax-fullwidth{
    width: 100%;
    margin: 0;
    padding: 40px 0;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.dm-parallax-full-card{
    display: block;
    width: 100%;
    min-height: 60vh;
    position: relative;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed; /* simple parallax */
}

.dm-parallax-full-overlay{
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.55) 100%);
    display: flex;
    align-items: end;
    justify-content: center;
    padding: 32px;
}

.dm-parallax-full-title{
    font-family: "Poppins", sans-serif;
    font-weight: 600;
    font-size: 32px;
    color: #F5FCFF;
    margin: 0;
    text-align: center;
}

@media (max-width: 768px){
    .dm-parallax-full-card{ min-height: 45vh; }
    .dm-parallax-full-title{ font-size: 24px; }
}







/* SERVICES ABOUT SECTION */
.every-business-section {
    background-color: #ffffff;
    /* padding: 80px 75px; */
    width: 100%;
}

.every-business-container {
    max-width: 1600px;
    padding: 75px 75px;
    margin: 0 auto;
    width: 100%;
}

.every-business-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    /* make each column match height so the image can fill its cell */
    grid-auto-rows: 1fr;
}

.every-business-image-wrapper {
    width: 100%;
    overflow: hidden;
    border-radius: 16px 16px 0 0;
    /* ensure image fills the column height in two-column layout */
    height: 100%;
}

.every-business-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.every-business-content {
    display: flex;
    flex-direction: column;
    gap: 24px;

    /* keep content vertically centered beside the image */
    justify-content: center;
}

.every-business-headline {
    font-family: "Poppins", sans-serif;
    font-weight: 600;
    font-size: 48px;
    line-height: 1.2;
    color: #000;
    margin: 0;
}

.every-business-text {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.every-business-text p {
    font-family: "DM Sans", sans-serif;
    font-size: 18px;
    font-weight: 400;
    line-height: 1.6;
    color: #374754;
    margin: 0;
}

/* Responsive Design for Services About Section */

@media (max-width: 1500px) {
		h1.casestudies-hero-section-bottom-header {
		font-size: 56px;
	}

}

@media (max-width: 1200px) {
		h1.casestudies-hero-section-bottom-header {
		font-size: 48;
	}

}


@media (max-width: 480px) {
		h1.casestudies-hero-section-bottom-header {
		font-size: 28px;
	}

}

@media (max-width: 1200px) {
    .every-business-section {
        padding: 60px 50px;
    }
    
    .every-business-grid {
        gap: 40px;
    }
    
    .every-business-headline {
        font-size: 40px;
    }
    
    .every-business-text p {
        font-size: 17px;
    }
}

@media (max-width: 768px) {

    /* .dm-casestudies-list-container-inner{

        padding: 30px 20px;
    } */

    .every-business-section {
        padding: 50px 30px;
    }

    /* container padding tuned for tablets and small desktops */
    .every-business-container {
        max-width: 1200px;
        padding: 0 20px;
        margin: 0 auto;
        width: 100%;
        box-sizing: border-box;
    }

    /* stack to single column and reduce gaps */
    .every-business-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        align-items: start;
    }

    .every-business-image-wrapper {
        border-radius: 12px 12px 0 0;
        height: auto; /* allow natural height when stacked */
    }

    /* image should scale but not overflow on tablets */
    .every-business-image {
        width: 100%;
        height: auto;
        max-height: 500px;
        display: block;
        object-fit: cover;
    }

    /* remove heavy internal padding on small screens and keep content near image */
    .every-business-content {
        padding: 0 10px;
        gap: 16px;
        justify-content: flex-start;
    }

    .every-business-headline {
        font-size: 32px;
    }

    .every-business-text {
        gap: 14px;
    }

    .every-business-text p {
        font-size: 16px;
    }
}

@media (max-width: 480px) {

    .dm-casestudies-list-container-inner{
        padding: 20px 15px;
    }


    .every-business-section {
        padding: 30px 15px;
    }
    
    .every-business-grid {
        gap: 24px;
    }
    
    .every-business-headline {
        font-size: 28px;
    }
    
    .every-business-image {
        max-height: 360px;
    }

    .every-business-text p {
        font-size: 15px;
        line-height: 1.5;
    }
}





/* TESTIMONIALS SECTION – FINAL VERSION */
.old-casestudies-testimonial-videos-section {
  margin-top: 3rem;
  padding: 0 1.5rem;
}

.old-casestudies-testimonial-videos-container {
  max-width: 1600px;
  margin: 0 auto;
}



.old-casestudies-testimonial-videos-section .video-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}



.old-casestudies-testimonial-videos-section .video-section > .video-container:nth-child(5) {
  grid-column: 1 / -1;          
  max-width: 100%;
  margin: 0 auto;
}



.old-casestudies-testimonial-videos-section .video-wrapper {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 177.78%;      
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
}



.old-casestudies-testimonial-videos-section .video-section > .video-container:nth-child(5) .video-wrapper {
  padding-bottom: 56.25%;     
}


.old-casestudies-testimonial-videos-video {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}


.old-casestudies-testimonial-videos-section .video-container:hover .play-button {
  transform: scale(1.15);
}



@media (max-width: 640px) {
 
.old-casestudies-testimonial-videos-section .video-section {
    gap: 1rem;
    margin-bottom: 2rem;
  }
 
.old-casestudies-testimonial-videos-section .play-button {
    width: 64px;
    height: 64px;
  }
  .old-casestudies-testimonial-videos-section {
    padding: 0 1rem;
  }
}