/* --- IMPOSTAZIONI GENERALI E TUA PALETTE PANTONE --- */
        :root {
            --grigio-antracite: #242526;
            --grigio-sfondo-hero: #3a3b3c;
            --grigio-testo: #333333;
            --grigio-testo-chiaro: #606266;
            --verde-eco: #237d00;        /* Il tuo nuovo verde aziendale */
            --verde-eco-hover: #36af07;  /* Il tuo verde luminoso */
            --verde-eco-contrasto: #36af07;
            --bianco: #ffffff;           /* Bianco puro per le schede */
            --grigio-chiaro: #f5f5f5;    /* Il tuo panna Pantone per lo sfondo */
            --grigio-bordo: #e4e7ed;
        }

        body { 
            font-family: 'Inter', sans-serif; 
            margin: 0; 
            padding: 0; 
            color: var(--grigio-testo); 
            line-height: 1.7; 
            background-color: var(--grigio-chiaro); 
            -webkit-font-smoothing: antialiased; 
        }

        a:focus-visible,
        button:focus-visible,
        input:focus-visible,
        textarea:focus-visible,
        summary:focus-visible {
            outline: 3px solid var(--verde-eco-contrasto);
            outline-offset: 3px;
        }

        /* --- TOP BAR --- */
        .top-bar {
            background-color: var(--verde-eco);
            color: var(--bianco);
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 8px 20px;
            font-size: 13px;
            letter-spacing: 0.5px;
            z-index: 200;
            position: relative;
        }
        
        .top-bar-content { display: flex; align-items: center; gap: 15px; }
        .top-bar-title { font-weight: 400; opacity: 0.9; display: flex; align-items: center; gap: 6px; }
        .top-bar-title svg { width: 14px; height: 14px; }
        .top-bar a { color: var(--bianco); text-decoration: none; font-weight: 700; transition: opacity 0.3s ease; }
        .top-bar a:hover { opacity: 0.8; text-decoration: underline; }
        .top-bar-divider { opacity: 0.5; font-size: 10px; }

        @keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
        @keyframes pulseDot { 0% { box-shadow: 0 0 0 0 rgba(35, 125, 0, 0.7); } 70% { box-shadow: 0 0 0 6px rgba(35, 125, 0, 0); } 100% { box-shadow: 0 0 0 0 rgba(35, 125, 0, 0); } }

        /* --- HEADER --- */
        header { 
            background-color: var(--grigio-antracite); 
            padding: 20px 50px; 
            display: flex; 
            justify-content: space-between; 
            align-items: center; 
            border-bottom: 3px solid var(--verde-eco); 
            position: sticky; 
            top: 0; 
            z-index: 100; 
            box-shadow: 0 4px 12px rgba(0,0,0,0.08); 
        }
        header .site-logo { margin: 0; font-size: 22px; letter-spacing: 1px; color: var(--bianco); font-weight: 700; text-decoration: none; display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; }
        header .site-logo-mark { width: 77px; height: auto; flex: 0 0 auto; display: block; }
        header .site-logo span { color: var(--verde-eco-contrasto); }
        nav { display: flex; gap: 35px; }
        nav a { 
            color: var(--bianco); 
            text-decoration: none; 
            font-weight: 500; 
            font-size: 14px; 
            text-transform: uppercase; 
            letter-spacing: 1px; 
            position: relative; 
            padding-bottom: 5px; 
            transition: color 0.3s ease; 
        }
        nav a::after { 
            content: ''; 
            position: absolute; 
            width: 0; 
            height: 2px; 
            bottom: 0; 
            left: 0; 
            background-color: var(--verde-eco-contrasto); 
            transition: width 0.3s ease; 
        }
        nav a:hover, nav a.active { color: var(--verde-eco-contrasto); }
        nav a:hover::after, nav a.active::after { width: 100%; }

        /* --- BANNER --- */
        .page-banner { 
            background-color: var(--grigio-antracite); 
            padding: 100px 50px; 
            text-align: center; 
            background-image: linear-gradient(rgba(36, 37, 38, 0.9), rgba(36, 37, 38, 0.9)); 
            color: var(--bianco); 
        }
        .page-banner h1 { font-size: 42px; margin: 0; font-weight: 700; letter-spacing: -1px; animation: fadeInUp 0.8s ease-out forwards;}
        .page-banner p { color: var(--verde-eco-contrasto); font-size: 16px; text-transform: uppercase; letter-spacing: 2px; margin-top: 10px; font-weight: 600;}

        /* --- INTRODUZIONE --- */
        .fleet-intro { padding: 80px 10% 40px 10%; text-align: center; max-width: 800px; margin: 0 auto; animation: fadeInUp 1s ease-out forwards; }
        .fleet-intro p { font-size: 18px; color: var(--grigio-testo-chiaro); margin-bottom: 30px; }
        
        .tracking-badge {
            display: inline-flex; align-items: center; background-color: var(--bianco);
            padding: 10px 20px; border-radius: 50px; border: 1px solid var(--grigio-bordo);
            font-size: 14px; font-weight: 600; color: var(--grigio-antracite); text-transform: uppercase; letter-spacing: 1px;
        }
        .tracking-dot { width: 10px; height: 10px; background-color: var(--verde-eco); border-radius: 50%; margin-right: 12px; animation: pulseDot 2s infinite; }

        /* --- GRIGLIA VEICOLI --- */
        .fleet-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 40px; padding: 0 10% 90px 10%; animation: fadeInUp 1.2s ease-out forwards; }

        .vehicle-card {
            background: var(--bianco); border-radius: 8px; border: 1px solid var(--grigio-bordo);
            box-shadow: 0 4px 20px rgba(0,0,0,0.02); overflow: hidden; transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
            display: flex; flex-direction: column;
        }
        .vehicle-card:hover { transform: translateY(-8px); box-shadow: 0 20px 40px rgba(0,0,0,0.08); border-color: transparent; }

        .vehicle-image {
            height: 280px; background-color: #e9ecef; position: relative; overflow: hidden;
            background-size: cover; background-position: center;
        }

        /* Classi specifiche per le immagini della flotta */
        .img-standard { background-image: url('../img/Van_standard.jpeg'); }
        .img-cassonati { background-image: url('../img/Van_cassonati_retro.jpeg'); }
        .img-centinato { background-image: url('../img/Van_centinato.jpeg'); }
        .img-motrici { background-image: url('../img/Van_cassonati_fronte.jpeg'); }

        .vehicle-content { padding: 40px; border-top: 3px solid var(--verde-eco); flex-grow: 1; display: flex; flex-direction: column; }
        .vehicle-content h3 { color: var(--grigio-antracite); margin-top: 0; margin-bottom: 15px; font-size: 22px; font-weight: 600; }
        .vehicle-content p { font-size: 15px; color: var(--grigio-testo-chiaro); margin: 0 0 20px 0; line-height: 1.7; flex-grow: 1; }

        /* --- TOOLTIP DIMENSIONI --- */
        .tooltip-container { position: relative; display: inline-block; margin-top: auto; }
        
        .tooltip-trigger {
            display: inline-flex; align-items: center; gap: 8px;
            background-color: var(--grigio-chiaro); color: var(--verde-eco);
            padding: 8px 16px; border-radius: 4px; border: 1px solid var(--grigio-bordo);
            font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 1px;
            cursor: pointer; transition: all 0.3s ease;
        }
        .tooltip-trigger svg { width: 16px; height: 16px; }
        .tooltip-trigger:hover { background-color: var(--verde-eco); color: var(--bianco); }

        .tooltip-content {
            visibility: hidden; opacity: 0; position: absolute; bottom: 130%; left: 0;
            background-color: var(--grigio-antracite); color: var(--bianco);
            padding: 20px; border-radius: 6px; width: 260px;
            box-shadow: 0 10px 25px rgba(0,0,0,0.15);
            transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
            transform: translateY(10px); z-index: 10;
        }
        
        .tooltip-content::after {
            content: ''; position: absolute; top: 100%; left: 30px;
            border-width: 8px; border-style: solid;
            border-color: var(--grigio-antracite) transparent transparent transparent;
        }

        .tooltip-container:hover .tooltip-content { visibility: visible; opacity: 1; transform: translateY(0); }

        .tooltip-content strong { display: block; color: var(--verde-eco-contrasto); margin-bottom: 10px; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 5px; }
        .tooltip-content ul { list-style: none; padding: 0; margin: 0; font-size: 13px; color: #d1d5db; }
        .tooltip-content ul li { margin-bottom: 6px; display: flex; justify-content: space-between; }
        .tooltip-content ul li span { font-weight: 600; color: var(--bianco); }

        /* --- CTA E FOOTER --- */
        .cta-section { background-color: var(--grigio-antracite); padding: 80px 10%; text-align: center; color: var(--bianco); }
        .cta-section h3 { font-size: 32px; color: var(--bianco); margin-bottom: 20px; }
        .cta-section p { font-size: 18px; color: #a0aab5; margin-bottom: 40px; }
        .btn { display: inline-block; padding: 16px 36px; background-color: var(--verde-eco); color: var(--bianco); text-decoration: none; font-weight: 600; border-radius: 4px; text-transform: uppercase; font-size: 13px; letter-spacing: 1px; transition: all 0.3s ease; }
        .btn:hover { background-color: var(--verde-eco-hover); transform: translateY(-3px); box-shadow: 0 8px 15px rgba(54, 175, 7, 0.3); }
        
        footer { 
            background-color: var(--grigio-antracite); 
            padding: 30px 20px; /* Spazio ridotto */
            text-align: center; 
            border-top: 1px solid rgba(255,255,255,0.05);
        }

        .footer-logo {
            width: 300px; /* Leggermente più piccolo per delicatezza */
            height: auto; 
            margin-bottom: 15px; 
            /* filter: brightness(0) invert(1); /* Lo rende bianco */ */
        }

        .footer-info {
            color: #9ca3af;
            font-size: 13px;
            margin: 0 0 8px 0;
        }

        .footer-info a {
            color: #9ca3af;
            text-decoration: none;
            transition: color 0.3s;
        }

        .footer-info a:hover {
            color: var(--verde-eco-contrasto);
        }

        .footer-legal {
            color: #6b7280;
            font-size: 11px;
            margin: 0;
            letter-spacing: 0.3px;
        }

        @media (max-width: 900px) { .fleet-grid { grid-template-columns: 1fr; } .vehicle-image { height: 220px; } }
        @media (max-width: 768px) { .page-banner { padding: 60px 20px; } .fleet-intro { padding-top: 60px; } }


        /* --- MENU MOBILE --- */
        .menu-toggle {
            display: none;
        }

        .menu-toggle-label {
            display: none;
            width: 42px;
            height: 42px;
            border: 1px solid rgba(255,255,255,0.18);
            border-radius: 4px;
            align-items: center;
            justify-content: center;
            flex-direction: column;
            gap: 5px;
            cursor: pointer;
        }

        .menu-toggle-label span {
            display: block;
            width: 22px;
            height: 2px;
            background-color: var(--bianco);
            transition: all 0.3s ease;
        }

        @media (max-width: 768px) {
            header {
                flex-direction: row;
                justify-content: space-between;
                align-items: center;
                padding: 16px 20px;
                position: sticky;
                top: 0;
            }

            header .site-logo {
                font-size: 18px;
                letter-spacing: 0.5px;
            }

            .menu-toggle-label {
                display: flex;
            }

            nav {
                display: none;
                position: absolute;
                left: 0;
                right: 0;
                top: 100%;
                background-color: var(--grigio-antracite);
                border-top: 1px solid rgba(255,255,255,0.08);
                border-bottom: 3px solid var(--verde-eco);
                padding: 12px 20px 18px 20px;
                margin-top: 0;
                box-shadow: 0 12px 24px rgba(0,0,0,0.18);
            }

            .menu-toggle:checked ~ nav {
                display: flex;
                flex-direction: column;
                gap: 0;
            }

            nav a {
                display: block;
                padding: 13px 0;
                font-size: 13px;
                border-bottom: 1px solid rgba(255,255,255,0.08);
            }

            nav a:last-child {
                border-bottom: none;
            }

            .menu-toggle:checked + .menu-toggle-label span:nth-child(1) {
                transform: translateY(7px) rotate(45deg);
            }

            .menu-toggle:checked + .menu-toggle-label span:nth-child(2) {
                opacity: 0;
            }

            .menu-toggle:checked + .menu-toggle-label span:nth-child(3) {
                transform: translateY(-7px) rotate(-45deg);
            }

            .top-bar {
                font-size: 12px;
                padding: 9px 12px;
            }

            .top-bar-content {
                gap: 4px;
            }

            footer {
                padding: 28px 16px;
            }

            .footer-logo {
                width: 220px;
                max-width: 80%;
            }

            .footer-info {
                font-size: 12px;
                line-height: 1.6;
            }

            .footer-legal {
                font-size: 10px;
                line-height: 1.5;
            }
        }

        @media (max-width: 480px) {
            header .site-logo {
                font-size: 16px;
                gap: 8px;
            }

            header .site-logo-mark {
                width: 60px;
            }

            .menu-toggle-label {
                width: 40px;
                height: 40px;
            }

            .page-banner h1,
            .hero h1 {
                font-size: 30px;
                line-height: 1.18;
            }

            .page-banner p,
            .hero p {
                font-size: 15px;
            }

            .btn {
                width: 100%;
                max-width: 300px;
                box-sizing: border-box;
                text-align: center;
            }
        }


        @media (max-width: 768px) {
            .fleet-intro {
                padding: 58px 6% 34px 6%;
                text-align: left;
            }

            .fleet-intro p {
                font-size: 16px;
            }

            .tracking-badge {
                align-items: flex-start;
                border-radius: 8px;
                line-height: 1.5;
            }

            .fleet-grid {
                padding: 0 6% 70px 6%;
                gap: 28px;
            }

            .vehicle-content {
                padding: 30px 24px;
            }

            .tooltip-content {
                left: 0;
                width: min(260px, 74vw);
            }
        }


        /* --- FIX STEP 5B: TOP BAR MOBILE E FOOTER --- */
        footer,
        footer p,
        footer span,
        footer .footer-info,
        footer .footer-legal {
            color: #9ca3af;
        }

        footer a,
        footer a:visited,
        footer a:active {
            color: #9ca3af;
            text-decoration: none;
        }

        footer a:hover {
            color: var(--verde-eco-contrasto);
        }

        .footer-legal a,
        .footer-legal a:visited,
        .footer-legal a:active {
            color: #6b7280;
            text-decoration: none;
        }

        .footer-legal a:hover {
            color: var(--verde-eco-contrasto);
        }

        @media (max-width: 768px) {
            .top-bar {
                padding: 10px 14px;
            }

            .top-bar-content {
                width: 100%;
                display: grid;
                grid-template-columns: 1fr 1fr;
                align-items: start;
                gap: 12px;
                text-align: center;
            }

            .top-bar-title,
            .top-bar-divider {
                display: none !important;
            }

            .top-bar-content > span:not(.top-bar-title):not(.top-bar-divider) {
                display: block;
                line-height: 1.35;
                font-size: 13px;
                font-weight: 500;
                min-width: 0;
            }

            .top-bar-content > span:not(.top-bar-title):not(.top-bar-divider) a {
                display: block;
                margin-top: 3px;
                font-size: 13px;
                font-weight: 700;
                white-space: nowrap;
            }
        }

        @media (max-width: 390px) {
            .top-bar {
                padding: 9px 10px;
            }

            .top-bar-content {
                gap: 8px;
            }

            .top-bar-content > span:not(.top-bar-title):not(.top-bar-divider),
            .top-bar-content > span:not(.top-bar-title):not(.top-bar-divider) a {
                font-size: 12px;
            }
        }


        /* --- FIX STEP 5D: DATI TECNICI FLOTTA CON DETAILS/SUMMARY --- */
        .tech-details {
            margin-top: auto;
            position: relative;
        }

        .tech-details summary {
            list-style: none;
        }

        .tech-details summary::-webkit-details-marker {
            display: none;
        }

        .tech-details .tooltip-trigger {
            font-family: inherit;
            appearance: none;
            -webkit-appearance: none;
            user-select: none;
        }

        .tech-details[open] .tooltip-trigger {
            background-color: var(--verde-eco);
            color: var(--bianco);
        }

        .tech-details[open] .tooltip-content {
            visibility: visible;
            opacity: 1;
            transform: translateY(0);
        }

        @media (hover: hover) and (pointer: fine) {
            .tech-details:hover .tooltip-content {
                visibility: visible;
                opacity: 1;
                transform: translateY(0);
            }
        }

        @media (hover: none), (pointer: coarse) {
            .tech-details {
                width: 100%;
            }

            .tech-details .tooltip-trigger {
                display: flex;
                justify-content: center;
                width: 100%;
                min-height: 46px;
                box-sizing: border-box;
            }

            .tech-details .tooltip-content {
                position: static;
                width: auto;
                margin-top: 14px;
                visibility: visible;
                opacity: 1;
                transform: none;
                display: none;
                box-shadow: 0 10px 24px rgba(0,0,0,0.12);
            }

            .tech-details .tooltip-content::after {
                display: none;
            }

            .tech-details[open] .tooltip-content {
                display: block;
            }
        }
