File size: 7,125 Bytes
2472cc6
 
 
 
 
 
 
 
a109a08
2472cc6
 
 
 
a109a08
2472cc6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
a109a08
2472cc6
 
 
dcce983
5589451
2472cc6
a109a08
2472cc6
 
5589451
a109a08
 
2472cc6
 
 
 
 
5589451
2472cc6
5589451
 
 
2472cc6
5589451
dcce983
5589451
2472cc6
5589451
 
 
2472cc6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29bfc2b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
  <title>Mosaico de Vídeos</title>
  <script src="https://cdn.tailwindcss.com"></script>
  <style>
    /* Faz todo o fundo da página preto */
    html, body {
      margin: 0;
      padding: 0;
      height: 100%;
      background-color: black;
    }

    /* Header transparente */
    header {
      position: fixed;
      top: 0; left: 0;
      width: 100%;
      z-index: 50;
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 1.5rem 2.5rem;
      background-color: transparent;
    }
    header img.logo { height: 40px; }
    header nav a {
      font-size: 1.125rem;
      margin-left: 1.5rem;
      transition: color 0.3s, opacity 0.3s;
      text-decoration: none;
    }
    header nav a:hover { opacity: 0.8; }

    /* Grid mosaico */
    .mosaic-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
      grid-auto-rows: 200px;
      gap: 10px;
      padding: 6rem 2rem 2rem;
    }
    .grid-item--large { grid-column: span 2; grid-row: span 2; }
    .grid-item--wide  { grid-column: span 2; }
    .grid-item--tall  { grid-row: span 2; }

    /* Estilos das boxes */
    .box {
      position: relative;
      overflow: hidden;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .box .video-bg {
      position: absolute; inset: 0;
      width: 100%; height: 100%;
      object-fit: cover;
      opacity: 0;
      transition: opacity 0.3s ease;
      z-index: 0;
    }
    .box .white-bg {
      position: absolute; inset: 0;
      background: white;
      opacity: 1;
      transition: opacity 0.3s ease;
      z-index: 1;
    }
    .box .content {
      position: relative;
      z-index: 2;
      color: white;
      text-align: center;
      padding: 1rem;
      transition: color 0.3s ease;
    }

    /* Hover / active */
    .box:hover .video-bg,
    .box.active .video-bg {
      opacity: 0.8;
    }
    .box:hover .white-bg,
    .box.active .white-bg {
      opacity: 0.2;
    }
    .box:hover .content,
    .box.active .content {
      color: white;
    }

    @media (max-width: 640px) {
      .mosaic-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: 150px;
      }
      .grid-item--large,
      .grid-item--wide,
      .grid-item--tall {
        grid-column: span 1 !important;
        grid-row: auto !important;
      }
    }
  </style>
</head>
<body>
  <!-- Header -->
  <header>
    <div class="logo-container">
      <img src="https://i.imgur.com/PrqgWQK.png" alt="Logo" class="logo" />
    </div>
    <nav id="menu">
      <a href="#" class="text-white">Home</a>
      <a href="#" class="text-white">Sobre</a>
      <a href="#" class="text-white">Contato</a>
    </nav>
  </header>

  <!-- Mosaico de Vídeos -->
  <main>
    <div class="mosaic-grid">
      <div class="box grid-item--large">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-2xl font-bold mb-2">Box 1</h2>
          <p>Vídeo 1</p>
        </div>
      </div>
      <div class="box grid-item--wide">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-xl font-semibold mb-1">Box 2</h2>
        </div>
      </div>
      <div class="box grid-item--tall">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-xl font-semibold">Box 3</h2>
        </div>
      </div>
      <div class="box">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-lg font-medium">Box 4</h2>
        </div>
      </div>
      <div class="box">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-lg font-medium">Box 5</h2>
        </div>
      </div>
      <div class="box">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-lg font-medium">Box 6</h2>
        </div>
      </div>
      <div class="box grid-item--wide">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-xl font-semibold">Box 7</h2>
        </div>
      </div>
      <div class="box">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-xl font-semibold">Box 8</h2>
        </div>
      </div>
      <div class="box">
        <video class="video-bg" autoplay muted loop>
          <source src="https://i.imgur.com/11w7fnl.mp4" type="video/mp4">
        </video>
        <div class="white-bg"></div>
        <div class="content">
          <h2 class="text-lg font-medium">Box 9</h2>
        </div>
      </div>
    </div>
  </main>

  <!-- Script para ativar por toque/click no mobile -->
  <script>
    const boxes = document.querySelectorAll('.box');
    boxes.forEach(box => {
      const video = box.querySelector('video');
      box.addEventListener('click', () => {
        boxes.forEach(b => {
          b.classList.remove('active');
          b.querySelector('video').pause();
        });
        box.classList.add('active');
        video.play();
      });
    });
  </script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=TiiaGOD/boxes" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>