html {
    scroll-behavior: smooth;
}

body {
    background: radial-gradient(ellipse at center,
            #0b1526 0%,
            #060b14 45%,
            #03060c 100%);
    color: white;
    margin: 0;
    font-family: 'Roboto Condensed', sans-serif;
    /* Font chính cho nội dung */
}

/* --- 1. TOP NAVIGATION BAR --- */
.top-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #000;
    padding: 10px 30px;
    border-bottom: 2px solid #b20000;
    /* Viền đỏ ngăn cách */
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

/* Bên trái */
.nav-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-logo {
    height: 40px;
    width: auto;
}

.brand-name {
    font-size: 1.2em;
    font-weight: bold;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Bebas Neue', cursive;
    /* Font logo mạnh mẽ */
}

/* Container chính chứa cả 3 phần: sidebar trái, main content, sidebar phải */
.home-game-details-container {
    display: flex;
    gap: 30px;
    max-width: 1400px;
    /* Giới hạn chiều rộng tối đa */
    margin: 0 auto;
    /* Căn giữa trang */
    width: 100%;
    padding: 0 20px;
}

/* Ở giữa */
.nav-center {
    display: flex;
    gap: 30px;
}

.nav-link {
    color: #ccc;
    text-decoration: none;
    font-size: 1em;
    font-weight: bold;
    text-transform: uppercase;
    transition: color 0.3s;
}

.nav-link:hover {
    color: #b20000;
}

/* Bên phải */
.nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* --- SEARCH BOX STYLES --- */
.search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 0;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    border: none;
    background: #222;
    color: #fff;
    padding: 8px 15px;
    border-radius: 20px;
    margin-right: 10px;
    outline: none;
    border: 1px solid transparent;
}

.search-wrapper.active .search-input {
    width: 250px;
    opacity: 1;
    visibility: visible;
    border-color: #444;
}

.search-results {
    position: absolute;
    top: 120%;
    right: 0;
    width: 300px;
    background: #1a1a1a;
    border: 1px solid #b20000;
    border-radius: 8px;
    max-height: 400px;
    overflow-y: auto;
    display: none;
    z-index: 1001;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.9);
}

.search-results.active {
    display: block;
}

/* Scrollbar cho search results */
.search-results::-webkit-scrollbar {
    width: 6px;
}

.search-results::-webkit-scrollbar-track {
    background: #111;
}

.search-results::-webkit-scrollbar-thumb {
    background: #b20000;
    border-radius: 3px;
}

.search-icon {
    color: #fff;
    font-size: 1.2em;
    cursor: pointer;
    transition: color 0.3s;
}

.search-icon:hover {
    color: #b20000;
}

.search-item {
    padding: 12px 15px;
    border-bottom: 1px solid #333;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    transition: background 0.2s;
}

.search-item:last-child {
    border-bottom: none;
}

.search-item:hover {
    background: #333;
}

.search-item-title {
    color: #fff;
    font-weight: bold;
    font-size: 0.95em;
}

.search-item-subtitle {
    color: #b20000;
    font-size: 0.8em;
    margin-top: 4px;
    font-style: italic;
}

/* --- 2. HERO SECTION (BANNER) --- */
.hero-section {
    position: relative;
    height: 500px;
    /* Chiều cao banner */
    display: flex;
    align-items: center;
    /* Căn giữa theo chiều dọc */
    padding-left: 80px;
    /* Căn lề trái cho nội dung */
    overflow: hidden;
}

.hero-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("https://imgs.search.brave.com/JhUBxNegTntDBvlZnUsZUOFky8z62jX77sXkin1tjPE/rs:fit:860:0:0:0/g:ce/aHR0cHM6Ly93YWxs/cGFwZXItaG91c2Uu/Y29tL2RhdGEvb3V0/LzYvd2FsbHBhcGVy/MnlvdV8xMzA1NTQu/anBn");
    background-size: cover;
    background-position: center;
    filter: brightness(0.6);
    /* Làm tối ảnh nền để chữ nổi bật hơn */
    z-index: -1;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero-title {
    font-size: 4em;
    font-weight: 900;
    color: #fff;
    margin: 0;
    text-transform: uppercase;
    line-height: 1.1;
    font-family: 'Cinzel', serif;
}

/* Font riêng cho chữ Assassin's Creed */
.hero-title .red-text {
    font-family: 'Roboto Condensed', sans-serif;
}

.hero-subtitle {
    font-size: 1.2em;
    color: #ddd;
    margin-top: 15px;
    font-weight: normal;
    text-shadow: 1px 1px 2px #000;
    border-left: 4px solid #b20000;
    padding-left: 15px;
    font-family: 'Cormorant Garamond', serif;
    /* Font tinh tế cho subtitle */
}

/* Container chính để gom gọn nội dung game vào giữa */
.main-container {
    width: 100%;
    background-color: #000;
    margin: 0;
    padding: 40px 0;
    box-sizing: border-box;
}

/* Phần Đăng nhập / Đăng ký */
.auth-btn {
    margin-left: 10px;
    gap: 8px;
}

.auth-btn {
    padding: 6px 12px;
    border-radius: 4px;
    border: none;
    background-color: #b20000;
    /* Màu đỏ đặc trưng */
    color: white;
    cursor: pointer;
    font-weight: bold;
    font-size: 14px;
}

.auth-btn:hover {
    background-color: #800000;
}

/* CSS cho Modal (Hộp thoại) */
.modal {
    display: none;
    /* Ẩn mặc định */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    /* Nền đen mờ */
}

.modal-content {
    background-color: #1a1a1a;
    margin: 10% auto;
    padding: 30px;
    border: 1px solid #b20000;
    width: 90%;
    max-width: 400px;
    border-radius: 8px;
    color: white;
    text-align: center;
    position: relative;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 15px;
    top: 5px;
}

.close:hover,
.close:focus {
    color: white;
    text-decoration: none;
    cursor: pointer;
}

.modal-input {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    display: inline-block;
    border: 1px solid #555;
    border-radius: 4px;
    box-sizing: border-box;
    background-color: #333;
    color: white;
}

.modal-submit-btn {
    width: 100%;
    background-color: #b20000;
    color: white;
    padding: 12px 20px;
    margin: 10px 0;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
}

.modal-submit-btn:hover {
    background-color: #800000;
}

.social-login-section {
    margin-top: 20px;
    border-top: 1px solid #444;
    padding-top: 10px;
}

.social-buttons {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

/* Button chung */
.hero-buttons button,
.hero-buttons a {
    padding: 12px 24px;
    font-size: 1em;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    margin: 5px;
    transition: all 0.3s;
    font-family: 'Roboto Condensed', sans-serif;
    /* Font cho buttons */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.social-btn {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    color: white;
    font-weight: bold;
    font-size: 20px;
    font-family: 'Roboto Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.social-btn.google {
    background-color: #ffffff;
}

.social-btn.google i {
    background: linear-gradient(to right, #4285f4, #ea4335, #fbbc05, #34a853);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.social-btn.facebook {
    background-color: #4267B2;
}

.social-btn.steam {
    background-color: #171a21;
}

/* Red text styling for highlights */
.red-text {
    color: #b20000;
}

/* --- CAROUSEL / SLIDER STYLES --- */
.carousel-wrapper {
    position: relative;
    width: 100%;
    padding: 40px 60px;
    box-sizing: border-box;
    background: transparent;
    border-radius: 0;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
    border-bottom: none;
    /* Bỏ line đỏ */
    margin-bottom: 50px;
    scroll-margin-top: 100px;
    /* Tránh bị thanh menu che khuất khi cuộn tới */
}

/* Game selection title */
.game-selection-title {
    text-align: center;
    font-size: 2.5em;
    font-family: 'Bebas Neue', cursive;
    text-transform: uppercase;
    color: #fff;
    margin: 0 0 10px 0;
    letter-spacing: 2px;
}

.game-selection-subtitle {
    text-align: center;
    font-size: 1em;
    color: #ccc;
    margin: 0 0 30px 0;
    font-family: 'Cormorant Garamond', serif;
}


.carousel-container {
    overflow: hidden;
    width: 100%;
}

.carousel-track {
    display: flex;
    gap: 20px;
    padding: 20px 5px;
    margin: 0;
    list-style: none;
    transition: transform 0.5s ease-in-out;
}

.carousel-card {
    flex: 0 0 220px;
    /* Thu nhỏ chiều rộng thẻ cho gọn gàng */
    background: linear-gradient(to bottom,
            rgba(11, 21, 38, 0.95),
            rgba(6, 11, 20, 0.95));
    backdrop-filter: blur(6px);
    border: 1px solid #444;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 350px;
    /* Giảm chiều cao tối thiểu */
    transition: transform 0.3s, box-shadow 0.3s;
}

.carousel-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(178, 0, 0, 0.6);
    border-color: #b20000;
}

.card-img-container {
    width: 100%;
    height: 140px;
    /* Thu nhỏ chiều cao ảnh */
    overflow: hidden;
}

.card-img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.carousel-card:hover .card-img-container img {
    transform: scale(1.1);
}

.card-content {
    padding: 15px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-content h3 {
    margin: 0 0 10px 0;
    color: #b20000;
    font-size: 1em;
    /* Giảm cỡ chữ tiêu đề */
    height: 2.4em;
    /* Giới hạn chiều cao tiêu đề */
    overflow: hidden;
    font-family: 'Playfair Display', serif;
}

.card-content p {
    font-size: 0.85em;
    /* Giảm cỡ chữ nội dung */
    color: #ccc;
    flex: 1;
    margin-bottom: 15px;
}

.card-btn {
    display: block;
    text-align: center;
    background-color: #b20000;
    color: white;
    text-decoration: none;
    padding: 10px;
    border-radius: 4px;
    font-weight: bold;
    transition: background 0.3s;
    font-family: 'Roboto Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.card-btn:hover {
    background-color: #800000;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: #b20000;
    border: 2px solid #b20000;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-family: 'Roboto Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.carousel-btn:hover {
    background-color: #b20000;
    color: white;
}

.prev-btn {
    left: 0;
}

.next-btn {
    right: 0;
}

.details-section {
    margin-top: 0;
    /* Khoảng cách đã được xử lý bởi margin-bottom của carousel-wrapper */
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
    border-top: none;
    /* Xóa viền cũ để tránh bị trùng lặp */
    display: flex;
    gap: 50px;
    /* Tăng khoảng cách giữa phần nhiệm vụ và thông tin */
    align-items: flex-start;
    flex-wrap: wrap;
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sidebar-left,
.sidebar-right {
    flex: 1.5;
    /* Tăng tỷ lệ chiều rộng cho ô thông tin */
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #333;
    min-width: 250px;
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Ẩn hoàn toàn sidebar khi detail active */
.details-section.detail-active .sidebar-right {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    /* Không thể click khi ẩn */
}

.main-content {
    flex: 2.5;
    background: rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 10px;
    border: 1px solid #333;
}

.details-section h2,
.details-section h3 {
    color: #b20000;
    margin-top: 0;
    border-bottom: 1px solid #b20000;
    padding-bottom: 10px;
    margin-bottom: 15px;
    font-family: 'Cinzel', serif;
    /* Font cho headings */
}

.sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-left ul {
    max-height: 400px;
    /* Giới hạn chiều cao */
    overflow-y: auto;
    /* Hiện thanh cuộn khi danh sách dài */
    padding-right: 5px;
}

/* Tùy chỉnh thanh cuộn cho đẹp (Webkit browsers: Chrome, Edge, Safari) */
.sidebar-left ul::-webkit-scrollbar {
    width: 6px;
}

.sidebar-left ul::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.sidebar-left ul::-webkit-scrollbar-thumb {
    background: #b20000;
    border-radius: 3px;
}

.sidebar-left ul::-webkit-scrollbar-thumb:hover {
    background: #ff0000;
}

/* Style cho tiêu đề phân loại nhiệm vụ */
.mission-category {
    color: #b20000;
    font-weight: bold;
    margin-top: 15px;
    margin-bottom: 5px;
    border-bottom: 1px solid #444;
    padding-bottom: 2px;
    cursor: pointer;
    /* Con trỏ chuột dạng tay */
    user-select: none;
    /* Không cho bôi đen text khi click nhanh */
    transition: color 0.3s;
}

.mission-category:hover {
    color: #ff0000;
}

/* Danh sách con (ẩn mặc định) */
.mission-sublist {
    display: none;
    padding-left: 15px !important;
    /* Thụt đầu dòng */
    border-left: 2px solid #333;
    margin-bottom: 10px !important;
}

/* Class để hiện danh sách */
.mission-sublist.active {
    display: block;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sidebar-list li {
    margin-bottom: 8px;
}

.sidebar-list a {
    color: #fff;
    text-decoration: none;
    display: block;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    transition: background 0.3s, padding-left 0.3s;
    font-size: 0.9em;
}

.sidebar-list a:hover {
    background: #b20000;
    padding-left: 12px;
}

.info-item {
    margin-bottom: 12px;
    border-bottom: 1px solid #444;
    padding-bottom: 8px;
}

.info-label {
    display: block;
    color: #aaa;
    font-size: 0.85em;
}

.info-value {
    display: block;
    font-weight: bold;
    color: #fff;
}

@media (max-width: 1024px) {
    .details-section {
        flex-direction: column;
    }

    .sidebar-left,
    .sidebar-right,
    .main-content {
        width: 100%;
        flex: none;
    }
}

.footer {
    background: radial-gradient(ellipse at center,
            #0b1526 0%,
            #060b14 45%,
            #03060c 100%);
    color: #ccc;
    padding: 50px 20px 20px;
    font-family: Arial, sans-serif;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: auto;
}

.footer h3 {
    color: #fff;
    margin-bottom: 15px;
}

.footer p {
    font-size: 14px;
    line-height: 1.6;
}

.logo {
    color: red;
    font-weight: bold;
}

.logo span {
    color: white;
}

.footer ul {
    list-style: none;
    padding: 0;
}

.footer ul li {
    margin-bottom: 10px;
}

.footer ul li a {
    color: #aaa;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer ul li a:hover {
    color: #fff;
}

/* Social icons */
.social-icons {
    margin-top: 15px;
}

.social-icons a {
    color: #aaa;
    margin-right: 12px;
    font-size: 18px;
    transition: color 0.3s, transform 0.3s;
}

.social-icons a:hover {
    color: rgb(247, 247, 247);
    transform: scale(1.2);
}

/* Bottom */
.footer-bottom {
    border-top: 1px solid #222;
    margin-top: 40px;
    padding-top: 15px;
    text-align: center;
    font-size: 13px;
    color: #777;
}

/* --- MISSION & WEAPON SECTION --- */
.mw-integrated-section {
    flex: 3;
    background: transparent;
    padding: 0;
    border: none;
    min-height: 400px;
    text-align: center;
    /* Căn giữa để tiêu đề inline-block nằm giữa */
}

.mw-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.mw-tab-btn {
    background: transparent;
    border: 1px solid #444;
    color: #aaa;
    padding: 10px 30px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    border-radius: 30px;
    transition: all 0.3s;
    font-family: 'Roboto Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.mw-tab-btn:hover,
.mw-tab-btn.active {
    border-color: #b20000;
    background-color: #b20000;
    color: white;
    box-shadow: 0 0 15px rgba(178, 0, 0, 0.4);
}

/* Ẩn tab nếu cần (dùng cho logic ẩn vũ khí) */
.mw-tab-btn.hidden {
    display: none !important;
}

.mw-content {
    display: none;
    /* Ẩn mặc định */
    animation: fadeIn 0.5s ease-in-out;
}

.mw-content.active {
    display: block;
    /* Hiện khi được chọn */
}

/* Wrapper cho layout 3 cột */
.mw-grid-wrapper {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 20px;
    position: relative;
    min-height: 500px;
    max-width: 1400px;
    /* Giới hạn chiều rộng */
    margin: 0 auto;
    /* Căn giữa */
    width: 100%;
}

/* Cột trái và phải */
.mw-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
    flex: 0 0 280px;
    /* Width cố định cho mỗi cột */
    transition: transform 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Khi detail active - đẩy cards ra 2 bên cân đối */
.mw-grid-wrapper.detail-active .mw-grid:first-child {
    transform: translateX(-400px);
    /* Cột trái sang trái 400px */
}

.mw-grid-wrapper.detail-active .mw-grid:last-child {
    transform: translateX(400px);
    /* Cột phải sang phải 400px */
}

.mw-card {
    background: linear-gradient(135deg, #1a2332 0%, #0f1621 100%);
    border: 1px solid rgba(178, 0, 0, 0.3);
    border-radius: 12px;
    padding: 20px 25px 25px 25px;
    min-height: 200px;
    position: relative;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: visible;
    z-index: 1;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

/* Class highlight khi search */
.mw-card.highlight {
    border-color: #fff;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
    animation: pulse 1s infinite alternate;
}

.mw-card:hover {
    transform: translateY(-5px);
    border-color: rgba(178, 0, 0, 0.6);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.7), 0 0 30px rgba(178, 0, 0, 0.3);
    background: linear-gradient(135deg, #1f2a3d 0%, #121926 100%);
}

@keyframes pulse {
    from {
        box-shadow: 0 0 10px rgba(178, 0, 0, 0.5);
    }

    to {
        box-shadow: 0 0 25px rgba(178, 0, 0, 1);
    }
}

.mw-badge {
    position: absolute;
    top: -12px;
    font-size: 0.7em;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: bold;
    color: #fff;
    background: #b20000;
    border: 2px solid #ff0000;
    padding: 6px 14px;
    border-radius: 20px;
    box-shadow: 0 2px 10px rgba(178, 0, 0, 0.5);
}

/* Badge game ở bên trái */
.mw-badge.game-badge {
    left: 15px;
    background: #b20000;
    border-color: #ff0000;
}

/* Badge độ khó ở bên phải - Màu mặc định */
.mw-badge.difficulty-badge {
    right: 15px;
    background: #ff8800;
    border-color: #ffaa00;
}

/* === MÀU SẮC THEO ĐỘ KHÓ (NHIỆM VỤ) === */
/* Dễ - Xanh lá cây */
.mw-badge.diff-easy {
    background: #22c55e;
    border-color: #4ade80;
}

/* Trung bình - Xanh dương */
.mw-badge.diff-medium {
    background: #3b82f6;
    border-color: #60a5fa;
}

/* Khó - Cam đậm */
.mw-badge.diff-hard {
    background: #ea580c;
    border-color: #f97316;
}

/* Cực khó - Đỏ */
.mw-badge.diff-extreme {
    background: #dc2626;
    border-color: #ef4444;
}

/* === MÀU SẮC THEO ĐỘ HIẾM (VŨ KHÍ) === */
/* Hiếm - Xanh dương */
.mw-badge.rarity-rare {
    background: #3b82f6;
    border-color: #60a5fa;
}

/* Huyền thoại - Vàng */
.mw-badge.rarity-legendary {
    background: #eab308;
    border-color: #fbbf24;
}

/* Sử thi - Tím */
.mw-badge.rarity-epic {
    background: #a855f7;
    border-color: #c084fc;
}

/* Thần thoại - Đỏ sẫm/hồng */
.mw-badge.rarity-mythical {
    background: #be123c;
    border-color: #fb7185;
}

.mw-title {
    color: #fff;
    margin: 25px 0 20px 0;
    font-size: 1.3em;
    font-weight: bold;
    font-family: 'Cinzel', serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.4;
}

/* Style riêng cho tiêu đề game để line gạch chân chỉ dài bằng chữ */
#selected-game-title {
    display: inline-block;
    /* Để độ rộng bằng nội dung chữ */
    border-bottom: 3px solid #b20000;
    /* Line ngăn cách */
    padding-bottom: 15px;
    margin-bottom: 30px;
}

.mw-subtitle {
    color: #888;
    font-size: 0.85em;
    margin: 0;
    font-style: italic;
}

.mw-reward {
    margin-top: 12px;
    font-size: 0.85em;
    color: #ccc;
    display: flex;
    align-items: center;
    gap: 8px;
}

.mw-reward::before {
    content: '🎁';
    font-size: 1.1em;
}

.mw-reward span {
    color: #ffd700;
    font-weight: bold;
}

/* Vị trí vũ khí */
.mw-location {
    margin-top: 12px;
    font-size: 0.85em;
    color: #ccc;
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
}

.mw-location::before {
    content: '📍';
    font-size: 1.1em;
    margin-right: 5px;
}

/* Yêu cầu */
.mw-requirement {
    margin-top: 8px;
    font-size: 0.85em;
    color: #ff6b6b;
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
}

.mw-requirement::before {
    content: '⭕';
    font-size: 1.1em;
    margin-right: 5px;
}

/* Nút hành động */
.mw-action-btn {
    display: block;
    width: 100%;
    margin-top: 20px;
    padding: 12px;
    background: #b20000;
    color: #fff;
    text-align: center;
    text-transform: uppercase;
    font-weight: bold;
    font-size: 0.85em;
    letter-spacing: 1px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 10px rgba(178, 0, 0, 0.3);
}

.mw-action-btn:hover {
    background: #d40000;
    box-shadow: 0 6px 15px rgba(178, 0, 0, 0.5);
    transform: translateY(-2px);
}

@media (max-width: 600px) {
    .mw-grid {
        grid-template-columns: 1fr;
    }
}

/* --- DETAIL PANEL STYLES --- */
.detail-panel {
    background: linear-gradient(160deg, #1a1a1a 0%, #0a0a0a 100%);
    border: 2px solid #b20000;
    border-radius: 10px;
    padding: 0;
    min-height: 0;
    max-height: 80vh;
    overflow-y: auto;

    /* Positioning ở giữa wrapper */
    position: absolute;
    left: 50%;
    top: 0;
    transform: translateX(-50%) scaleX(0);

    width: 0;
    max-width: 1000px;
    /* Giới hạn tối đa */
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(178, 0, 0, 0.3);
    z-index: 100;
}

.detail-panel.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) scaleX(1);
    width: 80%;
    /* Chiếm 80% chiều rộng của wrapper */
    min-width: 600px;
    /* Tối thiểu 600px */
    padding: 40px;
    overflow-y: auto;
}

/* Xóa placeholder style vì panel hoàn toàn ẩn */
.detail-panel.placeholder {
    display: flex;
    opacity: 0;
    visibility: hidden;
    width: 0;
}

.detail-panel.placeholder .detail-content {
    text-align: center;
    color: #666;
}

.close-detail-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 2em;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
    font-family: 'Roboto Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.close-detail-btn:hover {
    background: rgba(178, 0, 0, 0.2);
    color: #b20000;
    transform: rotate(90deg);
}

.close-detail-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 2em;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
    font-family: 'Roboto Condensed', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.close-detail-btn:hover {
    background: rgba(178, 0, 0, 0.2);
    color: #b20000;
    transform: rotate(90deg);
}

.detail-content h3 {
    color: #b20000;
    font-size: 2.2em;
    /* Font lớn hơn cho title */
    margin: 0 0 15px 0;
    border-bottom: 2px solid #b20000;
    padding-bottom: 15px;
    line-height: 1.3;
    font-family: 'Cinzel', serif;
    /* Font heading cho detail */
}

.detail-game-name {
    color: #888;
    font-style: italic;
    margin: 0 0 25px 0;
    font-size: 1.1em;
    font-family: 'Cormorant Garamond', serif;
    /* Font đặc biệt */
}

.detail-info-content {
    color: #ccc;
    line-height: 1.8;
}

.detail-info-content .info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    /* Padding lớn hơn */
    border-bottom: 1px dashed #333;
    gap: 20px;
}

.detail-info-content .info-row:last-child {
    border-bottom: none;
}

.detail-info-content .info-label {
    color: #aaa;
    font-weight: normal;
    font-size: 1.05em;
    flex-shrink: 0;
}

.detail-info-content .info-value {
    color: #fff;
    font-weight: bold;
    font-size: 1.1em;
    text-align: right;
}

/* --- CARD ANIMATION WHEN CLICKED --- */
.mw-card.active {
    border-color: #b20000;
    box-shadow: 0 5px 20px rgba(178, 0, 0, 0.5);
    transform: scale(1.02);
}

.mw-card {
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

@media (max-width: 1024px) {
    .mw-grid-wrapper {
        flex-direction: column;
        align-items: center;
    }

    .mw-grid {
        flex: 1 1 auto;
        width: 100%;
        max-width: 500px;
    }

    .mw-grid-wrapper.detail-active .mw-grid:first-child,
    .mw-grid-wrapper.detail-active .mw-grid:last-child {
        transform: none;
        /* Không đẩy ra ngoài trên mobile */
    }

    .detail-panel {
        position: relative;
        left: auto;
        transform: none;
        max-height: none;
        width: 100% !important;
        max-width: 100%;
    }

    .detail-panel.show {
        transform: none;
    }

    .detail-content h3 {
        font-size: 1.8em;
    }
}

@media (max-width: 768px) {
    .detail-panel {
        min-width: 90%;
        max-width: 90%;
        padding: 20px;
    }

    .mw-grid.has-active {
        grid-template-columns: 1fr;
    }

    .mw-card.active {
        transform: translateX(0) scale(0.98);
    }
}