:root {
    --bg-gradient: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --primary: #f65cf6;
    --primary-hover: #ed3adb;
    --danger: #ef4444;
    --warning: #f59e0b;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --font-family: 'Inter', sans-serif;
}

body {
    margin: 0;
    font-family: var(--font-family);
    background: var(--bg-gradient);
    color: var(--text-main);
    min-height: 100vh;
}

.header {
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(12px);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
    flex-wrap: wrap; 
    gap: 1rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.5px;
}


.btn {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    border: 1px solid var(--glass-border);
    padding: 0.6rem 1.2rem;
    margin: 0.2rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-family);
    font-weight: 500;
}

.btn:hover:not(:disabled) {
    background: var(--primary);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.btn-primary { background: var(--primary); border: none; }
.btn-danger { background: var(--danger); border: none; }
.btn-warning { background: var(--warning); border: none; color: #fff;}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    padding: 2rem;
    align-items: start;
}

.widget {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    animation: fadeInScale 0.4s ease-out forwards;
}

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.95) translateY(10px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.widget-header {
    padding: 1.2rem;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--glass-border);
    border-radius: 16px 16px 0 0;
}

.widget-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 500;
}

.close-btn {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.2s;
}

.close-btn:hover { color: var(--danger); }

.widget-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

input, textarea {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    border-radius: 8px;
    padding: 0.8rem;
    font-family: var(--font-family);
    transition: border 0.3s;
}

input:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.todo-list {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 200px;
    overflow-y: auto;
}

.todo-list::-webkit-scrollbar { width: 6px; }
.todo-list::-webkit-scrollbar-thumb { background: var(--glass-border); border-radius: 4px; }

.todo-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.todo-item button {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
}
.todo-item button:hover { color: var(--danger); }

.clock-time, .timer-display, .weather-temp {
    font-size: 3.5rem;
    font-weight: 300;
    color: #fff;
    text-align: center;
    letter-spacing: -2px;
}

.clock-date, .weather-desc {
    color: var(--text-muted);
    margin-top: 0.5rem;
    text-align: center;
    font-size: 1rem;
}

.timer-controls { display: flex; gap: 10px; justify-content: center; margin-top: 10px; }
.timer-settings { display: flex; justify-content: center; align-items: center; gap: 8px; color: var(--text-muted); font-size: 0.9rem; }
.time-input { width: 70px; text-align: center; }

.note-input {
    width: 100%;
    height: 140px;
    resize: none;
    box-sizing: border-box;
}

.quote-text {
    font-style: italic;
    font-size: 1.1rem;
    line-height: 1.5;
    text-align: center;
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.quote-author {
    text-align: right;
    color: var(--primary);
    font-weight: 500;
    margin-bottom: 1rem;
}
