philomena/assets/css/elements/layout.css

96 lines
1.5 KiB
CSS
Raw Permalink Normal View History

2023-11-23 17:07:49 +01:00
.column-layout {
display: flex;
flex-direction: row;
2023-11-23 17:07:49 +01:00
width: 100%;
}
.column-layout__left {
margin-right: var(--padding-normal);
width: var(--column-left-width);
}
.column-layout__main {
flex: 1 0 auto;
2024-05-31 20:07:00 +02:00
max-width: calc(100% - var(--column-left-width) - var(--padding-normal));
2023-11-23 17:07:49 +01:00
}
@mixin if-mobile {
2023-11-23 17:07:49 +01:00
.column-layout {
flex-direction: column;
}
.column-layout__left {
margin-right: 0;
}
2024-05-31 20:07:00 +02:00
.column-layout__main {
max-width: 100%;
}
2023-11-23 17:07:49 +01:00
}
#container {
display: flex;
flex-direction: column;
2023-11-23 17:07:49 +01:00
box-sizing: border-box;
height: 100%;
margin: auto;
min-height: 100vh;
width: 100%;
}
.layout--narrow {
width: 96vw;
max-width: var(--narrow-layout-width);
}
.layout--medium {
width: 96vw;
max-width: var(--medium-layout-width);
}
@mixin if-desktop {
2024-05-20 22:30:41 +02:00
.centered-layout .layout--medium,
.centered-layout .layout--narrow {
2024-04-30 20:38:28 +02:00
margin-left: auto;
margin-right: auto;
2023-11-23 17:07:49 +01:00
}
}
#container.centered-layout .layout--centered {
justify-content: center;
margin-left: auto;
margin-right: auto;
}
#container.centered-layout .layout--centered-flex {
display: flex;
flex-direction: column;
align-items: center;
}
.center {
text-align: center;
align-items: center;
justify-content: center;
}
.spacing {
margin: var(--padding-normal);
}
.spacing--right {
margin-right: var(--padding-normal);
}
.spacing--left {
margin-left: var(--padding-normal);
}
.spacing--top {
margin-top: var(--padding-normal);
}
.spacing--bottom {
margin-bottom: var(--padding-normal);
}