/**
 * MBA Gallery Pro — Modal refinements (v1.0.6)
 *
 *  #3  Case navigator: replace the numeric "3 / 4" with labels so it reads
 *      ‹ Previous Case / Next Case ›.
 *  #4  Details panel: show Description and Details stacked (both open) with
 *      headings and a divider, instead of click-between tabs.
 *  #8  Image-pair navigator: move it out of the bottom of the black column so
 *      it sits directly beneath the images.
 *
 * All selectors target the free plugin's existing markup; no free-plugin files
 * are modified.
 *
 * @package MBA_Gallery_Pro
 */

/* ════════════════════════════════════════════════════════════════════
   #3  CASE NAVIGATOR — "‹ Previous Case / Next Case ›"
   ════════════════════════════════════════════════════════════════════ */

.medbeafgallery-modal-nav-container .medbeafgallery-modal-prev,
.medbeafgallery-modal-nav-container .medbeafgallery-modal-next {
    width: auto;
    min-width: 0;
    padding: 6px 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 8px;
}

.medbeafgallery-modal-prev::after {
    content: "Previous Case";
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    line-height: 1;
}

.medbeafgallery-modal-next::before {
    content: "Next Case";
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    line-height: 1;
}

/* Hide the numeric counter but keep the "/" separator between the labels. */
#medbeafgallery-current-item,
#medbeafgallery-total-items {
    display: none;
}

.medbeafgallery-modal-counter .medbeafgallery-counter-separator {
    margin: 0 6px;
    font-weight: 600;
    color: inherit;
}

/* Narrow screens: collapse back to just the chevrons. */
@media (max-width: 480px) {
    .medbeafgallery-modal-prev::after,
    .medbeafgallery-modal-next::before {
        content: "";
    }
    .medbeafgallery-modal-counter .medbeafgallery-counter-separator {
        display: none;
    }
    .medbeafgallery-modal-nav-container .medbeafgallery-modal-prev,
    .medbeafgallery-modal-nav-container .medbeafgallery-modal-next {
        padding: 6px 10px;
    }
}

/* ════════════════════════════════════════════════════════════════════
   #4  DETAILS PANEL — stack Description above Details, both visible
   ════════════════════════════════════════════════════════════════════ */

.medbeafgallery-case-details .medbeafgallery-case-tabs {
    display: none;                    /* remove the clickable tab bar */
}

.medbeafgallery-case-details .medbeafgallery-tab-content {
    display: block !important;        /* show BOTH blocks (free CSS hides one) */
}

.medbeafgallery-case-details .medbeafgallery-tab-content::before {
    display: block;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: var(--pro-text, #1a1a2e);
    margin: 0 0 10px;
}

.medbeafgallery-case-details .medbeafgallery-tab-content[data-tab="description"]::before {
    content: "Description";
}

.medbeafgallery-case-details .medbeafgallery-tab-content[data-tab="details"]::before {
    content: "Details";
}

.medbeafgallery-case-details .medbeafgallery-tab-content[data-tab="details"] {
    margin-top: 20px;
    padding-top: 20px;
    /* v1.0.7: explicit brand-blue divider, high specificity so no theme/plugin
       rule (or an overridden --pro-border var) can hide it. */
    border-top: 1px solid #0c71c3 !important;
}

/* ════════════════════════════════════════════════════════════════════
   #8  IMAGE-PAIR NAV — directly beneath the images (not the column bottom)
   ════════════════════════════════════════════════════════════════════ */

/* Stack the image column top-down: images, then the pair-nav right under them,
   then the remaining black space. */
.medbeafgallery-comparison-container {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.medbeafgallery-comparison-container .medbeafgallery-image-sets-container {
    order: 1;
    height: auto;
    flex: 0 0 auto;
    width: 100%;
}

/* Take the pair-nav out of its bottom-pinned absolute position and place it
   in normal flow immediately below the images. */
.medbeafgallery-comparison-container .medbeafgallery-image-pairs-nav {
    order: 2;
    position: static;
    left: auto;
    bottom: auto;
    transform: none;
    margin: 12px auto 0;
}

/* Keep the hidden Before/After labels out of the flow. */
.medbeafgallery-comparison-container .medbeafgallery-labels {
    order: 3;
}
