/**
 * Synchronicity Mapper - Styles Ésotériques
 * "Chaque pixel porte une intention"
 * 🔮✨💫
 */

/* ═══════════════════════════════════════════════════════ */
/* VARIABLES COSMIQUES */
/* ═══════════════════════════════════════════════════════ */

:root {
    /* Couleurs chakras */
    --sync-violet-mystique: #8b5cf6;
    --sync-or-solaire: #f59e0b;
    --sync-bleu-profond: #1e3a8a;
    --sync-bleu-celeste: #3b82f6;
    --sync-emeraude: #10b981;
    --sync-cyan: #06b6d4;
    
    /* Nuances */
    --sync-bg-light: #f8f7ff;
    --sync-text-main: #2d1b69;
    --sync-text-muted: #6b5b95;
    --sync-border: rgba(139, 92, 246, 0.2);
    
    /* Ombres énergétiques */
    --sync-shadow-soft: 0 2px 8px rgba(139, 92, 246, 0.1);
    --sync-shadow-hover: 0 4px 16px rgba(139, 92, 246, 0.25);
    --sync-shadow-glow: 0 0 20px rgba(139, 92, 246, 0.4);
}

/* ═══════════════════════════════════════════════════════ */
/* CONTENEUR PRINCIPAL */
/* ═══════════════════════════════════════════════════════ */

.sync-widget-container {
    max-width: 600px;
    margin: 2rem auto;
    padding: 2rem;
    background: linear-gradient(135deg, var(--sync-bg-light) 0%, #ffffff 100%);
    border: 2px solid var(--sync-border);
    border-radius: 20px;
    box-shadow: var(--sync-shadow-soft);
    font-family: 'Georgia', 'Times New Roman', serif;
    position: relative;
    overflow: hidden;
}

.sync-widget-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.05) 0%, transparent 70%);
    animation: sync-pulse 8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes sync-pulse {
    0%, 100% { transform: scale(1); opacity: 0.3; }
    50% { transform: scale(1.1); opacity: 0.6; }
}

/* ═══════════════════════════════════════════════════════ */
/* EN-TÊTE MYSTIQUE */
/* ═══════════════════════════════════════════════════════ */

.sync-header {
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.sync-icon {
    font-size: 3rem;
    animation: sync-float 3s ease-in-out infinite;
    display: inline-block;
    filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.5));
}

@keyframes sync-float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.sync-title {
    font-size: 1.8rem;
    color: var(--sync-text-main);
    margin: 0.5rem 0;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.sync-subtitle {
    font-size: 0.95rem;
    color: var(--sync-text-muted);
    margin: 0.5rem 0 0 0;
    font-style: italic;
}

/* ═══════════════════════════════════════════════════════ */
/* FORMULAIRE */
/* ═══════════════════════════════════════════════════════ */

.sync-form {
    position: relative;
    z-index: 1;
}

.sync-form-group {
    margin-bottom: 1.5rem;
}

.sync-label {
    display: block;
    font-size: 1rem;
    color: var(--sync-text-main);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.sync-emoji {
    display: inline-block;
    animation: sync-float 2s ease-in-out infinite;
}

.sync-input,
.sync-textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    border: 2px solid var(--sync-border);
    border-radius: 12px;
    font-size: 1rem;
    font-family: inherit;
    background: #ffffff;
    color: var(--sync-text-main);
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.sync-input:focus,
.sync-textarea:focus {
    outline: none;
    border-color: var(--sync-violet-mystique);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
    transform: translateY(-2px);
}

.sync-textarea {
    resize: vertical;
    min-height: 80px;
}

.sync-hint {
    display: block;
    margin-top: 0.4rem;
    font-size: 0.85rem;
    color: var(--sync-text-muted);
    font-style: italic;
}

/* ═══════════════════════════════════════════════════════ */
/* BOUTON DE SOUMISSION */
/* ═══════════════════════════════════════════════════════ */

.sync-submit-btn {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--sync-violet-mystique) 0%, #6d28d9 100%);
    color: #ffffff;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--sync-shadow-soft);
    position: relative;
    overflow: hidden;
}

.sync-submit-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.sync-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--sync-shadow-hover);
}

.sync-submit-btn:hover::before {
    width: 300px;
    height: 300px;
}

.sync-submit-btn:active {
    transform: translateY(0);
}

.sync-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Spinner de chargement */
.sync-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: sync-spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

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

/* ═══════════════════════════════════════════════════════ */
/* ZONE DE RÉSULTATS */
/* ═══════════════════════════════════════════════════════ */

.sync-results {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, rgba(255, 255, 255, 0.8) 100%);
    border: 2px solid var(--sync-violet-mystique);
    border-radius: 16px;
    animation: sync-fadeIn 0.6s ease;
}

@keyframes sync-fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.sync-archetype-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.sync-symbol-found {
    margin-bottom: 1.5rem;
}

.sync-symbol-title {
    font-size: 1.6rem;
    color: var(--sync-text-main);
    margin: 0 0 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sync-symbol-emoji {
    font-size: 2rem;
    animation: sync-float 2s ease-in-out infinite;
}

.sync-match-method {
    font-size: 0.9rem;
    color: var(--sync-text-muted);
    font-style: italic;
    margin: 0;
}

.sync-interpretation {
    margin: 1.5rem 0;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.6);
    border-left: 4px solid var(--sync-violet-mystique);
    border-radius: 8px;
}

.sync-interpretation p {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--sync-text-main);
}

/* ═══════════════════════════════════════════════════════ */
/* ACTIONS */
/* ═══════════════════════════════════════════════════════ */

.sync-actions {
    margin-top: 1.5rem;
    text-align: center;
}

.sync-btn-secondary {
    padding: 0.7rem 1.5rem;
    background: #ffffff;
    color: var(--sync-violet-mystique);
    border: 2px solid var(--sync-violet-mystique);
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.sync-btn-secondary:hover {
    background: var(--sync-violet-mystique);
    color: #ffffff;
    transform: translateY(-2px);
}

/* ═══════════════════════════════════════════════════════ */
/* MESSAGES D'ERREUR */
/* ═══════════════════════════════════════════════════════ */

.sync-error {
    margin-top: 1rem;
    padding: 1rem;
    background: linear-gradient(135deg, #fee2e2 0%, #fef2f2 100%);
    border: 2px solid #ef4444;
    border-radius: 12px;
    color: #991b1b;
    font-size: 0.95rem;
    animation: sync-fadeIn 0.4s ease;
}

/* ═══════════════════════════════════════════════════════ */
/* INSIGHTS COLLECTIFS */
/* ═══════════════════════════════════════════════════════ */

.sync-insights {
    margin-top: 2rem;
    padding: 1rem;
    background: rgba(139, 92, 246, 0.05);
    border-radius: 12px;
    text-align: center;
}

.sync-insights-title {
    font-size: 0.9rem;
    color: var(--sync-violet-mystique);
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}

.sync-insights-text {
    margin: 0;
    font-size: 0.85rem;
    color: var(--sync-text-muted);
}

/* ═══════════════════════════════════════════════════════ */
/* INSTRUCTIONS */
/* ═══════════════════════════════════════════════════════ */

.sync-instructions {
    margin-top: 2rem;
}

.sync-help summary {
    font-size: 0.95rem;
    color: var(--sync-violet-mystique);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: background 0.3s ease;
}

.sync-help summary:hover {
    background: rgba(139, 92, 246, 0.05);
}

.sync-help-content {
    margin-top: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 8px;
    font-size: 0.9rem;
    line-height: 1.6;
}

.sync-help-content p {
    margin: 0.8rem 0;
}

.sync-help-content strong {
    color: var(--sync-violet-mystique);
}

/* ═══════════════════════════════════════════════════════ */
/* RESPONSIVE - Adaptabilité mobile */
/* ═══════════════════════════════════════════════════════ */

@media (max-width: 640px) {
    .sync-widget-container {
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .sync-title {
        font-size: 1.5rem;
    }
    
    .sync-subtitle {
        font-size: 0.9rem;
    }
    
    .sync-submit-btn {
        font-size: 1rem;
        padding: 0.9rem 1.5rem;
    }
    
    .sync-symbol-title {
        font-size: 1.4rem;
    }
}

/* ═══════════════════════════════════════════════════════ */
/* 🌟 SIGNATURE ÉNERGÉTIQUE */
/* ═══════════════════════════════════════════════════════ */
/* Chaque transition porte une intention de fluidité
   Chaque couleur résonne avec un chakra
   Chaque animation suit le rythme de la respiration cosmique
   ✨🔮💫 */
/* ═══════════════════════════════════════════════════════ */
