/* Company timeline. Without JavaScript the section is a plain list; timeline.js adds .tl-ready and builds the chart above the list. */
#timeline { text-align: left; --tl-ink: #000; --tl-muted: #888; --tl-line: #d0d0d0; --tl-wash: rgba(0, 0, 0, .07); margin: 40px 0 30px; font-family: "IBM Plex Mono", monospace; }
body.dark #timeline { --tl-ink: #bbb; --tl-muted: #999; --tl-line: #444; --tl-wash: rgba(255, 255, 255, .12); }

/* Same heading as BIG PICTURE (insight.css): same font, size, letter spacing, colour, gap and lines */
#timeline .tl-head { display: flex; align-items: center; gap: 14px; margin: 0 0 28px; color: #888; }
#timeline .tl-head hr { flex: 1; margin: 0; border: 0; border-top: 1px solid currentColor; opacity: .5; }
#timeline .tl-head h2 { margin: 0; color: inherit; font: 400 0.75em "IBM Plex Mono", monospace; letter-spacing: 2px; text-transform: uppercase; }

/* The plain list: what search engines and no-JS visitors get. Once the chart is built it stays in the page, out of sight. */
#timeline .tl-list { margin: 0; padding: 0; list-style: none; }
#timeline .tl-item { margin: 0 0 22px; }
#timeline .tl-item h3 { margin: 0 0 6px; font: 700 15px "IBM Plex Mono", monospace; }
#timeline .tl-item p { margin: 0; text-align: left; font-family: "Stooonks Serif", Georgia, serif; font-size: 18px; line-height: 1.5; }
#timeline.tl-ready .tl-list { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Chart */
#timeline .tl-bb { overflow-x: auto; padding-bottom: 8px; scrollbar-width: none; }
#timeline .tl-bb::-webkit-scrollbar { display: none; }
#timeline .tl-bar { display: flex; min-width: calc(var(--n) * 135px); height: 22px; }
#timeline .tl-seg { flex: 1; transition: opacity .1s; }
#timeline .tl-seg.hov { opacity: .7; }
#timeline .tl-labels { position: relative; display: flex; min-width: calc(var(--n) * 135px); margin-top: 6px; }
#timeline .tl-year { all: unset; box-sizing: border-box; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; flex: 1; padding: 54px 8px 0; text-align: center; cursor: pointer; }
#timeline .tl-year::before { content: ""; position: absolute; left: 50%; top: 0; margin-left: -5px; border-bottom: 10px solid var(--tl-ink); border-left: 5px solid transparent; border-right: 5px solid transparent; }
#timeline .tl-year::after { content: ""; position: absolute; left: 50%; top: 16px; height: 28px; border-left: 1px solid var(--tl-ink); }
#timeline .tl-year b { display: block; width: fit-content; margin: 0 auto 6px; font-size: 15px; font-weight: 700; }
#timeline .tl-year span { display: block; font-size: 13px; line-height: 1.4; }
#timeline .tl-year.on span { font-weight: 700; }
#timeline .tl-year:focus-visible { outline: 2px solid #4d819c; outline-offset: -2px; }
#timeline .tl-ul { position: absolute; left: 0; top: 0; height: 3px; background: currentColor; pointer-events: none; }

/* Story: only the year, name and text slide. The buttons and the box stay still. */
#timeline .tl-story { position: relative; overflow: hidden; margin-top: -5px; padding: 0 25px; }
#timeline .tl-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; min-height: 44px; }
#timeline .tl-y { flex: 0 0 auto; font: 700 15px "IBM Plex Mono", monospace; }
#timeline .tl-t { flex: 1 1 140px; min-width: 0; margin: 0; font: 700 15px/1.3 "IBM Plex Mono", monospace; }
#timeline .tl-p { margin: 8px 0 0; text-align: justify; font-family: "Stooonks Serif", Georgia, serif; font-size: 18px; line-height: 1.5; }
#timeline .tl-out { position: absolute; margin: 0; pointer-events: none; }
#timeline .tl-story { touch-action: pan-y; }

#timeline .tl-nav { display: inline-flex; gap: 4px; }
#timeline .tl-step { all: unset; box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 0 14px; color: inherit; cursor: pointer; }
#timeline .tl-step { position: relative; }
#timeline .tl-haptic { position: absolute; inset: 0; width: 100%; min-width: 0; max-width: none; height: 100%; margin: 0; opacity: 0; }
#timeline .tl-haptic { cursor: inherit; }
#timeline .tl-step { overflow: hidden; }
#timeline .tl-step svg { width: 34px; height: 20px; fill: none; stroke: currentColor; stroke-width: 3.6; stroke-linecap: square; stroke-linejoin: miter; }
#timeline .tl-step.next svg { transform: scaleX(-1); }
#timeline .tl-step:hover:not(:disabled) { background: var(--tl-wash); }
#timeline .tl-step:disabled { opacity: .35; cursor: default; }
/* No double-tap zoom on the arrows or year buttons (pinch zoom still works) */
#timeline, #timeline .tl-step, #timeline .tl-year { touch-action: manipulation; }
#timeline .tl-step:focus-visible { outline: 2px solid #4d819c; outline-offset: 2px; }

/* Loading: the same spinner line and shimmer as the revenue chart and the explainer text */
#timeline-status { margin: 40px 0 20px; }
#timeline-status .tl-head { display: flex; align-items: center; gap: 14px; margin: 0 0 28px; color: #888; }
#timeline-status .tl-head hr { flex: 1; margin: 0; border: 0; border-top: 1px solid currentColor; opacity: .5; }
#timeline-status .tl-head h2 { display: flex; align-items: center; margin: 0; color: inherit; font: 400 0.75em "IBM Plex Mono", monospace; letter-spacing: 2px; text-transform: uppercase; }
#timeline-status .revenue-loading-skeleton-bar { height: 22px; }
#timeline-status .tl-skel-labels { display: flex; justify-content: space-around; margin: 40px 0 28px; }
#timeline-status .tl-skel-labels .revenue-loading-skeleton-label { width: min(18%, 110px); }
#timeline-status .skeleton-line { margin-bottom: 4px; }
@media (prefers-reduced-motion: reduce) { #timeline .tl-seg { transition: none; } }
@media (max-width: 520px) {
  #timeline .tl-story { padding: 0 12px; }
  /* The chosen year and name are already shown (bold) in the chart above, so the story row keeps only the arrows. */
  #timeline .tl-y, #timeline .tl-t { display: none; }
  #timeline .tl-row { justify-content: flex-end; }
}
/* 35px more space between the timeline and Big Picture (the card's own top margin is 40px) */
#timeline-slot:has(#timeline) ~ #insight-slot #insight-card { margin-top: 75px; }

/* Line under the timeline, before the last paragraph of the explainer: the same line as the one around the TIMELINE heading */
#explanation-last { margin: 0; }
#timeline-divider { height: 0; margin: 0 0 30px; border: 0; border-top: 1px solid #888; opacity: .5; }
#timeline-slot:empty + #timeline-divider { display: none; }
