/* ======================================================
   BBLM HEADER & GLOBAL ENHANCEMENTS
   Versione 3.3 – CSS globale del sito
   ====================================================== */


/* ======================================================
   FONT AMATIC SC PER HEADER
   ====================================================== */
@import url('https://fonts.googleapis.com/css2?family=Amatic+SC:wght@400;700&display=swap');

.site-title,
.site-title a,
.site-description {
    font-family: "Amatic SC", cursive !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    margin: 0 !important;
    padding: 0 !important;
}



/* ======================================================
   HEADER STICKY (DESKTOP + TABLET + MOBILE)
   ====================================================== */

header.site-header {
    position: sticky;
    top: 0;
    z-index: 9999;
    background: #ffffff;
}

/* DESKTOP: header NON sticky */
@media (min-width: 1025px) {
    header.site-header {
        position: static !important;
    }
}


/* ======================================================
   BRANDING MOBILE/TABLET (pulito e minimale)
   ====================================================== */

@media (max-width: 1024px) {

    /* Logo mobile/tablet */
    .custom-logo {
        height: auto !important;
        width: auto !important;
        object-fit: contain;
    }

    /* Branding compatto */
    .site-branding,
    .ast-site-identity {
        display: flex;
        align-items: center;
        gap: 6px;
    }
}



/* ======================================================
   RIEPILOGO PRENOTAZIONE – STICKY GLOBALE
   (La parte di layout 60/40 resta nel CSS aggiuntivo)
   ====================================================== */

.riepilogo-prenotazione {
    position: sticky;
    align-self: flex-start;
    background: #ffffff;
    z-index: 20;
}

/* Desktop: riepilogo attaccato in alto */
@media (min-width: 1025px) {
    .riepilogo-prenotazione {
        top: 0;
    }
}

/* Tablet */
@media (min-width: 769px) and (max-width: 1024px) {
    .riepilogo-prenotazione {
        top: 120px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .riepilogo-prenotazione {
        top: 100px;
    }
}



/* ======================================================
   SBLOCCO STICKY (overflow/position)
   ====================================================== */

.camere-layout,
.camere-layout .elementor-container,
.camere-layout .elementor-row,
.camere-layout .elementor-column,
.camere-layout .elementor-widget-wrap {
    overflow: visible !important;
    position: static !important;
}



/* ======================================================
   BORDI ARROTONDATI COMPLETI QUANDO L'HEADER È SHRINK
   ====================================================== */

@media (max-width: 1024px) {
    header.site-header.is-shrunk {
        border-radius: 18px; /* arrotondamento completo */
        overflow: hidden; /* evita che i contenuti escano */
    }
}


/* ======================================================
   HEADER SHRINK – TABLET E MOBILE
   ====================================================== */
/* Stato normale */
header.site-header {
    transition: all 0.25s ease;
}

/* SHRINK TABLET (riduzione 40%) */
@media (min-width: 769px) and (max-width: 1024px) {
    header.site-header.is-shrunk {
        transform: scale(0.75); /* 40% di riduzione */
        transform-origin: top;
    }
}

/* SHRINK MOBILE (mini barra) */
@media (max-width: 768px) {
    header.site-header.is-shrunk {
        transform: scale(0.55); /* mini barra */
        transform-origin: top;
    }
}

/* ======================================================
   BARRA MOBILE FADE IN DOPO SCROLL FADE OUT PRIMA DI FOOTER
   ====================================================== */

/* Fade-in della barra */
.barra-prenotazione-fissa {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
}

.barra-prenotazione-fissa.visibile {
    opacity: 1;
    pointer-events: auto;
}

/* Nasconde la barra quando il footer entra in vista */
.barra-nascosta {
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translate(-50%, 120%) !important;
    transition: opacity 0.3s ease, transform 0.3s ease;
}