From 51e24b9d8d27ea14d8c23bda2ba69a84397e787c Mon Sep 17 00:00:00 2001 From: waifu Date: Mon, 3 Jun 2024 23:25:29 -0300 Subject: [PATCH] background scroll --- home/art/img/mainbackground.png | 3 +++ home/art/styles.css | 13 +++++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) create mode 100644 home/art/img/mainbackground.png diff --git a/home/art/img/mainbackground.png b/home/art/img/mainbackground.png new file mode 100644 index 0000000..c0cb160 --- /dev/null +++ b/home/art/img/mainbackground.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8987609ac4b84eb9fdbd00e4b4af3d264211e64e1fa6e2632a167c6661f4eefb +size 10619 diff --git a/home/art/styles.css b/home/art/styles.css index 32ac47b..299c96a 100644 --- a/home/art/styles.css +++ b/home/art/styles.css @@ -1,4 +1,4 @@ -body, html { +body { display: flex; justify-content: center; align-items: center; @@ -6,11 +6,16 @@ body, html { } body{ - background-image: url('./img/bg.jpg'); - background-attachment: fixed; - background-position: center center; + background-image: url('./img/mainbackground.png'); + animation: scroll 2s infinite cubic-bezier(.68,-0.55,.27,1.55); + } +@-webkit-keyframes scroll { + from {background-position: 0px 0px;} + to {background-position: 128px 128px;} + } + #header{ justify-content: center; }