/* ==========================================================================
   Единый подвал сайта + кнопка «наверх»
   ========================================================================== */

.yut-footer {
    --ft-bg: #241a14;
    --ft-ink: #f6ece4;
    --ft-mute: rgba(246, 236, 228, 0.6);
    --ft-line: rgba(246, 236, 228, 0.14);
    --ft-accent: #d8b494;

    position: relative;
    z-index: 1;
    padding: clamp(34px, 4vw, 52px) 0 clamp(24px, 2.6vw, 34px);
    background:
        radial-gradient(circle at 8% 0%, rgba(178, 134, 99, 0.22), transparent 42%),
        radial-gradient(circle at 92% 100%, rgba(178, 134, 99, 0.16), transparent 46%),
        var(--ft-bg);
    color: var(--ft-ink);
    font-size: 16px;
    line-height: 1.5;
}

.yut-footer *,
.yut-footer *::before,
.yut-footer *::after {
    box-sizing: border-box;
}

.ft-inner {
    width: min(1260px, 100%);
    margin: 0 auto;
    padding: 0 20px;
}

/* --- верхняя строка ------------------------------------------------------- */

.ft-top {
    display: flex;
    flex-wrap: wrap;
    gap: 24px 40px;
    align-items: center;
    justify-content: space-between;
    padding-bottom: clamp(22px, 2.4vw, 30px);
}

.ft-brand {
    display: block;
    min-width: 0;
    text-decoration: none;
    color: inherit;
}

.ft-brand__name {
    display: block;
    font-family: "Forum", serif;
    font-size: clamp(1.35rem, 2vw, 1.75rem);
    line-height: 1.2;
    letter-spacing: 0.01em;
    color: var(--ft-ink);
    transition: color .3s ease;
}

.ft-brand:hover .ft-brand__name {
    color: var(--ft-accent);
}

.ft-brand__tagline {
    display: block;
    margin-top: 8px;
    font-family: "Spectral", serif;
    font-style: italic;
    font-size: 0.95rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ft-mute);
}

/* --- соцсети (без кружков) ------------------------------------------------ */

.ft-social {
    display: flex;
    align-items: center;
    gap: clamp(20px, 2.2vw, 30px);
}

.ft-social__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--ft-ink);
    font-size: 24px;
    line-height: 1;
    text-decoration: none;
    opacity: 0.85;
    transition: color .3s ease, opacity .3s ease, transform .3s ease;
}

.ft-social__link:hover,
.ft-social__link:focus-visible {
    color: var(--ft-accent);
    opacity: 1;
    transform: translateY(-3px);
}

.ft-social__link i {
    display: block;
    line-height: 1;
}

.ft-social__link img {
    display: block;
    width: 21px;
    height: 21px;
    filter: brightness(0) invert(1);
    opacity: 0.9;
    transition: filter .3s ease, opacity .3s ease;
}

.ft-social__link:hover img {
    filter: brightness(0) invert(82%) sepia(18%) saturate(560%) hue-rotate(334deg) brightness(96%) contrast(89%);
    opacity: 1;
}

/* --- нижняя строка -------------------------------------------------------- */

.ft-bottom {
    display: flex;
    flex-wrap: wrap;
    gap: 16px 36px;
    align-items: center;
    justify-content: space-between;
    padding-top: clamp(20px, 2.2vw, 28px);
    border-top: 1px solid var(--ft-line);
}

.ft-legal {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 12px;
    font-family: "Spectral", serif;
    font-size: 0.92rem;
    color: var(--ft-mute);
    text-decoration: none;
    transition: color .3s ease;
}

.ft-legal:hover {
    color: var(--ft-ink);
}

.ft-legal__inn {
    color: rgba(246, 236, 228, 0.45);
}

.ft-docs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 22px;
}

.ft-docs__link {
    position: relative;
    font-family: "Spectral", serif;
    font-size: 0.92rem;
    color: var(--ft-mute);
    text-decoration: none;
    transition: color .3s ease;
}

.ft-docs__link::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -4px;
    height: 1px;
    background: var(--ft-accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .35s cubic-bezier(.22, .61, .36, 1);
}

.ft-docs__link:hover {
    color: var(--ft-ink);
}

.ft-docs__link:hover::after {
    transform: scaleX(1);
}

/* --- планшет -------------------------------------------------------------- */

@media (max-width: 991.98px) {
    .ft-top,
    .ft-bottom {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .ft-docs {
        justify-content: center;
    }

    .ft-legal {
        justify-content: center;
    }
}

/* --- телефон -------------------------------------------------------------- */

@media (max-width: 575.98px) {
    .yut-footer {
        font-size: 15px;
    }

    .ft-social {
        gap: 26px;
    }

    /* ссылки на документы — в столбик, чтобы длинные названия читались целиком */
    .ft-docs {
        flex-direction: column;
        gap: 12px;
    }

    .ft-legal {
        flex-direction: column;
        gap: 4px;
    }
}

/* ==========================================================================
   КНОПКА «НАВЕРХ»
   ========================================================================== */

#back-to-top.back-to-top {
    z-index: 99;
    position: fixed;
    right: clamp(18px, 2vw, 32px);
    bottom: clamp(18px, 2vw, 32px);
    width: 56px;
    height: 56px;
    padding: 0;
    line-height: 56px;
    border-radius: 50% !important;
    background-color: #b28663;
    color: #fff9f5;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 16px 32px rgba(122, 78, 45, 0.34);
    transition: background-color .3s ease, transform .3s ease, box-shadow .3s ease;
}

#back-to-top.back-to-top:hover,
#back-to-top.back-to-top:focus-visible {
    background-color: #96694a;
    color: #fff9f5;
    transform: translateY(-4px);
    box-shadow: 0 22px 40px rgba(122, 78, 45, 0.42);
}

#back-to-top.back-to-top .icons {
    display: inline-block;
    width: 26px;
    height: 26px;
    stroke-width: 2.2;
    vertical-align: middle;
    transition: transform .3s ease;
}

#back-to-top.back-to-top:hover .icons {
    transform: translateY(-2px);
}

@media (max-width: 575.98px) {
    #back-to-top.back-to-top {
        width: 50px;
        height: 50px;
        line-height: 50px;
    }

    #back-to-top.back-to-top .icons {
        width: 23px;
        height: 23px;
    }
}
