/* =========================================================
   WP WhatsApp Contact — style.css
   ========================================================= */

:root {
    --wwac-green:      #25D366;
    --wwac-green-dark: #128C7E;
    --wwac-white:      #ffffff;
    --wwac-text:       #111b21;
    --wwac-subtext:    #667781;
    --wwac-bg:         #f0f2f5;
    --wwac-bubble:     #dcf8c6;
    --wwac-radius:     16px;
    --wwac-shadow:     0 8px 32px rgba(0,0,0,.18);
}

/* ── Floating Wrapper ─────────────────────────────────── */
#wwac-floating-wrap {
    position: fixed;
    bottom: 28px;
    z-index: 99999;
}
#wwac-floating-wrap.wwac-pos-right { right: 28px; }
#wwac-floating-wrap.wwac-pos-left  { left:  28px; }

/* ── FAB Trigger Button ───────────────────────────────── */
.wwac-fab {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--wwac-green);
    color: var(--wwac-white);
    border: none;
    border-radius: 50px;
    padding: 14px 22px 14px 18px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(37,211,102,.45);
    transition: transform .2s, box-shadow .2s, background .2s;
    white-space: nowrap;
}
.wwac-fab:hover {
    background: var(--wwac-green-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(37,211,102,.5);
}
.wwac-fab svg { flex-shrink: 0; }

/* Pulse ring on fab */
.wwac-fab::after {
    content: '';
    position: absolute;
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--wwac-green);
    opacity: .35;
    animation: wwac-pulse 2s infinite;
    pointer-events: none;
}
@keyframes wwac-pulse {
    0%   { transform: scale(1);   opacity: .35; }
    70%  { transform: scale(1.6); opacity: 0;   }
    100% { transform: scale(1.6); opacity: 0;   }
}

/* ── Chat Popup ───────────────────────────────────────── */
.wwac-popup {
    position: absolute;
    bottom: calc(100% + 14px);
    width: 320px;
    background: var(--wwac-white);
    border-radius: var(--wwac-radius);
    box-shadow: var(--wwac-shadow);
    overflow: hidden;
    transform-origin: bottom center;
    transform: scale(.85) translateY(10px);
    opacity: 0;
    pointer-events: none;
    transition: transform .25s cubic-bezier(.34,1.56,.64,1), opacity .2s;
}
.wwac-pos-right .wwac-popup { right: 0; }
.wwac-pos-left  .wwac-popup { left:  0; }

.wwac-popup.wwac-open {
    transform: scale(1) translateY(0);
    opacity: 1;
    pointer-events: all;
}

/* Popup Header */
.wwac-popup-header {
    background: var(--wwac-green-dark);
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.wwac-avatar {
    width: 44px; height: 44px;
    border-radius: 50%;
    background: rgba(255,255,255,.2);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.wwac-header-info { flex: 1; }
.wwac-header-info strong {
    display: block;
    color: var(--wwac-white);
    font-size: 14px;
}
.wwac-status {
    font-size: 12px;
    color: rgba(255,255,255,.8);
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 2px;
}
.wwac-status-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: #8BC34A;
    display: inline-block;
    box-shadow: 0 0 0 2px rgba(139,195,74,.3);
}
.wwac-status-dot.offline { background: #9e9e9e; box-shadow: none; }
.wwac-close-btn {
    background: none; border: none;
    color: rgba(255,255,255,.7);
    cursor: pointer; font-size: 20px;
    line-height: 1; padding: 0;
    transition: color .15s;
}
.wwac-close-btn:hover { color: var(--wwac-white); }

/* Popup Body */
.wwac-popup-body {
    background: var(--wwac-bg);
    padding: 16px;
}
.wwac-chat-bubble {
    background: var(--wwac-white);
    border-radius: 0 12px 12px 12px;
    padding: 12px 14px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--wwac-text);
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
    position: relative;
    max-width: 90%;
    animation: wwac-fadein .3s ease;
}
.wwac-chat-bubble::before {
    content: '';
    position: absolute;
    top: 0; left: -8px;
    border: 8px solid transparent;
    border-top-color: var(--wwac-white);
    border-right-color: var(--wwac-white);
}
.wwac-chat-time {
    text-align: right;
    font-size: 11px;
    color: var(--wwac-subtext);
    margin-top: 4px;
}

/* Popup Footer */
.wwac-popup-footer { padding: 12px 16px 16px; }
.wwac-wa-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    background: var(--wwac-green);
    color: var(--wwac-white);
    text-decoration: none;
    border-radius: 10px;
    padding: 13px;
    font-size: 15px;
    font-weight: 600;
    transition: background .2s, transform .15s;
}
.wwac-wa-btn:hover {
    background: var(--wwac-green-dark);
    transform: translateY(-1px);
    color: var(--wwac-white);
}

/* Offline state */
.wwac-offline-note {
    background: #fff8e1;
    border-left: 3px solid #ffc107;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 13px;
    color: #5d4037;
    margin-bottom: 10px;
    line-height: 1.5;
}

/* ── Inline Widget ────────────────────────────────────── */
.wwac-inline-widget {
    border: 1px solid #e8e8e8;
    border-radius: var(--wwac-radius);
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,.08);
    max-width: 380px;
    font-family: inherit;
}
.wwac-inline-widget .wwac-popup-header { position: relative; }
.wwac-inline-widget .wwac-popup-body   { padding: 16px; }
.wwac-inline-widget .wwac-popup-footer { padding: 0 16px 16px; }

/* ── Animations ───────────────────────────────────────── */
@keyframes wwac-fadein {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Mobile ───────────────────────────────────────────── */
@media (max-width: 480px) {
    .wwac-fab span { display: none; }
    .wwac-fab { padding: 15px; border-radius: 50%; }
    .wwac-fab::after { width: 54px; height: 54px; }
    .wwac-popup { width: 290px; }
}
