/**
 * All of the CSS for your admin-specific functionality should be
 * included in this file.
 */

.pinnerpress-admin {
    margin: 20px 20px 20px 0;
}

.pinnerpress-admin-header {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.pinnerpress-logo {
    margin-right: 20px;
    width: 200px;
}

.pinnerpress-logo img {
    max-width: 100%;
    height: auto;
}

.pinnerpress-header-content h2 {
    margin-top: 0;
    color: #E60023;
}

.pinnerpress-admin-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.pinnerpress-card {
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.pinnerpress-card h3 {
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    color: #E60023;
}

/* Tabs Navigation */
.pinnerpress-tabs-wrapper {
    margin-top: 20px;
}

.pinnerpress-tabs-wrapper .nav-tab-wrapper {
    margin-bottom: 0;
    border-bottom: 1px solid #ccc;
}

.pinnerpress-tabs-wrapper .nav-tab {
    margin-bottom: -1px;
    font-size: 14px;
    padding: 10px 15px;
}

.pinnerpress-tabs-wrapper .nav-tab-active,
.pinnerpress-tabs-wrapper .nav-tab-active:focus,
.pinnerpress-tabs-wrapper .nav-tab-active:focus:active,
.pinnerpress-tabs-wrapper .nav-tab-active:hover {
    border-bottom: 1px solid #fff;
    background: #fff;
    color: #E60023;
}

.pinnerpress-tab-content {
    background: #fff;
    padding: 20px;
    border: 1px solid #ccc;
    border-top: none;
}

.pinnerpress-settings-container {
    background: #fff;
    border-radius: 0 0 4px 4px;
    margin-bottom: 20px;
}

.pinnerpress-settings-section {
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.pinnerpress-settings-section h2 {
    margin-top: 0;
    color: #E60023;
}

.pinnerpress-settings-section:last-child {
    border-bottom: none;
}

.pinnerpress-settings-layout {
    display: flex;
    gap: 20px; /* Optional: adds space between columns */
}

.pinnerpress-settings-column {
    flex: 0 0 60%; /* 60% width */
    max-width: 60%;
}

.pinnerpress-preview-column {
    flex: 0 0 40%; /* 40% width */
    max-width: 40%;
}

/* Mobile Responsive Layout */
@media screen and (max-width: 782px) {
    .pinnerpress-settings-layout {
        flex-direction: column;
    }
    
    .pinnerpress-settings-column,
    .pinnerpress-preview-column {
        flex: 0 0 100%;
        max-width: 100%;
    }
}



/* Preview Area */
.pinnerpress-preview {
    background: #f9f9f9;
    border: 1px solid #ddd;
    padding: 20px;
    margin-top: 20px;
    margin-right: 20px;
    text-align: center;
}

.pinnerpress-preview img {
    max-width: 100%;
    height: auto;
    max-height: 600px;
    display: block; /* Ensure image behaves as a block element */
    margin: 0 auto; /* Center the image */
}

.pinnerpress-preview-image {
    position: relative; /* Added for positioning the pin button */
    display: inline-block; /* Make container shrink to image size */
    font-size: 0; /* Collapse whitespace around image */
    margin: 0 auto; /* Center the container */
}

/* Pin Button Styles */
.pinnerpress-pin-it-button-wrapper {
    z-index: 10; /* Ensure button appears above the image */
}

.pinnerpress-pin-it-button {
    display: inline-flex;
    align-items: center;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 12px;
    text-decoration: none;
    cursor: pointer;
    background-color: #E60023;
    color: #FFFFFF;
    border-radius: 3px;
    border: none;
    outline: none;
    position: relative;
}

.pinnerpress-pin-it-button svg {
    flex-shrink: 0;
    display: inline-block;
    fill: currentColor;
    width: 1em;
    height: 1em;
    vertical-align: middle;
    pointer-events: none;
}

/* Pinterest Icon Specific Styles */
.pinnerpress-pin-icon {
    display: inline-block !important;
    vertical-align: -0.125em;
    fill: currentColor !important;
    width: 1em;
    height: 1em;
    pointer-events: none;
}

/* WordPress Color Picker Alpha Channel Support */
.wp-picker-container .iris-picker {
    z-index: 100;
}

/* Submit button styling */
.pinnerpress-submit-buttons {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.pinnerpress-submit-buttons .reset-button {
    color: #d63638;
    border-color: #d63638;
    text-decoration: none;
}

.pinnerpress-submit-buttons .reset-button:hover {
    background: #d63638;
    color: #fff;
    border-color: #d63638;
}

/* Follow Box Preview Styles */
.pinnerpress-follow-box-preview-container {
    background: white;
    border: 1px solid #e1e1e1;
    border-radius: 8px;
    padding: 20px;
    width: 280px;
    max-width: 100%;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.pinnerpress-follow-box-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    background: #f9f9f9;
    border-radius: 4px;
    padding: 20px;
}

.pinnerpress-follow-box-header {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.pinnerpress-pinterest-logo {
    width: 24px;
    height: 24px;
    margin-right: 8px;
}

.pinnerpress-pinterest-username {
    font-size: 16px;
    font-weight: 600;
    color: #111;
}

.pinnerpress-follow-box-description {
    font-size: 14px;
    line-height: 1.4;
    color: #333;
    margin-bottom: 15px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.pinnerpress-follow-button {
    display: inline-block;
    background-color: #E60023;
    color: white;
    padding: 8px 14px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}

/* New Follow Box Styles */
.pinnerpress-settings-preview-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: #f8f8f8;
    border-radius: 4px;
    width: 100%;
    min-height: 450px; /* Increased height to match front-end */
}

.pinnerpress-follow-box-preview {
    width: 400px;
    max-width: 100%;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.pinnerpress-follow-box-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    max-width: 400px;
}

.pinnerpress-follow-box {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.pinnerpress-shadow-lg {
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.pinnerpress-follow-box-header {
    position: relative;
    height: 120px; /* Match front-end height */
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.pinnerpress-follow-box-close {
    position: absolute;
    top: 8px;
    right: 8px;
    border: none;
    background: none;
    padding: 5px;
    cursor: pointer;
    z-index: 2;
    filter: drop-shadow(0px 0px 3px rgba(0, 0, 0, 1)) drop-shadow(0px 0px 1px rgba(0, 0, 0, 1));
}

.pinnerpress-follow-box-close svg {
    display: block;
}

.pinnerpress-follow-box-close path {
    fill: #FFFFFF;
}

.pinnerpress-follow-box-logo {
    position: absolute;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background-size: cover;
    background-position: center;
    border: 4px solid #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    z-index: 10;
}

.pinnerpress-follow-box-inner {
    padding: 50px 20px 20px;
    text-align: center;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.pinnerpress-follow-box-inner h3 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.pinnerpress-follow-box-inner p {
    margin: 0 0 20px;
    font-size: 14px;
    color: #666;
    line-height: 1.4;
}

.pinnerpress-follow-box-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    background-color: #ED4996;
    color: #fff;
    border-radius: 4px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s;
    margin-top: auto;
    margin-bottom: 10px;
    width: auto;
    max-width: 180px;
    align-self: center;
    line-height: 1;
}

.pinnerpress-follow-button-text {
    margin-right: 5px;
    display: inline-block;
    line-height: 1;
}

.pinnerpress-follow-box-button .pinnerpress-pinterest-button-logo {
    width: 24px !important;
    height: 24px !important;
    display: inline-block !important;
    vertical-align: middle !important;
    fill: currentColor !important;
    pointer-events: none;
    transform: translateY(-1px);
    margin-left: 5px;
}

.pinnerpress-follow-box-button .pinnerpress-pinterest-button-logo path {
    fill: currentColor !important;
}

.pinnerpress-follow-box-button:hover {
    opacity: 0.9;
}

.pinnerpress-follow-box-affiliate {
    margin-top: 10px;
    text-align: center;
}

.pinnerpress-follow-box-affiliate a {
    color: #666;
    font-size: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

/* Opacity Slider Styles */
.pinnerpress-opacity-slider {
    width: 200px;
    vertical-align: middle;
    margin-right: 10px;
}

.pinnerpress-opacity-value {
    display: inline-block;
    min-width: 40px;
    font-weight: 500;
    vertical-align: middle;
}

/* Media Uploader Styles */
.pinnerpress-media-field {
    margin-bottom: 10px;
}

.pinnerpress-media-preview {
    margin-bottom: 10px;
    padding: 10px;
    border: 1px solid #ddd;
    background: #f9f9f9;
    display: inline-block;
    border-radius: 4px;
}

.pinnerpress-media-preview img {
    max-width: 200px;
    max-height: 120px;
    display: block;
}

.button-container {
    margin-bottom: 5px;
}

.pinnerpress-media-upload {
    margin-right: 5px !important;
    background-color: #E60023 !important;
    border-color: #E60023 !important;
    color: white !important;
    transition: all 0.3s ease;
}

.pinnerpress-media-upload:hover {
    background-color: #c7001e !important;
    border-color: #c7001e !important;
}

.pinnerpress-media-remove {
    background-color: #fff !important;
    color: #E60023 !important;
    border: 1px solid #E60023 !important;
    transition: all 0.3s ease;
}

.pinnerpress-media-remove:hover {
    background-color: #E60023 !important;
    color: white !important;
    border-color: #E60023 !important;
}

/* Make the slider look nicer in modern browsers */
.pinnerpress-opacity-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #E60023;
    cursor: pointer;
}

.pinnerpress-opacity-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #E60023;
    cursor: pointer;
    border: none;
}

.pinnerpress-follow-box-dismiss {
    margin-top: 10px;
    text-align: center;
}

.pinnerpress-follow-box-dismiss-link {
    color: #666;
    font-size: 12px;
    text-decoration: none;
    display: inline-block;
}

.pinnerpress-admin .pinnerpress-follow-box-button .pinnerpress-pinterest-button-logo,
.pinnerpress-settings-preview-container .pinnerpress-pinterest-button-logo,
.pinnerpress-follow-box-preview .pinnerpress-pinterest-button-logo {
    width: 16px !important;
    height: 16px !important;
    display: inline-block !important;
    vertical-align: middle !important;
    fill: currentColor !important;
    pointer-events: none;
    margin-left: 5px;
    position: relative;
    top: 0px;
}

.pinnerpress-admin .pinnerpress-follow-box-button .pinnerpress-pinterest-button-logo path,
.pinnerpress-settings-preview-container .pinnerpress-pinterest-button-logo path,
.pinnerpress-follow-box-preview .pinnerpress-pinterest-button-logo path {
    fill: currentColor !important;
} 

/* Premium/Freemium Styles */
.pinnerpress-premium-only.pinnerpress-disabled {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

.pinnerpress-premium-only.pinnerpress-disabled input,
.pinnerpress-premium-only.pinnerpress-disabled select,
.pinnerpress-premium-only.pinnerpress-disabled textarea,
.pinnerpress-premium-only.pinnerpress-disabled button {
    cursor: not-allowed;
    background: #f7f7f7;
    color: #888;
}

.pinnerpress-premium-disabled {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

.pinnerpress-premium-disabled::after {
    content: "🔒";
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 18px;
    color: #E60023;
    z-index: 100;
}

/* Blue upgrade notices (new Freemius style) */
.pinnerpress-upgrade-notice-blue {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 15px;
    margin: 20px 0;
}

.pinnerpress-upgrade-notice-blue h4 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #E60023;
    font-size: 16px;
    font-weight: 600;
}

.pinnerpress-upgrade-notice-blue p {
    margin-bottom: 15px;
    color: #333;
    line-height: 1.5;
}

.pinnerpress-upgrade-notice-blue .button-primary {
    background: #E60023 !important;
    border-color: #E60023 !important;
    color: #fff !important;
    transition: all 0.3s ease;
}

.pinnerpress-upgrade-notice-blue .button-primary:hover {
    background: #c7001e !important;
    border-color: #c7001e !important;
}

/* Top Performing Posts Table Styles */
.pinnerpress-top-posts-table {
    background: #fff;
    border: none;
    border-spacing: 0;
    width: 100%;
}

.pinnerpress-top-posts-table th {
    background: #fff !important;
    color: #333 !important;
    font-weight: 600;
    padding: 10px;
    border-bottom: 1px solid #ddd;
    text-align: left;
}

.pinnerpress-top-posts-table td {
    padding: 10px;
    border-bottom: 1px solid #f1f1f1;
    vertical-align: middle;
}

.pinnerpress-top-posts-table tr:hover {
    background-color: #f9f9f9;
}

.pinnerpress-top-posts-table .column-rank {
    text-align: center;
    font-weight: 600;
    color: #E60023;
}

.pinnerpress-top-posts-table .column-preview {
    text-align: center;
}

.pinnerpress-top-posts-table .column-title a {
    text-decoration: none;
    color: #0073aa;
    font-weight: 500;
}

.pinnerpress-top-posts-table .column-title a:hover {
    text-decoration: underline;
}

.pinnerpress-top-posts-table .column-clicks {
    text-align: center;
    font-weight: 600;
    color: #E60023;
}

.pinnerpress-top-posts-table .column-actions {
    text-align: center;
}

.pinnerpress-top-posts-table .button-small {
    font-size: 12px;
    padding: 4px 8px;
    height: auto;
    line-height: 1.4;
}

/* Global PinnerPress Button Styling */
.pinnerpress-admin .button-primary {
    background-color: #E60023 !important;
    border-color: #E60023 !important;
    color: white !important;
    transition: all 0.3s ease;
}

.pinnerpress-admin .button-primary:hover,
.pinnerpress-admin .button-primary:focus {
    background-color: #c7001e !important;
    border-color: #c7001e !important;
    color: white !important;
}

.pinnerpress-admin .button-secondary {
    background-color: #fff !important;
    color: #E60023 !important;
    border: 1px solid #E60023 !important;
    transition: all 0.3s ease;
}

.pinnerpress-admin .button-secondary:hover,
.pinnerpress-admin .button-secondary:focus {
    background-color: #E60023 !important;
    color: white !important;
    border-color: #E60023 !important;
}

/* Modal buttons */
.pinnerpress-admin .modal-content .button-primary {
    background-color: #E60023 !important;
    border-color: #E60023 !important;
    color: white !important;
}

.pinnerpress-admin .modal-content .button-primary:hover {
    background-color: #c7001e !important;
    border-color: #c7001e !important;
}

.pinnerpress-admin .modal-content .button-secondary {
    background-color: #fff !important;
    color: #E60023 !important;
    border: 1px solid #E60023 !important;
}

.pinnerpress-admin .modal-content .button-secondary:hover {
    background-color: #E60023 !important;
    color: white !important;
    border-color: #E60023 !important;
}

/* Image Analytics Modal Button Styling */
.image-detail-modal .button {
    background-color: #fff !important;
    color: #E60023 !important;
    border: 1px solid #E60023 !important;
    transition: all 0.3s ease;
    text-decoration: none !important;
    box-shadow: none !important;
}

.image-detail-modal .button:hover:not(:disabled) {
    background-color: #E60023 !important;
    color: white !important;
    border-color: #E60023 !important;
}

.image-detail-modal .button:disabled {
    background-color: #f1f1f1 !important;
    color: #666 !important;
    border-color: #ddd !important;
    cursor: not-allowed !important;
    opacity: 0.6 !important;
}

.image-detail-modal .button-secondary {
    background-color: #fff !important;
    color: #E60023 !important;
    border: 1px solid #E60023 !important;
}

.image-detail-modal .button-secondary:hover {
    background-color: #E60023 !important;
    color: white !important;
    border-color: #E60023 !important;
}

/* Previous/Next navigation buttons in modal */
.image-detail-modal .prev-image,
.image-detail-modal .next-image {
    background-color: #E60023 !important;
    border-color: #E60023 !important;
    color: white !important;
}

.image-detail-modal .prev-image:hover,
.image-detail-modal .next-image:hover {
    background-color: #c7001e !important;
    border-color: #c7001e !important;
}

/* Global PinnerPress Color Picker Styling */
.pinnerpress-admin .wp-color-picker-wrap .wp-color-picker {
    border: 1px solid #ccd0d4 !important;
    border-radius: 4px;
    transition: border-color 0.3s ease;
}

.pinnerpress-admin .wp-color-picker-wrap .wp-color-picker:focus {
    border-color: #999 !important;
    box-shadow: 0 0 0 1px #ccd0d4 !important;
}

.pinnerpress-admin .wp-color-picker-wrap .wp-picker-container .wp-color-result {
    border: 1px solid #ccd0d4 !important;
    border-radius: 4px 0 0 4px;
    transition: border-color 0.3s ease;
}

.pinnerpress-admin .wp-color-picker-wrap .wp-picker-container .wp-color-result:hover,
.pinnerpress-admin .wp-color-picker-wrap .wp-picker-container .wp-color-result:focus {
    border-color: #999 !important;
}

.pinnerpress-admin .wp-color-picker-wrap .wp-picker-container .wp-picker-input-wrap {
    border: 1px solid #ccd0d4 !important;
    border-left: none !important;
    border-radius: 0 4px 4px 0;
}

.pinnerpress-admin .wp-color-picker-wrap .wp-picker-container .wp-picker-input-wrap .wp-color-picker {
    border: none !important;
}

/* Color picker button styling */
.pinnerpress-admin .wp-picker-container .wp-color-result.button {
    /* background: none !important; */
    border: 1px solid #ccd0d4 !important;
    transition: all 0.3s ease;
}

.pinnerpress-admin .wp-picker-container .wp-color-result.button:hover {
    border-color: #999 !important;
    transform: none !important;
}

/* Focus states for accessibility */
.pinnerpress-admin .wp-picker-container .wp-color-result:focus {
    outline: 2px solid #ccd0d4;
    outline-offset: 2px;
}

/* PinnerPress Form Elements Styling */
/* Checkboxes - Red SVG checkmark, default border/background */
.pinnerpress-admin input[type="checkbox"]:checked::before {
    content: url(data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.83%204.89l1.34.94-5.81%208.38H9.02L5.78%209.67l1.34-1.25%202.57%202.4z%27%20fill%3D%27%23E60023%27%2F%3E%3C%2Fsvg%3E) !important;
    margin: -0.1875rem 0 0 -0.25rem;
    height: 1.3125rem;
    width: 1.3125rem;
}

/* Radio buttons */
.pinnerpress-admin input[type="radio"]:checked {
    background-color: #E60023 !important;
    border-color: #E60023 !important;
}

.pinnerpress-admin input[type="radio"]:checked::before {
    background-color: white !important;
}

.pinnerpress-admin input[type="radio"]:focus {
    border-color: #E60023 !important;
    box-shadow: 0 0 0 1px #E60023 !important;
}

/* Select dropdowns */
.pinnerpress-admin select:focus {
    border-color: #E60023 !important;
    box-shadow: 0 0 0 1px #E60023 !important;
}

.pinnerpress-admin select option:checked,
.pinnerpress-admin select option:hover {
    background-color: #E60023 !important;
    color: white !important;
}

/* Text inputs focus */
.pinnerpress-admin input[type="text"]:focus,
.pinnerpress-admin input[type="email"]:focus,
.pinnerpress-admin input[type="url"]:focus,
.pinnerpress-admin input[type="number"]:focus,
.pinnerpress-admin input[type="date"]:focus,
.pinnerpress-admin textarea:focus {
    border-color: #E60023 !important;
    box-shadow: 0 0 0 1px #E60023 !important;
}

/* Range slider thumb styling for all sliders */
.pinnerpress-admin input[type="range"]::-webkit-slider-thumb {
    background: #E60023 !important;
    border: 2px solid #fff !important;
}

.pinnerpress-admin input[type="range"]::-moz-range-thumb {
    background: #E60023 !important;
    border: 2px solid #fff !important;
}

.pinnerpress-admin input[type="range"]::-ms-thumb {
    background: #E60023 !important;
    border: 2px solid #fff !important;
}

/* WordPress Toggle switches */
.pinnerpress-admin .toggle-switch:checked {
    background-color: #E60023 !important;
}

.pinnerpress-admin .toggle-switch:checked::before {
    background-color: white !important;
}

/* Legacy red upgrade notices (kept for backward compatibility) */
.pinnerpress-upgrade-notice {
    background: linear-gradient(135deg, #E60023 0%, #BD081C 100%);
    color: white;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 4px 12px rgba(230, 0, 35, 0.2);
}

.pinnerpress-upgrade-notice-content {
    text-align: center;
}

.pinnerpress-upgrade-notice h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    font-weight: 600;
    color: white;
}

.pinnerpress-upgrade-notice p {
    margin: 0 0 15px 0;
    font-size: 14px;
    opacity: 0.9;
    color: white;
}

.pinnerpress-upgrade-button {
    background: white !important;
    color: #E60023 !important;
    border: none !important;
    padding: 12px 24px !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    display: inline-block !important;
}

.pinnerpress-upgrade-button:hover {
    background: #f0f0f0 !important;
    color: #BD081C !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1) !important;
}

/* Free user limitations notice */
.pinnerpress-free-limitation {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    padding: 15px;
    margin: 15px 0;
    color: #856404;
}

.pinnerpress-free-limitation .dashicons {
    color: #f39c12;
    margin-right: 5px;
}

/* Analytics limitations for free users */
.pinnerpress-analytics-limitation {
    background: #e3f2fd;
    border-left: 4px solid #2196f3;
    padding: 15px;
    margin: 15px 0;
    border-radius: 0 4px 4px 0;
}

.pinnerpress-analytics-limitation h4 {
    margin: 0 0 10px 0;
    color: #1976d2;
    font-size: 16px;
}

.pinnerpress-analytics-limitation p {
    margin: 0;
    color: #424242;
}

/* Settings section disabled styling */
.pinnerpress-settings-section.pinnerpress-premium-only.pinnerpress-disabled .form-table th,
.pinnerpress-settings-section.pinnerpress-premium-only.pinnerpress-disabled .form-table td {
    color: #888;
}

.pinnerpress-settings-section.pinnerpress-premium-only.pinnerpress-disabled h2 {
    color: #888;
}

/* Tab styling for premium tabs */
.nav-tab.pinnerpress-premium-tab:not(.nav-tab-active) {
    position: relative;
}

.nav-tab.pinnerpress-premium-tab:not(.nav-tab-active)::after {
    content: "🔒";
    margin-left: 5px;
    font-size: 12px;
}

/* Select2 styling improvements for Image Analytics */
.pinnerpress-image-analytics-page .select2-container--default .select2-selection--single {
    height: 40px;
    line-height: 40px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.pinnerpress-image-analytics-page .select2-container--default .select2-selection--single .select2-selection__rendered {
    padding-left: 12px;
    line-height: 38px;
}

.pinnerpress-image-analytics-page .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 38px;
}

.pinnerpress-image-analytics-page .select2-dropdown {
    border: 1px solid #ddd;
    border-radius: 0 0 4px 4px;
    border-top: none;
}

.pinnerpress-image-analytics-page .select2-search--dropdown .select2-search__field {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.pinnerpress-image-analytics-page .select2-results__option {
    padding: 10px 12px;
}

.pinnerpress-image-analytics-page .select2-results__option--highlighted[aria-selected] {
    background-color: #E60023;
}

.pinnerpress-image-analytics-page .select2-results__message {
    padding: 10px 12px;
    color: #666;
}

/* Remove focus outlines and blue line artifacts - Comprehensive approach */
.pinnerpress-image-analytics-page *:focus,
.pinnerpress-image-analytics-page *:active,
.pinnerpress-image-analytics-page *:focus-visible,
.pinnerpress-image-analytics-page *:focus-within {
    outline: none !important;
    box-shadow: none !important;
    -webkit-tap-highlight-color: transparent !important;
}

/* Remove browser default focus styles from all interactive elements */
.pinnerpress-image-analytics-page input:focus,
.pinnerpress-image-analytics-page textarea:focus,
.pinnerpress-image-analytics-page select:focus,
.pinnerpress-image-analytics-page button:focus,
.pinnerpress-image-analytics-page a:focus,
.pinnerpress-image-analytics-page div:focus,
.pinnerpress-image-analytics-page span:focus,
.pinnerpress-image-analytics-page *[tabindex]:focus,
.pinnerpress-image-analytics-page *[role="button"]:focus,
.pinnerpress-image-analytics-page *[onclick]:focus {
    outline: none !important;
    box-shadow: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

/* Remove any blue highlight on touch devices */
.pinnerpress-image-analytics-page *,
.pinnerpress-image-analytics-page *:before,
.pinnerpress-image-analytics-page *:after {
    -webkit-tap-highlight-color: rgba(0,0,0,0) !important;
    -webkit-tap-highlight-color: transparent !important;
}

/* Specific fix for post links that cause blue line artifacts */
.pinnerpress-post-link,
.pinnerpress-post-link:link,
.pinnerpress-post-link:visited,
.pinnerpress-post-link:hover,
.pinnerpress-post-link:active,
.pinnerpress-post-link:focus,
.pinnerpress-post-link:focus-visible {
    text-decoration: none !important;
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
    background: none !important;
    color: inherit !important;
    -webkit-tap-highlight-color: transparent !important;
}

/* Ensure child elements don't inherit unwanted styles */
.pinnerpress-post-link *,
.pinnerpress-post-link *:focus,
.pinnerpress-post-link *:active,
.pinnerpress-post-link *:hover {
    text-decoration: none !important;
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
    -webkit-tap-highlight-color: transparent !important;
}

/* Remove focus from the image container and stats */
.pinnerpress-post-image-container,
.pinnerpress-post-image-container:focus,
.pinnerpress-post-stats,
.pinnerpress-post-stats:focus,
.pinnerpress-post-image,
.pinnerpress-post-image:focus,
.pinnerpress-post-clicks,
.pinnerpress-post-clicks:focus,
.pinnerpress-post-title,
.pinnerpress-post-title:focus {
    outline: none !important;
    box-shadow: none !important;
    text-decoration: none !important;
    border: none !important;
    -webkit-tap-highlight-color: transparent !important;
}

.pinnerpress-image-analytics-page .select2-container--default .select2-selection--single:focus {
    outline: none !important;
    box-shadow: none !important;
    border-color: #ddd !important;
}

.pinnerpress-image-analytics-page .select2-container--default.select2-container--focus .select2-selection--single {
    outline: none !important;
    box-shadow: none !important;
    border-color: #ddd !important;
}

/* WordPress admin specific overrides */
.pinnerpress-image-analytics-page .wp-admin * {
    outline: none !important;
    box-shadow: none !important;
}

/* Force override any WordPress focus styles */
.pinnerpress-image-analytics-page .wp-admin *:focus,
.pinnerpress-image-analytics-page .wp-admin *:active,
.pinnerpress-image-analytics-page .wp-admin *:focus-visible {
    outline: none !important;
    box-shadow: none !important;
    border-color: inherit !important;
}

/* Specific WordPress button overrides */
.pinnerpress-image-analytics-page .wp-admin .button:focus,
.pinnerpress-image-analytics-page .wp-admin .button-primary:focus,
.pinnerpress-image-analytics-page .wp-admin .button-secondary:focus {
    outline: none !important;
    box-shadow: none !important;
    border-color: inherit !important;
}

.pinnerpress-image-analytics-page .select2-dropdown {
    outline: none !important;
    box-shadow: none !important;
}

.pinnerpress-image-analytics-page .select2-search--dropdown .select2-search__field:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Remove focus outlines from buttons and controls */
.pinnerpress-image-analytics-page button:focus,
.pinnerpress-image-analytics-page .button:focus,
.pinnerpress-image-analytics-page input:focus,
.pinnerpress-image-analytics-page select:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Remove focus outlines from image cards and clickable elements */
.image-card:focus,
.image-card *:focus,
.image-preview:focus,
.image-preview *:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Remove focus outlines from modal elements */
.image-detail-modal *:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Ensure no blue outlines appear on any clickable elements */
.pinnerpress-image-analytics-page a:focus,
.pinnerpress-image-analytics-page div:focus,
.pinnerpress-image-analytics-page span:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Image Analytics Grid Styles */
.image-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.image-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none !important;
    box-shadow: none !important;
}

.image-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #E60023;
    outline: none !important;
}

.image-card:focus,
.image-card:active {
    outline: none !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    border-color: #E60023 !important;
}

.image-card.no-clicks {
    opacity: 0.7;
}

.image-preview {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: #f5f5f5;
    outline: none !important;
}

.image-preview:focus {
    outline: none !important;
}

.image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
    outline: none !important;
}

.image-card:hover .image-preview img {
    transform: scale(1.05);
}

.image-card-body {
    padding: 15px;
}

.image-name {
    font-weight: 600;
    font-size: 14px;
    color: #333;
    margin-bottom: 10px;
    word-break: break-word;
}

.image-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.stat-item {
    text-align: center;
}

.stat-label {
    font-size: 11px;
    color: #666;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.stat-number {
    font-size: 18px;
    font-weight: 600;
    color: #E60023;
}

/* Modal Styles */
.image-detail-modal {
    display: none;
    position: fixed;
    z-index: 100000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    outline: none !important;
}

.image-detail-modal .modal-content {
    position: relative;
    background-color: #fff;
    margin: 2% auto;
    padding: 0;
    width: 90%;
    max-width: 1200px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 8px;
    outline: none !important;
}

.image-detail-modal .close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
    z-index: 1001;
    outline: none !important;
}

.image-detail-modal .close:hover {
    color: #E60023;
}

.image-detail-modal .modal-body {
    padding: 20px;
    outline: none !important;
}

.image-detail-modal h2 {
    margin-top: 0;
    color: #E60023;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

/* Premium Feature Styling */

/* Upgrade Banner */
.pinnerpress-upgrade-banner {
    background: linear-gradient(135deg, #E60023 0%, #c7001e 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 20px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(230, 0, 35, 0.2);
}

.pinnerpress-upgrade-content {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
}

.pinnerpress-upgrade-icon {
    font-size: 24px;
}

.pinnerpress-upgrade-text {
    font-weight: 500;
    font-size: 16px;
}

.pinnerpress-upgrade-btn {
    background: white !important;
    color: #E60023 !important;
    border: none !important;
    padding: 10px 20px !important;
    border-radius: 6px !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
}

.pinnerpress-upgrade-btn:hover {
    background: #f8f9fa !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Premium Tab Styling */
.pinnerpress-premium-tab {
    position: relative;
    opacity: 0.7;
}

.pinnerpress-disabled-tab {
    cursor: not-allowed;
}

.pinnerpress-premium-badge {
    background: #E60023;
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 5px;
    font-weight: bold;
}

/* Premium Disabled Elements */
.pinnerpress-premium-disabled {
    opacity: 0.5;
    cursor: not-allowed;
    position: relative;
}

.pinnerpress-premium-disabled:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
}

/* Premium Tab Content Overlay */
.pinnerpress-premium-tab-content {
    position: relative;
}

.pinnerpress-premium-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pinnerpress-disabled-preview {
    filter: blur(2px);
    pointer-events: none;
}

/* Limitation Notice */
.pinnerpress-limitation-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 6px;
    padding: 15px;
    margin: 20px 0;
}

.pinnerpress-limitation-notice h4 {
    margin-top: 0;
    color: #856404;
}

.pinnerpress-limitation-notice ul {
    margin-bottom: 0;
    color: #856404;
}

/* Additional styling for date controls in free version */
.pinnerpress-date-preset.pinnerpress-premium-disabled {
    opacity: 0.5 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
    background-color: #f7f7f7 !important;
    border-color: #d3d3d3 !important;
    color: #999 !important;
}

.pinnerpress-date-preset.pinnerpress-premium-disabled:hover {
    background-color: #f7f7f7 !important;
    border-color: #d3d3d3 !important;
    color: #999 !important;
    transform: none !important;
    box-shadow: none !important;
}

/* Style for readonly date inputs */
input[type="date"][readonly] {
    background-color: #f9f9f9 !important;
    cursor: not-allowed !important;
    opacity: 0.7;
}

/* Detailed upgrade banner styles */
.pinnerpress-detailed-upgrade-banner {
    background: linear-gradient(135deg, #E60023 0%, #c7001e 100%);
    color: white;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 2px 10px rgba(230, 0, 35, 0.2);
}

.pinnerpress-detailed-upgrade-banner h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    font-weight: 600;
}

.pinnerpress-detailed-upgrade-banner p {
    margin: 10px 0;
    line-height: 1.5;
}

.pinnerpress-detailed-upgrade-banner .button-primary {
    background: white !important;
    color: #E60023 !important;
    border: none !important;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.pinnerpress-detailed-upgrade-banner .button-primary:hover {
    background: #f5f5f5 !important;
    color: #c7001e !important;
}

/* Activation notice styling - keep simple and focused on setup */
.pinnerpress-activation-notice strong {
    color: #1d2327;
    font-weight: 600;
}

.pinnerpress-activation-notice p {
    margin: 8px 0;
    line-height: 1.5;
}

input[type="date"][readonly]:focus {
    box-shadow: none !important;
    border-color: #ddd !important;
}

/* Disabled Feature Styling for Free Users */
.pinnerpress-disabled-feature {
    position: relative;
}

.pinnerpress-disabled-feature .pinnerpress-premium-notice-top {
    background: linear-gradient(135deg, #E60023 0%, #BD081C 100%);
    color: white;
    padding: 20px;
    margin: -20px -20px 20px -20px;
    border-radius: 4px 4px 0 0;
    text-align: center;
}

.pinnerpress-disabled-feature .pinnerpress-premium-notice-top h4 {
    color: white;
    margin: 0 0 10px 0;
    font-size: 18px;
}

.pinnerpress-disabled-feature .pinnerpress-premium-notice-top p {
    color: white;
    margin: 0 0 15px 0;
}

.pinnerpress-disabled-feature .pinnerpress-premium-notice-top .button-primary {
    background: white !important;
    color: #E60023 !important;
    border: none !important;
    font-weight: 600;
    padding: 8px 20px;
    margin: 0 5px;
}

.pinnerpress-disabled-feature .pinnerpress-premium-notice-top .button-primary:hover {
    background: #f5f5f5 !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Make disabled inputs look properly disabled */
.pinnerpress-disabled-feature input[disabled],
.pinnerpress-disabled-feature select[disabled],
.pinnerpress-disabled-feature textarea[disabled],
.pinnerpress-disabled-feature button[disabled] {
    opacity: 0.6;
    cursor: not-allowed !important;
    background-color: #f5f5f5 !important;
}

.pinnerpress-disabled-feature .button[disabled] {
    opacity: 0.5;
    cursor: not-allowed !important;
}

/* Color picker disabled state */
.pinnerpress-disabled-feature .wp-picker-container .wp-color-result {
    pointer-events: none;
    opacity: 0.6;
}

.pinnerpress-disabled-feature .wp-picker-container button {
    pointer-events: none;
    opacity: 0.6;
}

/* Make labels in disabled sections slightly dimmed */
.pinnerpress-disabled-feature .form-table th {
    opacity: 0.8;
}

/* Keep preview visible for disabled features */
.pinnerpress-disabled-feature .pinnerpress-preview-column {
    position: relative;
}

/* Feature Description Boxes */
.pinnerpress-feature-description {
    margin: 20px 0;
    padding: 0 20px;
}

.pinnerpress-feature-box {
    background: #f7f7f7;
    border: 1px solid #e1e1e1;
    border-radius: 4px;
    padding: 15px 20px;
    margin-bottom: 20px;
}

.pinnerpress-feature-box h3 {
    margin: 0 0 10px 0;
    color: #E60023;
    font-size: 16px;
    font-weight: 600;
}

.pinnerpress-feature-box p {
    margin: 0 0 10px 0;
    color: #555;
    line-height: 1.6;
    font-size: 14px;
}

.pinnerpress-feature-box p:last-child {
    margin-bottom: 0;
}

.pinnerpress-feature-box .pinnerpress-premium-notice {
    color: #E60023;
    font-style: italic;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #e1e1e1;
}