/* CSS Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 100%; /* Default font size for accessibility */
    scroll-behavior: smooth;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

h1,
h2,
h3,
nav a {
    font-family: var(--font-secondary);
}

body,
p,
button {
    font-family: var(--font-primary);
}

a {
    text-decoration: none;
    color: inherit;
}

ul,
ol {
    list-style: none;
}

button {
    border: none;
    background: none;
    cursor: pointer;
}

input,
textarea {
    font: inherit;
}

:focus {
    outline: none;
}

:root {
    /* Colors */
    --white: hsl(0, 0%, 100%);
    --black: hsl(0, 0%, 0%);
    --grey-200: hsl(0, 0%, 85%);

    /* Colors */
    --white: hsl(0, 0%, 100%);
    --black: hsl(0, 0%, 0%);
    --dark-gray: hsl(0, 0%, 15%);
    --light-gray: hsl(0, 0%, 56%);
    --primary-purple: hsl(259, 50%, 50%);
    --primary-pink: hsl(330, 70%, 60%);
    --hover-gray: hsl(0, 0%, 90%);

    /* Typography */
    --font-primary: 'Alata', sans-serif;
    --font-secondary: 'Josefin Sans', sans-serif;
}

/* Header */
.site-header {
    height: 100svh;
    background-image: url(./images/mobile/image-hero.jpg);
    background-size: cover;
    background-position: center right;
}

/* Navigation */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 2rem 1.5rem;
    position: relative;
}

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

.hamburger-menu {
    display: flex;
}

.desktop-nav,
.mobile-nav {
    display: none;
}

.mobile-nav {
    display: none; /* Default: hidden */
    position: absolute;
    top: 0;
    left: 0;
    background-color: var(--black);
    color: var(--white);
    width: 100%;
    height: 100svh;
    padding: 0rem 3rem;
    transition: 0.3s all ease-in-out; /* Smooth transition */
}

.close-button-mobile {
    position: absolute;
    left: 88%;
    top: 4%;
    transform: translate(-50%, 50%);
}

.nav-links-mobile {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 3rem;
}

.nav-links-mobile a {
    font-size: 1.5rem;
    font-weight: 300;
    text-transform: uppercase;
}

/* Hero section */
.hero {
    height: 90%;
    padding: 0 1rem;
    align-content: center;
}

.hero-frame {
    padding: 2rem;
    border: 4px solid var(--white);
}

.hero-title {
    color: var(--white);
    font-weight: 400;
    font-family: var(--font-secondary);
    font-size: clamp(
        2rem,
        5vw,
        3rem
    ); /* Adjusts font size between 2rem and 3rem based on viewport width */
    text-transform: uppercase;
    max-width: 90%; /* Prevents the text from exceeding the frame width */
}

/* Main section */

/* About section */
.about-section {
    padding: 7rem 1rem;
    display: flex;
    justify-content: center;
    flex-direction: column;
    align-items: center;
}

.about-content {
    padding: 2rem 1.5rem;
    text-align: center;
    display: flex;
    justify-content: center;
    flex-direction: column;
    gap: 1.5rem;
}

.about-title {
    font-family: var(--font-secondary);
    font-weight: 300;
    font-size: clamp(
        1.5rem,
        4vw,
        2.5rem
    ); /* Adjusts font size between 1.5rem and 2.5rem based on viewport width */
    text-transform: uppercase;
}

.about-description {
    color: var(--light-gray);
    font-size: clamp(
        1rem,
        2.5vw,
        1.25rem
    ); /* Adjusts font size between 1rem and 1.25rem based on viewport width */
}

/* Gallery section */
.gallery-section {
    display: flex;
    flex-direction: column;
    /* align-items: center; */
    padding-bottom: 6.5rem;
}

.gallery-title {
    transition: 0.3s ease-in-out;
    text-align: center;
    text-transform: uppercase;
    font-weight: 300;
    font-size: clamp(
        1.5rem,
        3vw,
        2.5rem
    ); /* Adjusts font size between 1.5rem and 2.5rem based on viewport width */
}

.gallery-grid {
    display: grid;
    grid-auto-flow: dense;
    grid-template-columns: repeat(auto-fit, minmax(14.75rem, 1fr));
    justify-content: center;
    align-items: center;
    padding: 4rem 2rem;
    gap: 1.5rem;
}

.gallery-item {
    position: relative;
}

.gallery-item img {
    transition: 0.3s;
    filter: brightness(0.7);
}

.gallery-item:hover img {
    cursor: pointer;
    background-color: hsla(0, 0%, 100%, 0.43);
    transform: scale(1.05);
    filter: brightness(1.1);
}

.item-title {
    transition: transform 0.3s;
    color: var(--white);
    position: absolute;
    left: 5%;
    bottom: 15%;
    transform: translateY(0%);
    font-weight: 300;
    text-transform: uppercase;
    width: 50%;
}

.gallery-item:hover .item-title {
    cursor: pointer;
    transform: scale(1.1);
}

/* SEE ALL button */
.see-all-desktop {
    display: none;
}

.see-all-mobile {
    display: flex;
    justify-content: center;
}

.see-all-btn {
    border: 2px solid var(--black);
    padding: 0.5rem 2rem;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.3rem;
}

.see-all-btn {
    position: relative;
    overflow: hidden;
}

.see-all-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background-color: var(--black);
    transition: transform 0.3s ease-in-out;
    z-index: -1;
}

.see-all-btn:hover::after {
    transform: translateX(100%);
}

.see-all-btn:hover {
    color: var(--white); /* Optional: Change text color on hover */
}

/* Footer section */
.site-footer {
    padding: 4rem 3rem;
    background-color: var(--black);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.footer-nav {
    display: flex;
}

.footer-container-left,
.footer-container-right {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

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

.footer-nav-links a {
    color: var(--white);
    text-align: center;
}

.footer-nav-links a::after {
    content: '';
    display: block;
    background-color: var(--white);
    height: 2px;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.footer-nav-links li a:hover::after {
    transform: scaleX(1);
}

.social-icons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
}

.social-icons img {
    transition: 0.3s ease;
}
.social-icons img:hover {
    filter: brightness(0.5);
}

.footer-copyright {
    text-align: center;
    color: var(--light-gray);
}

/* attribution */
.attribution {
    background-color: var(--black);
    color: var(--light-gray);
    padding: 2rem;
    text-align: center;
}

.attribution a {
    text-decoration: none;
    color: var(--white);
}

/* Styles for tablets (min-width: 768px) */
@media (min-width: 768px) {
    /* Update header background for tablets */
    .site-header {
        background-image: url('./images/desktop/image-hero.jpg');
        background-position: center;
        background-size: cover;
    }

    /* Hide hamburger menu and show desktop navigation */
    .hamburger-menu {
        display: none;
    }

    .desktop-nav {
        display: block;
    }

    /* Style desktop navigation links */
    .nav-links-desktop {
        display: flex;
        gap: 2rem;
    }

    .nav-links-desktop a {
        color: var(--white);
        font-size: 18px;
        font-weight: 300;
    }

    .nav-links-desktop a::after {
        content: '';
        display: block;
        height: 2px;
        background-color: var(--white);
        transform: scaleX(0);
        transition: transform 0.3s ease;
    }

    .nav-links-desktop li a:hover::after {
        transform: scaleX(1);
    }

    /* About section */
    .about-section {
        padding: 10rem 1rem;
    }

    /* Adjust gallery header layout */
    .gallery-header {
        padding: 0 2rem;
        display: flex;
        justify-content: space-between;
    }

    /* Update gallery grid for tablets */
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(10.75rem, 1fr));
    }

    .gallery-grid picture {
        display: inline-flex;
        justify-content: center;
    }

    /* Show desktop "See All" button and hide mobile version */
    .see-all-desktop {
        display: block;
    }

    .see-all-mobile {
        display: none;
    }
}

@media (min-width: 992px) {
    .site-footer {
        justify-content: space-between;
        flex-direction: row;
    }

    .footer-container-left,
    .footer-container-right {
        display: flex;
        flex-direction: column;
        align-items: unset;
        gap: 1.5rem;
    }

    .footer-nav-links {
        flex-direction: row;
        gap: 2.5rem;
    }

    .social-icons {
        justify-content: flex-end;
    }
}

@media (min-width: 1025px) {
    .navbar {
        padding: 2rem 3.5rem;
    }

    /* Adjust site logo dimensions */
    .site-logo img {
        width: auto;
        height: auto;
    }

    /* Adjust hero section padding for larger screens */
    .hero {
        padding: 0 3.5rem;
    }

    /* Set a fixed width for the hero frame */
    .hero-frame {
        width: 35rem;
    }

    .nav-links-desktop a {
        font-size: clamp(1.125rem, 2vw + 1rem, 1.2Zrem);
    }

    /* Adjust about section layout for larger screens */
    .about-section {
        padding: 10rem 4rem;
        display: flex;
        justify-content: center;
        flex-direction: row;
        align-items: center;
    }

    /* Set about content to take up half the space */
    .about-content {
        flex-basis: 50%;
    }

    /* Adjust gallery header and grid padding for larger screens */
    .gallery-header,
    .gallery-grid {
        padding: 4rem;
    }
}

@media (min-width: 1200px) {
    /* Align about section content to the bottom for extra-large screens */
    .about-section {
        align-items: flex-end;
    }

    /* Restrict about title width for better alignment */
    .about-title {
        width: 90%;
    }

    /* Style about content with background, padding, and positioning */
    .about-content {
        background-color: var(--white);
        padding: 3rem 0 0 4rem;
        text-align: left;
        position: relative;
        right: 5rem;
        width: 70%;
    }

    .site-footer {
        padding: 4rem 6rem;
    }
}

/* Styles for extra-large screens (min-width: 1440px) */
@media (min-width: 1440px) {
    /* Add consistent horizontal padding for key sections */
    .navbar,
    .hero,
    .about-section,
    .gallery-header,
    .gallery-grid {
        padding: 0 6rem;
    }

    /* Increase vertical padding for the navbar */
    .navbar {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }

    /* Add vertical padding for the about section */
    .about-section {
        padding: 12rem 2rem;
    }

    /* Add vertical padding for the gallery grid */
    .gallery-grid {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }
}
