/* ==========================================================================
   Klaviyo Email Marketing landing page (template-pages/new-klaviyo-email-marketing.php)
   Section-specific styles moved out of the template parts.
   Only rules that can't be expressed with Tailwind utilities live here.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Brands marquee (brands-section.php)
   -------------------------------------------------------------------------- */
.km-brands-section .km-brands-row {
    animation: km-brands-marquee-left 30s linear infinite;
}
.km-brands-section .km-brands-row--reverse {
    animation-name: km-brands-marquee-right;
    animation-duration: 35s;
}
.km-brands-section .km-brands-row--slow {
    animation-duration: 40s;
}
@media (min-width: 768px) {
    .km-brands-section .km-brands-row          { animation-duration: 60s; }
    .km-brands-section .km-brands-row--reverse { animation-duration: 70s; }
    .km-brands-section .km-brands-row--slow    { animation-duration: 80s; }
}
.km-brands-section .km-brands-marquee:hover .km-brands-row {
    animation-play-state: paused;
}
@keyframes km-brands-marquee-left  { from { transform: translateX(0); }   to { transform: translateX(-50%); } }
@keyframes km-brands-marquee-right { from { transform: translateX(-50%); } to { transform: translateX(0); } }
@media (prefers-reduced-motion: reduce) {
    .km-brands-section .km-brands-row { animation: none; }
}

/* --------------------------------------------------------------------------
   Services accordion (services-section.php)
   -------------------------------------------------------------------------- */
.services-accordion-section .accordion-arrow {
    transition: transform 0.3s ease;
}
.services-accordion-section .custom-accordion > li.active .accordion-arrow {
    transform: rotate(180deg);
}
@media (min-width: 768px) {
    /* Each <li> is a flex column so .card-inner stretches to fill the row height. */
    .services-accordion-section .custom-accordion > li {
        position: relative;
        display: flex;
        flex-direction: column;
    }
    /* card-inner fills the row height AND vertically centers its title so
       single-line titles sit at the same vertical position as multi-line ones. */
    .services-accordion-section .custom-accordion > li > .card-inner {
        flex: 1 1 auto;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    /* When the card is open the title goes to the top so the expanded
       content has room to slide down below it. */
    .services-accordion-section .custom-accordion > li.active > .card-inner {
        justify-content: flex-start;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        box-shadow: 0 18px 40px rgba(0, 0, 0, 0.08);
    }
    .services-accordion-section .custom-accordion > li.active {
        z-index: 20;
    }
}

/* --------------------------------------------------------------------------
   How We Work timeline (how-we-work-section.php)
   -------------------------------------------------------------------------- */
.how-we-work-section .timeline-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: 1fr auto 1fr;
    column-gap: 0;
    row-gap: 1.25rem;
    align-items: stretch;
}
.how-we-work-section .timeline-line {
    grid-column: 1 / -1;
    grid-row: 2;
    align-self: center;
    height: 1px;
    background: rgba(181, 248, 27, 0.4);
}
.how-we-work-section .timeline-step-above {
    grid-row: 1;
    overflow: visible;
}
.how-we-work-section .timeline-step-below {
    grid-row: 3;
    overflow: visible;
}
/* Let each text block extend into the empty alternate cell on either side */
.how-we-work-section .timeline-step-above .timeline-text,
.how-we-work-section .timeline-step-below .timeline-text {
    width: 160%;
    margin-left: -30%;
    padding-left: 1rem;
    padding-right: 1rem;
}
/* Edges: first/last steps can only extend inward */
.how-we-work-section .timeline-step-above[data-edge="left"] .timeline-text {
    margin-left: 0;
    width: 130%;
}
.how-we-work-section .timeline-step-above[data-edge="right"] .timeline-text {
    margin-left: -30%;
    width: 130%;
}
.how-we-work-section .timeline-circle {
    grid-row: 2;
    position: relative;
    z-index: 10;
    justify-self: center;
}

/* --------------------------------------------------------------------------
   More Client Love bento cards (more-client-love-section.php)
   -------------------------------------------------------------------------- */
.more-client-love-section .mcl-card {
    position: relative;
    border-radius: 1.5rem;
    overflow: hidden;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
@media (min-width: 768px) {
    .more-client-love-section .mcl-card {
        padding: 2.25rem;
    }
}
.more-client-love-section .mcl-card--light {
    background: #ffffff;
    color: #2d2d2d;
}
.more-client-love-section .mcl-card--patriot {
    background: linear-gradient(180deg, #2D3800 0%, #010101 83.83%);
    color: #ffffff;
}
.more-client-love-section .mcl-card--patriot .mcl-chart-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}
.more-client-love-section .mcl-card--patriot > * {
    position: relative;
    z-index: 1;
}
.more-client-love-section .mcl-card--patriot .mcl-stat {
    font-size: 3.5rem;
    line-height: 1;
    font-weight: 700;
}
.more-client-love-section .mcl-card--sixthreezero {
    background-color: #3d4800;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    color: #ffffff;
}
.more-client-love-section .mcl-card--sixthreezero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(139, 166, 0, 0.80) -0.05%, rgba(61, 72, 0, 0.80) 100%);
    z-index: 0;
}
.more-client-love-section .mcl-card--sixthreezero > * {
    position: relative;
    z-index: 1;
}
.more-client-love-section .mcl-card--reflectly {
    background: linear-gradient(135deg, #E6E0F8 0%, #D8D0F0 100%);
}
.more-client-love-section .mcl-card--reflectly-image {
    background-position: right top;
    background-repeat: no-repeat;
    background-size: cover;
}
.more-client-love-section .mcl-thyroid-img {
    background-position: left center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* --------------------------------------------------------------------------
   Why Work With Us (dark) testimonial sync slider (why-work-with-us-dark-section.php)
   -------------------------------------------------------------------------- */
.why-dark-testimonial-section .why-dark-text-slider .slick-list,
.why-dark-testimonial-section .why-dark-text-slider .slick-track {
    height: 100%;
}

/* --------------------------------------------------------------------------
   Success stories / case studies sync slider (success-story-section.php)
   -------------------------------------------------------------------------- */
/* Keep the side arrows from ever creating a horizontal scrollbar — they can be
   pushed outside the card via negative margins; clip anything past the section edge. */
.success-stories-section {
    overflow-x: clip;
}
.success-stories-section .success-stories-card {
    position: relative;
    border-radius: 1.5rem;
    background: #101400;
    overflow: hidden;
}
.success-stories-section .success-stories-inner {
    display: flex;
    flex-direction: column;
}
@media (min-width: 768px) {
    .success-stories-section .success-stories-inner {
        flex-direction: row;
        align-items: stretch;
        min-height: 24rem;
    }
    .success-stories-section .success-content-side {
        flex: 0 0 40%;
        max-width: 40%;
        padding: 2.5rem 2rem;
        display: flex;
        align-items: center;
        position: relative;
        z-index: 2;
        background: rgba(16, 20, 0, 0.72);
    }
    .success-stories-section .success-image-side {
        flex: 1 1 auto;
        position: relative;
        z-index: 1;
        padding: 2rem 5rem 2rem 1rem;
        min-width: 0;
    }
}
/* Text slider — keep all slides at the tallest height so the card doesn't jump. */
.success-stories-section .success-text-slider .slick-list,
.success-stories-section .success-text-slider .slick-track {
    height: 100%;
}
.success-stories-section .success-text-slider .slick-slide {
    height: auto;
}
.success-stories-section .success-text-slider .slick-slide > div {
    height: 100%;
}
.success-stories-section .success-text-slider .success-text-slide {
    height: 100%;
}
/* Image slider — active sharp, neighbours dim/blur. */
.success-stories-section .success-image-slider {
    width: 100%;
}
.success-stories-section .success-image-slider .slick-list {
    overflow: visible;
}
.success-stories-section .success-image-slider .slick-slide {
    opacity: 0.25;
    filter: blur(2px);
    transition: opacity 0.45s ease, filter 0.45s ease;
}
.success-stories-section .success-image-slider .slick-slide.slick-center,
.success-stories-section .success-image-slider .slick-slide.slick-current,
.success-stories-section .success-image-slider .slick-slide.slick-active.slick-current {
    opacity: 1;
    filter: none;
}
.success-stories-section .success-image-slider:not(.slick-initialized) .slick-slide {
    opacity: 1;
    filter: none;
}
.success-stories-section .success-image-slider .success-image-slide {
    padding: 0 1.25rem 0 1.5rem;
}
.success-stories-section .success-image-slider .success-image-slide figure {
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: #101400;
    margin: 0;
    border-radius: 1rem;
}
.success-stories-section .success-image-slider .success-image-slide img {
    width: 100%;
    height: 100%;
    object-position: center bottom;
    display: block;
}
/* Mobile (<md): vertical stack — text (centered), then image, then link, then arrows */
@media (max-width: 767px) {
    .success-stories-section .success-stories-inner {
        flex-direction: column;
    }
    .success-stories-section .success-content-side {
        padding: 2rem 1.5rem 1rem;
        color: #fff;
        text-align: center;
    }
    .success-stories-section .success-content-side .success-text-slide {
        text-align: center;
    }
    .success-stories-section .success-image-side {
        padding: 0.5rem 1rem 1.5rem;
    }
    .success-stories-section .success-image-slider .slick-slide {
        opacity: 0.4;
        filter: blur(1.5px);
    }
    .success-stories-section .success-image-slider .slick-slide.slick-current,
    .success-stories-section .success-image-slider .slick-slide.slick-active {
        opacity: 1;
        filter: none;
    }
    .success-stories-section .success-mobile-link {
        display: block;
        text-align: center;
        padding: 0 1.5rem 1rem;
    }
    .success-stories-section .success-mobile-arrows {
        display: flex !important;
        justify-content: center;
        gap: 4rem;
        padding-bottom: 1.5rem;
    }
}
@media (min-width: 768px) {
    .success-stories-section .success-mobile-link,
    .success-stories-section .success-mobile-arrows {
        display: none;
    }
}
