/* Промо карьерного теста — home / course / profession / blog */

.home-section--career-test-promo {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.home-career-test-promo {
  position: relative;
  /* Own typography baseline so parent article styles cannot inflate rem/line-height */
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--home-text, #f8fafc);
  border-radius: 1rem;
  border: 1px solid rgba(45, 212, 191, 0.28);
  background:
    radial-gradient(circle at top left, rgba(45, 212, 191, 0.14), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.72));
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.home-career-test-promo--embedded {
  margin: 1.75rem 0 0;
}

body.landing-blog .post-content .home-career-test-promo--embedded {
  margin: 1.75rem 0;
}

/*
 * Blog .post-content leaks h2 margins, img margins, link colors, ul list-style.
 * Match homepage promo metrics (same selectors win by specificity).
 */
body.landing-blog .blog-post-landing .post-content .home-career-test-promo h2.home-career-test-promo__title,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo .home-career-test-promo__title {
  margin: 0;
  font-size: clamp(1.15rem, 2.2vw, 1.4rem);
  font-weight: 700;
  line-height: 1.3;
  color: var(--home-text, #f8fafc);
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo * {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo p {
  margin: 0;
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo .home-career-test-promo__eyebrow {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--home-cta, #2dd4bf);
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo .home-career-test-promo__text {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--home-muted, rgba(226, 232, 240, 0.78));
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo ul.home-career-test-promo__perks,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo .home-career-test-promo__perks {
  list-style: none;
  list-style-position: outside;
  margin: 0;
  padding: 0;
  padding-inline-start: 0;
  margin-inline-start: 0;
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo .home-career-test-promo__perks li {
  margin: 0;
  line-height: 1.6;
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo .home-career-test-promo__avatar img {
  margin: 0;
  border-radius: 0;
  max-width: none;
  width: 1.55rem;
  height: 1.55rem;
}

body.landing-blog .blog-post-landing .post-content .home-career-test-promo a.home-career-test-promo__btn,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo a.home-career-test-promo__btn:hover,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo a.home-career-test-promo__btn:focus,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo a.home-career-test-promo__btn:focus-visible,
body.landing-blog .blog-post-landing .post-content .home-career-test-promo a.home-career-test-promo__btn:visited {
  color: var(--home-cta-text, #0f172a) !important;
  text-decoration: none;
  font-size: 1rem;
  line-height: 1.6;
}

.home-career-test-promo__glow {
  position: absolute;
  inset: -40% auto auto -12%;
  width: min(20rem, 58%);
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(45, 212, 191, 0.22), transparent 68%);
  pointer-events: none;
}

.home-career-test-promo__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "header action"
    "title action"
    "content action";
  column-gap: 1.75rem;
  row-gap: 1rem;
  align-items: start;
  padding: clamp(1.25rem, 3vw, 1.75rem) clamp(1.25rem, 3.2vw, 1.85rem);
}

.home-career-test-promo__header {
  grid-area: header;
  display: flex;
  align-items: center;
}

.home-career-test-promo__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
}

.home-career-test-promo__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid rgba(45, 212, 191, 0.34);
  background: #000;
  box-shadow: 0 0 0 3px rgba(45, 212, 191, 0.08);
  overflow: hidden;
}

.home-career-test-promo__avatar img {
  display: block;
  width: 1.55rem;
  height: 1.55rem;
  margin: 0;
  border-radius: 0;
  max-width: none;
  object-fit: contain;
}

.home-career-test-promo__eyebrow {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--home-cta, #2dd4bf);
}

.home-career-test-promo__title {
  grid-area: title;
  margin: 0;
  width: 100%;
  font-size: clamp(1.15rem, 2.2vw, 1.4rem);
  font-weight: 700;
  line-height: 1.3;
  color: var(--home-text, #f8fafc);
  text-wrap: balance;
}

.home-career-test-promo__content {
  grid-area: content;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-width: 0;
}

.home-career-test-promo__text {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--home-muted, rgba(226, 232, 240, 0.78));
  text-align: justify;
  text-wrap: pretty;
}

.home-career-test-promo__perks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.55rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.home-career-test-promo__perks li {
  display: inline-flex;
  align-items: center;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 0.02em;
  color: var(--home-cta, #2dd4bf);
  border: 1px solid rgba(45, 212, 191, 0.38);
  background: rgba(45, 212, 191, 0.08);
}

.home-career-test-promo__action {
  grid-area: action;
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
}

.home-career-test-promo__btn,
.home-career-test-promo__btn:hover,
.home-career-test-promo__btn:focus,
.home-career-test-promo__btn:focus-visible {
  font-size: 1rem;
  line-height: 1.6;
  text-decoration: none;
  white-space: nowrap;
}

@media (max-width: 860px) {
  .home-career-test-promo__inner {
    grid-template-columns: 1fr;
    grid-template-areas:
      "header"
      "title"
      "content"
      "action";
    column-gap: 0;
  }

  .home-career-test-promo__action {
    justify-content: flex-start;
    align-self: stretch;
  }
}

@media (max-width: 575px) {
  .home-career-test-promo__inner {
    row-gap: 0.9rem;
    padding: 1.15rem 1.1rem;
  }

  .home-career-test-promo__brand {
    width: 100%;
  }

  .home-career-test-promo__title {
    font-size: 1.12rem;
  }

  .home-career-test-promo__action {
    width: 100%;
  }

  .home-career-test-promo__btn {
    width: 100%;
    justify-content: center;
    white-space: normal;
    text-align: center;
  }

  .home-career-test-promo__perks {
    gap: 0.4rem;
  }
}
