-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathweather.css
224 lines (192 loc) · 7.14 KB
/
weather.css
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
.body{
min-width: 375px;
max-width: 1280px;
}
.heading{
display: flex;
justify-content: center;
align-items: center;
color: #7e255e;
font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;
}
/* Container for the search bar and button */
.search{
display: flex;
justify-content: center;
align-items: center;
max-width: 600px;
}
/* Search input field styling */
.search {
width: 100%;
padding: 10px 15px;
border: 2px solid #ccc;
border-radius: 30px 30px 30px 0px;
font-size: 16px;
outline: none;
transition: border-color 0.3s ease;
}
.search:focus {
border-color: #4d90fe;
}
.container1{
display: flex;
justify-content: center;
align-items: center;
background-color: lightblue;
box-shadow: 10px 10px 15px rgba(0, 0, 0, 0.3);
}
#btn {
margin-right: 100px;
padding: 10px 20px;
background-color: #4d90fe;
color: white;
border: 2px solid #4d90fe;
border-radius: 30px 30px 30px 30px;
font-size: 16px;
cursor: pointer;
transition: background-color 0.3s ease, transform 0.2s ease;
}
/* Button hover and focus effect */
#btn-button:hover {
background-color: #357ae8;
transform: scale(1.05);
}
#btn-button:focus {
outline: none;
box-shadow: 0 0 5px rgba(77, 144, 254, 0.6);
}
.container2{
display: flex;
justify-content: center;
align-items: center;
font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif;
color: #FD3E81;
}
.main-container1 {
margin: auto;
width: 500px; /* Width of the weather card */
height: 300px; /* Height of the weather card */
border: 0px solid #56cfe1; /* Border color */
border-radius: 25px; /* Rounded corners */
text-align: center; /* Center text inside */
padding: 20px; /* Internal padding */
background-color: #ffffff; /* White background for the card */
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* Shadow for depth */
transition: transform 0.3s ease;
background-color: #90DBF4;
box-shadow: 10px 10px 15px rgba(0, 0, 0, 0.3);/* Smooth transform for hover effect */
}
/* Hover effect for a slight lift of the card */
.main-container1:hover {
transform: translateY(-10px); /* Lifts the card up on hover */
}
/* Weather details and text inside */
.main-container1 h2 {
font-size: 24px;
font-weight: bold;
color: #333; /* Dark text for readability */
margin-bottom: 15px;
}
.main-container1 p {
height: 70px;
font-size: 18px;
color: #555; /* Lighter text color */
margin: 5px 0;
}
.main-container1 .temperature {
font-size: 36px;
font-weight: bold;
color: #4d90fe; /* Temperature color */
}
/* Responsive design for smaller screens */
@media (max-width: 600px) {
.main-container1 {
width: 200px; /* Smaller width on mobile */
height: 250px; /* Adjust height */
padding: 15px; /* Less padding */
}
.main-container1 h2 {
font-size: 20px; /* Smaller city name */
}
.main-container1 .temperature {
font-size: 28px; /* Smaller temperature */
}
}
.main {
min-width: 390px;
display: flex;
justify-content: center;
align-items: center;
margin: 50px auto; /* Combined margin settings */
flex: auto;
gap: 15vh; /* Larger gap for larger screens */
}
/* For screens smaller than 768px (common breakpoint for tablets and phones) */
@media (max-width: 768px) {
.main {
flex-direction: column; /* Stack items vertically */
gap: 10vh; /* Smaller gap for smaller screens */
margin-top: 20px; /* Reduce top margin */
}
}
/* For very small screens like phones (less than 480px) */
@media (max-width: 480px) {
.main {
min-width: 100%; /* Let the container fit smaller screens */
gap: 5vh; /* Smaller gap for very small screens */
}
}
.main-container2{
width: 1000px;
border: 0px solid #56cfe1; /* Border color */
border-radius: 25px; /* Rounded corners */
text-align: center; /* Center text inside */
padding: 20px; /* Internal padding */
background-color: #ffffff; /* White background for the card */
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* Shadow for depth */
transition: transform 0.3s ease;
background-color: #cfbaf0;;
box-shadow: 10px 10px 15px rgba(0, 0, 0, 0.3);
}
.main-container3{
width: 1000px;
border: 0px solid #98f5e1; /* Border color */
border-radius: 25px; /* Rounded corners */
text-align: center; /* Center text inside */
padding: 20px; /* Internal padding */
background-color: #ffffff; /* White background for the card */
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* Shadow for depth */
transition: transform 0.3s ease;
background-color: #cfbaf0;;
box-shadow: 10px 10px 15px rgba(0, 0, 0, 0.3);
}
.main-container4{
width: 1000px;
border: 0px solid ; /* Border color */
border-radius: 25px; /* Rounded corners */
text-align: center; /* Center text inside */
padding: 20px; /* Internal padding */
background-color: #cfbaf0; /* White background for the card */
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* Shadow for depth */
transition: transform 0.3s ease;
background-color: #cfbaf0;
box-shadow: 10px 10px 15px rgba(0, 0, 0, 0.3);
}
.main-container2:hover {
transform: translateY(-10px); /* Lifts the card up on hover */
}
.main-container3:hover {
transform: translateY(-10px); /* Lifts the card up on hover */
}
.main-container4:hover {
transform: translateY(-10px); /* Lifts the card up on hover */
}
body {
background: url('clouds.png') no-repeat center center fixed; /* Uniform background */
background-size: cover; /* Ensures the background covers the entire viewport */
margin: 0; /* Removes default margins */
padding: 0; /* Removes default padding */
font-family: 'Franklin Gothic Medium', 'Arial Narrow', Arial, sans-serif; /* Ensures consistent font usage */
background-color: #333;
}