/*====================================
        TODO PANEL
====================================*/

#todo-panel{

    position: fixed;

    top: 80px;

    left: 5%;

    width: min(400px,calc(100vw - 32px));

    height:77vh;

    display:flex;

    flex-direction:column;

    padding:20px;

    direction:ltr;

    border-radius:28px;

    background:rgba(255,255,255,.1);

    backdrop-filter:blur(25px);

    border:1px solid rgba(255,255,255,.15);

    box-shadow:
            0 40px 100px rgba(0,0,0,.45),
            0 0 0 1px rgba(255,255,255,.08),
            0 0 30px rgba(255,255,255,.15);

    opacity:0;

    pointer-events:none;

    transform:translateY(-20px);

    transition:.3s;

    z-index:99999;

}

#todo-panel.show{

    opacity:1;

    transform:translateY(0);

    pointer-events:auto;

}

#todo-panel::before{

    content:"";

    position:absolute;

    inset:0;

    border-radius:inherit;

    padding:1px;

    background:linear-gradient(
            135deg,
            rgba(255,255,255,.8),
            rgba(255,255,255,.15),
            rgba(130,255,200,.4)
    );

    -webkit-mask:
            linear-gradient(#fff 0 0) content-box,
            linear-gradient(#fff 0 0);

    -webkit-mask-composite:xor;

    mask-composite:exclude;

    pointer-events:none;

}

.todo-header{

    display:flex;

    justify-content:space-between;

    align-items:center;

    margin-bottom:18px;

}

.todo-header h3{

    color:#fff;

    margin:0;

    display:flex;

    align-items:center;

    gap:10px;

}

#close-todo{

    display:flex;
    justify-content:center;
    align-items:center;

    width:42px;

    height:42px;

    border:none;

    border-radius:14px;

    background:rgba(255,255,255,.08);

    color:#fff;

    cursor:pointer;

    transition:.25s;

}

#close-todo:hover{

    background:rgba(255,255,255,.16);

}

.todo-add{

    display:flex;

    gap:12px;

    margin-bottom:20px;

}

#task-input{

    flex:1;

    border:none;

    outline:none;

    padding:14px 18px;

    border-radius:18px;

    background:rgba(255,255,255,.08);

    color:#fff;

    font-size:15px;

}

#task-input::placeholder{

    color:rgba(255,255,255,.55);

}

#add-task{

    display:flex;
    justify-content: center;
    align-items: center;

    width:52px;

    border:none;

    border-radius:18px;

    background:#00d563;

    color:#fff;

    cursor:pointer;

    transition:.25s;

}

#add-task:hover{

    transform:scale(1.05);

}

#todo-list{

    flex:1;

    overflow-y:auto;

    display:flex;

    flex-direction:column;

    gap:10px;

    padding-right:4px;

}

.todo-item{

    display:flex;

    align-items:center;

    justify-content:space-between;

    gap:12px;

    padding:14px;

    border-radius:18px;

    background:rgba(255,255,255,.08);

    transition:.25s;

    animation:todoShow .25s ease;

}

.todo-item:hover{

    transform:translateY(-2px);

    background:rgba(255,255,255,.14);

}

.todo-check{

    width:22px;

    height:22px;

    accent-color:#00d563;

    cursor:pointer;

}

.todo-text{

    flex:1;

    color:#fff;

    font-size:15px;

    word-break:break-word;

}

.todo-item.done .todo-text{

    text-decoration:line-through;

    opacity:.45;

}

.delete-task{

    display:flex;
    justify-content:center;
    align-items:center;

    width:38px;

    height:38px;

    border:none;

    border-radius:12px;

    background:rgba(255,255,255,.08);

    color:#fff;

    cursor:pointer;

    transition:.25s;

}

.delete-task:hover{

    background:#ff4f6d;

    color:#fff;

}

#todo-list::-webkit-scrollbar{

    width:6px;

}

#todo-list::-webkit-scrollbar-thumb{

    background:rgba(255,255,255,.18);

    border-radius:20px;

}

#todo-list::-webkit-scrollbar-track{

    background:transparent;

}

@keyframes todoShow{

    from{

        opacity:0;

        transform:translateY(12px);

    }

    to{

        opacity:1;

        transform:none;

    }

}

@media (max-width:768px){

    #todo-panel{

        left:50%;

        transform:translateX(-50%);

        width:calc(100vw - 24px);

        height:72vh;

        padding:16px;

    }

    #todo-panel.show{

        transform:translateX(-50%);

    }

}

/*====================================
        TODO OVERLAY
====================================*/

#todo-overlay{

    position:fixed;

    inset:0;

    background:rgba(0,0,0,.25);

    backdrop-filter:blur(8px);

    opacity:0;

    visibility:hidden;

    transition:.3s;

    z-index:99998;

}

#todo-overlay.show{

    opacity:1;

    visibility:visible;

}

.task-text{
    color:#fff;
    margin:5px;
}

/*check box*/


/*=========================
      Checkbox
=========================*/

.task-check-wrapper{

    position:relative;

    width:24px;

    height:24px;

    display:flex;

    justify-content:center;

    align-items:center;

    cursor:pointer;

    flex-shrink:0;

}

.task-check{

    position:absolute;

    opacity:0;

    width:100%;

    height:100%;

    cursor:pointer;

}

.checkmark{

    width:24px;

    height:24px;

    border-radius:8px;

    border:2px solid rgba(255,255,255,.28);

    background:rgba(255,255,255,.05);

    backdrop-filter:blur(8px);

    transition:.25s;

    position:relative;

    overflow:hidden;

}

.task-check-wrapper:hover .checkmark{

    border-color:#00d563;

    box-shadow:
            0 0 12px rgba(0,213,99,.25);

}

.task-check:checked + .checkmark{

    background:linear-gradient(
            135deg,
            #00d563,
            #00b84f
    );

    border-color:#00d563;

    box-shadow:
            0 0 18px rgba(0,213,99,.45);

}

.checkmark::after{

    content:"";

    position:absolute;

    left:8px;

    top:3px;

    width:5px;

    height:11px;

    border:solid white;

    border-width:0 3px 3px 0;

    transform:rotate(45deg) scale(0);

    transition:.2s;

}

.task-check:checked + .checkmark::after{

    transform:rotate(45deg) scale(1);

}

.task-check:checked + .checkmark{

    animation:checkPop .25s ease;

}

@keyframes checkPop{

    0%{

        transform:scale(.8);

    }

    60%{

        transform:scale(1.15);

    }

    100%{

        transform:scale(1);

    }

}

.task-text{

    transition:.25s;

}

.task-completed{

    opacity:.45;

    text-decoration:line-through;

}

.task-left{

    display:flex;

    align-items:center;

    gap:14px;

    flex:1;

    min-width:0;

}