I need to change <p>
color by checking one of the buttons:
<div class="textstyle">
<span class="textarea">
<p class="text">Some text here</p>
</span>
<div class="buttons">
<input type="radio" id="red" name="textbutton" checked/><label for="red">Red</label>
<input type="radio" id="blue" name="textbutton"/><label for="blue">Blue</label>
<input type="radio" id="green" name="textbutton"/><label for="green">Green</label>
</div>
</div>
So, buttons and paragraph have one grandparent. How can I change this structure or what CSS rules should I add to make this work?
UPD: without JS or jQuery