/*
Theme Name: TikTok WP
Author: Gemini Partner
Description: Tema de video vertical con scroll snapping.
Version: 1.0
*/

body, html {
    margin: 0;
    padding: 0;
    overflow: hidden; /* Evita el scroll doble */
    background-color: #000;
}

.tiktok-wrapper {
    height: 100vh;
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
    scrollbar-width: none; /* Oculta scroll en Firefox */
}

.tiktok-wrapper::-webkit-scrollbar {
    display: none; /* Oculta scroll en Chrome/Safari */
}

.video-entry {
    height: 100vh;
    width: 100vw;
    scroll-snap-align: start;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.overlay {
    position: absolute;
    bottom: 30px;
    left: 15px;
    right: 15px;
    color: white;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.8);
    pointer-events: none;
}

.actions {
    position: absolute;
    right: 15px;
    bottom: 100px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    pointer-events: auto;
}

.btn-action {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
}

/* Botón de audio flotante */
#unmute-button {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 999;
    background: rgba(255, 0, 80, 0.8);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: bold;
}

/* Ajuste para que el texto no tape el video */
.overlay {
    pointer-events: none;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    padding: 40px 20px;
}

/*
Theme Name: TikTok Visual Style
Description: Diseño limpio inspirado en Reels/TikTok.
*/

* { box-sizing: border-box; }
html, body { 
    margin: 0; 
    height: 100%; 
    background: #000; 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto; 
    overflow: hidden; 
}

/* Contenedor de Scroll */
.feed { 
    height: 100vh; 
    overflow-y: scroll; 
    scroll-snap-type: y mandatory; 
    scrollbar-width: none; 
}
.feed::-webkit-scrollbar { display: none; }

/* Cada Video (Reel) */
.reel { 
    position: relative; 
    height: 100vh; 
    scroll-snap-align: start; 
    background: #000;
}

video { 
    position: absolute; 
    inset: 0; 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
}

/* Botón Play Central */
.play-btn {
    position: absolute; inset: 0; margin: auto;
    width: 80px; height: 80px; border-radius: 50%;
    background: rgba(0,0,0,.6);
    display: flex; align-items: center; justify-content: center;
    z-index: 10; cursor: pointer;
    animation: pulse 2s infinite;
}
.play-btn::before {
    content: ""; margin-left: 6px;
    border-left: 20px solid #fff;
    border-top: 12px solid transparent; border-bottom: 12px solid transparent;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(255,255,255,0.4); }
    70% { box-shadow: 0 0 0 30px rgba(255,255,255,0); }
    100% { box-shadow: 0 0 0 0 rgba(255,255,255,0); }
}

/* Información del Creador (Arriba Izquierda) */
.reel-meta {
    position: absolute; top: 20px; left: 15px;
    display: flex; align-items: center;
    background: rgba(0, 0, 0, 0.4);
    padding: 5px 12px; border-radius: 30px; z-index: 20; color: #fff;
}
.avatar { width: 35px; height: 35px; border-radius: 50%; overflow: hidden; margin-right: 10px; border: 1px solid #fff; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.meta-text strong { font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; }

/* Acciones Inferiores (Barra lateral derecha/abajo) */
.actions {
    position: absolute; bottom: 30px; right: 15px;
    display: flex; flex-direction: column; gap: 20px; z-index: 20;
}

.action-item {
    display: flex; flex-direction: column; align-items: center; color: white; font-size: 12px;
}

.action-btn {
    width: 45px; height: 45px; border-radius: 50%; 
    background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center;
    margin-bottom: 5px; cursor: pointer; border: none;
}

.action-btn svg { width: 22px; height: 22px; fill: white; }

/* Barra de Progreso Superior */
.progress-bar {
    position: absolute; top: 0; left: 0; width: 100%; height: 3px;
    background: rgba(255,255,255,0.2); z-index: 30;
}
.progress-fill { height: 100%; width: 0%; background: #fff; transition: width 0.1s linear; }