:root {
    --bg: #131210;
    --bg-elevated: #191815;
    --paper: #ece5d8;
    --paper-deep: #d8cfbf;
    --ink: #17140f;
    --text: #f2ede5;
    --text-soft: #d4cdc1;
    --muted: #a29a8c;
    --line: #2c2924;
    --line-strong: #3b3730;
    --accent: #9cc0da;
    --accent-strong: #c4ddee;
    --accent-deep: #6f9ab8;
    --blue-ink: #1c303d;
    --font-display: "Merriweather", Georgia, "Times New Roman", serif;
    --font-serif: "Merriweather", Georgia, "Times New Roman", serif;
    --font-sans: "Source Sans 3", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    --container: 1200px;
    --gutter: clamp(20px, 5vw, 64px);
    --radius: 2px;
    --transition: 180ms ease;
}

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

html {
    scroll-behavior: smooth;
    color-scheme: dark;
    scrollbar-color: var(--line-strong) var(--bg);
    scrollbar-width: thin;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: clip;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    opacity: 1;
    transition: opacity var(--transition);
}

main {
    flex: 1 0 auto;
}

body.page-exiting {
    opacity: 0;
    pointer-events: none;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
}

::selection {
    background: var(--accent);
    color: var(--ink);
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

main:focus,
main:focus-visible {
    outline: none;
}

.nav-inner,
main > section,
footer {
    width: 100%;
    max-width: calc(var(--container) + var(--gutter) * 2);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 200;
    padding: 11px 18px;
    background: var(--paper);
    color: var(--ink);
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius);
    transition: top var(--transition);
}

.skip-link:focus {
    top: 12px;
}

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

.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    min-height: 76px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    color: var(--text);
}

.logo-img {
    display: block;
    width: auto;
    height: 38px;
}

.logo span {
    font-family: var(--font-display);
    font-size: 21px;
    font-weight: 400;
    line-height: 1;
    letter-spacing: 0.22em;
}

.navbar nav {
    display: flex;
    align-items: center;
    gap: clamp(18px, 2.5vw, 32px);
}

.navbar nav a {
    position: relative;
    padding: 8px 0;
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: 0.01em;
    transition: color var(--transition);
}

.navbar nav a::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 1px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition);
}

.navbar nav a:hover {
    color: var(--text);
}

.navbar nav a:hover::after,
.navbar nav a.active::after {
    transform: scaleX(1);
}

.navbar nav a.active {
    color: var(--text);
}

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: transparent;
    color: var(--text);
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 17px;
    height: 1.5px;
    margin: 4px auto;
    background: currentColor;
    transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(5.5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-5.5px) rotate(-45deg);
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
    align-items: center;
    gap: clamp(40px, 6vw, 96px);
    min-height: 620px;
    padding-block: clamp(64px, 9vw, 112px);
}

.hero-text {
    max-width: 600px;
}

.hero h1 {
    max-width: 14ch;
    margin: 20px 0 24px;
    font-family: var(--font-display);
    font-size: clamp(44px, 6vw, 78px);
    font-weight: 400;
    line-height: 1.02;
    letter-spacing: -0.015em;
    text-wrap: balance;
}

.hero h1 span {
    font-style: italic;
    color: var(--accent);
}

.small-title,
.category,
.section-heading p {
    color: var(--muted);
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.small-title {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--text-soft);
}

.small-title::before {
    content: "";
    width: 26px;
    height: 1px;
    background: var(--accent-deep);
}

.description {
    max-width: 48ch;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: clamp(16px, 1.35vw, 17.5px);
    line-height: 1.75;
}

.description + .button,
.description + .text-link {
    margin-top: 32px;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 44px;
    padding: 13px 22px;
    border: 1px solid var(--paper);
    border-radius: var(--radius);
    background: var(--paper);
    color: var(--ink);
    font-family: var(--font-sans);
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition), color var(--transition), transform var(--transition);
}

.button:hover {
    border-color: var(--accent-strong);
    background: var(--accent-strong);
}

.button:active {
    transform: translateY(1px);
}

.text-link {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    margin-top: 24px;
    padding-bottom: 3px;
    border-bottom: 1px solid rgba(156, 192, 218, 0.35);
    color: var(--accent);
    font-family: var(--font-sans);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.02em;
    transition: color var(--transition), border-color var(--transition);
}

.text-link:hover {
    border-color: currentColor;
    color: var(--accent-strong);
}

.hero-cover {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cover {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    aspect-ratio: 2 / 3;
    padding: clamp(20px, 2.4vw, 30px);
    overflow: hidden;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
}

.cover::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 11px;
    width: 1px;
    background: currentColor;
    opacity: 0.22;
}

.cover--hero {
    max-width: 330px;
    box-shadow: 18px 18px 0 rgba(236, 229, 216, 0.06);
}

.cover--ink {
    border-color: #33505f;
    background: var(--blue-ink);
    color: #efe8db;
}

.cover--paper {
    border-color: var(--paper-deep);
    background: var(--paper);
    color: var(--ink);
}

.cover-head,
.cover-body,
.cover-foot {
    padding-left: 14px;
}

.cover-head,
.cover-foot {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-family: var(--font-sans);
    font-size: 9.5px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    opacity: 0.85;
}

.cover-index {
    display: block;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: clamp(46px, 5vw, 62px);
    line-height: 0.9;
}

.cover--paper .cover-index {
    color: var(--accent-deep);
}

.cover-title {
    max-width: 15ch;
    margin-top: 16px;
    font-family: var(--font-display);
    font-size: clamp(18px, 1.9vw, 23px);
    line-height: 1.22;
}

.cover-foot {
    opacity: 0.6;
}

.page-hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    min-height: 0;
    padding-block: clamp(64px, 8vw, 104px);
}

.page-hero .hero-text {
    max-width: 640px;
}

.page-hero--solo {
    display: block;
}

.page-hero--solo .hero-text {
    max-width: 760px;
}

.hero-slider {
    position: relative;
    justify-self: end;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--bg-elevated);
}

.slider-wrapper {
    position: absolute;
    inset: 0;
}

.slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 500ms ease;
}

.slide.active {
    opacity: 1;
}

.slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.94);
}

.slide-caption {
    position: absolute;
    bottom: 18px;
    left: 18px;
    z-index: 3;
    padding: 9px 14px;
    border-radius: var(--radius);
    background: var(--paper);
    color: var(--ink);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid transparent;
    border-radius: var(--radius);
    background: rgba(19, 18, 16, 0.84);
    color: var(--text);
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
    transition: background var(--transition), color var(--transition);
}

.slider-arrow:hover {
    background: var(--paper);
    color: var(--ink);
}

.slider-arrow:active {
    transform: translateY(-50%) scale(0.97);
}

.prev-arrow {
    left: 14px;
}

.next-arrow {
    right: 14px;
}

.slider-dots {
    position: absolute;
    right: 14px;
    bottom: 14px;
    z-index: 3;
    display: flex;
    align-items: center;
    padding: 3px 5px;
    border-radius: var(--radius);
    background: rgba(19, 18, 16, 0.72);
}

.dot {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

.dot::after {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(236, 229, 216, 0.45);
    transition: background var(--transition), transform var(--transition);
}

.dot:hover::after {
    background: var(--paper);
}

.dot[aria-current="true"]::after {
    background: var(--paper);
    transform: scale(1.25);
}

.section {
    padding-block: clamp(72px, 8.5vw, 112px);
    border-top: 1px solid var(--line);
}

section[id] {
    scroll-margin-top: 96px;
}

.section-heading {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.section-heading h2 {
    font-family: var(--font-display);
    font-size: clamp(32px, 3.8vw, 46px);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -0.01em;
    text-wrap: balance;
}

.section-note {
    max-width: 60ch;
    margin-top: 28px;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 16px;
}

.categories-nav {
    padding-block: 28px;
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-filters .button,
.category-filters .text-link {
    min-height: 42px;
    margin: 0;
    padding: 10px 16px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: transparent;
    color: var(--text-soft);
    font-size: 12.5px;
    font-weight: 500;
    line-height: 1.4;
    letter-spacing: 0.02em;
    text-transform: none;
    transition: border-color var(--transition), background var(--transition), color var(--transition);
}

.category-filters .button {
    border-color: var(--paper);
    background: var(--paper);
    color: var(--ink);
    font-weight: 600;
}

.category-filters .button:hover {
    border-color: var(--accent-strong);
    background: var(--accent-strong);
    color: var(--ink);
}

.category-filters .text-link:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.publication {
    display: grid;
    grid-template-columns: minmax(220px, 300px) minmax(0, 1fr);
    align-items: center;
    gap: clamp(32px, 5vw, 72px);
    margin-top: clamp(40px, 5vw, 64px);
}

.publication + .publication {
    margin-top: clamp(32px, 4vw, 48px);
    padding-top: clamp(32px, 4vw, 48px);
    border-top: 1px solid var(--line);
}

.publication-cover {
    width: 100%;
}

.publication-info {
    max-width: 620px;
}

.publication-info h3 {
    max-width: 18ch;
    margin: 10px 0 16px;
    font-family: var(--font-display);
    font-size: clamp(30px, 3.4vw, 40px);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: -0.01em;
}

.publication-info > p:not(.category):not(.publication-author) {
    max-width: 56ch;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 16.5px;
}

.about {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    column-gap: clamp(32px, 6vw, 80px);
    row-gap: 20px;
    padding-block: clamp(80px, 10vw, 120px);
    border-top: 1px solid var(--line);
}

.about .small-title {
    grid-column: 1;
    grid-row: 1;
    align-self: start;
}

.about h2 {
    grid-column: 2;
    grid-row: 1;
    max-width: 20ch;
    font-family: var(--font-display);
    font-size: clamp(36px, 4.4vw, 56px);
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -0.01em;
    text-wrap: balance;
}

.about h2 span {
    color: var(--accent);
    font-style: italic;
}

.about > p:not(.small-title) {
    grid-column: 2;
    grid-row: 2;
    max-width: 60ch;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 17px;
}

.about .text-link {
    grid-column: 2;
    grid-row: 3;
    justify-self: start;
}

.manifest-list {
    margin-top: clamp(40px, 5vw, 64px);
    border-top: 1px solid var(--line);
}

.manifest-item {
    display: grid;
    grid-template-columns: 56px minmax(0, 0.85fr) minmax(0, 1.15fr);
    gap: clamp(20px, 4vw, 56px);
    padding-block: clamp(28px, 3.5vw, 36px);
    border-bottom: 1px solid var(--line);
}

.manifest-num {
    color: var(--accent);
    font-family: var(--font-display);
    font-size: 18px;
    line-height: 1.4;
}

.manifest-item h3 {
    font-family: var(--font-display);
    font-size: clamp(22px, 2.4vw, 27px);
    font-weight: 400;
    line-height: 1.25;
}

.manifest-item p {
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 16px;
}

.authors-intro {
    max-width: 72ch;
    margin-top: 20px;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 16px;
}

.authors-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(28px, 4vw, 48px);
    margin-top: clamp(40px, 5vw, 64px);
}

.author-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding-top: 24px;
    border-top: 1px solid var(--line-strong);
}

.author-monogram {
    margin-bottom: 18px;
    color: var(--accent-deep);
    font-family: var(--font-display);
    font-size: clamp(40px, 4vw, 52px);
    line-height: 1;
    letter-spacing: 0.02em;
}

.author-card h3 {
    margin: 8px 0 10px;
    font-family: var(--font-display);
    font-size: clamp(23px, 2.2vw, 27px);
    font-weight: 400;
    line-height: 1.2;
}

.author-card p:not(.category) {
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 15.5px;
}

.author-card .text-link {
    margin-top: auto;
    padding-top: 22px;
}

.author-index {
    justify-self: end;
    width: 100%;
    max-width: 440px;
    padding: clamp(24px, 3.4vw, 34px);
    border-radius: var(--radius);
    background: var(--paper);
    color: var(--ink);
    box-shadow: 16px 16px 0 rgba(236, 229, 216, 0.06);
}

.author-index-label {
    color: #62594a;
    font-family: var(--font-sans);
    font-size: 10px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.author-index ol {
    margin: 18px 0 22px;
    padding: 0;
    list-style: none;
}

.author-index li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 13px 0;
    border-top: 1px solid #c9bda9;
}

.author-index li:last-child {
    border-bottom: 1px solid #c9bda9;
}

.author-index li span {
    font-family: var(--font-display);
    font-size: clamp(18px, 1.8vw, 21px);
    line-height: 1.2;
}

.author-index li em {
    color: #62594a;
    font-family: var(--font-sans);
    font-size: 9.5px;
    font-style: normal;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.1em;
    text-align: right;
    text-transform: uppercase;
}

.author-index-foot {
    color: #4f473b;
    font-family: var(--font-display);
    font-size: 15.5px;
    font-style: italic;
    line-height: 1.5;
}

.contact-single {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(32px, 6vw, 80px);
}

.contact-block {
    padding-top: 26px;
    border-top: 1px solid var(--line-strong);
}

.contact-block h3 {
    margin: 16px 0 12px;
    font-family: var(--font-display);
    font-size: clamp(21px, 2.5vw, 30px);
    font-weight: 400;
    line-height: 1.25;
}

.email-link {
    padding-bottom: 3px;
    border-bottom: 1px solid var(--line-strong);
    color: var(--text);
    overflow-wrap: anywhere;
    transition: color var(--transition), border-color var(--transition);
}

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

.contact-block > p:not(.small-title) {
    max-width: 46ch;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 15.5px;
}

footer {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: end;
    gap: 32px 48px;
    margin-top: clamp(40px, 6vw, 80px);
    padding-block: 40px;
    border-top: 1px solid var(--line);
}

footer strong {
    display: block;
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: 0.22em;
}

footer p {
    color: var(--muted);
    font-size: 13px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    font-size: 13px;
}

.footer-links a {
    color: var(--text-soft);
    transition: color var(--transition);
}

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

.copyright {
    font-size: 12px;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: var(--line-strong);
}

@media (max-width: 1100px) {
    .publication {
        grid-template-columns: minmax(200px, 260px) minmax(0, 1fr);
    }

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

@media (max-width: 900px) {
    .about {
        grid-template-columns: 180px minmax(0, 1fr);
    }

    .hero {
        gap: 48px;
    }
}

@media (max-width: 860px) {
    .hero,
    .page-hero {
        grid-template-columns: 1fr;
        min-height: 0;
        padding-block: 64px;
    }

    .hero-text,
    .page-hero .hero-text {
        max-width: 640px;
    }

    .hero-cover {
        justify-content: flex-start;
    }

    .author-index {
        justify-self: start;
    }

    .hero-slider {
        justify-self: stretch;
        max-width: 640px;
    }

    .about {
        grid-template-columns: 1fr;
        row-gap: 16px;
    }

    .about .small-title,
    .about h2,
    .about > p:not(.small-title),
    .about .text-link {
        grid-column: 1;
        grid-row: auto;
    }

    .manifest-item {
        grid-template-columns: 40px minmax(0, 1fr);
    }

    .manifest-item p {
        grid-column: 2;
    }

    .contact-single {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    footer {
        grid-template-columns: 1fr 1fr;
    }

    .copyright {
        grid-column: 1 / -1;
    }
}

@media (max-width: 980px) {
    .nav-inner {
        min-height: 68px;
    }

    .nav-toggle {
        display: block;
        margin-left: auto;
    }

    .navbar nav {
        position: absolute;
        top: 100%;
        right: 0;
        left: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 8px var(--gutter) 22px;
        border-bottom: 1px solid var(--line);
        background: var(--bg);
    }

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

    .navbar nav a {
        padding: 15px 0;
        border-bottom: 1px solid var(--line);
        font-size: 15px;
    }

    .navbar nav a::after {
        display: none;
    }

    .navbar nav a.active {
        color: var(--accent);
    }
}

@media (max-width: 700px) {
    .publication {
        grid-template-columns: 1fr;
        gap: 28px;
        align-items: start;
    }

    .publication-cover {
        max-width: 240px;
    }

    .publication-info h3 {
        max-width: 22ch;
    }

    .authors-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

@media (max-width: 600px) {
    .section {
        padding-block: 64px;
    }

    .hero,
    .page-hero {
        padding-block: 52px;
    }

    .hero h1 {
        font-size: clamp(38px, 10vw, 52px);
    }

    .logo span {
        font-size: 18px;
        letter-spacing: 0.18em;
    }

    .logo-img {
        height: 32px;
    }

    .cover--hero {
        max-width: 280px;
    }

    .slide-caption {
        bottom: 12px;
        left: 12px;
        padding: 8px 12px;
        font-size: 10px;
    }

    .slider-dots {
        right: 12px;
        bottom: 12px;
    }

    footer {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .copyright {
        grid-column: auto;
    }
}

@media (max-width: 420px) {
    .publication-cover {
        max-width: 210px;
    }

    .hero h1 {
        font-size: clamp(36px, 10.4vw, 46px);
    }

    .section-heading h2 {
        font-size: 29px;
    }

    .about h2 {
        font-size: 32px;
    }

    .publication-info h3 {
        font-size: 28px;
    }

    .contact-block h3 {
        font-size: 20px;
    }

    .author-index {
        padding: 20px;
    }

    .author-index li {
        flex-direction: column;
        gap: 4px;
    }

    .author-index li em {
        text-align: left;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

@media (forced-colors: active) {
    .cover,
    .author-index,
    .hero-slider {
        border: 1px solid CanvasText;
    }
}


/* Publication page */
.essay-page {
    padding-top: clamp(56px, 7vw, 88px);
    padding-bottom: clamp(72px, 9vw, 112px);
}

.essay-header {
    max-width: 850px;
    margin-inline: auto;
    padding-bottom: clamp(36px, 5vw, 56px);
    border-bottom: 1px solid var(--line);
}

.essay-header h1 {
    margin: 20px 0 18px;
    font-family: var(--font-display);
    font-size: clamp(38px, 5vw, 64px);
    font-weight: 400;
    line-height: 1.08;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.essay-byline {
    color: var(--muted);
    font-size: 14px;
}

.essay-byline span {
    color: var(--text-soft);
}

.essay-description {
    max-width: 62ch;
    margin-top: 22px;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 17px;
    line-height: 1.75;
}

.essay-download {
    margin-top: 26px;
}

.essay-body {
    max-width: 760px;
    margin: clamp(40px, 6vw, 72px) auto 0;
    font-family: var(--font-display);
    font-size: clamp(17px, 1.5vw, 19px);
    line-height: 1.85;
    overflow-wrap: anywhere;
}

.essay-body p {
    margin: 0 0 1.35em;
}

.essay-body .source-title {
    margin: 0 0 1.25em;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: clamp(25px, 3vw, 34px);
    font-weight: 400;
    line-height: 1.2;
}

.essay-body .essay-heading {
    margin: 2.1em 0 0.85em;
    color: var(--text);
    font-family: var(--font-display);
    font-size: clamp(24px, 2.8vw, 31px);
    font-weight: 400;
    line-height: 1.25;
}

.essay-body strong {
    font-weight: 700;
}

.essay-body em {
    font-style: italic;
}

.essay-back {
    max-width: 760px;
    margin: 36px auto 0;
}

.publication-author {
    margin-top: 10px;
    color: var(--muted);
    font-size: 13px !important;
}

@media (max-width: 600px) {
    .essay-header h1 {
        font-size: clamp(34px, 9vw, 46px);
    }

    .essay-body {
        font-size: 17px;
        line-height: 1.78;
    }
}


/* Układ publikacji tekstowych bez makiet okładek książek */
.hero:not(.page-hero) {
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
}
.publication {
    grid-template-columns: minmax(0, 1fr);
}
.publication-info {
    max-width: 780px;
}
.publication-info h3 {
    max-width: 28ch;
}


/* Ilustracja redakcyjna najnowszej publikacji */
.publication.publication--featured {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    align-items: center;
    gap: clamp(28px, 4.5vw, 64px);
}

.publication-image {
    width: 100%;
    aspect-ratio: 3 / 2;
    overflow: hidden;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--bg-elevated);
}

.publication-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.publication--featured .publication-info {
    max-width: 760px;
}

.publication--featured .publication-info h3 {
    max-width: 25ch;
}

@media (max-width: 700px) {
    .publication.publication--featured {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .publication-image {
        aspect-ratio: 3 / 2;
    }
}


/* Wyróżnienie najnowszej publikacji w prawym panelu strony głównej */
.hero-latest-wrap {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-width: 0;
}

.hero-latest {
    display: block;
    width: 100%;
    max-width: 440px;
    overflow: hidden;
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    box-shadow: 16px 16px 0 rgba(236, 229, 216, 0.045);
    transition: border-color var(--transition), transform var(--transition);
}

.hero-latest:hover {
    border-color: var(--accent-deep);
    transform: translateY(-3px);
}

.hero-latest-image {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--bg);
}

.hero-latest-image::after {
    content: "";
    position: absolute;
    inset: 45% 0 0;
    background: linear-gradient(transparent, rgba(19, 18, 16, 0.35));
    pointer-events: none;
}

.hero-latest-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 350ms ease;
}

.hero-latest:hover .hero-latest-image img {
    transform: scale(1.025);
}

.hero-latest-badge {
    position: absolute;
    z-index: 1;
    top: 16px;
    left: 16px;
    padding: 7px 10px;
    border: 1px solid rgba(236, 229, 216, 0.45);
    background: rgba(19, 18, 16, 0.82);
    color: var(--text);
    font-size: 9px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.hero-latest-content {
    padding: clamp(20px, 2.5vw, 28px);
}

.hero-latest-content .category {
    letter-spacing: 0.12em;
}

.hero-latest-content h2 {
    margin-top: 12px;
    font-family: var(--font-display);
    font-size: clamp(22px, 2.35vw, 29px);
    font-weight: 400;
    line-height: 1.18;
    letter-spacing: -0.01em;
}

.hero-latest-link {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    margin-top: 18px;
    padding-bottom: 3px;
    border-bottom: 1px solid rgba(156, 192, 218, 0.35);
    color: var(--accent);
    font-size: 12.5px;
    font-weight: 600;
}

@media (max-width: 860px) {
    .hero:not(.page-hero) {
        grid-template-columns: minmax(0, 1fr);
    }

    .hero-latest-wrap {
        justify-content: flex-start;
    }

    .hero-latest {
        max-width: 640px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-latest,
    .hero-latest-image img {
        transition: none;
    }
}


/* Wyszukiwarka u góry katalogu publikacji */
.publication-search-section {
    padding-top: 10px;
    padding-bottom: 12px;
}

.publication-search-wrap {
    max-width: 760px;
    margin-inline: auto;
}

.publication-search-wrap > label {
    display: block;
    margin-bottom: 10px;
    color: var(--text-soft);
    font-family: var(--font-display);
    font-size: clamp(21px, 2.4vw, 27px);
    line-height: 1.25;
}

.publication-search-control {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 58px;
    padding: 0 16px;
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    transition: border-color var(--transition), background var(--transition);
}

.publication-search-control:focus-within {
    border-color: var(--accent);
    background: #1d1c18;
}

.publication-search-icon {
    color: var(--accent);
    font-family: var(--font-sans);
    font-size: 28px;
    line-height: 1;
}

.publication-search-control input {
    width: 100%;
    min-width: 0;
    min-height: 54px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text);
    font: inherit;
    font-size: 14px;
}

.publication-search-control input::placeholder {
    color: var(--muted);
    opacity: 1;
}

.publication-search-control input::-webkit-search-cancel-button {
    display: none;
}

.publication-search-clear {
    flex: 0 0 auto;
    padding: 8px 0 8px 8px;
    border: 0;
    background: transparent;
    color: var(--accent);
    font: inherit;
    font-size: 12px;
    cursor: pointer;
}

.publication-search-clear:hover {
    color: var(--text);
}

.publication-search-help,
.publication-search-status {
    margin-top: 9px;
    color: var(--muted);
    font-size: 12px;
}

.publication-search-status:empty {
    display: none;
}

.publication-search-empty {
    padding-block: 36px;
    color: var(--text-soft);
    font-family: var(--font-display);
    font-size: clamp(22px, 3vw, 30px);
}

.publication-category[hidden],
.publication[hidden],
.publication-search-empty[hidden],
.publication-search-clear[hidden],
.category-filters [data-category-link][hidden] {
    display: none !important;
}

@media (max-width: 600px) {
    .publication-search-control {
        gap: 9px;
        padding-inline: 12px;
    }

    .publication-search-control input {
        font-size: 13px;
    }
}

/* Cookie consent banner */
.cookie-consent {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 300;
    padding: 20px var(--gutter) calc(20px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    box-shadow: 0 -18px 42px rgba(0, 0, 0, 0.42);
}

.cookie-consent[hidden] {
    display: none !important;
}

.cookie-consent-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px 40px;
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
}

.cookie-consent-content {
    max-width: 720px;
}

.cookie-consent h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
    font-family: var(--font-display);
    font-size: 21px;
    font-weight: 400;
    line-height: 1.2;
}

.cookie-consent-icon {
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
    color: var(--accent);
}

.cookie-consent p {
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.6;
}

.cookie-consent p a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.cookie-consent p a:hover {
    color: var(--accent-strong);
}

.cookie-consent-actions {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.cookie-consent-actions .button {
    min-height: 42px;
    padding: 11px 18px;
    text-transform: none;
    letter-spacing: 0.03em;
}

.cookie-consent-secondary {
    min-height: 42px;
    padding: 11px 18px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: transparent;
    color: var(--text-soft);
    font-family: var(--font-sans);
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition), background var(--transition);
}

.cookie-consent-secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.footer-cookie-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--text-soft);
    font-family: var(--font-sans);
    font-size: 13px;
    line-height: 1.65;
    cursor: pointer;
    transition: color var(--transition);
}

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

@media (max-width: 860px) {
    .cookie-consent-inner {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
}

@media (max-width: 560px) {
    .cookie-consent {
        padding-top: 16px;
        padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    }

    .cookie-consent-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-consent-actions .button,
    .cookie-consent-secondary {
        width: 100%;
    }
}

/* Breadcrumbs */
.breadcrumbs {
    width: 100%;
    max-width: calc(var(--container) + var(--gutter) * 2);
    margin-inline: auto;
    padding: 22px var(--gutter) 0;
    color: var(--muted);
    font-size: 12px;
    letter-spacing: 0.02em;
}

.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    list-style: none;
}

.breadcrumbs li {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.breadcrumbs li + li::before {
    content: "/";
    color: var(--line-strong);
}

.breadcrumbs a {
    transition: color var(--transition);
}

.breadcrumbs a:hover {
    color: var(--accent);
}

.breadcrumbs [aria-current="page"] {
    color: var(--text-soft);
}

/* Legal / privacy page */
.legal-meta {
    margin-top: 18px;
    color: var(--muted);
    font-size: 13px;
}

.legal-page {
    padding-top: clamp(32px, 4vw, 48px);
}

.legal-body {
    max-width: 780px;
    margin-inline: auto;
    font-family: var(--font-serif);
    font-size: 16px;
    line-height: 1.8;
    overflow-wrap: anywhere;
}

.legal-body h2 {
    margin: 2em 0 0.6em;
    color: var(--text);
    font-family: var(--font-display);
    font-size: clamp(24px, 2.6vw, 30px);
    font-weight: 400;
    line-height: 1.25;
}

.legal-body h2:first-of-type {
    margin-top: 0;
}

.legal-body p {
    margin-bottom: 1.1em;
    color: var(--text-soft);
}

.legal-body ul {
    margin: 0 0 1.2em;
    padding-left: 1.4em;
    color: var(--text-soft);
}

.legal-body li {
    margin-bottom: 0.5em;
}

.legal-body a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.legal-body a:hover {
    color: var(--accent-strong);
}

.legal-body strong {
    color: var(--text);
    font-weight: 600;
}

.legal-body code {
    padding: 1px 5px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--bg-elevated);
    color: var(--accent-strong);
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.88em;
}

.legal-table-wrap {
    margin: 0 0 1.4em;
    overflow-x: auto;
}

.legal-body table {
    width: 100%;
    min-width: 520px;
    border-collapse: collapse;
    font-family: var(--font-sans);
    font-size: 13.5px;
    line-height: 1.55;
}

.legal-body th,
.legal-body td {
    padding: 11px 13px;
    border: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.legal-body th {
    background: var(--bg-elevated);
    color: var(--text);
    font-weight: 600;
}

.legal-body td {
    color: var(--text-soft);
}

.legal-body .button {
    text-transform: none;
    letter-spacing: 0.03em;
}


/* ==========================================
   BOKS PO PRAWEJ STRONIE W SEKCJI O NAS
========================================== */

.about-hero-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 420px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--bg-elevated);
    box-shadow: 16px 16px 0 rgba(236, 229, 216, 0.045);
    overflow: hidden;
}

.about-hero-image {
    width: 100%;
    height: 240px;
    overflow: hidden;
}

.about-hero-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.about-hero-quote {
    padding: 24px clamp(20px, 3vw, 28px);
    border-top: 1px solid var(--line-strong);
    background: #191815;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.about-hero-quote .small-title {
    font-size: 10px;
    letter-spacing: 0.14em;
}

.about-hero-quote h2 {
    font-family: var(--font-display);
    font-size: clamp(20px, 2.2vw, 25px);
    font-weight: 400;
    line-height: 1.25;
    color: var(--text);
}

.about-hero-quote .category {
    margin-top: 2px;
    font-size: 10px;
    color: var(--muted);
    letter-spacing: 0.16em;
}

@media (max-width: 860px) {
    .about-hero-card {
        max-width: 100%;
    }
}


/* Account navigation */
.nav-account {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-left: 4px;
    padding-left: 18px;
    border-left: 1px solid var(--line-strong);
}

.nav-account a {
    color: var(--text-soft);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    white-space: nowrap;
}

.nav-account a:hover {
    color: var(--accent);
}

.nav-account .nav-auth-cta {
    padding: 8px 12px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    color: var(--text);
}

.nav-account .nav-auth-cta:hover {
    border-color: var(--accent);
}

.nav-account .nav-user,
.nav-account .nav-editor-link {
    color: var(--accent);
}

.nav-logout {
    margin: 0;
}

.nav-logout-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-family: var(--font-sans);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    cursor: pointer;
    transition: color var(--transition);
}

.nav-logout-button:hover {
    color: var(--accent);
}

@media (max-width: 1080px) and (min-width: 981px) {
    .navbar nav {
        gap: 14px;
    }

    .nav-account {
        gap: 10px;
        padding-left: 12px;
    }
}

@media (max-width: 980px) {
    .nav-account {
        flex-wrap: wrap;
        gap: 14px;
        margin: 12px 0 0;
        padding: 16px 0 0;
        border-top: 1px solid var(--line);
        border-left: 0;
    }

    .navbar nav .nav-account a {
        padding: 0;
        border-bottom: 0;
        font-size: 15px;
    }

    .nav-logout-button {
        font-size: 15px;
    }
}


/* Shared page elements */
.section-heading h1,
.auth-intro h1,
.editor-heading h1 {
    font-family: var(--font-display);
    font-size: clamp(38px, 4.4vw, 56px);
    font-weight: 400;
    line-height: 1.08;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.auth-intro h1 span,
.editor-heading h1 span {
    color: var(--accent);
    font-style: italic;
}

.button--secondary {
    border-color: var(--line-strong);
    background: transparent;
    color: var(--text-soft);
}

.button--secondary:hover {
    border-color: var(--accent);
    background: transparent;
    color: var(--accent);
}

.button--danger {
    border-color: #7a3d32;
    background: transparent;
    color: #e2a08e;
}

.button--danger:hover {
    border-color: #a95245;
    background: #7a3d32;
    color: var(--text);
}

.button--small {
    min-height: 38px;
    padding: 9px 14px;
    font-size: 11.5px;
}

.link-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--accent);
    font-family: var(--font-sans);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.4;
    cursor: pointer;
    transition: color var(--transition);
}

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

.link-button--danger {
    color: #e2a08e;
}

.link-button--danger:hover {
    color: #f1c1b3;
}

.flash-stack {
    width: 100%;
    max-width: calc(var(--container) + var(--gutter) * 2);
    margin-inline: auto;
    padding: 20px var(--gutter) 0;
}

.flash {
    padding: 14px 18px;
    border: 1px solid var(--line-strong);
    border-left: 3px solid var(--accent);
    background: var(--bg-elevated);
    color: var(--text-soft);
    font-size: 14px;
}

.flash + .flash {
    margin-top: 8px;
}

.flash--success {
    border-left-color: #8fb8a6;
}

.flash--warning {
    border-left-color: #d7b36a;
}

.flash--error {
    border-left-color: #d98b7a;
}

.message-page .section-note {
    font-size: 17px;
}

.message-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px 20px;
    margin-top: 28px;
}

.message-actions .text-link {
    margin-top: 0;
}


/* Forms and authentication */
.form-page {
    padding-top: clamp(56px, 7vw, 88px);
}

.auth-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 440px);
    align-items: start;
    gap: clamp(36px, 6vw, 80px);
    max-width: 1080px;
    margin-inline: auto;
}

.auth-layout--single {
    grid-template-columns: minmax(0, 720px);
    justify-content: center;
}

.auth-intro h1 {
    margin: 18px 0 22px;
}

.auth-benefits {
    margin-top: 30px;
    padding: 0;
    list-style: none;
    border-top: 1px solid var(--line);
}

.auth-benefits li {
    position: relative;
    padding: 13px 0 13px 24px;
    border-bottom: 1px solid var(--line);
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 15.5px;
}

.auth-benefits li::before {
    content: "";
    position: absolute;
    top: 23px;
    left: 0;
    width: 10px;
    height: 1px;
    background: var(--accent);
}

.form-card {
    padding: clamp(24px, 3.4vw, 38px);
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--bg-elevated);
    box-shadow: 16px 16px 0 rgba(236, 229, 216, 0.045);
}

.form-card h2 {
    margin-bottom: 22px;
    font-family: var(--font-display);
    font-size: clamp(24px, 2.6vw, 31px);
    font-weight: 400;
    line-height: 1.2;
}

.form-card h1 {
    margin: 16px 0 20px;
    font-family: var(--font-display);
    font-size: clamp(28px, 3.2vw, 40px);
    font-weight: 400;
    line-height: 1.16;
    text-wrap: balance;
}

.form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 20px;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-field > label {
    color: var(--text-soft);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
}

.form-field input,
.form-field textarea,
.form-field select {
    width: 100%;
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 14px;
    line-height: 1.5;
    transition: border-color var(--transition), background var(--transition);
}

.form-field textarea {
    resize: vertical;
}

.form-field select {
    color-scheme: dark;
}

.form-field input[type="file"] {
    padding: 10px;
    color: var(--muted);
    font-size: 13px;
}

.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus {
    border-color: var(--accent);
    outline: 0;
    background: #1d1c18;
}

.form-help {
    color: var(--muted);
    font-size: 12.5px;
    line-height: 1.55;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 4px;
}

.form-actions--split {
    justify-content: space-between;
}

.form-actions--stack {
    flex-direction: column;
    align-items: stretch;
}

.form-actions--stack .button {
    width: 100%;
}

.form-errors {
    margin-bottom: 22px;
    padding: 16px 18px;
    border: 1px solid #75443a;
    border-left: 3px solid #d98b7a;
    background: rgba(122, 61, 50, 0.16);
    color: #f0c9bf;
    font-size: 13.5px;
}

.form-errors p {
    margin-bottom: 8px;
    font-weight: 600;
}

.form-errors ul {
    margin: 0;
    padding-left: 20px;
}

.form-errors li + li {
    margin-top: 4px;
}

.auth-switch {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 13.5px;
}

.auth-switch a {
    color: var(--accent);
    border-bottom: 1px solid rgba(156, 192, 218, 0.35);
}

.auth-switch a:hover {
    color: var(--accent-strong);
}

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

.download-required h1 {
    margin: 16px 0 20px;
    font-family: var(--font-display);
    font-size: clamp(28px, 3.2vw, 40px);
    font-weight: 400;
    line-height: 1.16;
    text-wrap: balance;
}


/* Article catalogue */
.articles-summary {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    max-width: 340px;
    padding: clamp(22px, 3vw, 32px);
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
    box-shadow: 16px 16px 0 rgba(236, 229, 216, 0.045);
}

.articles-summary strong {
    color: var(--accent);
    font-family: var(--font-display);
    font-size: clamp(52px, 6vw, 72px);
    font-weight: 400;
    line-height: 0.95;
}

.articles-summary > span {
    color: var(--muted);
}

.articles-summary .text-link {
    margin-top: 14px;
    align-self: flex-start;
}

.category-filters .is-current {
    border-color: var(--accent);
    color: var(--accent);
}

.article-catalogue .section-heading {
    margin-bottom: 32px;
}

.article-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.article-card {
    display: flex;
    flex-direction: column;
    gap: 22px;
    padding: clamp(22px, 3vw, 32px);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--bg-elevated);
    transition: border-color var(--transition), transform var(--transition);
}

.article-card:hover {
    border-color: var(--accent-deep);
    transform: translateY(-2px);
}

.article-card h3 {
    max-width: 32ch;
    margin: 10px 0 14px;
    font-family: var(--font-display);
    font-size: clamp(26px, 3vw, 34px);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: -0.01em;
}

.article-card h3 a:hover {
    color: var(--accent);
}

.article-excerpt {
    max-width: 72ch;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 16px;
    line-height: 1.7;
}

.article-card-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
}

.article-card-foot .text-link {
    margin-top: 0;
}

.empty-state {
    margin-top: 32px;
    padding: clamp(28px, 4vw, 44px);
    border: 1px dashed var(--line-strong);
    text-align: left;
}

.empty-state h2,
.empty-state h3 {
    margin-bottom: 10px;
    font-family: var(--font-display);
    font-size: clamp(24px, 2.6vw, 31px);
    font-weight: 400;
    line-height: 1.2;
}

.empty-state p {
    max-width: 58ch;
    margin-bottom: 22px;
    color: var(--muted);
    font-family: var(--font-serif);
    font-size: 16px;
}

.empty-state--compact {
    margin-top: 18px;
    padding: 20px;
}

.download-notice {
    margin: 26px 0;
    padding: clamp(18px, 2.6vw, 24px);
    border: 1px solid var(--accent-deep);
    border-left: 3px solid var(--accent);
    background: rgba(156, 192, 218, 0.08);
}

.download-notice--inline {
    max-width: 860px;
    margin: 24px 0 0;
}

.download-notice p {
    max-width: 68ch;
    color: var(--text-soft);
    font-size: 14px;
}

.download-notice strong {
    color: var(--text);
}

.download-notice-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
    margin-top: 18px;
}

.download-notice-actions .button {
    min-height: 40px;
    padding: 10px 16px;
    font-size: 11.5px;
}

.download-notice-actions .text-link {
    margin-top: 0;
}

.download-notice-actions--stack {
    flex-direction: column;
    align-items: stretch;
}

.download-notice-actions--stack .button {
    width: 100%;
}


/* Article view additions */
.article-meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 18px;
    margin-top: 20px;
    color: var(--muted);
    font-size: 13px;
}

.article-meta-row .text-link {
    margin-top: 0;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    font-family: var(--font-sans);
    font-size: 10.5px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.status-badge--draft {
    border-color: #7f6837;
    color: #e3c781;
}

.status-badge--published {
    border-color: #4d7466;
    color: #a9d5c4;
}

.article-attachments {
    max-width: 850px;
    margin: clamp(36px, 5vw, 56px) auto 0;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
}

.attachments-heading,
.editor-attachments-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
}

.attachments-heading h2,
.editor-attachments-heading h2 {
    margin-top: 8px;
    font-family: var(--font-display);
    font-size: clamp(24px, 2.8vw, 32px);
    font-weight: 400;
    line-height: 1.2;
}

.attachments-count {
    color: var(--muted);
    font-size: 12.5px;
}

.attachment-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.attachment-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px 28px;
    padding: 18px 0;
    border-bottom: 1px solid var(--line);
}

.attachment-item:last-child {
    border-bottom: 0;
}

.attachment-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.attachment-info strong {
    color: var(--text);
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 400;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.attachment-meta {
    color: var(--muted);
    font-size: 12.5px;
    overflow-wrap: anywhere;
}

.attachment-description {
    margin-top: 2px;
    color: var(--text-soft);
    font-size: 13px;
}


/* Account panel */
.account-page .section-heading {
    margin-bottom: 40px;
}

.account-layout {
    display: grid;
    grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.2fr);
    gap: clamp(24px, 4vw, 40px);
}

.account-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: clamp(22px, 3vw, 30px);
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
}

.account-avatar {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 70px;
    height: 70px;
    border: 1px solid var(--accent-deep);
    border-radius: 50%;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: 30px;
    line-height: 1;
    text-transform: uppercase;
}

.account-card h2 {
    margin: 4px 0;
    font-family: var(--font-display);
    font-size: clamp(24px, 2.6vw, 30px);
    font-weight: 400;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.account-email {
    color: var(--muted);
    font-size: 13px;
    overflow-wrap: anywhere;
}

.account-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 28px;
    margin: 0;
    border-top: 1px solid var(--line);
}

.account-details > div {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
}

.account-details dt {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.account-details dd {
    color: var(--text-soft);
    font-family: var(--font-serif);
    font-size: 16px;
}

.account-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 36px;
}

.account-actions form {
    margin: 0;
}

.account-note {
    max-width: 72ch;
    margin-top: 24px;
    color: var(--muted);
    font-size: 13px;
}


/* Editor panel */
.editor-page {
    padding-top: clamp(56px, 7vw, 84px);
}

.editor-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px 48px;
    margin-bottom: 36px;
}

.editor-heading .description {
    margin-top: 18px;
}

.editor-heading h1 {
    margin: 16px 0 0;
}

.editor-heading-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.editor-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 36px;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.editor-stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 20px 22px 20px 0;
}

.editor-stat + .editor-stat {
    padding-left: 22px;
    border-left: 1px solid var(--line);
}

.editor-stat strong {
    color: var(--accent);
    font-family: var(--font-display);
    font-size: clamp(30px, 3.4vw, 42px);
    font-weight: 400;
    line-height: 1;
}

.editor-stat span {
    color: var(--muted);
    font-size: 12px;
}

/* Article view statistics */
.stats-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-bottom: 22px;
    border: 1px solid var(--line);
    background: var(--bg-elevated);
}

.stats-card {
    padding: 22px 24px;
}

.stats-card + .stats-card {
    border-left: 1px solid var(--line);
}

.stats-card strong {
    display: block;
    color: var(--text);
    font-family: var(--font-display);
    font-size: clamp(28px, 3vw, 38px);
    font-weight: 400;
    line-height: 1;
}

.stats-card--featured strong {
    color: var(--accent);
}

.stats-card span {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-size: 12px;
}

.stats-card strong.is-updated {
    animation: stats-pop 420ms ease;
}

@keyframes stats-pop {
    0% {
        opacity: 0.4;
        transform: translateY(4px);
    }

    100% {
        opacity: 1;
        transform: none;
    }
}

.stats-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 24px;
    margin-bottom: 12px;
    color: var(--muted);
    font-size: 12.5px;
}

.stats-updated {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.stats-live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #a9d5c4;
    animation: stats-pulse 2.4s ease-out infinite;
}

.stats-page.is-loading .stats-live-dot {
    background: var(--accent);
}

@keyframes stats-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(169, 213, 196, 0.45);
    }

    70% {
        box-shadow: 0 0 0 7px rgba(169, 213, 196, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(169, 213, 196, 0);
    }
}

.stats-table-wrap {
    border-top: 1px solid var(--line-strong);
}

.stats-table {
    width: 100%;
    border-collapse: collapse;
}

.stats-table th {
    padding: 12px 12px 12px 0;
    border-bottom: 1px solid var(--line-strong);
    color: var(--muted);
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-align: left;
    text-transform: uppercase;
}

.stats-table th:nth-child(2),
.stats-table th:nth-child(3) {
    text-align: right;
}

.stats-table td {
    padding: 18px 12px 18px 0;
    border-bottom: 1px solid var(--line);
    vertical-align: middle;
}

.stats-table td:last-child {
    padding-right: 0;
}

.stats-table__article {
    min-width: 0;
}

.stats-table__title {
    display: block;
    font-family: var(--font-display);
    font-size: clamp(18px, 2vw, 22px);
    line-height: 1.25;
}

.stats-table__title a:hover {
    color: var(--accent);
}

.stats-table__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 12px;
    margin-top: 8px;
    color: var(--muted);
    font-size: 12px;
}

.stats-table__views {
    text-align: right;
    white-space: nowrap;
}

.stats-table__views strong {
    display: block;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: clamp(22px, 2.4vw, 28px);
    font-weight: 400;
    line-height: 1;
}

.stats-table__views span {
    color: var(--muted);
    font-size: 11px;
}

.stats-table__share {
    width: 22%;
    min-width: 150px;
}

.stats-share-track {
    height: 6px;
    overflow: hidden;
    background: var(--line);
}

.stats-share-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-deep), var(--accent));
    transition: width 420ms ease;
}

.stats-share-value {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 11.5px;
    text-align: right;
}

.stats-table__last {
    color: var(--muted);
    font-size: 12.5px;
    text-align: right;
    white-space: nowrap;
}

.panel-list {
    display: flex;
    flex-direction: column;
}

.panel-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 20px 32px;
    padding: 26px 0;
    border-top: 1px solid var(--line);
}

.panel-item:last-child {
    border-bottom: 1px solid var(--line);
}

.panel-item-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
    color: var(--muted);
    font-size: 12px;
}

.panel-item h2 {
    margin: 12px 0 8px;
    font-family: var(--font-display);
    font-size: clamp(22px, 2.4vw, 28px);
    font-weight: 400;
    line-height: 1.2;
}

.panel-item h2 a:hover {
    color: var(--accent);
}

.panel-item-dates {
    color: var(--muted);
    font-size: 12.5px;
}

.panel-item-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
    align-self: center;
}

.panel-item-actions form {
    margin: 0;
}

.editor-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 20px;
    margin-bottom: 26px;
    padding: 14px 18px;
    border: 1px solid var(--line);
    background: var(--bg-elevated);
    color: var(--muted);
    font-size: 12.5px;
}

.article-form {
    max-width: 900px;
    gap: 24px;
}

.breadcrumbs--inline {
    width: auto;
    max-width: none;
    margin: 0 0 30px;
    padding: 0;
}

.editor-attachments {
    max-width: 900px;
    margin-top: clamp(44px, 6vw, 70px);
    padding-top: 8px;
}

.upload-form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 18px 24px;
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}

.upload-form .form-field {
    flex: 1 1 420px;
}

.upload-form .form-actions {
    margin: 0;
}

.attachment-editor-list {
    display: flex;
    flex-direction: column;
}

.attachment-editor-item {
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}

.attachment-editor-summary {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 16px;
}

.attachment-editor-summary strong {
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 400;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.attachment-edit-form {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr) auto;
    align-items: end;
    gap: 14px 18px;
}

.attachment-edit-form .form-field {
    gap: 6px;
}

.attachment-edit-form input {
    min-height: 42px;
    padding: 9px 12px;
}

.attachment-editor-actions {
    display: flex;
    align-items: center;
}

.attachment-editor-item > form[data-confirm] {
    margin-top: 12px;
}

.danger-zone {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px 32px;
    max-width: 900px;
    margin-top: 48px;
    padding: 22px 24px;
    border: 1px solid #5d332b;
    background: rgba(122, 61, 50, 0.1);
}

.danger-zone h2 {
    margin-bottom: 6px;
    font-family: var(--font-display);
    font-size: 21px;
    font-weight: 400;
}

.danger-zone p {
    color: var(--muted);
    font-size: 13px;
}

.danger-zone form {
    margin: 0;
}


/* Rich text editor */
.rich-editor-shell {
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: var(--bg);
    transition: border-color var(--transition);
}

.rich-editor-shell:focus-within {
    border-color: var(--accent);
}

.editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 8px;
    border-bottom: 1px solid var(--line);
    background: var(--bg-elevated);
}

.editor-tool {
    min-height: 34px;
    padding: 6px 10px;
    border: 1px solid var(--line-strong);
    border-radius: var(--radius);
    background: transparent;
    color: var(--text-soft);
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 500;
    line-height: 1.2;
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition), background var(--transition);
}

.editor-tool:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.editor-tool--strong {
    font-weight: 700;
}

.editor-tool--italic {
    font-style: italic;
}

.rich-editor {
    min-height: 380px;
    padding: 20px 22px;
    color: var(--text);
    font-family: var(--font-serif);
    font-size: 17px;
    line-height: 1.8;
    outline: 0;
    overflow-wrap: anywhere;
}

.rich-editor:empty::before {
    content: attr(data-placeholder);
    color: var(--muted);
    pointer-events: none;
}

.rich-editor p {
    margin: 0 0 1.1em;
}

.rich-editor h2 {
    margin: 1.4em 0 0.6em;
    color: var(--text);
    font-family: var(--font-display);
    font-size: 28px;
    font-weight: 400;
    line-height: 1.2;
}

.rich-editor h3 {
    margin: 1.3em 0 0.5em;
    color: var(--text);
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 400;
    line-height: 1.25;
}

.rich-editor ul,
.rich-editor ol {
    margin: 0 0 1.1em;
    padding-left: 1.5em;
}

.rich-editor blockquote {
    margin: 0 0 1.1em;
    padding-left: 18px;
    border-left: 2px solid var(--accent-deep);
    color: var(--text-soft);
    font-style: italic;
}

.rich-editor a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}


/* Responsive additions */
@media (max-width: 900px) {
    .auth-layout,
    .account-layout {
        grid-template-columns: 1fr;
    }

    .auth-layout--single {
        max-width: 720px;
    }

    .auth-intro {
        max-width: 720px;
    }

    .account-details {
        max-width: 720px;
    }

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

    .editor-stat:nth-child(odd) {
        padding-left: 0;
        border-left: 0;
    }

    .editor-stat:nth-child(n + 3) {
        border-top: 1px solid var(--line);
    }

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

    .stats-card:nth-child(3) {
        border-top: 1px solid var(--line);
        border-left: 0;
    }

    .stats-card:nth-child(4) {
        border-top: 1px solid var(--line);
    }

    .attachment-edit-form {
        grid-template-columns: 1fr 1fr;
    }

    .attachment-editor-actions {
        grid-column: 1 / -1;
    }
}

@media (max-width: 700px) {
    .form-row {
        grid-template-columns: 1fr;
    }

    .stats-summary {
        grid-template-columns: 1fr;
    }

    .stats-card + .stats-card {
        border-top: 1px solid var(--line);
        border-left: 0;
    }

    .stats-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
    }

    .stats-table,
    .stats-table tbody,
    .stats-table tr,
    .stats-table td {
        display: block;
        width: auto;
    }

    .stats-table tr {
        padding: 18px 0;
        border-bottom: 1px solid var(--line);
    }

    .stats-table td {
        padding: 0;
        border: 0;
        text-align: left;
    }

    .stats-table__views {
        display: flex;
        align-items: baseline;
        gap: 8px;
        margin-top: 12px;
        text-align: left;
    }

    .stats-table__views strong {
        display: inline;
    }

    .stats-table__share {
        width: auto;
        min-width: 0;
        margin-top: 12px;
    }

    .stats-share-value {
        text-align: left;
    }

    .stats-table__last {
        margin-top: 10px;
        text-align: left;
        white-space: normal;
    }

    .editor-stats {
        grid-template-columns: 1fr;
    }

    .editor-stat {
        padding: 16px 0;
    }

    .editor-stat + .editor-stat {
        padding-left: 0;
        border-top: 1px solid var(--line);
        border-left: 0;
    }

    .panel-item {
        grid-template-columns: 1fr;
    }

    .panel-item-actions {
        justify-content: flex-start;
    }

    .attachment-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .attachment-edit-form {
        grid-template-columns: 1fr;
    }

    .account-details {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .form-card {
        padding: 22px 18px;
        box-shadow: 8px 8px 0 rgba(236, 229, 216, 0.045);
    }

    .form-actions--split {
        flex-direction: column;
        align-items: stretch;
    }

    .form-actions--split .button {
        width: 100%;
    }

    .editor-heading {
        align-items: flex-start;
    }

    .editor-heading-actions {
        width: 100%;
    }

    .editor-heading-actions .button {
        flex: 1 1 100%;
    }

    .download-notice-actions .button,
    .download-notice-actions .text-link {
        width: 100%;
    }

    .article-card-foot {
        flex-direction: column;
        align-items: flex-start;
    }

    .rich-editor {
        min-height: 300px;
        padding: 16px;
        font-size: 16px;
    }

    .editor-toolbar {
        gap: 3px;
        padding: 6px;
    }

    .editor-tool {
        padding: 6px 8px;
        font-size: 11.5px;
    }

    .danger-zone {
        padding: 18px;
    }

    .danger-zone .button {
        width: 100%;
    }
}


/* Publication images */
.publication-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.publication-info h3 a:hover {
    color: var(--accent);
}

.article-card-image {
    display: block;
    overflow: hidden;
    border: 1px solid var(--line-strong);
    background: var(--bg);
}

.article-card-image img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 7;
    max-height: 340px;
    object-fit: cover;
    object-position: center;
}

.article-cover {
    max-width: 850px;
    margin: clamp(32px, 5vw, 52px) auto 0;
    overflow: hidden;
    border: 1px solid var(--line-strong);
    background: var(--bg-elevated);
}

.article-cover img {
    display: block;
    width: 100%;
    max-height: 580px;
    object-fit: cover;
    object-position: center;
}

.article-cover figcaption {
    padding: 12px 16px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 12.5px;
}

.article-gallery {
    max-width: 850px;
    margin: clamp(38px, 5vw, 58px) auto 0;
}

.article-gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 22px;
}

.article-gallery-item {
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--bg-elevated);
}

.article-gallery-item img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center;
}

.article-gallery-item figcaption {
    padding: 10px 14px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 12.5px;
}


/* Editor image management */
.editor-images {
    max-width: 900px;
    margin-top: clamp(44px, 6vw, 70px);
    padding-top: 8px;
}

.image-editor-block {
    margin-top: 30px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.image-editor-block h3 {
    margin-bottom: 6px;
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 400;
    line-height: 1.25;
}

.image-editor-item {
    display: grid;
    grid-template-columns: minmax(180px, 230px) minmax(0, 1fr);
    align-items: start;
    gap: 20px 26px;
    padding: 20px 0;
    border-top: 1px solid var(--line);
}

.image-preview {
    overflow: hidden;
    border: 1px solid var(--line-strong);
    background: var(--bg);
}

.image-preview img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center;
}

.image-editor-data {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    min-width: 0;
}

.image-info-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
    align-items: end;
    gap: 12px 16px;
    width: 100%;
}

.image-info-form .form-field {
    gap: 6px;
}

.image-info-form input {
    min-height: 42px;
    padding: 9px 12px;
}

.image-editor-list {
    display: flex;
    flex-direction: column;
}

.image-upload-form {
    padding: 18px 0 0;
    border-bottom: 0;
}

.image-upload-form .form-field {
    flex: 1 1 240px;
}

@media (max-width: 800px) {
    .image-editor-item {
        grid-template-columns: 1fr;
    }

    .image-preview {
        max-width: 340px;
    }

    .image-info-form {
        grid-template-columns: 1fr;
    }

    .image-info-form .button {
        justify-self: start;
    }
}

@media (max-width: 600px) {
    .article-gallery-grid {
        grid-template-columns: 1fr;
    }

    .article-card-image img {
        aspect-ratio: 3 / 2;
    }

    .image-preview {
        max-width: 100%;
    }
}


/* Server diagnostics */
.diagnostic-list {
    max-width: 900px;
    border-top: 1px solid var(--line);
}

.diagnostic-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px 32px;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
}

.diagnostic-item strong {
    display: block;
    margin-bottom: 4px;
    color: var(--text);
    font-size: 14px;
}

.diagnostic-value {
    display: block;
    color: var(--text-soft);
    font-family: Consolas, "Courier New", monospace;
    font-size: 12.5px;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.diagnostic-hint {
    display: block;
    margin-top: 4px;
    color: var(--muted);
    font-size: 12.5px;
}

.diagnostic-status--ok {
    border-color: #4d7466;
    color: #a9d5c4;
}

.diagnostic-status--warn {
    border-color: #7f6837;
    color: #e3c781;
}

.diagnostic-status--fail {
    border-color: #7a3d32;
    color: #e2a08e;
}

@media (max-width: 600px) {
    .diagnostic-item {
        flex-direction: column;
        gap: 8px;
    }
}
@media screen and (max-width: 768px) {
    .reading-progress-container {
        position: fixed;
        top: 0;
        left: 0;
        width: 4px;
        height: 100vh;
        background-color: rgba(0, 0, 0, 0.05); 
        z-index: 9999;
        pointer-events: none;
    }

    .reading-progress-bar {
        width: 100%;
        height: 0%;
        background-color: #6b635b; 
        transition: height 0.1s ease-out;
    }
}

/* Domyślnie na większych ekranach  
@media screen and (min-width: 769px) {
    .reading-progress-container {
        display: none !important;
    }
}