.andw-mime-label {
    position: absolute;
    top: 4px;
    right: 4px;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
    color: white;
    border-radius: 3px;
    z-index: 100;
    text-transform: uppercase;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    pointer-events: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.andw-mime-jpg {
    background-color: #4285f4;
}

.andw-mime-png {
    background-color: #34a853;
}

.andw-mime-gif {
    background-color: #fbbc04;
    color: #333;
}

.andw-mime-svg {
    background-color: #ea4335;
}

.andw-mime-webp {
    background-color: #9c27b0;
}

.andw-mime-other {
    background-color: #666;
}

.attachment .thumbnail .andw-mime-label,
.media-modal .attachment .thumbnail .andw-mime-label {
    position: absolute;
}

.wp-list-table .column-title .media-icon,
.wp-list-table .media-icon {
    position: relative;
}

.media-frame .attachment {
    position: relative;
}

/* List view specific positioning */
.wp-list-table .media-icon .andw-mime-label {
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 9px;
    padding: 1px 4px;
    border-radius: 2px;
    z-index: 10;
}

/* Ensure proper stacking in list view */
.wp-list-table .column-title {
    position: relative;
}

.wp-list-table .type-attachment .media-icon {
    position: relative;
    display: inline-block;
}