/* Base Styles for Desktop */
body {
    font-family: Arial, sans-serif;
    background: linear-gradient(135deg, #e0f7fa, #ffffff);
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    color: #333;
}

.container {
    flex: 1;
    width: 80%;
    max-width: 800px;
    padding: 30px;
    background-color: #68c0b9;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    text-align: center;
    margin: 20px auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-height: 60vh;
    overflow: hidden;
}

#note {
    margin-bottom: 20px;
    font-size: 18px;
    color: #333;
}

#user-id-container, #new-task-container, #filter-container {
    margin-bottom: 20px;
}

#user-name, #task-input, #date-input, #time-input, #add-task-btn, #get-id-btn {
    width: 100%;
    max-width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px solid #333;
    border-radius: 5px;
    font-size: 18px;
}

#add-task-btn, #get-id-btn {
    padding: 12px;
    border-radius: 8px;
    border: none;
    font-size: 18px;
    color: white;
    background-color: #3b8d2a;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

#add-task-btn:hover, #get-id-btn:hover {
    background-color: #45a041;
    transform: scale(1.05);
}

/* Task list styling */
.task-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin-bottom: 10px;
    background-color: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 16px;
    min-width: 0;
    width: 100%;
}

.task-item span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.task-item div {
    display: flex;
    gap: 10px;
    white-space: nowrap;
}

.task-item button {
    padding: 10px 15px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.task-item button.complete {
    background-color: #28a745;
    color: white;
    border: none;
}

.task-item button.complete:hover {
    background-color: #218838;
    transform: scale(1.05);
}

.task-item button.delete {
    background-color: #dc3545;
    color: white;
    border: none;
}

.task-item button.delete:hover {
    background-color: #c82333;
    transform: scale(1.05);
}

.task-item button.undo {
    background-color: #ffc107;
    color: black;
    border: none;
}

.task-item button.undo:hover {
    background-color: #e0a800;
    transform: scale(1.05);
}

/* Completed task */
.completed-task {
    text-decoration: line-through;
    color: gray;
}

/* Filter buttons */
#filter-container {
    display: flex;
    justify-content: space-around;
    gap: 10px;
    flex-wrap: nowrap;
}

.filter-btn {
    padding: 8px 15px;
    background-color: #389226;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    font-size: larger;
}

.filter-btn:hover {
    background-color: #45a041;
    transform: scale(1.05);
}

/* Colorful button */
.colorful-button {
    background: linear-gradient(45deg, #ee1b08, #e03004, #ffcf56, #98ff6c, #f00af0, #566eff);
    background-size: 400% 400%;
    color: white;
    font-weight: bold;
    padding: 15px 30px;
    font-size: 1.5em;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-position 1s ease, transform 0.2s ease;
}

.colorful-button:hover {
    background-position: 100% 0%;
    transform: scale(1.1);
}

.colorful-button:active {
    transform: scale(1);
}

/* User ID Display */
#user-id-display-container {
    margin-bottom: 20px;
    padding: 10px;
    background-color: #e0f7fa;
    border: 2px solid #333;
    border-radius: 5px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

/* Footer */
footer {
    text-align: center;
    color: #666;
    background-color: #f1f1f1;
    padding: 10px 0;
    margin-top: auto;
    width: 100%;
}

footer a {
    color: #161515;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Tablet Design */
@media (max-width: 768px) {
    .container {
        width: 90%;
        padding: 20px;
    }

    #user-name, #task-input, #date-input, #time-input, #add-task-btn, #get-id-btn {
        max-width: 100%;
        font-size: 16px;
    }

    #add-task-btn, #get-id-btn {
        padding: 10px;
        font-size: 16px;
    }

    .filter-btn {
        font-size: medium;
    }
    
    .task-item {
        font-size: 14px;
    }

    .task-item span {
        max-width: 80%;
    }
}

/* Mobile Design */
@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    .container {
        width: 95%;
        padding: 15px;
        box-shadow: none;
    }

    #user-name, #task-input, #date-input, #time-input, #add-task-btn, #get-id-btn {
        font-size: 14px;
    }

    #add-task-btn, #get-id-btn {
        padding: 8px;
        font-size: 14px;
    }

    .filter-btn {
        padding: 8px;
        font-size: small;
    }

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

    .task-item span {
        max-width: 100%;
    }
    
    .task-item button {
        padding: 8px;
        font-size: 12px;
    }
}






