/* =========================
   OPERE - INDEX (compatibilità)
========================= */

#books,
#opere{

    background:linear-gradient(135deg, #17130f 0%, #1f1813 100%);

    color:white;

    padding:var(--section-spacing-small) 0;

}


#books .container,
#opere .container{

    text-align:center;

}


#books h2,
#opere h2{

    font-family:'Cormorant Garamond',serif;

    font-size:var(--section-title-size);

    margin-bottom:var(--block-spacing);

    color:#f4e5b4;

    text-shadow:0 2px 12px rgba(0,0,0,.25);

}



/* mantiene il vecchio nome */

.books-grid,
.opere-grid{

    display:grid;

    grid-template-columns:repeat(3,1fr);

    gap:28px;

    max-width:1050px;

    margin:0 auto;

}



/* mantiene il vecchio nome */

.book-card,
.opera-card{

    background:rgba(255,255,255,.04);

    border:1px solid rgba(255,255,255,.08);

    border-radius:18px;

    overflow:hidden;

    padding:20px;

    transition:.4s;

    width:100%;

    max-width:260px;

    margin:0 auto;

}


.book-card:hover,
.opera-card:hover{

    transform:translateY(-8px);

}


.book-card img,
.opera-card img{

    width:160px;

    height:auto;

    display:block;

    margin:0 auto 20px;

    transition:.4s;

}


.book-card:hover img,
.opera-card:hover img{

    transform:scale(1.05);

}


.book-card h3,
.opera-card h3{

    font-family:'Cormorant Garamond',serif;

    font-size:var(--section-subtitle-size);

    margin-bottom:10px;

}


.book-card p,
.opera-card p{

    font-size:var(--body-size-small);

    color:#ccc;

    margin-bottom:18px;

}

/* ==========================================
   PAGINA OPERE.HTML
========================================== */


/* SOLO PAGINA OPERE */

.opere-page{

    padding:0;

}

.page-intro{

    background:#17130f;

    padding:60px 0 44px;

    color:white;

}

.page-intro-content{

    max-width:1000px;

    margin:auto;

    display:flex;

    align-items:flex-end;
    gap:50px;

}

.page-intro-image{

    flex:1;

}

.page-intro-image img{

    width:100%;

    max-width:320px;
    height:360px;
    object-fit:cover;
    object-position:center;
    border-radius:16px;
    display:block;

}

.page-intro-text{

    flex:1;

}

.page-intro-label {

    display:block;
    font-size:13px;
    letter-spacing:2.5px;
    color:#c19a6b;
    text-transform:uppercase;
    font-weight:600;
    margin-bottom:14px;

}

.page-intro-text h1{

    font-family:'Cormorant Garamond',serif;

    font-size:46px;

    font-weight:500;

    color:#f4e5b4;

    line-height:1.1;

    margin:0 0 16px;

}

.page-intro-text p{

    font-family:'Cormorant Garamond',serif;

    color:#ccc;

    font-size:16px;

    line-height:1.75;

    margin:0;
    max-width:560px;

}



/* ==========================================
   ELENCO OPERE
========================================== */


.works-section{

    background:#fff;

    padding:72px 0;

    color:#222;

}


.works-container{

    max-width:1100px;

    margin:auto;

}



.works-heading{

    text-align:center;

    margin-bottom:56px;

}


.works-heading span{

    color:#b08b57;

    letter-spacing:3px;

    font-size:14px;

}


.works-heading h2{

    font-family:'Cormorant Garamond',serif;

    font-size:46px;

    font-weight:500;

    color:#15110d;

    margin:15px 0;

}



.works-heading p{

    color:#666;

}



/* singola opera */


.work-item{

    display:grid;

    grid-template-columns:minmax(220px, 280px) 1fr;

    align-items:center;

    gap:clamp(24px, 3.5vw, 40px);

    margin-bottom:24px;

    padding:28px 30px;

    background:#faf7f1;

    border:1px solid #eee6dc;

    border-radius:24px;

    box-shadow:0 18px 40px rgba(17, 17, 17, 0.05);

}


.work-item.reverse{

    grid-template-columns:1fr minmax(220px, 280px);

}

.work-item.reverse .work-cover{

    order:2;

}

.work-item.reverse .work-content{

    order:1;

}


.work-cover{

    display:flex;

    justify-content:center;

    align-items:center;

}


.work-cover img{

    width:100%;

    max-width:220px;

    height:auto;

    aspect-ratio:3 / 4;

    object-fit:cover;

    border-radius:14px;

    box-shadow:0 14px 28px rgba(0, 0, 0, 0.12);

}


.work-content{

    max-width:620px;

}



.work-category{

    font-size:13px;

    letter-spacing:3px;

    color:#b08b57;

}


.work-content h3{

    font-family:'Cormorant Garamond',serif;

    font-size:46px;

    font-weight:500;

    margin:12px 0;

    color:#15110d;
}


.work-content p{

    font-size:16px;

    line-height:1.8;

    color:#555;

}


.work-button{

    display:inline-block;

    margin-top:18px;

    color:#b08b57;

    text-decoration:none;

    font-weight:600;

}



/* ==========================================
   CHIUSURA
========================================== */


.works-ending{

    background:#17130f;

    color:white;

    text-align:center;

    padding:80px 0;

}


.works-ending span{

    color:#c19a6b;

    letter-spacing:3px;

}


.works-ending h2{

    font-family:'Cormorant Garamond',serif;

    font-size:46px;

    font-weight:500;

    color:#f4e5b4;

}


.works-ending p{

    max-width:700px;

    margin:16px auto 32px;

    color:#ccc;

    line-height:1.8;

}



/* ==========================================
   RESPONSIVE - PAGINA OPERE
========================================== */

@media (max-width:900px){

    /* =========================
       INTRO PAGINA
    ========================= */

    .page-intro{
    
        padding:100px 20px 40px;

    }

    .page-intro-content{

        display:flex;

        flex-direction:column;

        align-items:center;

        justify-content:center;

        gap:30px;

        width:100%;

        max-width:100%;

        margin:0 auto;

        text-align:center;

    }

    .page-intro-image{

        width:100%;

        display:flex;

        justify-content:center;

    }

    .page-intro-image img{

        width:100%;

        max-width:420px;

        height:auto;

        display:block;

        border-radius:18px;

    }

    .page-intro-text{

        width:100%;

        max-width:700px;

    }

    .page-intro-text h1{

        font-size:40px;

        line-height:1.15;

        margin:12px 0 16px;

    }

    .page-intro-text p{

        font-size:16px;

        line-height:1.7;

    }

    .opere-page .page-intro-image img{
   
        width:100%;
   
        max-width:420px;
   
        height:auto;
   
        aspect-ratio:auto;
   
        object-fit:contain;

    }


    /* =========================
       ELENCO OPERE
    ========================= */

    .works-section{

        padding:55px 20px;

    }

    .works-container{

        width:100%;

        max-width:100%;

        margin:0 auto;

    }

    .works-heading{

        margin-bottom:40px;

    }

    .works-heading h2{

        font-size:44px;

        line-height:1.15;

    }

    .works-heading p{

        font-size:16px;

        line-height:1.7;

    }


    /* =========================
       SINGOLA OPERA
    ========================= */

    .work-item,
    .work-item.reverse{

        display:grid;

        grid-template-columns:1fr;

        width:100%;

        box-sizing:border-box;

        gap:30px;

        margin-bottom:25px;

        padding:30px 24px;

        text-align:center;

    }

    .work-item .work-cover,
    .work-item.reverse .work-cover{

        order:1;

        width:100%;

    }

    .work-item .work-content,
    .work-item.reverse .work-content{

        order:2;

        width:100%;

        max-width:100%;

    }

    .work-cover{

        display:flex;

        justify-content:center;

        align-items:center;

        width:100%;

    }

    .work-cover img{

        width:100%;

        max-width:210px;

        height:auto;

        aspect-ratio:3 / 4;

        object-fit:cover;

        border-radius:14px;

    }

    .work-content h3{

        font-size:36px;

        line-height:1.2;

        margin:12px 0 15px;

    }

    .work-content p{

        font-size:16px;

        line-height:1.75;

        margin:0;

    }

    .work-button{

        margin-top:20px;

    }


    /* =========================
       CHIUSURA
    ========================= */

    .works-ending{

        padding:65px 20px;

    }

    .works-ending h2{

        font-size:42px;

        line-height:1.2;

    }

    .works-ending p{

        font-size:16px;

        line-height:1.75;

    }

}


/* ==========================================
   SMARTPHONE
========================================== */

@media (max-width:600px){

    /* =========================
       INTRO
    ========================= */

    .page-intro{

    padding:90px 18px 35px;

    }

    .page-intro-content{

        gap:25px;

    }

    .page-intro-image img{

        width:100%;

        max-width:100%;

        border-radius:15px;

    }

    .page-intro-label{

        font-size:12px;

        letter-spacing:2px;

    }

    .page-intro-text h1{

        font-size:34px;

        line-height:1.15;

        margin:10px 0 14px;

    }

    .page-intro-text p{

        font-size:15px;

        line-height:1.7;

    }


    /* =========================
       ELENCO
    ========================= */

    .works-section{

        padding:45px 15px;

    }

    .works-heading{

        margin-bottom:32px;

    }

    .works-heading span{

        font-size:12px;

        letter-spacing:2px;

    }

    .works-heading h2{

        font-size:36px;

        line-height:1.15;

        margin:12px 0;

    }

    .works-heading p{

        font-size:15px;

        line-height:1.7;

    }


    /* =========================
       OPERE
    ========================= */

    .work-item,
    .work-item.reverse{

        display:flex;

        flex-direction:column;

        align-items:center;

        width:100%;

        margin-bottom:20px;

        padding:25px 18px;

        gap:25px;

        border-radius:18px;

        box-sizing:border-box;

    }

    .work-cover{

        width:100%;

    }

    .work-cover img{

        width:100%;

        max-width:180px;

        height:auto;

        aspect-ratio:3 / 4;

        object-fit:cover;

    }

    .work-content{

        width:100%;

        max-width:100%;

    }

    .work-category{

        font-size:11px;

        letter-spacing:2px;

    }

    .work-content h3{

        font-size:30px;

        line-height:1.2;

        margin:10px 0 15px;

    }

    .work-content p{

        font-size:15px;

        line-height:1.7;

        text-align:left;

    }

    .work-button{

        font-size:15px;

        margin-top:18px;

    }


    /* =========================
       CHIUSURA
    ========================= */

    .works-ending{

        padding:55px 20px;

    }

    .works-ending span{

        font-size:12px;

    }

    .works-ending h2{

        font-size:36px;

    }

    .works-ending p{

        font-size:15px;

        line-height:1.7;

    }

}

/* ==========================================
   INTRO OPERE - FOTO ORIZZONTALE
   ========================================== */

.opere-page .page-intro{
    padding-top:110px;
}

.opere-page .page-intro-content{
    max-width:1100px;
    margin:0 auto;
    display:grid;
    grid-template-columns:minmax(0, 1.15fr) minmax(0, 1fr);
    align-items:center;
    gap:50px;
}

.opere-page .page-intro-image{
    width:100%;
    display:flex;
    justify-content:center;
    align-items:center;
}

.opere-page .page-intro-image img{
    width:100%;
    max-width:none;
    height:auto;
    aspect-ratio:auto;
    object-fit:contain;
    border-radius:16px;
    display:block;
}

.opere-page .page-intro-text{
    width:100%;
    max-width:none;
}