The user orchardstreet is seeking a way to shift content to the right only on pages with posts, not globally. Johani explains that topic pages have the class archetype-regular, which can be used to target specific pages with CSS. They provide a solution using .archetype-regular to scope the style changes, and note that private message pages use archetype-private_message, which can be included in the selector if needed. orchardstreet thanks Johani for the helpful advice.
It’s not immediately clear to me why you’d want to do that, but the <body> tag in topic pages has a unique class that’s added to it. That class is archetype-regular
You can use that to scope your style changes with something like this
.archetype-regular {
#main-outlet {
// styles go here
}
}
Personal message pages also have something similar and the class in that case is
archetype-private_message
If you want the changes to apply to PM pages, you can include them by adding the selector the the CSS above like so
.archetype-regular,
.archetype-private_message {
#main-outlet {
// styles go here
}
}
Fair warning though, changes to the #main-outlet margins can have unintended consequences. More on that here.