* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {                        
    background: linear-gradient(135deg, #8B0000 0%, #DC143C 100%);
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-rojo.jpg');
    color: white;    
    font-style: normal;
    /*font-display: swap;*/
    min-height: 100vh;    

    -webkit-font-smoothing:antialiased;
    -moz-osx-font-smoothing: grayscale;
}

    body.bg-rojo{
        background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-rojo.jpg');
    }
.filters {
    background: rgba(139, 0, 0, 0.9);
    border-bottom: 3px solid #FFD700;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    padding: 20px;
}
    .filter-btn {
        font: 1.6rem/1 "Bebas Neue", sans-serif;
        background: transparent;
        border: none;
        color: white;
        max-width: 185px;
        padding: 12px 25px;
        cursor: pointer;
        text-transform: uppercase;
        letter-spacing: 1px;
        transition: all 0.3s ease;
    }
        .filter-btn:hover,
        .filter-btn.active {
            color: #FFD800;
            transform: translateY(-2px);
        }
        /* Menú desplegable para móvil */
        .mobile-filter-container {
            display: none;
            background: rgba(139, 0, 0, 0.9);
            padding: 20px;
        }

        .mobile-filter-select {
            width: 100%;
            padding: 15px 20px;
            border: 2px solid white;
            border-radius: 25px;
            background: rgba(255, 255, 255, 0.1);
            color: white;
            font-size: 16px;
            font-weight: bold;
            text-transform: uppercase;
            appearance: none;
            cursor: pointer;
            background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
            background-repeat: no-repeat;
            background-position: right 15px center;
            background-size: 20px;
            padding-right: 50px;
            font: 1.6rem / 1 "Bebas Neue", sans-serif;
        }

        .mobile-filter-select:focus {
            outline: none;
            background: rgba(255, 255, 255, 0.2);
        }

        .mobile-filter-select option {
            background: #8B0000;
            color: white;
            padding: 10px;
        }
        .mobile-filter-container {
            display: none;
        }
        
        .filters {
            display: flex;
        }
.search-container {
    margin: 30px auto;
    max-width: 1200px;    
    padding: 0 20px;
    text-align: center;
}
    .search-box {
        background: white;
        border: none;
        border-radius: 50px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.3);        
        font-size: 18px;        
        margin: 0 auto;
        max-width: 600px;        
        padding: 15px 25px;
        width: 100%;   
    }
.goals-grid {
    max-width: 1000px;
    margin: 40px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 25px;
}
    .goals-grid:has(.goal-card:only-child) .goal-card {
        max-width: 400px;
        margin: 0 auto;
    }
    
    .goal-card {
        background: white;
        box-shadow: 0 15px 40px rgba(0,0,0,0.3);
        color: #333;
        cursor: pointer;   
        transition: all 0.3s ease;
        overflow: hidden;
        padding: 10px;
        loading: lazy;
    }
        .goal-card:hover {
            transform: translateY(-10px);
            box-shadow: 0 25px 60px rgba(0,0,0,0.4);
        }
        .ctn-info-gol{
            border: 1px solid #0b558e;
            min-height: 370px;
            text-align: center;
        }
            .goal-number {
                color: #0B558E;
                font: 8rem/1 'Abolition Test Round';
                text-align: center;
                position: relative;
            }
            .goal-info {
                padding: 20px;
            }
                .goal-teams {
                    color: #0b558e;
                    font: 1.6rem/1 'ramagothicmw01-heavyregular';      
                    text-transform: uppercase;              
                }
                .goal-result{
                    font: 1.5rem/1.2 'Abolition Test Round';
                }
                .goal-competition{
                    font: 1rem/1.3 arial;
                    font-weight: 600;
                }
                .goal-date{
                    font: 0.9rem/1.3 arial;
                    font-weight: 500;
                }
        .goal-details {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            font-size: 14px;
            margin-bottom: 15px;
        }
        .goal-detail {
            display: flex;
            flex-direction: column;
        }
        .detail-label {
            font-weight: bold;
            color: #666;
            margin-bottom: 3px;
        }
        .detail-value {
            color: #333;
        }
        .play-btn {
            background: #8B0000;
            color: white;
            border: none;
            margin: 10px auto;
            padding: 12px 25px;
            border-radius: 25px;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
            width: fit-content;
        }

        .play-btn:hover {
            background: #DC143C;
            transform: translateY(-2px);
        }

        .modal {
            display: none;
            position: fixed;
            z-index: 2000;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background: rgba(0,0,0,0.9);
            backdrop-filter: blur(10px);
        }

        .modal-content {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            background: white;
            border-radius: 15px;
            padding: 5px;
            max-width: 800px;
            width: 50dvh;
            max-height: 90%;
            overflow-y: auto;
        }

        .close {
            position: absolute;
            right: 25px;
            top: 13px;
            font-size: 45px;
            font-weight: bold;
            cursor: pointer;
            color: #ffffff;
            z-index: 20;
        }

        .video-container {
            width: 100%;
            height: 85vh;
            background: #000;
            border-radius: 10px;
            position: relative;
            overflow: hidden;
        }

        .video-container iframe {
            width: 100%;
            height: 100%;
            border: none;
            border-radius: 10px;
        }

        .calendar-container {
            display: none;
            max-width: 800px;
            margin: 30px auto;
            border-radius: 15px;
            padding: 30px;
        }
        p.bajada-calendario{
            font: 1.1rem / 1.2 arial;
            text-align: center;
            max-width: 550px;
            margin: 0 auto 20px;
        }

        .calendar-header {
            text-align: center;
            margin-bottom: 0;
            font: 1.5rem / 1.1 'druk_wide_mediumregular';
        }

        .calendar-nav {
            display: flex;
            justify-content: space-between;
            margin-top: -30px;
            align-items: center;
            margin-bottom: 20px;
        }

        .nav-btn {
            background: white;
            color: #8B0000;
            border: none;
            padding: 10px 20px;
            border-radius: 25px;
            cursor: pointer;
            font-weight: bold;
        }

        .back-to-calendar {
            text-align: center;
            margin: 20px 0;
        }

        .back-btn {
            background: rgba(255, 255, 255, 0.2);
            color: white;
            border: 2px solid white;
            padding: 12px 25px;
            border-radius: 25px;
            font-weight: bold;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .back-btn:hover {
            background: white;
            color: #8B0000;
        }

        .calendar-grid {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            gap: 10px;
        }

        .calendar-day {
            font: 1rem / 1.1 'druk_wide_mediumregular';
            aspect-ratio: 1;
            background: rgba(255,255,255,0.2);
            border: 2px solid transparent;
            border-radius: 2px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            pointer-events: none;
            transition: all 0.3s ease;
        }

        .calendar-day:hover,
        .calendar-day.has-goals {
            background: white;
            color: #8B0000;
            pointer-events: inherit;
        }

        .minute-slider-container {
            display: none;
            max-width: 800px;
            margin: 30px auto;
            border-radius: 15px;
            padding: 30px;
            text-align: center;
        }

        .minute-clock {
            position: relative;
            width: 300px;
            height: 300px;
            margin: 20px auto;
            border-radius: 50%;
            background: conic-gradient(from 0deg, #e8dddd 0deg, #f7f4f4 360deg);
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .minute-clock::before {
            content: '';
            position: absolute;
            width: 280px;
            height: 280px;
            border-radius: 50%;
            background: #8B0000;
            z-index: 1;
        }

        .minute-indicator {
            position: absolute;
            width: 20px;
            height: 20px;
            background: white;
            border-radius: 20px;
            z-index: 3;
            transition: all 0.1s ease;
            transform: translate(-50%, -50%);
        }

        .minute-display-clock {
            color: white;
            font: 9rem / 1 'Abolition Test Round';
            position: relative;
            z-index: 10;            
            text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
            margin-top: -50px;
        }

        .clock-numbers {
            position: absolute;
            width: 100%;
            height: 100%;
            border-radius: 50%;
            scale: 1.1;
        }
            #clockNumbers > .clock-number:nth-child(1){
                opacity: 0;
            }

        .clock-number {
            font: 1.4rem/1 'Abolition Test Round';
            position: absolute;
            color: white;
            font-weight: bold;
            transform: translate(-50%, -50%);
        }

        .clock-instruction {
            font: 1.1rem / 1.2 arial;
            color: white;
            align-items: center;
            max-width: 350px;
            margin: 0 auto 40px;
            text-align: center;
        }

        .reload-icon {
            display: block;
            width: 45px;
            height: 45px;
            border: 3px solid white;
            border-radius: 50%;
            border-top: 3px solid transparent;
            position: relative;
            margin: 0 auto 15px;
        }

        .reload-icon::after {
            content: '↻';
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            font-size: 30px;
            color: white;
        }

        .minute-selector {
            position: absolute;
            width: 100%;
            height: 100%;
            border-radius: 50%;
            cursor: pointer;
            z-index: 5;
        }

        .loading {
            text-align: center;
            padding: 50px;
            font-size: 1.2rem;
        }

        .no-results {
            text-align: center;
            padding: 50px;
            font-size: 1.2rem;
            opacity: 0.7;
        }

        .pagination {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 5px;
            padding: 40px 20px;
            margin: 30px auto;
        }

        .pagination::before {
            content: '';
            flex: 1;
            height: 2px;
            background: linear-gradient(to right, transparent, white);
        }

        .pagination::after {
            content: '';
            flex: 1;
            height: 2px;
            background: linear-gradient(to left, transparent, white);
        }

        .page-number {
            align-items: center;
            background: transparent;
            border: none;
            color: rgba(255, 255, 255, 0.5);
            cursor: pointer;
            display: flex;
            font: 1.3rem/1.2 'Abolition Test Round';          
            height: 40px;
            justify-content: center;
            text-decoration: none;
            width: 40px;
           
            transition: all 0.3s ease;    
        }

            .page-number:hover,
            .page-number.active {
                border-bottom: 2px solid #fff;
                color: #fff;
                transform: scale(1.1);
            }

        .page-number.next {
            border: none;
            color: #fff;
            width: auto;
            padding: 0 20px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .page-number.next:hover {
            border-bottom: 2px solid #fff;
            transform: translateX(5px);
        }

        .results-info {
            font: 1rem/1.1 'druk_wide_mediumregular';
            text-align: center;
            margin: 20px 0;
            opacity: 0.9;
        }

        .teams-container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 40px 20px;
    text-align: center;
    border-radius: 15px;
}

.team-logos {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.team-logo {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.team-logo:hover,
.team-logo.active {    
    transform: scale(1.1);
}
    .team-logo.active img{
        filter: grayscale(0);
    }

.team-logo img {
    filter: grayscale(1);
    width: 50px;
}

.current-team-name {
    font: 1.4rem/1.1 'druk_wide_mediumregular';
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}


/* Estilos para los fondos de equipos en el body */
body.team-al-nassr {
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-al-nassr.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

body.team-juventus {
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-juventus.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

body.team-manchester-united {
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-manchester-united.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

body.team-real-madrid {
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-real-madrid.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

body.team-sporting-lisboa {
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-sporting-lisboa.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

body.team-portugal {
    background-image: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/img/bg-portugal.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}


.body-parts-container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0;
    text-align: center;
    border-radius: 15px;
}

.body-part-options {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.body-part-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 20px;
    border-radius: 15px;
    border: 2px solid transparent;
    max-width: 140px;
}

.body-part-option:hover,
.body-part-option.active {
    
    transform: translateY(-5px);
}

.silhouette-container {
    width: 80px;
    height: 120px;
    margin-bottom: 15px;
}

.player-silhouette {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.3));
}

.body-part-label {
    font: .8rem/1.1 'druk_wide_mediumregular';
    color: white;
}

.body-part-option.active .body-part-label {
    background-color: #DC143C;
    padding: 5px 10px;
}

.field-parts-container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0;
    text-align: center;
    border-radius: 15px;
}

.field-part-options {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.field-part-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 20px;
    border-radius: 15px;
    min-width: 120px;
    position: relative;
}

.field-part-option:hover,
.field-part-option.active {    
    transform: translateY(-5px);
}

.field-icon {
    width: 100px;
    height: 60px;
    margin-bottom: 15px;
}

.field-svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.3));
}

.field-part-label {
    background: #fff;
    color: #F00000;
    font: .7rem / 1.1 'druk_wide_mediumregular';    
    margin-top: -15px;
    padding: 5px 10px;
    text-align: center;
}

    .field-part-option.active .field-part-label {
        background-color: #F00000;
        color: #fff;
    }

@media (max-height: 900px) {

    .modal-content{
        width: 50dvh;
    }

}

@media (max-width: 640px){

    body .box-portada video{
        height: 50dvh;
    }
    body .goals-grid{
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    #social #wst{
        display: inline-block;
    }      
    .goal-number{
        font-size: 6rem;
    }
    .ctn-info-gol{
        min-height: 385px;
    }
    .goal-info {
        padding: 20px 10px;
    }
    .modal-content {
        height: 75%;
        width: 45dvh;
    }
    .video-container{
        height: 100%;
    }

    .filters {
        position: relative;
        flex-direction: column;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        padding: 0 20px;
    }
    
    .filters.open {
        max-height: 500px;
        padding: 20px;
    }
    
    body .filters-toggle {
        display: block;
    }
    
    .filter-btn {
        width: 100%;
        margin-bottom: 10px;
        padding: 15px 20px;
        text-align: center;
        border-radius: 8px;
        display: block;
        margin: 0 auto;
    }
    
    .filter-btn:last-child {
        margin-bottom: 0;
    }

}

@media (max-width: 768px) {


    #social #wst{
        display: inline-block;
    }        
    .filters {
        padding: 15px 10px;
    }            
        .filter-btn {
            padding: 10px 15px;
            font-size: 1.3rem;
            max-width: 90%;
        }            
    .goals-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 20px;
    }  

    .mobile-filter-container {
        display: block;
    }
    
    .filters {
        display: none;
    }

    body.team-al-nassr,
    body.team-juventus,
    body.team-manchester-united,
    body.team-real-madrid,
    body.team-sporting-lisboa,
    body.team-portugal {
        background-size: 100%;
    }

    
}

@media (max-width: 820px) {

    .filter-btn{
        padding: 12px 5px;
    }

}
    
@font-face {
    font-family: 'abolition_testsoft_oblique';
    src: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/abolitiontest-softoblique-webfont.woff2') format('woff2'),
         url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/abolitiontest-softoblique-webfont.woff') format('woff');  
}
@font-face {
    font-family: 'Abolition Test Round';
    src: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/Abolition-RoundOblique.woff2') format('woff2'),
        url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/Abolition-RoundOblique.woff') format('woff');  
}
@font-face {
    font-family: 'Quinn';
    src: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/Quinn-Bold.woff2') format('woff2'),
        url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/Quinn-Bold.woff') format('woff');
}
@font-face {
    font-family: 'druk_wide_mediumregular';
    src: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/fonnts.com-druk_wide_medium-webfont.woff2') format('woff2'),
         url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/fonnts.com-druk_wide_medium-webfont.woff') format('woff');
}
@font-face {
    font-family: 'ramagothicmw01-heavyregular';
    src: url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/rama_gothic_m_w01_heavy-webfont.woff2') format('woff2'),
         url('https://nuevasnarrativasec.github.io/cristiano-ronaldo-goles/fonts/rama_gothic_m_w01_heavy-webfont.woff') format('woff');
}

.box-portada {
    background-color: #000;
    position: relative;
    overflow: hidden;
}
    .box-portada video {
        height: 100dvh;
        object-fit: cover;
        object-position: top;
        width: 100%;
    }
    #social{
        position: absolute;
        right: 10px;
        top: 10px;
        z-index: 600;
        margin: 0;
    }
        #social ul{
            display: inline-block;
            margin: 0 auto;
            padding: 0;
            vertical-align: middle;
        }
            #social ul li{
                cursor: pointer;
                display: inline-block;
                margin: 0 3px;
                vertical-align: middle;
            }
                #social ul li a{
                    height: 36px;
                    width: 36px;
                }
                    #fb{
                        background: url(https://d1ts5g4ys243sh.cloudfront.net/proyectos_especiales_prod/especiales-multimedia/personas-desaparecidas/img/fb-icon.png?v2) no-repeat 0 0;
                        background-size: 100% !important;
                        border: none;
                        display: inline-block;
                        height: 36px;
                        text-indent: -9999px;
                        width: 36px;
                    }
                    #wst{                
                        background: url(https://d1ts5g4ys243sh.cloudfront.net/proyectos_especiales_prod/especiales-multimedia/personas-desaparecidas/img/wsp-icon.png?v2) no-repeat 0 0 !important;
                        background-size: 100% !important;
                        border: none;
                        display: none;
                        height: 36px;
                        text-indent: -9999px;
                        width: 36px;
                    }
                    #tw{            
                        background: url(https://d1ts5g4ys243sh.cloudfront.net/proyectos_especiales_prod/especiales-multimedia/personas-desaparecidas/img/tw-icon.png?v2) no-repeat 0 0 !important;
                        background-size: 100% !important;
                        border: none;
                        display: inline-block;
                        height: 36px;
                        text-indent: -9999px;
                        width: 36px;
                    } 

.filters {
    background: #7d2929;
    background: linear-gradient(180deg, rgba(125, 41, 41, 1) 0%, rgba(232, 14, 14, 1) 20%, rgba(65, 0, 0, 1) 80%, rgba(65, 0, 0, 1) 100%);
    border-bottom: none;
}
#goalModalInfo{
    display: none;
}
.box-footer{
    padding: 50px 0;
}
    .box-footer img{
        display: block;
        margin: 10px auto 30px;
        max-width: 80px;
    }
    .box-footer ul{
        padding: 0;
        text-align: center;
    }
        .box-footer ul li{
            margin: 0 auto 10px;
        }
            .box-footer ul li p{
                font: .9rem/1.2 arial;
                margin: 0;
            }
                .box-footer ul li span{
                    display: block;
                    font-weight: bold;
                    margin-bottom: 5px;
                }
