.tasks-page {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 24px 22px 30px;
    color: #1f2f46;
}

.tasks-tabs {
    display: flex;
    gap: 18px;
    border-bottom: 1px solid #dfe7f3;
    padding-bottom: 8px;
}

.tasks-tab {
    border: none;
    background: transparent;
    padding: 0 0 8px;
    color: #445674;
    font-size: 14px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
}

.tasks-tab.active {
    color: #2d72f7;
    border-bottom-color: #2d72f7;
}

.tasks-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.tasks-create-btn,
.tasks-card-btn,
.tasks-empty-link {
    height: 40px;
    padding: 0 14px;
    border: none;
    border-radius: 8px;
    background: #16a34a;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
}

.tasks-segmented {
    display: inline-flex;
    border: 1px solid #cad5e6;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.tasks-segmented button {
    height: 40px;
    padding: 0 16px;
    border: none;
    background: #fff;
    color: #1d2c42;
    font-size: 14px;
    cursor: pointer;
}

.tasks-segmented button.active {
    background: #f2f6fc;
}

.tasks-select {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #cad5e6;
    border-radius: 8px;
    background: #fff;
    color: #1d2c42;
    font-size: 14px;
}

.tasks-select select {
    border: none;
    background: transparent;
    outline: none;
    color: #1d2c42;
    font-size: 14px;
}

.tasks-notif-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 40px;
    padding: 0 14px;
    border: 1.5px solid #cad5e6;
    border-radius: 8px;
    background: #fff;
    color: #64748b;
    font-size: 14px;
    cursor: pointer;
    margin-left: auto;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.tasks-notif-btn:hover {
    border-color: #93afd4;
    color: #1d2c42;
}

.tasks-notif-btn.active {
    background: #eff6ff;
    border-color: #3b82f6;
    color: #1d4ed8;
}

.tasks-notif-btn svg {
    flex-shrink: 0;
}

.tasks-body {
    min-height: 440px;
}

.tasks-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 440px;
    text-align: center;
}

.tasks-empty-illustration {
    font-size: 52px;
    color: #2d72f7;
}

.tasks-empty-state h2 {
    margin: 0;
    font-size: 32px;
}

.tasks-empty-state p {
    margin: 0;
    max-width: 760px;
    color: #60708a;
    line-height: 1.6;
}

.tasks-empty-link {
    background: transparent;
    color: #2d72f7;
    padding: 0;
    height: auto;
}

.tasks-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tasks-group {
    max-width: 666px;
    margin: 0 auto 28px;
}

.tasks-group h2 {
    margin: 0 0 12px;
    color: #334155;
    font-size: 17px;
    font-weight: 700;
}

.tasks-group-overdue h2 {
    color: #ef2424;
}

.tasks-card {
    position: relative;
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 10px;
    min-height: 80px;
    padding: 12px 14px 12px 10px;
    border: 1px solid #cfd6e2;
    border-radius: 3px;
    background: #fff;
}

.tasks-card.is-overdue {
    border-color: #f0b4b4;
}

.tasks-card-check {
    padding-top: 1px;
}

.tasks-card-check input {
    width: 13px;
    height: 13px;
}

.tasks-card-main {
    min-width: 0;
}

.tasks-card-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.tasks-title-link {
    border: none;
    background: transparent;
    padding: 0;
    color: #111827;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    text-align: left;
}

.tasks-title-link:hover {
    color: #2563eb;
    text-decoration: underline;
}

.tasks-due {
    color: #111827;
    font-size: 12px;
    white-space: nowrap;
}

.tasks-due.is-overdue {
    color: #ef2424;
}

.tasks-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 110px;
    height: 28px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.tasks-status-badge.is-progress {
    background: #eef5ff;
    color: #2d72f7;
}

.tasks-status-badge.is-done {
    background: #e8f6ee;
    color: #13824b;
}

.tasks-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 7px;
    color: #60708a;
    font-size: 12px;
}

.tasks-order-link {
    border: none;
    background: transparent;
    padding: 0;
    color: #2563eb;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.tasks-order-link:hover {
    text-decoration: underline;
}

.tasks-card-description {
    margin: 6px 0 0;
    color: #33465f;
    font-size: 12px;
    line-height: 1.4;
}

.tasks-card-description a {
    color: #2563eb;
    font-weight: 600;
    text-decoration: none;
}

.tasks-card-description a:hover {
    text-decoration: underline;
}

.tasks-card-actions {
    margin-top: 14px;
}

.task-create-drawer-root {
    position: fixed;
    inset: 0;
    z-index: 3000;
    pointer-events: none;
}

.task-create-drawer-root.show {
    pointer-events: auto;
}

.task-create-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.48);
}

.task-create-drawer {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    width: min(460px, 100vw);
    height: 100%;
    background: #fff;
    box-shadow: -18px 0 40px rgba(15, 23, 42, 0.18);
}

.task-create-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 54px;
    padding: 0 16px;
    border-bottom: 1px solid #e1e7f0;
}

.task-create-head h2 {
    margin: 0;
    color: #4b5563;
    font-size: 22px;
    font-weight: 500;
}

.task-create-close {
    width: 34px;
    height: 34px;
    border: none;
    background: transparent;
    color: #8a95a5;
    font-size: 24px;
    cursor: pointer;
}

.task-create-body {
    flex: 1;
    padding: 18px 16px;
    overflow: auto;
}

.task-create-field {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 18px;
}

.task-create-field span,
.task-create-section-title {
    color: #3f4d63;
    font-size: 13px;
    font-weight: 600;
}

.task-create-field b,
.task-create-section-title b {
    color: #e23c46;
}

.task-create-field small {
    position: absolute;
    top: 0;
    right: 0;
    color: #8a95a5;
    font-size: 12px;
}

.task-create-field input,
.task-create-field textarea,
.task-create-person input,
.task-create-person select {
    width: 100%;
    border: 1px solid #cfd7e4;
    outline: none;
    font: inherit;
}

.task-create-field input {
    height: 34px;
    padding: 0 8px;
}

.task-create-field textarea {
    min-height: 70px;
    padding: 10px 12px;
    resize: vertical;
}

.task-create-date-field input {
    width: 174px;
}

.task-create-field input:focus,
.task-create-field textarea:focus,
.task-create-person input:focus,
.task-create-person select:focus {
    border-color: #2d72f7;
    box-shadow: 0 0 0 3px rgba(45, 114, 247, 0.12);
}

.task-create-assignee {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.task-create-person {
    display: flex;
    align-items: center;
    gap: 10px;
}

.task-create-people {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.task-create-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f4bd33;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.task-create-person input {
    max-width: 220px;
    height: 32px;
    border-color: transparent;
    padding: 0 6px;
}

.task-create-person select {
    max-width: 260px;
    height: 34px;
    padding: 0 34px 0 10px;
    border-color: transparent;
    border-radius: 6px;
    background: #fff;
    color: #1f2f46;
    cursor: pointer;
}

.task-create-person select:hover {
    border-color: #d7e0ed;
    background: #f8fafc;
}

.task-create-remove-person {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: #8a95a5;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
}

.task-create-remove-person:hover {
    background: #eef3fa;
    color: #334155;
}

.task-create-add-person {
    align-self: flex-start;
    border: none;
    background: transparent;
    color: #2563eb;
    padding: 0;
    font-size: 13px;
    cursor: pointer;
}

.task-create-footer {
    display: flex;
    align-items: center;
    min-height: 64px;
    padding: 0 16px;
    border-top: 1px solid #dfe7f3;
    background: #eef4fd;
}

.task-create-footer button {
    height: 36px;
    padding: 0 18px;
    border: none;
    border-radius: 3px;
    background: #1f7ae0;
    color: #fff;
    font-size: 13px;
    cursor: pointer;
}

.task-complete-check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    color: #334155;
    font-size: 14px;
    cursor: pointer;
}

.task-complete-check input {
    width: 15px;
    height: 15px;
}

@media (max-width: 760px) {
    .tasks-page {
        padding: 18px 14px 24px;
    }

    .tasks-toolbar {
        align-items: stretch;
    }

    .tasks-segmented {
        display: grid;
        grid-template-columns: 1fr;
    }
}
