From 8573b8c29d20fc2d8d29003a22ca71298e23498d Mon Sep 17 00:00:00 2001 From: Navneeth Mahadevan Date: Wed, 24 Jun 2026 20:28:20 +0530 Subject: [PATCH 1/2] chore: relative section sizing --- src/styles/main_about.css | 3 +-- src/styles/main_body.css | 23 +++++++++++++++++------ src/styles/main_projects.css | 2 +- 3 files changed, 19 insertions(+), 9 deletions(-) diff --git a/src/styles/main_about.css b/src/styles/main_about.css index e431bd9..7903fbd 100644 --- a/src/styles/main_about.css +++ b/src/styles/main_about.css @@ -38,10 +38,9 @@ display: flex; justify-content: space-between; align-items: center; - min-height: 100vh; + min-height: 100dvh; gap: 50px; flex-wrap: wrap; - border-top: 2px solid #ccc; } #about .about-text, diff --git a/src/styles/main_body.css b/src/styles/main_body.css index f9ba215..88413cb 100644 --- a/src/styles/main_body.css +++ b/src/styles/main_body.css @@ -38,15 +38,20 @@ body { /* HERO (first section) */ .hero { - margin-top: 120px; + min-height: 100dvh; + padding-top: 120px; /* leave room for navbar */ display: flex; justify-content: space-around; align-items: center; text-align: left; - padding: 2rem; + padding-left: 2rem; + padding-right: 2rem; + padding-bottom: 2rem; gap: 3rem; - /* border-bottom: 2px solid #ccc; divider for first section */ + border-bottom: 2px solid #ccc; /* divider for first section */ + box-sizing: border-box; + width: 100%; } #slideshow { @@ -67,7 +72,7 @@ body { /* Section styling + dividers */ section:not(#footer-new) { - min-height: 100vh; + min-height: 100dvh; display: flex; justify-content: center; align-items: center; @@ -77,6 +82,8 @@ section:not(#footer-new) { color: #ffffff; border-bottom: 2px solid #ccc; /* divider for all sections */ + box-sizing: border-box; + width: 100%; } /* Explicit divider for #about too (redundant but ensures consistency) */ @@ -91,9 +98,12 @@ section:not(#footer-new) { justify-content: center; text-align: center; gap: 2rem; - margin-top: 80px; + padding-top: 80px; /* reduced for navbar */ - padding: 1.5rem 1rem; + padding-left: 1rem; + padding-right: 1rem; + padding-bottom: 1.5rem; + min-height: 100dvh; } /* Slideshow fixed box */ @@ -112,6 +122,7 @@ section:not(#footer-new) { section { font-size: 1.8rem; padding: 2rem 1rem; + min-height: 100dvh; } } diff --git a/src/styles/main_projects.css b/src/styles/main_projects.css index 7950dbf..582a9b6 100644 --- a/src/styles/main_projects.css +++ b/src/styles/main_projects.css @@ -38,7 +38,7 @@ flex-direction: column; align-items: center; gap: 20px; - min-height: 100vh; + min-height: 100dvh; width: 100%; } From 23cc3c035a3bb9fd85e8ac968a5ca0ba4dd2b1b9 Mon Sep 17 00:00:00 2001 From: Navneeth Mahadevan Date: Wed, 24 Jun 2026 20:40:15 +0530 Subject: [PATCH 2/2] chore: overflow region at bottom --- src/styles/main_body.css | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/styles/main_body.css b/src/styles/main_body.css index 88413cb..1598df7 100644 --- a/src/styles/main_body.css +++ b/src/styles/main_body.css @@ -73,6 +73,7 @@ body { /* Section styling + dividers */ section:not(#footer-new) { min-height: 100dvh; + scroll-margin-top: 120px; display: flex; justify-content: center; align-items: center; @@ -119,10 +120,11 @@ section:not(#footer-new) { } /* Sections smaller */ - section { + section:not(#footer-new) { font-size: 1.8rem; padding: 2rem 1rem; min-height: 100dvh; + scroll-margin-top: 80px; } }