/* =========================================
   1. STILI GENERALI & RESET
   ========================================= */
body {
    font-family: 'Montserrat', sans-serif;
    color: #333;
    line-height: 1.6;
    background-color: #ffffff;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Fix per scorrimento con navbar sticky */
section {
    scroll-margin-top: 140px; 
}

/* =========================================
   2. NAVBAR & HEADER
   ========================================= */
.navbar {
    background-color: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 10px 0;
    min-height: auto; /* Default mobile */
}

.navbar-brand img {
    height: 50px;
    width: auto;
    transition: height 0.3s ease;
}

/* Desktop Navbar Override */
@media (min-width: 992px) {
    .navbar { min-height: 120px; }
    .navbar-brand img { height: 90px; }
}

/* Griglia Pulsanti Header */
.header-btn-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
    align-items: center;
}

/* Stile Base Pulsanti Header */
.btn-header {
    background-color: #ffffff;
    border-width: 1px;
    border-style: solid;
    transition: all 0.2s ease;
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.75rem;
    width: 100%;
    white-space: nowrap;
}

.btn-header i { margin-right: 5px; }

/* Desktop Pulsanti Override */
@media (min-width: 992px) {
    .header-btn-grid { gap: 8px; }
    .btn-header {
        padding: 6px 15px;
        font-size: 0.85rem;
        width: 130px;
    }
}

/* Colori Pulsanti Header */
.btn-prenota { border-color: #bc181d; color: #bc181d !important; }
.btn-prenota:hover { background-color: #bc181d; color: #ffffff !important; }

.btn-chiama { border-color: #343a40; color: #343a40 !important; }
.btn-chiama:hover { background-color: #343a40; color: #ffffff !important; }

.btn-scrivi { border-color: #6c757d; color: #6c757d !important; }
.btn-scrivi:hover { background-color: #6c757d; color: #ffffff !important; }

.btn-maps-header { border-color: #0d6efd; color: #0d6efd !important; }
.btn-maps-header:hover { background-color: #0d6efd; color: #ffffff !important; }

/* =========================================
   3. ELEMENTI COMUNI (Bottoni, Titoli)
   ========================================= */
.btn-custom {
    background-color: #bc181d;
    color: #ffffff !important;
    border: none;
    transition: background-color 0.3s ease;
    text-decoration: none;
    padding: 8px 20px;
    border-radius: 5px;
    display: inline-block;
}
.btn-custom:hover { background-color: #444444; color: #ffffff !important; }

.btn-lg-custom {
    padding: 12px 30px;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-map {
    background-color: #ffffff;
    color: #bc181d !important;
    border: 2px solid #bc181d;
    font-weight: 600;
}
.btn-map:hover { background-color: #bc181d; color: #fff !important; }

/* Titoli con font Caveat */
.section-title, .page-title, .client-area-section h3, .caveat-font {
    font-family: 'Caveat', cursive;
    font-weight: 500;
    color: #bc181d;
    line-height: 1.2;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2.8rem;
}

.page-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 30px;
    padding: 0 15px;
}

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero-section {
    background-image: url('https://tools.s-d.it/bg.webp');
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    position: relative;
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    padding: 60px 20px;
}
.hero-overlay { background-color: rgba(0, 0, 0, 0.6); position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; }
.hero-content { position: relative; z-index: 2; max-width: 900px; }
.hero-content h1 { font-weight: 700; margin-bottom: 30px; text-transform: uppercase; font-size: 2.5rem; }
.hero-content p { font-size: 1.2rem; line-height: 1.6; margin-bottom: 15px; }

/* =========================================
   5. INFO SECTION & CONTATTI
   ========================================= */
.info-section { background-color: #ffffff; padding: 60px 20px 40px 20px; text-align: center; }
.info-section p { font-size: 1.2rem; color: #333; margin-bottom: 30px; }

.mid-contacts-box {
    margin-top: 30px; padding-top: 30px; border-top: 1px solid #eee;
    display: flex; flex-direction: column; align-items: center; gap: 15px;
}
.mid-contacts-text { font-weight: 600; font-size: 1.1rem; color: #555; margin-bottom: 0px !important; }

/* Social Icons */
.social-icon { font-size: 1.5rem; transition: color 0.3s ease; display: flex; align-items: center; text-decoration: none !important; }
.social-icon-large { font-size: 3rem !important; margin: 0 15px; }
.social-facebook { color: #1877F2; }
.social-linkedin { color: #0a66c2; }
.social-icon:hover { color: #444444; }
.mid-social-container { margin-top: 20px; display: flex; justify-content: center; align-items: center; }

/* Orari di contatto */
.opening-hours-box {
    background-color: #f9f9f9; padding: 20px; border-radius: 8px; border: 1px solid #eee;
    margin: 15px 0; width: 100%; max-width: 700px; text-align: left;
}
.hours-main { text-align: center; margin-bottom: 15px; font-size: 1.05rem; }
.emergency-title { font-weight: 700; color: #bc181d; margin-bottom: 10px; font-size: 0.95rem; }
.emergency-list { list-style: none; padding: 0; margin: 0; font-size: 0.9rem; color: #555; }
.emergency-list li { margin-bottom: 8px; display: flex; align-items: flex-start; }
.emergency-list li i { color: #bc181d; margin-right: 10px; margin-top: 5px; width: 20px; text-align: center; }

/* =========================================
   6. SERVIZI & CARD
   ========================================= */
.services-section { background-color: #f9f9f9; padding: 60px 20px; }
.service-card {
    background-color: #fff; padding: 30px 20px; border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); height: 100%;
    transition: transform 0.3s ease; text-align: left;
    position: relative; padding-bottom: 70px;
}
.service-card:hover { transform: translateY(-5px); }
.service-brand-logo { position: absolute; bottom: 15px; right: 15px; width: 66%; height: auto; opacity: 0.9; }
@media (min-width: 992px) { .service-brand-logo { width: 50%; } }

.service-icon { font-size: 2rem; color: #bc181d; margin-bottom: 20px; display: block; text-align: center; }
.service-title {
    font-weight: 700; font-size: 1.2rem; margin-bottom: 20px; text-align: center;
    color: #222; text-transform: uppercase; border-bottom: 2px solid #bc181d;
    padding-bottom: 10px; display: inline-block; width: 100%;
}
.service-list { list-style: none; padding-left: 0; margin: 0; }
.service-list li { position: relative; padding-left: 25px; margin-bottom: 12px; font-size: 0.95rem; color: #555; line-height: 1.5; }
.service-list li::before {
    content: '\f00c'; font-family: "Font Awesome 6 Free"; font-weight: 900;
    position: absolute; left: 0; top: 3px; color: #bc181d; font-size: 0.8rem;
}

/* Card Speciale (Rossa) */
.service-card-special {
    background-color: #bc181d; color: #fff; display: flex; flex-direction: column;
    justify-content: center; align-items: center; text-align: center; padding-bottom: 30px;
}
.service-card-special .service-icon { color: #fff; }
.service-card-special p { font-size: 1.1rem; line-height: 1.6; color: #fff; }
.service-card-special:hover { background-color: #a01418; }

/* Link "Leggi più sotto" */
.read-more-link {
    margin-top: 15px; font-weight: 700; color: #ffffff; text-decoration: none;
    border-bottom: 1px solid rgba(255,255,255,0.5); transition: all 0.3s ease; cursor: pointer;
}
.read-more-link:hover { color: #ffffff; border-bottom: 1px solid #ffffff; transform: translateY(2px); }

/* =========================================
   7. BRAND ACCORDION
   ========================================= */
.brands-accordion-section { background-color: #fff; padding: 0px 20px 60px 20px; }
.brands-accordion-section .accordion-button {
    font-family: 'Caveat', cursive; font-size: 1.8rem; font-weight: 500;
    color: #bc181d; background-color: #fff; box-shadow: none;
    border-bottom: 1px solid #eee; justify-content: center;
}
.brands-accordion-section .accordion-button:not(.collapsed) { color: #bc181d; background-color: #f9f9f9; }
.brand-row-item { padding: 20px 0; border-bottom: 1px solid #eee; }
.brand-row-item:last-child { border-bottom: none; }
.brand-desc-logo { max-width: 250px; width: 100%; height: auto; margin-bottom: 15px; }
@media (min-width: 768px) { .brand-desc-logo { margin-bottom: 0; } }
.brand-description-text { font-size: 1rem; color: #555; }

/* =========================================
   8. PARTNER & INFRASTRUTTURA
   ========================================= */
.partners-section { background-color: #ffffff; padding: 60px 20px; border-top: 1px solid #eee; }
.partner-box { text-align: center; padding: 20px; height: 100%; }
.partner-logo-wrapper { height: 130px; display: flex; align-items: center; justify-content: center; margin-bottom: 20px; }
.partner-logo-img { max-width: 240px; height: auto; max-height: 100%; object-fit: contain; }
.microsoft-logo-text { font-family: "Segoe UI", Segoe, Tahoma, Geneva, Verdana, sans-serif; font-weight: 400; font-size: 1.8rem; color: #5e5e5e; line-height: 1; }
.partner-description { font-size: 0.95rem; color: #555; line-height: 1.5; }

.infrastructure-section { background-color: #f4f4f4; padding: 60px 20px; border-top: 1px solid #ddd; }
.infrastructure-content { max-width: 900px; margin: 0 auto; text-align: left; font-size: 1.1rem; color: #444; }
.infrastructure-content p { margin-bottom: 25px; }

/* =========================================
   9. CLIENT AREA & RECENSIONI
   ========================================= */
/* Aggiornato: Sfondo #f4f4f4 come infrastruttura */
.client-area-section { background-color: #f4f4f4; padding: 60px 20px; text-align: center; border-top: 1px solid #ddd; }
.client-area-section h3 { font-size: 2.8rem; margin-bottom: 15px; }
.client-area-section p { font-size: 1.1rem; margin-bottom: 25px; color: #444; }

/* Stile per i box separati (Card con ombra) */
.client-card-box {
    background-color: #fff; /* Box bianco */
    padding: 30px 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 1px solid #eee;
    transition: transform 0.3s ease;
}
.client-card-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.review-section { background-color: #fff; padding: 50px 20px; text-align: center; border-top: 1px solid #eee; }
.caveat-font { font-size: 2.2rem; margin-bottom: 20px; }
.qr-code-img { max-width: 150px; height: auto; margin-bottom: 20px; border: 1px solid #ddd; padding: 5px; background: #fff; }
.review-social-wrapper { display: flex; justify-content: center; margin-top: 20px; }

/* =========================================
   10. ELEMENTI FLUTTUANTI (Menu, BackToTop, WhatsApp)
   ========================================= */
/* Bottone Menu Laterale */
#toggleMenuBtn {
    position: fixed; top: 50%; right: 0; transform: translateY(-50%);
    z-index: 9999; background-color: #ffffff; color: #bc181d;
    border: 2px solid #bc181d; border-right: none;
    border-radius: 5px 0 0 5px; padding: 12px 15px;
    box-shadow: -2px 2px 10px rgba(0,0,0,0.15); cursor: pointer;
    transition: all 0.3s ease;
}
#toggleMenuBtn:hover { background-color: #f8f8f8; padding-right: 20px; }

/* Menu Fluttuante */
.custom-floating-menu {
    position: fixed; top: 50%; right: 60px; transform: translateY(-50%) translateX(20px);
    z-index: 9998; background-color: #ffffff; border: 1px solid #ddd;
    border-radius: 8px; box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    width: 240px; padding: 15px 0; opacity: 0; visibility: hidden;
    transition: all 0.3s ease-in-out;
}
.custom-floating-menu.active { opacity: 1; visibility: visible; transform: translateY(-50%) translateX(0); }
.custom-floating-menu a {
    display: block; padding: 10px 20px; color: #333; text-decoration: none;
    font-weight: 600; font-size: 0.95rem; border-bottom: 1px solid #f1f1f1;
    transition: background 0.2s, color 0.2s; text-transform: uppercase;
}
.custom-floating-menu a:last-child { border-bottom: none; }
.custom-floating-menu a:hover { background-color: #f9f9f9; color: #bc181d; padding-left: 25px; }

/* Bottone Torna Su */
#backToTopBtn {
    display: none; position: fixed; bottom: 20px; right: 20px;
    z-index: 9999; border: none; outline: none;
    background-color: #bc181d; color: white;
    cursor: pointer; width: 45px; height: 45px;
    border-radius: 50%; font-size: 18px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    transition: background-color 0.3s, transform 0.3s;
}
#backToTopBtn:hover { background-color: #444; transform: translateY(-3px); }

/* --- PULSANTE WHATSAPP --- */
.whatsapp-btn {
    position: fixed; bottom: 80px; right: 20px; z-index: 9999;
    background-color: #25d366; color: white; width: 50px; height: 50px;
    border-radius: 50%; text-align: center; font-size: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3); display: flex;
    align-items: center; justify-content: center; text-decoration: none;
    transition: all 0.3s ease;
}
.whatsapp-btn:hover { background-color: #128c7e; color: white; transform: scale(1.1); }

@media (max-width: 600px) {
    .whatsapp-btn { width: 45px; height: 45px; font-size: 26px; bottom: 75px; right: 20px; }
}

/* =========================================
   11. PAGINA PRENOTA (Specifici)
   ========================================= */
.main-content { flex-grow: 1; padding: 20px 0; }
.container-fluid-custom { width: 100%; padding: 0; margin: 0; }
iframe {
    width: 100%; border: 0; display: block;
    height: 1200px; /* Desktop default */
    border-bottom: 1px solid silver !important;
    border-top: 1px solid silver !important;
}

/* =========================================
   12. FOOTER
   ========================================= */
footer { background-color: #fff; padding: 40px 0; border-top: 1px solid #eee; }
.footer-content { display: flex; flex-direction: column; align-items: center; width: 100%; padding: 0 24px; text-align: center; }
.footer-details { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 20px; width: 100%; max-width: 700px; }
.footer-details .logo { width: 160px; height: auto; flex-shrink: 0; }
.contact-info { text-align: left; color: #555; font-size: 0.8em; line-height: 1.5; flex-grow: 1; min-width: 280px; max-width: 400px; }
.contact-info p { margin: 3px 0; display: flex; align-items: flex-start; gap: 8px; justify-content: flex-start; }
.contact-info a { color: #bc181d; text-decoration: none; transition: color 0.3s ease; }
.contact-info a:hover { color: #444444; text-decoration: underline; }
.contact-info i { margin-right: 5px; flex-shrink: 0; font-size: 1.1em; color: #555; }

/* MEDIA QUERIES FINALI */
@media (max-width: 768px) {
    .navbar-brand img { height: 45px; }
    .page-title { font-size: 2rem; }
    .header-actions { flex-direction: column; align-items: flex-end; gap: 5px; }
    .btn-header { font-size: 0.75rem; padding: 4px 10px; }
    
    /* Iframe su mobile */
    iframe { height: 1800px !important; }
}

@media (max-width: 600px) {
    .footer-details { flex-direction: column; align-items: center; text-align: center; }
    .contact-info { text-align: center; }
    .contact-info p { justify-content: center; }
}


/* Iubenda */

#iubenda-cs-banner.iubenda-cs-overlay {
  visibility: visible;
  opacity: 1;
  backdrop-filter: blur(10px);
}

body #iubenda-iframe, .offcanvas-overlay {
  transition: 0.4s;
  backdrop-filter: blur(10px);
  background-color: rgba(0, 0, 0, .4) !important;
}

#iub-legalDoc p, #iub-legalDoc {font-size: 1rem !important;}