/* SRS Knowledge Pipeline — visual Leitner-box progress timeline.
   Brand colors are CSS custom properties so each project can override on .srs-pipeline. */

.srs-pipeline {
    --srs-brand:        #97c433;
    --srs-brand-soft:   rgba(151, 196, 51, 0.12);
    --srs-brand-glow:   rgba(151, 196, 51, 0.22);
    --srs-final:        #7ba426;
    --srs-final-glow:   rgba(123, 164, 38, 0.22);

    background: #ffffff;
    border-radius: 10px;
    padding: 30px 25px 25px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
    border: 1px solid #eef0f3;
}

.srs-pipeline__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
}

.srs-pipeline__title {
    margin: 0;
    color: var(--srs-brand);
    font-size: 18px;
    font-weight: 700;
}

.srs-pipeline__subtitle {
    margin: 4px 0 0;
    color: #6c757d;
    font-size: 13px;
}

.srs-pipeline__total {
    color: var(--srs-brand);
    font-weight: 600;
    font-size: 13px;
    background: var(--srs-brand-soft);
    padding: 6px 12px;
    border-radius: 20px;
}

.srs-pipeline__track {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    position: relative;
    padding: 10px 0 0;
}

.srs-pipeline__stage {
    flex: 1 1 0;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 0;
}

.srs-pipeline__count {
    font-size: 13px;
    font-weight: 700;
    color: var(--srs-brand);
    margin-bottom: 10px;
    min-height: 18px;
    white-space: nowrap;
}

.srs-pipeline__count--empty {
    color: #adb5bd;
    font-weight: 500;
}

/* Dot wrapper — fixed height equal to dot diameter, so the connector line
   can be vertically centered on the wrapper (and thus exactly on the dot). */
.srs-pipeline__dot-wrap {
    position: relative;
    height: 22px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.srs-pipeline__dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #e9ecef;
    border: 3px solid #ffffff;
    box-shadow: 0 0 0 2px #ced4da;
    position: relative;
    z-index: 2;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.srs-pipeline__dot--active {
    background: var(--srs-brand);
    box-shadow: 0 0 0 2px var(--srs-brand), 0 0 0 6px var(--srs-brand-glow);
}

.srs-pipeline__dot--final {
    background: var(--srs-final);
    box-shadow: 0 0 0 2px var(--srs-final), 0 0 0 6px var(--srs-final-glow);
}

.srs-pipeline__stage:hover .srs-pipeline__dot {
    transform: scale(1.1);
}

/* Connector line — lives on the dot-wrap, perfectly centered vertically. */
.srs-pipeline__stage:not(:last-child) .srs-pipeline__dot-wrap::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 2px;
    background: #ced4da;
    transform: translateY(-50%);
    z-index: 1;
}

.srs-pipeline__stage--reached:not(:last-child) .srs-pipeline__dot-wrap::after {
    background: var(--srs-brand);
}

.srs-pipeline__label {
    font-size: 12px;
    color: #495057;
    margin-top: 12px;
    font-weight: 500;
    line-height: 1.3;
}

.srs-pipeline__label-interval {
    display: block;
    color: #6c757d;
    font-size: 11px;
    margin-top: 2px;
}

.srs-pipeline__loading {
    text-align: center;
    color: #6c757d;
    font-size: 13px;
    padding: 30px 0;
}

/* Responsive — keep the timeline horizontal but tighten spacing. */
@media (max-width: 575px) {
    .srs-pipeline { padding: 20px 12px; }
    .srs-pipeline__count { font-size: 11px; }
    .srs-pipeline__label { font-size: 10px; }
    .srs-pipeline__label-interval { font-size: 9px; }
    .srs-pipeline__dot { width: 16px; height: 16px; }
    .srs-pipeline__dot-wrap { height: 16px; }
}
