/*
 * Programmatic page styles (group G3, contract C8).
 * Town pages, topic pages and the six service hubs.
 * Colours come from the page's own CSS variables, so the dark town and
 * topic pages and the light hub pages both work.
 */

/* Hero subline under the town page H1 (P06) */
.sp-hero-subline {
  margin: -1.25rem 0 1.5rem;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-dim, inherit);
}

/* Namesake note linking the real Preston page (P18) */
.sp-namesake-note {
  margin: -1rem 0 2rem;
  font-size: 1rem;
  color: var(--text-dim, inherit);
}

.sp-namesake-note a,
.sp-text-link {
  color: var(--neon-cyan, currentColor);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.sp-namesake-note a:hover,
.sp-namesake-note a:focus-visible,
.sp-text-link:hover,
.sp-text-link:focus-visible {
  color: var(--neon-pink, currentColor);
}

/* How the work runs (service-facts partial) */
.sp-steps {
  list-style: none;
  counter-reset: sp-step;
  margin: 0 0 1.25rem;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.sp-step {
  counter-increment: sp-step;
  position: relative;
  padding: 1rem 1rem 1rem 3.25rem;
  border: 1px solid var(--border, rgba(127, 127, 127, 0.3));
  border-radius: 12px;
}

.sp-step::before {
  content: counter(sp-step);
  position: absolute;
  left: 1rem;
  top: 1rem;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--bg-deep, #fff);
  background: var(--neon-cyan, #555);
}

.sp-step-title {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main, inherit);
}

.sp-step p {
  margin: 0;
}

/* What affects the price */
.sp-cost-drivers {
  margin: 0 0 1rem;
  padding-left: 1.25rem;
  list-style: disc;
  display: grid;
  gap: 0.4rem;
}

.sp-faq-note,
.sp-hub-uplink {
  margin-top: 2rem;
  text-align: center;
  color: var(--text-dim, inherit);
}

.sp-hub-uplink a + span {
  margin: 0 0.5rem;
}

/* Hub guides (P50) */
.sp-guide .sp-guide-body {
  max-width: 820px;
}

.sp-guide .sp-guide-body h3 {
  margin: 2.25rem 0 0.75rem;
  font-size: 1.35rem;
  line-height: 1.3;
  font-weight: 800;
  color: var(--text-main, inherit);
}

.sp-guide .sp-guide-body h3:first-child {
  margin-top: 0;
}

.sp-guide .sp-guide-body p,
.sp-guide .sp-guide-body li {
  line-height: 1.7;
}

.sp-guide .sp-guide-body p {
  margin: 0 0 1rem;
}

.sp-guide .sp-guide-body ul,
.sp-guide .sp-guide-body ol:not(.sp-steps) {
  margin: 0 0 1.25rem;
  padding-left: 1.25rem;
  display: grid;
  gap: 0.45rem;
}

.sp-guide .sp-guide-body ul {
  list-style: disc;
}

.sp-guide .sp-guide-body ol:not(.sp-steps) {
  list-style: decimal;
}

.sp-guide .sp-guide-body a {
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
}

.sp-guide .sp-step-title {
  font-size: 1rem;
}

@media (max-width: 640px) {
  .sp-hero-subline {
    font-size: 1.05rem;
    margin-top: -1rem;
  }

  .sp-step {
    padding: 0.9rem 0.9rem 0.9rem 3rem;
  }

  .sp-guide .sp-guide-body h3 {
    font-size: 1.2rem;
  }
}
