/* 배경음악 오디오 요소 */
#ssanggyesa-bgm {
    display: none;
}

/* 배경음악 제어 버튼 */
.ssanggyesa-bgm-toggle {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(254, 254, 254, 0.8);
    color: #a7a09a;
    line-height: 0;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.18);
    transition:
        bottom 0.2s ease,
        background-color 0.2s ease,
        transform 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.ssanggyesa-bgm-toggle[hidden] {
    display: none;
}

.ssanggyesa-bgm-toggle:hover {
    background: rgba(254, 254, 254, 0.92);
    transform: translateY(-2px);
}

.ssanggyesa-bgm-toggle:focus {
    outline: none;
}

.ssanggyesa-bgm-toggle:focus-visible {
    outline: 2px solid #593e34;
    outline-offset: 3px;
}

.ssanggyesa-bgm-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.ssanggyesa-bgm-icon svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.ssanggyesa-bgm-icon-off {
    display: none;
}

.ssanggyesa-bgm-toggle[aria-pressed="true"] .ssanggyesa-bgm-icon-on {
    display: none;
}

.ssanggyesa-bgm-toggle[aria-pressed="true"] .ssanggyesa-bgm-icon-off {
    display: flex;
}

@media screen and (max-width: 768px) {
    .ssanggyesa-bgm-toggle {
        right: 26px;
        bottom: 20px;
        width: 32px;
        height: 32px;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
    }

    /*
     * 맨 위로 버튼이 표시될 때만
     * 음악 버튼을 그 위로 이동
     */
    .ssanggyesa-bgm-toggle.with-go-to-top {
        bottom: 70px;
    }

    .ssanggyesa-bgm-icon {
        width: 18px;
        height: 18px;
    }
}