/* --- Tối ưu hóa lại style.css --- */
* {
    padding: 0;
    margin: 0;
    box-sizing: border-box; /* Quan trọng để tính toán kích thước chuẩn */
    -webkit-user-select: none;
    user-select: none;
}
:root {
    --primary: #28c7b8;
    --primary-dark: #12998e;
    --primary-light: #67f4e7;
    --primary-soft: rgba(40, 199, 184, 0.35);
    --primary-glow: rgba(40, 199, 184, 0.55);
    --panel-bg: rgba(10, 20, 20, 0.88);
    --text-dark: #021817;
}

body {
    font-family: Arial, sans-serif;
    background: #020706;
    color: #fff;
    overflow-x: hidden;
}

.wrapper {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    position: relative;
}

/* Video nền */
.bg_site video {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    object-fit: cover;
    z-index: -2;
}

.bg1 {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 50% 12%, rgba(40, 199, 184, 0.18), transparent 32%),
        rgba(0, 0, 0, 0.68);
    z-index: -1;
}

.container {
    width: 100%;
    max-width: 1000px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 1;
}

/* Logo Top */
.abcvip {
    width: 100%;
    max-width: 440px;
    margin: 24px 0 32px 0;
    padding: 14px 28px;
    text-align: center;
    position: relative;
    border-radius: 24px;
    background:
        linear-gradient(180deg, rgba(8, 36, 34, 0.82), rgba(2, 14, 13, 0.72)),
        rgba(0, 0, 0, 0.55);
    box-shadow:
        0 0 32px rgba(40, 199, 184, 0.32),
        0 16px 45px rgba(0, 0, 0, 0.35),
        inset 0 0 28px rgba(40, 199, 184, 0.14);
    isolation: isolate;
    overflow: hidden;
}

.abcvip::before,
.abcvip::after {
    content: '';
    position: absolute;
    pointer-events: none;
    border-radius: inherit;
}

.abcvip::before {
    inset: 0;
    padding: 2px;
    background: linear-gradient(
        90deg,
        rgba(40, 199, 184, 0.15),
        var(--primary-light),
        #ffffff,
        var(--primary),
        rgba(40, 199, 184, 0.18)
    );
    background-size: 260% 100%;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    z-index: 0;
    animation: ledFlow 3.4s linear infinite;
}

.abcvip::after {
    inset: 2px;
    background:
        linear-gradient(115deg, transparent 0 36%, rgba(103, 244, 231, 0.2) 46%, transparent 58%),
        radial-gradient(circle at 50% 0, rgba(103, 244, 231, 0.18), transparent 48%);
    transform: translateX(-125%);
    opacity: 0.85;
    z-index: 1;
    animation: logoSweep 4.8s ease-in-out infinite;
}

@keyframes ledFlow {
    to {
        background-position: 260% 0;
    }
}

@keyframes logoSweep {
    0%, 42% {
        transform: translateX(-125%);
    }

    70%, 100% {
        transform: translateX(125%);
    }
}

.abcviplogo {
    width: 100%;
    height: auto;
    display: block;
    position: relative;
    z-index: 2;
    filter:
        drop-shadow(0 0 8px rgba(103, 244, 231, 0.48))
        drop-shadow(0 0 22px rgba(40, 199, 184, 0.28));
}

/* Tiêu đề */
.title-section {
    text-align: center;
    margin-bottom: 30px;
}

.title-section h1 {
    font-size: clamp(20px, 6vw, 32px);
    color: var(--primary);
    text-transform: uppercase;
    margin-bottom: 10px;
    text-shadow: 0 0 18px rgba(40, 199, 184, 0.35);
}

.title-section p {
    font-size: 14px;
    color: #ccc;
}

/* --- KHU VỰC SỬA LỖI CHÍNH --- */
.list {
    width: 100%;
    display: flex;
    flex-wrap: wrap; /* Cho phép xuống dòng trên mobile */
    justify-content: center;
    gap: 20px;
    margin-bottom: 34px;
}

.item {
    background: var(--panel-bg);
    border: 1px solid var(--primary-soft);
    border-radius: 20px;
    padding: 20px 10px;
    flex: 0 1 calc(25% - 20px); /* 4 cột trên PC */
    min-width: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: 0.3s;
    backdrop-filter: blur(10px);
}

.item:hover {
    transform: translateY(-5px);
    border-color: rgba(103, 244, 231, 0.75);
    box-shadow: 0 8px 26px rgba(40, 199, 184, 0.34);
}

/* Vòng tròn xoay quanh flag */
.flag-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
    margin-bottom: 15px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.flag-wrapper::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    padding: 3px;
    background: conic-gradient(var(--primary), transparent 60%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    animation: spin 3s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.flag {
    width: 80%;
    height: 80%;
    border-radius: 50%;
    object-fit: cover;
}

.item .text {
    font-size: 14px;
    font-weight: bold;
    color: var(--primary);
    margin-bottom: 15px;
}

.button {
    background: linear-gradient(90deg, var(--primary-light), var(--primary), var(--primary-dark));
    color: var(--text-dark);
    padding: 10px 15px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    text-align: center;
    width: 90%;
    box-shadow: 0 0 16px rgba(40, 199, 184, 0.28);
    transition: 0.25s;
}

.button:hover {
    filter: brightness(1.08);
    box-shadow: 0 0 24px rgba(40, 199, 184, 0.46);
}

/* Footer ads */
.chuky {
    width: 100%;
    max-width: 660px;
    text-align: center;
    margin-top: 8px;
    padding: 12px 12px 18px;
    position: relative;
    border-radius: 18px;
    background:
        linear-gradient(180deg, rgba(8, 36, 34, 0.84), rgba(2, 12, 12, 0.82)),
        rgba(0, 0, 0, 0.55);
    box-shadow:
        0 0 28px rgba(40, 199, 184, 0.22),
        0 18px 42px rgba(0, 0, 0, 0.42),
        inset 0 0 20px rgba(40, 199, 184, 0.1);
    isolation: isolate;
    overflow: hidden;
}

.chuky::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 1px;
    border-radius: inherit;
    background: linear-gradient(
        90deg,
        rgba(40, 199, 184, 0.12),
        var(--primary),
        var(--primary-light),
        var(--primary),
        rgba(40, 199, 184, 0.12)
    );
    background-size: 240% 100%;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    z-index: 0;
    animation: ledFlow 4s linear infinite;
}

.chuky::after {
    content: '';
    position: absolute;
    top: 9px;
    left: 12%;
    right: 12%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(103, 244, 231, 0.8), transparent);
    box-shadow: 0 0 14px rgba(40, 199, 184, 0.5);
    z-index: 1;
}

.chuky a {
    display: block;
    position: relative;
    z-index: 2;
    border-radius: 12px;
    overflow: hidden;
    background: #041514;
    box-shadow:
        0 0 0 1px rgba(103, 244, 231, 0.22),
        0 10px 24px rgba(0, 0, 0, 0.35);
    transition: 0.25s;
}

.chuky a::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent 0 38%, rgba(255, 255, 255, 0.34) 50%, transparent 62%);
    transform: translateX(-130%);
    z-index: 2;
    pointer-events: none;
    animation: bannerShine 5.2s ease-in-out infinite;
}

.chuky a:hover {
    transform: translateY(-2px);
    box-shadow:
        0 0 0 1px rgba(103, 244, 231, 0.55),
        0 0 24px rgba(40, 199, 184, 0.38),
        0 12px 28px rgba(0, 0, 0, 0.42);
}

.ck {
    width: 100%;
    display: block;
    position: relative;
    z-index: 1;
    margin-bottom: 0;
    filter: saturate(1.08) contrast(1.04);
}

@keyframes bannerShine {
    0%, 46% {
        transform: translateX(-130%);
    }

    72%, 100% {
        transform: translateX(130%);
    }
}

.copyright h4 {
    position: relative;
    z-index: 2;
    margin-top: 12px;
    font-size: 14px;
    color: #d7fffb;
    text-shadow: 0 0 10px rgba(40, 199, 184, 0.42);
}

/* --- MOBILE RESPONSIVE --- */
@media screen and (max-width: 768px) {
    .item {
        flex: 0 1 calc(50% - 10px); /* Chia 2 cột trên điện thoại */
        min-width: 140px;
        padding: 15px 5px;
    }
    
    .flag-wrapper {
        width: 80px;
        height: 80px;
    }

    .title-section h1 {
        font-size: 22px;
    }

    .abcvip {
        max-width: 340px;
        margin: 16px 0 24px;
        padding: 10px 18px;
        border-radius: 18px;
    }

    .chuky {
        max-width: 94%;
        padding: 8px 8px 14px;
        border-radius: 14px;
    }

    .chuky a {
        border-radius: 10px;
    }

    .copyright h4 {
        margin-top: 10px;
        font-size: 12px;
    }

    .list {
        gap: 10px; /* Thu hẹp khoảng cách trên mobile */
    }
}
