.wrapper {
    margin: 0 auto;
    width: 100%;
    max-width: 1642px;
}

.inner-wrapper-padding {
    padding: 0 80px;
}

.about-timeline {
    background-color: #fff;
    padding: 60px 0 50px;
}

.timeline-box h6 {
    font-size: 55px;
    line-height: 26px;
    color: #d21e1e;
    font-weight: 700;
    font-family: "Poppins", sans-serif;
    background-color: #fff;
    position: relative;
    z-index: 1;
    display: inline-block;
    width: auto;
    padding: 0 10px;
    margin-top: 0;
    transform: translate(0, -50%);
}

.timeline-box p {
    font-size: 18px;
    line-height: 27px;
    color: #000000;
    font-weight: 400;
    margin-bottom: 26px;
    font-family: "Inter", sans-serif;
}

.timeline-box p:last-of-type {
    margin-bottom: 15px;
}

.start-point h4 {
    font-size: 17px;
    line-height: 23px;
    color: #ffffff;
    font-weight: 600;
    text-transform: uppercase;
    background-color: #d21e1e;
    border-radius: 16px;
    display: block;
    width: auto;
    text-align: center;
    padding: 5px 25px;
    position: relative;
    margin-bottom: 45px;
    font-family: "Inter", sans-serif;
}

.black-dot {
    width: 21px;
    height: 21px;
    background-color: #000;
    border-radius: 50%;
    display: block;
    margin: 0 auto 62px;
    z-index: 1;
}

.start-point {
    position: relative;
    display: flex;
    justify-content: center;
    flex-direction: column;
    align-items: center;
}

.start-point:before {
    content: "";
    position: absolute;
    left: 0;
    height: 100%;
    width: 0px;
    background-color: #aaa;
    left: 50%;
    top: 0;
    transform: translate(-50%, 0%);
    -webkit-transform: translate(-50%, 0%);
    -moz-transform: translate(-50%, 0%);
    border-left: 1px solid #aaa;
}

.timeline-row .horizontal-line {
    border-top: 1px solid #aaa;
    width: calc(100% - 150px);
    margin: 0 auto;
    position: absolute;
    top: 0;
    left: 50%;
    z-index: 0;
    transform: translate(-50%, 0%);
}

.timeline-row .verticle-line {
    margin: 0;
    padding: 0;
    width: 2px;
    border-right: 1px solid #aaa;
    height: calc(100% - 150px);
    position: absolute;
    top: 0;
    right: 0;
    margin: auto 0;
    bottom: 0;
}

.timeline-row:nth-child(2n + 2) .verticle-line {
    left: 0;
    right: inherit;
}

.corner {
    position: absolute;
    border-right: 1px solid #aaa;
    width: 76px;
    height: 76px;
    right: 0;
    border-top: 1px solid #aaa;
    top: 74.9px;
    border-radius: 0 70px 0 0;
    top: 0;
}

.timeline-row:nth-child(2n + 2) .corner {
    right: inherit;
    left: 0;
    border-left: 1px solid #aaa;
    border-right: 0;
    border-radius: 70px 0 0 0;
}

.corner.bottom {
    bottom: -76px;
    top: inherit;
    border-radius: 0;
    border-top: 0;
    border-bottom: 1px solid #aaa;
    border-radius: 0 0 70px 0;
    right: 0;
    z-index: 1;
    bottom: -1px;
}

.timeline-row:nth-child(2n + 2) .corner.bottom {
    border-radius: 0 0 0 70px;
}

.timeline-row {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    padding-bottom: 0px;
    position: relative;
}

.timeline-row:nth-child(2n + 2) {
    justify-content: space-around;
    text-align: right;
    padding: 0 2%;
    flex-direction: row-reverse;
}

.timeline-box {
    max-width: 550px;
    margin-right: 25px;
    position: relative;
}

.timeline-main {
    margin-top: 75px;
}

.timeline-row:first-child {
    margin: 0 0px 0 auto;
    max-width: 50%;
    justify-content: space-between;
    padding: 0 0 0 120px;
}

.corner.bl {
    bottom: 0;
    left: 0;
    border-left: 1px solid #aaa;
    border-bottom: 1px solid #aaa;
    border-radius: 0 0 0px 100%;
    border-right: none;
    border-top: none;
    height: 76px;
    width: 76px;
}

.start-point .corner.bl {
    left: 50%;
    bottom: 0px;
    transform: translateY(100%);
    top: unset;
}

.timeline-box:before {
    content: "";
    position: absolute;
    left: 0;
    top: 27.5px;
    height: 1px;
    width: 100%;
}

.timeline-box-wrap {
    padding: 45px 0px 0;
    position: relative;
    background: #fff;
    padding: 0;
    margin-bottom: 50px;
}

.timeline-content {
    padding: 10px 10px 0;
}

.timeline-content-txt {
    padding: 10px 0 0 0;
}

.timeline-box.img-right .timeline-content,
.timeline-box.img-left .timeline-content {
    display: flex;
    align-items: flex-start;
}

.timeline-box.img-right .timeline-content img {
    margin-left: 18px;
}

.timeline-box.img-left .timeline-content img {
    margin-right: 18px;
}

.timeline-box.img-left .timeline-content {
    flex-direction: row-reverse;
}

.timeline-row:last-child .corner.bottom {
    display: none;
}

.timeline-row:nth-child(2n + 1) .timeline-box:last-child .timeline-box-wrap {
    text-align: center;
}

.start-point.end-point:before {
    display: none;
}

.start-point.end-point {
    position: absolute;
    bottom: 0;
    right: 0%;
    transform: translateX(50%);
}

.timeline-row:nth-child(2n + 2) .start-point.end-point {
    left: 0;
    transform: translateX(-50%);
    right: unset;
}

.timeline-box.img-right .timeline-content-txt {
    text-align: right;
}

.timeline-box.img-left .timeline-content-txt {
    text-align: left;
}

.timeline-box.img-left,
.timeline-box.img-right {
    text-align: center;
}

.timeline-content img {
    filter: grayscale(100%) drop-shadow(0 0 27px rgba(0, 0, 0, 0.16));
    -webkit-filter: grayscale(100%) drop-shadow(0 0 27px rgba(0, 0, 0, 0.16));
    transition: filter 0.4s ease, transform 0.3s ease;
}

.timeline-content:hover img {
    filter: grayscale(0%) drop-shadow(0 0 27px rgba(0, 0, 0, 0.16));
    -webkit-filter: grayscale(0%) drop-shadow(0 0 27px rgba(0, 0, 0, 0.16));
    animation: shake 0.5s ease;
}

@keyframes shake {
    0% {
        transform: translate(0, 0);
    }

    20% {
        transform: translate(-5px, 0);
    }

    40% {
        transform: translate(5px, 0);
    }

    60% {
        transform: translate(-5px, 0);
    }

    80% {
        transform: translate(5px, 0);
    }

    100% {
        transform: translate(0, 0);
    }
}

/* Responsive Styles */
@media screen and (max-width: 1800px) {
    .timeline-box {
        max-width: 460px;
    }

    .timeline-box.img-right .timeline-content img,
    .timeline-box.img-left .timeline-content img {
        max-width: 220px;
        max-height: 230px;
    }

    .timeline-box-wrap .timeline-content img {
        max-width: 100%;
    }
}

@media screen and (max-width: 1600px) {
    .timeline-row:first-child .timeline-box:first-child {
        width: 38%;
    }

    .timeline-box {
        max-width: 380px;
    }

    .timeline-box.img-right .timeline-content img,
    .timeline-box.img-left .timeline-content img {
        max-width: 180px;
        max-height: 190px;
    }

    .timeline-box h6 {
        font-size: 50px;
    }

    .about-timeline {
        padding: 60px 0 40px;
    }

    .timeline-box p {
        font-size: 16px;
    }
}

@media screen and (max-width: 1440px) {
    .about-timeline {
        padding: 60px 0 40px;
    }

    .start-point h4 {
        font-size: 15px;
        letter-spacing: 0;
    }

    .timeline-box h6 {
        font-size: 40px;
    }

    .timeline-row:first-child .timeline-box:first-child {
        width: 45%;
    }

    .timeline-box p {
        font-size: 15px;
        line-height: 1.4;
    }

    .timeline-box {
        max-width: 300px;
    }

    .timeline-box.img-right .timeline-content img,
    .timeline-box.img-left .timeline-content img {
        max-width: 140px;
        max-height: 200px;
    }

    .timeline-box-wrap .timeline-content img {
        max-width: 100%;
    }

    .timeline-row:first-child .timeline-box:nth-child(2) {
        width: 150px;
    }
}

@media screen and (max-width: 1199px) {
    .about-timeline {
        padding: 50px 0 40px;
    }

    .timeline-box h6 {
        font-size: 34px;
    }

    .timeline-box {
        max-width: 240px;
    }

    .timeline-row:first-child {
        padding: 0 0 0 60px;
    }

    .timeline-row:first-child .timeline-box:first-child {
        width: 42%;
    }

    .timeline-box.img-right .timeline-content,
    .timeline-box.img-left .timeline-content {
        flex-wrap: wrap;
    }

    .timeline-box.img-right .timeline-content img,
    .timeline-box.img-left .timeline-content img {
        max-width: 180px;
        max-height: 200px;
    }
}

@media screen and (max-width: 1024px) {
    .corner {
        display: none;
    }

    .timeline-row .horizontal-line {
        display: none;
    }

    .timeline-row:first-child {
        max-width: 100%;
        padding: 0;
    }

    .timeline-main {
        margin-top: 0;
    }

    .timeline-row .verticle-line {
        right: 50%;
        transform: translate(50%, 0);
        height: calc(100% - 0px);
    }

    .timeline-row:nth-child(2n + 2) .verticle-line {
        left: auto;
        right: 50%;
    }

    .verticle-line::after {
        display: none;
    }

    .timeline-row .timeline-box {
        width: 100%;
        max-width: 100%;
        margin: 0;
    }

    .timeline-row:first-child .timeline-box:first-child {
        width: 100%;
        margin: 0;
    }

    .timeline-row:first-child .timeline-box:nth-child(2) {
        width: 100%;
    }

    .timeline-box h6 {
        transform: translate(0, -0%);
        padding: 0;
    }

    .timeline-content {
        padding: 0;
    }

    .start-point.end-point {
        right: 50%;
    }

    .start-point h4 {
        margin-bottom: 0;
    }

    .about-timeline {
        padding: 80px 0;
    }

    /* Mobile layout fixes */
    .timeline-box-wrap {
        width: 50%;
        text-align: right;
        padding: 0 30px 0 0;
        margin: 40px 0 0 0;
    }

    .timeline-row .timeline-box:nth-child(even) .timeline-box-wrap {
        width: 50%;
        text-align: left;
        padding: 0 0 0 30px;
        margin: 40px 0 0 auto;
    }

    .timeline-row .timeline-box:nth-child(odd) img {
        margin: 0 0 0 auto;
    }

    .timeline-row .timeline-box:nth-child(even) img {
        margin: 0 auto 0 0;
    }

    .timeline-row:first-child .timeline-box:first-child img {
        margin: 0 0 0 auto;
    }

    .timeline-box.img-right .timeline-content img,
    .timeline-box.img-left .timeline-content img {
        margin: 0 0 0 auto;
    }

    .timeline-row .timeline-box:nth-child(odd)::after {
        left: 50%;
        right: auto;
        transform: translate(-100%, 100%) rotate(180deg);
        -webkit-transform: translate(-100%, 100%) rotate(180deg);
        top: 20px;
    }

    .timeline-row .timeline-box:nth-child(even)::after {
        right: 50%;
        left: auto;
        transform: translate(100%, 100%) rotate(0deg);
        -webkit-transform: translate(100%, 100%) rotate(0deg);
        top: 20px;
    }

    .timeline-row:last-child {
        padding-bottom: 70px;
    }

    .inner-wrapper-padding {
        padding: 0 30px;
    }
}

@media screen and (max-width: 640px) {
    .about-timeline {
        padding: 50px 0;
    }

    .timeline-box h6 {
        font-size: 27px;
    }

    .timeline-box p {
        font-size: 14px;
        line-height: 1.4;
    }

    .timeline-box-wrap {
        margin: 30px 0 0 0;
    }

    .timeline-row .timeline-box:nth-child(even) .timeline-box-wrap {
        margin: 30px 0 0 auto;
    }

    .timeline-box::after,
    .timeline-row:nth-child(2n + 1) .timeline-box::after {
        top: 6px;
    }

    .timeline-box-wrap .timeline-content img {
        max-width: 100%;
    }

    .timeline-box.img-right .timeline-content img,
    .timeline-box.img-left .timeline-content img {
        max-width: 100%;
        max-height: unset;
    }

    .inner-wrapper-padding {
        padding: 0 15px;
    }

    .timeline-row {
        padding: 0;
    }
}

/*  */
/* Add this to your existing CSS */
/* Add red arrow before headings - works for all views */
.timeline-box h6.fsz {
    position: relative;
    padding-left: 30px;
    /* Space for arrow */
    display: inline-block;
    /* Ensure arrow stays with text */
}

.timeline-box h6.fsz::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23d21e1e'%3E%3Cpath d='M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: contain;
}

/* For right-aligned headings in alternate rows (desktop only) */
@media screen and (min-width: 1025px) {
    .timeline-row:nth-child(2n + 2) .timeline-box h6.fsz {
        padding-left: 0;
        padding-right: 30px;
    }

    .timeline-row:nth-child(2n + 2) .timeline-box h6.fsz::before {
        left: auto;
        right: 0;
        transform: translateY(-50%) rotate(180deg);
    }
}

/* Mobile view adjustments - ensure arrows are always visible */
@media screen and (max-width: 1024px) {
    .timeline-box h6.fsz {
        padding-left: 30px !important;
        padding-right: 0 !important;
        text-align: left !important;
    }

    .timeline-box h6.fsz::before {
        left: 0 !important;
        right: auto !important;
        transform: translateY(-50%) !important;
    }

    /* For even items in mobile */
    .timeline-row .timeline-box:nth-child(even) .timeline-box-wrap h6.fsz {
        padding-left: 30px !important;
        padding-right: 0 !important;
    }

    .timeline-row .timeline-box:nth-child(even) .timeline-box-wrap h6.fsz::before {
        left: 0 !important;
        right: auto !important;
        transform: translateY(-50%) !important;
    }
}

@media screen and (max-width: 786px) {
    .timeline-box h6.fsz::before {
        background-image: unset !important;
    }

    .fsz {
        font-size: 18px !important;
    }


}