/* Modale de captation - Styles basés sur Figma */

.brigade-popin-captation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999999999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.brigade-popin-captation.show {
    opacity: 1;
    visibility: visible;
}

.brigade-popin-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    animation: fadeIn 0.3s ease;
}

.brigade-popin-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 357px;
    max-height: 90vh;
    overflow-y: auto;
    background: #FFFFFF;
    border-radius: 4px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease forwards;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0px;
}

.brigade-popin-captation.show .brigade-popin-container {
    transform: translate(-50%, -50%) scale(1);
}

.brigade-popin-container button.brigade-popin-close, .brigade-popin-container button.brigade-popin-close:hover {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 26px;
    height: 26px;
    background: #FFFFFF;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    color: #000000;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}



.brigade-popin-container .brigade-popin-close svg {
    width: 18px;
    height: 18px;
}

/* Étapes */
.brigade-popin-step{
    display: none;
    animation: fadeIn 0.3s ease;
    width: 100%;
}

.brigade-popin-container .brigade-popin-step.active {
    display: flex;
    flex-direction: column;
}

/* Header avec image */
.brigade-popin-header {
    position: relative;
    width: 357px;
    height: 140px;
    background: #FFFFFF;
    border-radius: 4px 4px 40px 40px;
    overflow: hidden;
}

.brigade-popin-icon {
    position: absolute;
    width: 400px;
    height: 200px;
    left: -40px;
    top: -49.5px;
    object-fit: cover;
}

/* Contenu */
.brigade-popin-content {
    padding: 24px 20px;
    gap: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    background: #FFFFFF;
    border-radius: 0px 0px 4px 4px;
}

/* Logo */
.brigade-popin-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0px;
    width: 100%;
    margin-bottom: 0px;
}

.brigade-popin-logo img {
    width: 110px;
    height: 64px;
}

/* Titre */
.brigade-popin-container h2.brigade-popin-title {
    width: 317px;
    font-family: 'Decoy', sans-serif;
    font-style: normal;
    font-weight: 500;
    font-size: 22px;
    line-height: 26px;
    text-align: center;
    color: #000000;
    margin: 0 0 0px 0;
}

/* Description */
.brigade-popin-description {
    font-family: 'Decoy', sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 15px;
    line-height: 18px;
    text-align: center;
    color: #464646;
    margin: 0 0 14px 0;
}

/* Couleur rouge */
.text-red {
    color: #EA2424;
    display: inline;
}

/* Formulaire */
/*

TODO : à mettre dans hubspot
.brigade-popin-form {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0px;
    gap: 14px;
    width: 317px;
}

.brigade-popin-form label {
    width: 100%;
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 15px;
    line-height: 20px;
    text-align: center;
    color: #676767;
    display: block;
    margin-bottom: 0px;
} */

.brigade-popin-input {
    box-sizing: border-box;
    display: block;
    padding: 10px;
    width: 317px;
    height: 50px;
    border: 1px solid #D3D3D3;
    border-radius: 5px;
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 15px;
    line-height: 20px;
    color: #676767;
    outline: none;
    transition: all 0.2s ease;
}

.brigade-popin-input:focus {
    border-color: #EA2424;
    box-shadow: 0 0 0 3px rgba(234, 36, 36, 0.1);
}

.brigade-popin-input::placeholder {
    color: #676767;
}

/* Actions */




.brigade-popin-btn-primary {
    background: #EA2424;
    color: #FFFFFF;
}

.brigade-popin-btn-primary:hover {
    background: #d32020;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(234, 36, 36, 0.3);
}

/* Bouton sticky "Un cadeau vous attend" */
.brigade-popin-sticky-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 9999999999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
}

.brigade-popin-sticky-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.brigade-popin-sticky-btn .brigade-popin-sticky-close {
    border: none;
}

.brigade-popin-sticky-content {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    gap: 3px;
    background: #EA2424;
    border-radius: 50px;
    border: 2px solid black;
    box-shadow: 0 4px 12px rgba(234, 36, 36, 0.4);
    cursor: pointer;
    transition: all 0.2s ease;
}

.brigade-popin-sticky-content:hover {
    background: #d32020;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(234, 36, 36, 0.5);
}

.brigade-popin-sticky-text {
    font-family: 'Decoy', sans-serif;
    font-style: normal;
    font-weight: 700;
    font-size: 16px;
    line-height: 19px;
    color: #FFFFFF;
    white-space: nowrap;
    pointer-events: none;
}

.brigade-popin-container button.brigade-popin-sticky-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    padding: 0;
}


.brigade-popin-container button.brigade-popin-sticky-close svg {
    width: 8px;
    height: 8px;
}

/* Règles */
.brigade-popin-rules {
    width: 317px;
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 10px;
    line-height: 13px;
    color: #000000;
    margin: 0;
}

.brigade-popin-rules a {
    text-decoration: underline;
    display: inline;
}

/* Commentaire */
.brigade-popin-comment {
    width: 317px;
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 16px;
    line-height: 21px;
    text-align: center;
    color: #000000;

}

/* Countdown */
.brigade-popin-countdown {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 10px 0px;
    gap: 10px;
    width: 317px;
    background: #EA2424;
    border-radius: 10px;
}

.brigade-popin-countdown-title {
    font-family: 'Decoy', sans-serif;
    font-style: normal;
    font-weight: 700;
    font-size: 16px;
    line-height: 19px;
    color: #FFFFFF;
    text-align: center;
}

.brigade-popin-countdown-timer {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0px;
    gap: 10px;
}

.brigade-popin-countdown-timer-item {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    padding: 5px 7px;
    gap: 10px;
    width: 50px;
    height: 50px;
    background: #FFFFFF;
    border-radius: 5px;
}

.brigade-popin-countdown-timer-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0px;
}

.brigade-popin-countdown-timer-item-value {
    font-family: 'Decoy', sans-serif;
    font-style: normal;
    font-weight: 700;
    font-size: 22px;
    line-height: 26px;
    text-align: center;
    color: #EA2424;
}

.brigade-popin-countdown-timer-item-label {
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 12px;
    line-height: 16px;
    text-align: center;
    color: #EA2424;
}

/* Code promo avec icône copie */
.brigade-popin-form-code {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0px;
    gap: 5px;
    width: 317px;
}

.brigade-popin-form-code label {
    width: 100%;
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 15px;
    line-height: 20px;
    text-align: center;
    color: #676767;
    display: block;
    margin-bottom: 0px;
}

.brigade-popin-container .brigade-popin-input-wrapper {
    position: relative;
    width: 317px;
    box-sizing: border-box;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    padding: 13px;
    gap: 10px;
    border: 1px solid #EA2424;
    border-radius: 5px;
}

.brigade-popin-input-code {
    border: none;
    padding: 0;
    width: auto;
    height: auto;
    font-family: 'Degular', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 16px;
    line-height: 21px;
    text-align: center;
    color: #000000;
    background: transparent;
}

.brigade-popin-input-code:focus {
    border: none;
    box-shadow: none;
}

.brigade-popin-copy-icon, .brigade-popin-copied-icon {
    position: absolute;
    right: 10px;
    width: 14px;
    height: 16px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.brigade-popin-copy-icon:hover {
    transform: scale(1.1);
}

/* Indicateur d'étapes */
.brigade-popin-steps-indicator {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 16px 0;
    width: 100%;
}

.brigade-popin-step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #D3D3D3;
    transition: all 0.3s ease;
    cursor: pointer;
}

.brigade-popin-step-dot.active {
    background-color: #EA2424;
    width: 24px;
    border-radius: 5px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translate(-50%, -40%) scale(0.9);
        opacity: 0;
    }
    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

.brigade-popin-container .brigade-popin-btn {
    display: none;
}

.brigade-popin-actions {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {



    .brigade-popin-actions {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 14px;
        width: 317px;
    }

    .brigade-popin-container .brigade-popin-btn {
        display: block;
        padding: 10px;
        width: 317px;
        height: 50px;
        background: #EA2424;
        border-radius: 5px;
        border: none;
        cursor: pointer;
        transition: all 0.2s ease;
        font-family: 'Decoy', sans-serif;
        font-style: normal;
        font-weight: 700;
        font-size: 15px;
        line-height: 18px;
        text-align: center;
        color: #FFFFFF;
    }
    .brigade-popin-container {
        width: 95%;
        max-width: 357px;
    }

    .brigade-popin-header {
        width: 100%;
    }

    .brigade-popin-icon {
        width: calc(100% + 80px);
        left: -40px;
    }

    .brigade-popin-container .brigade-popin-content {
        padding: 20px 15px;
    }

    .brigade-popin-title,
    .brigade-popin-description,
    .brigade-popin-form,
    .brigade-popin-actions,
    .brigade-popin-rules,
    .brigade-popin-comment,
    .brigade-popin-countdown,
    .brigade-popin-form-code,
    .brigade-popin-input-wrapper {
        width: 100%;
        max-width: 95%;
    }

    .brigade-popin-form-code {
        margin-bottom: 14px;
    }

    .brigade-popin-comment {
        margin: 14px 0px;
    }

    .brigade-popin-input {
        width: 100%;
    }

    .brigade-popin-btn {
        width: 100%;
    }

    .brigade-popin-close {
        top: 8px;
        right: 8px;
    }
}

@media (max-width: 400px) {
    .brigade-popin-container h2.brigade-popin-title {
        font-size: 20px;
        line-height: 24px;
    }

    .brigade-popin-description {
        font-size: 14px;
        line-height: 17px;
    }

    .brigade-popin-container .brigade-popin-countdown-title {
        font-size: 14px;
    }

    .brigade-popin-container .brigade-popin-countdown-timer-item {
        width: 45px;
        height: 45px;
    }

    .brigade-popin-container .brigade-popin-countdown-timer-item-value {
        font-size: 20px;
    }
}

/* Scrollbar personnalisée pour le container */
.brigade-popin-container::-webkit-scrollbar {
    width: 8px;
}

.brigade-popin-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.brigade-popin-container::-webkit-scrollbar-thumb {
    background: #EA2424;
    border-radius: 10px;
}

.brigade-popin-container::-webkit-scrollbar-thumb:hover {
    background: #d32020;
}

/* Responsive sticky button */
@media (max-width: 768px) {
    .brigade-popin-sticky-btn {
        bottom: 15px;
        left: 15px;
    }

    .brigade-popin-sticky-content {
        padding: 10px 16px;
    }

    .brigade-popin-sticky-text {
        font-size: 14px;
        line-height: 17px;
    }
}

@media (max-width: 400px) {
    .brigade-popin-sticky-btn {
        bottom: 10px;
        left: 10px;
    }

    .brigade-popin-sticky-text {
        font-size: 13px;
    }
}

/* Exit Popin Funnel - Spécificités */
#brigade-exit-popin-funnel .brigade-popin-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    width: 317px;
}

#brigade-exit-popin-funnel .brigade-popin-btn {
    display: block;
    padding: 10px;
    width: 317px;
    height: 50px;
    background: #EA2424;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Decoy', sans-serif;
    font-style: normal;
    font-weight: 500;
    font-size: 15px;
    line-height: 18px;
    text-align: center;
    color: #FFFFFF;
}

#brigade-exit-popin-funnel .brigade-popin-btn:hover {
    background: #d32020;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(234, 36, 36, 0.3);
}

#brigade-exit-popin-funnel .brigade-popin-comment {
    margin-bottom: 0px;
}

#brigade-exit-popin-funnel .brigade-popin-close {
    border: 1px solid;
    padding: 0 5px !important;
    width: 28px;
    height: 28px;
}

#brigade-exit-popin-funnel .brigade-popin-copy-icon {
    width: 17px;
    height: 16px;
}

@media (max-width: 768px) {
    #brigade-exit-popin-funnel .brigade-popin-actions,
    #brigade-exit-popin-funnel .brigade-popin-btn {
        width: 100%;
        max-width: 95%;
    }
}
