/* Подвал сайта (footer.php): компания, копирайт, ссылки на документы */

.site-footer {
    padding: 16px 0;
    background: #1f201f;
    color: rgba(var(--color-whte--rgb), .7);
    font-size: 14px;
    line-height: 1.5;
}

.site-footer__container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 32px;
}

.site-footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
}

.site-footer__link {
    color: inherit;
    text-decoration: underline;
    text-decoration-color: rgba(var(--color-whte--rgb), .3);
    text-underline-offset: 4px;
    transition: color .2s ease, text-decoration-color .2s ease;
}

.site-footer__link:hover {
    color: var(--color-alt);
    text-decoration-color: currentColor;
}

/* Последний блок страницы вплотную к подвалу: их нижние отступы (72–100px) были рассчитаны на старый подвал.
   Блог выводит подвал после .wrapper, остальные страницы — после main.page */
.page > :last-child,
.wrapper > section:last-of-type {
    margin-bottom: 0;
}

/* На телефоне: всё по центру в столбик; снизу — запас под «домашнюю полоску» iPhone */
@media (max-width: 767.98px) {
    .site-footer {
        padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
        font-size: 13px;
        text-align: center;
    }

    .site-footer__container {
        flex-direction: column;
        align-items: center;
    }

    .site-footer__links {
        flex-direction: column;
        align-items: center;
    }
}
