/* ==========================================================================
   nial.group — единый подвал сайта (footer)
   Файл: /local/static/site-footer/site-footer.css
   Подключается из /bitrix/templates/aspro-allcorp3metal/page_blocks/footer_1.php
   Нейминг изолирован префиксом .site-footer__, шапку и контент не затрагивает.
   ========================================================================== */

.site-footer {
    --sf-bg: #2B2B2B;
    --sf-text: #CCCCCC;
    --sf-text-hover: #FFFFFF;
    --sf-muted: #B0B0B0;
    --sf-accent: #1F3680;
    --sf-accent-hover: #2A48A8;
    --sf-line: rgba(255, 255, 255, 0.1);
    --sf-gap: 40px;
    --sf-radius: 6px;

    background: var(--sf-bg);
    color: var(--sf-text);
    font-family: "Roboto", Arial, Helvetica, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    margin-top: 0;
    padding: 0;
    border: 0;
}

.site-footer a {
    color: var(--sf-text);
    text-decoration: none;
    transition: color 0.2s ease;
}

.site-footer a:hover,
.site-footer a:focus-visible {
    color: var(--sf-text-hover);
}

.site-footer a:focus-visible,
.site-footer button:focus-visible {
    outline: 2px solid #7FA0FF;
    outline-offset: 2px;
    border-radius: 4px;
}

.site-footer__inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 48px 24px 0;
}

/* ---------- Сетка 4 равные колонки ---------- */

.site-footer__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--sf-gap);
    align-items: start;
    padding-bottom: 36px;
}

.site-footer__col {
    min-width: 0;
}

/* Заголовки колонок */
.site-footer__title {
    margin: 0 0 18px;
    color: #FFFFFF;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: 0.01em;
}

/* ---------- Списки ссылок ---------- */

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

.site-footer__list-item {
    margin: 0 0 10px;
    padding: 0;
}

.site-footer__list-item:last-child {
    margin-bottom: 0;
}

.site-footer__link {
    display: inline-block;
    color: var(--sf-text);
    font-size: 14px;
    line-height: 1.4;
}

/* «Весь каталог ->» — чуть заметнее остальных пунктов */
.site-footer__list-item--more .site-footer__link {
    color: #FFFFFF;
    font-weight: 600;
}

.site-footer__list-item--more .site-footer__link::after {
    content: "";
    display: inline-block;
    width: 6px;
    height: 6px;
    margin-left: 8px;
    border-top: 1.5px solid #FFFFFF;
    border-right: 1.5px solid #FFFFFF;
    transform: rotate(45deg) translateY(-1px);
    opacity: 0.75;
}

.site-footer__list-item--more .site-footer__link:hover {
    color: #FFFFFF;
}

/* ---------- Контакты ---------- */

.site-footer__contacts {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.site-footer__phone {
    display: flex;
    align-items: center;
    gap: 10px;
}

.site-footer__icon {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    color: #FFFFFF;
    opacity: 0.85;
}

.site-footer__icon svg {
    display: block;
    width: 100%;
    height: 100%;
}

.site-footer__phone-link {
    color: #FFFFFF !important;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}

.site-footer__phone-link:hover {
    color: #FFFFFF !important;
    opacity: 0.85;
}

.site-footer__schedule {
    margin: -8px 0 0 28px;
    color: var(--sf-muted);
    font-size: 13px;
    line-height: 1.4;
}

/* Кнопка «Отправить заявку на расчет» */
.site-footer__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: auto;
    max-width: 100%;
    padding: 12px 20px;
    border: 1px solid var(--sf-accent);
    border-radius: 8px;
    background: var(--sf-accent);
    color: #FFFFFF !important;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.site-footer__cta:hover,
.site-footer__cta:focus-visible {
    background: var(--sf-accent-hover);
    border-color: var(--sf-accent-hover);
    color: #FFFFFF !important;
}

.site-footer__cta:active {
    transform: translateY(1px);
}

/* Email + копирование в 1 клик */
.site-footer__email-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.site-footer__email {
    color: var(--sf-text) !important;
    font-size: 15px;
}

.site-footer__email:hover {
    color: #FFFFFF !important;
}

.site-footer__copy {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--sf-radius);
    background: transparent;
    color: var(--sf-text);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.site-footer__copy:hover {
    background: #3A3A3A;
    border-color: rgba(255, 255, 255, 0.32);
    color: #FFFFFF;
}

.site-footer__copy svg {
    width: 14px;
    height: 14px;
    display: block;
}

.site-footer__copy-tip {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    padding: 4px 8px;
    border-radius: 4px;
    background: #FFFFFF;
    color: #2B2B2B;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 5;
}

.site-footer__copy-tip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: #FFFFFF;
}

.site-footer__copy.is-copied .site-footer__copy-tip,
.site-footer__copy:hover .site-footer__copy-tip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Адрес */
.site-footer__address {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: var(--sf-text);
    font-size: 14px;
    line-height: 1.45;
}

.site-footer__address .site-footer__icon {
    margin-top: 2px;
}

.site-footer__address-label {
    display: block;
    color: var(--sf-muted);
    font-size: 13px;
}

.site-footer__geo {
    margin: 0 0 0 28px;
    color: var(--sf-muted);
    font-size: 13px;
    line-height: 1.4;
}

/* Соцсети и доверие */
.site-footer__social {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.site-footer__social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--sf-radius);
    background: #3A3A3A;
    transition: background 0.2s ease, transform 0.15s ease;
}

.site-footer__social-link:hover {
    background: #4A4A4A;
    transform: translateY(-1px);
}

.site-footer__social-link svg {
    width: 22px;
    height: 22px;
    display: block;
    fill: #FFFFFF;
}

.site-footer__reviews {
    display: inline-flex;
    align-items: center;
    margin-top: 4px;
}

.site-footer__reviews img {
    display: block;
    max-width: 150px;
    height: auto;
}

/* ---------- Нижняя полоса ---------- */

.site-footer__bottom {
    border-top: 1px solid var(--sf-line);
}

.site-footer__bottom-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 18px 24px;
    font-size: 13px;
    line-height: 1.45;
}

.site-footer__copyright {
    color: var(--sf-muted);
    flex: 0 1 auto;
}

.site-footer__copyright-details {
    display: block;
    margin-top: 4px;
    color: #9A9A9A;
    font-size: 12px;
}

.site-footer__disclaimer {
    flex: 1 1 auto;
    text-align: center;
    color: var(--sf-muted);
}

.site-footer__legal {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 18px;
    flex: 0 1 auto;
    flex-wrap: wrap;
}

.site-footer__legal-link {
    padding: 0;
    border: 0;
    background: none;
    color: var(--sf-text);
    font: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

.site-footer__legal-link:hover,
.site-footer__legal-link:focus-visible {
    color: var(--sf-text-hover);
}

/* Постоянно висящий ярлык cookie убираем: настройки теперь в нижней полосе подвала */
.cookie-float-btn {
    display: none !important;
}

/* ---------- Планшеты ---------- */

@media (max-width: 1024px) {
    .site-footer__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px;
    }

    .site-footer__bottom-inner {
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 14px;
    }

    .site-footer__disclaimer {
        order: 3;
        flex: 1 1 100%;
        text-align: left;
    }
}

/* ---------- Смартфоны: аккордеоны ---------- */

@media (max-width: 767px) {
    .site-footer__inner {
        padding: 28px 16px 0;
    }

    .site-footer__grid {
        grid-template-columns: 1fr;
        gap: 0;
        padding-bottom: 20px;
    }

    /* Колонки 1–3 — аккордеоны */
    .site-footer__col--collapsible {
        border-bottom: 1px solid var(--sf-line);
    }

    .site-footer__col--collapsible .site-footer__title {
        margin: 0;
        padding: 16px 34px 16px 0;
        position: relative;
        font-size: 15px;
        cursor: pointer;
        user-select: none;
    }

    /* Шеврон */
    .site-footer__col--collapsible .site-footer__title::after {
        content: "";
        position: absolute;
        top: 50%;
        right: 8px;
        width: 8px;
        height: 8px;
        margin-top: -6px;
        border-right: 2px solid #FFFFFF;
        border-bottom: 2px solid #FFFFFF;
        transform: rotate(45deg);
        transition: transform 0.25s ease;
        opacity: 0.8;
    }

    .site-footer__col--collapsible.is-open .site-footer__title::after {
        transform: rotate(-135deg);
        margin-top: -2px;
    }

    .site-footer__col--collapsible .site-footer__list {
        overflow: hidden;
        max-height: 0;
        opacity: 0;
        transition: max-height 0.3s ease, opacity 0.25s ease, padding 0.3s ease;
        padding-bottom: 0;
    }

    .site-footer__col--collapsible.is-open .site-footer__list {
        max-height: 500px;
        opacity: 1;
        padding-bottom: 14px;
    }

    /* Колонка 4 — всегда открыта */
    .site-footer__col--contacts {
        padding: 20px 0 8px;
    }

    .site-footer__col--contacts .site-footer__title {
        margin-bottom: 16px;
    }

    .site-footer__cta {
        width: 100%;
        padding: 14px 16px;
    }

    .site-footer__phone-link {
        font-size: 19px;
    }

    /* Нижняя полоса в одну колонку */
    .site-footer__bottom-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 18px 16px 24px;
    }

    .site-footer__disclaimer {
        text-align: left;
    }

    .site-footer__legal {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}

/* Уважаем настройку «меньше движения» */
@media (prefers-reduced-motion: reduce) {
    .site-footer *,
    .site-footer *::after,
    .site-footer *::before {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

/* Региональный подвал: статус поставок на городских поддоменах */
.site-footer__region-status {
    margin: 0 0 6px;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
}
