/* =========================================================
   FILE CSS TỔNG HỢP - gộp từ các thẻ <style> trong index.php
   ========================================================= */

/* =========================================================
   MODERN HERO SECTION (FIGMA STYLE)
   ========================================================= */
.hero-modern {
    position: relative;
    background: radial-gradient(circle at 50% 0%, #1e3a8a 0%, #0f172a 50%, #030712 100%);
    background-color: #030712;
    padding: 80px 20px 60px 20px;
    overflow: hidden;
    text-align: center;
    color: #ffffff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Lưới kỹ thuật số nền (Digital Grid) */
.hero-bg-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(circle at 50% 20%, black 30%, transparent 80%);
    -webkit-mask-image: radial-gradient(circle at 50% 20%, black 30%, transparent 80%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    z-index: 2;
}

/* Badge Pill */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #e2e8f0;
    backdrop-filter: blur(10px);
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.badge-dot {
    width: 6px;
    height: 6px;
    background-color: #00f2fe;
    border-radius: 50%;
    box-shadow: 0 0 8px #00f2fe;
}

/* Tiêu đề lớn */
.hero-title {
    font-size: clamp(2.2rem, 5vw, 3.8rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -1.5px;
    margin-bottom: 20px;
    color: #ffffff;
}

.hero-title span {
    background: linear-gradient(135deg, #00f2fe 0%, #4facfe 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Mô tả */
.hero-desc {
    font-size: clamp(1rem, 1.5vw, 1.15rem);
    color: #94a3b8;
    max-width: 700px;
    margin: 0 auto 32px auto;
    line-height: 1.6;
}

.hero-desc b {
    color: #f8fafc;
    font-weight: 600;
}

/* Nút bấm hành động */
.hero-actions {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-bottom: 50px;
    flex-wrap: wrap;
}

.btn-hero-primary {
    background: linear-gradient(135deg, #00f2fe 0%, #0072ff 100%);
    color: #ffffff;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 30px;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(0, 242, 254, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-hero-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0, 242, 254, 0.5);
    color: #ffffff;
}

.btn-hero-outline {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 30px;
    text-decoration: none;
    backdrop-filter: blur(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-hero-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    color: #ffffff;
}

/* Thẻ thống kê (Stats Cards) */
.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    max-width: 850px;
    margin: 0 auto;
}

.hero-stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 16px;
    padding: 18px;
    backdrop-filter: blur(12px);
    text-align: center;
    transition: transform 0.3s, border-color 0.3s;
}

.hero-stat-card:hover {
    transform: translateY(-4px);
    border-color: rgba(0, 242, 254, 0.3);
    background: rgba(255, 255, 255, 0.05);
}

.hero-stat-card b {
    display: block;
    font-size: 1.6rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 4px;
}

.hero-stat-card span {
    font-size: 0.85rem;
    color: #94a3b8;
}

/* =========================================================
   HIỆU ỨNG CHUYỂN ĐỘNG MƯỢT MÀ (ANIMATIONS)
   ========================================================= */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(25px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-down {
    animation: fadeDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-fade-up {
    animation: fadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    opacity: 0; /* Ẩn ban đầu để chờ chạy hiệu ứng */
}

/* Độ trễ hiệu ứng xuất hiện lần lượt (Stagger effect) */
.delay-1 { animation-delay: 0.15s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.45s; }

/* =========================================================
   FEATURES SECTION (QUADENCY STYLE)
   ========================================================= */
.features-section {
    position: relative;
    background-color: #030712;
    padding: 80px 20px;
    color: #ffffff;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.features-badge {
    display: inline-flex;
    padding: 6px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #38bdf8;
    margin-bottom: 16px;
    backdrop-filter: blur(10px);
}

.features-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 12px;
    color: #ffffff;
}

.features-subtitle {
    font-size: 1.05rem;
    color: #94a3b8;
    max-width: 600px;
    margin: 0 auto 50px auto;
    line-height: 1.5;
}

/* Khung bọc lưới chứa các thẻ */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto 50px auto;
    text-align: left;
}

/* Từng thẻ card phong cách kính mờ (Glassmorphism) */
.feature-card {
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.6) 0%, rgba(3, 7, 18, 0.8) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(16px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    transform: translateY(-6px);
    border-color: rgba(0, 242, 254, 0.4);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Icon đại diện trong card */
.feature-icon {
    width: 44px;
    height: 44px;
    background: rgba(0, 242, 254, 0.1);
    border: 1px solid rgba(0, 242, 254, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 10px;
}

.feature-card p {
    font-size: 0.92rem;
    color: #94a3b8;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* Nút link chuyển hướng nhỏ bên trong thẻ */
.feature-link {
    display: inline-flex;
    align-items: center;
    font-size: 0.9rem;
    font-weight: 600;
    color: #38bdf8;
    text-decoration: none;
    transition: color 0.2s;
}

.feature-link:hover {
    color: #00f2fe;
    text-decoration: underline;
}

/* Khu vực nút bấm CTA lớn cuối phần giới thiệu */
.features-cta {
    margin-top: 30px;
}

/* =========================================================
   RESPONSIVE GRID CHO DANH SÁCH CODE (4 CỘT)
   ========================================================= */
.grid.cm-code-grid {
    grid-template-columns: repeat(4, 1fr) !important;
}

@media (max-width: 1024px) {
    .grid.cm-code-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}
@media (max-width: 640px) {
    .grid.cm-code-grid {
        grid-template-columns: 1fr !important;
    }
}

/* =========================================================
   CSS BỔ SUNG CHO NHÃN VÀ CHỮ "MIỄN PHÍ"
   ========================================================= */
.badge.cm-badge-code.cm-badge-free {
    border-color: rgba(34, 197, 94, 0.5);
    color: #4ade80;
}
.cm-code-price-free {
    font-size: 1.1rem;
    font-weight: 800;
    color: #4ade80;
    text-shadow: 0 0 10px rgba(74, 222, 128, 0.2);
}

:root {
    --cm-code-gradient: linear-gradient(135deg, #00f2fe 0%, #4facfe 100%);
    --cm-code-glow: rgba(0, 242, 254, 0.25);
    --cm-code-border: rgba(255, 255, 255, 0.1);
    --cm-code-bg: rgba(15, 23, 42, 0.6);
}

.cm-category-block {
    margin-bottom: 48px;
}

.cm-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 12px;
}
.cm-section-head h2 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    color: var(--text, #f8fafc);
}
.cm-section-head .desc a {
    color: #00f2fe;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}
.cm-section-head .desc a:hover {
    text-decoration: underline;
}

/* 1. Promo Banners Grid */
.cm-promo-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 32px;
}
.cm-promo-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 28px 32px;
    border-radius: 12px;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.3s ease;
}
.cm-promo-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}
.cm-promo-dark {
    background: #18181b;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.cm-promo-light {
    background: #ffffff;
    color: #0f172a;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}
.cm-promo-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.cm-promo-info h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0 0 6px 0;
    line-height: 1.25;
}
.cm-promo-dark .cm-promo-info h3 { color: #ffffff; }
.cm-promo-light .cm-promo-info h3 { color: #0f172a; }

.cm-promo-link {
    font-size: 0.9rem;
    font-weight: 500;
    opacity: 0.7;
    transition: opacity 0.2s ease, transform 0.2s ease;
    display: inline-block;
}
.cm-promo-dark .cm-promo-link { color: #a1a1aa; }
.cm-promo-light .cm-promo-link { color: #64748b; }

.cm-promo-card:hover .cm-promo-link {
    opacity: 1;
    transform: translateX(4px);
}

/* 2. Popular Searches Section */
.cm-popular-searches {
    margin-top: 28px;
    margin-bottom: 36px;
}
.cm-popular-searches h4 {
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 12px 0;
    color: var(--text, #f8fafc);
}
.cm-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.cm-tag-pill {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #cbd5e1;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}
.cm-tag-pill:hover {
    background: #ffffff;
    color: #0f172a;
    border-color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.15);
}

/* 3. Code Cards Grid */
.cm-code-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.card.cm-code-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--cm-code-bg);
    overflow: hidden;
    text-decoration: none;
    backdrop-filter: blur(12px);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.card.cm-code-card::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; height: 2px;
    background: var(--cm-code-gradient);
    opacity: 0.3;
    transition: opacity 0.3s ease;
    z-index: 10;
}
.card.cm-code-card:hover {
    transform: translateY(-6px);
    border-color: rgba(0, 242, 254, 0.4);
    box-shadow: 0 16px 36px -10px var(--cm-code-glow);
}
.card.cm-code-card:hover::before {
    opacity: 1;
}

/* Card Thumbnail & Carousel */
.cm-code-thumb {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #0b1120;
}
.cm-code-thumb img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.5s ease, filter 0.5s ease;
    filter: brightness(0.9);
}
.card.cm-code-card:hover .cm-code-thumb img {
    transform: scale(1.06);
    filter: brightness(1.05);
}
.cm-code-noimg {
    height: 100%; display: flex; align-items: center; justify-content: center;
    font-family: monospace; font-size: 0.85rem; color: #475569;
}

.cm-carousel { position: relative; width: 100%; height: 100%; overflow: hidden; }
.cm-carousel-inner { display: flex; width: 100%; height: 100%; transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1); }
.cm-carousel-inner img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; }

.cm-nav-btn {
    position: absolute; top: 50%; transform: translateY(-50%);
    background: rgba(15, 23, 42, 0.75); color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    width: 32px; height: 32px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; cursor: pointer; z-index: 20; backdrop-filter: blur(4px);
    transition: all 0.2s ease;
}
.cm-nav-btn:hover {
    background: rgba(0, 242, 254, 0.9);
    border-color: #ffffff;
    transform: translateY(-50%) scale(1.1);
}
.cm-prev { left: 8px; }
.cm-next { right: 8px; }

.badge.cm-badge-code {
    position: absolute; top: 12px; right: 12px;
    background: rgba(15, 23, 42, 0.75); backdrop-filter: blur(8px);
    border: 1px solid rgba(0, 242, 254, 0.3); color: #00f2fe;
    font-family: monospace; font-size: 0.65rem; font-weight: 800;
    padding: 3px 9px; border-radius: 6px; z-index: 10;
}

/* Card Content Details */
.card.cm-code-card .card-body { padding: 18px; display: flex; flex-direction: column; flex-grow: 1; }
.card.cm-code-card .card-title {
    color: #f8fafc; font-size: 1.05rem; font-weight: 700; margin-bottom: 6px; line-height: 1.4;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card.cm-code-card .card-desc {
    color: #94a3b8; font-size: 0.85rem; line-height: 1.5; margin-bottom: 12px; flex-grow: 1;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card.cm-code-card .card-meta {
    display: flex; justify-content: space-between; align-items: center;
    padding-top: 14px; border-top: 1px dashed rgba(255, 255, 255, 0.1);
}
.card.cm-code-card .card-seller { display: flex; align-items: center; gap: 8px; color: #cbd5e1; font-size: 0.82rem; }
.card.cm-code-card .card-seller img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }

.cm-code-price {
    font-size: 1.2rem; font-weight: 800;
    background: var(--cm-code-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.cm-code-price::after { content: ' ₫'; font-size: 0.85rem; -webkit-text-fill-color: #4facfe; }

/* Responsive Adjustments */
@media (max-width: 992px) {
    .cm-code-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .cm-promo-grid { grid-template-columns: 1fr; }
    .cm-code-grid { grid-template-columns: 1fr; }
}
/* =========================================================
   STYLE FOOTER QUADENCY STYLE
   ========================================================= */
.footer-modern {
    background-color: #030712;
    color: #94a3b8;
    position: relative;
    overflow: hidden;
    padding-top: 40px;
    padding-bottom: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-family: inherit;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 30px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

/* Brand */
.footer-brand {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 6px;
}
.footer-brand .prompt {
    color: #00f2fe;
}

/* Links Nav */
.footer-links {
    list-style: none;
    display: flex;
    gap: 24px;
    padding: 0;
    margin: 0;
}
.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}
.footer-links a:hover {
    color: #ffffff;
}

/* Social Icons */
.footer-socials {
    display: flex;
    gap: 16px;
}
.footer-socials a {
    color: #ffffff;
    font-size: 1.1rem;
    opacity: 0.8;
    transition: all 0.2s;
}
.footer-socials a:hover {
    opacity: 1;
    transform: translateY(-2px);
    color: #00f2fe;
}

/* CHỮ SIÊU TO CHẠY TỪ PHẢI SANG TRÁI */
.footer-big-text-track span {
    font-family: 'PSBolden', sans-serif !important; /* Gọi font PS-Bolden.otf */
    font-size: clamp(6rem, 18vw, 15rem);          /* Chỉnh cỡ chữ to siêu khủng tùy ý */
    font-weight: normal;                          /* Font .otf đã đậm sẵn nên để normal hoặc bold tùy mẫu */
    line-height: 0.85;
    letter-spacing: -2px;
    margin-right: 40px;
    
    /* Màu Gradient chữ tráng bạc lỏng đẹp mắt */
    background: linear-gradient(180deg, #ffffff 0%, rgba(255, 255, 255, 0.15) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.footer-big-text-track {
    display: inline-flex;
    animation: marquee-left 25s linear infinite;
    /* Hiệu ứng trượt từ dưới lên khi vừa load trang */
    animation-name: slide-up-entry, marquee-left;
    animation-duration: 0.8s, 25s;
    animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1), linear;
    animation-delay: 0s, 0.8s;
    animation-iteration-count: 1, infinite;
}

.footer-big-text-track span {
    font-size: clamp(5rem, 15vw, 12rem);
    font-weight: 900;
    line-height: 0.85;
    letter-spacing: -2px;
    margin-right: 40px;
    
    /* Màu Gradient chữ tráng bạc lỏng đẹp mắt */
    background: linear-gradient(180deg, #ffffff 0%, rgba(255, 255, 255, 0.15) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Keyframes cho hiệu ứng chuyển động */
@keyframes slide-up-entry {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes marquee-left {
    0% {
        transform: translateX(0%);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Thông tin phí nền tảng bên dưới cùng */
.footer-bottom-info {
    text-align: center;
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 15px;
    font-family: monospace;
}

/* Responsive cho Mobile */
@media (max-width: 768px) {
    .footer-container {
        flex-direction: column;
        text-align: center;
    }
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }
}