/* ==========================================================
   Top Selling Wheel Carousel - CSS
   (chuyển thể từ CSS bóc tách của smithtran.com, đổi prefix tsw-)
   ========================================================== */

.tsw-sellinhome{
    margin-bottom: 70px;
}
.tsw-setitle{
    text-align: center;
    margin-bottom: 40px;
}
.tsw-setitle h2{
    font-size: 40px;
    line-height: 50px;
    font-weight: bold;
    color: #4f4f4e;
    margin: 0;
}

.tsw-wrap{
    overflow-x: clip;
    position: relative;
    margin-bottom: 60px;
}

/* Swiper */
.tsw-carousel{
    overflow: unset !important;
}
.tsw-carousel .swiper-slide{
    width: 280px;
}

/* Card */
.tsw-item{
    width: 280px;
    padding: 50px 30px 30px;
    background-color: #f8f8f8;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    transition: box-shadow .3s linear;
    will-change: transform;
}
.tsw-item:hover{
    box-shadow: 0 5px 10px 0 rgba(0, 0, 0, 0.1);
}
.tsw-thumb{
    margin-bottom: 25px;
}
.tsw-thumb a{
    display: block;
    padding-top: 100%;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    background-color: #ebebed;
}
.tsw-thumb a img{
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    transition: transform 0.8s cubic-bezier(0.44, 0.185, 0.575, 0.86);
    backface-visibility: hidden;
}
.tsw-item:hover .tsw-thumb a img{
    transform: translate(-50%, -50%) scale(1.05);
}
.tsw-title{
    text-align: center;
}
.tsw-title h3{
    font-size: 15px;
    line-height: 25px;
    font-weight: 400;
    margin: 0;
}
.tsw-title a{
    color: inherit;
    text-decoration: none;
}

/* Mũi tên điều hướng */
.tsw-arrow{
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #fff;
    width: 50px;
    height: 50px;
    border-radius: 100%;
    z-index: 2;
    color: #666666;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.tsw-arrow i{
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 20px;
    font-weight: bold;
    line-height: 1;
}
.tsw-prev{ margin-left: -170px; }
.tsw-next{ margin-left: 170px; }

/* Nút dưới carousel */
.tsw-btn{
    text-align: center;
}
.tsw-btn a{
    display: inline-block;
    padding: 14px 40px;
    background: #f5f3e6;
    border-radius: 6px;
    font-size: 16px;
    color: #333;
    text-decoration: none;
    transition: all .3s linear;
}
.tsw-btn a:hover{
    background: #222;
    color: #fff;
}

.tsw-empty{
    text-align: center;
    color: #999;
}

/* Responsive */
@media all and (min-width: 1600px){
    .tsw-carousel .swiper-slide{ width: 350px; }
    .tsw-item{ width: 350px; }
    .tsw-prev{ margin-left: -210px; }
    .tsw-next{ margin-left: 210px; }
}
@media all and (max-width: 991px){
    .tsw-sellinhome{ margin-bottom: 50px; }
    .tsw-setitle{ margin-bottom: 25px; }
    .tsw-setitle h2{ font-size: 30px; line-height: 40px; }
}
@media all and (max-width: 767px){
    .tsw-wrap{ margin-bottom: 40px; }
    .tsw-thumb{ margin-bottom: 15px; }
    .tsw-title h3{ font-size: 13px; line-height: 20px; }
    .tsw-item{ padding: 20px 20px 25px; }
    .tsw-carousel .swiper-slide, .tsw-item{ width: 160px; }
    .tsw-arrow{ width: 30px; height: 30px; }
    .tsw-arrow::before{ font-size: 15px; }
    .tsw-prev{ margin-left: -95px; }
    .tsw-next{ margin-left: 95px; }
}
