/**
 * Image Squeeze Admin Styles
 */

/* General Layout */
.image-squeeze-admin {
    max-width: 1200px;
    padding: 20px 0;
}

.image-squeeze-admin .postbox {
    margin-bottom: 24px;
    border-radius: 4px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.image-squeeze-admin .hndle {
    display: flex;
    align-items: center;
    padding: 12px 16px;
}

.image-squeeze-admin .hndle .dashicons {
    margin-right: 10px;
    width: 20px;
    height: 20px;
    font-size: 20px;
}

.image-squeeze-admin .inside {
    padding: 16px;
}

.image-squeeze-admin h2, 
.image-squeeze-admin h3 {
    margin-top: 0;
    margin-bottom: 16px;
    font-weight: 600;
}

.image-squeeze-admin .nav-tab-wrapper {
    margin-bottom: 24px;
}

.tab-content {
    margin-top: 24px;
}

/* Action Buttons */
.image-squeeze-admin button,
.image-squeeze-admin .button {
    display: inline-flex;
    align-items: center;
    margin-right: 12px;
    transition: all 0.2s ease;
}

.image-squeeze-admin button:hover,
.image-squeeze-admin .button:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.image-squeeze-admin button .dashicons,
.image-squeeze-admin .button .dashicons {
    margin-right: 6px;
    font-size: 18px;
    width: 18px;
    height: 18px;
    margin-top: -1px;
}

.imagesqueeze-actions-card {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f1;
    margin-bottom: 30px;
    transition: all 0.2s ease;
    overflow: hidden;
}

.imagesqueeze-actions-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.imagesqueeze-card-header {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f1;
    background-color: #f9f9f9;
}

.imagesqueeze-card-header .dashicons {
    color: #2271b1;
    font-size: 20px;
    width: 20px;
    height: 20px;
    margin-right: 10px;
}

.imagesqueeze-card-header h2 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #23282d;
}

.imagesqueeze-card-content {
    padding: 20px;
}

/* Status Badge */
.imagesqueeze-status-badge {
    padding: 10px 15px;
    border-radius: 6px;
}

.imagesqueeze-status-badge.in-progress {
    background-color: #f0f6fc;
    color: #2271b1;
    border-left: 4px solid #2271b1;
}

.imagesqueeze-status-badge.idle {
    background-color: #f6f7f7;
    color: #50575e;
    border-left: 4px solid #50575e;
}

.imagesqueeze-status-badge.complete {
    background-color: #edf9ee;
    color: #00701a;
    border-left: 4px solid #00a32a;
}

/* Action Buttons */
.imagesqueeze-action-buttons {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.imagesqueeze-action-buttons button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    min-width: 180px;
    transition: all 0.2s ease;
}

.imagesqueeze-action-buttons button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
}

.imagesqueeze-action-buttons button:active:not(:disabled) {
    transform: translateY(0);
}

.imagesqueeze-action-buttons button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Progress Container */
.imagesqueeze-progress-container {
    margin-top: 0;
    padding: 0;
    transition: all 0.3s ease;
}

.imagesqueeze-progress-wrapper {
    height: 12px;
    background-color: #f0f0f1;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
}

.imagesqueeze-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #2271b1, #72aee6);
    border-radius: 6px;
    width: 0%; /* Set dynamically via JS */
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.imagesqueeze-progress-text {
    display: flex;
    align-items: center;
    font-size: 14px;
    color: #3c434a;
    margin-top: 10px;
    font-weight: 500;
}

.imagesqueeze-progress-text .dashicons {
    margin-right: 8px;
    font-size: 18px;
    width: 18px;
    height: 18px;
    animation: spin 2s linear infinite;
    color: #2271b1;
}

/* Stats Display */
.imagesqueeze-stats-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.imagesqueeze-stat-card {
    background: #fff;
    padding: 20px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    flex: 1;
    min-width: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: all 0.2s ease;
    border: 1px solid #f0f0f1;
}

.imagesqueeze-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.imagesqueeze-stat-icon {
    margin-bottom: 10px;
    background: #f5f5f5;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.imagesqueeze-stat-icon .dashicons {
    font-size: 25px;
    width: 25px;
    height: 25px;
    color: #2271b1;
}

.imagesqueeze-stat-title {
    font-size: 14px;
    font-weight: 600;
    color: #23282d;
    margin-bottom: 8px;
}

.imagesqueeze-stat-value {
    font-size: 28px;
    font-weight: 700;
    color: #2271b1;
    margin-bottom: 5px;
    line-height: 1.2;
}

.imagesqueeze-stat-subtext {
    font-size: 12px;
    color: #666;
}

/* Warning state for failed images */
.imagesqueeze-stat-warning .imagesqueeze-stat-icon .dashicons {
    color: #d63638;
}

.imagesqueeze-stat-warning .imagesqueeze-stat-value {
    color: #d63638;
}

/* Progress Bar */
.image-squeeze-progress {
    margin-bottom: 24px;
}

.imagesqueeze-progress-label {
    font-weight: 500;
    color: #3c434a;
    margin-bottom: 5px;
    font-size: 13px;
}

.image-squeeze-progress .progress-bar-container {
    height: 24px;
    background-color: #f0f0f1;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 10px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.image-squeeze-progress .progress-bar {
    height: 100%;
    background-color: #2271b1;
    width: 0; /* Set dynamically via JS */
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Notices Container */
.imagesqueeze-notices {
    margin: 15px 0 24px;
}

.imagesqueeze-notices .notice {
    margin: 5px 0 15px;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Logs UI */
.imagesqueeze-logs-container {
    margin-top: 24px;
}

.imagesqueeze-log-card {
    background: #fff;
    border-radius: 4px;
    margin-bottom: 20px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
    border: 1px solid #e5e5e5;
    transition: all 0.2s ease;
}

.imagesqueeze-log-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.imagesqueeze-log-entry {
    border-left: 4px solid #2271b1;
    margin-bottom: 20px;
}

.imagesqueeze-log-entry.retry-job {
    border-left-color: #d63638;
}

.imagesqueeze-log-entry.cleanup-job {
    border-left-color: #00a32a;
}

.imagesqueeze-log-entry .dashicons {
    margin-right: 8px;
    color: #2271b1;
    width: 20px;
    height: 20px;
    font-size: 20px;
    margin-top: -2px;
}

.imagesqueeze-log-entry.retry-job .dashicons {
    color: #d63638;
}

.imagesqueeze-log-entry.cleanup-job .dashicons {
    color: #00a32a;
}

.imagesqueeze-log-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f1;
}

.imagesqueeze-log-header .log-title {
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 14px;
}

.imagesqueeze-log-header .log-date {
    color: #757575;
    font-size: 13px;
    font-weight: normal;
    margin-left: auto;
}

.imagesqueeze-log-details {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.imagesqueeze-log-summary {
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f0f0f1;
    font-weight: 500;
}

.imagesqueeze-log-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.imagesqueeze-log-stat {
    display: flex;
    align-items: center;
    padding: 12px;
    border-radius: 4px;
    background: #f9f9f9;
}

.imagesqueeze-log-stat.success .dashicons {
    color: #00a32a;
}

.imagesqueeze-log-stat.error .dashicons {
    color: #d63638;
}

.imagesqueeze-log-stat .stat-label {
    font-weight: 600;
    margin: 0 8px;
}

.imagesqueeze-log-stat .stat-value {
    font-size: 18px;
    font-weight: 700;
    margin-left: auto;
}

.imagesqueeze-no-logs {
    margin: 24px 0;
    padding: 16px;
    display: flex;
    align-items: center;
}

.imagesqueeze-no-logs .dashicons {
    margin-right: 10px;
    color: #72aee6;
    width: 24px;
    height: 24px;
    font-size: 24px;
}

/* Cleanup UI */
.imagesqueeze-cleanup-card {
    background: #fff;
    border-radius: 6px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f1;
    transition: all 0.2s ease;
    overflow: hidden;
}

.imagesqueeze-cleanup-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.imagesqueeze-cleanup-description {
    margin-bottom: 24px;
    color: #50575e;
    line-height: 1.6;
}

.imagesqueeze-cleanup-description p {
    margin-bottom: 10px;
}

.imagesqueeze-cleanup-description p:last-child {
    margin-bottom: 0;
}

.imagesqueeze-cleanup-actions {
    margin-bottom: 24px;
}

.imagesqueeze-cleanup-actions button {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 220px;
    padding: 8px 16px;
    transition: all 0.2s ease;
}

.imagesqueeze-cleanup-actions button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
}

.imagesqueeze-cleanup-actions button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.imagesqueeze-cleanup-results {
    margin-top: 30px;
}

.imagesqueeze-cleanup-results.hidden {
    display: none;
}

.imagesqueeze-cleanup-status {
    display: flex;
    align-items: center;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 4px;
    background: #f6f7f7;
    color: #50575e;
    font-weight: 500;
}

.imagesqueeze-cleanup-status.in-progress {
    background: #f0f6fc;
    color: #2271b1;
    border-left: 4px solid #2271b1;
}

.imagesqueeze-cleanup-status.in-progress .dashicons {
    margin-right: 8px;
    color: #2271b1;
    animation: spin 2s linear infinite;
}

/* Cleanup Summary */
.imagesqueeze-cleanup-summary {
    display: flex;
    align-items: flex-start;
    padding: 16px;
    border-radius: 6px;
    margin-bottom: 24px;
}

.imagesqueeze-cleanup-summary .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    margin-right: 16px;
    flex-shrink: 0;
}

.cleanup-summary-content {
    flex-grow: 1;
}

.cleanup-summary-title {
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 5px;
}

.cleanup-summary-text {
    color: #50575e;
}

.imagesqueeze-cleanup-summary.success {
    background-color: #edfaef;
    border: 1px solid #d3efcf;
}

.imagesqueeze-cleanup-summary.success .dashicons {
    color: #00a32a;
}

.imagesqueeze-cleanup-summary.success .cleanup-summary-title {
    color: #00701a;
}

.imagesqueeze-cleanup-summary.error {
    background-color: #fcf0f1;
    border: 1px solid #f7d6d9;
}

.imagesqueeze-cleanup-summary.error .dashicons {
    color: #d63638;
}

.imagesqueeze-cleanup-summary.error .cleanup-summary-title {
    color: #ba0c14;
}

.imagesqueeze-cleanup-summary.empty {
    background-color: #edfaef;
    border: 1px solid #d3efcf;
}

.imagesqueeze-cleanup-summary.empty .dashicons {
    color: #00a32a;
}

.imagesqueeze-cleanup-summary.empty .cleanup-summary-title {
    color: #00701a;
}

/* File List */
.imagesqueeze-cleanup-filelist-container {
    background: #f9f9f9;
    border-radius: 6px;
    padding: 16px;
    margin-bottom: 20px;
    border: 1px solid #f0f0f1;
}

.imagesqueeze-cleanup-filelist-title {
    display: flex;
    align-items: center;
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #2271b1;
}

.imagesqueeze-cleanup-filelist-title .dashicons {
    margin-right: 8px;
    color: #2271b1;
}

.imagesqueeze-cleanup-filelist {
    max-height: 200px;
    overflow-y: auto;
    margin: 0;
    padding: 10px 15px;
    background: #fff;
    border: 1px solid #f0f0f1;
    border-radius: 4px;
    list-style-position: inside;
    font-family: Consolas, Monaco, monospace;
    font-size: 12px;
}

.imagesqueeze-cleanup-filelist li {
    margin-bottom: 6px;
    padding-bottom: 6px;
    border-bottom: 1px solid #f0f0f1;
    word-break: break-all;
}

.imagesqueeze-cleanup-filelist li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.imagesqueeze-cleanup-tooltip {
    margin-top: 10px;
    text-align: center;
    font-style: italic;
    color: #757575;
    font-size: 12px;
}

/* Responsive Adjustments */
@media (max-width: 782px) {
    .imagesqueeze-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .imagesqueeze-stat-card {
        min-width: 0;
    }
    
    .image-squeeze-admin button,
    .image-squeeze-admin .button {
        margin-bottom: 10px;
        width: 100%;
        justify-content: center;
    }
    
    .imagesqueeze-actions-card {
        display: flex;
        flex-direction: column;
    }
}

@media screen and (max-width: 1200px) {
    .imagesqueeze-stats-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

@media screen and (max-width: 600px) {
    .imagesqueeze-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* Screen reader text */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.wrap>h2:first-child {
    padding-bottom: 10px;
}

/* Section Titles - unified styling */
.imagesqueeze-section-title,
.imagesqueeze-tab-content h2,
.imagesqueeze-tab-content .imagesqueeze-section-title,
.wrap h2.imagesqueeze-section-title,
.imagesqueeze h2.imagesqueeze-section-title {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    font-size: 20px;
    font-weight: 500;
    margin-top: 0;
    margin-bottom: 20px;
    color: #1d2327;
    width: 100%;
    padding: 0;
    line-height: 1.3;
    text-align: left;
}

.imagesqueeze-section-title .dashicons,
.wrap h2.imagesqueeze-section-title .dashicons {
    margin-right: 10px;
    color: #2271b1;
    font-size: 24px;
    width: 24px;
    height: 24px;
}

/* Modern Settings UI */
.imagesqueeze-settings-form {
    max-width: 960px;
}

.imagesqueeze-settings-section {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin-bottom: 25px;
    overflow: hidden;
    border: 1px solid #e5e5e5;
}

.imagesqueeze-settings-section h2 {
    margin: 0;
    padding: 16px 20px;
    font-size: 16px;
    background: #f8f9fa;
    border-bottom: 1px solid #e5e5e5;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.imagesqueeze-settings-section h2 .dashicons {
    margin-right: 8px;
    color: #2271b1;
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.imagesqueeze-settings-section .form-table {
    margin: 0;
    border: none;
    box-shadow: none;
}

.imagesqueeze-settings-section .form-table th {
    padding: 25px 20px 25px 20px;
    width: 230px;
    vertical-align: top;
}

.imagesqueeze-settings-section .form-table td {
    padding: 20px 20px 20px 0;
}

.imagesqueeze-save-settings {
    padding: 10px 0 30px;
}

/* Slider improvements */
.quality-slider-container {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    max-width: 400px;
}

.quality-slider-container input[type="range"] {
    flex: 1;
    margin-right: 15px;
}

.quality-value-display {
    font-weight: 600;
    color: #2271b1;
    font-size: 16px;
    min-width: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f0f6fc;
    padding: 6px 10px;
    border-radius: 4px;
    border: 1px solid #c5d9ed;
}

/* Toggle Switch */
.imagesqueeze-toggle-container {
    margin-bottom: 12px;
}

.imagesqueeze-toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.imagesqueeze-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.imagesqueeze-toggle-slider {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 22px;
    background-color: #ccc;
    border-radius: 34px;
    transition: 0.2s;
    margin-right: 12px;
    flex-shrink: 0;
}

.imagesqueeze-toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 2px;
    background-color: white;
    border-radius: 50%;
    transition: 0.2s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.imagesqueeze-toggle input:checked + .imagesqueeze-toggle-slider {
    background-color: #00a32a;
}

.imagesqueeze-toggle input:focus + .imagesqueeze-toggle-slider {
    box-shadow: 0 0 1px #00a32a;
}

.imagesqueeze-toggle input:checked + .imagesqueeze-toggle-slider:before {
    transform: translateX(21px);
}

.imagesqueeze-toggle-label {
    font-weight: 500;
}

/* Responsive Settings */
@media screen and (max-width: 782px) {
    .imagesqueeze-settings-section .form-table, 
    .imagesqueeze-settings-section .form-table tbody,
    .imagesqueeze-settings-section .form-table tr,
    .imagesqueeze-settings-section .form-table th,
    .imagesqueeze-settings-section .form-table td {
        display: block;
        width: 100%;
        padding: 15px 20px;
    }
    
    .imagesqueeze-settings-section .form-table th {
        padding-bottom: 5px;
    }
    
    .imagesqueeze-settings-section .form-table td {
        padding-top: 0;
    }
    
    .quality-slider-container {
        max-width: 100%;
    }
}

/* Logs Timeline UI */
.imagesqueeze-logs-timeline {
    position: relative;
    margin: 30px 0;
    padding-left: 20px;
}

.imagesqueeze-logs-timeline:before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 5px;
    width: 3px;
    background: #e5e5e5;
    border-radius: 3px;
}

.imagesqueeze-timeline-card {
    position: relative;
    margin-bottom: 30px;
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f1;
    transition: all 0.2s ease;
    overflow: hidden;
}

.imagesqueeze-timeline-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.imagesqueeze-timeline-card:last-child {
    margin-bottom: 0;
}

.timeline-connector {
    position: absolute;
    left: -22px;
    top: 25px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #2271b1;
    border: 2px solid #fff;
    z-index: 2;
}

.imagesqueeze-timeline-card.retry-job .timeline-connector {
    background: #f0b849;
}

.imagesqueeze-timeline-card.cleanup-job .timeline-connector {
    background: #00a32a;
}

.timeline-card-header {
    display: flex;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid #f0f0f1;
    background-color: #f9f9f9;
}

.timeline-date {
    display: flex;
    align-items: center;
    font-weight: 600;
    color: #2271b1;
    margin-right: 15px;
}

.timeline-date .dashicons {
    margin-right: 6px;
    color: #2271b1;
}

.timeline-type {
    flex-grow: 1;
}

.timeline-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.timeline-badge .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    margin-right: 4px;
}

.timeline-badge.badge-full {
    background-color: #e6f0f7;
    color: #2271b1;
}

.timeline-badge.badge-retry {
    background-color: #fcf0d3;
    color: #986a08;
}

.timeline-badge.badge-cleanup {
    background-color: #e6f6e8;
    color: #00701a;
}

.timeline-time {
    color: #757575;
    font-size: 12px;
}

.timeline-card-content {
    padding: 16px;
}

.timeline-details-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.timeline-details-list li {
    display: flex;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f1;
}

.timeline-details-list li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.timeline-details-list li:first-child {
    padding-top: 0;
}

.timeline-details-list li .dashicons {
    margin-right: 10px;
    font-size: 18px;
    width: 18px;
    height: 18px;
    color: #50575e;
}

.timeline-details-list li.success .dashicons {
    color: #00a32a;
}

.timeline-details-list li.error .dashicons {
    color: #d63638;
}

.timeline-details-list li.savings .dashicons {
    color: #2271b1;
}

.detail-label {
    margin-right: 8px;
    font-weight: 500;
    color: #23282d;
}

.detail-value {
    margin-left: auto;
    font-weight: 600;
    font-size: 16px;
    color: #2271b1;
}

.timeline-details-list li.success .detail-value {
    color: #00a32a;
}

.timeline-details-list li.error .detail-value {
    color: #d63638;
}

/* Empty state */
.imagesqueeze-no-logs {
    display: flex;
    align-items: center;
    padding: 20px;
    background: #f0f6fc;
    border-left: 4px solid #72aee6;
    border-radius: 4px;
    margin: 20px 0;
}

.imagesqueeze-no-logs .dashicons {
    margin-right: 15px;
    color: #72aee6;
    width: 24px;
    height: 24px;
    font-size: 24px;
}

.imagesqueeze-no-logs p {
    margin: 0;
    color: #50575e;
}

/* Responsive adjustments */
@media screen and (max-width: 782px) {
    .timeline-card-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .timeline-date {
        margin-bottom: 10px;
    }
    
    .timeline-type {
        margin-bottom: 10px;
    }
    
    .timeline-details-list li {
        flex-wrap: wrap;
    }
    
    .detail-value {
        width: 100%;
        margin-top: 5px;
        margin-left: 28px;
    }
}

/* Make slider look better in WordPress admin */
input[type=range] {
    -webkit-appearance: none;
    margin: 10px 0;
    height: 8px;
    background: #f0f0f1;
    border-radius: 4px;
    border: 1px solid #dcdcde;
}

input[type=range]:focus {
    outline: none;
    border-color: #2271b1;
}

input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 18px;
    width: 18px;
    border-radius: 50%;
    background: #2271b1;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    transition: background 0.2s;
}

input[type=range]::-moz-range-thumb {
    height: 18px;
    width: 18px;
    border-radius: 50%;
    background: #2271b1;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    border: none;
    transition: background 0.2s;
}

input[type=range]::-webkit-slider-thumb:hover {
    background: #135e96;
}

input[type=range]::-moz-range-thumb:hover {
    background: #135e96;
}

/* Last Optimization Summary */
.imagesqueeze-summary-card {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f1;
    margin-bottom: 30px;
    transition: all 0.2s ease;
    overflow: hidden;
}

.imagesqueeze-summary-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.imagesqueeze-summary-header {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f1;
    background-color: #f9f9f9;
}

.imagesqueeze-summary-header .dashicons {
    color: #2271b1;
    font-size: 20px;
    width: 20px;
    height: 20px;
    margin-right: 10px;
}

.imagesqueeze-summary-header h2 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #23282d;
}

.imagesqueeze-summary-content {
    padding: 20px;
}

.imagesqueeze-summary-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.imagesqueeze-summary-item {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f0f0f1;
}

.imagesqueeze-summary-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.summary-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #f5f5f5;
    border-radius: 50%;
    margin-right: 15px;
    flex-shrink: 0;
}

.summary-icon .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
    color: #2271b1;
}

.summary-icon.success .dashicons {
    color: #00a32a;
}

.summary-info {
    flex-grow: 1;
}

.summary-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #23282d;
    margin-bottom: 5px;
}

.summary-value {
    font-size: 16px;
    color: #2271b1;
    font-weight: 500;
}

.summary-value.warning {
    display: flex;
    align-items: center;
    color: #d63638;
    margin-top: 5px;
}

.summary-value.warning .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    margin-right: 5px;
    color: #d63638;
}

.imagesqueeze-no-summary {
    display: flex;
    align-items: center;
    padding: 15px;
    background: #f0f6fc;
    border-left: 4px solid #72aee6;
    border-radius: 4px;
}

.imagesqueeze-no-summary .dashicons {
    color: #72aee6;
    font-size: 20px;
    width: 20px;
    height: 20px;
    margin-right: 10px;
}

.imagesqueeze-no-summary p {
    margin: 0;
    color: #50575e;
}

/* Responsive adjustments for summary card */
@media screen and (max-width: 782px) {
    .imagesqueeze-summary-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .summary-icon {
        margin-bottom: 10px;
    }
}

/* Summary grid layout - horizontal stats */
.imagesqueeze-summary-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 0;
    padding: 0;
}

.imagesqueeze-summary-stat-card {
    flex: 1;
    min-width: 200px;
    background: #f9f9f9;
    border-radius: 8px;
    padding: 15px;
    border: 1px solid #f0f0f1;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
}

.imagesqueeze-summary-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    background: #fff;
}

/* Responsive adjustments for summary grid */
@media screen and (max-width: 782px) {
    .imagesqueeze-summary-grid {
        flex-direction: column;
    }
    
    .imagesqueeze-summary-stat-card {
        width: 100%;
    }
}

/* Actions Container - New styling for optimization actions */
.imagesqueeze-actions-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.imagesqueeze-actions-top-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.imagesqueeze-actions-top-row .imagesqueeze-status-badge {
    margin-bottom: 0;
}

.imagesqueeze-action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 0;
}

/* Final Status Message */
.imagesqueeze-final-status {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background-color: #edf9ee;
    border-radius: 6px;
    border: 1px solid #d3efcf;
    margin-top: 10px;
    font-weight: 500;
    color: #00701a;
}

.imagesqueeze-final-status .dashicons {
    color: #00a32a;
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* Responsive adjustments for the actions container */
@media screen and (max-width: 782px) {
    .imagesqueeze-actions-top-row {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .imagesqueeze-action-buttons {
        width: 100%;
    }
    
    .imagesqueeze-action-buttons button {
        flex: 1;
        min-width: auto;
        justify-content: center;
    }
}

/* Improved Progress UI with Spinner */
.imagesqueeze-progress-with-spinner {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background-color: #f0f6fc;
    border-radius: 6px;
    border: 1px solid #c5d9ed;
    margin-top: 10px;
}

.imagesqueeze-spinner {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.imagesqueeze-spinner .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    color: #2271b1;
    animation: spin 1.5s linear infinite;
}

.imagesqueeze-progress-details {
    flex-grow: 1;
}

.imagesqueeze-progress-label {
    font-weight: 500;
    color: #2271b1;
    font-size: 15px;
    margin-bottom: 5px;
}

.imagesqueeze-progress-text {
    color: #50575e;
    font-size: 13px;
}

/* Hide notices container when using status indicators instead */
.imagesqueeze-notices:empty {
    display: none;
}

/* Clear Logs Button */
.imagesqueeze-clear-logs-container {
    margin-left: auto;
    display: flex;
    align-items: center;
}

.imagesqueeze-clear-logs-container .spinner {
    float: none;
    margin-left: 10px;
}

/* Plain timestamp styling - more straightforward styling */
.plain-timestamp {
    color: #135e96;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 3px;
    display: inline-block;
}

/* Logs filtering */
.imagesqueeze-logs-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: 4px;
    border: 1px solid #e2e4e7;
}

.imagesqueeze-filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.imagesqueeze-filter-group label {
    font-weight: 600;
    color: #23282d;
}

.imagesqueeze-filter {
    min-width: 150px;
    height: 30px;
    border-radius: 3px;
}

.imagesqueeze-date-input {
    width: 150px;
}

#custom-date-inputs {
    border-top: 1px solid #e2e4e7;
    padding-top: 10px;
    margin-top: 5px;
    width: 100%;
}

#apply-custom-date {
    margin-left: 10px;
}

/* No visible logs message */
.imagesqueeze-no-visible-logs {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    background-color: #f8f8f8;
    border-radius: 4px;
    text-align: center;
    margin-top: 20px;
    border: 1px dashed #ccc;
}

.imagesqueeze-no-visible-logs .dashicons {
    font-size: 35px;
    width: 35px;
    height: 35px;
    margin-bottom: 10px;
    color: #72aee6;
}

.imagesqueeze-no-visible-logs p {
    margin: 5px 0;
    font-size: 14px;
}

/* Add styling for failed job badge */
.timeline-badge.badge-failed {
    background-color: #f0c33c;
    color: #3c2e00;
}

/* Responsive styles for filters */
@media screen and (max-width: 782px) {
    .imagesqueeze-filter-group {
        width: 100%;
    }
    
    .imagesqueeze-filter {
        width: 100%;
    }
    
    .imagesqueeze-date-input {
        width: 100%;
    }
    
    #custom-date-inputs {
        flex-direction: column;
        align-items: flex-start;
    }
    
    #apply-custom-date {
        margin-left: 0;
        margin-top: 10px;
    }
}

/* Tab Navigation */
.imagesqueeze-tab-nav {
    border-bottom: 1px solid #c3c4c7;
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
}

.imagesqueeze-tab-nav li {
    margin: 0 0 -1px 0;
    position: relative;
}

.imagesqueeze-tab-nav a {
    display: inline-block;
    padding: 10px 16px;
    text-decoration: none;
    color: #646970;
    font-weight: 500;
    font-size: 14px;
    border: 1px solid transparent;
    border-bottom: none;
    background: transparent;
    transition: all 0.2s ease;
}

.imagesqueeze-tab-nav a:hover {
    color: #1d2327;
    background: #f0f0f1;
}

.imagesqueeze-tab-nav a:focus {
    box-shadow: none;
    outline: none;
}

.imagesqueeze-tab-nav a.active {
    color: #1d2327;
    background: #fff;
    border-color: #c3c4c7;
    border-bottom-color: #fff;
}

.imagesqueeze-tab-nav a .dashicons {
    margin-right: 5px;
    font-size: 16px;
    width: 16px;
    height: 16px;
    vertical-align: text-bottom;
}

/* Tab Content */
.imagesqueeze-tab-content {
    background: #fff;
    border: 1px solid #c3c4c7;
    border-top: none;
    padding: 20px;
}

.imagesqueeze-tab-content .tab-pane {
    display: none;
}

.imagesqueeze-tab-content .tab-pane.active {
    display: block;
}

/* Ensure all tab content h2 headers are consistently styled */
.imagesqueeze-tab-content h2,
.imagesqueeze-tab-content .imagesqueeze-section-title,
.wrap h2.imagesqueeze-section-title {
    font-size: 20px;
    font-weight: 500;
    margin-top: 0;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    color: #1d2327;
    padding: 0;
    line-height: 1.3;
}

/* Ensure that card headers inside tabs are also consistently styled */
.imagesqueeze-tab-content .imagesqueeze-card-header h2 {
    font-size: 18px;
    margin: 0;
    padding: 0;
    border: none;
}

/* Main plugin title styling */
.image-squeeze-admin h1.wp-heading-inline {
    margin-bottom: 20px;
    font-size: 23px;
    font-weight: 500;
    color: #1d2327;
    padding: 0;
    display: flex;
    align-items: center;
}

.image-squeeze-admin h1.wp-heading-inline .dashicons {
    color: #2271b1;
    margin-right: 10px;
}

/* Fix settings tab header to match other tabs */
.wrap h2.imagesqueeze-section-title {
    margin-top: 0;
    margin-bottom: 20px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    font-size: 20px;
    font-weight: 500;
    color: #1d2327;
    width: 100%;
    text-align: left;
    line-height: 1.3;
}

.wrap h2.imagesqueeze-section-title .dashicons {
    margin-right: 10px;
    color: #2271b1;
    font-size: 24px;
    width: 24px;
    height: 24px;
} 