:root {
    --loading-time: 5.5s;
    --background-color: #333;
    --multiplicator: 1;
    --phone-height: calc(445px * var(--multiplicator));
    --phone-width: calc(205px * var(--multiplicator));
}

body {
    background-color: var(--background-color);
}
.absolute-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.image {
    opacity: 0.3;
    max-height: 450px;
}

.phone {
    height: var(--phone-height);
    width: var(--phone-width);
    background-color: white;
    border-radius: calc(30px * var(--multiplicator));
}

.camera {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background-color: black;
    top: calc(17px * var(--multiplicator));
    height: calc(8px * var(--multiplicator));
    width: calc(8px * var(--multiplicator));
    border-radius: 100%;
}

.speaker-grill {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: calc(35px * var(--multiplicator));
    display: flex;
    justify-content: space-between;
    width: calc(35px * var(--multiplicator));
    height: calc(5px * var(--multiplicator));
    border-radius: calc(10px * var(--multiplicator));
    background-color: black;
}

.microphone {
    position: absolute;
    left: 34%;
    top: calc(33.5px * var(--multiplicator));
    height: calc(8px * var(--multiplicator));
    width: calc(8px * var(--multiplicator));
    border-radius: calc(10px * var(--multiplicator));
    background-color: black;
    transform: scale(0.7);
}

.screen {
    height: calc(325px * var(--multiplicator));
    width: calc(185px * var(--multiplicator));
    background-color: black;
}

.home-button {
    position: absolute;
    bottom: calc(12px * var(--multiplicator));
    background-color: white;
    left: 50%;
    transform: translateX(-50%);
    height: calc(35.5px * var(--multiplicator));
    width: calc(35.5px * var(--multiplicator));
    border-radius: 100%;
    border: calc(2.5px * var(--multiplicator)) solid lightslategray;
}

.phone-border {
    height: calc(var(--phone-height) + calc(3px * var(--multiplicator)));
    width: calc(var(--phone-width) + calc(3px * var(--multiplicator)));
    background-color: lightslategray;
    border-radius: calc(32px * var(--multiplicator));
}

.power {
    position: absolute;
    top: -0.2%;
    left: 73%;
    background-color: lightslategray;
    height: calc(3px * var(--multiplicator));
    width: calc(25px * var(--multiplicator));
    border-radius: calc(1px * var(--multiplicator));
}

.mute {
    position: absolute;
    left: -0.2%;
    top: 13%;
    width: calc(3px * var(--multiplicator));
    height: calc(18px * var(--multiplicator));
    border-radius: calc(1px * var(--multiplicator));
    background-color: lightslategray;
}

.volume-up {
    position: absolute;
    left: -0.2%;
    top: 21%;
    width: calc(3px * var(--multiplicator));
    height: calc(12px * var(--multiplicator));
    border-radius: calc(10px * var(--multiplicator));
    background-color: lightslategray;
}

.volume-down {
    position: absolute;
    left: -0.2%;
    top: 26%;
    width: calc(3px * var(--multiplicator));
    height: calc(12px * var(--multiplicator));
    border-radius: calc(10px * var(--multiplicator));
    background-color: lightslategray;
}

.loading-box {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    width: calc(110px * var(--multiplicator));
    height: calc(90px * var(--multiplicator));
}

.apple-logo {
    width: calc(calc(100px * var(--multiplicator)) * 0.3);
    height: calc(calc(118.7198px * var(--multiplicator)) * 0.3);
    fill: currentColor;
    color: white;
    margin-bottom: calc(15px * var(--multiplicator));
}

.loading {
    height: calc(2px * var(--multiplicator));
    width: 100%;
    background-color: gray;
    border-radius: calc(1px * var(--multiplicator));
    overflow: hidden;
}

.fill {
    width: 100%;
    background-color: white;
    height: 100%;
    transform: translateX(0%);
    border-radius: calc(1px * var(--multiplicator));
    animation: load var(--loading-time) linear forwards;
}

.homescreen {
    display: none;
    height: 100%;
    width: 100%;
    background-position: center;
    background-size: cover;
    flex-direction: column;
}

@keyframes load {
    0% {
        transform: translateX(calc(-100% + 0%));
    }

    30% {
        transform: translateX(calc(-100% + 22%));
    }

    44% {
        transform: translateX(calc(-100% + 22%));
    }

    66% {
        transform: translateX(calc(-100% + 57%));
    }

    75% {
        transform: translateX(calc(-100% + 59%));
    }

    90% {
        transform: translateX(calc(-100% + 70%));
    }

    100% {
        transform: translateX(calc(-100% + 100%));
    }
}

.topbar {
    height: calc(12px * var(--multiplicator));
    width: 100%;
    background-color: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

.icons-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(5, 1fr);
    gap: 5px;
    padding: 5px;
}

.app {
    display: flex;
    justify-content: center;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.icon {
    height: calc(32px * var(--multiplicator));
    width: calc(32px * var(--multiplicator));
    border-radius: calc(8px * var(--multiplicator));
    cursor: pointer;
    object-fit: cover;
}

.app > .icon {
    margin-bottom: calc(5px * var(--multiplicator));
}

.text {
    font-size: 0.55rem;
    font-family: Arial, Helvetica, sans-serif;
    color: #fafafa;
}

.dock {
    height: 50px;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-around;
}

.app-screen {
    position: absolute;
    background-color: black;
    height: 100%;
    width: 100%;
    transition: transform 200ms linear;
    transform: scale(0);
    display: flex;
    justify-content: center;
    align-items: center;
}

.app-screen > p {
    font-family: arial;
    color: white;
}

.time {
    display: block;
    text-align: center;
    color: white;
    font-size: 0.5rem;
    opacity: 0.6;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: bolder;
}

@media (max-width: 486px) {
    :root {
        --multiplicator: 1.3;
    }
}
