Shopify themes, liquid, logos, and UX
I got this code from chatgpt
<style>
.video-container {
position: relative;
width: 100%;
max-width: px; /* Justera efter behov */
margin: 0 auto;
}
video {
width: 100%;
height: auto;
display: block;
}
.video-text {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
color: white;
font-size: 24px;
font-weight: bold;
text-align: center;
white-space: nowrap; /* Förhindrar att texten bryts */
}
</style>
<div class="video-container">
<video muted autoplay playsinline loop>
<source src="/media/cc0-videos/flower.webm" type="video/mp4">
<source src="https://cdn.shopify.com/videos/c/o/v/5ccecaece49047bd9142d51e6ab33156.mp4" type="video/mp4">
</video>
<div class="video-text">Sommarens hetaste bikinis</div>
</div>
which is the code i have right now but I want to have the montserrat textstyle in the middle. website: necessarywear.se password: rewfra
Solved! Go to the solution
This is an accepted solution.
Hi @armin777 😊 Ellie again from BOGOS, #1 Shopify Promotion App (Gifts, Bundles, Upsells, Discounts)
Please follow my steps below:
Step 1. Go to Online Store
Step 2. Find "Edit Code"
Step 3. Go to any CSS file
Step 4. Paste this code anywhere you want in that CSS file
.video-container .video-text{
font-size: calc(var(--font-heading-scale)* 5.2rem) !important;
font-family: var(--font-heading-family) !important;
font-weight: normal !important;
}
*Result:
* If you want to change the size, simply adjust the number "5.2" in my code to reach the size you want
If my code worked, appreciate if you could Like and Accept as Solution!
Hi @armin777 😊
I’m Ellie from BOGOS, #1 Shopify Promotion App (Gifts, Bundles, Upsells, Discounts)
I just checked out your store, and it looks like the text style in the middle of your video is Montserrat (though it's bold). Could you clarify if you'd like to change it to regular, make it bigger, or adjust it in another way?
If it worked, appreciate if you could Like and Accept as Solution!
Yes I would like the text to be like this (Regular)
This is an accepted solution.
Hi @armin777 😊 Ellie again from BOGOS, #1 Shopify Promotion App (Gifts, Bundles, Upsells, Discounts)
Please follow my steps below:
Step 1. Go to Online Store
Step 2. Find "Edit Code"
Step 3. Go to any CSS file
Step 4. Paste this code anywhere you want in that CSS file
.video-container .video-text{
font-size: calc(var(--font-heading-scale)* 5.2rem) !important;
font-family: var(--font-heading-family) !important;
font-weight: normal !important;
}
*Result:
* If you want to change the size, simply adjust the number "5.2" in my code to reach the size you want
If my code worked, appreciate if you could Like and Accept as Solution!
Thank you
Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025