The space of flexible elements does not extend on a small screen

I am trying to add justify-content: space-between;so that both flex elements have equal space between them.

I am trying to allocate space using justify-content: space-between;

Any ideas?

/* SECTION THREE */
.sec-3 {
  background-color: #f1eeee;
  margin-top: -22px;
}

.sec-3-flex {
  background-color: red;
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  justify-content: space-around;
}

.sec-3-flex #iphone-2-img {
  padding-top: 30px;
  background-color: orange;
  margin-right: -10%;
}

.sec-3-flex .sales-copy-wrap {
  background-color: yellow;
}

#iphone-sec-3 {}
<div class="sec-3">
  <!-- iphone image  -->
  <div class="sec-3-flex">
    <!-- Iphone 1 image -->
    <picture id="iphone-sec-3">
      <!-- <source media="(min-width: 320px)" srcset="img/mobile/mobile-iphone-1.jpg"> -->
      <source media="(min-width: 320px)" srcset="img/desktop/images/home_11.jpg">
      <img id="iphone-2-img" src="img_orange_flowers.jpg" alt="Flowers" style="width:50%">
    </picture>
    <div class="sales-copy-wrap">
      <h3>Get organized with events, tasks and notes.</h3>
      <p class="sales-copy">Now more then ever it is critical for smart professionals to stay up to date with important deadlines.</p>
    </div>
  </div>
</div>
Run codeHide result
+4
source share
1

. (picture).

, flex () .

:

picture {
   text-align: right;
}
+1

Source: https://habr.com/ru/post/1681419/


All Articles