/* Home: the six-stage workflow from planning to reporting, after Dilara's mockups (design/reference). */

/* The band (night render, water floor, heading) is scoped to .teo-website-lifecycle-section. The glass panel with the
   numbered timeline is scoped to .teo-website-lifecycle-panel, so the Solutions page shows its five migration steps
   (.teo-website-migration-section) in the same panel without the render. */

.teo-website-lifecycle-section {
  --teo-lifecycle-floor: 122px;
  overflow: hidden;
  isolation: isolate;
  padding-top: clamp(64px, 9.4vw, 136px);
  padding-bottom: calc(var(--teo-lifecycle-floor) * 0.83);
}

/* night sky behind the render, ambient light on the water behind the panel; faded at the top and the bottom so the
   section meets its neighbours without a seam */
.teo-website-lifecycle-section::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 40% 24% at 88% 9%, rgba(88, 158, 254, 0.5), transparent 70%),
    radial-gradient(ellipse 30% 20% at 62% 8%, rgba(40, 96, 220, 0.22), transparent 70%),
    radial-gradient(ellipse 4% 12% at 1.5% 66%, rgba(0, 80, 192, 0.55), transparent 70%),
    radial-gradient(ellipse 5% 16% at 99% 60%, rgba(64, 150, 255, 0.5), transparent 70%),
    radial-gradient(ellipse 34% 18% at 50% 72%, rgba(0, 60, 170, 0.16), transparent 72%),
    linear-gradient(90deg, #01030c 0%, rgba(1, 3, 12, 0.85) 40%, rgba(1, 3, 12, 0.35) 70%, rgba(1, 3, 12, 0) 100%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 110px, #000 calc(100% - 150px), transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0, #000 110px, #000 calc(100% - 150px), transparent 100%);
}

/* the water floor with the horizon light, drawn over the bottom edge of the panel */
.teo-website-lifecycle-section::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--teo-lifecycle-floor);
  z-index: 2;
  pointer-events: none;
  background: url('../../images/design/lifecycle-floor.webp') center top / 100% 100% no-repeat;
}

.teo-website-lifecycle-art {
  position: absolute;
  top: 0;
  right: 0;
  width: min(65%, 1180px);
  z-index: -1;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 70px);
  mask-image: linear-gradient(180deg, transparent 0, #000 70px);
}

.teo-website-lifecycle-art img {
  width: 100%;
  height: auto;
}

.teo-website-lifecycle-section .teo-website-shell {
  max-width: 1440px;
  position: relative;
  z-index: 1;
}

/* heading on the left, over the dark side of the render */

.teo-website-lifecycle-section .teo-website-heading {
  max-width: 880px;
  margin-bottom: clamp(56px, 8.9vw, 128px);
  padding-left: clamp(0px, 1.6vw, 22px);
}

.teo-website-lifecycle-section .teo-website-eyebrow {
  margin-bottom: 20px;
  color: #b1c7db;
  font-size: 13px;
  letter-spacing: 0.24em;
}

.teo-website-lifecycle-section .teo-website-title {
  font-size: clamp(40px, 4.86vw, 70px);
  font-weight: 600;
  line-height: 1.01;
  letter-spacing: -0.035em;
  word-spacing: 0.08em;
}

/* only the closing words light up, pale sky blue as in the mockup, 'tek' staying almost white */
.teo-website-lifecycle-section .teo-website-title em {
  background: linear-gradient(100deg, #f4f9ff 0%, #e2f1fd 20%, #bfe2fa 34%, #acd7f7 70%, #a3d2f6 100%);
  -webkit-background-clip: text;
  background-clip: text;
  text-shadow: 0 0 28px rgba(120, 190, 255, 0.22);
}

.teo-website-lifecycle-section .teo-website-lead {
  max-width: 440px;
  margin-top: 22px;
  color: #bac9da;
  font-size: clamp(16px, 1.45vw, 21px);
  line-height: 1.3;
}

/* the glass panel: one card holding the stages */

.teo-website-lifecycle.teo-website-lifecycle-panel {
  --teo-lifecycle-dot: 60px;
  --teo-lifecycle-panel-top: 18px;
  --teo-lifecycle-number: 16px;
  --teo-lifecycle-number-gap: 12px;
  --teo-lifecycle-divider: rgba(77, 140, 255, 0.16);
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0;
  padding: var(--teo-lifecycle-panel-top) 0 30px;
  border-radius: 32px 32px 0 0;
  background:
    radial-gradient(ellipse 9% 40% at 100% 0%, rgba(96, 180, 255, 0.28), transparent 70%),
    linear-gradient(180deg, rgba(2, 20, 50, 0.82) 0%, rgba(2, 18, 46, 0.7) 55%, rgba(2, 14, 38, 0.35) 100%);
  box-shadow: inset 0 1px 0 rgba(120, 180, 255, 0.16), 0 -18px 60px -30px rgba(40, 110, 255, 0.45);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.teo-website-lifecycle.teo-website-lifecycle-panel.teo-website-lifecycle-5 {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

/* 1px edge, brightest along the top and fading down the sides */
.teo-website-lifecycle.teo-website-lifecycle-panel::after {
  content: '';
  position: absolute;
  inset: 0;
  padding: 1px;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(ellipse 10% 60% at 99% 0%, rgba(128, 212, 253, 0.95), transparent 70%),
    linear-gradient(180deg, rgba(48, 120, 255, 0.7) 0%, rgba(40, 110, 255, 0.28) 35%, rgba(40, 110, 255, 0) 85%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

/* the timeline through the centres of the circles, with faded tails to the panel edges; it draws in from the left
   (the base transition) when the panel is revealed */
.teo-website-lifecycle.teo-website-lifecycle-panel::before {
  top: calc(var(--teo-lifecycle-panel-top) + var(--teo-lifecycle-number) + var(--teo-lifecycle-number-gap) + var(--teo-lifecycle-dot) / 2 - 1px);
  left: 1%;
  right: 1%;
  height: 2px;
  background: linear-gradient(90deg, rgba(42, 107, 255, 0) 0%, rgba(42, 107, 255, 0.6) 4%, #6cc0ff 8.4%, #d6f1ff 50%,
    #6cc0ff 91.6%, rgba(42, 107, 255, 0.6) 96%, rgba(42, 107, 255, 0) 100%);
  filter: drop-shadow(0 0 3px rgba(77, 164, 255, 0.95)) drop-shadow(0 0 10px rgba(42, 107, 255, 0.8));
}

.teo-website-lifecycle-panel .teo-website-lifecycle-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.teo-website-lifecycle-number {
  display: block;
  height: var(--teo-lifecycle-number);
  margin-bottom: var(--teo-lifecycle-number-gap);
  color: #8fb0e0;
  font-size: 14px;
  font-weight: 500;
  line-height: var(--teo-lifecycle-number);
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

/* the circles ignite one after another as the panel is revealed */
.teo-website-lifecycle-panel .teo-website-lifecycle-dot {
  position: relative;
  flex: none;
  width: var(--teo-lifecycle-dot);
  height: var(--teo-lifecycle-dot);
  border: 2px solid rgba(77, 164, 255, 0.45);
  background: radial-gradient(circle at 50% 32%, #0f3f86 0%, #072b61 58%, #04214d 100%);
  color: #cfe6ff;
  font-size: 22px;
  box-shadow: 0 0 0 1px rgba(144, 215, 255, 0.06), 0 0 6px rgba(42, 140, 255, 0.3);
  transition: border-color 0.7s ease, box-shadow 0.7s ease, transform 0.3s ease;
  transition-delay: calc(var(--teo-delay, 0s) + 0.35s), calc(var(--teo-delay, 0s) + 0.35s), 0s;
}

.teo-website-lifecycle-panel.teo-website-visible .teo-website-lifecycle-dot {
  border-color: #5cb6ff;
  box-shadow: 0 0 0 1px rgba(144, 215, 255, 0.15), 0 0 14px rgba(42, 140, 255, 0.85), 0 0 36px rgba(42, 107, 255, 0.45),
    inset 0 0 14px rgba(77, 164, 255, 0.35);
}

.teo-website-lifecycle-panel .teo-website-lifecycle-stage:hover .teo-website-lifecycle-dot {
  border-color: #8fd2ff;
  box-shadow: 0 0 0 1px rgba(144, 215, 255, 0.25), 0 0 18px rgba(77, 170, 255, 0.95), 0 0 48px rgba(42, 107, 255, 0.6),
    inset 0 0 16px rgba(110, 190, 255, 0.45);
  transform: translateY(-2px);
  transition-delay: 0s;
}

.teo-website-lifecycle-dot i {
  line-height: 1;
}

/* title and text left-aligned under the centred circle, a hairline between the columns */
.teo-website-lifecycle-body {
  align-self: stretch;
  flex: 1;
  margin-top: 17px;
  padding: 0 20px 0 clamp(20px, 2.8vw, 40px);
}

.teo-website-lifecycle-stage + .teo-website-lifecycle-stage .teo-website-lifecycle-body {
  border-left: 1px solid var(--teo-lifecycle-divider);
}

.teo-website-lifecycle-panel .teo-website-lifecycle-stage h3 {
  margin: 4px 0 15px;
  color: #fff;
  font-size: clamp(17px, 1.42vw, 20.5px);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.teo-website-lifecycle-panel .teo-website-lifecycle-stage p {
  color: #9db4d5;
  font-size: clamp(14px, 1.15vw, 16.5px);
  line-height: 1.43;
}

/* Solutions page: the migration steps stand in their own glass card, closed all round since no water floor covers its
   lower edge, with a pool of light under it */
.teo-website-migration-section .teo-website-lifecycle-panel {
  padding-bottom: 36px;
  border-radius: 28px;
  box-shadow: inset 0 1px 0 rgba(120, 180, 255, 0.16), 0 -18px 60px -30px rgba(40, 110, 255, 0.45),
    0 34px 70px -40px rgba(30, 100, 240, 0.55);
}

@media (max-width: 1280px) {
  .teo-website-lifecycle-body {
    padding-right: 14px;
  }
}

/* tablet: the render sits behind the heading, the panel holds rows of three */
@media (max-width: 1080px) {
  .teo-website-lifecycle-art {
    width: 100%;
    opacity: 0.8;
  }

  /* a dark veil on the left keeps the heading readable over the town */
  .teo-website-lifecycle-art::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 20, 0.88) 0%, rgba(2, 6, 20, 0.62) 50%, rgba(2, 6, 20, 0) 85%);
  }

  .teo-website-lifecycle-section .teo-website-heading {
    margin-bottom: clamp(48px, 18vw, 180px);
  }

  .teo-website-lifecycle.teo-website-lifecycle-panel, .teo-website-lifecycle.teo-website-lifecycle-panel.teo-website-lifecycle-5 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 0;
    border-radius: 28px;
  }

  /* one short segment per stage replaces the single line, so each row has its own timeline */
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage::before {
    content: '';
    position: absolute;
    top: calc(var(--teo-lifecycle-number) + var(--teo-lifecycle-number-gap) + var(--teo-lifecycle-dot) / 2 - 1px);
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #4da4ff, #a9dcff, #4da4ff);
    filter: drop-shadow(0 0 3px rgba(77, 164, 255, 0.9)) drop-shadow(0 0 8px rgba(42, 107, 255, 0.7));
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(3n + 1)::before {
    left: 50%;
  }

  /* each row's line ends at its last circle, also when the last row is not full */
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(3n)::before,
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:last-child::before {
    right: 50%;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(n + 4) {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--teo-lifecycle-divider);
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(n + 4)::before {
    top: calc(24px + var(--teo-lifecycle-number) + var(--teo-lifecycle-number-gap) + var(--teo-lifecycle-dot) / 2 - 1px);
  }

  .teo-website-lifecycle-stage:nth-child(3n + 1) .teo-website-lifecycle-body {
    border-left: 0;
  }
}

/* phone: a vertical timeline, the render a banner above the heading */
@media (max-width: 600px) {
  .teo-website-lifecycle-section {
    --teo-lifecycle-floor: 84px;
    padding-top: 24px;
  }

  .teo-website-lifecycle.teo-website-lifecycle-panel {
    --teo-lifecycle-dot: 48px;
  }

  .teo-website-lifecycle-art {
    position: relative;
    width: 100%;
    height: 260px;
    margin-bottom: -50px;
    overflow: hidden;
    opacity: 1;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 56px, #000 50%, transparent 94%);
    mask-image: linear-gradient(180deg, transparent 0, #000 56px, #000 50%, transparent 94%);
  }

  .teo-website-lifecycle-art::after {
    content: none;
  }

  .teo-website-lifecycle-art img {
    position: absolute;
    top: -34px;
    right: -26%;
    width: 168%;
    max-width: none;
  }

  .teo-website-lifecycle-section .teo-website-title {
    font-size: clamp(30px, 9.3vw, 40px);
  }

  .teo-website-lifecycle-section .teo-website-heading {
    margin-bottom: 40px;
    padding-left: 0;
  }

  .teo-website-lifecycle-section .teo-website-lead {
    max-width: none;
    margin-top: 20px;
  }

  .teo-website-lifecycle.teo-website-lifecycle-panel, .teo-website-lifecycle.teo-website-lifecycle-panel.teo-website-lifecycle-5 {
    grid-template-columns: minmax(0, 1fr);
    padding: 20px 20px 28px;
    border-radius: 24px;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage {
    display: grid;
    grid-template-columns: var(--teo-lifecycle-dot) minmax(0, 1fr);
    column-gap: 18px;
    align-items: start;
    padding: 16px 0;
  }

  /* the line runs down from each circle centre to the next one */
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage::before,
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(3n + 1)::before,
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(3n)::before,
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(n + 4)::before {
    top: calc(16px + var(--teo-lifecycle-dot) / 2);
    bottom: calc(-16px - var(--teo-lifecycle-dot) / 2);
    left: calc(var(--teo-lifecycle-dot) / 2 - 1px);
    right: auto;
    width: 2px;
    height: auto;
    background: linear-gradient(180deg, #6cc0ff, #c4e9ff 50%, #6cc0ff);
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:last-child::before {
    content: none;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:nth-child(n + 4) {
    margin-top: 0;
    padding-top: 16px;
    border-top: 0;
  }

  /* hairline between stages, beside the line rather than across it */
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage + .teo-website-lifecycle-stage::after {
    content: '';
    position: absolute;
    top: 0;
    left: calc(var(--teo-lifecycle-dot) + 18px);
    right: 0;
    height: 1px;
    background: var(--teo-lifecycle-divider);
  }

  .teo-website-lifecycle-number {
    grid-column: 2;
    grid-row: 1;
    height: auto;
    margin: 0 0 2px;
    font-size: 13px;
    line-height: 1.4;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-dot {
    grid-column: 1;
    grid-row: 1 / span 2;
    font-size: 19px;
  }

  .teo-website-lifecycle-body,
  .teo-website-lifecycle-stage + .teo-website-lifecycle-stage .teo-website-lifecycle-body {
    grid-column: 2;
    grid-row: 2;
    margin: 0;
    padding: 0;
    border-left: 0;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage h3 {
    margin: 0 0 6px;
    font-size: 19px;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-stage p {
    font-size: 15px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .teo-website-lifecycle.teo-website-lifecycle-panel::before {
    transform: none;
    transition: none;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-dot {
    border-color: #5cb6ff;
    box-shadow: 0 0 0 1px rgba(144, 215, 255, 0.15), 0 0 14px rgba(42, 140, 255, 0.85), 0 0 36px rgba(42, 107, 255, 0.45),
      inset 0 0 14px rgba(77, 164, 255, 0.35);
    transition: none;
  }

  .teo-website-lifecycle-panel .teo-website-lifecycle-dot,
  .teo-website-lifecycle-panel .teo-website-lifecycle-stage:hover .teo-website-lifecycle-dot {
    transform: none;
  }
}
