.seo-topic-cluster {
  width: min(1160px, calc(100% - 40px));
  margin: 34px auto 0;
}

.seo-topic-cluster__inner {
  background: linear-gradient(180deg, rgba(18, 23, 32, 0.92), rgba(10, 12, 18, 0.96));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  padding: clamp(22px, 3vw, 32px);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.08), 0 24px 70px rgba(0, 0, 0, 0.22);
}

.seo-topic-cluster__head {
  display: grid;
  gap: 8px;
  max-width: 760px;
  margin-bottom: 18px;
}

.seo-topic-cluster__eyebrow {
  color: var(--accent, #c47af5);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.72rem;
  font-weight: 850;
}

.seo-topic-cluster h2 {
  margin: 0;
  color: #f7f3ff;
  font-family: var(--font-h, "Space Grotesk", sans-serif);
  font-size: clamp(1.45rem, 2.7vw, 2.25rem);
  line-height: 1.08;
  letter-spacing: 0;
  font-weight: 850;
}

.seo-topic-cluster p {
  margin: 0;
  color: rgba(233, 224, 244, 0.72);
  font-size: 0.94rem;
  line-height: 1.7;
}

.seo-topic-cluster__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.seo-topic-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 158px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  color: inherit;
  text-decoration: none;
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.seo-topic-card:hover {
  transform: translateY(-1px);
  border-color: rgba(196, 122, 245, 0.38);
  background: rgba(255, 255, 255, 0.09);
}

.seo-topic-card:focus-visible {
  outline: 3px solid rgba(196, 122, 245, 0.42);
  outline-offset: 3px;
}

.seo-topic-card__label {
  width: max-content;
  max-width: 100%;
  color: #d7c3ff;
  background: rgba(196, 122, 245, 0.12);
  border: 1px solid rgba(196, 122, 245, 0.24);
  border-radius: 999px;
  padding: 5px 8px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-size: 0.64rem;
  font-weight: 850;
}

.seo-topic-card strong {
  color: #fff;
  font-size: 0.95rem;
  line-height: 1.25;
}

.seo-topic-card span:last-child {
  color: rgba(226, 232, 240, 0.68);
  font-size: 0.78rem;
  line-height: 1.5;
}

:root[data-theme="light"] .seo-topic-cluster__inner {
  background: linear-gradient(180deg, rgba(255, 251, 245, 0.96), rgba(242, 236, 228, 0.96));
  border-color: rgba(60, 52, 42, 0.14);
  box-shadow: 0 18px 44px rgba(60, 52, 42, 0.08), inset 0 1px rgba(255, 255, 255, 0.88);
}

:root[data-theme="light"] .seo-topic-cluster h2,
:root[data-theme="light"] .seo-topic-card strong {
  color: #211d18;
}

:root[data-theme="light"] .seo-topic-cluster p {
  color: #5f564d;
}

:root[data-theme="light"] .seo-topic-card {
  background: rgba(255, 255, 255, 0.58);
  border-color: rgba(60, 52, 42, 0.14);
}

:root[data-theme="light"] .seo-topic-card:hover {
  border-color: rgba(123, 79, 168, 0.28);
  background: rgba(255, 255, 255, 0.82);
}

:root[data-theme="light"] .seo-topic-card__label {
  color: #6d3da1;
  background: rgba(123, 79, 168, 0.09);
  border-color: rgba(123, 79, 168, 0.18);
}

:root[data-theme="light"] .seo-topic-card span:last-child {
  color: #655d54;
}

@media (max-width: 1080px) {
  .seo-topic-cluster__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .seo-topic-cluster {
    width: min(100% - 28px, 1160px);
    margin-top: 24px;
  }

  .seo-topic-cluster__inner {
    border-radius: 20px;
    padding: 18px;
  }

  .seo-topic-cluster__head {
    gap: 6px;
    margin-bottom: 14px;
  }

  .seo-topic-cluster h2 {
    font-size: clamp(1.32rem, 6vw, 1.72rem);
    line-height: 1.12;
  }

  .seo-topic-cluster p {
    font-size: 0.88rem;
    line-height: 1.55;
  }

  .seo-topic-cluster__grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .seo-topic-card {
    min-height: 0;
    gap: 6px;
    border-radius: 14px;
    padding: 13px;
  }

  .seo-topic-card__label {
    padding: 4px 7px;
    font-size: 0.6rem;
  }

  .seo-topic-card strong {
    font-size: 0.9rem;
  }

  .seo-topic-card span:last-child {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }
}
