.fab-wrapper {
    position: relative;
    width: 100%;
    display: flex;
    overflow: hidden;
    box-sizing: border-box;
}

.fab-wrapper * {
    box-sizing: border-box;
}

.fab-dir-vertical {
    flex-direction: column;
}

.fab-dir-horizontal {
    flex-direction: row;
    height: 520px;
}

.fab-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.5s ease;
    min-width: 0;
    isolation: isolate;
}

.fab-dir-vertical .fab-item {
    width: 100%;
    height: 80px;
}

.fab-dir-vertical .fab-item.active {
    height: 450px;
}

.fab-dir-horizontal .fab-item {
    flex: 1;
    height: 100%;
}

.fab-dir-horizontal .fab-item.active {
    flex: 4;
}

.fab-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    transform: scale(1);
    transition: transform 0.6s ease;
    z-index: 1;
}

.fab-item.active .fab-bg {
    transform: scale(1.06);
}

.fab-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.35);
    transition: background 0.35s ease;
    z-index: 2;
}

.fab-item.active .fab-overlay {
    background: rgba(0,0,0,0.2);
}

.fab-content-inner {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 40px;
    z-index: 3;
}

.fab-content-details {
    position: relative;
    width: 900px;
    max-width: 100%;
    z-index: 4;
    text-align: left;
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.fab-item.active .fab-content-details {
    opacity: 1;
    transform: translateY(0);
}

.fab-title {
    margin: 0 0 20px 0;
    padding: 0;
    color: #ffffff;
    font-size: 54px;
    line-height: 1.1;
    font-weight: 700;
}

.fab-description {
    margin: 0 0 30px 0;
    padding: 0;
    color: #ffffff;
    font-size: 22px;
    line-height: 1.5;
    font-weight: 400;
}

.fab-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #111111;
    background-color: #ffffff;
    padding: 18px 36px;
    font-size: 16px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: 1.5px;
    transition: all 0.3s ease;
    border: none;
}

.fab-button:hover {
    color: #ffffff;
    background-color: #111111;
    text-decoration: none;
}

.fab-dir-vertical .fab-item:not(.active) .fab-content-inner {
    height: 100%;
}

.fab-dir-vertical .fab-item:not(.active) .fab-content-details {
    opacity: 1;
    transform: none;
}

.fab-dir-vertical .fab-item:not(.active) .fab-title {
    margin-bottom: 0;
    font-size: 38px;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fab-dir-vertical .fab-item:not(.active) .fab-description,
.fab-dir-vertical .fab-item:not(.active) .fab-button {
    display: none;
}

.fab-dir-horizontal .fab-item:not(.active) .fab-content-details {
    opacity: 1;
    transform: none;
}

.fab-dir-horizontal .fab-item:not(.active) .fab-title {
    margin-bottom: 0;
    font-size: 28px;
    line-height: 1.15;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    white-space: nowrap;
}

.fab-dir-horizontal .fab-item:not(.active) .fab-description,
.fab-dir-horizontal .fab-item:not(.active) .fab-button {
    display: none;
}

.fab-dir-horizontal .fab-item:not(.active) .fab-content-inner {
    align-items: center;
    justify-content: center;
    padding: 20px;
}

@media (max-width: 1024px) {
    .fab-title {
        font-size: 42px;
    }

    .fab-description {
        font-size: 18px;
    }

    .fab-content-inner {
        padding: 30px;
    }

    .fab-dir-vertical .fab-item:not(.active) .fab-title {
        font-size: 30px;
    }
}

@media (max-width: 767px) {
    .fab-wrapper.fab-mobile-stacked {
        flex-direction: column;
        height: auto;
        overflow: visible;
    }

    .fab-wrapper.fab-mobile-stacked .fab-item {
        width: 100%;
        height: auto !important;
        min-height: 360px;
        flex: none;
    }

    .fab-wrapper.fab-mobile-stacked .fab-item .fab-content-inner {
        height: auto;
        min-height: 360px;
        padding: 28px 22px;
        align-items: flex-start;
        justify-content: center;
    }

    .fab-wrapper.fab-mobile-stacked .fab-item .fab-content-details {
        opacity: 1;
        transform: none;
        width: 100%;
        max-width: 100%;
    }

    .fab-wrapper.fab-mobile-stacked .fab-item .fab-title {
        writing-mode: initial;
        transform: none;
        white-space: normal;
        overflow: visible;
        text-overflow: initial;
        margin-bottom: 16px;
        font-size: 34px;
        line-height: 1.15;
    }

    .fab-wrapper.fab-mobile-stacked .fab-item .fab-description,
    .fab-wrapper.fab-mobile-stacked .fab-item .fab-button {
        display: inline-flex;
    }

    .fab-wrapper.fab-mobile-stacked .fab-item .fab-description {
        display: block;
        font-size: 16px;
        line-height: 1.5;
        margin-bottom: 24px;
    }

    .fab-wrapper.fab-mobile-stacked .fab-button {
        padding: 15px 28px;
        font-size: 14px;
    }

    .fab-wrapper.fab-mobile-keep.fab-dir-horizontal {
        height: 420px;
    }

    .fab-wrapper.fab-mobile-keep.fab-dir-horizontal .fab-title {
        font-size: 24px;
    }

    .fab-wrapper.fab-mobile-keep.fab-dir-vertical .fab-item.active {
        height: 420px;
    }
}