:root {
    /*
     * Minimal dark: #111 / #222 hex scheme
     */
    --font-sans: Inter, system-ui, sans-serif;
    --background: #111;
    --foreground: #eee;
    --muted: #222;
    --muted-foreground: #aaa;
    --border: #333;
    --ring: #555;

    --accent: #b5b5b5;
    --accent-foreground: #eee;

    /* Type Scale — Based on 1rem (16px) base */
    --font-size-xs: 0.75rem;     /* 12px */
    --font-size-sm: 0.8125rem;  /* 13px */
    --font-size-base: 0.9375rem; /* 15px - base */
    --font-size-lg: 1rem;        /* 16px */
    --font-size-xl: 1.0625rem;   /* 17px */
    --font-size-2xl: 1.1875rem;  /* 19px */
    --font-size-3xl: 1.375rem;   /* 22px */
    --font-size-4xl: 1.625rem;   /* 26px */
    --font-size-5xl: 2rem;       /* 32px */
    --font-size-6xl: 2.5rem;     /* 40px */
    --font-size-7xl: 3rem;       /* 48px */
    --font-size-8xl: 3.5rem;     /* 56px */

    /* Spacing Scale — more generous, Linear/Apple-inspired */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 40px;
    --spacing-2xl: 64px;
    --spacing-3xl: 96px;
    --spacing-4xl: 128px;
}

@supports (font-variation-settings: normal) {
    :root {
        --font-sans: InterVariable, system-ui, sans-serif;
    }
}

* {
    box-sizing: border-box;
}

img, video, iframe {
    max-width: 100%;
}

/* Skip Link */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--foreground);
    color: var(--background);
    padding: var(--spacing-sm) var(--spacing-md);
    text-decoration: none;
    font-weight: 600;
    z-index: 1000;
    border-radius: 4px;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: var(--spacing-md);
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Grid System */
.grid {
    display: grid;
    width: 100%;
    gap: var(--spacing-lg);
}

.grid-cols-1 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
}

.grid-cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* Grid gap utilities (match spacing scale) */
.grid.gap-sm { gap: var(--spacing-sm); }
.grid.gap-md { gap: var(--spacing-md); }
.grid.gap-lg { gap: var(--spacing-lg); }
.grid.gap-xl { gap: var(--spacing-xl); }
.grid.gap-2xl { gap: var(--spacing-2xl); }

@media (max-width: 768px) {
    .grid-cols-2,
    .grid-cols-3 {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }

    .grid.gap-xl,
    .grid.gap-2xl {
        gap: var(--spacing-2xl);
    }
}

html {
    width: 100%;
    min-height: 100%;
    overflow-x: clip;
    background-color: var(--background);
    position: relative;
    font-size: 16px;
    line-height: 1.5;
    scroll-behavior: smooth;
    scrollbar-gutter: stable;
}

body {
    --content-max-width: 40rem;
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    font-family: var(--font-sans);
    background-color: var(--background);
    color: var(--muted-foreground);
    text-align: left;
    margin: 0;
    padding: 0;
    align-items: center;
    justify-content: flex-start;
    padding-top: var(--spacing-xl);
    font-size: var(--font-size-base);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Navigation */
.nav {
    width: 100%;
    max-width: var(--content-max-width);
    padding: 0;
    box-sizing: border-box;
    margin: 0 auto var(--spacing-2xl) auto;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-lg);
}

.nav-photo {
    display: flex;
    align-items: center;
    text-decoration: none;
    flex-shrink: 0;
}

.nav-photo-img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--border);
    filter: contrast(1.2) brightness(0.9);
}

.nav-links {
    display: flex;
    gap: var(--spacing-lg);
    align-items: baseline;
}

/* Nav: inactive muted, active and hover foreground */
.nav .nav-link {
    display: inline-block;
    padding: 0;
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--muted-foreground);
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.nav .nav-link:hover {
    color: var(--foreground);
}

.nav .nav-link.active,
.nav .nav-link.active:visited {
    color: var(--foreground);
    font-weight: 600;
}

.nav .nav-link:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Archive / notes filters — same style as nav links */
.notes-filters-wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--spacing-lg);
}

.archive-filters {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-lg);
    margin-bottom: 0;
}

.notes-filters-wrap .archive-filters {
    margin-bottom: 0;
}

.archive-filter {
    display: inline-block;
    padding: 0;
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--foreground);
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.archive-filter:hover {
    color: var(--muted-foreground);
}

.archive-filter-active,
.archive-filter-active:hover {
    color: var(--foreground);
    font-weight: 600;
}

.archive-filter:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
}

.archive-filter-count {
    font-weight: 400;
    opacity: 0.85;
}

.notes-search-wrap {
    margin-left: auto;
}

.notes-search {
    display: block;
    width: 100%;
    min-width: 180px;
    max-width: 280px;
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: var(--font-size-sm);
    color: var(--foreground);
    background: var(--muted);
    border: 1px solid var(--border);
    border-radius: 6px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.notes-search::placeholder {
    color: var(--muted-foreground);
}

.notes-search:hover {
    border-color: var(--muted-foreground);
}

.notes-search:focus {
    outline: none;
    border-color: var(--ring);
    box-shadow: 0 0 0 2px var(--background), 0 0 0 4px var(--ring);
}

.notes-no-results {
    margin-top: var(--spacing-lg);
}

.section-mb-md {
    margin-bottom: var(--spacing-2xl);
}

.container {
    width: 100%;
    max-width: var(--content-max-width);
    padding: var(--spacing-lg) 0 0;
    box-sizing: border-box;
    background: transparent;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    margin: 0 auto;
}


/* General Section Styles */
.section {
    width: 100%;
    text-align: left;
}

@keyframes enterAnimation {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes pageEnter {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-enter {
    width: 100%;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    opacity: 0;
    animation: pageEnter 0.4s ease-out forwards;
}

.section-fade {
    opacity: 0;
    animation: enterAnimation 0.35s ease forwards;
}

.section-fade:nth-of-type(1) { animation-delay: 0ms; }
.section-fade:nth-of-type(2) { animation-delay: 50ms; }
.section-fade:nth-of-type(3) { animation-delay: 100ms; }
.section-fade:nth-of-type(4) { animation-delay: 150ms; }
.section-fade:nth-of-type(5) { animation-delay: 200ms; }
.section-fade:nth-of-type(6) { animation-delay: 250ms; }
.section-fade:nth-of-type(7) { animation-delay: 300ms; }
.section-fade:nth-of-type(8) { animation-delay: 350ms; }

/* Section Spacing */
.section-mb-sm {
    margin-bottom: var(--spacing-lg);
}

.section-mb-md {
    margin-bottom: var(--spacing-2xl);
}

.section-mb-lg {
    margin-bottom: var(--spacing-xl);
}

/* Heading Hierarchy — shrunk for better balance */
h1, h2, h3, h4, h5, h6 {
    color: var(--foreground);
    font-weight: 600;
    position: relative;
}

/* Anchor links — show on hover */
.heading-anchor {
    margin-left: 0.35em;
    color: var(--muted-foreground);
    text-decoration: none;
    opacity: 0;
    transition: opacity 0.2s ease, color 0.2s ease;
    font-weight: 400;
    font-size: 0.75em;
}

h1:hover .heading-anchor,
h2:hover .heading-anchor,
h3:hover .heading-anchor,
h4:hover .heading-anchor,
h5:hover .heading-anchor,
h6:hover .heading-anchor,
.heading-anchor:focus {
    opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
    .heading-anchor {
        opacity: 1;
    }
}

.heading-anchor:hover {
    color: var(--foreground);
}

/* Anchor icon — plugin may add empty span, we show # */
.heading-anchor .icon {
    display: none;
}

.heading-anchor::after {
    content: '#';
}

/* h1 — Page titles, hero headings */
h1,
.section h1 {
    font-size: var(--font-size-6xl);
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 1.1;
    margin: 0 0 var(--spacing-lg) 0;
    scroll-margin-top: var(--spacing-xl);
}

/* h2 — Major sections */
h2,
.section h2 {
    font-size: var(--font-size-4xl);
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.2;
    margin: var(--spacing-2xl) 0 var(--spacing-lg) 0;
    scroll-margin-top: var(--spacing-xl);
}

h2:first-child,
.section h2:first-child {
    margin-top: 0;
}

/* h3 — Subsections */
h3 {
    font-size: var(--font-size-3xl);
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin: var(--spacing-xl) 0 var(--spacing-md) 0;
    scroll-margin-top: var(--spacing-lg);
}

/* h4 — Sub-subsections */
h4 {
    font-size: var(--font-size-2xl);
    font-weight: 600;
    letter-spacing: -0.015em;
    line-height: 1.35;
    margin: var(--spacing-lg) 0 var(--spacing-md) 0;
    scroll-margin-top: var(--spacing-lg);
}

/* h5 — Minor headings */
h5 {
    font-size: var(--font-size-xl);
    font-weight: 600;
    line-height: 1.4;
    margin: var(--spacing-md) 0 var(--spacing-sm) 0;
    scroll-margin-top: var(--spacing-md);
}

/* h6 — Smallest headings */
h6 {
    font-size: var(--font-size-lg);
    font-weight: 600;
    line-height: 1.4;
    margin: var(--spacing-md) 0 var(--spacing-sm) 0;
    scroll-margin-top: var(--spacing-md);
}

/* Text: base is muted; use .text-foreground for descriptions / emphasis */
p {
    color: var(--muted-foreground);
}

ul, ol, li {
    color: var(--muted-foreground);
}

.text {
    font-size: var(--font-size-base);
    color: var(--muted-foreground);
    line-height: 1.6;
    font-weight: 400;
}

.text-lg {
    font-size: var(--font-size-lg);
    line-height: 1.7;
}

.text-muted {
    color: var(--muted-foreground);
}

.text-foreground {
    color: var(--foreground);
}

.highlight {
    color: var(--foreground);
    font-weight: 600;
}

/* Code: minimalist, brutalist — inline and blocks */
.page-content code,
article code,
.changelog-content code {
    font-family: ui-monospace, 'SF Mono', 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
    font-size: 0.85em;
    padding: 0.15em 0.35em;
    background: var(--muted);
    border-radius: 8px;
    color: var(--foreground);
}

.page-content pre,
.changelog-content pre {
    margin: 0 0 var(--spacing-lg) 0;
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--muted);
    border-radius: 8px;
    overflow-x: auto;
    font-family: ui-monospace, 'SF Mono', 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
    font-size: var(--font-size-sm);
    line-height: 1.65;
    color: var(--foreground);
}

.page-content pre code,
.changelog-content pre code {
    padding: 0;
    background: none;
    border: none;
    font-size: inherit;
}

/* Shiki / Astro code blocks (.astro-code): override inline theme with minimalist style */
article pre.astro-code,
.page-content pre.astro-code,
.changelog-content pre.astro-code {
    background: var(--muted) !important;
    color: var(--foreground) !important;
    border-radius: 8px;
    padding: var(--spacing-md) var(--spacing-lg);
}

article pre.astro-code code,
article pre.astro-code .line,
article pre.astro-code span,
.page-content pre.astro-code code,
.page-content pre.astro-code .line,
.page-content pre.astro-code span,
.changelog-content pre.astro-code code,
.changelog-content pre.astro-code .line,
.changelog-content pre.astro-code span {
    color: var(--foreground) !important;
}

/* Links: default foreground; in-p and footer overridden below */
a:any-link {
    color: var(--foreground);
    text-decoration: none;
}

/* Links inside paragraphs: accent color, underlined */
p a:any-link,
.page-content p a:any-link,
article p a:any-link,
.changelog-content p a:any-link {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 0.2em;
    transition: opacity 0.2s ease;
}

p a:any-link:hover,
.page-content p a:any-link:hover,
article p a:any-link:hover,
.changelog-content p a:any-link:hover {
    opacity: 0.85;
    text-decoration: none;
}

/* Outbound (external, off-site) links in paragraphs: diagonal arrow */
p a[href^="http"]:not([href*="djibril.co"])::after,
.page-content p a[href^="http"]:not([href*="djibril.co"])::after,
article p a[href^="http"]:not([href*="djibril.co"])::after,
.changelog-content p a[href^="http"]:not([href*="djibril.co"])::after {
    content: '↗';
    margin-left: 0.2em;
    font-size: 0.85em;
    display: inline-block;
    vertical-align: 0.05em;
    text-decoration: none;
    transition: transform 0.2s ease;
}

p a[href^="http"]:not([href*="djibril.co"]):hover::after,
.page-content p a[href^="http"]:not([href*="djibril.co"]):hover::after,
article p a[href^="http"]:not([href*="djibril.co"]):hover::after,
.changelog-content p a[href^="http"]:not([href*="djibril.co"]):hover::after {
    transform: translate(2px, -2px);
}

/* General Link Styles */
.link {
    color: var(--foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease, opacity 0.2s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.link:hover {
    color: var(--accent);
    opacity: 1;
}

.link:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
}

/* External Link Styles */
.link-external {
    color: var(--foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease, opacity 0.2s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.link-external:hover {
    color: var(--accent);
    opacity: 1;
}

.link-external:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Animated Link Styles */
.link-animated {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    font-size: var(--font-size-base);
    transition: opacity 0.2s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.link-animated:hover {
    opacity: 0.85;
}

.link-arrow {
    display: inline-flex;
    line-height: 1;
}

.link-animated:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
}


@media (prefers-reduced-motion: reduce) {
    .page-enter {
        animation: none;
        opacity: 1;
        transform: none;
    }

    .section-fade {
        animation: none;
        opacity: 1;
    }

    p a[href^="http"]:not([href*="djibril.co"]):hover::after,
    .page-content p a[href^="http"]:not([href*="djibril.co"]):hover::after,
    article p a[href^="http"]:not([href*="djibril.co"]):hover::after,
    .changelog-content p a[href^="http"]:not([href*="djibril.co"]):hover::after {
        transform: none;
    }
}

/* Profile Section Specific */
.profile-section {
    margin-bottom: var(--spacing-xl);
}

.profile-section h1 {
    font-size: var(--font-size-6xl);
    margin: 0 0 var(--spacing-lg) 0;
    font-weight: 600;
    letter-spacing: -0.04em;
    line-height: 1.05;
    color: var(--foreground);
}

.profile-section p {
    margin-bottom: 0;
}

.profile-section .intro-version {
    margin: 0 0 var(--spacing-sm) 0;
}

.intro-links {
    margin: var(--spacing-md) 0 0 0;
    font-size: var(--font-size-sm);
    color: var(--muted-foreground);
}

.intro-links-sep {
    margin: 0 var(--spacing-sm);
    opacity: 0.6;
}

/* Article TOC: left sticky sidebar (layout controlled by ArticleLayout scoped styles) */
/* Footer: muted text and links (scoped so .footer-link wins over a:any-link) */
footer {
    width: 100%;
    max-width: 100%;
    overflow: visible;
    padding: var(--spacing-xl) 0 var(--spacing-xl) 0;
    font-size: var(--font-size-sm);
    color: var(--muted-foreground);
    font-weight: 400;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: var(--content-max-width);
    margin: 0 auto;
    box-sizing: border-box;
}

.footer-copyright {
    text-align: left;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: var(--spacing-lg);
    align-items: baseline;
}

footer .footer-link {
    font-size: var(--font-size-sm);
    color: var(--muted-foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

footer .footer-link:hover {
    color: var(--accent);
}

footer .footer-link:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    width: 100%;
    gap: var(--spacing-md);
}

@media (max-width: 768px) {
    .footer-top {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-sm);
    }

    .footer-copyright {
        text-align: center;
    }

    .footer-links {
        justify-content: center;
    }
}

/* Build Badge */
.build-badge {
    position: fixed;
    bottom: var(--spacing-md);
    right: var(--spacing-md);
    font-size: var(--font-size-xs);
    color: var(--muted-foreground);
    opacity: 0.5;
    font-family: ui-monospace, 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    white-space: nowrap;
    z-index: 100;
    text-decoration: none;
    transition: opacity 0.2s ease, color 0.2s ease;
    cursor: pointer;
    pointer-events: auto;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.build-badge:hover {
    opacity: 0.8;
    color: var(--foreground);
}

.build-badge:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 2px;
    opacity: 1;
}

.build-badge code {
    font-family: inherit;
    font-size: inherit;
    background: transparent;
    padding: 0;
    color: inherit;
}

@media (max-width: 768px) {
    .build-badge {
        display: none;
    }
}



/* General Item/Card Styles */
.item {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    margin-bottom: var(--spacing-xl);
    display: flex;
    gap: var(--spacing-lg);
    align-items: flex-start;
}

.item:last-child {
    margin-bottom: 0;
}

/* General Content Wrapper */
.content {
    flex: 1;
    min-width: 0;
}

/* General Header Styles */
.header {
    margin-bottom: var(--spacing-sm);
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.header h3 {
    font-size: var(--font-size-2xl);
    font-weight: 600;
    margin: 0 0 var(--spacing-xs) 0;
    color: var(--foreground);
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.header h3 a {
    color: inherit;
}

/* General Badge Column */
.badge-col {
    flex-shrink: 0;
    display: block;
    min-width: 100px;
    text-align: right;
    font-size: var(--font-size-base);
    font-weight: 400;
    color: var(--muted-foreground);
    line-height: 1.5;
    white-space: nowrap;
}

/* Portfolio Styles */
.portfolio-item {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s ease;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.portfolio-item:hover {
    opacity: 0.85;
    text-decoration: none;
    color: inherit;
}

.portfolio-item:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
    border-radius: 4px;
}

.portfolio-item-image {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: var(--spacing-md);
    background-color: var(--muted);
    border: 1px solid var(--border);
}

.portfolio-item-image-fallback {
    display: block;
    background-color: var(--muted);
}

/* Inline/content images: rounded corners and border (same as featured images) */
.now-image,
article img,
.page-content img,
.changelog-content img {
    border-radius: 8px;
    border: 1px solid var(--border);
    max-width: 100%;
    height: auto;
}

/* Reset figure user-agent margins (e.g. margin-inline-start: 40px) */
article figure,
.page-content figure,
.changelog-content figure {
    margin: var(--spacing-xl) 0;
    margin-inline-start: 0;
    margin-inline-end: 0;
}

figure img,
article img,
.page-content img,
.changelog-content img {
    margin: var(--spacing-md) 0;
    display: block;
}

article figure img,
.page-content figure img,
.changelog-content figure img {
    margin-top: 0;
}

figure figcaption,
article figcaption,
.page-content figcaption,
.changelog-content figcaption {
    margin-top: var(--spacing-sm);
    margin-bottom: 0;
    font-size: var(--font-size-sm);
    color: var(--muted-foreground);
    text-align: center;
}

.portfolio-item-content {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.portfolio-item h3 {
    font-size: var(--font-size-2xl);
    font-weight: 600;
    margin: 0 0 var(--spacing-xs) 0;
    color: var(--foreground);
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.portfolio-item .text {
    margin: 0;
    font-size: var(--font-size-base);
}

@media (max-width: 768px) {
    .notes-search-wrap {
        display: none;
    }

    .container {
        padding: var(--spacing-xl) var(--spacing-lg) 0;
    }

    .nav {
        padding: 0 var(--spacing-lg);
        margin-bottom: var(--spacing-xl);
    }

    .nav .nav-link.active,
    .nav .nav-link.active:visited {
        color: var(--foreground);
        font-weight: 600;
    }

    body {
        padding-top: var(--spacing-xl);
    }

    .profile-section {
        margin-bottom: var(--spacing-xl);
    }

    /* Responsive heading hierarchy */
    h1,
    .section h1 {
        font-size: var(--font-size-5xl);
    }

    h2 {
        font-size: var(--font-size-3xl);
    }

    h3 {
        font-size: var(--font-size-2xl);
    }

    h4 {
        font-size: var(--font-size-xl);
    }

    h5 {
        font-size: var(--font-size-lg);
    }

    h6 {
        font-size: var(--font-size-base);
    }

    .profile-section h1 {
        font-size: var(--font-size-5xl);
    }

    .item {
        flex-direction: row;
        gap: var(--spacing-md);
        margin-bottom: var(--spacing-xl);
    }

    .badge-col {
        display: none !important;
    }

    footer {
        padding: var(--spacing-xl) 0 var(--spacing-lg) 0;
    }

    .footer-content {
        padding: 0 var(--spacing-lg);
        align-items: stretch;
        gap: var(--spacing-md);
    }

    .footer-copyright {
        text-align: left;
    }

    .footer-links {
        gap: var(--spacing-md);
    }
}

/* 404 Error Page Styles */
body.error-page {
    padding-top: 0;
    justify-content: center;
    align-items: center;
}

/* Shrink content block so body can center it */
body.error-page .page-enter {
    flex: 0 0 auto;
}

body.error-page .error-container {
    flex-grow: 0;
}

.error-container {
    justify-content: center;
    align-items: center;
    padding: var(--spacing-lg);
}

.error-content {
    text-align: center;
    margin: 0;
}

.error-content h1 {
    font-size: var(--font-size-8xl);
    margin: 0 0 var(--spacing-md) 0;
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.2;
    color: var(--foreground);
}

.error-content p {
    font-size: var(--font-size-xl);
    margin: 0 0 var(--spacing-lg) 0;
    line-height: 1.6;
    font-weight: 400;
    color: var(--muted-foreground);
}

.error-content a {
    color: var(--muted-foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    display: inline-block;
}

.error-content a:hover {
    color: var(--foreground);
}

@media (max-width: 768px) {
    .error-content h1 {
        font-size: var(--font-size-7xl);
    }
}