/* Base Style */

:root {
    --color-pa: #031F73;
    --color-extime: #004650;
    --motion-duration: 5s;
}

html{
    font-family: Century Gothic, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, sans-serif, BlinkMacSystemFont, Helvetica Neue, Arial, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;
    /* font-size: 100%; */
    height: 100%;
}

/* Style Components */

body{
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
}

.background{
    position: absolute;
    z-index: -1;
    background-color: var(--color-pa);
    opacity: 0;
    width: 100vw;
    height: 100vh;
    transform-origin: center;
    transform: scale(0.75);
    animation: 
        background-motion var(--motion-duration) ease-in-out;
}

.content{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: auto;
    width: 100%;
    height: 100%;
    gap: 5rem;
}

.block{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2.5rem;
    transform-origin: center;
    transform: scale(0.5);
    width: 80vw;
    opacity: 0;
    animation: 
        block-motion var(--motion-duration) ease-in-out;
}

.logo{
    display: flex;
    position: relative;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    width: 100%;
    height: 12rem;
    overflow: hidden;
}

.logo > svg{
    position: absolute;
    transform-origin: center;
}

svg.pa{
    height: 12rem;
    animation: 
        logo-pa-motion var(--motion-duration) ease-in-out;
}

svg.extime{
    height: 11rem;
    transform: translateX(-100vw);
    opacity: 0;
    animation: 
        logo-extime-motion var(--motion-duration) ease-in-out;
}

.loader {
    width: 3rem;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    border: .5rem solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.loader::before{
    content: "";
    position: absolute;
    width: 3rem;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    border: .5rem solid #fff;
    animation:
        l20-1 1s infinite linear alternate,
        l20-2 2s infinite linear;
}

.modale{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: #fff;
    border-radius: .25rem;
    padding: 2rem 2.5rem;
    gap: .5rem;
    box-shadow: 0px 10px 30px 0px rgba(0, 0, 0, 0.2);
    transform-origin: center;
    transform: translateY(4rem);
    opacity: 0;
    animation: 
        modale-motion var(--motion-duration) ease-in-out;
}

.modale h1, .modale h2{
    margin: 0;
    padding: 0;
    text-align: center;
    color: var(--color-extime);
    animation: 
        title-motion var(--motion-duration) ease-in-out;
}

.modale h1{
    font-size: 1.5rem;
    font-weight: 600;
}

.modale h2{
    font-size: 1rem;
    font-weight: 500;
}

/* Responsive */

@media (max-width: 768px) {

    html{
        font-size: 14px;
    }

    .block{
        width: 100vw;
    }
    
    .modale{
        margin: 0 10vw;
    }

}

@media (max-width: 320px) {

    html{
        font-size: 10px;
    }

}

/* Animations Keyframes */

@keyframes background-motion{
    5%   {transform: scale(1); opacity: 1;}
    45%  {transform: scale(1); background-color: var(--color-pa);}
    50%  {background-color: var(--color-extime);}
    95%  {transform: scale(1); opacity: 1; }
    100% {transform: scale(0.75); opacity: 0; background-color: var(--color-extime);}
}

@keyframes block-motion{
    5%   {transform: scale(0.5); opacity: 0;}
    10%  {transform: scale(1); opacity: 1;}
    90%  {transform: scale(1); opacity: 1;}
    95%  {transform: scale(0.5); opacity: 0;}
}

@keyframes logo-pa-motion{
    45%  {transform: translateX(0); opacity: 1;}
    55%  {transform: translateX(100vw); opacity: 0;}
    100% {transform: translateX(100vw); opacity: 0;}
}

@keyframes logo-extime-motion{
    5%   {transform: translateX(-100vw); opacity: 0;}
    45%  {transform: translateX(-100vw); opacity: 0;}
    55%  {transform: translateX(0); opacity: 1;}
    100% {transform: translateX(0); opacity: 1;}
}

@keyframes modale-motion{
    10%  {transform: translateY(4rem); opacity: 0;}
    15%  {transform: translateY(0); opacity: 1;}
    90%  {transform: translateY(0); opacity: 1; }
    95%  {transform: translateY(4rem); opacity: 0;}
}

@keyframes title-motion{
    0%    {color: var(--color-pa);}
    45%   {color: var(--color-pa);}
    55%   {color: var(--color-extime);}
    100%  {color: var(--color-extime);}
}

@keyframes l20-1{
    0%    {clip-path: polygon(50% 50%,0       0,  50%   0%,  50%    0%, 50%    0%, 50%    0%, 50%    0% )}
    12.5% {clip-path: polygon(50% 50%,0       0,  50%   0%,  100%   0%, 100%   0%, 100%   0%, 100%   0% )}
    25%   {clip-path: polygon(50% 50%,0       0,  50%   0%,  100%   0%, 100% 100%, 100% 100%, 100% 100% )}
    50%   {clip-path: polygon(50% 50%,0       0,  50%   0%,  100%   0%, 100% 100%, 50%  100%, 0%   100% )}
    62.5% {clip-path: polygon(50% 50%,100%    0, 100%   0%,  100%   0%, 100% 100%, 50%  100%, 0%   100% )}
    75%   {clip-path: polygon(50% 50%,100% 100%, 100% 100%,  100% 100%, 100% 100%, 50%  100%, 0%   100% )}
    100%  {clip-path: polygon(50% 50%,50%  100%,  50% 100%,   50% 100%,  50% 100%, 50%  100%, 0%   100% )}
}

@keyframes l20-2{ 
    0%    {transform:scaleY(1)  rotate(0deg)}
    49.99%{transform:scaleY(1)  rotate(135deg)}
    50%   {transform:scaleY(-1) rotate(0deg)}
    100%  {transform:scaleY(-1) rotate(-135deg)}
}