/* ==========================================================================
   Papyrus Converse — Ontology section
   /e15/css/papyrus-converse-ontology.css
   ========================================================================== */

.cv-onto {
    --cv-onto-primary: var(--cv-primary, #6bb8be);
    --cv-onto-primary-dark: var(--cv-primary-dark, #5aa8ae);
    --cv-onto-ink: #3f8a90;
    --cv-onto-text: #1e293b;
    --cv-onto-text-2: #475569;
    --cv-onto-border: var(--cv-border, #e2e8f0);
    --cv-onto-ease: cubic-bezier(0.4, 0, 0.2, 1);

    background: linear-gradient(180deg, rgba(107, 184, 190, 0.07) 0%, rgba(107, 184, 190, 0.02) 100%);
}

.cv-onto .cv-section__title {
    margin-bottom: 40px;
}

.cv-onto .cv-onto__steps {
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
    margin: 0 0 56px;
    padding: 34px 0 0;
    list-style: none;
}

/* the line the four steps grow along: light at 01, full teal at 04 */
.cv-onto__steps::before {
    content: "";
    position: absolute;
    top: 9px;
    right: 12.5%;
    left: 12.5%;
    height: 3px;
    border-radius: 3px;
    background: linear-gradient(90deg, rgba(107, 184, 190, 0.25) 0%, var(--cv-onto-primary) 100%);
}

.cv-onto__step {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* nodes get bigger from 01 to 04: the ontology grows */
.cv-onto__node {
    position: absolute;
    top: -34px;
    left: 50%;
    width: 14px;
    height: 14px;
    margin-top: 4px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: rgba(107, 184, 190, 0.5);
    box-shadow: 0 0 0 1px rgba(107, 184, 190, 0.4);
    transform: translateX(-50%);
}

.cv-onto__step--2 .cv-onto__node {
    width: 17px;
    height: 17px;
    margin-top: 2px;
    background: rgba(107, 184, 190, 0.7);
}

.cv-onto__step--3 .cv-onto__node {
    width: 20px;
    height: 20px;
    margin-top: 1px;
    background: rgba(107, 184, 190, 0.85);
}

.cv-onto__step--4 .cv-onto__node {
    width: 23px;
    height: 23px;
    margin-top: -1px;
    background: var(--cv-onto-primary);
    box-shadow: 0 0 0 1px var(--cv-onto-primary), 0 4px 14px rgba(107, 184, 190, 0.45);
}

.cv-onto__card {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 26px 24px;
    border: 1px solid var(--cv-onto-border);
    border-radius: 12px;
    background: #fff;
    transition: transform 0.25s var(--cv-onto-ease), box-shadow 0.25s var(--cv-onto-ease), border-color 0.25s var(--cv-onto-ease);
}

.cv-onto__card:hover {
    border-color: rgba(107, 184, 190, 0.55);
    transform: translateY(-3px);
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.07);
}

.cv-onto__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.cv-onto__num {
    font-family: 'Montserrat', sans-serif;
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--cv-onto-primary);
}

.cv-onto__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(107, 184, 190, 0.1);
    font-size: 19px;
    color: var(--cv-onto-ink);
}

.cv-onto .cv-onto__title {
    margin: 0 0 10px;
    font-family: 'Montserrat', sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--cv-onto-text);
}

.cv-onto .cv-onto__text {
    margin: 0;
    font-size: 15.5px;
    line-height: 1.65;
    color: var(--cv-onto-text-2);
}

.cv-onto__sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* the Business Terminology example sits on white inside the tinted section */
.cv-onto .cv-animated-section {
    margin-bottom: 0;
}

@media (max-width: 1199px) {
    .cv-onto .cv-onto__steps {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 54px;
    }

    .cv-onto__steps::before,
    .cv-onto__node {
        display: none;
    }

    .cv-onto .cv-onto__steps {
        padding-top: 0;
        row-gap: 20px;
    }
}

/* one column: the line runs down the left side */
@media (max-width: 767px) {
    .cv-onto .cv-section__title {
        margin-bottom: 28px;
    }

    .cv-onto .cv-onto__steps {
        grid-template-columns: minmax(0, 1fr);
        gap: 16px;
        margin-bottom: 40px;
        padding: 0 0 0 34px;
    }

    .cv-onto__steps::before {
        display: block;
        top: 24px;
        right: auto;
        bottom: 24px;
        left: 10px;
        width: 3px;
        height: auto;
        background: linear-gradient(180deg, rgba(107, 184, 190, 0.25) 0%, var(--cv-onto-primary) 100%);
    }

    .cv-onto__node {
        display: block;
        top: 24px;
        left: -24px;
        margin-top: 0;
    }

    .cv-onto__step--2 .cv-onto__node,
    .cv-onto__step--3 .cv-onto__node,
    .cv-onto__step--4 .cv-onto__node {
        margin-top: 0;
    }

    .cv-onto__card {
        padding: 20px 18px;
    }

    .cv-onto__num {
        font-size: 28px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cv-onto__card {
        transition: none;
    }
}
