photomk/extra/photo.css
2025-02-20 14:18:04 +01:00

54 lines
831 B
CSS

html {
font-size: 16px;
}
body {
margin: 0;
font-family: 'Source Sans Pro', sans-serif;
}
.my-epic-layout {
display: grid;
grid-template-columns: 1fr 20em;
grid-template-rows: 1fr;
width: 100vw;
height: 100vh;
}
.picture-frame {
padding: 1em;
background-color: #555;
/* for some reason this is required to make the img fit in the box */
overflow: hidden;
display: flex;
justify-content: center;
align-items: center;
}
.picture-frame img {
display: block;
margin: 0 auto;
max-width: 100%;
max-height: 100%;
object-fit: contain;
}
.text-frame {
padding: 1em;
background-color: #f0f0f0;
}
h1 {
font-weight: normal;
font-size: 1.5em;
margin-top: 0;
}
@media (max-aspect-ratio: 16/9) {
.my-epic-layout {
grid-template-columns: 1fr;
grid-template-rows: 1fr auto;
}
}