/*
 * Safe effects for CMS rich text. Authors use semantic HTML only; rules are
 * scoped to known rich-text containers so existing site chrome is unaffected.
 */
:is(.detail-content, .dynamic-content-page__body) details {
    margin-bottom: 10px;
    overflow: hidden;
    border: 1px solid #e8e8e8;
    border-radius: 14px;
    background: #fff;
}

:is(.detail-content, .dynamic-content-page__body) details > summary {
    position: relative;
    display: block;
    padding: 14px 44px 14px 16px;
    color: #111;
    font-weight: 700;
    line-height: 1.5;
    text-align: left;
    cursor: pointer;
    list-style: none;
}

:is(.detail-content, .dynamic-content-page__body) details > summary::-webkit-details-marker {
    display: none;
}

:is(.detail-content, .dynamic-content-page__body) details > summary::after {
    position: absolute;
    top: 50%;
    right: 16px;
    color: #666;
    font-size: 14px;
    line-height: 1;
    content: "\25BC";
    transform: translateY(-50%);
    transition: transform 0.25s ease;
}

:is(.detail-content, .dynamic-content-page__body) details[open] > summary::after {
    transform: translateY(-50%) rotate(180deg);
}

/* Hide arrows present in older configured content; the shared arrow replaces them. */
:is(.detail-content, .dynamic-content-page__body) details > summary > .epcube-faq-arrow {
    display: none !important;
}

/* Supported browsers animate the native details content; others still expand normally. */
:is(.detail-content, .dynamic-content-page__body) details::details-content {
    block-size: 0;
    opacity: 0;
    overflow: hidden;
    transition: block-size 0.3s ease, opacity 0.25s ease, content-visibility 0.3s allow-discrete;
}

:is(.detail-content, .dynamic-content-page__body) details[open]::details-content {
    block-size: auto;
    opacity: 1;
}

@media (max-width: 768px) {
    :is(.detail-content, .dynamic-content-page__body) details > summary {
        padding: 12px 40px 12px 14px;
    }

    :is(.detail-content, .dynamic-content-page__body) details > summary::after {
        right: 14px;
    }
}
