-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproduct-details.html
139 lines (138 loc) · 4.37 KB
/
product-details.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Quicksand:wght@300;500;700&family=Roboto:wght@700&display=swap" rel="stylesheet">
<title>Document</title>
<style>
:root{
--very-light-pink: #c7c7c7;
--white:#ffffff;
--text-input-field: #f7f7f7;
--black: #000000;
--hospital-green: #acd9b2;
--dark: #232830;
--sm: 14px;
--md: 16px;
--lg: 18px;
}
body {
margin: 0;
font-family: 'Quicksand', sans-serif;
/* font-family: 'Roboto', sans-serif; */
}
.product-detail {
display: grid;
grid-template-rows: auto auto 1fr;
width: 360px;
height: 100vh;
box-shadow: 0px 0px 4px 0px var(--very-light-pink);
}
.close {
position: absolute;
top: 12px;
left: 12px;
height: 14px;
width: 14px;
background-color: var(--text-input-field);
border-radius: 50%;
box-shadow: 0px 0px 4px 0px var(--very-light-pink);
padding: 12px;
cursor: pointer;
}
.product-detail > img {
width: 100%;
height: 360px;
border-radius: 0 0 24px 24px;
object-fit: cover;
}
.dots {
text-align: center;
padding-top: 4px;
}
.dot {
cursor: pointer;
height: 8px;
width: 8px;
margin: 0 2px;
background-color: var(--text-input-field);
border-radius: 50%;
display: inline-block;
}
.dots .dot:first-child {
background-color: var(--very-light-pink);
}
.product-info {
display: grid;
grid-template-rows: auto auto 1fr auto;
padding: 16px;
}
.product-info p:first-child {
font-size: var(--md);
font-weight: 700;
margin: 4px 0;
}
.product-info p:nth-child(2) {
font-size: var(--md);
color: var(--dark);
margin: 4px 0;
}
.product-info p:nth-child(3) {
font-size: var(--sm);
color: var(--dark);
margin: 20px 0;
}
.primary-button {
padding: 8px;
font-size: var(--md);
font-weight: 700;
color: var(--white);
font-family: 'Quicksand', sans-serif;
background-color: var(--hospital-green);
border-radius: 8px;
border: none;
cursor: pointer;
width: 100%;
}
.add-to-cart-button {
display: flex;
align-items: center;
justify-content: center;
}
@media (max-width: 640px) {
.product-detail {
width: 100%;
}
.close {
display: none;
}
}
</style>
</head>
<body>
<aside class="product-detail">
<div class="close">
<img src="./icons/icon_close.png" alt="close">
</div>
<img src="https://images.pexels.com/photos/159866/books-book-pages-read-literature-159866.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=1" alt="book">
<div class="dots">
<span class="dot"></span>
<span class="dot"></span>
<span class="dot"></span>
</div>
<div class="product-info">
<p>$35,00</p>
<p>Book</p>
<p>Lorem, ipsum dolor sit amet consectetur adipisicing elit. Minus eos qui, pariatur alias distinctio reprehenderit saepe a perferendis cum est doloremque quaerat, dicta, earum quibusdam harum aspernatur! Harum, quisquam magnam?</p>
<button class="primary-button add-to-cart-button">
<img src="./icons/bt_add_to_cart.svg" alt="add to cart">
Add to cart
</button>
</div>
</aside>
</body>
</html>