Edit home style

This commit is contained in:
Paul Nicoué 2025-05-25 18:29:02 +02:00
parent 2f9bf8cd78
commit badf6c29be
16 changed files with 154 additions and 159 deletions

View file

@ -2,4 +2,4 @@
// ABSTRACTS (INDEX)
// --------------------------------------------------
@forward 'variables';
@forward "variables";

View file

@ -4,21 +4,21 @@
// Fonts
$text-font-family: Helvetica, Arial, sans-serif;
$regular-font-weight: 400;
$medium-font-weight: 500;
$semi-bold-font-weight: 600;
$bold-font-weight: 700;
$text-font-size: 1rem;
$text-line-height: 1.1;
$text-font-size: 0.9rem;
$text-line-height: 1.15;
// Dimensions
$icon-size: 3rem;
$sidebar-padding: 0.8rem;
$app-width: min(100%, 120rem); // => 1920px
$large-content-width: min(100%, 100rem); // => 1600px
$medium-content-width: min(100%, 80rem); // => 1280px
$small-content-width: min(100%, 60rem); // => 960px
$icon-size: clamp(2rem, 1.667rem + 0.694vw, 2.5rem); // Viewport range: 48rem <=> 120rem
$icon-spacing: clamp(0.25rem, 0.083rem + 0.347vw, 0.5rem); // Viewport range: 48rem <=> 120rem
// Colors
$black: #000;
$white: #fff;
// Media queries
$tablet-media-query: 48rem;
$desktop-media-query: 62rem;
$tablet-media-query: 48rem; // => 768px
$desktop-media-query: 62rem; // => 992px

View file

@ -1,38 +1,29 @@
@use '../abstracts' as *;
@use "../abstracts" as *;
// --------------------------------------------------
// BASE STYLE
// --------------------------------------------------
// Fonts and colors
body {
color: $black;
background-color: $white;
font-family: $text-font-family;
font-size: $text-font-size;
line-height: $text-line-height;
color: $black;
}
strong {
font-weight: $bold-font-weight;
font-weight: 700;
}
em {
font-style: italic;
}
// Link style
a {
color: $black;
text-decoration: none;
transition: text-decoration 200ms ease-in-out;
&:hover,
&:focus,
&:active {
text-decoration: underline;
}
text-decoration: underline;
text-underline-position: under;
&:focus-visible {
outline: 1px dashed $black;
@ -40,40 +31,81 @@ a {
}
}
// General layout
// --------------------------------------------------
// BASE LAYOUT
// --------------------------------------------------
body {
min-height: 100vh !important;
display: flex;
flex-direction: column;
align-items: center;
header {
position: fixed;
top: 0;
#app {
position: relative;
display: grid;
grid-template-columns: auto 1fr auto;
justify-content: center;
justify-items: center;
width: $app-width;
.header__logo {
width: 5rem;
header {
grid-column: 1;
position: sticky;
top: 0;
height: 100vh; // Fallback in case dvh unit is not supported
height: 100dvh;
padding: 1rem;
.header__logo {
position: relative;
width: $icon-size;
aspect-ratio: calc(1 / 2);
background-image: url("/public/images/signature-vertical.svg");
background-size: contain;
background-position: center;
@media screen and (min-width: $desktop-media-query) {
width: calc(($icon-size * 2) + $icon-spacing);
aspect-ratio: calc(2 / 1);
background-image: url("/public/images/signature-horizontal.svg");
}
}
}
}
main {}
main {
grid-column: 2;
width: $large-content-width;
padding: calc(2rem + $icon-size) 0;
}
footer {
position: fixed;
bottom: 0;
display: flex;
flex-direction: column;
justify-content: flex-end;
gap: 0.8rem;
.footer__link {
footer {
grid-column: 3;
position: sticky;
top: 0;
height: 100vh; // Fallback in case dvh unit is not supported
height: 100dvh;
display: flex;
justify-content: center;
align-items: center;
width: $icon-size;
height: $icon-size;
flex-direction: column;
justify-content: flex-end;
gap: $icon-spacing;
padding: 1rem;
svg {
width: 100%;
height: 100%;
@media screen and (min-width: $desktop-media-query) {
flex-direction: row;
align-items: flex-end;
}
.footer__link {
display: flex;
justify-content: center;
align-items: center;
width: $icon-size;
aspect-ratio: 1;
svg {
width: 100%;
height: 100%;
}
}
}
}

View file

@ -2,5 +2,5 @@
// BASE (INDEX)
// --------------------------------------------------
@forward 'minireset';
@forward 'base';
@forward "minireset";
@forward "base";

View file

@ -2,6 +2,6 @@
// MAIN
// --------------------------------------------------
@use '@splidejs/splide/dist/css/splide-core.min';
@use "@splidejs/splide/dist/css/splide-core.min";
@use "base" as *;
@use "pages" as *;

View file

@ -1,4 +1,4 @@
@use '../abstracts' as *;
@use "../abstracts" as *;
// --------------------------------------------------
// HOME STYLE
@ -10,11 +10,11 @@
display: flex;
flex-direction: column;
align-items: center;
gap: 1rem;
gap: 2rem;
.home__gallery-item {
display: table;
max-width: min(1280px, 100%);
max-width: $medium-content-width;
.home__carousel {
@ -52,6 +52,8 @@
caption-side: bottom;
width: fit-content;
margin: 0.5rem auto 0;
padding: 0 0.5rem;
text-align: center;
}
}
}

View file

@ -2,4 +2,4 @@
// PAGES (INDEX)
// --------------------------------------------------
@forward 'home';
@forward "home";