* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    background: #000000;
    background: linear-gradient(90deg, rgba(0, 0, 0, 1) 20%, rgba(199, 87, 87, 1) 50%, rgba(0, 0, 0, 1) 81%);
    overflow-x: hidden;
    padding: 20px 15px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.container {
    background: black;
    border-radius: 20px;
    padding: 30px 20px;
    backdrop-filter: blur(150px);
    box-shadow: 
        0 0 80px rgba(0, 0, 0, 0.8),
        0 0 160px rgba(255, 253, 253, 0.5),
        12px 24px 50px rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(180, 70, 255, 0.3);
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    margin-top: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.container h1 {
    color: #f8e8ff;
    font-size: clamp(32px, 8vw, 42px);
    text-align: center;
    letter-spacing: 2px;
    text-shadow: 
        0 0 20px #820000,
        0 0 40px #ff2e8f,
        0 0 60px #ff2e8f;
    font-weight: 700;
    line-height: 1.2;
}

#elements {
    display: flex;
    gap: 10px;
    width: 100%;
    align-items: center;
    flex-wrap: wrap; 
}

#elements input {
    flex: 1;
    min-width: 200px; 
    padding: 14px 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    font-size: 16px;
    backdrop-filter: blur(10px);
    outline: none;
    transition: all 0.3s ease;
}

#elements input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

#elements input:focus {
    border-color: #ff2e8f;
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 0 25px rgba(255, 46, 143, 0.5);
    transform: scale(1.02);
}

#elements button {
    padding: 14px 20px;
    background: white;
    color: #764ba2;
    border: none;
    border-radius: 14px;
    font-weight: bold;
    font-size: 15px;
    cursor: pointer;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    white-space: nowrap;
}

#elements button:hover {
    background: #f0f0f0;
    transform: translateY(-4px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.4);
}

#elements button:active {
    transform: translateY(-1px);
}

#list {
    list-style: none;
    width: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

#list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 8px;
    margin: 0;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: clamp(16px, 4vw, 18px);
    font-weight: 500;
    transition: all 0.4s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    flex-wrap: wrap; 
    gap: 10px;
}

#list li span {
    flex: 1;
    word-break: break-word;
    padding-right: 10px;
}

.task-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.delete-btn,
.edit-btn {
    padding: 8px 12px;
    border-radius: 8px;
    border: none;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
}

.delete-btn {
    background: #ff0000;
    color: white;
}

.edit-btn {
    background: #764ba2;
    color: white;
    margin-left: 150px;
}

.delete-btn:hover,
.edit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.task-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #59ff00;
    clip-path: circle();
}

.completed {
    text-decoration: line-through;
    opacity: 0.7;
}

p {
    color: white;
    font-weight: bold;
    text-align: center;
    font-size: 18px;
}


@media (max-width: 500px) {
    * {
        margin: 0;
        padding: 0;
    }

    .container {
        padding: 10px 15px;
        margin: 10px;
        border-radius: 50px;
    }

    #elements {
        flex-direction: column;
    }

    #elements input {
        width: 100%;
        min-width: unset;
    }

    #elements button {
        width: 100%;
        padding: 16px;
    }

    #list li {
        padding: 14px 12px;
        text-align: center;
    }

    #list li {
    flex-direction: column;
    align-items: center; 
    }

    #list .task-text {
        width: 100%;
        text-align: center;
    }

.task-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    gap: 10px;
}

.delete-btn,
.edit-btn {
    width: 100%;
    max-width: 300px;
    height: 44px;      
    padding: 0;           
    text-align: center;
    margin: 0 auto;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    line-height: 44px;   
    box-sizing: border-box;
    font-size: 16px;
    font-weight: bold;
    color: white;
}


.edit-btn {
    background-color: #6a4fbf; 
}

.delete-btn {
    background-color: #ff0000; 
}

}

@media (max-width: 350px) {
    .container h1 {
        letter-spacing: 1px;   
    }
}



