﻿.map-container {
    position: relative;
    width: 390px; /* Kích thước bản đồ */
    height: auto; /* Đảm bảo tỉ lệ bản đồ */
    animation: mapMove 5s infinite alternate ease-in-out;
    margin: auto;
}

.vietnam-map {
    width: 100%;
    height: auto;
}

.home-content-map {
    padding: 32px 0;
    background: url(/Design/img/MoiTruongViet/b8.png) no-repeat;
    background-size: 100% 100%;
}

    .home-content-map .grid.wide {
        max-width: 1285px;
        padding: 0;
    }

.marker {
    position: absolute;
    width: 2px;
    height: 15px;
    background-color: #ffcc00;
    cursor: pointer;
    transform: translate(-50%, -50%);
}

    .marker::before {
        content: attr(data-name); /* Hiển thị tên tỉnh/thành phố */
        position: absolute;
        top: -25px; /* Hiển thị ở trên icon */
        left: 50%;
        transform: translateX(-50%);
        background-color: white;
        padding: 5px 8px;
        font-size: 13px;
        font-family: 'AVERTASTDCY-REGULAR';
        text-transform: uppercase;
        color: #3d3d3d;
        border: 1px solid #ccc;
        border-radius: 5px;
        white-space: nowrap;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    }

    .marker::after {
        content: '';
        position: absolute;
        top: 100%;
        left: 50%;
        width: 31px;
        height: 48px;
        background: url(/Design/img/SaoPhuongBac/Map/check-map.png) no-repeat; /* Tạo đuôi của icon */
        transform: translateX(-50%);
    }

.right-map-content h5 {
    margin: 0;
    text-align: center;
    font-family: 'Oswald-Medium';
    font-size: 34px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    text-transform: uppercase;
    background: linear-gradient(90deg, #009247 0%, #57BA76 50%, #009247 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.right-map-content section {
    font-size: 22px;
    color: #ffffff;
    font-family: 'AvertaStdCY-Regular';
    text-align: center;
    margin-top: 10px;
    margin-bottom: 75px;
}

.num-cc-map, .num-cc-map h5 {
    font-size: 60px;
    color: #02a5e3;
    font-family: 'AvertaStdCY-Extrabold';
}

.num-cc-map {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 150px;
    margin: auto;
    height: 60px;
}

    .num-cc-map h5 {
        padding: 0;
    }

.line-dedor-map {
    display: flex;
    align-items: center;
    position: relative;
}

.num-cc-map:before {
    content: "";
    position: absolute;
    background: #20407b;
    width: 100%;
    height: 6px;
    left: 0;
    bottom: -14px;
    margin: auto;
    right: 0;
    top: 0;
    pointer-events: unset;
}

.img-icon-map-decor img {
    filter: invert(24%) sepia(76%) saturate(830%) hue-rotate(95deg) brightness(91%) contrast(98%);
}

.item-cc-map span {
    position: relative;
    font-size: 24px;
    font-family: 'Oswald-Medium';
    color: #238E44;
    display: block;
    text-align: center;
    padding-bottom: 5px;
    margin-top: 15px;
}

.item-cc-map section {
    width: 166px;
    font-size: 18px;
    color: #fff;
    font-family: 'AvertaStdCY-Regular';
    text-align: center;
    margin: auto;
    margin-bottom: 14px;
    margin-top: 14px;
}

.img-icon-map-decor {
    width: 102px;
    height: 104px;
    display: flex;
    align-items: center;
    background: #fff;
    border-radius: 0 25px;
    justify-content: center;
    margin: auto;
}

.item-cc-map {
    margin-right: 18px;
    padding: 0 12px;
    border: 2px solid #fff;
    border-radius: 20px;
    height: 217px;
    background: rgb(255 255 255 / 20%);
}

.item-cc-map {
    perspective: 1000px; /* Tạo chiều sâu cho hiệu ứng 3D */
}

.img-icon-map-decor img {
    transition: transform 0.6s ease-in-out;
    transform-style: preserve-3d; /* Giữ hiệu ứng 3D */
}

/* Khi hover vào .item-cc-map, ảnh sẽ lật */
.item-cc-map:hover .img-icon-map-decor img {
    transform: rotateY(180deg);
}

.list-top-map-cc {
    display: flex;
}

.item-cc-map:nth-child(4) {
    margin-right: 0;
}

.c-content-map {
    display: flex;
}

.right-map-content {
    flex: 1 1 0;
}

.c-full-map-t {
    position: relative;
    top: -39px;
}

.left-map-full {
    width: 450px;
    text-align: center;
}

.item-cc-map span:after {
    content: "";
    position: absolute;
    background: #fff;
    left: 0;
    bottom: 0;
    right: 0;
    width: 52px;
    height: 2px;
    margin: auto;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.5);
        opacity: 0.5;
    }
}

@keyframes mapMove {
    0% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(10px);
    }
}

@media (min-width: 1024px) and (max-width: 1220px) {
    .right-map-content h5 {
        font-size: 27px;
    }

    .home-content-map .grid.wide {
        max-width: 96%;
    }

    .right-map-content section {
        font-size: 16px;
    }

    .num-cc-map, .num-cc-map h5 {
        font-size: 42px;
    }

    .img-icon-map-decor img {
        width: 49%;
        height: auto;
    }

    .map-container {
        position: relative;
        width: 315px;
    }

    .item-cc-map > section {
        width: 113px;
        font-size: 14px;
    }

    .left-map-full {
        width: 315px;
    }

    .img-icon-map-decor {
        width: 82px;
        height: 84px;
    }
}

@media(max-width:1023px) {
    .map-container {
        width: 100%;
        text-align: center;
        margin: auto;
    }

    .left-map-full {
        width: 100%;
    }

    .vietnam-map {
        width: 92%;
        height: auto;
        margin: auto;
    }

    .right-map-content h5 {
        font-size: 18px;
        text-align: left;
    }

    .right-map-content section {
        font-size: 15px;
        text-align: justify;
        margin-bottom: 18px;
    }

    .right-map-content {
        padding: 0 5px;
        margin-top: 16px;
    }

    .list-top-map-cc {
        display: grid;
        grid-auto-rows: minmax(min-content, max-content);
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 10px;
        row-gap: 58px;
        margin-top: 60px;
    }

    .item-cc-map {
        margin: 0;
        height: 160px;
    }

        .item-cc-map span {
            font-size: 18px;
            margin-top: 19px;
        }

    .num-cc-map, .num-cc-map h5 {
        font-size: 34px;
    }

    .item-cc-map section {
        width: 91%;
        text-align: center;
    }

    .item-cc-map:nth-child(1) section {
        width: 73%;
    }

    .img-icon-map-decor {
        width: 68px;
        height: 68px;
    }

        .img-icon-map-decor img {
            display: block;
            width: 68%;
            /* height: 100%; */
        }

    .item-cc-map:nth-child(1) .img-icon-map-decor img {
        width: 48%;
    }

    .c-full-map-t {
    }

    .home-content-map {
        padding-bottom: 70px;
        background-size: cover;
    }

    .item-cc-map:nth-child(3) .num-cc-map:before, .item-cc-map:nth-child(4) .num-cc-map:before {
        background: #1f376e;
    }

    .c-content-map {
        display: block;
    }
}