Skip to content

Commit 48fea27

Browse files
Merge pull request #849 from Rohit12012007/patch-13
Update style.css
2 parents 9911804 + 59a7183 commit 48fea27

File tree

1 file changed

+30
-20
lines changed

1 file changed

+30
-20
lines changed

Countdown_Timer/style.css

Lines changed: 30 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,41 +4,51 @@
44
box-sizing: border-box;
55
}
66

7-
body{
8-
7+
body {
8+
/* Use a background image that covers the whole body */
99
background-image: url(./deepavali.jpg);
10-
background-size: contain;
10+
background-size: cover; /* Changed to cover for better responsiveness */
1111
background-position: center center;
12+
13+
/* Center content and provide a minimum height for the viewport */
1214
display: flex;
1315
flex-direction: column;
1416
align-items: center;
1517
min-height: 100vh;
18+
19+
/* Set the font family and color for the text */
1620
font-family: 'Roboto', sans-serif;
17-
margin-top: 4rem;
18-
color: #ffae42;
21+
margin: 0; /* Reset margin to remove default body margin */
22+
color: #ffae42; /* Set the text color */
1923
}
20-
.countdown-container{
24+
25+
/* Countdown container layout */
26+
.countdown-container {
2127
display: flex;
22-
2328
}
24-
h1{
29+
30+
/* Main heading style */
31+
h1 {
2532
font-size: 4rem;
26-
margin-top: 100 rem;
27-
33+
margin-top: 2rem; /* Adjusted for a more reasonable top margin */
2834
}
29-
.big-text{
35+
36+
/* Big text for countdown numbers */
37+
.big-text {
3038
font-weight: bold;
3139
font-size: 8rem;
32-
line-height: 0.5;
33-
margin: 1rem 2rem;
34-
40+
line-height: 0.5; /* Adjusted for spacing between lines */
41+
margin: 1rem 2rem; /* Consistent margin around each number */
3542
}
36-
.countdown-el{
43+
44+
/* Individual countdown element styling */
45+
.countdown-el {
3746
text-align: center;
38-
margin-left: 2rem;
47+
margin: 0 2rem; /* Center text and space elements evenly */
3948
}
40-
.countdown-el span{
41-
margin-left: -1 rem;
42-
margin-top: 50 rem;
49+
50+
/* Span styling for countdown labels */
51+
.countdown-el span {
52+
margin-top: 1rem; /* Adjusted to provide proper spacing above the label */
4353
font-size: 2rem;
44-
}
54+
}

0 commit comments

Comments
 (0)