.mfps-slider {
    --mfps-accent: #d71920;
    --mfps-overlay-top: rgba(0,0,0,0.02);
    --mfps-overlay-middle: rgba(0,0,0,0.42);
    --mfps-overlay-bottom: rgba(0,0,0,0.88);
    --mfps-image-y: 50%;
    width: 100%;
    max-width: 100%;
    background: #fff;
    box-sizing: border-box;
    overflow: hidden;
}

.mfps-slider * {
    box-sizing: border-box;
}

.mfps-stage {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    background: #111;
}

.mfps-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility .35s ease;
    z-index: 1;
}

.mfps-slide.is-active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

.mfps-image-link {
    display: block;
    width: 100%;
    height: 100%;
    position: relative;
    color: #fff;
    text-decoration: none !important;
    overflow: hidden;
}

.mfps-image-link img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: 50% var(--mfps-image-y);
    transform: scale(1.001);
    transition: transform 5s ease;
}

.mfps-slide.is-active .mfps-image-link img {
    transform: scale(1.035);
}

.mfps-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        var(--mfps-overlay-top) 35%,
        var(--mfps-overlay-middle) 67%,
        var(--mfps-overlay-bottom) 100%
    );
    pointer-events: none;
}

.mfps-copy {
    position: absolute;
    z-index: 2;
    left: 22px;
    right: 22px;
    bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 7px;
    max-width: 92%;
}

.mfps-category {
    display: inline-block;
    align-self: flex-start;
    width: auto;
    padding: 5px 8px;
    background: var(--mfps-accent);
    color: #fff;
    font-size: 11px;
    line-height: 1;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.mfps-title {
    display: block;
    color: #fff;
    font-size: clamp(22px, 3vw, 38px);
    line-height: 1.08;
    font-weight: 800;
    text-shadow: 0 2px 12px rgba(0,0,0,.45);
}

.mfps-excerpt {
    display: block;
    color: #efefef;
    font-size: 14px;
    line-height: 1.45;
    max-width: 760px;
    text-shadow: 0 2px 10px rgba(0,0,0,.42);
}

.mfps-arrow {
    position: absolute;
    z-index: 5;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    padding: 0;
    border: 0 solid transparent;
    border-radius: 50%;
    background: rgba(0,0,0,.52);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    line-height: 1;
    opacity: 0;
    transition: opacity .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}

.mfps-arrow-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58%;
    height: 58%;
    line-height: 0;
}

.mfps-arrow-icon svg {
    display: block;
    width: 100%;
    height: 100%;
}

.mfps-stage:hover .mfps-arrow,
.mfps-arrow:focus-visible {
    opacity: 1;
}

.mfps-arrow:hover {
    background: var(--mfps-accent);
}

.mfps-prev { left: 14px; }
.mfps-next { right: 14px; }

.mfps-thumbs {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 7px;
    padding: 8px 0 0;
    background: #fff;
}

.mfps-thumb {
    position: relative;
    min-width: 0;
    height: 92px;
    padding: 0;
    margin: 0;
    border: 0;
    border-top: 4px solid transparent;
    background: #e7e7e7;
    cursor: pointer;
    overflow: hidden;
    transition: border-color .2s ease, opacity .2s ease, transform .2s ease;
    opacity: .82;
}

.mfps-thumb:hover {
    opacity: 1;
}

.mfps-thumb.is-active {
    border-top-color: var(--mfps-accent);
    opacity: 1;
}

.mfps-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mfps-thumb:focus-visible,
.mfps-arrow:focus-visible {
    outline: 3px solid rgba(215,25,32,.28);
    outline-offset: 2px;
}

.mfps-empty {
    padding: 18px;
    border: 1px dashed #bbb;
    background: #fafafa;
    color: #444;
    font-size: 14px;
}

@media (max-width: 900px) {
    .mfps-stage {
        height: 420px;
    }

    .mfps-thumbs {
        grid-template-columns: repeat(4, minmax(120px, 1fr));
        overflow-x: auto;
        scrollbar-width: thin;
    }

    .mfps-thumb {
        min-width: 120px;
        height: 82px;
    }
}

@media (max-width: 640px) {
    .mfps-stage {
        height: 330px;
    }

    .mfps-copy {
        left: 15px;
        right: 15px;
        bottom: 15px;
    }

    .mfps-title {
        font-size: 23px;
    }

    .mfps-excerpt {
        display: none;
    }

    .mfps-category {
        font-size: 10px;
    }

    .mfps-arrow {
        width: 36px;
        height: 36px;
        opacity: .8;
    }

    .mfps-thumbs {
        grid-template-columns: repeat(4, minmax(95px, 1fr));
        gap: 5px;
    }

    .mfps-thumb {
        min-width: 95px;
        height: 68px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mfps-slide,
    .mfps-image-link img,
    .mfps-arrow,
    .mfps-thumb {
        transition: none !important;
    }
}


/* v1.2.2 — thumbnail strip always stays on one horizontal line */
.mfps-slider .mfps-thumbs {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: stretch !important;
    gap: 7px;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.mfps-slider .mfps-thumb {
    flex: 0 0 calc((100% - 35px) / 6) !important;
    min-width: 82px !important;
    max-width: none !important;
    flex-shrink: 0 !important;
}

@media (max-width: 900px) {
    .mfps-slider .mfps-thumbs {
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
    }

    .mfps-slider .mfps-thumb {
        flex: 0 0 120px !important;
        min-width: 120px !important;
    }
}

@media (max-width: 640px) {
    .mfps-slider .mfps-thumbs {
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        gap: 5px;
    }

    .mfps-slider .mfps-thumb {
        flex: 0 0 95px !important;
        min-width: 95px !important;
    }
}
