/* Reset e base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

/* Hero content sempre visibile */
.hero-content {
    opacity: 1;
}

@keyframes heroContentReveal {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header e Navigation */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar {
    padding: 15px 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    flex-direction: column;
    text-decoration: none;
}

.nav-logo .logo-link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.3s ease;
}

.nav-logo .logo-link:hover {
    opacity: 0.8;
}

.nav-logo .logo-link:focus {
    outline: 2px solid #2c5aa0;
    outline-offset: 2px;
    border-radius: 4px;
}

.nav-logo h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c3e50;
}

.nav-logo span {
    font-size: 0.9rem;
    color: #667eea;
    margin-top: -5px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #4a90e2;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: #4a90e2;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    height: 100vh;
    background: url('../images/banner.png') no-repeat center center;
    background-size: cover;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    filter: contrast(1.3) saturate(1.2) brightness(1.1);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(74, 144, 226, 0.4) 0%, rgba(49, 130, 206, 0.4) 100%);
    background-size: 400% 400%;
    animation: gradientShift 8s ease infinite;
    z-index: 1;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.05);
    z-index: 2;
}

/* Animazioni Hero */
@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(45deg); }
    50% { transform: translateX(100vw) rotate(45deg); }
    100% { transform: translateX(100vw) rotate(45deg); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes float {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) rotate(360deg);
        opacity: 0;
    }
}

/* Cursore lampeggiante */
.cursor {
    animation: blink 1s infinite;
    color: #ffd700;
    font-weight: normal;
}

/* Particelle fluttuanti */
.floating-particle {
    pointer-events: none;
    will-change: transform;
}

/* ===== PULSANTE CONSULENZA ANIMATO ===== */
.nav-cta {
    margin-left: auto;
    position: relative;
}

.btn-consulenza {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, #2c5aa0 0%, #1e4080 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(44, 90, 160, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 2px solid transparent;
    overflow: hidden;
    z-index: 1;
    /* ANIMAZIONI PROFESSIONALI SOTTILI */
    animation: professional-glow 4s ease-in-out infinite;
}

.btn-consulenza:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 8px 25px rgba(44, 90, 160, 0.5);
    border-color: rgba(255, 255, 255, 0.2);
    background: linear-gradient(135deg, #3d6bb0 0%, #2c5aa0 100%);
}

.btn-consulenza.active {
    background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 100%);
    box-shadow: 0 4px 15px rgba(46, 125, 50, 0.3);
    animation: professional-glow-green 4s ease-in-out infinite;
}

.btn-consulenza.active:hover {
    box-shadow: 0 8px 25px rgba(46, 125, 50, 0.5);
    background: linear-gradient(135deg, #2e7d32 0%, #388e3c 100%);
}

.btn-consulenza i {
    font-size: 1.1rem;
    animation: professional-icon-pulse 3s ease-in-out infinite;
}

.btn-consulenza span {
    position: relative;
    z-index: 2;
}

/* Effetto glow professionale sottile */
.btn-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, 
        transparent 30%, 
        rgba(255, 255, 255, 0.1) 50%, 
        transparent 70%
    );
    border-radius: 50px;
    transform: translateX(-100%);
    animation: professional-sweep 6s ease-in-out infinite;
    z-index: 0;
}

/* ANIMAZIONI PROFESSIONALI */
@keyframes professional-glow {
    0%, 100% {
        box-shadow: 0 4px 15px rgba(44, 90, 160, 0.3);
    }
    50% {
        box-shadow: 0 4px 20px rgba(44, 90, 160, 0.4);
    }
}

@keyframes professional-glow-green {
    0%, 100% {
        box-shadow: 0 4px 15px rgba(46, 125, 50, 0.3);
    }
    50% {
        box-shadow: 0 4px 20px rgba(46, 125, 50, 0.4);
    }
}

@keyframes professional-icon-pulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 1;
    }
    50% { 
        transform: scale(1.05);
        opacity: 0.9;
    }
}

@keyframes professional-sweep {
    0% {
        transform: translateX(-100%);
    }
    20% {
        transform: translateX(-100%);
    }
    50% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Responsive per tablet - PROFESSIONALE */
@media (max-width: 1024px) {
    .nav-cta {
        margin-left: 1rem;
    }
    
    .btn-consulenza {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }
    
    .btn-consulenza span {
        display: none;
    }
    
    .btn-consulenza i {
        font-size: 1.3rem;
        margin: 0;
    }
    
    /* Notifica professionale discreta */
    .btn-consulenza::after {
        content: '';
        position: absolute;
        top: -5px;
        right: -5px;
        width: 12px;
        height: 12px;
        background: linear-gradient(45deg, #ff6b35, #f7931e);
        border-radius: 50%;
        animation: professional-notification 3s ease-in-out infinite;
        border: 2px solid white;
        box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
    }
}

/* Mobile responsive - PROFESSIONALE */
@media (max-width: 768px) {
    .nav-cta {
        display: block !important;
        margin-left: 1rem;
    }
    
    .btn-consulenza {
        padding: 0.5rem;
        width: 50px;
        height: 50px;
        border-radius: 50%;
        justify-content: center;
    }
    
    .btn-consulenza span {
        display: none;
    }
    
    .btn-consulenza i {
        font-size: 1.4rem;
        margin: 0;
    }
    
    /* Effetto bordo professionale su mobile */
    .btn-consulenza::before {
        content: '';
        position: absolute;
        top: -2px;
        left: -2px;
        width: calc(100% + 4px);
        height: calc(100% + 4px);
        border-radius: 50%;
        background: linear-gradient(45deg, #2c5aa0, #1e4080, #2c5aa0);
        animation: professional-border-rotate 8s linear infinite;
        z-index: -1;
        opacity: 0.7;
    }
    
    /* Mostra anche nel menu mobile quando aperto */
    .nav-menu.active .nav-cta {
        display: block !important;
        margin: 1rem auto;
        text-align: center;
    }
    
    .nav-menu.active .btn-consulenza {
        display: inline-flex;
        width: auto;
        height: auto;
        padding: 1rem 2rem;
        font-size: 1rem;
        justify-content: center;
        border-radius: 50px;
    }
    
    .nav-menu.active .btn-consulenza span {
        display: inline;
    }
    
    .nav-menu.active .btn-consulenza::after,
    .nav-menu.active .btn-consulenza::before {
        display: none;
    }
}

@keyframes professional-notification {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

@keyframes professional-border-rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Effetto hover professionale per desktop */
@media (min-width: 1025px) {
    .btn-consulenza::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
        border-radius: 50px;
        opacity: 0;
        transition: opacity 0.3s ease;
        z-index: 1;
    }
    
    .btn-consulenza:hover::before {
        opacity: 1;
    }
    
    .btn-consulenza:active {
        transform: translateY(-1px) scale(1.01);
        transition: transform 0.1s ease;
    }
}

/* Focus professionale accessibile */
.btn-consulenza:focus {
    outline: 3px solid rgba(44, 90, 160, 0.6);
    outline-offset: 2px;
}

.btn-consulenza.active:focus {
    outline-color: rgba(46, 125, 50, 0.6);
}

/* ===== PULSANTE FLOATING MOBILE ===== */
/* POSIZIONE: Destra (bilanciato con WhatsApp a sinistra) */
.floating-cta {
    position: fixed;
    bottom: 20px;
    right: 20px; /* Destra per bilanciare WhatsApp a sinistra */
    z-index: 1000;
    display: block; /* SEMPRE VISIBILE */
}

.floating-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #2c5aa0 0%, #1e4080 100%);
    color: white;
    border-radius: 50%;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(44, 90, 160, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    /* NESSUNA ANIMAZIONE SU DESKTOP */
}

.floating-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 25px rgba(44, 90, 160, 0.6);
    background: linear-gradient(135deg, #3d6bb0 0%, #2c5aa0 100%);
}

.floating-btn i {
    font-size: 1.5rem;
    /* NESSUNA ANIMAZIONE SU DESKTOP */
}

/* Rimuovo stili del testo dato che non c'è più */
.floating-text {
    display: none;
}

/* Effetto pulse - solo base */
.floating-pulse {
    position: absolute;
    top: -5px;
    left: -5px;
    width: calc(100% + 10px);
    height: calc(100% + 10px);
    border-radius: 50%;
    background: rgba(44, 90, 160, 0.3);
    animation: floating-basic-pulse 3s ease-out infinite;
    pointer-events: none;
}

/* ANIMAZIONE BASE PER TUTTI */
@keyframes floating-basic-pulse {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }
    100% {
        transform: scale(2);
        opacity: 0;
    }
}

/* Responsive per desktop - NESSUNA ANIMAZIONE EXTRA */
@media (min-width: 1025px) {
    .floating-cta {
        bottom: 30px;
        right: 30px;
    }
    
    .floating-btn {
        width: 65px;
        height: 65px;
        /* NESSUNA ANIMAZIONE COSTANTE */
    }
    
    .floating-btn i {
        font-size: 1.6rem;
    }
}

@media (max-width: 1024px) and (min-width: 769px) {
    .floating-cta {
        bottom: 25px;
        right: 25px;
    }
    
    .floating-btn {
        width: 62px;
        height: 62px;
    }
    
    .floating-btn i {
        font-size: 1.5rem;
    }
}

/* MOBILE - ANIMAZIONI ATTIVE */
@media (max-width: 768px) {
    .floating-cta {
        display: block !important;
        bottom: 20px;
        right: 20px;
    }
    
    .floating-btn {
        width: 55px;
        height: 55px;
        /* ANIMAZIONI ATTIVE SOLO SU MOBILE */
        animation: mobile-float-bounce 2s ease-in-out infinite, mobile-glow-rotate 4s linear infinite;
    }
    
    .floating-btn i {
        font-size: 1.4rem;
        /* ANIMAZIONE ICONA SOLO SU MOBILE */
        animation: mobile-icon-dance 2.5s ease-in-out infinite;
    }
    
    /* Nascondi quando il menu mobile è aperto */
    body.nav-open .floating-cta {
        display: none;
    }
    
    .floating-btn:active {
        transform: scale(0.95);
    }
}

/* ANIMAZIONI SPECIFICHE PER MOBILE */
@keyframes mobile-float-bounce {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-8px);
    }
}

@keyframes mobile-glow-rotate {
    0% {
        box-shadow: 0 4px 20px rgba(44, 90, 160, 0.4);
    }
    25% {
        box-shadow: 0 6px 25px rgba(67, 160, 71, 0.5);
    }
    50% {
        box-shadow: 0 8px 30px rgba(255, 193, 7, 0.5);
    }
    75% {
        box-shadow: 0 6px 25px rgba(233, 30, 99, 0.5);
    }
    100% {
        box-shadow: 0 4px 20px rgba(44, 90, 160, 0.4);
    }
}

@keyframes mobile-icon-dance {
    0%, 100% {
        transform: rotate(0deg) scale(1);
    }
    25% {
        transform: rotate(-10deg) scale(1.1);
    }
    50% {
        transform: rotate(10deg) scale(1.2);
    }
    75% {
        transform: rotate(-5deg) scale(1.1);
    }
}

/* Notifica mobile più evidente */
.floating-btn::after {
    content: '';
    position: absolute;
    top: -8px;
    right: -5px;
    width: 18px;
    height: 18px;
    background: linear-gradient(45deg, #ff6b35, #f7931e);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
    color: white;
    border: 2px solid white;
    box-shadow: 0 2px 10px rgba(255, 107, 53, 0.4);
}

/* Animazione notifica solo su mobile */
@media (max-width: 768px) {
    .floating-btn::after {
        animation: mobile-notification-bounce 1.5s ease-in-out infinite;
    }
}

@keyframes mobile-notification-bounce {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.8;
    }
}

/* Focus accessibile */
.floating-btn:focus {
    outline: 3px solid rgba(44, 90, 160, 0.6);
    outline-offset: 3px;
}

/* ===== EFFETTI INTERATTIVI SPECIALI ===== */

/* DESIGN PROFESSIONALE 2024
 * - Colori blu corporate: #2c5aa0, #1e4080 
 * - Animazioni sottili e discrete
 * - Hover effects contenuti
 * - Focus accessibile
 * - Adatto per sito commercialista
 */

/* Effetto sparkle per click */
.sparkle {
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    animation: sparkle-float 1s ease-out forwards;
}

@keyframes sparkle-float {
    0% {
        transform: translateY(0) scale(0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(-50px) scale(1) rotate(180deg);
        opacity: 0;
    }
}

/* Effetto ripple per floating button */
.ripple-effect {
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    transform: scale(0);
    animation: ripple 0.6s ease-out;
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Cursor personalizzato per pulsanti consulenza */
.btn-consulenza {
    cursor: pointer;
}

.btn-consulenza:hover {
    /* Cursore standard del browser - rimosso cursore personalizzato */
}

.floating-btn:hover {
    /* Cursore standard del browser - rimossa trasformazione personalizzata */
}

/* Effetto particelle fluttuanti sui pulsanti */
.btn-consulenza::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50px;
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), 
        rgba(255, 255, 255, 0.3) 0%, 
        transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.btn-consulenza:hover::before {
    opacity: 1;
}

/* Navbar nascosta durante scroll */
.navbar-hidden {
    transform: translateY(-100%);
    transition: transform 0.3s ease-in-out;
}

.navbar-scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* Animazioni di caricamento per prevenire flash */
body:not(.loaded) .btn-consulenza {
    animation-play-state: paused;
}

body:not(.loaded) .floating-btn {
    animation-play-state: paused;
}

body.loaded .btn-consulenza,
body.loaded .floating-btn {
    animation-play-state: running;
}

/* Effetti di focus migliorati per accessibilità */
.btn-consulenza:focus-visible {
    outline: 4px solid rgba(255, 107, 107, 0.8);
    outline-offset: 2px;
    animation: accessibility-pulse 1s ease-in-out infinite;
}

.floating-btn:focus-visible {
    outline: 4px solid rgba(255, 107, 107, 0.8);
    outline-offset: 4px;
    animation: accessibility-pulse 1s ease-in-out infinite;
}

@keyframes accessibility-pulse {
    0%, 100% {
        outline-color: rgba(255, 107, 107, 0.8);
    }
    50% {
        outline-color: rgba(255, 107, 107, 1);
    }
}

/* Prefers-reduced-motion per accessibilità */
@media (prefers-reduced-motion: reduce) {
    .btn-consulenza,
    .floating-btn {
        animation: none !important;
    }
    
    .btn-consulenza *,
    .floating-btn * {
        animation: none !important;
    }
    
    .btn-glow,
    .floating-pulse {
        display: none;
    }
    
    .btn-consulenza::after,
    .floating-btn::after {
        animation: none;
    }
}

/* ===== GESTIONE SPAZIO PULSANTI FLOATING ===== */
/* Assicura che WhatsApp (sinistra) e Consulenza (destra) non si sovrappongano */

@media (max-width: 480px) {
    /* Su schermi molto piccoli, riduci dimensioni per evitare sovrapposizione */
    .whatsapp-chat {
        bottom: 90px; /* Sopra il floating consulenza */
        left: 15px;
    }
    
    .whatsapp-btn {
        width: 50px;
        height: 50px;
        font-size: 1.4rem;
    }
    
    .floating-cta {
        bottom: 20px; /* In basso a destra */
        right: 15px;
    }
    
    .floating-btn {
        width: 55px;
        height: 55px;
    }
    
    .floating-btn i {
        font-size: 1.6rem;
    }
}

@media (max-width: 360px) {
    /* Per schermi extra piccoli, disponi i pulsanti verticalmente a destra */
    .whatsapp-chat {
        bottom: 140px; /* Ancora più in alto */
        left: 10px;
    }
    
    .whatsapp-btn {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }
    
    .floating-cta {
        bottom: 15px;
        right: 10px;
    }
    
    .floating-btn {
        width: 50px;
        height: 50px;
    }
    
    .floating-btn i {
        font-size: 1.4rem;
    }
}

/* Nasconde tooltip su mobile per entrambi i pulsanti */
@media (max-width: 768px) {
    .whatsapp-btn .tooltip,
    .floating-btn .tooltip {
        display: none;
    }
}

/* Ottimizzazioni performance */
.btn-consulenza,
.floating-btn {
    will-change: transform, box-shadow;
    backface-visibility: hidden;
    perspective: 1000px;
    transform-style: preserve-3d;
}

/* Disabilita animazioni durante il ridimensionamento */
.resize-animation-stopper * {
    animation-duration: 0s !important;
    animation-delay: 0s !important;
    transition-duration: 0s !important;
    transition-delay: 0s !important;
}

/* Riduzione movimento per floating button */
@media (prefers-reduced-motion: reduce) {
    .floating-btn i {
        animation: none;
    }
    
    .floating-pulse {
        animation: none;
        display: none;
    }
    
    .floating-cta {
        animation: none;
    }
}

/* Miglioramenti per animazioni mobile */
@media (max-width: 768px) {
    .hero {
        background-size: cover;
        background-position: center;
    }
    
    .hero::before {
        animation: gradientShift 12s ease infinite; /* Rallenta su mobile */
    }
    
    /* Semplifica animazioni per prestazioni migliori */
    .floating-particle {
        display: none; /* Nasconde particelle su mobile */
    }
}

/* Effetti hover migliorati */
@media (hover: hover) and (pointer: fine) {
    .hero-buttons .btn:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 25px rgba(74, 144, 226, 0.4);
    }
    
    .stat:hover {
        transform: translateY(-8px) scale(1.02);
        box-shadow: 0 15px 30px rgba(255, 255, 255, 0.2);
    }
}

.hero-content {
    position: relative;
    z-index: 3;
    color: rgb(0, 0, 0);
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    opacity: 0;
    animation: fadeInLeft 1s ease 0.5s forwards;
    position: relative;
    overflow: hidden;
}

.hero-text h1::after {
    content: '|';
    animation: blink 1s infinite;
    opacity: 0;
    animation-delay: 1.5s;
    animation-duration: 2s;
}

.hero-text p {
    font-size: 1.3rem;
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: fadeInLeft 1s ease 1s forwards;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeInUp 1s ease 1.5s forwards;
}

/* Typing effect per il titolo */
.typing-text {
    overflow: hidden;
    white-space: nowrap;
    border-right: 2px solid transparent;
    animation: typing 2s steps(40) 0.5s forwards;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: #4a90e2;
    color: white;
    box-shadow: 0 5px 15px rgba(74, 144, 226, 0.4);
}

.btn-primary:hover {
    background: #357abd;
    transform: translateY(-2px);
    box-shadow: 0 7px 20px rgba(74, 144, 226, 0.6);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background: white;
    color: #4a90e2;
}

.hero-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    opacity: 1;
    visibility: visible;
}

.stat {
    text-align: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    transform: translateY(0);
    opacity: 1;
    transition: all 0.3s ease;
    visibility: visible !important;
    display: block !important;
}

.stat.animate {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

.stat:nth-child(1).animate {
    animation-delay: 2.2s;
}

.stat:nth-child(2).animate {
    animation-delay: 2.5s;
}

.stat:nth-child(3).animate {
    animation-delay: 2.8s;
}

.stat h3 {
    font-size: 4.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #000000;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #0c1d51;
    line-height: 1;
}

.stat p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Hover effect per le statistiche */
.stat:hover {
    transform: translateY(-5px) !important;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.2);
    opacity: 1 !important;
    visibility: visible !important;
}

/* Assicura visibilità permanente delle statistiche */
.hero-stats .stat,
.stat.animate,
.stat:not(.animate) {
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

/* Sezioni */
.services, .contact {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 3rem;
    font-weight: 700;
    color: #2c5282;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.3rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* Griglia Servizi */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.service-card {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #4a90e2, #357abd);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.service-icon i {
    font-size: 2rem;
    color: white;
}

.service-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c5282;
    margin-bottom: 1rem;
}

.service-card p {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.service-card ul {
    list-style: none;
}

.service-card li {
    padding: 0.5rem 0;
    color: #555;
    position: relative;
    padding-left: 1.5rem;
}

.service-card li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #4a90e2;
    font-weight: bold;
}

/* Sezione Contatti */
.contact {
    background: #f8f9fa;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h3 {
    font-size: 2rem;
    color: #2c5282;
    margin-bottom: 2rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 2rem;
    gap: 1rem;
}

.contact-item i {
    font-size: 1.5rem;
    color: #4a90e2;
    margin-top: 0.25rem;
}

.contact-item h4 {
    font-size: 1.2rem;
    color: #2c5282;
    margin-bottom: 0.5rem;
}

.contact-item p {
    color: #666;
    line-height: 1.6;
}

/* Form Contatti */
.contact-form {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.contact-form h3 {
    font-size: 2rem;
    color: #2c5282;
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #4a90e2;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #666;
}

.checkbox-container input {
    width: auto;
}

/* Footer */
.footer {
    background: #2c5282;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: #ffd700;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.8;
}

/* WhatsApp Chat */
.whatsapp-chat {
    position: fixed;
    bottom: 20px;
    left: 20px; /* Cambiato da right a left */
    z-index: 999; /* Leggermente sotto il pulsante consulenza per evitare conflitti */
}

.whatsapp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: #25d366;
    border-radius: 50%;
    color: white;
    font-size: 1.8rem;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    transition: all 0.3s ease;
    position: relative;
}

.whatsapp-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
}

.tooltip {
    position: absolute;
    bottom: 70px;
    left: 0; /* Cambiato da right a left */
    background: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 5px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.whatsapp-btn:hover .tooltip {
    opacity: 1;
    visibility: visible;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-content {
        gap: 3rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    
    .service-card {
        padding: 2rem;
    }
}

@media (max-width: 768px) {
    /* Navigation Mobile Ottimizzata */
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 1rem 0;
        z-index: 999;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu li {
        margin: 0.3rem 0;
    }
    
    .nav-link {
        font-size: 1.1rem;
        padding: 0.6rem 1rem;
        display: block;
        transition: all 0.3s ease;
        border-radius: 8px;
        margin: 0 1rem;
    }
    
    .nav-link:hover {
        background: rgba(102, 126, 234, 0.1);
        color: #667eea;
    }
    
    .nav-cta {
        margin: 0.5rem 1rem 0;
    }
    
    .nav-cta .btn-consulenza {
        padding: 0.8rem 1.5rem;
        font-size: 1rem;
        width: 100%;
        justify-content: center;
    }
    
    /* Header mobile più compatto */
    .nav-logo h2 {
        font-size: 1.4rem;
    }
    
    .nav-logo span {
        font-size: 0.8rem;
    }
    
    /* Hero Section Mobile */
    .hero {
        height: auto;
        min-height: 100vh;
        padding: 80px 0 40px;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
        padding: 0 15px;
    }
    
    .hero-text h1 {
        font-size: 2.2rem;
        line-height: 1.3;
        margin-bottom: 1rem;
    }
    
    .hero-text p {
        font-size: 1.1rem;
        margin-bottom: 2rem;
    }
    
    .hero-buttons {
        justify-content: center;
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }
    
    .hero-stats {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-top: 2rem;
    }
    
    .stat {
        padding: 1.5rem;
        margin: 0 20px;
    }
    
    .stat h3 {
        font-size: 3.5rem;
        color: #ffffff;
    }
    
    .stat p {
        font-size: 1rem;
    }
    
    /* Sezioni Mobile */
    .services, .contact {
        padding: 60px 0;
    }
    
    .section-header {
        margin-bottom: 3rem;
        padding: 0 15px;
    }
    
    .section-header h2 {
        font-size: 2.2rem;
        line-height: 1.3;
    }
    
    .section-header p {
        font-size: 1.1rem;
    }
    
    /* Servizi Mobile */
    .services-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0 15px;
    }
    
    .service-card {
        padding: 1.8rem 1.4rem;
        margin-bottom: 1.5rem;
        border-radius: 12px;
    }
    
    .service-icon {
        width: 65px;
        height: 65px;
        margin-bottom: 1rem;
    }
    
    .service-icon i {
        font-size: 1.6rem;
    }
    
    .service-card h3 {
        font-size: 1.2rem;
        margin-bottom: 0.9rem;
        line-height: 1.3;
    }
    
    .service-card p {
        font-size: 0.9rem;
        margin-bottom: 1rem;
        line-height: 1.5;
    }
    
    /* Ottimizzazione liste per tablet */
    .service-card ul {
        margin-bottom: 0.8rem;
    }
    
    .service-card li {
        font-size: 0.85rem;
        padding: 0.45rem 0;
        padding-left: 1.1rem;
        line-height: 1.4;
    }
    
    .service-card li::before {
        content: '•';
        color: #4a90e2;
        font-weight: bold;
        font-size: 0.95rem;
        left: 0.25rem;
        top: 0.45rem;
    }
    
    /* Contatti Mobile */
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 0 15px;
    }
    
    .contact-info,
    .contact-form {
        margin-bottom: 2rem;
    }
    
    .contact-form {
        padding: 2rem 1.5rem;
    }
    
    .contact-item {
        margin-bottom: 1.5rem;
        flex-direction: row;
        align-items: flex-start;
    }
    
    .contact-item i {
        font-size: 1.3rem;
        margin-top: 0.1rem;
        margin-right: 0.5rem;
        min-width: 30px;
    }
    
    .contact-item h4 {
        font-size: 1.1rem;
        margin-bottom: 0.3rem;
    }
    
    .contact-item p {
        font-size: 0.95rem;
    }
    
    /* Form Mobile */
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px;
        font-size: 16px; /* Previene zoom su iOS */
    }
    
    .checkbox-container {
        font-size: 0.85rem;
        line-height: 1.4;
    }
    
    /* Footer Mobile */
    .footer {
        padding: 2rem 0 1rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        text-align: center;
        padding: 0 15px;
    }
    
    .footer-section h3,
    .footer-section h4 {
        font-size: 1.1rem;
    }
    
    .footer-section p {
        font-size: 0.9rem;
    }
    
    /* WhatsApp Mobile */
    .whatsapp-chat {
        bottom: 15px;
        left: 15px; /* Cambiato da right a left */
    }
    
    .whatsapp-btn {
        width: 55px;
        height: 55px;
        font-size: 1.6rem;
    }
    
    .tooltip {
        display: none; /* Nasconde tooltip su mobile */
    }
}

@media (max-width: 480px) {
    /* Extra Small Mobile */
    .container {
        padding: 0 10px;
    }
    
    /* Header Extra Small */
    .navbar {
        padding: 10px 0;
    }
    
    .nav-logo h2 {
        font-size: 1.2rem;
    }
    
    .nav-logo span {
        font-size: 0.75rem;
    }
    
    /* Hero Extra Small */
    .hero {
        padding: 70px 0 30px;
        background-size: cover;
        background-position: center;
    }
    
    .hero-content {
        padding: 0 10px;
        gap: 2rem;
    }
    
    .hero-text h1 {
        font-size: 1.8rem;
        line-height: 1.2;
    }
    
    .hero-text p {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .btn {
        padding: 12px 20px;
        font-size: 0.95rem;
        max-width: 100%;
    }
    
    .hero-stats {
        grid-template-columns: 1fr;
        gap: 1rem;
        margin-top: 1.5rem;
    }
    
    .stat {
        padding: 1rem;
        margin: 0 10px;
    }
    
    .stat h3 {
        font-size: 3rem;
        color: #ffffff;
    }
    
    .stat p {
        font-size: 0.9rem;
    }
    
    /* Sezioni Extra Small */
    .services, .contact {
        padding: 40px 0;
    }
    
    .section-header {
        margin-bottom: 2rem;
        padding: 0 10px;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
    }
    
    .section-header p {
        font-size: 1rem;
    }
    
    /* Servizi Extra Small - OTTIMIZZATI PER MOBILE */
    .services-grid {
        padding: 0 10px;
        gap: 1.2rem;
    }
    
    .service-card {
        padding: 1.5rem 1.2rem;
        margin-bottom: 1.5rem;
        border-radius: 12px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    }
    
    .service-icon {
        width: 55px;
        height: 55px;
        margin-bottom: 1rem;
    }
    
    .service-icon i {
        font-size: 1.4rem;
    }
    
    .service-card h3 {
        font-size: 1.1rem;
        margin-bottom: 0.8rem;
        line-height: 1.3;
    }
    
    .service-card p {
        font-size: 0.85rem;
        margin-bottom: 1rem;
        line-height: 1.5;
    }
    
    /* Ottimizzazione liste per mobile */
    .service-card ul {
        margin-bottom: 0.5rem;
    }
    
    .service-card li {
        font-size: 0.8rem;
        padding: 0.4rem 0;
        padding-left: 1rem;
        line-height: 1.4;
    }
    
    .service-card li::before {
        content: '•';
        color: #4a90e2;
        font-weight: bold;
        font-size: 0.9rem;
        left: 0.2rem;
        top: 0.45rem;
    }
    
    /* Contatti Extra Small */
    .contact-content {
        padding: 0 10px;
        gap: 1.5rem;
    }
    
    .contact-form {
        padding: 1.5rem 1rem;
    }
    
    .contact-info h3,
    .contact-form h3 {
        font-size: 1.4rem;
        margin-bottom: 1.5rem;
    }
    
    .contact-item {
        margin-bottom: 1.2rem;
    }
    
    .contact-item i {
        font-size: 1.2rem;
        min-width: 25px;
    }
    
    .contact-item h4 {
        font-size: 1rem;
    }
    
    .contact-item p {
        font-size: 0.9rem;
        line-height: 1.4;
    }
    
    /* Form Extra Small */
    .form-group {
        margin-bottom: 1.2rem;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 10px;
        font-size: 16px;
        border-radius: 8px;
    }
    
    .checkbox-container {
        font-size: 0.8rem;
    }
    
    /* Footer Extra Small */
    .footer-content {
        padding: 0 10px;
    }
    
    .footer-section {
        margin-bottom: 1rem;
    }
    
    .footer-section h3,
    .footer-section h4 {
        font-size: 1rem;
    }
    
    .footer-section p {
        font-size: 0.85rem;
    }
    
    /* WhatsApp Extra Small */
    .whatsapp-btn {
        width: 50px;
        height: 50px;
        font-size: 1.4rem;
        bottom: 10px;
        left: 10px; /* Cambiato da right a left */
    }
}

/* Mobile Touch Optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Dispositivi touch - rimuovi hover effects */
    .service-card:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
    
    .whatsapp-btn:hover {
        transform: none;
    }
    
    /* Aumenta area di tocco per elementi interattivi */
    .nav-link {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .btn {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Feedback visivo per touch */
    .service-card:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
    
    .btn:active {
        transform: scale(0.95);
        transition: transform 0.1s ease;
    }
}

/* Miglioramenti accessibilità mobile */
@media (max-width: 768px) {
    /* Focus visibile per navigazione da tastiera */
    .nav-link:focus,
    .btn:focus,
    input:focus,
    select:focus,
    textarea:focus {
        outline: 2px solid #4a90e2;
        outline-offset: 2px;
    }
    
    /* Scrolling più fluido */
    html {
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Evita zoom accidentale su iOS */
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    select,
    textarea {
        font-size: 16px !important;
        -webkit-appearance: none;
        border-radius: 0;
    }
    
    /* Migliora leggibilità su mobile */
    body {
        -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
    }
    
    /* Ottimizza selezione testo */
    .hero-text,
    .service-card,
    .contact-info {
        -webkit-user-select: text;
        -moz-user-select: text;
        -ms-user-select: text;
        user-select: text;
    }
}

/* Ottimizzazioni prestazioni mobile */
@media (max-width: 768px) {
    /* Riduci animazioni per prestazioni migliori */
    .service-card {
        animation: none;
    }
    
    /* Ottimizza rendering */
    .hero,
    .services,
    .contact {
        will-change: auto;
    }
    
    /* Semplifica ombre per prestazioni */
    .service-card,
    .contact-form {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    }
    
    .whatsapp-btn {
        box-shadow: 0 2px 10px rgba(37, 211, 102, 0.4);
    }
}

/* Animazioni per desktop */
@media (min-width: 769px) {
    @keyframes fadeInUp {
        from {
            opacity: 0;
            transform: translateY(30px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .service-card {
        animation: fadeInUp 0.6s ease forwards;
    }

    .service-card:nth-child(1) { animation-delay: 0.1s; }
    .service-card:nth-child(2) { animation-delay: 0.2s; }
    .service-card:nth-child(3) { animation-delay: 0.3s; }
    .service-card:nth-child(4) { animation-delay: 0.4s; }
    .service-card:nth-child(5) { animation-delay: 0.5s; }
    .service-card:nth-child(6) { animation-delay: 0.6s; }
}

/* Call to Action Preventivo */
.services-cta {
    margin-top: 50px;
    padding: 40px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    border-radius: 15px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.services-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1) 25%, transparent 25%), 
                linear-gradient(-45deg, rgba(255,255,255,0.1) 25%, transparent 25%);
    background-size: 20px 20px;
    opacity: 0.5;
}

.cta-content {
    position: relative;
    z-index: 2;
}

.services-cta h3 {
    color: white;
    font-size: 2rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.services-cta p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    margin-bottom: 25px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.btn-large {
    padding: 15px 35px;
    font-size: 1.1rem;
    font-weight: 600;
}

.btn-outline {
    background: transparent;
    color: #3498db;
    border: 2px solid #3498db;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

/* Responsive per Call to Action */
@media (max-width: 768px) {
    .services-cta {
        margin-top: 30px;
        padding: 30px 20px;
    }
    
    .services-cta h3 {
        font-size: 1.5rem;
    }
    
    .services-cta p {
        font-size: 1rem;
    }
    
    .btn-large {
        padding: 12px 25px;
        font-size: 1rem;
        width: 100%;
        justify-content: center;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 15px;
    }
    
    .hero-buttons .btn {
        width: 100%;
        justify-content: center;
        margin-bottom: 10px;
    }
    
    .hero-buttons .btn:last-child {
        margin-bottom: 0;
    }
} 

/* Miglioramenti per animazioni mobile */

/* ================================
   SEZIONE BLOG ANTEPRIMA PROFESSIONALE
   ================================ */
.blog-preview {
    padding: 100px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 50%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

.blog-preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="%23667eea" opacity="0.1"/><circle cx="80" cy="40" r="1.5" fill="%232c5aa0" opacity="0.1"/><circle cx="40" cy="80" r="2" fill="%23667eea" opacity="0.1"/></svg>') repeat;
    animation: float-dots 20s linear infinite;
    pointer-events: none;
}

@keyframes float-dots {
    0% { transform: translateY(0); }
    100% { transform: translateY(-100px); }
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 2.5rem;
    margin: 4rem 0;
    position: relative;
    z-index: 2;
}

.blog-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border: 1px solid rgba(102, 126, 234, 0.1);
}

.blog-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 25px 60px rgba(102, 126, 234, 0.25);
    border-color: rgba(102, 126, 234, 0.3);
}

.blog-header {
    padding: 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.blog-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: header-glow 6s ease-in-out infinite;
}

@keyframes header-glow {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-30%, -30%) scale(1.1); }
}

.blog-icon {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    position: relative;
    z-index: 2;
    backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.blog-icon i {
    font-size: 2.2rem;
    color: white;
}

.blog-icon.dichiarazioni {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.9), rgba(41, 128, 185, 0.9));
    box-shadow: 0 8px 32px rgba(52, 152, 219, 0.4);
}

.blog-icon.costituzione {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.9), rgba(39, 174, 96, 0.9));
    box-shadow: 0 8px 32px rgba(46, 204, 113, 0.4);
}

.blog-icon.agevolazioni {
    background: linear-gradient(135deg, rgba(230, 126, 34, 0.9), rgba(211, 84, 0, 0.9));
    box-shadow: 0 8px 32px rgba(230, 126, 34, 0.4);
}

.blog-category {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 600;
    text-align: center;
    position: relative;
    z-index: 2;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    letter-spacing: 0.5px;
}

.blog-content {
    padding: 2rem;
    position: relative;
}

.blog-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    color: #6c757d;
    font-size: 0.9rem;
    flex-wrap: wrap;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: #f8f9fa;
    padding: 0.5rem 0.8rem;
    border-radius: 20px;
    font-weight: 500;
}

.blog-meta i {
    color: #667eea;
}

.blog-content h3 {
    margin-bottom: 1rem;
    line-height: 1.4;
    font-size: 1.3rem;
    font-weight: 700;
}

.blog-content h3 a {
    color: #2c3e50;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.blog-content h3 a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    transition: width 0.3s ease;
}

.blog-content h3 a:hover {
    color: #667eea;
}

.blog-content h3 a:hover::after {
    width: 100%;
}

.blog-content p {
    color: #6c757d;
    margin-bottom: 2rem;
    line-height: 1.7;
    font-size: 0.95rem;
}

.blog-read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.8rem 1.5rem;
    border: 2px solid #667eea;
    border-radius: 30px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.blog-read-more::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    transition: left 0.3s ease;
    z-index: -1;
}

.blog-read-more:hover {
    color: white;
    border-color: #764ba2;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.blog-read-more:hover::before {
    left: 0;
}

.blog-read-more:hover i {
    transform: translateX(3px);
}

.blog-cta {
    text-align: center;
    margin-top: 4rem;
    position: relative;
    z-index: 2;
}

.btn-outline-primary {
    background: transparent;
    color: #667eea;
    border: 2px solid #667eea;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    position: relative;
    overflow: hidden;
}

.btn-outline-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    transition: left 0.3s ease;
    z-index: -1;
}

.btn-outline-primary:hover {
    color: white;
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.4);
}

.btn-outline-primary:hover::before {
    left: 0;
}

.btn-outline-primary:hover i {
    transform: rotate(360deg);
}

/* ================================
   RESPONSIVE BLOG SECTION
   ================================ */
@media (max-width: 768px) {
    .blog-preview {
        padding: 60px 0;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin: 2rem 0;
    }
    
    .blog-card {
        margin: 0 15px;
    }
    
    .blog-image {
        height: 180px;
    }
    
    .blog-content {
        padding: 1.2rem;
    }
    
    .blog-meta {
        flex-direction: column;
        gap: 0.5rem;
        margin-bottom: 0.8rem;
    }
    
    .blog-content h3 {
        font-size: 1.1rem;
        margin-bottom: 0.6rem;
    }
    
    .blog-content p {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
}

/* ================================
   MIGLIORAMENTI MOBILE GENERALI
   ================================ */
@media (max-width: 768px) {
    /* Container più compatto su mobile */
    .container {
        padding: 0 15px;
    }
    
    /* Spaziature sezioni ridotte */
    .services {
        padding: 60px 0;
    }
    
    .contact {
        padding: 60px 0;
    }
    
    /* Section headers più compatti */
    .section-header {
        margin-bottom: 2rem;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
        margin-bottom: 0.8rem;
    }
    
    .section-header p {
        font-size: 1rem;
        line-height: 1.5;
    }
    
    /* Pulsanti più compatti */
    .btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.95rem;
    }
    
    /* Contact form migliorata */
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .contact-item {
        margin-bottom: 1.5rem;
    }
    
    /* Service cards più compatte */
    .service-card {
        padding: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .service-card h3 {
        font-size: 1.2rem;
        margin-bottom: 0.8rem;
    }
    
    .service-card p {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
    
    .service-card ul li {
        font-size: 0.85rem;
        margin-bottom: 0.3rem;
    }
    
    /* Footer più compatto */
    .footer {
        padding: 40px 0 20px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        text-align: center;
    }
    
    .footer-section {
        margin-bottom: 1rem;
    }
    
    /* Floating buttons ottimizzati */
    .floating-cta {
        bottom: 80px;
        right: 15px;
    }
    
    .floating-btn {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .whatsapp-chat {
        bottom: 15px;
        right: 15px;
    }
    
    .whatsapp-btn {
        width: 55px;
        height: 55px;
        font-size: 1.4rem;
    }
    
    /* Form elements più touch-friendly */
    input, textarea, select {
        font-size: 16px; /* Previene zoom su iOS */
        padding: 0.8rem;
        border-radius: 8px;
    }
    
    /* Miglioramenti tipografici mobile */
    body {
        font-size: 16px;
        line-height: 1.5;
    }
    
    h1 {
        font-size: 2rem;
        line-height: 1.3;
    }
    
    h2 {
        font-size: 1.6rem;
        line-height: 1.3;
    }
    
    h3 {
        font-size: 1.3rem;
        line-height: 1.4;
    }
    
    /* Spaziatura touch-friendly per links */
    a {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }
    
    /* Menu mobile: riduci ulteriormente spazi su schermi piccoli */
    @media (max-width: 480px) {
        .nav-menu {
            padding: 0.5rem 0;
        }
        
        .nav-menu li {
            margin: 0.2rem 0;
        }
        
        .nav-link {
            padding: 0.5rem 0.8rem;
            font-size: 1rem;
            margin: 0 0.5rem;
        }
        
        .nav-cta {
            margin: 0.3rem 0.5rem 0;
        }
        
        .nav-cta .btn-consulenza {
            padding: 0.7rem 1.2rem;
            font-size: 0.9rem;
        }
    }
}

/* ================================
   SEZIONE PREVENTIVO PROFESSIONALE
   ================================ */
.preventivo-section {
    padding: 100px 0;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 50%, #e9ecef 100%);
    position: relative;
    overflow: hidden;
}

.preventivo-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="%23e0e7ef" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>') repeat;
    opacity: 0.3;
    pointer-events: none;
}

.preventivo-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.preventivo-info {
    animation: slideInLeft 0.8s ease-out;
}

.preventivo-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #2c5aa0 0%, #1e4080 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(44, 90, 160, 0.3);
    animation: float 3s ease-in-out infinite;
}

.preventivo-icon i {
    font-size: 2.5rem;
    color: white;
}

.preventivo-info h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c5aa0;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.preventivo-info p {
    font-size: 1.1rem;
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 2.5rem;
}

.preventivo-features {
    margin-bottom: 3rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 0.8rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.feature-item:hover {
    transform: translateX(10px);
    box-shadow: 0 5px 20px rgba(44, 90, 160, 0.15);
}

.feature-item i {
    color: #28a745;
    font-size: 1.2rem;
    min-width: 20px;
}

.feature-item span {
    font-weight: 500;
    color: #343a40;
}

.preventivo-cta {
    text-align: left;
}

.btn-preventivo {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 2.5rem;
    background: linear-gradient(135deg, #2c5aa0 0%, #1e4080 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: 0 8px 25px rgba(44, 90, 160, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    margin-bottom: 1rem;
}

.btn-preventivo:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 35px rgba(44, 90, 160, 0.6);
}

.btn-preventivo .btn-arrow {
    background: rgba(255, 255, 255, 0.2);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

.btn-preventivo:hover .btn-arrow {
    transform: translateX(5px) scale(1.1);
}

.preventivo-note {
    font-size: 0.9rem;
    color: #6c757d;
    margin: 0;
    font-style: italic;
}

.preventivo-visual {
    animation: slideInRight 0.8s ease-out;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.preventivo-card {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(44, 90, 160, 0.1);
    position: relative;
    overflow: hidden;
}

.preventivo-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #2c5aa0, #28a745, #ffc107, #dc3545);
    background-size: 200% 100%;
    animation: gradientShift 3s ease-in-out infinite;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e9ecef;
}

.card-header i {
    font-size: 1.5rem;
    color: #2c5aa0;
}

.card-header h4 {
    margin: 0;
    color: #343a40;
    font-weight: 600;
}

.card-steps {
    margin-bottom: 2rem;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 0.8rem;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.step-item.active {
    background: rgba(44, 90, 160, 0.1);
    border-left: 3px solid #2c5aa0;
}

.step-number {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    color: #6c757d;
    transition: all 0.3s ease;
}

.step-item.active .step-number {
    background: #2c5aa0;
    color: white;
    animation: pulse 2s infinite;
}

.step-item span {
    font-weight: 500;
    color: #343a40;
}

.step-item.active span {
    color: #2c5aa0;
    font-weight: 600;
}

.card-footer {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.progress-bar {
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 25%;
    background: linear-gradient(90deg, #2c5aa0, #28a745);
    border-radius: 3px;
    animation: progressGrow 2s ease-out infinite;
}

.progress-text {
    font-size: 0.85rem;
    color: #6c757d;
    text-align: center;
    font-weight: 500;
}

.preventivo-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.stat-item {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-5px);
}

.stat-item i {
    font-size: 2rem;
    color: #2c5aa0;
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c5aa0;
    line-height: 1;
}

.stat-label {
    font-size: 0.8rem;
    color: #6c757d;
    font-weight: 500;
}

/* Animazioni */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

@keyframes progressGrow {
    0% {
        width: 0%;
    }
    100% {
        width: 25%;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* ================================
   RESPONSIVE BLOG E PREVENTIVO
   ================================ */
@media (max-width: 1024px) {
    .blog-preview {
        padding: 80px 0;
    }
    
    .blog-grid {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
        gap: 2rem;
        margin: 3rem 0;
    }
    
    .preventivo-section {
        padding: 80px 0;
    }
    
    .preventivo-content {
        gap: 3rem;
    }
    
    .preventivo-info h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    /* Blog Mobile */
    .blog-preview {
        padding: 60px 0;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin: 2rem 0;
    }
    
    .blog-card {
        margin: 0 15px;
    }
    
    .blog-header {
        padding: 1.5rem;
        text-align: center;
    }
    
    .blog-icon {
        width: 60px;
        height: 60px;
    }
    
    .blog-icon i {
        font-size: 1.8rem;
    }
    
    .blog-content {
        padding: 1.5rem;
    }
    
    .blog-meta {
        flex-direction: column;
        gap: 0.8rem;
        margin-bottom: 1rem;
    }
    
    .blog-content h3 {
        font-size: 1.1rem;
        margin-bottom: 0.8rem;
    }
    
    .blog-content p {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }
    
    .blog-read-more {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .btn-outline-primary {
        padding: 12px 25px;
        font-size: 1rem;
    }
    
    /* Preventivo Mobile */
    .preventivo-section {
        padding: 60px 0;
    }
    
    .preventivo-content {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    
    .preventivo-info h2 {
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .preventivo-info p {
        font-size: 1rem;
        margin-bottom: 2rem;
    }
    
    .preventivo-cta {
        text-align: center;
    }
    
    .btn-preventivo {
        padding: 1rem 2rem;
        font-size: 1rem;
    }
    
    .preventivo-card {
        padding: 1.5rem;
    }
    
    .preventivo-stats {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .stat-item {
        padding: 1.2rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .feature-item:hover {
        transform: translateY(-3px);
    }
}

@media (max-width: 480px) {
    /* Blog Extra Small */
    .blog-preview {
        padding: 40px 0;
    }
    
    .blog-card {
        margin: 0 10px;
    }
    
    .blog-header {
        padding: 1.2rem;
    }
    
    .blog-icon {
        width: 50px;
        height: 50px;
    }
    
    .blog-icon i {
        font-size: 1.5rem;
    }
    
    .blog-content {
        padding: 1.2rem;
    }
    
    .blog-content h3 {
        font-size: 1rem;
    }
    
    .blog-content p {
        font-size: 0.85rem;
    }
    
    .blog-category {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
    
    /* Preventivo Extra Small */
    .preventivo-section {
        padding: 40px 0;
    }
    
    .preventivo-content {
        gap: 2rem;
    }
    
    .preventivo-info h2 {
        font-size: 1.8rem;
    }
    
    .preventivo-icon {
        width: 60px;
        height: 60px;
        margin: 0 auto 1.5rem;
    }
    
    .preventivo-icon i {
        font-size: 2rem;
    }
    
    .btn-preventivo {
        padding: 0.9rem 1.8rem;
        font-size: 0.95rem;
    }
    
    .preventivo-card {
        padding: 1.2rem;
    }
    
    .stat-item {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
    }
    
    .stat-number {
        font-size: 1.8rem;
    }
}
