/* DisputePilot homepage Round 5 — dark / only. Five journey stages, no orphan gaps. */

/* Desktop: five equal columns */
body.v9 #journey .v9-journey {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
body.v9 #journey .v9-stage:last-child::before {
  right: 40%;
}

/* Override the shared 3-column (max-width: 1200px) rule so five stages don't leave a hole */
@media (max-width: 1200px) {
  body.v9 #journey .v9-journey {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    row-gap: var(--g, 14px);
  }
  body.v9 #journey .v9-stage:nth-child(3n)::before {
    right: calc(-1 * var(--g, 14px));
  }
  body.v9 #journey .v9-stage:last-child::before {
    right: 40%;
  }
}

/* Mid widths: 3 + 2, last row split evenly */
@media (max-width: 1100px) {
  body.v9 #journey .v9-journey {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    row-gap: 28px;
  }
  body.v9 #journey .v9-stage {
    grid-column: span 2;
  }
  body.v9 #journey .v9-stage:nth-child(4),
  body.v9 #journey .v9-stage:nth-child(5) {
    grid-column: span 3;
  }
  body.v9 #journey .v9-stage::before,
  body.v9 #journey .v9-stage:nth-child(3n)::before {
    right: calc(-1 * var(--g, 14px));
  }
  body.v9 #journey .v9-stage:nth-child(3)::before,
  body.v9 #journey .v9-stage:nth-child(5)::before,
  body.v9 #journey .v9-stage:last-child::before {
    right: 40%;
  }
}

/* Mobile: one column; Round 4 type and width rules still apply */
@media (max-width: 760px) {
  body.v9 #journey .v9-journey {
    grid-template-columns: 1fr;
    row-gap: 0;
  }
  body.v9 #journey .v9-stage,
  body.v9 #journey .v9-stage:nth-child(4),
  body.v9 #journey .v9-stage:nth-child(5) {
    grid-column: auto;
  }
  body.v9 #journey .v9-stage::before,
  body.v9 #journey .v9-stage:nth-child(3)::before,
  body.v9 #journey .v9-stage:nth-child(3n)::before,
  body.v9 #journey .v9-stage:nth-child(5)::before,
  body.v9 #journey .v9-stage:last-child::before {
    top: 6px;
    bottom: -6px;
    left: 4px;
    right: auto;
    border-top: 0;
    border-left: 2px dotted rgba(7, 28, 40, 0.18);
  }
  body.v9 #journey .v9-stage:last-child::before {
    display: none;
  }
}
