* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: #f3f4f6;
    color: #1f2937;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    padding: 20px;
}

.app-container {
    background: #ffffff;
    width: 100%;
    max-width: 460px;
    padding: 32px;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

/* WIDGET DE DATA E HORA */
.header-widget {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e5e7eb;
    text-align: center;
}

.time-container {
    display: flex;
    flex-direction: column;
}

#time-display {
    font-size: 2rem;
    font-weight: 600;
    color: #111827;
    letter-spacing: -1px;
}

.date-text {
    font-size: 0.9rem;
    color: #6b7280;
    text-transform: capitalize;
}

/* TÍTULO E INPUT PRINCIPAL */
h1 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: #111827;
    text-align: center;
}

.input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    outline: none;
    font-size: 0.95rem;
    transition: border-color 0.2s;
}

input:focus {
    border-color: #374151;
}

#add-btn {
    padding: 12px 20px;
    background-color: #111827;
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
}

#add-btn:hover {
    background-color: #374151;
}

/* CONTROLOS (PESQUISA E FILTRO) */
.controls-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
    background: #f9fafb;
    padding: 16px;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.filters {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.filter-btn {
    background: transparent;
    border: 1px solid #d1d5db;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    color: #4b5563;
    transition: all 0.2s;
    flex: 1;
}

.filter-btn:hover {
    border-color: #9ca3af;
}

.filter-btn.active {
    background: #111827;
    color: white;
    border-color: #111827;
}

/* LISTA DE TAREFAS */
ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 300px;
    overflow-y: auto;
    padding-right: 4px;
}

/* Estilização da barra de scroll */
ul::-webkit-scrollbar {
    width: 6px;
}
ul::-webkit-scrollbar-thumb {
    background-color: #d1d5db;
    border-radius: 10px;
}

li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    transition: all 0.2s ease;
}

li:hover {
    border-color: #9ca3af;
    box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}

li.completed span {
    text-decoration: line-through;
    color: #9ca3af;
}

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

.btn-action {
    padding: 6px;
    font-size: 0.9rem;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.btn-check { background-color: #10b981; }
.btn-check:hover { background-color: #059669; }

.btn-delete { background-color: #ef4444; }
.btn-delete:hover { background-color: #dc2626; }


/* =========================================
   BOTÃO DE VOLTAR
   ========================================= */
.back-link {
    display: block;
    text-align: center;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
    color: #6b7280;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.back-link:hover {
    color: #111827;
    text-decoration: underline;
}