Vídeo de fondo


<!DOCTYPE html>

<html>
<head>
<title>Vídeo pantalla completa</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
video {
position: fixed;
right: 0;
bottom: 0;
min-width: 100%;
min-height: 100%;
}
section {
position: fixed;
bottom: 0;
background: rgba(0, 0, 0, 0.5);
color: #f1f1f1;
width: 100%;
padding: 20px;
}
</style>
</head>
<body>
<video autoplay muted loop>
<source src="img/rain.mp4" type="video/mp4">
El navegador no soporta vídeos.
</video>
<section>
<h1>Contenido</h1>
<p>Lorem ipsum...</p>

</section>
</body>
</html>

Publicado por

Avatar del usuario

Juan Pablo Fuentes

Formador de programación y bases de datos