:root {
    --primary-color: #4CAF50;
    --secondary-color: #2196F3;
    --background-color: #f5f5f5;
    --card-background: #ffffff;
    --text-color: #333333;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: var(--background-color);
    color: var(--text-color);
}

.app-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

h1 {
    color: var(--primary-color);
    font-size: 2.5em;
    margin-bottom: 10px;
}

h2 {
    color: var(--secondary-color);
    font-size: 1.8em;
    margin-bottom: 15px;
}

#date-display {
    font-size: 1.2em;
    color: var(--text-color);
}

main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.card {
    background-color: var(--card-background);
    border-radius: 8px;
    padding: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

#habit-form {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

#habit-input {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1em;
}

#add-habit-btn {
    padding: 10px 15px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

#add-habit-btn:hover {
    background-color: #45a049;
}

.habit-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #eee;
    transition: var(--transition);
}

.habit-item:last-child {
    border-bottom: none;
}

.habit-item:hover {
    background-color: #f9f9f9;
}

.habit-item label {
    flex-grow: 1;
    margin-left: 10px;
    cursor: pointer;
}

.habit-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
}

.delete-btn {
    background-color: #ff4444;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

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

#streak-info {
    text-align: center;
    font-size: 1.2em;
    font-weight: bold;
    color: var(--secondary-color);
}

#calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.9em;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: var(--transition);
}

.calendar-day.completed {
    background-color: var(--primary-color);
    color: white;
}

.calendar-day.today {
    border: 2px solid var(--secondary-color);
    font-weight: bold;
}

@media (max-width: 768px) {
    main {
        grid-template-columns: 1fr;
    }
}