body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex-grow: 1;
}

.site-footer {
    background-color: var(--secondary-color);
    color: var(--text-color);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 1.4rem;
	position: relative;
    z-index: 1;
}

/* This rule now correctly centers the navigation on desktop */
.footer-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 0;
}

.footer-logo img {
    height: 45px;
    width: auto;
    display: block;
}

.footer-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 2.5rem;
}

.footer-navigation a,
.footer-contact a {
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.2s ease;
}

.footer-navigation a:hover,
.footer-contact a:hover {
    color: var(--accent-color);
}

.footer-bottom {
    padding: 1.5rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.5);
}

.scroll-to-top {
    position: fixed;
    bottom: 2.5rem;
    right: 2.5rem;
    width: 44px;
    height: 44px;
    background-color: var(--primary-color);
    color: var(--text-color-pure-white);
    border-radius: 50%;
    font-size: 2.4rem;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    cursor: pointer;
    z-index: 999;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.scroll-to-top.show {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    background-color: var(--accent-color);
    color: var(--secondary-color);
}

/* ==========================================================================
   Responsive Styles for Mobile
   ========================================================================== */

@media (max-width: 768px) {
    .footer-main {
        /* On mobile, stack all three items vertically and center them */
        flex-direction: column;
        gap: 2.5rem;
    }

    .footer-navigation ul {
        /* On mobile, use a 2-column grid for the links */
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem 2rem;
        text-align: center;
    }
}