html {
    box-sizing: border-box;
}

*, *:before, *:after {
    box-sizing: inherit;
}

html, body {
    height: 100%;
    margin: 0;
}

canvas {
    display: block;
}

#unity-container {
    width: 100%;
    height: 100%;
    position: relative;
}

#unity-canvas {
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, #01ADFF 0%, #0139F2 100%);
}


#loading-cover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

#unity-loading-bar {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

#unity-logo {
    display: block;
    text-align: center;
    pointer-events: none;
    border-radius: 40px;
    margin-bottom: 15px; /* Отступ снизу логотипа */
}

#unity-logo img {
    display: block;
    max-width: 45%;
    pointer-events: none;
    border: rgb(241, 241, 241);
    border-radius: 40px;
    outline: 15px solid #fff;
    margin: 0 auto;
}

#unity-progress-bar-empty {
    width: 35%;
    height: 40px;
    border: 2px solid white;
    padding: 2px;
    border-radius: 50px;
}

#unity-progress-bar-full {
    width: 0%;
    height: 100%;
    background: repeating-linear-gradient(45deg, #ff0000, #ff0000 10px, #ffffff 10px, #ffffff 20px);
    border-radius: 50px;
    transition: width 0.5s ease;
}

#additional-image {
    margin: 10px 0;
    text-align: center;
}

#additional-image img {
    max-width: 80%;
    max-height: 100px;
    display: block;
    margin: 0 auto;
}

/* === Медиа-запросы для адаптации под экраны до 1024px === */

@media screen and (max-width: 1024px) {
    #unity-logo img {
        max-width: 25%;
        outline: 9px solid #fff;
        border-radius: 25px;
    }

    #additional-image img {
        max-width: 50%;
    }
}

/* === Темная/светлая тема === */

.light #unity-progress-bar-empty {
    border-color: black;
}

.light #unity-progress-bar-full {
    background: black;
}

/* === Спиннер (анимация загрузки) === */

.spinner,
.spinner:after {
    border-radius: 50%;
    width: 5em;
    height: 5em;
}

.spinner {
    margin: 10px;
    font-size: 10px;
    position: relative;
    text-indent: -9999em;
    border-top: 1.1em solid rgba(255, 211, 37, 0.2);
    border-right: 1.1em solid rgba(255, 211, 37, 0.2);
    border-bottom: 1.1em solid rgba(255, 211, 37, 0.2);
    border-left: 1.1em solid #ffffff;
    transform: translateZ(0);
    animation: spinner-spin 1.1s infinite linear;
}

@keyframes spinner-spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}


