.todos {
    transform: perspective(400);
    transition: 0.5s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.todo-group {
    --button-width: 80%;
    --button-height: 70px;
    --rotate-deg: 100deg;

    margin: 20px auto;
    position: relative;
    height: var(--button-height);
    width: var(--button-width);
    line-height: var(--button-height);
    transform: translateZ(0);
    transition: 0.5s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.todo-group .todo-shadow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;

    height: 105%;
    background: rgba(0, 0, 0, 0.05);
    transition: 0.7s cubic-bezier(0.215, 0.61, 0.355, 1);
    transform-origin: center top;
}

.todo-group .todo-paper {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;

    transform-origin: center top;
    transform-style: preserve-3d;

    perspective: 1000px;
}
.todo-group .todo-paper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;

    transform-origin: center top;
    transform: translateY(-100%);
    width: calc(var(--button-width) * 0.8);
    height: calc(var(--button-height) * 0.1);

    margin: 0 auto;
    background: rgba(239, 239, 239, 0.8);
    transition: 0.65s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.todo-group .todo-paper .todo-paper-bg {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: linear-gradient(104deg, #123597, #97ABFF);
    transform-origin: center top;
    transform-style: preserve-3d;
    z-index: 2;
    transition: 0.65s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.todo-group .todo-paper .todo-paper-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    transform-origin: center top;
    transform: rotateZ(0);
    width: calc(var(--button-width) * 0.8);
    height: calc(var(--button-height) * 0.1);
    margin: 0 auto;
    background: rgba(239, 239, 239, 0.8);
    backface-visibility: hidden;
}

.todo-group .cover-content-container {
    position: absolute;
    top: 0;
    left: 0;
    perspective: 1000;
    width: 100%;
    height: 100%;
    color: white;
}

.todo-group .cover-content {
    transform-origin: center top;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: all 0.65s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.todo-group .cover-content p {
    overflow: hidden;
    text-overflow:ellipsis;
    white-space: nowrap;
}

.todo-group .cover-content p.completed {
    text-decoration: line-through;
    color: rgba(255, 255, 255, 0.3);
}

.todo-group .cover-content .editing {
    width: 80%;
    height: calc(var(--button-height) * 0.5);
    font-size: 1rem;
    border-radius: 5px;
    border: #333;
    color: #555;
    padding: 3px;
}


@media (prefers-color-scheme: dark) {
    .todo-group .todo-paper .todo-paper-bg {
        background: linear-gradient(104deg, #123597, #97ABFF);
    }

    .todo-group .cover-content-container {
        color: rgba(255, 255, 255, 0.8);
    }
    
    .todo-group .cover-content p.completed {
        color: rgba(255, 255, 255, 0.3);
    }

    .todo-group .cover-content .editing {
        border: #333;
        background-color: #555;
        color: white;
    }
}

@media (prefers-color-scheme: light) {
    .todo-group .todo-paper .todo-paper-bg {
        background: linear-gradient(104deg, #5151E5, #72EDF2);
    }

    .todo-group .cover-content-container {
        color: rgba(255, 255, 255, 0.8);
    }
    
    .todo-group .cover-content p.completed {
        color: rgba(255, 255, 255, 0.3);
    }

    .todo-group .cover-content .editing {
        border: #333;
        color: #555;
        background-color: rgba(255, 255, 255, 0.8);
    }
}