/* --- Uncode Repeater Timeline Styles --- */
.uncode-custom-timeline-wrap {
    position: relative;
    padding: 30px 0;
    width: 100%;
    box-sizing: border-box;
}

.uncode-custom-timeline-wrap *, 
.uncode-custom-timeline-wrap *::before, 
.uncode-custom-timeline-wrap *::after {
    box-sizing: border-box;
}

/* Vertical line anchored cleanly between the center of the first and last badge nodes */
.uncode-custom-timeline-wrap .uncode-timeline-line {
    position: absolute;
    top: calc(30px + 46px); /* Container padding + space to first badge center */
    bottom: calc(30px + 46px); /* Container padding + space from bottom block edge to last badge center */
    left: 50%;
    width: 3px;
    margin-left: -1.5px;
    background-color: #e5e5e5;
}

.uncode-timeline-items {
    position: relative;
}

/* Individual timeline block row */
.uncode-timeline-block {
    position: relative;
    margin-bottom: 40px;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

/* Remove bottom margin from the last timeline block */
.uncode-timeline-block:last-child {
    margin-bottom: 0;
}

/* Even/Odd Alternating logic */
.uncode-timeline-block:nth-child(odd) {
    flex-direction: row-reverse;
}

/* Content Box Panel */
.uncode-timeline-panel {
    width: 44%;
    position: relative;
    background: #ffffff;
    border: 1px solid #e1e1e1;
    padding: 30px;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

/* Center Badge Node */
.uncode-timeline-badge {
    position: absolute;
    left: 50%;
    top: 8px;
    transform: translateX(-50%);
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background-color: #6c2eb9; /* Uncode theme compatible accent base */
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 10;
    font-weight: 700;
    font-size: 12px;
    box-shadow: 0 0 0 4px #ffffff, 0 4px 6px rgba(0,0,0,0.1);
}

/* Typography & Media Elements */
.uncode-timeline-title {
    margin-top: 0 !important;
    margin-bottom: 15px !important;
    font-size: 18px !important;
    line-height: 1.3 !important;
}

.uncode-timeline-image {
    margin-bottom: 15px;
}

.uncode-timeline-image img {
    max-width: 100%;
    height: auto;
    border-radius: 3px;
    display: block;
}

.uncode-timeline-body p {
    margin-bottom: 0 !important;
}

/* Responsive layout adjustments for mobile screens */
@media screen and (max-width: 768px) {
    .uncode-custom-timeline-wrap .uncode-timeline-line {
        left: 30px;
        margin-left: 0;
        top: calc(30px + 38px);
        bottom: calc(30px + 38px);
    }
    
    .uncode-timeline-block,
    .uncode-timeline-block:nth-child(odd) {
        flex-direction: row;
        justify-content: flex-end;
    }

    .uncode-timeline-badge {
        left: 30px;
        transform: none;
        width: 60px;
        height: 60px;
        font-size: 11px;
    }

    .uncode-timeline-panel {
        width: calc(100% - 75px);
    }
}