/* Reset di base */
body, html {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    box-sizing: border-box;
    scroll-behavior: smooth;
    background-color: #333;
}

.page {
    display: none;
    padding: 0;
}

.page:not(.hidden) {
    display: block;
}

/* Home Page Layout */
.split-container {
    display: flex;
    flex-direction: row;
    height: 100vh;
}

.split {
    flex: 1;
}

.split.left {
    overflow: hidden;
}

.full-height-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.split.right {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #333;
    text-align: center;
}

.content {
    max-width: 80%;
    margin: auto;
    color: #f4f4f4;
}

.content h1{
    color: #f4f4f4;
    font-size: 2.6rem
}

button {
    margin-top: 20px;
    padding: 10px 20px;
    font-size: 16px;
    border: 0.2vw solid #fff;
    background-color: #00000000;
    color: #fff;
    border-radius: 25px;
    cursor: pointer;
}

button:hover {
    background-color: #ffffff;
    color: #000000;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px 0;
}


.social-button i {
    font-size: 24px;
    color: #f4f4f4;
}


.social-button:hover i {
opacity: 0.6;
}

/* Portfolio Page Layout */
.portfolio-header {
    text-align: center;
    margin: 20px 0;
    color: #f4f4f4;
}

.portfolio-header.hidden {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.portfolio-header h1 {
    font-size: 2.5rem;
    color: #f4f4f4;
}

.portfolio-header p {
    font-size: 1.2rem;
    margin: 5px 0;
    opacity: 0.4;
}

.scroll-to-categories {
    text-align: center;
    margin: 50px 0;
    transition: margin 0.5s ease; /* Animazione più veloce */
}

.scroll-to-categories a {
    color: #f4f4f4;
    font-size: 2rem;
    text-decoration: none;
    transition: color 0.1s ease; /* Animazione più veloce */
}

.scroll-to-categories a.hidden {
    display: none;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* Due categorie per riga */
    gap: 20px;
    padding: 20px;
    opacity: 1;
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out; /* Animazione più veloce */
    margin-top: 10px;
}

.gallery.move-closer {
    transform: translateY(-120px); /* Spostamento più alto */
}

.photo-item {
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border-radius: 5px;
}

.photo-item img {
    width: 100%;
    height: 100%;
    transition: filter 0.3s ease, transform 0.3s ease; /* Animazione più veloce */
    transform: scale(1.03);
    filter: brightness(70%);
}

.photo-item p {
    position: absolute;
    bottom: 10px;
    left: 10px;
    margin: 0;
    color: #fff;  /* Titolo bianco */
    padding: 10px 15px;
    font-size: 2.3rem;
    font-weight: bold;
    transition: left 0.3s ease, font-size 0.3s ease; /* Animazione più veloce */
}

/* On hover: larger title, no background */
.photo-item:hover img {
    filter: brightness(50%);
    transform: scale(1.06);
}

.photo-item:hover p {
    left: 20px;
    font-size: 2.5rem;  /* Titolo più grande al passaggio del mouse */
    background: transparent;  /* Nessuno sfondo al passaggio del mouse */
}

/* Responsive Design */
@media (max-width: 768px) {
    .split-container {
        flex-direction: column;
    }

    .split {
        width: 100%;
        height: auto;
    }

    .gallery {
        grid-template-columns: 1fr;
    }
}
