/* ============================================
   Boxkun Theme Patches
   Fixes for Spoiler Block and other overrides
   ============================================ */

/* Spoiler Block Fix */
/* Spoiler Block Fix */
.boxkun-spoiler-block {
    position: relative;
    cursor: pointer;
    overflow: hidden;
    /* Remove boxy background */
    filter: none !important;
    min-height: 1.5em;
}

/* Blur the content */
.boxkun-spoiler-block>* {
    filter: blur(5px);
    transition: filter 0.5s ease, opacity 0.5s ease;
    user-select: none;
    -webkit-user-select: none;
    display: block;
    opacity: 0.6;
    /* Soften edges */
    mask-image: linear-gradient(to bottom, black 10%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.8) 50%, rgba(0, 0, 0, 0.1) 100%);
}

/* Overlay Text */
.boxkun-spoiler-block::after {
    content: '⚠️ \c2a4\d3ec\c77c\b7ec (\d074\b9ad\d558\c5ec  \bcf4\ae30)';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #0f172a;
    /* Slate-900 */
    color: white;
    padding: 10px 20px;
    border-radius: 9999px;
    font-size: 14px;
    font-weight: 600;
    z-index: 10;
    white-space: nowrap;
    opacity: 1;
    transition: opacity 0.3s ease;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    /* Soft shadow */
    pointer-events: none;
}

/* Revealed State */
.boxkun-spoiler-block.boxkun-spoiler-revealed>* {
    filter: none !important;
    user-select: text !important;
    -webkit-user-select: text !important;
    opacity: 1;
    mask-image: none;
    -webkit-mask-image: none;
}

.boxkun-spoiler-block.boxkun-spoiler-revealed {
    cursor: auto !important;
}

.boxkun-spoiler-block.boxkun-spoiler-revealed::after {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    /* Ensure it's gone */
}