From 5da678115ab38fb83bcbdee613d736b3043b6e46 Mon Sep 17 00:00:00 2001 From: Soni Dhruv Date: Mon, 20 May 2024 15:47:37 +0530 Subject: [PATCH] css for collections page --- src/Pages/CSS/Collections.css | 132 ++++++++++++++++++++++++++++++++++ 1 file changed, 132 insertions(+) create mode 100644 src/Pages/CSS/Collections.css diff --git a/src/Pages/CSS/Collections.css b/src/Pages/CSS/Collections.css new file mode 100644 index 0000000..a18408b --- /dev/null +++ b/src/Pages/CSS/Collections.css @@ -0,0 +1,132 @@ +/* collectionPage.css */ +.collection-page { + font-family: Arial, sans-serif; + color: #333; + padding: 0 160px; +} + +.collection-header { + background-color: #f8d7da; + padding: 20px; + text-align: center; +} + +.collection-container { + display: flex; + padding: 20px; + gap: 20px; + justify-content: space-between; + flex-wrap: wrap; +} + +.collection-filters { + flex: 1; + min-width: 200px; + margin-right: 20px; +} + +.collection-filters h2, +.collection-filters h3 { + margin-bottom: 10px; +} + +.collection-filters label { + display: block; + margin-bottom: 10px; +} + +.collection-products { + flex: 3; + display: flex; + flex-wrap: wrap; + gap: 20px; + border-left: 1px solid #ddd; + padding-left: 20px; +} + +.product-card { + background: #fff; + border: 1px solid #ddd; + border-radius: 8px; + padding: 10px; + text-align: center; + width: calc(33.333% - 20px); + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); + height: 500px; +} + +.product-card img { + max-width: 100%; + height: 300px; + object-fit: cover; + border-radius: 10px; + border-bottom: 1px solid #ddd; + margin-bottom: 15px; +} + +.product-card h3 { + font-size: 1.2em; + margin: 10px 0; +} + +.product-card p { + color: #e74c3c; +} + +.product-card .original-price { + text-decoration: line-through; + color: #999; +} + +.product-card .product-tag { + display: inline-block; + margin-top: 10px; + padding: 5px 10px; + background-color: #e74c3c; + color: #fff; + border-radius: 3px; + font-size: 0.8em; +} + +@media (max-width: 1200px) { + .collection-page { + margin-inline: 50px; + padding: 0px 0px; + } + + .product-card { + width: calc(50% - 20px); + } +} + +@media (max-width: 768px) { + .collection-container { + flex-direction: column; + } + + .collection-filters { + margin-right: 0; + border-right: none; + border-bottom: 1px solid #ddd; + padding-bottom: 20px; + } + + .collection-products { + border-left: none; + padding-left: 0; + } + + .product-card { + width: calc(50% - 20px); + } +} + +@media (max-width: 480px) { + .collection-page { + padding: 0 10px; + } + + .product-card { + width: calc(100% - 20px); + } +}