.rocketchat-widget {
    display: none !important;
}

#sg-support-root {
    --sg-ease: cubic-bezier(.22, .61, .36, 1);
    --brand: #FDB93B;
    --brand-hi: #F8D48A;
    --brand-dim: rgba(253, 185, 59, 0.16);
    --brand-glow: rgba(253, 185, 59, 0.32);
    --navy: #071629;
    --navy-mid: #0A2240;
    --text: #E8EEF6;
    --text-dim: #C9D6E5;
    --text-faint: #9FB0C4;
    --line: rgba(255, 255, 255, 0.12);
    --sg-dock-gap: 24px;
    position: fixed;
    right: var(--sg-dock-gap);
    bottom: var(--sg-dock-gap);
    z-index: 1200;
    font-family: "Source Sans 3", system-ui, sans-serif;
    color: var(--text);
    -webkit-font-smoothing: antialiased;
}

#sg-support-root * { box-sizing: border-box; }

.sg-support-shell {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: max-content;
    max-width: min(380px, calc(100vw - 32px));
    border-radius: 999px;
    overflow: hidden;
    border: 1px solid transparent;
    background: transparent;
    box-shadow: none;
}

.sg-support-shell.is-open {
    width: min(380px, calc(100vw - 32px));
    max-height: calc(100vh - (var(--sg-dock-gap) * 2));
    border-radius: 16px;
    border-color: var(--line);
    background:
        radial-gradient(120% 80% at 100% 0%, rgba(253, 185, 59, 0.14), transparent 55%),
        linear-gradient(165deg, #071629 0%, #0A2240 70%, #0E2D52 100%);
    box-shadow: 0 28px 64px rgba(3, 12, 24, 0.45);
}

.sg-support-menu,
.sg-support-panel {
    display: none;
}

.sg-support-menu.is-open,
.sg-support-panel.is-open {
    display: block;
}

.sg-support-shell.is-open > .sg-support-chat.is-open {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

.sg-support-menu-hd { padding: 18px 18px 8px; }

.sg-support-eyebrow {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 6px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--brand);
}

.sg-support-eyebrow::before {
    content: "";
    width: 28px;
    height: 2px;
    background: var(--brand);
}

.sg-support-menu-hd p:last-child {
    margin: 0;
    font-size: 15px;
    line-height: 1.45;
    color: var(--text-dim);
}

.sg-support-menu-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px 14px 14px;
}

.sg-support-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 14px 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    color: inherit;
    font: inherit;
    text-align: center;
    cursor: pointer;
}

.sg-support-option:hover {
    background: var(--brand-dim);
    border-color: var(--brand-glow);
}

.sg-support-option-icon {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--brand-dim);
    border: 1px solid var(--brand-glow);
    color: var(--brand);
}

.sg-support-option-text strong {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}

.sg-support-option-text span {
    display: block;
    font-size: 12px;
    color: var(--text-faint);
}

.sg-support-panel-hd {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 14px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sg-support-panel-hd h3 {
    flex: 1;
    margin: 0;
    font-family: Newsreader, Georgia, serif;
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.02em;
    text-align: center;
    color: #fff;
}

.sg-support-icon-btn {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--text-dim);
    cursor: pointer;
}

.sg-support-icon-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.sg-support-form {
    padding: 14px 14px 16px;
    display: grid;
    gap: 12px;
}

.sg-support-form label {
    display: grid;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-dim);
}

.sg-support-form input,
.sg-support-form textarea,
.sg-support-chat-compose textarea {
    width: 100%;
    padding: 11px 12px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 6px;
    background: rgba(5, 15, 28, 0.45);
    color: #fff;
    font: inherit;
    font-size: 15px;
}

.sg-support-form input::placeholder,
.sg-support-form textarea::placeholder,
.sg-support-chat-compose textarea::placeholder { color: #9FB0C4; }

.sg-support-form input:focus,
.sg-support-form textarea:focus,
.sg-support-chat-compose textarea:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(253, 185, 59, 0.22);
}

.sg-support-form textarea { min-height: 88px; resize: vertical; }

.sg-support-form .sg-support-submit,
.sg-support-chat-send {
    border: 0;
    border-radius: 4px;
    background: var(--brand);
    color: #0B2340;
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
}

.sg-support-form .sg-support-submit {
    padding: 12px 16px;
}

.sg-support-form .sg-support-submit:hover:not(:disabled),
.sg-support-chat-send:hover:not(:disabled) { filter: brightness(1.06); }

.sg-support-form .sg-support-submit:disabled,
.sg-support-chat-send:disabled { opacity: 0.6; cursor: not-allowed; }

.sg-support-status { margin: 0; min-height: 16px; font-size: 13px; }
.sg-support-status.is-ok { color: #8EE0B2; }
.sg-support-status.is-err { color: #F0A8A8; }
.sg-support-optional { font-weight: 500; color: var(--text-faint); }

.sg-support-chat-start,
.sg-support-chat-active {
    display: none;
}

.sg-support-chat-start:not([hidden]) {
    display: block;
    overflow-y: auto;
    padding: 0 14px 16px;
}

.sg-support-chat-welcome {
    margin: 12px 0 4px;
    font-size: 14px;
    line-height: 1.45;
    color: var(--text-dim);
}

.sg-support-chat-start-form { padding: 0; }
.sg-support-chat-start-form textarea { min-height: 72px; }

.sg-support-chat-active:not([hidden]) {
    display: flex;
    flex-direction: column;
    min-height: 0;
    flex: 1;
}

.sg-support-chat-messages {
    flex: 1;
    min-height: 180px;
    max-height: 280px;
    overflow-y: auto;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sg-support-chat-bubble-row { display: flex; }
.sg-support-chat-bubble-row.is-visitor { justify-content: flex-end; }
.sg-support-chat-bubble-row.is-agent { justify-content: flex-start; }

.sg-support-chat-bubble {
    max-width: 88%;
    padding: 8px 11px;
    border-radius: 14px;
    font-size: 14px;
    line-height: 1.4;
}

.sg-support-chat-bubble-row.is-visitor .sg-support-chat-bubble {
    background: var(--brand);
    color: #0B2340;
    border-bottom-right-radius: 4px;
}

.sg-support-chat-bubble-row.is-agent .sg-support-chat-bubble {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-bottom-left-radius: 4px;
}

.sg-support-chat-sender {
    display: block;
    margin-bottom: 3px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--brand);
}

.sg-support-chat-text { margin: 0; white-space: pre-wrap; word-break: break-word; }

.sg-support-chat-compose {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 10px 12px 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sg-support-chat-compose textarea {
    flex: 1;
    min-height: 40px;
    max-height: 96px;
    resize: none;
}

.sg-support-chat-send {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
}

.sg-support-chat-send svg { stroke: #0B2340; }

.sg-support-launcher {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    flex-shrink: 0;
    min-height: 52px;
    padding: 8px 18px 8px 10px;
    border: 0;
    border-radius: 999px;
    background: var(--brand);
    color: #0B2340;
    box-shadow: 0 10px 28px rgba(7, 22, 41, 0.28);
    cursor: pointer;
    font: inherit;
    font-size: 15px;
    font-weight: 700;
}

.sg-support-shell:not(.is-open) .sg-support-launcher:hover {
    filter: brightness(1.06);
    transform: translateY(-2px);
}

.sg-support-shell.is-open .sg-support-launcher {
    border-radius: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.18);
    color: #fff;
    box-shadow: none;
}

.sg-support-launcher-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border-radius: 50%;
    background: var(--navy);
}

.sg-support-launcher-mark img {
    width: 22px;
    height: auto;
    display: block;
}

.sg-support-shell.is-open .sg-support-launcher-mark { display: none; }

.sg-support-launcher-label { flex: 1; text-align: left; }

.sg-support-live-dot {
    width: 8px;
    height: 8px;
    flex-shrink: 0;
    border-radius: 50%;
    background: #0B2340;
}

.sg-support-shell.is-open .sg-support-live-dot { display: none; }

.sg-support-launcher-chevron {
    display: grid;
    place-items: center;
    opacity: 0;
    color: currentColor;
}

.sg-support-shell.is-open .sg-support-launcher-chevron {
    opacity: 1;
}

.sg-support-shell.is-open .sg-support-launcher-chevron svg { stroke: #fff; }

@media (max-width: 480px) {
    #sg-support-root { --sg-dock-gap: 14px; }
    .sg-support-shell.is-open { width: calc(100vw - 28px); }
    .sg-support-shell:not(.is-open) .sg-support-launcher-label,
    .sg-support-shell:not(.is-open) .sg-support-live-dot,
    .sg-support-shell:not(.is-open) .sg-support-launcher-chevron { display: none; }
    .sg-support-shell:not(.is-open) .sg-support-launcher {
        width: 56px;
        padding: 0;
        justify-content: center;
    }
}

.sg-support-form input.sh-hp {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    padding: 0;
    border: 0;
    opacity: 0;
    pointer-events: none;
}
