/* =========================================================
   YOM-B-YOM TO DO LIST DASHBOARD STYLESHEET
   - Unified Typography (Space Grotesk matching Index)
   - Warm Coffee, Caramel & Cream Palette
   - Clean Sidebar, Pomodoro Timer, Progress & Tasks
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

:root {
    --brown-950: #2B1809;
    --brown-900: #3B241C;
    --brown-800: #4D2F25;
    --brown-700: #604033;
    --brown: #765043;
    --caramel: #B87333;
    --caramel-dark: #9D6040;

    --cream: var(--bg-main, #DEC8B0);
    --cream-dark: var(--bg-subtle, #D2BA9F);
    --card: var(--bg-card, #EAD8C4);
    --card-2: var(--bg-card-alt, #E0CEB9);

    --text: var(--text-primary, #2B1809);
    --muted: var(--text-muted, #6B4628);

    --green: #4E7C59;
    --green-light: #E0EDE3;

    --red: #C8615D;
    --red-light: #F6DDDD;

    --yellow: #C7924B;
    --yellow-light: #F4E6CC;

    --border: rgba(43, 24, 9, 0.18);

    --shadow: 0 10px 30px rgba(43, 24, 9, 0.12);
    --radius: 22px;

    /* Unified Website Typography */
    --font-title: "Space Grotesk", sans-serif;
    --font-body: "Space Grotesk", sans-serif;
}

/* Dark Mode Tokens */
body.dark-mode {
    --brown-950: #FFECC6;
    --brown-900: #EDCDAF;
    --cream: var(--bg-main, #140D07);
    --cream-dark: var(--bg-subtle, #1C130A);
    --card: var(--bg-card, #22170D);
    --card-2: var(--bg-card-alt, #2D1F12);
    --text: var(--text-primary, #FFECC6);
    --muted: var(--text-muted, #CFB595);
    --border: rgba(255, 236, 198, 0.15);
    --shadow: 0 12px 32px rgba(0, 0, 0, 0.55);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background:
        radial-gradient(circle at 90% 0%, #e6c9b4 0, transparent 27%),
        var(--cream);
    color: var(--text);
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

button,
input,
textarea,
select {
    font-family: var(--font-body);
}

button {
    cursor: pointer;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-title);
    font-weight: 500;
    letter-spacing: 0.5px;
}

.dashboard {
    min-height: 100vh;
    display: flex;
    position: relative;
    width: 100%;
}


/* ================= MAIN CONTENT ================= */

.main-content {
    flex: 1;
    min-width: 0;
    width: calc(100% - 250px);
    margin-left: 250px;
    padding: 28px 32px 45px;
}

.top-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 26px;
}

.welcome-line {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
    color: var(--caramel-dark);
    font-family: var(--font-title);
    font-size: 20px;
    letter-spacing: 0.5px;
}

.welcome-line i {
    font-size: 18px;
}

.welcome h1 {
    font-family: var(--font-title);
    font-size: 32px;
    font-weight: 500;
    letter-spacing: 0.5px;
    color: var(--text);
}

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

.search-box {
    width: 250px;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 14px;
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: 14px;
    box-shadow: 0 6px 18px rgba(70, 45, 33, 0.05);
}

.search-box i {
    color: var(--caramel);
}

.search-box input {
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    color: var(--text);
    font-size: 13px;
    font-weight: 500;
}

.header-icon,
.profile-button {
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    background: var(--card);
    color: var(--brown);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: 0.2s;
}

.header-icon:hover {
    background: var(--cream-dark);
}

.profile-button {
    border: none;
    background: var(--brown);
    color: white;
}


/* ================= CARDS & STATS ================= */

.dashboard-card {
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.stats-grid {
    display: grid;
    grid-template-columns: 1.4fr 0.9fr 0.9fr 1.4fr;
    gap: 16px;
    margin-bottom: 22px;
}

.progress-card,
.small-stat,
.timer-card {
    min-height: 175px;
}

.progress-card {
    padding: 20px;
}

.card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.card-label {
    font-family: var(--font-title);
    font-size: 19px;
    letter-spacing: 0.5px;
    color: var(--text);
}

.card-top h3 {
    margin-top: 2px;
    font-size: 13px;
    color: var(--muted);
    font-family: var(--font-body);
}

.card-top-icon {
    color: var(--caramel);
    font-size: 18px;
}

.progress-content {
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 26px;
}

.progress-circle {
    width: 95px;
    height: 95px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: conic-gradient(var(--caramel) 0deg,
            var(--caramel) 0deg,
            #e7ddd6 0deg);
    position: relative;
}

.progress-circle::before {
    content: "";
    width: 75px;
    height: 75px;
    position: absolute;
    border-radius: 50%;
    background: var(--card);
}

.progress-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.progress-inner strong {
    font-family: var(--font-title);
    font-size: 24px;
    letter-spacing: 0.5px;
    color: var(--text);
}

.progress-inner span {
    margin-top: -3px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 600;
}

.progress-numbers {
    display: flex;
    flex-direction: column;
}

.progress-numbers strong {
    font-family: var(--font-title);
    font-size: 26px;
    letter-spacing: 0.5px;
    color: var(--text);
}

.progress-numbers span {
    margin-top: 2px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

/* Small Stats */
.small-stat {
    padding: 22px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.stat-icon {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    font-size: 19px;
}

.important-stat .stat-icon {
    background: var(--red-light);
    color: var(--red);
}

.due-stat .stat-icon {
    background: var(--green-light);
    color: var(--green);
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-info span {
    color: var(--muted);
    font-family: var(--font-title);
    font-size: 17px;
    letter-spacing: 0.4px;
}

.stat-info strong {
    font-family: var(--font-title);
    font-size: 28px;
    line-height: 1.1;
    color: var(--text);
}

.stat-info small {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

/* Timer */
.timer-card {
    padding: 20px;
}

.timer-display {
    margin: 8px 0 10px;
    text-align: center;
    font-family: var(--font-title);
    font-size: 40px;
    letter-spacing: 2px;
    color: var(--brown-950);
}

.timer-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

.timer-btn {
    padding: 7px 5px;
    border: none;
    border-radius: 10px;
    background: #eadfd8;
    color: var(--brown);
    font-family: var(--font-title);
    font-size: 14px;
    letter-spacing: 0.4px;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.timer-btn:hover {
    background: #ddcdc1;
}

.timer-btn.primary {
    background: var(--brown);
    color: white;
}

.timer-btn.primary:hover {
    background: var(--brown-700);
}


/* ================= MAIN GRID (TASKS & RIGHT COLUMN) ================= */

.main-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(320px, 1fr);
    gap: 20px;
}

.tasks-card {
    min-height: 570px;
    padding: 26px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 9px;
}

.section-title i {
    color: var(--caramel);
    font-size: 22px;
}

.section-title h2 {
    font-family: var(--font-title);
    font-size: 26px;
    letter-spacing: 0.5px;
    color: var(--text);
}

.section-header p {
    margin-top: 3px;
    color: var(--muted);
    font-size: 12.5px;
    font-weight: 500;
}

.add-task-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 18px;
    border: none;
    border-radius: 14px;
    background: var(--brown);
    color: white;
    font-family: var(--font-title);
    font-size: 17px;
    letter-spacing: 0.5px;
    transition: 0.25s ease;
}

.add-task-btn:hover {
    background: var(--brown-900);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(111, 78, 61, 0.2);
}

/* Tasks List */
.tasks-list {
    height: 465px;
    overflow-y: auto;
    padding-right: 6px;
}

.tasks-list::-webkit-scrollbar,
.notes-list::-webkit-scrollbar {
    width: 5px;
}

.tasks-list::-webkit-scrollbar-thumb,
.notes-list::-webkit-scrollbar-thumb {
    background: #d1b5a2;
    border-radius: 10px;
}

.task-item {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 14px 16px;
    margin-bottom: 10px;
    background: #fffdfb;
    border: 1.5px solid #eadbd0;
    border-radius: 16px;
    transition: 0.22s;
}

body.dark-mode .task-item {
    background: #34241b;
    border-color: #4a3328;
}

.task-item:hover {
    border-color: #cba58d;
    transform: translateY(-2px);
    box-shadow: 0 7px 20px rgba(75, 48, 35, 0.08);
}

.task-item.completed {
    background: #f3eee9;
    opacity: 0.85;
}

body.dark-mode .task-item.completed {
    background: #251b15;
}

.task-check {
    width: 22px;
    height: 22px;
    border: 2px solid var(--caramel);
    border-radius: 7px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: transparent;
    color: white;
    font-size: 12px;
    flex-shrink: 0;
    transition: 0.2s;
}

.task-item.completed .task-check {
    background: var(--green);
    border-color: var(--green);
}

.task-content {
    flex: 1;
    min-width: 0;
}

.task-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 3px;
}

.task-item.completed .task-title {
    text-decoration: line-through;
    color: var(--muted);
}

.task-description {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.4;
    margin-bottom: 5px;
}

.task-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.tag {
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 8px;
    text-transform: capitalize;
}

.tag-study {
    background: #e0ecf8;
    color: #356094;
}

.tag-work {
    background: #fbeee0;
    color: #9c5c24;
}

.tag-health {
    background: var(--green-light);
    color: var(--green);
}

.tag-personal {
    background: #f3e6f5;
    color: #7c3b88;
}

.tag-reading {
    background: var(--yellow-light);
    color: #8c6020;
}

.tag-important {
    background: var(--red-light);
    color: var(--red);
}

.tag-deadline {
    background: #eee5de;
    color: var(--brown);
}

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

.task-del-btn {
    background: transparent;
    border: none;
    color: var(--muted);
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: 0.2s;
}

.task-del-btn:hover {
    color: var(--red);
    background: var(--red-light);
}


/* ================= RIGHT COLUMN (CALENDAR, NOTES, MOTIVATION) ================= */

.right-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.calendar-card {
    padding: 22px;
}

.calendar-header {
    margin-bottom: 12px;
}

.calendar-header p {
    font-size: 13px;
    color: var(--caramel-dark);
    font-weight: 600;
}

.calendar-controls button {
    width: 32px;
    height: 32px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--card);
    color: var(--text);
    font-size: 14px;
    transition: 0.2s;
}

.calendar-controls button:hover {
    background: var(--cream-dark);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    margin-bottom: 8px;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    text-align: center;
}

.cal-day {
    padding: 7px 0;
    font-size: 12px;
    font-weight: 600;
    border-radius: 8px;
    color: var(--text);
    cursor: pointer;
    transition: 0.2s;
}

.cal-day:hover {
    background: var(--cream-dark);
}

.cal-day.today {
    background: var(--caramel);
    color: white;
    font-weight: 700;
}

.cal-day.empty {
    cursor: default;
}

/* Notes Card */
.notes-card {
    padding: 22px;
}

.add-note-btn {
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 10px;
    background: var(--brown);
    color: white;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
}

.add-note-btn:hover {
    background: var(--brown-900);
}

.notes-list {
    max-height: 180px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.note-item {
    background: #fffdfb;
    border: 1.5px solid #eadbd0;
    border-radius: 12px;
    padding: 10px 14px;
    font-size: 12.5px;
    color: var(--text);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

body.dark-mode .note-item {
    background: #34241b;
    border-color: #4a3328;
}

.note-item input {
    background: transparent;
    border: none;
    outline: none;
    color: var(--text);
    font-size: 12.5px;
    width: 85%;
}

.note-del-btn {
    background: transparent;
    border: none;
    color: var(--muted);
    font-size: 14px;
    cursor: pointer;
}

.note-del-btn:hover {
    color: var(--red);
}

/* Motivation Card */
.motivation-card {
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #FFF8F0, #F4E7DB);
    border: 1.5px solid var(--border);
}

body.dark-mode .motivation-card {
    background: linear-gradient(135deg, #3D2820, #2A1A15);
}

.motivation-icon {
    font-size: 24px;
    color: var(--caramel);
}

.motivation-card span {
    font-family: var(--font-title);
    font-size: 15px;
    color: var(--caramel-dark);
}

.motivation-card p {
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    margin: 2px 0 0;
}

.motivation-card button {
    margin-left: auto;
    background: transparent;
    border: none;
    color: var(--brown);
    font-size: 18px;
    cursor: pointer;
    transition: transform 0.3s;
}

.motivation-card button:hover {
    transform: rotate(180deg);
}

/* ================= CALENDAR ================= */

.calendar-card {
    padding: 22px;
}

.calendar-header {
    margin-bottom: 12px;
}

.calendar-header p {
    font-size: 13px;
    color: var(--caramel-dark);
    font-weight: 600;
}

.calendar-controls {
    display: flex;
    gap: 6px;
}

.calendar-controls button {
    width: 32px;
    height: 32px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--card);
    color: var(--text);
    font-size: 14px;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-controls button:hover {
    background: var(--cream-dark);
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
    margin-bottom: 8px;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    text-align: center;
}

.calendar-day {
    height: 34px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 12px;
    font-weight: 600;
    color: var(--text);

    border-radius: 8px;
    cursor: pointer;

    transition: 0.2s ease;
}

.calendar-day:not(.empty):hover {
    background: var(--cream-dark);
}

.calendar-day.today {
    background: var(--caramel);
    color: white;
    font-weight: 700;
}

.calendar-day.empty {
    cursor: default;
    pointer-events: none;
}

/* Task Deadline */

.calendar-day.has-task::after {
    content: "";
    position: absolute;

    width: 17px;
    height: 3px;

    left: 50%;
    bottom: 2px;

    transform: translateX(-50%);

    background: var(--brown);
    border-radius: 10px;
}

.calendar-day.today.has-task::after {
    background: white;
}


/* ================= MODAL ================= */

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(45, 27, 21, 0.65);
    backdrop-filter: blur(6px);
}

.modal.show {
    display: flex;
}

.modal-content {
    width: 100%;
    max-width: 500px;
    padding: 28px;
    background: var(--card);
    border: 1.5px solid var(--border);
    border-radius: 24px;
    box-shadow: 0 25px 60px rgba(35, 20, 14, 0.3);
}

.modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 22px;
}

.modal-header span {
    color: var(--caramel-dark);
    font-family: var(--font-title);
    font-size: 16px;
}

.modal-header h2 {
    font-family: var(--font-title);
    font-size: 28px;
    letter-spacing: 0.5px;
    color: var(--text);
}

.modal-header button {
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 10px;
    background: #eaded5;
    color: var(--brown);
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 15px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.form-group label {
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    outline: none;
    background: #fffdfb;
    color: var(--text);
    font-family: var(--font-body);
    font-size: 13px;
    transition: 0.2s;
}

body.dark-mode .form-group input,
body.dark-mode .form-group select,
body.dark-mode .form-group textarea {
    background: #34241b;
}

.form-group textarea {
    min-height: 80px;
    resize: vertical;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--caramel);
    box-shadow: 0 0 0 3px rgba(185, 121, 80, 0.12);
}

.save-task-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 14px;
    background: var(--brown);
    color: white;
    font-family: var(--font-title);
    font-size: 20px;
    letter-spacing: 0.6px;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: 0.2s;
}

.save-task-btn:hover {
    background: var(--brown-900);
}

/* =========================
   NOTES
========================= */

.notes-card {
    overflow: hidden;
}

.notes-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.add-note-btn {
    width: 36px;
    height: 36px;

    border: 1px solid var(--border);
    border-radius: 11px;

    background: var(--card-2);
    color: var(--brown-700);

    display: flex;
    align-items: center;
    justify-content: center;

    cursor: pointer;
    transition: 0.2s ease;
}

.add-note-btn:hover {
    background: var(--cream-dark);
}


/* Note Card */

.note-card {
    position: relative;

    min-height: 115px;

    padding: 15px;

    border: 1px solid var(--border);
    border-radius: 16px;

    background: var(--card-2);

    display: flex;
    flex-direction: column;

    overflow: hidden;
}

.note-card::before {
    content: "";

    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;

    width: 4px;

    background: var(--caramel);
}

.note-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 10px;
}

.note-card-title {
    margin: 0;

    font-size: 14px;
    font-weight: 700;

    color: var(--text);

    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.note-delete-btn {
    flex-shrink: 0;

    width: 27px;
    height: 27px;

    border: none;
    border-radius: 8px;

    background: transparent;
    color: var(--muted);

    cursor: pointer;

    display: flex;
    align-items: center;
    justify-content: center;

    transition: 0.2s ease;
}

.note-delete-btn:hover {
    background: var(--red-light);
    color: var(--red);
}

.note-card-text {
    margin: 10px 0 0;

    font-size: 12px;
    line-height: 1.6;

    color: var(--muted);

    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;

    overflow: hidden;
}

.note-card-date {
    margin-top: auto;
    padding-top: 10px;

    font-size: 10px;
    color: var(--muted);
}


/* Empty Notes */

.empty-notes {
    grid-column: 1 / -1;

    min-height: 150px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;

    border: 1px dashed var(--border);
    border-radius: 16px;

    color: var(--muted);
}

.empty-notes i {
    font-size: 28px;
    margin-bottom: 8px;
    color: var(--caramel);
}

.empty-notes p {
    margin: 0;
    font-size: 12px;
}

.empty-notes span {
    margin-top: 4px;
    font-size: 10px;
}


/* =========================
   NOTE MODAL
========================= */

.note-modal {
    position: fixed;
    inset: 0;

    background: rgba(45, 27, 21, 0.45);

    display: none;
    align-items: center;
    justify-content: center;

    padding: 20px;

    z-index: 2000;
}

.note-modal.show {
    display: flex;
}

.note-modal-content {
    width: min(480px, 100%);

    padding: 24px;

    background: var(--card);

    border: 1px solid var(--border);
    border-radius: 22px;

    box-shadow: var(--shadow);
}

.note-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 15px;

    margin-bottom: 20px;
}

.note-modal-header h3 {
    margin: 0;

    color: var(--text);

    font-size: 20px;
}

.note-modal-header p {
    margin: 4px 0 0;

    color: var(--muted);

    font-size: 11px;
}

.close-note-btn {
    width: 34px;
    height: 34px;

    border: none;
    border-radius: 10px;

    background: var(--card-2);
    color: var(--muted);

    cursor: pointer;
}

.note-title-input,
.note-text-input {
    width: 100%;

    border: 1px solid var(--border);
    border-radius: 12px;

    background: var(--card-2);
    color: var(--text);

    outline: none;

    font-family: var(--font-body);

    box-sizing: border-box;
}

.note-title-input {
    height: 45px;

    padding: 0 13px;

    margin-bottom: 10px;

    font-size: 13px;
    font-weight: 600;
}

.note-text-input {
    min-height: 140px;

    padding: 13px;

    resize: vertical;

    font-size: 12px;
    line-height: 1.6;
}

.note-title-input:focus,
.note-text-input:focus {
    border-color: var(--caramel);
}

.note-modal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: 14px;
}

#noteCounter {
    font-size: 10px;
    color: var(--muted);
}

.save-note-btn {
    height: 38px;

    padding: 0 16px;

    border: none;
    border-radius: 11px;

    background: var(--caramel);
    color: white;

    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 600;

    cursor: pointer;

    display: flex;
    align-items: center;
    gap: 7px;
}


/* =========================
   NOTES RESPONSIVE
========================= */

@media (max-width: 560px) {

    .notes-list {
        grid-template-columns: 1fr;
    }

    .note-modal {
        padding: 14px;
    }

    .note-modal-content {
        padding: 20px;
    }
}
/* =========================================================
   RESPONSIVE
========================================================= */


/* =========================
   TABLET / SMALL LAPTOP
   <= 1150px
========================= */

@media (max-width: 1150px) {

    /* Stats */
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .stats-grid>* {
        min-width: 0;
        width: 100%;
    }

    /* Main content */
    .main-grid {
        grid-template-columns: 1fr;
    }

    /* Right side cards */
    .right-column {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }

    .motivation-card {
        grid-column: 1 / -1;
    }

    /* Calendar */
    .calendar-day {
        height: 36px;
    }
}


/* =========================
   TABLET
   <= 850px
========================= */

@media (max-width: 850px) {

    /* ---------- Main ---------- */

    .main-content {
        width: auto;
        margin-left: 0;
        padding: 20px 16px;
        min-width: 0;
    }


    /* ---------- Header ---------- */

    .top-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 16px;
    }

    .header-actions {
        width: 100%;
        min-width: 0;
    }

    .search-box {
        flex: 1;
        min-width: 0;
    }


    /* ---------- Stats ---------- */

    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

    .stats-grid>* {
        min-width: 0;
        width: 100%;
    }


    /* ---------- Main Grid ---------- */

    .main-grid {
        grid-template-columns: 1fr;
    }

    .right-column {
        grid-template-columns: 1fr;
    }

    .motivation-card {
        grid-column: auto;
    }


    /* ---------- Calendar ---------- */

    .calendar-card {
        min-width: 0;
    }

    .calendar-days {
        gap: 4px;
    }

    .calendar-day {
        height: 36px;
    }
}


/* =========================
   MOBILE
   <= 560px
========================= */

@media (max-width: 560px) {

    /* ---------- Main ---------- */

    .main-content {
        width: 100%;
        margin-left: 0;
        padding: 16px 12px 25px;
        min-width: 0;
    }


    /* ---------- Header ---------- */

    .top-header {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
    }

    .welcome {
        min-width: 0;
    }

    .welcome h1 {
        font-size: 26px;
    }

    .header-actions {
        width: 100%;
        display: grid;
        grid-template-columns: minmax(0, 1fr) 40px 40px;
        gap: 7px;
    }

    .search-box {
        width: 100%;
        min-width: 0;
    }


    /* ---------- Stats ---------- */

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .stats-grid>* {
        width: 100%;
        min-width: 0;
    }


    /* ---------- Main Grid ---------- */

    .main-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .right-column {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }


    /* ---------- Tasks ---------- */

    .tasks-card {
        width: 100%;
        min-width: 0;
        padding: 18px 14px;
    }


    /* ---------- Calendar ---------- */

    .calendar-card {
        width: 100%;
        min-width: 0;
        padding: 18px 14px;
    }

    .calendar-header {
        gap: 10px;
    }

    .calendar-weekdays {
        font-size: 10px;
    }

    .calendar-days {
        gap: 3px;
    }

    .calendar-day {
        height: 38px;
        font-size: 12px;
    }

    /* Deadline underline */
    .calendar-day.has-task::after {
        width: 16px;
        height: 3px;
        bottom: 4px;
    }


    /* ---------- Forms ---------- */

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
}


/* =========================
   VERY SMALL PHONES
   <= 380px
========================= */

@media (max-width: 380px) {

    .main-content {
        padding-left: 10px;
        padding-right: 10px;
    }

    .calendar-day {
        height: 34px;
        font-size: 11px;
    }

    .calendar-day.has-task::after {
        width: 14px;
        height: 3px;
    }

    .welcome h1 {
        font-size: 23px;
    }
}