- 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>
12 lines
430 B
JavaScript
12 lines
430 B
JavaScript
document.addEventListener("DOMContentLoaded", () => {
|
|
function updateCharactersOffset() {
|
|
const charactersWrapper = document.querySelector(".characters");
|
|
const MAX_OFFSET = 7;
|
|
const SPEED = 0.6;
|
|
|
|
const topSpace = Math.max(0, MAX_OFFSET - (window.scrollY / 16) * SPEED);
|
|
charactersWrapper.style.setProperty("--offset", topSpace + "rem");
|
|
}
|
|
|
|
window.addEventListener("scroll", updateCharactersOffset);
|
|
});
|