/* --- STRUTTURA ESTERNA --- */
.francesca-section-wrapper {
    width: 100%;
    display: block; 
    text-align: center; 
    overflow: visible; 
    /* Spazio calibrato tra sottotitolo e inizio card come da foto */
    padding: 30px 0 0px 0; 
    box-sizing: border-box;
}

.cards-mobile-wrapper {
    display: block; 
    overflow: visible;
}

/* --- GRIGLIA & CONTENITORI --- */
.francesca-grid {
    display: inline-flex; 
    vertical-align: top;
    margin: 20px; 
    text-align: left;
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.francesca-card-container {
    width: 300px;
    background-color: #1a2a3a;
    border-radius: 35px;
    padding: 12px;
    font-family: 'Inter', sans-serif;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.francesca-card-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.3);
}

/* --- BOX IMMAGINE --- */
.francesca-card-image-box {
    position: relative;
    background-color: #ffffff;
    height: 260px;
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
}

.francesca-card-img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
}

/* --- WISHLIST (CUORE) & ANIMAZIONI --- */
.francesca-card-wishlist {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #1a2a3a;
    color: #ffffff;
    border: none;
    border-radius: 50%;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 10;
}

.francesca-card-wishlist ion-icon { font-size: 28px; }
.francesca-card-wishlist:hover { transform: scale(1.2); }
.francesca-card-wishlist.is-active { background-color: #ff4757; box-shadow: 0 0 20px rgba(255, 71, 87, 0.4); }

.francesca-card-wishlist.is-active ion-icon {
    animation: heartPop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.5);
    color: white;
}

@keyframes heartPop {
    0% { transform: scale(1); }
    30% { transform: scale(1.6); }
    60% { transform: scale(0.8); }
    100% { transform: scale(1); }
}

/* PARTICELLE ESPLOSIONE CUORE */
.francesca-card-wishlist .particle {
    position: absolute;
    width: 8px; height: 8px;
    border-radius: 50%;
    opacity: 0;
    pointer-events: none;
    z-index: -1;
    top: 50%; left: 50%;
}

.francesca-card-wishlist.is-active .particle { animation: particlesExplosion 0.7s ease-out forwards; }
.francesca-card-wishlist .particle:nth-child(2) { background: #ff4757; --tw-y: -60px; --tw-x: -25px; }
.francesca-card-wishlist .particle:nth-child(3) { background: #ffbc00; --tw-y: 60px; --tw-x: 25px; }
.francesca-card-wishlist .particle:nth-child(4) { background: #2ed573; --tw-x: -60px; --tw-y: 20px; }
.francesca-card-wishlist .particle:nth-child(5) { background: #1e90ff; --tw-x: 60px; --tw-y: -20px; }

@keyframes particlesExplosion {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    100% { transform: translate(calc(-50% + var(--tw-x)), calc(-50% + var(--tw-y))) scale(0); opacity: 0; }
}

/* --- INFO TESTUALI --- */
.francesca-card-info {
    padding: 15px 10px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.francesca-card-title {
    margin: 5px 0;
    font-size: 20px;
    color: #ffffff;
    font-weight: 600;
}

.francesca-card-category {
    font-size: 11px;
    color: #8fa1b3;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.francesca-card-description {
    font-size: 14px;
    color: #d1d9e0;
    margin: 10px 0 20px 0;
    line-height: 1.4;
}

/* --- BOTTONE --- */
.francesca-card-button {
    display: block;
    padding: 12px 0;
    background-color: #ffffff;
    color: #1a2a3a;
    text-align: center;
    text-decoration: none;
    border-radius: 15px;
    font-size: 14px;
    font-weight: 700;
    transition: transform 0.2s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.francesca-card-button:hover { transform: scale(1.06); }

/* --- RESPONSIVE MOBILE --- */
@media (max-width: 768px) {
    .francesca-section-wrapper {
        text-align: left; 
        padding: 20px 0 40px 0; 
    }

    .cards-mobile-wrapper {
        display: flex; 
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding: 20px 15%; 
        gap: 20px;
        scrollbar-width: none; 
    }

    .cards-mobile-wrapper::-webkit-scrollbar { display: none; }

    .francesca-grid {
        display: flex; 
        flex: 0 0 auto;
        width: 70vw;    
        max-width: 280px; 
        scroll-snap-align: center;
        margin: 0 !important;
        transform: scale(0.9);
        opacity: 0.4; 
    }

    .francesca-grid.is-featured {
        transform: scale(1.02);
        opacity: 1 !important;
        z-index: 10;
    }

    .francesca-card-container {
        width: 100% !important;
    }
}

/* --- SEZIONE TITOLI (DESKTOP & GENERAL) --- */
.fr-section-container {
    text-align: center;
    /* Padding generoso sopra e sotto i titoli come da foto */
    padding: 70px 20px 0px 20px; 
    background-color: transparent;
    width: 100%;
    box-sizing: border-box;
}

.fr-main-title {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 52px; 
    font-weight: 900;
    color: #1a2a3a; 
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0 0 10px 0;
    line-height: 1.1;
}

.fr-title-underline {
    display: block;
    width: 60px;
    height: 3px;
    background-color: #1a2a3a;
    margin: 5px auto 15px auto;
}

.fr-sub-title {
    font-family: 'Georgia', serif;
    font-size: 20px;
    font-style: italic;
    color: #444444;
    margin: 0 auto; 
    max-width: 800px;
    line-height: 1.4;
}

/* --- RESPONSIVE MOBILE (SOTTO 768px) --- */
@media (max-width: 768px) {
    .fr-section-container { 
        padding: 50px 15px 15px 15px; 
    }

    .fr-main-title { 
        font-size: 34px; 
    }

    .fr-sub-title { 
        font-size: 18px; 
    }
}