/* Backlink Monitors homepage visual refinement v1
   Loaded only by pages/home_page.html. It does not alter inner pages. */

.home-stream {
  overflow: clip;
}

.home-stream .section {
  padding: 88px 0;
}

.home-stream .section-heading {
  max-width: 790px;
  margin-bottom: 44px;
}

.home-stream .section-heading h2,
.home-stream .rich-text-section h2 {
  text-wrap: balance;
}

.home-stream .section-heading p,
.home-stream .rich-text {
  text-wrap: pretty;
}

/* Hero: clearer line breaks and a calmer first viewport. */
.home-block-1 .hero-section {
  padding: 88px 0 62px;
}

.home-block-1 .hero-grid {
  grid-template-columns: minmax(0, 1.08fr) minmax(380px, .92fr);
  gap: 58px;
}

.home-block-1 .hero-copy h1 {
  max-width: 11.5ch;
  font-size: clamp(44px, 5.55vw, 72px);
  line-height: .97;
  letter-spacing: -.043em;
  text-wrap: balance;
}

.home-block-1 .hero-copy .lead {
  max-width: 59ch;
  font-size: 18px;
}

.home-block-1 .bm-mini-card {
  box-shadow: 0 44px 110px -48px rgba(0, 0, 0, .92), 0 0 70px -48px rgba(46, 230, 166, .65);
}

/* Stats visually belong to the hero instead of opening another large chapter. */
.home-block-2 .section {
  padding: 0 0 70px;
}

.home-block-2 .stats-grid {
  gap: 0;
  overflow: hidden;
  border: 1px solid var(--bm-line);
  border-radius: 18px;
  background: var(--bm-line);
}

.home-block-2 .stat-card {
  border: 0;
  border-radius: 0;
  background: rgba(8, 13, 15, .88);
  padding: 25px 26px;
}

/* Editorial split section. */
.home-block-3 .section {
  border-top: 1px solid var(--bm-line);
  border-bottom: 1px solid var(--bm-line);
  background:
    radial-gradient(650px 360px at 10% 10%, rgba(46, 230, 166, .075), transparent 68%),
    rgba(255, 255, 255, .012);
}

.home-block-3 .container.narrow {
  max-width: 1160px;
  display: grid;
  grid-template-columns: minmax(250px, .72fr) minmax(0, 1.28fr);
  grid-template-rows: auto 1fr;
  column-gap: 82px;
  align-items: start;
}

.home-block-3 .eyebrow {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
}

.home-block-3 h2 {
  grid-column: 1;
  grid-row: 2;
  margin: 20px 0 0;
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.02;
}

.home-block-3 .rich-text {
  grid-column: 2;
  grid-row: 1 / span 2;
  font-size: 17px;
  line-height: 1.78;
}

.home-block-3 .rich-text p:last-child {
  margin-bottom: 0;
}

/* Platform hub: complete rows and compact navigational cards. */
.home-block-4 .content-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.home-block-4 .content-card {
  min-height: 235px;
  padding: 25px 23px 23px;
}

.home-block-4 .content-card h3 {
  font-size: 19px;
}

/* Reusable card polish. */
.home-stream .content-card {
  position: relative;
  overflow: hidden;
}

.home-stream .content-card-accent {
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  opacity: .72;
  background: linear-gradient(90deg, var(--bm-green), var(--bm-cyan));
}

.home-stream .content-card:nth-child(4n + 2) .content-card-accent {
  background: linear-gradient(90deg, var(--bm-cyan), #7f8cff);
}

.home-stream .content-card:nth-child(4n + 3) .content-card-accent {
  background: linear-gradient(90deg, #a678ff, var(--bm-rose));
}

.home-stream .content-card:nth-child(4n) .content-card-accent {
  background: linear-gradient(90deg, var(--bm-amber), var(--bm-green));
}

.home-stream .content-card h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.home-stream .content-card p,
.home-stream .content-card .card-link,
.home-stream .content-card .button {
  position: relative;
  z-index: 1;
}

.home-stream .card-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  margin-top: auto;
  color: var(--bm-green);
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
}

.home-stream .card-link span {
  transition: transform .2s ease;
}

.home-stream .content-card:hover .card-link span {
  transform: translateX(4px);
}

/* Technical checks: a regular 3x3 matrix is useful here. */
.home-block-5 .section {
  background: radial-gradient(700px 420px at 90% 18%, rgba(92, 225, 255, .055), transparent 68%);
}

.home-block-5 .feature-grid {
  gap: 16px;
}

.home-block-5 .feature-card {
  min-height: 218px;
}

/* Inventory block: three readable columns instead of another card component. */
.home-block-6 .section {
  padding-top: 98px;
  padding-bottom: 98px;
  border-top: 1px solid var(--bm-line);
  border-bottom: 1px solid var(--bm-line);
  background: rgba(255, 255, 255, .014);
}

.home-block-6 .container.narrow {
  max-width: 1160px;
}

.home-block-6 h2 {
  max-width: 820px;
  margin: 18px 0 42px;
  font-size: clamp(34px, 4.4vw, 54px);
  line-height: 1.03;
}

.home-block-6 .rich-text {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  counter-reset: inventory;
}

.home-block-6 .rich-text p {
  counter-increment: inventory;
  position: relative;
  min-height: 100%;
  margin: 0;
  padding: 30px 26px 26px;
  border: 1px solid var(--bm-line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .025);
}

.home-block-6 .rich-text p::before {
  content: "0" counter(inventory);
  display: block;
  margin-bottom: 18px;
  color: var(--bm-green);
  font: 700 12px/1 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  letter-spacing: .14em;
}

/* Six-step process: numbered stages, not another icon-card wall. */
.home-block-7 .feature-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--bm-line);
  border-radius: 22px;
  overflow: hidden;
  background: var(--bm-line);
}

.home-block-7 .feature-card {
  min-height: 225px;
  border: 0;
  border-radius: 0;
  background: rgba(7, 11, 14, .96);
  padding: 30px;
  transform: none;
}

.home-block-7 .feature-card:hover {
  background: rgba(46, 230, 166, .045);
  transform: none;
}

.home-block-7 .step-number {
  display: block;
  margin-bottom: 34px;
  color: var(--bm-green);
  font: 700 13px/1 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  letter-spacing: .14em;
}

.home-block-7 .feature-card h3 {
  font-size: 21px;
}

/* Use cases: clean 3x2 arrangement. */
.home-block-8 .section {
  background:
    radial-gradient(650px 380px at 0% 30%, rgba(46, 230, 166, .055), transparent 70%),
    rgba(255, 255, 255, .01);
}

.home-block-8 .content-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.home-block-8 .content-card {
  min-height: 235px;
}

/* Alerts and reports: editorial intro on the left, compact capability list on the right. */
.home-block-9 .section {
  border-top: 1px solid var(--bm-line);
  border-bottom: 1px solid var(--bm-line);
}

.home-block-9 .container {
  display: grid;
  grid-template-columns: minmax(280px, .78fr) minmax(0, 1.22fr);
  gap: 72px;
  align-items: start;
}

.home-block-9 .section-heading {
  position: sticky;
  top: 104px;
  max-width: 430px;
  margin: 0;
  text-align: left;
}

.home-block-9 .feature-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.home-block-9 .feature-card {
  min-height: 190px;
  padding: 23px;
}

.home-block-9 .feature-icon {
  width: 36px;
  height: 36px;
  margin-bottom: 14px;
}

/* Pricing: three cards above, two centred below. */
.home-block-10 .content-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

.home-block-10 .content-card {
  grid-column: span 2;
  min-height: 285px;
  padding: 29px 26px 25px;
}

.home-block-10 .content-card:nth-child(4) {
  grid-column: 2 / span 2;
}

.home-block-10 .content-card:nth-child(5) {
  grid-column: 4 / span 2;
}

.home-block-10 .content-card:nth-child(3) {
  border-color: rgba(46, 230, 166, .52);
  background: linear-gradient(180deg, rgba(46, 230, 166, .085), rgba(255, 255, 255, .025));
  box-shadow: 0 34px 90px -52px rgba(46, 230, 166, .82);
}

.home-block-10 .content-card:nth-child(3)::after {
  content: "Most popular";
  position: absolute;
  top: 17px;
  right: 18px;
  padding: 5px 9px;
  border: 1px solid rgba(46, 230, 166, .24);
  border-radius: 999px;
  color: var(--bm-green);
  background: rgba(46, 230, 166, .07);
  font: 700 10px/1 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.home-block-10 .pricing-card-link {
  margin-top: auto;
  width: fit-content;
}

/* Resources: broad 2x2 editorial cards. */
.home-block-11 .section {
  background: rgba(255, 255, 255, .012);
  border-top: 1px solid var(--bm-line);
  border-bottom: 1px solid var(--bm-line);
}

.home-block-11 .content-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.home-block-11 .content-card {
  min-height: 220px;
  padding: 30px;
}

.home-block-11 .content-card h3 {
  max-width: 21ch;
  font-size: 23px;
}

/* FAQ and final CTA: tighter finish after a long page. */
.home-block-12 .section {
  padding-bottom: 72px;
}

.home-block-12 .container.narrow {
  max-width: 900px;
}

.home-block-13 .section {
  padding: 40px 0 88px;
}

.home-block-13 .cta-box {
  padding: 68px 36px;
  background:
    radial-gradient(560px 260px at 50% 0%, rgba(46, 230, 166, .18), transparent 72%),
    linear-gradient(145deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .02));
  box-shadow: 0 48px 120px -72px rgba(46, 230, 166, .85);
}

@media (max-width: 1100px) {
  .home-block-1 .hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(340px, .88fr);
    gap: 38px;
  }

  .home-block-4 .content-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-block-9 .container {
    gap: 44px;
  }
}

@media (max-width: 900px) {
  .home-stream .section {
    padding: 72px 0;
  }

  .home-block-1 .hero-grid,
  .home-block-3 .container.narrow,
  .home-block-9 .container {
    grid-template-columns: 1fr;
  }

  .home-block-1 .hero-copy h1 {
    max-width: 13ch;
  }

  .home-block-3 .rich-text {
    grid-column: 1;
    grid-row: 3;
    margin-top: 30px;
  }

  .home-block-6 .rich-text,
  .home-block-7 .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-block-9 .section-heading {
    position: static;
    max-width: 720px;
  }

  .home-block-10 .content-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-block-10 .content-card,
  .home-block-10 .content-card:nth-child(4),
  .home-block-10 .content-card:nth-child(5) {
    grid-column: auto;
  }

  .home-block-10 .content-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 8px);
    justify-self: center;
  }
}

@media (max-width: 640px) {
  .home-stream .section {
    padding: 58px 0;
  }

  .home-block-1 .hero-section {
    padding: 58px 0 44px;
  }

  .home-block-1 .hero-copy h1 {
    max-width: none;
    font-size: clamp(38px, 12vw, 52px);
  }

  .home-block-2 .section {
    padding-bottom: 54px;
  }

  .home-block-4 .content-grid,
  .home-block-6 .rich-text,
  .home-block-7 .feature-grid,
  .home-block-8 .content-grid,
  .home-block-9 .feature-grid,
  .home-block-10 .content-grid,
  .home-block-11 .content-grid {
    grid-template-columns: 1fr;
  }

  .home-block-10 .content-card:last-child {
    grid-column: auto;
    width: auto;
  }

  .home-block-3 h2,
  .home-block-6 h2 {
    font-size: clamp(32px, 10vw, 42px);
  }

  .home-block-13 .cta-box {
    padding: 48px 22px;
  }
}
