diff --git a/readme.md b/readme.md index b1f43ed970..639b98b6e2 100644 --- a/readme.md +++ b/readme.md @@ -23,8 +23,8 @@ This is possible because [we use the Parcel library](https://en.parceljs.org/scs ❗️ Replace `` with your GitHub username and copy the links to the `Pull Request` description: -- [DEMO LINK](https://.github.io/layout_product-cards/) -- [TEST REPORT LINK](https://.github.io/layout_product-cards/report/html_report/) +- [DEMO LINK](https://khorets.github.io/layout_product-cards/) +- [TEST REPORT LINK](https://khorets.github.io/layout_product-cards/report/html_report/) ❗️ Copy this `Checklist` to the `Pull Request` description after links, and put `- [x]` before each point after you checked it. diff --git a/src/index.html b/src/index.html index 43745cc17f..bf650e80d4 100644 --- a/src/index.html +++ b/src/index.html @@ -11,8 +11,46 @@ rel="stylesheet" href="./styles/index.scss" /> + -

Product cards

+
+ # +

+ APPLE A1419 iMac 27" Retina 5K Monoblock (MNED2UA/A) +

+

Product code: 195434

+
+
+
+
+
+
+
+
+

Reviews: 5

+
+
+

Price:

+

$2,199

+
+ + BUY + +
diff --git a/src/styles/index.scss b/src/styles/index.scss index 293d3b1f13..aef161b31b 100644 --- a/src/styles/index.scss +++ b/src/styles/index.scss @@ -1,3 +1,121 @@ +$primary-color: #060b35; +$secondary-color: #616070; +$accent-color: #00acdc; + +* { + margin: 0; + padding: 0; + box-sizing: border-box; +} + body { margin: 0; + font-family: 'Roboto', sans-serif; +} + +.card { + margin-top: 25px; + margin-left: 25px; + display: flex; + flex-direction: column; + align-content: space-between; + padding: 32px 16px 16px 16px; + + width: 200px; + height: 408px; + border: 1px solid #f3f3f3; + border-radius: 5px; + + &__image--product { + margin-bottom: 40px; + align-self: center; + width: 160px; + height: 134px; + } + + &__product-name { + margin-bottom: 4px; + color: $primary-color; + font-size: 12px; + font-weight: 500; + } + + &__product-code { + margin-bottom: 16px; + color: $secondary-color; + font-size: 10px; + font-weight: 400; + } + + &__reviews { + margin-bottom: 24px; + display: flex; + justify-content: space-between; + } + + &__price { + margin-bottom: 16px; + display: flex; + justify-content: space-between; + align-items: center; + } + + &__price-name { + font-size: 12px; + color: $secondary-color; + font-weight: 400; + } + + &__price-sum { + font-size: 16px; + color: $primary-color; + font-weight: 700; + } +} + +.stars { + display: flex; +} + +.stars__star { + margin-right: 4px; + height: 16px; + width: 16px; + background-image: url(../images/star.svg); + background-repeat: no-repeat; + background-position: center; +} + +.stars__star:last-child { + margin-right: 0; +} + +.stars--active .stars__star:nth-child(-n + 4) { + background-image: url(../images/star-active.svg); +} + +.reviews-count { + color: $primary-color; + font-size: 10px; + font-weight: 400; +} + +.button { + align-self: center; + width: 166px; + height: 40px; + border-radius: 5px; + background-color: $accent-color; + padding: 12px 69px; + font-size: 14px; + text-transform: uppercase; + text-decoration: none; + color: white; + font-weight: 700; +} + +.button:hover { + background-color: white; + border: 1px solid $accent-color; + color: $accent-color; }