﻿/* ----- UTILITIES ----- */

h2::before {
    height: 24px;
}

.stadio-caption::before {
    height: 15px;
}

h2::before, .stadio-caption::before {
    content: '';
    display: inline-block;
    width: 3px;
    background: linear-gradient(180deg, rgba(197, 175, 108, 0.7) 15%, rgba(255, 255, 255, 0) 100%);
    margin-right: 10px;
}

hr {
    height: 1px;
    width: 100%;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(197, 175, 108, 0.3) 50%, rgba(255, 255, 255, 0) 100%) !important;
}

    hr.drawer {
        width: 80%;
        background: linear-gradient(90deg, rgba(197, 175, 108, 0.3) 0%, rgba(255, 255, 255, 0) 100%) !important;
    }

/*.scrolling-hidden {
    overflow-x: scroll;
    -ms-overflow-style: none;*/ /* Internet Explorer 10+ */
/*scrollbar-width: none;*/ /* Firefox, Safari 18.2+, Chromium 121+ */
/*}

    .scrolling-hidden::-webkit-scrollbar {
        display: none;*/ /* Older Safari and Chromium */
/*}

.scrolling-track {
    width: max-content;
}*/


.scrolling-hidden {
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

    .scrolling-hidden::-webkit-scrollbar {
        display: none;
    }

.scrolling-track {
    display: flex;
    flex-wrap: nowrap;
    gap: 24px;
    padding: 8px 8px 16px 8px; /* un filo di respiro */
}


.campione-card {
    flex: 0 0 85%;
    max-width: 85%;
}

/* tablet: 3 */
@media (min-width: 960px) {
    .campione-card {
        flex-basis: calc((100% - 24px * 2) / 3);
        max-width: calc((100% - 24px * 2) / 3);
    }
}

/* desktop: 4 ma più larghe => scroll presente */
@media (min-width: 1280px) {

    .scrolling-hidden {
        scrollbar-width: thin; /* Firefox */
    }

        .scrolling-hidden::-webkit-scrollbar {
            display: block;
            height: 8px;
        }

        .scrolling-hidden::-webkit-scrollbar-track {
            background: rgba(255,255,255,0.08);
            border-radius: 4px;
        }

        .scrolling-hidden::-webkit-scrollbar-thumb {
            background: rgba(255,255,255,0.35);
            border-radius: 4px;
        }

            .scrolling-hidden::-webkit-scrollbar-thumb:hover {
                background: rgba(255,255,255,0.55);
            }

        .scrolling-hidden::after {
            content: "";
            position: sticky;
            right: 0;
            width: 40px;
            pointer-events: none;
            background: linear-gradient(to right, transparent, rgba(0,0,0,0.8));
        }

    .campione-card {
        flex-basis: 350px;
        max-width: 350px;
        max-height: 450px;
    }
}




/* ----- HOME ----- */
.home-cta span[class^='mud-button-icon-']{
    transition: .2s transform ease-in-out;
}
.home-cta:hover span[class^='mud-button-icon-'] {
    transform: rotate(90deg)
}

.evento-card {
    border-radius: 20px;
    width: 80vw;
    background-color: #0D0D0D;
    height: 100%;
    min-height: 455px;
    display: flex;
    flex-direction: column;
    position: relative;
}

    .evento-card.disabled {
        color: #FAFAF9a5;
    }

.evento-card-img, .timeline-image, video.home, .stadio-img {
    border-radius: 16px;
}

.evento-card-img {
    margin: 16px;
    position: relative;
}

.card-chip {
    position: absolute;
    border-radius: 8px !important;
    padding: 10px;
    top: 5%;
    right: 5%;
    backdrop-filter: blur(12px);
    background: #00000040;
}

video.home {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.timeline-image {
    width: 100%;
    aspect-ratio: 4/3;
    box-shadow: 0px 0px 80px 0px #262626B2 inset;
}

.custom-timeline {
    margin-left: -50px;
}

.custom-timeline-item {
    padding-bottom: 64px !important;
}

.mud-timeline-vertical::before {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) -35%, rgba(197, 175, 108, 0.7) 41%, rgba(255, 255, 255, 0) 160%)
}

#keywords {
    position: relative;
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #0D0D0D 20%, #0D0D0D 80%, transparent);
}

    #keywords p {
        text-transform: uppercase;
        font-weight: 500;
        font-size: 72px;
        text-wrap: nowrap;
    }

    #keywords img {
        margin-bottom: 10px;
    }

.keywords-track {
    animation: scroll-X 10s linear infinite;
    display: flex;
}

.keywords-stack {
    flex-wrap: nowrap;
}

.home-img {
    width: 70vw;
    aspect-ratio: 1/1;
    border-radius: 16px;
    box-shadow: 0px 0px 80px 0px #262626B2 inset;
}

/* ----- PAGINA EVENTO ----- */
.anteprima-evento-container {
    height: 70vh;
}

.anteprima-evento-container, .card-anteprima {
    display: flex;
    justify-content: center;
    flex-direction: column;
    background-size: cover;
    position: relative;
    z-index: 0;
}

    .anteprima-evento-container::before, .card-anteprima::before, .evento-card.disabled .evento-card-img::before {
        content: '';
        position: absolute;
        top: 0;
        width: 100%;
        height: 100%;
        background: #2E2E2E8C;
        z-index: 1;
        inset: 0;
    }


.campione-card {
    width: 80vw;
    height: 60vh;
    border-radius: 12px;
    box-shadow: 0px 0px 24px 0px #262626B2 inset;
    background-size: cover;
    background-position: top;
    display: flex;
    flex-direction: column;
    justify-content: end;
    background-color: #0D0D0D99;
    overflow: hidden;
}

.campione-card-description {
    padding-block: 32px;
    padding-inline: 16px;
    background: #0D0D0D99;
    backdrop-filter: blur(6px);
}

.sponsor {
    width: 200px;
    height: 120px;
}

    .sponsor.main {
        width: 250px;
    }



/* viewport (contenitore) */
.partners-viewport {
    position: relative;
    overflow-x: auto; /* mobile: scroll manuale */
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    /* fade ai bordi come keywords (opzionale) */
    mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

/* track: di base NON anima su mobile */
.partners-track {
    display: flex;
    width: max-content;
    gap: 48px; /* spazio tra copia1 e copia2 */
}

/* evita wrap */
.partners-stack {
    flex-wrap: nowrap;
    width: max-content;
}

/* (opzionale) dimensione card/item */
.partner-item {
    min-width: 180px; /* regola in base ai loghi */
}

/* DESKTOP: auto-scroll + blocca scroll manuale */
@media (min-width: 960px) { /* md di MudBlazor */
    .partners-viewport {
        overflow: hidden; /* desktop: niente scroll manuale */
    }

    .partners-track {
        animation: partners-scroll-x 30s linear infinite;
        will-change: transform;
    }

    .partners-viewport:hover .partners-track {
        animation-play-state: paused;
    }
}

/* Animazione: trasla di metà track (perché hai 2 copie identiche) */
@keyframes partners-scroll-x {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

/* Rispetta riduzione animazioni */
@media (prefers-reduced-motion: reduce) {
    .partners-track {
        animation: none !important;
    }

    .partners-viewport {
        overflow-x: auto;
    }
}


/* ----- GALLERIA, MASONRY ETC. ----- */
.card-anteprima {
    aspect-ratio: 4/5;
    border-radius: 20px;
    width: 100%;
}

    .card-anteprima::before {
        border-radius: 20px;
    }

.masonryRow .mud-grid-item {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.6s ease-in-out, transform 0.6s ease-in-out;
}

    .masonryRow .mud-grid-item.fade-in {
        opacity: 1;
        transform: translateY(0);
    }

.video-title {
    position: absolute;
    bottom: 0;
    width: 100%;
    background: #0D0D0D99;
    backdrop-filter: blur(6px);
    padding-block: 16px;
    padding-inline: 16px;
    display: flex;
    justify-content: center;
}

/* ----- ANIMAZIONI/TRANSIZIONI ----- */
@keyframes scroll-X {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}


/* ------- Desktop version ------- */
/* ?????? questo breakpoint interviene in tutti gli schermi piccoli fino a 960px */
@media (max-width: 959.98px) {

    .dettaglio-evento-img-stadio {
        order: 2;
    }

    .dettaglio-evento-descrizione {
        order: 1;
    }
}


/* ------- Desktop version ------- */
@media (min-width: 960px) {

    h2::before{
        height: 30px;
    }

    .logo-navbar {
        width: 280px;
    }

    .header-claim {
        font-size: 24px;
    }

    .evento-card {
        width: 330px;
    }

        .evento-card h4 {
            font-size: 24px;
        }

    .who-video-grid {
        flex-direction: row-reverse;
        margin-bottom: 42px;
    }


    .custom-timeline {
        margin-left: 0;
    }

    .why-home-grid {
        flex-direction: row-reverse;
    }

    .why-home-grid p{
        font-size: 18px;
    }

    .logo-footer{
        width: 214px;
    }

    .link-group {
         align-items: start !important; 
    }

    .anteprima-evento-container{
        height: 80vh;
    }

    .card-anteprima{
        width: 325px;
    }

    .card-anteprima p {
        font-size: 32px;
        font-weight: 500;
    }

    .cartella-selezionata{
        font-size: 28px;
    }
}
