Skip to content

Commit 8fb0c98

Browse files
committed
responsive static styles completed
1 parent eb1d5ce commit 8fb0c98

2 files changed

Lines changed: 45 additions & 15 deletions

File tree

‎front/static/index.html‎

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -85,14 +85,16 @@ <h3 class="instructions__subtitle">How does it work?</h3>
8585
</div>
8686
<!-- / video / -->
8787
<section class="box-content border-bottom">
88-
<div>
88+
<div class="video-section-container">
8989
<h2 class="heading">Video tutorial</h2>
90-
<iframe
91-
src="https://www.youtube.com/embed/4sswp02n0Yg"
92-
frameborder="0"
93-
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
94-
allowfullscreen
95-
></iframe>
90+
<div class="video-container">
91+
<iframe
92+
src="https://www.youtube.com/embed/4sswp02n0Yg"
93+
frameborder="0"
94+
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
95+
allowfullscreen
96+
></iframe>
97+
</div>
9698
</div>
9799
</section>
98100

‎front/static/styles.css‎

Lines changed: 36 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -181,20 +181,19 @@ ul {
181181
}
182182

183183
@media only screen and (max-width: 770px) {
184-
.navbar__list__item:first-of-type {
185-
display: none;
184+
.navbar {
185+
background-image: none;
186+
background-color: var(--color-light);
186187
}
187188
}
188189

189-
@media only screen and (max-width: 578px) {
190+
@media only screen and (max-width: 728px) {
190191
.navbar {
191192
flex-direction: column;
192193
align-items: center;
193194
justify-content: center;
194195
align-content: center;
195196
height: auto;
196-
background-image: none;
197-
background-color: var(--color-light);
198197
}
199198

200199
.navbar__logo {
@@ -254,7 +253,7 @@ ul {
254253
}
255254
}
256255

257-
@media only screen and (max-width: 578px) {
256+
@media only screen and (max-width: 728px) {
258257
.top-container {
259258
margin-top: 6rem;
260259
padding-bottom: 0rem;
@@ -305,7 +304,7 @@ ul {
305304
fill: var(--color-light);
306305
}
307306

308-
@media only screen and (max-width: 578px) {
307+
@media only screen and (max-width: 1250px) {
309308
.cta-button-container {
310309
display: none;
311310
}
@@ -379,12 +378,41 @@ ul {
379378
}
380379
}
381380

382-
@media only screen and (max-width: 578px) {
381+
@media only screen and (max-width: 728px) {
383382
.instructions {
384383
border: none;
385384
}
386385
}
387386

387+
/* - - - - - video - - - - - */
388+
.video-section-container {
389+
width: 70%;
390+
}
391+
392+
.video-container {
393+
position: relative;
394+
padding-bottom: 56.25%;
395+
padding-top: 30px;
396+
height: 0;
397+
overflow: hidden;
398+
}
399+
400+
.video-container iframe,
401+
.video-container object,
402+
.video-container embed {
403+
position: absolute;
404+
top: 0;
405+
left: 0;
406+
width: 100%;
407+
height: 100%;
408+
}
409+
410+
@media only screen and (max-width: 770px) {
411+
.video-section-container {
412+
width: 100%;
413+
}
414+
}
415+
388416
/* - - - - - credits - - - - - */
389417
.card {
390418
display: flex;

0 commit comments

Comments
 (0)