The appearance of spin-density-wave (SDW) magnetic order in the
low-temperature and high-field corner of the superconducting phase diagram of
CeCoIn5 is unique among unconventional superconductors. The nature of this
magnetic Q phase is a matter of current debate. Here, we present the thermal
conductivity of CeCoIn5 in a rotating magnetic field, which reveals the
presence of an additional order inside the Q phase that is intimately
intertwined with the superconducting d-wave and SDW orders. A discontinuous
change of the thermal conductivity within the Q phase, when the magnetic
field is rotated about antinodes of the superconducting d-wave order
parameter, demands that the additional order must change abruptly together with
the recently observed switching of the SDW. A combination of interactions,
where spin-orbit coupling orients the SDW, which then selects the secondary
p-wave pair-density-wave component (with an average amplitude of 20\% of the
primary d-wave order parameter), accounts for the observed behavior