Jump to content

Mobile-Only Edits: Overriding Text Alignment for 1 Block

Recommended Posts

Site URL: https://chameleon-cobalt-rwzt.squarespace.com/

Hi all,

I am trying to optimize a site I am working on for mobile but encountering a lot of challenge. (Side note, it seems like Squarespace needs to expand their mobile/tablet only customizations a lot? Other site-building platforms I've used have had much more built in flexibility. 

I am trying to figure out how to override the text and button alignment only within one block on the homepage. I'm not quite sure what I'm doing wrong... nothing seems to affect the text. Does anyone have any tips? 

@media screen only and (max-width: 640px) {
  #block-a655a39c1604a6f3cee0 {
    text-align: center !important ;
    align: center !important;
    .button-block>div {
		text-align: center !important;
    }
  }
}

password = rashida

Link to comment
  • Replies 1
  • Views 174
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

You mean center Welcome to the garden text + button on mobile?

Add to Design > Custom CSS

/* Mobile Welcome to the garden text */
@media screen and (max-width:767px) {
div#block-a655a39c1604a6f3cee0 * {
    text-align: center !important;
}
div#block-242a33d4975bff65945c div {
    text-align: center;
}
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.