Setup frontend — fonts, SCSS structure, header scroll animation
- Add Bartok font-faces (Regular, Poster, Highlight) - Structure SCSS with reset, variables, global, header, home partials - Build fixed header with characters SVG and scroll-driven offset animation - Add home template wiring snippets - Update .gitignore to track src/ and exclude local/ Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
4c0fad1446
commit
c85e0c5a1a
17 changed files with 230 additions and 2 deletions
20
assets/css/src/_fonts.scss
Normal file
20
assets/css/src/_fonts.scss
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
@font-face {
|
||||
font-family: "Bartok";
|
||||
src: url("../fonts/BartokTrial-Regular.otf") format("opentype");
|
||||
font-weight: 400;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: "Bartok";
|
||||
src: url("../fonts/BartokTrial-Poster.otf") format("opentype");
|
||||
font-weight: 700;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: "Bartok";
|
||||
src: url("../fonts/BartokTrial-Highlight.otf") format("opentype");
|
||||
font-weight: 900;
|
||||
font-style: normal;
|
||||
}
|
||||
9
assets/css/src/_global.scss
Normal file
9
assets/css/src/_global.scss
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
// Styles of the raw HTML elements
|
||||
|
||||
body {
|
||||
background-color: var(--color-green);
|
||||
}
|
||||
|
||||
button {
|
||||
cursor: pointer;
|
||||
}
|
||||
53
assets/css/src/_header.scss
Normal file
53
assets/css/src/_header.scss
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
body > .logo {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
text-align: center;
|
||||
position: absolute;
|
||||
font-family: "Bartok", sans-serif;
|
||||
font-size: 6rem;
|
||||
text-transform: uppercase;
|
||||
line-height: 0.8;
|
||||
z-index: -1;
|
||||
}
|
||||
.main-header {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
z-index: 1;
|
||||
|
||||
.top {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
button {
|
||||
font-family: "Bartok", sans-serif;
|
||||
text-transform: uppercase;
|
||||
font-size: 2rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
.characters {
|
||||
margin-top: var(--offset);
|
||||
svg {
|
||||
margin-top: -2.5rem;
|
||||
#left-character-background,
|
||||
#right-character-background path {
|
||||
fill: var(--color-green) !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.strip {
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
padding: 1rem 0;
|
||||
background-color: var(--color-beige);
|
||||
border-radius: var(--radius);
|
||||
border: var(--border);
|
||||
|
||||
font-family: "Bartok", sans-serif;
|
||||
font-size: 2rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
24
assets/css/src/_reset.scss
Normal file
24
assets/css/src/_reset.scss
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
body,
|
||||
html {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
button {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
h1,
|
||||
h2,
|
||||
h3,
|
||||
h4,
|
||||
h5,
|
||||
h6,
|
||||
p,
|
||||
a,
|
||||
figcaption {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
7
assets/css/src/_variables.scss
Normal file
7
assets/css/src/_variables.scss
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
:root {
|
||||
--color-green: #0bb786;
|
||||
--color-beige: #f3f0e7;
|
||||
|
||||
--radius: 0.8rem;
|
||||
--border: 2px solid #000;
|
||||
}
|
||||
5
assets/css/src/pages/_home.scss
Normal file
5
assets/css/src/pages/_home.scss
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
[data-template="home"] {
|
||||
main {
|
||||
height: 200vh;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
@import "src/reset";
|
||||
@import "src/fonts";
|
||||
@import "src/variables";
|
||||
@import "src/global";
|
||||
@import "src/header";
|
||||
@import "src/pages/home";
|
||||
Loading…
Add table
Add a link
Reference in a new issue