Fix Shop intro responsive

This commit is contained in:
2021-11-07 23:12:48 +01:00
parent 5229105e5d
commit 7242027be9
3 changed files with 74 additions and 31 deletions

View File

@@ -62,10 +62,16 @@
<Cart /> <Cart />
<section class="shop-page__intro" bind:this={introEl}> <section class="shop-page__intro" bind:this={introEl}>
<a href="/" class="back"> <div class="top container">
Back to Houses Of <a href="/" class="back">
</a> <svg width="5" height="8" viewBox="0 0 5 8" fill="none" xmlns="http://www.w3.org/2000/svg">
<span class="shop-title">Shop</span> <path d="M4 1 1 4l3 3" stroke="#fff" stroke-linecap="round" stroke-linejoin="round"/>
</svg>
<span>Back to Houses Of</span>
</a>
<span class="shop-title">Shop</span>
</div>
<SiteTitle <SiteTitle
variant="inline" variant="inline"

View File

@@ -75,7 +75,7 @@
@include bp (sm) { @include bp (sm) {
font-size: 0.333em; font-size: 0.333em;
margin: 0 16px 0 20px; margin: 0 10px 0 20px;
} }
} }
} }

View File

@@ -74,35 +74,48 @@
overflow: hidden; overflow: hidden;
// Top Menu // Top Menu
// Back .top {
.back {
position: absolute; position: absolute;
z-index: 2; z-index: 1;
left: 32px; top: 20px;
top: 32px; left: 0;
color: #fff; padding: 0 20px;
text-decoration: none; display: flex;
font-size: rem(14px); justify-content: space-between;
color: $color-cream; width: 100%;
max-width: 76px; margin: 0 auto;
@include bp (sm) { @include bp (sm) {
max-width: none; top: 32px;
font-size: rem(18px); padding: 0 32px;
} }
}
// Shop
.shop-title {
position: absolute;
z-index: 2;
top: 32px;
left: 50%;
transform: translateX(-50%);
font-size: rem(14px);
color: $color-cream;
@include bp (sm) { // Back
font-size: rem(18px); .back {
display: flex;
align-items: center;
color: #fff;
font-size: rem(14px);
color: $color-cream;
text-decoration: none;
@include bp (sm) {
max-width: none;
font-size: rem(18px);
}
svg {
margin-right: 8px;
}
}
// Shop
.shop-title {
font-size: rem(14px);
color: $color-cream;
@include bp (sm) {
font-size: rem(18px);
}
} }
} }
@@ -114,12 +127,28 @@
left: 50%; left: 50%;
width: 100%; width: 100%;
transform: translate3d(-50%, -50%, 0); transform: translate3d(-50%, -50%, 0);
font-size: clamp(#{rem(88px)}, 10vw, #{rem(140px)}); // font-size: clamp(#{rem(88px)}, 10vw, #{rem(140px)});
text-shadow: 0px 8px 12px rgba(#000, 0.25);
text-align: center; text-align: center;
@include bp (sm) {
top: clamp(#{rem(40px)}, 16vw, #{rem(144px)});
left: 0;
font-size: clamp(#{rem(40px)}, 8vw, #{rem(96px)});
transform: none;
}
@include bp (md) {
top: clamp(#{rem(40px)}, 10vw, #{rem(96px)});
font-size: clamp(#{rem(40px)}, 6vw, #{rem(96px)});
}
span, strong { span, strong {
color: #fff; color: #fff;
} }
span {
font-weight: 300;
}
} }
// Background Image // Background Image
@@ -160,6 +189,7 @@
position: absolute; position: absolute;
z-index: 20; z-index: 20;
bottom: 0; bottom: 0;
left: 0;
width: 100%; width: 100%;
@include bp (md) { @include bp (md) {
@@ -167,6 +197,8 @@
} }
.container { .container {
padding: 0 16px 24px;
@include bp (md) { @include bp (md) {
display: grid; display: grid;
grid-template-columns: 15% auto 15%; grid-template-columns: 15% auto 15%;
@@ -179,7 +211,12 @@
// Shop // Shop
p { p {
margin-right: auto; text-align: center;
margin-bottom: 8px;
@include bp (md) {
margin-right: auto;
}
} }
// Navigation // Navigation