:root {
  --article-bg: #f4f1ff;
  --article-bg-soft: #f8f7ff;
  --article-surface: #ffffff;
  --article-text: #2f2f2f;
  --article-muted: #666666;
  --article-border: rgba(149, 129, 237, 0.25);
  --article-accent: #9581ed;
  --article-accent-light: #d9b1fe;
}

.articles-main,
.article-main {
  padding: 18px 0 88px;
  min-height: calc(100vh - 200px);
}

.container {
  max-width: 1290px;
  margin: 0 auto;
  padding: 0 20px;
}

.breadcrumb {
  line-height: 17px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  row-gap: 6px;
  font-size: 14px;
  margin-bottom: 13px;
  font-weight: 500;
  color: rgba(96, 96, 96, 1);
}

.breadcrumb__link {
  text-decoration: none;
  color: inherit;
  transition: color 0.2s ease;
  text-transform: uppercase;
}

.breadcrumb__link:hover {
  color: var(--article-accent);
}

.breadcrumb__sep {
  margin: 0 8px;
  color: rgba(0, 0, 0, 1);
}

.breadcrumb__link--current {
  color: var(--article-accent);
}

.articles-hero,
.article-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(149, 129, 237, 0.16), rgba(217, 177, 254, 0.14));
  border: 1px solid var(--article-border);
  border-radius: 32px;
  padding: 40px;
}

.articles-hero::after,
.article-hero::after {
  content: "";
  position: absolute;
  width: 320px;
  height: 320px;
  right: -120px;
  top: -160px;
  background: radial-gradient(circle, rgba(149, 129, 237, 0.32) 0%, rgba(149, 129, 237, 0) 72%);
  pointer-events: none;
}

.articles-title,
.article-title {
  font-size: clamp(30px, 5vw, 52px);
  line-height: 1.05;
  margin: 0 0 18px;
  color: var(--article-text);
}

.articles-description,
.article-summary {
  max-width: 820px;
  margin: 0;
  color: var(--article-muted);
  font-size: 18px;
  line-height: 1.55;
}

.articles-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 26px 0 30px;
}

.articles-chip {
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(55, 55, 55, 0.12);
  color: #434343;
  text-decoration: none;
  font-size: 13px;
  line-height: 1;
  font-weight: 600;
  background: var(--article-surface);
  transition: all 0.2s ease;
}

.articles-chip:hover,
.articles-chip.active {
  border-color: transparent;
  color: #ffffff;
  background: linear-gradient(90deg, var(--article-accent), var(--article-accent-light));
}

.articles-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.article-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px;
  border-radius: 28px;
  border: 1px solid rgba(58, 58, 58, 0.08);
  background: var(--article-surface);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.05);
  text-decoration: none;
  color: inherit;
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.1);
}

.article-card--featured {
  grid-column: span 2;
  background: linear-gradient(145deg, #ffffff, var(--article-bg-soft));
  border: 1px solid var(--article-border);
}

.article-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #717171;
  font-weight: 600;
}

.article-card__tag {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(149, 129, 237, 0.14);
  color: #4f3f98;
}

.article-card__title {
  margin: 0;
  font-size: clamp(22px, 3.2vw, 34px);
  line-height: 1.2;
  color: #272727;
}

.article-card__excerpt {
  margin: 0;
  color: var(--article-muted);
  font-size: 16px;
  line-height: 1.55;
}

.article-card__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.article-card__list li {
  position: relative;
  padding-left: 16px;
  color: #4a4a4a;
  font-size: 14px;
  line-height: 1.45;
}

.article-card__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--article-accent);
}

.article-card__footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #5f45c3;
  font-size: 14px;
  font-weight: 700;
}

.articles-seo-panel {
  position: sticky;
  top: 22px;
  height: fit-content;
  border: 1px solid rgba(149, 129, 237, 0.28);
  border-radius: 24px;
  background: #ffffff;
  padding: 24px;
}

.articles-seo-panel h2 {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 1.2;
  color: #2d2d2d;
}

.articles-seo-panel p {
  margin: 0 0 16px;
  color: #626262;
  font-size: 15px;
  line-height: 1.45;
}

.articles-seo-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.articles-seo-list li {
  position: relative;
  padding-left: 15px;
  color: #434343;
  font-size: 14px;
  line-height: 1.4;
}

.articles-seo-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--article-accent), var(--article-accent-light));
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 28px;
  margin-top: 26px;
}

.article-content {
  border: 1px solid rgba(58, 58, 58, 0.08);
  border-radius: 30px;
  background: #ffffff;
  padding: 30px;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.05);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 20px 0 0;
  color: #595959;
  font-size: 13px;
  font-weight: 600;
}

.article-meta__dot {
  opacity: 0.45;
}

.article-content h2,
.article-content h3 {
  color: #2d2d2d;
  line-height: 1.2;
}

.article-content h2 {
  margin: 38px 0 14px;
  font-size: clamp(24px, 3vw, 34px);
}

.article-content h3 {
  margin: 24px 0 12px;
  font-size: clamp(19px, 2.2vw, 24px);
}

.article-content p {
  margin: 0 0 14px;
  font-size: 17px;
  line-height: 1.6;
  color: #444444;
}

.article-content ul,
.article-content ol {
  margin: 0 0 18px;
  padding-left: 20px;
  color: #444444;
}

.article-content li {
  margin-bottom: 9px;
  line-height: 1.55;
}

.article-callout {
  padding: 18px;
  border-left: 4px solid var(--article-accent);
  border-radius: 14px;
  background: rgba(149, 129, 237, 0.08);
  margin: 22px 0;
}

.article-callout p {
  margin: 0;
}

.article-hack-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0 0 24px;
}

.article-hack {
  border: 1px solid rgba(149, 129, 237, 0.3);
  background: #faf8ff;
  border-radius: 14px;
  padding: 14px;
}

.article-hack h4 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.3;
  color: #303030;
}

.article-hack p {
  margin: 0;
  font-size: 14px;
  line-height: 1.45;
}

.article-faq {
  margin-top: 30px;
  border-top: 1px solid rgba(58, 58, 58, 0.1);
  padding-top: 24px;
}

.article-faq-item {
  border: 1px solid rgba(58, 58, 58, 0.08);
  border-radius: 14px;
  padding: 14px;
  background: #ffffff;
  margin-bottom: 10px;
}

.article-faq-item h4 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.4;
}

.article-faq-item p {
  margin: 0;
  font-size: 15px;
}

.article-share {
  border: 1px solid rgba(58, 58, 58, 0.08);
  border-radius: 20px;
  background: #ffffff;
  padding: 20px;
}

.article-share h3,
.article-toc h3,
.article-template-guide h3 {
  margin: 0 0 12px;
  font-size: 20px;
  line-height: 1.25;
}

.article-share p,
.article-template-guide p,
.article-toc p {
  margin: 0;
  color: #636363;
  font-size: 14px;
  line-height: 1.5;
}

.article-share + .article-toc,
.article-toc + .article-template-guide {
  margin-top: 12px;
}

.article-toc,
.article-template-guide {
  border: 1px solid rgba(58, 58, 58, 0.08);
  border-radius: 20px;
  background: #ffffff;
  padding: 20px;
}

.article-toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.article-toc a {
  color: #4534a5;
  text-decoration: none;
  font-size: 14px;
  line-height: 1.35;
}

.article-toc a:hover {
  text-decoration: underline;
}

.article-template-guide ul {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.article-template-guide li {
  position: relative;
  padding-left: 15px;
  font-size: 14px;
  line-height: 1.4;
  color: #434343;
}

.article-template-guide li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--article-accent);
}

.article-side {
  position: sticky;
  top: 22px;
  align-self: flex-start;
}

.article-cta {
  margin-top: 28px;
  padding: 22px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(149, 129, 237, 0.18), rgba(217, 177, 254, 0.2));
  border: 1px solid rgba(149, 129, 237, 0.3);
}

.article-cta h3 {
  margin: 0 0 10px;
  font-size: 24px;
  line-height: 1.2;
}

.article-cta p {
  margin: 0 0 16px;
}

.article-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 20px;
  border-radius: 999px;
  border: 0;
  text-decoration: none;
  color: #ffffff;
  background: linear-gradient(90deg, #856ff0, #bf85f3);
  font-size: 14px;
  font-weight: 700;
}

.article-btn--ghost {
  background: #ffffff;
  color: #2d2d2d;
  border: 1px solid rgba(58, 58, 58, 0.16);
}

.article-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

@media (max-width: 1150px) {
  .articles-layout,
  .article-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .articles-seo-panel,
  .article-side {
    position: static;
  }
}

@media (max-width: 900px) {
  .articles-hero,
  .article-hero,
  .article-content {
    border-radius: 24px;
    padding: 24px;
  }

  .articles-grid,
  .article-hack-grid {
    grid-template-columns: 1fr;
  }

  .article-card--featured {
    grid-column: auto;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 15px;
  }

  .articles-main,
  .article-main {
    padding: 10px 0 62px;
  }

  .articles-description,
  .article-summary,
  .article-content p {
    font-size: 16px;
  }

  .article-content {
    padding: 20px;
  }

  .article-content h2 {
    margin-top: 28px;
  }
}

@media (max-width: 560px) {
  .articles-hero,
  .article-hero {
    padding: 18px;
  }

  .article-card {
    border-radius: 20px;
    padding: 18px;
  }

  .article-share,
  .article-toc,
  .article-template-guide,
  .articles-seo-panel {
    border-radius: 16px;
    padding: 16px;
  }

  .article-btn,
  .article-btn--ghost {
    width: 100%;
  }
}

.article-figure {
  margin: 22px 0 26px;
  border: 1px solid rgba(149, 129, 237, 0.24);
  border-radius: 20px;
  overflow: hidden;
  background: #ffffff;
}

.article-figure img {
  display: block;
  width: 100%;
  height: auto;
}

.article-figure figcaption {
  margin: 0;
  padding: 11px 14px 13px;
  font-size: 13px;
  line-height: 1.45;
  color: #5d5870;
  background: rgba(149, 129, 237, 0.06);
}

@media (max-width: 560px) {
  .article-figure {
    border-radius: 14px;
  }

  .article-figure figcaption {
    font-size: 12px;
    padding: 10px 11px 11px;
  }
}
