/* General Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;

    --colore-principale: #265B91;
    --colore-testo: rgb(49, 103, 129);

}

body {
    overflow-x: hidden;
}

#particle-js {
    width: 95%;
    height: 400px;
    background-color: #00a326cc;
    /* colore iniziale */
    position: relative;
    margin: 0 auto;
    border-radius: 8px;
    box-shadow: 0 0 10px;
}

small {
    font-size: 1.2rem;
}

#form-campionati-eu {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 8px;
    gap: 20px;

}

select {
    border-radius: 15px;
    font-size: 18px;
    padding: 15px;
}

#form-campionati-eu select {
    border-radius: 20px;
    font-size: 18px;
    margin-top: 20px;
    padding: 15px;
}

#sezione-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    font-size: 3rem;
    height: 2.6rem;
}

#sezione-logo img {
    border-radius: 50%;
    animation-name: animazionepallone;
    animation-duration: 10s;
    transform: rotate(0);

}

/* Video a schermo intero in primo piano */
#video-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: black;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

#intro-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Nasconde il video dopo la riproduzione */
.hidden {
    opacity: 0;
    visibility: hidden;
    transition: opacity 1s ease-out;
}

/* Contenuto della home page */
#home-content {
    display: none;
    /* Nasconde il contenuto finché il video è in riproduzione */
    text-align: center;
    font-size: 2em;
    font-weight: bold;
    margin-top: 20%;
}

/* ANIMAZIONI */
@keyframes animazionepallone {
    80% {
        transform: rotate(360deg) scale(0.5);
    }

    100% {
        transform: scale(1);
    }
}

body {
    background-color: #f4f4f4;
    color: #333;
}

header {
    margin-top: 30px;

}



#logo img {
    max-width: 150px;
    border-radius: 15px;

}

#navigazione {
    display: flex;
    justify-content: center;
    width: 100%;
    background-color: black;
    margin-bottom: 0;
    border-top: 20px solid hsl(116, 100%, 30%);
}

nav ul {
    list-style-type: none;
    padding: 0;
    margin-top: 10px;
    background-color: black;
    color: white;
    padding: 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: center;
    gap: 2rem;
}


nav ul li a {
    text-decoration: none;
    color: rgb(255, 255, 255);
    font-weight: bold;
    padding: 5px 10px;
    border-radius: 5px;
    transition: background-color 0.3s ease;

}

nav ul li {
    border-right: 1px solid var(--colore-principale);

}

nav ul li a:hover {
    background-color: #2e2e2e;
}

main {
    padding: 20px;
    text-align: center;
    width: 98%;
    margin: 0 auto;
    background-image: url(/src/sfondo-statistiche-commenti.webp);
}

main>h2 {
    margin-top: 20px;
}

#latest-comments {
    background-color: #edecec;

}

#latest-comments h2 {
    color: #f2f2f2;
    margin-bottom: 20px;
    background-color: var(--colore-principale);
    width: 50%;
    margin: 0 auto;
    border-radius: 15px;

}

/* barre di ricerca */
#ricerca {
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
}

/* Stile Carosello */
/* .carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
    max-width: 600px;
    margin: 0 auto;
    padding: 10px;

} */

/* .carousel-item {
    display: grid;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    opacity: 0;
    position: absolute;
    width: 100%;
    transition: opacity 1s ease;
    font-size: 1.2rem;
    gap: 8px;

} */

.immagine-sfondo {
    background-image: url(src/sfondo3.jpg);
    background-size: cover;
    padding-top: 2rem;
    padding-bottom: 2rem;
    width: 100%;
}

/* .utente-reg {
    padding: 20px;
    border: 2px inset black;
    background-color: #4d5057;
    color: white;
    width: 25%;
    border-radius: 100px;
    line-height: 75px;
} */

/* .carousel-item p {
    position: relative;
    height: 300px;
    padding: 10px;
    text-align: justify;
    border-radius: 15px;
    overflow: hidden;
} */




/* .carousel-item.active {
    opacity: 1;
    position: relative;
} */

/* Sponsor Section */
#sponsor-section {
    margin: 40px 0;
    background-color: #ececec;
    padding: 20px;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    gap: 10px;
}

#sponsor-section div {
    border: 2px dashed darkgray;
    padding: 20px;
    border-radius: 7px;
}


footer {
    background-color: #3A3D42;
    color: white;
    text-align: center;
    padding: 10px;
    margin-top: 20px;
    width: 98%;
}

#legal-info a {
    color: #FFD700;
    text-decoration: none;
}

#campo {
    box-shadow: 0 0 10px black;
    border-radius: 30px;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    .carousel-item {
        font-size: 14px;
    }

    .commento-su-giocatore p {
        font-size: 1.5rem;
    }

    #campo {
        width: 90vw;
    }

    #latest-comments {
        background-color: #edecec;

    }

}

label {
    font-size: 18px;
}



input[type="text"] {
    padding: 15px;
    font-size: 20px;
    border-radius: 15px;
}

input[type="submit"] {
    padding: 15px;
    font-size: 18px;
    border-radius: 15px;
    border: 0;
    box-shadow: 2px 2px 5px var(--colore-principale);
}

/* STATISTICHE CONTAINER */
#statistiche-container {
    display: grid;
    grid-template-columns: repeat(3, 0.5fr);
    grid-template-rows: 360px;
    place-content: center;
    gap: 30px;
    width: 70%;
    margin: 0 auto;
}

#classifica {
    display: flex;
    justify-content: center;
    /* display: grid;
    grid-template-columns: 200px;
    grid-template-rows: 360px;
    place-content: center;
    gap: 30px;
    width: 70%;
    margin: 0 auto; */
}

#classifica-item {
    flex-basis: 300px;

    /* display: grid;
    grid-template-columns: 200px;
    grid-template-rows: 360px;
    place-content: center;
    gap: 30px;
    width: 70%;
    margin: 0 auto; */
}

.grid-item {
    background-color: white;
    color: var(--colore-principale);
    border-radius: 20px;
    box-shadow: 2px 3px 10px var(--colore-principale);
}

.grid-item>h3 {
    margin-top: 1rem;
    text-align: center;
    font-family: "Bruno Ace SC", sans-serif;

}

h2 {
    text-align: center;
    font-family: "Bruno Ace SC", sans-serif;
    color: var(--colore-principale);
    margin-bottom: 1rem;
}



/* CARD COMMENTO */
/* .utente-reg {
    margin: 20px auto;
    width: 120px;
    height: 120px;
}

.carousel-item {
    background-color: #dcdcdc;
    padding-top: 20px;
    padding-bottom: 40px;
    padding-left: 25px;
    padding-right: 25px;
} */

/* grafica statistiche */
.statistica-grafica {
    width: 50px;
    height: 50px;
    padding-top: 10px;
    padding-left: 8px;
    margin: 0 auto;
    border: 1px solid var(--colore-principale);
    border-radius: 50%;
    margin-top: 0.8rem;

}

.animazione-barra1 {
    width: 8px;
    height: 10px;
    background-color: #cfb41a;
    animation-name: animabarra;
    animation-duration: 5s;
    animation-iteration-count: infinite;
    border-radius: 3px;
}

.animazione-barra2 {
    width: 8px;
    height: 10px;
    animation-name: animabarra;
    animation-duration: 5s;
    background-color: #05aca1;
    animation-iteration-count: infinite;
    animation-delay: .8s;
    border-radius: 3px;
}

.animazione-barra3 {
    width: 8px;
    height: 10px;
    animation-name: animabarra;
    animation-duration: 5s;
    background-color: rgb(194, 72, 72);
    animation-iteration-count: infinite;
    animation-delay: 1.2s;
    border-radius: 3px;
}

@keyframes animabarra {
    50% {
        width: 88%;
    }
}

.corpo-statistica {
    width: 85%;
    margin: 0 auto;
    color: var(--colore-principale);
    margin-top: 1rem;
    font-size: 1.1rem;
    text-align: center;
}

hr {

    background-color: var(--colore-principale);
    margin: 10px auto;
    width: 70%;
    height: 2px;
}

/* segno più (+) sotto ogni statistica */
.altro {
    width: 40px;
    height: 40px;
    display: grid;
    place-content: center;
    font-weight: bold;
    background-color: var(--colore-principale);
    color: white;
    margin: 0 auto;
    border-radius: 50%;
}

.altro:hover {
    background-color: #143a60;
}

/* display: flex;
    justify-content: space-evenly; */
#commenti-container {
    border-radius: 10px;
    box-shadow: 1px 2px 10px var(--colore-principale);
    margin: 0 auto;
    width: 90%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
}

#sfondo-sinistra {
    background-image: url(src/sfondo-sinistra.png);
    height: 470px;
    background-size: contain;
    background-position: left;
    background-repeat: no-repeat;
    animation: colorTransition 10s 1;
    position: relative;
    border-radius: 10px;
}

#sfondo-destra {
    background-image: url(src/sfondo-destra.png);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: right;
    filter: opacity(0.9);
    position: relative;
}

@keyframes colorTransition {
    0% {
        filter: grayscale(100%);
    }

    100% {
        filter: grayscale(0%);
    }

}


/* scintilla */
#scintilla {
    position: absolute;
    width: 5px;
    height: 5px;
    background-color: gold;
    border-radius: 50%;
    box-shadow: 0 0 10px gold;
    animation: moveSpark 10s infinite ease-in-out;
}

#scintilla2 {
    position: absolute;
    width: 5px;
    height: 5px;
    background-color: gold;
    border-radius: 50%;
    box-shadow: 0 0 10px gold;
    animation: moveSpark2 15s infinite ease-in-out;
}

#scintilla3 {
    position: absolute;
    width: 5px;
    height: 5px;
    background-color: gold;
    border-radius: 50%;
    box-shadow: 0 0 10px gold;
    animation: moveSpark3 20s infinite ease-in-out;
}

#scintilla4 {
    position: absolute;
    width: 5px;
    height: 5px;
    background-color: gold;
    border-radius: 50%;
    box-shadow: 0 0 10px gold;
    animation: moveSpark4 20s infinite ease-in-out;
}

@keyframes moveSpark {
    0% {
        top: 10%;
        left: 10%;
        opacity: 1;
    }

    20% {
        top: 30%;
        left: 30%;
        opacity: 0.8;
    }

    40% {
        top: 45%;
        left: 30%;
        opacity: 0.8;
    }

    60% {
        top: 45%;
        left: 25%;
        opacity: 0.6;
    }

    80% {
        top: 55%;
        left: 20%;
        opacity: 0.6;
    }

    100% {
        top: 70%;
        left: 10%;
        opacity: 0.4;
    }
}

@keyframes moveSpark2 {

    0% {
        top: 70%;
        left: 10%;
        opacity: 0.4;
    }

    20% {
        top: 55%;
        left: 20%;
        opacity: 0.6;
    }

    40% {
        top: 45%;
        left: 25%;
        opacity: 0.6;
    }

    60% {
        top: 45%;
        left: 30%;
        opacity: 0.8;
    }

    80% {
        top: 30%;
        left: 30%;
        opacity: 0.8;
    }

    100% {
        top: 10%;
        left: 10%;
        opacity: 1;
    }
}

@keyframes moveSpark3 {

    0% {
        top: 25%;
        left: 25%;
        opacity: 1;
    }

    20% {
        top: 55%;
        left: 20%;
        opacity: 1;
    }

    40% {
        top: 65%;
        left: 15%;
        opacity: 0.6;
    }

    60% {
        top: 75%;
        left: 10%;
        opacity: 0.8;
    }

    80% {
        top: 90%;
        left: 20%;
        opacity: 0.8;
    }

    100% {
        top: 20%;
        left: 30%;
        opacity: 1;
    }
}

@keyframes moveSpark4 {


    0% {
        top: 20%;
        left: 30%;
        opacity: 1;
    }

    20% {
        top: 90%;
        left: 20%;
        opacity: 0.8;
    }

    40% {
        top: 75%;
        left: 10%;
        opacity: 0.8;
    }

    60% {
        top: 65%;
        left: 15%;
        opacity: 0.6;
    }

    80% {
        top: 55%;
        left: 20%;
        opacity: 1;
    }

    100% {
        top: 25%;
        left: 25%;
        opacity: 1;
    }
}

#pallone-animato {
    position: absolute;
    top: 37px;
    left: 265px;
    animation-name: ruotapallone;
    animation-duration: 3s;
    animation-iteration-count: infinite;
    animation-timing-function: linear;

}

@keyframes ruotapallone {
    100% {
        transform: rotate(360deg);
    }
}


#scintilla5,
#scintilla6,
#scintilla7,
#scintilla8 {
    background-color: gold;
    width: 10px;
    height: 10px;
    position: absolute;
    animation-name: elettric;
    animation-duration: 1.5s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    border-radius: 50%;
    filter: blur(2px);
}

#scintilla5 {
    top: 5%;
    left: 220px;
}

#scintilla6 {
    top: 10%;
    left: 240px;
}

#scintilla7 {
    top: 3%;
    left: 260px;
}

#scintilla8 {
    top: 8%;
    left: 280px;
}

@keyframes elettric {
    50% {
        top: 23%;
        opacity: 0;
    }

    70% {
        top: 75%;
        opacity: 0;
    }

    100% {
        top: 98%;
        opacity: 1;
    }
}

#carosello-commenti {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: auto;
    width: 100%;
    height: 470px;
}

.commento {
    position: absolute;
    opacity: 0;
    top: 0;
    transition: opacity 1s ease-in-out;
    width: 95%;
    text-align: center;
    background: rgba(255, 255, 255, 0.8);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.3);
    font-size: 1.1rem;
    line-height: 1.3;
    height: auto;
}

.commento.attivo {
    opacity: 1;
}

/* slide  */
#slide-container {
    width: 512px;
    height: 512px;
    border: 3px solid black;
    overflow: hidden;
    position: relative;
}

#slide-items {
    width: 200%;
    display: flex;
    animation: sliding 10s linear 2s infinite;
}

@keyframes sliding {
    10% {
        transform: translate(0%);
    }

    50% {
        transform: translate(-51%);
    }

    /* pausa di un secondo */
    60% {
        transform: translate(-51%);
    }

}