/* Container principal */
.wpsu-uploader-wrapper {
    max-width: 600px;
    margin: 2rem auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* Zone de drag & drop */
.wpsu-dropzone {
    position: relative;
    border: 3px dashed #cbd5e1;
    border-radius: 12px;
    padding: 3rem 2rem;
    text-align: center;
    background-color: #f8fafc;
    transition: all 0.3s ease;
    cursor: pointer;
}

.wpsu-dropzone:hover {
    border-color: #11A3EA;
    background-color: #eff6ff;
}

.wpsu-dropzone.wpsu-dragover {
    border-color: #11A3EA;
    background-color: #dbeafe;
    border-style: solid;
}

.wpsu-dropzone.wpsu-dragover .wpsu-dropzone-content {
    opacity: 0.3;
}

.wpsu-dropzone.wpsu-dragover .wpsu-dropzone-overlay {
    opacity: 1;
}

/* Contenu de la dropzone */
.wpsu-dropzone-content {
    position: relative;
    z-index: 1;
    transition: opacity 0.3s ease;
}

.wpsu-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    color: #64748b;
}

.wpsu-dropzone-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 0.5rem;
}

.wpsu-dropzone-subtitle {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0 0 1rem;
}

.wpsu-file-button {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background-color: #11A3EA;
    color: white;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.wpsu-file-button:hover {
    background-color: #0e8bc7;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(17, 163, 234, 0.3);
}

.wpsu-dropzone-hint {
    font-size: 0.75rem;
    color: #94a3b8;
    margin: 1rem 0 0;
}

/* Overlay de drag & drop */
.wpsu-dropzone-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(17, 163, 234, 0.1);
    border-radius: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.wpsu-dropzone-overlay p {
    font-size: 1.25rem;
    font-weight: 600;
    color: #11A3EA;
}

/* Overlay plein écran pour le drag & drop */
.wpsu-fullscreen-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(17, 163, 234, 0.3);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.wpsu-fullscreen-overlay.wpsu-active {
    display: flex;
    animation: wpsu-overlay-fadein 0.2s ease;
}

.wpsu-fullscreen-overlay::before {
    content: '📁 Drop your file anywhere';
    font-size: 2rem;
    font-weight: 700;
    color: white;
    text-align: center;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    padding: 2rem;
}

@keyframes wpsu-overlay-fadein {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Informations du fichier */
.wpsu-file-info {
    background-color: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.wpsu-file-details {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.wpsu-file-icon {
    width: 40px;
    height: 40px;
    color: #11A3EA;
    flex-shrink: 0;
}

.wpsu-file-text {
    flex: 1;
    min-width: 0;
}

.wpsu-file-name {
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 0.25rem;
    word-break: break-word;
}

.wpsu-file-size {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0;
}

.wpsu-remove-file {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid #e2e8f0;
    background-color: white;
    color: #64748b;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    padding: 0;
}

.wpsu-remove-file:hover {
    background-color: #fee2e2;
    border-color: #ef4444;
    color: #ef4444;
}

/* Bouton de soumission */
.wpsu-submit-button {
    width: 100%;
    max-width: 300px;
    margin: 0 auto 1rem;
    display: block;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #1CC75A 0%, #18a84d 100%);
    color: white !important;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    text-align: center;
}

.wpsu-submit-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(28, 199, 90, 0.4);
}

.wpsu-submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.wpsu-submit-button .wpsu-button-text {
    color: white !important;
}

.wpsu-button-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: white !important;
}

.wpsu-spinner {
    width: 20px;
    height: 20px;
    animation: wpsu-spin 1s linear infinite;
}

@keyframes wpsu-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Messages de résultat */
.wpsu-result {
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    animation: wpsu-fadein 0.3s ease;
}

.wpsu-result.wpsu-success {
    background-color: #dcfce7;
    color: #166534;
    border: 2px solid #1CC75A;
}

.wpsu-result.wpsu-error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 2px solid #fca5a5;
}

@keyframes wpsu-fadein {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Notice de preview */
.wpsu-preview-notice {
    background-color: #fef3c7;
    color: #92400e;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 2px solid #fcd34d;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 500;
    margin-top: 1rem;
}

/* Maintenance notice */
.wpsu-maintenance-notice {
    background-color: #fff8e5;
    border: 1px solid #f0c33c;
    color: #b47f00;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 20px;
}

/* Mapping Selection Modal (V5) */
.wpsu-mapping-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wpsu-mapping-modal {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    max-width: 520px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: wpsu-fadein 0.2s ease;
}

.wpsu-mapping-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid #e2e8f0;
    background-color: white;
    color: #64748b;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 0;
    z-index: 1;
}

.wpsu-mapping-close:hover {
    background-color: #fee2e2;
    border-color: #ef4444;
    color: #ef4444;
}

.wpsu-mapping-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 1.5rem;
    text-align: center;
}

.wpsu-mapping-options {
    display: flex;
    flex-direction: row;
    gap: 0.75rem;
}

.wpsu-mapping-option {
    flex: 1;
    border: 2px solid transparent;
    border-radius: 10px;
    padding: 1.25rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.wpsu-mapping-option[data-mapping="accurate"] {
    background-color: rgba(28, 199, 90, 0.1);
    border-color: rgba(28, 199, 90, 0.3);
}

.wpsu-mapping-option[data-mapping="accurate"]:hover {
    background-color: rgba(28, 199, 90, 0.2);
    border-color: #1cc75a;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(28, 199, 90, 0.25);
}

.wpsu-mapping-option[data-mapping="color"] {
    background-color: rgba(17, 163, 234, 0.1);
    border-color: rgba(17, 163, 234, 0.3);
}

.wpsu-mapping-option[data-mapping="color"]:hover {
    background-color: rgba(17, 163, 234, 0.2);
    border-color: #11a3ea;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(17, 163, 234, 0.25);
}

.wpsu-mapping-option-name {
    font-weight: 600;
    color: #1e293b;
    font-size: 1rem;
}

.wpsu-mapping-option-desc {
    color: #64748b;
    font-size: 0.813rem;
    margin-top: 0.4rem;
    line-height: 1.4;
}

/* Responsive */
@media (max-width: 640px) {
    .wpsu-uploader-wrapper {
        margin: 1rem;
    }

    .wpsu-dropzone {
        padding: 2rem 1rem;
    }

    .wpsu-dropzone-title {
        font-size: 1rem;
    }

    .wpsu-icon {
        width: 48px;
        height: 48px;
    }

    .wpsu-fullscreen-overlay::before {
        font-size: 1.5rem;
        padding: 1rem;
    }

    .wpsu-mapping-modal {
        padding: 1.5rem;
        margin: 1rem;
    }

    .wpsu-mapping-title {
        font-size: 1.1rem;
    }

    .wpsu-mapping-options {
        flex-direction: column;
    }
}