:root {
    --bg: #111214;
    --panel: #121316;
    --text: #f4f4f4;
    --muted: rgba(255, 255, 255, 0.82);
    --line: rgba(255, 255, 255, 0.28);
    --line-active: #ffffff;
    --gap: clamp(1.5rem, 3vw, 3rem);
    --section-padding: clamp(1.25rem, 2.5vw, 2.25rem);


    --image-height: clamp(320px, 44vw, 660px);
    --content-width: 34%;
    --transition: 420ms ease;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
  /*  font-size: 16px;*/
}

body {
  /*  margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;

   */
}

.carousel img {
    display: block;
    width: 100%;
    height: 100%;
}

button {
    font: inherit;
}
/*
.hero-carousel {
    width: 100%;
    background: linear-gradient(90deg, #121316 0%, #111214 100%);
}

.carousel {
    max-width: 1600px;
    margin: 0 auto;
    padding: var(--section-padding);
}
*/

/**/

.hero-carousel {
    width: 100%;
    background: transparent;
 /*   background: linear-gradient(90deg, #121316 0%, #111214 100%);*/
}

.carousel {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}
/**/




.carousel__track {
    position: relative;
    overflow: hidden;
    /*min-height: calc(var(--image-height) + 3rem);*7

     */
    padding-bottom: 50px;
}

.slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, var(--content-width));
    gap: clamp(2rem, 4vw, 6rem);
    align-items: start;
    opacity: 0;
    visibility: hidden;
    transform: translateX(40px);
    /*
    transition:
            opacity var(--transition),
            transform var(--transition),
            visibility var(--transition);
    */
}

.slide.is-active {
    position: relative;
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
    z-index: 1;
}
/*
.slide__media {
    width: 100%;
    height: var(--image-height);
    overflow: hidden;
    background: #0d0e10;
}

.slide__media img {
    object-fit: cover;
}
*/

/**/
.slide__media {
    position: relative;
    width: 100%;
    /*aspect-ratio: 16 / 9;

     */
    aspect-ratio: 758 / 458;
    overflow: hidden;
    background: #0d0e10;
}

.slide__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
/**/

/**/

.slide {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 34%);
    gap: clamp(2rem, 4vw, 6rem);
    align-items: start;
}

.slide__media,
.slide__content {
    align-self: start;
}

/**/



/*
.slide__content {
    display: flex;
    min-height: var(--image-height);
}
*/

.slide__content {
    display: flex;
    align-self: stretch;
}

/*
.slide__text-wrap {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    width: 100%;
    padding-top: clamp(0.5rem, 1vw, 1rem);
}
*/

.slide__main {
    display: flex;
    flex-direction: column;
    gap: 1rem; /* säätää title-body välin */
}

.slide__text-wrap {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}



/**/
.slide {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 34%);
    gap: clamp(2rem, 4vw, 6rem);
    align-items: stretch;
}

.slide__content {
    display: flex;
    height: 100%;
}

.slide__text-wrap {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    height: 100%;
}
/**/

/*
.slide__title {
    margin: 0 0 2rem;
    max-width: 10ch;
    font-size: clamp(2rem, 4vw, 4rem);
    line-height: 0.95;
    font-weight: 500;
    letter-spacing: -0.04em;
}
*/
.slide__title {
    margin: 0 0 1.5rem;
    max-width: 12ch;

    font-size: clamp(24px, 3vw, 40px);
    line-height: 1.05;

    font-weight: 400;
    letter-spacing: -0.02em;
}
/*
.slide__body {
    max-width: 32rem;
    color: var(--muted);
    font-size: clamp(1rem, 1.05vw, 1.125rem);
    line-height: 1.6;
}
*/

.slide__body {
    max-width: 32rem;
  /*  color: var(--muted);*/

    font-size: 14px;
    line-height: 1.6;
}

.slide__body p {
    margin: 0 0 1.4rem;
}

.slide__body p:last-child {
    margin-bottom: 0;
}

.slide__counter {
    /*margin-top: auto;
    padding-top: 3rem;*/
    font-weight: 400;
    line-height: 1;
    letter-spacing: -0.04em;
}
/*
.slide__counter {
    margin-top: auto;
    padding-top: 2rem;
}
*/
.slide__counter {
    margin-top: 2rem;
    line-height: 1;
}
/*
.slide__current {
    font-size: clamp(2.75rem, 4vw, 4.75rem);
}

.slide__divider,
.slide__total {
    font-size: clamp(1.1rem, 1.8vw, 1.75rem);
}
*/

/**/
.slide__current {
    font-size: clamp(28px, 3vw, 48px);
    line-height: 1;
}

.slide__divider,
.slide__total {
    font-size: 16px;
    opacity: 0.8;
}
/**/


.carousel__footer {
    margin-top: clamp(1rem, 2vw, 2rem);
}

.carousel__progress {
    position: relative;
    width: 100%;
    height: 2px;
    background: var(--line);
    overflow: hidden;
}

.carousel__progress-fill {
    position: absolute;
    inset: 0 auto 0 0;
    width: 25%;
    height: 100%;
    background: var(--line-active);
    transition: width var(--transition);
}

.carousel__controls {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 1rem;
}

.carousel__button {
    appearance: none;
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: transparent;
    /*color: var(--text);*/
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition);
}

.carousel__button:hover,
.carousel__button:focus-visible {
    /*
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.5);
    outline: none;
    */
}





@media (max-width: 1100px) {
    .slide {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .slide__content {
        min-height: auto;
    }

    .slide__title {
        max-width: 100%;
    }

    .slide__counter {
        padding-top: 2rem;
        margin-top: 1rem;
    }
}

@media (max-width: 700px) {
    :root {
        --image-height: 260px;
    }

    .carousel {
        padding: 1rem;
    }

    .slide__title {
        margin-bottom: 1.25rem;
        font-size: clamp(1.8rem, 8vw, 2.8rem);
    }

    .slide__body {
        font-size: 1rem;
        line-height: 1.55;
    }

    .carousel__controls {
        justify-content: space-between;
    }

    .carousel__button {
        flex: 1 1 auto;
        text-align: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .slide,
    .carousel__progress-fill,
    .carousel__button {
        transition: none;
    }
}
/**/
/*
@media (min-width: 1101px) {
    .slide__content {
        align-items: stretch;
    }

    .slide__text-wrap {
        height: var(--image-height);
    }
}*/