Solved

I want to change the title size on my product page on mobile and on desktop

imazele
Excursionist
27 0 7

Hi I want to reduce the size of my product page's title on mobile and on desktop ! I want to choose the size myself ! Here is my product page's website link : https://www.five-pocket.com/products/pro-club-heavyweight-cotton-tshirt-white

Capture d’écran 2024-02-01 à 20.17.56.png

Accepted Solution (1)

Spac-es
Shopify Partner
300 90 114

This is an accepted solution.

Add this code in your base.css:

@media (max-width: 749px) {
  .product__title h1 {
    font-size: 20px !important;
  }
}
@media (min-width: 750px) {
  .product__title h1 {
    font-size: 30px !important;
  }
}

Edit the pixels of the font-size to increase or decrease the text size. The first font-size applies to mobile devices, and the second font-size applies to PC devices.

 

Result:

 

1.PNG

 

 

View solution in original post

Replies 2 (2)

Made4uo-Ribe
Shopify Partner
5127 1223 1497

Hi @imazele 

Check this one. 

From your Shopify admin dashboard, click on "Online Store" and then "Themes".

Find the theme that you want to edit and click on "Actions" and then "Edit code".

In the "Assets" folder, click on "base.css, style.css or theme.css" file, depending on which file your theme uses to store its CSS styles. At the bottom of the file, add the following CSS code:

 

@media only screen and (min-width: 749px){
.product__title h1 {
    font-size: 30px;
}
}

 

And save. 

Result:

Made4uoRibe_0-1706817854992.png

This size only in the desktop view. 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

Please don't forget to 

Like

 and 

Mark Solution 

to the post that helped you. Thanks!
Sip, savor, and support – your

Coffee Tip

 helps us keep coding magic.❤️❤️❤️
Need a knowledgeable developer? Come and visit us at

Made4uo.com


Spac-es
Shopify Partner
300 90 114

This is an accepted solution.

Add this code in your base.css:

@media (max-width: 749px) {
  .product__title h1 {
    font-size: 20px !important;
  }
}
@media (min-width: 750px) {
  .product__title h1 {
    font-size: 30px !important;
  }
}

Edit the pixels of the font-size to increase or decrease the text size. The first font-size applies to mobile devices, and the second font-size applies to PC devices.

 

Result:

 

1.PNG