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

#toplevel_page_ai-magic-menu .wp-menu-image img {
    width: 22px;
    height: 22px;
}

/* AI Magic Menu Color */
#adminmenu .toplevel_page_ai-magic-settings .wp-menu-name,
#adminmenu .toplevel_page_ai-magic-settings:hover .wp-menu-name,
#adminmenu .toplevel_page_ai-magic-settings.current .wp-menu-name,
#adminmenu .toplevel_page_ai-magic-settings.wp-has-current-submenu .wp-menu-name,
a.toplevel_page_ai-magic-menu {
    color: #c8ff2a !important;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border-left-color: #09f;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Analytics & History Page Styles */
.ai-magic-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.ai-magic-stat-card {
    background: #fff;
    padding: 24px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.ai-magic-stat-card h3 {
    margin: 0 0 10px 0;
    font-size: 14px;
    color: #6b7280;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.ai-magic-stat-card .value {
    font-size: 32px;
    font-weight: 700;
    color: #111827;
}

.ai-magic-badge {
    background: #e0e7ff;
    color: #3730a3;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

/* Modal Styles */
.ai-magic-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

.ai-magic-modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 0;
    border: 1px solid #888;
    width: 60%;
    max-width: 800px;
    border-radius: 8px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.ai-magic-modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ai-magic-modal-header h2 {
    margin: 0;
    font-size: 18px;
    color: #111827;
}

.ai-magic-close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
}

.ai-magic-close:hover,
.ai-magic-close:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

.ai-magic-modal-body {
    padding: 20px;
    max-height: 70vh;
    overflow-y: auto;
}

.ai-magic-modal-section {
    margin-bottom: 20px;
}

.ai-magic-modal-section h3 {
    margin-top: 0;
    font-size: 14px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.ai-magic-modal-content-box {
    background: #f9fafb;
    padding: 15px;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    white-space: pre-wrap;
    font-family: monospace;
    font-size: 13px;
    color: #374151;
}