/* Ensure plugin menu SVG icon uses currentColor for fill and color */

/* Tooltip for settings question mark icon */
.pt-wuclean-tooltip {
    display: inline-block;
    position: relative;
    cursor: pointer;
    color: #0073aa;
    font-weight: bold;
    margin-left: 5px;
}
.pt-wuclean-tooltip-text {
    visibility: hidden;
    width: 220px;
    background-color: #23282d;
    color: #fff;
    text-align: left;
    border-radius: 4px;
    padding: 8px;
    position: absolute;
    z-index: 10;
    bottom: 125%;
    left: 50%;
    margin-left: -110px;
    opacity: 0;
    transition: opacity 0.2s;
    font-size: 13px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.pt-wuclean-tooltip:hover .pt-wuclean-tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Settings table styling for better label spacing */
.pt-wucleanup .form-table th {
    width: 350px;
    min-width: 350px;
    padding-right: 20px;
}

/* Animated pulsing dots for scan progress */
.pt-wuclean-dots::after {
    content: '.';
    animation: pt-wuclean-dots-pulse 1.5s steps(3, end) infinite;
}

@keyframes pt-wuclean-dots-pulse {
    0%, 33% { content: '.'; }
    34%, 66% { content: '..'; }
    67%, 100% { content: '...'; }
}

/* Image scan: pulse bar while waiting for the next batch response */
#pt-wuclean-image-progress-bar.pt-wuclean-progress-bar-pending {
    animation: pt-wuclean-progress-pending 1.1s ease-in-out infinite;
}

@keyframes pt-wuclean-progress-pending {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.22); }
}

/* Image scan: three-step progress indicator */
.pt-wuclean-image-scan-steps {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0;
    margin: 0 0 12px 0;
    padding: 0;
    list-style: none;
}

.pt-wuclean-scan-step {
    position: relative;
    flex: 1 1 0;
    min-width: 100px;
    padding: 0 8px 0 0;
    text-align: center;
    color: #646970;
    font-size: 12px;
    line-height: 1.35;
}

.pt-wuclean-scan-step:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 11px;
    left: calc(50% + 14px);
    right: -8px;
    height: 2px;
    background: #dcdcde;
    z-index: 0;
}

.pt-wuclean-scan-step.is-done:not(:last-child)::after {
    background: #0073aa;
}

.pt-wuclean-scan-step-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    margin: 0 auto 6px auto;
    border: 2px solid #c3c4c7;
    border-radius: 50%;
    background: #fff;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
    position: relative;
    z-index: 1;
}

.pt-wuclean-scan-step.is-active .pt-wuclean-scan-step-marker {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
}

.pt-wuclean-scan-step.is-active {
    color: #1d2327;
    font-weight: 600;
}

.pt-wuclean-scan-step.is-done .pt-wuclean-scan-step-marker {
    border-color: #0073aa;
    background: #0073aa;
    color: #fff;
}

.pt-wuclean-scan-step.is-done .pt-wuclean-scan-step-marker::before {
    content: '\2713';
}

.pt-wuclean-scan-step.is-pending .pt-wuclean-scan-step-label {
    opacity: 0.85;
}

.pt-wuclean-scan-step-uploads.is-hidden {
    display: none;
}

.pt-wuclean-image-scan-steps.is-two-steps .pt-wuclean-scan-step[data-step="media_library"]:not(:last-child)::after {
    left: calc(50% + 14px);
    right: -8px;
}

/* Image scan results table: fixed columns so long filenames do not overflow the page */
.pt-wuclean-image-results-table {
    table-layout: fixed;
    width: 100%;
}

.pt-wuclean-image-results-table .pt-wuclean-col-check {
    width: 36px;
}

.pt-wuclean-image-results-table .pt-wuclean-col-preview {
    width: 72px;
}

.pt-wuclean-image-results-table .pt-wuclean-col-image-info {
    width: 240px;
}

/* Actions column width is set on <col> + cells (table-layout: fixed reads <col> first). */

.pt-wuclean-image-results-table td.pt-wuclean-col-image-info,
.pt-wuclean-image-results-table th.pt-wuclean-col-image-info {
    max-width: 240px;
    overflow-wrap: anywhere;
    word-break: break-word;
    vertical-align: top;
}

.pt-wuclean-image-results-table .pt-wuclean-image-info-cell {
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.pt-wuclean-image-results-table .pt-wuclean-image-info-cell strong {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.pt-wuclean-image-results-table td.pt-wuclean-col-issue,
.pt-wuclean-image-results-table th.pt-wuclean-col-issue {
    overflow-wrap: anywhere;
    word-break: break-word;
    vertical-align: top;
}

.pt-wuclean-image-results-table col.pt-wuclean-col-actions,
.pt-wuclean-image-results-table td.pt-wuclean-col-actions,
.pt-wuclean-image-results-table th.pt-wuclean-col-actions {
    width: 375px;
    min-width: 375px;
    vertical-align: top;
}

.pt-wuclean-image-row-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 4px;
    align-items: center;
    margin-bottom: 4px;
}

.pt-wuclean-image-row-actions .button {
    flex-shrink: 0;
    white-space: nowrap;
    margin: 0;
}
