body {
    background-color: #333;
    height: 100vh; 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    margin: 0;
    overflow: hidden; 
}

.container {
    display: flex;
    flex-direction: column;
    flex-grow: 1; 
    width: 100%; 
    gap: 5px;
    max-width: 500px;
    height: 600px;
    min-height: 400px; 
    margin: 0; 
    border-radius: 0px;
    padding: 20px;
    background-color: #333;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 1);
    position: relative; 
    overflow: hidden; 
    z-index: 1; 
}

.container::before {
    width: 400vmin;
    height: 400vmin;
}


.container h1 {
    text-align: center;
    font-size: 2.2rem;
    margin: 0 0 20px 0;
    background: linear-gradient(45deg, #00ffff, #5f11dd);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative; 
    font-weight: 800;
}


.input-container {
    display: flex;
    gap: 10px; 
    margin-bottom: 20px;
    flex-wrap: nowrap; 
    position: relative; 
}

#task-input {
    flex-grow: 1; 
    color: #000;
    border: 2px solid transparent; 
    border-radius: 0px;
    font-size: 16px;
    background-color: #fff;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 1);
}

::placeholder {
    background: linear-gradient(45deg, #00ffff, #7513a3);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    opacity: 0.7; 
}


.action-button {
    padding: 8px;
    border: 2px solid transparent; 
    background-color: transparent; 
    border-radius: 0px;
    font-size: 14px;
    cursor: pointer;
    text-align: center;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.7);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.action-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 15px rgba(0, 0, 0, 0.9);
}


.animated-border {
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.animated-border::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 500%; 
    height: 500%;
    background: conic-gradient(#5f11dd, #00ffff, #5f11dd);
    animation: rotate-gradient 4s linear infinite;
    z-index: -2;
}

.animated-border::after {
    content: '';
    position: absolute;
    inset: 2px;
    background-color: #333;
    border-radius: 0px;
    z-index: -1;
}

#add-button {
    color: #00ffff;
}


#clear-button {
    color: #d91111;
}


#task-list {
    flex-grow: 1; 
    overflow-y: auto; 
    padding-right: 10px; 
    position: relative; 
}


.task-item {
    display: flex;
    justify-content: space-between; 
    align-items: center;
    background-color: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 0px;
    margin-bottom: 10px;
    color: white;
    font-size: 18px;
    transition: opacity 0.5s ease; 
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}


.task-item.new {
    animation: fadeIn 0.5s ease;
}


.task-item .task-text {
    flex-grow: 1; 
    margin: 0 10px;
}


.task-item .task-timestamp {
    font-size: 14px;
    color: rgba(0, 255, 255, 0.8);
    margin-left: auto; 
    padding-right: 15px;
    white-space: nowrap; 
    margin: 0 10px;
}


.delete-button {
    background: none;
    border: none;
    color: #d91111;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

.delete-button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}


.check-icon {
    color: #00ffff;
    cursor: pointer;
    margin-right: 15px;
    font-size: 24px; 
    transition: color 0.3s ease;
}

.task-item.completed .task-text {
    text-decoration: line-through;
    opacity: 0.6;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0px;
}

::-webkit-scrollbar-thumb {
    background-color: #7513a3;
    border-radius: 0px;
    border: 2px solid #09ebd9;
}


@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


@keyframes rotate-gradient {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}


footer {
    color: #00ffff;
    width: 100%;
    max-width: 500px;
    text-align: center;
    padding: 15px 0; 
}

.music-button {
    background: none;
    border: none;
    font-size: 24px;
    color: #00ffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.music-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    position: absolute;
    bottom: 15px;
    right: 20px;
    z-index: 2; 
}



@media (max-width: 768px) {
    .container {
        width: 95%; 
        height: auto; 
        margin: 20px auto; 
        padding: 15px; 
    }

    #task-input {
        min-width: 0; 
    }

    .task-item {
        font-size: 16px;
    }
}