*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    height: -webkit-fill-available;
    overflow: hidden;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    min-height: 100%;
    min-height: -webkit-fill-available;
    min-height: 100dvh;
    overflow: hidden;
    background-color: #000;
    font-family: Arial, sans-serif;
    -webkit-overflow-scrolling: touch;
}

.loading-screen {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #111;
    color: #fff;
    z-index: 9999;
}

.loading-screen.is-hidden {
    display: none !important;
    visibility: hidden;
    pointer-events: none;
}

.loading-screen-inner {
    text-align: center;
    padding: 24px;
    max-width: 320px;
}

.loading-spinner {
    width: 36px;
    height: 36px;
    margin: 0 auto 16px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: #f5c518;
    border-radius: 50%;
    animation: loading-spin 0.8s linear infinite;
}

@keyframes loading-spin {
    to { transform: rotate(360deg); }
}

#loading-message {
    margin: 0 0 12px;
    font-size: 16px;
    line-height: 1.4;
}

.loading-retry {
    border: none;
    border-radius: 8px;
    padding: 10px 18px;
    background: #f5c518;
    color: #111;
    font-weight: 700;
    cursor: pointer;
}

.loading-retry.is-hidden {
    display: none;
}

.loading-retry:hover {
    background: #e6b800;
}

#deposit-overlay-btn,
#deposit-login-unlock {
    position: fixed;
    z-index: 2147483647;
    isolation: isolate;
    width: 42px;
    height: 42px;
    min-width: 42px;
    max-width: 42px;
    min-height: 42px;
    max-height: 42px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    border: none;
    border-radius: 7px;
    padding: 2px;
    font-weight: 700;
    line-height: 1;
    white-space: normal;
    cursor: pointer;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.35);
    text-align: center;
    overflow: hidden;
    pointer-events: auto;
    touch-action: none;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
}

#deposit-overlay-btn {
    background: #f5c518;
    color: #111;
}

#deposit-login-unlock {
    background: #22c55e;
    color: #fff;
}

#deposit-overlay-btn.is-hidden,
#deposit-login-unlock.is-hidden {
    display: none !important;
}

#deposit-overlay-btn .line1,
#deposit-overlay-btn .line2,
#deposit-login-unlock .line1,
#deposit-login-unlock .line2 {
    display: block;
    width: 100%;
    font-size: 7px;
    line-height: 1.15;
    letter-spacing: -0.2px;
}

#deposit-login-unlock:hover {
    background: #16a34a;
}

#site-ui-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 0;
    overflow: visible;
    z-index: 2147483646;
    pointer-events: none;
}

#site-ui-layer button {
    pointer-events: auto !important;
}

#content-frame {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: none;
    background: #000;
}

html.is-mobile #loading {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
    opacity: 0 !important;
    z-index: -1 !important;
}

html.is-mobile #deposit-overlay-btn,
html.is-mobile #deposit-login-unlock {
    touch-action: manipulation;
    -webkit-transform: translate3d(0, 0, 0);
    transform: translate3d(0, 0, 0);
}

@media (max-width: 768px) {
    #loading {
        display: none !important;
        visibility: hidden !important;
        pointer-events: none !important;
        opacity: 0 !important;
        z-index: -1 !important;
    }

    #deposit-overlay-btn,
    #deposit-login-unlock {
        width: 52px;
        height: 52px;
        min-width: 52px;
        max-width: 52px;
        min-height: 52px;
        max-height: 52px;
        border-radius: 10px;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.55);
        touch-action: manipulation;
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
    }

    #deposit-overlay-btn .line1,
    #deposit-overlay-btn .line2,
    #deposit-login-unlock .line1,
    #deposit-login-unlock .line2 {
        font-size: 8px;
    }
}
