M
M
MonsterAndrew2018-04-16 17:41:05
Layout
MonsterAndrew, 2018-04-16 17:41:05

How to drop one word below the line?

Good afternoon. How can I make the word "in" below "Work" one line, and "minimalism" below "in" also one line? Those. such a ladder of words. The code:

<h2 class="heading">Work <span class="in">in</span> <span class="minimal">minimalism</span></h2>

5ad4b5f9c154d230221909.png

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
Ivan Bogachev, 2018-04-16
@MonsterAndrew

so that the word "in" is one line below "Work" and "minimalism" is also one line below "in"?

.in {
    vertical-align: -1em;
}

.minimal {
    vertical-align: -2em;
}

P
Pavel Kornilov, 2018-04-16
@KorniloFF

<style>
  .in {
    position: relative;
    top: 1em;
  }
  .minimal {
    position: relative;
    top: 2em;
  }
</style>

<h2 class="heading">Work <span class="in">in</span> <span class="minimal">minimalism</span></h2>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question