/* =============================================
   BLOG — список статей
   ============================================= */

.seo-blog-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
}

.seo-blog-hero {
  text-align: center;
  padding: 2.5rem 1rem 2rem;
}

.seo-blog-hero__title {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: .5rem;
}

.seo-blog-hero__sub {
  color: #6b7280;
  font-size: 1rem;
}

.seo-blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.seo-blog-card {
  display: flex;
  flex-direction: column;
  border-radius: 1rem;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e5e7eb;
  text-decoration: none;
  color: inherit;
  transition: box-shadow .2s, transform .2s;
}

.seo-blog-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,.1);
  transform: translateY(-2px);
}

.seo-blog-card__img-wrap {
  height: 200px;
  overflow: hidden;
  background: #f3f4f6;
}

.seo-blog-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s;
}

.seo-blog-card:hover .seo-blog-card__img {
  transform: scale(1.05);
}

.seo-blog-card__body {
  padding: 1.1rem 1.25rem 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: .35rem;
}

.seo-blog-card__tag {
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: #2563eb;
}

.seo-blog-card__title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.seo-blog-card__desc {
  font-size: .875rem;
  color: #6b7280;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.seo-blog-card__date {
  font-size: .75rem;
  color: #9ca3af;
  margin-top: auto;
  padding-top: .5rem;
}

.seo-blog-pager {
  display: flex;
  justify-content: center;
  gap: .5rem;
  margin-top: 2.5rem;
}

.seo-blog-pager__btn {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: .5rem;
  border: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .875rem;
  text-decoration: none;
  color: #374151;
  transition: background .15s;
}

.seo-blog-pager__btn--active,
.seo-blog-pager__btn:hover {
  background: #2563eb;
  color: #fff;
  border-color: #2563eb;
}

/* =============================================
   BLOG — статья
   ============================================= */

.seo-article-wrap {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 1rem 4rem;
}

.seo-article-hero {
  position: relative;
  height: 320px;
  border-radius: 1.25rem;
  overflow: hidden;
  margin-bottom: 2rem;
}

.seo-article-hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.seo-article-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.5) 0%, transparent 60%);
}

.seo-article-hero__content {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  right: 1.5rem;
}

.seo-article-hero__tag {
  display: inline-block;
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  color: #fff;
  background: rgba(255,255,255,.2);
  border: 1px solid rgba(255,255,255,.4);
  border-radius: 2rem;
  padding: .2rem .75rem;
  text-decoration: none;
  margin-bottom: .6rem;
  backdrop-filter: blur(4px);
}

.seo-article-hero__title {
  font-size: 1.75rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.3;
  margin: 0 0 .4rem;
  text-shadow: 0 1px 4px rgba(0,0,0,.4);
}

.seo-article-hero__date {
  font-size: .8rem;
  color: rgba(255,255,255,.8);
}

.seo-article-body {
  margin-top: 0;
}

/* CTA блок */
.seo-article-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: .875rem;
  padding: 1rem 1.25rem;
  margin-bottom: 2rem;
}

.seo-article-cta--bottom {
  margin-top: 2.5rem;
  margin-bottom: 0;
}

.seo-article-cta__text {
  flex: 1;
  font-size: .9rem;
  color: #1e3a5f;
  line-height: 1.5;
}

/* Контент статьи */
.seo-article-content {
  font-size: 1rem;
  line-height: 1.8;
  color: #1f2937;
}

.seo-article-content h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin: 2.5rem 0 .75rem;
  color: #111827;
  padding-top: .5rem;
  border-top: 2px solid #f3f4f6;
}

.seo-article-content p {
  margin: 0 0 1.1rem;
}

.seo-article-content ul {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
}

.seo-article-content ul li {
  padding: .35rem 0 .35rem 1.5rem;
  position: relative;
  line-height: 1.6;
}

.seo-article-content ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: #2563eb;
  font-weight: 600;
}

/* Врезка с советом */
.blog-tip {
  background: #f0fdf4;
  border-left: 4px solid #22c55e;
  border-radius: 0 .5rem .5rem 0;
  padding: .85rem 1.1rem;
  margin: 1.25rem 0 1.5rem;
  font-size: .9rem;
  line-height: 1.6;
  color: #14532d;
}

.blog-tip strong {
  color: #16a34a;
}

.seo-article-back {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #f3f4f6;
}

.seo-article-back__link {
  font-size: .875rem;
  color: #6b7280;
  text-decoration: none;
  transition: color .15s;
}

.seo-article-back__link:hover {
  color: #2563eb;
}

/* React blog content */
.blog-content h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin: 2.5rem 0 .75rem;
  padding-top: .5rem;
  border-top: 2px solid #f3f4f6;
}

.blog-content p  { margin: 0 0 1.1rem; line-height: 1.8; }

.blog-content ul {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
}

.blog-content ul li {
  padding: .35rem 0 .35rem 1.5rem;
  position: relative;
  line-height: 1.6;
}

.blog-content ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: #2563eb;
  font-weight: 600;
}

.blog-content .blog-tip {
  background: #f0fdf4;
  border-left: 4px solid #22c55e;
  border-radius: 0 .5rem .5rem 0;
  padding: .85rem 1.1rem;
  margin: 1.25rem 0 1.5rem;
  font-size: .9rem;
  line-height: 1.6;
  color: #14532d;
}

.blog-content .blog-tip strong { color: #16a34a; }

@media (max-width: 640px) {
  .seo-article-hero  { height: 220px; border-radius: .75rem; }
  .seo-article-hero__title { font-size: 1.3rem; }
  .seo-article-cta   { flex-direction: column; align-items: flex-start; }
  .seo-blog-grid     { grid-template-columns: 1fr; }
}

/* Цитата-лайфхак */
.seo-article-content blockquote,
.blog-content blockquote {
  margin: 1.25rem 0 1.5rem;
  padding: .9rem 1.1rem .9rem 1.25rem;
  border-left: 4px solid #6366f1;
  background: #f5f3ff;
  border-radius: 0 .75rem .75rem 0;
  font-style: italic;
  color: #3730a3;
  font-size: .95rem;
  line-height: 1.65;
}

.seo-article-content blockquote p,
.blog-content blockquote p {
  margin: 0;
}

/* =============================================
   BLOG MINI BLOCK (на страницах страны и главной)
   ============================================= */

.seo-blog-block__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.seo-blog-block__all {
  font-size: .875rem;
  color: #2563eb;
  text-decoration: none;
  white-space: nowrap;
}

.seo-blog-block__all:hover {
  text-decoration: underline;
}

.seo-blog-mini-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

@media (max-width: 900px) {
  .seo-blog-mini-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 500px) {
  .seo-blog-mini-grid { grid-template-columns: repeat(2, 1fr); gap: .625rem; }
}

.seo-blog-mini-card {
  display: flex;
  flex-direction: column;
  border-radius: .75rem;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e5e7eb;
  text-decoration: none;
  color: inherit;
  transition: box-shadow .2s, transform .2s;
}

.seo-blog-mini-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,.1);
  transform: translateY(-2px);
}

.seo-blog-mini-card__img-wrap {
  height: 120px;
  overflow: hidden;
  background: #f3f4f6;
}

.seo-blog-mini-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .3s;
}

.seo-blog-mini-card:hover .seo-blog-mini-card__img {
  transform: scale(1.05);
}

.seo-blog-mini-card__body {
  padding: .625rem .75rem .75rem;
  display: flex;
  flex-direction: column;
  gap: .25rem;
  flex: 1;
}

.seo-blog-mini-card__tag {
  font-size: .7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #2563eb;
}

.seo-blog-mini-card__title {
  font-size: .8rem;
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: #111827;
}

/* Фото внутри статьи */
.blog-figure {
  margin: 1.75rem 0;
  border-radius: .875rem;
  overflow: hidden;
}

.blog-figure__img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  display: block;
}

/* Таблицы в статье */
.seo-article-content table,
.blog-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0 1.5rem;
  font-size: .9rem;
}

.seo-article-content th,
.blog-content th {
  background: #f3f4f6;
  font-weight: 600;
  text-align: left;
  padding: .6rem .85rem;
  border: 1px solid #e5e7eb;
}

.seo-article-content td,
.blog-content td {
  padding: .55rem .85rem;
  border: 1px solid #e5e7eb;
  vertical-align: top;
}

.seo-article-content tr:nth-child(even) td,
.blog-content tr:nth-child(even) td {
  background: #f9fafb;
}

/* Dark mode таблицы */
@media (prefers-color-scheme: dark) {
  .blog-content th { background: #1f2937; border-color: #374151; }
  .blog-content td { border-color: #374151; }
  .blog-content tr:nth-child(even) td { background: #111827; }
}

/* Dark mode через класс .dark */
.dark .blog-content th { background: #1f2937; border-color: #374151; color: #f9fafb; }
.dark .blog-content td { border-color: #374151; color: #e5e7eb; }
.dark .blog-content tr:nth-child(even) td { background: #111827; }
.dark .blog-content table { color: #e5e7eb; }

/* Мобильная прокрутка таблицы */
.blog-content table {
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}