@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/Inter-400-cyrillic-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/Inter-400-cyrillic.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/Inter-400-latin-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/Inter-400-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/Inter-500-cyrillic-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/Inter-500-cyrillic.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/Inter-500-latin-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/Inter-500-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/Inter-600-cyrillic-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/Inter-600-cyrillic.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/Inter-600-latin-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/Inter-600-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/Inter-700-cyrillic-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/Inter-700-cyrillic.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/Inter-700-latin-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/Inter-700-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/JM-400-cyrillic-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/JM-400-cyrillic.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/JM-400-latin-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/JM-400-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/JM-500-cyrillic-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/JM-500-cyrillic.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/JM-500-latin-ext.woff2') format('woff2');
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/JM-500-latin.woff2') format('woff2');
}
/* Блог esin48.ru — та же лексика, что и главная.
   Палитра, тёмная тема и переключатель — в /css/palette.css (подключается до этого файла). */

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.wrap { max-width: 680px; margin: 0 auto; padding: 64px 24px 40px; }

.crumbs {
    font-family: var(--mono);
    font-size: 0.78rem;
    color: var(--muted);
    margin-bottom: 28px;
}
.crumbs a { color: var(--accent); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }

h1.blog-title {
    font-size: 1.7rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 6px;
}
h1.blog-title a { color: var(--text); text-decoration: none; }
h1.blog-title a:hover { color: var(--accent); }

.blog-sub { color: var(--muted); font-size: 0.95rem; margin-bottom: 34px; }

.post-card { padding: 20px 0; border-bottom: 1px solid var(--line); }
.post-card:last-of-type { border-bottom: none; }
.post-card h2 { font-size: 1.15rem; font-weight: 600; margin-bottom: 2px; }
.post-card h2 a { color: var(--text); text-decoration: none; }
.post-card h2 a:hover { color: var(--accent); }

.meta { font-family: var(--mono); font-size: 0.75rem; color: var(--muted); margin-bottom: 8px; }
.excerpt { color: var(--muted); font-size: 0.93rem; line-height: 1.6; }
.excerpt p { margin: 0; }

.post h1 { font-size: 1.7rem; line-height: 1.25; letter-spacing: -0.02em; margin-bottom: 6px; }

.post .content { line-height: 1.75; font-size: 1rem; margin-top: 26px; }
.post .content p { margin-bottom: 15px; }
.post .content h2, .post .content h3 { margin: 28px 0 10px; letter-spacing: -0.01em; }
.post .content ul, .post .content ol { margin: 0 0 15px 24px; }
.post .content blockquote {
    border-left: 3px solid var(--line);
    padding: 2px 0 2px 18px;
    margin: 0 0 15px;
    color: var(--muted);
}
.post .content pre {
    background: var(--pre-bg); color: var(--pre-text); padding: 16px 18px; border-radius: 10px;
    overflow-x: auto; margin-bottom: 15px; font-size: 0.85em;
    font-family: var(--mono);
}
.post .content code {
    font-family: var(--mono); font-size: 0.87em;
    background: var(--code-bg); padding: 2px 6px; border-radius: 5px;
}
.post .content pre code { background: none; padding: 0; }
.post .content img { max-width: 100%; border-radius: 10px; border: 1px solid var(--line); }
.post .content a { color: var(--accent); }
.post .content table { border-collapse: collapse; margin-bottom: 15px; width: 100%; }
.post .content td, .post .content th { border: 1px solid var(--line); padding: 7px 11px; font-size: 0.92em; }
.post .content th { background: var(--surface); text-align: left; }

.post-nav {
    display: flex; justify-content: space-between; gap: 16px;
    margin-top: 40px; padding-top: 18px; border-top: 1px solid var(--line);
}
.post-nav a { color: var(--accent); text-decoration: none; font-family: var(--mono); font-size: 0.8rem; max-width: 46%; }
.post-nav a:hover { color: var(--accent-dark); text-decoration: underline; }

.empty { text-align: center; color: var(--muted); padding: 48px 0; font-size: 0.95rem; }

footer {
    margin-top: 72px; padding-top: 20px; border-top: 1px solid var(--line);
    font-family: var(--mono); font-size: 0.74rem; color: var(--muted);
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
}
footer a { color: var(--muted); text-decoration: none; border-bottom: 1px dotted var(--line); }
footer a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.footer-channels { display: inline-flex; align-items: center; gap: 12px; }
.footer-channels a { border-bottom: none; display: inline-flex; align-items: center; }
.footer-channels svg { width: 18px; height: 18px; fill: currentColor; }
.footer-legal { flex-basis: 100%; margin-top: 6px; font-size: 0.62rem; opacity: 0.75; }

@media (max-width: 560px) {
    .wrap { padding: 40px 18px 30px; }
    h1.blog-title, .post h1 { font-size: 1.4rem; }
}

/* ——— теги ——— */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.tag {
    font-family: var(--mono);
    font-size: 0.74rem;
    color: var(--muted);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 3px 10px;
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
}
.tag:hover { color: var(--accent); border-color: var(--accent); }
.tag.active { color: var(--accent-dark); border-color: var(--accent); background: var(--accent-soft); }
.tag.clear { color: var(--muted); }
.tag.clear:hover { color: var(--danger); border-color: var(--danger); }
.tag-n { opacity: 0.6; font-size: 0.68rem; }
.post-card .tags, .post .tags { margin: 4px 0 10px; }

/* ——— обложки постов ——— */
.post-card { display: flex; gap: 18px; align-items: flex-start; }
.post-card-body { flex: 1; min-width: 0; }
.post-cover { flex-shrink: 0; }
.post-cover img {
    width: 160px; height: 110px; object-fit: cover; border-radius: 10px;
    border: 1px solid var(--line); display: block;
}
.post-cover-img {
    width: 100%; max-height: 340px; object-fit: cover; border-radius: 12px;
    border: 1px solid var(--line); margin-bottom: 18px;
}
@media (max-width: 560px) {
    .post-card { flex-direction: column-reverse; gap: 10px; }
    .post-cover img { width: 100%; height: 160px; }
}

/* ——— встроенные видео (YouTube) ——— */
figure.video {
    position: relative; width: 100%; aspect-ratio: 16 / 9;
    margin: 0 0 18px; border-radius: 12px; overflow: hidden;
    border: 1px solid var(--line); background: var(--pre-bg);
}
figure.video iframe {
    position: absolute; inset: 0; width: 100%; height: 100%; border: 0;
}
