Skip to content

Commit d7479b0

Browse files
committed
Done
1 parent d08f714 commit d7479b0

1 file changed

Lines changed: 164 additions & 0 deletions

File tree

productpage/style.css

Lines changed: 164 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,164 @@
1+
img {
2+
max-width: 100%;
3+
}
4+
5+
p {
6+
font-size: 14px;
7+
font-family: 'Montserrat';
8+
font-weight: 500;
9+
color: hsl(228, 12%, 48%);
10+
11+
}
12+
13+
body {
14+
background: hsl(30, 38%, 92%);
15+
}
16+
17+
.container-fluid {
18+
width: 1440px;
19+
}
20+
21+
.mainContainer {
22+
width: 600px;
23+
height: 450px;
24+
margin: auto;
25+
display: flex;
26+
align-items: center;
27+
margin-top: 100px;
28+
border-radius: 10px;
29+
background: hsl(0, 0%, 100%);
30+
}
31+
32+
.leftcontainer {
33+
width: 50%;
34+
}
35+
36+
.rightcontainer p:first-child {
37+
text-transform: uppercase;
38+
letter-spacing: 5px;
39+
font-weight: 500;
40+
color: hsl(228, 12%, 48%);
41+
}
42+
43+
.leftcontainer img {
44+
height: 450px;
45+
/* width: 50%; */
46+
border-radius: 10px 0 0 10px;
47+
}
48+
49+
.hideMobile {
50+
display: none;
51+
}
52+
53+
.rightcontainer {
54+
width: 50%;
55+
padding: 0 35px;
56+
}
57+
58+
.rightcontainer h2 {
59+
font-family: 'Fraunces';
60+
font-weight: 700;
61+
}
62+
63+
.rightcontainer .price {
64+
display: flex;
65+
align-items: center;
66+
}
67+
68+
.rightcontainer .price h2 {
69+
font-family: 'Fraunces';
70+
font-weight: 700;
71+
display: inline;
72+
color: #3c8067;
73+
/* font-family: Montserrat; */
74+
font-family: Fraunces;
75+
}
76+
77+
.rightcontainer .price span {
78+
font-family: Montserrat;
79+
font-weight: 500;
80+
color: hsl(228, 12%, 48%);
81+
display: inline;
82+
text-decoration: line-through;
83+
margin-left: 10px;
84+
margin-top: -10px;
85+
font-size: 14px;
86+
}
87+
88+
.rightcontainer .cart {
89+
font-family: Montserrat;
90+
display: block;
91+
border: none;
92+
margin-top: 20px;
93+
padding: 10px 20px;
94+
font-weight: 500;
95+
color: hsl(0, 0%, 100%);
96+
background: #3c8067;
97+
border-radius: 10px;
98+
width: 100%;
99+
}
100+
101+
.rightcontainer .cart:hover {
102+
background: #184131;
103+
}
104+
105+
/*
106+
107+
Responsive for mobile
108+
109+
*/
110+
111+
@media (max-width: 375px) {
112+
.container-fluid {
113+
width: 320px;
114+
padding: 0;
115+
}
116+
117+
.mainContainer {
118+
width: 320px;
119+
height: auto;
120+
display: flex;
121+
flex-direction: column;
122+
overflow: hidden;
123+
}
124+
125+
img {
126+
display: none;
127+
}
128+
129+
.hideMobile {
130+
display: block;
131+
}
132+
133+
.leftcontainer {
134+
display: block;
135+
width: 100%;
136+
}
137+
138+
.leftcontainer img {
139+
height: 200px;
140+
width: 100%;
141+
border-radius: 0;
142+
}
143+
144+
.rightcontainer {
145+
width: 100%;
146+
padding: 20px 20px;
147+
}
148+
149+
.rightcontainer p:first-child {
150+
margin-bottom: 5px;
151+
}
152+
153+
.rightcontainer h2 {
154+
font-size: 30px;
155+
}
156+
157+
.rightcontainer .price h2 {
158+
font-size: 36px;
159+
}
160+
161+
.rightcontainer .cart {
162+
margin-top: 20px;
163+
}
164+
}

0 commit comments

Comments
 (0)