Series e novelas turcas

Series e novelas turcas

<!DOCTYPE html>
<html lang="pt-BR">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Painel Flutuante</title>

<style>
body {
margin: 0;
font-family: Arial, sans-serif;
}

.fullscreen-panel {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: #000;
display: flex;
justify-content: center;
align-items: center;
z-index: 999999;
}

.panel {
background: #000;
padding: 30px;
border-radius: 20px;
box-shadow: 0 0 40px rgba(255,0,0,0.4);
text-align: center;
}

.grid {
display: flex;
gap: 15px;
justify-content: center;
}

.btn-card {
width: 160px;
border-radius: 12px;
overflow: hidden;
cursor: pointer;
background: #111;
}

.btn-card img {
width: 100%;
height: 220px;
object-fit: cover;
}

.btn-card span {
display: block;
padding: 10px;
color: white;
font-weight: bold;
}

.chapter-list {
max-height: 400px;
overflow-y: auto;
margin-top: 20px;
display: none;
}

.chapter-list button {
width: 100%;
margin: 5px 0;
padding: 10px;
border: none;
background: #ff0000;
color: white;
border-radius: 8px;
cursor: pointer;
}

/* PLAYER */
.player-overlay {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: black;
display: none;
z-index: 9999999;
}

video {
width: 100%;
height: 100%;
background: black;
}

.close-btn {
position: absolute;
top: 15px;
right: 20px;
background: red;
color: white;
border: none;
padding: 10px 14px;
cursor: pointer;
border-radius: 8px;
font-weight: bold;
z-index: 20;
}
</style>
</head>

<body>

<div class="fullscreen-panel">
<div class="panel">

<div class="grid">
<div class="btn-card" onclick="toggleList('yabaniSeason')">
<img src="https://upnovelas.com/wp-content/uploads/2024/10/34544-204x300.jpg">
<span>Yabani novela</span>
</div>
</div>

<div class="chapter-list" id="yabaniSeason">
<button onclick="toggleList('yabani1')">1ª Temporada</button>
<button onclick="toggleList('yabani2')">2ª Temporada</button>
</div>

<div class="chapter-list" id="yabani1"></div>
<div class="chapter-list" id="yabani2"></div>

</div>
</div>

<div class="player-overlay" id="playerBox">
<button class="close-btn" onclick="closePlayer()">Fechar ✕</button>
<video id="videoPlayer" controls></video>
</div>

<script>
let created1 = false;
let created2 = false;

function toggleList(id) {
document.querySelectorAll('.chapter-list').forEach(el => el.style.display = 'none');

let c = document.getElementById(id);

if (id === 'yabani1' && !created1) {

// CAP 59
let b59 = document.createElement('button');
b59.innerText = 'Capítulo 59';
b59.onclick = () => openPlayer('https://cbb87jx3ss9597i.cdn-novflix.com/storage8/YABANI/YABANI-059.mp4');
c.appendChild(b59);

// CAP 60
let b60 = document.createElement('button');
b60.innerText = 'Capítulo 60';
b60.onclick = () => openPlayer('https://cbb87jx3ss9597i.cdn-novflix.com/storage8/YABANI/YABANI-060.mp4');
c.appendChild(b60);

// RESTO SEM LINK
for (let i = 61; i <= 120; i++) {
let b = document.createElement('button');
b.innerText = 'Capítulo ' + i;

b.onclick = () => alert('Sem link ainda');

c.appendChild(b);
}

created1 = true;
}

if (id === 'yabani2' && !created2) {
for (let i = 121; i <= 167; i++) {
let b = document.createElement('button');
b.innerText = 'Capítulo ' + i;

b.onclick = () => alert('Sem link ainda');

c.appendChild(b);
}
created2 = true;
}

c.style.display = 'block';
}

function openPlayer(url) {
const video = document.getElementById('videoPlayer');
video.src = url;
document.getElementById('playerBox').style.display = 'block';
video.play();
}

function closePlayer() {
const video = document.getElementById('videoPlayer');
video.pause();
video.src = '';
document.getElementById('playerBox').style.display = 'none';
}
</script>

</body>
</html>