﻿
/* 轮播图样式 */
.custom-carousel {
    position: relative;
    width: 100%;
    height: 15rem;
    overflow: hidden;
    
}

.carousel-slides {
    display: flex;
    transition: transform 0.4s ease-in-out;
    height: 100%;
}

.slide {
    min-width: 100%;
    height: 100%;
    position: relative; /* ← 关键：作为 overlay 的定位上下文 */
}

    .slide img {
        width: 100%;
        height: 100%;
        /*object-fit: cover;*/
        display: block;
        border-radius:0.6rem;
    }

.overlay-text {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 5px 8px;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    color: white;
    font-size: 14px;
    line-height: 1.4;
    z-index: 5;
    text-align: left;
}
/* 透明点击层，覆盖整个 slide */
.slide-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 6; /* 在文字上方，但不影响显示 */
    background: transparent;
}

.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    line-height: 36px;
    text-align: center;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    z-index: 10;
    user-select: none;
}

    .carousel-arrow.left {
        left: 10px;
    }

    .carousel-arrow.right {
        right: 10px;
    }

.carousel-indicators {
    position: absolute;
    bottom: 26px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}

.indicator {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(0,0,0,0.7); /* 黑色背景 */
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 6px;
    /*font-weight: bold;*/
    cursor: default; /* 不可点击样式 */
}

    .indicator.active {
        background: #333; /* 当前项高亮色 */
    }
