Como te comenta pateketrueke, lo debes de hacer así:
Código PHP:
<?php
header( "Content-type: text/css" );
?>
.fondo-docs {
background-image: url(../pic/bg-docs-<?php echo mt_rand(1,5);
?>.png);
background-repeat: no-repeat;
}
Luego lo que haces es poner el documento en tu html (en el head):
Código HTML:
<link rel="stylesheet" href="css.php" type="text/css">
Saludos.