/* ==========================================================================
   Footer Module Styles — eztio Global Footer
   Design tokens: DNA.md (primary-950, cta, neutral scale)
   ========================================================================== */

/* --------------------------------------------------------------------------
   Floating Action Buttons
   -------------------------------------------------------------------------- */
.eztio-fab-group {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 50;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.eztio-fab {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease, opacity 0.3s ease, visibility 0.3s ease;
}

.eztio-fab:hover {
    transform: scale(1.08);
}

.eztio-fab--top {
    width: 48px;
    height: 48px;
    background-color: #155E75;
    color: #fff;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
}

.eztio-fab--top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.eztio-fab--top:hover {
    background-color: #0E7490;
    transform: scale(1.08);
}

.eztio-fab--wa {
    width: 56px;
    height: 56px;
    background-color: #25D366;
    color: #fff;
}

.eztio-fab--wa:hover {
    background-color: #20b858;
}

/* --------------------------------------------------------------------------
   WhatsApp Chat Panel
   -------------------------------------------------------------------------- */
.eztio-wa-panel {
    position: fixed;
    bottom: 100px;
    right: 1.5rem;
    width: 360px;
    max-width: calc(100vw - 2rem);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(16px) scale(0.96);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    font-family: 'Inter', system-ui, sans-serif;
}

.eztio-wa-panel.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* Panel Header */
.eztio-wa-panel__header {
    background: #075e54;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.eztio-wa-panel__header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.eztio-wa-panel__avatar {
    width: 42px;
    height: 42px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.eztio-wa-panel__close {
    background: none;
    border: none;
    color: #fff;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
    padding: 0 4px;
}

.eztio-wa-panel__close:hover {
    opacity: 1;
}

/* Panel Body */
.eztio-wa-panel__body {
    background: #ece5dd;
    padding: 20px;
}

.eztio-wa-panel__bubble {
    background: #fff;
    padding: 14px 18px;
    border-radius: 0 12px 12px 12px;
    margin-bottom: 20px;
    color: #333;
    font-size: 14px;
    line-height: 1.5;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

/* Panel Form */
.eztio-wa-panel__form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.eztio-wa-panel__form input,
.eztio-wa-panel__form textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    background: #fff;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
}

.eztio-wa-panel__form input:focus,
.eztio-wa-panel__form textarea:focus {
    border-color: #25D366;
    box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.1);
}

.eztio-wa-panel__form input.is-invalid,
.eztio-wa-panel__form textarea.is-invalid {
    border-color: #e53e3e;
}

.eztio-wa-panel__form textarea {
    min-height: 72px;
    resize: vertical;
}

.eztio-wa-panel__submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #25D366;
    color: #fff;
    border: none;
    padding: 13px 20px;
    border-radius: 24px;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.2s ease;
    margin-top: 4px;
}

.eztio-wa-panel__submit:hover {
    background: #1fad55;
}

/* Panel Footer */
.eztio-wa-panel__footer {
    padding: 12px 20px;
    background: #f7f7f7;
    border-top: 1px solid #e8e8e8;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 11px;
    color: #888;
}

.eztio-wa-panel__status-dot {
    width: 8px;
    height: 8px;
    background: #25D366;
    border-radius: 50%;
    animation: eztio-pulse 2s infinite;
}

@keyframes eztio-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.85); }
}

.eztio-wa-panel__status-text {
    color: #25D366;
    font-weight: 600;
}

.eztio-wa-panel__divider {
    color: #ccc;
}

.eztio-wa-panel__mini-logo {
    display: inline-block;
}

/* --------------------------------------------------------------------------
   Responsive Adjustments
   -------------------------------------------------------------------------- */
@media (max-width: 480px) {
    .eztio-wa-panel {
        bottom: 80px;
        right: 0.75rem;
        width: calc(100vw - 1.5rem);
        max-width: 360px;
    }

    .eztio-fab-group {
        bottom: 1rem;
        right: 1rem;
    }

    .eztio-fab--wa {
        width: 52px;
        height: 52px;
    }

    .eztio-fab--top {
        width: 44px;
        height: 44px;
    }
}
