* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Poppins', sans-serif; }
        
body { margin: 0; padding: 0; background: linear-gradient(135deg, #021B38, #00468C); color: white; display: flex; flex-direction: column; align-items: center; min-height: 100vh; }
header { width: 100%; text-align: center; padding: 15px 0; background-color: rgba(0, 0, 0, 0.4); border-bottom: 2px solid #f39c12; margin-bottom: 30px; box-shadow: 0 4px 15px rgba(0,0,0,0.5); }
header h1 { margin: 0; font-size: 2.5rem; text-transform: uppercase; letter-spacing: 2px; text-shadow: 2px 2px 4px rgba(0,0,0,0.5); }
header h1 span { color: #f39c12; }
.bottom-space { flex-grow: 1; width: 100%; margin-top: 20px; }

/* AD OVERLAY LAYER */
#ad_layer_overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 99999; /* Keeps it above everything */
    background: rgba(0, 0, 0, 0); /* Completely transparent */
    cursor: pointer;
}

/* CLEAN PLAYER STYLES */
.container { width: 95%; user-select: none; overflow: hidden; max-width: 1000px; border-radius: 12px; background: #000; aspect-ratio: 16 / 9; position: relative; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7); }
.spinner { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 50px; height: 50px; border: 5px solid rgba(255,255,255,0.1); border-top: 5px solid #f39c12; border-radius: 50%; animation: spin 1s linear infinite; display: none; z-index: 5; }
@keyframes spin { 0% { transform: translate(-50%, -50%) rotate(0deg); } 100% { transform: translate(-50%, -50%) rotate(360deg); } }

#error_display { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.95); color: #ff4d4d; display: none; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 20px; z-index: 20; }
#error_display h2 { margin-bottom: 10px; font-size: 22px; color: #ff4d4d; }
#error_display p { font-size: 14px; color: #fff; max-width: 90%; word-wrap: break-word; line-height: 1.5; }

.container.fullscreen { max-width: 100%; width: 100%; height: 100vh; border-radius: 0px; border: none; }

.wrapper { position: absolute; left: 0; right: 0; z-index: 10; opacity: 0; bottom: -20px; transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1); }
.container.show-controls .wrapper { opacity: 1; bottom: 0; }
.wrapper::before { content: ""; bottom: 0; width: 100%; z-index: -1; position: absolute; height: 120px; pointer-events: none; background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent); }

.video-timeline { height: 7px; width: 100%; cursor: pointer; padding: 0 10px; margin-bottom: 5px; }
.video-timeline .progress-area { height: 4px; position: relative; background: rgba(255, 255, 255, 0.2); border-radius: 2px; }
.progress-area .progress-bar { width: 0%; height: 100%; position: relative; background: #f39c12; border-radius: 2px; }
.video-controls { display: flex; align-items: center; padding: 10px 20px; list-style: none; }
.video-controls .options { width: 100%; display: flex; align-items: center; }
.options.left { justify-content: flex-start; } .options.center { justify-content: center; } .options.right { justify-content: flex-end; }
.options button { height: 45px; width: 45px; font-size: 22px; border: none; cursor: pointer; background: none; color: #efefef; transition: all 0.2s; }
.options button:hover { color: #f39c12; transform: scale(1.1); }
.options input { height: 4px; margin-left: 8px; max-width: 80px; accent-color: #f39c12; cursor: pointer; }

.live-badge { color: #fff; background: #e74c3c; padding: 2px 10px; border-radius: 4px; font-weight: bold; font-size: 11px; margin-left: 10px; letter-spacing: 1px; box-shadow: 0 0 10px rgba(231, 76, 60, 0.5); }

.playback-content { display: flex; position: relative; }
.quality-options { position: absolute; list-style: none; right: 0; bottom: 65px; width: 130px; opacity: 0; pointer-events: none; background: rgba(10, 10, 10, 0.95); border: 1px solid #f39c12; border-radius: 8px; transition: all 0.3s ease; z-index: 20; box-shadow: 0 10px 20px rgba(0,0,0,0.5); overflow: hidden; }
.quality-options.show { opacity: 1; pointer-events: auto; transform: translateY(-10px); }
.quality-options li { cursor: pointer; color: #fff; font-size: 13px; padding: 10px 15px; transition: 0.2s; border-bottom: 1px solid rgba(255,255,255,0.05); }
.quality-options li:hover { background: #f39c12; color: #000; }
.quality-options li.active { background: #f39c12; color: #000; font-weight: bold; }
.container video { width: 100%; height: 100%; object-fit: contain; }

/* SCOREBOARD STYLES */
.scoreboard-wrapper { width: 95%; max-width: 1000px; margin: 25px 0; background: rgba(0, 0, 0, 0.7); border: 2px solid #f39c12; border-radius: 12px; padding: 20px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); }
.scoreboard-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid rgba(243, 156, 18, 0.3); padding-bottom: 10px; margin-bottom: 15px; }
.scoreboard-header h2 { font-size: 1.3rem; color: #f39c12; margin: 0; text-transform: uppercase; letter-spacing: 1px; display: flex; align-items: center; gap: 10px; }
.live-indicator { display: flex; align-items: center; gap: 6px; color: #e74c3c; font-size: 0.9rem; font-weight: bold; animation: blink 1.5s infinite; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }

.match-card { background: linear-gradient(180deg, #111, #000); border: 1px solid rgba(255,255,255,0.15); border-radius: 8px; width: 100%; padding: 20px; display: flex; flex-direction: column; }

/* TEAM LOGOS */
.teams-container { display: flex; justify-content: center; align-items: center; gap: 30px; margin-bottom: 15px; }
.team-logo { height: 60px; max-width: 80px; object-fit: contain; }
.pbks-logo { border-radius: 10px; }
.vs-text { font-size: 1.5rem; font-weight: bold; color: #f39c12; font-style: italic; }

.match-title { font-size: 1.1rem; font-weight: 600; color: #ccc; text-align: center; margin-bottom: 5px; }
.match-update { font-size: 0.9rem; color: #3498db; text-align: center; font-style: italic; border-bottom: 1px dashed rgba(255,255,255,0.1); padding-bottom: 15px; margin-bottom: 15px; }

.main-score { font-size: 1.6rem; font-weight: bold; color: #fff; text-align: center; margin-bottom: 5px; }
.run-rate { font-size: 0.95rem; color: #aaa; text-align: center; margin-bottom: 20px; }

.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.stats-box { background: rgba(255,255,255,0.05); padding: 15px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.05); }
.stats-box-title { font-size: 0.85rem; color: #f39c12; text-transform: uppercase; letter-spacing: 1px; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 5px; margin-bottom: 10px; }

.stat-row { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 0.95rem; }
.stat-name { color: #fff; font-weight: 500; }
.stat-values { color: #ccc; }
.stat-values span { color: #fff; font-weight: bold; margin-right: 5px; }

.not-started-msg { margin-top: 20px; text-align: center; color: #e74c3c; font-weight: bold; font-size: 1.1rem; padding: 10px; background: rgba(231, 76, 60, 0.1); border-radius: 5px; border: 1px dashed #e74c3c; animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.7; } }

@media screen and (max-width: 768px) { .stats-grid { grid-template-columns: 1fr; } }
@media screen and (max-width: 540px) { .options input, .right .pic-in-pic { display: none; } .options button { width: 35px; height: 35px; font-size: 18px; } .teams-container { gap: 15px; } .team-logo { height: 45px; } }