Compare commits
2 Commits
6bfa021fdb
...
c482a91015
Author | SHA1 | Date | |
---|---|---|---|
c482a91015 | |||
dbe803d3bc |
12
index.html
12
index.html
@@ -6,14 +6,13 @@
|
||||
<title>Peter the Baker</title>
|
||||
|
||||
<!-- Optional: system fonts for speed; swap later if you like -->
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link rel="stylesheet" href="/resources/css/index.css" />
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Iceland&display=swap" rel="stylesheet">
|
||||
<link rel="stylesheet" href="/resources/css/index.css" />
|
||||
</head>
|
||||
<body>
|
||||
<a class="skip-link" href="#main">Skip to content</a>
|
||||
|
||||
<header class="site-header">
|
||||
<img class="avatar" src="/resources/img/pb.png" alt="Portrait of Peter Baker" width="200" height="200" class="responsive"/>
|
||||
<img src="/resources/img/pb.png" alt="Portrait of Peter Baker" width="1280" height="372"/>
|
||||
<h1 class="site-title">Peter Baker</h1>
|
||||
</header>
|
||||
|
||||
@@ -26,9 +25,6 @@
|
||||
</nav>
|
||||
|
||||
<main id="main" class="content">
|
||||
<section id="social"><h2>Social</h2><p>Links coming soon.</p></section>
|
||||
<section id="projects"><h2>Projects</h2><p>Stuff I’m building.</p></section>
|
||||
<section id="contact"><h2>Contact</h2><p>Email or DM.</p></section>
|
||||
</main>
|
||||
|
||||
<footer class="site-footer">
|
||||
|
@@ -1,52 +1,62 @@
|
||||
/* Basic reset & layout */
|
||||
/* Reset the default 8px body margin so the image can touch the edges */
|
||||
* { box-sizing: border-box; }
|
||||
html, body { margin: 0; padding: 0; }
|
||||
|
||||
/* Optional base text */
|
||||
body {
|
||||
font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
|
||||
color: #efefef;
|
||||
background: #2c2c2c;
|
||||
font-family: 'Iceland';
|
||||
color: #BF8915;
|
||||
background: #1c1c1c;
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
/* Accessibility: visible focus */
|
||||
:focus-visible { outline: 3px solid #7dd3fc; outline-offset: 2px; }
|
||||
.skip-link {
|
||||
position: absolute; left: -9999px; top: -9999px;
|
||||
}
|
||||
.skip-link:focus { left: 1rem; top: 1rem; background:#111; color:#fff; padding:.5rem .75rem; border-radius:.5rem; }
|
||||
|
||||
/* Header with centered image at the very top */
|
||||
/* Full-bleed banner at the very top */
|
||||
.site-header {
|
||||
display: grid;
|
||||
place-items: center;
|
||||
padding: 3rem 1rem 2rem;
|
||||
gap: .5rem;
|
||||
background: linear-gradient(180deg, rgba(0,0,0,.35), rgba(0,0,0,0));
|
||||
}
|
||||
.site-header .avatar {
|
||||
display: block;
|
||||
border-radius: 50%;
|
||||
border: 4px solid rgba(255,255,255,.15);
|
||||
max-width: 40vw; /* keeps it reasonable on mobile */
|
||||
height: auto;
|
||||
}
|
||||
.site-title {
|
||||
margin: .25rem 0 0;
|
||||
font-size: clamp(1.5rem, 2.5vw + 1rem, 2.5rem);
|
||||
letter-spacing: .5px;
|
||||
}
|
||||
.site-tagline {
|
||||
position: relative; /* allows overlay title */
|
||||
margin: 0;
|
||||
color: #cfcfcf;
|
||||
font-size: clamp(.95rem, .5vw + .8rem, 1.1rem);
|
||||
padding: 0;
|
||||
/* line-height: 0; /* removes stray gap under inline images */
|
||||
}
|
||||
.site-header img {
|
||||
display: block; /* removes inline whitespace */
|
||||
width: 100%; /* full width */
|
||||
height: auto; /* keep aspect ratio */
|
||||
}
|
||||
|
||||
/* Overlay title on the banner (optional; keep if you like this look) */
|
||||
|
||||
.site-title {
|
||||
line-height: 1; /* restore readable line height */
|
||||
position: absolute; /* overlay on the banner */
|
||||
left: 50%;
|
||||
bottom: 8%;
|
||||
transform: translateX(-50%);
|
||||
margin: 0;
|
||||
text-align: center;
|
||||
z-index: 1;
|
||||
|
||||
/* animations */
|
||||
opacity: 1;
|
||||
animation: fadeSlideIn 2s ease-out forwards, goldShine 4s ease-in-out infinite;
|
||||
animation-delay: 0s, 2s;
|
||||
|
||||
/* gold shine */
|
||||
background: linear-gradient(90deg, #b8860b, #ffd700, #b8860b);
|
||||
background-size: 200% auto;
|
||||
-webkit-background-clip: text;
|
||||
background-clip: text;
|
||||
color: transparent;
|
||||
-webkit-text-fill-color: transparent; /* extra safety for WebKit */
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Horizontal nav under header */
|
||||
.site-nav {
|
||||
position: sticky; /* optional: keeps it visible on scroll */
|
||||
position: sticky;
|
||||
top: 0;
|
||||
background: rgba(20,20,20,.75);
|
||||
backdrop-filter: blur(6px);
|
||||
background: rgba(20,20,20,.7);
|
||||
border-top: 1px solid rgba(255,255,255,.07);
|
||||
border-bottom: 1px solid rgba(255,255,255,.07);
|
||||
}
|
||||
@@ -57,38 +67,18 @@ body {
|
||||
display: flex;
|
||||
gap: 1rem;
|
||||
justify-content: center;
|
||||
max-width: 900px;
|
||||
max-width: 1000px;
|
||||
}
|
||||
.site-nav a {
|
||||
display: inline-block;
|
||||
padding: .5rem .75rem;
|
||||
border-radius: .5rem;
|
||||
color: #efefef;
|
||||
text-decoration: none;
|
||||
padding: .5rem .75rem;
|
||||
border-radius: .5rem;
|
||||
}
|
||||
.site-nav a:hover,
|
||||
.site-nav a:focus-visible {
|
||||
.site-nav a:hover, .site-nav a:focus-visible {
|
||||
background: rgba(255,255,255,.08);
|
||||
}
|
||||
|
||||
/* Content */
|
||||
.content {
|
||||
max-width: 900px;
|
||||
margin: 2rem auto;
|
||||
padding: 0 1rem 3rem;
|
||||
}
|
||||
.content h2 { margin-top: 2rem; font-size: 1.35rem; }
|
||||
|
||||
/* Footer */
|
||||
.site-footer {
|
||||
border-top: 1px solid rgba(255,255,255,.07);
|
||||
color: #bdbdbd;
|
||||
padding: 1.5rem 1rem 3rem;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* Responsive tweaks */
|
||||
@media (min-width: 768px) {
|
||||
.site-header { padding: 4rem 1rem 2.25rem; }
|
||||
.site-nav ul { gap: 1.25rem; }
|
||||
}
|
||||
/* Content + footer */
|
||||
.content { max-width: 1000px; margin: 2rem auto; padding: 0 1rem 3rem; }
|
||||
.site-footer { text-align: center; color: #bdbdbd; padding: 1.5rem 1rem 3rem; }
|
||||
|
Reference in New Issue
Block a user