/* ======= Base ======= */
body {
    margin: 0;
    font-family: 'EB Garamond', serif;
    background: #fff;
    color: #111;
}

/* ======= Layout ======= */
.layout {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* ======= Sidebar (izquierda) ======= */
.sidebar {
    width: 22%;
    min-width: 180px;
    padding: 40px 20px;
    box-sizing: border-box;
    border-right: 1px solid #eee;
}

.sidebar h1 {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 40px;
}

.sidebar h1 a {
    text-decoration: none;
    color: inherit;
}

.sidebar h1 a:hover {
    opacity: 0.7;
}

.sidebar nav a {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 300;
    text-decoration: none;
    color: #111;
    margin: 14px 0;
    transition: opacity 0.3s ease;
}

.sidebar nav a:hover {
    opacity: 0.5;
}

.sidebar .nav-text {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 300;
    color: #111;
    margin: 14px 0;
}

/* ======= Galería horizontal ======= */
.gallery-container {
    flex: 1; 
    overflow-x: auto;
    overflow-y: hidden;
}

.gallery-scroll {
    display: flex;
    height: 100%;
    align-items: center;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
}

.gallery-scroll img {
    flex: 0 0 auto;
    max-height: 90vh;
    max-width: 90vw;
    height: auto;
    width: auto;
    margin-right: 25px;
    object-fit: contain;
    scroll-snap-align: center;
}

/* ======= Panel de texto de proyecto ======= */
.project-text {
    flex: 0 0 32vw;
    max-width: 380px;
    align-self: flex-start;
    padding-top: 80px;
    padding-left: 20px;
    padding-right: 40px;
}

.project-text h2 {
    font-weight: 400;
    margin-bottom: 20px;
}

.project-text p {
    line-height: 1.65;
    font-size: 17px;
}

/* ======= Sobre mín ======= */
.about {
    max-width: 380px;           /* igual que el panel de proyecto */
    margin: 80px 0 0 20px;      /* mismo margen izquierdo que los proyectos */
}

.about h2 {
    font-weight: 400;
    font-size: 24px;            /* igual que los títulos de proyecto */
    margin-bottom: 20px;
}

.about p {
    line-height: 1.65;
    font-size: 17px;
    margin-bottom: 16px;
}

/* ======= Contacto estilo enlaces igual que los proyectos ======= */
.about .contacto {
    font-size: 19px;   /* tamaño de "Contacto:" */
    margin-top: 30px;
    line-height: 1.65;
}

/* enlaces de correo e Instagram más pequeños */
.about .contacto a {
    font-size: 17px;          /* más pequeño que "Contacto:" */
    text-decoration: none;
    color: #111;              /* mismo color que los enlaces de proyectos */
    transition: opacity 0.3s ease;
}

.about .contacto a:hover {
    opacity: 0.5;             /* igual que los enlaces de proyectos */
}

/* ======= Home / Index ======= */
.home {
    max-width: 90%;
    margin: 80px auto 0 auto;
    text-align: center;
}

.home h2 {
    font-weight: 400;
    font-size: 28px;
    margin-bottom: 20px;
}

.home p {
    line-height: 1.65;
    font-size: 17px;
}

.home img {
    display: block;
    max-width: 95%;
    max-height: 85vh;
    height: auto;
    margin: 30px auto 0 auto;
    object-fit: contain;
}

/* ======= Media (móvil / tablet) ======= */
@media (max-width: 768px) {
    .layout {
        flex-direction: column;
        height: auto;
    }

    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding: 20px;
    }

    .gallery-container {
        overflow-x: hidden;
        overflow-y: auto;
    }

    .gallery-scroll {
        flex-direction: column;
        align-items: center;
        height: auto;
    }

    .gallery-scroll img {
        height: auto;
        width: 90%;
        margin: 0 0 20px 0;
    }

    .project-text {
        flex: 0 0 auto;
        max-width: 90%;
        padding: 20px;
    }

    .home {
        margin: 60px auto 0 auto;
    }

    .home h2 {
        font-size: 24px;
    }

    .home p {
        font-size: 16px;
    }

    .home img {
        width: 100%;
        max-height: 60vh;
        margin-top: 20px;
    }
}