.transport-selector {
  position: absolute;
  top: var(--s-sm);
  right: var(--s-sm);
  z-index: 1000;
  display: flex;
  background: var(--white);
  border-radius: var(--s-s);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.transport-mode {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--white);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;

  svg {
    width: var(--s-sm);
    height: var(--s-sm);
    color: var(--dark-grey);
    transition: color 0.2s ease;
    pointer-events: none;
  }

  &:hover:not(.active) {
    svg {
      color: var(--brand-primary);
    }
  }

  &.active {
    background: var(--brand-primary);

    svg {
      color: var(--white);
    }
  }

  &:first-child {
    border-radius: var(--s-s) 0 0 var(--s-s);
  }

  &:last-child {
    border-radius: 0 var(--s-s) var(--s-s) 0;
  }

  &:not(:last-child) {
    border-right: 1px solid var(--brand-primary);
  }

  &:not(:first-child):not(:last-child) {
    border-radius: 0;
  }
}

/* Travel time display */
.travel-time-box {
  position: absolute;
  top: var(--s-sm);
  right: calc(var(--s-sm) + 144px + var(--s-s)); /* Right of transport selector + gap */
  z-index: 1000;
  background: var(--brand-primary);
  border-radius: var(--s-s);
  height: 48px;
  min-width: 80px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  color: var(--white);
  font-size: var(--font-md);
  font-weight: normal;
  text-align: center;
  
  /* Center content vertically and horizontally */
  display: flex;
  align-items: center;
  justify-content: center;
}

.travel-time-box.hidden {
  display: none;
}

.travel-time {
  font-size: var(--font-md);
  margin-bottom: 2px;
}

.travel-distance {
  font-size: var(--font-xs);
  opacity: 0.9;
}

/* Responsive */
@media (max-width: var(--brk-mobile)) {
  .transport-selector {
    top: var(--s-xs);
    right: var(--s-xs);
  }

  .transport-mode {
    width: 40px;
    height: 40px;

    svg {
      width: var(--s-ssm);
      height: var(--s-ssm);
    }
  }
  
  .travel-time-box {
    top: var(--s-xs);
    right: calc(var(--s-xs) + 120px + var(--s-s)); /* Adjust for mobile */
    height: 40px; /* Same height as mobile transport-mode */
    min-width: 70px;
  }
}
