/* 6rsh WhatsApp floating chat widget */
:root { --sixrsh-color: #25D366; }

.sixrsh-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}
.sixrsh-widget.sixrsh-visible { opacity: 1; pointer-events: auto; }
.sixrsh-widget.pos-left { right: auto; left: 24px; align-items: flex-start; }
.sixrsh-widget.sixrsh-hidden { display: none !important; }

/* RTL: flip default position */
[dir="rtl"] .sixrsh-widget:not(.pos-left) { right: auto; left: 24px; }
[dir="rtl"] .sixrsh-widget.pos-left       { left: auto; right: 24px; }

/* Tooltip bubble */
.sixrsh-tooltip {
    background: #fff;
    color: #1a1a1a;
    border-radius: 12px;
    padding: 10px 16px;
    font-size: 14px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    line-height: 1.45;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.14);
    max-width: 230px;
    white-space: normal;
    word-break: break-word;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    position: relative;
    pointer-events: none;
}
.sixrsh-tooltip.tooltip-visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
/* Arrow pointing down */
.sixrsh-tooltip::after {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 20px;
    border-width: 8px 8px 0;
    border-style: solid;
    border-color: #fff transparent transparent;
}
.sixrsh-widget.pos-left .sixrsh-tooltip::after,
[dir="rtl"] .sixrsh-widget .sixrsh-tooltip::after {
    right: auto;
    left: 20px;
}

/* Button wrapper (holds button + close X) */
.sixrsh-btn-wrap {
    position: relative;
    display: inline-block;
    line-height: 0;
}

/* Main button */
.sixrsh-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--sixrsh-color);
    border: none;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.22);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    animation: sixrsh-pulse 2.5s ease-out infinite;
}
.sixrsh-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 28px rgba(0, 0, 0, 0.32);
    animation: none;
}
.sixrsh-btn svg {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
}

/* Pulse animation — CSS only, no JS repaints */
@keyframes sixrsh-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.50); }
    70%  { box-shadow: 0 0 0 18px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* Dismiss (×) button */
.sixrsh-close {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 13px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
    padding: 0;
}
.sixrsh-btn-wrap:hover .sixrsh-close { opacity: 1; }

/* Hide on mobile (applied via JS class when hideMobile=true) */
@media (max-width: 767px) {
    .sixrsh-widget.hide-mobile { display: none !important; }
}
