Закрасить margin: auto без указания width родителя

<div class="contact-bg">
                <div class="contact-info">
                    <h2>Contact info</h2>
                    <address>
                        <p>Jalalabad 24 / A, Ambaarkhana, Sylhet, Bangladesh<br></p>
                        <p>[email protected]<br></p>
                        <p>(+88) 017 617 46373<br></p>
                    </address>
                </div>
            </div>
        </div>

Выглядит всё это как-то так

.contact-bg {
    background-color: #2D2D2D;
    max-height: 485px;
    margin-right: auto
}

.contact-info {
    position: relative;
    color: #ffffff;
    background-color: #2c2c2c;
    box-sizing: border-box;
    padding: 125px 55px 125px 80px;
    min-height: 480px;
    max-width: 410px;
}

.contact-info h2 {
    color: #ffffff;
    font-size: 18px;
}

.contact-info h2, .contact-info p {
    margin-bottom: 15px;
}

Вопрос как закрасить margin-right: auto без потери отзывчивости, чтобы сохранить уменьшение отступов при уменьшении ширины экрана?


Ответы (0 шт):