/* carousel */
.carousel {
    height: 100vh;
    margin: 0;
    overflow: hidden;
    position: relative;
    background-color: #e7e5dc;
}

.carousel-container {
    overflow: auto;
    position: relative;
}

.carousel .list .item {
    width: 100%;
    height: 100%;
    position: absolute;
    inset: 0 0 0 0;
}

.carousel .list .item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel .list .item .ayurveda-content {
    position: absolute;
    top: 40%;
    width: 1140px;
    max-width: 80%;
    left: 50%;
    transform: translateX(-50%);
    padding-right: 30%;
    box-sizing: border-box;
    color: #fff;
    text-shadow: 0 5px 10px #0004;
}

.carousel .list .item .author {
    font-weight: bold;
    letter-spacing: 10px;
}

.carousel .list .item .title,
.carousel .list .item .topic {
    font-size: 10em;
    font-weight: bold;
    line-height: 1.3em;
}

.carousel .list .item .buttons {
    display: grid;
    grid-template-columns: repeat(2, 130px);
    grid-template-rows: 40px;
    gap: 5px;
    margin-top: 20px;
}

.carousel .list .item .buttons button {
    border: none;
    /* background-color: #eee; */
    letter-spacing: 2px;
    font-family: monospace;
    font-weight: 400;
    border: 1px solid #f2f2f2;
    color: #f2f2f2;
    cursor: pointer;
    font-size: 1.5rem;
}

.carousel .list .item .buttons button:nth-child(2) {
    background-color: transparent;
    border: 1px solid #fff;
    color: #eee;
}

/* thumbail */
.thumbnail {
    position: absolute;
    float: inline-end;
    left: 56%;
    width: max-content;
    z-index: 1;
    display: flex;
    gap: 20px;
}

.thumbnail .item {
    width: 150px;
    height: 220px;
    flex-shrink: 0;
    position: relative;
}

.thumbnail .item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
}

.thumbnail .item .ayurveda-content {
    color: #fff;
    position: absolute;
    bottom: 20px;
    left: 10px;
    right: 10px;
}

.thumbnail .item .ayurveda-content .title {
    font-weight: 500;
}

.thumbnail .item .ayurveda-content .description {
    font-weight: 300;
}

.slider-btn {
    display: grid;
    position: absolute;
    z-index: 1;
    color: white;
    font-size: 2.4rem;
    border: 1px solid white;
    width: 35px;
    height: 35px;
    place-items: center;
    transform: translateY(-50%) rotate(45deg);
    transition: var(--transition-1);
}

.slider-btn ion-icon {
    transform: rotate(-45deg);
}

.slider-btn.prev {
    left: 30px;
    top: 60%;
}

.slider-btn.next {
    right: 30px;
    top: 60%;
}

.slider-btn:is(:hover, :focus-visible) {
    background-color: white;
    color: var(--black);
}

@media (min-width: 320px) {
    .arrows {
        position: absolute;
        top: 60%;
        right: 50%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

@media (min-width: 375px) {
    .arrows {
        position: absolute;
        top: 60%;
        right: 50%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

@media (min-width: 425px) {
    .arrows {
        position: absolute;
        top: 60%;
        right: 53%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

@media (min-width: 768px) {
    .arrows {
        position: absolute;
        top: 50%;
        right: 70%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

@media (min-width: 1024px) {
    .arrows {
        position: absolute;
        top: 50%;
        right: 75%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

@media (min-width: 1400px) {
    .arrows {
        position: absolute;
        top: 50%;
        right: 78%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

@media (min-width: 1400px) {
    .arrows {
        position: absolute;
        top: 50%;
        right: 75%;
        transform: translate(50%, -50%);
        z-index: 1;
        width: 80%;
        max-width: 300px;
        display: flex;
        gap: 10%;
        align-items: center;
    }
}

.arrows button {
    position: relative;
    width: 10vw;
    height: 10vw;
    max-width: 40px;
    max-height: 40px;

    border: 2px solid #fff;
    color: #fff;
    font-family: monospace;
    font-weight: bold;
    transition: 0.5s;
    background-color: transparent;
    cursor: pointer;
    transform: rotate(45deg);
}

.arrows button::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-top: 2px solid #fff;
    border-right: 2px solid #fff;
    width: 30%;
    height: 30%;
}

#prev::before {
    transform: translate(-50%, -50%) rotate(180deg);
}

#next::before {
    transform: translate(-50%, -50%) rotate(-4deg);
}

.arrows button:hover {
    background-color: #fff;
    border-color: #000;
}

.arrows button:hover::before {
    border-color: #000;
}

/* animation */
.carousel .list .item:nth-child(1) {
    z-index: 1;
}

/* animation text in first item */

/* .carousel .list .item:nth-child(1) .ayurveda-content .author,
.carousel .list .item:nth-child(1) .ayurveda-content .title,
.carousel .list .item:nth-child(1) .ayurveda-content .topic,
.carousel .list .item:nth-child(1) .ayurveda-content .des,
.carousel .list .item:nth-child(1) .ayurveda-content .btn {
    transform: translateY(50px);
    filter: blur(20px);
    opacity: 0;
    animation: showContent .5s 1s linear 1 forwards;
} */

@keyframes showContent {
    to {
        transform: translateY(0px);
        filter: blur(0px);
        opacity: 1;
    }
}

/* .carousel .list .item:nth-child(1) .ayurveda-content .title {
    animation-delay: 1.2s !important;
}

.carousel .list .item:nth-child(1) .ayurveda-content .topic {
    animation-delay: 1.4s !important;
}

.carousel .list .item:nth-child(1) .ayurveda-content .des {
    animation-delay: 1.6s !important;
}

.carousel .list .item:nth-child(1) .ayurveda-content .btn {
    animation-delay: 1.8s !important;
} */

/* create animation when next click */
/* .carousel.next .list .item:nth-child(1) img {
    width: 150px;
    height: 220px;
    position: absolute;
    bottom: 50px;
    left: 50%;
    border-radius: 30px;
    animation: showImage .5s linear 1 forwards;
}

@keyframes showImage {
    to {
        bottom: 0;
        left: 0;
        width: 100%;
        height: 100%;
        border-radius: 0;
    }
} */

.carousel.next .thumbnail .item:nth-last-child(1) {
    overflow: hidden;
    animation: showThumbnail 0.5s linear 1 forwards;
}

.carousel.prev .list .item img {
    z-index: 100;
}

@keyframes showThumbnail {
    from {
        width: 0;
        opacity: 0;
    }
}

.carousel.next .thumbnail {
    animation: effectNext 0.5s linear 1 forwards;
}

@keyframes effectNext {
    from {
        transform: translateX(150px);
    }
}

/* running time */

.carousel .time {
    position: absolute;
    z-index: 1000;
    width: 0%;
    height: 3px;
    /* background-color: #f1683a; */
    left: 0;
    top: 0;
}

.carousel.next .time,
.carousel.prev .time {
    animation: runningTime 1s linear 1 forwards;
}

@keyframes runningTime {
    from {
        width: 100%;
    }

    to {
        width: 0;
    }
}

/* prev click */

.carousel.prev .list .item:nth-child(2) {
    z-index: 2;
}

.carousel.prev .list .item:nth-child(2) img {
    animation: outFrame 0.5s linear 1 forwards;
    position: absolute;
    bottom: 0;
    left: 0;
}

@keyframes outFrame {
    to {
        width: 150px;
        height: 220px;
        bottom: 50px;
        left: 50%;
        border-radius: 20px;
    }
}

.carousel.prev .thumbnail .item:nth-child(1) {
    overflow: hidden;
    opacity: 0;
    animation: showThumbnail 0.5s linear 1 forwards;
}

.carousel.next .arrows button,
.carousel.prev .arrows button {
    pointer-events: none;
}

.carousel.prev .list .item:nth-child(2) .ayurveda-content .author,
.carousel.prev .list .item:nth-child(2) .ayurveda-content .title,
.carousel.prev .list .item:nth-child(2) .ayurveda-content .topic,
.carousel.prev .list .item:nth-child(2) .ayurveda-content .des,
.carousel.prev .list .item:nth-child(2) .ayurveda-content .btn {
    animation: contentOut 1.5s linear 1 forwards !important;
}

@keyframes contentOut {
    to {
        transform: translateY(-150px);
        filter: blur(20px);
        opacity: 0;
    }
}

@media screen and (max-width: 678px) {
    .carousel .list .item .ayurveda-content {
        padding-right: 0;
    }

    .carousel .list .item .ayurveda-content .title {
        font-size: 30px;
    }
}

@media (max-width: 880px) {
    .footer-distributed {
        font: bold 14px sans-serif;
    }

    .footer-distributed .footer-left,
    .footer-distributed .footer-center,
    .footer-distributed .footer-right {
        display: block;
        width: 100%;
        margin-bottom: 40px;
        text-align: center;
    }

    .footer-distributed .footer-center i {
        margin-left: 0;
    }
}
