:root {
    --primary-blue: #00008b;
    --secondary-blue: #1e90ff;
    --brand-yellow: #ffff00;
}

/* Scroll fluido */
html { scroll-behavior: smooth; }

/* --- SLIDER / CAROSELLO --- */
.slider-container {
    position: relative;
    width: 100%;
    height: 450px;
    overflow: hidden;
    background-color: var(--primary-blue);
}

.slider {
    display: flex;
    width: 100%; 
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.slide {
    min-width: 100%; /* Ogni slide occupa il 100% della vista */
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-around; /* Cambiato da center a space-around */
    text-align: left; /* Meglio allineato a sinistra se c'è un'immagine a destra */
    color: white;
    padding: 0 10%;
    box-sizing: border-box;
    background-size: cover;
    background-position: center;
    position: relative;
    flex-wrap: wrap; /* Permette alla mascotte di andare sotto il testo su mobile */
}

.slide::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(45deg, rgba(0,0,139,0.8), rgba(30,144,255,0.4));
    z-index: 1;
}

.slide-content {
    position: relative;
    z-index: 2;
    max-width: 600px; /* Ridotto leggermente per far spazio alla mascotte */
    flex: 1;
    min-width: 300px; /* Impedisce al testo di diventare troppo stretto */
}

.slide-content h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3rem;
    margin-bottom: 15px;
    color: var(--brand-yellow);
}

.slide-content p {
    font-size: 1.25rem;
    margin-bottom: 30px;
}

.btn-slide {
    padding: 12px 30px;
    background: var(--brand-yellow);
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: bold;
    border-radius: 50px;
    transition: 0.3s;
    display: inline-block;
}

.btn-slide:hover { transform: scale(1.1); box-shadow: 0 0 20px rgba(255,255,0,0.4); }
/* --- NUOVI STILI MASCOTTE SLIDER --- */
.mascot-container {
    position: relative;
    z-index: 2;
    flex: 0 0 300px; /* Larghezza fissa per la mascotte */
    display: flex;
    justify-content: center;
    align-items: center;
}

.slide-mascot {
    max-width: 250px; /* Regola questa grandezza in base alla tua immagine */
    height: auto;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.3));
    animation: float-mascot 3s ease-in-out infinite;
}

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

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.dot {
    width: 12px; height: 12px;
    background: rgba(255,255,255,0.3);
    border-radius: 50%;
    cursor: pointer;
}

.dot.active { background: var(--brand-yellow); }

@media (max-width: 768px) {
    .slider-container { height: 350px; }
    .slide-content h2 { font-size: 1.8rem; }
}

/* --- ANIMAZIONI --- */
.scrolling-text { 
    display: inline-flex !important; 
    white-space: nowrap !important; 
    width: max-content !important; 
    /* 150s è estremo: se è troppo lento scendi a 100s */
    animation: scorri-testo 50s linear infinite !important; 
    will-change: transform;
}

@keyframes scorri-testo {
    0% { transform: translateX(40%); }
    100% { transform: translateX(-50%); }
}

/* Questo serve solo per rendere il movimento fluido */
.scrolling-text {
    will-change: transform;
}
/* 1. Animazione del movimento del furgone */
@keyframes drive-pass {
  0% { transform: translateX(-20%); }
  100% { transform: translateX(120vw); }
}

/* 2. Animazione del fumetto (fluttuante) */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

/* Configurazione del contenitore del furgone */
.mascotte-box {
  position: absolute;
  bottom: 20%;
  left: -150px; /* Parte fuori dallo schermo */
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: drive-pass 8s linear infinite;
}

/* L'icona del furgone */
.van-icon {
  font-size: 5rem;
  color: #1e3a8a; /* Blu scuro elegante */
}

/* Il fumetto "CONSEGNA RAPIDA!" */
.bubble {
  background: #ffff00;
  color: #00008b;
  padding: 5px 12px;
  border-radius: 15px;
  font-size: 0.8rem;
  font-weight: bold;
  margin-bottom: 10px;
  position: relative;
  white-space: nowrap;
  animation: float 2s ease-in-out infinite;
}

/* Punta del fumetto */
.bubble::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #1e3a8a;
}

/* Scintille/Effetto velocità */
.spark {
  position: absolute;
  height: 4px;
  background: #fbbf24; /* Colore oro/giallo per risaltare */
  border-radius: 2px;
  opacity: 0.6;
}

.sp1 { width: 20px; bottom: 5px; left: -25px; }
.sp2 { width: 15px; bottom: 15px; left: -20px; }
.sp3 { width: 25px; bottom: 10px; left: -35px; }
/* --- SEZIONE LOGHI STATICI (ZERO EFFETTI) --- */
.partners-static-section {
    padding: 60px 5%;
    background-color: #ffffff; 
    text-align: center;
}

.partners-title {
    color: var(--primary-blue);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.partners-subtitle {
    color: #777;
    margin-bottom: 40px;
    font-size: 1rem;
}

.partners-grid {
    display: grid;
    /* Configurazione colonne: 2 su mobile, 3 su tablet, 6 su desktop */
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    align-items: center;
    max-width: 1000px;
    margin: 0 auto;
}

@media (min-width: 640px) {
    .partners-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
    .partners-grid { grid-template-columns: repeat(6, 1fr); }
}

.partner-card {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.partner-logo {
    max-width: 100%;
    height: 40px; /* Altezza fissa per tenerli tutti uguali */
    object-fit: contain;
    /* Nessun filtro: i loghi restano con i loro colori originali */
    opacity: 1; 
}

/*SOTTOPAGINA SPEDIZIONI*/

/* Sezione Partner Spedizioni */
.partner-grid div {
    transition: transform 0.3s ease, opacity 0.3s ease;
    cursor: default;
    opacity: 0.8;
}

.partner-grid div:hover {
    transform: scale(1.1);
    opacity: 1;
}

/* Colori Brand Posta Privata Chiaiano */
.brand-sda {
    color: #004595; /* Blu SDA */
}

.brand-fedex-purple {
    color: #4D148C; /* Viola FedEx */
}

.brand-fedex-orange {
    color: #FF6600; /* Arancione FedEx */
}

.brand-brt {
    color: #E2001A; /* Rosso BRT */
}

.brand-gls {
    color: #002F6C; /* Blu GLS */
}