/**
 * Company Journey Section
 * Video + Horizontal Draggable Timeline
 */

/* ── Section ─────────────────────────────────────────── */
.c-journey {
    padding: 100px 0 120px;
}

/* ── Header ──────────────────────────────────────────── */
.c-journey__header {
    text-align: center;
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 56px;
}

.c-journey__header .title {
    margin-bottom: 16px;
}

.c-journey__header-desc {
    font-size: 1rem;
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.65);
    margin: 0;
}

/* ── Video ───────────────────────────────────────────── */
.c-journey__video {
    position: relative;
    margin-bottom: 72px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.45);
}

.c-journey__video-inner {
    position: relative;
    aspect-ratio: 16 / 7;
    background: #071428;
    overflow: hidden;
}

.c-journey__iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.c-journey__iframe.is-active {
    opacity: 1;
}

/* Poster / overlay */
.c-journey__poster {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(
        135deg,
        rgba(7, 20, 40, 0.85) 0%,
        rgba(37, 60, 116, 0.75) 50%,
        rgba(7, 20, 40, 0.85) 100%
    );
    transition: opacity 0.4s ease, visibility 0.4s ease;
    cursor: pointer;
}

.c-journey__poster.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Animated grid lines on poster */
.c-journey__poster::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 223, 8, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 223, 8, 0.04) 1px, transparent 1px);
    background-size: 60px 60px;
    z-index: 0;
}

.c-journey__poster-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

/* Play button */
.c-journey__play-btn {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 223, 8, 0.95);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
                box-shadow 0.25s ease,
                background 0.2s ease;
    box-shadow: 0 0 0 0 rgba(255, 223, 8, 0.4);
    animation: cpPlayPulse 2.5s ease-out infinite;
    color: #071428;
    flex-shrink: 0;
}

.c-journey__play-btn:hover {
    transform: scale(1.12);
    background: #fff;
    animation: none;
    box-shadow: 0 8px 32px rgba(255, 223, 8, 0.5);
}

.c-journey__play-btn svg {
    margin-left: 4px; /* optical centering */
}

@keyframes cpPlayPulse {
    0%   { box-shadow: 0 0 0 0   rgba(255, 223, 8, 0.45); }
    70%  { box-shadow: 0 0 0 20px rgba(255, 223, 8, 0);   }
    100% { box-shadow: 0 0 0 0   rgba(255, 223, 8, 0);    }
}

/* Poster labels */
.c-journey__poster-labels {
    text-align: center;
}

.c-journey__poster-tag {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 4px 14px;
    border-radius: 100px;
    margin-bottom: 8px;
}

.c-journey__poster-title {
    font-family: "Archivo", sans-serif;
    font-size: clamp(1.125rem, 3vw, 1.625rem);
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px;
}

.c-journey__poster-meta {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.c-journey__poster-meta span::before {
    content: "•";
    margin-right: 8px;
    opacity: 0.5;
}

.c-journey__poster-meta span:first-child::before {
    display: none;
}

/* Video hint text at bottom-left */
.c-journey__video-hint {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 24px 28px 20px;
    background: linear-gradient(to top, rgba(7, 20, 40, 0.85) 0%, transparent 100%);
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    pointer-events: none;
}

.c-journey__video-label-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.c-journey__video-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #FFdf08;
    flex-shrink: 0;
}

.c-journey__video-desc {
    font-size: 0.8125rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.c-journey__video-tag {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    padding: 4px 12px;
    border-radius: 6px;
}

/* ── Timeline wrapper ────────────────────────────────── */
.c-journey__tl {
    position: relative;
}

.c-journey__tl-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 36px;
    flex-wrap: wrap;
}

.c-journey__tl-eyebrow {
    display: block;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #FFdf08;
    margin-bottom: 6px;
}

.c-journey__tl-title {
    font-family: "Archivo", sans-serif;
    font-size: clamp(1.25rem, 2.5vw, 1.625rem);
    font-weight: 700;
    color: #fff;
    margin: 0;
    line-height: 1.25;
}

/* Nav controls */
.c-journey__tl-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.c-journey__tl-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.07);
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
    flex-shrink: 0;
    backdrop-filter: blur(8px);
}

.c-journey__tl-btn:hover {
    background: rgba(255, 223, 8, 0.15);
    border-color: rgba(255, 223, 8, 0.5);
    color: #FFdf08;
    transform: scale(1.05);
}

.c-journey__tl-btn:disabled {
    opacity: 0.3;
    pointer-events: none;
}

.c-journey__tl-pager {
    font-size: 0.8125rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    min-width: 48px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

/* ── Viewport + Track ────────────────────────────────── */
.c-journey__tl-viewport {
    overflow-x: scroll;
    overflow-y: visible;
    scrollbar-width: none;
    -ms-overflow-style: none;
    cursor: grab;
    user-select: none;
    -webkit-overflow-scrolling: touch;
    /* overflow-y visible so ::before/after decorations show */
    padding-bottom: 4px;
}

.c-journey__tl-viewport::-webkit-scrollbar {
    display: none;
}

.c-journey__tl-viewport.is-dragging {
    cursor: grabbing;
    scroll-snap-type: none;
}

.c-journey__tl-track {
    display: inline-flex;
    align-items: flex-end;
    gap: 0;
    padding: 20px 0 0;
    position: relative;
    /* Extra side padding so first/last items are fully visible */
    padding-left: 20px;
    padding-right: 20px;
    min-width: max-content;
}

/* Horizontal line spanning the whole track */
.c-journey__tl-line {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 56px; /* aligns with dot centers: year(24) + gap(8) + dot-radius(8) + padding(16) = 56 */
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    pointer-events: none;
    z-index: 0;
}

.c-journey__tl-line-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #FFdf08 0%, rgba(255, 223, 8, 0.35) 100%);
    transition: width 0.1s linear;
}

/* ── Timeline Item ───────────────────────────────────── */
.c-journey__item {
    flex: 0 0 230px;
    width: 230px;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 12px;
    cursor: default;
    position: relative;
    z-index: 1;
}

/* Stagger card heights for visual rhythm */
.c-journey__item:nth-child(odd)  .c-journey__card { min-height: 170px; }
.c-journey__item:nth-child(even) .c-journey__card { min-height: 140px; }

/* ── Card ────────────────────────────────────────────── */
.c-journey__card {
    width: 100%;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 16px 18px;
    transition: background 0.25s ease, border-color 0.25s ease, transform 0.25s ease,
                box-shadow 0.25s ease;
    position: relative;
    backdrop-filter: blur(8px);
}

.c-journey__card:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 223, 8, 0.4);
    transform: translateY(-5px);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.25);
}

.c-journey__item.is-active .c-journey__card {
    background: rgba(255, 223, 8, 0.1);
    border-color: rgba(255, 223, 8, 0.55);
}

.c-journey__card-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 223, 8, 0.15);
    color: #FFdf08;
    font-size: 0.625rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 100px;
    margin-bottom: 10px;
    border: 1px solid rgba(255, 223, 8, 0.25);
}

.c-journey__card-title {
    font-family: "Archivo", sans-serif;
    font-size: 0.9375rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 8px;
    line-height: 1.3;
}

.c-journey__card-text {
    font-size: 0.75rem;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.58);
    margin: 0;
}

/* ── Connector (stem) ────────────────────────────────── */
.c-journey__stem {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
    transition: background 0.25s;
}

.c-journey__item.is-active .c-journey__stem,
.c-journey__item:hover .c-journey__stem {
    background: rgba(255, 223, 8, 0.45);
}

/* ── Dot (node) ──────────────────────────────────────── */
.c-journey__dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    border: 2px solid rgba(255, 255, 255, 0.35);
    flex-shrink: 0;
    position: relative;
    z-index: 2;
    transition: background 0.25s, border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

.c-journey__dot::after {
    content: "";
    position: absolute;
    inset: 3px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    transition: background 0.25s;
}

.c-journey__item.is-active .c-journey__dot,
.c-journey__item:hover .c-journey__dot {
    background: #FFdf08;
    border-color: rgba(255, 255, 255, 0.7);
    transform: scale(1.35);
    box-shadow: 0 0 0 6px rgba(255, 223, 8, 0.2);
}

.c-journey__item.is-active .c-journey__dot::after,
.c-journey__item:hover .c-journey__dot::after {
    background: rgba(255, 255, 255, 0.9);
}

/* ── Year label ──────────────────────────────────────── */
.c-journey__year {
    margin-top: 10px;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    color: rgba(255, 255, 255, 0.35);
    height: 24px;
    line-height: 24px;
    white-space: nowrap;
    transition: color 0.25s;
    flex-shrink: 0;
    /* extra bottom padding counted in line offset */
    padding-bottom: 16px;
}

.c-journey__item.is-active .c-journey__year,
.c-journey__item:hover .c-journey__year {
    color: #FFdf08;
}

/* ── Progress bar ────────────────────────────────────── */
.c-journey__tl-progress {
    height: 2px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 100px;
    margin-top: 24px;
    overflow: hidden;
}

.c-journey__tl-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #FFdf08, rgba(255, 223, 8, 0.5));
    border-radius: 100px;
    transition: width 0.1s linear;
}

/* ── Scroll hint (first load) ───────────────────────── */
.c-journey__tl-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
    margin-top: 12px;
    transition: opacity 0.4s;
}

.c-journey__tl-hint.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.c-journey__tl-hint-icon {
    display: flex;
    animation: cpHintSlide 1.5s ease-in-out infinite;
}

@keyframes cpHintSlide {
    0%, 100% { transform: translateX(0); }
    50%       { transform: translateX(6px); }
}

/* ── Responsive ──────────────────────────────────────── */
@media (max-width: 767px) {
    .c-journey {
        padding: 72px 0 90px;
    }

    .c-journey__header {
        margin-bottom: 40px;
    }

    .c-journey__video {
        margin-bottom: 48px;
        border-radius: 18px;
    }

    .c-journey__video-inner {
        aspect-ratio: 16 / 9;
    }

    .c-journey__play-btn {
        width: 64px;
        height: 64px;
    }

    .c-journey__tl-head {
        margin-bottom: 24px;
    }

    .c-journey__item {
        flex: 0 0 185px;
        width: 185px;
    }

    .c-journey__item:nth-child(odd)  .c-journey__card { min-height: 150px; }
    .c-journey__item:nth-child(even) .c-journey__card { min-height: 130px; }
}

@media (max-width: 479px) {
    .c-journey__video-hint {
        padding: 16px 16px 14px;
    }

    .c-journey__item {
        flex: 0 0 165px;
        width: 165px;
    }

    .c-journey__tl-pager {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .c-journey__play-btn,
    .c-journey__tl-line-fill,
    .c-journey__tl-progress-fill,
    .c-journey__tl-hint-icon {
        animation: none;
        transition: none;
    }
}
