From ee08d3491b487dea16855eec17bb5e0a2dfecd25 Mon Sep 17 00:00:00 2001 From: Yasutake Yohei <61961825+yasutakeyohei@users.noreply.github.com> Date: Tue, 6 Oct 2026 13:40:04 +0900 Subject: Astro 7へ更新し、画像をsrc/へ移行・重複を整理 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - astro 6→7 / starlight 0.40→0.42 / sharp更新、markdown-remark導入 - markdownをunified()へ移行、compressHTML:trueで従来の空白を維持 - starlight日本語訳パッチを0.42.5向けに再生成 - 有益な画像をsrc/へ移行しpublic重複を削除、孤立画像を整理 - scripts/optimize-images.mjs を追加(prebuildで自動実行) --- src/styles/custom.css | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'src/styles/custom.css') diff --git a/src/styles/custom.css b/src/styles/custom.css index 856bfe1..1a62595 100644 --- a/src/styles/custom.css +++ b/src/styles/custom.css @@ -859,8 +859,7 @@ main:has(.home-hero) { position: relative; margin: 3.5rem calc(-50vw + 50%) 3rem calc(-50vw + 50%); padding: 6rem 1rem 5rem 8%; - background: url("/img/mini_yasutake-yohei_15.jpg") top center/auto 110% - no-repeat; + overflow: hidden; text-align: left; color: #fff; min-height: 320px; @@ -875,6 +874,16 @@ main:has(.home-hero) { inset: 0; background: none; } +/* Hero background image (optimized via astro:assets) */ +.home-hero .hero-bg { + position: absolute; + inset: 0; + width: 100%; + height: 100%; + object-fit: cover; + object-position: top center; + z-index: 0; +} .home-hero > * { position: relative; z-index: 1; @@ -959,7 +968,7 @@ main:has(.home-hero) { } .home-sep span { font-size: 0.85rem; - color: #888; + color: #666; font-weight: 600; } -- cgit v1.3.1