/*
  shine-timeline — circular milestone row with year + copy.
  Desktop: Figma 479:4
  Mobile: no frame yet — stacked, centered.
*/

.shine-timeline {
  position: relative;
  isolation: isolate;
  overflow-x: clip;
  border-block-end: 1px solid var(--color-border-subtle);
  background-color: var(--color-bg);
  color: var(--color-text);
}

.shine-timeline__inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  box-sizing: border-box;
  inline-size: 100%;
  max-inline-size: var(--header-frame-max);
  margin-inline: auto;
  padding-block: var(--shine-timeline-pad-y-mobile);
  padding-inline: var(--space-md);
}

/* Optional H3 + intro above the year row (content brief, not in Figma 479:4). */
.shine-timeline__header {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  inline-size: 100%;
  max-inline-size: 60.8125rem; /* 973px — match guarantee lead */
  margin-inline: auto;
  text-align: center;
}

.shine-timeline__title {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: var(--fw-black);
  font-size: var(--fs-hero-title-mobile);
  line-height: var(--hero-title-lh-mobile);
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--color-text);
}

.shine-timeline__intro {
  margin: 0;
  font-family: var(--font-body-alt);
  font-weight: var(--fw-regular);
  font-size: var(--fs-hero-text-mobile);
  line-height: 1.875rem;
  letter-spacing: -0.02em;
  color: var(--color-text-heading);
}

/* Stacked cards on small screens */
.shine-timeline__list {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2xl);
  margin: 0;
  padding: 0;
  list-style: none;
}

.shine-timeline__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--shine-timeline-item-gap);
  inline-size: 100%;
  max-inline-size: 20rem;
}

.shine-timeline__photo {
  position: relative;
  z-index: 1;
  margin: 0;
  inline-size: var(--shine-timeline-photo);
  block-size: var(--shine-timeline-photo);
  overflow: hidden;
  border-radius: var(--radius-pill);
  background-color: var(--color-bg);
}

.shine-timeline__photo-img {
  display: block;
  inline-size: 100%;
  block-size: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
}

.shine-timeline__copy {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9375rem; /* 15px — Figma year → body */
  inline-size: 100%;
  max-inline-size: var(--shine-timeline-copy-w);
}

.shine-timeline__year {
  margin: 0;
  inline-size: 100%;
  font-family: var(--font-heading);
  font-weight: var(--fw-black);
  font-size: 1.5rem; /* 24px */
  line-height: 1.8125rem; /* 29px */
  letter-spacing: -0.02em;
  text-align: center;
  text-transform: uppercase;
  color: var(--color-text);
}

.shine-timeline__text {
  margin: 0;
  font-family: var(--font-body-alt);
  font-weight: var(--fw-regular);
  font-size: 1rem; /* 16px */
  line-height: 1.25rem; /* 20px */
  letter-spacing: -0.02em;
  color: var(--color-text);
}

.shine-timeline__text p {
  margin: 0;
}

.shine-timeline__link {
  color: inherit;
  text-decoration: underline;
  text-underline-position: from-font;
  text-decoration-skip-ink: none;
}

.shine-timeline__link:hover,
.shine-timeline__link:focus-visible {
  color: var(--color-primary);
}

.shine-timeline__link:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* ---------- Desktop — Figma 479:4 ---------- */
/* --bp-lg: 1024px */

@media (min-width: 1024px) {
  .shine-timeline__inner {
    padding-block: var(--shine-timeline-pad-y);
    padding-inline: var(--header-pad-x);
  }

  .shine-timeline__title {
    font-size: var(--fs-brand-intro-title, 3.375rem);
    line-height: var(--lh-brand-intro-title, 3.375rem);
  }

  .shine-timeline__intro {
    font-size: var(--fs-hero-text);
  }

  .shine-timeline__list {
    position: relative;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0;
  }

  .shine-timeline__item {
    position: relative;
    flex: 1 1 0;
    max-inline-size: none;
    min-inline-size: 0;
    /* Figma Price-board: 44px sides / 40px vertical */
    padding-block: 2.5rem;
    padding-inline: 0.75rem;
  }

  /*
    Figma 479:4 uses five short strokes (Line 15–19, 124px) in the
    gaps between photos — not one rule across the whole row.
    Each item except the last draws from this photo’s right edge
    to the next photo’s left edge. Photos sit above (z-index).
  */
  .shine-timeline__item:not(:last-child)::after {
    content: "";
    position: absolute;
    z-index: 0;
    /* Vertically center on the 127px photo (below the 40px item padding). */
    inset-block-start: calc(
      2.5rem + (var(--shine-timeline-photo) / 2) - (var(--shine-timeline-line-thickness) / 2)
    );
    /* Start at the photo’s right edge. 1px overlap hides a hairline gap. */
    inset-inline-start: calc(50% + (var(--shine-timeline-photo) / 2) - 1px);
    inline-size: calc(100% - var(--shine-timeline-photo) + 2px);
    block-size: var(--shine-timeline-line-thickness);
    background-color: var(--shine-timeline-line);
    pointer-events: none;
  }

  .shine-timeline__copy {
    max-inline-size: var(--shine-timeline-copy-w);
  }
}
