/* Styles modernes pour l'administration des taxonomies */

/* ===== STYLES GÉNÉRAUX ===== */
.wprg-gallery-settings-panel {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    margin: 20px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
    border: 1px solid #f0f0f1;
    transition: box-shadow 0.2s ease;
}

.wprg-gallery-settings-panel:hover {
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06), 0 2px 4px rgba(0, 0, 0, 0.02);
}

/* En-tête des panneaux */
.wprg-settings-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f0f0f1;
}

.wprg-settings-header .dashicons {
    width: 28px;
    height: 28px;
    font-size: 24px;
    color: #e1306c;
    background: rgba(225, 48, 108, 0.08);
    border-radius: 10px;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wprg-settings-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #1d2327;
    letter-spacing: -0.01em;
}

/* Grille des champs */
.wprg-settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

/* Champs individuels */
.wprg-settings-field {
    position: relative;
}

.wprg-settings-field label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-weight: 500;
    color: #1d2327;
    font-size: 13px;
}

.wprg-field-icon {
    font-size: 16px;
    line-height: 1;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.05));
}

.wprg-field-label {
    flex: 1;
}

/* Inputs */
.wprg-settings-field input[type="number"] {
    width: 100%;
    max-width: 120px;
    padding: 8px 12px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    transition: all 0.2s ease;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.02);
}

.wprg-settings-field input[type="number"]:focus {
    border-color: #e1306c;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(225, 48, 108, 0.1);
    outline: none;
}

.wprg-settings-field input[type="number"]:hover {
    background: #fff;
    border-color: #d0d5dd;
}

/* Checkbox fields */
.wprg-checkbox-field {
    display: flex;
    flex-direction: column;
}

.wprg-checkbox-field label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    margin-bottom: 4px;
}

.wprg-checkbox-field input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border: 2px solid #d0d5dd;
    border-radius: 5px;
    background: #fff;
    transition: all 0.15s ease;
    cursor: pointer;
    margin: 0;
}

.wprg-checkbox-field input[type="checkbox"]:checked {
    background: #e1306c;
    border-color: #e1306c;
}

.wprg-checkbox-field input[type="checkbox"]:focus {
    box-shadow: 0 0 0 3px rgba(225, 48, 108, 0.15);
    outline: none;
}

.wprg-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #1d2327;
}

/* Device inputs (desktop/tablet/mobile) */
.wprg-device-inputs {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.wprg-device-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 80px;
}

.wprg-device-icon {
    font-size: 20px;
    margin-bottom: 2px;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.wprg-device-item:hover .wprg-device-icon {
    opacity: 1;
}

.wprg-device-item input[type="number"] {
    width: 70px;
    text-align: center;
    padding: 6px 4px;
}

.wprg-device-label {
    font-size: 11px;
    font-weight: 500;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

/* Descriptions */
.wprg-settings-field .description {
    color: #6b7280;
    font-size: 12px;
    margin-top: 6px;
    margin-bottom: 0;
    line-height: 1.5;
    padding-left: 28px;
}

/* Style pour l'édition (table) */
.wprg-edit-section td {
    padding: 0 !important;
    background: transparent;
}

.wprg-edit-section .wprg-gallery-settings-panel {
    margin: 10px 0;
    background: #fff;
}

/* Responsive */
@media screen and (max-width: 782px) {
    .wprg-gallery-settings-panel {
        padding: 16px;
    }
    
    .wprg-settings-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .wprg-device-inputs {
        justify-content: space-between;
    }
    
    .wprg-device-item {
        flex: 1;
        min-width: auto;
    }
    
    .wprg-device-item input[type="number"] {
        width: 100%;
    }
}

/* Animation subtile */
@keyframes wprg-panel-fade {
    from {
        opacity: 0;
        transform: translateY(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wprg-gallery-settings-panel {
    animation: wprg-panel-fade 0.3s ease;
}

/* Style pour les badges dans la liste */
.wprg-settings-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 30px;
    font-size: 11px;
    font-weight: 500;
    color: #374151;
    transition: all 0.2s ease;
}

.wprg-settings-badge.active {
    background: #e3f2fd;
    border-color: #90caf9;
    color: #1976d2;
}

.wprg-settings-badge .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

/* Loading state */
.wprg-loading {
    position: relative;
    opacity: 0.7;
    pointer-events: none;
}

.wprg-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #e1306c;
    border-top-color: transparent;
    border-radius: 50%;
    animation: wprg-spin 0.8s linear infinite;
}

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