/* Ultra Lightweight CSS - Sederhana tapi Modern */
html,
body {
    margin: 0;
    height: 100%;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    color: white;
    font-family: 'Teko', sans-serif;
}

#main-content {
    display: flex;
    width: 100%;
    height: 100%;
}

.video-container {
    flex: 1;
    background-color: #000;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
}

.video-wrapper iframe,
.video-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#single-view::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.58);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 4;
}

#single-view.countdown-active::after {
    opacity: 1;
}

#player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: black;
    display: none;
}

.home-ad-gate {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 12vh;
    box-sizing: border-box;
    background: rgba(0, 0, 0, 0.25);
    cursor: pointer;
}

.home-ad-gate-close {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border: 2px solid #fff;
    border-radius: 4px;
    background: #ef233c;
    color: #fff;
    font: 700 13px/1 Arial, sans-serif;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 3px 12px rgba(239, 35, 60, 0.55);
}

.home-ad-gate-icon {
    padding: 3px 4px;
    border-radius: 2px;
    background: #fff;
    color: #ef233c;
    font-size: 9px;
    line-height: 1;
}

.home-ad-gate-x {
    font-size: 21px;
    font-weight: 400;
    line-height: 12px;
}

.home-ad-gate-close:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 3px;
}

.home-ad-gate-close:active {
    transform: scale(0.94);
}
/* ===== CHANNEL CARD - Simple but Modern ===== */
.channel-container {
    display: flex;
    align-items: center;
    background: rgba(15, 23, 42, 0.95);
    padding: 10px;
    border-radius: 4px;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 2px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    transition: all 0.2s ease;
}

.channel-container.selected {
    background: rgba(20, 30, 55, 0.95);
}

@media (hover: hover) and (pointer: fine) {
    .channel-container:hover {
        background: rgba(20, 30, 55, 0.95);
    }
}

.logo-container {
    flex-shrink: 0;
    width: 80px;
    height: 55px;
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.logo {
    max-width: 100%;
    max-height: 100%;
}

.info-container {
    margin-left: 10px;
}

.channel-name {
    margin: 0;
    font-size: 16px;
    font-weight: bold;
    color: white;
}

.status {
    margin: 0;
    font-size: 14px;
    color: #f87171;
}

#countdown.countdown-wrapper {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    width: min(330px, calc(100% - 34px));
    box-sizing: border-box;
    text-align: center;
    background:
        linear-gradient(180deg, rgba(15, 23, 42, 0.84), rgba(2, 6, 23, 0.96)),
        radial-gradient(circle at 50% -10%, rgba(34, 211, 238, 0.24), transparent 56%),
        radial-gradient(circle at 10% 100%, rgba(255, 0, 113, 0.11), transparent 46%);
    padding: 9px;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow:
        0 24px 74px rgba(0, 0, 0, 0.66),
        0 0 0 1px rgba(34, 211, 238, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.07),
        inset 0 -1px 0 rgba(34, 211, 238, 0.11);
    z-index: 5;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

#countdown.countdown-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #22d3ee, #38bdf8, #ff0071, transparent);
    opacity: 0.95;
}

#countdown.countdown-wrapper::after {
    content: '';
    position: absolute;
    inset: 1px;
    border-radius: 11px;
    border: 1px solid rgba(255, 255, 255, 0.045);
    pointer-events: none;
}

#countdown .countdown-title {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 18px;
    margin: 0 0 8px;
    color: rgba(226, 232, 240, 0.78);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

#countdown .countdown-title::before,
#countdown .countdown-title::after {
    content: '';
    flex: 1;
    height: 1px;
    max-width: 64px;
    background: linear-gradient(90deg, transparent, rgba(34, 211, 238, 0.45));
}

#countdown .countdown-title::before {
    margin-right: 8px;
}

#countdown .countdown-title::after {
    margin-left: 8px;
    transform: scaleX(-1);
}

#countdown .countdown-event-info {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    margin-bottom: 9px;
}

#countdown .countdown-team {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

#countdown .countdown-logo-box {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
    box-sizing: border-box;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.58);
    border: 1px solid rgba(148, 163, 184, 0.18);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.26);
}

#countdown .countdown-logo-box img {
    position: static;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

#countdown .countdown-team span {
    max-width: 100%;
    color: #f8fafc;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: center;
    letter-spacing: 0.1px;
}

#countdown .countdown-vs {
    width: auto;
    height: auto;
    padding: 0 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0;
    color: #e0f2fe;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.8px;
    background: transparent;
    border: 0;
    box-shadow: none;
}

#countdown .countdown-timer {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 5px;
    position: relative;
    z-index: 2;
}

#countdown .time-unit {
    min-width: 0;
    padding: 6px 4px 5px;
    border-radius: 8px;
    background:
        linear-gradient(180deg, rgba(15, 23, 42, 0.9), rgba(2, 6, 23, 0.96));
    border: 1px solid rgba(148, 163, 184, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 8px 18px rgba(0, 0, 0, 0.24);
}

#countdown .time-unit strong {
    display: block;
    color: #f8fafc;
    font-size: 24px;
    font-weight: 700;
    line-height: 0.95;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 18px rgba(34, 211, 238, 0.28);
}

#countdown .time-unit span {
    display: block;
    margin-top: 5px;
    color: rgba(148, 163, 184, 0.78);
    font-size: 9px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.event-container .countdown-wrapper {
    position: static;
    transform: none;
    width: auto;
    color: inherit;
    font-size: inherit;
    text-align: center;
    background: transparent;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
    z-index: auto;
}

.sidebar {
    flex: 0 0 400px;
    background: linear-gradient(180deg, #020617 0%, #0f172a 100%);
    padding: 0;
    overflow-y: auto;
    overflow-x: hidden;
    height: 100vh;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

/* ========== MENU TOP - KATEGORI HORIZONTAL SCROLL ========== */
.menu-wrapper-top {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
    padding: 4px;
    border-bottom: 1px solid rgba(255, 0, 113, 0.48);
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    box-sizing: border-box;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

.category-scroll-container {
    display: flex;
    align-items: stretch;
    position: relative;
    width: 100%;
    gap: 4px;
    padding: 2px;
    box-sizing: border-box;
    border-radius: 6px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.1);
}

/* Live Event Button - FREEZE di kiri dengan LEBAR SAMA */
.category-freeze {
    flex: 0 0 auto;
    width: 120px;
    box-sizing: border-box;
    background: transparent;
    color: rgba(203, 213, 225, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 5px;
    padding: 9px 8px;
    font-family: 'Teko', sans-serif;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    position: relative;
}

.category-freeze:hover {
    background: rgba(148, 163, 184, 0.1);
    color: #fff;
    border-color: rgba(34, 211, 238, 0.28);
}

.category-freeze.active {
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.96), rgba(15, 23, 42, 0.96));
    color: #fff;
    box-shadow:
        inset 0 0 0 1px rgba(34, 211, 238, 0.24),
        0 8px 18px rgba(0, 0, 0, 0.18);
    border-color: rgba(34, 211, 238, 0.34);
}

.category-freeze::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, #22d3ee, #ff0071);
    transition: width 0.2s ease;
}

.category-freeze.active::after {
    width: 55%;
}

.live-indicator {
    font-size: 8px;
    color: #ff0545;
    animation: pulse-live 1.5s ease-in-out infinite;
}

@keyframes pulse-live {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* ========== ARROW BUTTONS (Tidak ikut scroll) ========== */
.fas {
    font-weight: 900 !important;
    display: inline-block;
}

.category-arrow-btn {
    flex: 0 0 auto;
    width: 36px;
    background: rgba(15, 23, 42, 0.88);
    color: rgba(34, 211, 238, 0.82);
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.category-arrow-btn:hover {
    background: rgba(30, 41, 59, 0.96);
    color: #ff0071;
    border-color: rgba(255, 0, 113, 0.28);
}

.category-arrow-btn:active {
    transform: scale(0.95);
}

/* Hide arrows if not needed */
.category-arrow-btn.hidden {
    display: none;
}

/* Scroll Wrapper - Area yang bisa di-scroll TANPA SCROLLBAR */
.category-scroll-wrapper {
    flex: 1;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    display: flex;
    padding: 0 2px;
    
    /* Hide scrollbar - ALL BROWSERS */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

/* Hide scrollbar completely */
.category-scroll-wrapper::-webkit-scrollbar {
    display: none;
}

.category-scroll-wrapper {
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
}

/* Container untuk button kategori */
.category-buttons-container {
    display: flex;
    gap: 4px;
    min-width: 100%;
    flex: 1;
}

/* Category Button - FLEX BAGI RATA */
.category-button {
    flex: 1;
    min-width: 120px;
    background: transparent;
    color: rgba(203, 213, 225, 0.86);
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 5px;
    padding: 9px 8px;
    font-family: 'Teko', sans-serif;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
    white-space: nowrap;
    position: relative;
}

.category-button::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, #22d3ee, #ff0071);
    transition: width 0.2s ease;
}

.category-button:hover {
    background: rgba(148, 163, 184, 0.1);
    color: #fff;
    border-color: rgba(34, 211, 238, 0.28);
}

.category-button:hover::after {
    width: 55%;
}

.category-button.active {
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.96), rgba(15, 23, 42, 0.96));
    color: #fff;
    box-shadow:
        inset 0 0 0 1px rgba(34, 211, 238, 0.24),
        0 8px 18px rgba(0, 0, 0, 0.18);
    border-color: rgba(34, 211, 238, 0.34);
}

.category-button.active::after {
    width: 55%;
}

.category-img-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    margin-right: 8px;
    vertical-align: middle;
    margin-top: -2px;
    
    opacity: 0.8;
    transition: opacity 0.2s ease;
}


.category-button[data-category="hot"] i {
    margin-right: 8px;
    font-size: 14px;
    width: 16px;
    text-align: center;
    
    opacity: 0.9;
    transition: opacity 0.2s ease;
}

.category-button:hover .category-img-icon,
.category-button.active .category-img-icon,
.category-button:hover i,
.category-button.active i {
    opacity: 1;
    filter: none;
    transform: none;
}

/* ========== MENU BOTTOM - UPDATED 4 BUTTONS ========== */
.menu-wrapper-bottom {
    position: sticky;
    bottom: 0;
    z-index: 100;
    padding: 4px;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.88), rgba(15, 23, 42, 0.98));
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    box-shadow: 0 -10px 28px rgba(0, 0, 0, 0.28);
    box-sizing: border-box;
}

.menu-wrapper-bottom .menu-container {
    display: flex;
    width: 100%;
    margin: 0;
    padding: 2px;
    gap: 4px;
    box-sizing: border-box;
    border-radius: 6px;
    background: rgba(2, 6, 23, 0.42);
    border: 1px solid rgba(148, 163, 184, 0.08);
}

.menu-wrapper-bottom .menu-button {
    flex: 1;
    text-align: center;
    padding: 9px 4px 8px;
    color: rgba(226, 232, 240, 0.92);
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
    margin: 0;
    font-family: 'Teko', sans-serif;
    font-size: 14px;
    background: rgba(15, 23, 42, 0.88);
}

.menu-wrapper-bottom .menu-button:first-child {
    border-left: none;
}

.menu-wrapper-bottom .menu-button i {
    margin-right: 6px;
    font-size: 16px;
    transition: color 0.18s ease;
}

.menu-wrapper-bottom .multiview-button {
    --button-accent: #38bdf8;
}

.menu-wrapper-bottom .androidtv-button {
    --button-accent: #22c55e;
}

.menu-wrapper-bottom .chat-button {
    --button-accent: #a78bfa;
}

.menu-wrapper-bottom .saweria-button {
    --button-accent: #f59e0b;
}

.menu-wrapper-bottom .menu-button i {
    color: var(--button-accent, #22d3ee);
}

.menu-wrapper-bottom .menu-button:hover,
.menu-wrapper-bottom .saweria-button:hover {
    color: #fff;
    border-color: color-mix(in srgb, var(--button-accent, #22d3ee) 46%, transparent);
    background:
        linear-gradient(180deg, rgba(30, 41, 59, 0.96), rgba(15, 23, 42, 0.96));
}

.menu-container {
    display: flex;
    width: 100%;
    margin: 0;
    padding: 0;
}

.sidebar-content {
    flex-grow: 1;
    padding: 2px;
    display: none;
    overflow-y: auto;
    background:
        repeating-linear-gradient(45deg, #0000 calc(-650%/13) calc(50%/13), #0f1129 0 calc(100%/13),
            #0000 0 calc(150%/13), #0f1129 0 calc(200%/13),
            #0000 0 calc(250%/13), #0f1129 0 calc(300%/13)), repeating-linear-gradient(45deg, #0000 calc(-650%/13) calc(50%/13), #0f1129 0 calc(100%/13),
            #0000 0 calc(150%/13), #0f1129 0 calc(200%/13),
            #0000 0 calc(250%/13), #0f1129 0 calc(300%/13)) 32px 32px,
        repeating-linear-gradient(-45deg, #0000 calc(-650%/13) calc(50%/13), #0f1129 0 calc(100%/13),
            #0000 0 calc(150%/13), #0f1129 0 calc(200%/13),
            #0000 0 calc(250%/13), #0f1129 0 calc(300%/13)), repeating-linear-gradient(-45deg, #0000 calc(-650%/13) calc(50%/13), #0f1129 0 calc(100%/13),
            #0000 0 calc(150%/13), #0f1129 0 calc(200%/13),
            #0000 0 calc(250%/13), #0f1129 0 calc(300%/13)) 32px 32px #0f172a;
    background-size: 64px 64px;
}

.sidebar-content.active {
    display: block;
}

/* ===== EVENT CARD - Simple but Modern ===== */
.event-container {
    position: relative;
    background: rgba(15, 23, 42, 0.95);
    padding: 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 2px;
    border: 1px solid rgb(0 222 255 / 35%);
}

.event-container.hover-effect {
    background: rgba(20, 30, 55, 0.95);
}

@media (hover: hover) and (pointer: fine) {
    .event-container:hover {
        background: rgba(20, 30, 55, 0.95);
    }
}

.event-container,
.channel-container,
.event-share-button,
.server-button,
.server-refresh-button {
    -webkit-tap-highlight-color: transparent;
}

.event-container.poster-event {
    min-height: 132px;
    padding: 0;
    overflow: hidden;
    background: rgba(15, 23, 42, 0.95);
}

.poster-background,
.poster-shade {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
}

.poster-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.poster-shade {
    background:
        linear-gradient(180deg, rgba(15, 23, 42, 0.18) 0%, rgba(15, 23, 42, 0.58) 48%, rgba(8, 12, 24, 0.96) 100%),
        linear-gradient(90deg, rgba(8, 12, 24, 0.82) 0%, rgba(8, 12, 24, 0.28) 52%, rgba(8, 12, 24, 0.7) 100%);
}

.poster-content {
    position: relative;
    z-index: 1;
    min-height: 132px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 10px;
}

.poster-event h2 {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: auto;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.75);
}

.poster-event .league-name {
    max-width: calc(100% - 42px);
}

.poster-meta {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 5px;
    color: rgba(255, 255, 255, 0.82);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

.poster-meta .kickoff-match-date,
.poster-meta .kickoff-match-time {
    text-align: left;
    padding-right: 0;
    font-size: 0.84em;
}

.event-share-button {
    position: absolute;
    right: 10px;
    z-index: 4;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    margin: 3px 0 0;
    padding: 0;
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 4px;
    background: rgba(15, 23, 42, 0.72);
    color: rgba(226, 232, 240, 0.82);
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.event-share-button:focus-visible {
    background: rgba(30, 41, 59, 0.94);
    border-color: rgba(34, 211, 238, 0.5);
    color: #fff;
}

@media (hover: hover) and (pointer: fine) {
    .event-share-button:hover {
        background: rgba(30, 41, 59, 0.94);
        border-color: rgba(34, 211, 238, 0.5);
        color: #fff;
    }
}

.event-share-button.is-copied {
    color: #22c55e;
    border-color: rgba(34, 197, 94, 0.65);
}

.event-share-button svg {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.poster-title {
    color: #fff;
    font-size: 1.02em;
    font-weight: 700;
    line-height: 1.05;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.poster-source-team {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.poster-event .server-buttons,
.poster-event .countdown-wrapper {
    position: relative;
    z-index: 2;
    margin: 0 10px 10px;
}

.poster-event .live-label {
    z-index: 3;
}

#countdown .countdown-poster-info {
    grid-template-columns: 54px minmax(0, 1fr);
    text-align: left;
}

#countdown .countdown-poster-team {
    align-items: center;
}

#countdown .countdown-logo-box.countdown-poster-thumb {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    overflow: hidden;
    padding: 0;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.18);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.26);
}

#countdown .countdown-logo-box.countdown-poster-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#countdown .countdown-poster-copy {
    min-width: 0;
}

#countdown .countdown-poster-league {
    color: rgba(226, 232, 240, 0.72);
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
    text-transform: uppercase;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#countdown .countdown-poster-title {
    margin-top: 4px;
    color: #f8fafc;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.05;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ===== NO LIVE EVENT MESSAGE ===== */
.no-live-message {
    background: rgba(15, 23, 42, 0.95);
    padding: 20px;
    border-radius: 4px;
    margin: 10px 2px;
    border: 1px solid rgba(239, 68, 68, 0.3);
    text-align: center;
}

.no-live-message i {
    font-size: 48px;
    color: rgba(239, 68, 68, 0.6);
    margin-bottom: 15px;
}

.no-live-message h3 {
    margin: 0 0 10px 0;
    font-size: 20px;
    color: rgba(255, 255, 255, 0.9);
}

.no-live-message p {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.event-load-error {
    border-color: rgba(245, 158, 11, 0.45);
}

.event-load-error i {
    color: rgba(245, 158, 11, 0.75);
}

.event-load-error-details {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    margin-top: 14px;
}

.event-load-error-details span {
    padding: 5px 8px;
    border-radius: 3px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(148, 163, 184, 0.25);
    color: rgba(226, 232, 240, 0.82);
    font-size: 12px;
    line-height: 1.2;
}

.live-label {
    display: none;
    position: absolute;
    top: 0px;
    right: 0px;
    background: #ff0545;
    color: white;
    padding: 3px 15px 3px 15px;
    font-size: 0.75em;
    border-radius: 0 5px 1px 10px;
    border: 1px solid rgba(239, 68, 68, 0.5);
}

/* ===== SERVER BUTTONS ===== */
.server-buttons {
    display: none;
    flex-direction: column;
    align-items: flex-start;
    padding: 10px;
    margin-top: 10px;
    background: rgba(15, 23, 42, 0.7);
    border-radius: 4px;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.server-buttons .buttons-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-start;
    width: 100%;
}

.server-button {
    background: rgba(15, 23, 42, 0.6);
    padding: 5px 10px;
    font-size: 0.75em;
    color: rgba(255, 255, 255, 0.85);
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    max-width: 80px;
    border: 1px solid rgba(59, 130, 246, 0.25);
}

.server-button.active {
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
    color: white;
    border-color: rgba(59, 130, 246, 0.6);
}

.server-button.is-new {
    position: relative;
    border-color: rgba(250, 204, 21, 0.95);
    animation: serverNewPulse 1.15s ease-in-out 5;
}

.server-button.is-new:not(.active) {
    background: rgba(133, 77, 14, 0.82);
    color: #fef9c3;
}

.server-button.is-new::after {
    content: '';
    position: absolute;
    top: 3px;
    right: 3px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #fde047;
    box-shadow: 0 0 6px rgba(253, 224, 71, 0.9);
}

@keyframes serverNewPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(250, 204, 21, 0); }
    50% { box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.24); }
}

@media (prefers-reduced-motion: reduce) {
    .server-button.is-new {
        animation: none;
    }
}

@media (hover: hover) and (pointer: fine) {
    .server-button:hover {
        background: rgba(29, 78, 216, 0.5);
        border-color: rgba(59, 130, 246, 0.4);
        color: rgba(255, 255, 255, 0.95);
    }
}

.instruction {
    font-size: 0.75em;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 5px;
    text-align: left;
    width: 100%;
}

.server-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    margin-bottom: 8px;
}

.server-toolbar .instruction {
    flex: 1;
    width: auto;
    margin-bottom: 0;
}

.server-refresh-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: rgb(16 24 44);
    background: rgb(16 24 44);
    color: rgba(255, 255, 255, 0.95);
    cursor: pointer;
    transition: all 0.2s ease;
}

@media (hover: hover) and (pointer: fine) {
    .server-refresh-button:hover {
        background: rgba(22, 163, 74, 0.75);
        border-color: rgba(74, 222, 128, 0.65);
    }
}

.server-refresh-button svg {
    width: 16px;
    height: 16px;
}

.server-refresh-button.is-loading svg {
    animation: serverRefreshSpin 0.8s linear infinite;
}

@keyframes serverRefreshSpin {
    to { transform: rotate(360deg); }
}

h2 {
    font-size: 0.9em;
    margin-top: 0;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(168, 85, 247, 0.3);
    display: flex;
    align-items: center;
}

.league-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    max-width: 180px;
}

.sport-icon {
    width: 24px;
    height: auto;
    margin-right: 10px;
}

.team {
    display: flex;
    align-items: center;
}

.team-logo {
    width: 24px;
    height: auto;
    margin-right: 10px;
}

.kickoff-match-time {
    text-align: right;
    padding-right: 0;
    font-size: 0.8em;
}

.kickoff-match-date {
    text-align: right;
    padding-right: 0;
    font-size: 0.8em;
}

.chat-iframe {
    width: 100%;
    height: 98%;
    border: none;
    overflow: hidden;
}

.event-container .team-logo1,
.event-container .team-logo2 {
    width: 24px;
    height: auto;
    margin-right: 10px;
}

.event-container .team-logo2 {
    background-color: #ffff0000;
}

.event-container .team1,
.event-container .team2 {
    display: flex;
    align-items: center;
}

.event-container .team2 {
    color: #ffff0000;
}

.event-container .team2:hover {
    color: #ffff0000;
}

/* ========== SEARCH BAR STYLES ========== */
.search-wrapper {
    padding: 2px;
    background: rgba(15, 23, 42, 0.6);
    border-bottom: 1px solid rgba(59, 130, 246, 0.3);
}

.search-container {
    width: 100%;
}

.search-input-wrapper {
    position: relative;
    width: 100%;
    display: flex;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 12px;
    color: rgb(251 251 251);
    font-size: 14px;
    pointer-events: none;
    z-index: 1;
}

.search-input {
    width: 100%;
    padding: 8px 35px 8px 35px;
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 6px;
    color: white;
    font-family: 'Teko', sans-serif;
    font-size: 15px;
    transition: all 0.3s ease;
    outline: none;
}

.search-input::placeholder {
    color: rgba(148, 163, 184, 0.6);
    font-size: 14px;
}

.search-input:focus {
    border-color: rgba(59, 130, 246, 0.8);
    background: rgba(30, 41, 59, 0.95);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.clear-search-btn {
    position: absolute;
    right: 8px;
    background: rgba(239, 68, 68, 0.8);
    border: none;
    border-radius: 4px;
    color: white;
    padding: 6px 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: none;
    font-size: 12px;
}

.clear-search-btn:hover {
    background: rgba(239, 68, 68, 1);
    transform: scale(1.05);
}

.search-input:not(:placeholder-shown) ~ .clear-search-btn {
    display: block;
}

.search-result-count {
    margin-top: 6px;
    padding: 4px 8px;
    font-size: 13px;
    color: rgba(148, 163, 184, 0.9);
    background: rgba(30, 41, 59, 0.5);
    border-radius: 4px;
    text-align: center;
    display: none;
}

@keyframes fadeInSearch {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.search-result-count[style*="display: block"] {
    animation: fadeInSearch 0.3s ease;
}

.event-container.search-highlight {
    animation: searchPulse 0.5s ease;
}

@keyframes searchPulse {
    0%, 100% {
        border-color: rgba(59, 130, 246, 0.3);
    }
    50% {
        border-color: rgba(59, 130, 246, 0.8);
        box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
    }
}

/* ===== MULTIVIEW MODAL - Simple Version ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.92);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-container-modern {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-radius: 4px;
    padding: 0;
    max-width: 700px;
    width: 90%;
    animation: slideUp 0.2s ease;
    overflow: hidden;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

@keyframes slideUp {
    from { 
        transform: translateY(30px);
        opacity: 0;
    }
    to { 
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header-modern {
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header-modern h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: white;
    letter-spacing: 0.5px;
}

.modal-close-btn-modern {
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-weight: 300;
}

.modal-close-btn-modern:hover {
    background: rgba(0, 0, 0, 0.5);
    border-color: rgba(255, 255, 255, 0.5);
    transform: rotate(90deg);
}

.modal-body-modern {
    padding: 30px 20px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    background: rgba(0, 0, 0, 0.3);
}

.grid-option-modern {
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 4px;
    padding: 20px 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.grid-option-modern:hover {
    background: rgba(29, 78, 216, 0.3);
    transform: translateY(-5px);
}

.grid-option-modern:active {
    transform: translateY(-2px);
}

.grid-preview-modern {
    background: rgba(0, 0, 0, 0.6);
    border-radius: 3px;
    padding: 12px;
    display: grid;
    gap: 6px;
    margin-bottom: 12px;
    min-height: 80px;
}

.grid-preview-2 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr;
}

.grid-preview-4 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.grid-preview-6 {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
}

.grid-preview-8 {
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 1fr);
}

.grid-box-modern {
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
    border-radius: 2px;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.grid-label-modern {
    font-size: 16px;
    font-weight: 600;
    color: white;
    margin-bottom: 4px;
}

.grid-subtitle-modern {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 400;
}

/* ========== MOBILE RESPONSIVE ========== */
@media (max-width: 768px) {
    #main-content {
        flex-direction: column;
        display: flex;
        height: 100vh;
    }

    .video-container {
        width: 100%;
        position: relative;
        padding-top: 56.25%;
    }

    .video-wrapper {
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
    }

    .sidebar {
        width: 100%;
        padding: 2px;
        box-sizing: border-box;
        overflow-y: auto;
        flex-shrink: 0;
        flex-grow: 1;
        min-height: calc(100vh - 56.25vw);
    }

    .chat-iframe {
        height: 63vh;
        border: none;
    }

    #countdown.countdown-wrapper {
        width: min(300px, calc(100% - 24px));
        padding: 8px;
    }

    #countdown .countdown-title {
        min-height: 16px;
        margin-bottom: 6px;
        font-size: 10px;
    }

    #countdown .countdown-event-info {
        gap: 5px;
        margin-bottom: 7px;
    }

    #countdown .countdown-team {
        gap: 4px;
    }

    #countdown .countdown-logo-box {
        width: 28px;
        height: 28px;
        padding: 4px;
        border-radius: 6px;
    }

    #countdown .countdown-team span {
        font-size: 11px;
    }

    #countdown .countdown-vs {
        width: auto;
        height: auto;
        font-size: 10px;
    }

    #countdown .countdown-timer {
        gap: 4px;
    }

    #countdown .time-unit {
        padding: 5px 3px 4px;
    }

    #countdown .time-unit strong {
        font-size: 20px;
    }

    #countdown .time-unit span {
        margin-top: 4px;
        font-size: 8px;
    }

    #spacer {
        height: 140px;
        width: 100%;
        background: transparent;
    }

    .menu-wrapper-bottom {
        position: fixed;
        bottom: env(safe-area-inset-bottom);
        left: 0;
        right: 0;
        width: 100%;
        z-index: 1000;
        padding-bottom: calc(0px + env(safe-area-inset-bottom));
    }
    
    /* Mobile - Category buttons smaller */
    .category-freeze {
        width: 120px;
        font-size: 13px;
        padding: 8px 6px;
    }
    
    .category-button {
        width: 120px;
        font-size: 13px;
        padding: 8px 6px;
    }
    
    /* Arrow buttons mobile */
    .category-arrow-btn {
        width: 35px;
        font-size: 12px;
    }
    
    /* Hide scrollbar di mobile juga */
    .category-scroll-wrapper::-webkit-scrollbar {
        display: none;
    }
    
    .live-indicator {
        font-size: 7px;
    }
    
    /* Mobile - Menu bottom */
    .menu-wrapper-bottom .menu-button {
        padding: 10px 0;
        font-size: 12px;
    }
    
    .menu-wrapper-bottom .menu-button i {
        font-size: 14px;
        margin-right: 4px;
    }
    
    /* Mobile - Search */
    .search-wrapper {
        padding: 2px;
    }
    
    .search-input {
        padding: 7px 30px 7px 30px;
        font-size: 14px;
    }
    
    .search-icon {
        font-size: 13px;
        left: 10px;
    }
    
    .clear-search-btn {
        padding: 5px 8px;
        font-size: 11px;
    }
    
    .search-result-count {
        font-size: 12px;
        margin-top: 5px;
    }
    
    /* Mobile - Modal */
    .modal-container-modern {
        max-width: 95%;
        width: 95%;
    }
    
    .modal-body-modern {
        grid-template-columns: repeat(2, 1fr);
        padding: 20px 15px;
        gap: 15px;
    }
    
    .grid-option-modern {
        padding: 15px 10px;
    }
    
    .grid-preview-modern {
        min-height: 60px;
        padding: 8px;
        gap: 4px;
    }
    
    .grid-label-modern {
        font-size: 14px;
    }
    
    .grid-subtitle-modern {
        font-size: 10px;
    }
}
