<div>display: block;id и class;width: auto);height: auto)html {
box-sizing: border-box;
}
*,
*:before,
*:after {
box-sizing: inherit;
}
.box {
margin: 12px 3px 6px 9px;
/* same as: */
margin-top: 12px;
margin-right: 3px;
margin-bottom: 6px;
margin-left: 9px;
}
.box {
margin: 12px 3px 9px;
/* same as: */
margin-top: 12px;
margin-left: 3px;
margin-right: 3px;
margin-bottom: 9px;
}
.box {
margin: 12px 3px;
/* same as: */
margin-top: 12px;
margin-bottom: 12px;
margin-left: 3px;
margin-right: 3px;
}
.box {
margin: 12px;
/* same as: */
margin-top: 12px;
margin-bottom: 12px;
margin-left: 12px;
margin-right: 12px;
}
auto.auto)px, em, rem)%)vw, vh).box {
margin: 20px;
width: calc(100% - 40px);
height: calc(100vh - 40px);
}
displaydisplay: block;floatdisplay и превращает элемент в blockdisplay: inlinedisplay: inline-block;vertical-align, о котором хорошо написано здесьwidth/height.display: inline-block;display: table;, display: table-cell;, display: table-row;table { display: table; }
tr { display: table-row; }
thead { display: table-header-group; }
tbody { display: table-row-group; }
tfoot { display: table-footer-group; }
col { display: table-column; }
colgroup { display: table-column-group; }
td, th { display: table-cell; }
caption { display: table-caption; }
display: none;display: flex;.container {
display: flex;
flex-direction: row; /* row | row-reverse | column |
column-reverse; */
justify-content: flex-start; /* | flex-end | center |
space-between | space-around | space-evenly |
start | end | left | right ... + safe | unsafe */
align-items: stretch /* flex-start | flex-end |
center | baseline | first baseline | last baseline |
start | end | self-start | self-end + ... safe | unsafe */;
}
.child {
flex-grow: 0; /* 1, ..., n */
flex-shrink: 1; /* 2, ..., n */
flex-basis: auto; /* 0, 200px, 50% */
}
display: flex;.post-title внизу;flex-shrink;justify-content;<aside> и <main> во flexbox контейнер;<aside> и <main> занимали 1/4 и 3/4 от всей длинны контейнераdisplay: grid;grid-template-column, grid-template-rows, grid-areasgrid-area, grid-column, grid-rowgrid-template-column для родителяgrid-template-rows для родилетяgrid-areas для родителяgrid-area для дочерних контейнеровgrid-auto-column, grid-auto-rows, grid-auto-flow.container {
background-image: url(/path/to/file.png);
background-size: cover;
background-repeat: repeat;
background-position: center;
}
.box {
background-image: url(./images/безмятежность.png);
}
.box {
background-image: url(./images/безмятежность.png);
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: no-repeat;
background-color: green;
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: no-repeat;
background-position: center;
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: no-repeat;
background-position: center top;
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: no-repeat;
background-position: right 35% bottom 45%;
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: no-repeat;
background-size: contain;
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: repeat;
background-size: contain;
}
.box {
background-image: url(./images/безмятежность.png);
background-repeat: no-repeat;
background-size: cover;
}
"pages/cv/")index.html и style.css для главной страницыdisplay: griddisplay: flexboxbackground-image