I wouldn't have to do it to each template file
you would do it generally just in header.php;
example:
<style type="text/css" media="screen">
#header {
background: <?php
$time = intval(date('Hi'));
if ( ($time>800) && ($time<=2000) )
{
echo '#fff';
}
else
{
echo '#000';
}
?>;
}
</style>
either work with a child theme;if I update the theme, I wouldn't have to do it all over again.
http://codex.wordpress.org/Child_Themes
or in extreme create a plugin for this and enqueue the styles; http://codex.wordpress.org/Plugin_API
http://codex.wordpress.org/Function_Reference/wp_enqueue_style