Witam.
Tworzę stronkę która posiada wiele podstron, chciałbym uzyskać efekt innego tła na wielu podstronach.
Niestety nie wiem jak optymalnie to zrobić.
Czy muszę tworzyć nowego cssa dla każdej podstrony gdzie zmienia się tylko background-image?
Czy istnieje jakiś optymalny sposób, trick w css na różne tło na wielu podstronach?
Mój css
body
{
background-size: 100%;
background-repeat: no-repeat;
background-attachment: fixed;
background-image: url("ducati.jpg");
}
#topnav
{
background-color: #141414;
width:900px;
margin:0 auto;
list-style:none;
margin-top:50px;
font-size:20px;
}
#topnav li {
float:left;
}
#topnav a {
padding: 5px 19px 5px 5px;
display:block;
text-align:center;
width:100px; /* fixed width */
text-decoration:none;
color: white;
background-image: url("black.jpg");
}
#topnav:after { content: ''; display: block; clear: left; }
#topnav li a:hover{
background-color: #000000;
color:white;
}
#bar
{
float: left;
margin-left:150px;
margin-top:140px;
font-size:20px;
list-style-type:none;
width:130px;
}
#bar li a
{
margin: 15px;
display: block;
color: white;
padding: 8px 16px;
text-decoration: none;
}
#bar li a:hover
{
background-color: #141414;
color:white;
}
#art{
margin: 10px 200px 200px 300px;
padding: 140px;
line-height: 150%;
}
#h1{
font-size=20px;
}
#foot {
color:white;
display: block;
bottom:0;
margin: 20px auto 0px auto;
font-size: 15px;
text-align: center;
clear: both;
float:center;
text-decoration: none;
}
#foot a
{
text-decoration: none;
color:white;
}