C
C
Caesar13372020-01-07 11:38:57
JavaScript
Caesar1337, 2020-01-07 11:38:57

Why are styles not applied to popup in scss?

<div class="header__top">
  <div class="container">
    <div class="header__info info">
      <div class="info__contacts">
        <a href="#" class="info__phone">+38 (096) 309 21 45</a>
        <a href="" class="info__email">[email protected]</a>
      </div>
      <div class="info__consultation consultation">
        <a href="#consultation__popup" class="consultation__link">Бесплатная консультация</a>
        <div id="consultation__popup" class="mfp-hide consultation__popup">
          Hello
        </div>	
      </div>
    </div>
  </div>
</div>

.header {
    &__top {
        .info {
            display: flex;
            justify-content: space-between;
            align-items: center;
            &__contacts {

            }
            &__phone {

            }
            &__email {

            }
            .consultation {
                &__link {
                    color: red
                }
                &__popup {
                    background-color: #fff;
                }
            }
        }
    }
}

Well, respectively, simple javascript, which simply opens a window. The question is, why aren't styles being applied to the consultation__popup class ? But they apply if you take out all scss nesting.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question