.task-detail {
    display: flex;
    flex-direction: column;
    margin: 0 -10px 30px;
    .task-info {
        flex: 1;
        display: flex;
        flex-direction: column;
        position: relative;
        .head {
            display: flex;
            align-items: center;
            height: 40px;
            padding-bottom: 10px;
            color: #888888;
            position: relative;
            &:before {
                content: "";
                position: absolute;
                left: 36px;
                right: 0;
                bottom: 0;
                height: 1px;
                background-color: #f4f5f5;
            }
            .icon {
                width: 18px;
                font-size: 18px;
                cursor: pointer;
                &.completed {
                    color: #87d068;
                }
            }
            .nav {
                flex: 1;
                display: flex;
                align-items: center;
                padding-left: 18px;
                font-size: 12px;
                > p {
                    display: flex;
                    align-items: center;
                    padding-right: 5px;
                    &:after {
                        content: "/";
                        padding-left: 5px;
                    }
                    &:last-child {
                        &:after {
                            display: none;
                        }
                    }
                }
            }
            .menu {
                font-size: 22px;
                margin: 0 32px;
                cursor: pointer;
            }
        }
        .scroller {
            margin-left: 36px;
            padding-right: 36px;
            overflow-x: hidden;
            overflow-y: auto;
            .title {
                margin-top: 18px;
                .ivu-input {
                    font-weight: 500;
                    font-size: 24px;
                    padding: 4px 0;
                    line-height: 1.4;
                    resize: none;
                    border-color: transparent;
                    &:focus {
                        box-shadow: none
                    }
                }
            }
            .desc {
                margin-top: 10px;
                div[contenteditable="true"] {
                    outline: none
                }
                .mce-content-body[data-mce-placeholder]:not(.mce-visualblocks)::before {
                    color: #bbbbbb;
                }
            }
            .items {
                margin-top: 12px;
                .ivu-form-item {
                    margin-bottom: 10px;
                }
                .item-label {
                    display: flex;
                    align-items: center;
                    color: #bbbbbb;
                    .iconfont {
                        margin-right: 4px;
                    }
                }
                .item-content {
                    margin-top: 5px;
                    margin-left: 12px;
                    > li {
                        display: flex;
                        align-items: center;
                        list-style: none;
                        line-height: 26px;
                        .el-dropdown {
                            display: flex;
                            cursor: pointer;
                        }
                        .picker-time {
                            display: flex;
                            align-items: center;
                            line-height: 26px;
                            .time {
                                cursor: pointer;
                            }
                            .ivu-tag {
                                margin-left: 10px;
                                padding: 0 4px;
                                height: 20px;
                                line-height: 18px;
                                .ivu-tag-text {
                                    display: flex;
                                    align-items: center;
                                    > i {
                                        padding-right: 2px;
                                    }
                                }
                            }
                        }
                    }
                    &.user {
                        margin-top: 1px;
                        cursor: pointer;
                        .user-list {
                            > div {
                                display: inline-block;
                                margin-right: 6px;
                            }
                        }
                    }
                    &.file {
                        margin-bottom: -3px;
                        > li {
                            margin-bottom: 2px;
                            .file-load {
                                margin: 0;
                                padding: 2px;
                                width: 16px;
                                height: 16px;
                            }
                            .file-ext {
                                width: 16px;
                            }
                            .file-name {
                                color: #515a6e;
                                padding-left: 8px;
                                overflow: hidden;
                                text-overflow: ellipsis;
                                white-space: nowrap;
                                &:hover {
                                    color: #2d8cf0;
                                }
                            }
                            .file-size {
                                flex-shrink: 0;
                                padding-left: 10px;
                                height: 24px;
                                font-size: 12px;
                                color: #bbbbbb;
                            }
                        }
                    }
                    &.subtask {
                        > li {
                            align-items: flex-start;
                            margin-bottom: 4px;
                            &:last-child {
                                margin-bottom: -6px;
                            }
                            .subtask-icon {
                                width: 16px;
                                height: 26px;
                                line-height: 26px;
                                margin-right: 6px;
                                cursor: pointer;
                                .loading {
                                    width: 16px;
                                    height: 16px;
                                    margin: 0;
                                    padding: 2px;
                                }
                                .ivu-icon {
                                    font-size: 16px;
                                    color: #cccccc;
                                    &.completed {
                                        color: #87d068;
                                    }
                                }
                                &.sub-icon {
                                    font-size: 16px;
                                    width: 16px;
                                    height: 16px;
                                    margin-left: -20px;
                                    margin-right: 4px;
                                    color: #cfcfcf;
                                    transition: transform 0.2s;
                                    &.active {
                                        transform: rotate(90deg);
                                    }
                                }
                            }
                            .subtask-name {
                                flex: 1;
                                margin-right: 16px;
                                display: flex;
                                .ivu-input {
                                    margin: -2px 0;
                                    padding: 4px 0;
                                    resize: none;
                                    border-color: transparent;
                                    line-height: 20px;
                                    &:focus {
                                        box-shadow: none
                                    }
                                }
                            }
                            .subtask-time {
                                margin-right: 8px;
                                .time {
                                    overflow: hidden;
                                    text-overflow: ellipsis;
                                    white-space: nowrap;
                                    font-size: 13px;
                                    height: 26px;
                                    line-height: 26px;
                                    cursor: pointer;
                                    &.overdue {
                                        font-weight: 600;
                                        color: #ed4014;
                                    }
                                    &.today {
                                        font-weight: 500;
                                        color: #ff9900;
                                    }
                                }
                            }
                            .subtask-avatar {
                                height: 26px;
                                line-height: 26px;
                                margin-top: -2px;
                                cursor: pointer;
                            }
                            .ivu-icon-ios-loading {
                                animation: icon-loading-load 0.6s infinite linear;
                            }
                        }
                    }
                    &.nosub {
                        margin-top: 0;
                        > li {
                            .add-input,
                            .add-button {
                                margin-top: -2px;
                            }
                        }
                    }
                }
            }
            .add {
                margin-top: 12px;
                margin-bottom: 10px;
            }
            .add-input {
                margin-top: 6px;
            }
            .add-button {
                cursor: pointer;
                color: #bbbbbb;
                display: flex;
                align-items: center;
                margin-top: 6px;
                height: 32px;
                > i {
                    font-size: 14px;
                    padding-right: 8px;
                }
                > em {
                    font-style: normal;
                    padding-left: 4px;
                    &:after {
                        content: "/";
                        padding-left: 4px;
                    }
                    &:last-child {
                        &:after {
                            display: none;
                        }
                    }
                }
                &:hover {
                    color: #999999;
                }
            }
        }
        .upload {
            display: none;
        }
    }
    .task-dialog {
        flex: 1;
        display: flex;
        flex-direction: column;
        margin-top: 22px;
        position: relative;
        .head {
            display: flex;
            align-items: center;
            height: 40px;
            padding-bottom: 10px;
            color: #888888;
            position: relative;
            &:before {
                content: "";
                position: absolute;
                left: 36px;
                right: 0;
                bottom: 0;
                height: 1px;
                background-color: #f4f5f5;
            }
            .icon {
                width: 18px;
                font-size: 18px;
            }
            .nav {
                flex: 1;
                display: flex;
                align-items: center;
                padding-left: 18px;
                font-weight: 500;
                color: #666666;
                > p {
                    display: flex;
                    align-items: center;
                    margin-right: 24px;
                    cursor: pointer;
                    &.active {
                        margin-top: -2px;
                        font-size: 16px;
                        font-weight: 600;
                        color: #555555;
                        cursor: default;
                    }
                }
            }
        }
        .no-dialog {
            flex: 1;
            display: flex;
            flex-direction: column;
            .no-tip {
                flex: 1;
                display: none;
                margin-left: 36px;
            }
            .no-input {
                margin: 32px 0 0 36px;
                background-color: #F4F5F7;
                padding: 10px 12px;
                border-radius: 10px;
                .ivu-input {
                    border: 0;
                    resize: none;
                    background-color: transparent;
                    &:focus {
                        box-shadow: none;
                    }
                }
            }
        }
        .project-log {
            margin-left: 36px;
            .logs-activity {
                padding: 22px 0 0;
                > li {
                    list-style: none;
                    padding-top: 0;
                    &.logs-loading,
                    &.logs-more,
                    &.logs-none {
                        height: 59px;
                        line-height: 59px;
                    }
                    &.logs-loading {
                        display: flex;
                        align-items: center;
                        .common-loading {
                            width: 22px;
                            height: 22px;
                            margin: 0;
                        }
                    }
                }
            }
        }
    }

    &.open-dialog {
        flex-direction: row;
        .task-info {
            overflow: auto;
            .head {
                .menu {
                    margin: 0 2px;
                }
            }
        }
        .task-dialog {
            margin: 0 0 0 18px;
            min-width: 320px;
            max-width: 450px;
            &:before {
                content: "";
                position: absolute;
                top: 0;
                left: 0;
                bottom: 0;
                width: 1px;
                background-color: #f4f5f5;
            }
            .head {
                &:before {
                    left: 18px;
                }
                .icon {
                    &:before {
                        display: none;
                    }
                }
                .nav {
                    padding-left: 0;
                    > p {
                        margin-right: 28px;
                        &.active {
                            font-size: 18px;
                        }
                    }
                }
            }
            .no-dialog {
                .no-tip {
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    margin-left: 18px;
                    color: #999999;
                }
                .no-input {
                    margin: 0 0 0 18px;
                }
            }
            .dialog-wrapper {
                z-index: 0;
                .dialog-footer {
                    margin-bottom: 0;
                }
            }
            .project-log {
                position: absolute;
                top: 40px;
                left: 0;
                right: 0;
                bottom: 0;
                z-index: 1;
                padding: 8px 8px;
                margin-left: 8px;
                background-color: #ffffff;
                overflow: auto;
            }
        }
    }

    &.completed {
        .task-info {
            &:before {
                content: "\f373";
                font-family: Ionicons, serif;
                pointer-events: none;
                position: absolute;
                top: 0;
                right: 13%;
                font-size: 72px;
                color: #19be6b;
                opacity: .2;
                z-index: 1;
            }
        }
    }
}

.task-detail-avatar-buttons {
    margin-top: 12px;
    margin-bottom: 4px;
    text-align: right;
    position: absolute;
    top: 5px;
    right: 14px;
    > button {
        font-size: 12px;
        transform: scale(0.9);
    }
}
