.chev-uploader {
    margin: 8px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    box-sizing: border-box;
    max-width: 100%;
    padding: 8px;
    border: 2px dashed transparent;
    border-radius: 6px;
    transition: border-color .2s, background-color .2s;
}
.chev-uploader.is-dragover {
    border-color: #0073aa;
    background-color: rgba(0, 115, 170, 0.05);
}
.chev-uploader [hidden] {
    display: none !important;
}
.chev-uploader__btn {
    flex: 0 0 auto;
    max-width: 100%;
    white-space: nowrap;
    padding: .45em .8em;
    border: 1px solid var(--wp--preset--color--contrast-3, #ccc);
    border-radius: 6px;
    cursor: pointer;
}
.chev-uploader__hint {
    flex: 1 1 180px;
    min-width: 0;
    font-size: .85em;
    opacity: .8;
    overflow-wrap: anywhere;
}
.comment-body img.chevimg-thumb,
.comment-content img.chevimg-thumb {
    max-height: 120px;
    max-width: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    display: inline-block;
    border-radius: 6px;
    vertical-align: middle;
}
.chev-previews {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: flex-start;
    flex: 0 0 100%;
    min-width: 0;
}
.chev-previews img {
    max-height: 120px;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    border-radius: 6px;
    display: inline-block;
    vertical-align: middle;
    transition: opacity 0.3s;
}

.chev-loading {
    cursor: wait;
}
.chev-loading > img {
    opacity: 0.4;
}
.chev-previews .chev-loading {
    position: relative;
    display: inline-block;
    min-width: 72px;
    min-height: 56px;
    border-radius: 6px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.06);
    line-height: 0;
}
.chev-prog {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 4px 4px 8px;
    box-sizing: border-box;
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
    font-size: 11px;
    line-height: 1.2;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
    pointer-events: none;
}
.chev-prog__spin {
    width: 18px;
    height: 18px;
    box-sizing: border-box;
    border: 2px solid rgba(255, 255, 255, 0.45);
    border-top-color: #fff;
    border-radius: 50%;
    animation: chev-spin 0.8s linear infinite;
}
.chev-prog__label {
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-variant-numeric: tabular-nums;
}
.chev-prog__track {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 4px;
    background: rgba(255, 255, 255, 0.35);
    overflow: hidden;
}
.chev-prog__bar {
    display: block;
    width: 0;
    height: 100%;
    background: #2ea3f2;
    transition: width 0.15s linear;
}
.chev-prog.is-wait .chev-prog__bar {
    width: 40%;
    transition: none;
    animation: chev-slide 1.1s ease-in-out infinite;
}
@keyframes chev-spin {
    to { transform: rotate(360deg); }
}
@keyframes chev-slide {
    from { transform: translateX(-100%); }
    to { transform: translateX(250%); }
}
@media (prefers-reduced-motion: reduce) {
    .chev-prog__spin { animation-duration: 2.4s; }
    .chev-prog.is-wait .chev-prog__bar { animation: none; width: 100%; opacity: 0.6; }
}

