@import url("kanban.css");
@import url("task-card-actions.css");
@import url("task-card-enhancements.css");
@import url("kanban-fixes.css");
@import url("compact-task-cards.css");

.notes-section {
    background: linear-gradient(145deg, #fff9b8, #ffe264);
    border: 1px solid rgba(255, 230, 125, 0.95);
    border-radius: 18px;
    box-shadow: 8px 12px 0 rgba(149, 117, 18, 0.14), 0 20px 36px rgba(15, 23, 42, 0.14);
}

.note-card {
    border: 0;
    border-radius: 6px 16px 16px 16px;
    background: linear-gradient(145deg, #fff9b8, #ffe26f);
    box-shadow: 6px 10px 0 rgba(149, 117, 18, 0.14), 10px 16px 20px rgba(15, 23, 42, 0.14);
    transform: rotate(-1.2deg);
}

.home-panel {
    display: grid;
    grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
    gap: 20px;
}

.home-panel > .glass-nav,
.home-panel > .home-hero,
.home-panel > .quick-stats,
.home-panel > .workspace-grid {
    grid-column: 1 / -1;
}

.home-panel > .notes-section {
    grid-column: 1;
    position: sticky;
    top: 92px;
    margin-top: 4px;
    padding: 16px;
}

.home-panel > .board-card {
    grid-column: 2;
    min-width: 0;
    width: 100%;
    margin-top: 4px;
}

.home-panel > .notes-section .notes-list {
    max-height: 520px;
    overflow-y: auto;
    padding-right: 4px;
}

.notes-add-btn {
    width: 44px;
    min-width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 999px;
    font-size: 0;
}

.notes-add-btn::before {
    content: '+';
    font-size: 1.4rem;
}

@media (max-width: 1000px) {
    .home-panel {
        display: block;
    }

    .home-panel > .notes-section {
        position: static;
        margin-top: 24px;
    }

    .home-panel > .notes-section .notes-list {
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

@media (max-width: 760px) {
    .notes-section {
        padding: 14px;
        overflow: hidden;
    }

    .notes-list {
        min-width: 0;
        overflow: hidden;
    }

    .note-card {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        transform: none;
    }

    .note-card:nth-child(2n),
    .note-card.is-moving,
    .note-card:focus-within {
        transform: none;
    }

    .note-card-text,
    .note-task-chip {
        max-width: 100%;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .note-card-footer {
        align-items: stretch;
    }

    .note-move-select {
        flex-basis: 100%;
        width: 100%;
    }
}

.note-form-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin: 10px 0;
}

.note-task-select,
.note-move-select {
    min-height: 38px;
    border: 1px solid rgba(15, 23, 42, 0.14);
    border-radius: 999px;
    padding: 0 12px;
    background: rgba(255, 255, 255, 0.78);
    color: #0f172a;
}

.note-task-select {
    flex: 1 1 180px;
}

.note-color-input,
.note-card-color {
    width: 42px;
    height: 38px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    cursor: pointer;
}

.note-default-color-label {
    display: inline-flex;
    gap: 6px;
    align-items: center;
    font-size: 0.82rem;
    font-weight: 800;
    color: #7c5c00;
}

.note-card {
    position: relative;
    padding-top: 38px;
    background: linear-gradient(145deg, var(--note-color, #fff9b8), #ffffff66);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.note-card:nth-child(2n) {
    transform: rotate(1deg);
}

.note-card.is-pinned {
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.22), 6px 10px 0 rgba(149, 117, 18, 0.14), 10px 16px 20px rgba(15, 23, 42, 0.14);
}

.note-card.is-moving,
.note-card:focus-within {
    transform: translateY(-3px) rotate(0deg);
    box-shadow: 0 18px 32px rgba(15, 23, 42, 0.18);
}

.note-pin-btn {
    position: absolute;
    top: 8px;
    left: 10px;
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.7);
    cursor: pointer;
}

.note-card-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.note-move-select {
    flex: 1 1 160px;
    max-width: 100%;
}

.notes-delete-btn {
    border: 0;
    border-radius: 999px;
    min-width: 38px;
    min-height: 38px;
    background: #fee2e2;
    color: #991b1b;
    cursor: pointer;
    font-weight: 800;
}
