/* Initial hidden state for each text element */
.about-content h2,
.about-content .about-text,
.about-content .about-highlight {
    opacity: 0;
    transform: translateX(-70px);

    transition:
        opacity 0.8s ease,
        transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Revealed state */
.about-content h2.slide-in,
.about-content .about-text.slide-in,
.about-content .about-highlight.slide-in {
    opacity: 1;
    transform: translateX(0);
}




body {
    background:
        radial-gradient(
            circle at 15% 20%,
            rgba(230, 57, 70, 0.12),
            transparent 30%
        ),
        radial-gradient(
            circle at 85% 70%,
            rgba(255, 255, 255, 0.04),
            transparent 30%
        ),
        #0b0b0d;

    color: #f5f5f5;

    font-family: Arial, Helvetica, sans-serif;
    text-align: center;
}


button {
    padding: 10px 20px;
    font-size: 18px;
}

footer {
    background-color: #111114;
    color: #cacaca;
}

/* ==========================================
   HERO
========================================== */

.hero {
    position: relative;

    width: 100%;
    height: 100vh;
    min-height: 600px;

    overflow: hidden;

    background: #050505;
}


/* ==========================================
   HERO IMAGE
========================================== */

.hero > img {
    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 100%;

    object-fit: cover;

    z-index: 1;

    transform: scale(1.08);

    transition: transform 0.1s linear;
}


/* ==========================================
   DARK OVERLAY
========================================== */

.hero::before {
    content: "";

    position: absolute;

    inset: 0;

    z-index: 2;

    pointer-events: none;

    background:
        linear-gradient(
            90deg,
            rgba(0, 0, 0, 0.75),
            rgba(0, 0, 0, 0.15),
            rgba(0, 0, 0, 0.55)
        );

}


/* ==========================================
   BOTTOM DARK GRADIENT
========================================== */

.hero::after {
    content: "";

    position: absolute;

    left: 0;
    right: 0;
    bottom: 0;

    height: 50%;

    z-index: 3;

    pointer-events: none;

    background:
        linear-gradient(
            to top,
            rgba(0, 0, 0, 0.85),
            transparent
        );
}


/* ==========================================
   SPEED EFFECT CONTAINER
========================================== */

.speed-effects {

    position: absolute;

    inset: 0;

    z-index: 5;

    pointer-events: none;

    overflow: hidden;

}


/* ==========================================
   SPEED LINES
========================================== */

.speed-line {

    position: absolute;

    right: -400px;

    height: 2px;

    background:
        linear-gradient(
            90deg,
            transparent,
            rgba(255,255,255,0.8),
            #ff2020
        );

    box-shadow:
        0 0 6px rgba(255,255,255,0.7),
        0 0 12px rgba(255,0,0,0.5);

    transform:
        translateX(0);

    animation:
        speedLineMove
        linear
        infinite;

}


@keyframes speedLineMove {

    from {

        transform:
            translateX(0);

    }

    to {

        transform:
            translateX(-140vw);

    }

}





/* ==========================================
   TITLE
========================================== */

.hero h1 {

    position: absolute;

    left: 7%;
    bottom: 15%;

    z-index: 10;

    margin: 0;

    color: white;

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    font-size:
        clamp(60px, 10vw, 150px);

    font-weight: 900;

    line-height: 0.85;

    letter-spacing: -5px;

    text-transform: uppercase;

    text-shadow:
        0 5px 30px rgba(0,0,0,0.8);

    animation:
        titleEnter
        1.2s
        cubic-bezier(.16,1,.3,1)
        forwards;
}


/* ==========================================
   RED LINE UNDER TITLE
========================================== */

.hero h1::after {

    content: "";

    display: block;

    width: 120px;
    height: 5px;

    margin-top: 25px;

    background: #ff2020;

    box-shadow:
        0 0 10px #ff2020,
        0 0 30px rgba(255,0,0,0.7);

    animation:
        lineEnter
        1s
        0.5s
        ease-out
        both;
}


/* ==========================================
   TITLE ANIMATION
========================================== */

@keyframes titleEnter {

    from {
        opacity: 0;

        transform:
            translateY(80px);
    }

    to {
        opacity: 1;

        transform:
            translateY(0);
    }

}


@keyframes lineEnter {

    from {
        width: 0;
        opacity: 0;
    }

    to {
        width: 120px;
        opacity: 1;
    }

}


/* ==========================================
   RACING LIGHT
========================================== */

.racing-light {

    position: absolute;

    top: -50%;

    left: -40%;

    width: 25%;
    height: 200%;

    z-index: 5;

    pointer-events: none;

    background:
        linear-gradient(
            90deg,
            transparent 0%,
            rgba(255, 0, 0, 0.05) 20%,
            rgba(255, 30, 30, 0.8) 50%,
            rgba(255, 0, 0, 0.05) 80%,
            transparent 100%
        );

    filter: blur(12px);

    transform:
        rotate(20deg)
        translateX(-200%);

    animation:
        racingLightMove
        4s
        ease-in-out
        infinite;

}


/* ==========================================
   RACING LIGHT ANIMATION
========================================== */

@keyframes racingLightMove {

    0% {

        transform:
            rotate(20deg)
            translateX(-200%);

        opacity: 0;

    }

    15% {
        opacity: 1;
    }

    50% {

        transform:
            rotate(20deg)
            translateX(700%);

        opacity: 0.8;

    }

    65% {
        opacity: 0;
    }

    100% {

        transform:
            rotate(20deg)
            translateX(700%);

        opacity: 0;

    }

}


/* ==========================================
   PARTICLE CONTAINER
========================================== */

.racing-particles {

    position: absolute;

    inset: 0;

    z-index: 6;

    pointer-events: none;

    overflow: hidden;

}


/* ==========================================
   PARTICLES
========================================== */

.particle {

    position: absolute;

    width: 3px;
    height: 3px;

    border-radius: 50%;

    background: white;

    box-shadow:
        0 0 5px white,
        0 0 12px red,
        0 0 20px red;

    opacity: 0;

    animation:
        particleMove
        linear
        infinite;

}


/* ==========================================
   PARTICLE MOVEMENT
========================================== */

@keyframes particleMove {

    0% {

        opacity: 0;

        transform:
            translate(
                100px,
                0
            )
            scale(0.5);

    }

    20% {
        opacity: 1;
    }

    80% {
        opacity: 0.8;
    }

    100% {

        opacity: 0;

        transform:
            translate(
                -500px,
                -40px
            )
            scale(1.8);

    }

}


/* ==========================================
   MOBILE
========================================== */

@media (max-width: 700px) {

    .hero {
        min-height: 550px;
    }

    .hero h1 {

        left: 7%;
        bottom: 12%;

        font-size:
            clamp(50px, 15vw, 90px);

        letter-spacing: -3px;

    }

    .hero h1::after {

        width: 80px;
        height: 4px;

        margin-top: 18px;

    }

}




.quote-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    box-sizing: border-box;
}

.quote {
    max-width: 800px;
    font-size: 3.5rem;
    line-height: 1.4;
    color: #b71c1c;
    margin: 0;
    font-family: "Playfair Display", serif;
    font-weight: 800;
    font-style: normal;

    /* Visible by default */
    clip-path: inset(0 0);

    transition: clip-path 1.2s ease;
}

.author {
    margin-top: 20px;
    font-size: 1.2rem;
    color: #777;

    /* Visible by default */
    clip-path: inset(0 0);

    transition: clip-path 1.2s ease;
    transition-delay: 0.2s;
}

/* Applied only when JavaScript is running */
.quote-container.animate-on-scroll .quote,
.quote-container.animate-on-scroll .author {
    clip-path: inset(0 50%);
}

.quote-container.animate-on-scroll.revealed .quote,
.quote-container.animate-on-scroll.revealed .author {
    clip-path: inset(0 0);
}

@media (max-width: 700px) {
    .quote {
        font-size: 2.2rem;
    }
}




.about-content {
    width: min(900px, 90%);
    margin: 0 auto;
    padding: 80px 0;
    text-align: left;
}

/* Main heading */
.about-content h2 {
    margin: 0 0 35px;

    font-size: clamp(3rem, 7vw, 6rem);
    line-height: 0.95;
    font-weight: 900;
    letter-spacing: -3px;
    text-transform: uppercase;

    color: #e1e1e1;
}

/* Main paragraph */
.about-text {
    max-width: 750px;
    margin: 0;

    font-size: 1.2rem;
    line-height: 1.8;
    color: #636363;
}

/* Final statement */
.about-highlight {
    max-width: 700px;
    margin-top: 35px;

    font-size: 1.5rem;
    line-height: 1.5;
    font-weight: 600;

    color: #6c6c6c;
}

.about-highlight strong {
    color: #e63946;
    font-weight: 800;
}



    /* Link to recent video */

.about-race {
    height: 70vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding-left: 20px;
    padding-right: 20px;
}

.about-race img {
    width: 30vw;
    max-width: 600px;
    min-width: 280px;
    border-radius: 12px;
    display: block;

    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);

    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-race a:first-child:hover img {
    transform: scale(1.03);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.about-race p {
    margin-top: 25px;
    font-size: 1.2rem;
    color: #cccccc;
}

.about-race p a {
    color: #e63946;
    font-weight: 700;
    text-decoration: none;
    margin-left: 5px;
    transition: color 0.2s ease;
}

.about-race p a:hover {
    color: #b71c1c;
    text-decoration: underline;
}



/* Merch Cards  */

.merch-section {
    height: 100vh;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    text-align: center;

    padding-left: 20px;
    padding-right: 20px;
}

.merch-section img {
    width: 40vw;
    max-width: 700px;
    min-width: 300px;

    transition: transform 0.3s ease;
}

.merch-section img:hover {
    transform: scale(1.03);
}

.merch-section p {

    font-size: 1.5rem;
    font-weight: 600;
    color: #ececec;
    line-height: 1.8;
}

.merch-section a {
    display: inline-block;

    margin-left: 15px;
    padding: 12px 25px;
    line-height: 1.0;

    background-color: #e63946;
    color: white;

    border-radius: 8px;

    text-decoration: none;
    font-size: 1rem;
    font-weight: 700;

    transition: 0.2s ease;
}

.merch-section a:hover {
    background-color: #c92f3b;
    transform: translateY(-2px);
}



/* =========================
   NAVBAR
   ========================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, Helvetica, sans-serif;
}

/* Main navbar */
.navbar {
    width: 100%;
    height: 72px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);

    display: flex;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 10000;
    backdrop-filter: blur(12px);
    /* Hidden initially */
    transform: translateY(-100%);
    transition: transform 0.4s ease;
}

/* Navbar when visible */
.navbar.show {
    transform: translateY(0);
}

/* Container */
.navbar_container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;

    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 8px;
}

/* Navigation links */
.navbar_container a {
    color: #e8e8e8;
    text-decoration: none;

    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0.2px;

    padding: 11px 17px;
    border-radius: 8px;

    transition:
        color 0.25s ease,
        background-color 0.25s ease,
        transform 0.25s ease;
}

/* Hover */
.navbar_container a:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

/* Click */
.navbar_container a:active {
    transform: translateY(0);
}

/* Contact button */
.navbar_container a:last-child {
    margin-left: 8px;

    background-color: #ffffff;
    color: #111114;

    padding: 11px 20px;
    font-weight: 600;
}

/* Contact hover */
.navbar_container a:last-child:hover {
    background-color: #e9e9e9;
    color: #000000;
}


/* =========================
   MOBILE
   ========================= */

@media screen and (max-width: 700px) {
 .navbar {
        height: 72px;
    }

    .navbar_container {
        padding: 0 5px;
        justify-content: flex-start;
        flex-wrap: nowrap;
        gap: 4px;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .navbar_container::-webkit-scrollbar {
        display: none;
    }

    .navbar_container a {
        flex: 0 0 auto;
        white-space: nowrap;
        font-size: 13px;
        padding: 9px 10px;
    }

    .navbar_container a:last-child {
        margin-left: 0;
        flex-shrink: 0;
    }
    
    .about-text {
        font-size: 1.0rem;
    }
    .about-highlight {
        font-size: 1.2rem;
    }
    .merch-section {
        height: 0vh;
    }
}


.sponsor-section {
    position: relative;
    width: 100%;
    height: calc(100vh - 72px);
    display: flex;
    justify-content: center;
    align-items: flex-end;
    overflow: hidden;
}
/* Image at the bottom-centre */
.sponsor-section > img {
    width: 550px;
    max-width: 70%;
    height: auto;

    display: block;


    opacity: 0;
    transition: opacity 0.1s linear;
    will-change: opacity;
}

/* Text directly over the centre of the image */
.highlight-section-texts {
    position: absolute;
    /* Centre the text over the image */
    left: 20%;
    bottom: 50%;
    transform: translate(-50%, 50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    color: white;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.8);
}
.sponsor-section-texts {
    position: absolute;
    /* Centre the text over the image */
    left: 80%;
    bottom: 50%;
    transform: translate(-50%, 50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    color: white;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.8);
}

.sponsor-section-texts a, .highlight-section-texts a {
    display: inline-block;
    margin-left: 15px;
    padding: 12px 25px;
    background-color: #e63946;
    color: white;
    border-radius: 8px;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 700;
    transition: 0.2s ease;
}
.sponsor-section-texts a:hover, .highlight-section-texts a:hover {
    background-color: #c92f3b;
    transform: translateY(-2px);
}
.sponsor-section-texts p, .highlight-section-texts p {
    padding-top: 10px;
    font-size: medium;
}



@media screen and (max-width: 700px) {
    
    .about-text {
        font-size: 1.0rem;
    }
    .about-highlight {
        font-size: 1.2rem;
    }
    .merch-section {
        height: 70vh;
    }
}




/* =========================
   SPONSOR SECTION — MOBILE
   ========================= */

@media (max-width: 700px) {

    .sponsor-section {
        position: relative;
        isolation: isolate;

        width: 100%;
        height: auto;
        min-height: 600px;

        padding: 45px 20px 15px;
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        align-items: center;
        gap: 18px;

        overflow: hidden;
    }

    /* Driver image as a subtle backdrop */
    .sponsor-section > img {
        position: absolute;
        z-index: -1;

        left: 50%;
        bottom: 0;
        transform: translateX(-50%);

        width: 100%;
        max-width: 540px;
        max-height: 90%;
        height: auto;

        object-fit: contain;
        object-position: bottom;

        opacity: 0.35;
        pointer-events: none;
    }

    /* Both text blocks become cards */
    .highlight-section-texts,
    .sponsor-section-texts {
        position: relative;
        inset: auto;
        left: auto;
        bottom: auto;
        transform: none;

        width: 100%;
        max-width: 420px;
        min-width: 0;

        display: flex;
        flex-direction: column;
        align-items: flex-start;
        text-align: left;

        padding: 22px 20px;
        border: 1px solid rgba(255, 255, 255, 0.09);
        border-left: 3px solid #e63946;
        border-radius: 12px;

        background: rgba(15, 15, 18, 0.88);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);

        text-shadow: none;
        z-index: 2;
    }

    /* Link buttons */
    .highlight-section-texts a,
    .sponsor-section-texts a {
        display: inline-block;

        max-width: 100%;
        margin: 0;
        padding: 11px 15px;

        background: #e63946;
        color: #fff;

        border-radius: 7px;
        font-size: 0.95rem;
        line-height: 1.4;
        text-align: center;
        text-decoration: none;
    }

    /* Supporting text */
    .highlight-section-texts p,
    .sponsor-section-texts p {
        padding-top: 12px;
        margin: 0;

        color: #c7c7cc;
        font-size: 0.95rem;
        line-height: 1.6;
    }

    .highlight-section-texts a:hover,
    .sponsor-section-texts a:hover {
        background: #c92f3b;
    }
}

/* Smaller phones */
@media (max-width: 380px) {
    .sponsor-section {
        padding: 30px 14px;
        gap: 14px;
        min-height: 540px;
    }

    .highlight-section-texts,
    .sponsor-section-texts {
        padding: 18px 15px;
    }

    .highlight-section-texts a,
    .sponsor-section-texts a {
        font-size: 0.9rem;
    }
}