#credits-dialog {
    position: fixed;
    inset: 0;
    margin: auto;
    box-sizing: border-box;
    width: min(36rem, calc(100% - 1.5rem));
    max-height: min(42rem, calc(100dvh - 1.5rem));
    padding: clamp(.85rem, 3vw, 1.5rem);
    border: 2px solid #d6a33c;
    outline: 1px solid #9b7739;
    outline-offset: -.45rem;
    background: linear-gradient(180deg, #233660aa, transparent 30%), #172447 url('/static/assets/theatre/paper-grain.webp');
    color: #f2e7cc;
    box-shadow: .35rem .5rem 0 #080d1c, 0 1rem 4rem #080d1ccc;
    text-align: center;
    font-family: var(--font-body, 'Crimson Pro', Georgia, serif);
}
#credits-dialog[open] { display: flex; flex-direction: column; }
#credits-dialog::backdrop { background: rgba(4, 7, 17, .82); backdrop-filter: blur(3px); }
.credits-heading { padding-bottom: .65rem; border-bottom: 1px solid #9b7739; }
.credits-heading p { margin: 0; font: 800 clamp(1.4rem, 5vw, 2.25rem)/1 var(--font-heading, Cinzel, Georgia, serif); letter-spacing: .16em; color: #f4d488; }
.credits-heading h2, .credits-scroll h3 { font: 700 clamp(.85rem, 3vw, 1.05rem)/1.25 var(--font-heading, Cinzel, Georgia, serif); color: #f4d488; }
.credits-heading h2 { margin: .35rem 0 0; }
.credits-scroll { min-height: 0; padding: .9rem .55rem; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #c09343 #172447; font-size: clamp(1rem, 3vw, 1.2rem); line-height: 1.55; }
.credits-group + .credits-group, .credits-end { margin-top: 1.3rem; }
.credits-scroll h3 { margin: 0 0 .35rem; }
.credits-scroll ul { list-style: none; padding: 0; margin: 0; }
.credits-end p { margin: .4rem 0 0; }
.credits-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .55rem; padding-top: .55rem; border-top: 1px solid #9b7739; }
.credits-actions .btn { min-height: 44px; }
#credits-dialog :focus-visible { outline: 2px solid #f4d488; outline-offset: 2px; }

.credits-setting {
    width: 100%;
    min-height: 44px;
    padding: .6rem .75rem;
    text-align: left;
    color: #f2e7cc;
    background: #223461;
    border: 1px solid #9b7739;
    font: inherit;
    cursor: pointer;
}
.credits-setting.ps-slip { width: calc(100% - 1rem); }
.credits-setting:hover { filter: brightness(1.09); }
.credits-setting:focus-visible { outline: 2px solid #d6a33c; outline-offset: 2px; }
