/**
 * Estilos exclusivos para la sección de Inscripción - sportRCBike
 * Con responsividad adaptada y corregida para dispositivos móviles.
 */

:root {
    --neon-green-bg: #76ff03; 
    --black-text-solid: #000000;
    --font-inscription-heavy: 'Kanit', 'Impact', 'Arial Black', sans-serif;
}

.inscription-section {
    position: relative;
    background-color: var(--neon-green-bg);
    padding: 50px 20px;
    overflow: hidden; 
    width: 100%;
    box-sizing: border-box;
}

.inscription-grunge-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-repeat: no-repeat;
    background-size: cover;
    z-index: 1;
    pointer-events: none;
}

.inscription-container {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: center;
}

/* --- Bloque Izquierdo --- */
.inscription-status {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.status-icon-wrapper {
    width: 70px;
    height: 70px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.status-icon {
    width: 100%; /* Fluido por defecto en móvil */
    height: 100%;
    display: block;
    object-fit: contain;
}

.status-title {
    font-family: var(--font-inscription-heavy);
    font-size: 2.2rem;
    font-weight: 900;
    font-style: italic; 
    color: var(--black-text-solid);
    line-height: 1.05;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: -1px;
}

.status-title span {
    display: block;
}

.status-title .text-main {
    letter-spacing: -0.5px;
}

/* --- TEXTO ABIERTAS CON EFECTO GLITCH DE ALTO IMPACTO --- */
.status-title .text-accent {
    font-size: 2.6rem;
    color: transparent;
    -webkit-text-stroke: 2px var(--black-text-solid);
    text-shadow: 1px 1px 0px rgba(0,0,0,0.1);
    position: relative;
    display: inline-block;
}

/* Pseudo-elementos para duplicar el texto calado y simular distorsión */
.status-title .text-accent::before,
.status-title .text-accent::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

.status-title .text-accent::before {
    -webkit-text-stroke: 2px rgba(0, 0, 0, 0.7);
    left: 2px;
    animation: glitchTop 4s linear infinite;
    clip-path: rect(0 900px 20px 0);
}

.status-title .text-accent::after {
    -webkit-text-stroke: 2px rgba(0, 0, 0, 0.8);
    left: -2px;
    animation: glitchBottom 3s linear infinite;
    clip-path: rect(20px 900px 100px 0);
}

/* --- Centro: Datos e Información --- */
.inscription-core {
    display: flex;
    flex-direction: column;
    gap: 35px;
    width: 100%;
}

.inscription-data-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
    text-align: center;
}

.data-column {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.data-icon {
    height: 40px;
    width: 40px;
    display: block;
    margin-bottom: 12px;
}

.data-title {
    font-family: var(--font-inscription-heavy);
    font-size: 20px; 
    font-weight: 800;
    text-transform: uppercase;
    color: rgba(0, 0, 0, 0.88); 
    margin: 0 0 4px 0;
}

.data-value {
    font-family: var(--font-inscription-heavy);
    font-size: 30px;
    font-weight: 900;
    font-style: italic;
    text-transform: uppercase;
    color: var(--black-text-solid);
    margin: 0;
    letter-spacing: -0.5px;
}

.text-glint {
    position: relative;
    display: inline-block;
}

.vertical-divider {
    display: none;
    width: 2px;
    background-color: var(--black-text-solid);
    height: 139px;
    align-self: center;
    opacity: 0.8;
}

/* Botón Negro Píldora */
.inscription-cta-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
}

/* --- BOTÓN CON EFECTO LÁSER / GLOW --- */
.btn-inscription-black {
    display: inline-block;
    background-color: var(--black-text-solid);
    color: #ffffff;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    text-decoration: none;
    padding: 14px 45px;
    border-radius: 50px; 
    text-transform: uppercase;
    position: relative;
    overflow: hidden; /* Encapsula el destello oblicuo */
    z-index: 1;
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.25s ease;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    text-align: center;
}

/* Elemento del destello láser reflectivo */
.btn-glow-effect::after {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        90deg, 
        rgba(255, 255, 255, 0) 0%, 
        rgba(255, 255, 255, 0.25) 50%, 
        rgba(255, 255, 255, 0) 100%
    );
    transform: skewX(-25deg);
    z-index: 2;
}

.btn-inscription-black:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

/* --- Bloque Derecho: Ciclista --- */
.inscription-image-wrapper {
    display: flex;
    justify-content: center;
    position: relative;
}

.racer-img {
    max-width: 90%;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(5px 15px 15px rgba(0, 0, 0, 0.25));
}

/* Ocultar la foto del ciclista en pantallas muy pequeñas si satura el diseño vertical (Opcional) */
@media (max-width: 576px) {
    .inscription-image-wrapper {
        display: none;
    }
}

/* ==========================================================================
   ESTADOS DE LA ANIMACIÓN EXCLUSIVA (Cargados vía JS)
   ========================================================================== */
.inscription-animate {
    opacity: 0;
    will-change: transform, opacity;
    transition: opacity 0.75s cubic-bezier(0.25, 1, 0.5, 1), 
                transform 0.75s cubic-bezier(0.25, 1, 0.5, 1);
}

.scale-up { transform: scale(0.8); }
.fade-in-scale { transform: scale(0.9) translateY(15px); }
.delay-button { transform: translateY(10px); transition-delay: 0.2s; }
.racer-slide { transform: translateX(80px) cubic-bezier(0.16, 1, 0.3, 1); transition-duration: 0.95s; }

.inscription-active .inscription-animate {
    opacity: 1;
    transform: scale(1) translateY(0) translateX(0);
}

/* DISPARADORES DE ANIMACIONES EN BUCLE */
.inscription-active .btn-glow-effect::after {
    animation: laserScan 3.5s infinite ease-in-out;
}

.inscription-active .text-glint {
    animation: shimmerEffect 4s ease-in-out infinite;
}

/* Keyframes */
@keyframes laserScan {
    0% { left: -150%; }
    30%, 100% { left: 150%; }
}

@keyframes glitchTop {
    0%, 100% { transform: translate(0); }
    19% { transform: translate(0); }
    20% { transform: translate(-2px, 2px); }
    21% { transform: translate(1px, -1px); }
    22% { transform: translate(0); }
    59% { transform: translate(0); }
    60% { transform: translate(1.5px, -1.5px); }
    61% { transform: translate(0); }
}

@keyframes glitchBottom {
    0%, 100% { transform: translate(0); }
    21% { transform: translate(0); }
    22% { transform: translate(1.5px, -1.5px); }
    23% { transform: translate(-1px, 1px); }
    24% { transform: translate(0); }
    79% { transform: translate(0); }
    80% { transform: translate(-2px, 1.5px); }
    81% { transform: translate(0); }
}

@keyframes shimmerEffect {
    0%, 90%, 100% { opacity: 1; transform: translateY(0); }
    95% { opacity: 0.85; transform: scale(0.98); }
}

/* ==========================================================================
   MEDIA QUERY PARA ESCRITORIO (Aquí encapsulamos los desfases fijos del mockup)
   ========================================================================== */
@media (min-width: 992px) {
    .inscription-section {
        padding: 0; 
        height: 280px; 
        display: flex;
        align-items: center;
    }

    .inscription-container {
        grid-template-columns: 1.2fr 2fr 1.1fr; 
        gap: 0;
        width: 100%;
        height: 100%;
    }

    .inscription-status {
        flex-direction: row;
        align-items: center;
        text-align: left;
        gap: 20px;
        padding-left: 10px;
    }

    .status-icon-wrapper {
        margin-bottom: 0;
        width: 65px;
        height: 65px;
    }

    /* Ajustes específicos de posición en Desktop */
    .status-icon {
        width: 158%;
        height: 154%;
        margin-left: -61px;
        margin-top: -44px;
    }

    .status-title {
        font-size: 46px;
        margin-top: -50px;
        margin-left: -48px;
    }
    
    .status-title .text-accent {
        font-size: 52px;
        margin-top: -5px;
    }

    .inscription-core {
        gap: 20px;
        justify-content: center;
        position: relative;
        top: 15px; 
    }

    .inscription-data-grid {
        flex-direction: row;
        justify-content: center;
        gap: 32px;
        margin-right: -83px;
        margin-top: -28px;
    }

    .data-column {
        min-width: 180px;
    }

    .vertical-divider {
        display: block; 
    }

    /* Margen negativo del botón exclusivo en pantallas grandes */
    .btn-inscription-black {
        margin-right: -81px;
    }

    .inscription-image-wrapper {
        position: relative;
        height: 100%;
        align-items: flex-end;
    }

    .racer-img {
        position: absolute;
        bottom: -25px; 
        right: -134px;
        max-width: none;
        height: 325px; 
    }
}