.nml-nsp {
    padding: 136px 0 80px !important;
    background: var(--color-bg);
}

.nml-nsp__post {
    max-width: 798px;
    margin: 0 auto;
}

/* ── Шапка записи ── */
.nml-nsp__head {
    margin-bottom: 32px;
}

.nml-nsp__meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
    justify-content: center;
}

.nml-nsp__date {
    font-size: 14px;
    line-height: 20px;
    font-weight: 700;
    text-transform: uppercase;
    color: #303D60;
}

/* Цвет тега приходит инлайном, как в карточках ленты. */
.nml-nsp__badge {
    padding: 2px 12px;
    border: 1px solid currentColor;
    border-radius: 999px;
    font-size: 14px;
    line-height: 20px;
    font-weight: 500;
    color: var(--nml-nsp-color, var(--color-text-tertiary));
}

.nml-nsp__title {
    margin: 0;
    font-size: 48px;
    line-height: 56px;
    font-weight: 700;
    color: #0B101F;
    text-align: center;
}

/* ── Обложка ── */
.nml-nsp__thumb {
    margin-bottom: 32px;
}

.nml-nsp__thumb img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 12px;
    border: 1px solid var(--color-line);
    box-shadow: 0px 1px 2px 0px #4C83F333;
}

/* ── Контент ── */
.nml-nsp__content p {
    margin: 0 0 16px;
    font-size: 16px;
    line-height: 24px;
    font-weight: 500;
    color: var(--color-text-secondary);
}

.nml-nsp__content p:last-child {
    margin-bottom: 0;
}

.nml-nsp__content h2 {
    margin: 48px 0 16px;
    font-size: 32px;
    line-height: 40px;
    font-weight: 700;
    color: var(--color-text-primary);
}

.nml-nsp__content h3 {
    margin: 40px 0 16px;
    font-size: 24px;
    line-height: 32px;
    font-weight: 700;
    color: var(--color-text-primary);
}

.nml-nsp__content h4,
.nml-nsp__content h5 {
    margin: 32px 0 12px;
    font-size: 18px;
    line-height: 26px;
    font-weight: 700;
    color: var(--color-text-primary);
}

/* Списки — маркеры рисуем сами, как в блоге */
.nml-nsp__content ul,
.nml-nsp__content ol {
    margin: 0 0 20px;
    padding-left: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nml-nsp__content ul li,
.nml-nsp__content ol li {
    position: relative;
    padding-left: 32px;
    font-size: 16px;
    line-height: 24px;
    font-weight: 500;
    color: var(--color-text-secondary);
}

.nml-nsp__content ul li::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 8px;
    height: 8px;
    margin: 8px;
    border-radius: 50%;
    background: var(--color-accent);
}

.nml-nsp__content ol {
    counter-reset: nml-nsp-ol;
}

.nml-nsp__content ol li {
    counter-increment: nml-nsp-ol;
}

.nml-nsp__content ol li::before {
    content: counter(nml-nsp-ol) '.';
    position: absolute;
    top: 0;
    left: 0;
    font-size: 15px;
    font-weight: 700;
    color: var(--color-accent);
}

.nml-nsp__content a {
    color: var(--color-accent);
    font-weight: 600;
    text-decoration-line: underline;
    transition: all 0.3s;
}

.nml-nsp__content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
}

.nml-nsp__content blockquote {
    margin: 24px 0;
    padding: 20px 24px;
    border-left: 3px solid var(--color-accent);
    border-radius: 0 8px 8px 0;
    background: var(--color-bg-secondary);
    font-size: 17px;
    line-height: 27px;
    font-weight: 500;
    font-style: italic;
    color: var(--color-text-primary);
}

.nml-nsp__content code {
    padding: 2px 6px;
    border-radius: 4px;
    background: var(--color-bg-secondary);
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: var(--color-accent);
}

.nml-nsp__content pre {
    margin: 0 0 24px;
    padding: 20px 24px;
    border-radius: 10px;
    background: #0B101F;
    color: #E8EAFF;
    font-size: 14px;
    line-height: 22px;
    overflow-x: auto;
}

.nml-nsp__content pre code {
    padding: 0;
    background: none;
    color: inherit;
}

/* Широкая таблица прокручивается внутри себя, а не растягивает страницу */
.nml-nsp__content .wp-block-table,
.nml-nsp__content figure.wp-block-table {
    overflow-x: auto;
}

.nml-nsp__content table {
    width: 100%;
    margin: 0 0 24px;
    border-collapse: collapse;
    font-size: 15px;
}

.nml-nsp__content th,
.nml-nsp__content td {
    padding: 12px 16px;
    border: 1px solid var(--color-line);
    text-align: left;
}

.nml-nsp__content th {
    background: var(--color-bg-secondary);
    font-weight: 700;
    color: var(--color-text-primary);
}

.nml-nsp__content hr {
    margin: 32px 0;
    border: none;
    border-top: 1px solid var(--color-line);
}

.nml-nsp__content figcaption,
.nml-nsp__content .wp-caption-text {
    margin-top: 8px;
    font-size: 13px;
    line-height: 20px;
    color: var(--color-text-tertiary);
}

@media (max-width: 768px) {
    .nml-nsp {
        padding: 96px 0 40px !important
    }

    .nml-nsp__head {
        margin-bottom: 24px;
    }

    .nml-nsp__meta {
        justify-content: flex-start;
    }

    .nml-nsp__title {
        font-size: 32px;
        line-height: 40px;
        text-align: left;
    }

    .nml-nsp__thumb {
        margin-bottom: 24px;
    }

    .nml-nsp__thumb img {
        border-radius: 8px;
    }

    .nml-nsp__content p {
        font-size: 14px;
        line-height: 20px;
    }

    .nml-nsp__content h4, .nml-nsp__content h5 {
        margin: 16px 0 8px;
        font-size: 16px;
        line-height: 24px;
    }

    .nml-nsp__content h2 {
        margin: 32px 0 12px;
        font-size: 24px;
        line-height: 32px;
    }

    .nml-nsp__content h3 {
        margin: 28px 0 12px;
        font-size: 20px;
        line-height: 28px;
    }
}
