Let $(X,<)$ be a totally ordered set with corresponding order topology $\tau$ and suppose the topology is second countable. Also suppose $X$ contains at least two points, otherwise the result is trivial.
(side note: Henno Brandsma made repeated use of the "gap" and "jump" terminology below. I thought it was his own, but found out it's used with the same meaning on p. 5 of Engelking.)
Step 1: Construct the Dedekind-MacNeille completion $(X^*,<)$ of $(X,<)$ (using the same symbol $<$ for the order relation) and let $\tau^*$ be the corresponding order topology. So $X^*$ is obtained by adding an element $\alpha$ for each "gap" (= Dedekind cut) in $X$, that is, for each pair of nonempty sets $(A,B)$ such that $X=A\cup B$, $a<b$ for each $a\in A$ and $b\in B$, $A$ has no maximum element and $B$ has no minimum element; and also adding a smallest element and a largest element if $X$ did not already have one. The resulting $X^*$ is order-complete (i.e., every subset has a least upper bound) and $\tau^*$ is compact.
Claim: The order topology $\tau$ on $X$ coincides with the subspace topology induced by the order topology $\tau^*$ on $X^*$ and $X$ is topologically dense in $X^*$.
This is easy to check.
Claim: There are only countably many "jumps" in $(X,<)$, i.e., pairs of elements $x,y\in X$ with $x$ an immediate predecessor of $y$.
Reason: Let $\mathscr B\subseteq\tau$ be a countable base for the topology on $X$. For each jump $(x,y)$, the open set $(\leftarrow,x]$ contains an element of $\mathscr B$ containing $x$. So there is a element $B_x$ of the countable base having $x$ as a maximum. Therefore these $B_x$ must all be distinct, and there are only countably many possible $x$.
Step 2: Fill in the jumps. For each jump $\langle x,y\rangle$ in $X$ (which are the same as the jumps in $X^*$), insert a copy of the open real interval $(0,1)$. This constructs a larger ordered set $(X',<)$ into which the ordered set $(X^*,<)$ embeds. Let $\tau'$ be the corresponding order topology on $X'$. $X'$ does not have any jump and does not have any gap (not hard to check).
Claim: The order topology $\tau^*$ on $X^*$ coincides with the subspace topology induced by the order topology $\tau'$ on $X'$.
This is easy to check by comparing neighborhoods of points of $X^*$ for the two topologies, separately for cases when the point is an endpoint of one of the jumps and not.
So by transitivity the ordered set $(X,<)$ embeds into $(X',<)$ as an ordered set and the inclusion is a homeomorphic embedding for the corresponding order topologies.
The space $X$ is separable and dense in $X^*$. And the real interval $(0,1)$ is also separable. So by taking the union of a countable dense subset of $X$ with a countable dense subset for each copy of $(0,1)$ used to fill the countably many gaps, one obtains a countable dense subset of $X'$, showing that $X'$ is separable.
Claim: $X'$ is homeomorphic to the real interval $[0,1]$.
Reason: Let $D$ be a countable (topologically) dense subset of $X'$. Since $X'$ has no jumps, $D$ is order-dense (for each $x,y\in D$ with $x<y$, there is some $z\in D$ with $x<z<y$) and also we can assume $D$ does not contain the smallest and largest element of $X'$, i.e., $(D,<)$ is unbounded. And $X'$ contains no gaps, so is (order-isomorphic to) the Dedekind-MacNeille completion of $(D,<)$. Now, by Cantor's isomorphism theorem any two countable order-dense unbounded linear orders are order-isomorphic. So $D$ is order-isomorphic to $(0,1)\cap\mathbb Q$. And their respective Dedekind-MacNeille completions are also order-isomorphic. So $X'$ is order-isomorphic to the real interval $[0,1]$, and their corresponding order topologies are homeomorphic.
Finally, this shows that $X$ is homeomorphic to a subspace of $[0,1]$ and embeds into $\mathbb R$.
NOTE: The homeomorphic embedding of $X$ into $\mathbb R$ in the proof above is also order-preserving.