/* 特殊作品多图轮播 / 多证书样式 (works/789870) */

/* ============ PC 端：作品缩略图条 ============ */
.sw-carousel {
    margin: 16px auto 4px;
    width: 960px;       /* 与 .imgShow 同宽 */
    max-width: 100%;
}
.sw-counter {
    text-align: center;
    color: #666;
    font-size: 13px;
    margin-bottom: 8px;
}
.sw-thumb-wrap {
    position: relative;
    padding: 0 26px;
}
.sw-thumbs {
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    height: 78px;
    scroll-behavior: smooth;
}
.sw-thumbs::-webkit-scrollbar { height: 6px; }
.sw-thumbs::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }
.sw-thumb {
    display: inline-block;
    width: 70px;
    height: 70px;
    margin-right: 6px;
    border: 2px solid #e0e0e0;
    box-sizing: border-box;
    overflow: hidden;
    text-align: center;
    background: #f5f5f5;
    vertical-align: middle;
}
.sw-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.sw-thumb.active {
    border-color: #c00;
}
.sw-thumb-arrow {
    position: absolute;
    top: 0;
    width: 22px;
    height: 70px;
    line-height: 70px;
    text-align: center;
    font-size: 24px;
    color: #888;
    background: #f0f0f0;
    text-decoration: none;
    user-select: none;
}
.sw-thumb-arrow:hover { color: #c00; }
.sw-prev { left: 0; }
.sw-next { right: 0; }

/* ============ PC 端：多证书轮播（大图+左右切换，无缩略图） ============ */
.certImg.sw-cert-wrap {
    padding: 20px 0;
}
.sw-cert-carousel {
    width: 960px;
    max-width: 100%;
    margin: 0 auto;
}
.sw-cert-stage {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 620px;
    margin: 0 auto;
    min-height: 120px;
}
.sw-cert-main {
    display: block;
    text-align: center;
    cursor: zoom-in;
}
/* 提高优先级并 !important，确保盖过 detail.css 的 .certImg img */
.certImg .sw-cert-main img,
.sw-cert-carousel .sw-cert-main img {
    max-width: 420px !important;
    max-height: 600px !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    border: 1px solid #e0e0e0;
    box-shadow: 0 1px 6px rgba(0, 0, 0, .12);
}
.sw-cert-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 64px;
    line-height: 64px;
    text-align: center;
    font-size: 40px;
    color: #888;
    background: rgba(240, 240, 240, .9);
    text-decoration: none;
    user-select: none;
    border-radius: 4px;
    z-index: 2;
}
.sw-cert-nav:hover { color: #c00; background: #f0f0f0; }
.sw-cert-prev { left: 0; }
.sw-cert-next { right: 0; }
.sw-cert-carousel .sw-counter { margin-top: 14px; }

/* ============ 移动端：作品横向滑动轮播 ============ */
.sw-m-carousel { position: relative; width: 100%; background: #fff; }
.sw-m-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}
.sw-m-track::-webkit-scrollbar { display: none; }
.sw-m-slide {
    flex: 0 0 100%;
    scroll-snap-align: center;
    text-align: center;
}
.sw-m-slide img {
    width: 100%;
    height: auto;
    display: block;
}
/* 作品轮播：控制每屏高度，避免长图被拉得过长（证书轮播 .sw-m-carousel 不受影响） */
.sw-m-works .sw-m-slide {
    height: 110vw;
    max-height: 78vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f7f7f7;
}
.sw-m-works .sw-m-slide img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.sw-m-counter {
    position: absolute;
    right: 10px;
    bottom: 10px;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 12px;
    padding: 2px 10px;
    border-radius: 12px;
}

/* 移动端证书复用 .sw-m-carousel 横向滑动样式 */
