// 文档提醒对话框样式
.document-reminder-dialog {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 12px;
    background: var(--b3-theme-background);
}

.doc-reminder-header {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--b3-border-color);
}

.doc-reminder-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;

    @media (max-width: 600px) {
        flex-direction: column;
        gap: 8px;
    }
}

.doc-reminder-filters {
    display: flex;
    gap: 8px;
    align-items: center;

    .b3-select {
        min-width: 100px;
    }

    @media (max-width: 600px) {
        flex-wrap: wrap;
    }
}

.doc-sort-order-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;

    .b3-button__icon {
        width: 14px;
        height: 14px;
    }

    span {
        font-size: 12px;
    }
}

.doc-reminder-search {
    .doc-search-input {
        min-width: 200px;

        @media (max-width: 600px) {
            min-width: 150px;
        }
    }
}

.doc-reminder-stats {
    .doc-reminder-count {
        font-size: 13px;
        color: var(--b3-theme-on-surface-light);
        display: flex;
        align-items: center;
        gap: 4px;

        &::before {
            content: "📊";
            font-size: 14px;
        }
    }
}

.doc-reminder-content {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.doc-reminders-container {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
}

.doc-reminder-loading,
.doc-reminder-empty,
.doc-reminder-error {
    text-align: center;
    color: var(--b3-theme-on-surface-light);
    padding: 40px 20px;
    font-style: italic;
}

.doc-reminder-error {
    color: var(--b3-theme-error);
}

// 文档提醒项样式
.doc-reminder-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
    margin-bottom: 8px;
    border: 1px solid var(--b3-theme-surface-lighter);
    border-radius: 8px;
    background: var(--b3-theme-surface);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;

    &:hover {
        background: var(--b3-theme-surface-light);
        transform: translateY(-1px);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);

        &::before {
            transform: scaleY(1);
        }
    }

    // 过期状态
    &--overdue {
        border-color: var(--b3-theme-error-light);
        background: var(--b3-theme-error-lighter);
    }

    // 跨天事件状态
    &--spanning {
        border-left: 3px solid var(--b3-theme-primary);
    }

    // 复选框
    input[type="checkbox"] {
        margin: 4px 0 0 0;
        flex-shrink: 0;
    }

    // 手机端样式优化
    @media (max-width: 768px) {
        padding: 8px 12px;
        gap: 8px;
        margin-bottom: 6px;
        border-radius: 6px;

        input[type="checkbox"] {
            margin: 2px 0 0 0;
            transform: scale(0.9);
        }
    }
}

.doc-reminder-item__info {
    flex: 1;
    min-width: 0;
}

.doc-reminder-item__title {
    font-size: 14px;
    font-weight: 500;
    color: var(--b3-theme-on-background);
    margin-bottom: 6px;
    display: block;
    text-decoration: none;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.3;
    cursor: pointer;
    transition: color 0.2s ease;

    &:hover {
        color: var(--b3-theme-primary);
        text-decoration: underline;
    }

    @media (max-width: 768px) {
        font-size: 13px;
        margin-bottom: 4px;
        line-height: 1.2;
    }
}

.doc-reminder-item__time {
    font-size: 12px;
    color: var(--b3-theme-on-surface-light);
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;

    @media (max-width: 768px) {
        font-size: 11px;
        margin-bottom: 3px;
        gap: 6px;
    }
}

.doc-reminder-repeat-icon {
    font-size: 11px;
    opacity: 0.7;
    cursor: help;
}

.doc-reminder-priority-label {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-size: 10px;
    padding: 1px 4px;
    border-radius: 2px;
    font-weight: 500;

    &.high {
        background-color: rgba(231, 76, 60, 0.1);
        color: #e74c3c;
    }

    &.medium {
        background-color: rgba(243, 156, 18, 0.1);
        color: #f39c12;
    }

    &.low {
        background-color: rgba(52, 152, 219, 0.1);
        color: #3498db;
    }

    .priority-dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        flex-shrink: 0;

        &.high {
            background-color: #e74c3c;
        }

        &.medium {
            background-color: #f39c12;
        }

        &.low {
            background-color: #3498db;
        }
    }
}

.doc-reminder-overdue-label {
    color: var(--b3-theme-error);
    font-weight: 500;
    font-size: 10px;
    padding: 1px 4px;
    background: var(--b3-theme-error-lighter);
    border-radius: 2px;
}

.doc-reminder-category-tag {
    // 样式已在创建元素时内联定义
}

.doc-reminder-item__note {
    font-size: 12px;
    color: var(--b3-card-success-color);
    margin-top: 4px;
    padding: 4px 8px;
    background: var(--b3-card-success-background);
    border-radius: 4px;
    white-space: pre-wrap;
    word-break: break-word;
    border: 1px solid var(--b3-card-success-color);

    @media (max-width: 768px) {
        font-size: 11px;
        margin-top: 3px;
        padding: 3px 6px;
        border-radius: 3px;
    }
}

.doc-reminder-completed-time {
    font-size: 11px;
    color: var(--b3-theme-on-surface);
    opacity: 0.7;
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;

    @media (max-width: 768px) {
        font-size: 10px;
        margin-top: 3px;
        gap: 3px;
    }
}

.doc-reminder-item__actions {
    flex-shrink: 0;
    margin-left: 8px;

    .b3-button--small {
        padding: 4px 8px;
        font-size: 11px;
        border-radius: 4px;
        transition: all 0.2s ease;

        &:hover {
            transform: translateY(-1px);
            box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
        }
    }

    @media (max-width: 768px) {
        margin-left: 4px;

        .b3-button--small {
            padding: 3px 6px;
            font-size: 10px;
            border-radius: 3px;
        }
    }
}

// 优先级颜色样式 - 文档提醒项
.doc-reminder-priority-high {
    border-left: 4px solid var(--b3-card-error-color) !important;
    background-color: var(--b3-card-error-background) !important;
}

.doc-reminder-priority-high .doc-reminder-item__note {
    border: 2px solid var(--b3-card-error-color) !important;
    color: var(--b3-card-error-color) !important;
    background-color: transparent !important;
}

.doc-reminder-priority-medium {
    border-left: 4px solid var(--b3-card-warning-color) !important;
    background-color: var(--b3-card-warning-background) !important;
}

.doc-reminder-priority-medium .doc-reminder-item__note {
    color: var(--b3-card-warning-color) !important;
    background-color: var(--b3-card-warning-background) !important;
    border: 2px solid var(--b3-card-warning-color) !important;
}

.doc-reminder-priority-low {
    border-left: 4px solid var(--b3-card-info-color) !important;
    background-color: var(--b3-card-info-background) !important;
}

.doc-reminder-priority-low .doc-reminder-item__note {
    color: var(--b3-card-info-color) !important;
    background-color: var(--b3-card-info-background) !important;
    border: 2px solid var(--b3-card-info-color) !important;
}

.doc-reminder-priority-none .doc-reminder-item__note {
    color: var(--b3-theme-on-background) !important;
    background-color: transparent !important;
    border: 2px solid var(--b3-border-color) !important;
}

// 响应式设计
@media (max-width: 480px) {
    .doc-reminder-item {
        padding: 6px 10px;
        gap: 6px;
        margin-bottom: 4px;

        input[type="checkbox"] {
            align-self: flex-start;
            transform: scale(0.85);
        }
    }

    .doc-reminder-item__title {
        font-size: 12px;
        margin-bottom: 3px;
    }

    .doc-reminder-item__time {
        font-size: 10px;
        margin-bottom: 2px;
        gap: 4px;
    }

    .doc-reminder-item__note {
        font-size: 10px;
        margin-top: 2px;
        padding: 2px 4px;
    }

    .doc-reminder-completed-time {
        font-size: 9px;
        margin-top: 2px;
        gap: 2px;
    }

    .doc-reminder-item__actions {
        margin-left: 2px;

        .b3-button--small {
            padding: 2px 4px;
            font-size: 9px;
        }
    }

    .doc-reminder-priority-label {
        font-size: 9px;
        padding: 1px 3px;
    }

    .doc-reminder-overdue-label {
        font-size: 9px;
        padding: 1px 3px;
    }
}