/* --- Ggiao diện Tabs (PHIÊN BẢN MỚI) --- */
.okvip-livestream-container {
    width: 100%;
    margin: 0 auto;
}
.okvip-tab-nav {
    margin-bottom: 25px;
    border-bottom: 1px solid #3a3a3a; /* Đường gạch chân mờ bên dưới */
    padding-bottom: 15px;
}
.tab-link {
    padding: 10px 25px; /* Tăng padding cho to hơn */
    cursor: pointer;
    text-decoration: none;
    font-weight: bold;
    border-radius: 10px; /* Bo góc */
    transition: all 0.2s ease;
    background-color: transparent;
    border: 2px solid #4CAF50; /* Viền xanh lá */
    color: #fff;
	margin-right :7px;
}
.tab-link:not(.active):hover, .tab-link.active {
    text-decoration: none;
    border-radius: 10px;
    background: linear-gradient(90deg, #ff1744, #ff8417);
    color: #fff9f9;
    box-shadow: 0 4px 15px rgba(76, 175, 80, .4);
    transition: transform .2s, box-shadow .2s;
    border: none;
    cursor: pointer;
}

/* --- Giao diện Content của Tab --- */
.tab-pane {
    display: none; /* Ẩn tất cả các tab */
}
.tab-pane.active {
    display: block; /* Hiện tab đang active */
}
.okvip-match-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
    font-family: Arial, sans-serif;
}
.no-matches-notice {
    color: #888;
    text-align: center;
    padding: 20px;
}

/* --- Giao diện Match Card (Dark Mode) --- */
.okvip-match-card {
    background: #0f30119e;
    border-radius: 12px;
    padding: 15px;
    text-decoration: none;
    color: #fff; /* Màu chữ trắng */
    border: 1px solid #3a3a3a;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    transition: transform 0.2s, border-color 0.2s;
}
.okvip-match-card:hover {
    transform: translateY(-5px);
    border-color: #4CAF50;
}
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #aaa;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #3a3a3a;
}
.header-right { display: flex; align-items: center; gap: 10px; }
.view-count { display: flex; align-items: center; gap: 4px; }
.view-count svg { fill: #aaa; }
.live-badge {
    background-color: #e53935; /* Màu đỏ cho Live */
    color: #fff;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 5px;
    font-size: 10px;
}
.card-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.card-body .team {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 35%;
    text-align: center;
    gap: 8px;
}
.card-body .team img { width: 40px; height: 40px; }
.card-body .team span { font-weight: bold; font-size: 14px; }
.score-container { text-align: center; }
.score-container .match-time { font-size: 12px; color: #e53935; font-weight: bold; margin-bottom: 5px; display: block; }
.score-container .score-box {
    font-size: 24px;
    font-weight: bold;
    background-color: #4CAF50; /* Màu xanh lá cho tỷ số */
    color: #fff;
    padding: 5px 15px;
    border-radius: 8px;
}
.card-footer { margin-top: 12px; }
.commentators-list { display: flex; align-items: center; gap: 5px; }
.commentators-list img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid #555;
}


/* --- Giao diện Khung Mô phỏng --- */
.simulation-section {
    margin-top: 30px;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
}
.simulation-section h2 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.5rem;
    color: #333;
}

/* Kỹ thuật làm iframe responsive */
.simulation-wrapper {
    position: relative;
    padding-top: 75%; /* Tỷ lệ khung hình 4:3, có thể đổi thành 56.25% cho 16:9 */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
}
.simulation-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}



/* ====================================================== */
/* --- Giao diện Shortcode [list_math_live] (MỚI) --- */
/* ====================================================== */

.okvip-live-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    background-color: #4caf5045;
    color: #fff;
    font-family: Arial, sans-serif;
    padding: 20px;
    border-radius: 12px;
}

/* --- Cột Trái (Main View) --- */
.live-main-view {
    flex: 3;
    min-width: 300px;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);/
    width: 100%;
    text-align: center;
    background-image: linear-gradient(rgb(0 0 0 / 62%), rgb(0 0 0)), url(/wp-content/uploads/2025/11/play-home.gif);
    background-size: cover;
    background-position: center;
    color: #fff;
    z-index: 5;
    transition: opacity .3s 
ease;
}



.live-main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #aaa;
    font-size: 14px;
    padding-bottom: 15px;
    border-bottom: 1px solid #3a3a3a;
}
.live-main-header .view-count { display: flex; align-items: center; gap: 4px; }
.live-main-header .live-badge {
    background-color: #e53935;
    color: #fff;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 5px;
    font-size: 10px;
}
.live-main-body {
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 40px 10px;
    text-align: center;
}
.live-main-body .team {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    width: 30%;
}
.live-main-body .team img { width: 80px; height: 80px; }
.live-main-body .team span { font-size: 1.2rem; font-weight: bold; }
.score-box-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}
#live-main-status-badge {
    background-color: #f3c23e; /* Màu vàng */
    color: #000;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: bold;
    border-radius: 5px;
}
#live-main-score {
    font-size: 2.5rem;
    font-weight: bold;
    color: #4CAF50; /* Màu xanh lá */
    background-color: rgba(76, 175, 80, 0.1);
    padding: 10px 20px;
    border-radius: 10px;
}
.live-main-button {
    display: block;
    width: 200px;
    margin: 20px auto 30px auto;
    padding: 15px 20px;
    background: linear-gradient(90deg, #e53935, #f57c00);
    color: #fff;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: bold;
    text-align: center;
    border-radius: 30px;
    transition: transform 0.2s, box-shadow 0.2s;
}
.live-main-button:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(230, 81, 0, 0.4);
}
.live-main-commentators {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    padding-top: 20px;
    border-top: 1px solid #3a3a3a;
}
.caster-item-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #aaa;
    font-size: 13px;
}
.caster-item-main img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: 3px solid #555; /* Viền xám */
    transition: border-color 0.2s;
}
.caster-item-main:hover img {
    border-color: #4CAF50; /* Đổi viền khi hover */
}

/* ====================================================== */
/* --- CSS MỚI: Sửa lỗi hiển thị [list_math_live_z] sidebar --- */
/* ====================================================== */

/* Ẩn cấu trúc HTML cũ (phòng trường hợp cache) */
.live-sidebar-item-z .sidebar-item-team,
.live-sidebar-item-z .sidebar-item-score {
    display: none;
}

/* 1. Định dạng thẻ <a> (item cha) */
.live-sidebar-item-z {
    display: block; /* Chuyển sang block để chứa layout mới */
    padding: 12px 10px;
    border-radius: 8px;
    text-decoration: none;
    color: #ddd;
    margin-bottom: 8px;
    border: 2px solid transparent;
    transition: background-color 0.2s, border-color 0.2s;
}
.live-sidebar-item-z:hover {
    background-color: #2a2a2a;
}
.live-sidebar-item-z.active {
    background-color: rgba(76, 175, 80, 0.1);
    border-color: #4CAF50;
}

/* 2. Định dạng layout mới (2 hàng dọc) */
.sidebar-new-layout {
    display: flex;
    flex-direction: column;
    gap: 5px; /* Khoảng cách giữa 2 đội */
}

/* 3. Định dạng mỗi hàng (đội) */
.sidebar-new-team {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #eee;
}

/* 4. Logo (đảm bảo nó lấy đúng style) */
.sidebar-new-team .team-logo-sidebar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #3a3a3a;
}

/* 5. Tỷ số (đẩy ra lề phải) */
.sidebar-new-team .score {
    margin-left: auto; /* Đây là mấu chốt */
    font-size: 14px;
    font-weight: bold;
    color: #fff;
}

/* 6. Phút (căn lề thẳng hàng với tên) */
.sidebar-new-layout .minute {
    font-size: 11px;
    color: #e53935; /* Màu đỏ live */
    font-weight: bold;
    padding-left: 28px; /* = 20px (logo) + 8px (gap) */
}



/* --- Cột Phải (Sidebar) --- */
.live-sidebar {
    flex: 1; /* Chiếm 1/4 không gian */
    min-width: 280px;
    background-color: #1a1a1a;
    border-radius: 12px;
    padding: 15px;
    max-height: 800px; /* Giới hạn chiều cao */
}
.live-sidebar h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1rem;
    color: #fff;
    padding-bottom: 10px;
    border-bottom: 2px solid #4CAF50;
}
.live-sidebar-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px;
    max-height: 430px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #4caf50 #111812;
}
/* CSS cho thanh cuộn */
.live-sidebar-list::-webkit-scrollbar { width: 6px; }
.live-sidebar-list::-webkit-scrollbar-track { background: #333; border-radius: 3px;}
.live-sidebar-list::-webkit-scrollbar-thumb { background: #555; border-radius: 3px;}
.live-sidebar-list::-webkit-scrollbar-thumb:hover { background: #777; }

.live-sidebar-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 10px;
    border-radius: 8px;
    text-decoration: none;
    color: #ddd;
    margin-bottom: 8px;
    border: 2px solid transparent;
    transition: background-color 0.2s, border-color 0.2s;
}
.live-sidebar-item:hover {
    background-color: #2a2a2a;
}
.live-sidebar-item.active {
    background-color: rgba(76, 175, 80, 0.1);
    border-color: #4CAF50;
}
.sidebar-item-team { display: flex; align-items: center; gap: 8px; width: 40%; font-size: 13px; }
.sidebar-item-team img { width: 20px; height: 20px; }
.sidebar-item-team.away { justify-content: flex-end; text-align: right; }
.sidebar-item-score { text-align: center; width: 20%; font-size: 14px; font-weight: bold; }
.sidebar-item-score small { font-size: 11px; color: #e53935; display: block; }

/* ====================================================== */
/* --- Giao diện [chi_tiet_tran_dau] (PHIÊN BẢN MỚI) --- */
/* ====================================================== */

.okvip-detail-page-wrapper {
    max-width: 1200px;
    margin: 20px auto;
    font-family: Arial, sans-serif;
    color: #fff;
    background-color: #1f1f1f; /* Nền tối */
    border: 1px solid #3a3a3a;
    border-radius: 12px;
    overflow: hidden;
}

/* --- Phần 1: Video Player --- */
.detail-video-container {
    background-color: #1a1a1a;
    padding: 20px;
}
h1.detail-main-title {
    font-size: 1.5rem;
    color: #4CAF50;
    text-align: left;
    margin-top: 0;
    margin-bottom: 20px;
    background: url(/wp-content/uploads/2025/11/heading-pc2.webp) no-repeat;
    padding: 9px 25px 9px 100px;
    background-position: -85px;
    background-color: #1b8802;
    text-transform: uppercase;	
}
.detail-scoreboard {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #111;
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 15px;
}
.detail-scoreboard .team-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px ;
    font-weight: bold;
    width: 40%;
}
.detail-scoreboard .team-info.away {
    justify-content: flex-end;
}
.detail-scoreboard .team-info img {
    width: 80px;
    height: 80px;
}
.match-score-info {
    text-align: center;
}
.match-score-info .score {
    font-size: 2rem;
    font-weight: bold;
    color: #fff;
    background-color: #298604;
    padding: 6px 20px;
    border-radius: 10px;
}
.match-score-info .minute {
    font-size: 18px;
    color: #e53935; /* Màu đỏ live */
    font-weight: bold;
    display: block;
}
.video-section {
    background-color: #000;
    position: relative; /* Cần cho video-overlay */
}
#video-player {
    width: 100%;
    aspect-ratio: 16/9;
    display: block;
}
.video-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2em;
    text-align: center;
    padding: 20px;
}

/* Danh sách BLV bên dưới video */
.detail-page-casters {
    padding: 15px 0;
    border-top: 1px solid #3a3a3a;
    margin-top: 15px;
}
.detail-page-casters .commentator-list-detail.interactive {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}
.detail-page-casters .caster-item-link {
    text-decoration: none;
    border: 2px solid transparent;
    border-radius: 12px;
    transition: all 0.2s ease;
    display: block;
}
.detail-page-casters .caster-item-link:hover {
    border-color: #555;
}
.detail-page-casters .caster-item-link.active {
    border-color: #4CAF50;
    background-color: #2a2a2a;
}
.detail-page-casters .caster-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 10px;
    min-width: 80px;
}
.detail-page-casters .caster-item img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
}
.detail-page-casters .caster-item span {
    color: #ddd;
    font-size: 14px;
}


/* --- Phần 2: Layout 2 Cột (Mô phỏng + Trận khác) --- */
.detail-bottom-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 20px;
    background-color: #1f1f1f;
}
.bottom-layout-title {
    font-size: 1.2rem;
    color: #fff;
    padding-bottom: 10px;
    border-bottom: 2px solid #4CAF50;
    margin-top: 0;
    margin-bottom: 15px;
}

/* Cột trái: Mô phỏng */
.detail-sim-col {
    flex: 3;
    min-width: 300px;
}
.simulation-wrapper {
    position: relative;
    padding-top: 75%; /* Tỷ lệ 4:3 */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid #3a3a3a;
}
.simulation-wrapper iframe {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border: 0;
}

/* Cột phải: Các trận khác */
.detail-sidebar-col {
    flex: 1;
    min-width: 280px;
}
.sidebar-match-list {
    max-height: 500px; /* Giới hạn chiều cao và cho phép cuộn */
    overflow-y: auto;
    padding-right: 5px;
}
/* CSS cho thanh cuộn */
.sidebar-match-list::-webkit-scrollbar { width: 6px; }
.sidebar-match-list::-webkit-scrollbar-track { background: #333; border-radius: 3px;}
.sidebar-match-list::-webkit-scrollbar-thumb { background: #555; border-radius: 3px;}

.sidebar-match-item {
    display: block;
    background-color: #2a2a2a;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 10px;
    text-decoration: none;
    color: #ddd;
    border: 1px solid #3a3a3a;
    transition: background-color 0.2s;
}
.sidebar-match-item:hover {
    background-color: #3a3a3a;
}
.match-item-header {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #aaa;
    margin-bottom: 10px;
}
.match-item-header .league { font-weight: bold; }
.match-item-header .time { color: #e53935; font-weight: bold; }
.match-item-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    font-weight: bold;
}
.match-item-body .team { display: flex; align-items: center; gap: 6px; width: 40%; }
.match-item-body .team img { width: 18px; height: 18px; }
.match-item-body .team.away { justify-content: flex-end; text-align: right; }
.match-item-body .score { font-size: 14px; color: #4CAF50; width: 20%; text-align: center; }




/* --- CSS MỚI: Định dạng Logo cho API_Z --- */
.okvip-match-card .team-logo-list {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #3a3a3a; /* Màu nền nếu ảnh trong suốt */
}
.live-sidebar-item-z .team-logo-sidebar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #3a3a3a;
}
.live-main-body .team-logo-main {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: #3a3a3a;
}
/* CSS cho placeholder (phòng trường hợp API không có ID) */
.team-logo-placeholder { width: 40px; height: 40px; background-color: #3a3a3a; border-radius: 50%; }
.team-logo-placeholder-sidebar { width: 20px; height: 20px; background-color: #3a3a3a; border-radius: 50%; }
.team-logo-placeholder-main { width: 80px; height: 80px; background-color: #3a3a3a; border-radius: 50%; }