/* ADA Compliance Guardian - Admin Styles */

/* --- Global Page Styles --- */
.adacogu-guardian-page {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    background-color: #f0f0f1;
    /* WordPress Admin Background */
    padding-bottom: 40px;
}

.adacogu-guardian-header {
    background-color: #ffffff;
    padding: 25px 30px;
    border-bottom: 1px solid #ccd0d4;
    margin: -20px -20px 20px -20px;
    /* Extend to edges of .wrap padding */
    box-shadow: 0 1px 1px rgba(0, 0, 0, .04);
}

.adacogu-guardian-logo-title {
    display: flex;
    align-items: center;
    margin-bottom: 5px;
}

.adacogu-guardian-header h1 {
    font-size: 24px;
    font-weight: 600;
    color: #1d2327;
    margin: 0;
    line-height: 1.3;
}

.adacogu-guardian-tagline {
    font-size: 14px;
    color: #50575e;
    margin-top: 0;
}

.adacogu-guardian-content {
    margin-top: 20px;
}

.adacogu-guardian-card {
    background-color: #fff;
    border: 1px solid #ccd0d4;
    box-shadow: 0 1px 1px rgba(0, 0, 0, .04);
    padding: 20px 25px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.adacogu-guardian-card h2,
.adacogu-guardian-card h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1d2327;
    margin-top: 0;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.adacogu-guardian-card p {
    font-size: 14px;
    line-height: 1.6;
    color: #3c434a;
}

.adacogu-guardian-card p.description {
    font-size: 13px;
    color: #787c82;
}

/* --- Forms & Inputs --- */
.adacogu-guardian-form .form-field {
    margin-bottom: 20px;
}

.adacogu-guardian-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1d2327;
}

.adacogu-guardian-input,
.adacogu-guardian-textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #8c8f94;
    border-radius: 3px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .07);
    font-size: 14px;
    line-height: 1.5;
    box-sizing: border-box;
    /* Important for width 100% */
}

.adacogu-guardian-input:focus,
.adacogu-guardian-textarea:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
    outline: none;
}

.adacogu-guardian-textarea {
    min-height: 80px;
    resize: vertical;
}

/* --- Buttons --- */
.adacogu-guardian-button,
.adacogu-guardian-button-primary,
.adacogu-guardian-button-secondary {
    padding: 8px 16px;
    font-size: 14px;
    border-radius: 3px;
    text-decoration: none;
    cursor: pointer;
    border-width: 1px;
    border-style: solid;
    line-height: 1.5;
    transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, color 0.15s ease-in-out;
}

.adacogu-guardian-button-primary {
    /* WordPress primary style */
    background: #2271b1;
    border-color: #2271b1;
    color: #fff;
    text-shadow: none;
}

.adacogu-guardian-button-primary:hover,
.adacogu-guardian-button-primary:focus {
    background: #135e96;
    border-color: #135e96;
    color: #fff;
}

.adacogu-guardian-button-secondary {
    /* WordPress secondary style */
    background: #f6f7f7;
    border-color: #007cba;
    /* WP uses this for secondary button borders too */
    color: #007cba;
}

.adacogu-guardian-button-secondary:hover,
.adacogu-guardian-button-secondary:focus {
    background: #f0f0f1;
    border-color: #016087;
    color: #016087;
}

.adacogu-guardian-button-disabled,
/* For JS to use */
.adacogu-guardian-button:disabled {
    background-color: #d1d1d1 !important;
    border-color: #c1c1c1 !important;
    color: #777 !important;
    cursor: not-allowed !important;
}

/* --- Notices --- */
.adacogu-guardian-notice {
    margin: 15px 0;
    padding: 12px 15px;
    border-left-width: 4px;
    border-left-style: solid;
    border-radius: 3px;
}

.adacogu-guardian-notice-success {
    border-left-color: #4caf50;
    /* Green */
    background-color: #f1f8e9;
}

.adacogu-guardian-notice-error {
    border-left-color: #f44336;
    /* Red */
    background-color: #ffebee;
}

.adacogu-guardian-notice p {
    margin: 0;
    padding: 0;
}

/* --- Alt Generator Page Specifics --- */
.adacogu-controls-bar {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 3px;
}

#adacogu-image-name-filter {
    max-width: 400px;
}

.adacogu-bulk-actions-panel {
    margin-bottom: 25px;
    padding-top: 10px;
}

.adacogu-bulk-buttons button {
    margin-right: 8px;
    margin-bottom: 8px;
    /* For wrapping */
}

#adacogu-bulk-progress-container {
    width: 100%;
    background-color: #e0e0e0;
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-top: 15px;
    height: 26px;
    box-sizing: border-box;
    overflow: hidden;
    /* Clip the inner bar */
}

#adacogu-bulk-progress-bar {
    width: 0%;
    height: 100%;
    background-color: #2271b1;
    /* WordPress Blue */
    text-align: center;
    line-height: 26px;
    color: white;
    font-weight: bold;
    border-radius: 3px;
    /* Slightly smaller to fit inside */
    transition: width 0.3s ease-in-out;
}

#adacogu-bulk-progress-bar.warning {
    background-color: #ffb900;
    /* WordPress Yellow/Orange */
}

#adacogu-bulk-progress-bar.error {
    background-color: #d63638;
    /* WordPress Red */
}

.adacogu-status-message {
    margin-top: 10px;
    font-weight: 500;
    padding: 8px;
    border-radius: 3px;
}

.adacogu-status-message.status-success {
    background-color: #e8f5e9;
    color: #2e7d32;
}

.adacogu-status-message.status-error {
    background-color: #ffebee;
    color: #c62828;
}

.adacogu-status-message.status-warning {
    background-color: #fff3e0;
    color: #ef6c00;
}

.adacogu-status-message.status-info {
    background-color: #e3f2fd;
    color: #1565c0;
}


/* --- Table Styles --- */
.adacogu-guardian-table {
    margin-top: 20px;
    border-collapse: collapse;
    /* More modern look */
}

.adacogu-guardian-table th {
    background-color: #f5f5f5;
    color: #333;
    font-weight: 600;
    text-align: left;
    padding: 12px 10px;
    border-bottom: 2px solid #e0e0e0;
}

.adacogu-guardian-table td {
    padding: 12px 10px;
    vertical-align: top;
    /* Align content to top */
    border-bottom: 1px solid #eee;
}

.adacogu-guardian-table tbody tr:hover {
    background-color: #f9f9f9;
}

.adacogu-col-image {
    width: 120px;
}

.adacogu-col-details {
    width: auto;
}

/* Takes remaining space */
.adacogu-col-actions {
    width: 35%;
    min-width: 280px;
}

.thumbnail-cell img.adacogu-image-thumb {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 3px;
    border: 1px solid #ddd;
}

.details-cell strong {
    font-size: 14px;
    color: #1d2327;
    display: block;
    /* Ensure it's on its own line */
    margin-bottom: 4px;
}

.adacogu-filename-link {
    font-size: 13px;
    color: #0073aa;
    word-break: break-all;
    /* Prevent long filenames from breaking layout */
}

.details-cell em {
    color: #50575e;
    font-style: normal;
}

.current-alt-text {
    color: #3c434a;
    display: inline-block;
    /* Allows margin if needed */
    background-color: #f0f0f1;
    padding: 2px 5px;
    border-radius: 3px;
    font-size: 0.9em;
}

.alt-status {
    display: inline-block;
    padding: 3px 6px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
    margin-top: 4px;
}

.alt-missing {
    background-color: #fff0f0;
    color: #d9534f;
    border: 1px solid #d9534f;
}

.alt-present {
    background-color: #e6ffed;
    color: #4CAF50;
    border: 1px solid #4CAF50;
}

.actions-cell .button {
    margin-right: 8px;
    margin-bottom: 8px;
    /* If they wrap */
}

.gemini-alt-text-result {
    margin-top: 10px;
    padding: 12px;
    border: 1px solid transparent;
    border-radius: 3px;
    background-color: #fdfdfd;
}

.gemini-alt-text-result.result-success {
    border-color: #4CAF50;
    background-color: #f1f8e9;
}

.gemini-alt-text-result.result-error {
    border-color: #f44336;
    background-color: #ffebee;
}

.gemini-alt-text-result strong {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
}

.gemini-alt-text-result .editable-alt-text {
    /* Inherits .adacogu-guardian-textarea */
    margin-top: 5px !important;
    margin-bottom: 10px;
}

.gemini-alt-text-result .action-buttons .button {
    margin-top: 0;
}

.save-status-message {
    font-size: 0.9em;
    margin-top: 8px !important;
    /* Override general p margins if needed */
    padding: 5px 8px;
    border-radius: 3px;
}

.save-status-message.status-success {
    color: #2e7d32;
    background-color: #e8f5e9;
}

.save-status-message.status-error {
    color: #c62828;
    background-color: #ffebee;
}

.save-status-message.status-info {
    color: #1565c0;
    background-color: #e3f2fd;
}


/* Footer */
.adacogu-guardian-footer {
    margin: 30px -20px -40px -20px;
    /* Extend to edges of .wrap padding */
    padding: 20px;
    text-align: center;
    background-color: #fff;
    border-top: 1px solid #ccd0d4;
    font-size: 13px;
    color: #50575e;
}

.adacogu-guardian-footer p {
    margin: 0;
}

/* Spinner alignment */
.spinner.is-active {
    vertical-align: middle;
    margin-right: 5px;
}

.notice,
.notice-warning,
.notice-error,
.notice-success,
.notice-info,
.update-nag {
    display: none !important;
}

/* --- Base Button Style (Apply to all relevant buttons) --- */
.adacogu-guardian-page .button,
.adacogu-guardian-page .button-primary,
/* WordPress Core class */
.adacogu-guardian-page .button-secondary {
    /* WordPress Core class */
    display: inline-flex;
    /* For aligning icons and text */
    align-items: center;
    justify-content: center;
    padding: 10px 18px;
    /* Slightly more padding for a modern feel */
    font-size: 14px;
    /* Or 13px depending on WP admin consistency */
    font-weight: 500;
    /* Semi-bold for clarity */
    line-height: 1.4;
    text-decoration: none;
    border-radius: 4px;
    /* Consistent rounded corners */
    border-width: 1px;
    border-style: solid;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    /* Subtle shadow */
    transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    margin-right: 8px;
    /* Spacing between buttons */
    margin-bottom: 8px;
    /* For wrapping */
    white-space: nowrap;
    /* Prevent text wrapping on small buttons */
}

/* --- Primary Button Style --- */
/* For "Save All Visible Suggestions" and individual "Save This Alt" when active */
.adacogu-guardian-page .button-primary,
.adacogu-guardian-page .adacogu-guardian-button-primary {
    /* Your custom class if needed */
    background-color: #0073aa;
    /* WordPress Blue - good primary color */
    border-color: #006597;
    /* Slightly darker border */
    color: #ffffff;
}

.adacogu-guardian-page .button-primary:hover,
.adacogu-guardian-page .adacogu-guardian-button-primary:hover {
    background-color: #006597;
    border-color: #005077;
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.adacogu-guardian-page .button-primary:focus,
.adacogu-guardian-page .adacogu-guardian-button-primary:focus {
    outline: 2px solid transparent;
    /* Remove default outline */
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #0073aa;
    /* Custom focus ring */
}


/* --- Secondary Button Style --- */
/* For "Generate for All Missing Alt Texts", "Regenerate All for SEO & ADA",
  individual "Generate Alt Text" / "Regenerate" */
.adacogu-guardian-page .button-secondary,
.adacogu-guardian-page .adacogu-guardian-button-secondary {
    /* Your custom class */
    background-color: #f6f7f7;
    /* Light gray, standard WP secondary */
    border-color: #dcdcde;
    /* Neutral border */
    color: #2c3338;
    /* Dark gray text for good contrast */
}

.adacogu-guardian-page .button-secondary:hover,
.adacogu-guardian-page .adacogu-guardian-button-secondary:hover {
    background-color: #f0f0f1;
    border-color: #c8c8c8;
    color: #1d2327;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.adacogu-guardian-page .button-secondary:focus,
.adacogu-guardian-page .adacogu-guardian-button-secondary:focus {
    outline: 2px solid transparent;
    box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #7e8993;
    /* Focus ring for secondary */
}

/* Icon styling within buttons (if you add them) */
.adacogu-guardian-page .button .dashicons {
    margin-right: 6px;
    font-size: 18px;
    /* Adjust as needed */
    line-height: 1;
    /* Ensure proper vertical alignment */
}

/* Specifically for the "Regenerate All for SEO & ADA" button which has an icon */
#regenerate-seo-ada-button .dashicons {
    vertical-align: text-bottom;
    /* Keeps existing style if it works well */
    margin-right: 5px;
}


/* Disabled State - Crucial for usability */
.adacogu-guardian-page .button:disabled,
.adacogu-guardian-page .button-primary:disabled,
.adacogu-guardian-page .button-secondary:disabled,
.adacogu-guardian-page .adacogu-guardian-button-disabled {
    /* Your custom disabled class */
    background-color: #e0e0e0 !important;
    border-color: #c8c8c8 !important;
    color: #a0a5aa !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}

/* --- Button Grouping (Example for Bulk Actions) --- */
.adacogu-bulk-actions-panel .adacogu-bulk-buttons {
    /* Assuming you have a container */
    display: flex;
    flex-wrap: wrap;
    /* Allow buttons to wrap on smaller screens */
    gap: 10px;
    /* Spacing between buttons in a group */
    margin-bottom: 15px;
}

/* Individual action buttons in the table */
.adacogu-guardian-table .actions-cell .button {
    /* Base style is already applied, specific overrides if needed */
}

.adacogu-guardian-table .actions-cell .gemini-alt-text-result .action-buttons .button {
    /* Style for save button that appears after generation */
    margin-top: 8px;
}

.adacogu-guardian-logo-icon {
    font-size: 25px !important;
    color: #2271b1;
    /* WordPress Blue */
    margin-right: 10px;
    line-height: 1;
}