:root {
    --mbwa-dark: #2E3A32;
    --mbwa-gold: #B08D47;
    --mbwa-sand: #EDE3D6;
    --mbwa-bone: #F7F3ED;
    --mbwa-green: #25D366;
}

.mbwa-widget,
.mbwa-widget * {
    box-sizing: border-box;
}

.mbwa-widget {
    position: fixed;
    left: 22px;
    right: auto;
    bottom: 22px;
    z-index: 999999;
    font-family: inherit, Arial, sans-serif;
}

.mbwa-fab {
    position: relative;
    width: 62px;
    height: 62px;
    border: 0;
    border-radius: 50%;
    background: var(--mbwa-green);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 14px 35px rgba(0,0,0,.22);
    transition: transform .2s ease, box-shadow .2s ease;
}

.mbwa-fab:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 18px 42px rgba(0,0,0,.26);
}

.mbwa-icon {
    width: 34px;
    height: 34px;
    position: relative;
    z-index: 2;
    display: block;
    color: #fff !important;
    fill: #fff !important;
    animation: mbwa-bounce 2.2s ease-in-out infinite;
}

.mbwa-pulse {
    position: absolute;
    inset: -7px;
    border-radius: 50%;
    border: 2px solid rgba(37,211,102,.48);
    animation: mbwa-pulse 1.8s ease-out infinite;
}

@keyframes mbwa-pulse {
    0% { transform: scale(.85); opacity: .9; }
    70%,100% { transform: scale(1.25); opacity: 0; }
}

@keyframes mbwa-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-2px); }
}

.mbwa-panel {
    position: absolute;
    left: 0;
    right: auto;
    bottom: 76px;
    width: min(360px, calc(100vw - 28px));
    background: #fff;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 22px 60px rgba(20,35,27,.24);
    border: 1px solid rgba(46,58,50,.10);
    transform-origin: bottom left;
    animation: mbwa-pop .18s ease-out;
}

@keyframes mbwa-pop {
    from { opacity: 0; transform: translateY(8px) scale(.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.mbwa-header {
    background: var(--mbwa-dark);
    color: #fff;
    padding: 18px 18px 16px;
    display: flex;
    gap: 14px;
    justify-content: space-between;
    align-items: flex-start;
}

.mbwa-header strong {
    display: block;
    font-size: 17px;
    line-height: 1.25;
    margin-bottom: 4px;
}

.mbwa-header span {
    display: block;
    color: rgba(255,255,255,.72);
    font-size: 12px;
}

.mbwa-close {
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 50%;
    background: rgba(255,255,255,.10);
    color: #fff;
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
}

.mbwa-body {
    padding: 20px;
    background: var(--mbwa-bone);
}

.mbwa-body label {
    display: block;
    color: var(--mbwa-dark);
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 8px;
}

.mbwa-select {
    width: 100%;
    min-height: 48px;
    padding: 0 13px;
    border: 1px solid #d8d0c5;
    border-radius: 10px;
    background: #fff;
    color: #333;
    font-size: 14px;
    outline: none;
}

.mbwa-select:focus {
    border-color: var(--mbwa-gold);
    box-shadow: 0 0 0 3px rgba(176,141,71,.12);
}

.mbwa-continue {
    width: 100%;
    min-height: 49px;
    margin-top: 15px;
    border: 0;
    border-radius: 10px;
    background: var(--mbwa-gold);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.mbwa-continue:hover {
    background: #96763A;
    transform: translateY(-1px);
}

.mbwa-error {
    margin: 8px 0 0;
    color: #b3261e;
    font-size: 12px;
}

.mbwa-note {
    display: block;
    text-align: center;
    margin-top: 11px;
    color: #777;
    font-size: 11px;
}

@media (max-width: 600px) {
    .mbwa-widget {
        left: 14px;
        right: auto;
        bottom: 18px;
    }

    .mbwa-fab {
        width: 58px;
        height: 58px;
    }

    .mbwa-panel {
        position: fixed;
        left: 14px;
        right: 14px;
        bottom: 88px;
        width: auto;
    }
}

.mbwa-icon path { fill: #fff !important; stroke: none !important; opacity: 1 !important; }

/* v1.0.2 - Patient-friendly care chat launcher */
.mbwa-fab {
    width: 68px;
    height: 68px;
    background: linear-gradient(145deg, #2E3A32 0%, #1f2b24 100%) !important;
    border: 2px solid rgba(176,141,71,.55) !important;
    box-shadow: 0 14px 36px rgba(46,58,50,.28), 0 0 0 6px rgba(237,227,214,.72) !important;
    overflow: visible;
}

.mbwa-fab:hover {
    transform: translateY(-4px) scale(1.04);
    box-shadow: 0 18px 44px rgba(46,58,50,.34), 0 0 0 7px rgba(176,141,71,.16) !important;
}

.mbwa-pulse {
    inset: -10px;
    border: 1.5px solid rgba(176,141,71,.58);
    animation: mbwa-pulse 2s ease-out infinite;
}

.mbwa-care-icon {
    position: relative;
    z-index: 3;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mbwa-care-ring {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, #B08D47 0%, #c9aa67 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.34), 0 5px 12px rgba(0,0,0,.16);
    animation: mbwa-care-float 2.7s ease-in-out infinite;
}

.mbwa-care-ring svg {
    width: 35px !important;
    height: 35px !important;
    display: block !important;
    overflow: visible !important;
}

.mbwa-chat-shape {
    fill: #fff !important;
    stroke: none !important;
}

.mbwa-heart-shape {
    fill: #2E3A32 !important;
    stroke: none !important;
}

.mbwa-spark {
    fill: none !important;
    stroke: #fff !important;
    stroke-width: 2.4 !important;
    stroke-linecap: round !important;
}

.mbwa-online-dot {
    position: absolute;
    right: -1px;
    bottom: 2px;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #25D366;
    border: 3px solid #2E3A32;
    box-shadow: 0 1px 6px rgba(0,0,0,.2);
}

.mbwa-hover-label {
    position: absolute;
    left: 78px;
    top: 50%;
    transform: translateY(-50%) translateX(-6px);
    white-space: nowrap;
    padding: 9px 13px;
    border-radius: 999px;
    background: #2E3A32;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease, visibility .2s ease;
    box-shadow: 0 8px 22px rgba(46,58,50,.2);
}

.mbwa-hover-label::before {
    content: "";
    position: absolute;
    left: -5px;
    top: 50%;
    width: 10px;
    height: 10px;
    background: #2E3A32;
    transform: translateY(-50%) rotate(45deg);
}

.mbwa-fab:hover .mbwa-hover-label,
.mbwa-fab:focus-visible .mbwa-hover-label {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateX(0);
}

@keyframes mbwa-care-float {
    0%,100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-2px) rotate(-2deg); }
}

@media (max-width: 600px) {
    .mbwa-fab {
        width: 64px;
        height: 64px;
    }
    .mbwa-care-icon { width: 48px; height: 48px; }
    .mbwa-care-ring { width: 46px; height: 46px; }
    .mbwa-care-ring svg { width: 32px !important; height: 32px !important; }
    .mbwa-hover-label { display: none; }
}

/* ==========================================================
   v1.0.3 - Patient concern field + Medical Concierge icon
   ========================================================== */
.mbwa-body label + .mbwa-concern,
.mbwa-concern {
    width: 100%;
    min-height: 104px;
    padding: 12px 13px;
    margin: 0 0 6px;
    border: 1px solid #d8d0c5;
    border-radius: 10px;
    background: #fff;
    color: #333;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    resize: vertical;
    outline: none;
}

.mbwa-body .mbwa-select {
    margin-bottom: 15px;
}

.mbwa-concern:focus {
    border-color: var(--mbwa-gold);
    box-shadow: 0 0 0 3px rgba(176,141,71,.12);
}

.mbwa-char-note {
    display: block;
    color: #7b7b77;
    font-size: 10.5px;
    line-height: 1.45;
    margin: 0 0 2px;
}

/* New patient concierge / receptionist headset icon */
.mbwa-care-ring {
    background: linear-gradient(145deg, #B08D47 0%, #c8aa68 100%) !important;
}

.mbwa-care-ring svg {
    width: 38px !important;
    height: 38px !important;
}

.mbwa-icon-face {
    fill: #fff !important;
    stroke: none !important;
}

.mbwa-icon-body,
.mbwa-icon-headset,
.mbwa-icon-mic {
    fill: none !important;
    stroke: #fff !important;
    stroke-width: 3 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
}

.mbwa-icon-ear {
    fill: #2E3A32 !important;
    stroke: #fff !important;
    stroke-width: 1.7 !important;
}

.mbwa-icon-mic-dot {
    fill: #fff !important;
}

.mbwa-icon-heart {
    fill: #2E3A32 !important;
    stroke: none !important;
}

.mbwa-header strong::before {
    content: "●";
    color: #25D366;
    font-size: 9px;
    margin-right: 7px;
    vertical-align: 2px;
}

@media (max-width: 600px) {
    .mbwa-panel {
        max-height: calc(100vh - 110px);
        overflow-y: auto;
    }
    .mbwa-concern {
        min-height: 92px;
    }
}
