/* ============================================================
   footer.css — Подвал сайта
   АНО «Бессмертный подвиг защитников Отечества»
   v3.1 (2026-09-21)

   Требует: style.css (переменные --bpzo-*)
   Брейкпоинты: 992 / 768 / 480 / 360

   Изменения v3.1:
   - ПОЛНОСТЬЮ ПЕРЕДЕЛАН
   - Лента (.georgian-ribbon--footer) — ПЕРВАЯ строка подвала,
     вплотную к верхней границе синего. padding-top у .site-footer = 0.
   - Убраны backdrop-filter и box-shadow — могли давать артефакты
   - Убран !important везде, где не критично
   - margin ленты — только снизу (30px до контента)
   - overflow: hidden у .site-footer — на всякий случай

   Изменения v3.0:
   - Агрессивные !important (отменено в v3.1)
   ============================================================ */

/* ============================================================
   1. ПОДВАЛ
   Никаких отступов сверху. padding-top = 0.
   ============================================================ */
.site-footer {
    position: relative;
    z-index: 11;

    background: #01579B;

    margin: 0 !important;
    padding: 0 0 15px 0 !important;

    border: none;
    box-shadow: none !important;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;

    overflow: hidden;

    color: var(--bpzo-light, #FFD700);
}

/* ============================================================
   2. ГЕОРГИЕВСКАЯ ЛЕНТА — ПЕРВАЯ строка подвала
   Прижата к верхней границе синего блока.
   ============================================================ */
.georgian-ribbon--footer {
    display: block !important;
    width: 100%;
    height: 16px !important;

    margin: 0 0 30px 0 !important;
    padding: 0 !important;

    background: linear-gradient(
        to bottom,
        #000 0%,     #000 20%,
        #FF8C00 20%, #FF8C00 40%,
        #000 40%,    #000 60%,
        #FF8C00 60%, #FF8C00 80%,
        #000 80%,    #000 100%
    ) !important;

    line-height: 0;
    font-size: 0;
    overflow: hidden;
    position: relative;
}

.georgian-ribbon--footer::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.3), transparent);
    animation: ribbonShine 4s ease-in-out infinite;
    transform: translate3d(-100%, 0, 0);
    will-change: transform;
    pointer-events: none;
}

@keyframes ribbonShine {
    0%   { transform: translate3d(-100%, 0, 0); }
    100% { transform: translate3d(100%, 0, 0); }
}

/* ============================================================
   3. СЕТКА ПОДВАЛА
   ============================================================ */
.footer-grid {
    display: grid;
    gap: 30px;
    margin-bottom: 20px;
}

.footer-grid--3col {
    grid-template-columns: 1.5fr 1fr 1.3fr;
}

.footer-col {
    min-width: 0;
}

.footer-title {
    color: var(--bpzo-light, #FFD700);
    font-size: 1.1rem;
    margin: 0 0 12px;
    padding: 0;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    cursor: default;
    pointer-events: none;
    user-select: none;
}

.footer-title::-webkit-details-marker { display: none; }
.footer-title::marker { display: none; content: ''; }

.footer-title > i:first-child {
    color: var(--bpzo-light, #FFD700);
    flex-shrink: 0;
}

.footer-title__text {
    flex: 1;
    min-width: 0;
}

.footer-toggle-icon {
    display: none;
    margin-left: auto;
    font-size: 0.85rem;
    color: var(--bpzo-light, #FFD700);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

/* ============================================================
   4. КОНТАКТЫ
   ============================================================ */
.footer-contacts {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.footer-contacts li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.footer-contacts i {
    color: var(--bpzo-light, #FFD700);
    flex-shrink: 0;
    width: 18px;
    margin-top: 3px;
    text-align: center;
}

.footer-contacts a {
    color: var(--bpzo-light, #FFD700);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-contacts a:hover,
.footer-contacts a:focus-visible {
    color: var(--bpzo-accent, #FFF176);
    text-decoration: underline;
}

/* ============================================================
   5. РЕКВИЗИТЫ
   ============================================================ */
.footer-requisites {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.9;
    color: var(--bpzo-light, #FFD700);
}

.footer-requisites li { word-break: break-word; }

.footer-requisites strong {
    color: var(--bpzo-light, #FFD700);
    font-weight: 700;
}

.footer-muted {
    color: rgba(255, 215, 0, 0.75);
    font-size: 0.88rem;
    line-height: 1.6;
    margin: 0;
}

.footer-muted i {
    color: var(--bpzo-light, #FFD700);
    margin-right: 6px;
}

.footer-muted a {
    color: var(--bpzo-accent, #FFF176);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* ============================================================
   6. НИЖНЯЯ СТРОКА
   ============================================================ */
.footer-bottom {
    border-top: 1px solid rgba(255, 215, 0, 0.3);
    padding-top: 15px;
    margin-top: 5px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.8rem;
    color: rgba(255, 215, 0, 0.6);
}

.footer-copyright { line-height: 1.5; }

/* ============================================================
   7. СОЦСЕТИ
   ============================================================ */
.footer-social {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
}

.footer-social-link {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255, 215, 0, 0.06);
    border: 1px solid var(--bpzo-light, #FFD700);
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
}

.footer-social-link img {
    width: 18px;
    height: 18px;
    display: block;
    object-fit: contain;
}

.footer-social-link:hover,
.footer-social-link:focus-visible {
    border-color: var(--bpzo-accent, #FFF176);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
    background: rgba(255, 215, 0, 0.15);
    transform: translateY(-2px);
}

/* ============================================================
   8. ПРАВОВЫЕ ССЫЛКИ
   ============================================================ */
.footer-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.footer-links a {
    color: rgba(255, 215, 0, 0.6);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover,
.footer-links a:focus-visible {
    color: var(--bpzo-light, #FFD700);
    text-decoration: underline;
}

/* ============================================================
   9. COOKIE-БАННЕР
   ============================================================ */
#cookie-consent-banner {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 20px;
    border-top: 2px solid var(--bpzo-light, #FFD700);
    z-index: 9999;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    animation: cookieSlideUp 0.4s ease-out;
}

#cookie-consent-banner[hidden] { display: none; }

@keyframes cookieSlideUp {
    from { transform: translateY(100%); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}

.cookie-consent-text {
    color: var(--bpzo-light, #FFD700);
    font-size: 0.95rem;
    flex: 1;
    min-width: 200px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.5;
}

.cookie-consent-text i { margin-top: 3px; flex-shrink: 0; }
.cookie-consent-text a { color: var(--bpzo-light, #FFD700); text-decoration: underline; }
.cookie-consent-text a:hover { color: var(--bpzo-accent, #FFF176); }

.cookie-consent-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.cookie-btn {
    padding: 8px 25px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.25s ease;
    font-family: inherit;
}

.cookie-btn--primary {
    background: var(--bpzo-light, #FFD700);
    color: var(--bpzo-dark, #1B2A4A);
    border: none;
}
.cookie-btn--primary:hover,
.cookie-btn--primary:focus-visible {
    background: var(--bpzo-accent, #FFF176);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 215, 0, 0.4);
}

.cookie-btn--outline {
    background: transparent;
    color: var(--bpzo-light, #FFD700);
    border: 1px solid var(--bpzo-light, #FFD700);
}
.cookie-btn--outline:hover,
.cookie-btn--outline:focus-visible {
    background: rgba(255, 215, 0, 0.1);
    border-color: var(--bpzo-accent, #FFF176);
}

.cookie-btn--link {
    background: transparent;
    border: none;
    color: var(--bpzo-light, #FFD700);
    padding: 8px 15px;
    text-decoration: underline;
    font-weight: 400;
}
.cookie-btn--link:hover,
.cookie-btn--link:focus-visible {
    color: var(--bpzo-accent, #FFF176);
}

/* ============================================================
   10. АДАПТИВ
   ============================================================ */

@media (max-width: 992px) {
    .footer-grid--3col {
        grid-template-columns: 1fr 1fr;
        gap: 25px;
    }
    .footer-grid--3col > .footer-col:last-child {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    .georgian-ribbon--footer {
        height: 14px !important;
        margin-bottom: 20px !important;
    }

    .footer-grid--3col {
        grid-template-columns: 1fr;
        gap: 0;
        margin-bottom: 15px;
    }
    .footer-grid--3col > .footer-col:last-child { grid-column: auto; }

    .footer-col { border-bottom: 1px solid rgba(255, 215, 0, 0.15); }
    .footer-col:last-child { border-bottom: none; }

    .footer-title {
        margin: 0;
        padding: 14px 0;
        cursor: pointer;
        pointer-events: auto;
        font-size: 1rem;
        gap: 10px;
    }

    .footer-title > i:first-child { font-size: 1rem; }
    .footer-toggle-icon { display: inline-block; }
    .footer-col[open] .footer-toggle-icon { transform: rotate(180deg); }

    .footer-col[open] > ul,
    .footer-col[open] > p { padding-bottom: 16px; }

    .footer-contacts,
    .footer-requisites { font-size: 0.88rem; line-height: 1.6; }

    .footer-bottom {
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin-top: 15px;
    }
    .footer-links { justify-content: center; }
    .cookie-consent-actions { width: 100%; justify-content: center; }
}

@media (max-width: 480px) {
    .footer-social-link { width: 30px; height: 30px; }
    .footer-social-link img { width: 15px; height: 15px; }
    .cookie-btn { padding: 8px 18px; font-size: 0.8rem; }
}

@media (max-width: 360px) {
    .georgian-ribbon--footer {
        height: 10px !important;
        margin-bottom: 14px !important;
    }

    .footer-title { font-size: 0.95rem; padding: 12px 0; }

    .footer-contacts,
    .footer-requisites,
    .footer-muted { font-size: 0.82rem; line-height: 1.5; }

    .footer-bottom { gap: 10px; font-size: 0.72rem; padding-top: 12px; }
    .footer-copyright { font-size: 0.72rem; text-align: center; line-height: 1.4; }

    .footer-social { gap: 5px; }
    .footer-social-link { width: 28px; height: 28px; border-radius: 7px; }
    .footer-social-link img { width: 14px; height: 14px; }

    .footer-links { gap: 8px; font-size: 0.7rem; }

    #cookie-consent-banner { padding: 14px; gap: 10px; }
    .cookie-consent-text { font-size: 0.82rem; line-height: 1.4; }
    .cookie-consent-text i { font-size: 1rem; }
    .cookie-consent-actions { gap: 6px; width: 100%; }
    .cookie-btn { padding: 7px 14px; font-size: 0.75rem; flex: 1; min-width: 0; }
    .cookie-btn--link { padding: 7px 8px; flex: 0 0 auto; }
}

/* ============================================================
   11. СНИЖЕННАЯ АНИМАЦИЯ
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    #cookie-consent-banner { animation: none !important; }
    .georgian-ribbon--footer::after { animation: none !important; }
    .footer-social-link,
    .cookie-btn { transition: none !important; }
    .footer-social-link:hover,
    .cookie-btn:hover { transform: none !important; }
    .footer-toggle-icon { transition: none !important; }
}

/* ============================================================
   12. ПЕЧАТЬ
   ============================================================ */
@media print {
    .georgian-ribbon--footer { display: none !important; }

    .site-footer {
        background: white !important;
        color: black !important;
        padding-top: 20px !important;
        box-shadow: none !important;
    }

    .footer-social,
    .footer-links,
    #cookie-consent-banner { display: none !important; }

    .footer-col { display: block !important; }
    .footer-col > * { display: block !important; }
    .footer-toggle-icon { display: none !important; }

    .footer-title,
    .footer-requisites,
    .footer-contacts a,
    .footer-contacts i,
    .footer-muted {
        color: black !important;
        text-shadow: none !important;
    }
}