body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #111;
    color: #eee;
}

a {
    color: inherit;
}

.ew-site-header,
.ew-site-footer,
.ew-site-main {
    max-width: 960px;
    margin: 0 auto;
    padding: 24px;
}

.ew-entry {
    border-top: 1px solid rgba(255,255,255,.15);
    padding: 24px 0;
}

.ew-entry-title {
    font-size: 28px;
    line-height: 1.2;
}

.ew-single-main {
    max-width: 1040px;
}

.ew-single {
    padding: 32px 0 56px;
}

.ew-single-header {
    border-bottom: 1px solid rgba(255,255,255,.16);
    padding-bottom: 28px;
    margin-bottom: 32px;
}

.ew-single-kicker {
    margin: 0 0 12px;
    color: #aaa;
    font-size: 13px;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.ew-single-title {
    margin: 0;
    max-width: 900px;
    font-size: clamp(34px, 6vw, 64px);
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.ew-single-excerpt {
    max-width: 780px;
    margin: 22px 0 0;
    color: #cfcfcf;
    font-size: 19px;
    line-height: 1.6;
}

.ew-single-meta {
    display: flex;
    gap: 10px;
    margin-top: 18px;
    color: #8f8f8f;
    font-size: 14px;
}

.ew-featured-figure {
    margin: 0 0 32px;
    padding: 0;
}

.ew-featured-image {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid rgba(255,255,255,.2);
    background: #050505;
}

.ew-single-content {
    max-width: 820px;
    font-size: 18px;
    line-height: 1.75;
}

.ew-single-content h2 {
    margin-top: 42px;
    font-size: 28px;
    line-height: 1.25;
}

.ew-single-content p {
    margin: 0 0 18px;
}

.ew-single-content figure.ew-figure {
    max-width: 1000px;
    margin: 36px 0;
    padding: 14px;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(255,255,255,.03);
}

.ew-single-content figure.ew-figure img {
    display: block;
    width: 100%;
    height: auto;
}

.ew-single-content figcaption {
    margin-top: 5px;
    color: #aaa;
    font-size: 14px;
    line-height: 1.5;
}

.ew-archive-main {
    max-width: 1120px;
}

.ew-archive-header {
    padding: 42px 0 34px;
    border-bottom: 1px solid rgba(255,255,255,.16);
    margin-bottom: 32px;
}

.ew-archive-kicker {
    margin: 0 0 12px;
    color: #aaa;
    font-size: 13px;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.ew-archive-title {
    margin: 0;
    font-size: clamp(36px, 6vw, 68px);
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.ew-archive-description {
    max-width: 780px;
    margin-top: 20px;
    color: #cfcfcf;
    font-size: 18px;
    line-height: 1.65;
}

.ew-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.ew-card {
    border: 1px solid rgba(255,255,255,.16);
    background: rgba(255,255,255,.03);
}

.ew-card-link {
    display: block;
    height: 100%;
    text-decoration: none;
}

.ew-card-figure {
    margin: 0;
    border-bottom: 1px solid rgba(255,255,255,.14);
    background: #050505;
}

.ew-card-image {
    display: block;
    width: 100%;
    height: auto;
}

.ew-card-body {
    padding: 20px;
}

.ew-card-kicker {
    margin: 0 0 10px;
    color: #aaa;
    font-size: 12px;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.ew-card-title {
    margin: 0;
    font-size: 24px;
    line-height: 1.18;
}

.ew-card-excerpt {
    margin: 7px 0 0;
    color: #cfcfcf;
    font-size: 15px;
    line-height: 1.6;
}

.ew-pagination {
    margin-top: 36px;
}

.ew-front-main {
    max-width: 1120px;
}

.ew-front-hero {
    padding: 64px 0 48px;
    border-bottom: 1px solid rgba(255,255,255,.16);
    margin-bottom: 36px;
}

.ew-front-kicker,
.ew-section-kicker {
    margin: 0 0 12px;
    color: #aaa;
    font-size: 13px;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.ew-front-title {
    max-width: 980px;
    margin: 0;
    font-size: clamp(36px, 5.6vw, 64px);
    line-height: 1.02;
    letter-spacing: -0.045em;
}

.ew-front-lead {
    max-width: 780px;
    margin: 24px 0 0;
    color: #cfcfcf;
    font-size: 20px;
    line-height: 1.6;
}

.ew-front-section {
    padding: 12px 0 56px;
}

.ew-section-heading {
    margin-bottom: 24px;
}

.ew-section-heading h2 {
    margin: 0;
    font-size: 32px;
    line-height: 1.15;
}

.ew-search-main {
    max-width: 1120px;
}

.ew-error-main {
    max-width: 960px;
}

.ew-error-panel {
    padding: 72px 0;
}

.ew-error-kicker {
    margin: 0 0 12px;
    color: #aaa;
    font-size: 13px;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.ew-error-title {
    margin: 0;
    font-size: clamp(42px, 7vw, 78px);
    line-height: 1;
    letter-spacing: -0.055em;
}

.ew-error-lead {
    max-width: 720px;
    margin: 24px 0 0;
    color: #cfcfcf;
    font-size: 20px;
    line-height: 1.6;
}

.ew-error-action {
    margin-top: 28px;
}

.ew-error-action a {
    display: inline-block;
    border: 1px solid rgba(255,255,255,.22);
    padding: 12px 16px;
    text-decoration: none;
}

/* --- EPICWORLD ATLAS V1: STABILITY PATCH V3 --- */

/* [1] Interactivity: hover and keyboard focus. */
.ew-card {
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.ew-card:hover,
.ew-card:focus-within {
    border-color: rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.105);
    transform: translateY(-2px);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.32);
}

.ew-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.ew-card-link:focus-visible {
    outline: none;
}

.ew-card-link:focus-visible::after {
    content: '';
    position: absolute;
    top: -1px;
    right: -1px;
    bottom: -1px;
    left: -1px;
    z-index: 10;
    pointer-events: none;
    border: 2px solid #fff;
}

/* [2] Stable card image ratio. */
.ew-card-figure {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    position: relative;
    display: block;
}

.ew-card-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* [3] Narrow mobile layout. */
@media (max-width: 520px) {
    .ew-site-header,
    .ew-site-footer,
    .ew-site-main {
        padding: 16px;
    }

    .ew-card-grid {
        gap: 16px;
        grid-template-columns: 1fr;
    }

    .ew-card-body {
        padding: 16px;
    }
}

/* --- EPICWORLD ATLAS V1: NO THUMBNAIL CARD V1 --- */

/* CSS-only visual placeholder for archive cards without featured images. */
.ew-card:not(.has-post-thumbnail) .ew-card-link::before {
    content: '';
    display: block;
    aspect-ratio: 16 / 9;
    border-bottom: 1px solid rgba(255,255,255,.14);
    background:
        linear-gradient(rgba(255,255,255,.12), rgba(255,255,255,.12)) 0 50% / 100% 1px no-repeat,
        linear-gradient(90deg, rgba(255,255,255,.12), rgba(255,255,255,.12)) 50% 0 / 1px 100% no-repeat,
        radial-gradient(circle at 50% 50%, transparent 0 34px, rgba(255,255,255,.16) 35px 36px, transparent 37px),
        #080808;
    opacity: .9;
}

/* --- EPICWORLD ATLAS V1: SINGLE READABILITY V1 --- */

/* Keep the single content area wide enough for atlas figures. */
.ew-single-content {
    max-width: none;
}

/* Keep prose readable without constraining wide engineering figures. */
.ew-single-content > p,
.ew-single-content > h2,
.ew-single-content > h3,
.ew-single-content > ul,
.ew-single-content > ol,
.ew-single-content > blockquote {
    max-width: 760px;
}

/* Secondary headings for future object articles. */
.ew-single-content h3 {
    margin-top: 32px;
    font-size: 22px;
    line-height: 1.3;
}

/* Lists should follow the same reading rhythm as paragraphs. */
.ew-single-content ul,
.ew-single-content ol {
    margin: 0 0 20px;
    padding-left: 24px;
    line-height: 1.7;
}

/* Quiet technical quote block for future lore/source notes. */
.ew-single-content blockquote {
    margin: 28px 0;
    padding: 4px 0 4px 18px;
    border-left: 2px solid rgba(255,255,255,.24);
    color: #d7d7d7;
}

/* Allow atlas figures to be wider than prose. */
.ew-single-content figure.ew-figure {
    width: min(100%, 1000px);
}

/* Baseline table support for future object passports. */
.ew-single-content table {
    width: min(100%, 900px);
    border-collapse: collapse;
    margin: 32px 0;
    font-size: 15px;
    line-height: 1.5;
}

.ew-single-content th,
.ew-single-content td {
    border: 1px solid rgba(255,255,255,.16);
    padding: 10px 12px;
    vertical-align: top;
}

.ew-single-content th {
    text-align: left;
    color: #eee;
    background: rgba(255,255,255,.06);
}

/* --- EPICWORLD ATLAS V1: ARCHIVE DOSSIER DESK LAYER --- */

/* [1] Dark archive desk: not sci-fi, not sandy paper page. */
body {
    background-color: #0f0f0e;
    background-image:
        linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.014) 1px, transparent 1px),
        radial-gradient(circle at 20% 10%, rgba(115,42,34,.055), transparent 34%),
        radial-gradient(circle at 80% 18%, rgba(255,255,255,.028), transparent 30%);
    background-size: 34px 34px, 34px 34px, auto, auto;
    color: #e7e1d6;
}

/* [2] Site frame: service labels on the archive desk. */
.ew-site-header,
.ew-site-footer {
    color: #d7d0c4;
}

.ew-site-header {
    position: relative;
    border-bottom: 1px dashed rgba(231,225,214,.28);
    background: linear-gradient(180deg, rgba(255,255,255,.035), transparent);
}

.ew-site-header::before {
    content: 'АРХИВНОЕ БЮРО / EPICWORLD ATLAS';
    display: block;
    margin-bottom: 18px;
    color: rgba(231,225,214,.58);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.ew-site-footer {
    border-top: 1px dashed rgba(231,225,214,.28);
    margin-top: 64px;
    color: rgba(231,225,214,.56);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
}

/* [3] Front and archive titles remain dark-environment headings. */
.ew-front-title,
.ew-archive-title,
.ew-error-title {
    color: #f0eadf;
}

.ew-front-lead,
.ew-archive-description,
.ew-error-lead {
    color: #c7bfb2;
}

.ew-front-kicker,
.ew-section-kicker,
.ew-archive-kicker,
.ew-error-kicker {
    color: #aaa093;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* [4] Cards as physical inventory forms on the dark desk. */
.ew-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(14,14,13,.92);
    background:
        linear-gradient(180deg, rgba(226,223,215,.96), rgba(198,193,181,.96));
    box-shadow:
        3px 3px 0 rgba(0,0,0,.52),
        0 18px 34px rgba(0,0,0,.26);
}

.ew-card:hover,
.ew-card:focus-within {
    border-color: rgba(0,0,0,.98);
    background:
        linear-gradient(180deg, rgba(235,231,222,.98), rgba(205,199,185,.98));
    box-shadow:
        5px 5px 0 rgba(0,0,0,.58),
        0 20px 38px rgba(0,0,0,.30);
    transform: translate(-2px, -2px);
}

.ew-card::after {
    content: 'ДЕЛО';
    position: absolute;
    right: 12px;
    bottom: 10px;
    color: rgba(20,20,18,.34);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 10px;
    line-height: 1;
    letter-spacing: .18em;
    pointer-events: none;
}

.ew-card-title {
    color: #11110f;
}

.ew-card-excerpt {
    color: #35312b;
}

.ew-card-kicker {
    display: inline-block;
    border-bottom: 1px solid rgba(20,20,18,.38);
    color: #4f473b;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-weight: 700;
}

.ew-card-figure {
    border-bottom: 1px solid rgba(20,20,18,.48);
    background: #bfb7a6;
}

.ew-card-body {
    background: rgba(220,216,205,.56);
}

/* [5] No-thumbnail state as an empty technical form. */
.ew-card:not(.has-post-thumbnail) .ew-card-link::before {
    border-bottom: 1px solid rgba(20,20,18,.48);
    background:
        linear-gradient(rgba(20,20,18,.13), rgba(20,20,18,.13)) 0 50% / 100% 1px no-repeat,
        linear-gradient(90deg, rgba(20,20,18,.11), rgba(20,20,18,.11)) 50% 0 / 1px 100% no-repeat,
        radial-gradient(circle at 50% 50%, transparent 0 34px, rgba(125,38,31,.28) 35px 36px, transparent 37px),
        linear-gradient(rgba(20,20,18,.048) 1px, transparent 1px),
        linear-gradient(90deg, rgba(20,20,18,.04) 1px, transparent 1px),
        #d1ccbe;
    background-size:
        100% 1px,
        1px 100%,
        auto,
        28px 28px,
        28px 28px,
        auto;
}

/* [6] Single post as a dossier sheet on the desk. */
.ew-single-main {
    background:
        linear-gradient(180deg, rgba(236,232,223,.98), rgba(218,212,198,.98));
    color: #181713;
    border: 1px solid rgba(0,0,0,.78);
    box-shadow:
        4px 4px 0 rgba(0,0,0,.54),
        0 24px 48px rgba(0,0,0,.38);
    margin-top: 32px;
    margin-bottom: 40px;
}

.ew-single-title,
.ew-entry-title,
.ew-section-heading h2 {
    color: #11110f;
}

.ew-single-excerpt,
.ew-single-content {
    color: #28251f;
}

.ew-single-kicker,
.ew-single-meta {
    color: #655c4e;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* [7] Published archive stamp. */
.ew-single-header {
    position: relative;
}

.ew-single-header::after {
    content: 'АРХИВ ОПУБЛИКОВАН';
    position: absolute;
    right: 0;
    bottom: 22px;
    transform: rotate(-3deg);
    border: 2px solid rgba(142,38,32,.70);
    padding: 7px 12px 6px;
    color: rgba(142,38,32,.90);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    pointer-events: none;
}

/* [8] Content headings as dossier sections. */
.ew-single-content h2,
.ew-single-content h3 {
    color: #11110f;
    border-bottom: 2px solid rgba(20,20,18,.72);
    padding-bottom: 5px;
}

/* [9] Archive plates: featured images and ew-figures. */
.ew-featured-image,
.ew-single-content figure.ew-figure {
    border-color: rgba(20,20,18,.62);
    background: rgba(226,220,207,.82);
    box-shadow: 3px 3px 0 rgba(20,20,18,.24);
}

.ew-single-content figcaption {
    border-top: 1px solid rgba(20,20,18,.22);
    padding-top: 10px;
    color: #625a4d;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

/* [10] Object passport tables. */
.ew-single-content table {
    background: rgba(242,240,234,.84);
    border: 2px solid rgba(20,20,18,.82);
    border-left: 4px solid rgba(142,38,32,.68);
}

.ew-single-content th,
.ew-single-content td {
    border-color: rgba(20,20,18,.54);
}

.ew-single-content th {
    color: #11110f;
    background: rgba(20,20,18,.10);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.ew-single-content td {
    color: #27241f;
}

/* [11] Official archive note, not literary quote. */
.ew-single-content blockquote {
    background: rgba(242,240,234,.66);
    border-left-color: rgba(142,38,32,.72);
    color: #27241f;
}

/* [12] Error action as document control. */
.ew-error-action a {
    border-color: rgba(231,225,214,.36);
    background: rgba(231,225,214,.08);
}

/* [13] Mobile safety for dossier tables and stamp. */
@media (max-width: 768px) {
    .ew-single-content {
        overflow-wrap: break-word;
    }

    .ew-single-content table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .ew-single-header::after {
        position: static;
        display: inline-block;
        margin-top: 18px;
        transform: rotate(-2deg);
    }
}

/* --- EPICWORLD ATLAS V1: ARCHIVE DOSSIER DESK HEADING FIX --- */

/* Section headings live on the dark archive desk, not on paper. */
.ew-front-section .ew-section-heading h2,
.ew-archive-main .ew-archive-title,
.ew-search-main .ew-archive-title {
    color: #f0eadf;
}

/* Section kickers on dark background must remain readable. */
.ew-front-section .ew-section-kicker,
.ew-archive-main .ew-archive-kicker,
.ew-search-main .ew-archive-kicker {
    color: #aaa093;
}

/* Keep dossier-internal headings dark on paper. */
.ew-single-main .ew-section-heading h2,
.ew-single-content h2,
.ew-single-content h3 {
    color: #11110f;
}

/* --- EPICWORLD ATLAS V1: OBJECT DOCUMENT GRAMMAR --- */

/* [1] Object code: inventory line of the dossier. */
.ew-single-content .ew-object-code {
    max-width: 760px;
    margin: 0 0 24px;
    border: 1px solid rgba(20,20,18,.64);
    border-left: 4px solid rgba(142,38,32,.72);
    padding: 10px 12px;
    background: rgba(242,240,234,.72);
    color: #2b2721;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 13px;
    line-height: 1.45;
    letter-spacing: .06em;
    text-transform: uppercase;
}

/* [2] Strong passport labels: bureaucratic density without changing HTML. */
.ew-single-content p strong {
    color: #11110f;
    font-weight: 800;
}

/* [3] Regulation block: official note, not decorative quote. */
.ew-single-content blockquote.ew-regulation {
    max-width: 760px;
    position: relative;
    margin: 34px 0;
    border: 2px solid rgba(20,20,18,.72);
    border-left: 5px solid rgba(142,38,32,.76);
    padding: 18px 20px 18px 52px;
    background:
        linear-gradient(180deg, rgba(242,240,234,.88), rgba(226,220,207,.82));
    color: #211f1b;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 14px;
    line-height: 1.65;
}

.ew-single-content blockquote.ew-regulation::before {
    content: 'РЕГЛАМЕНТ';
    position: absolute;
    left: 14px;
    top: 18px;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    color: rgba(142,38,32,.80);
    font-size: 10px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: .16em;
}

.ew-single-content blockquote.ew-regulation p {
    margin: 0;
}

/* [4] Dossier section rhythm: headings behave like form dividers. */
.ew-single-content h2 {
    position: relative;
    margin-top: 46px;
    margin-bottom: 18px;
    padding-bottom: 7px;
}

.ew-single-content h2::before {
    content: '§';
    display: inline-block;
    margin-right: 10px;
    color: rgba(142,38,32,.78);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .82em;
}

/* [5] Archive conclusion: last strong paragraph reads as classification. */
.ew-single-content > p:last-child strong {
    display: block;
    border: 2px solid rgba(20,20,18,.72);
    border-left: 5px solid rgba(142,38,32,.76);
    padding: 14px 16px;
    background: rgba(242,240,234,.82);
    color: #161410;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 14px;
    line-height: 1.65;
}

/* [6] Inline code inside archive prose: technical tokens. */
.ew-single-content code {
    border: 1px solid rgba(20,20,18,.38);
    padding: 1px 4px;
    background: rgba(20,20,18,.08);
    color: #161410;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: .92em;
}

/* [7] Mobile: keep official blocks readable. */
@media (max-width: 768px) {
    .ew-single-content .ew-object-code,
    .ew-single-content blockquote.ew-regulation,
    .ew-single-content > p:last-child strong {
        max-width: none;
    }

    .ew-single-content blockquote.ew-regulation {
        padding: 16px 16px 16px 44px;
    }
}

/* --- EPICWORLD ATLAS V1: REGULATION BLOCK FIX V1 --- */

/* Turn regulation quote into an internal archive notice, not a side label. */
.ew-single-content blockquote.ew-regulation {
    padding: 0;
    overflow: hidden;
}

.ew-single-content blockquote.ew-regulation::before {
    content: 'РЕГЛАМЕНТНАЯ ПОМЕТКА';
    position: static;
    display: block;
    writing-mode: horizontal-tb;
    transform: none;
    padding: 9px 14px 8px;
    border-bottom: 1px solid rgba(20,20,18,.54);
    background: rgba(20,20,18,.08);
    color: rgba(142,38,32,.92);
    font-size: 11px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: .16em;
}

.ew-single-content blockquote.ew-regulation p {
    padding: 16px 18px 18px;
}

/* Keep ordinary blockquotes quieter than regulation notices. */
.ew-single-content blockquote:not(.ew-regulation) {
    border-style: solid;
}

/* --- EPICWORLD ATLAS V1: SINGLE TITLE SCALE V1 --- */

/* Long object titles must read as dossier headings, not hero posters. */
.ew-single-title {
    max-width: 920px;
    font-size: clamp(30px, 4.4vw, 48px);
    line-height: 1.08;
    letter-spacing: -0.035em;
}

/* Keep fixture labels from visually dominating the actual object title. */
.ew-single-title::first-letter {
    letter-spacing: inherit;
}

/* --- EPICWORLD ATLAS V1: SINGLE DOSSIER META PANEL CSS V1 --- */

/* Restore the old EpicWorld dossier logic: document line + four-cell archive form. */
.ew-dossier-meta {
    max-width: 100%;
    margin: 0 0 30px;
    color: #161410;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.ew-dossier-meta__head {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 0 0 22px;
    color: rgba(20,20,18,.66);
    font-size: 13px;
    line-height: 1;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.ew-dossier-meta__head span + span::before {
    content: '·';
    margin-right: 8px;
    color: rgba(20,20,18,.62);
}

.ew-dossier-meta__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border: 2px solid rgba(20,20,18,.88);
    background: rgba(205,201,190,.74);
}

.ew-dossier-meta__grid > div {
    min-height: 76px;
    padding: 14px 16px;
    border-right: 1px solid rgba(20,20,18,.66);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
}

.ew-dossier-meta__grid > div:last-child {
    border-right: 0;
}

.ew-dossier-meta__grid span {
    display: block;
    color: rgba(20,20,18,.58);
    font-size: 11px;
    line-height: 1;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.ew-dossier-meta__grid strong {
    display: block;
    color: #11110f;
    font-size: 14px;
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.ew-dossier-meta__grid > div:nth-child(3) strong {
    display: inline-block;
    align-self: flex-start;
    border: 1px solid rgba(142,38,32,.54);
    padding: 6px 10px 5px;
    color: rgba(112,37,31,.92);
    background: rgba(142,38,32,.045);
}

/* After the dossier panel the title must behave like a document title, not a poster. */
.ew-single-title {
    font-size: clamp(28px, 3.8vw, 42px);
    line-height: 1.1;
    letter-spacing: -0.03em;
}

/* The category kicker remains useful, but the dossier panel now carries the main metadata. */
.ew-single-kicker {
    margin-bottom: 18px;
}


/* Related objects as internal atlas cross-links. */
.ew-related-objects {
    max-width: 1000px;
    margin: 44px 0 0;
    padding: 22px 24px;
    border: 1px solid rgba(20,20,18,.42);
    background:
        linear-gradient(180deg, rgba(255,255,255,.34), rgba(255,255,255,0)),
        rgba(242,240,234,.62);
    box-shadow: 0 12px 32px rgba(20,20,18,.08);
}

.ew-related-objects__kicker {
    margin-bottom: 8px;
    color: rgba(112,37,31,.92);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.ew-related-objects__title {
    margin: 0 0 14px;
    color: #161410;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(20px, 2.2vw, 26px);
    line-height: 1.15;
}

.ew-related-objects__list {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ew-related-objects__item {
    margin: 0;
    padding: 0;
}

.ew-related-objects__item a {
    display: block;
    padding: 10px 12px;
    border: 1px solid rgba(20,20,18,.30);
    background: rgba(255,255,255,.34);
    color: #161410;
    text-decoration: none;
}

.ew-related-objects__item a:hover,
.ew-related-objects__item a:focus {
    border-color: rgba(20,20,18,.72);
    background: rgba(255,255,255,.64);
    text-decoration: underline;
    text-underline-offset: .18em;
}

@media (max-width: 520px) {
    .ew-related-objects {
        padding: 18px 16px;
    }
}


/* Object navigation as archive register controls. */
.ew-object-nav {
    max-width: 1000px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 12px;
    align-items: center;
    margin: 48px 0 0;
    padding-top: 22px;
    border-top: 2px dashed rgba(20,20,18,.42);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ew-object-nav a {
    color: #161410;
    text-decoration: none;
    border: 1px solid rgba(20,20,18,.42);
    padding: 8px 10px;
    background: rgba(242,240,234,.62);
}

.ew-object-nav a:hover,
.ew-object-nav a:focus {
    border-color: rgba(20,20,18,.84);
    background: rgba(242,240,234,.92);
}

.ew-object-nav__next {
    text-align: right;
}

.ew-object-nav__register {
    font-weight: 800;
}

@media (max-width: 820px) {
    .ew-dossier-meta__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ew-dossier-meta__grid > div:nth-child(2) {
        border-right: 0;
    }

    .ew-dossier-meta__grid > div:nth-child(1),
    .ew-dossier-meta__grid > div:nth-child(2) {
        border-bottom: 1px solid rgba(20,20,18,.66);
    }

    .ew-object-nav {
        grid-template-columns: 1fr;
        text-align: left;
    }

    .ew-object-nav__next {
        text-align: left;
    }
}

@media (max-width: 520px) {
    .ew-dossier-meta__grid {
        grid-template-columns: 1fr;
    }

    .ew-dossier-meta__grid > div {
        border-right: 0;
        border-bottom: 1px solid rgba(20,20,18,.66);
    }

    .ew-dossier-meta__grid > div:last-child {
        border-bottom: 0;
    }
}

/* --- EPICWORLD ATLAS V1: REMOVE DUPLICATE SINGLE STAMP V1 --- */

/* Status is now carried by the dossier metadata panel. */
.ew-single-header::after {
    content: none;
    display: none;
}

/* --- EPICWORLD ATLAS V1: OBJECT PASSPORT TABLE V1 --- */

/* The object passport is the central dossier form, not a generic table. */
.ew-single-content h2 + table {
    width: min(100%, 940px);
    margin: 22px 0 42px;
    border: 3px solid rgba(20,20,18,.88);
    border-left: 6px solid rgba(142,38,32,.76);
    background:
        linear-gradient(180deg, rgba(244,242,236,.96), rgba(224,219,207,.94));
    box-shadow:
        3px 3px 0 rgba(20,20,18,.28),
        0 18px 34px rgba(20,20,18,.16);
}

/* Header row as a registry form heading. */
.ew-single-content h2 + table thead th {
    border-bottom: 2px solid rgba(20,20,18,.88);
    background: rgba(20,20,18,.12);
    color: #11110f;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    line-height: 1.2;
    letter-spacing: .16em;
    text-transform: uppercase;
}

/* Passport cells: dense, bureaucratic, readable. */
.ew-single-content h2 + table th,
.ew-single-content h2 + table td {
    border-color: rgba(20,20,18,.58);
    padding: 12px 14px;
}

/* First column: official field names. */
.ew-single-content h2 + table tbody td:first-child {
    width: 34%;
    background:
        linear-gradient(180deg, rgba(20,20,18,.09), rgba(20,20,18,.06));
    color: #14120f;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    line-height: 1.35;
    letter-spacing: .08em;
    text-transform: uppercase;
    vertical-align: top;
}

/* Field labels inside first column. */
.ew-single-content h2 + table tbody td:first-child strong {
    font-weight: 800;
}

/* Second column: object characteristic text. */
.ew-single-content h2 + table tbody td:nth-child(2) {
    color: #25221d;
    font-size: 15px;
    line-height: 1.55;
    vertical-align: top;
}

/* Last row is usually the description risk: make it a control field. */
.ew-single-content h2 + table tbody tr:last-child td {
    border-top: 2px solid rgba(142,38,32,.62);
    background: rgba(142,38,32,.045);
}

.ew-single-content h2 + table tbody tr:last-child td:first-child {
    color: rgba(112,37,31,.96);
}

.ew-single-content h2 + table tbody tr:last-child td:nth-child(2) {
    color: #211d18;
}

/* Strengthen the “Паспорт объекта” heading when it precedes a table. */
.ew-single-content h2:has(+ table) {
    max-width: 940px;
    margin-bottom: 0;
    border: 2px solid rgba(20,20,18,.82);
    border-bottom: 0;
    padding: 12px 14px 10px;
    background: rgba(20,20,18,.10);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 18px;
    letter-spacing: .08em;
    text-transform: uppercase;
}

/* Mobile: preserve passport readability without crushing columns. */
@media (max-width: 768px) {
    .ew-single-content h2 + table {
        width: 100%;
    }

    .ew-single-content h2 + table tbody td:first-child {
        min-width: 210px;
    }

    .ew-single-content h2:has(+ table) {
        font-size: 16px;
    }
}

/* --- EPICWORLD ATLAS V1: OBJECT PASSPORT PARAGRAPH FALLBACK V1 --- */

/* Fallback for simplified passports:
   <h2>Паспорт объекта</h2>
   <p><strong>Инвентарный номер:</strong> ...<br>...</p>
   The production standard remains the table passport. */
.ew-single-content h2:has(+ p strong):not(:has(+ table)) {
    max-width: 760px;
    margin-bottom: 0;
    border: 2px solid rgba(20,20,18,.78);
    border-bottom: 0;
    padding: 12px 14px 10px;
    background: rgba(20,20,18,.10);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 18px;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ew-single-content h2 + p:has(strong):has(br) {
    max-width: 760px;
    margin: 0 0 40px;
    border: 3px solid rgba(20,20,18,.82);
    border-left: 6px solid rgba(142,38,32,.72);
    padding: 16px 18px;
    background:
        linear-gradient(180deg, rgba(244,242,236,.94), rgba(224,219,207,.90));
    box-shadow:
        3px 3px 0 rgba(20,20,18,.22),
        0 14px 26px rgba(20,20,18,.12);
    color: #25221d;
    font-size: 15px;
    line-height: 1.8;
}

.ew-single-content h2 + p:has(strong):has(br) strong {
    display: inline-block;
    min-width: 170px;
    margin-right: 10px;
    color: #11110f;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    letter-spacing: .06em;
    text-transform: uppercase;
}

/* Prevent the simplified passport fallback from affecting the final classification block. */
.ew-single-content > p:last-child:has(strong):has(br) {
    margin-bottom: 18px;
}

/* --- EPICWORLD ATLAS V1: FRONT ARCHIVE BUREAU CSS V1 --- */

/* Front page is an archive bureau intake desk, not a blog grid. */
.ew-front-bureau {
    display: grid;
    gap: 34px;
}

/* Hero dossier: institutional entry point. */
.ew-front-dossier {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(300px, .75fr);
    gap: 24px;
    align-items: stretch;
    border: 1px solid rgba(231,225,214,.30);
    background:
        linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.018));
    box-shadow:
        0 22px 54px rgba(0,0,0,.30),
        inset 0 1px 0 rgba(255,255,255,.045);
    padding: clamp(24px, 4vw, 44px);
}

.ew-front-dossier__copy {
    min-width: 0;
}

.ew-front-dossier .ew-front-title {
    max-width: 860px;
    margin: 0;
    font-size: clamp(38px, 6vw, 72px);
    line-height: .98;
    letter-spacing: -0.052em;
}

.ew-front-dossier .ew-front-lead {
    max-width: 760px;
    margin-top: 22px;
}

/* Published object register. */
.ew-front-register {
    border: 2px solid rgba(231,225,214,.38);
    background:
        linear-gradient(180deg, rgba(232,227,216,.13), rgba(232,227,216,.06));
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.ew-front-register__title {
    padding: 13px 15px 12px;
    border-bottom: 1px solid rgba(231,225,214,.30);
    color: #f0eadf;
    font-size: 12px;
    line-height: 1;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.ew-front-register__row {
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr);
    gap: 14px;
    padding: 14px 15px;
    border-bottom: 1px solid rgba(231,225,214,.20);
    color: #e7e1d6;
    text-decoration: none;
}

.ew-front-register__row:last-child {
    border-bottom: 0;
}

.ew-front-register__row span {
    color: rgba(231,225,214,.62);
    font-size: 11px;
    letter-spacing: .12em;
}

.ew-front-register__row strong {
    color: #f0eadf;
    font-size: 12px;
    line-height: 1.25;
    font-weight: 800;
    text-transform: uppercase;
}

.ew-front-register__row:hover,
.ew-front-register__row:focus {
    background: rgba(232,227,216,.10);
}

/* Protocol block: service instruction. */
.ew-front-method {
    border: 2px solid rgba(20,20,18,.84);
    border-left: 6px solid rgba(142,38,32,.72);
    background:
        linear-gradient(180deg, rgba(236,232,223,.96), rgba(213,207,193,.94));
    color: #181713;
    box-shadow:
        3px 3px 0 rgba(0,0,0,.46),
        0 18px 38px rgba(0,0,0,.22);
    padding: clamp(22px, 3vw, 32px);
}

.ew-front-method h2 {
    margin: 0 0 12px;
    color: #11110f;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: clamp(20px, 2.4vw, 28px);
    line-height: 1.1;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.ew-front-method p {
    max-width: 920px;
    margin: 0;
    color: #28251f;
    font-size: 17px;
    line-height: 1.7;
}

/* Section cards on the archive desk. */
.ew-front-bureau .ew-front-section,
.ew-front-featured-object {
    border: 1px solid rgba(231,225,214,.28);
    background:
        linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.014));
    box-shadow: 0 18px 46px rgba(0,0,0,.24);
    padding: clamp(22px, 3vw, 34px);
}

.ew-front-bureau .ew-section-heading {
    margin-bottom: 20px;
    border-bottom: 1px dashed rgba(231,225,214,.28);
    padding-bottom: 14px;
}

.ew-front-bureau .ew-section-heading h2 {
    color: #f0eadf;
}

/* Classifier register as table-like bureau register. */
.ew-classifier-register {
    border: 2px solid rgba(231,225,214,.30);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.ew-classifier-register__row {
    display: grid;
    grid-template-columns: 92px 90px minmax(160px, .8fr) minmax(240px, 1.4fr) 150px;
    border-bottom: 1px solid rgba(231,225,214,.22);
    background: rgba(232,227,216,.055);
}

.ew-classifier-register__row:last-child {
    border-bottom: 0;
}

.ew-classifier-register__row > div {
    padding: 13px 14px;
    border-right: 1px solid rgba(231,225,214,.18);
}

.ew-classifier-register__row > div:last-child {
    border-right: 0;
}

.ew-register-code,
.ew-register-kind,
.ew-register-state {
    color: rgba(231,225,214,.70);
    font-size: 11px;
    line-height: 1.35;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.ew-register-name {
    color: #f0eadf;
    font-size: 13px;
    line-height: 1.35;
    font-weight: 800;
    text-transform: uppercase;
}

.ew-register-desc {
    color: rgba(231,225,214,.74);
    font-size: 12px;
    line-height: 1.45;
}

.ew-register-state a,
.ew-register-state span {
    color: #f0eadf;
    text-decoration: none;
}

.ew-register-state a {
    border-bottom: 1px solid rgba(142,38,32,.76);
}

/* Control document. */
.ew-front-featured-object {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, .9fr);
    gap: 24px;
    align-items: center;
}

.ew-front-featured-object__text h2 {
    margin: 0 0 14px;
    color: #f0eadf;
    font-size: clamp(26px, 3.8vw, 44px);
    line-height: 1.04;
    letter-spacing: -0.035em;
}

.ew-front-featured-object__text h2 a {
    color: inherit;
    text-decoration: none;
}

.ew-front-featured-object__text p {
    max-width: 720px;
    color: #c7bfb2;
    line-height: 1.7;
}

.ew-front-featured-object__image {
    display: block;
    border: 1px solid rgba(231,225,214,.34);
    background: #111;
    box-shadow: 3px 3px 0 rgba(0,0,0,.56);
    overflow: hidden;
}

.ew-front-featured-object__image img {
    display: block;
    width: 100%;
    height: auto;
}

/* Intake log: the main front-page documentary register. */
.ew-intake-log {
    border: 2px solid rgba(231,225,214,.30);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.ew-intake-log__head,
.ew-intake-log__row {
    display: grid;
    grid-template-columns: 110px 118px minmax(150px, .72fr) minmax(260px, 1.45fr) 110px;
    align-items: stretch;
}

.ew-intake-log__head {
    background: rgba(232,227,216,.12);
    color: rgba(231,225,214,.68);
    font-size: 11px;
    line-height: 1;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.ew-intake-log__row {
    border-top: 1px solid rgba(231,225,214,.22);
    background: rgba(232,227,216,.045);
}

.ew-intake-log__head span,
.ew-intake-log__row > * {
    min-width: 0;
    margin: 0;
    padding: 13px 14px;
    border-right: 1px solid rgba(231,225,214,.18);
}

.ew-intake-log__head span:last-child,
.ew-intake-log__row > *:last-child {
    border-right: 0;
}

.ew-intake-log__row time,
.ew-intake-code,
.ew-intake-sector,
.ew-intake-status {
    color: rgba(231,225,214,.70);
    font-size: 11px;
    line-height: 1.35;
    letter-spacing: .10em;
    text-transform: uppercase;
}

.ew-intake-log__row h3 {
    color: #f0eadf;
    font-size: 13px;
    line-height: 1.35;
    font-weight: 800;
}

.ew-intake-log__row h3 a {
    color: inherit;
    text-decoration: none;
}

.ew-intake-status {
    color: rgba(142,38,32,.98);
    font-weight: 800;
}

/* Compatibility: old simple card grid should not dominate this layout. */
.ew-front-bureau .ew-card-grid {
    margin-top: 20px;
}

/* Responsive bureau tables. */
@media (max-width: 980px) {
    .ew-front-dossier,
    .ew-front-featured-object {
        grid-template-columns: 1fr;
    }

    .ew-classifier-register__row,
    .ew-intake-log__head,
    .ew-intake-log__row {
        grid-template-columns: 1fr;
    }

    .ew-classifier-register__row > div,
    .ew-intake-log__head span,
    .ew-intake-log__row > * {
        border-right: 0;
        border-bottom: 1px solid rgba(231,225,214,.16);
    }

    .ew-classifier-register__row > div:last-child,
    .ew-intake-log__head span:last-child,
    .ew-intake-log__row > *:last-child {
        border-bottom: 0;
    }
}

@media (max-width: 620px) {
    .ew-front-dossier,
    .ew-front-bureau .ew-front-section,
    .ew-front-featured-object,
    .ew-front-method {
        padding: 20px;
    }

    .ew-front-register__row {
        grid-template-columns: 1fr;
        gap: 6px;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT PAPER DOCUMENT OVERRIDE V1 --- */

/* Dark background is the desk. Front blocks are paper documents. */
.ew-front-dossier,
.ew-front-bureau .ew-front-section,
.ew-front-featured-object {
    border: 2px solid rgba(20,20,18,.72);
    background:
        linear-gradient(180deg, rgba(236,232,223,.98), rgba(218,212,198,.97));
    color: #181713;
    box-shadow:
        4px 4px 0 rgba(0,0,0,.48),
        0 22px 46px rgba(0,0,0,.28);
}

/* Inner sheet line, closer to old production document panels. */
.ew-front-dossier {
    position: relative;
}

.ew-front-dossier::before,
.ew-front-bureau .ew-front-section::before,
.ew-front-featured-object::before {
    content: '';
    position: absolute;
    inset: 10px;
    border: 1px solid rgba(20,20,18,.16);
    pointer-events: none;
}

.ew-front-bureau .ew-front-section,
.ew-front-featured-object {
    position: relative;
}

/* Hero typography on paper. */
.ew-front-dossier .ew-front-kicker,
.ew-front-dossier .ew-section-kicker {
    color: rgba(20,20,18,.62);
}

.ew-front-dossier .ew-front-title {
    color: #11110f;
    font-family: Georgia, 'Times New Roman', serif;
    letter-spacing: -0.055em;
}

.ew-front-dossier .ew-front-lead {
    color: #2b2822;
}

/* Front action link as archive button, not web CTA. */
.ew-front-dossier .ew-read-more,
.ew-front-featured-object .ew-read-more {
    display: inline-block;
    border: 1px solid rgba(20,20,18,.62);
    padding: 10px 14px;
    background: rgba(242,240,234,.50);
    color: #11110f;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    letter-spacing: .12em;
    text-transform: uppercase;
    text-decoration: none;
}

.ew-front-dossier .ew-read-more:hover,
.ew-front-featured-object .ew-read-more:hover,
.ew-front-dossier .ew-read-more:focus,
.ew-front-featured-object .ew-read-more:focus {
    background: rgba(20,20,18,.08);
}

/* Register is a paper table inside the hero document. */
.ew-front-register {
    border: 1px solid rgba(20,20,18,.66);
    background: rgba(226,220,207,.64);
    color: #181713;
    box-shadow: none;
}

.ew-front-register__title {
    border-bottom: 1px solid rgba(20,20,18,.38);
    color: rgba(20,20,18,.68);
    background: rgba(20,20,18,.045);
}

.ew-front-register__row {
    border-bottom: 1px solid rgba(20,20,18,.25);
    color: #181713;
}

.ew-front-register__row span {
    color: rgba(142,38,32,.78);
}

.ew-front-register__row strong {
    color: #161410;
}

.ew-front-register__row:hover,
.ew-front-register__row:focus {
    background: rgba(20,20,18,.055);
}

/* Protocol block should align with the same paper language. */
.ew-front-method {
    background:
        linear-gradient(180deg, rgba(236,232,223,.98), rgba(218,212,198,.97));
}

/* Section headers on paper. */
.ew-front-bureau .ew-section-heading {
    border-bottom: 1px solid rgba(20,20,18,.48);
}

.ew-front-bureau .ew-section-heading h2,
.ew-front-featured-object__text h2 {
    color: #11110f;
}

.ew-front-bureau .ew-section-kicker,
.ew-front-featured-object .ew-front-kicker {
    color: rgba(20,20,18,.62);
}

/* Classifier register becomes a paper ведомость. */
.ew-classifier-register {
    border: 2px solid rgba(20,20,18,.72);
    background: rgba(242,240,234,.58);
}

.ew-classifier-register__row {
    border-bottom: 1px solid rgba(20,20,18,.30);
    background: transparent;
}

.ew-classifier-register__row > div {
    border-right: 1px solid rgba(20,20,18,.22);
}

.ew-register-code,
.ew-register-kind,
.ew-register-state {
    color: rgba(20,20,18,.62);
}

.ew-register-code {
    color: rgba(142,38,32,.86);
}

.ew-register-name {
    color: #11110f;
}

.ew-register-desc {
    color: #332f29;
}

.ew-register-state a,
.ew-register-state span {
    color: #11110f;
}

.ew-register-state a {
    border-bottom-color: rgba(142,38,32,.76);
}

/* Control document as a paper case file. */
.ew-front-featured-object__text h2 a {
    color: #11110f;
}

.ew-front-featured-object__text p {
    color: #2b2822;
}

.ew-front-featured-object__image {
    border: 1px solid rgba(20,20,18,.54);
    background: #d8d2c4;
    box-shadow: 3px 3px 0 rgba(20,20,18,.24);
}

/* Intake log as paper register, not black terminal table. */
.ew-intake-log {
    border: 2px solid rgba(20,20,18,.72);
    background: rgba(242,240,234,.58);
}

.ew-intake-log__head {
    background: rgba(20,20,18,.10);
    color: rgba(20,20,18,.66);
}

.ew-intake-log__row {
    border-top: 1px solid rgba(20,20,18,.28);
    background: transparent;
}

.ew-intake-log__head span,
.ew-intake-log__row > * {
    border-right: 1px solid rgba(20,20,18,.22);
}

.ew-intake-log__row time,
.ew-intake-code,
.ew-intake-sector {
    color: rgba(20,20,18,.66);
}

.ew-intake-code,
.ew-intake-status {
    color: rgba(142,38,32,.86);
}

.ew-intake-log__row h3 {
    color: #11110f;
}

.ew-intake-status {
    border: 1px solid rgba(142,38,32,.54);
    background: rgba(142,38,32,.045);
    font-weight: 800;
}

/* Mobile: preserve paper register readability. */
@media (max-width: 980px) {
    .ew-classifier-register__row > div,
    .ew-intake-log__head span,
    .ew-intake-log__row > * {
        border-right: 0;
        border-bottom: 1px solid rgba(20,20,18,.22);
    }
}

/* --- EPICWORLD ATLAS V1: FRONT BUREAU STAMPS V1 --- */

/* Bureaucratic micro-layer: document references, intake stamps, stricter office tone. */

/* Right-top service references for paper blocks. */
.ew-front-dossier::after,
.ew-front-method::after,
.ew-front-classifier-section::after,
.ew-front-featured-object::after,
.ew-front-section:last-child::after {
    position: absolute;
    right: 28px;
    top: 24px;
    color: rgba(20,20,18,.58);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 10px;
    line-height: 1;
    letter-spacing: .18em;
    text-transform: uppercase;
    pointer-events: none;
}

.ew-front-dossier::after {
    content: 'ДОК-000 / ИНДЕКС АТЛАСА';
}

.ew-front-method::after {
    content: 'ДОК-001 / МЕТОД АРХИВА';
}

.ew-front-classifier-section::after {
    content: 'ДОК-002 / КЛАССИФИКАТОР';
}

.ew-front-featured-object::after {
    content: 'ДОК-003 / КОНТРОЛЬНЫЙ ДОК.';
}

.ew-front-section:last-child::after {
    content: 'ДОК-004 / ЖУРНАЛ ПРИЁМКИ';
}

.ew-front-method,
.ew-front-classifier-section,
.ew-front-featured-object,
.ew-front-section:last-child {
    position: relative;
}

/* Give paper blocks a stricter form edge. */
.ew-front-dossier,
.ew-front-method,
.ew-front-bureau .ew-front-section,
.ew-front-featured-object {
    outline: 1px solid rgba(20,20,18,.18);
    outline-offset: -10px;
}

/* Status labels become small office stamps, not colored UI badges. */
.ew-register-state a,
.ew-register-state span,
.ew-intake-status {
    display: inline-block;
    border: 1px solid rgba(142,38,32,.54);
    padding: 4px 7px 3px;
    background: rgba(142,38,32,.045);
    color: rgba(112,37,31,.94);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 10px;
    line-height: 1;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

/* Intake rows: make accepted documents feel registered. */
.ew-intake-log__row {
    position: relative;
}

.ew-intake-log__row::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: rgba(142,38,32,.54);
    pointer-events: none;
}

/* Register rows: more ledger, less list. */
.ew-front-register__row span,
.ew-intake-code,
.ew-register-code {
    font-variant-numeric: tabular-nums;
}

.ew-front-register__row strong,
.ew-register-name,
.ew-intake-log__row h3 {
    letter-spacing: .015em;
}

/* Classifier and intake ledgers: stronger horizontal rhythm. */
.ew-classifier-register__row:nth-child(even),
.ew-intake-log__row:nth-child(even) {
    background: rgba(20,20,18,.035);
}

.ew-classifier-register__row:hover,
.ew-intake-log__row:hover {
    background: rgba(142,38,32,.035);
}

/* Method document: more like an internal instruction. */
.ew-front-method h2::before {
    content: '§ ';
    color: rgba(142,38,32,.82);
}

.ew-front-method p::before {
    content: 'ПРИМЕЧАНИЕ. ';
    color: rgba(112,37,31,.92);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    letter-spacing: .08em;
    font-weight: 800;
}

/* Hero register title as a stamped folder label. */
.ew-front-register__title::before {
    content: '№ ';
    color: rgba(142,38,32,.82);
}

/* Mobile: service refs should not collide with headings. */
@media (max-width: 720px) {
    .ew-front-dossier::after,
    .ew-front-method::after,
    .ew-front-classifier-section::after,
    .ew-front-featured-object::after,
    .ew-front-section:last-child::after {
        position: static;
        display: block;
        margin-bottom: 14px;
    }
}



/* --- EPICWORLD ATLAS V1: FEATURED OBJECT WITHOUT IMAGE V1 --- */

/* If the control document has no thumbnail, it must behave like a compact file note,
   not like an empty two-column promo panel. */
.ew-front-featured-object.is-without-image {
    grid-template-columns: minmax(0, 760px);
    align-items: start;
}

.ew-front-featured-object.is-without-image .ew-front-featured-object__text {
    max-width: 760px;
}

.ew-front-featured-object.is-without-image .ew-front-featured-object__text h2 {
    max-width: 760px;
    font-size: clamp(28px, 3.1vw, 40px);
    line-height: 1.08;
}

@media (min-width: 981px) {
    .ew-front-featured-object.is-without-image {
        min-height: 0;
        padding-right: clamp(22px, 3vw, 34px);
    }
}

/* --- EPICWORLD ATLAS V1: FRONT REGISTER NATURAL HEIGHT V1 --- */

/* The hero-side register must not stretch into an empty box when only one object is visible. */
.ew-front-dossier .ew-front-register {
    align-self: start;
}

/* --- EPICWORLD ATLAS V1: FRONT TYPOGRAPHIC RESTRAINT V1 --- */

/* The front page must read as an archive dossier, not as a promotional landing page. */
.ew-front-dossier .ew-front-title {
    max-width: 780px;
    font-size: clamp(34px, 4.8vw, 58px);
    line-height: 1.04;
    letter-spacing: -0.045em;
}

/* Keep the opening statement editorial, but less poster-like. */
.ew-front-dossier .ew-front-lead {
    max-width: 720px;
    font-size: clamp(17px, 1.45vw, 19px);
    line-height: 1.62;
}

/* Control document title should be important, but not compete with the dossier title. */
.ew-front-featured-object__text h2 {
    font-size: clamp(24px, 3vw, 36px);
    line-height: 1.1;
    letter-spacing: -0.025em;
}

/* No-image control document is a compact file note, not a poster block. */
.ew-front-featured-object.is-without-image .ew-front-featured-object__text h2 {
    font-size: clamp(24px, 2.5vw, 34px);
    line-height: 1.12;
}

/* Section headings should remain authoritative, but closer to registry typography. */
.ew-front-bureau .ew-section-heading h2 {
    font-size: clamp(24px, 3vw, 32px);
    line-height: 1.14;
}

.ew-front-method h2 {
    font-size: clamp(19px, 2.1vw, 25px);
}

/* --- EPICWORLD ATLAS V1: OBJECT REGISTER PAGE V1 --- */

.ew-register-main {
    max-width: 1180px;
    margin: 0 auto;
    padding: clamp(32px, 5vw, 72px) 20px clamp(56px, 7vw, 96px);
}

.ew-register-header {
    position: relative;
    margin-bottom: 28px;
    padding: clamp(26px, 4vw, 42px);
    border: 1px solid rgba(52, 43, 33, 0.22);
    background: #f4ead9;
    box-shadow: 0 22px 60px rgba(22, 18, 14, 0.18);
}

.ew-register-title {
    max-width: 760px;
    margin: 0;
    font-size: clamp(34px, 4.2vw, 54px);
    line-height: 1.04;
    letter-spacing: -0.04em;
}

.ew-register-lead {
    max-width: 760px;
    margin: 18px 0 0;
    font-size: clamp(17px, 1.45vw, 19px);
    line-height: 1.62;
}

.ew-register-table {
    display: grid;
    gap: 0;
    border: 1px solid rgba(52, 43, 33, 0.24);
    background: #f7efdf;
    box-shadow: 0 18px 50px rgba(22, 18, 14, 0.14);
}

.ew-register-table__head,
.ew-register-table__row {
    display: grid;
    grid-template-columns: minmax(110px, 0.8fr) minmax(110px, 0.75fr) minmax(150px, 1fr) minmax(260px, 2.4fr);
    gap: 0;
    align-items: stretch;
}

.ew-register-table__head {
    border-bottom: 1px solid rgba(52, 43, 33, 0.28);
    background: rgba(91, 32, 28, 0.08);
    color: #5b201c;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ew-register-table__head span,
.ew-register-table__row > span,
.ew-register-table__row > time,
.ew-register-table__row > h2 {
    margin: 0;
    padding: 15px 16px;
    border-right: 1px solid rgba(52, 43, 33, 0.18);
}

.ew-register-table__head span:last-child,
.ew-register-table__row > h2 {
    border-right: 0;
}

.ew-register-table__row {
    border-bottom: 1px solid rgba(52, 43, 33, 0.16);
}

.ew-register-table__row:last-child {
    border-bottom: 0;
}

.ew-register-table__code,
.ew-register-table__sector,
.ew-register-table__row time {
    color: #6f6253;
    font-size: 13px;
    line-height: 1.45;
}

.ew-register-table__code {
    color: #5b201c;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.ew-register-table__row h2 {
    font-size: clamp(16px, 1.6vw, 20px);
    line-height: 1.25;
    letter-spacing: -0.015em;
}

.ew-register-table__row h2 a {
    color: inherit;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

.ew-register-table__row h2 a:hover,
.ew-register-table__row h2 a:focus-visible {
    color: #7a2c26;
}

@media (max-width: 760px) {
    .ew-register-table {
        gap: 12px;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .ew-register-table__head {
        display: none;
    }

    .ew-register-table__row {
        display: grid;
        grid-template-columns: 1fr;
        border: 1px solid rgba(52, 43, 33, 0.2);
        background: #f7efdf;
        box-shadow: 0 12px 30px rgba(22, 18, 14, 0.1);
    }

    .ew-register-table__row > span,
    .ew-register-table__row > time,
    .ew-register-table__row > h2 {
        border-right: 0;
        border-bottom: 1px solid rgba(52, 43, 33, 0.12);
    }

    .ew-register-table__row > h2 {
        border-bottom: 0;
    }
}

/* --- EPICWORLD ATLAS V1: REGISTER ENTRY LINKS V1 --- */

.ew-front-register__more {
    margin: 7px 0 0;
    padding-top: 14px;
    border-top: 1px solid rgba(52, 43, 33, 0.16);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.ew-front-register__more a {
    color: #5b201c;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

.ew-front-register__more a:hover,
.ew-front-register__more a:focus-visible {
    color: #7a2c26;
}

/* --- EPICWORLD ATLAS V1: PAGE DOCUMENT V1 --- */

.ew-page-main {
    max-width: 980px;
    margin: 0 auto;
    padding: clamp(32px, 5vw, 72px) 20px clamp(56px, 7vw, 96px);
}

.ew-page {
    padding: clamp(26px, 4vw, 44px);
    border: 1px solid rgba(52, 43, 33, 0.22);
    background: #f4ead9;
    box-shadow: 0 22px 60px rgba(22, 18, 14, 0.18);
}

.ew-page-header {
    margin-bottom: 28px;
}

.ew-page-title {
    max-width: 780px;
    margin: 0;
    font-size: clamp(32px, 4vw, 50px);
    line-height: 1.06;
    letter-spacing: -0.04em;
}

.ew-page-content {
    max-width: 760px;
    font-size: 18px;
    line-height: 1.72;
}

.ew-page-content h2 {
    margin-top: 34px;
    margin-bottom: 6px;
    font-size: clamp(22px, 2.4vw, 30px);
    line-height: 1.18;
    letter-spacing: -0.025em;
}

.ew-page-content p {
    margin: 0 0 18px;
}

.ew-page-content a {
    color: #5b201c;
    font-weight: 700;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

.ew-page-content a:hover,
.ew-page-content a:focus-visible {
    color: #7a2c26;
}

/* --- EPICWORLD ATLAS V1: FOOTER BUREAU V1 --- */

.ew-site-footer {
    max-width: 1180px;
}

.ew-site-footer__inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 22px;
    padding-top: 18px;
    border-top: 1px solid rgba(215, 208, 196, 0.14);
}

.ew-site-footer__mark {
    display: grid;
    gap: 5px;
}

.ew-site-footer__mark strong {
    color: #d7d0c4;
    font-size: 13px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.ew-site-footer__mark span {
    color: rgba(215, 208, 196, 0.68);
    font-size: 13px;
    line-height: 1.45;
}

.ew-site-footer__nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px 14px;
}

.ew-site-footer__nav a {
    color: rgba(215, 208, 196, 0.78);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
    text-transform: uppercase;
}

.ew-site-footer__nav a:hover,
.ew-site-footer__nav a:focus-visible {
    color: #f1e8da;
}

@media (max-width: 620px) {
    .ew-site-footer__inner {
        flex-direction: column;
    }

    .ew-site-footer__nav {
        justify-content: flex-start;
    }
}

/* --- EPICWORLD ATLAS V1: PAPER DOCUMENT CONTRAST FIX V1 --- */

.ew-page,
.ew-register-header,
.ew-register-table {
    color: #342b21;
}

.ew-page-title,
.ew-register-title,
.ew-page-content h2,
.ew-page-content h3,
.ew-register-table__row h2 {
    color: #2f281f;
}

.ew-page .ew-front-kicker,
.ew-register-header .ew-front-kicker {
    color: rgba(91, 32, 28, 0.72);
}

.ew-page-content,
.ew-register-lead {
    color: #5b5146;
}

.ew-page-content p,
.ew-page-content li,
.ew-page-content blockquote {
    color: #5b5146;
}

.ew-page-content strong,
.ew-page-content b,
.ew-register-table__code {
    color: #5b201c;
}

.ew-page-content a,
.ew-register-table__row h2 a {
    color: #5b201c;
}

.ew-page-content a:hover,
.ew-page-content a:focus-visible,
.ew-register-table__row h2 a:hover,
.ew-register-table__row h2 a:focus-visible {
    color: #7a2c26;
}

/* --- EPICWORLD ATLAS V1: CATEGORY SECTOR DOSSIER V1 --- */

.ew-sector-main {
    max-width: 1180px;
    margin: 0 auto;
    padding: clamp(32px, 5vw, 72px) 20px clamp(56px, 7vw, 96px);
}

.ew-sector-header {
    margin-bottom: 28px;
    padding: clamp(26px, 4vw, 42px);
    border: 1px solid rgba(52, 43, 33, 0.22);
    background: #f4ead9;
    color: #342b21;
    box-shadow: 0 22px 60px rgba(22, 18, 14, 0.18);
}

.ew-sector-title {
    max-width: 780px;
    margin: 0;
    color: #2f281f;
    font-size: clamp(34px, 4.2vw, 54px);
    line-height: 1.06;
    letter-spacing: -0.04em;
}

.ew-sector-summary {
    max-width: 760px;
    margin-top: 18px;
    color: #5b5146;
    font-size: clamp(17px, 1.45vw, 19px);
    line-height: 1.62;
}

.ew-sector-summary p {
    margin: 0 0 16px;
}

.ew-sector-register {
    display: grid;
    border: 1px solid rgba(52, 43, 33, 0.24);
    background: #f7efdf;
    color: #342b21;
    box-shadow: 0 18px 50px rgba(22, 18, 14, 0.14);
}

.ew-sector-register__head,
.ew-sector-register__row {
    display: grid;
    grid-template-columns: minmax(110px, .75fr) minmax(110px, .7fr) minmax(260px, 2.4fr) minmax(110px, .65fr);
}

.ew-sector-register__head {
    border-bottom: 1px solid rgba(52, 43, 33, 0.28);
    background: rgba(91, 32, 28, 0.08);
    color: #5b201c;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.ew-sector-register__head span,
.ew-sector-register__row > span,
.ew-sector-register__row > time,
.ew-sector-register__row > h2 {
    margin: 0;
    padding: 15px 16px;
    border-right: 1px solid rgba(52, 43, 33, 0.18);
}

.ew-sector-register__head span:last-child,
.ew-sector-register__row > span:last-child {
    border-right: 0;
}

.ew-sector-register__row {
    border-bottom: 1px solid rgba(52, 43, 33, 0.16);
}

.ew-sector-register__row:last-child {
    border-bottom: 0;
}

.ew-sector-register__code {
    color: #5b201c;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.ew-sector-register__row time,
.ew-sector-register__status {
    color: #6f6253;
    font-size: 13px;
    line-height: 1.45;
}

.ew-sector-register__row h2 {
    color: #2f281f;
    font-size: clamp(16px, 1.6vw, 20px);
    line-height: 1.25;
    letter-spacing: -0.015em;
}

.ew-sector-register__row h2 a {
    color: inherit;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

.ew-sector-register__row h2 a:hover,
.ew-sector-register__row h2 a:focus-visible {
    color: #7a2c26;
}

@media (max-width: 760px) {
    .ew-sector-register {
        gap: 12px;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .ew-sector-register__head {
        display: none;
    }

    .ew-sector-register__row {
        display: grid;
        grid-template-columns: 1fr;
        border: 1px solid rgba(52, 43, 33, 0.2);
        background: #f7efdf;
        box-shadow: 0 12px 30px rgba(22, 18, 14, 0.1);
    }

    .ew-sector-register__row > span,
    .ew-sector-register__row > time,
    .ew-sector-register__row > h2 {
        border-right: 0;
        border-bottom: 1px solid rgba(52, 43, 33, 0.12);
    }

    .ew-sector-register__row > span:last-child {
        border-bottom: 0;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT ARCHIVE FOLIO FINAL V1 --- */

/*
 * Responsibility:
 * - front page reads as one opened archive folio;
 * - header is a folio strip, not a detached web bar;
 * - modules remain documents inside one archive set;
 * - old dark base is neutralized on the public shell;
 * - no sci-fi glow, no dashboard panels, no blog-card feed.
 */

body {
    background:
        linear-gradient(rgba(52, 43, 33, 0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(52, 43, 33, 0.045) 1px, transparent 1px),
        #d8cfbd;
    background-size: 18px 18px, 18px 18px, auto;
    color: #211d18;
}

.ew-site-header,
.ew-site-main,
.ew-site-footer {
    max-width: 1180px;
}

/* Header: first strip of the folio. */
.ew-site-header {
    margin: 18px auto 0;
    padding: 0 20px;
    color: #342b21;
}

.ew-site-header__inner {
    display: grid;
    grid-template-columns: minmax(260px, 1.1fr) minmax(240px, auto) minmax(250px, 0.9fr);
    align-items: center;
    gap: 26px;
    padding: 18px 18px 16px;
    border: 1px solid rgba(52, 43, 33, 0.22);
    background:
        linear-gradient(rgba(52, 43, 33, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(52, 43, 33, 0.03) 1px, transparent 1px),
        #eee6d7;
    background-size: 20px 20px, 20px 20px, auto;
    box-shadow: none;
}

.ew-site-identity {
    display: grid;
    gap: 10px;
}

.ew-site-title {
    margin: 0;
    color: #1f1b16;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(27px, 2.7vw, 34px);
    font-weight: 800;
    letter-spacing: 0.14em;
    line-height: 1;
    text-transform: uppercase;
}

.ew-site-title a {
    color: inherit;
    text-decoration: none;
}

.ew-site-tagline {
    margin: 0;
    color: #5e564c;
    font-size: 14px;
    line-height: 1.42;
}

.ew-site-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.ew-site-nav a {
    display: inline-flex;
    align-items: center;
    min-height: auto;
    padding: 1px 4px;
    border: 0;
    color: #5c5147;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.11em;
    line-height: 1.1;
    text-decoration: none;
    text-transform: uppercase;
    background: rgba(122, 44, 38, 0.11);
}

.ew-site-nav a:hover,
.ew-site-nav a:focus-visible {
    color: #211d18;
    background: rgba(122, 44, 38, 0.18);
}

.ew-site-search {
    justify-self: end;
    display: grid;
    gap: 6px;
    width: min(100%, 270px);
}

.ew-site-search input {
    width: 100%;
    min-height: 34px;
    padding: 7px 8px;
    border: 1px solid rgba(52, 43, 33, 0.3);
    border-right: 0;
    color: #342b21;
    font: inherit;
    font-size: 13px;
    background:
        repeating-linear-gradient(
            90deg,
            transparent 0 17px,
            rgba(52, 43, 33, 0.17) 18px 19px
        ),
        rgba(255, 255, 255, 0.18);
}

.ew-site-search input::placeholder {
    color: rgba(52, 43, 33, 0.62);
}

.ew-site-search button {
    display: none;
}

.ew-site-search span {
    color: #6c6155;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.22em;
    line-height: 1;
    text-transform: uppercase;
}

/* Front page: one large archive folio surface. */
.home .ew-front-main {
    margin: 0 auto 42px;
    padding: 20px 20px 56px;
    background:
        linear-gradient(rgba(52, 43, 33, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(52, 43, 33, 0.032) 1px, transparent 1px),
        #ddd5c6;
    background-size: 20px 20px, 20px 20px, auto;
    border: 1px solid rgba(52, 43, 33, 0.18);
    border-top: 0;
    box-shadow: 0 28px 80px rgba(34, 27, 20, 0.18);
}

.home .ew-front-dossier,
.home .ew-front-method,
.home .ew-front-classifier-section,
.home .ew-front-featured-object,
.home .ew-intake-log {
    margin-left: auto;
    margin-right: auto;
    border-color: rgba(52, 43, 33, 0.26);
    background:
        linear-gradient(rgba(52, 43, 33, 0.028) 1px, transparent 1px),
        linear-gradient(90deg, rgba(52, 43, 33, 0.022) 1px, transparent 1px),
        #eee7d8;
    background-size: 18px 18px, 18px 18px, auto;
    box-shadow: none;
}

.home .ew-front-dossier {
    margin-top: 24px;
    margin-bottom: 28px;
}

.home .ew-front-method,
.home .ew-front-classifier-section,
.home .ew-front-featured-object,
.home .ew-intake-log {
    margin-top: 28px;
    margin-bottom: 0;
}

.home .ew-front-dossier,
.home .ew-front-method,
.home .ew-front-classifier-section {
    outline: 1px solid rgba(52, 43, 33, 0.12);
    outline-offset: -10px;
}

/* Footer stays inside the same paper/desk language. */
.ew-site-footer {
    margin-top: 0;
    color: #342b21;
}

.ew-site-footer__inner {
    border-top-color: rgba(52, 43, 33, 0.2);
}

.ew-site-footer__mark strong,
.ew-site-footer__nav a {
    color: #4c4036;
}

.ew-site-footer__mark span {
    color: rgba(52, 43, 33, 0.68);
}

@media (max-width: 860px) {
    .ew-site-header__inner {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .ew-site-nav {
        justify-content: flex-start;
    }

    .ew-site-search {
        justify-self: stretch;
        width: 100%;
    }

    .home .ew-front-main {
        padding: 16px 16px 44px;
    }
}

@media (max-width: 520px) {
    .ew-site-header {
        margin-top: 5px;
        padding: 0 12px;
    }

    .ew-site-header__inner {
        padding: 14px 14px 13px;
    }

    .ew-site-nav {
        gap: 10px;
    }

    .home .ew-front-main {
        padding: 12px 12px 36px;
    }

    .home .ew-front-dossier,
    .home .ew-front-method,
    .home .ew-front-classifier-section {
        outline-offset: -7px;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT FOLIO BAIZE DESK V13 --- */

/*
 * Material correction over V12:
 * - preserve shell composition and ultratight document rhythm;
 * - replace drafting-grid desk with old green baize/felt office surface;
 * - keep paper documents warm and readable;
 * - avoid casino green, sci-fi glow, and decorative theatrical texture.
 */

body {
    background:
        radial-gradient(circle at 18% 14%, rgba(230, 225, 195, 0.055), transparent 22%),
        radial-gradient(circle at 76% 10%, rgba(12, 20, 13, 0.16), transparent 30%),
        radial-gradient(circle at 42% 86%, rgba(10, 18, 12, 0.18), transparent 34%),
        repeating-linear-gradient(
            0deg,
            rgba(255, 255, 255, 0.018) 0 1px,
            transparent 1px 4px
        ),
        repeating-linear-gradient(
            90deg,
            rgba(0, 0, 0, 0.022) 0 1px,
            transparent 1px 5px
        ),
        #42513f;
    background-size: auto, auto, auto, 100% 4px, 5px 100%, auto;
    color: #161411;
}

.ew-site-shell,
.ew-site-header,
.ew-site-main,
.ew-site-footer,
.home .ew-front-dossier,
.home .ew-front-method,
.home .ew-front-classifier-section,
.home .ew-front-featured-object,
.home .ew-intake-log {
    box-sizing: border-box;
}

/* Common archive folder. */
.home .ew-site-shell {
    max-width: 1180px;
    margin: 30px auto 30px;
    padding: 7px 7px 12px;
    border: 1px solid rgba(42, 37, 30, 0.32);
    background:
        linear-gradient(rgba(50, 44, 35, 0.028) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.02) 1px, transparent 1px),
        #c4bba9;
    background-size: 18px 18px, 18px 18px, auto;
    box-shadow: 4px 5px 0 rgba(18, 27, 19, 0.24);
}

/* Header as first internal sheet. */
.home .ew-site-header {
    max-width: none;
    margin: 0;
    padding: 0;
    color: #2b261f;
}

.home .ew-site-header__inner {
    box-sizing: border-box;
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(250px, auto) minmax(240px, 0.8fr);
    align-items: center;
    gap: 24px;
    min-height: 78px;
    padding: 16px 28px;
    border: 1px solid rgba(42, 37, 30, 0.25);
    background:
        linear-gradient(rgba(58, 50, 39, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(58, 50, 39, 0.016) 1px, transparent 1px),
        #e8e1d2;
    background-size: 18px 18px, 18px 18px, auto;
    box-shadow: 2px 2px 0 rgba(38, 34, 28, 0.12);
}

.home .ew-site-identity {
    display: grid;
    gap: 8px;
}

.home .ew-site-title {
    margin: 0;
    color: #161411;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 29px;
    font-weight: 800;
    letter-spacing: 0.18em;
    line-height: 1;
    text-transform: uppercase;
}

.home .ew-site-title a {
    color: inherit;
    text-decoration: none;
}

.home .ew-site-tagline {
    margin: 0;
    color: #5d564d;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 14px;
    line-height: 1.45;
}

.home .ew-site-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.home .ew-site-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 0;
    padding: 1px 5px 2px;
    border: 0;
    color: #4e463d;
    font-family: "Courier New", Courier, monospace;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.09em;
    line-height: 1.1;
    text-decoration: none;
    text-transform: uppercase;
    background: rgba(104, 46, 39, 0.13);
}

.home .ew-site-nav a:hover,
.home .ew-site-nav a:focus-visible {
    color: #161411;
    background: rgba(104, 46, 39, 0.22);
}

.home .ew-site-search {
    justify-self: end;
    display: grid;
    gap: 7px;
    width: min(100%, 240px);
}

.home .ew-site-search input {
    box-sizing: border-box;
    width: 100%;
    min-height: 31px;
    padding: 6px 8px;
    border: 1px solid rgba(46, 40, 32, 0.38);
    border-right: 0;
    color: #3b342b;
    font: inherit;
    font-size: 13px;
    background:
        repeating-linear-gradient(
            90deg,
            transparent 0 15px,
            rgba(48, 42, 34, 0.22) 16px 17px
        ),
        rgba(255, 255, 255, 0.13);
}

.home .ew-site-search input::placeholder {
    color: rgba(54, 48, 40, 0.62);
}

.home .ew-site-search button {
    display: none;
}

.home .ew-site-search span {
    color: #4f473d;
    font-family: "Courier New", Courier, monospace;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.24em;
    line-height: 1;
    text-transform: uppercase;
}

/* Document flow: almost touching sheet spacing. */
.home .ew-front-main {
    max-width: none;
    margin: 3px 0 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}

.home .ew-front-dossier,
.home .ew-front-method,
.home .ew-front-classifier-section,
.home .ew-front-featured-object,
.home .ew-intake-log {
    width: 100%;
    max-width: none;
    margin-left: 0;
    margin-right: 0;
    border: 1px solid rgba(42, 37, 30, 0.31);
    background:
        linear-gradient(rgba(50, 44, 35, 0.024) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.017) 1px, transparent 1px),
        #e9e3d5;
    background-size: 18px 18px, 18px 18px, auto;
    box-shadow: none;
    outline: 1px solid rgba(42, 37, 30, 0.15);
    outline-offset: -10px;
}

.home .ew-front-dossier {
    margin-top: 0;
    margin-bottom: 3px;
    min-height: 286px;
    padding: 34px 44px;
}

.home .ew-front-method,
.home .ew-front-classifier-section,
.home .ew-front-featured-object,
.home .ew-intake-log {
    margin-top: 3px;
    margin-bottom: 0;
    padding: 28px 28px;
}

.home .ew-front-dossier .ew-front-kicker,
.home .ew-front-bureau .ew-section-kicker,
.home .ew-front-featured-object .ew-front-kicker {
    color: #6d675d;
    font-family: "Courier New", Courier, monospace;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.24em;
    line-height: 1.25;
    text-transform: uppercase;
}

.home .ew-front-dossier .ew-front-title {
    max-width: 590px;
    margin-top: 24px;
    color: #151310;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(46px, 5vw, 58px);
    font-weight: 800;
    letter-spacing: -0.055em;
    line-height: 0.96;
}

.home .ew-front-dossier .ew-front-lead {
    max-width: 610px;
    margin-top: 26px;
    color: #27231d;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 16px;
    line-height: 1.62;
}

.home .ew-front-dossier .ew-read-more,
.home .ew-front-featured-object .ew-read-more {
    margin-top: 18px;
    padding: 12px 15px;
    border: 1px solid rgba(42, 37, 30, 0.48);
    color: #211d18;
    font-family: "Courier New", Courier, monospace;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    background: transparent;
}

/* Right register: keep drafting gap from external DOC index. */
.home .ew-front-register {
    box-sizing: border-box;
    align-self: start;
    margin-top: 34px;
    padding-top: 18px;
    border-color: rgba(42, 37, 30, 0.38);
    background: rgba(218, 211, 196, 0.68);
}

.home .ew-front-register__title {
    margin-top: 0;
    padding-top: 12px;
    color: #5c554b;
    font-family: "Courier New", Courier, monospace;
    font-size: 10px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
}

.home .ew-front-register__row {
    min-height: 42px;
    border-color: rgba(42, 37, 30, 0.2);
}

.home .ew-front-register__row span {
    color: #8c302b;
    font-family: "Courier New", Courier, monospace;
    font-size: 10px;
    letter-spacing: 0.08em;
}

.home .ew-front-register__row strong {
    color: #151310;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 13px;
    font-weight: 800;
}

.home .ew-front-bureau .ew-section-heading h2,
.home .ew-front-method h2,
.home .ew-front-featured-object__text h2 {
    color: #151310;
    font-size: clamp(28px, 3vw, 34px);
    line-height: 1.08;
    letter-spacing: -0.035em;
}

.home .ew-front-method p,
.home .ew-front-featured-object__text p {
    max-width: 760px;
    color: #27231d;
    font-size: 16px;
    line-height: 1.62;
}

.home .ew-classifier-register,
.home .ew-intake-log {
    box-sizing: border-box;
    width: 100%;
    border-color: rgba(42, 37, 30, 0.34);
}

.home .ew-classifier-register__row,
.home .ew-intake-log__head,
.home .ew-intake-log__row {
    border-color: rgba(42, 37, 30, 0.22);
}

.home .ew-classifier-register__row > div,
.home .ew-intake-log__head span,
.home .ew-intake-log__row > * {
    border-color: rgba(42, 37, 30, 0.18);
}

.home .ew-intake-log {
    box-shadow: none;
}

.home .ew-site-footer {
    max-width: none;
    margin: 4px 0 0;
    padding: 0;
    color: #342f28;
}

.home .ew-site-footer__inner {
    border-top-color: rgba(42, 37, 30, 0.22);
}

.home .ew-site-footer__mark strong,
.home .ew-site-footer__nav a {
    color: #342f28;
}

.home .ew-site-footer__mark span {
    color: rgba(52, 43, 33, 0.68);
}

@media (max-width: 860px) {
    .home .ew-site-shell {
        margin: 18px 12px 24px;
        padding: 6px 6px 14px;
    }

    .home .ew-site-header__inner {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 18px;
    }

    .home .ew-site-nav {
        justify-content: flex-start;
    }

    .home .ew-site-search {
        justify-self: stretch;
        width: 100%;
    }

    .home .ew-front-main {
        margin-top: 3px;
    }

    .home .ew-front-dossier {
        min-height: 0;
        margin-bottom: 3px;
        padding: 32px 24px;
    }

    .home .ew-front-method,
    .home .ew-front-classifier-section,
    .home .ew-front-featured-object,
    .home .ew-intake-log {
        margin-top: 3px;
        padding: 24px 22px;
    }

    .home .ew-front-register {
        margin-top: 0;
    }
}

@media (max-width: 520px) {
    .home .ew-site-title {
        font-size: 24px;
    }

    .home .ew-front-dossier .ew-front-title {
        font-size: 40px;
    }

    .home .ew-site-shell {
        margin-left: 8px;
        margin-right: 8px;
        padding: 5px 5px 12px;
    }

    .home .ew-front-dossier,
    .home .ew-front-method,
    .home .ew-front-classifier-section,
    .home .ew-front-featured-object,
    .home .ew-intake-log {
        outline-offset: -7px;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT FOLIO OFFICE MARK PATCH V14 --- */

/*
 * Targeted patch:
 * - make small upper office labels more legible on the green baize desk;
 * - add a diagonal red approval stamp to the archive protocol sheet;
 * - no structural changes.
 */

/* Stronger office micro-labels / upper inscriptions. */
.home .ew-front-dossier .ew-front-kicker,
.home .ew-front-bureau .ew-section-kicker,
.home .ew-front-featured-object .ew-front-kicker,
.home .ew-front-register__title,
.home .ew-site-search span {
    color: #494238;
    font-weight: 700;
}

/* Slightly darker header tagline for readability. */
.home .ew-site-tagline {
    color: #4f493f;
}

/* Archive protocol approval stamp. */
.home .ew-front-method {
    position: relative;
    overflow: hidden;
}

.home .ew-front-method::after {
    content: "УТВЕРЖДЕНО\AАДМИНИСТРАЦИЕЙ";
    white-space: pre;
    position: absolute;
    top: 28px;
    right: 44px;
    z-index: 3;
    pointer-events: none;

    padding: 8px 14px 7px;
    border: 3px solid rgba(143, 31, 27, 0.78);
    border-radius: 4px;

    color: rgba(143, 31, 27, 0.82);
    background: rgba(255, 255, 255, 0.03);

    font-family: "Courier New", Courier, monospace;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.08;
    letter-spacing: 0.08em;
    text-align: center;
    text-transform: uppercase;

    transform: rotate(-14deg);
}

/* Mobile: keep the stamp but make it smaller and safer. */
@media (max-width: 860px) {
    .home .ew-front-method::after {
        top: 22px;
        right: 20px;
        font-size: 15px;
        padding: 6px 10px 5px;
        border-width: 2px;
    }
}

@media (max-width: 520px) {
    .home .ew-front-method::after {
        position: static;
        display: inline-block;
        margin: 0 0 16px;
        transform: rotate(-10deg);
    }
}

/* --- EPICWORLD ATLAS V1: FRONT FOLIO KICKER VISIBILITY V15 --- */

/*
 * Targeted patch:
 * - strengthen the top office line above the front title;
 * - make "Архивное бюро / EpicWorld Atlas" clearly readable;
 * - no layout or structural changes.
 */

.home .ew-front-dossier .ew-front-kicker {
    color: #3f392f;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.18);
}

/* If the kicker uses nested spans/small labels, keep them visible too. */
.home .ew-front-dossier .ew-front-kicker span,
.home .ew-front-dossier .ew-front-kicker strong,
.home .ew-front-dossier .ew-front-kicker small {
    color: inherit;
}

/* --- EPICWORLD ATLAS V1: FRONT FOLIO KICKER VISIBILITY V15 --- */

/*
 * Targeted patch:
 * - strengthen the top office line above the front title;
 * - make "Архивное бюро / EpicWorld Atlas" clearly readable;
 * - no layout or structural changes.
 */

.home .ew-front-dossier .ew-front-kicker {
    color: #3f392f;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.18);
}

/* If the kicker uses nested spans/small labels, keep them visible too. */
.home .ew-front-dossier .ew-front-kicker span,
.home .ew-front-dossier .ew-front-kicker strong,
.home .ew-front-dossier .ew-front-kicker small {
    color: inherit;
}

/* --- EPICWORLD ATLAS V1: TOP OFFICE LINE SAFE V17 --- */

/*
 * Targeted correction:
 * - affect only the very top office line;
 * - do not touch title, nav, search, document labels, protocol stamp or content fonts.
 */

.home .ew-site-shell::before {
    color: rgba(42, 38, 31, 0.78) !important;
    opacity: 1 !important;
    font-family: "Courier New", Courier, monospace !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: 0.18em !important;
    line-height: 1 !important;
    text-transform: uppercase !important;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Safety only if the line is attached to header by an older rule. */
.home .ew-site-header::before {
    color: rgba(42, 38, 31, 0.78) !important;
    opacity: 1 !important;
    font-family: "Courier New", Courier, monospace !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: 0.18em !important;
    line-height: 1 !important;
    text-transform: uppercase !important;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* --- EPICWORLD ATLAS V1: READABLE FONT BUMP V18 --- */

/*
 * Targeted readability patch:
 * - slightly increase readable text across the archive documents;
 * - do not enlarge service codes, stamps, nav labels or table micro-labels;
 * - preserve compact bureaucratic rhythm.
 */

.home .ew-front-dossier .ew-front-lead,
.home .ew-front-method p,
.home .ew-front-featured-object__text p,
.ew-page-content,
.ew-register-lead,
.ew-sector-summary,
.ew-single-content {
    font-size: 17px;
}

.home .ew-front-register__row strong,
.home .ew-intake-log__row h3,
.ew-register-table__row h2,
.ew-sector-register__row h2 {
    font-size: calc(1em + 0.5px);
}

/* Keep classifier descriptions readable without turning them into body copy. */
.home .ew-classifier-register__row > div {
    font-size: calc(1em + 0.35px);
}

/* Do not scale stamps, codes, nav, search helper labels, or archive micro-markings. */
.home .ew-front-kicker,
.home .ew-section-kicker,
.home .ew-site-nav a,
.home .ew-site-search span,
.home .ew-front-register__row span,
.home .ew-register-code,
.home .ew-register-kind,
.home .ew-register-state,
.home .ew-intake-log__head,
.home .ew-intake-log__row time {
    font-size: inherit;
}

/* --- EPICWORLD ATLAS V1: FEATURED OBJECT MAP PREVIEW LAYOUT V19 --- */

/*
 * Targeted patch:
 * - control document must reserve composition space for future map preview;
 * - text column becomes gathered and dossier-like;
 * - image/preview column remains part of the document architecture;
 * - no global typography changes.
 */

.home .ew-front-featured-object {
    display: grid;
    grid-template-columns: minmax(0, 0.58fr) minmax(280px, 0.42fr);
    align-items: stretch;
    gap: 28px;
}

.home .ew-front-featured-object__text {
    max-width: 620px;
}

.home .ew-front-featured-object__text h2 {
    max-width: 580px;
    font-size: clamp(28px, 2.75vw, 38px);
    line-height: 1.04;
    letter-spacing: -0.04em;
}

.home .ew-front-featured-object__text p {
    max-width: 560px;
    font-size: 16px;
    line-height: 1.55;
}

.home .ew-front-featured-object .ew-read-more {
    margin-top: 16px;
}

/* Future map / scheme preview. */
.home .ew-front-featured-object__image {
    align-self: stretch;
    min-height: 220px;
    border: 1px solid rgba(42, 37, 30, 0.34);
    background:
        linear-gradient(rgba(50, 44, 35, 0.026) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.018) 1px, transparent 1px),
        rgba(218, 211, 196, 0.72);
    background-size: 18px 18px, 18px 18px, auto;
}

.home .ew-front-featured-object__image img {
    width: 100%;
    height: 100%;
    min-height: 220px;
    object-fit: cover;
    filter: sepia(0.08) contrast(0.96);
}

/*
 * Current dev fixture may have no featured image.
 * Keep the text gathered anyway; do not let it expand into a full-width poster.
 */
.home .ew-front-featured-object.is-without-image {
    grid-template-columns: minmax(0, 0.62fr) minmax(260px, 0.38fr);
}

.home .ew-front-featured-object.is-without-image::after {
    content: "ПРЕВЬЮ КАРТЫ\AБУДЕТ ПРИКРЕПЛЕНО";
    white-space: pre;
    display: grid;
    place-items: center;
    min-height: 220px;
    border: 1px dashed rgba(42, 37, 30, 0.28);
    color: rgba(74, 66, 55, 0.58);
    font-family: "Courier New", Courier, monospace;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.18em;
    line-height: 1.45;
    text-align: center;
    text-transform: uppercase;
    background:
        linear-gradient(rgba(50, 44, 35, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.016) 1px, transparent 1px),
        rgba(218, 211, 196, 0.42);
    background-size: 18px 18px, 18px 18px, auto;
}

@media (max-width: 860px) {
    .home .ew-front-featured-object,
    .home .ew-front-featured-object.is-without-image {
        grid-template-columns: 1fr;
    }

    .home .ew-front-featured-object__text,
    .home .ew-front-featured-object__text h2,
    .home .ew-front-featured-object__text p {
        max-width: none;
    }

    .home .ew-front-featured-object__image,
    .home .ew-front-featured-object__image img,
    .home .ew-front-featured-object.is-without-image::after {
        min-height: 190px;
    }
}

/* --- EPICWORLD ATLAS V1: FEATURED OBJECT MAP PREVIEW ENLARGE V20 --- */

/*
 * Targeted correction:
 * - map preview area must be a real document-side visual field;
 * - increase preview width and height;
 * - keep text column gathered.
 */

.home .ew-front-featured-object {
    grid-template-columns: minmax(0, 0.52fr) minmax(360px, 0.48fr);
    gap: 30px;
}

.home .ew-front-featured-object__text {
    max-width: 560px;
}

.home .ew-front-featured-object__text h2 {
    max-width: 540px;
    font-size: clamp(27px, 2.55vw, 36px);
    line-height: 1.05;
}

.home .ew-front-featured-object__text p {
    max-width: 520px;
    line-height: 1.55;
}

.home .ew-front-featured-object__image {
    min-height: 280px;
}

.home .ew-front-featured-object__image img {
    min-height: 280px;
}

/* Current no-image fixture: reserve the same real map space. */
.home .ew-front-featured-object.is-without-image {
    grid-template-columns: minmax(0, 0.52fr) minmax(360px, 0.48fr);
}

.home .ew-front-featured-object.is-without-image::after {
    min-height: 280px;
}

@media (max-width: 860px) {
    .home .ew-front-featured-object,
    .home .ew-front-featured-object.is-without-image {
        grid-template-columns: 1fr;
    }

    .home .ew-front-featured-object__image,
    .home .ew-front-featured-object__image img,
    .home .ew-front-featured-object.is-without-image::after {
        min-height: 220px;
    }
}

/* --- EPICWORLD ATLAS V1: FEATURED OBJECT MAP REFERENCE V21 --- */

/*
 * Reference correction:
 * - control document follows dossier + attached map layout;
 * - map preview is a primary archival exhibit, not a small thumbnail;
 * - text stays gathered on the left;
 * - right visual field takes a little more than half of the document.
 */

.home .ew-front-featured-object {
    display: grid;
    grid-template-columns: minmax(0, 0.44fr) minmax(460px, 0.56fr);
    align-items: stretch;
    gap: 28px;
    min-height: 400px;
}

.home .ew-front-featured-object__text {
    max-width: 460px;
    align-self: center;
}

.home .ew-front-featured-object__text h2 {
    max-width: 440px;
    font-size: clamp(30px, 3vw, 42px);
    line-height: 1.05;
    letter-spacing: -0.045em;
}

.home .ew-front-featured-object__text p {
    max-width: 420px;
    font-size: 16px;
    line-height: 1.55;
}

.home .ew-front-featured-object .ew-read-more {
    margin-top: 28px;
}

/* Map / scheme preview as full archival exhibit. */
.home .ew-front-featured-object__image {
    align-self: stretch;
    min-height: 360px;
    border: 1px solid rgba(42, 37, 30, 0.36);
    background:
        linear-gradient(rgba(50, 44, 35, 0.026) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.018) 1px, transparent 1px),
        rgba(218, 211, 196, 0.72);
    background-size: 18px 18px, 18px 18px, auto;
}

.home .ew-front-featured-object__image img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 360px;
    object-fit: cover;
    filter: sepia(0.08) contrast(0.96);
}

/* Current no-image fixture: reserve real map space. */
.home .ew-front-featured-object.is-without-image {
    grid-template-columns: minmax(0, 0.44fr) minmax(460px, 0.56fr);
}

.home .ew-front-featured-object.is-without-image::after {
    min-height: 360px;
    border: 1px dashed rgba(42, 37, 30, 0.3);
    background:
        linear-gradient(rgba(50, 44, 35, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.016) 1px, transparent 1px),
        rgba(218, 211, 196, 0.42);
    background-size: 18px 18px, 18px 18px, auto;
}

/* Small dossier caption under the future/current visual field. */
.home .ew-front-featured-object__image::after {
    content: "ТЕКУЩИЙ / ПРОВЕРЕНО / EW-DOC";
    display: block;
    margin-top: 5px;
    color: rgba(74, 66, 55, 0.68);
    font-family: "Courier New", Courier, monospace;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.18em;
    line-height: 1;
    text-align: right;
    text-transform: uppercase;
}

@media (max-width: 980px) {
    .home .ew-front-featured-object,
    .home .ew-front-featured-object.is-without-image {
        grid-template-columns: minmax(0, 0.48fr) minmax(360px, 0.52fr);
    }

    .home .ew-front-featured-object__text h2 {
        font-size: clamp(28px, 3.2vw, 36px);
    }
}

@media (max-width: 860px) {
    .home .ew-front-featured-object,
    .home .ew-front-featured-object.is-without-image {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .home .ew-front-featured-object__text,
    .home .ew-front-featured-object__text h2,
    .home .ew-front-featured-object__text p {
        max-width: none;
    }

    .home .ew-front-featured-object__image,
    .home .ew-front-featured-object__image img,
    .home .ew-front-featured-object.is-without-image::after {
        min-height: 240px;
    }
}

/* --- EPICWORLD ATLAS V1: FEATURED OBJECT MAP FIELD FIX V22 --- */

/*
 * Fix over V21:
 * - the map preview field must occupy the whole right half;
 * - no-image placeholder must behave like a real map sheet;
 * - text stays gathered on the left.
 */

.home .ew-front-featured-object {
    display: grid;
    grid-template-columns: minmax(0, 0.44fr) minmax(430px, 0.56fr);
    align-items: stretch;
    gap: 28px;
    min-height: 390px;
}

.home .ew-front-featured-object__text {
    grid-column: 1;
    max-width: 460px;
    align-self: center;
}

.home .ew-front-featured-object__text h2 {
    max-width: 440px;
    font-size: clamp(29px, 2.8vw, 40px);
    line-height: 1.05;
    letter-spacing: -0.045em;
}

.home .ew-front-featured-object__text p {
    max-width: 420px;
    font-size: 16px;
    line-height: 1.55;
}

/* Real image state. */
.home .ew-front-featured-object__image {
    grid-column: 2;
    align-self: stretch;
    justify-self: stretch;
    width: 100%;
    min-height: 350px;
    box-sizing: border-box;
}

.home .ew-front-featured-object__image img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 350px;
    object-fit: cover;
}

/* No-image state: make the placeholder a real map field. */
.home .ew-front-featured-object.is-without-image {
    grid-template-columns: minmax(0, 0.44fr) minmax(430px, 0.56fr);
}

.home .ew-front-featured-object.is-without-image::after {
    grid-column: 2;
    align-self: stretch;
    justify-self: stretch;
    display: grid;
    place-items: center;
    width: 100%;
    min-width: 0;
    min-height: 350px;
    box-sizing: border-box;

    content: "ПРЕВЬЮ КАРТЫ\AБУДЕТ ПРИКРЕПЛЕНО";
    white-space: pre;

    border: 1px dashed rgba(42, 37, 30, 0.3);
    color: rgba(74, 66, 55, 0.58);
    font-family: "Courier New", Courier, monospace;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.18em;
    line-height: 1.45;
    text-align: center;
    text-transform: uppercase;

    background:
        linear-gradient(rgba(50, 44, 35, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.016) 1px, transparent 1px),
        rgba(218, 211, 196, 0.42);
    background-size: 18px 18px, 18px 18px, auto;
}

@media (max-width: 980px) {
    .home .ew-front-featured-object,
    .home .ew-front-featured-object.is-without-image {
        grid-template-columns: minmax(0, 0.48fr) minmax(340px, 0.52fr);
    }
}

@media (max-width: 860px) {
    .home .ew-front-featured-object,
    .home .ew-front-featured-object.is-without-image {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .home .ew-front-featured-object__text,
    .home .ew-front-featured-object__text h2,
    .home .ew-front-featured-object__text p {
        max-width: none;
    }

    .home .ew-front-featured-object__image,
    .home .ew-front-featured-object__image img,
    .home .ew-front-featured-object.is-without-image::after {
        grid-column: 1;
        min-height: 230px;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT FOOTER HIDE V23 --- */

/*
 * Targeted patch:
 * - hide duplicated site footer on the front page only;
 * - keep footer.php and .ew-site-shell structure intact;
 * - do not affect protocol/register/category/single pages.
 */

.home .ew-site-footer {
    display: none;
}

/* --- EPICWORLD ATLAS V1: MAP PREVIEW SCALE V24 --- */

/*
 * Targeted correction:
 * - maps inside single posts must behave as archival previews;
 * - full-resolution image remains available through lightbox / direct media;
 * - do not let a map dominate the article text column.
 */

.single .ew-single-content .ew-figure--map,
.single .ew-content .ew-figure--map,
.single article .ew-figure--map {
    width: min(760px, 82%);
    max-width: 100%;
    margin: 24px auto 34px;
}

.single .ew-single-content .ew-figure--map img,
.single .ew-content .ew-figure--map img,
.single article .ew-figure--map img {
    display: block;
    width: 100%;
    height: auto;
}

.single .ew-single-content .ew-figure--map figcaption,
.single .ew-content .ew-figure--map figcaption,
.single article .ew-figure--map figcaption {
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
    font-size: 13px;
    line-height: 1.45;
    text-align: center;
}

@media (max-width: 760px) {
    .single .ew-single-content .ew-figure--map,
    .single .ew-content .ew-figure--map,
    .single article .ew-figure--map {
        width: 100%;
        margin: 20px auto 28px;
    }
}

/* --- EPICWORLD ATLAS V1: SINGLE FEATURED IMAGE HIDE V25 --- */

/*
 * Targeted correction:
 * - keep featured image for OG/Twitter/social previews;
 * - prevent automatic single-post thumbnail from duplicating the map above content;
 * - keep manually inserted .ew-figure--map visible inside the article.
 */

.single .ew-single-featured,
.single .ew-single-thumbnail,
.single .ew-single-figure,
.single .post-thumbnail,
.single .wp-post-image:not(.ew-figure--map img) {
    display: none;
}

/* Safety: explicitly keep archive map figures visible. */
.single .ew-figure--map,
.single .ew-figure--map img {
    display: block;
}

/* --- EPICWORLD ATLAS V1: INNER SHELL HEADER NORMALIZE V26 --- */

/*
 * Targeted correction after production migration:
 * - inner pages must use the same archival shell logic as the approved front page;
 * - header must be the first document sheet inside the case/folder, not a separate blog strip;
 * - do not change the already approved front-page layout.
 */

body:not(.home) .ew-site-shell {
    max-width: 1180px;
    margin: 30px auto 34px;
    padding: 7px 7px 18px;
    border: 1px solid rgba(42, 37, 30, 0.32);
    background:
        linear-gradient(rgba(50, 44, 35, 0.028) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.02) 1px, transparent 1px),
        #c4bba9;
    background-size: 18px 18px, 18px 18px, auto;
    box-shadow: 4px 5px 0 rgba(18, 27, 19, 0.24);
}

body:not(.home) .ew-site-header {
    max-width: none;
    margin: 0;
    padding: 0;
    color: #2b261f;
}

body:not(.home) .ew-site-header__inner {
    box-sizing: border-box;
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(250px, auto) minmax(240px, 0.8fr);
    align-items: center;
    gap: 24px;
    min-height: 78px;
    padding: 16px 28px;
    border: 1px solid rgba(42, 37, 30, 0.25);
    background:
        linear-gradient(rgba(58, 50, 39, 0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(58, 50, 39, 0.016) 1px, transparent 1px),
        #e8e1d2;
    background-size: 18px 18px, 18px 18px, auto;
    box-shadow: 2px 2px 0 rgba(38, 34, 28, 0.12);
}

body:not(.home) .ew-site-main {
    max-width: none;
    margin: 4px 0 0;
    padding: 0;
}

/* Remove old separator feeling between header and inner document. */
body:not(.home) .ew-site-header + .ew-site-main {
    border-top: 0;
}

/* Keep inner documents visually tied to the same case. */
body:not(.home) .ew-single-main,
body:not(.home) .ew-page-main,
body:not(.home) .ew-sector-main,
body:not(.home) .ew-register-main,
body:not(.home) .ew-search-main,
body:not(.home) .ew-archive-main {
    margin-top: 3px;
}

/* Header typography parity with approved front page. */
body:not(.home) .ew-site-title {
    margin: 0;
    color: #161411;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 29px;
    font-weight: 800;
    letter-spacing: 0.18em;
    line-height: 1;
    text-transform: uppercase;
}

body:not(.home) .ew-site-title a {
    color: inherit;
    text-decoration: none;
}

body:not(.home) .ew-site-tagline {
    margin: 0;
    color: #4f493f;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 14px;
    line-height: 1.45;
}

body:not(.home) .ew-site-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

body:not(.home) .ew-site-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 0;
    padding: 1px 5px 2px;
    border: 0;
    color: #4e463d;
    font-family: "Courier New", Courier, monospace;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.09em;
    line-height: 1.1;
    text-decoration: none;
    text-transform: uppercase;
    background: rgba(104, 46, 39, 0.13);
}

body:not(.home) .ew-site-search {
    justify-self: end;
    display: grid;
    gap: 7px;
    width: min(100%, 240px);
}

body:not(.home) .ew-site-search input {
    box-sizing: border-box;
    width: 100%;
    min-height: 31px;
    padding: 6px 8px;
    border: 1px solid rgba(46, 40, 32, 0.38);
    border-right: 0;
    color: #3b342b;
    font: inherit;
    font-size: 13px;
    background:
        repeating-linear-gradient(
            90deg,
            transparent 0 15px,
            rgba(48, 42, 34, 0.22) 16px 17px
        ),
        rgba(255, 255, 255, 0.13);
}

body:not(.home) .ew-site-search button {
    display: none;
}

body:not(.home) .ew-site-search span {
    color: #4f473d;
    font-family: "Courier New", Courier, monospace;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.24em;
    line-height: 1;
    text-transform: uppercase;
}

/* WordPress admin bar: prevent visual compression when logged in. */
.admin-bar body:not(.home) .ew-site-shell {
    margin-top: 26px;
}

@media (max-width: 860px) {
    body:not(.home) .ew-site-shell {
        margin: 18px 12px 28px;
        padding: 6px 6px 14px;
    }

    body:not(.home) .ew-site-header__inner {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 18px;
    }

    body:not(.home) .ew-site-nav {
        justify-content: flex-start;
    }

    body:not(.home) .ew-site-search {
        justify-self: stretch;
        width: 100%;
    }
}

@media (max-width: 520px) {
    body:not(.home) .ew-site-title {
        font-size: 24px;
    }

    body:not(.home) .ew-site-shell {
        margin-left: 8px;
        margin-right: 8px;
        padding: 5px 5px 12px;
    }
}

/* --- EPICWORLD ATLAS V1: SINGLE ARCHIVE HEAD FORM V27 --- */

/*
 * Targeted correction:
 * - the upper single-post archive label must behave like a document form header;
 * - remove the white empty slab effect;
 * - keep the single page inside the same archival case rhythm.
 */

.single .ew-single-main {
    background:
        linear-gradient(rgba(50, 44, 35, 0.024) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.017) 1px, transparent 1px),
        #e9e3d5;
    background-size: 18px 18px, 18px 18px, auto;
}

/* Top archive label area above the object table. */
.single .ew-single-head,
.single .ew-single-header,
.single .ew-single-intro,
.single .ew-single-kicker-row {
    background:
        linear-gradient(rgba(50, 44, 35, 0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.012) 1px, transparent 1px),
        rgba(214, 207, 193, 0.72);
    background-size: 18px 18px, 18px 18px, auto;
    border-bottom: 1px solid rgba(42, 37, 30, 0.34);
}

/* If the visible white slab is the first direct block inside the single document. */
.single .ew-single-main > header,
.single .ew-single-main > .ew-single-head,
.single .ew-single-main > .ew-single-header {
    padding: 26px 28px 18px;
    margin: 0;
    min-height: 0;
}

/* Service labels: keep them dry, visible, not decorative. */
.single .ew-single-main .ew-section-kicker,
.single .ew-single-main .ew-front-kicker,
.single .ew-single-main .ew-single-kicker,
.single .ew-single-main .ew-document-kicker {
    color: #5d564b;
    font-family: "Courier New", Courier, monospace;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.22em;
    line-height: 1.45;
    text-transform: uppercase;
}

/* Reduce excessive air before the object passport grid. */
.single .ew-single-main .ew-object-meta,
.single .ew-single-main .ew-single-meta-grid,
.single .ew-single-main .ew-document-meta,
.single .ew-single-main .ew-register-table {
    margin-top: 0;
}

/* The title block should continue the form, not start a separate white page. */
.single .ew-single-title,
.single .entry-title {
    margin-top: 32px;
}

@media (max-width: 760px) {
    .single .ew-single-main > header,
    .single .ew-single-main > .ew-single-head,
    .single .ew-single-main > .ew-single-header {
        padding: 20px 20px 16px;
    }
}

/* --- EPICWORLD ATLAS V1: SINGLE DOCUMENT TYPESET V30 --- */

/*
 * Targeted correction:
 * - single posts must look like archival documents, not landing pages;
 * - reduce poster-like title scale;
 * - restore proper document margins;
 * - keep map preview and SEO/social image behavior intact.
 */

.single .ew-single-main {
    box-sizing: border-box;
    padding: 0 0 46px;
    overflow: hidden;
}

.single .ew-single {
    box-sizing: border-box;
    max-width: 100%;
    margin: 0;
}

/* Passport grid: keep it precise, but give it document margins. */
.single .ew-dossier-meta {
    margin: 0 34px 0;
}

.single .ew-dossier-meta__grid {
    border-color: rgba(35, 31, 26, 0.78);
}

.single .ew-dossier-meta__grid > div {
    min-height: 86px;
    padding: 24px 16px 18px;
}

/* Title block: no hero-poster scale. */
.single .ew-single-header {
    padding: 34px 0 26px;
}

.single .ew-single-title,
.single .entry-title {
    max-width: 900px;
    margin: 34px 34px 18px;
    color: #161411;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(34px, 3.1vw, 48px);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.045em;
}

/* Small date line under title. */
.single .ew-single-meta {
    margin: 0 34px;
    color: #6b6256;
    font-family: "Courier New", Courier, monospace;
    font-size: 13px;
    letter-spacing: 0.03em;
}

/* Main article text: restore document fields and readable measure. */
.single .ew-single-content {
    box-sizing: border-box;
    max-width: 900px;
    margin: 32px 0 0;
    padding: 0 34px;
}

.single .ew-single-content p,
.single .ew-single-content li {
    max-width: 760px;
    color: #25211d;
    font-size: 18px;
    line-height: 1.72;
}

.single .ew-single-content p {
    margin: 0 0 22px;
}

.single .ew-single-content h2 {
    max-width: 760px;
    margin: 42px 0 18px;
    color: #161411;
    font-family: Arial, Helvetica, sans-serif;
    font-size: clamp(26px, 2.2vw, 34px);
    font-weight: 800;
    line-height: 1.14;
    letter-spacing: -0.035em;
}

/* First paragraph should not visually crash into the left border. */
.single .ew-single-content > p:first-child {
    margin-top: 0;
}

/* Map figure: keep as archival insert, aligned to text/document rhythm. */
.single .ew-single-content .ew-figure--map {
    width: min(760px, 100%);
    margin: 26px 0 36px;
}

.single .ew-single-content .ew-figure--map figcaption {
    max-width: 720px;
    text-align: left;
}

/* Object navigation should also sit inside document fields. */
.single .ew-object-nav {
    margin: 42px 34px 0;
}

/* Mobile safety. */
@media (max-width: 760px) {
    .single .ew-dossier-meta {
        margin-left: 18px;
        margin-right: 18px;
    }

    .single .ew-single-title,
    .single .entry-title {
        margin-left: 18px;
        margin-right: 18px;
        font-size: clamp(29px, 9vw, 38px);
    }

    .single .ew-single-meta {
        margin-left: 18px;
        margin-right: 18px;
    }

    .single .ew-single-content {
        padding-left: 18px;
        padding-right: 18px;
    }

    .single .ew-single-content p,
    .single .ew-single-content li {
        font-size: 17px;
        line-height: 1.68;
    }

    .single .ew-object-nav {
        margin-left: 18px;
        margin-right: 18px;
    }
}

/* --- EPICWORLD ATLAS V1: SINGLE FONT REFINE V31 --- */

/*
 * Targeted correction over V30:
 * - reduce single-post typography slightly for normal 100% browser zoom;
 * - keep document margins and archival rhythm from V30;
 * - do not affect front page, register, category, map, OG/Twitter image.
 */

.single .ew-single-title,
.single .entry-title {
    max-width: 860px;
    font-size: clamp(30px, 2.65vw, 42px);
    line-height: 1.1;
    letter-spacing: -0.04em;
}

.single .ew-single-content p,
.single .ew-single-content li {
    max-width: 740px;
    font-size: 17px;
    line-height: 1.68;
}

.single .ew-single-content p {
    margin-bottom: 20px;
}

.single .ew-single-content h2 {
    max-width: 740px;
    font-size: clamp(24px, 2vw, 30px);
    line-height: 1.16;
}

.single .ew-single-meta {
    font-size: 12px;
}

@media (max-width: 760px) {
    .single .ew-single-title,
    .single .entry-title {
        font-size: clamp(27px, 8vw, 35px);
    }

    .single .ew-single-content p,
    .single .ew-single-content li {
        font-size: 16.5px;
        line-height: 1.66;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT MAP INTAKE FIX V33 --- */

/*
 * Targeted front-page correction:
 * - do not crop archival map previews in the featured object block;
 * - keep full map visible as a document preview;
 * - stabilize intake log columns so date and ID do not overlap.
 */

.home .ew-front-featured-object__image {
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        linear-gradient(rgba(50, 44, 35, 0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(50, 44, 35, 0.012) 1px, transparent 1px),
        rgba(226, 218, 202, 0.46);
    background-size: 18px 18px, 18px 18px, auto;
}

.home .ew-front-featured-object__image img {
    width: 100%;
    height: 100%;
    object-fit: contain !important;
    object-position: center center;
}

/* Intake log: fixed bureaucratic columns without date/ID collision. */
.home .ew-intake-log__head,
.home .ew-intake-log__row {
    grid-template-columns:
        minmax(118px, 0.78fr)
        minmax(96px, 0.62fr)
        minmax(150px, 0.88fr)
        minmax(340px, 1.72fr)
        minmax(96px, 0.62fr);
}

.home .ew-intake-log__row time,
.home .ew-intake-code,
.home .ew-intake-sector,
.home .ew-intake-status {
    white-space: nowrap;
}

.home .ew-intake-log__row time,
.home .ew-intake-code {
    overflow: visible;
}

.home .ew-intake-log__row h3 {
    min-width: 0;
}

@media (max-width: 900px) {
    .home .ew-intake-log__head,
    .home .ew-intake-log__row {
        grid-template-columns: 1fr;
    }

    .home .ew-intake-log__row time,
    .home .ew-intake-code,
    .home .ew-intake-sector,
    .home .ew-intake-status {
        white-space: normal;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT FEATURED MAP BALANCE V34 --- */

/*
 * Targeted correction over V33:
 * - keep the map uncropped;
 * - make the map a real document preview, not a small label;
 * - reduce empty right-column paper around the map;
 * - move the DOC-003 label away from the border.
 */

.home .ew-front-featured-object {
    grid-template-columns: minmax(0, 0.40fr) minmax(560px, 0.60fr);
    align-items: center;
    column-gap: 34px;
    padding-top: 34px;
}

.home .ew-front-featured-object::before {
    top: 14px;
    right: 24px;
    z-index: 3;
    background: rgba(232, 225, 212, 0.82);
    padding-left: 8px;
}

.home .ew-front-featured-object__image {
    align-self: center;
    width: 100%;
    max-width: 640px;
    justify-self: end;
    aspect-ratio: 4 / 3;
    min-height: 0;
    height: auto;
    padding: 0;
    border: 1px solid rgba(42, 37, 30, 0.38);
    overflow: hidden;
    background: rgba(226, 218, 202, 0.32);
}

.home .ew-front-featured-object__image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain !important;
    object-position: center center;
}

/* Keep text compact enough so the map can breathe. */
.home .ew-front-featured-object__text {
    max-width: 430px;
}

.home .ew-front-featured-object__text h2 {
    max-width: 420px;
}

/* Medium screens: avoid horizontal pressure. */
@media (max-width: 1040px) {
    .home .ew-front-featured-object {
        grid-template-columns: minmax(0, 0.44fr) minmax(430px, 0.56fr);
        column-gap: 24px;
    }

    .home .ew-front-featured-object__image {
        max-width: 560px;
    }
}

@media (max-width: 760px) {
    .home .ew-front-featured-object {
        grid-template-columns: 1fr;
    }

    .home .ew-front-featured-object__image {
        justify-self: stretch;
        max-width: none;
        width: 100%;
    }

    .home .ew-front-featured-object::before {
        position: static;
        display: block;
        margin: 0 0 12px auto;
        width: max-content;
    }
}

/* --- EPICWORLD ATLAS V1: FRONT FEATURED MAP NATURAL V35 --- */

/*
 * Correction over V33/V34:
 * - map preview must not look like a small label inside an empty box;
 * - use the generated 4:3 image at natural document scale;
 * - keep it uncropped;
 * - prevent decorative overlays from fading the text/map layer.
 */

.home .ew-front-featured-object {
    grid-template-columns: minmax(0, 0.42fr) minmax(520px, 0.58fr);
    align-items: center;
    column-gap: 34px;
    padding: 30px 28px 28px;
}

/* Keep the document label visible but not colliding with the border. */
.home .ew-front-featured-object::before {
    top: 12px;
    right: 22px;
    z-index: 2;
    background: rgba(232, 225, 212, 0.9);
    padding: 0 0 0 8px;
}

/* Any decorative overlay must stay behind the content. */
.home .ew-front-featured-object::after {
    z-index: 0 !important;
    pointer-events: none;
}

/* Text and map must stay above paper overlays. */
.home .ew-front-featured-object__text,
.home .ew-front-featured-object__image {
    position: relative;
    z-index: 3;
    opacity: 1 !important;
}

/* Natural image document preview. */
.home .ew-front-featured-object__image {
    display: block;
    justify-self: end;
    width: 100%;
    max-width: 650px;
    height: auto !important;
    min-height: 0 !important;
    aspect-ratio: auto !important;
    padding: 0 !important;
    border: 1px solid rgba(42, 37, 30, 0.38);
    overflow: visible !important;
    background: transparent !important;
}

.home .ew-front-featured-object__image img {
    display: block;
    width: 100% !important;
    max-width: none !important;
    height: auto !important;
    aspect-ratio: auto !important;
    object-fit: unset !important;
    object-position: center center;
    opacity: 1 !important;
}

/* Undo excessive faded look inside the control document. */
.home .ew-front-featured-object__text,
.home .ew-front-featured-object__text h2,
.home .ew-front-featured-object__text p,
.home .ew-front-featured-object__text a {
    opacity: 1 !important;
}

@media (max-width: 1040px) {
    .home .ew-front-featured-object {
        grid-template-columns: minmax(0, 0.44fr) minmax(430px, 0.56fr);
        column-gap: 24px;
    }

    .home .ew-front-featured-object__image {
        max-width: 560px;
    }
}

@media (max-width: 760px) {
    .home .ew-front-featured-object {
        grid-template-columns: 1fr;
    }

    .home .ew-front-featured-object__image {
        justify-self: stretch;
        max-width: none;
    }

    .home .ew-front-featured-object::before {
        position: static;
        display: block;
        width: max-content;
        margin: 0 0 12px auto;
    }
}

/* --- EPICWORLD ATLAS V1: SINGLE EXCERPT DOCUMENT MARGIN V37 --- */

/*
 * Targeted correction:
 * - single post excerpt must not stick to the document edge;
 * - align excerpt with title/meta/content rhythm;
 * - CSS-only, no content update, no post_modified change.
 */

.single .ew-single-excerpt {
    box-sizing: border-box;
    max-width: 740px;
    margin: 0 34px 22px;
    color: #2c2721;
    font-size: 17px;
    line-height: 1.66;
}

@media (max-width: 760px) {
    .single .ew-single-excerpt {
        margin-left: 18px;
        margin-right: 18px;
        font-size: 16.5px;
        line-height: 1.64;
    }
}
