/**
 * Guide Tour — Carrousel d'onboarding
 * Overlay plein écran avec slides, navigation dots, swipe mobile.
 */

/* Overlay */
.cv-guide-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 999999;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.cv-guide-overlay.active {
    display: flex;
    opacity: 1;
}

/* Container du carrousel */
.cv-guide-container {
    position: relative;
    width: 90vw;
    max-width: 720px;
    max-height: 88vh;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.35);
    display: flex;
    flex-direction: column;
    animation: cvGuideIn 0.4s ease;
}
@keyframes cvGuideIn {
    from { opacity: 0; transform: scale(0.92) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Bouton fermer */
.cv-guide-close {
    position: absolute;
    top: 14px; right: 14px;
    width: 36px; height: 36px;
    border-radius: 50%;
    background: rgba(0,0,0,0.08);
    border: none;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.2s;
    z-index: 10;
}
.cv-guide-close:hover { background: rgba(0,0,0,0.15); }
.cv-guide-close svg { width: 20px; height: 20px; stroke: #555; }

/* Zone des slides */
.cv-guide-slides {
    position: relative;
    flex: 1;
    overflow: hidden;
}
.cv-guide-track {
    display: flex;
    transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    height: 100%;
}
.cv-guide-slide {
    min-width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 32px 20px;
    box-sizing: border-box;
    text-align: center;
}

/* Visuel du slide — placeholder illustratif */
.cv-guide-visual {
    width: 100%;
    max-width: 480px;
    aspect-ratio: 16/10;
    border-radius: 14px;
    overflow: hidden;
    margin-bottom: 24px;
    position: relative;
    background: #f5f3ef;
    border: 1px solid #e8e4de;
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}
.cv-guide-visual img {
    width: 100%; height: 100%; object-fit: cover;
}
/* Placeholder illustratif quand pas d'image */
.cv-guide-visual-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 64px;
    background: linear-gradient(135deg, #f8f4e8 0%, #e8e4de 100%);
}

/* Bulle explicative */
.cv-guide-bubble {
    position: relative;
    background: #fff;
    max-width: 520px;
}
.cv-guide-bubble h3 {
    font-size: 22px;
    font-weight: 700;
    color: #2b3545;
    margin: 0 0 10px;
    line-height: 1.3;
}
.cv-guide-bubble p {
    font-size: 15px;
    color: #7a8599;
    line-height: 1.65;
    margin: 0 0 18px;
}

/* Bouton d'action contextuel */
.cv-guide-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #c9a84c, #d4b45c);
    color: #fff;
    padding: 12px 24px;
    border-radius: 10px;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: filter 0.2s;
}
.cv-guide-action:hover { filter: brightness(1.1); color: #fff; }
.cv-guide-action svg { width: 18px; height: 18px; }

/* Barre de navigation basse */
.cv-guide-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px 20px;
    background: #fff;
    border-top: 1px solid #f0ede8;
}

/* Flèches */
.cv-guide-arrow {
    width: 42px; height: 42px;
    border-radius: 50%;
    border: 2px solid #e8e4de;
    background: #fff;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}
.cv-guide-arrow:hover { border-color: #c9a84c; background: #f8f4e8; }
.cv-guide-arrow:disabled { opacity: 0.3; cursor: default; }
.cv-guide-arrow:disabled:hover { border-color: #e8e4de; background: #fff; }
.cv-guide-arrow svg { width: 20px; height: 20px; stroke: #2b3545; }

/* Dots */
.cv-guide-dots {
    display: flex;
    gap: 8px;
    align-items: center;
}
.cv-guide-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    background: #e0dcd5;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    padding: 0;
}
.cv-guide-dot.active {
    background: #c9a84c;
    width: 28px;
    border-radius: 5px;
}

/* Compteur de slides */
.cv-guide-counter {
    font-size: 12px;
    color: #aaa;
    position: absolute;
    top: 16px; left: 20px;
    z-index: 10;
}

/* Responsive */
@media (max-width: 600px) {
    .cv-guide-container {
        width: 96vw;
        max-height: 92vh;
        border-radius: 14px;
    }
    .cv-guide-slide {
        padding: 30px 18px 14px;
    }
    .cv-guide-bubble h3 { font-size: 19px; }
    .cv-guide-bubble p { font-size: 14px; }
    .cv-guide-visual { aspect-ratio: 16/11; }
    .cv-guide-nav { padding: 12px 16px 16px; }
}
