Skip to content

The design language that makes your AI harness better at design.

JavaScript

Polish the site header based on user feedback

Paul Bakausc4dc0feb2305
diff --git a/content/site/partials/header.html b/content/site/partials/header.html
index 1d1e1b4bd..2a9963836 100644
--- a/content/site/partials/header.html
+++ b/content/site/partials/header.html
@@ -1,14 +1,21 @@
<!-- site-header v1 -->
<header class="site-header" data-site-header>
<a href="/" class="site-header-brand" aria-label="Impeccable home">
+ <svg class="site-header-brand-logo" viewBox="0 0 32 32" aria-hidden="true"><rect width="32" height="32" rx="6" fill="#1a1a1a"/><text x="16" y="24" font-family="system-ui, -apple-system, sans-serif" font-size="22" font-weight="500" fill="#f5f3ef" text-anchor="middle">/</text></svg>
<span class="site-header-brand-name">Impeccable</span>
</a>
- <nav class="site-header-nav" aria-label="Primary">
- <a href="/" data-nav="home">Home</a>
- <a href="/skills" data-nav="skills">Skills</a>
- <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
- <a href="/tutorials" data-nav="tutorials">Tutorials</a>
- <a href="/gallery" data-nav="gallery">Gallery</a>
- <a href="https://github.com/pbakaus/impeccable" target="_blank" rel="noopener" data-nav="github">GitHub</a>
- </nav>
+ <div class="site-header-right">
+ <nav class="site-header-nav" aria-label="Primary">
+ <a href="/" data-nav="home">Home</a>
+ <a href="/skills" data-nav="skills">Skills</a>
+ <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
+ <a href="/tutorials" data-nav="tutorials">Tutorials</a>
+ <a href="/gallery" data-nav="gallery">Gallery</a>
+ </nav>
+ <a href="https://github.com/pbakaus/impeccable" class="site-header-github" target="_blank" rel="noopener" aria-label="Impeccable on GitHub — 17k stars">
+ <svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"/></svg>
+ <span class="site-header-github-label">17k</span>
+ <svg class="site-header-github-star" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2l2.76 6.36L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l7.24-.91L12 2z"/></svg>
+ </a>
+ </div>
</header>
diff --git a/public/cheatsheet.html b/public/cheatsheet.html
index 9d60822e6..f49521c72 100644
--- a/public/cheatsheet.html
+++ b/public/cheatsheet.html
@@ -168,16 +168,23 @@
<!-- site-header v1 -->
<header class="site-header" data-site-header>
<a href="/" class="site-header-brand" aria-label="Impeccable home">
+ <svg class="site-header-brand-logo" viewBox="0 0 32 32" aria-hidden="true"><rect width="32" height="32" rx="6" fill="#1a1a1a"/><text x="16" y="24" font-family="system-ui, -apple-system, sans-serif" font-size="22" font-weight="500" fill="#f5f3ef" text-anchor="middle">/</text></svg>
<span class="site-header-brand-name">Impeccable</span>
</a>
- <nav class="site-header-nav" aria-label="Primary">
- <a href="/" data-nav="home">Home</a>
- <a href="/skills" data-nav="skills">Skills</a>
- <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
- <a href="/tutorials" data-nav="tutorials">Tutorials</a>
- <a href="/gallery" data-nav="gallery">Gallery</a>
- <a href="https://github.com/pbakaus/impeccable" target="_blank" rel="noopener" data-nav="github">GitHub</a>
- </nav>
+ <div class="site-header-right">
+ <nav class="site-header-nav" aria-label="Primary">
+ <a href="/" data-nav="home">Home</a>
+ <a href="/skills" data-nav="skills">Skills</a>
+ <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
+ <a href="/tutorials" data-nav="tutorials">Tutorials</a>
+ <a href="/gallery" data-nav="gallery">Gallery</a>
+ </nav>
+ <a href="https://github.com/pbakaus/impeccable" class="site-header-github" target="_blank" rel="noopener" aria-label="Impeccable on GitHub — 17k stars">
+ <svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"/></svg>
+ <span class="site-header-github-label">17k</span>
+ <svg class="site-header-github-star" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2l2.76 6.36L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l7.24-.91L12 2z"/></svg>
+ </a>
+ </div>
</header>
<div class="cheatsheet-page-header">
diff --git a/public/css/sub-pages.css b/public/css/sub-pages.css
index 02f027229..f9c3108e8 100644
--- a/public/css/sub-pages.css
+++ b/public/css/sub-pages.css
@@ -42,20 +42,27 @@ a {
display: flex;
align-items: center;
justify-content: space-between;
- gap: var(--spacing-lg);
- padding: 18px clamp(var(--spacing-md), 4vw, var(--spacing-2xl));
+ gap: var(--spacing-md);
+ padding: 14px clamp(var(--spacing-md), 4vw, var(--spacing-2xl));
background: color-mix(in oklch, var(--color-paper) 94%, transparent);
-webkit-backdrop-filter: saturate(1.4) blur(16px);
backdrop-filter: saturate(1.4) blur(16px);
border-bottom: 1px solid var(--color-mist);
}
+/* Kill any inherited text-decoration from page-level `a` rules. */
+.site-header a,
+.site-header a:hover {
+ text-decoration: none;
+ text-decoration-thickness: 0;
+}
+
.site-header-brand {
display: inline-flex;
align-items: center;
gap: 10px;
font-family: var(--font-display);
- font-size: 1.375rem;
+ font-size: 1.25rem;
font-weight: 600;
letter-spacing: -0.01em;
color: var(--color-ink);
@@ -67,21 +74,38 @@ a {
color: var(--color-accent);
}
+.site-header-brand-logo {
+ width: 26px;
+ height: 26px;
+ border-radius: 6px;
+ flex-shrink: 0;
+}
+
.site-header-brand-name {
display: inline-block;
}
+.site-header-right {
+ display: flex;
+ align-items: center;
+ gap: clamp(var(--spacing-sm), 2vw, var(--spacing-md));
+ min-width: 0;
+}
+
.site-header-nav {
display: flex;
align-items: center;
- gap: clamp(var(--spacing-sm), 2vw, var(--spacing-lg));
+ gap: clamp(var(--spacing-sm), 2vw, var(--spacing-md));
font-family: var(--font-body);
font-size: 0.9375rem;
font-weight: 500;
+ min-width: 0;
}
.site-header-nav a {
position: relative;
+ display: inline-block;
+ white-space: nowrap;
color: var(--color-charcoal);
padding: 4px 0;
transition: color var(--duration-fast) var(--ease-out);
@@ -101,20 +125,68 @@ a {
position: absolute;
left: 0;
right: 0;
- bottom: -6px;
+ bottom: -4px;
height: 2px;
background: var(--color-accent);
border-radius: 2px;
}
-@media (max-width: 720px) {
+/* GitHub star pill — subtle, inviting nudge without shouting */
+.site-header-github {
+ display: inline-flex;
+ align-items: center;
+ gap: 6px;
+ padding: 4px 10px 4px 8px;
+ border-radius: 99px;
+ background: var(--color-cream);
+ border: 1px solid var(--color-mist);
+ font-family: var(--font-mono);
+ font-size: 0.8125rem;
+ font-weight: 500;
+ color: var(--color-charcoal);
+ flex-shrink: 0;
+ transition:
+ background var(--duration-fast) var(--ease-out),
+ border-color var(--duration-fast) var(--ease-out),
+ color var(--duration-fast) var(--ease-out);
+}
+
+.site-header-github svg {
+ width: 14px;
+ height: 14px;
+ flex-shrink: 0;
+}
+
+.site-header-github:hover {
+ background: var(--color-paper);
+ border-color: var(--color-ink);
+ color: var(--color-ink);
+}
+
+.site-header-github-star {
+ color: #f59e0b;
+ width: 12px;
+ height: 12px;
+ flex-shrink: 0;
+}
+
+@media (max-width: 820px) {
.site-header {
- padding: 14px var(--spacing-md);
+ padding: 12px var(--spacing-md);
gap: var(--spacing-sm);
}
.site-header-brand {
- font-size: 1.125rem;
+ font-size: 1.0625rem;
+ }
+
+ .site-header-brand-logo {
+ width: 22px;
+ height: 22px;
+ }
+
+ .site-header-right {
+ gap: var(--spacing-sm);
}
.site-header-nav {
@@ -122,13 +194,33 @@ a {
gap: var(--spacing-sm);
overflow-x: auto;
scrollbar-width: none;
+ -webkit-overflow-scrolling: touch;
+ /* fade the right edge so users see there's more to scroll */
+ mask-image: linear-gradient(to right, black 0%, black calc(100% - 24px), transparent 100%);
+ -webkit-mask-image: linear-gradient(to right, black 0%, black calc(100% - 24px), transparent 100%);
}
.site-header-nav::-webkit-scrollbar {
display: none;
}
- .site-header-nav a[data-nav="github"] {
+ .site-header-nav a[data-nav="home"] {
+ /* Brand already acts as home link on mobile */
+ display: none;
+ }
+
+ .site-header-github {
+ padding: 4px 8px;
+ }
+
+ .site-header-github-label {
+ display: none;
+ }
+}
+
+@media (max-width: 480px) {
+ .site-header-brand-name {
+ /* Logo alone on narrow screens */
display: none;
}
}
diff --git a/public/gallery.html b/public/gallery.html
index c2fcc61e4..730ccd3c0 100644
--- a/public/gallery.html
+++ b/public/gallery.html
@@ -190,16 +190,23 @@
<!-- site-header v1 -->
<header class="site-header" data-site-header>
<a href="/" class="site-header-brand" aria-label="Impeccable home">
+ <svg class="site-header-brand-logo" viewBox="0 0 32 32" aria-hidden="true"><rect width="32" height="32" rx="6" fill="#1a1a1a"/><text x="16" y="24" font-family="system-ui, -apple-system, sans-serif" font-size="22" font-weight="500" fill="#f5f3ef" text-anchor="middle">/</text></svg>
<span class="site-header-brand-name">Impeccable</span>
</a>
- <nav class="site-header-nav" aria-label="Primary">
- <a href="/" data-nav="home">Home</a>
- <a href="/skills" data-nav="skills">Skills</a>
- <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
- <a href="/tutorials" data-nav="tutorials">Tutorials</a>
- <a href="/gallery" data-nav="gallery" aria-current="page">Gallery</a>
- <a href="https://github.com/pbakaus/impeccable" target="_blank" rel="noopener" data-nav="github">GitHub</a>
- </nav>
+ <div class="site-header-right">
+ <nav class="site-header-nav" aria-label="Primary">
+ <a href="/" data-nav="home">Home</a>
+ <a href="/skills" data-nav="skills">Skills</a>
+ <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
+ <a href="/tutorials" data-nav="tutorials">Tutorials</a>
+ <a href="/gallery" data-nav="gallery" aria-current="page">Gallery</a>
+ </nav>
+ <a href="https://github.com/pbakaus/impeccable" class="site-header-github" target="_blank" rel="noopener" aria-label="Impeccable on GitHub — 17k stars">
+ <svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"/></svg>
+ <span class="site-header-github-label">17k</span>
+ <svg class="site-header-github-star" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2l2.76 6.36L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l7.24-.91L12 2z"/></svg>
+ </a>
+ </div>
</header>
<section class="hero">
diff --git a/public/index.html b/public/index.html
index c75846492..b057e6abc 100644
--- a/public/index.html
+++ b/public/index.html
@@ -51,16 +51,23 @@
<!-- site-header v1 -->
<header class="site-header" data-site-header>
<a href="/" class="site-header-brand" aria-label="Impeccable home">
+ <svg class="site-header-brand-logo" viewBox="0 0 32 32" aria-hidden="true"><rect width="32" height="32" rx="6" fill="#1a1a1a"/><text x="16" y="24" font-family="system-ui, -apple-system, sans-serif" font-size="22" font-weight="500" fill="#f5f3ef" text-anchor="middle">/</text></svg>
<span class="site-header-brand-name">Impeccable</span>
</a>
- <nav class="site-header-nav" aria-label="Primary">
- <a href="/" data-nav="home" aria-current="page">Home</a>
- <a href="/skills" data-nav="skills">Skills</a>
- <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
- <a href="/tutorials" data-nav="tutorials">Tutorials</a>
- <a href="/gallery" data-nav="gallery">Gallery</a>
- <a href="https://github.com/pbakaus/impeccable" target="_blank" rel="noopener" data-nav="github">GitHub</a>
- </nav>
+ <div class="site-header-right">
+ <nav class="site-header-nav" aria-label="Primary">
+ <a href="/" data-nav="home" aria-current="page">Home</a>
+ <a href="/skills" data-nav="skills">Skills</a>
+ <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
+ <a href="/tutorials" data-nav="tutorials">Tutorials</a>
+ <a href="/gallery" data-nav="gallery">Gallery</a>
+ </nav>
+ <a href="https://github.com/pbakaus/impeccable" class="site-header-github" target="_blank" rel="noopener" aria-label="Impeccable on GitHub — 17k stars">
+ <svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"/></svg>
+ <span class="site-header-github-label">17k</span>
+ <svg class="site-header-github-star" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2l2.76 6.36L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l7.24-.91L12 2z"/></svg>
+ </a>
+ </div>
</header>
<!-- Sticky Section Nav -->
@@ -76,10 +83,6 @@
<!-- 1. HERO - Combined with Problem Section -->
<section id="hero" class="hero-combined">
- <a href="https://github.com/pbakaus/impeccable" class="github-link" aria-label="View on GitHub">
- <svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"/></svg>
- <span class="github-stars">16k</span>
- </a>
<div class="hero-combined-container">
<!-- Left: Title & Info -->
<div class="hero-combined-left">
diff --git a/public/privacy.html b/public/privacy.html
index 7785d5fdc..1d54d2cea 100644
--- a/public/privacy.html
+++ b/public/privacy.html
@@ -26,16 +26,23 @@
<!-- site-header v1 -->
<header class="site-header" data-site-header>
<a href="/" class="site-header-brand" aria-label="Impeccable home">
+ <svg class="site-header-brand-logo" viewBox="0 0 32 32" aria-hidden="true"><rect width="32" height="32" rx="6" fill="#1a1a1a"/><text x="16" y="24" font-family="system-ui, -apple-system, sans-serif" font-size="22" font-weight="500" fill="#f5f3ef" text-anchor="middle">/</text></svg>
<span class="site-header-brand-name">Impeccable</span>
</a>
- <nav class="site-header-nav" aria-label="Primary">
- <a href="/" data-nav="home">Home</a>
- <a href="/skills" data-nav="skills">Skills</a>
- <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
- <a href="/tutorials" data-nav="tutorials">Tutorials</a>
- <a href="/gallery" data-nav="gallery">Gallery</a>
- <a href="https://github.com/pbakaus/impeccable" target="_blank" rel="noopener" data-nav="github">GitHub</a>
- </nav>
+ <div class="site-header-right">
+ <nav class="site-header-nav" aria-label="Primary">
+ <a href="/" data-nav="home">Home</a>
+ <a href="/skills" data-nav="skills">Skills</a>
+ <a href="/anti-patterns" data-nav="anti-patterns">Anti-Patterns</a>
+ <a href="/tutorials" data-nav="tutorials">Tutorials</a>
+ <a href="/gallery" data-nav="gallery">Gallery</a>
+ </nav>
+ <a href="https://github.com/pbakaus/impeccable" class="site-header-github" target="_blank" rel="noopener" aria-label="Impeccable on GitHub — 17k stars">
+ <svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2C6.477 2 2 6.484 2 12.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0112 6.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.202 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.943.359.309.678.92.678 1.855 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0022 12.017C22 6.484 17.522 2 12 2z"/></svg>
+ <span class="site-header-github-label">17k</span>
+ <svg class="site-header-github-star" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2l2.76 6.36L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l7.24-.91L12 2z"/></svg>
+ </a>
+ </div>
</header>
<main class="privacy-content">