/* ==== Layout CSS === */
/* This file contains the CSS for the layout of the website */
/* It includes styles for the header, footer, navbar, grid, page structure */


/* =========================================
   Layout - Site Header and Navigation
   ========================================= */

/* Mobile-first: stacked nav.
   Below 768px, .nav-container (not .site-header) carries the background
   and padding - a plain background on .site-header can never paint above
   the positioned, fixed .mobile-menu panel nested inside it, only a
   positioned sibling like .nav-container can. On >=768px, where the
   full-screen menu doesn't apply, this reverts to the original full-bleed
   bar + centered content pattern (see the media query below). Aug 2026. */
.site-header {
    padding: 0;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    background-color: var(--color-primary);
    position: relative;
    z-index: 300; /* .mobile-menu is a sibling inside <nav> - this keeps the bar above it when open */
}

.site-logo img {
    height: 40px;
    width: auto;
}

.site-nav .nav-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}


.site-nav .nav-item a {
    color: var(--color-text-light);
}

.nav-item a {
    text-decoration: none;
    color: var(--color-text-main);
    font-weight: 600;
    text-decoration: none;
    font-size: 1.125rem; /* 18px */
    transition: color 0.3s ease;
}

.site-nav .nav-item a:hover {
    color: var(--color-secondary);
}


/* Tablet and up: horizontal nav.
   The full-screen mobile menu doesn't apply here, so restore the original
   full-bleed bar (.site-header) + centered content (.nav-container) split. */
@media (min-width: 768px) {
    .site-header {
        background-color: var(--color-primary);
        padding: 1rem 2rem;
    }

    .nav-container {
        background-color: transparent;
        padding: 0;
    }

    .site-nav .nav-links {
        flex-direction: row;
        justify-content: center;
        gap: 2rem;
    }
}




/* =========================================
   Burger Menu
   ========================================= */
    .burger{
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        width: 30px;
        height: 30px;
        background: none;
        border: none;
        cursor: pointer;
        z-index: 10;
    }

    .burger-line{
        width: 100%;
        height: 3px;
        background-color: var(--color-text-light);
        border-radius: 2px;
        transition: all 0.3s ease;
    }

    /* Burger morphs into an X when the menu is open (Aug 2026) - top and
       bottom lines rotate to cross in the middle, middle line fades out.
       8px = line height (3px) + gap (5px), the vertical distance to the
       middle line's position. */
    .burger.open .burger-line:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .burger.open .burger-line:nth-child(2) {
        opacity: 0;
    }

    .burger.open .burger-line:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    /* Hide nav links on mobile */
    .nav-links-wrapper{
        display: none;
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
    
    .nav-links-wrapper.show {
        display: flex;
    }

    @media (min-width: 768px) {
        .burger {
             display: none;
        }

        .nav-links-wrapper {
            display: flex;
            flex-direction: row;
            justify-content: center;
        }
    }









/* =========================================
   Mobile menu - full-screen overlay when burger clicked
   ========================================= */

/* Full-screen solid white panel (Aug 2026, replaces the old narrow
   left-side drawer + dark backdrop). Sits below .site-header (z-index 300)
   so the logo and burger/X stay visible in the header throughout. */
  .mobile-menu {
    position: fixed;
    inset: 0;
    height: 100dvh;
    background-color: var(--color-white);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
    z-index: 200;
    padding: 6rem 2rem 2rem;
    display: flex;
    flex-direction: column;
  }

  /* When menu is open */
  .mobile-menu.open {
    opacity: 1;
    visibility: visible;
  }

  /* Airbnb-style list rows (Aug 2026): thin solid dividers between items
     instead of gaps, each row a full-width block so the whole row - not
     just the text - is tappable. */
  .mobile-nav-links {
    display: flex;
    flex-direction: column;
    font-size: 1.125rem;
  }

  .mobile-nav-links li {
    border-bottom: 1px solid var(--color-grey);
  }

  .mobile-nav-links li:last-child {
    border-bottom: none;
  }

  .mobile-nav-links a {
    display: block;
    width: 100%;
    padding: 1.25rem 0;
    color: var(--color-text-main);
    font-weight: 600;
  }

  /* Locks background scroll while the menu is open (Aug 2026) */
  body.menu-open {
    overflow: hidden;
  }











/* =========================================
   Layout - Footer
   ========================================= */

.site-footer {
    background-color: var(--color-text-main);
    color: var(--color-text-light);
    text-align: left;
    padding: 2rem 2rem;
}

.site-footer h3 {
    color: var(--color-text-light);
    font-size: 1rem; /* 14px */
}

.footer-container {
    display: flex;
    flex-direction: column;
    align-items: left;
    gap: 1rem;
    max-width: 1000px;
    margin: 0 auto;
}

.footer-logo {
    height: 40px;
    margin-bottom: 1rem;
}

.footer-branding {
    font-size: 0.875rem; /* 14px */
}

.footer-links, .footer-social {
    padding-bottom: 2rem;
}

.footer-links {
    padding-bottom: 4rem;
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    color: var(--color-text-light);
}



.footer-links a {
    color: var(--color-text-light);
    transition: color 0.3s ease;
    font-size: 0.875rem; /* 14px */
}

.footer-links a:hover {
    color: var(--color-primary);
}

.footer-social a {
    font-size: 1.5rem;
    padding-bottom: 1rem;
    color: var(--color-text-light);
    transition: color 0.3s ease;
}

.footer-social a:hover {
    color: var(--color-primary);
}

.social-icons {
    display: flex;
    gap: 1rem;
}

.footer-bottom {
    font-size: 0.8rem; /* 14px */
}




/* Responsive layout */
@media (min-width: 768px) {
    .site-footer p, a {
        font-size: 1rem; /* 14px */
    }

    .footer-container {
        flex-direction: row;
        justify-content: space-between;
    }

    .footer-branding {
        text-align: left;
        max-width: 250px;
    }

    .footer-links ul {
        flex-direction: column;
    }

    .footer-links li {
        margin: 0;
        line-height: 1;
    }



    .footer-bottom p {
        font-size: 0.875rem; /* 14px */
        text-align: right;
    }
}
