.unread .mail-sender,
.unread .mail-subject {
    font-weight: 600;
}

.unread .mail-body {
    color: var(--bs-body-color) !important;
}

.starred .mail-starred {
    fill: var(--warning-500);
    stroke: var(--warning-700);
}

.mail-starred:hover {
    stroke-width: 2px !important;
    cursor: pointer;
}

/* Animation for deleting emails */
@keyframes slideOut {
    0% {
        transform: translateX(0);
        opacity: 1;
    }

    100% {
        transform: translateX(-100%);
        opacity: 0;
    }
}

.deleting {
    animation: slideCollapse 0.3s ease-out forwards;
}

@keyframes slideCollapse {
    from {
        opacity: 1;
        max-height: 44px;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        max-height: 0;
        transform: translateX(0);
    }
}


/* Refresh animation */
.refreshing::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(var(--bs-body-bg-rgb), 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.refreshing {
    position: relative;
}

/* Hide extra attachments */
.hidden-attachment {
    display: none;
}

/* Toast styling */
.mail-toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--success-500);
    color: white;
    padding: 1rem;
    border-radius: 4px;
    z-index: 1060;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.mail-toast.show {
    opacity: 1;
}

/* Checkbox animation */
.form-check-input:checked {
    animation: checkmark 0.2s ease-in-out forwards;
}

@keyframes checkmark {
    0% {
        transform: scale(0.8);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}