    :root {
        color-scheme: dark;
        --bg: #08090d;
        --panel: #12131a;
        --text: #f5f2ff;
        --muted: #a9a3ba;
        --line: rgba(178, 158, 255, .22);
        --violet: #b9a4ff;
        --green: #6ee7b7;
    }

    * { box-sizing: border-box; }

    html, body { min-height: 100%; }

    body {
        margin: 0;
        padding: 40px 20px calc(40px + env(safe-area-inset-bottom));
        display: flex;
        align-items: center;
        justify-content: center;
        background:
            radial-gradient(90% 60% at 50% -10%, rgba(124, 96, 255, .24), transparent 60%),
            radial-gradient(70% 50% at 100% 100%, rgba(255, 122, 168, .08), transparent 60%),
            var(--bg);
        color: var(--text);
        font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
        -webkit-font-smoothing: antialiased;
    }

    .as-qr-shell { width: 100%; max-width: 560px; }

    .as-qr-brand {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
        margin-bottom: 26px;
    }

    .as-qr-brand-name {
        display: inline-flex;
        align-items: center;
        gap: 10px;
        font-size: 11px;
        font-weight: 800;
        letter-spacing: .22em;
        text-transform: uppercase;
    }

    .as-qr-brand-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: var(--violet);
        box-shadow: 0 0 14px var(--violet);
    }

    .as-qr-brand-pill {
        padding: 5px 9px;
        border: 1px solid var(--line);
        border-radius: 999px;
        color: var(--muted);
        font-size: 9px;
        font-weight: 800;
        letter-spacing: .14em;
        text-transform: uppercase;
    }

    h1 {
        margin: 0;
        font-size: clamp(30px, 7vw, 44px);
        font-weight: 780;
        line-height: 1.02;
        letter-spacing: -.045em;
    }

    .as-qr-lead {
        margin: 12px 0 0;
        max-width: 44ch;
        color: var(--muted);
        font-size: 14px;
        line-height: 1.5;
    }

    .as-qr-user {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-top: 22px;
        padding: 12px 14px;
        border: 1px solid rgba(255, 255, 255, .08);
        border-radius: 16px;
        background: rgba(255, 255, 255, .04);
    }

    .as-qr-avatar {
        display: inline-flex;
        width: 38px;
        height: 38px;
        flex: 0 0 38px;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        background: linear-gradient(160deg, #9b82ff, #6d4bff);
        color: #fff;
        font-size: 15px;
        font-weight: 800;
        box-shadow: 0 6px 18px rgba(109, 75, 255, .35);
    }

    .as-qr-user-copy { min-width: 0; }

    .as-qr-user-name {
        margin: 0;
        overflow: hidden;
        font-size: 13px;
        font-weight: 700;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .as-qr-user-role {
        margin: 2px 0 0;
        color: var(--muted);
        font-size: 10px;
        font-weight: 700;
        letter-spacing: .1em;
        text-transform: uppercase;
    }

    .as-qr-card {
        margin-top: 22px;
        padding: 22px;
        border: 1px solid var(--line);
        border-radius: 26px;
        background:
            radial-gradient(120% 90% at 12% -10%, rgba(124, 96, 255, .18), transparent 58%),
            linear-gradient(180deg, #12131a, #0b0c11 70%);
        box-shadow: 0 32px 80px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .06);
    }

    .as-qr-frame {
        position: relative;
        width: min(330px, 100%);
        margin: 0 auto;
        padding: 16px;
        border-radius: 20px;
        background: #fff;
        box-shadow: 0 12px 32px rgba(0, 0, 0, .35);
    }

    .as-qr-frame::before,
    .as-qr-frame::after {
        content: "";
        position: absolute;
        width: 22px;
        height: 22px;
        border: 3px solid var(--violet);
        border-radius: 6px;
        opacity: .9;
    }

    .as-qr-frame::before { top: -8px; left: -8px; border-right: 0; border-bottom: 0; }
    .as-qr-frame::after { right: -8px; bottom: -8px; border-left: 0; border-top: 0; }

    #as-qr-svg { display: block; min-height: 220px; }
    #as-qr-svg svg { display: block; width: 100%; height: auto; }

    .as-qr-statusrow {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 9px;
        margin-top: 18px;
        color: var(--muted);
        font-size: 12px;
        font-weight: 600;
        text-align: center;
    }

    .as-qr-pulse {
        width: 7px;
        height: 7px;
        flex: 0 0 7px;
        border-radius: 50%;
        background: var(--green);
        box-shadow: 0 0 10px var(--green);
        animation: as-qr-pulse 2.4s ease-in-out infinite;
    }

    @keyframes as-qr-pulse {
        0%, 100% { opacity: 1; transform: scale(1); }
        50% { opacity: .45; transform: scale(.8); }
    }

    .as-qr-left {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        margin-top: 10px;
        color: var(--muted);
        font-size: 11px;
        font-variant-numeric: tabular-nums;
    }

    .as-qr-left strong { color: var(--text); font-weight: 800; }

    .as-qr-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        justify-content: center;
        margin-top: 20px;
    }

    .as-qr-btn {
        display: inline-flex;
        min-height: 40px;
        align-items: center;
        justify-content: center;
        padding: 0 16px;
        border: 1px solid rgba(255, 255, 255, .14);
        border-radius: 12px;
        background: rgba(255, 255, 255, .06);
        color: var(--text);
        font-family: inherit;
        font-size: 11px;
        font-weight: 750;
        line-height: 1;
        text-decoration: none;
        cursor: pointer;
        -webkit-appearance: none;
        appearance: none;
        transition: background .16s ease, border-color .16s ease;
    }

    .as-qr-btn:hover { background: rgba(255, 255, 255, .11); border-color: rgba(255, 255, 255, .26); }
    .as-qr-btn:focus-visible { outline: 2px solid var(--violet); outline-offset: 3px; }
    .as-qr-btn.primary { border-color: transparent; background: var(--violet); color: #151022; }
    .as-qr-btn.primary:hover { background: #c9b8ff; }
    .as-qr-btn[aria-disabled="true"] { opacity: .45; pointer-events: none; }

    .as-qr-steps {
        display: grid;
        gap: 10px;
        margin: 22px 0 0;
        padding: 0;
        list-style: none;
    }

    .as-qr-steps li {
        display: flex;
        align-items: flex-start;
        gap: 11px;
        color: var(--muted);
        font-size: 12px;
        line-height: 1.45;
    }

    .as-qr-step-num {
        display: inline-flex;
        width: 21px;
        height: 21px;
        flex: 0 0 21px;
        align-items: center;
        justify-content: center;
        border: 1px solid var(--line);
        border-radius: 50%;
        color: var(--violet);
        font-size: 9px;
        font-weight: 800;
    }

    .as-qr-steps strong { color: var(--text); font-weight: 700; }

    .as-qr-note {
        display: flex;
        align-items: flex-start;
        gap: 9px;
        margin-top: 22px;
        padding-top: 16px;
        border-top: 1px solid rgba(255, 255, 255, .07);
        color: #8d87a0;
        font-size: 10.5px;
        line-height: 1.45;
    }

    .as-qr-note svg { width: 14px; height: 14px; flex: 0 0 14px; margin-top: 1px; }

    .as-qr-error {
        margin-top: 14px;
        padding: 10px 12px;
        border: 1px solid rgba(255, 120, 120, .35);
        border-radius: 10px;
        background: rgba(255, 80, 80, .08);
        color: #ffc9c9;
        font-size: 11px;
        line-height: 1.4;
    }

    .as-qr-error[hidden] { display: none; }

    .as-qr-foot {
        margin-top: 18px;
        color: #6f6a80;
        font-size: 9.5px;
        text-align: center;
    }

    .as-qr-foot a { color: #9a92b3; text-decoration: underline; text-underline-offset: 2px; }

    @media (max-width: 420px) {
        .as-qr-card { padding: 16px; border-radius: 22px; }
        .as-qr-frame { padding: 12px; }
    }

.as-qr-device {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    padding: 12px 14px;
    border: 1px dashed rgba(255, 255, 255, .16);
    border-radius: 12px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.4;
}

.as-qr-device svg { width: 17px; height: 17px; flex: 0 0 17px; color: var(--violet); }
.as-qr-device strong { color: var(--text); font-weight: 700; }
.as-qr-device small { display: block; margin-top: 2px; color: #7f798f; font-size: 9.5px; }

.as-qr-approve-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.as-qr-approve-actions .as-qr-btn { flex: 1 1 160px; min-height: 46px; }

.as-qr-success { padding: 10px 0 4px; text-align: center; }
.as-qr-success-icon {
    display: inline-flex;
    width: 66px;
    height: 66px;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    border: 1px solid rgba(110, 231, 183, .35);
    border-radius: 50%;
    background: rgba(110, 231, 183, .12);
    color: var(--green);
    box-shadow: 0 0 32px rgba(110, 231, 183, .18);
}
.as-qr-success-icon svg { width: 30px; height: 30px; }
.as-qr-success h2 { margin: 0; font-size: 24px; font-weight: 780; letter-spacing: -.03em; }
.as-qr-success p { margin: 10px auto 0; max-width: 36ch; color: var(--muted); font-size: 12.5px; line-height: 1.5; }

.as-qr-message { padding: 12px 0 4px; text-align: center; }
.as-qr-message h2 { margin: 0; font-size: 22px; font-weight: 780; letter-spacing: -.03em; }
.as-qr-message p { margin: 10px auto 0; max-width: 36ch; color: var(--muted); font-size: 12.5px; line-height: 1.5; }
.as-qr-message .as-qr-btn { margin-top: 20px; }

.as-qr-brand-name { max-width: 70%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.as-qr-form { margin: 0; }

.as-qr-account-note { margin: 10px 0 0; color: #8d87a0; font-size: 10.5px; line-height: 1.45; }

.as-qr-phone-note { margin-top: 14px; }

@media (max-width: 420px) {
    .as-qr-approve-actions .as-qr-btn { flex-basis: 100%; }
}

.as-qr-success .as-qr-btn { margin-top: 22px; }
.as-qr-message .as-qr-btn { margin-top: 22px; }

[hidden] { display: none !important; }
