/* Slider CSS – Template 3 split hero (text left, image right) */

/* Slider colours – point these at --colour1 / --colour2 in core.css if you prefer */
:root {
    --slide-accent: #a8e81f;
    /* lime – from the X8 mockup */
    --slide-dark: #03080b;
    /* black – from the X8 mockup */
    --slide-line: rgba(255, 255, 255, 0.18);
}

/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */

#slide-container {
    display: grid;
    background-color: var(--slide-dark);
    overflow: hidden;
}

/* Slides stack in one cell so they can fade (slider.js) */
.slide {
    display: grid;
    grid-row: 1;
    grid-column: 1;
    width: 100%;
    max-width: 100vw;
    opacity: 1;
    transition: opacity ease .5s;
    z-index: 3;
}

.opacity-0 {
    opacity: 0 !important;
    z-index: 1;
}

/* - Images - */

.slide-img {
    display: grid;
    width: 100%;
    grid-column: 1;
}

/* Mobile: image at the top fading down into black, text overlapping the fade */
.slide-img-m {
    grid-row: 1;
    z-index: 1;
    height: 420px;
    object-fit: cover;
    object-position: center top;
}

.slide-img-d {
    display: none !important;
}

.slide-shade {
    display: grid;
    grid-row: 1;
    grid-column: 1;
    z-index: 2;
    background: linear-gradient(180deg, rgba(3, 8, 11, 0) 35%, rgba(3, 8, 11, 0.75) 70%, var(--slide-dark) 100%);
}

@media(min-width: 600px) {
    .slide-img-m {
        height: 520px;
    }
}

@media(min-width: 992px) {
    .slide-img-m {
        display: none !important;
    }

    /* Desktop: image fills the slide, anchored right so the machines never get cropped */
    .slide-img-d {
        display: grid !important;
        grid-row: 1;
        z-index: 1;
        height: 100%;
        min-height: 560px;
        object-fit: cover;
        object-position: right center;
    }

    .slide-shade {
        display: grid !important;
        grid-row: 1;
        grid-column: 1;
        z-index: 2;
        background: linear-gradient(90deg, var(--slide-dark) 0%, rgba(3, 8, 11, 0.92) 42%, rgba(3, 8, 11, 0) 70%);
    }
}

@media(min-width: 1200px) {
    .slide-img-d {
        min-height: 640px;
    }

    .slide-shade {
        background: linear-gradient(90deg, var(--slide-dark) 0%, rgba(3, 8, 11, 0.85) 35%, rgba(3, 8, 11, 0) 58%);
    }
}

/* - Text - */

.slide-txt {
    display: grid;
    grid-row: 2;
    grid-column: 1;
    z-index: 3;
    width: 90%;
    justify-self: center;
    margin-top: -140px;
    /* pulls the text up over the faded part of the image */
    padding: 0 0 48px;
}

@media(min-width: 600px) {
    .slide-txt {
        margin-top: -180px;
    }
}

@media(min-width: 768px) {
    .slide-txt {
        width: 750px;
    }
}

@media(min-width: 992px) {
    .slide-txt {
        grid-row: 1;
        align-self: center;
        width: 950px;
        margin-top: 0;
        padding: 64px 0;
    }
}

@media(min-width: 1200px) {
    .slide-txt {
        width: 1200px;
    }
}

.slide-inner {
    display: grid;
    grid-gap: 28px;
    justify-self: start;
    max-width: 640px;
}

@media(min-width: 992px) {
    .slide-inner {
        max-width: 440px;
    }
}

@media(min-width: 1200px) {
    .slide-inner {
        max-width: 580px;
        grid-gap: 32px;
    }
}

.slide-title {
    font-family: "soleil", sans-serif;
    font-weight: 700;
    font-style: normal;
    color: #fff;
    font-size: 32px;
    line-height: 1.1;
    letter-spacing: 0.5px;
    text-align: left;
    text-transform: uppercase;
}

.slide-title span {
    display: block;
    color: var(--slide-accent);
}

@media(min-width: 600px) {
    .slide-title {
        font-size: 40px;
    }
}

@media(min-width: 1200px) {
    .slide-title {
        font-size: 50px;
    }
}

.slide-intro {
    color: #fff;
    font-weight: 400;
    font-size: 17px;
    line-height: 1.55;
    text-align: left;
}

@media(min-width: 1200px) {
    .slide-intro {
        font-size: 19px;
    }
}

/* - Feature icons (4 across, 2x2 on small phones) - */

.slide-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-row-gap: 24px;
}

@media(min-width: 480px) {
    .slide-features {
        grid-template-columns: repeat(4, 1fr);
    }
}

.slide-feature {
    display: grid;
    grid-gap: 10px;
    justify-items: center;
    align-content: start;
    padding: 0 8px;
    border-left: 1px solid var(--slide-line);
}

.slide-feature:nth-child(odd) {
    border-left: none;
}

@media(min-width: 480px) {
    .slide-feature:nth-child(odd) {
        border-left: 1px solid var(--slide-line);
    }

    .slide-feature:first-child {
        border-left: none;
    }
}

.slide-feature i,
.slide-feature svg {
    font-size: 32px;
    color: var(--slide-accent);
}

.slide-feature p {
    color: #fff;
    font-size: 14px;
    line-height: 1.3;
    font-weight: 400;
    letter-spacing: 0.3px;
    text-align: center;
    justify-self: center;
}

/* - Button: uses .but2 from custom.css, recoloured to the X8 green & black - */

.slide-txt .but2 {
    background-color: var(--slide-accent);
    color: var(--slide-dark);
}

.slide-txt .but2:hover {
    background-color: #fff;
    color: var(--slide-dark);
}

.slide-txt .but2 i,
.slide-txt .but2 svg {
    margin-left: 10px;
    transition: transform 300ms cubic-bezier(.23, 1, 0.32, 1);
}

.slide-txt .but2:hover i,
.slide-txt .but2:hover svg {
    transform: translateX(4px);
}

/* - Arrows & dots (only used with more than one slide) - */

.slide-arrow {
    color: #fff;
    font-size: 32px;
    grid-row: 1;
    grid-column: 1;
    z-index: 6;
    align-self: center;
    margin: 32px;
    transition: opacity .5s ease;
}

.slide-arrow:hover {
    cursor: pointer;
    opacity: 0.5;
}

.slide-left {
    justify-self: start;
}

.slide-right {
    justify-self: end;
}

.slide-dots {
    display: grid;
    grid-gap: 8px;
    justify-content: center;
    justify-self: center;
    align-self: end;
    z-index: 6;
    grid-row: 1;
    grid-column: 1;
    margin-bottom: 24px;
}

.slide-dot {
    grid-row: 1;
    width: 8px;
    height: 8px;
    border-radius: 16px;
    border: #fff solid 1px;
    align-self: center;
}

.slide-dot:hover {
    cursor: pointer;
    border-color: var(--slide-accent);
}

.active-slide-dot {
    background-color: var(--slide-accent);
    border-color: var(--slide-accent);
}

/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
/* Feature strip under the slider */

#slide-strip {
    display: grid;
    background-color: var(--slide-dark);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.slide-strip-inner {
    display: grid;
    width: 90%;
    justify-self: center;
    padding: 12px 0;
}

@media(min-width: 768px) {
    .slide-strip-inner {
        width: 750px;
        grid-template-columns: repeat(3, 1fr);
        padding: 24px 0;
    }
}

@media(min-width: 992px) {
    .slide-strip-inner {
        width: 950px;
    }
}

@media(min-width: 1200px) {
    .slide-strip-inner {
        width: 1200px;
    }
}

.slide-strip-item {
    display: grid;
    grid-template-columns: max-content auto;
    grid-gap: 20px;
    align-items: start;
    justify-content: left;
    padding: 14px 0;
    border-top: 1px solid var(--slide-line);
}

.slide-strip-item:first-child {
    border-top: none;
}

@media(min-width: 768px) {
    .slide-strip-item {
        padding: 4px 16px;
        border-top: none;
        border-left: 1px solid var(--slide-line);
    }

    .slide-strip-item:first-child {
        border-left: none;
    }
}

.slide-strip-item i,
.slide-strip-item svg {
    font-size: 34px;
    color: var(--slide-accent);
}

.slide-strip-item p {
    color: #fff;
    font-size: 16px;
    font-weight: 400;
    margin: 0;
}
