/* =============================================
   Wallex Read More / Read Less
   ============================================= */

/* Outer container — position context for the footer overlay */
.wallex-readmore-outer {
    position: relative;
}

/* The masked content wrapper */
.wallex-readmore-wrap {
    position: relative;
    overflow: hidden;
    height: 80px;
    mask-image: linear-gradient(black 50%, transparent);
    -webkit-mask-image: linear-gradient(black 50%, transparent);
    transition: height 0.5s ease;
    top: -20px;


}

/* When open: expand to full height and remove mask */
.wallex-readmore-outer.is-open .wallex-readmore-wrap {
    height: auto;
    mask-image: none;
    -webkit-mask-image: none;
}

/* Inner content — flows naturally */
.wallex-readmore-inner {
    /* intentionally unstyled */
}

/* Footer — overlays the bottom of the wrap using negative margin */
.wallex-readmore-footer {
    display: flex;
    justify-content: center;
    margin-top: -20px;
    /* pulls the footer up over the bottom of the wrap */
    position: relative;
    z-index: 1;
    padding: 0 0 8px;
}

/* When open: footer flows below content normally */
.wallex-readmore-outer.is-open .wallex-readmore-footer {
    margin-top: 0;
    padding: 12px 0 8px;
}

/* Button */
.wallex-readmore-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    padding: 8px 24px;
    font-size: 0.9em;
    font-weight: 600;
    cursor: pointer;
    color: var(--color-primaryBrandText);
    opacity: 1;
    transition: opacity 0.2s ease, transform 0.2s ease;
    line-height: 1.4;
    border: none;
}

.wallex-readmore-btn:hover {
    background-color: rgb(0, 122, 255, 0.05);
    transform: translateY(-1px);
}

.wallex-readmore-btn:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

/* SVG chevron */
.wallex-readmore-icon {
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.wallex-readmore-outer.is-open .wallex-readmore-icon {
    transform: rotate(180deg);
}