/* ========================================
   Reset & Base
   ======================================== */

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --color-bg: #fdfdfd;
    --color-surface: #ffffff;
    --color-text: #111111;
    --color-text-secondary: #52525b;
    --color-accent: #111111;
    --color-accent-hover: #3f3f46;
    --color-border: #d4d4d8;
    --color-tag-bg: #f4f4f5;
    --color-tag-text: #3f3f46;
    --color-code-bg: #fafafa;

    --color-chromatic-r: #ff3366;
    --color-chromatic-c: #33ccff;

    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    --space-xs: 0.5rem;
    --space-sm: 0.75rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2.5rem;
    --space-2xl: 4rem;
    --space-3xl: 6rem;

    --radius: 4px;
    --radius-lg: 6px;

    --max-width: 640px;
    --max-width-narrow: 640px;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.7;
}

::selection {
    background: var(--color-text);
    color: var(--color-bg);
}

/* ========================================
   Layout
   ======================================== */

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.container-narrow {
    max-width: var(--max-width-narrow);
}

/* ========================================
   Typography
   ======================================== */

h1, h2, h3, h4 {
    line-height: 1.2;
    font-weight: 600;
    letter-spacing: -0.03em;
}

h1 { font-size: 2rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.1rem; }

a {
    color: var(--color-text);
    text-decoration: none;
    transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

a:hover {
    color: var(--color-text-secondary);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   Header
   ======================================== */

.site-header {
    padding: var(--space-xl) 0 0;
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-logo {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-text);
    letter-spacing: -0.02em;
}

.site-logo:hover {
    color: var(--color-text-secondary);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: var(--space-lg);
}

.nav-links a {
    color: var(--color-text-secondary);
    font-size: 0.8125rem;
    font-weight: 400;
    transition: color 0.15s ease;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
    color: var(--color-text);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--space-xs);
    flex-direction: column;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 18px;
    height: 1.5px;
    background: var(--color-text);
    transition: transform 0.2s ease;
}

/* ========================================
   Footer
   ======================================== */

.site-footer {
    padding: var(--space-3xl) 0 var(--space-xl);
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.footer-copy {
    color: var(--color-text-secondary);
    font-size: 0.75rem;
    font-family: var(--font-mono);
}

/* ========================================
   Homepage — Intro
   ======================================== */

.intro {
    padding: var(--space-3xl) 0 var(--space-2xl);
    border-bottom: 1px solid var(--color-border);
}

.hero-name {
    font-family: var(--font-mono);
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.04em;
    margin-bottom: var(--space-xl);
    text-transform: lowercase;
    position: relative;
    display: inline-block;
}

/* Glitch container — sits on top of the real text */
.glitch-wrap {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Two chromatic layers */
.glitch-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
    line-height: inherit;
    overflow: hidden;
}

.glitch-layer::before {
    content: attr(data-text);
    display: block;
}

/* Red channel — shifts left */
.glitch-layer:first-child {
    color: var(--color-chromatic-r);
    mix-blend-mode: multiply;
    opacity: 0;
    animation: glitch-red 8s infinite;
}

/* Cyan channel — shifts right */
.glitch-layer:last-child {
    color: var(--color-chromatic-c);
    mix-blend-mode: multiply;
    opacity: 0;
    animation: glitch-cyan 8s infinite;
}

/* Hover: glitch goes hard */
.hero-name:hover .glitch-layer:first-child {
    animation: glitch-red-intense 0.3s infinite;
}

.hero-name:hover .glitch-layer:last-child {
    animation: glitch-cyan-intense 0.3s infinite;
}

.hero-name:hover {
    animation: glitch-skew 0.3s infinite;
}

/* Ambient glitch — subtle, fires occasionally */
@keyframes glitch-red {
    0%, 92%, 100% {
        opacity: 0;
        transform: none;
        clip-path: none;
    }
    93% {
        opacity: 0.8;
        transform: translate(-3px, 1px);
        clip-path: inset(20% 0 40% 0);
    }
    94% {
        opacity: 0.8;
        transform: translate(2px, -1px);
        clip-path: inset(60% 0 5% 0);
    }
    95% {
        opacity: 0;
    }
    96% {
        opacity: 0.6;
        transform: translate(-1px, 2px);
        clip-path: inset(40% 0 20% 0);
    }
    97% {
        opacity: 0;
    }
}

@keyframes glitch-cyan {
    0%, 92%, 100% {
        opacity: 0;
        transform: none;
        clip-path: none;
    }
    93% {
        opacity: 0.8;
        transform: translate(3px, -1px);
        clip-path: inset(50% 0 10% 0);
    }
    94% {
        opacity: 0.8;
        transform: translate(-2px, 1px);
        clip-path: inset(10% 0 60% 0);
    }
    95% {
        opacity: 0;
    }
    96% {
        opacity: 0.6;
        transform: translate(1px, -2px);
        clip-path: inset(30% 0 30% 0);
    }
    97% {
        opacity: 0;
    }
}

/* Hover glitch — rapid fire chromatic split */
@keyframes glitch-red-intense {
    0% {
        opacity: 0.8;
        transform: translate(-2px, 0);
        clip-path: inset(10% 0 70% 0);
    }
    20% {
        opacity: 0.9;
        transform: translate(3px, 1px);
        clip-path: inset(45% 0 25% 0);
    }
    40% {
        opacity: 0;
    }
    60% {
        opacity: 0.7;
        transform: translate(-4px, -1px);
        clip-path: inset(70% 0 5% 0);
    }
    80% {
        opacity: 0.8;
        transform: translate(1px, 2px);
        clip-path: inset(25% 0 50% 0);
    }
    100% {
        opacity: 0.8;
        transform: translate(-2px, 0);
        clip-path: inset(10% 0 70% 0);
    }
}

@keyframes glitch-cyan-intense {
    0% {
        opacity: 0.8;
        transform: translate(2px, 0);
        clip-path: inset(65% 0 10% 0);
    }
    20% {
        opacity: 0;
    }
    40% {
        opacity: 0.9;
        transform: translate(-3px, -1px);
        clip-path: inset(15% 0 55% 0);
    }
    60% {
        opacity: 0.7;
        transform: translate(4px, 1px);
        clip-path: inset(40% 0 35% 0);
    }
    80% {
        opacity: 0;
    }
    100% {
        opacity: 0.8;
        transform: translate(2px, 0);
        clip-path: inset(65% 0 10% 0);
    }
}

@keyframes glitch-skew {
    0%, 100% { transform: skewX(0); }
    20% { transform: skewX(-1deg); }
    40% { transform: skewX(0.5deg); }
    60% { transform: skewX(-0.3deg); }
    80% { transform: skewX(0.8deg); }
}

/* Reduce motion preference */
@media (prefers-reduced-motion: reduce) {
    .glitch-layer,
    .hero-name:hover .glitch-layer:first-child,
    .hero-name:hover .glitch-layer:last-child,
    .hero-name:hover {
        animation: none;
        opacity: 0;
    }
}

.intro-body {
    display: flex;
    align-items: flex-start;
    gap: var(--space-xl);
}

.intro-photo {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    filter: grayscale(20%);
    transition: filter 0.3s ease;
}

.intro-photo:hover {
    filter: grayscale(0%);
}

.intro-text {
    flex: 1;
    min-width: 0;
}

.intro-bio {
    color: var(--color-text-secondary);
    font-size: 0.9375rem;
    line-height: 1.65;
}

.intro-links {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    margin-top: var(--space-md);
}

.intro-links a {
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    color: var(--color-text-secondary);
    transition: color 0.15s ease;
}

.intro-links a:hover {
    color: var(--color-text);
}

.intro-sep {
    color: var(--color-border);
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    user-select: none;
}

/* ========================================
   Homepage — Ventures
   ======================================== */

.ventures {
    padding: var(--space-2xl) 0;
    border-bottom: 1px solid var(--color-border);
}

.venture-grid {
    display: flex;
    flex-direction: column;
}

.venture-card {
    display: flex;
    align-items: flex-start;
    gap: var(--space-lg);
    padding: var(--space-lg) 0;
    border-top: 1px solid var(--color-border);
    text-decoration: none;
    color: var(--color-text);
    transition: background 0.15s ease;
}

.venture-card:last-child {
    border-bottom: 1px solid var(--color-border);
}

.venture-card:hover {
    color: var(--color-text);
    text-decoration: none;
}

.venture-card:hover .venture-meta {
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}

.venture-index {
    font-family: var(--font-mono);
    font-size: 0.6875rem;
    color: var(--color-chromatic-r);
    flex-shrink: 0;
    padding-top: 0.2em;
    user-select: none;
    transition: color 0.15s ease;
    position: relative;
}

.venture-index::after {
    content: attr(data-index);
    position: absolute;
    top: 0;
    left: 0;
    color: var(--color-chromatic-c);
    transform: translate(1px, -1px);
    opacity: 0.5;
    pointer-events: none;
}

.venture-card:hover .venture-index {
    color: var(--color-text);
}

.venture-card:hover .venture-index::after {
    opacity: 0;
}

.venture-body {
    flex: 1;
    min-width: 0;
}

.venture-name {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    display: inline-block;
    position: relative;
}

/* Chromatic glitch on venture name hover — borrows from the hero effect */
.venture-name::before,
.venture-name::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.venture-name::before {
    color: var(--color-chromatic-r);
    mix-blend-mode: multiply;
}

.venture-name::after {
    color: var(--color-chromatic-c);
    mix-blend-mode: multiply;
}

.venture-card:hover .venture-name::before {
    animation: venture-glitch-r 0.4s steps(2) 1;
}

.venture-card:hover .venture-name::after {
    animation: venture-glitch-c 0.4s steps(2) 1;
}

@keyframes venture-glitch-r {
    0%   { opacity: 0; transform: none; }
    25%  { opacity: 0.8; transform: translate(-2px, 1px); clip-path: inset(20% 0 50% 0); }
    50%  { opacity: 0; }
    75%  { opacity: 0.6; transform: translate(1px, -1px); clip-path: inset(60% 0 10% 0); }
    100% { opacity: 0; transform: none; }
}

@keyframes venture-glitch-c {
    0%   { opacity: 0; transform: none; }
    25%  { opacity: 0; }
    50%  { opacity: 0.8; transform: translate(2px, -1px); clip-path: inset(40% 0 20% 0); }
    75%  { opacity: 0.6; transform: translate(-1px, 1px); clip-path: inset(10% 0 60% 0); }
    100% { opacity: 0; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .venture-card:hover .venture-name::before,
    .venture-card:hover .venture-name::after {
        animation: none;
    }
}

.venture-desc {
    color: var(--color-text-secondary);
    font-size: 0.875rem;
    line-height: 1.55;
    margin-top: 0.25rem;
}

.venture-meta {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--color-text-secondary);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    margin-top: var(--space-xs);
    transition: color 0.15s ease;
}

.venture-card:hover .venture-meta {
    color: var(--color-text);
}

.venture-arrow {
    display: inline-block;
    transition: transform 0.15s ease;
}

.venture-card:hover .venture-arrow {
    transform: translate(2px, -2px);
}

/* ========================================
   Section Labels
   ======================================== */

.section-label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-text-secondary);
    margin-bottom: var(--space-lg);
}

.section-more {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    color: var(--color-text-secondary);
    margin-top: var(--space-sm);
}

.section-more:hover {
    color: var(--color-text);
}

/* ========================================
   Homepage — Post List
   ======================================== */

.recent {
    padding: var(--space-2xl) 0;
}

.post-list {
    list-style: none;
}

.post-list-item {
    border-bottom: 1px solid var(--color-border);
}

.post-list-item:first-child {
    border-top: 1px solid var(--color-border);
}

.post-list-item a {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-lg);
    padding: var(--space-sm) 0;
    color: var(--color-text);
    text-decoration: none;
    transition: color 0.15s ease;
}

.post-list-item a:hover {
    color: var(--color-text-secondary);
}

.post-list-item a:hover .post-list-title {
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}

.post-list-title {
    font-size: 0.9375rem;
    font-weight: 500;
}

.post-list-date {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--color-text-secondary);
    white-space: nowrap;
    flex-shrink: 0;
}

/* ========================================
   Section Headings (legacy)
   ======================================== */

.section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: var(--space-lg);
}

.section-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
}

.section-header a {
    font-size: 0.8125rem;
    font-weight: 400;
    color: var(--color-text-secondary);
}

/* ========================================
   Post Cards (blog listing)
   ======================================== */

.post-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

.post-card {
    border-bottom: 1px solid var(--color-border);
}

.post-card:first-child {
    border-top: 1px solid var(--color-border);
}

.post-card a {
    color: inherit;
    text-decoration: none;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-lg);
    padding: var(--space-sm) 0;
    transition: color 0.15s ease;
}

.post-card a:hover {
    color: var(--color-text-secondary);
}

.post-card-image {
    display: none;
}

.post-card-body {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-lg);
    width: 100%;
}

.post-card-tags {
    display: none;
}

.post-card-title {
    font-size: 0.9375rem;
    font-weight: 500;
    line-height: 1.4;
}

.post-card-excerpt {
    display: none;
}

.post-card-meta {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--color-text-secondary);
    white-space: nowrap;
    flex-shrink: 0;
}

/* ========================================
   Tags
   ======================================== */

.tag {
    display: inline-block;
    padding: 2px 8px;
    background: var(--color-tag-bg);
    color: var(--color-tag-text);
    border-radius: 3px;
    font-size: 0.6875rem;
    font-weight: 500;
    font-family: var(--font-mono);
    text-transform: lowercase;
}

/* ========================================
   Blog Listing
   ======================================== */

.blog-hero {
    padding: var(--space-2xl) 0;
}

.blog-hero h1 {
    font-size: 1.75rem;
    margin-bottom: var(--space-xs);
}

.blog-hero p {
    color: var(--color-text-secondary);
    font-size: 0.9375rem;
}

/* ========================================
   Post Page
   ======================================== */

.post-header {
    padding: var(--space-2xl) 0 var(--space-lg);
}

.post-back {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    font-weight: 400;
    color: var(--color-text-secondary);
    margin-bottom: var(--space-lg);
}

.post-back:hover {
    color: var(--color-text);
}

.post-tags {
    display: flex;
    gap: var(--space-xs);
    margin-bottom: var(--space-md);
    flex-wrap: wrap;
}

.post-header h1 {
    font-size: 2rem;
    margin-bottom: var(--space-md);
}

.post-meta {
    color: var(--color-text-secondary);
    font-size: 0.8125rem;
    font-family: var(--font-mono);
}

.meta-sep {
    margin: 0 var(--space-xs);
    color: var(--color-border);
}

.post-hero {
    margin-bottom: var(--space-xl);
}

.post-hero img {
    width: 100%;
    border-radius: var(--radius-lg);
    max-height: 480px;
    object-fit: cover;
}

.post-body {
    padding-bottom: var(--space-2xl);
}

.post-body h2 {
    margin-top: var(--space-xl);
    margin-bottom: var(--space-md);
}

.post-body h3 {
    margin-top: var(--space-lg);
    margin-bottom: var(--space-sm);
}

.post-body p {
    margin-bottom: var(--space-md);
}

.post-body ul, .post-body ol {
    margin-bottom: var(--space-md);
    padding-left: var(--space-lg);
}

.post-body li {
    margin-bottom: var(--space-xs);
}

.post-body blockquote {
    border-left: 2px solid var(--color-text);
    padding-left: var(--space-lg);
    margin: var(--space-lg) 0;
    color: var(--color-text-secondary);
    font-style: italic;
}

.post-body pre {
    background: var(--color-code-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: var(--space-lg);
    overflow-x: auto;
    margin-bottom: var(--space-md);
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    line-height: 1.65;
}

.post-body code {
    font-family: var(--font-mono);
    font-size: 0.85em;
    background: var(--color-code-bg);
    padding: 2px 5px;
    border-radius: 3px;
}

.post-body pre code {
    background: none;
    padding: 0;
    border-radius: 0;
}

.post-body img {
    border-radius: var(--radius);
    margin: var(--space-lg) 0;
}

.post-body table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: var(--space-md);
}

.post-body th, .post-body td {
    padding: var(--space-sm) var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}

.post-body th {
    font-weight: 600;
    font-size: 0.75rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-secondary);
}

.post-footer {
    padding-top: var(--space-xl);
    border-top: 1px solid var(--color-border);
}

/* ========================================
   Portfolio
   ======================================== */

.portfolio-section {
    padding: var(--space-2xl) 0 0;
}

.portfolio-section h1 {
    font-size: 1.75rem;
    margin-bottom: var(--space-xs);
}

.portfolio-section > .container > p {
    color: var(--color-text-secondary);
    margin-bottom: var(--space-2xl);
    font-size: 0.9375rem;
}

.portfolio-section h2 {
    margin-bottom: var(--space-lg);
}

.portfolio-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: var(--space-2xl);
}

.portfolio-table th,
.portfolio-table td {
    padding: var(--space-sm) var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}

.portfolio-table th {
    font-weight: 500;
    font-size: 0.6875rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-text-secondary);
}

.portfolio-table td {
    font-size: 0.9375rem;
}

.status-live {
    color: #16a34a;
    font-weight: 500;
}

.status-iced {
    color: var(--color-text-secondary);
}

.client-work p {
    margin-bottom: var(--space-md);
    line-height: 1.7;
}

.client-work strong {
    font-weight: 600;
}

/* ========================================
   About & Contact
   ======================================== */

.page-section {
    padding: var(--space-2xl) 0;
}

.page-section h1 {
    font-size: 1.75rem;
    margin-bottom: var(--space-lg);
}

.page-section p {
    margin-bottom: var(--space-md);
    color: var(--color-text-secondary);
    max-width: var(--max-width-narrow);
    font-size: 0.9375rem;
}

/* ========================================
   Contact Links
   ======================================== */

.contact-links {
    list-style: none;
    margin-top: var(--space-lg);
}

.contact-links li {
    border-bottom: 1px solid var(--color-border);
}

.contact-links li:first-child {
    border-top: 1px solid var(--color-border);
}

.contact-links a {
    display: block;
    padding: var(--space-sm) 0;
    font-family: var(--font-mono);
    font-size: 0.9375rem;
    color: var(--color-text);
    transition: color 0.15s ease;
}

.contact-links a:hover {
    color: var(--color-text-secondary);
}

/* ========================================
   Buttons
   ======================================== */

.btn {
    display: inline-block;
    padding: var(--space-sm) var(--space-lg);
    background: var(--color-text);
    color: var(--color-bg);
    border: none;
    border-radius: var(--radius);
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease;
    letter-spacing: 0.01em;
}

.btn:hover {
    background: var(--color-accent-hover);
    color: var(--color-bg);
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 768px) {
    :root {
        --space-xl: 2rem;
        --space-2xl: 3rem;
        --space-3xl: 4rem;
    }

    h1 { font-size: 1.5rem; }
    .post-header h1 { font-size: 1.5rem; }

    .intro-body {
        flex-direction: column;
        gap: var(--space-lg);
    }

    .intro-photo {
        width: 72px;
        height: 72px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        z-index: 100;
        background: var(--color-bg);
        border-bottom: 1px solid var(--color-border);
        flex-direction: column;
        padding: var(--space-lg);
        gap: var(--space-md);
    }

    .nav-links.is-open {
        display: flex;
    }

    .site-header .container {
        position: relative;
    }

    .footer-content {
        text-align: center;
        justify-content: center;
    }

    .portfolio-table {
        font-size: 0.85rem;
    }

    .portfolio-table th:nth-child(4),
    .portfolio-table td:nth-child(4) {
        display: none;
    }

    .post-list-item a {
        flex-direction: column;
        gap: 0.125rem;
    }

    .post-list-date {
        font-size: 0.6875rem;
    }

    .post-card a {
        flex-direction: column;
        gap: 0.125rem;
    }

    .post-card-body {
        flex-direction: column;
        gap: 0.125rem;
    }
}

@media (max-width: 480px) {
    :root {
        --space-xl: 1.5rem;
        --space-2xl: 2rem;
        --space-3xl: 3rem;
    }

    .container {
        padding: 0 var(--space-md);
    }

    h1 { font-size: 1.25rem; }
    .post-header h1 { font-size: 1.25rem; }
    .blog-hero h1 { font-size: 1.35rem; }
    .portfolio-section h1 { font-size: 1.35rem; }

    .hero-name {
        font-size: clamp(1.35rem, 6vw, 1.75rem);
    }

    .ventures,
    .recent {
        padding-top: var(--space-xl);
    }

    .intro-bio {
        font-size: 0.875rem;
    }

    .intro-links {
        flex-wrap: wrap;
        gap: 0.375rem;
    }

    .intro-links a {
        font-size: 0.75rem;
    }

    .intro-sep {
        font-size: 0.75rem;
    }

    .venture-desc {
        font-size: 0.8125rem;
    }

    .venture-name {
        font-size: 0.9375rem;
    }

    .post-list-title {
        font-size: 0.875rem;
    }

    .post-card-title {
        font-size: 0.875rem;
    }

    .portfolio-table th,
    .portfolio-table td {
        padding: var(--space-xs) var(--space-sm);
    }

    .portfolio-table th:nth-child(3),
    .portfolio-table td:nth-child(3) {
        display: none;
    }

    .portfolio-table td {
        font-size: 0.8125rem;
    }

    .page-section h1 {
        font-size: 1.35rem;
    }

    .page-section p {
        font-size: 0.875rem;
    }

    .post-body pre {
        padding: var(--space-md);
        font-size: 0.75rem;
        margin-left: calc(-1 * var(--space-md));
        margin-right: calc(-1 * var(--space-md));
        border-radius: 0;
        border-left: none;
        border-right: none;
    }

    .post-body table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}
