/* footer.css */
/* ================================================
   FOOTER BLOCK (БЭМ-структура)
   ================================================ */

:root {
    --footer-bg: rgb(4, 80, 160);
    --footer-text: rgba(255, 255, 255, 0.9);
    --footer-link-hover: #ffffff;
    --footer-border: rgba(255, 255, 255, 0.1);
    --footer-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    font-size: 0.95rem;
    position: relative;
    z-index: 100;
    width: 100%;
    /* Гарантирует 100% ширину */
    box-sizing: border-box;
    /* Предотвращает выход за границы */
    overflow: hidden;
    /* Скрывает любые выходящие элементы */
}

/* Добавьте этот новый блок для основного контейнера */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
    box-sizing: border-box;
}

/* Footer Menu */
.footer__menu {
    border-bottom: 1px solid var(--footer-border);
    padding-bottom: 2.5rem;
}

.footer__menu-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer__menu-item {
    margin-bottom: 0.75rem;
}

.footer__menu-link {
    color: var(--footer-text);
    text-decoration: none;
    transition: var(--footer-transition);
    display: inline-block;
    line-height: 1.4;
    position: relative;
}

.footer__menu-link:hover {
    color: var(--footer-link-hover);
    transform: translateX(5px);
}

.footer__menu-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 1px;
    background: var(--footer-link-hover);
    transition: var(--footer-transition);
}

.footer__menu-link:hover::after {
    width: 100%;
}

/* Sub-menu (для вложенных пунктов) */
.footer__sub-menu {
    margin-top: 0.5rem;
    padding-left: 1rem;
    list-style: none;
}

.footer__sub-menu .footer__menu-link {
    font-size: 0.9em;
    opacity: 0.8;
}

/* Copyright Section */
.footer__copy {
    margin: 2rem 0;
    text-align: center;
}

.footer__copy-text {
    margin: 0;
    line-height: 1.6;
    opacity: 0.8;
    font-size: 0.9em;
}

/* Legal Navigation */
.footer__legal-nav {
    border-top: 1px solid var(--footer-border);
    padding-top: 2rem;
}

.footer__legal-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer__legal-link {
    color: var(--footer-text);
    text-decoration: none;
    font-size: 0.85em;
    opacity: 0.7;
    transition: var(--footer-transition);
}

.footer__legal-link:hover {
    opacity: 1;
    text-decoration: underline;
}

/* Новая структура футера */
.footer__top {
    padding-bottom: 3rem;
    border-bottom: 1px solid var(--footer-border);
}

.footer__columns {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.footer__col {
    display: flex;
    flex-direction: column;
}

.footer__contact {
    color: var(--footer-text);
    font-size: 0.95rem;
    line-height: 1.5;
    display: block;
    transition: var(--footer-transition);
}

.footer__contact:hover {
    color: var(--footer-link-hover);
}

.footer__socials {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.social-link {
    display: block;
    width: 32px;
    height: 32px;
    transition: transform 0.3s ease;
}

.social-link:hover {
    transform: translateY(-3px);
}

.social-link img {
    width: 100%;
    height: auto;
    display: block;
}

/* Стили для кастомного меню в футере */
.footer__custom-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer__custom-menu li {
    margin-bottom: 0.75rem;
}

.footer__custom-menu a {
    color: var(--footer-text);
    text-decoration: none;
    transition: var(--footer-transition);
    display: inline-block;
    line-height: 1.4;
    position: relative;
}

.footer__custom-menu a:hover {
    color: var(--footer-link-hover);
    transform: translateX(5px);
}

.footer__custom-menu a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 1px;
    background: var(--footer-link-hover);
    transition: var(--footer-transition);
}

.footer__custom-menu a:hover::after {
    width: 100%;
}

/* Добавьте в конец файла */

/* Стили для заголовка контактов */
.footer__contacts-title {
    color: #fff;
}

/* Обертка для контактных данных */
.footer__contacts-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.copy__nav {
    margin-top: 1.5rem;
    text-align: center;
}

.copy__nav--list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.copy__nav--list li {
    margin: 0;
}

.copy__nav--list a {
    color: white !important;
    text-decoration: none;
    font-size: 0.85em;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.copy__nav--list a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* ================================================
   MEDIA QUERIES
   ================================================ */
@media (max-width: 1024px) {
    .footer__container {
        padding: 0 1.5rem;
        gap: 2rem;
    }

    .footer__menu-list {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer__columns {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer__col-3 {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .footer {
        padding: 2rem 0;
        /* Уменьшите если нужно */
    }

    .container {
        padding: 0 1.5rem;
        /* Соблюдаем отступы на мобильных */
    }

    .footer__menu-list {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .footer__menu {
        padding-bottom: 1.5rem;
    }

    .footer__legal-list {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1rem;
    }

    .footer__columns {
        grid-template-columns: 1fr;
    }


    .footer__socials {
        justify-content: center;
    }

    .footer__custom-menu {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .footer__col-3 {
        padding-top: 1.5rem;
        border-top: 1px solid var(--footer-border);
        margin-top: 1.5rem;
        grid-column: auto;
    }

    .copy__nav--list {
        flex-direction: column;
        gap: 0.75rem;
    }
}


@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
        /* Уменьшаем отступы на маленьких экранах */
    }

    .footer__copy-text {
        font-size: 0.85em;
    }

    .footer__legal-link {
        font-size: 0.8em;
    }

    .footer__custom-menu {
        grid-template-columns: 1fr;
    }
}