Skip to content

Commit 8b9f9eb

Browse files
adding text on header image
1 parent d6a3e4f commit 8b9f9eb

File tree

1 file changed

+34
-12
lines changed

1 file changed

+34
-12
lines changed

_layouts/default_about.liquid

Lines changed: 34 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,42 @@
1414
{% endif %}
1515
{% include head.liquid %}
1616

17-
<div class="header-background">
18-
<div class="img" style="
19-
background-image: url('/assets/img/lab_header_1.jpg');
20-
background-repeat: no-repeat;
21-
background-size: contain;
22-
background-position: top center;
23-
padding-bottom: 56.25%; /* 16:9 aspect ratio */
24-
height: 0
25-
margin-bottom: 0;
26-
margin-top: -0.0em;
27-
width: 100%;
28-
"></div>
17+
<div class="header-background" style="position: relative; display:">
18+
<div class="img" style="
19+
background-image: url('/assets/img/lab_header_2.jpg');
20+
background-repeat: no-repeat;
21+
background-size: contain;
22+
background-position: top center;
23+
padding-bottom: 56.25%; /* 16:9 aspect ratio */
24+
height: 0;
25+
margin-bottom: 0;
26+
margin-top: 0;
27+
width: 100%;
28+
position: relative;
29+
">
30+
31+
32+
33+
<div class="text" style="
34+
position: absolute;
35+
bottom: 0; /* Aligns the text to the bottom of the image */
36+
left: 0; /* Aligns the text to the left of the image */
37+
color: white;
38+
font-weight: bold;
39+
font-size: 1.5vw; /* Font size will adjust based on viewport width */
40+
font-family: 'Arial', sans-serif;
41+
width: 45%;
42+
max-width: 400px;
43+
line-height: 2vw;
44+
padding-bottom: 10vw;
45+
padding-left: 1vw;
46+
">
47+
Bridging the Gap between Scientific Knowledge and Machine Learning for Accelerating Science
2948
</div>
3049

50+
</div>
51+
</div>
52+
3153
<style>
3254
@media (max-width: 768px) { /* Tablet and smaller screens */
3355
.header-background .img {

0 commit comments

Comments
 (0)