/* Футер TEZ: фон из --primary-color, белый текст */

.site_footer {
    background-color: var(--primary-color);
    color: #ffffff;
    font-size: 14px;
    line-height: 1.4;
    width: 100%;
}

.site_footer a {
    color: #ffffff;
}

.site_footer_wrapper {
    box-sizing: border-box;
    margin: 0 auto;
    max-width: 1170px;
    padding: 0 20px;
    width: 100%;
}

/* Верхняя панель: колонки меню + курсы/соцсети */

.site_footer_top_panel {
    padding: 40px 0;
}

.site_footer_columns {
    align-items: flex-start;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin: 0 -8px;
}

.site_footer_menu_col,
.site_footer_aside_col {
    box-sizing: border-box;
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: 0;
    min-width: 160px;
    padding: 0 8px;
}

.site_footer_aside_col {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: 0;
    gap: 24px;
    max-width: 240px;
    min-width: 180px;
}

.site_footer_menu_col_title,
.site_footer_rates_title {
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}

.site_footer_menu_col_title {
    margin-bottom: 20px;
}

.site_footer_menu_list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.site_footer_menu_item {
    margin: 0 0 6px;
}

.site_footer_menu_link {
    color: #ffffff;
    font-size: 12px;
    font-weight: 300;
    line-height: 14px;
    text-decoration: none;
}

.site_footer_menu_link:hover,
.site_footer_menu_link:focus {
    color: #ffffff;
    opacity: 0.9;
    text-decoration: underline;
}

/* Курсы валют: компактная table.rates на синем фоне */

.site_footer_rates_col {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.site_footer_rates_content {
    color: #ffffff;
    font-size: 12px;
    line-height: 1.4;
}

.site_footer_rates_content p {
    margin: 0 0 6px;
}

.site_footer_rates_content table,
.site_footer_rates_content table.rates {
    border-collapse: collapse;
    color: #ffffff;
    margin: 0;
    max-width: 100%;
    width: auto;
}

.site_footer_rates_content table th,
.site_footer_rates_content table td,
.site_footer_rates_content table.rates th,
.site_footer_rates_content table.rates td {
    border: 0;
    color: #ffffff;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.35;
    padding: 3px 0;
    text-align: left;
    vertical-align: top;
    white-space: nowrap;
}

.site_footer_rates_content table.rates td:first-child {
    color: rgba(255, 255, 255, 0.85);
    font-weight: 400;
    padding-right: 10px;
}

.site_footer_rates_content table.rates td:last-child {
    color: #ffffff;
    font-weight: 600;
}

.site_footer_rates_content table.rates td.rates_date {
    color: rgba(255, 255, 255, 0.75);
    font-size: 11px;
    font-weight: 400;
    opacity: 1;
    padding-bottom: 6px;
    text-align: left;
}

/* Соцсети: ряд иконок на синем футере (reuse social_links / new_footer_social_buttons_list) */

.site_footer_social_col {
    margin-top: 16px;
    width: 100%;
}

.site_footer_social_widget {
    width: 100%;
}

.site_footer_social_widget .new_footer_social_buttons_list {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site_footer_social_widget .new_footer_social_buttons_list li {
    margin: 0;
}

.site_footer_social_widget .new_footer_social_buttons_list a {
    align-items: center;
    background-color: #ffffff;
    border-radius: 8px;
    box-sizing: border-box;
    display: flex;
    flex-grow: 0;
    flex-shrink: 0;
    flex-basis: 40px;
    height: 40px;
    justify-content: center;
    overflow: hidden;
    text-decoration: none;
    transition: opacity 0.2s ease;
    width: 40px;
}

.site_footer_social_widget .new_footer_social_buttons_list a:hover {
    opacity: 0.85;
}

.site_footer_social_widget .new_footer_social_buttons_list img,
.site_footer_social_widget .footer_social_icon_img {
    display: block;
    height: 28px;
    max-height: 28px;
    max-width: 28px;
    object-fit: contain;
    width: 28px;
}

/* Нижняя панель: логотип | тексты | платёжные иконки */

.site_footer_bottom_panel {
    padding: 40px 0;
}

.site_footer_bottom {
    align-items: flex-start;
    display: flex;
    flex-wrap: wrap;
    gap: 24px 40px;
    justify-content: space-between;
}

.site_footer_bottom_left {
    display: flex;
    flex-direction: column;
    flex-grow: 0;
    flex-shrink: 0;
    flex-basis: 190px;
    max-width: 220px;
}

.site_footer_logo {
    display: inline-block;
    margin: 0 0 10px;
    max-width: 190px;
    text-decoration: none;
}

.site_footer_logo img {
    display: block;
    height: auto;
    max-width: 100%;
    width: 100%;
}

.site_footer_brand_meta {
    font-size: 12px;
    line-height: 1.5;
}

.site_footer_copyright {
    color: #ffffff;
    font-size: 12px;
    line-height: 1.5;
    margin: 0 0 4px;
}

.site_footer_email {
    font-size: 12px;
    line-height: 1.5;
    margin: 0;
}

.site_footer_email a {
    color: #ffffff;
    text-decoration: underline;
}

.site_footer_email a:hover {
    opacity: 0.9;
}

.site_footer_bottom_right {
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: 0;
    font-size: 12px;
    line-height: 1.5;
    min-width: 240px;
}

/* Правая колонка: платёжные логотипы */
.site_footer_bottom_payments {
    align-items: flex-start;
    display: flex;
    flex-grow: 0;
    flex-shrink: 0;
    flex-basis: auto;
    justify-content: flex-end;
    margin-left: auto;
    max-width: 300px;
}

.site_footer_help,
.site_footer_legal,
.site_footer_privacy,
.site_footer_feedback {
    color: #ffffff;
    font-size: 12px;
    line-height: 1.5;
    margin: 0 0 12px;
}

.site_footer_help:last-child,
.site_footer_legal:last-child,
.site_footer_privacy:last-child,
.site_footer_feedback:last-child {
    margin-bottom: 0;
}

.site_footer_help p,
.site_footer_legal p {
    margin: 0 0 8px;
}

.site_footer_help p:last-child,
.site_footer_legal p:last-child {
    margin-bottom: 0;
}

.site_footer_help a,
.site_footer_legal a,
.site_footer_privacy a,
.site_footer_feedback a {
    color: #ffffff;
    text-decoration: underline;
}

.site_footer_help a:hover,
.site_footer_legal a:hover,
.site_footer_privacy a:hover,
.site_footer_feedback a:hover {
    opacity: 0.9;
}

.site_footer_payment_list {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 16px 20px;
    justify-content: flex-end;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site_footer_payment_item {
    margin: 0;
}

.site_footer_payment_link {
    align-items: center;
    display: flex;
    flex-grow: 0;
    flex-shrink: 0;
    flex-basis: auto;
    line-height: 0;
    text-decoration: none;
}

.site_footer_payment_img {
    display: block;
    height: 24px;
    max-height: 30px;
    max-width: 110px;
    object-fit: contain;
    width: auto;
}

/* Планшет: колонки по две в ряд */

@media all and (max-width: 991px) {
    .site_footer_top_panel {
        padding: 32px 0;
    }

    .site_footer_columns {
        margin: 0 -10px;
    }

    .site_footer_menu_col {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: calc(50% - 20px);
        margin-bottom: 28px;
        max-width: none;
        min-width: 0;
        padding: 0 10px;
    }

    .site_footer_aside_col {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: calc(50% - 20px);
        margin-bottom: 28px;
        max-width: none;
        min-width: 0;
        padding: 0 10px;
    }

    .site_footer_bottom_panel {
        padding: 32px 0;
    }

    .site_footer_bottom_left {
        flex-basis: 190px;
    }

    .site_footer_bottom_right {
        flex-basis: calc(100% - 460px);
        min-width: 200px;
    }

    .site_footer_bottom_payments {
        margin-left: 0;
    }
}

/* Мобильный: колонки на всю ширину, низ столбиком */

@media all and (max-width: 767px) {
    .site_footer_wrapper {
        padding: 0 16px;
    }

    .site_footer_top_panel {
        padding: 28px 0 8px;
    }

    .site_footer_columns {
        margin: 0;
        text-align: center;
    }

    .site_footer_menu_col,
    .site_footer_aside_col {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: 100%;
        margin-bottom: 24px;
        max-width: none;
        min-width: 0;
        padding: 0;
        width: 100%;
    }

    .site_footer_menu_col_title {
        margin-bottom: 14px;
        font-size: 16px;
    }

    .site_footer_menu_link {
        font-size: 16px;
    }

    .site_footer_bottom_panel {
        padding: 24px 0 32px;
    }

    .site_footer_bottom {
        flex-direction: column;
        gap: 20px;
    }

    .site_footer_bottom_left,
    .site_footer_bottom_right,
    .site_footer_bottom_payments {
        flex-grow: 1;
        flex-shrink: 1;
        flex-basis: 100%;
        margin-left: 0;
        max-width: none;
        min-width: 0;
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .site_footer_payment_list {
        justify-content: center;
    }

    .site_footer_logo {
        max-width: 160px;
        margin: 0 auto 20px;
    }

    .site_footer_rates_content table, 
    .site_footer_rates_content table.rates {
        margin: 0 auto;
    }

    .site_footer_rates_content table th,
    .site_footer_rates_content table td,
    .site_footer_rates_content table.rates th,
    .site_footer_rates_content table.rates td {
        white-space: normal;
    }

    .site_footer_social_widget .new_footer_social_buttons_list {
        justify-content: center;
    }
}
