/**
 * GLOBAL FOOTER STYLES
 * ===================
 * Shared styles for the global footer component.
 * Include this stylesheet on any page that uses the footer.
 */

/* ============================================
   FOOTER - Multi-Column Design
   ============================================ */

footer {
    background: var(--bg-color-light, #f5f5f7);
    /* Subtle gradient overlay at the top for visual separation */
    position: relative;
    padding: 3rem 0 1.5rem;
    margin-top: auto;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(
        to right,
        transparent 0%,
        var(--border-subtle, #e5e5e5) 20%,
        var(--border-medium, #d5d5d5) 50%,
        var(--border-subtle, #e5e5e5) 80%,
        transparent 100%
    );
}

/* Dark mode: slightly darker background */
[data-theme="dark"] footer {
    background: #0a0a0a;
}

/* Light mode: slightly lighter background */
[data-theme="light"] footer {
    background: #fafafa;
}

/* Grid Layout */
.footer-inner {
    width: min(1200px, calc(100% - 0.5rem));
    margin: 0 auto;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 2rem;
}

/* Footer Column */
.footer-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Footer Headings */
.footer-heading {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-color, #0a0a0a);
    margin-bottom: 0.5rem;
}

/* Footer Links */
.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links a {
    font-size: 0.85rem;
    color: var(--text-muted, #666666);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--text-color, #0a0a0a);
}

/* Social Links */
.social-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.social-link {
    display: inline-block;
    font-size: 0.85rem;
    color: var(--text-muted, #666666);
    text-decoration: none;
    transition: color 0.2s ease;
}

.social-link:hover {
    color: var(--text-color, #0a0a0a);
}

/* Brand Column */
.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-color, #0a0a0a);
    text-decoration: none;
    width: fit-content;
}

.footer-logo:hover,
.footer-logo:focus-visible,
.footer-logo:active {
    color: var(--text-color, #0a0a0a);
}

.footer-logo-img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

/* Invert footer logo in light mode */
[data-theme="light"] .footer-logo-img {
    filter: invert(1);
}

.footer-tagline {
    font-size: 0.85rem;
    color: var(--text-muted, #666666);
    line-height: 1.5;
    max-width: 250px;
}

/* Footer Bottom */
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-subtle, #e5e5e5);
    font-size: 0.7rem;
    color: var(--gray, #999999);
}

.footer-copyright {
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.footer-back-to-top {
    color: var(--text-muted, #666666);
    text-decoration: none;
    transition: color 0.2s ease;
    font-size: 0.7rem;
}

.footer-back-to-top:hover {
    color: var(--text-color, #0a0a0a);
}

/* Responsive Design */
@media (max-width: 900px) {
    footer {
        padding: 2rem 0 1.5rem;
    }

    .footer-inner {
        width: min(1200px, calc(100% - 2rem));
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 600px) {
    .footer-inner {
        width: min(1200px, calc(100% - 2.25rem));
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .footer-logo span {
        font-size: 1rem;
    }

    .footer-logo-img {
        width: 28px;
        height: 28px;
    }
}
