/*
 * Clareza Acadêmica — footer global
 * Camada escopada para preservar os destinos e as classes legadas.
 */

.footer-clarity {
    --footer-primary: #667eea;
    --footer-primary-hover: #545fcb;
    --footer-primary-soft: #f0f1ff;
    --footer-surface: #ffffff;
    --footer-canvas: #f6f7fb;
    --footer-ink: #1f2937;
    --footer-muted: #6b7280;
    --footer-subtle: #9ca3af;
    --footer-border: #e5e7eb;
    --footer-border-strong: #d8dce5;
    margin-top: 3rem;
    padding: 1.75rem 0 1.25rem;
    overflow: visible;
    border-top: 1px solid var(--footer-border);
    background: var(--footer-canvas);
    color: var(--footer-ink);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.footer-clarity::before {
    display: none;
}

.footer-clarity .footer-clarity-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding-bottom: 1.25rem;
}

.footer-clarity .footer-brand-block {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    min-width: 0;
}

.footer-clarity .footer-brand-mark {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 44px;
    border-radius: 12px;
    background: var(--footer-primary-soft);
    color: var(--footer-primary);
    font-size: 1rem;
}

.footer-clarity .footer-brand-block > div {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 0.15rem;
}

.footer-clarity .footer-brand-name {
    color: var(--footer-ink);
    font-size: 0.95rem;
    font-weight: 750;
    letter-spacing: -0.02em;
}

.footer-clarity .footer-brand-note {
    color: var(--footer-muted);
    font-size: 0.78rem;
    line-height: 1.45;
}

.footer-clarity .footer-social-group {
    display: flex;
    align-items: flex-end;
    flex-direction: column;
    gap: 0.45rem;
}

.footer-clarity .footer-section-label {
    color: var(--footer-muted);
    font-size: 0.7rem;
    font-weight: 750;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.footer-clarity .footer-social-links {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin: 0;
}

.footer-clarity .social-link {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--footer-border-strong);
    border-radius: 11px;
    background: var(--footer-surface);
    color: var(--footer-muted);
    box-shadow: none;
    font-size: 1rem;
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

.footer-clarity .social-link:hover {
    border-color: #dfe2ff;
    background: var(--footer-primary-soft);
    color: var(--footer-primary-hover);
    box-shadow: none;
    transform: none;
}

.footer-clarity .footer-copyright {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--footer-border);
    color: var(--footer-muted);
    text-align: left;
    font-size: 0.8rem;
}

.footer-clarity .footer-copyright-text {
    margin: 0;
    white-space: nowrap;
}

.footer-clarity .footer-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.15rem;
    margin: 0;
}

.footer-clarity .footer-link {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    padding: 0.45rem 0.55rem;
    border-radius: 9px;
    color: #4b5563;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.footer-clarity .footer-link i {
    color: var(--footer-primary);
}

.footer-clarity .footer-link:hover {
    background: var(--footer-primary-soft);
    color: var(--footer-primary-hover);
    text-decoration: none;
}

.footer-clarity .footer-separator {
    display: none;
}

.footer-clarity .footer-lgpd-note {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--footer-muted);
    font-size: 0.74rem;
    font-weight: 600;
    white-space: nowrap;
}

.footer-clarity .footer-lgpd-note i {
    color: #10b981;
}

.footer-clarity a:focus-visible {
    outline: 3px solid rgba(102, 126, 234, 0.28);
    outline-offset: 2px;
}

@media (max-width: 991.98px) {
    .footer-clarity .footer-clarity-main {
        align-items: flex-start;
    }

    .footer-clarity .footer-copyright {
        grid-template-columns: 1fr auto;
    }

    .footer-clarity .footer-links {
        grid-column: 1 / -1;
        grid-row: 2;
        justify-content: flex-start;
        flex-wrap: wrap;
    }
}

@media (max-width: 767.98px) {
    .footer-clarity {
        margin-top: 2rem;
        padding: 1.5rem 0 calc(5.25rem + env(safe-area-inset-bottom));
    }

    .footer-clarity .container {
        padding-inline: 1rem;
    }

    .footer-clarity .footer-clarity-main {
        align-items: center;
        flex-direction: column;
        gap: 1.2rem;
        padding-bottom: 1.1rem;
        text-align: center;
    }

    .footer-clarity .footer-brand-block {
        align-items: center;
        flex-direction: column;
        gap: 0.6rem;
    }

    .footer-clarity .footer-social-group {
        align-items: center;
    }

    .footer-clarity .footer-social-links {
        justify-content: center;
        gap: 0.4rem;
    }

    .footer-clarity .social-link {
        width: 44px;
        height: 44px;
    }

    .footer-clarity .footer-copyright {
        display: flex;
        align-items: center;
        flex-direction: column;
        gap: 0.55rem;
        text-align: center;
    }

    .footer-clarity .footer-copyright-text {
        white-space: normal;
    }

    .footer-clarity .footer-links {
        justify-content: center;
        gap: 0.1rem;
    }

    .footer-clarity .footer-link {
        padding-inline: 0.45rem;
    }
}

@media (max-width: 390px) {
    .footer-clarity .footer-social-links {
        gap: 0.3rem;
    }

    .footer-clarity .footer-links {
        display: grid;
        width: 100%;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.2rem;
    }

    .footer-clarity .footer-link {
        justify-content: center;
        min-width: 0;
    }

    .footer-clarity .footer-link:last-of-type {
        grid-column: 1 / -1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .footer-clarity *,
    .footer-clarity *::before,
    .footer-clarity *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
