Nick Compton's exemplary technique shone through as Somerset gained a first-innings lead of 65 over Surrey on the second day of the LV= County Championship relegation battle at Taunton.
Compton hit 66 in testing conditions to help his side make 260 in reply to Surrey's 195 on a day curtailed by 19.3 overs because of poor light.
Peter Trego, Craig Kieswetter, Piyush Chawla and Craig Meschede made valuable contributions after openers Marcus Trescothick and Chris Jones had been dismissed for ducks. There were three wickets each for Jade Dernbach and Zafar Ansari.
By the close Surrey had made 13 without loss in their second innings and trailed by 52.
Compton's was the only half-century in either side's first innings and he stood head and shoulders above the other batsmen in handling a pitch that offered seam movement and turn under heavily overcast skies.
The second day began with Surrey 195 for eight. They failed to add to that total, missing out on a precious batting point, as Alfonso Thomas removed Chris Tremlett and Dernbach for figures of 4-23.
Still it looked a reasonable score when Trescothick chopped the third ball of Somerset's reply from Dernbach onto his stumps and Jones edged Tremlett through to wicketkeeper Steven Davies to leave the hosts four for two.
James Hildreth helped Compton take the total to 46 before falling lbw, playing across the line to Stuart Meaker.
Then Kieswetter shared a quick stand of 62, only to ruin his good work by loosely driving a catch to extra-cover off a wide ball from Zander de Bruyn in the final over before lunch.
Somerset's previous game against fellow strugglers Derbyshire had seen Kieswetter dismissed playing an attacking shot off the last ball of the day. As then, it was Compton left incredulous at the other end by his latest indiscretion.
Compton had demonstrated some glorious cover drives amid solid defence to reach his fifty off 88 balls, with 11 fours. It was ended when he chopped a ball from Dernbach onto his stumps with the total on 130.
In the same over Dernbach pinned Alex Barrow leg before for 13 and, at 133 for six, Somerset were in danger of conceding a first-innings deficit.
But Trego and Meschede added 68 in positive fashion before falling in quick succession to slow left-armer Ansari, Trego slicing a catch to deep cover and Meschede bowled by a turning delivery in the same over.
At 201 for eight, Somerset's lead was just six runs. But Chawla is proving a dangerous lower-order batsman for them and the India spinner played with typical panache, hitting Ansari for a towering six over long-off as he and Lewis Gregory added a priceless 55.