/**
 * Styles CSS pour l'administration WpDoliProspect
 */

/* Styles généraux pour l'admin */
.business-forms-for-doliprospect-admin {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    line-height: 1.6;
    color: #333;
}

.business-forms-for-doliprospect-admin * {
    box-sizing: border-box;
}

/* Cartes d'information */
.business-forms-for-doliprospect-card {
    background: #ffffff;
    border: 1px solid #ccd0d4;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    transition: box-shadow 0.3s ease;
}

.business-forms-for-doliprospect-card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.business-forms-for-doliprospect-card h3 {
    margin-top: 0;
    color: #23282d;
    font-size: 1.2rem;
    font-weight: 600;
}

/* Exemples de shortcodes */
.shortcode-example {
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 4px;
    border-left: 4px solid #007cba;
}

.shortcode-example code {
    background: #e9ecef;
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9rem;
    display: block;
    margin-bottom: 0.5rem;
    color: #495057;
}

.shortcode-example p {
    margin: 0;
    font-size: 0.9rem;
    color: #6c757d;
}

/* Statut de connexion */
.connection-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem;
    border-radius: 4px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
}

.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.status-indicator.success {
    background-color: #28a745;
    box-shadow: 0 0 0 2px rgba(40,167,69,0.2);
}

.status-indicator.error {
    background-color: #dc3545;
    box-shadow: 0 0 0 2px rgba(220,53,69,0.2);
}

.status-indicator.warning {
    background-color: #ffc107;
    box-shadow: 0 0 0 2px rgba(255,193,7,0.2);
}

.connection-status span:last-child {
    font-weight: 500;
    color: #23282d;
}

.connection-status-ok {
    background: #edfaef;
    border: 1px solid #b8e6bf;
}

.connection-status-ko {
    background: #fcf0f1;
    border: 1px solid #f1aeb5;
}

.bfdp-connection-detail {
    margin: 10px 0 0;
    font-size: 13px;
    color: #555;
    line-height: 1.5;
}

.bfdp-connection-detail-error {
    color: #b32d2e;
}

.bfdp-api-key-notice {
    margin: 0 0 12px;
    max-width: 600px;
}

.bfdp-api-key-notice p {
    margin: 0.5em 0;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.bfdp-api-key-status {
    margin-top: 10px !important;
}

.bfdp-api-key-status-ok,
.bfdp-api-key-status-error {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.bfdp-api-key-status-ok {
    color: #007017;
}

.bfdp-api-key-status-error {
    color: #b32d2e;
}

/* Amélioration des formulaires WordPress */
.form-table th {
    font-weight: 600;
    color: #23282d;
    padding: 15px 10px;
}

.form-table td {
    padding: 15px 10px;
}

.form-table td .regular-text {
    width: 100%;
    max-width: 400px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-table td .description {
    color: #666;
    font-style: italic;
    margin-top: 0.5rem;
    font-size: 13px;
}

/* Boutons personnalisés */
.button.button-primary {
    background: linear-gradient(135deg, #007cba 0%, #005a87 100%);
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.button.button-primary:hover {
    background: linear-gradient(135deg, #005a87 0%, #004466 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,124,186,0.3);
}

.button.button-secondary {
    background: #6c757d;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.button.button-secondary:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

/* Messages de statut */
.notice {
    border-left: 4px solid;
    padding: 12px;
    margin: 15px 0;
    border-radius: 0 4px 4px 0;
}

.notice.notice-success {
    border-left-color: #28a745;
    background: #d4edda;
    color: #155724;
}

.notice.notice-error {
    border-left-color: #dc3545;
    background: #f8d7da;
    color: #721c24;
}

.notice.notice-warning {
    border-left-color: #ffc107;
    background: #fff3cd;
    color: #856404;
}

.notice.notice-info {
    border-left-color: #17a2b8;
    background: #d1ecf1;
    color: #0c5460;
}

/* Table des soumissions */
.wp-list-table {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.wp-list-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
}

.wp-list-table td {
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

.wp-list-table tr:hover {
    background: #f8f9fa;
}

/* Badges de statut */
.status-badge {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge.status-success {
    background: #d4edda;
    color: #155724;
}

.status-badge.status-error {
    background: #f8d7da;
    color: #721c24;
}

.status-badge.status-pending {
    background: #fff3cd;
    color: #856404;
}

/* Modal */
.business-forms-for-doliprospect-modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(2px);
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 0;
    border-radius: 8px;
    width: 80%;
    max-width: 800px;
    max-height: 80%;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #e1e5e9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
    border-radius: 8px 8px 0 0;
}

.modal-header h2 {
    margin: 0;
    color: #333;
    font-size: 1.5rem;
}

.close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #000;
}

.modal-body {
    padding: 20px;
}

.details-section {
    margin-bottom: 30px;
}

.details-section h3 {
    margin-bottom: 10px;
    color: #333;
    font-size: 1.2rem;
    border-bottom: 2px solid #007cba;
    padding-bottom: 5px;
}

.details-section pre {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    border: 1px solid #e1e5e9;
    overflow-x: auto;
    font-size: 12px;
    line-height: 1.4;
    color: #495057;
}

/* Pagination */
.business-forms-for-doliprospect-pagination {
    margin-top: 20px;
    text-align: center;
}

.business-forms-for-doliprospect-pagination .page-numbers {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 2px;
    text-decoration: none;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #333;
    transition: all 0.3s ease;
}

.business-forms-for-doliprospect-pagination .page-numbers:hover,
.business-forms-for-doliprospect-pagination .page-numbers.current {
    background: #007cba;
    color: white;
    border-color: #007cba;
}

/* Documentation */
.business-forms-for-doliprospect-docs {
    display: flex;
    gap: 30px;
    margin-top: 20px;
}

.docs-nav {
    flex: 0 0 250px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    height: fit-content;
    position: sticky;
    top: 20px;
    border: 1px solid #e9ecef;
}

.docs-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.docs-nav li {
    margin-bottom: 8px;
}

.docs-nav a {
    display: block;
    padding: 8px 12px;
    text-decoration: none;
    color: #333;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.docs-nav a:hover,
.docs-nav a.active {
    background: #007cba;
    color: white;
}

.docs-content {
    flex: 1;
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: 1px solid #e9ecef;
}

.docs-content section {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #e1e5e9;
}

.docs-content section:last-child {
    border-bottom: none;
}

.docs-content h2 {
    color: #007cba;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #007cba;
    font-size: 1.8rem;
}

.docs-content h3 {
    color: #333;
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.docs-content pre {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    border: 1px solid #e1e5e9;
    overflow-x: auto;
    margin: 15px 0;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.docs-content code {
    background: #f8f9fa;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9em;
    color: #e83e8c;
}

/* Support cards */
.support-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.support-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid #e1e5e9;
    transition: transform 0.3s ease;
}

.support-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.support-card h3 {
    margin-top: 0;
    color: #007cba;
}

.mgc-promo {
    background: linear-gradient(135deg, #007cba 0%, #005a87 100%);
    color: white;
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    margin-top: 30px;
}

.mgc-promo h3 {
    margin-top: 0;
    color: white;
}

.mgc-promo .button {
    background: white;
    color: #007cba;
    border: none;
}

.mgc-promo .button:hover {
    background: #f8f9fa;
}

/* Responsive */
@media (max-width: 768px) {
    .business-forms-for-doliprospect-admin {
        padding: 10px;
    }
    
    .business-forms-for-doliprospect-card {
        padding: 15px;
    }
    
    .form-table td .regular-text {
        max-width: 100%;
    }
    
    .modal-content {
        width: 95%;
        margin: 2% auto;
    }
    
    .modal-header {
        padding: 15px;
    }
    
    .modal-body {
        padding: 15px;
    }
    
    .business-forms-for-doliprospect-docs {
        flex-direction: column;
    }
    
    .docs-nav {
        position: static;
        order: 2;
    }
    
    .docs-content {
        order: 1;
        padding: 20px;
    }
    
    .support-links {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .business-forms-for-doliprospect-card {
        padding: 10px;
    }
    
    .docs-content {
        padding: 15px;
    }
    
    .docs-content h2 {
        font-size: 1.5rem;
    }
    
    .docs-content h3 {
        font-size: 1.2rem;
    }
}

/* Documentation styles */
.business-forms-for-doliprospect-docs {
    display: flex;
    gap: 30px;
    margin-top: 20px;
}

.docs-nav {
    flex: 0 0 250px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    height: fit-content;
    position: sticky;
    top: 20px;
}

.docs-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.docs-nav li {
    margin-bottom: 8px;
}

.docs-nav a {
    display: block;
    padding: 8px 12px;
    text-decoration: none;
    color: #333;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.docs-nav a:hover {
    background: #e9ecef;
}

.docs-nav a.active {
    background: #007cba;
    color: white;
}

.docs-content {
    flex: 1;
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.docs-content section {
    margin-bottom: 40px;
}

.docs-content h2 {
    color: #23282d;
    border-bottom: 2px solid #007cba;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.docs-content h3 {
    color: #23282d;
    margin-top: 30px;
    margin-bottom: 15px;
}

.docs-content h4 {
    color: #23282d;
    margin-top: 20px;
    margin-bottom: 10px;
}

.docs-content p {
    line-height: 1.6;
    margin-bottom: 15px;
}

.docs-content ul, .docs-content ol {
    margin-bottom: 15px;
    padding-left: 20px;
}

.docs-content li {
    margin-bottom: 8px;
}

.docs-content code {
    background: #f1f1f1;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
}

.docs-content pre {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    overflow-x: auto;
    border-left: 4px solid #007cba;
}

.docs-content pre code {
    background: none;
    padding: 0;
}

.docs-content .highlight {
    background: #fff3cd;
    padding: 15px;
    border-radius: 5px;
    border-left: 4px solid #ffc107;
    margin: 20px 0;
}

.docs-content .info-box {
    background: #d1ecf1;
    padding: 15px;
    border-radius: 5px;
    border-left: 4px solid #17a2b8;
    margin: 20px 0;
}

.docs-content .warning-box {
    background: #f8d7da;
    padding: 15px;
    border-radius: 5px;
    border-left: 4px solid #dc3545;
    margin: 20px 0;
}

.docs-content .success-box {
    background: #d4edda;
    padding: 15px;
    border-radius: 5px;
    border-left: 4px solid #28a745;
    margin: 20px 0;
}

/* Responsive documentation */
@media (max-width: 768px) {
    .business-forms-for-doliprospect-docs {
        flex-direction: column;
    }
    
    .docs-nav {
        position: static;
        flex: none;
    }
}
