/* ==========================================================================
   Services directory (services.html)
   Every rule is scoped to body.page-services so it cannot leak into other pages.
   Values follow the original site's measurements for this page.
   ========================================================================== */

body.page-services {
  --sv-line: #d8dee7;
  --sv-accent-dark: #b87814;
  --sv-hero-start: #f7f4ed;
  --sv-hero-end: #e8edf1;
  --sv-hero-copy: #536274;
  --sv-stat-label: #5f6f82;
  --sv-card-copy: #687689;
  --sv-card-number: #a1adba;
  --sv-tab-text: #43556a;
  --sv-search-icon: #708093;
  --sv-cta-copy: #bbc7d5;
}

body.page-services [hidden] {
  display: none !important;
}

/* Eyebrow labels follow the original's bar length, weight and accent colour */
body.page-services .eyebrow {
  gap: 10px;
  letter-spacing: 0.16em;
  color: var(--sv-accent-dark);
}

body.page-services .eyebrow::before {
  width: 30px;
  height: 2px;
}

/* Buttons: original lift on hover and accent shadow */
body.page-services .button {
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

body.page-services .button:hover {
  transform: translateY(-2px);
}

/* 1. Page hero ---------------------------------------------------------- */
body.page-services .page-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 510px;
  padding: 105px clamp(24px, 8vw, 130px) 85px;
  background: linear-gradient(135deg, var(--sv-hero-start), var(--sv-hero-end));
}

body.page-services .page-hero::after {
  content: "";
  position: absolute;
  top: -40%;
  right: -8vw;
  width: 48vw;
  height: 48vw;
  border: 1px solid rgba(8, 39, 80, 0.11);
  border-radius: 50%;
  box-shadow: 0 0 0 80px rgba(8, 39, 80, 0.024), 0 0 0 160px rgba(8, 39, 80, 0.02);
  pointer-events: none;
}

body.page-services .page-hero h1 {
  max-width: 1050px;
  margin: 22px 0 25px;
  font-size: clamp(48px, 5.3vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

body.page-services .page-hero > p {
  max-width: 780px;
  font-size: 18px;
  line-height: 1.7;
  color: var(--sv-hero-copy);
}

body.page-services .page-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

body.page-services .page-hero .button-accent {
  min-height: 56px;
  padding: 0 27px;
  box-shadow: 0 12px 32px rgba(184, 120, 20, 0.22);
}

body.page-services .page-hero .button-outline {
  min-height: 48px;
  padding: 0 21px;
  border-color: rgba(8, 39, 80, 0.28);
}

body.page-services .page-hero-stat {
  position: absolute;
  right: 9%;
  bottom: 52px;
  display: flex;
  align-items: baseline;
  gap: 12px;
  line-height: 1.5;
  color: var(--navy);
}

body.page-services .page-hero-stat strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 50px;
  font-weight: 500;
  line-height: 1.5;
}

body.page-services .page-hero-stat span {
  width: 100px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--sv-stat-label);
}

/* 2. Directory ---------------------------------------------------------- */
body.page-services .directory-section {
  background: #fff;
  padding: 90px clamp(24px, 7vw, 110px) 115px;
}

body.page-services .service-tools {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  margin-bottom: 40px;
}

body.page-services .category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

body.page-services .category-tabs button {
  padding: 11px 12px;
  border: 1px solid var(--sv-line);
  background: #fff;
  color: var(--sv-tab-text);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.5;
  cursor: pointer;
}

body.page-services .category-tabs button.active {
  border-color: var(--navy);
  background: var(--navy);
  color: #fff;
}

body.page-services .category-tabs button span {
  margin-left: 6px;
  opacity: 0.62;
}

body.page-services .service-search {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 240px;
  padding: 0 12px;
  border-bottom: 1px solid var(--navy);
}

body.page-services .service-search:focus-within {
  border-bottom-color: var(--gold);
}

body.page-services .service-search .icon {
  width: 17px;
  height: 17px;
  color: var(--sv-search-icon);
}

body.page-services .service-search input {
  flex: 1 1 auto;
  width: 197px;
  padding: 11px 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 24px;
  color: var(--navy);
}

/* Card grid: hairline dividers drawn by the grid background */
body.page-services .service-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--sv-line);
  border: 1px solid var(--sv-line);
}

body.page-services .service-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 300px;
  padding: 30px;
  background: #fff;
  color: var(--navy);
  text-decoration: none;
  transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

body.page-services .service-card:hover,
body.page-services .service-card:focus-visible {
  z-index: 1;
  background: #f6f8fa;
  box-shadow: 0 24px 70px rgba(4, 26, 55, 0.13);
  transform: translateY(-4px);
  color: var(--navy);
}

body.page-services .service-number {
  position: absolute;
  top: 28px;
  right: 28px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.5;
  color: var(--sv-card-number);
}

body.page-services .service-category {
  display: block;
  padding-right: 40px;
  font-size: 10px;
  font-weight: 900;
  line-height: 1.5;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sv-accent-dark);
}

body.page-services .service-card h2 {
  margin: 32px 0 13px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 27px;
  font-weight: 500;
  line-height: 1.15;
  color: var(--navy);
}

body.page-services .service-card p {
  margin: 0;
  font-size: 13px;
  line-height: 1.65;
  color: var(--sv-card-copy);
}

body.page-services .service-card strong {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 28px;
  font-size: 11px;
  font-weight: 800;
  line-height: 24px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--navy);
}

body.page-services .service-card strong .icon {
  width: 16px;
  height: 16px;
}

body.page-services .directory-empty {
  margin: 0;
  padding: 40px 0 0;
  text-align: center;
  font-size: 16px;
  line-height: 1.6;
  color: var(--sv-card-copy);
}

/* 3. Closing call to action -------------------------------------------- */
body.page-services .final-cta.compact {
  padding: 82px 24px;
}

body.page-services .final-cta .eyebrow {
  display: inline-flex;
}

body.page-services .final-cta h2 {
  max-width: 900px;
  margin: 18px auto;
  font-size: clamp(38px, 4vw, 60px);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.045em;
  color: #fff;
}

body.page-services .final-cta p {
  max-width: 680px;
  margin: 0 auto 30px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--sv-cta-copy);
}

body.page-services .final-cta .button-accent {
  min-height: 56px;
  margin-top: 0;
  padding: 0 27px;
  box-shadow: 0 12px 32px rgba(184, 120, 20, 0.22);
}

/* 4. Responsive --------------------------------------------------------- */
@media (max-width: 1080px) {
  body.page-services .service-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 760px) {
  body.page-services .page-hero {
    min-height: 470px;
    padding-top: 80px;
  }

  body.page-services .page-hero-stat {
    position: static;
    margin-top: 28px;
  }

  body.page-services .service-tools {
    flex-direction: column;
    align-items: stretch;
  }

  body.page-services .service-search {
    min-width: 0;
  }

  body.page-services .directory-section {
    padding-block: 70px;
  }

  body.page-services .service-card-grid {
    grid-template-columns: 1fr;
  }

  body.page-services .service-card {
    min-height: 250px;
  }
}

/* Review fixes: empty search state */
body.page-services .directory-empty {
  max-width: 620px;
  margin: 36px auto 0;
  padding: 36px 32px;
  text-align: center;
  background: #f1ede4;
  border-radius: 6px;
}

body.page-services .directory-empty[hidden] {
  display: none;
}

body.page-services .directory-empty h2 {
  font-size: 26px;
  margin: 0 0 10px;
}

body.page-services .directory-empty p {
  color: var(--muted);
  margin: 0 0 22px;
}
