.history-page {
    --history-dark: #111318;
    --history-orange: var(--theme-color, #ff6b35);
    --history-ink: #17191d;
    --history-muted: #686c74;
    --history-line: #dedfe2;
    background: #ffffff;
}

/* ---- Hero ---- */
.history-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 116px 0 108px;
    background:
        linear-gradient(118deg, rgba(255, 107, 53, 0.08), transparent 38%),
        var(--history-dark);
}

.history-hero::before {
    position: absolute;
    z-index: -1;
    inset: 0;
    content: "";
    opacity: 0.2;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 72px 72px;
    mask-image: linear-gradient(90deg, transparent, #000 50%, #000);
}

.history-hero__glow {
    position: absolute;
    z-index: -1;
    right: -180px;
    bottom: -320px;
    width: 720px;
    height: 720px;
    border: 1px solid rgba(255, 107, 53, 0.25);
    border-radius: 50%;
    box-shadow:
        0 0 0 90px rgba(255, 107, 53, 0.035),
        0 0 0 180px rgba(255, 107, 53, 0.025);
}

.history-eyebrow {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    color: var(--history-orange);
    font: 700 12px/1.2 var(--secondary-font, "Inter", sans-serif);
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.history-eyebrow > span {
    width: 34px;
    height: 2px;
    background: currentColor;
}

.history-eyebrow--light {
    color: #ff8b60;
}

.history-hero h1 {
    max-width: 900px;
    color: #ffffff;
    font-size: clamp(46px, 5.2vw, 74px);
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: -0.045em;
}

.history-hero h1 em {
    color: var(--history-orange);
    font-style: normal;
}

.history-hero__lead {
    max-width: 690px;
    margin-top: 30px;
    color: rgba(255, 255, 255, 0.68);
    font-size: 18px;
    line-height: 1.75;
}

.history-principles {
    margin-left: auto;
    padding: 10px 30px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(10px);
}

.history-principle {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.history-principle:last-child {
    border-bottom: 0;
}

.history-principle span {
    min-width: 74px;
    color: var(--history-orange);
    font-size: 13px;
    font-weight: 800;
}

.history-principle strong {
    color: #ffffff;
    font: 500 15px/1.45 var(--secondary-font, "Inter", sans-serif);
}

/* ---- Shared section heading ---- */
.history-section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 50px;
    margin-bottom: 76px;
}

.history-section-heading > div {
    max-width: 650px;
}

.history-section-heading h2 {
    color: var(--history-ink);
    font-size: clamp(36px, 3.6vw, 52px);
    font-weight: 600;
    line-height: 1.12;
    letter-spacing: -0.035em;
}

.history-section-heading > p {
    max-width: 460px;
    padding-bottom: 4px;
    color: var(--history-muted);
    font-size: 15px;
    line-height: 1.75;
}

/* ---- Timeline ---- */
.history-timeline-section {
    padding: 124px 0 132px;
    background: #f4f4f2;
}

.history-timeline {
    position: relative;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0;
    list-style: none;
}

.history-timeline::before {
    position: absolute;
    top: 32px;
    bottom: 32px;
    left: 50%;
    width: 1px;
    content: "";
    background: var(--history-line);
    transform: translateX(-50%);
}

.history-timeline__item {
    position: relative;
    width: 50%;
    padding: 0 60px 34px 0;
}

.history-timeline__item:nth-child(even) {
    margin-left: 50%;
    padding: 0 0 34px 60px;
}

.history-timeline__dot {
    position: absolute;
    z-index: 2;
    top: 43px;
    right: -9px;
    width: 18px;
    height: 18px;
    border: 5px solid #f4f4f2;
    border-radius: 50%;
    background: var(--history-orange);
    box-shadow: 0 0 0 1px var(--history-orange);
}

.history-timeline__item:nth-child(even) .history-timeline__dot {
    right: auto;
    left: -9px;
}

.history-milestone {
    position: relative;
    height: 100%;
    padding: 34px 34px 32px;
    border: 1px solid #e1e1df;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 18px 50px rgba(18, 20, 24, 0.055);
    transition: transform 250ms ease, border-color 250ms ease, box-shadow 250ms ease;
}

.history-milestone::before {
    position: absolute;
    top: 42px;
    right: -8px;
    width: 16px;
    height: 16px;
    content: "";
    border-top: 1px solid #e1e1df;
    border-right: 1px solid #e1e1df;
    background: #ffffff;
    transform: rotate(45deg);
}

.history-timeline__item:nth-child(even) .history-milestone::before {
    right: auto;
    left: -8px;
    border: 0;
    border-bottom: 1px solid #e1e1df;
    border-left: 1px solid #e1e1df;
}

.history-milestone:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 107, 53, 0.34);
    box-shadow: 0 28px 64px rgba(18, 20, 24, 0.1);
}

.history-milestone__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.history-milestone__year {
    color: var(--history-orange);
    font: 700 34px/1 var(--primary-font, "Outfit", sans-serif);
    letter-spacing: -0.03em;
}

.history-milestone__phase {
    padding: 7px 11px;
    border-radius: 50px;
    color: #7a7d84;
    background: #f2f2f0;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.history-milestone h3 {
    margin-bottom: 14px;
    color: var(--history-ink);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.25;
    letter-spacing: -0.02em;
}

.history-milestone > p {
    color: var(--history-muted);
    font-size: 14px;
    line-height: 1.8;
}

.history-milestone__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
}

.history-milestone__tags li {
    padding: 7px 11px;
    border: 1px solid #e8e8e5;
    border-radius: 50px;
    color: #5e6168;
    background: #fafaf9;
    font-size: 11px;
    font-weight: 600;
}

.history-timeline__item--current .history-milestone {
    border-color: rgba(255, 107, 53, 0.45);
    background:
        linear-gradient(135deg, rgba(255, 107, 53, 0.055), transparent 58%),
        #ffffff;
}

.history-timeline__item--current .history-timeline__dot {
    box-shadow:
        0 0 0 1px var(--history-orange),
        0 0 0 8px rgba(255, 107, 53, 0.11);
}

/* ---- Stats manifesto ---- */
.history-stats-section {
    padding: 120px 0;
}

.history-manifesto {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 58px 64px;
    border-radius: 28px;
    background: var(--history-dark);
}

.history-manifesto::after {
    position: absolute;
    z-index: -1;
    top: -180px;
    right: -120px;
    width: 420px;
    height: 420px;
    border: 75px solid rgba(255, 107, 53, 0.08);
    border-radius: 50%;
    content: "";
}

.history-manifesto__heading {
    max-width: 680px;
    margin-bottom: 46px;
}

.history-manifesto__heading > span {
    display: block;
    margin-bottom: 12px;
    color: #ff8b60;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.history-manifesto__heading h2 {
    color: #ffffff;
    font-size: clamp(30px, 3vw, 42px);
    font-weight: 500;
    letter-spacing: -0.025em;
}

.history-manifesto__heading p {
    max-width: 600px;
    margin-top: 14px;
    color: rgba(255, 255, 255, 0.62);
    font-size: 14px;
    line-height: 1.75;
}

.history-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
}

.history-stat {
    padding: 0 26px;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.history-stat:first-child {
    padding-left: 0;
    border-left: 0;
}

.history-stat > i {
    display: block;
    margin-bottom: 16px;
    color: var(--history-orange);
    font-size: 20px;
}

.history-stat > div {
    color: #ffffff;
    font: 600 clamp(30px, 3vw, 42px)/1.1 var(--primary-font, "Outfit", sans-serif);
    letter-spacing: -0.035em;
}

.history-stat p {
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.58);
    font-size: 13px;
    font-weight: 500;
}

/* ---- Responsive ---- */
@media only screen and (max-width: 1199px) {
    .history-hero h1 {
        font-size: 58px;
    }

    .history-milestone {
        padding: 30px 28px;
    }
}

@media only screen and (max-width: 991px) {
    .history-hero {
        padding: 94px 0 88px;
    }

    .history-principles {
        margin-top: 50px;
        margin-left: 0;
    }

    .history-section-heading {
        display: block;
        margin-bottom: 58px;
    }

    .history-section-heading > p {
        margin-top: 22px;
    }

    .history-timeline::before {
        left: 9px;
        transform: none;
    }

    .history-timeline__item,
    .history-timeline__item:nth-child(even) {
        width: 100%;
        margin-left: 0;
        padding: 0 0 30px 54px;
    }

    .history-timeline__dot,
    .history-timeline__item:nth-child(even) .history-timeline__dot {
        top: 43px;
        right: auto;
        left: 0;
    }

    .history-milestone::before,
    .history-timeline__item:nth-child(even) .history-milestone::before {
        top: 42px;
        right: auto;
        left: -8px;
        border: 0;
        border-bottom: 1px solid #e1e1df;
        border-left: 1px solid #e1e1df;
    }

    .history-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        row-gap: 36px;
    }

    .history-stat:nth-child(3) {
        padding-left: 0;
        border-left: 0;
    }
}

@media only screen and (max-width: 767px) {
    .history-hero {
        padding: 78px 0 74px;
    }

    .history-hero h1 {
        font-size: 43px;
        line-height: 1.08;
    }

    .history-hero__lead {
        font-size: 16px;
    }

    .history-principles {
        padding: 8px 22px;
    }

    .history-timeline-section {
        padding: 84px 0 90px;
    }

    .history-section-heading h2 {
        font-size: 36px;
    }

    .history-timeline__item,
    .history-timeline__item:nth-child(even) {
        padding-left: 44px;
    }

    .history-milestone {
        padding: 28px 24px;
        border-radius: 18px;
    }

    .history-milestone__year {
        font-size: 30px;
    }

    .history-milestone h3 {
        font-size: 21px;
    }

    .history-stats-section {
        padding: 80px 0;
    }

    .history-manifesto {
        padding: 42px 30px;
        border-radius: 22px;
    }
}

@media only screen and (max-width: 575px) {
    .history-hero h1 {
        font-size: 37px;
    }

    .history-principle {
        align-items: flex-start;
    }

    .history-milestone__meta {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .history-stats-grid {
        grid-template-columns: 1fr;
        row-gap: 0;
    }

    .history-stat,
    .history-stat:first-child,
    .history-stat:nth-child(3) {
        padding: 24px 0;
        border: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .history-stat:last-child {
        padding-bottom: 0;
        border-bottom: 0;
    }
}

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