/* Global Settings */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', sans-serif; /* Fonte limpa e moderna */
}

/* Body */
body {
    background-color: #f9f9f9; /* Cor de fundo suave */
    color: #333; /* Texto escuro para boa legibilidade */
    line-height: 1.6;
    -webkit-font-smoothing: antialiased; /* Suaviza as fontes no macOS */
    -moz-osx-font-smoothing: grayscale;  /* Para Firefox em macOS */
    font-smooth: always; /* Melhor visualização de fontes no Webkit */
}

/* Container Principal */
.welcome-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    text-align: center;
    background-color: #fff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1); /* Sombra suave para dar profundidade */
}

/* Títulos */
h1, h2 {
    font-weight: normal;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
}

/* Título Principal */
h1 {
    font-size: 36px;
    line-height: 1.3;
    letter-spacing: -0.5px;
    margin-bottom: 40px; /* Maior espaço entre título e botão */
    font-weight: 400;
}

/* Subtítulo */
h2 {
    font-size: 24px;
    font-weight: 500;
    color: #333;
}

/* Input - Estilo Geral */
input {
    width: 100%;
    max-width: 400px;
    padding: 14px;
    font-size: 16px;
    border-radius: 10px;
    border: 1px solid #ddd;
    margin-bottom: 20px;
    transition: border-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

/* Foco no input */
input:focus {
    border-color: #ae36fc;
    outline: none;
    box-shadow: 0 0 5px rgba(174, 54, 252, 0.4); /* Suaviza o foco */
}

/* Slider de Idade */
input[type="range"] {
    width: 100%;
    max-width: 400px;
    margin-bottom: -18px;
}

/* Exibição do Valor do Slider */
#age-value {
    font-size: 18px;
    color: #333;
    margin-top: -5px; /* Ajusta o espaçamento entre o slider e o número */
    display: inline-block; /* Faz com que o número fique ao lado do slider */
    margin-left: 10px; /* Espaçamento entre o slider e o número */
    vertical-align: middle; /* Garante que o número fique alinhado ao centro do slider */
}

#age-value[contenteditable="true"] {
    outline: none;
    border-bottom: 2px solid #ae36fc; /* Linha inferior para indicar que é editável */
    cursor: text;
    display: inline-block;
    font-size: 18px;
    color: #333;
    margin-top: -5px;
    margin-left: 10px;
    vertical-align: middle;
}

/* Botões */
button {
    background-color: #ae36fc;
    color: white;
    padding: 14px 30px;
    border: none;
    border-radius: 50px; /* Bordas arredondadas para maior elegância */
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.1s ease;
    margin-top: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Hover & Active Effects */
button:hover {
    background-color: #8a28c4;
}

button:active {
    transform: scale(0.98); /* Efeito sutil de clique */
}

/* Animações de Transição entre as Perguntas */
.question {
    display: none;
    opacity: 0;
    transform: translateX(100%);
    transition: transform 0.5s ease-in-out, opacity 0.5s ease-in-out;
}

.question.active {
    display: block;
    opacity: 1;
    transform: translateX(0);
}

/* Responsividade - Mobile First */

@media (max-width: 768px) {
    h1 {
        font-size: 28px;
    }
    h2 {
        font-size: 20px;
    }
    input, button {
        width: 90%;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 22px;
    }
    h2 {
        font-size: 18px;
    }
    input, button {
        width: 90%;
    }
}

/* Design de Transições e Movimentos Suaves */
@keyframes slideIn {
    0% {
        transform: translateX(100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Ajuste para visualização em tablet e mobile */
@media (max-width: 1024px) {
    .welcome-container {
        padding: 10px;
    }
    h1 {
        font-size: 32px;
    }
    h2 {
        font-size: 22px;
    }
}

/* Acessibilidade e Foco nos Botões */
button:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(174, 54, 252, 0.5);
}

input:focus, button:focus {
    transition: box-shadow 0.3s ease;
}

/* Desempenho Máximo */
body {
    will-change: transform, opacity;
    font-smooth: always;
}

/* Garantir que a imagem de fundo (se houver) seja responsiva */
img {
    max-width: 100%;
    height: auto;
    display: block;
}
