.screen-help-widget {
    position: fixed;
    right: max(20px, calc(env(safe-area-inset-right) + 12px));
    bottom: max(52px, calc(env(safe-area-inset-bottom) + 52px));
    z-index: 2147483500;
    display: block;
    box-sizing: border-box;
    width: 52px;
    height: 52px;
    color: var(--app-text, #18345e);
    isolation: isolate;
}

.screen-help-button {
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 4;
    display: inline-flex;
    box-sizing: border-box;
    width: 52px;
    height: 52px;
    padding: 0;
    align-items: center;
    justify-content: center;
    overflow: visible;
    border: 1px solid rgba(255, 255, 255, .78);
    border-radius: 50%;
    background: #2baae2;
    box-shadow:
        0 10px 24px rgba(14, 39, 79, .32),
        inset 0 1px 0 rgba(255, 255, 255, .28);
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-size: 21px;
    line-height: 1;
    list-style: none;
    text-decoration: none;
    opacity: .72;
    filter: saturate(.82);
    -webkit-tap-highlight-color: transparent;
    transition:
        transform .18s cubic-bezier(.2, .8, .2, 1),
        box-shadow .18s ease,
        border-color .18s ease,
        background-color .18s ease,
        filter .18s ease,
        opacity .18s ease;
}

.screen-help-button::-webkit-details-marker {
    display: none;
}

.screen-help-widget:hover .screen-help-button,
.screen-help-widget:focus-within .screen-help-button,
.screen-help-widget.is-open .screen-help-button {
    border-color: rgba(255, 255, 255, .96);
    box-shadow:
        0 14px 30px rgba(14, 39, 79, .38),
        inset 0 1px 0 rgba(255, 255, 255, .34);
    color: #fff;
    text-decoration: none;
    opacity: 1;
    filter: none;
    transform: translateY(-3px) scale(1.025);
}

.screen-help-button--image {
    overflow: hidden;
    padding: 3px;
    border-color: rgba(49, 92, 163, .46);
    background: rgba(250, 253, 255, .98);
    box-shadow:
        0 10px 24px rgba(14, 39, 79, .28),
        0 0 0 3px rgba(255, 255, 255, .16);
    color: #315ca3;
}

.screen-help-widget:hover .screen-help-button--image,
.screen-help-widget:focus-within .screen-help-button--image,
.screen-help-widget.is-open .screen-help-button--image {
    border-color: rgba(67, 125, 204, .82);
    background: #fff;
    box-shadow:
        0 14px 30px rgba(14, 39, 79, .34),
        0 0 0 4px rgba(80, 141, 220, .14);
    color: #244a86;
}

.screen-help-button__image {
    position: absolute;
    inset: 3px;
    z-index: 1;
    display: block;
    box-sizing: border-box;
    width: calc(100% - 6px);
    height: calc(100% - 6px);
    border-radius: 50%;
    background: #fff;
    object-fit: contain;
    pointer-events: none;
    transition: opacity .18s ease, visibility .18s ease;
}

.screen-help-button__image--hover {
    z-index: 2;
    opacity: 0;
    visibility: hidden;
}

.screen-help-widget:hover .screen-help-button--dual-image .screen-help-button__image--normal,
.screen-help-widget:focus-within .screen-help-button--dual-image .screen-help-button__image--normal,
.screen-help-widget.is-open .screen-help-button--dual-image .screen-help-button__image--normal {
    opacity: 0;
    visibility: hidden;
}

.screen-help-widget:hover .screen-help-button--dual-image .screen-help-button__image--hover,
.screen-help-widget:focus-within .screen-help-button--dual-image .screen-help-button__image--hover,
.screen-help-widget.is-open .screen-help-button--dual-image .screen-help-button__image--hover {
    opacity: 1;
    visibility: visible;
}

.screen-help-button__fallback {
    position: absolute;
    inset: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Gipsi: identidad visual predeterminada del acceso a la mesa de ayuda. */
.screen-help-widget--brand-image {
    width: clamp(178px, 13vw, 210px);
    height: clamp(82px, 6vw, 97px);
    pointer-events: none;
}

.screen-help-button--brand-image,
body.theme-dark .screen-help-button--brand-image {
    width: clamp(48px, 3.7vw, 58px);
    height: 100%;
    padding: 0;
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: transparent;
    pointer-events: auto;
}

.screen-help-button--brand-image {
    opacity: .48;
    filter: saturate(.82) drop-shadow(0 7px 11px rgba(12, 38, 77, .2));
    transform-origin: right bottom;
    transition:
        width .22s cubic-bezier(.2, .8, .2, 1),
        transform .18s cubic-bezier(.2, .8, .2, 1),
        filter .18s ease,
        opacity .18s ease;
}

.screen-help-widget:hover .screen-help-button--brand-image,
.screen-help-widget:focus-within .screen-help-button--brand-image,
.screen-help-widget.is-open .screen-help-button--brand-image {
    width: 100%;
    height: 100%;
    padding: 0;
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: transparent;
    opacity: 1;
    filter: drop-shadow(0 10px 14px rgba(12, 38, 77, .32));
    transform: translateY(-2px) scale(1.01);
}

.screen-help-button--brand-image .screen-help-button__image {
    inset: 0 0 0 auto;
    width: clamp(48px, 3.7vw, 58px);
    height: 100%;
    border-radius: 0;
    background: transparent;
    object-fit: cover;
    object-position: center 38%;
}

.screen-help-button--brand-image .screen-help-button__image--hover {
    inset: 0;
    width: 100%;
    object-fit: contain;
    object-position: right bottom;
}

.screen-help-button--brand-image .screen-help-button__fallback {
    opacity: 0;
}

.screen-help-widget--brand-image .screen-help-prompt {
    display: none;
}

.screen-help-button:focus-visible,
.screen-help-menu__item:focus-visible {
    outline: 3px solid #ffc94a;
    outline-offset: 3px;
}

.screen-help-prompt {
    position: absolute;
    right: calc(100% + 12px);
    bottom: 7px;
    z-index: 2;
    display: inline-flex;
    box-sizing: border-box;
    min-height: 38px;
    padding: 9px 13px;
    align-items: center;
    gap: 7px;
    border: 1px solid rgba(43, 78, 126, .09);
    border-radius: 13px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 8px 22px rgba(23, 43, 77, .19);
    color: #17345f;
    font-size: .79rem;
    line-height: 1.18;
    opacity: 0;
    pointer-events: none;
    transform: translate(8px, 3px) scale(.97);
    transform-origin: right center;
    visibility: hidden;
    white-space: nowrap;
    backdrop-filter: blur(10px);
    transition:
        opacity .16s ease,
        transform .2s cubic-bezier(.2, .8, .2, 1),
        visibility .16s ease;
}

.screen-help-prompt::after {
    position: absolute;
    top: 50%;
    right: -6px;
    width: 11px;
    height: 11px;
    border-top: 1px solid rgba(43, 78, 126, .09);
    border-right: 1px solid rgba(43, 78, 126, .09);
    background: rgba(255, 255, 255, .96);
    content: "";
    transform: translateY(-50%) rotate(45deg);
}

.screen-help-prompt i {
    color: #f0a423;
    font-size: .9rem;
}

.screen-help-prompt .fa-whatsapp {
    color: #1fa463;
}

.screen-help-widget:hover .screen-help-prompt,
.screen-help-widget:focus-within .screen-help-prompt,
.screen-help-widget.is-open .screen-help-prompt {
    opacity: 1;
    transform: translate(0, 0) scale(1);
    visibility: visible;
}

.screen-help-menu {
    position: absolute;
    right: 0;
    bottom: calc(100% + 14px);
    z-index: 3;
    display: grid;
    box-sizing: border-box;
    width: min(310px, calc(100vw - 28px));
    max-height: min(410px, calc(100vh - 150px));
    padding: 8px;
    overflow: auto;
    border: 1px solid rgba(43, 78, 126, .12);
    border-radius: 16px;
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 18px 46px rgba(19, 41, 74, .25);
    opacity: 0;
    pointer-events: none;
    transform: translateY(9px) scale(.97);
    transform-origin: right bottom;
    visibility: hidden;
    backdrop-filter: blur(14px);
    scrollbar-width: thin;
    transition:
        opacity .16s ease,
        transform .2s cubic-bezier(.2, .8, .2, 1),
        visibility .16s ease;
}

.screen-help-widget--multiple.is-open .screen-help-menu {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0) scale(1);
    visibility: visible;
}

.screen-help-menu__eyebrow {
    padding: 7px 10px 8px;
    color: #6a7a91;
    font-size: .65rem;
    font-weight: 800;
    letter-spacing: .11em;
}

.screen-help-menu__item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 28px;
    gap: 10px;
    align-items: center;
    min-height: 54px;
    padding: 9px 10px;
    border-radius: 11px;
    color: #17345f;
    text-decoration: none;
    transition: background-color .16s ease, color .16s ease, transform .16s ease;
}

button.screen-help-menu__item {
    width: 100%;
    border: 0;
    background: transparent;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.screen-help-menu__item + .screen-help-menu__item {
    border-top: 1px solid rgba(43, 78, 126, .08);
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
}

.screen-help-menu__item:hover,
.screen-help-menu__item:focus-visible {
    background: #eef6ff;
    color: #174f95;
    text-decoration: none;
    transform: translateX(-2px);
}

.screen-help-menu__item span,
.screen-help-menu__item strong,
.screen-help-menu__item small {
    display: block;
    min-width: 0;
}

.screen-help-menu__item strong {
    overflow: hidden;
    font-size: .84rem;
    font-weight: 750;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.screen-help-menu__item small {
    margin-top: 2px;
    color: #728198;
    font-size: .69rem;
}

.screen-help-menu__item > i {
    display: inline-flex;
    width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: #e8f2ff;
    color: #2c68b6;
    font-size: .76rem;
}

.screen-help-menu__item--whatsapp > i {
    background: #e5f8ee;
    color: #128c57;
    font-size: .94rem;
}

.screen-help-menu__item--whatsapp:hover,
.screen-help-menu__item--whatsapp:focus-visible {
    background: #ecfaf2;
    color: #0d7447;
}

.screen-help-menu__item--assistant > i {
    background: #eeeaff;
    color: #6750c7;
    font-size: .88rem;
}

.screen-help-menu__item--assistant:hover,
.screen-help-menu__item--assistant:focus-visible {
    background: #f3f0ff;
    color: #5139b5;
}

body.screen-help-assistant-open {
    overflow: hidden;
}

.screen-help-assistant[hidden] {
    display: none !important;
}

.screen-help-assistant {
    position: fixed;
    inset: 0;
    z-index: 2147483600;
    display: flex;
    box-sizing: border-box;
    padding: clamp(12px, 2.5vw, 30px);
    align-items: center;
    justify-content: flex-end;
    pointer-events: auto;
}

.screen-help-assistant__backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(8, 22, 43, .62);
    cursor: default;
    backdrop-filter: blur(5px);
}

.screen-help-assistant__panel {
    position: relative;
    z-index: 1;
    display: grid;
    width: min(520px, 100%);
    max-height: calc(100vh - clamp(24px, 5vw, 60px));
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .68);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(4, 17, 38, .42);
    animation: screen-help-assistant-slide-in .22s ease-out both;
}

@keyframes screen-help-assistant-slide-in {
    from {
        opacity: 0;
        transform: translateX(32px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.screen-help-assistant__header {
    display: flex;
    min-height: 52px;
    padding: 8px 10px 8px 16px;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid rgba(43, 78, 126, .12);
    background: #f7faff;
    color: #17345f;
}

.screen-help-assistant__heading {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    gap: 9px;
}

.screen-help-assistant__heading i {
    color: #6750c7;
}

.screen-help-assistant__heading strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.screen-help-assistant__actions {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 7px;
}

.screen-help-assistant__external,
.screen-help-assistant__close {
    display: inline-flex;
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    padding: 0;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(43, 78, 126, .14);
    border-radius: 10px;
    background: #fff;
    color: #52647e;
    cursor: pointer;
}

.screen-help-assistant__external:hover,
.screen-help-assistant__external:focus-visible,
.screen-help-assistant__close:hover,
.screen-help-assistant__close:focus-visible {
    border-color: rgba(103, 80, 199, .38);
    background: #f1edff;
    color: #5139b5;
}

.screen-help-assistant__frame {
    display: block;
    width: 100%;
    max-height: calc(100vh - 112px);
    border: 0;
    background: #fff;
}

body.theme-dark .screen-help-button--image:not(.screen-help-button--brand-image) {
    border-color: rgba(145, 190, 255, .72);
    background: #f8fbff;
    box-shadow:
        0 12px 28px rgba(0, 0, 0, .46),
        0 0 0 3px rgba(122, 174, 245, .12);
}

body.theme-dark .screen-help-prompt,
body.theme-dark .screen-help-menu {
    border-color: rgba(145, 190, 255, .19);
    background: rgba(20, 36, 58, .96);
    color: #edf5ff;
    box-shadow: 0 18px 46px rgba(0, 0, 0, .44);
}

body.theme-dark .screen-help-prompt::after {
    border-color: rgba(145, 190, 255, .19);
    background: rgba(20, 36, 58, .96);
}

body.theme-dark .screen-help-menu__eyebrow,
body.theme-dark .screen-help-menu__item small {
    color: #aabbd0;
}

body.theme-dark .screen-help-menu__item {
    color: #edf5ff;
}

body.theme-dark .screen-help-menu__item + .screen-help-menu__item {
    border-top-color: rgba(145, 190, 255, .12);
}

body.theme-dark .screen-help-menu__item:hover,
body.theme-dark .screen-help-menu__item:focus-visible {
    background: rgba(70, 126, 194, .2);
    color: #fff;
}

body.theme-dark .screen-help-menu__item > i {
    background: rgba(73, 137, 218, .2);
    color: #9cc8ff;
}

body.theme-dark .screen-help-menu__item--whatsapp > i {
    background: rgba(37, 211, 102, .16);
    color: #74e8a1;
}

body.theme-dark .screen-help-menu__item--whatsapp:hover,
body.theme-dark .screen-help-menu__item--whatsapp:focus-visible {
    background: rgba(37, 211, 102, .13);
    color: #eafff2;
}

body.theme-dark .screen-help-menu__item--assistant > i {
    background: rgba(145, 116, 255, .18);
    color: #c2b1ff;
}

body.theme-dark .screen-help-menu__item--assistant:hover,
body.theme-dark .screen-help-menu__item--assistant:focus-visible {
    background: rgba(145, 116, 255, .14);
    color: #f4f0ff;
}

body.theme-dark .screen-help-assistant__panel {
    border-color: rgba(145, 190, 255, .22);
    background: #14243a;
}

body.theme-dark .screen-help-assistant__header {
    border-bottom-color: rgba(145, 190, 255, .16);
    background: #172b45;
    color: #edf5ff;
}

body.theme-dark .screen-help-assistant__external,
body.theme-dark .screen-help-assistant__close {
    border-color: rgba(145, 190, 255, .2);
    background: #203854;
    color: #d7e7fa;
}

@media (max-width: 767.98px) {
    .screen-help-widget {
        right: max(14px, calc(env(safe-area-inset-right) + 10px));
        bottom: max(48px, calc(env(safe-area-inset-bottom) + 48px));
        width: 48px;
        height: 48px;
    }

    .screen-help-button {
        width: 48px;
        height: 48px;
        font-size: 19px;
    }

    .screen-help-widget--brand-image {
        width: clamp(142px, 40vw, 162px);
        height: clamp(65px, 18.5vw, 75px);
    }

    .screen-help-widget--brand-image .screen-help-button {
        height: 100%;
    }

    .screen-help-widget--brand-image .screen-help-button--brand-image,
    .screen-help-widget--brand-image .screen-help-button__image--normal {
        width: clamp(40px, 11vw, 47px);
    }

    .screen-help-widget--brand-image:hover .screen-help-button--brand-image,
    .screen-help-widget--brand-image:focus-within .screen-help-button--brand-image,
    .screen-help-widget--brand-image.is-open .screen-help-button--brand-image,
    .screen-help-widget--brand-image .screen-help-button__image--hover {
        width: 100%;
    }

    .screen-help-prompt {
        right: calc(100% + 10px);
        bottom: 5px;
        max-width: calc(100vw - 86px);
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .screen-help-menu {
        right: 0;
        bottom: calc(100% + 12px);
    }

    .screen-help-assistant {
        padding: 8px;
        align-items: stretch;
    }

    .screen-help-assistant__panel {
        width: 100%;
        max-height: calc(100vh - 16px);
        border-radius: 14px;
    }

    .screen-help-assistant__frame {
        height: calc(100vh - 70px);
        max-height: calc(100vh - 70px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .screen-help-button,
    .screen-help-button__image,
    .screen-help-prompt,
    .screen-help-menu,
    .screen-help-menu__item,
    .screen-help-assistant__panel {
        transition: none;
        animation: none;
    }
}

@media (forced-colors: active) {
    .screen-help-button,
    .screen-help-prompt,
    .screen-help-menu {
        border: 2px solid ButtonText;
        background: ButtonFace;
        color: ButtonText;
        forced-color-adjust: auto;
    }
}
