/* 
 Theme Name:   Kadence child
 Theme URI:    https://1248201.us8.myftpupload.com/
 Description:  This is Child Theme Description.
 Author:       Stefano
 Author URI:   https://1248201.us8.myftpupload.com/
 Template:     kadence
 Version:      1.4.4
Text Domain: kadence
 License:      GNU General Public License v2 or later
 License URI:  http://www.gnu.org/licenses/gpl-2.0.html

 /* == Add your own styles below this line ==
--------------------------------------------*/

/* Global CSS Elementor and Contact Form 7 */
.single-content h1.elementor-heading-title, .single-content h2.elementor-heading-title, .single-content h3.elementor-heading-title, .single-content h4.elementor-heading-title, .single-content h5.elementor-heading-title, .single-content h6.elementor-heading-title {
    margin: inherit;
}

/* Global CSS End */

.case-study-section {
    padding: 100px 20px;
}

/* Tablet CSS  */
@media (max-width: 1024px){
    .case-study-section {
    padding: 60px 20px;
}
}

.case-study-container {
    max-width: 1250px;
    margin: auto;
}
/* Common CSS end */


.case-study-hero {
    position: relative;
    min-height: 390px;
    width: 100%;
    overflow: hidden;
    background-size: cover;
    background-position: center center;
}

/* Purple overlay */
.case-study-hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;

    background:
        linear-gradient(
            90deg,
            rgba(35, 29, 91, 0.96) 0%,
            rgba(45, 37, 105, 0.91) 45%,
            rgba(35, 29, 91, 0.72) 100%
        );
}

/* Container */
.case-study-hero__container {
    position: relative;
    z-index: 2;
    min-height: 390px;
    padding: 100px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* =========================================
   BREADCRUMB
========================================= */

.case-study-hero__breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.58);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.case-study-hero__line {
    width: 27px;
    height: 2px;

    display: inline-block;

    background: rgba(255, 255, 255, 0.5);
}

.case-study-hero__slash {
    color: #d9a967;
    font-size: 15px;
}

.case-study-hero__category {
    color: #d9a967;
}

/* =========================================
   TITLE
========================================= */

.case-study-hero__title {
    max-width: 760px;
    margin: 23px 0 0;
    color: #d5a16b;
    font-size: 62px;
    line-height: 1.1;
    font-weight: 600;
    text-transform: uppercase;
}

.case-study-hero__title span {
    display: block;
}

.case-study-hero__title-white {
    color: #ffffff;
}

/* =========================================
   DETAILS
========================================= */

.case-study-hero__details {
    display: flex;
    align-items: stretch;
    gap: 12px;
    margin-top: 38px;
	flex-wrap: wrap;
}

.case-study-hero__detail {
    padding: 15px;
    display: flex;
    align-items: center;
	flex-wrap: wrap;
    gap: 4px;
    border: 1px solid #c79b5d;
    color: #ffffff;
    font-size: 12px;
    line-height: 1.4;
    font-weight: 700;
    letter-spacing: 0.7px;
    text-transform: uppercase;
    background: rgba(35, 29, 91, 0.12);
    border-radius: 3px;
}

.case-study-hero__detail span {
    color: #d5a16b;
    font-weight: 800;
}

.case-study-hero__detail strong {
    color: #ffffffe6;
    font-weight: 600;
}

/* =========================================
   TABLET
========================================= */

@media (max-width: 900px) {
 
    .case-study-hero__title {
        font-size: 44px;
    }

    .case-study-hero__details {
        flex-wrap: wrap;
    }

}

/* =========================================
   MOBILE
========================================= */

@media (max-width: 767px) {

    .case-study-hero__container {
        max-width: 100%;
        padding: 60px 20px;
    }

    .case-study-hero__breadcrumb {
        font-size: 12px;
        gap: 7px;
    }

    .case-study-hero__line {
        width: 22px;
    }

    .case-study-hero__title {
        margin-top: 25px;
        font-size: 30px;
    }

    .case-study-hero__details {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin-top: 32px;
    }

   .case-study-hero__detail {
		width: 100%;
		min-width: 0;
		padding: 12px;
	}
}

/* =========================================
   SMALL MOBILE
========================================= */

@media (max-width: 380px) {

    .case-study-hero__details {
        grid-template-columns: 1fr;
    }

}


/* =========================================================
   CONTAINER (10-Column Grid System)
========================================================= */

.case-study-gallery__container {
    width: min(100% - 40px, 1250px);
    margin: 0 auto;
    display: grid;
    /* Divide the grid into 10 parts to easily achieve 70/30 and 50/50 splits */
    grid-template-columns: repeat(10, 1fr);
    grid-auto-rows: 150px; /* Base height for grid rows */
    gap: 15px;
}


/* ---------------------------------------------------------
   GALLERY ITEMS (Base Styling)
--------------------------------------------------------- */

.gallery-item {
    padding: 8px;
    border: 1px solid #e2e2e2;
    background: #ffffff;
    overflow: hidden;
}

.gallery-item img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* =========================================================
   DYNAMIC SIZING (Repeats exactly every 5 images)
========================================================= */

/* 1st image in every cycle (1, 6, 11...): 70% width, spans 4 rows */
.gallery-item:nth-child(5n + 1) {
    grid-column: span 7;
    grid-row: span 4;
}

/* 2nd & 3rd images in every cycle (2, 3, 7, 8...): 30% width, span 2 rows */
.gallery-item:nth-child(5n + 2),
.gallery-item:nth-child(5n + 3) {
    grid-column: span 3;
    grid-row: span 2;
}

/* 4th & 5th images in every cycle (4, 5, 9, 10...): 50% width, span 2 rows */
.gallery-item:nth-child(5n + 4),
.gallery-item:nth-child(5n + 5) {
    grid-column: span 5;
    grid-row: span 2; 
}


/* =========================================================
   RESPONSIVE QUERIES
========================================================= */

/* Tablet: Switch to a 2-column grid, but maintain the repeating cycle */
@media (max-width: 991px) {
    .case-study-gallery__container {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: minmax(200px, auto);
    }

    /* 1st image in each cycle becomes full width (100%) */
    .gallery-item:nth-child(5n + 1) {
        grid-column: span 2;
        grid-row: span 2;
    }

    /* Images 2, 3, 4, and 5 in the cycle drop below in a 50/50 grid */
    /* Targeting them directly avoids specificity issues */
    .gallery-item:nth-child(5n + 2),
    .gallery-item:nth-child(5n + 3),
    .gallery-item:nth-child(5n + 4),
    .gallery-item:nth-child(5n + 5) {
        grid-column: span 1;
        grid-row: span 1;
    }
}

/* Mobile: Stack everything in a single column */
@media (max-width: 575px) {
    .case-study-gallery__container {
        grid-template-columns: 1fr;
        grid-auto-rows: auto;
    }

    /* Using :nth-child(n) perfectly matches desktop specificity without needing !important */
    .gallery-item:nth-child(n) {
        grid-column: span 1;
        grid-row: span 1;
        aspect-ratio: 16 / 9; 
    }
}

/* =========================================================
   CHALLENGE / SOLUTION / RESULT
========================================================= */

.case-study-csr {
    width: 100%;
    background: #433b93;
    padding: 80px 20px;
}

.case-study-csr__container {
    max-width: 1250px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}


/* ---------------------------------------------------------
   CARD
--------------------------------------------------------- */

.case-study-csr__card {
    position: relative;
    min-height: 102px;
    padding: 24px;
    border: 1px solid #CC9F7A;
    background-color: #2E2A66CC;
}

.case-study-csr__card:first-child::before {
    content: "";
    position: absolute;
    left: -12px;
    bottom: -12px;
    width: 62px;
    height: 1px;
    background: #c9a15e;
}
.case-study-csr__card:first-child::after {
    content: "";
    position: absolute;
    left: -12px;
    bottom: -12px;
    width: 1px;
    height: 62px;
    background: #c9a15e;
}
.case-study-csr__card:last-child::before {
    content: "";
    position: absolute;
    right: -12px;
    top: -12px;
    width: 62px;
    height: 1px;
    background: #c9a15e;
}
.case-study-csr__card:last-child::after {
    content: "";
    position: absolute;
    right: -12px;
    top: -12px;
    width: 1px;
    height: 62px;
    background: #c9a15e;
}

/* ---------------------------------------------------------
   CARD TITLE
--------------------------------------------------------- */

.case-study-csr__title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
}

.case-study-csr__title-line {
    display: block;
    width: 36px;
    height: 2px;
    flex: 0 0 36px;
    background: #d2ad6d;
}

.case-study-csr__title h2 {
    margin-bottom: 5px;
    color: #d6a96a;
    font-size: 44px;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.3px;
}


/* ---------------------------------------------------------
   CARD CONTENT
--------------------------------------------------------- */
.case-study-csr__content {
    color: #FFFFFFCC;
}
.case-study-csr__content h1,
.case-study-csr__content h2,
.case-study-csr__content h3,
.case-study-csr__content h4,
.case-study-csr__content h5,
.case-study-csr__content h6 {
  color: #FFFFFF;
}


.case-study-csr__content p {
    color: #FFFFFFCC;
    font-size: 16px;
    line-height: 1.4;
    font-weight: 400;
}



/* =========================================================
   RESPONSIVE QUERIES
========================================================= */

/* Tablet & Smaller Desktop */
@media (max-width: 991px) {
    .case-study-csr {
        padding: 60px 20px;
    }
    
    .case-study-csr__container {
        /* Stack the cards vertically */
        grid-template-columns: 1fr;
        gap: 24px;
        max-width: 600px; /* Constrain width when stacked */
    }

    /* Adjust the corner accents to fit the vertical layout naturally */
    .case-study-csr__card:last-child::before,
    .case-study-csr__card:last-child::after {
        top: auto;
        bottom: -12px;
    }
}

/* Mobile */
@media (max-width: 767px) {
    .case-study-csr {
        padding: 40px 16px;
    }

    .case-study-csr__card {
        padding: 20px;
    }

    .case-study-csr__title h2 {
        font-size: 32px; /* Scale down heading */
    }

    .case-study-csr__title-line {
        width: 28px;
        flex: 0 0 28px;
    }
}

/* Capabilities Section */

section.case-study-capabilities.case-study-slider-section {
    padding: 100px 0;
}

.capabilities-container {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 0 20px;
    margin-bottom: -50px;
}

.capabilities-title-wrap {
    flex-basis: 600px;
}
h4.case-study-capabilities__subtitle {
    color: #CC9F7A;
    font-size: 16px;
    text-transform: uppercase;
    font-weight: 600;
}
h2.case-study-capabilities__title {
    font-size: 44px;
    text-transform: uppercase;
    line-height: 1.2;
    color: #2E2A66;
}
span.case-study-title-brown {
    color: #CC9F7A;
}
.case-study-capabilities__description {
    flex-basis: 350px;
    line-height: 1.4;
    color: #2E2A66CC;
    font-size: 16px;
}


/* =========================================================
   CASE STUDY CTA
========================================================= */

.case-study-cta {
    position: relative;
    width: 100%;
    min-height: 230px;
    overflow: hidden;
    background-size: cover;
    background-position: center center;
}

/* =========================================================
   DARK OVERLAY
========================================================= */

.case-study-cta__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: rgba(10, 13, 12, 0.65);
}


/* =========================================================
   CONTAINER
========================================================= */

.case-study-cta__container {
    position: relative;
    z-index: 2;
    max-width: 1250px;
    margin: auto;
    padding: 115px 20px;
}

/* TITLE */

.case-study-cta__title {
    margin: 0 0 32px;
    color: #ffffff;
    font-size: 44px;
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: -0.3px;
    text-transform: uppercase;
    max-width: 590px;
}

.case-study-cta__title span {
    color: #d4a366;
}


/* =========================================================
   BUTTONS
========================================================= */

.case-study-cta__buttons {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Common button */
.case-study-cta__button {
    min-height: 34px;
    padding: 16px 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    line-height: 1;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-decoration: none;
    text-transform: uppercase;
    transition: background-color 250ms ease,
        color 250ms ease,
        border-color 250ms ease,
        transform 250ms ease;
}


/* Primary button */
.case-study-cta__button--primary {
    color: #28245c;
    background: #ffffff;
    border: 1px solid #ffffff;
}


/* Outline button */
.case-study-cta__button--outline {
    color: #ffffff;
    background: transparent;
    border: 1px solid #d4a366;
}


/* =========================================================
   HOVER
========================================================= */

.case-study-cta__button:hover {
    transform: translateY(-2px);
}

.case-study-cta__button--primary:hover {
    color: #ffffff;
    background: #d4a366;
    border-color: #d4a366;
}

.case-study-cta__button--outline:hover {
    color: #28245c;
    background: #d4a366;
    border-color: #d4a366;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1024px) {

    .case-study-cta {
        min-height: 200px;
    }

    .case-study-cta__title {
        font-size: 36px;
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 767px) {

    .case-study-cta {
        min-height: 230px;
        background-position: center;
    }

    .case-study-cta__container {
        padding: 60px 20px;
    }

    .case-study-cta__title {
        max-width: 320px;
        margin-bottom: 20px;
        font-size: 30px;
        line-height: 1.05;
    }

    .case-study-cta__buttons {
        flex-wrap: wrap;
    }

    .case-study-cta__button {
        min-height: 38px;
        padding: 0 15px;
        font-size: 14px;
    }

}


/* =========================================================
   CASE STUDY SLIDER
========================================================= */

.case-study-swiper {
	width: 100%;
	overflow: hidden;
	cursor: grab;
	padding-top: 100px !important;
}



.case-study-swiper.swiper-grabbing {
	cursor: grabbing;
}

.case-study-swiper .swiper-wrapper {
	align-items: flex-start;
}

.case-study-swiper .swiper-slide {
	width: auto;
	opacity: 1;
}

.case-study-slide {
	width: 100%;
	overflow: hidden;
	background: #292264;
	transition: box-shadow 700ms ease;
}

/* =========================================================
   IMAGE
========================================================= */

.case-study-slide__image {
	width: 100%;
	height: 250px;
	overflow: hidden;
	position: relative;
	transition: height 700ms cubic-bezier(.22, .61, .36, 1);
	will-change: height;
}

.case-study-swiper .swiper-slide.is-big .case-study-slide__image {
	height: 220px;
}

.case-study-swiper .swiper-slide.is-small .case-study-slide__image {
	height: 250px;
}

.case-study-slide__image img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 900ms cubic-bezier(.22, .61, .36, 1);
}

/* =========================================================
   IMAGE HOVER
========================================================= */

.case-study-swiper .swiper-slide:hover
.case-study-slide__image img {
	transform: scale(1.05);
}

/* =========================================================
   CONTENT
========================================================= */

.case-study-slide__content {
	position: absolute;
	left: 25px;
	right: 25px;
	bottom: 25px;
	z-index: 2;
	color: #fff;
}

.case-study-slide__caption {
	margin: 0;
	color: #fff;
	font-size: 17px;
	line-height: 1.3;
	font-weight: 600;
}

/* =========================================================
   IMAGE OVERLAY
========================================================= */

.case-study-slide__image::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(
		180deg,
		rgba(24, 20, 65, 0) 60%,
		rgba(24, 20, 65, 0.75) 100%
	);
}

/* =========================================================
   NAVIGATION
========================================================= */

.case-study-slider__navigation {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    max-width: 1250px;
    margin: auto;
    position: absolute;
    z-index: 20;
    top: 0;
    width: 100%;
    left: 0;
    right: 0;
    padding: 0 20px;
}

.case-study-slider__navigation button {
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #2E2A66;
    background: transparent;
    color: #2E2A66;
    font-size: 18px;
    cursor: pointer;
    transition: transform 250ms ease,
		background 250ms ease;
}
.case-study-slider__navigation button svg {
    fill: #2E2A66;
}
.case-study-slider__navigation button:hover {
	background: transparent;
}
.case-study-slider__navigation button:focus {
	background: transparent;
}

.case-study-slider__navigation button.swiper-button-disabled {
	opacity: 0.4;
	cursor: not-allowed;
}

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 600px) {

	.case-study-slide__image {
		height: 220px;
	}

	.case-study-swiper .swiper-slide.is-big .case-study-slide__image {
		height: 250px;
	}

	.case-study-swiper .swiper-slide.is-small .case-study-slide__image {
		height: 220px;
	}

	.case-study-slide__content {
		left: 20px;
		right: 20px;
		bottom: 22px;
	}

	.case-study-slide__caption {
		font-size: 19px;
	}

}



