/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background: #f0f4f8;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    transition: background 0.3s;
}

.dark-mode {
    background: #181818;
    color: white;
}

.container {
    background: white;
    padding: 20px;
    width: 450px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    transition: background 0.3s;
}

.dark-mode .container {
    background: #242424;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

header h1 {
    font-size: 24px;
}

header button {
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: #333;
}

.dark-mode header button {
    color: white;
}

.task-input {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.task-input input,
.task-input button {
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.task-input input[type="text"] {
    flex: 1;
}

.task-input button {
    background: #007bff;
    color: #fff;
    border: none;
    cursor: pointer;
}

.task-input button:hover {
    background: #0056b3;
}

#task-list {
    list-style: none;
}

.task-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #eee;
    transition: background 0.3s;
}

.dark-mode .task-item {
    border-color: #444;
}

.task-item.completed span {
    text-decoration: line-through;
    color: #888;
}

.task-actions button {
    margin-left: 10px;
    padding: 6px 8px;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

.complete-btn {
    background: #28a745;
    color: white;
}

.delete-btn {
    background: #dc3545;
    color: white;
}

#task-summary {
    text-align: right;
    font-size: 16px;
    margin-bottom: 10px;
    font-weight: bold;
}

#floating-add {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    background: #007bff;
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    transition: background 0.3s;
}

#floating-add:hover {
    background: #0056b3;
}

.desktop-add {
    display: inline-block;
}

.mobile-add {
    display: none;
}


.complete-btn {
  color: green;
  background-color: white;
  
}

.edit-btn {
  color: blue;
}

.delete-btn {
  color: red;
  color: white;
}

.save-btn {
  color: purple;
}

/* Optional: hover effects */
.complete-btn:hover,
.edit-btn:hover,
.delete-btn:hover,
.save-btn:hover {
  opacity: 0.8;
  transform: scale(1.05);
  transition: 0.2s ease;
}

.task-item {
    border-bottom: 1px solid #007bff;
}

#task-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-weight: bold;
  font-size: 16px;
}

#current-date {
  color: #555;
}

.dark-mode #current-date {
  color: #ccc;
}


@media (max-width: 500px) {
    .container {
        width: 90%;
    }
    .task-input {
        flex-direction: column;
    }
}
