/* Delta VPN Blog — читаемый стиль, выделенные блоки */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ── Основные переменные (в духе сайта) ─────────────────────────────────── */
:root {
  --blog-bg: #010101;
  --blog-card: #0f0f0f;
  --blog-text: #e0e0e0;
  --blog-muted: #b2b2b2;
  --blog-accent: #6b8cff;
  --blog-border: #2a2a2a;
  --blog-radius: 8px;
  --blog-font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ── Список постов ──────────────────────────────────────────────────────── */
.blog-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 24px 20px 48px;
}

.blog-title {
  font-size: 1.75rem;
  font-weight: 700;
  text-align: center;
  color: #fff;
  margin-bottom: 36px;
}

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

.blog-post {
  background: var(--blog-card);
  border: 1px solid var(--blog-border);
  border-radius: var(--blog-radius);
  overflow: hidden;
}

.blog-post:hover {
  border-color: #3a3a3a;
}

.post-image {
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: #1a1a1a;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-content {
  padding: 20px;
}

.post-content h2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 8px;
}

.post-description {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--blog-muted);
  margin-bottom: 12px;
}

.read-more {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--blog-accent);
  text-decoration: none;
}

.read-more:hover {
  text-decoration: underline;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
  font-size: 0.8rem;
  color: var(--blog-muted);
}

.category {
  background: rgba(107, 140, 255, 0.2);
  color: var(--blog-accent);
  padding: 4px 10px;
  border-radius: 4px;
}

.no-posts {
  text-align: center;
  padding: 48px 20px;
  color: var(--blog-muted);
}

/* ── Страница поста ──────────────────────────────────────────────────────── */
.blog-detail {
  max-width: 680px;
  margin: 0 auto;
  padding: 32px 20px 48px;
  color: var(--blog-text);
}

.blog-header {
  margin-bottom: 32px;
}

.blog-header h1 {
  font-size: 1.9rem;
  font-weight: 700;
  line-height: 1.3;
  color: #fff;
  margin-bottom: 12px;
}

.blog-detail .post-image {
  height: auto;
  max-height: 360px;
  margin: 20px 0;
  border-radius: var(--blog-radius);
}

.blog-detail .post-image img {
  width: 100%;
  height: auto;
  display: block;
}

.blog-meta {
  font-size: 0.9rem;
  color: var(--blog-muted);
}

/* ── Контент: текст, заголовки, списки ───────────────────────────────────── */
.blog-content {
  font-size: 1.05rem;
  line-height: 1.7;
}

.blog-content p {
  margin-bottom: 1.2em;
}

.blog-content p:last-child {
  margin-bottom: 0;
}

.blog-content h2 {
  font-size: 1.4rem;
  font-weight: 600;
  color: #fff;
  margin: 2em 0 0.6em;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--blog-border);
}

.blog-content h3 {
  font-size: 1.2rem;
  font-weight: 600;
  color: #fff;
  margin: 1.6em 0 0.5em;
}

.blog-content h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #fff;
  margin: 1.4em 0 0.4em;
}

.blog-content ul, .blog-content ol {
  margin: 1em 0;
  padding-left: 1.5em;
}

.blog-content li {
  margin-bottom: 0.4em;
}

/* ── Цитаты и выделенные блоки ──────────────────────────────────────────── */
.blog-content blockquote {
  margin: 1.5em 0;
  padding: 16px 20px;
  background: rgba(107, 140, 255, 0.08);
  border-left: 4px solid var(--blog-accent);
  border-radius: 0 6px 6px 0;
  color: var(--blog-text);
  font-style: normal;
}

/* Варианты выделенных блоков (можно добавить в редакторе класс) */
.blog-content blockquote.callout-info,
.blog-content .callout-info {
  background: rgba(107, 140, 255, 0.1);
  border-left-color: #6b8cff;
}

.blog-content blockquote.callout-tip,
.blog-content .callout-tip {
  background: rgba(46, 204, 113, 0.08);
  border-left-color: #2ecc71;
}

.blog-content blockquote.callout-warning,
.blog-content .callout-warning {
  background: rgba(243, 156, 18, 0.08);
  border-left-color: #f39c12;
}

.blog-content blockquote.callout-important,
.blog-content .callout-important {
  background: rgba(231, 76, 60, 0.08);
  border-left-color: #e74c3c;
}

.blog-content a {
  color: var(--blog-accent);
  text-decoration: none;
}

.blog-content a:hover {
  text-decoration: underline;
}

.blog-content img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
}

.blog-content pre {
  background: #1a1a1a;
  padding: 16px;
  border-radius: 6px;
  overflow-x: auto;
  margin: 1.2em 0;
  font-size: 0.9rem;
  border: 1px solid var(--blog-border);
}

.blog-content code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9em;
  background: rgba(255,255,255,0.06);
  padding: 2px 6px;
  border-radius: 4px;
}

.blog-content pre code {
  background: none;
  padding: 0;
}

.blog-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.2em 0;
  font-size: 0.95rem;
}

.blog-content th, .blog-content td {
  padding: 10px 14px;
  border: 1px solid var(--blog-border);
  text-align: left;
}

.blog-content th {
  background: rgba(255,255,255,0.04);
  font-weight: 600;
  color: #fff;
}

/* ── Адаптив ────────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .blog-container, .blog-detail {
    padding-left: 16px;
    padding-right: 16px;
  }

  .post-image {
    height: 160px;
  }

  .blog-header h1 {
    font-size: 1.5rem;
  }

  .blog-content {
    font-size: 1rem;
  }

  .blog-content h2 {
    font-size: 1.25rem;
  }
}
