@charset "UTF-8";

@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');

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

:root{
    --background: linear-gradient(90deg, #E6F0FC 0%, #C7C5EE 50%, #8067A9 100%);
    --font-color: black;
    --border: rgba(0, 0, 0, 0.5);
    --background-link: rgba(255, 255, 255, 0.1);
    --background-hover:  #C7C5EE;
    --switch-bg-url: url(img/sun.svg);
    --bg-color: rgba(0, 0, 0, 0.1);
}

.dark{
    --background: linear-gradient(90deg, #5E2F73 0%, #370139 50%, #03010C 100%);
    --font-color: white;
    --border: rgba(255, 255, 255, 0.5);
    --background-link: rgba(255, 255, 255, 0.1);
    --background-hover: #5d2f7338;
    --switch-bg-url: url(img/moon.svg);
    --bg-color: rgba(255, 255, 255, 0.1);
}

body {
    font-family: 'Inter', sans-serif;
    background-image: var(--background);
}

main{
    max-width: 360px;
    width: 90%;
    margin: 56px auto 0px;
}

#perfil {
    padding: 24px;
    text-align: center;
}

#perfil img{
    width: 112px;
    height: 112px;
    border-radius: 50%;
}

#perfil p {
    font-weight: 500;
    color: var(--font-color);
    line-height: 24px;
    margin-top: 8px;
}

/*switch*/

#switch{
    margin: 8px auto 32px;
    position: relative;
    width: 64px;
}

#switch button{
    width: 32px;
    height: 32px;
    background: white var(--switch-bg-url) no-repeat center;
    background-size: 70%;
    border: none;
    border-radius: 50%;

    position: absolute;
    left: 0;
    top: 50%;
    z-index: 1;
    transform: translateY(-50%);

    animation: slide-out 0.3s;
}

#switch button:hover{
    outline: 8px solid var(--bg-color);
}

.dark #switch button{
    animation: slide-in 0.3s forwards;
}

#switch span{
    width: 64px;
    height: 24px;
    background: var(--bg-color);
    border: 1px solid var(--border);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: 9999px;
    display: block;
}

/*links*/

ul{
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding-bottom: 16px;
}

ul li a{
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px 24px;
    background-color: var(--background-link);
    border-radius: 10px;
    text-decoration: none;
    color: var(--font-color);
    font-weight: 400;

    transition: background-color 0.5s ease, box-shadow 0.5s ease;
}

ul li a:hover{
    background-color: var(--background-hover);
    border: none;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
}

/*redes sociais*/

#social{
    padding: 24px;
    display: flex;
    justify-content: center;
}

#social img{
    width: 24px;
    height: 24px;
}

#social a{
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

/*animação*/

@keyframes slide-in{
    from{
        left: 0;
    }
    to{
        left: 50%;
    }
}

@keyframes slide-out{
    from{
        left: 50%;
    }
    to{
        left: 0;
    }
}