.app-user-btn {
    position: absolute;
    top: 10px;
    right: 14px;
    background: rgba(255, 255, 255, 0.15);
    color: rgb(238, 178, 17);
    border: 1px solid rgba(238, 178, 17, 0.55);
    border-radius: 999px;
    width: 34px;
    height: 34px;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    outline: none;
    box-shadow: none;
    -webkit-tap-highlight-color: transparent;
}

.app-user-btn:focus,
.app-user-btn:focus-visible,
.app-user-btn:active {
    outline: none;
    box-shadow: none;
}

.app-user-btn.modal-open {
    background: rgb(238, 178, 17);
    color: rgb(70, 22, 107);
    border-color: rgb(238, 178, 17);
}

.app-user-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    z-index: 10000;
}

.app-user-modal.open {
    display: flex;
}

.app-user-modal-card {
    display: inline-block;
    min-width: 260px;
    max-width: min(92vw, 400px);
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border: 1px solid #ddd;
    padding: 16px;
    box-sizing: border-box;
}

.app-user-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.app-user-modal-title {
    font-size: 18px;
    font-weight: 700;
    color: #46166b;
}

.app-user-modal-close-x {
    border: none;
    background: transparent;
    color: #666;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
}

.app-user-token-modal-header-actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.app-user-modal-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 6px 0;
    font-size: 14px;
}

.app-user-modal-row .label {
    min-width: 110px;
    color: #666;
    font-weight: 600;
}

.app-user-token-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
    text-align: left;
}

.app-user-modal-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 16px;
}

.app-user-token-exp-value {
    color: #2d2d2d;
    white-space: nowrap;
}

.app-user-token-claims-link {
    color: #1a5fb4;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    line-height: 1;
    border-radius: 3px;
    -webkit-tap-highlight-color: transparent;
}

.app-user-token-claims-link:hover {
    color: #0f3f85;
    background: #eef1f7;
}

.app-user-token-claims-link:focus,
.app-user-token-claims-link:focus-visible,
.app-user-token-claims-link:active {
    outline: none;
    box-shadow: none;
}

.app-user-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 14px;
}

.app-user-btn-secondary,
.app-user-btn-danger {
    border-radius: 4px;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 14px;
}

.app-user-btn-secondary {
    background: #eee;
    color: #333;
}

.app-user-modal-copy-token {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    color: #5f6a7d;
    cursor: pointer;
    border-radius: 3px;
    transition: color 120ms ease, background-color 120ms ease;
}

.app-user-modal-copy-token:hover,
.app-user-modal-copy-token:focus {
    color: #2d3b55;
    background: #eef1f7;
    outline: none;
}

.app-user-modal-copy-token.copied {
    color: #2e7d32;
    background: #e9f7ea;
}

.app-user-modal-refresh-token {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    color: #5f6a7d;
    cursor: pointer;
    border-radius: 3px;
    transition: color 120ms ease, background-color 120ms ease;
}

.app-user-modal-refresh-token:hover,
.app-user-modal-refresh-token:focus {
    color: #2d3b55;
    background: #eef1f7;
    outline: none;
}

.app-user-modal-refresh-token.copied {
    color: #2e7d32;
    background: #e9f7ea;
}

.app-user-modal-refresh-token.error {
    color: #a61f1f;
    background: #fbe9e7;
}

.app-user-modal-logout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    color: #c62828;
    cursor: pointer;
    border-radius: 3px;
    margin-left: 2px;
    transition: color 120ms ease, background-color 120ms ease;
    background: none;
    border: none;
}
.app-user-modal-logout:hover,
.app-user-modal-logout:focus {
    color: #a61f1f;
    background: #fbe9e7;
    outline: none;
}

.app-user-token-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    z-index: 10001;
}

.app-user-token-modal.open {
    display: flex;
}

.app-user-token-modal-card {
    width: min(92vw, 720px);
    max-height: 82vh;
    overflow: hidden;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border: 1px solid #ddd;
    padding: 16px;
}

.app-user-token-modal-copy {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    color: #5f6a7d;
    cursor: pointer;
    border-radius: 3px;
    transition: color 120ms ease, background-color 120ms ease;
}

.app-user-token-modal-copy:hover,
.app-user-token-modal-copy:focus {
    color: #2d3b55;
    background: #eef1f7;
    outline: none;
}

.app-user-token-modal-copy.copied {
    color: #2e7d32;
    background: #e9f7ea;
}

.app-user-token-json {
    margin: 8px 0 0;
    padding: 12px;
    max-height: 56vh;
    overflow: auto;
    background: #f6f7f9;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 12px;
    line-height: 1.45;
    font-family: 'SFMono-Regular', Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace;
    word-break: break-word;
}

/* JSON syntax highlight classes */

