/* 3TREE FLOATING WHATSAPP */

#tree-whatsapp {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 999998;
    direction: rtl;
    font-family: Tahoma, Arial, sans-serif;
}

#tree-whatsapp * {
    box-sizing: border-box;
}

#tree-whatsapp .wa-launcher {
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    padding: 15px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #25d366;
    color: white;
    box-shadow: 0 8px 28px rgba(0,0,0,.25);
    cursor: pointer;
    transition: transform .2s, box-shadow .2s;
}

#tree-whatsapp .wa-launcher:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 35px rgba(0,0,0,.3);
}

#tree-whatsapp svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: currentColor;
}

#tree-whatsapp .wa-panel {
    position: absolute;
    right: 0;
    bottom: 80px;
    width: 340px;
    max-width: calc(100vw - 30px);
    overflow: hidden;
    border: 1px solid #d8c49c;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 15px 50px rgba(0,0,0,.24);
}

#tree-whatsapp .wa-panel[hidden] {
    display: none !important;
}

#tree-whatsapp .wa-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 19px;
    background: #191919;
    color: #fff;
}

#tree-whatsapp .wa-header strong {
    display: block;
    font-size: 17px;
    letter-spacing: 1px;
}

#tree-whatsapp .wa-header span {
    display: block;
    margin-top: 6px;
    color: #dfc58e;
    font-size: 12px;
}

#tree-whatsapp .wa-close {
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 26px;
    cursor: pointer;
}

#tree-whatsapp .wa-content {
    padding: 23px;
    text-align: center;
}

#tree-whatsapp .wa-content h3 {
    margin: 0 0 12px;
    color: #242424;
    font-size: 18px;
}

#tree-whatsapp .wa-content p {
    margin: 0 0 20px;
    color: #666;
    font-size: 13px;
    line-height: 1.9;
}

#tree-whatsapp .wa-start {
    display: block;
    padding: 14px;
    border-radius: 11px;
    background: #25d366;
    color: #fff;
    text-align: center;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
    transition: background .2s;
}

#tree-whatsapp .wa-start:hover {
    background: #1daa50;
    color: #fff;
}

#tree-whatsapp .wa-footer {
    padding: 11px;
    border-top: 1px solid #eee;
    color: #999;
    text-align: center;
    font-size: 11px;
}

@media(max-width:600px) {
    #tree-whatsapp {
        right: 15px;
        bottom: 15px;
    }

    #tree-whatsapp .wa-launcher {
        width: 57px;
        height: 57px;
        padding: 13px;
    }

    #tree-whatsapp .wa-panel {
        position: fixed;
        right: 10px;
        bottom: 85px;
        width: min(340px,calc(100vw - 20px));
    }
}



/* 3TREE WHATSAPP BOUNCE V2 */

#tree-whatsapp .wa-launcher {
    position: relative;
    isolation: isolate;
    animation: treeWaBounce 3s ease-in-out infinite;
    transform-origin: center bottom;
}

/* Two expanding green rings */

#tree-whatsapp .wa-launcher::before,
#tree-whatsapp .wa-launcher::after {
    content: "";
    position: absolute;
    inset: -5px;
    border: 2px solid rgba(37, 211, 102, .65);
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    animation: treeWaPulse 3s ease-out infinite;
}

#tree-whatsapp .wa-launcher::after {
    animation-delay: 1.5s;
}

/* Double bounce every 3 seconds */

@keyframes treeWaBounce {

    0%, 12%, 30%, 100% {
        transform: translateY(0) scale(1);
    }

    5% {
        transform: translateY(-19px) scale(1.04);
    }

    9% {
        transform: translateY(0) scale(.96,1.04);
    }

    19% {
        transform: translateY(-10px) scale(1.02);
    }

    25% {
        transform: translateY(0) scale(1);
    }
}

@keyframes treeWaPulse {

    0% {
        opacity: .75;
        transform: scale(1);
    }

    70%, 100% {
        opacity: 0;
        transform: scale(1.55);
    }
}

/* Pause when hovering */

#tree-whatsapp .wa-launcher:hover {
    animation-play-state: paused;
}

/* Accessibility */

@media (prefers-reduced-motion: reduce) {

    #tree-whatsapp .wa-launcher,
    #tree-whatsapp .wa-launcher::before,
    #tree-whatsapp .wa-launcher::after {
        animation: none !important;
    }
}
