:root {
    --primary: #00ffff;
    --secondary: #ff00ff;
    --background: #000000;
    --text: #ffffff;
    --heading-font: 'Space Grotesk', sans-serif;
    --body-font: 'Inter', sans-serif;
}

body, html {
    margin: 0;
    padding: 0;
    font-family: var(--body-font);
    background-color: var(--background);
    color: var(--text);
    overflow-x: hidden;
    line-height: 1.6;
}

#quantum-field {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background-color: var(--primary);
    border-radius: 50%;
}

#app {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.logo {
    font-family: var(--heading-font);
    font-size: 2em;
    color: var(--primary);
    font-weight: 600;
}

nav a {
    color: var(--text);
    text-decoration: none;
    margin-left: 20px;
    transition: color 0.3s;
    font-family: var(--heading-font);
    font-size: 0.95em;
    letter-spacing: 0.02em;
    font-weight: 500;
}

nav a:hover {
    color: var(--primary);
}

h1, h2, h3 {
    font-family: var(--heading-font);
    letter-spacing: 0.02em;
    font-weight: 600;
}

.content-section {
    margin-bottom: 60px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s, transform 0.5s;
}

.quantum-card {
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--primary);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.3s;
    cursor: pointer;
}

.quantum-card p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 16px;
    letter-spacing: 0.02em;
}

.quantum-card h3 {
    margin-top: 0;
    margin-bottom: 16px;
}

.quantum-card:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.contribution-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.contribution-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.contribution-meta {
    display: flex;
    justify-content: space-between;
    margin: 10px 0;
}

.stars {
    color: var(--primary);
}

.contribution-type {
    background-color: var(--secondary);
    color: var(--background);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.8em;
}

.github-link {
    display: inline-block;
    margin-top: 20px;
}


.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.skill-card {
    padding: 20px;
}

.skill-bar {
    height: 10px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
    margin-top: 10px;
}

.skill-level {
    height: 100%;
    background: linear-gradient(90deg, #00ffff, #ff00ff);
    border-radius: 5px;
    transition: width 1s ease-in-out;
}

#contact {
    text-align: center;
}

.contact-info {
    display: inline-block;
    margin: 10px;
    padding: 10px;
    border: 1px solid var(--secondary);
    border-radius: 5px;
    transition: all 0.3s;
}

.contact-info a {
    text-decoration: none;
    color: inherit;
}


.contact-info:hover {
    background-color: var(--secondary);
    color: var(--background);
}

.newsletter-card {
    text-align: center;
    padding: 40px;
    background: linear-gradient(45deg, rgba(0, 255, 255, 0.1), rgba(255, 0, 255, 0.1));
}

.newsletter-form {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

#email-input {
    padding: 10px;
    font-size: 16px;
    border: 2px solid #00ffff;
    background-color: rgba(0, 0, 0, 0.7);
    color: #fff;
    border-radius: 5px 0 0 5px;
    width: 300px;
}

#email-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-form .quantum-button {
    border-radius: 0 5px 5px 0;
}

.quantum-button {
    cursor: pointer;
}

.quantum-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    animation: quantumFadeIn 0.3s;
}

.quantum-modal-content {
    background-color: var(--background);
    border: 2px solid var(--primary);
    border-radius: 10px;
    position: relative;
    margin: 15% auto;
    padding: 20px;
    width: 70%;
    max-width: 500px;
    text-align: center;
    box-shadow: 0 0 20px var(--primary);
    animation: quantumSlideIn 0.3s;
}

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

@keyframes quantumSlideIn {
    from {transform: translateY(-50px); opacity: 0;}
    to {transform: translateY(0); opacity: 1;}
}


footer {
    text-align: center;
    padding: 40px 20px;
    border-top: 1px solid rgba(0, 255, 255, 0.2);
    margin-top: 80px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.footer-logo {
    font-family: var(--heading-font);
    font-size: 1.5em;
    color: var(--primary);
    margin-bottom: 8px;
}

.footer-tagline {
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 16px;
}

.footer-divider {
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    margin: 0 auto 16px;
}

.copyright {
    font-size: 0.85em;
    color: rgba(255, 255, 255, 0.5);
}

.resume-preview-container {
    display: flex;
    align-items: center;
    gap: 20px;
}

.resume-preview {
    flex: 1;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
}

.resume-iframe {
    width: 130%;
    height: 130%;
    border: none;
    transform: scale(0.75);
    transform-origin: 0 0;
}

.resume-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
}

.quantum-button {
    display: inline-block;
    padding: 10px 20px;
    background: linear-gradient(45deg, #00ffff, #ff00ff);
    color: #000;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.quantum-button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.search-container {
    margin-bottom: 20px;
}

#search-input {
    width: 98%;
    padding: 10px;
    font-size: 16px;
    border: 2px solid #00ffff;
    background-color: rgba(0, 0, 0, 0.7);
    color: #fff;
    border-radius: 5px;
}

#search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}


/* Quantum blog styling */
.quantum-title {
    color: var(--primary);
    text-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

.quantum-meta {
    color: var(--secondary);
    border-bottom: 1px solid var(--secondary);
    padding-bottom: 15px;
    margin-bottom: 30px;
}

.blog-post h2 {
    color: var(--primary);
    margin-top: 30px;
    margin-bottom: 15px;
    font-family: var(--heading-font);
    font-weight: 600;
}

.blog-post h3 {
    color: var(--secondary);
    margin-top: 25px;
    margin-bottom: 10px;
    font-family: var(--heading-font);
    font-weight: 500;
}

.blog-post ul, .blog-post ol {
    margin-left: 20px;
    margin-bottom: 20px;
    font-family: var(--body-font);
}

.blog-post p {
    margin-bottom: 15px;
    line-height: 1.8;
    font-size: 17px;
    font-family: var(--body-font);
    letter-spacing: 0.015em;
}

.blog-post a {
    color: var(--primary);
    text-decoration: none;
    border-bottom: 1px dotted var(--primary);
    transition: color 0.3s, border-color 0.3s;
}

.blog-post a:hover {
    color: var(--secondary);
    border-color: var(--secondary);
}

.blog-post code {
    background-color: rgba(0, 255, 255, 0.1);
    padding: 2px 5px;
    border-radius: 3px;
    font-family: 'Roboto Mono', monospace;
}

.blog-post pre {
    background-color: rgba(0, 0, 0, 0.5);
    border-left: 3px solid var(--primary);
    padding: 15px;
    overflow-x: auto;
    margin-bottom: 20px;
}

.blog-post blockquote {
    border-left: 3px solid var(--secondary);
    padding-left: 15px;
    margin-left: 0;
    font-style: italic;
    color: rgba(255, 255, 255, 0.8);
}

.section-subtitle {
    font-family: var(--body-font);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1em;
    margin-top: -10px;
    margin-bottom: 30px;
    text-align: center;
}

@media (max-width: 768px) {
    .section-subtitle {
        font-size: 0.95em;
        margin-bottom: 24px;
    }
}



/* Editorial redesign for writing pages */
.editorial-page {
    --editorial-bg: #1d1d1b;
    --editorial-surface: #242421;
    --editorial-text: #f1f0ea;
    --editorial-muted: #9b9990;
    --editorial-soft: #c7c2b7;
    --editorial-rule: #3c3b36;
    --editorial-accent: #e8e0d0;
    min-height: 100vh;
    margin: 0;
    background: var(--editorial-bg);
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: 19px;
    line-height: 1.75;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

.editorial-page * { box-sizing: border-box; }
.editorial-page a { color: inherit; }

.editorial-nav {
    width: min(948px, calc(100% - 48px));
    margin: 0 auto;
    padding: 34px 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    font-family: 'Inter', system-ui, sans-serif;
}

.editorial-brand,
.editorial-nav nav a {
    color: var(--editorial-muted);
    text-decoration: none;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    transition: color 180ms ease;
}

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

.editorial-nav nav { display: flex; align-items: center; gap: 22px; }

.article-shell,
.blog-index-shell {
    width: min(948px, calc(100% - 48px));
    margin: 0 auto;
}

.article-post { padding: 16px 0 72px; }

.article-kicker {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 30px;
    color: #85837c;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.18em;
    line-height: 1.2;
    text-transform: uppercase;
}

.article-kicker span {
    width: 36px;
    height: 1px;
    background: #77756f;
    display: inline-block;
}

.article-post h1,
.blog-index-hero h1 {
    max-width: 820px;
    margin: 0;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(2.05rem, 3.1vw, 2.75rem);
    font-weight: 700;
    letter-spacing: -0.035em;
    line-height: 1.06;
}

.blog-index-hero h1 {
    font-size: clamp(1.9rem, 2.8vw, 2.35rem);
    letter-spacing: -0.03em;
}

.article-subtitle,
.blog-index-hero p {
    max-width: 760px;
    margin: 22px 0 0;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.1rem, 1.65vw, 1.38rem);
    font-style: italic;
    line-height: 1.45;
}

.blog-index-hero p {
    max-width: 660px;
    margin-top: 18px;
    font-size: clamp(1rem, 1.25vw, 1.12rem);
    line-height: 1.48;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    margin: 34px 0 0;
    color: #9a9891;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
}

.article-meta span:not(:last-child)::after {
    content: '•';
    margin-left: 22px;
    color: #696760;
}

.article-rule {
    border: 0;
    border-top: 1px solid var(--editorial-rule);
    margin: 38px 0 46px;
}

.article-content { max-width: 930px; }

.article-content p,
.article-content li {
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.05rem, 1.45vw, 1.22rem);
    line-height: 1.68;
    letter-spacing: -0.012em;
}

.article-content p { margin: 0 0 24px; }

.article-content h1,
.article-content h2,
.article-content h3 {
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.12;
}

.article-content h1 { font-size: clamp(1.75rem, 2.9vw, 2.25rem); margin: 48px 0 18px; }
.article-content h2 { font-size: clamp(1.55rem, 2.4vw, 1.95rem); margin: 42px 0 16px; }
.article-content h3 { font-size: clamp(1.3rem, 2vw, 1.58rem); margin: 34px 0 14px; }

.article-content ul,
.article-content ol { margin: 0 0 24px 1.25em; padding: 0; }
.article-content li { margin: 8px 0; padding-left: 0.1em; }
.article-content strong { font-weight: 700; color: #ffffff; }
.article-content em { color: var(--editorial-soft); }

.article-content a {
    color: var(--editorial-text);
    text-decoration-color: #77756f;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.16em;
}

.article-content blockquote {
    margin: 42px 0;
    padding-left: 28px;
    border-left: 1px solid #68665f;
    color: var(--editorial-soft);
    font-style: italic;
}

.article-content code {
    background: #2a2926;
    border: 1px solid #3b3934;
    border-radius: 5px;
    color: #f7efe0;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.78em;
    padding: 0.08em 0.3em;
}

.article-content pre {
    overflow-x: auto;
    margin: 42px 0;
    padding: 22px;
    background: #141412;
    border: 1px solid var(--editorial-rule);
    border-radius: 12px;
}

.article-content pre code { background: transparent; border: 0; padding: 0; font-size: 0.95rem; }

.blog-index-hero {
    padding: 32px 0 30px;
}

.writing-search {
    margin: 26px 0 12px;
    position: relative;
    display: grid;
    gap: 10px;
    font-family: 'Inter', system-ui, sans-serif;
}

.writing-search label {
    color: var(--editorial-muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.editorial-page .writing-search input,
.editorial-page #search-input {
    width: 100%;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--editorial-text);
    font: 600 15px/1.2 'Inter', system-ui, sans-serif;
    outline: none;
    padding: 8px 0 10px;
    box-shadow: none;
}

.editorial-page .writing-search input::placeholder,
.editorial-page #search-input::placeholder {
    color: #6f6d66;
}

.editorial-page .writing-search input:focus,
.editorial-page #search-input:focus {
    border-color: #8a877e;
}

.writing-list { padding: 18px 0 64px; }

.writing-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    padding: 26px 0;
    border-bottom: 1px solid var(--editorial-rule);
    text-decoration: none;
}

.writing-item-meta {
    color: #85837c;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.writing-item h2 {
    max-width: 720px;
    margin: 0 0 8px;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.35rem, 2vw, 1.72rem);
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.14;
    transition: color 180ms ease;
}

.writing-item p {
    max-width: 680px;
    margin: 0;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(0.96rem, 1.18vw, 1.06rem);
    line-height: 1.55;
}

.writing-item-meta {
    min-width: 130px;
    padding-top: 3px;
    display: grid;
    gap: 8px;
    text-align: right;
}

.writing-item:hover h2 { color: #ffffff; }
.writing-item:last-child { border-bottom: 0; }
.writing-item.is-hidden { display: none; }

.misc-list {
    padding: 18px 0 72px;
}

.misc-list-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    align-items: start;
    padding: 34px 0;
    border-bottom: 1px solid var(--editorial-rule);
    text-decoration: none;
}

.misc-list-item h2 {
    margin: 0 0 10px;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.65rem, 3vw, 2.35rem);
    font-weight: 700;
    letter-spacing: -0.035em;
    line-height: 1.08;
}

.misc-list-item p {
    max-width: 680px;
    margin: 0;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1rem, 1.45vw, 1.15rem);
    line-height: 1.5;
}

.misc-list-item > span {
    color: #85837c;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.misc-list-item:hover h2 {
    color: #ffffff;
}

.misc-list-item:last-child,
.library-item:last-child,
.photo-category:last-child {
    border-bottom: 0;
}

.embedded-app {
    margin: 30px 0 18px;
    border: 1px solid var(--editorial-rule);
    background: #11110f;
}

.embedded-app iframe {
    display: block;
    width: 100%;
    height: min(760px, 76vh);
    min-height: 560px;
    border: 0;
}

.app-fallback {
    margin: 0 0 72px;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1rem, 1.35vw, 1.12rem);
    line-height: 1.5;
}

.app-fallback a {
    color: var(--editorial-text);
    text-decoration-color: #77756f;
    text-underline-offset: 0.16em;
}

.ideas-group {
    border-top: 1px solid var(--editorial-rule);
    padding: 34px 0 10px;
}

.ideas-group:last-of-type {
    border-bottom: 0;
    margin-bottom: 54px;
}

.ideas-group-header {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 18px;
    margin-bottom: 20px;
    align-items: baseline;
}

.ideas-group-header span {
    color: var(--editorial-muted);
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.14em;
}

.ideas-group-header h2 {
    margin: 0;
    color: var(--editorial-text);
    font-family: 'Inter', system-ui, sans-serif;
    font-size: clamp(1rem, 1.8vw, 1.22rem);
    letter-spacing: -0.02em;
}

.ideas-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 42px;
    padding-left: 62px;
}

.idea-item {
    border-top: 1px solid var(--editorial-rule);
    padding: 18px 0 20px;
}

.idea-item h3 {
    margin: 0 0 8px;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.18rem, 2vw, 1.55rem);
    font-weight: 500;
    letter-spacing: -0.035em;
}

.idea-item p {
    margin: 0;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(0.98rem, 1.35vw, 1.08rem);
    line-height: 1.48;
}

@media (max-width: 760px) {
    .ideas-list {
        grid-template-columns: 1fr;
        padding-left: 0;
    }

    .ideas-group-header {
        grid-template-columns: 34px 1fr;
    }
}

.library-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    margin: 30px 0;
    border: 1px solid var(--editorial-rule);
    background: var(--editorial-rule);
}

.library-stats div {
    background: var(--editorial-bg);
    padding: 18px;
}

.library-stats strong {
    display: block;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.7rem, 3vw, 2.3rem);
    line-height: 1;
}

.library-stats span,
.book-meta span {
    color: #85837c;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.library-controls {
    display: grid;
    gap: 16px;
    margin: 0 0 16px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--editorial-rule);
}

.editorial-page .library-controls input {
    width: 100%;
    border: 0;
    border-bottom: 1px solid var(--editorial-rule);
    border-radius: 0;
    background: transparent;
    color: var(--editorial-text);
    font: 600 15px/1.2 'Inter', system-ui, sans-serif;
    outline: none;
    padding: 12px 0 16px;
    box-shadow: none;
}

.editorial-page .library-controls input::placeholder {
    color: #6f6d66;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-btn {
    border: 1px solid var(--editorial-rule);
    border-radius: 999px;
    background: transparent;
    color: var(--editorial-muted);
    cursor: pointer;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.12em;
    padding: 9px 13px;
    text-transform: uppercase;
}

.filter-btn:hover,
.filter-btn.active {
    border-color: #8a877e;
    color: var(--editorial-text);
}

.library-list {
    padding-bottom: 72px;
}

.library-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 30px;
    padding: 30px 0;
    border-bottom: 1px solid var(--editorial-rule);
}

.library-item h2 {
    margin: 0 0 6px;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.45rem, 2.5vw, 2rem);
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.book-author {
    margin: 0 0 14px;
    color: #908d85;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.book-description,
.empty-state p,
.photo-category-header p {
    max-width: 720px;
    margin: 0;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1rem, 1.45vw, 1.15rem);
    line-height: 1.5;
}

.book-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 9px;
    padding-top: 5px;
    text-align: right;
}

.empty-state {
    padding: 42px 0 72px;
}

.empty-state h2,
.photo-category-header h2 {
    margin: 0 0 10px;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.45rem, 2.5vw, 2rem);
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.photo-categories {
    padding: 8px 0 72px;
}

.photo-category {
    padding: 34px 0;
    border-bottom: 1px solid var(--editorial-rule);
}

.photo-category-header {
    margin-bottom: 22px;
}

.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
}

.photo-item {
    position: relative;
    min-height: 280px;
    overflow: hidden;
    border: 1px solid var(--editorial-rule);
    background: #141412;
    cursor: pointer;
    padding: 0;
    text-align: left;
}

.photo-item img {
    width: 100%;
    height: 100%;
    min-height: 280px;
    object-fit: cover;
    display: block;
    filter: saturate(0.88) contrast(0.98);
    transition: transform 220ms ease, filter 220ms ease;
}

.photo-item:hover img {
    transform: scale(1.025);
    filter: saturate(1) contrast(1);
}

.photo-caption {
    position: absolute;
    inset: auto 0 0;
    display: grid;
    gap: 2px;
    padding: 44px 14px 14px;
    background: linear-gradient(to top, rgba(0,0,0,0.82), transparent);
    color: var(--editorial-text);
}

.photo-caption strong,
.photo-caption em {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 11px;
    font-style: normal;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.photo-caption em {
    color: #aaa69c;
    font-size: 10px;
}

.photo-viewer {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 28px;
    background: rgba(12, 12, 11, 0.92);
}

.photo-viewer.active {
    display: flex;
}

.viewer-image {
    max-width: min(1100px, 92vw);
    max-height: 88vh;
    object-fit: contain;
    border: 1px solid var(--editorial-rule);
}

.close-viewer {
    position: fixed;
    top: 22px;
    right: 24px;
    border: 1px solid var(--editorial-rule);
    border-radius: 50%;
    width: 42px;
    height: 42px;
    background: var(--editorial-bg);
    color: var(--editorial-text);
    cursor: pointer;
    font-size: 24px;
    line-height: 1;
}

.home-shell {
    width: min(948px, calc(100% - 48px));
    margin: 0 auto;
}

.home-hero {
    padding: 54px 0 46px;
    border-bottom: 1px solid var(--editorial-rule);
}

.home-hero h1 {
    max-width: 860px;
    margin: 0;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(2.15rem, 4vw, 3.15rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1.04;
}

.home-hero p {
    max-width: 760px;
    margin: 24px 0 0;
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.08rem, 1.65vw, 1.28rem);
    font-style: italic;
    line-height: 1.48;
}

.home-about {
    display: grid;
    gap: 24px;
    max-width: 800px;
    padding: 46px 0;
    border-bottom: 1px solid var(--editorial-rule);
}

.home-page {
    min-height: 100vh;
    overflow-y: hidden;
}

.home-page .editorial-nav {
    padding-top: 28px;
    padding-bottom: 18px;
}

.home-plain .home-about {
    gap: 18px;
    padding-top: 36px;
    padding-bottom: 34px;
}

.home-about p,
.home-contact p {
    margin: 0;
    color: var(--editorial-text);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1rem, 1.35vw, 1.13rem);
    line-height: 1.62;
    letter-spacing: -0.012em;
}

.home-about strong {
    color: #f4dfb8;
    font-weight: 700;
}

.home-links {
    display: grid;
    padding: 8px 0 0;
    border-bottom: 1px solid var(--editorial-rule);
}

.home-links a {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 28px;
    padding: 26px 0;
    border-top: 1px solid var(--editorial-rule);
    text-decoration: none;
}

.home-links span,
.home-contact a {
    color: #85837c;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.home-links strong {
    color: var(--editorial-soft);
    font-family: 'Newsreader', Georgia, serif;
    font-size: clamp(1.08rem, 1.6vw, 1.25rem);
    font-weight: 400;
    line-height: 1.4;
}

.home-links a:hover span,
.home-contact a:hover {
    color: var(--editorial-text);
}

.home-contact {
    display: grid;
    gap: 16px;
    padding: 28px 0 0;
}

.home-contact div {
    display: flex;
    flex-wrap: wrap;
    gap: 18px 24px;
}

.home-contact a {
    text-decoration: none;
}

@media (max-width: 720px) {
    .library-stats { grid-template-columns: repeat(2, 1fr); }
    .library-item,
    .misc-list-item { grid-template-columns: 1fr; gap: 12px; }
    .book-meta { align-items: flex-start; text-align: left; }
    .photo-grid { grid-template-columns: 1fr; }
    .home-shell { width: min(100% - 32px, 948px); }
    .home-hero { padding-top: 38px; }
    .home-page { overflow-y: auto; }
    .home-plain .home-about { padding-top: 28px; }
    .home-hero h1 { font-size: clamp(2rem, 10vw, 2.65rem); }
    .home-links a { grid-template-columns: 1fr; gap: 8px; }
}

.editorial-footer {
    width: min(948px, calc(100% - 48px));
    margin: 0 auto;
    padding: 26px 0 44px;
    border-top: 1px solid var(--editorial-rule);
    color: #77756f;
    text-align: left;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

@media (max-width: 720px) {
    .editorial-page { font-size: 17px; }
    .editorial-nav,
    .article-shell,
    .blog-index-shell,
    .editorial-footer { width: min(100% - 32px, 948px); }
    .editorial-nav { align-items: flex-start; flex-direction: column; padding-top: 24px; }
    .editorial-nav nav { gap: 14px; flex-wrap: wrap; }
    .article-kicker { margin-bottom: 22px; font-size: 11px; }
    .article-post h1,
    .blog-index-hero h1 { font-size: clamp(1.95rem, 9vw, 2.45rem); }
    .article-meta { display: grid; gap: 8px; margin-top: 30px; font-size: 14px; }
    .article-meta span::after { display: none; }
    .article-rule { margin: 34px 0 40px; }
    .article-content p,
    .article-content li { font-size: 1.08rem; line-height: 1.65; }
    .writing-item { grid-template-columns: 1fr; gap: 14px; }
    .writing-item-meta { min-width: 0; display: flex; gap: 16px; text-align: left; }
}
