:root {
    --mt-navy: #241016;
    --mt-navy-2: #3a141d;
    --mt-gold: #e32639;
    --mt-gold-soft: #ffb8c0;
    --mt-white: #ffffff;
    --mt-duration: 6500ms;
}

* { box-sizing: border-box; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.mt-services-slider {
    width: min(100%, 1600px);
    margin-inline: auto;
    color: var(--mt-white);
    font-family: 'DM Sans', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.mt-slider__viewport {
    position: relative;
    min-height: clamp(392px, 50.4vh, 574px);
    overflow: hidden;
    isolation: isolate;
    background: var(--mt-navy);
    border-radius: clamp(0px, 2vw, 28px);
    box-shadow: 0 30px 80px rgba(1, 18, 41, .26);
}

.mt-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: end;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .7s ease, visibility .7s ease;
}

.mt-slide.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    z-index: 2;
}

.mt-slide__image,
.mt-slide__shade,
.mt-slide__accent {
    position: absolute;
    inset: 0;
}

.mt-slide__image {
    z-index: -3;
    background-image: var(--slide-image);
    background-position: center;
    background-size: cover;
    transform: scale(1.06);
    filter: saturate(.92) contrast(1.04);
    will-change: transform, clip-path;
}

.mt-slide__shade {
    z-index: -2;
    background:
        linear-gradient(90deg, rgba(36, 16, 22, .74) 0%, rgba(36, 16, 22, .5) 34%, rgba(36, 16, 22, .1) 62%, transparent 82%),
        linear-gradient(0deg, rgba(36, 16, 22, .48) 0%, transparent 46%);
}

.mt-slide__accent {
    z-index: -1;
    background: linear-gradient(115deg, transparent 45%, rgba(227, 38, 57, .18) 68%, transparent 87%);
    transform: translateX(-35%);
    opacity: 0;
}

.mt-slide.is-active .mt-slide__accent {
    animation: mtSweep 1.5s .1s ease-out forwards;
}

.mt-slide__content {
    width: min(760px, calc(100% - 11rem));
    padding: clamp(1.5rem, 3.4vw, 3.2rem);
    padding-right: 0;
}

.mt-slide__icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    margin-bottom: .9rem;
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 14px;
    color: var(--mt-gold);
    background: rgba(255, 255, 255, .09);
    backdrop-filter: blur(12px);
    transform: translateY(22px) rotate(-4deg);
    opacity: 0;
}

.mt-slide__icon svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.mt-slide__kicker {
    margin: 0 0 .5rem;
    color: var(--mt-gold-soft);
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .18em;
    text-transform: uppercase;
    transform: translateY(22px);
    opacity: 0;
}

.mt-slide h2 {
    max-width: 820px;
    margin: 0;
    font-size: clamp(1.8rem, 3.6vw, 3.8rem);
    line-height: 1;
    letter-spacing: -.05em;
    text-wrap: balance;
    transform: translateY(30px);
    opacity: 0;
    color: #e9e6e7;
    text-shadow:
        -.6px -.6px 0 rgba(227, 38, 57, .6),
        .6px -.6px 0 rgba(36, 16, 22, .7),
        -.6px .6px 0 rgba(36, 16, 22, .7),
        .6px .6px 0 rgba(227, 38, 57, .6),
        0 8px 26px rgba(10, 4, 6, .4);
}

.mt-slide__copy {
    max-width: 560px;
    margin: 1rem 0 1.4rem;
    color: rgba(255, 255, 255, .78);
    font-size: clamp(.92rem, 1.3vw, 1.08rem);
    line-height: 1.5;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transform: translateY(26px);
    opacity: 0;
}

.mt-slide__cta {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    min-height: 44px;
    padding: .65rem 1.1rem .65rem 1.3rem;
    border-radius: 999px;
    color: #fff;
    background: var(--mt-gold);
    font-weight: 850;
    text-decoration: none;
    box-shadow: 0 14px 35px rgba(227, 38, 57, .3);
    transform: translateY(26px);
    opacity: 0;
    transition: transform .25s ease, background .25s ease, box-shadow .25s ease;
}

.mt-slide__cta:hover {
    transform: translateY(-2px);
    background: #b8141f;
    box-shadow: 0 17px 45px rgba(227, 38, 57, .35);
}

.mt-slide__cta svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.mt-slide.is-active .mt-slide__icon,
.mt-slide.is-active .mt-slide__kicker,
.mt-slide.is-active h2,
.mt-slide.is-active .mt-slide__copy,
.mt-slide.is-active .mt-slide__cta {
    animation: mtContentIn .8s cubic-bezier(.2, .72, .24, 1) forwards;
}

.mt-slide.is-active .mt-slide__kicker { animation-delay: .08s; }
.mt-slide.is-active h2 { animation-delay: .15s; }
.mt-slide.is-active .mt-slide__copy { animation-delay: .23s; }
.mt-slide.is-active .mt-slide__cta { animation-delay: .31s; }

.mt-slide[data-effect="zoom"].is-active .mt-slide__image {
    animation: mtZoom var(--mt-duration) ease-out both;
}

.mt-slide[data-effect="pan"].is-active .mt-slide__image {
    animation: mtPan var(--mt-duration) linear both;
}

.mt-slide[data-effect="wipe"] .mt-slide__image {
    clip-path: inset(0 100% 0 0);
}

.mt-slide[data-effect="wipe"].is-active .mt-slide__image {
    animation: mtWipe 1.15s cubic-bezier(.18, .85, .18, 1) forwards, mtZoom var(--mt-duration) ease-out both;
}

.mt-slide[data-effect="rise"] .mt-slide__image {
    clip-path: inset(100% 0 0 0);
}

.mt-slide[data-effect="rise"].is-active .mt-slide__image {
    animation: mtRise 1.1s cubic-bezier(.18, .85, .18, 1) forwards, mtZoom var(--mt-duration) ease-out both;
}

.mt-slide[data-effect="ripple"] .mt-slide__image {
    clip-path: circle(20% at 73% 56%);
}

.mt-slide[data-effect="ripple"].is-active .mt-slide__image {
    animation: mtRipple 1.15s cubic-bezier(.16, .82, .17, 1) forwards, mtZoom var(--mt-duration) ease-out both;
}

.mt-slider__arrow,
.mt-slider__toggle {
    position: absolute;
    z-index: 6;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 50%;
    color: #fff;
    background: rgba(6, 27, 53, .48);
    backdrop-filter: blur(14px);
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.mt-slider__arrow:hover,
.mt-slider__toggle:hover {
    background: rgba(227, 38, 57, .92);
    color: #fff;
    transform: scale(1.05);
}

.mt-slider__arrow { top: 50%; transform: translateY(-50%); }
.mt-slider__arrow:hover { transform: translateY(-50%) scale(1.05); }
.mt-slider__arrow--prev { left: 1.4rem; }
.mt-slider__arrow--next { right: 1.4rem; }
.mt-slider__toggle { top: 1.4rem; right: 1.4rem; }

.mt-slider__arrow svg,
.mt-slider__toggle svg {
    width: 23px;
    height: 23px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.mt-slider__toggle .icon-play { display: none; }
.mt-slider__toggle.is-paused .icon-pause { display: none; }
.mt-slider__toggle.is-paused .icon-play { display: block; }

.mt-slider__progress {
    position: absolute;
    z-index: 7;
    inset: auto 0 0;
    height: 4px;
    background: rgba(255, 255, 255, .13);
}

.mt-slider__progress span {
    display: block;
    width: 100%;
    height: 100%;
    background: var(--mt-gold);
    transform-origin: left center;
    transform: scaleX(0);
}

.mt-services-slider:not(.is-paused) .mt-slider__progress span {
    animation: mtProgress var(--mt-duration) linear forwards;
}

@keyframes mtContentIn {
    to { transform: translateY(0) rotate(0); opacity: 1; }
}

@keyframes mtZoom {
    from { transform: scale(1.08); }
    to { transform: scale(1.01); }
}

@keyframes mtPan {
    from { transform: scale(1.1) translateX(-1.8%); }
    to { transform: scale(1.04) translateX(1.8%); }
}

@keyframes mtWipe { to { clip-path: inset(0); } }
@keyframes mtRise { to { clip-path: inset(0); } }
@keyframes mtRipple { to { clip-path: circle(90% at 73% 56%); } }
@keyframes mtSweep { 0% { transform: translateX(-35%); opacity: 0; } 35% { opacity: 1; } 100% { transform: translateX(35%); opacity: 0; } }
@keyframes mtProgress { to { transform: scaleX(1); } }

@media (max-width: 900px) {
    .mt-slider__viewport { min-height: 476px; border-radius: 20px; }
    .mt-slide { align-items: end; }
    .mt-slide__shade {
        background:
            linear-gradient(0deg, rgba(36, 16, 22, .8) 0%, rgba(36, 16, 22, .5) 46%, transparent 78%),
            linear-gradient(90deg, rgba(36, 16, 22, .12), transparent 60%);
    }
    .mt-slide__content {
        width: 100%;
        padding: 3rem 2rem 4.5rem;
    }
    .mt-slide h2 { font-size: clamp(1.96rem, 8.4vw, 3.64rem); }
    .mt-slider__arrow { top: auto; bottom: 1.1rem; }
    .mt-slider__arrow--prev { left: 1.2rem; }
    .mt-slider__arrow--next { right: 1.2rem; }
}

@media (max-width: 560px) {
    .mt-slider__viewport { min-height: 455px; border-radius: 0; }
    .mt-slide__content { padding-inline: 1.35rem; }
    .mt-slide__copy { font-size: 1rem; }
    .mt-slide__cta { width: 100%; justify-content: center; }
    .mt-slider__toggle { top: .9rem; right: .9rem; }
}

@media (prefers-reduced-motion: reduce) {
    .mt-slide,
    .mt-slide__image,
    .mt-slide__accent,
    .mt-slide__icon,
    .mt-slide__kicker,
    .mt-slide h2,
    .mt-slide__copy,
    .mt-slide__cta,
    .mt-slider__progress span {
        animation: none !important;
        transition-duration: .01ms !important;
    }
    .mt-slide.is-active .mt-slide__image { clip-path: inset(0); transform: none; }
    .mt-slide.is-active .mt-slide__icon,
    .mt-slide.is-active .mt-slide__kicker,
    .mt-slide.is-active h2,
    .mt-slide.is-active .mt-slide__copy,
    .mt-slide.is-active .mt-slide__cta { opacity: 1; transform: none; }
}
