/* =========================================================
   KATIE'S ELITE CLEANING – GALLERY PAGE
   Matches the HTML structure provided
========================================================= */


/* =========================================================
   GLOBAL CONTAINER
========================================================= */

.kec-gallery-container {
    width: min(1200px, calc(100% - 48px));
    margin: 0 auto;
}


/* =========================================================
   COMMON KICKER
========================================================= */

.kec-gallery-kicker {
    display: inline-block;
    margin-bottom: 14px;

    font-size: 12px;
    font-weight: 800;
    letter-spacing: 3px;
    line-height: 1.2;

    color: #d9232e;
}


/* =========================================================
   PAGE INTRO
========================================================= */

.kec-gallery-intro {
    padding: 90px 0 80px;
    background: #f4f5f7;
}

.kec-gallery-heading {
    max-width: 760px;
}

.kec-gallery-heading h1 {
    margin: 0 0 24px;

    font-size: clamp(48px, 6vw, 76px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -1.5px;

    color: #fff;
}

.kec-gallery-heading p {
    max-width: 720px;
    margin: 0;

    font-size: 18px;
    line-height: 1.8;

    color: #C5C9D1;
}


/* =========================================================
   PHOTO GALLERY
========================================================= */

.kec-photo-gallery {
    padding: 100px 0;
    background: #ffffff;
}

.kec-section-heading {
    margin-bottom: 50px;
}

.kec-section-heading h2 {
    margin: 0;

    font-size: clamp(36px, 4vw, 58px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1px;

    color: #20354d;
}

.kec-section-heading h2 span {
    color: #d9232e;
}

.kec-section-heading p {
    max-width: 650px;
    margin: 22px 0 0;

    font-size: 17px;
    line-height: 1.8;

    color: #59697a;
}


/* =========================================================
   PHOTO GRID
========================================================= */

.kec-photo-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.kec-photo-item {
    margin: 0;
    overflow: hidden;

    background: #edf0f3;
}

.kec-photo-link {
    display: block;

    width: 100%;
    height: 100%;

    overflow: hidden;
}

.kec-photo-link img {
    display: block;

    width: 100%;
    aspect-ratio: 4 / 3;

    object-fit: cover;

    transition:
        transform 0.45s ease,
        filter 0.45s ease;
}

.kec-photo-link:hover img {
    transform: scale(1.05);
    filter: brightness(0.95);
}


/* =========================================================
   BEFORE & AFTER
========================================================= */

.kec-before-after {
    padding: 100px 0;

    background: #eef1f4;
}

.kec-before-after-content {
    display: grid;

    grid-template-columns: 1fr 1.2fr;
    gap: 70px;

    align-items: center;
}

.kec-before-after-heading h2 {
    margin: 0 0 24px;

    font-size: clamp(38px, 4vw, 58px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1px;

    color: #20354d;
}

.kec-before-after-heading h2 span {
    color: #d9232e;
}

.kec-before-after-heading p {
    max-width: 520px;
    margin: 0;

    font-size: 17px;
    line-height: 1.8;

    color: #59697a;
}


/* =========================================================
   BEFORE / AFTER IMAGE
========================================================= */

.kec-before-after-image {
    width: 100%;
}

.kec-comparison-wrapper {
    position: relative;

    overflow: hidden;

    background: #dfe4e9;
}

.kec-comparison-wrapper img {
    display: block;

    width: 100%;
    aspect-ratio: 16 / 10;

    object-fit: cover;
}


/* =========================================================
   BEFORE / AFTER LABELS
========================================================= */

.kec-before-label,
.kec-after-label {
    position: absolute;
    bottom: 20px;

    padding: 10px 16px;

    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;

    color: #ffffff;
    background: #20354d;
}

.kec-before-label {
    left: 20px;
}

.kec-after-label {
    right: 20px;

    background: #d9232e;
}


/* =========================================================
   VIDEO SECTION
========================================================= */

.kec-video-gallery {
    padding: 100px 0;

    background: #ffffff;
}

.kec-section-heading-center {
    max-width: 760px;
    margin-right: auto;
    margin-bottom: 55px;
    margin-left: auto;

    text-align: center;
}

.kec-section-heading-center p {
    margin-right: auto;
    margin-left: auto;
}


/* =========================================================
   VIDEO GRID
========================================================= */

.kec-video-grid {
    display: grid;

    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
}

.kec-video-item {
    overflow: hidden;

    background: #20354d;
}

.kec-video-wrapper {
    position: relative;

    width: 100%;
    aspect-ratio: 16 / 9;
}

.kec-video-wrapper iframe {
    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 100%;

    border: 0;
}


/* =========================================================
   CALL TO ACTION
========================================================= */

.kec-gallery-cta {
    padding: 75px 0;

    background: #2d425c;
    border-top: 4px solid #d9232e;
}

.kec-gallery-cta-content {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 60px;
}

.kec-gallery-cta-text {
    max-width: 720px;
}

.kec-gallery-cta-text .kec-gallery-kicker {
    color: #ffffff;
}

.kec-gallery-cta-text h2 {
    margin: 0 0 20px;

    font-size: clamp(38px, 4vw, 58px);
    font-weight: 800;
    line-height: 1.1;

    color: #ffffff;
}

.kec-gallery-cta-text h2 span {
    color: #dfe7ef;
}

.kec-gallery-cta-text p {
    margin: 0;

    font-size: 17px;
    line-height: 1.8;

    color: #d9e1e9;
}


/* =========================================================
   CTA BUTTON
========================================================= */

.kec-gallery-button {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    gap: 12px;

    min-width: 190px;

    padding: 17px 26px;

    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1.5px;

    text-decoration: none;

    color: #ffffff;
    background: #d9232e;

    transition:
        background 0.25s ease,
        transform 0.25s ease;
}

.kec-gallery-button:hover {
    background: #b91923;
    transform: translateY(-2px);
}

.kec-gallery-button span {
    font-size: 18px;
    line-height: 1;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 900px) {

    .kec-gallery-intro,
    .kec-photo-gallery,
    .kec-before-after,
    .kec-video-gallery {
        padding: 75px 0;
    }

    .kec-photo-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .kec-before-after-content {
        grid-template-columns: 1fr;
        gap: 45px;
    }

    .kec-video-grid {
        grid-template-columns: 1fr;
    }

    .kec-gallery-cta-content {
        flex-direction: column;

        align-items: flex-start;
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 600px) {

    .kec-gallery-container {
        width: min(100% - 32px, 1200px);
    }

    .kec-gallery-intro,
    .kec-photo-gallery,
    .kec-before-after,
    .kec-video-gallery {
        padding: 60px 0;
    }

    .kec-gallery-cta {
        padding: 60px 0;
    }

    .kec-gallery-heading h1 {
        font-size: 46px;
    }

    .kec-gallery-heading p,
    .kec-section-heading p,
    .kec-before-after-heading p,
    .kec-gallery-cta-text p {
        font-size: 16px;
    }

    .kec-photo-grid {
        grid-template-columns: 1fr;

        gap: 16px;
    }

    .kec-section-heading {
        margin-bottom: 35px;
    }

    .kec-before-label,
    .kec-after-label {
        bottom: 12px;

        padding: 8px 12px;

        font-size: 10px;
    }

    .kec-before-label {
        left: 12px;
    }

    .kec-after-label {
        right: 12px;
    }

    .kec-gallery-cta-content {
        gap: 35px;
    }

    .kec-gallery-button {
        width: 100%;
    }

}


/* =========================================================
   KATIE'S ELITE CLEANING GALLERY LIGHTBOX
========================================================= */

.kec-lightbox {
    position: fixed;

    top: 0;
    left: 0;

    width: 100%;
    height: 100%;

    display: none;

    align-items: center;
    justify-content: center;

    padding: 60px 90px;

    background: rgba(15, 25, 38, 0.94);

    z-index: 99999;
}

.kec-lightbox.is-active {
    display: flex;
}


/* =========================================================
   LIGHTBOX IMAGE
========================================================= */

.kec-lightbox-content {
    position: relative;

    display: flex;

    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100%;
}

.kec-lightbox-content img {
    display: block;

    max-width: 100%;
    max-height: 100%;

    width: auto;
    height: auto;

    object-fit: contain;

    box-shadow: 0 20px 70px rgba(0, 0, 0, 0.5);
}


/* =========================================================
   CLOSE BUTTON
========================================================= */

.kec-lightbox-close {
    position: absolute;

    top: 25px;
    right: 30px;

    width: 48px;
    height: 48px;

    border: 0;

    font-size: 42px;
    line-height: 1;

    cursor: pointer;

    color: #ffffff;
    background: transparent;

    z-index: 2;

    transition: color 0.25s ease;
}

.kec-lightbox-close:hover {
    color: #d9232e;
}


/* =========================================================
   PREVIOUS / NEXT BUTTONS
========================================================= */

.kec-lightbox-prev,
.kec-lightbox-next {
    position: absolute;

    top: 50%;

    width: 55px;
    height: 70px;

    border: 0;

    display: flex;

    align-items: center;
    justify-content: center;

    font-size: 38px;

    cursor: pointer;

    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);

    transform: translateY(-50%);

    transition:
        background 0.25s ease,
        color 0.25s ease;
    z-index: 999;
}

.kec-lightbox-prev {
    left: 20px;
}

.kec-lightbox-next {
    right: 20px;
}

.kec-lightbox-prev:hover,
.kec-lightbox-next:hover {
    color: #ffffff;
    background: #d9232e;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 700px) {

    .kec-lightbox {
        padding: 70px 20px;
    }

    .kec-lightbox-prev,
    .kec-lightbox-next {
        width: 42px;
        height: 55px;

        font-size: 28px;

        color: #ffffff;
        background: #d9232e;
    }

    .kec-lightbox-prev {
        left: 5px;
    }

    .kec-lightbox-next {
        right: 5px;
    }

    .kec-lightbox-close {
        top: 15px;
        right: 15px;

        font-size: 36px;
    }

}



/* =========================================================
   KATIE'S GALLERY - OUR WORK CAROUSEL
========================================================= */

.kec-photo-carousel {
    position: relative;
    display: flex;
    align-items: center;
    gap: 18px;
    width: 100%;
}


/* VIEWPORT */

.kec-photo-viewport {
    width: 100%;
    overflow: hidden;
}


/* SLIDING TRACK */

.kec-photo-gallery .kec-photo-grid {
    display: flex;
    gap: 20px;

    width: max-content;

    transition: transform 0.5s ease;
}


/* EACH IMAGE */

.kec-photo-gallery .kec-photo-item {
    flex: 0 0 calc((100vw - 260px) / 3);

    max-width: 350px;

    margin: 0;
    overflow: hidden;
}


.kec-photo-gallery .kec-photo-link {
    display: block;
    width: 100%;
}


.kec-photo-gallery .kec-photo-item img {
    display: block;

    width: 100%;
    height: 320px;

    object-fit: cover;

    transition: transform 0.4s ease;
}


.kec-photo-gallery .kec-photo-item:hover img {
    transform: scale(1.04);
}


/* ARROWS */

.kec-carousel-btn {
    flex: 0 0 58px;

    width: 58px;
    height: 58px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: none;
    border-radius: 14px;

    background: #ffffff;

    color: #20344d;

    cursor: pointer;

    box-shadow:
        0 8px 22px rgba(32, 52, 77, 0.10),
        0 2px 6px rgba(32, 52, 77, 0.06);

    transition:
        transform 0.25s ease,
        background 0.25s ease,
        color 0.25s ease,
        box-shadow 0.25s ease;
}


.kec-carousel-btn:hover {
    background: #d9272e;
    color: #ffffff;

    transform: translateY(-3px);

    box-shadow:
        0 14px 28px rgba(217, 39, 46, 0.20),
        0 4px 10px rgba(32, 52, 77, 0.10);
}

.kec-carousel-prev {
    z-index: 20;
}

.kec-carousel-prev:hover i {
    transform: translateX(-3px);
}

.kec-carousel-next:hover i {
    transform: translateX(3px);
}


/* ARROW */

.kec-carousel-btn i {
    font-size: 18px;
    transition: transform 0.25s ease;
}


/* TABLET */

@media (max-width: 900px) {

    .kec-photo-gallery .kec-photo-item {
        flex-basis: calc((100vw - 180px) / 2);
    }

}


/* MOBILE */

@media (max-width: 600px) {

    .kec-photo-carousel {
        gap: 10px;
    }


    .kec-carousel-btn {
        flex: 0 0 52px;

        width: 52px;
        height: 52px;

        border-radius: 13px;
    }


    .kec-photo-gallery .kec-photo-item {
        flex-basis: calc(100vw - 110px);
    }


    .kec-photo-gallery .kec-photo-item img {
        height: 300px;
    }

}


/* =========================================================
   VIDEO CAROUSEL
========================================================= */

.kec-video-carousel {
    position: relative;

    display: flex;
    align-items: center;

    gap: 24px;

    width: 100%;
}


/* VIEWPORT */

.kec-video-viewport {
    width: 100%;

    overflow: hidden;
}


/* VIDEO TRACK */

.kec-video-gallery .kec-video-grid {
    display: flex;

    gap: 24px;

    width: max-content;

    transition: transform 0.5s ease;
}


/* VIDEO SLIDE */

.kec-video-gallery .kec-video-item {
    flex: 0 0 calc((100vw - 260px) / 2);

    max-width: 600px;

    margin: 0;
}


/* VIDEO */

.kec-video-wrapper {
    position: relative;

    width: 100%;

    aspect-ratio: 16 / 9;

    overflow: hidden;

    border-radius: 8px;

    background: #0b0b0b;
}


.kec-video-wrapper iframe {
    position: absolute;

    inset: 0;

    width: 100%;
    height: 100%;

    border: 0;
}


/* =========================================================
   VIDEO NAVIGATION BUTTONS
========================================================= */

.kec-video-carousel-btn {
    flex: 0 0 58px;

    width: 58px;
    height: 58px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: none;
    border-radius: 14px;

    background: #ffffff;

    color: #20344d;

    cursor: pointer;

    box-shadow:
        0 8px 22px rgba(32, 52, 77, 0.10),
        0 2px 6px rgba(32, 52, 77, 0.06);

    transition:
        transform 0.25s ease,
        background 0.25s ease,
        color 0.25s ease,
        box-shadow 0.25s ease;
}


.kec-video-carousel-btn i {
    font-size: 18px;

    transition: transform 0.25s ease;
}


.kec-video-carousel-btn:hover {
    background: #d9272e;

    color: #ffffff;

    transform: translateY(-3px);

    box-shadow:
        0 14px 28px rgba(217, 39, 46, 0.20),
        0 4px 10px rgba(32, 52, 77, 0.10);
}


.kec-video-carousel-prev:hover i {
    transform: translateX(-3px);
}


.kec-video-carousel-next:hover i {
    transform: translateX(3px);
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 900px) {

    .kec-video-carousel {
        gap: 16px;
    }

    .kec-video-gallery .kec-video-item {
        flex-basis: calc(100vw - 180px);
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 600px) {

    .kec-video-carousel {
        gap: 10px;
    }

    .kec-video-carousel-btn {
        flex: 0 0 52px;

        width: 52px;
        height: 52px;

        border-radius: 13px;
    }

    .kec-video-gallery .kec-video-item {
        flex-basis: calc(100vw - 120px);
    }

}