/* Definições do fundo de estrelas */
body {
    margin: 0;
    overflow: hidden;
    background: black;
    color: #ffe81f;
    font-family: 'MinhaFonte', sans-serif;
    perspective: 800px;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    position: relative;
}

/* Container para as estrelas (agora estático) */
.stars {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://www.transparenttextures.com/patterns/stardust.png');
    background-size: cover;
    z-index: -1;
}

/* Definindo a fonte personalizada */
@font-face {
    font-family: 'MinhaFonte';
    src: url('star_jedi/starjedi/Starjedi.ttf') format('truetype');
}

.crawl-container {
    width: 80%;
    height: 100%;
    transform-origin: 50% 100%;
    transform: rotateX(35deg);
    opacity: 0;
    /* Inicialmente invisível */
}

.crawl {
    display: flex;
    flex-direction: column;
    gap: 2em;
    text-align: center;
    position: relative;
    /* animation: moveCrawl 75s linear; */
    /* Remover o "infinite" para não repetir */
}

@keyframes moveCrawl {
    0% {
        transform: translateY(100vh);
    }

    50% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-200vh);
    }
}

/* Título */
.title {
    font-size: 80px;
    font-weight: bold;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
    opacity: 1;
}

/* Animação das linhas de texto */
.crawl p {
    margin: 0;
    opacity: 1;
    font-size: 40px;
    animation: fadeLine 120s linear;
}

@keyframes fadeLine {
    0% {
        opacity: 1;
        transform: translateY(10px);
    }

    10% {
        opacity: 1;
        transform: translateY(0);
    }

    70% {
        opacity: 1;
        transform: translateY(0);
    }

    100% {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* Controle do delay para cada linha */
.crawl p:nth-child(1) {
    animation-delay: 5s;
}

.crawl p:nth-child(2) {
    animation-delay: 5s;
}

.crawl p:nth-child(3) {
    animation-delay: 5s;
}

.crawl p:nth-child(4) {
    animation-delay: 5s;
}

/* Botão "Ver Presente" */
.btn-presente {
    display: none;
    /* Inicialmente escondido */
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #ffe81f;
    border: none;
    padding: 20px 40px;
    font-size: 20px;
    font-weight: bold;
    color: black;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'MinhaFonte', sans-serif;
    text-decoration: none;
}

.btn-presente:hover {
    background-color: #f5d100;
}

.btn-start {
    background-color: #f5d100;
    border-radius: 10px;
    width: 100px;
    height: 50px;
    color: black;
    cursor: pointer;
    border: none;
    font-size: 18px;
    font-family: 'MinhaFonte', sans-serif;
    position: fixed;
    top: 50%;
    left: 45%;
    overflow: hidden;
}

.btn-start:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transform: translateY(-5px);
    transition: all 0.6s ease;
    background-color: #f5d100;
}

/* Media Queries para dispositivos móveis */
@media (max-width: 768px) {
    .title {
        font-size: 40px;
    }

    .crawl p {
        font-size: 20px;
    }

    .btn-presente {
        padding: 10px 10px;
        font-size: 16px;
    }

    .btn-start {
        width: 80px;
        height: 40px;
        font-size: 16px;
    }
}