.task-nav {
    /*background-color: #ffffff;*/
    /*box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);*/
    padding: 0 var(--content-padding);
    height: var(--nav-height);
    display: flex;
    align-items: center;
    justify-content: center;
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1;
    --nav-item-height: 45px;
    background: var(--bg-color);
}

.task-nav  .task-nav-title {
    flex: 1;
    font-weight: bold;
}

.task-nav-search-wrapper {
    flex: 1;
    background: #ffffff;
    height: var(--nav-item-height);
    border-radius: 30px;
    border: 1px solid var(--text-color-0-8);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 15px;
    box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
}

.task-nav-search-wrapper input {
    flex: 1;
    border: none;
    background: none;
    outline: none;
    height: var(--nav-item-height);
}


.close-task-nav-btn {
    --size: calc(var(--nav-item-height) - 4px);
    height: var(--size);
    width: var(--size);
    margin-left: 4px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
}


.task-items-wrapper {
    padding: var(--content-padding);
}


.task-item {
    width: 100%;
    background: #ffffff;
    border-radius: 8px;

    --item-padding: 15px;

    border: 1px solid var(--text-color-1);

    overflow-y: hidden;


    /*transition: height 0.3s ease, opacity 0.3s ease;*/
}

.task-item:not(:last-child) {
    margin-bottom: 15px;
}

.task-item .task-head {
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--item-padding);
    border-bottom: 1px solid var(--text-color-0-8);

}

.task-item .task-head .task-date {
    font-size: 14px;
    color: var(--text-color-5);
}

.task-item .task-head .delete-task-btn {
    font-size: 14px;
    color: var(--text-color-5);
    cursor: pointer;
}

.task-item .task-content {
    padding: var(--item-padding);
}

.task-item .task-content .task-prompt {
    font-size: 14px;
    margin-bottom: 15px;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.task-error-msg {
    transition: opacity 0.3s ease;
}

.task-item .task-content .task-prompt i:first-child {
    font-size: inherit;
    margin-right: 8px;
    color: mediumpurple;
}

.task-item .task-content .task-prompt i:last-child {
    font-size: 12px;
    margin-left: 4px;
    color: var(--text-color-5);
}

.task-images-wrapper {
    width: 100%;
    gap: 2px;
    display: grid;
    /*一行2个*/
    grid-template-columns: repeat(2, 1fr); /* 一行2个 */
}

.task-images-wrapper-one {
    /*grid-template-columns: repeat(1, 1fr); !* 一行2个 *!*/
}

.task-images-wrapper .task-image-item {
    width: 100%;
    padding-top: 100%;
    background: var(--text-color-0-5);

    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;

    position: relative;
}

.task-images-wrapper .task-image-item .task-item-time-wrapper {
    display: none;
    font-size: 14px;

    align-items: center;
    justify-content: center;

    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
}


.task-images-wrapper .task-image-item .task-item-time-wrapper .task-item-time {
    font-size: inherit;
    color: var(--text-color-4);
    font-weight: lighter;
}




.task-images-wrapper.landscape .task-image-item {
    padding-top: 56.25%;
}

.task-images-wrapper.portrait .task-image-item {
    padding-top: 177%;
}


.task-generating-hint {
    padding: 16px 0;
    text-align: center;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    animation: fadeInOut 3s ease-in-out infinite;
}

.task-generating-hint * {
    font-size: inherit;
}


.task-generating-hint .loader-2 {
    --size: 15px;
    --border-size: 1px;
    margin-right: 10px;;
}


.task-item.is-generating .task-generating-hint {
    display: flex;
}

.task-item.is-generating .task-item-time-wrapper {
    display: flex
}

.task-item.is-generating .delete-task-btn {
    display: none;
}
/*.task-item.is-generating .task-image-item {*/
/*    !*animation: fadeInOut 3s ease-in-out infinite;*!*/
/*    background: var(--text-color-0-5);*/
/*}*/

.task-item.is-generating .task-image-item {
    /* 浅色调科技渐变，贴近白色，无突兀感 */
    background: linear-gradient(
        135deg,
        rgba(248, 251, 255, 0.5), /* 极浅蓝（贴近白色） */
        rgba(234, 244, 255, 0.5),
        rgba(215, 234, 255, 0.5),
        rgba(232, 229, 255, 0.5),
        rgba(212, 244, 255, 0.5) /* 淡青蓝 */
    );

    /* 放大渐变尺寸，为流动动画预留空间 */
    background-size: 300% 300%;
    /* 渐变流动动画：15秒循环，匀速流畅 */
    /*animation: techGradientMove 15s ease infinite;*/
    animation: techGradientMove 5s ease infinite;
    /* 轻微模糊，增强柔和科技感，可选删除 */
    filter: blur(0.5px);
    position: relative;
    overflow: hidden;
    /* 降低不透明度，更好与全局白色融合 */
    opacity: 0.95;
}


/* 伪元素：光点点缀（提升科技感，无额外DOM元素） */
.task-item.is-generating .task-image-item::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(
        circle at random(100%) random(100%),
        rgba(64, 128, 255, 0.2) 0%,
        transparent 50%
    ),
    radial-gradient(
        circle at random(100%) random(100%),
        rgba(123, 104, 238, 0.15) 0%,
        transparent 40%
    );
    animation: techLightTwinkle 8s ease-in-out infinite;
    pointer-events: none; /* 不遮挡鼠标点击等事件，关键优化 */
}


/* 渐变流动核心动画：背景位置平移实现流动效果 */
@keyframes techGradientMove {
    0% {
        background-position: 0% 0%;
    }
    50% {
        background-position: 100% 100%;
    }
    100% {
        background-position: 0% 0%;
    }
}

/* 光点闪烁动画：透明度+缩放实现呼吸闪烁感 */
@keyframes techLightTwinkle {
    0%, 100% {
        opacity: 0.7;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}

.task-item .error-msg {
    color: var(--danger-color);
    font-size: 14px;
}


.task-item .retry-btn {
    width: 100%;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    border: 1px solid var(--text-color);
    margin-top: 10px;
    cursor: pointer;
    border-radius: 4px;
}



.task-item .retry-btn i {
    font-size: inherit;
    margin-right: 10px;
}

.task-item .retry-hint {
    margin-top: 10px;
    text-align: center;
    font-size: 12px;
    color: var(--text-color-3);
}


.task-preview-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    color: var(--text-color-2);

    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);

    font-size: 14px;
}


.task-preview-wrapper * {
    color: inherit;
    white-space: nowrap;
}

.task-preview-wrapper i {
    font-size: 36px;
    margin-bottom: 15px;
}

.task-board-loader {
    align-items: center;
    justify-content: center;
    padding: 20px 0;
    display: none;
}


.task-board-loader .loader-2 {
    --border-size: 1.5px;
    --size: 20px;
}


.confirm-pop {
    position: fixed;
    /*width: 100px;*/
    /*height: 100px;*/
    transform: scale(1);
    transition: transform 0.2s ease, opacity 0.2s ease;
    transform-origin: top right;
    background: #fff;
    box-shadow: rgba(0, 0, 0, 0.35) 0px 5px 15px;
    border: 1px solid var(--text-color-0-5);
    border-radius: 8px 0 8px 8px;
    padding: 10px 20px;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.confirm-pop .text {
    margin-bottom: 10px;
    font-size: 15px;
}


.confirm-pop .btn-group {
    display: flex;
    align-items: center;
    justify-content: center;
}

.confirm-pop .btn-group button {
    border: none;
    outline: none;
    height: 30px;
    padding: 0 20px;
    cursor: pointer;
    border-radius: 4px;
}

.confirm-pop .btn-group button:not(:last-child) {
    margin-right: 8px;
}

.confirm-pop .btn-group button.confirm {
    background: var(--danger-color);
    color: #fff;
}



.task-item .returned-hint {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border: 1px dashed var(--danger-color);
    border-radius: 4px;
    margin-top: 20px;
    font-size: 14px;
    color: var(--danger-color);
}