@import url("https://fonts.googleapis.com/css2?family=Bree+Serif&family=Caveat:wght@400;700&family=Lobster&family=Monoton&family=Open+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Playfair+Display+SC:ital,wght@0,400;0,700;1,700&family=Playfair+Display:ital,wght@0,400;0,700;1,700&family=Roboto:ital,wght@0,400;0,700;1,400;1,700&family=Source+Sans+Pro:ital,wght@0,400;0,700;1,700&family=Work+Sans:ital,wght@0,400;0,700;1,700&display=swap");

* {
    box-sizing: border-box;
}

.todos-bg-container {
    background-color: #f9fbfe;
    min-height: 100vh;
    padding: 10px;
}

.user-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.todos-heading {
    text-align: center;
    font-family: "Roboto";
    font-size: clamp(28px, 5vw, 46px);
    font-weight: 500;
    margin: 0;
    flex: 1;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.welcome-text {
    font-family: "Roboto";
    font-size: clamp(14px, 2.5vw, 16px);
    color: #6c757d;
    white-space: nowrap;
}

.welcome-text span {
    font-weight: 600;
    color: #4c63b6;
}

.logout-btn {
    background-color: #dc3545;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 8px 15px;
    font-family: "Roboto";
    font-size: clamp(12px, 2vw, 14px);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

.logout-btn:hover {
    background-color: #c82333;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(220, 53, 69, 0.3);
}

.logout-btn:active {
    transform: translateY(0);
}

.create-task-heading {
    font-family: "Roboto";
    font-size: clamp(20px, 4vw, 32px);
    font-weight: 700;
}

.create-task-heading-subpart {
    font-family: "Roboto";
    font-size: clamp(20px, 4vw, 32px);
    font-weight: 500;
}

.todo-items-heading {
    font-family: "Roboto";
    font-size: clamp(20px, 4vw, 32px);
    font-weight: 700;
}

.todo-items-heading-subpart {
    font-family: "Roboto";
    font-size: clamp(20px, 4vw, 32px);
    font-weight: 500;
}

.todo-items-container {
    margin: 0;
    padding: 0;
    list-style: none;
}

.todo-item-container {
    margin-top: 15px;
    border-radius: 8px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.todo-item-container:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.todo-user-input {
    background-color: white;
    width: 100%;
    border-style: solid;
    border-width: 1px;
    border-color: #e4e7eb;
    border-radius: 10px;
    margin-top: 10px;
    padding: 15px;
    font-size: clamp(14px, 2.5vw, 16px);
    outline: none;
    transition: border-color 0.3s ease;
}

.todo-user-input:focus {
    border-color: #4c63b6;
    box-shadow: 0 0 0 2px rgba(76, 99, 182, 0.2);
}

.button {
    color: white;
    background-color: #4c63b6;
    font-family: "Roboto";
    font-size: clamp(14px, 2.5vw, 18px);
    border-width: 0;
    border-radius: 4px;
    margin-top: 20px;
    margin-bottom: 50px;
    padding: 12px 20px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.1s ease;
    min-width: 80px;
}

.button:hover {
    background-color: #3a4d8f;
    transform: translateY(-1px);
}

.button:active {
    transform: translateY(0);
}

.label-container {
    background-color: #e6f6ff;
    width: 100%;
    border-style: solid;
    border-width: 5px;
    border-color: #096f92;
    border-right: none;
    border-top: none;
    border-bottom: none;
    border-radius: 4px;
}

.checkbox-input {
    width: 20px;
    height: 20px;
    margin-top: 12px;
    margin-right: 12px;
    cursor: pointer;
    flex-shrink: 0;
}

.checkbox-label {
    font-family: "Roboto";
    font-size: clamp(14px, 2.5vw, 16px);
    font-weight: 400;
    flex: 1;
    margin: 0;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.delete-icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: auto;
    min-width: 50px;
}

.delete-icon {
    padding: 15px;
    cursor: pointer;
    color: #dc3545;
    transition: color 0.3s ease, transform 0.1s ease;
    font-size: clamp(14px, 2.5vw, 16px);
}

.delete-icon:hover,
.delete-icon:focus {
    color: #c82333;
    transform: scale(1.1);
    outline: 2px solid #4c63b6;
    outline-offset: 2px;
}

.checked {
    text-decoration: line-through;
    opacity: 0.6;
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.empty-state-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state-text {
    font-family: "Roboto";
    font-size: clamp(14px, 2.5vw, 16px);
    margin: 0;
}

.task-counter {
    font-family: "Roboto";
    font-size: clamp(12px, 2vw, 14px);
    color: #6c757d;
    margin-bottom: 15px;
    text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
    .todos-bg-container {
        padding: 5px;
    }
    
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .user-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .todos-heading {
        margin-bottom: 10px;
    }
    
    .user-info {
        justify-content: center;
        gap: 10px;
    }
    
    .todo-user-input {
        padding: 12px;
    }
    
    .button {
        width: 100%;
        margin-bottom: 30px;
    }
    
    .checkbox-label {
        padding: 8px 15px;
    }
    
    .delete-icon {
        padding: 10px;
    }
    
    .todo-item-container {
        margin-top: 10px;
    }
}

@media (max-width: 480px) {
    .todos-bg-container {
        padding: 2px;
    }
    
    .checkbox-input {
        width: 18px;
        height: 18px;
        margin-right: 8px;
    }
    
    .checkbox-label {
        padding: 6px 12px;
    }
    
    .delete-icon {
        padding: 8px;
    }
    
    .delete-icon-container {
        min-width: 40px;
    }
}

/* Improved touch targets for mobile */
@media (hover: none) and (pointer: coarse) {
    .button {
        min-height: 44px;
    }
    
    .checkbox-input {
        width: 24px;
        height: 24px;
    }
    
    .delete-icon {
        padding: 12px;
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}