html, body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    height: 100%;
}

body {
    background-color: #000030;
    color: white;
    font-family: Arial, sans-serif;
    overflow: visible;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
    overflow: visible;
}

#content {
    overflow: visible;
    min-height: 100vh; /* Ensure content area allows sticky positioning */
}

.league {
    text-align: center;
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.header {
    display: flex;
    justify-content: center;
    align-items: center;
}

.header img {
    width: 35px;
    height: 35px;
    background-color: white;
    border-radius: 8px;
    padding: 4px;
}

.score {
    font-size: 24px;
    margin: 0 30px;
    font-weight: bold;
    color: #00e0e0;
}

.location {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 15px 0;
    font-size: 0.9rem;
    opacity: 0.7;
}

.location img {
    margin-right: 8px;
}

.iframe-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-top: 56.25%;
    z-index: 2000; /* Increased z-index */
    will-change: position;
}

.background {
    position: absolute;
    top: -20px;
    left: -20px;
    width: calc(100% + 40px);
    height: calc(100% + 40px);
    background-color: black;
    z-index: -1;
}

.iframe-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

@media (min-width: 768px) {
    .iframe-container {
        position: relative;
        margin-top: 20px;
    }

    .header {
        justify-content: space-between;
    }

    .score {
        font-size: 28px;
    }

    .control-bar {
        padding: 15px;
    }

    .control-bar button {
        font-size: 1.4rem;
    }
}

@media (max-width: 767px) {
    .iframe-container {
        position: -webkit-sticky; /* For Safari compatibility */
        position: sticky;
        top: 0;
        z-index: 2000;
        background-color: black;
        margin-top: 0;
        padding-top: 56.25%;
        transform: translateZ(0);
    }
}

.message {
    position: relative;
    background-color: #003366;
    color: white;
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    margin: 20px -20px;
    width: calc(100% + 40px);
    box-sizing: border-box;
}

.message span {
    color: #FFD700;
}

.control-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-radius: 5px;
    margin: 20px -20px 0;
    width: calc(100% + 40px);
    box-sizing: border-box;
    background-color: transparent;
}

.control-bar .buttons-container {
    display: flex;
    width: 100%;
}

.control-bar button {
    background: none;
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
    margin-left: 10px;
    position: relative;
    padding: 8px 12px;
    border-radius: 5px;
}

.control-bar button i {
    margin-right: 0;
}

.control-bar .select-server {
    background-color: #004080;
}

.control-bar .reload {
    background-color: #005080;
    margin-left: auto;
}

.control-bar .lights {
    background-color: #0066cc;
    margin-left: 10px;
}

.control-bar button:hover {
    background-color: #004080;
    color: #FFD700;
}

.disqus-spacing {
    margin-top: 20px;
}

.server-dropdown {
    display: none;
    margin: 10px auto;
    width: 100%;
    border-collapse: collapse;
}

.server-dropdown th,
.server-dropdown td {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: center;
}

.server-dropdown th {
    background-color: #003366;
    color: white;
}

.server-dropdown td.language {
    text-align: left;
}

.server-dropdown td img {
    margin-right: 8px;
}

.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    z-index: 5;
}

.league-icon {
    width: 20px;
    height: 20px;
    border-radius: 10%;
    background-color: white;
    border: 1px solid #ddd;
}

.team-logo {
    width: 100px;
    height: 100px;
}

.team-score-container {
    display: flex;
    justify-content: center;
    align-items: center;
}

.team-score-container img {
    margin: 0 15px;
}

.iframe-crop-container {
    width: 100px;
    height: 100px;
    overflow: hidden;
    position: relative;
}

.iframe-crop-container iframe {
    width: 150%;
    height: 100%;
    position: absolute;
    left: 0;
    top: 0;
    transform: translateX(-25%);
}

.table-cell {
    height: 22px;
    vertical-align: middle;
    font-size: 12px;
}

.quality-cell {
    font-weight: bold;
    text-align: center;
    white-space: nowrap;
    font-size: 12px;
}

.server-cell {
    text-align: center;
    white-space: nowrap;
    font-size: 12px;
    font-weight: bold;
}

.channel-info {
    display: flex;
    align-items: center;
    font-size: 13px;
    font-weight: bold;
}

.channel-flag {
    width: 20px;
    height: 15px;
    margin-right: 5px;
}

.dropdown-visible {
    display: table;
}

.dropdown-hidden {
    display: none;
}