﻿/* I Need An Arborist - Shared Website Styles */

/* ---------- Base Reset ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 5.25rem;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, Helvetica, sans-serif;
  color: #17351f;
  background: #f7f6ef;
  line-height: 1.6;
  min-height: 100vh;
}

img,
svg {
  max-width: 100%;
  height: auto;
}

a {
  color: #1f6f43;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #144c2d;
}

button,
input,
select,
textarea {
  font: inherit;
}

/* ---------- Accessibility ---------- */

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 9999;
  background: #ffffff;
  color: #17351f;
  padding: 0.75rem 1rem;
  border: 2px solid #17351f;
  border-radius: 0.5rem;
}

.skip-link:focus {
  top: 1rem;
}

:focus-visible {
  outline: 3px solid #b05a00;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Layout ---------- */

.site-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #17351f;
  color: #ffffff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 24px rgba(10, 28, 16, 0.16);
}

.nav-container,
.section-container {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 4rem;
  padding: 0.65rem 0;
}

.site-logo {
  color: #ffffff;
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
  line-height: 1.2;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-nav a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  text-decoration: underline;
}

main {
  flex: 1;
}

main [id] {
  scroll-margin-top: 5.25rem;
}

.section {
  padding: clamp(3rem, 7vw, 6rem) 0;
}

.section-light {
  background: #ffffff;
}

.section-muted {
  background: #eef2e7;
}

/* ---------- Typography ---------- */

.eyebrow {
  color: #5a6d3d;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.85rem;
}

h1,
h2,
h3 {
  color: #17351f;
  line-height: 1.15;
  margin: 0 0 1rem;
}

h1 {
  font-size: clamp(2.25rem, 6vw, 4.75rem);
  max-width: 900px;
}

h2 {
  font-size: clamp(1.8rem, 4vw, 3rem);
}

h3 {
  font-size: clamp(1.2rem, 2.5vw, 1.5rem);
}

p {
  margin: 0 0 1rem;
  max-width: 72ch;
}

.lead {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: #344a38;
  max-width: 760px;
}

/* ---------- Buttons ---------- */

.button-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.button,
button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 0.8rem 1.2rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.button-primary {
  background: #1f6f43;
  color: #ffffff;
}

.button-primary:hover {
  background: #144c2d;
  color: #ffffff;
}

.button-secondary {
  background: #ffffff;
  color: #17351f;
  border-color: #17351f;
}

.button-secondary:hover {
  background: #eef2e7;
  color: #17351f;
}

/* ---------- Cards ---------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}

.card {
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 1.25rem;
  padding: 1.5rem;
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.08);
}

.card-action {
  text-align: left;
  width: 100%;
  color: #17351f;
  background: #ffffff;
  border: 2px solid #d9dfcf;
  border-radius: 1.25rem;
  padding: 1.5rem;
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.08);
}

.card-action:hover,
.card-action:focus-visible {
  border-color: #1f6f43;
  background: #f7fbf3;
}

/* ---------- Forms ---------- */

.form-card {
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 1.25rem;
  padding: clamp(1rem, 4vw, 2rem);
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.08);
}

label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

input,
select,
textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid #8a987f;
  border-radius: 0.6rem;
  padding: 0.75rem;
  background: #ffffff;
  color: #17351f;
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: #1f6f43;
  box-shadow: 0 0 0 4px rgba(31, 111, 67, 0.16);
}

[aria-invalid="true"] {
  border-color: #8a1f11;
}

.help-text {
  color: #526050;
  font-size: 0.95rem;
}

.error-text {
  color: #8a1f11;
  font-weight: 700;
}

/* ---------- Footer ---------- */

.site-footer {
  background: #17351f;
  color: #ffffff;
  padding: 2rem 0;
}

.site-footer a {
  color: #ffffff;
}

/* ---------- Responsive ---------- */

@media (max-width: 800px) {
  .nav-container {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-nav {
    gap: 0.75rem;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .button,
  button {
    width: 100%;
  }
}

/* ---------- Homepage ---------- */

.hero-section {
  overflow: clip;
  background: #f7f6ef;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
}

.home-page .home-hero {
  padding-top: clamp(1rem, 2vw, 1.5rem);
  padding-bottom: clamp(2rem, 4vw, 3.25rem);
}

.home-hero-stage {
  position: relative;
  min-height: clamp(34rem, 46vw, 40rem);
  overflow: hidden;
  isolation: isolate;
  background: #eef2e7;
  border: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 1.5rem;
  box-shadow: 0 18px 42px rgba(23, 53, 31, 0.12);
}

.home-hero-art {
  position: absolute;
  inset: 0;
  display: block;
}

.home-hero-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.home-hero-stage::after {
  position: absolute;
  inset: 0;
  z-index: 0;
  content: "";
  pointer-events: none;
  background:
    radial-gradient(
      ellipse at 14% 48%,
      rgba(247, 246, 239, 0.28) 0%,
      rgba(247, 246, 239, 0.16) 34%,
      rgba(247, 246, 239, 0) 66%
    ),
    linear-gradient(
      90deg,
      rgba(247, 246, 239, 0.96) 0%,
      rgba(247, 246, 239, 0.92) 40%,
      rgba(247, 246, 239, 0.7) 47%,
      rgba(247, 246, 239, 0.3) 58%,
      rgba(247, 246, 239, 0.08) 66%,
      rgba(247, 246, 239, 0) 72%
    );
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(54%, 640px);
  max-width: none;
  padding: clamp(2rem, 4vw, 4rem) clamp(2rem, 4vw, 4rem) 0;
}

.home-hero-stage .hero-copy h1 {
  max-width: 12ch;
  font-size: clamp(2.65rem, 4.6vw, 3.65rem);
}

.home-hero-stage .hero-copy .lead {
  max-width: 52ch;
}

.home-hero-start {
  position: relative;
  z-index: 2;
  margin: -0.5rem 0 0;
  padding: clamp(1.25rem, 2.5vw, 1.75rem);
}

.home-hero-start .choice-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 1rem;
}

.trust-line {
  margin-top: 1.5rem;
  font-weight: 700;
  color: #17351f;
}

.home-hero-trust {
  position: relative;
  z-index: 1;
  width: min(54%, 640px);
  max-width: none;
  margin-bottom: 0;
  padding: 0 clamp(2rem, 4vw, 4rem) clamp(2rem, 4vw, 4rem);
}

.hero-card h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
}

.choice-list {
  display: grid;
  gap: 1rem;
  margin-top: 1.5rem;
}

.choice-card {
  display: block;
  color: #17351f;
  text-decoration: none;
  background: #ffffff;
  border: 2px solid #d9dfcf;
  border-radius: 1rem;
  padding: 1rem;
}

.choice-card:hover,
.choice-card:focus-visible {
  border-color: #1f6f43;
  background: #f7fbf3;
}

.choice-title {
  display: block;
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
}

.choice-description {
  display: block;
  color: #344a38;
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 6vw, 4rem);
  align-items: start;
}

.footer-layout {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-nav {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

@media (max-width: 900px) {
  .split-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 800px) {
  .home-hero-stage {
    display: flex;
    min-height: 0;
    flex-direction: column;
  }

  .home-hero-art {
    position: relative;
    order: 2;
    height: calc((100vw - 2.125rem) * 0.625);
    aspect-ratio: auto;
    flex: 0 0 auto;
  }

  .home-hero-art::before {
    position: absolute;
    inset: 0 0 auto;
    z-index: 1;
    height: 3rem;
    content: "";
    pointer-events: none;
    background: linear-gradient(180deg, #f7f6ef 0%, rgba(247, 246, 239, 0) 100%);
  }

  .home-hero-stage::after {
    display: none;
  }

  .hero-copy {
    order: 1;
    width: 100%;
    padding: clamp(1.35rem, 5vw, 2.25rem) clamp(1.35rem, 5vw, 2.25rem) 1.25rem;
    background: rgba(247, 246, 239, 0.98);
  }

  .home-hero-art img {
    object-position: center 52%;
  }

  .home-hero-trust {
    order: 3;
    width: 100%;
    margin: 0;
    padding: 1.15rem clamp(1.35rem, 5vw, 2.25rem) 2.25rem;
    background: #f7f6ef;
  }

  .home-hero-stage .hero-copy h1 {
    max-width: 15ch;
    font-size: clamp(2.35rem, 8vw, 3.25rem);
  }

  .home-hero-start .choice-list {
    grid-template-columns: 1fr;
  }

  .home-hero-start {
    margin-top: -2rem;
  }
}

@media (min-width: 601px) and (max-width: 800px) {
  .home-hero-art {
    height: calc((100vw - 2.125rem) * 0.5);
  }

  body.home-page .home-hero-stage .hero-actions {
    flex-direction: row;
  }

  body.home-page .home-hero-stage .hero-actions .button {
    width: auto;
  }
}

/* ---------- Homepage muted section readability panels ---------- */

.home-page .home-section-panel {
  padding: clamp(1.5rem, 4vw, 2.5rem);
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(23, 53, 31, 0.12);
  border-radius: 1.25rem;
  box-shadow: 0 14px 34px rgba(23, 53, 31, 0.08);
}

.home-page .home-section-panel > :last-child {
  margin-bottom: 0;
}

/* ---------- Homepage chapter rhythm ---------- */

.home-page .home-process-section,
.home-page .why-section,
.home-page .home-guidance-section,
.home-page .home-professional-section,
.home-page .home-final-section {
  border-top: 1px solid rgba(23, 53, 31, 0.12);
}

.home-page .home-process-section {
  padding-top: clamp(4rem, 7vw, 5.5rem);
  padding-bottom: clamp(4.5rem, 8vw, 6.25rem);
}

.home-process-section .card {
  padding: 1.4rem 1.5rem;
  background: #f7f6ef;
  border-width: 0 0 0 3px;
  border-color: #9a6a1f;
  border-radius: 0 0.75rem 0.75rem 0;
  box-shadow: none;
}

.home-page .why-section {
  padding-top: clamp(4.5rem, 8vw, 6.5rem);
  padding-bottom: clamp(4.5rem, 8vw, 6.5rem);
}

.why-section .home-section-panel {
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.why-section .home-section-panel > :last-child {
  padding-left: clamp(1.5rem, 4vw, 2.5rem);
  border-left: 3px solid rgba(154, 106, 31, 0.72);
}

.home-page .home-guidance-section {
  padding-top: clamp(4rem, 7vw, 5.5rem);
  padding-bottom: clamp(4.5rem, 8vw, 6rem);
  background: #f7f6ef;
}

.home-guidance-section .home-guide-grid > a {
  border-width: 1px;
  box-shadow: none;
}

.home-page .home-professional-section {
  padding-top: clamp(4.5rem, 8vw, 6rem);
  padding-bottom: clamp(4.5rem, 8vw, 6rem);
  background: #e4eadf;
}

.home-professional-section .home-section-panel {
  color: #ffffff;
  background: #17351f;
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: 0 18px 42px rgba(23, 53, 31, 0.18);
}

.home-professional-section .eyebrow {
  color: #d9c38f;
}

.home-professional-section h2 {
  color: #ffffff;
}

.home-professional-section .button-primary {
  color: #17351f;
  background: #f3e7c7;
}

.home-professional-section .button-primary:hover {
  color: #17351f;
  background: #ffffff;
}

.home-professional-section .button-secondary {
  color: #ffffff;
  background: transparent;
  border-color: rgba(255, 255, 255, 0.78);
}

.home-professional-section .button-secondary:hover {
  color: #17351f;
  background: #ffffff;
}

.home-page .home-final-section {
  padding-top: clamp(3.75rem, 7vw, 5.25rem);
  padding-bottom: clamp(4rem, 7vw, 5.5rem);
  background: #ffffff;
}

.home-final-section .final-cta-card {
  padding-top: clamp(2rem, 5vw, 3.25rem);
  padding-bottom: clamp(2rem, 5vw, 3.25rem);
  background: linear-gradient(135deg, #eef2e7, #f7f6ef);
  border-color: rgba(23, 53, 31, 0.16);
  box-shadow: none;
}

@media (max-width: 800px) {
  .home-page .home-process-section,
  .home-page .why-section,
  .home-page .home-guidance-section,
  .home-page .home-professional-section,
  .home-page .home-final-section {
    padding-top: 3.25rem;
    padding-bottom: 3.5rem;
  }

  .why-section .home-section-panel > :last-child {
    padding-top: 1.5rem;
    padding-left: 0;
    border-top: 3px solid rgba(154, 106, 31, 0.72);
    border-left: 0;
  }

  .home-professional-section .home-section-panel {
    padding: 1.5rem;
  }

  .home-page .home-final-section {
    padding-bottom: 3.75rem;
  }

  .home-page .footer-layout {
    flex-direction: column;
    gap: 1.5rem;
  }

  .home-page .footer-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem 1rem;
    width: 100%;
  }

  .home-page .footer-nav a {
    display: flex;
    min-height: 44px;
    align-items: center;
  }
}

/* ---------- Public Site Image Cards ---------- */

.public-image-band {
  padding-top: 0;
  padding-bottom: clamp(2rem, 5vw, 3.5rem);
}

.public-image-card {
  overflow: hidden;
  margin: 0;
  background: #ffffff;
  border: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 1.25rem;
  box-shadow: 0 14px 34px rgba(23, 53, 31, 0.1);
}

.public-image-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.public-image-card-portrait img {
  aspect-ratio: 3 / 4;
}

.public-image-caption {
  max-width: none;
  margin: 0;
  padding: 0.85rem 1rem;
  color: #526050;
  font-size: 0.92rem;
}

.hero-side-stack {
  display: grid;
  gap: 1rem;
}

/* ---------- Info Page Layout Refinements ---------- */

.info-page .info-hero {
  padding-top: clamp(2rem, 5vw, 3.5rem);
  padding-bottom: clamp(2rem, 5vw, 3.5rem);
}

.info-page .info-hero .lead {
  margin-bottom: 0;
}

.info-page .hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
  margin-bottom: 0;
}

/* ---------- Shared page banners ---------- */

.page-banner {
  position: relative;
  overflow: hidden;
  padding: clamp(1.35rem, 4vw, 2.25rem);
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 1.25rem;
  box-shadow: 0 14px 34px rgba(23, 53, 31, 0.08);
}

.page-banner::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 0.35rem;
  background: linear-gradient(180deg, #1f6f43, #9a6a1f);
}

.page-banner > :first-child {
  margin-top: 0;
}

.page-banner > :last-child {
  margin-bottom: 0;
}

.page-banner--compact {
  padding: clamp(1.15rem, 3vw, 1.75rem);
}

.page-banner--quiet {
  overflow: visible;
  padding: 0 0 1.25rem;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 0;
  box-shadow: none;
}

.page-banner--quiet::before {
  display: none;
}

.info-page .info-hero.page-banner {
  margin-top: clamp(1.5rem, 4vw, 3rem);
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}

.info-page .info-content {
  display: grid;
  gap: 1.25rem;
  padding-top: 0;
  padding-bottom: clamp(2.5rem, 6vw, 4rem);
}

/* ---------- Info Page Related Guide Cards ---------- */

.info-related {
  padding: clamp(2.5rem, 6vw, 4rem) 0;
}

.info-link-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.info-guide-card,
.info-link-grid > a {
  display: block;
  color: #17351f;
  text-decoration: none;
  background: #ffffff;
  border: 2px solid #d9dfcf;
  border-radius: 1rem;
  padding: 1rem;
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.08);
}

.info-guide-card:hover,
.info-guide-card:focus-visible,
.info-link-grid > a:hover,
.info-link-grid > a:focus-visible {
  border-color: #1f6f43;
  background: #f7fbf3;
  color: #17351f;
}

.info-guide-card span,
.info-link-grid > a span {
  display: block;
  font-weight: 800;
  margin-bottom: 0.35rem;
}

.info-guide-card small,
.info-link-grid > a small {
  display: block;
  color: #344a38;
  font-size: 0.95rem;
  line-height: 1.45;
}

@media (max-width: 800px) {
  .info-link-grid {
    grid-template-columns: 1fr;
  }
}

.info-section {
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 1.25rem;
  padding: clamp(1.25rem, 3vw, 1.75rem);
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.08);
}

.info-section h2 {
  margin-top: 0;
  font-size: clamp(1.35rem, 3vw, 2rem);
}

.info-section p:last-child {
  margin-bottom: 0;
}

/* ---------- Forestry Guide Page ---------- */

.forestry-guide-page .section-heading-row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 1.5rem;
  align-items: end;
  margin-bottom: 1.5rem;
}

.forestry-guide-page .section-heading-row h2,
.forestry-guide-page .section-heading-row p {
  margin-bottom: 0;
}

.forestry-guide-page .forestry-start-card {
  border-left: 6px solid #1f6f43;
  background:
    linear-gradient(rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.94)),
    url("/assets/images/abstract_tree_background.png");
  background-size: cover;
  background-position: center;
}

.forestry-guide-page .forestry-start-grid,
.forestry-guide-page .forestry-fit-grid,
.forestry-guide-page .forestry-question-grid {
  display: grid;
  gap: 1rem;
}

.forestry-guide-page .forestry-start-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.forestry-guide-page .forestry-fit-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.forestry-guide-page .forestry-question-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.forestry-guide-page .forestry-start-grid article,
.forestry-guide-page .info-mini-card {
  padding: 1rem;
  background: #f7fbf3;
  border: 1px solid #d9dfcf;
  border-radius: 1rem;
}

.forestry-guide-page .info-mini-card h3,
.forestry-guide-page .forestry-start-grid h3 {
  margin-top: 0;
}

.forestry-guide-page .responsive-table-wrap {
  overflow-x: auto;
  margin-top: 1rem;
}

.forestry-guide-page .comparison-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  background: #ffffff;
}

.forestry-guide-page .comparison-table th,
.forestry-guide-page .comparison-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid #d9dfcf;
  text-align: left;
  vertical-align: top;
}

.forestry-guide-page .comparison-table th {
  color: #17351f;
  background: #eef2e7;
  font-weight: 800;
}

.forestry-guide-page .important-note {
  display: flex;
  gap: 1rem;
  border-left: 6px solid #b05a00;
  background: #fff8e6;
}

.forestry-guide-page .important-note > span {
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: #b05a00;
  border-radius: 999px;
  font-weight: 900;
}

.forestry-guide-page .final-cta-card {
  margin-bottom: clamp(3rem, 7vw, 5rem);
}

@media (max-width: 900px) {
  .forestry-guide-page .section-heading-row,
  .forestry-guide-page .forestry-start-grid,
  .forestry-guide-page .forestry-fit-grid,
  .forestry-guide-page .forestry-question-grid {
    grid-template-columns: 1fr;
  }

  .forestry-guide-page .important-note {
    display: block;
  }

  .forestry-guide-page .important-note > span {
    margin-bottom: 0.75rem;
  }
}

/* ---------- Forestry important note marker ---------- */

.forestry-guide-page .forestry-limitation {
  align-items: flex-start;
}

.forestry-guide-page .forestry-limitation > span {
  flex: 0 0 auto;
  width: auto;
  height: auto;
  display: inline;
  margin-top: 0.25rem;
  color: #8a5a00;
  background: transparent;
  border-radius: 0;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1;
}

/* ---------- Why this exists callout ---------- */

.why-section .why-emphasis {
  position: relative;
  max-width: 68ch;
  margin: 0 0 1.25rem;
  padding: 1rem 1.1rem 1rem 3rem;
  color: #17351f;
  background: rgba(31, 111, 67, 0.08);
  border: 1px solid rgba(31, 111, 67, 0.16);
  border-left: 5px solid #1f6f43;
  border-radius: 1rem;
  font-size: clamp(1.05rem, 2vw, 1.18rem);
  line-height: 1.55;
}

.why-section .why-emphasis span {
  position: absolute;
  top: 0.78rem;
  left: 1rem;
  color: #1f6f43;
  font-size: 1.8rem;
  font-weight: 900;
  line-height: 1;
}

.why-section .why-emphasis em {
  font-style: italic;
  font-weight: 700;
}

/* ---------- Self-reported listing disclaimer ---------- */

.why-disclaimer {
  position: relative;
  max-width: 68ch;
  margin-top: 1.25rem;
  padding: 0.95rem 1rem 0.95rem 2.75rem;
  color: #17351f;
  background: rgba(31, 111, 67, 0.08);
  border: 1px solid rgba(31, 111, 67, 0.16);
  border-left: 5px solid #1f6f43;
  border-radius: 1rem;
}

.why-disclaimer span {
  position: absolute;
  top: 0.75rem;
  left: 1rem;
  color: #1f6f43;
  font-size: 1.6rem;
  font-weight: 900;
  line-height: 1;
}

.why-disclaimer em {
  font-style: italic;
  font-weight: 700;
}

/* ---------- Subtle Tree Texture Sections ---------- */

.section-muted {
  position: relative;
  background:
    linear-gradient(rgba(238, 242, 231, 0.94), rgba(238, 242, 231, 0.94)),
    url("assets/images/abstract_tree_background.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.section-muted > .section-container {
  position: relative;
  z-index: 1;
}

/* ---------- Completion / Form Guidance ---------- */

.completion-panel {
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-left: 6px solid #1f6f43;
  border-radius: 1rem;
  padding: 1rem;
  margin: 1.5rem 0;
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.08);
}

.completion-panel h2,
.completion-panel h3 {
  margin-bottom: 0.5rem;
}

.completion-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.completion-list li {
  padding: 0.35rem 0;
}

.completion-list .complete {
  color: #1f6f43;
  font-weight: 700;
}

.completion-list .missing {
  color: #8a1f11;
  font-weight: 700;
}

.form-warning {
  background: #fff8e6;
  border: 1px solid #e5c46b;
  border-radius: 0.75rem;
  padding: 1rem;
  margin: 1rem 0;
  color: #4d3b00;
}

.form-error {
  background: #fff0ed;
  border: 1px solid #d98b7c;
  border-radius: 0.75rem;
  padding: 1rem;
  margin: 1rem 0;
  color: #8a1f11;
}

.form-success {
  background: #edf8ef;
  border: 1px solid #95c79b;
  border-radius: 0.75rem;
  padding: 1rem;
  margin: 1rem 0;
  color: #17351f;
}

/* ---------- Compact Checkbox / Radio Inputs ---------- */

input[type="checkbox"],
input[type="radio"] {
  width: auto;
  min-height: auto;
  display: inline-block;
  margin: 0 0.5rem 0 0;
  padding: 0;
  vertical-align: middle;
}

.checkbox-list label,
.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0.45rem 0;
  font-weight: 500;
  line-height: 1.4;
}

.checkbox-list input[type="text"],
.checkbox-row input[type="text"] {
  width: min(260px, 100%);
  min-height: 36px;
  margin-left: 0.5rem;
  margin-top: -0.25rem;
}

/* ---------- Legal Pages ---------- */

.legal-page {
  max-width: 900px;
}

.legal-page h1 {
  max-width: 100%;
}

.legal-page h2 {
  margin-top: 2rem;
  font-size: clamp(1.35rem, 3vw, 2rem);
}

.legal-page ul {
  padding-left: 1.25rem;
}

.legal-page li {
  margin-bottom: 0.45rem;
}

.legal-note {
  background: #fff8e6;
  border: 1px solid #e5c46b;
  border-radius: 0.75rem;
  padding: 1rem;
  margin: 1.5rem 0;
}

.legal-meta {
  color: #526050;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.legal-page {
  padding: clamp(1.25rem, 4vw, 2rem);
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(23, 53, 31, 0.12);
  border-radius: 1.25rem;
  box-shadow: 0 12px 30px rgba(23, 53, 31, 0.08);
}

.legal-highlight-note {
  max-width: 72ch;
  margin: 1.25rem 0 2rem;
  padding: 1rem 1.1rem;
  color: #17351f;
  background: rgba(31, 111, 67, 0.08);
  border: 1px solid rgba(31, 111, 67, 0.16);
  border-left: 5px solid #1f6f43;
  border-radius: 1rem;
}

.legal-highlight-note strong {
  font-weight: 800;
}

.legal-page p,
.legal-page li {
  font-size: 1rem;
}

.accessibility-page .legal-page h2 {
  scroll-margin-top: 5rem;
}

/* ---------- Dynamic Member Listing Sections ---------- */

.config-group {
  border: 1px solid #d9dfcf;
  border-radius: 0.75rem;
  margin: 0.75rem 0;
  background: #ffffff;
  overflow: hidden;
}

.config-group summary {
  cursor: pointer;
  font-weight: 800;
  padding: 0.8rem 1rem;
  background: #f7f6ef;
  color: #17351f;
}

.config-group summary:hover {
  background: #eef2e7;
}

.config-group-content {
  padding: 0.75rem 1rem 1rem;
}

.config-group-meta {
  color: #526050;
  font-size: 0.92rem;
  margin-bottom: 0.75rem;
}

.dynamic-section-heading {
  margin-top: 1.5rem;
}

.inline-help {
  display: block;
  color: #526050;
  font-size: 0.92rem;
  margin-left: 1.7rem;
}

/* =========================================================
   Individual membership / listing form
   ========================================================= */

body.membership-page {
  --membership-forest: var(--forest-green, #17351f);
  --membership-green: var(--primary-green, #4f7a45);
  --membership-green-dark: var(--primary-green-dark, #355f39);
  --membership-sage: var(--light-sage, #eef2e7);
  --membership-sage-hover: var(--light-sage-hover, #e3eadb);
  --membership-border: var(--border-color, #d9dfcf);
  --membership-control-border: #7e8c73;
  --membership-text: var(--text-color, #2d392f);
  --membership-muted: var(--muted-text, #607060);
  --membership-white: #ffffff;

  margin: 0;
  min-height: 100vh;
  padding: clamp(1rem, 3vw, 2.5rem);

  color: var(--membership-text);
  font-family:
    Inter,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;

  background:
    linear-gradient(
      rgba(247, 249, 244, 0.9),
      rgba(247, 249, 244, 0.94)
    ),
    url("/assets/images/abstract_tree_background.png")
      center / cover fixed no-repeat;
}

.membership-page *,
.membership-page *::before,
.membership-page *::after {
  box-sizing: border-box;
}

.membership-page .membership-shell {
  width: min(100%, 1000px);
  margin: 0 auto;
  padding: clamp(1.25rem, 4vw, 3rem);

  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(217, 223, 207, 0.9);
  border-radius: 1.5rem;
  box-shadow:
    0 24px 60px rgba(23, 53, 31, 0.12),
    0 6px 18px rgba(23, 53, 31, 0.08);

  backdrop-filter: blur(8px);
}

body.individual-membership-page,
body.corporate-membership-page {
  padding: 0;
}

.individual-membership-page .membership-shell,
.corporate-membership-page .membership-shell {
  width: min(1000px, calc(100% - 2rem));
  margin: clamp(1rem, 3vw, 2.5rem) auto;
}

.membership-page .page-intro {
  max-width: 760px;
  margin: 0 auto 2rem;
  text-align: center;
}

.membership-page .eyebrow {
  margin: 0 0 0.5rem;
  color: var(--membership-green-dark);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.membership-page h1 {
  margin: 0;
  color: var(--membership-forest);
  font-size: clamp(2rem, 5vw, 3.25rem);
  line-height: 1.08;
}

.membership-page .lead {
  max-width: 680px;
  margin: 1rem auto 0;
  color: var(--membership-muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  line-height: 1.7;
}

.membership-page #arboristForm,
.membership-page #companyForm,
.membership-page #profileForm,
.membership-page .member-form {
  max-width: none;
  margin: 0;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.membership-page fieldset,
.membership-page .form-section,
.membership-page .form-note {
  background: var(--membership-white);
  border: 1px solid var(--membership-border);
  border-radius: 1rem;
  box-shadow: 0 8px 24px rgba(23, 53, 31, 0.05);
}

.membership-page fieldset {
  margin: 0 0 1.25rem;
  padding: clamp(1.25rem, 3vw, 2rem);
}

.membership-page legend {
  padding: 0 0.35rem;
  color: var(--membership-forest);
  font-size: 1.2rem;
  font-weight: 800;
}

.membership-page label {
  display: block;
  margin: 0.9rem 0 0.35rem;
  color: var(--membership-forest);
  font-weight: 700;
}

.membership-page input[type="text"],
.membership-page input[type="email"],
.membership-page input[type="password"],
.membership-page input[type="url"],
.membership-page input[type="number"],
.membership-page select {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: 0.75rem 0.9rem;

  color: var(--membership-text);
  background: var(--membership-white);
  border: 1px solid var(--membership-control-border);
  border-radius: 0.65rem;
  font: inherit;
  line-height: 1.4;

  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
}

.membership-page input[readonly],
.membership-page select:disabled {
  color: #657265;
  background: #f1f4ef;
  cursor: not-allowed;
}

.membership-page input:focus,
.membership-page select:focus {
  outline: none;
  border-color: var(--membership-green);
  box-shadow: 0 0 0 4px rgba(79, 122, 69, 0.14);
}

.membership-page fieldset > br,
.membership-page #servicesContainer > br {
  display: none;
}

.membership-page .help-text,
.membership-page .required-note,
.membership-page .config-group-meta {
  color: var(--membership-muted);
  font-size: 0.94rem;
  line-height: 1.55;
}

.membership-page .form-note {
  margin: 1.25rem 0;
  padding: 1rem 1.15rem;
  background: var(--membership-sage);
  box-shadow: none;
}

.membership-page .form-note p:first-child {
  margin-top: 0;
}

.membership-page .form-note p:last-child {
  margin-bottom: 0;
}

/* Primary accordion sections */

.membership-page .form-section {
  margin: 1.25rem 0;
  padding: 0;
  overflow: hidden;
}

.membership-page .form-section > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;

  padding: 1rem 1.2rem;
  cursor: pointer;
  list-style: none;

  color: var(--membership-forest);
  font-size: 1.05rem;
  font-weight: 800;

  background: var(--membership-sage);
  transition: background-color 0.2s ease;
}

.membership-page .form-section > summary::-webkit-details-marker {
  display: none;
}

.membership-page .form-section > summary::after {
  content: "";
  flex: 0 0 auto;
  width: 0.65rem;
  height: 0.65rem;
  margin-left: auto;
  border-right: 3px solid currentColor;
  border-bottom: 3px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.membership-page .form-section[open] > summary::after {
  transform: rotate(-135deg);
}

.membership-page .config-group > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  list-style: none;
}

.membership-page .config-group > summary::-webkit-details-marker {
  display: none;
}

.membership-page .config-group > summary::after {
  content: "";
  flex: 0 0 auto;
  width: 0.55rem;
  height: 0.55rem;
  margin-left: auto;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.membership-page .config-group[open] > summary::after {
  transform: rotate(-135deg);
}

.membership-page .form-section > summary:hover {
  background: var(--membership-sage-hover);
}

.membership-page .form-section-content {
  padding: clamp(1rem, 3vw, 1.5rem);
}

/* Nested credential groups */

.membership-page .config-group {
  margin: 0.75rem 0;
  overflow: hidden;
  border: 1px solid var(--membership-border);
  border-radius: 0.75rem;
  background: #ffffff;
}

.membership-page .config-group > summary {
  padding: 0.85rem 1rem;
  cursor: pointer;
  color: var(--membership-forest);
  font-weight: 750;
  background: #f7f9f5;
}

.membership-page .config-group-content {
  padding: 0.75rem 1rem 1rem;
}

/* Checkbox options */

.membership-page .checkbox-list {
  display: grid;
  gap: 0.45rem;
}

.membership-page #servicesContainer {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.membership-page .checkbox-list label:not(.config-option),
.membership-page .checkbox-row {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.65rem;

  margin: 0;
  padding: 0.75rem 0.85rem;

  color: var(--membership-text);
  font-weight: 600;

  border: 1px solid transparent;
  border-radius: 0.75rem;
  background: #fbfcfa;

  cursor: pointer;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.membership-page .checkbox-list label:not(.config-option):hover,
.membership-page .checkbox-row:hover {
  background: var(--membership-sage);
  border-color: var(--membership-border);
}

.membership-page input[type="checkbox"],
.membership-page input[type="radio"] {
  width: auto;
  min-height: auto;
  margin: 0.2rem 0 0;
  padding: 0;
  accent-color: var(--membership-green);
}

.membership-page .inline-help {
  flex-basis: 100%;
  margin-left: 1.7rem;
  color: var(--membership-muted);
  font-size: 0.88rem;
  font-weight: 400;
  line-height: 1.45;
}

/* Submit button */

.membership-page button[type="submit"] {
  display: block;
  width: 100%;
  min-height: 52px;
  margin-top: 1.5rem;
  padding: 0.85rem 1.25rem;

  color: #ffffff;
  font: inherit;
  font-weight: 800;

  background: var(--membership-green-dark);
  border: 0;
  border-radius: 0.85rem;

  cursor: pointer;
  box-shadow: 0 10px 24px rgba(53, 95, 57, 0.2);

  transition:
    transform 0.2s ease,
    background-color 0.2s ease,
    box-shadow 0.2s ease;
}

.membership-page button[type="submit"]:hover {
  transform: translateY(-1px);
  background: var(--membership-forest);
  box-shadow: 0 14px 30px rgba(53, 95, 57, 0.25);
}

.membership-page button[type="submit"]:focus-visible {
  outline: 3px solid rgba(79, 122, 69, 0.3);
  outline-offset: 3px;
}

@media (max-width: 700px) {
  body.membership-page {
    padding: 0;
    background-attachment: scroll;
  }

  .membership-page .membership-shell {
    min-height: 100vh;
    padding: 1.15rem;
    border: 0;
    border-radius: 0;
  }

  .individual-membership-page .membership-shell,
  .corporate-membership-page .membership-shell {
    width: 100%;
    min-height: calc(100vh - 4.65rem);
    margin: 0;
  }

  .membership-page #servicesContainer {
    grid-template-columns: 1fr;
  }

  .membership-page fieldset {
    padding: 1.1rem;
  }
}

/* =========================================================
   Authentication pages
   ========================================================= */

body.auth-page,
body.payment-page {
  background:
    linear-gradient(rgba(247, 249, 244, 0.9), rgba(247, 249, 244, 0.94)),
    url("/assets/images/abstract_tree_background.png") center / cover fixed no-repeat;
}

.auth-main,
.payment-main {
  width: 100%;
  padding: clamp(2rem, 6vw, 5rem) 1rem;
}

.auth-shell,
.payment-card {
  width: min(100%, 1040px);
  margin: 0 auto;
}

.auth-intro,
.payment-page .page-intro {
  max-width: 760px;
  margin: 0 auto 2rem;
  text-align: center;
}

.auth-intro h1,
.payment-page .page-intro h1 {
  max-width: none;
  text-align: center;
}

.auth-intro .lead,
.payment-page .page-intro .lead {
  margin-left: auto;
  margin-right: auto;
}

.auth-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}

.auth-card,
.payment-card {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #d9dfcf;
  border-radius: 1.35rem;
  padding: clamp(1.25rem, 4vw, 2rem);
  box-shadow: 0 18px 48px rgba(23, 53, 31, 0.12);
  backdrop-filter: blur(8px);
}

.auth-card h2,
.discount-card h2,
.profile-status-card h2 {
  font-size: clamp(1.35rem, 3vw, 1.85rem);
}

.auth-form {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

/* Grid display otherwise overrides the browser's native hidden state. */
.auth-form[hidden] {
  display: none;
}

.auth-form label {
  margin-bottom: -0.4rem;
}

.auth-form .button {
  width: 100%;
  margin-top: 0.5rem;
}

.field-hint {
  margin: -0.35rem 0 0;
  color: #526050;
  font-size: 0.9rem;
}

.text-button {
  min-height: auto;
  width: auto;
  justify-self: center;
  padding: 0.25rem;
  color: #1f6f43;
  background: transparent;
  border: 0;
  border-radius: 0;
  text-decoration: underline;
  box-shadow: none;
}

.text-button:hover {
  color: #144c2d;
  background: transparent;
}

/* ---------- Consistent Page Intro Alignment ---------- */

.page-intro {
  width: 100%;
  max-width: 760px;
  margin: 0 auto 2rem;
  text-align: center;
}

.page-intro > .eyebrow,
.page-intro > h1,
.page-intro > .lead {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.page-intro > .eyebrow,
.page-intro > h1 {
  width: 100%;
  max-width: none;
}

/* ---------- Utility / Status Pages ---------- */

body.utility-page {
  min-height: 100vh;
  background-color: #f7f9f4;
  background-image:
    linear-gradient(
      rgba(247, 249, 244, 0.9),
      rgba(247, 249, 244, 0.94)
    ),
    url("/assets/images/abstract_tree_background.png");
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

.utility-page .site-shell {
  min-height: 100vh;
}

.utility-page .utility-main {
  flex: 1;
  display: grid;
  place-items: center;
  width: min(100%, 760px);
  margin: 0 auto;
  padding: clamp(2rem, 7vw, 5rem) 1rem;
}

.utility-page .utility-card {
  width: 100%;
  padding: clamp(1.5rem, 5vw, 3rem);
  text-align: center;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid #d9dfcf;
  border-radius: 1.5rem;
  box-shadow:
    0 24px 60px rgba(23, 53, 31, 0.12),
    0 6px 18px rgba(23, 53, 31, 0.08);
  backdrop-filter: blur(8px);
}

.utility-page .utility-brand {
  display: inline-block;
  margin-bottom: 1.25rem;
  color: #17351f;
  font-weight: 800;
  text-decoration: none;
}

.utility-page .utility-status {
  width: 100%;
  max-width: none;
  margin: 0 0 0.5rem;
  color: #5a6d3d;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-align: center;
  text-transform: uppercase;
}

.utility-page .utility-card h1 {
  width: 100%;
  max-width: none;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
  font-size: clamp(2rem, 6vw, 3.5rem);
}

.utility-page .utility-card p {
  margin-left: auto;
  margin-right: auto;
  color: #344a38;
}

.utility-page .utility-actions {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.utility-page .utility-form {
  max-width: 520px;
  margin: 1.5rem auto 0;
  text-align: left;
}

.utility-page .utility-form label {
  color: #17351f;
}

.utility-page .utility-form button {
  width: 100%;
  margin-top: 1rem;
}

.utility-page .utility-message {
  min-height: 1.5rem;
  margin-top: 1rem;
  font-weight: 700;
}

.utility-page .utility-message.error {
  color: #8a1f11;
}

.utility-page .utility-message.success {
  color: #1f6f43;
}

.utility-page .utility-countdown {
  color: #526050;
  font-size: 0.95rem;
}

@media (max-width: 600px) {
  body.utility-page {
    background-attachment: scroll;
  }

  .utility-page .utility-main {
    padding: 1rem;
  }

  .utility-page .utility-card {
    padding: 1.4rem;
    border-radius: 1rem;
  }

  .utility-page .utility-actions .button {
    width: 100%;
  }
}

/* =========================================================
   Shared membership and profile refinements
   ========================================================= */

.membership-brand {
  display: block;
  width: max-content;
  margin: 0 auto 1.25rem;
  color: #17351f;
  font-weight: 800;
  text-decoration: none;
}

.field-label {
  display: block;
  margin: 0.9rem 0 0.35rem;
  color: var(--membership-forest, #17351f);
  font-weight: 700;
}

.membership-page .form-field > label:first-child,
.membership-page .phone-field-row label {
  margin-top: 0;
}

.membership-page input[type="tel"] {
  display: block;
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: 0.75rem 0.9rem;
  color: var(--membership-text);
  font: inherit;
  background: #ffffff;
  border: 1px solid var(--membership-control-border);
  border-radius: 0.75rem;
}

.membership-page input[type="tel"]:focus {
  outline: none;
  border-color: var(--membership-green);
  box-shadow: 0 0 0 4px rgba(79, 122, 69, 0.14);
}

.membership-page #servicesContainer,
.profile-page #servicesContainer {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.profile-page .profile-status-card {
  margin-top: 1.25rem;
  padding: 1.25rem;
  background: #eef2e7;
  border: 1px solid #d9dfcf;
  border-radius: 1rem;
}

.profile-page #referralProgramCard .referral-link-preview {
  margin: 0.65rem 0 0;
  color: #344a38;
  font-size: 0.92rem;
  overflow-wrap: anywhere;
}

.profile-page #referralProgramCard [data-referral-vanity-input]:disabled {
  background: #e1e5dc;
  color: #667065;
  cursor: not-allowed;
  opacity: 0.82;
}

.profile-page #referralProgramCard .referral-status {
  margin: 1rem auto 0;
  padding: 0.8rem 1rem;
  max-width: 34rem;
  border: 1px solid rgba(31, 111, 67, 0.3);
  border-radius: 0.75rem;
  background: #f7fbf5;
  color: #245436;
  font-weight: 700;
  text-align: center;
}

.profile-page #referralProgramCard .referral-status[data-state="error"] {
  border-color: rgba(138, 31, 17, 0.38);
  background: #fff4f1;
  color: #8a1f11;
}

.profile-page #referralProgramCard .referral-status[hidden] {
  display: none;
}

.payment-action-card {
  margin-top: 1.25rem;
}

.payment-action-card .button {
  width: 100%;
  margin-top: 0.75rem;
}

.payment-action-card[hidden] {
  display: none;
}

.profile-page .payment-info {
  color: #344a38;
}

.profile-page .payment-info p:last-child {
  margin-bottom: 0;
}

.profile-page #renewButton {
  width: 100%;
  margin-top: 1rem;
}

/* =========================================================
   Payment page
   ========================================================= */

.payment-card {
  max-width: 760px;
}

.payment-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

/* `display: grid` above outranks the user-agent rule for [hidden], so the
   attribute alone would not hide the quote summary. Same fix already applied
   to .payment-action-card. */
.payment-summary[hidden] {
  display: none;
}

.payment-summary p {
  max-width: none;
  margin: 0;
  padding: 1rem;
  background: #eef2e7;
  border: 1px solid #d9dfcf;
  border-radius: 0.85rem;
}

.payment-summary strong {
  display: block;
  margin-top: 0.25rem;
  color: #17351f;
  font-size: 1.2rem;
}

.discount-card {
  margin: 1.25rem 0;
  padding: 1.25rem;
  border: 1px solid #d9dfcf;
  border-radius: 1rem;
  background: #f7f9f5;
}

.discount-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  align-items: end;
}

.discount-row .button {
  white-space: nowrap;
}

.payment-provider {
  margin-top: 1.5rem;
}

.payment-note {
  margin: 1.25rem auto 0;
  color: #526050;
  font-size: 0.9rem;
  text-align: center;
}

@media (max-width: 760px) {
  .auth-grid,
  .payment-summary,
  .discount-row,
  .membership-page #servicesContainer,
  .profile-page #servicesContainer {
    grid-template-columns: 1fr;
  }

  body.auth-page,
  body.payment-page {
    background-attachment: scroll;
  }
}

/* =========================================================
   Unified membership/profile forms - 2026-06-25
   ========================================================= */

.membership-page .form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem 1.25rem;
}

.membership-page .form-field {
  min-width: 0;
}

.membership-page .form-field-full {
  grid-column: 1 / -1;
}

.membership-page .phone-field-row {
  display: grid;
  grid-template-columns: minmax(180px, 0.75fr) minmax(0, 1.25fr);
  gap: 1rem;
  align-items: end;
}

.membership-page textarea {
  display: block;
  width: 100%;
  min-height: 130px;
  margin: 0;
  padding: 0.75rem 0.9rem;
  resize: vertical;
  color: var(--membership-text);
  font: inherit;
  background: #ffffff;
  border: 1px solid var(--membership-control-border);
  border-radius: 0.75rem;
}

.membership-page textarea:focus {
  outline: none;
  border-color: var(--membership-green);
  box-shadow: 0 0 0 4px rgba(79, 122, 69, 0.14);
}

/* Keep long service names beside their checkbox rather than below it. */
.membership-page #servicesContainer .checkbox-row {
  display: grid;
  grid-template-columns: 1.1rem minmax(0, 1fr);
  align-items: start;
  gap: 0.65rem;
  flex-wrap: nowrap;
}

.membership-page #servicesContainer .checkbox-row > input[type="checkbox"] {
  grid-column: 1;
  margin-top: 0.22rem;
}

.membership-page #servicesContainer .checkbox-row > span {
  grid-column: 2;
  min-width: 0;
  overflow-wrap: anywhere;
  line-height: 1.45;
}

/* Structured credential and capability option cards. */
.membership-page .checkbox-list label.config-option {
  display: grid;
  grid-template-columns: 1.1rem minmax(0, 1fr);
  align-items: start;
  gap: 0.65rem;
  margin: 0;
  padding: 0.75rem 0.85rem;
  color: var(--membership-text);
  font-weight: 600;
  border: 1px solid transparent;
  border-radius: 0.75rem;
  background: #fbfcfa;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.membership-page .checkbox-list label.config-option:hover {
  background: var(--membership-sage);
  border-color: var(--membership-border);
}

.membership-page .checkbox-list label.config-option > input[type="checkbox"] {
  grid-column: 1;
  margin-top: 0.22rem;
}

.membership-page .checkbox-list label.config-option .config-option-copy {
  grid-column: 2;
  min-width: 0;
  overflow-wrap: anywhere;
}

.membership-page .checkbox-list label.config-option .config-option-label {
  display: block;
  line-height: 1.45;
}

.membership-page .checkbox-list label.config-option .inline-help {
  display: block;
  margin: 0.25rem 0 0;
  color: var(--membership-muted);
  font-size: 0.88rem;
  font-weight: 400;
  line-height: 1.45;
}

.membership-page .corporate-plan-summary {
  margin: 0;
  padding: 1rem 1.1rem;
  background: var(--membership-sage);
  border: 1px solid var(--membership-border);
  border-radius: 0.85rem;
  color: var(--membership-forest);
}

.membership-page .business-plan-guide {
  margin: 0 0 1rem;
  padding: 1rem 1.1rem;
  background: var(--membership-sage);
  border: 1px solid var(--membership-border);
  border-radius: 0.85rem;
  color: var(--membership-forest);
}

.membership-page .business-plan-guide h3,
.membership-page .business-plan-guide p {
  margin-top: 0;
}

.membership-page .business-plan-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.membership-page .business-plan-list li {
  display: grid;
  gap: 0.2rem;
  padding: 0.8rem;
  background: #ffffff;
  border: 1px solid var(--membership-border);
  border-radius: 0.7rem;
}

.membership-page .business-plan-list span {
  color: var(--membership-muted);
  font-size: 0.92rem;
}

.membership-page .business-plan-enterprise {
  margin: 0.85rem 0 0;
}

.membership-page .form-actions {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.membership-page .form-actions button {
  margin: 0;
}

@media (max-width: 760px) {
  .membership-page .form-grid,
  .membership-page .phone-field-row {
    grid-template-columns: 1fr;
  }

  .membership-page .form-field-full {
    grid-column: auto;
  }

  .membership-page .business-plan-list {
    grid-template-columns: 1fr;
  }
}


/* Unified form action buttons */
.membership-page .form-actions .button,
.membership-page .form-actions button {
  width: 100%;
}

.membership-page .form-field .help-text {
  margin-top: 0.45rem;
}

.membership-page .form-note + .form-section,
.membership-page .form-section + .form-section {
  margin-top: 1rem;
}

/* ---------- Secure Membership Payment ---------- */

.payment-page .payment-main {
  width: min(100%, 820px);
}

.payment-page .payment-card {
  text-align: left;
}

.payment-page .payment-card > .utility-brand,
.payment-page .payment-card > .utility-status,
.payment-page .payment-card > h1,
.payment-page .payment-card > p {
  display: block;
  text-align: center;
}

/* One bordered card with internal dividers, rather than a separate box per
   row. `auto-fit` keeps three items evenly filling the width today and
   leaves room for a future row (for example, an applied referral credit)
   to join the same card without a layout change. */
.payment-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0;
  margin: 1.5rem 0;
  background: #f7f9f4;
  border: 1px solid #d9dfcf;
  border-radius: 0.9rem;
  overflow: hidden;
}

.payment-summary > div {
  padding: 1rem;
  text-align: center;
  border-right: 1px solid #d9dfcf;
}

.payment-summary > div:last-child {
  border-right: 0;
}

.payment-summary dt {
  color: #526050;
  font-size: 0.85rem;
  font-weight: 700;
}

.payment-summary dd {
  margin: 0.3rem 0 0;
  color: #17351f;
  font-size: 1.1rem;
  font-weight: 800;
}

.payment-inline-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  align-items: end;
}

.payment-inline-fields .button {
  width: auto;
  white-space: nowrap;
}

.payment-security {
  margin: 1.5rem 0;
  padding: 1rem;
  background: #f7f9f4;
  border: 1px solid #d9dfcf;
  border-radius: 0.9rem;
}

/* An author rule that sets `display` outranks the user-agent `[hidden]` rule,
   so `element.hidden = true` alone leaves the control on screen. Two global
   rules do exactly that to the confirmation controls:
     `.button, button { display: inline-flex; }`
     `.utility-page .utility-actions { display: flex; }`
   That is why an approved payment could show Check payment status, Try payment
   again, Start a new payment, and Return to profile all at once. Scoped to the
   payment page and given attribute specificity so the JS that already sets
   `.hidden` takes visual effect. Same fix already applied to
   .payment-action-card and .payment-summary. */
.payment-page .button[hidden],
.payment-page button[hidden],
.payment-page .utility-actions[hidden] {
  display: none;
}

/* Visual-only accent for the confirmation card. Each rule keys off a control
   that setConfirmingContent() already shows only from the authoritative
   payment-status response — no new class, no new status meaning, and no
   coupling to the URL or a cancel flag. Unsupported browsers simply keep the
   neutral .payment-security border above. */
#paymentConfirmingSection:has(#confirmedProfileLink:not([hidden])) {
  border-left: 6px solid #1f6f43;
}

#paymentConfirmingSection:has(#startNewPaymentButton:not([hidden])) {
  border-left: 6px solid #8a1f11;
}

#paymentConfirmingSection:has(#retryPaymentButton:not([hidden])) {
  border-left: 6px solid #b05a00;
}

.payment-provider {
  max-width: 520px;
  margin: 1.25rem auto 0;
}

.payment-page #completeFreeButton {
  width: min(100%, 520px);
  margin: 1.25rem auto 0;
}

/* Center the zero-dollar membership completion button. */
.payment-page #completeFreeButton {
  display: flex;
  margin-left: auto;
  margin-right: auto;
}

.payment-review-main {
  width: min(100%, 1200px) !important;
}

.payment-review-card {
  max-width: none;
  text-align: left !important;
}

.payment-review-card > .utility-brand,
.payment-review-card > .utility-status,
.payment-review-card > h1,
.payment-review-card > p {
  display: block;
  text-align: center;
}

.payment-review-table-wrap {
  overflow-x: auto;
  margin-top: 1.5rem;
}

.payment-review-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.payment-review-table th,
.payment-review-table td {
  padding: 0.75rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid #d9dfcf;
}

.payment-review-table th {
  color: #17351f;
  background: #eef2e7;
}

.payment-review-table .button {
  width: auto;
  min-width: 150px;
  padding: 0.55rem 0.8rem;
  border-radius: 0.7rem;
  font-size: 0.85rem;
}

@media (max-width: 700px) {
  .payment-summary,
  .payment-inline-fields {
    grid-template-columns: 1fr;
  }

  .payment-summary > div {
    border-right: 0;
    border-bottom: 1px solid #d9dfcf;
  }

  .payment-summary > div:last-child {
    border-bottom: 0;
  }

  .payment-inline-fields .button {
    width: 100%;
  }
}

/* ---------- Payment card stacking ---------- */

.payment-page .payment-card {
  position: relative;
  z-index: 1;
  overflow: visible;
  background: #ffffff;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

/* =========================================================
   Site dialog — layout and modal chrome only.
   Button colours and radius come from the existing
   .button, .button-primary, .button-secondary rules.
   ========================================================= */

#inaa-dialog-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(23, 53, 31, 0.55);
  backdrop-filter: blur(3px);
  overscroll-behavior: contain;
}

.inaa-dialog-box {
  width: min(100%, 480px);
  max-height: calc(100vh - 2rem);
  overflow-y: auto;
  padding: clamp(1.5rem, 5vw, 2.5rem);
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 1.25rem;
  box-shadow: 0 24px 60px rgba(23, 53, 31, 0.2);
}

@supports (height: 100dvh) {
  .inaa-dialog-box {
    max-height: calc(100dvh - 2rem);
  }
}

.inaa-dialog-title {
  margin: 0 0 0.5rem;
  color: #17351f;
  font-size: 1.1rem;
  font-weight: 800;
  max-width: none;
}

.inaa-dialog-message {
  margin: 0 0 1.5rem;
  color: #344a38;
  max-width: none;
}

.inaa-dialog-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  flex-wrap: wrap;
}

/* On mobile the buttons stack and fill the width,
   matching the existing responsive button rule. */
@media (max-width: 480px) {
  .inaa-dialog-actions {
    flex-direction: column-reverse;
  }
}

/* ── Finder additions: capability badges + relaxed-results note ── */

.finder-badge-dist-unknown {
  background: #f1f1ea;
  color: #526050;
}

.finder-badge-consulting {
  background: #e8eef7;
  color: #1e4c7a;
}

.finder-badge-handson {
  background: #f3ecdf;
  color: #6b4d12;
}

.finder-badge-emergency {
  background: #fdeeea;
  color: #8a1f11;
}

.finder-relaxed-note {
  margin: 0 0 1.25rem;
  padding: 0.85rem 1rem;
  background: #fff8e6;
  border: 1px solid #e5c46b;
  border-radius: 0.75rem;
  color: #4d3b00;
  font-size: 0.92rem;
  max-width: none;
}

.finder-legend-num-loc {
  font-size: 0.82rem;
}

/* ── Finder: "Why this matched" line ── */

.finder-card-why {
  margin: 0;
  font-size: 0.88rem;
  color: #1f6f43;
  max-width: none;
}

.finder-flow-note {
  max-width: 820px;
  margin: 1.25rem 0 2rem;
  padding: 1rem 1.15rem;
  background: rgba(31, 111, 67, 0.08);
  border: 1px solid rgba(31, 111, 67, 0.16);
  border-left: 5px solid #1f6f43;
  border-radius: 1rem;
}

.finder-flow-note h2 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.15rem, 2.5vw, 1.35rem);
}

.finder-flow-note p {
  max-width: none;
}

.finder-flow-note p:last-child {
  margin-bottom: 0;
}

/* =========================================================
   Finder — find.html questionnaire and results
   ========================================================= */

/* ── Page intro ─────────────────────────────────────────────────── */

.finder-intro {
  max-width: 920px;
  margin-bottom: 1.5rem;
}


/* ── Form layout ────────────────────────────────────────────────── */

.finder-form {
  max-width: 920px;
}

.finder-fieldset {
  margin: 0 0 2rem;
  padding: clamp(1rem, 3vw, 1.35rem);
  border: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 22px rgba(23, 53, 31, 0.04);
}

.finder-legend {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0 0.4rem;
  color: #17351f;
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  font-weight: 800;
}

.finder-legend-num {
  flex: 0 0 auto;
  min-width: 2rem;
  min-height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.75rem;
  background: #1f6f43;
  color: #ffffff;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}

.finder-legend-tag {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  padding: 0.3rem 0.7rem;
  background: #1f6f43;
  color: #ffffff;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
}

.finder-legend-num-loc {
  font-size: 1.1rem;
}

.finder-legend-optional {
  font-size: 0.85rem;
  font-weight: 500;
  color: #526050;
}

/* ── Option cards ───────────────────────────────────────────────── */

.finder-option-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 0.85rem;
}

.finder-option-card-wide {
  grid-column: 1 / -1;
}

.finder-option-card {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  min-height: 100%;
  margin: 0;
  padding: 1rem 1.1rem;
  background: #ffffff;
  border: 2px solid #d9dfcf;
  border-radius: 1rem;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

.finder-option-card:hover {
  border-color: #1f6f43;
  background: #f7fbf3;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(23, 53, 31, 0.07);
}

.finder-option-card input[type="radio"],
.finder-option-card input[type="checkbox"] {
  flex: 0 0 auto;
  margin-top: 0.25rem;
  width: auto;
  min-height: auto;
  accent-color: #1f6f43;
}

.finder-option-card:has(input:checked) {
  border-color: #1f6f43;
  background: #f0f7ec;
  box-shadow: 0 8px 20px rgba(23, 53, 31, 0.08);
}

.finder-option-content {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
}

.finder-option-title {
  color: #17351f;
  font-weight: 800;
  line-height: 1.25;
}

.finder-option-hint {
  color: #526050;
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.4;
}

/* ── Location section ───────────────────────────────────────────── */

.finder-loc-btn {
  margin-top: 0.5rem;
}

.finder-loc-status {
  min-height: 1.4em;
  margin-top: 0.65rem;
  color: #1f6f43;
  font-size: 0.92rem;
  font-weight: 700;
}

.finder-loc-or {
  margin: 1.25rem 0 0.75rem;
  color: #526050;
  font-size: 0.86rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.finder-loc-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.finder-loc-field label {
  display: block;
  margin-bottom: 0.3rem;
  color: #17351f;
  font-size: 0.9rem;
  font-weight: 800;
}

.finder-loc-note {
  margin-top: 0.65rem;
}

/* ── Submit button ──────────────────────────────────────────────── */

.finder-submit-btn {
  min-width: 220px;
  margin-top: 0.25rem;
}

/* ── Results section ────────────────────────────────────────────── */

.finder-results-section {
  padding-top: clamp(2.5rem, 6vw, 4rem);
}

.finder-results-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.finder-results-count {
  margin: 0;
  font-size: clamp(1.65rem, 4vw, 2.6rem);
}

.finder-results-list {
  display: grid;
  gap: 1.15rem;
}

.finder-no-results {
  max-width: 60ch;
  color: #526050;
}

.finder-relaxed-note {
  margin: 0 0 1.25rem;
  padding: 0.85rem 1rem;
  background: #fff8e6;
  border: 1px solid #e5c46b;
  border-radius: 0.75rem;
  color: #4d3b00;
  font-size: 0.92rem;
  max-width: none;
}

/* ── Result cards ───────────────────────────────────────────────── */

.finder-card {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 1.25rem;
  box-shadow: 0 10px 28px rgba(23, 53, 31, 0.08);
  overflow: hidden;
  transition:
    box-shadow 0.15s ease,
    transform 0.15s ease,
    border-color 0.15s ease;
}

.finder-card + .finder-card {
  margin-top: 0;
}

.finder-card:hover {
  transform: translateY(-1px);
  border-color: rgba(31, 111, 67, 0.28);
  box-shadow: 0 14px 36px rgba(23, 53, 31, 0.13);
}

.finder-card-inner {
  display: grid;
  gap: 0.65rem;
  padding: clamp(1.1rem, 3vw, 1.5rem);
}

/* ── Finder result avatar/logo area ─────────────────────────────── */

.finder-card-media-row {
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr);
  gap: 0.9rem;
  align-items: start;
}

.finder-card-main {
  min-width: 0;
  display: grid;
  gap: 0.45rem;
}

.finder-card-avatar {
  width: 4rem;
  height: 4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid rgba(23, 53, 31, 0.14);
  box-shadow: 0 8px 18px rgba(23, 53, 31, 0.08);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.finder-card-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #ffffff;
}

.finder-card-avatar-individual {
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(31, 111, 67, 0.95), rgba(23, 53, 31, 0.92));
}

.finder-card-avatar-company {
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(154, 106, 31, 0.95), rgba(91, 66, 23, 0.92));
}

.finder-card-affiliated .finder-card-avatar-individual {
  outline: 3px solid rgba(35, 107, 68, 0.18);
  outline-offset: 2px;
}

@media (max-width: 520px) {
  .finder-card-media-row {
    grid-template-columns: 3.25rem minmax(0, 1fr);
    gap: 0.75rem;
  }

  .finder-card-avatar {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 0.85rem;
    font-size: 0.9rem;
  }
}

.finder-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

/* Founder recognition is presentation-ready only until server-derived public
   listing authority is available. Empty hosts intentionally render nothing. */
.founder-badge-slot {
  display: contents;
}

.founder-badge-slot:empty {
  display: none;
}

.founder-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  width: max-content;
  max-width: 100%;
  min-height: 1.75rem;
  padding: 0.28rem 0.7rem 0.28rem 0.4rem;
  color: #4d3b00;
  background: #fff8e6;
  border: 1px solid #c99b32;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 850;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

.founder-badge__emblem {
  display: inline-grid;
  flex: 0 0 auto;
  width: 1.15rem;
  height: 1.15rem;
  place-items: center;
  color: #ffffff;
  background: #79581b;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.founder-badge__emblem::before {
  content: "✦";
  font-size: 0.68rem;
  line-height: 1;
}

.finder-badge {
  display: inline-flex;
  align-items: center;
  width: max-content;
  max-width: 100%;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

.finder-badge + .finder-badge {
  margin-left: 0;
}

.finder-badge-type {
  background: #eef2e7;
  color: #17351f;
}

.finder-badge-dist {
  background: #e6f0ea;
  color: #1f6f43;
}

.finder-badge-dist-unknown {
  background: #f1f1ea;
  color: #526050;
}

.finder-badge-consulting {
  background: #e8eef7;
  color: #1e4c7a;
}

.finder-badge-handson {
  background: #f3ecdf;
  color: #6b4d12;
}

.finder-badge-emergency {
  background: #fdeeea;
  color: #8a1f11;
}

.finder-card-name {
  margin: 0;
  color: #17351f;
  font-size: clamp(1.2rem, 2.5vw, 1.45rem);
  line-height: 1.2;
}

.finder-card-location {
  margin: -0.15rem 0 0;
  color: #526050;
  font-size: 0.95rem;
  max-width: none;
}

.finder-card-why {
  margin: 0.25rem 0 0;
  padding: 0.65rem 0.75rem;
  color: #1f6f43;
  background: rgba(31, 111, 67, 0.08);
  border-radius: 0.75rem;
  font-size: 0.9rem;
  max-width: none;
}

.finder-card-why-label {
  font-weight: 800;
}

.finder-card-summary {
  margin: 0;
  color: #344a38;
  font-size: 0.96rem;
  max-width: none;
}

.finder-card-chips {
  margin: 0;
  color: #526050;
  font-size: 0.88rem;
  line-height: 1.55;
  max-width: none;
}

.finder-card-foot {
  padding-top: 0.35rem;
}

.finder-card-link {
  width: auto;
}

.finder-load-more-wrap {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
}

/* ── Finder result type separation ──────────────────────────────── */

.finder-card-individual {
  border-left: 6px solid #1f6f43;
}

.finder-card-company {
  border-left: 6px solid #9a6a1f;
}

.finder-card-affiliated {
  border-left-color: #236b44;
  background:
    linear-gradient(90deg, rgba(35, 107, 68, 0.045), rgba(255, 255, 255, 0.94) 42%),
    rgba(255, 255, 255, 0.94);
}

.finder-badge-individual {
  background: #e6f0ea;
  color: #1f6f43;
}

.finder-badge-company {
  background: #f3ecdf;
  color: #6b4d12;
}

.finder-badge-affiliated {
  background: #edf6ef;
  color: #236b44;
  border: 1px solid rgba(35, 107, 68, 0.18);
}

.finder-card-affiliation {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: baseline;
  margin: 0.15rem 0 0;
  padding: 0.65rem 0.8rem;
  color: #17351f;
  background: rgba(35, 107, 68, 0.08);
  border: 1px solid rgba(35, 107, 68, 0.14);
  border-radius: 0.8rem;
  font-size: 0.92rem;
  max-width: none;
}

.finder-card-affiliation-label {
  color: #236b44;
  font-weight: 800;
}

.finder-card-affiliation-name {
  font-weight: 800;
}

/* ── Finder responsive ──────────────────────────────────────────── */

@media (max-width: 760px) {
  .finder-option-grid,
  .finder-loc-fields {
    grid-template-columns: 1fr;
  }

  .finder-results-header {
    align-items: stretch;
  }

  .finder-results-header .button,
  .finder-submit-btn,
  .finder-card-link {
    width: 100%;
  }

  .finder-fieldset {
    padding: 1rem;
  }
}

/* ──  Auth status pill ── */

.auth-status-badge {
  width: auto;
  height: auto;
  min-width: auto;
  min-height: 38px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.65);
  box-shadow: none;
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1;
  text-decoration: none;
  color: #ffffff;
  cursor: pointer;
  white-space: nowrap;
}

.auth-status-badge:hover,
.auth-status-badge:focus-visible {
  transform: none;
  box-shadow: none;
  text-decoration: underline;
  outline: 2px solid rgba(255, 255, 255, 0.35);
  outline-offset: 2px;
}

.auth-status-badge--inline {
  position: static;
  margin-left: 0.35rem;
}

.auth-status-badge--floating {
  position: fixed;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 1000;
}

.auth-status-badge--individual {
  background: #236b44;
}

.auth-status-badge--company {
  background: #9a6a1f;
}

.auth-status-badge--signed-out,
.auth-status-badge--loading {
  background: #526050;
}

.auth-status-badge--unknown {
  background: #5f6670;
}

.auth-status-badge__text {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.auth-status-badge__sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.auth-status-sign-out {
  min-height: 38px;
  width: auto;
  flex: 0 0 auto;
  padding: 0.45rem 0.6rem;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: underline;
  cursor: pointer;
}

.auth-status-sign-out:hover,
.auth-status-sign-out:focus-visible {
  background: transparent;
  color: #ffffff;
  outline: 2px solid rgba(255, 255, 255, 0.35);
  outline-offset: 2px;
}

.auth-status-sign-out[hidden] {
  display: none;
}

.auth-status-sign-out--inline {
  position: static;
}

.auth-status-sign-out--floating {
  position: fixed;
  top: 3.75rem;
  right: 0.75rem;
  z-index: 1000;
  border-radius: 0.5rem;
  background: #3f474f;
}

.auth-status-sign-out--floating:hover,
.auth-status-sign-out--floating:focus-visible {
  background: #30363c;
}

@media (max-width: 820px) {
  .site-nav .auth-status-badge--inline,
  .site-nav .auth-status-sign-out--inline {
    width: 100%;
    min-height: 44px;
    justify-content: flex-start;
    margin-left: 0;
    padding: 0.65rem 0.75rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.14);
  }

  .site-nav .auth-status-sign-out--inline {
    border: 0;
    color: #ffffff;
    font: inherit;
    text-decoration: underline;
  }
}

/* ---------- Public page hero section ---------- */
.home-page .home-hero .lead {
  max-width: 62ch;
}

.home-page .hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.4rem;
}

.section-heading-row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 1.5rem;
  align-items: end;
  margin-bottom: 1.5rem;
}

.section-heading-row h2,
.section-heading-row p {
  margin-bottom: 0;
}

.home-guide-grid a {
  display: grid;
  gap: 0.35rem;
}

.home-guide-grid small {
  color: var(--color-muted, #5f6b62);
  font-weight: 500;
  line-height: 1.4;
}

.section-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.final-cta-card {
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border-radius: 1.25rem;
  border: 1px solid rgba(27, 48, 37, 0.12);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 14px 34px rgba(27, 48, 37, 0.08);
  text-align: center;
}

.final-cta-card p {
  max-width: 650px;
  margin-left: auto;
  margin-right: auto;
}

@media (max-width: 800px) {
  .section-heading-row {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .home-page .hero-actions,
  .section-cta {
    flex-direction: column;
  }

  .home-page .hero-actions .button,
  .section-cta .button,
  .final-cta-card .button {
    width: 100%;
  }
}

/* ---------- Glossary Section ---------- */
.glossary-page .glossary-disclaimer {
  margin-bottom: 1.5rem;
}

.glossary-jump-section {
  padding-top: 0;
  padding-bottom: 1.5rem;
}

.glossary-jump-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.glossary-jump-links a {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  border: 1px solid rgba(27, 48, 37, 0.14);
  background: rgba(255, 255, 255, 0.82);
  font-weight: 700;
  text-decoration: none;
}

.glossary-jump-links a:hover,
.glossary-jump-links a:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(27, 48, 37, 0.1);
}

.glossary-content {
  display: grid;
  gap: 2rem;
  padding-bottom: 2rem;
}

.glossary-group {
  display: grid;
  gap: 1rem;
}

.glossary-group h2 {
  margin-bottom: 0;
}

.glossary-entry-grid {
  display: grid;
  gap: 1rem;
}

.glossary-entry {
  padding: 1.25rem;
  border-radius: 1rem;
  border: 1px solid rgba(27, 48, 37, 0.12);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 10px 26px rgba(27, 48, 37, 0.06);
  scroll-margin-top: 5rem;
}

.glossary-entry h3 {
  margin-top: 0;
  margin-bottom: 0.45rem;
}

.glossary-entry p:last-child {
  margin-bottom: 0;
}

.glossary-sources ul {
  margin: 0.75rem 0 0;
  padding-left: 1.2rem;
}

.glossary-sources li + li {
  margin-top: 0.35rem;
}

@media (min-width: 900px) {
  .glossary-entry-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------- Dropdown Menu ---------- */
.site-nav .nav-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.site-nav .nav-dropdown summary {
  list-style: none;
  cursor: pointer;
  font-weight: 700;
}

.site-nav .nav-dropdown summary::-webkit-details-marker {
  display: none;
}

.site-nav .nav-dropdown summary::after {
  content: "▾";
  display: inline-block;
  margin-left: 0.25rem;
  font-size: 0.72em;
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 0.65rem);
  right: 0;
  min-width: 250px;
  padding: 0.55rem;
  border-radius: 0.85rem;
  border: 1px solid rgba(27, 48, 37, 0.12);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 18px 36px rgba(27, 48, 37, 0.16);
  display: grid;
  gap: 0.15rem;
  z-index: 1001;
}

.nav-dropdown:not([open]) .nav-dropdown-menu {
  display: none;
}

.nav-dropdown-menu a {
  display: block;
  padding: 0.65rem 0.75rem;
  border-radius: 0.65rem;
  color: var(--color-text, #1b3025);
  text-decoration: none;
  white-space: nowrap;
}

.nav-dropdown.is-current-section > summary {
  color: var(--color-primary, #236b44);
}

.nav-dropdown-menu a:hover,
.nav-dropdown-menu a:focus-visible,
.nav-dropdown-menu a[aria-current="page"] {
  background: rgba(35, 107, 68, 0.1);
}

.utility-header {
  padding: 0.9rem 0;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid rgba(27, 48, 37, 0.1);
}

.utility-header-layout {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.utility-header-note {
  color: var(--color-muted, #5f6b62);
  font-size: 0.92rem;
  font-weight: 700;
}

.utility-footer {
  margin-top: 2rem;
}

@media (max-width: 820px) {
  .nav-container {
    align-items: stretch;
    gap: 0.75rem;
  }

  .site-logo {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }

  .site-nav {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    gap: 0.45rem;
    padding-top: 0.35rem;
  }

  .site-nav > a,
  .site-nav > .nav-dropdown > summary {
    width: 100%;
    min-height: 44px;
    display: flex;
    align-items: center;
    padding: 0.65rem 0.75rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.08);
  }

  .site-nav .nav-dropdown {
    display: block;
    width: 100%;
  }

  .nav-dropdown-menu {
    position: static;
    min-width: 0;
    width: 100%;
    margin-top: 0.35rem;
    padding: 0.35rem;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: none;
  }

  .nav-dropdown-menu a {
    color: #ffffff;
    white-space: normal;
  }

  .nav-dropdown-menu a:hover,
  .nav-dropdown-menu a:focus-visible,
  .nav-dropdown-menu a[aria-current="page"] {
    background: rgba(255, 255, 255, 0.14);
  }

  .nav-dropdown.is-current-section > summary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
  }

  .utility-header-layout {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* =========================================================
   Shared header mobile menu override
   ========================================================= */

.mobile-menu-toggle {
  display: none;
  width: auto;
  min-height: 44px;
  padding: 0.5rem 0.85rem;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  font-weight: 800;
}

.mobile-menu-toggle:hover,
.mobile-menu-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.18);
}

.site-header .nav-dropdown.is-current-section > summary {
  color: #ffffff;
  text-decoration: underline;
  text-underline-offset: 0.22em;
}

@media (max-width: 820px) {
  .nav-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    flex-direction: row;
    min-height: 3.75rem;
    padding: 0.45rem 0;
  }

  .site-logo {
    min-width: 0;
    font-size: clamp(0.98rem, 4.2vw, 1.08rem);
  }

  .mobile-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    justify-self: end;
  }

  .site-nav {
    grid-column: 1 / -1;
    display: none;
    grid-template-columns: 1fr;
    width: 100%;
    gap: 0.45rem;
    padding-top: 0.35rem;
  }

  .site-nav.is-open {
    display: grid;
    max-height: calc(100vh - 4.75rem);
    padding-bottom: 0.5rem;
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .site-nav > a,
  .site-nav > .nav-dropdown > summary,
  .site-nav .auth-status-badge--inline,
  .site-nav .auth-status-sign-out--inline {
    width: 100%;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0.65rem 0.75rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.08);
  }

  .site-nav .nav-dropdown {
    display: block;
    width: 100%;
  }

  .nav-dropdown-menu {
    position: static;
    min-width: 0;
    width: 100%;
    margin-top: 0.35rem;
    padding: 0.35rem;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: none;
  }

  .nav-dropdown-menu a {
    color: #ffffff;
    white-space: normal;
  }

  .nav-dropdown-menu a:hover,
  .nav-dropdown-menu a:focus-visible,
  .nav-dropdown-menu a[aria-current="page"] {
    background: rgba(255, 255, 255, 0.14);
  }

  .nav-dropdown.is-current-section > summary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
  }
}

@media (min-width: 821px) {
  .site-nav {
    display: flex !important;
  }
}

/* =========================================================
   Listing detail page
   ========================================================= */

.detail-breadcrumb {
  margin-bottom: 1.25rem;
}

.detail-breadcrumb a {
  font-weight: 800;
  text-decoration: none;
}

.detail-breadcrumb a:hover,
.detail-breadcrumb a:focus-visible {
  text-decoration: underline;
}

.detail-hero {
  display: grid;
  grid-template-columns: 5.5rem minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 1.5rem);
  align-items: start;
  margin-bottom: 1.5rem;
  padding: clamp(1.25rem, 4vw, 2rem);
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(23, 53, 31, 0.14);
  border-radius: 1.35rem;
  box-shadow: 0 14px 36px rgba(23, 53, 31, 0.1);
}

.detail-hero-company {
  border-left: 7px solid #9a6a1f;
}

.detail-hero-individual {
  border-left: 7px solid #1f6f43;
}

.detail-avatar {
  width: 5.5rem;
  height: 5.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 1.15rem;
  border: 1px solid rgba(23, 53, 31, 0.14);
  box-shadow: 0 10px 22px rgba(23, 53, 31, 0.1);
  color: #ffffff;
  font-size: 1.3rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.detail-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #ffffff;
}

.detail-avatar-individual {
  background: linear-gradient(135deg, rgba(31, 111, 67, 0.95), rgba(23, 53, 31, 0.92));
}

.detail-avatar-company {
  background: linear-gradient(135deg, rgba(154, 106, 31, 0.95), rgba(91, 66, 23, 0.92));
}

.detail-hero-copy {
  min-width: 0;
}

.detail-header-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.detail-name {
  max-width: none;
  margin-bottom: 0.35rem;
}

.detail-location {
  margin: 0 0 0.75rem;
  color: #526050;
  font-weight: 700;
  max-width: none;
}

.detail-hero-note {
  margin: 0;
  color: #344a38;
  max-width: 72ch;
}

.detail-featured-card {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(1rem, 3vw, 1.5rem);
  align-items: start;
  margin-bottom: 1.5rem;
  padding: clamp(1.25rem, 4vw, 1.75rem);
  background: #f7fbf3;
  border: 1px solid rgba(31, 111, 67, 0.18);
  border-left: 7px solid #1f6f43;
  border-radius: 1.25rem;
  box-shadow: 0 10px 28px rgba(23, 53, 31, 0.08);
}

.detail-featured-card h2 {
  margin-bottom: 0.5rem;
  font-size: clamp(1.35rem, 3vw, 2rem);
}

.detail-featured-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.detail-featured-item {
  display: inline-flex;
  align-items: center;
  padding: 0.48rem 0.75rem;
  color: #17351f;
  background: #ffffff;
  border: 1px solid rgba(31, 111, 67, 0.22);
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 850;
  box-shadow: 0 6px 16px rgba(23, 53, 31, 0.06);
}

.detail-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.35fr);
  gap: clamp(1rem, 3vw, 1.5rem);
  align-items: start;
}

.detail-main,
.detail-sidebar {
  display: grid;
  gap: 1rem;
}

.detail-card {
  padding: clamp(1.15rem, 3vw, 1.5rem);
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(23, 53, 31, 0.12);
  border-radius: 1.15rem;
  box-shadow: 0 10px 28px rgba(23, 53, 31, 0.07);
}

.detail-card-heading {
  margin-bottom: 0.65rem;
  font-size: clamp(1.15rem, 2.5vw, 1.45rem);
}

.detail-summary {
  color: #344a38;
  max-width: none;
}

.detail-self-report-note {
  margin-bottom: 0.85rem;
  color: #526050;
  font-size: 0.9rem;
  font-weight: 700;
  max-width: none;
}

.detail-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.detail-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.42rem 0.68rem;
  color: #17351f;
  background: #eef2e7;
  border: 1px solid rgba(23, 53, 31, 0.12);
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 750;
  line-height: 1.25;
}

.detail-chip-featured {
  color: #ffffff;
  background: #1f6f43;
  border-color: #1f6f43;
}

.detail-contact-list,
.detail-meta-list {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.45rem 0.75rem;
  margin: 0;
}

.detail-contact-term,
.detail-meta-term {
  color: #526050;
  font-size: 0.86rem;
  font-weight: 800;
}

.detail-contact-value,
.detail-meta-value {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
  color: #17351f;
  font-weight: 700;
}

.detail-contact-note {
  margin: 1rem 0 0;
  padding: 0.85rem;
  background: #fff8e6;
  border: 1px solid #e5c46b;
  border-radius: 0.85rem;
  color: #4d3b00;
  font-size: 0.9rem;
  max-width: none;
}

.detail-loading {
  font-weight: 800;
}

.detail-hero-note.important-note {
  margin-top: 0.85rem;
  margin-bottom: 0;
}

.detail-featured-help.important-note {
  margin-top: 0.75rem;
  margin-bottom: 0;
}

@media (max-width: 860px) {
  .detail-body,
  .detail-featured-card {
    grid-template-columns: 1fr;
  }

  .detail-sidebar {
    order: -1;
  }
}

@media (max-width: 560px) {
  .detail-hero {
    grid-template-columns: 1fr;
  }

  .detail-avatar {
    width: 4.5rem;
    height: 4.5rem;
  }

  .detail-contact-list,
  .detail-meta-list {
    grid-template-columns: 1fr;
  }

  .detail-contact-term,
  .detail-meta-term {
    margin-top: 0.35rem;
  }
}

/* ---------- Important notes / self-reported statements ---------- */

.important-note {
  position: relative;
  max-width: none;
  margin: 0.85rem 0;
  padding: 0.9rem 1rem 0.9rem 2.65rem;
  color: #17351f;
  background: rgba(31, 111, 67, 0.08);
  border: 1px solid rgba(31, 111, 67, 0.16);
  border-left: 5px solid #1f6f43;
  border-radius: 1rem;
}

.important-note span[aria-hidden="true"] {
  position: absolute;
  top: 0.7rem;
  left: 1rem;
  color: #1f6f43;
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1;
}

.important-note em {
  font-style: italic;
  font-weight: 700;
}

.important-note p {
  margin: 0;
  max-width: none;
}

.finder-results-notice {
  margin-bottom: 1.25rem;
}


/* ---------- Launch polish: membership section summary affordance ---------- */
/* Makes collapsed and expanded membership/profile form sections read as interactive groups. */
body.membership-page .form-section > summary,
body.membership-page .config-group > summary {
  position: relative;
  border-bottom: 1px solid rgba(23, 53, 31, 0.12);
  background:
    linear-gradient(90deg, rgba(31, 111, 67, 0.12), rgba(31, 111, 67, 0.03) 42%, rgba(255, 255, 255, 0));
  box-shadow: inset 4px 0 0 rgba(31, 111, 67, 0.35);
}

body.membership-page .form-section > summary:hover,
body.membership-page .config-group > summary:hover {
  background:
    linear-gradient(90deg, rgba(31, 111, 67, 0.18), rgba(31, 111, 67, 0.06) 45%, rgba(255, 255, 255, 0));
}

body.membership-page .form-section[open] > summary,
body.membership-page .config-group[open] > summary {
  background:
    linear-gradient(90deg, rgba(31, 111, 67, 0.22), rgba(31, 111, 67, 0.08) 48%, rgba(255, 255, 255, 0));
  box-shadow: inset 4px 0 0 #1f6f43;
}

body.membership-page .form-section > summary:focus-visible,
body.membership-page .config-group > summary:focus-visible {
  outline: 3px solid #b05a00;
  outline-offset: 3px;
  box-shadow:
    inset 4px 0 0 #1f6f43,
    0 0 0 4px rgba(31, 111, 67, 0.16);
}

body.membership-page .form-section > summary::after,
body.membership-page .config-group > summary::after {
  border-color: #17351f;
  opacity: 0.95;
}



/* Phase 1D: account verification and registration security */
.registration-security {
  margin: 1rem 0 1.25rem;
  padding: 1rem;
  border: 1px solid rgba(31, 93, 63, 0.22);
  border-radius: 0.75rem;
  background: rgba(239, 247, 242, 0.72);
}

.registration-security .help-text {
  margin-top: 0;
}

.utility-actions--stacked {
  align-items: stretch;
  flex-direction: column;
}

.utility-actions--stacked .button,
.utility-actions--stacked .text-button {
  width: 100%;
}


/* Phase 1E1: shared profile image editor */
.profile-image-fieldset {
  scroll-margin-top: 1rem;
}

.profile-image-editor {
  display: grid;
  grid-template-columns: minmax(7rem, 9rem) minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 1.5rem);
  align-items: start;
}

.profile-image-preview {
  width: 100%;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid rgba(23, 53, 31, 0.18);
  border-radius: 1rem;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(23, 53, 31, 0.08);
  color: #ffffff;
  font-size: 1.3rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.individual-profile-page .profile-image-preview {
  background: linear-gradient(135deg, rgba(31, 111, 67, 0.95), rgba(23, 53, 31, 0.92));
}

.corporate-profile-page .profile-image-preview {
  background: linear-gradient(135deg, rgba(154, 106, 31, 0.95), rgba(91, 66, 23, 0.92));
}

.profile-image-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #ffffff;
}

.profile-image-controls {
  min-width: 0;
}

.profile-image-controls > p:first-child {
  margin-top: 0;
}

.profile-image-controls input[type="file"] {
  display: block;
  width: 100%;
  margin-top: 0.45rem;
}

.profile-image-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.9rem;
}

.profile-image-actions[hidden] {
  display: none;
}

.profile-image-status {
  min-height: 1.5em;
  margin-bottom: 0;
}

.profile-image-status.form-error {
  color: #8b1e1e;
  font-weight: 700;
}

@media (max-width: 620px) {
  .profile-image-editor {
    grid-template-columns: 1fr;
  }

  .profile-image-preview {
    width: min(9rem, 45vw);
  }
}

@media (max-width: 600px) {
  html {
    scroll-padding-top: 4.75rem;
  }

  main [id] {
    scroll-margin-top: 4.75rem;
  }

  .section {
    padding: clamp(2rem, 8vw, 3.25rem) 0;
  }

  .home-page .home-hero {
    padding-top: 1rem;
    padding-bottom: 2.25rem;
  }

  .home-page .home-hero h1,
  .page-banner h1,
  .membership-page h1 {
    font-size: clamp(2rem, 10vw, 3rem);
  }

  .page-banner,
  .page-banner--compact {
    padding: 1.15rem;
    border-radius: 1rem;
  }

  .page-banner--quiet {
    padding: 0 0 1rem;
    border-radius: 0;
  }

  .auth-main,
  .payment-main {
    padding-top: 1.5rem;
    padding-bottom: 2rem;
  }

  /* Homepage mobile rhythm: flatten repeated card chrome while preserving content. */
  .home-page .home-hero-trust {
    padding-top: 1rem;
    padding-bottom: 2.35rem;
    background: linear-gradient(180deg, #f7f6ef 0%, #f1f2e9 100%);
    border-top: 1px solid rgba(23, 53, 31, 0.1);
    font-size: 0.92rem;
    line-height: 1.5;
  }

  .home-page .home-hero-start {
    padding: 1.15rem;
    border-radius: 1rem;
    box-shadow: 0 10px 26px rgba(23, 53, 31, 0.08);
  }

  .home-page .home-hero-start .choice-list {
    gap: 0;
    margin-top: 1rem;
    border-top: 1px solid rgba(23, 53, 31, 0.16);
  }

  .home-page .home-hero-start .choice-card {
    min-height: 44px;
    padding: 1rem 0.2rem;
    background: transparent;
    border: 0;
    border-bottom: 1px solid rgba(23, 53, 31, 0.16);
    border-radius: 0;
  }

  .home-page .home-hero-start .choice-card:last-child {
    border-bottom: 0;
  }

  .home-page .home-hero-start .choice-card:hover,
  .home-page .home-hero-start .choice-card:focus-visible {
    background: #f7fbf3;
  }

  .home-page .home-hero-start .choice-title {
    margin-bottom: 0.25rem;
  }

  .home-page .home-process-section {
    padding-top: 3rem;
    padding-bottom: 3.75rem;
  }

  .home-process-section .card-grid {
    position: relative;
    gap: 0;
    margin-top: 1.75rem;
  }

  .home-process-section .card-grid::before {
    position: absolute;
    top: 1.25rem;
    bottom: 1.25rem;
    left: 1.2rem;
    width: 2px;
    content: "";
    background: rgba(154, 106, 31, 0.34);
  }

  .home-process-section .card {
    position: relative;
    z-index: 1;
    padding: 0 0 1.75rem 3.5rem;
    background: transparent;
    border: 0;
    border-radius: 0;
  }

  .home-process-section .card:last-child {
    padding-bottom: 0;
  }

  .home-process-section .card h3 {
    min-height: 2.5rem;
    margin-bottom: 0.45rem;
    padding-top: 0.3rem;
  }

  .home-process-section .card p {
    margin-bottom: 0;
  }

  .home-step-number {
    position: absolute;
    top: 0;
    left: 0;
    display: inline-flex;
    width: 2.5rem;
    height: 2.5rem;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: #9a6a1f;
    border-radius: 50%;
    font-size: 0.95rem;
    font-weight: 800;
  }

  .home-page .why-section {
    padding-top: 3.75rem;
    padding-bottom: 3.75rem;
  }

  .home-page .home-guidance-section {
    padding-top: 3.5rem;
    padding-bottom: 3.75rem;
  }

  .home-page .home-guidance-section .home-guide-grid {
    gap: 0;
    margin-top: 1.5rem;
    background: rgba(255, 255, 255, 0.72);
    border-top: 1px solid rgba(23, 53, 31, 0.16);
    border-bottom: 1px solid rgba(23, 53, 31, 0.16);
  }

  .home-page .home-guidance-section .home-guide-grid > a {
    min-height: 44px;
    padding: 0.9rem 0.25rem;
    background: transparent;
    border: 0;
    border-bottom: 1px solid rgba(23, 53, 31, 0.14);
    border-radius: 0;
    box-shadow: none;
  }

  .home-page .home-guidance-section .home-guide-grid > a:last-child {
    border-bottom: 0;
  }

  .home-page .home-guidance-section .home-guide-grid > a:hover,
  .home-page .home-guidance-section .home-guide-grid > a:focus-visible {
    color: #17351f;
    background: #f7fbf3;
  }

  .home-page .home-guidance-section .home-guide-grid span {
    margin-bottom: 0.15rem;
    font-size: 1rem;
  }

  .home-page .home-guidance-section .home-guide-grid small {
    font-size: 0.9rem;
    line-height: 1.4;
  }
}

@media (forced-colors: active) {
  .membership-page input:focus,
  .membership-page select:focus,
  .membership-page input[type="tel"]:focus,
  .membership-page textarea:focus {
    outline: 2px solid Highlight;
    outline-offset: 2px;
  }
}

/* Member portal foundation: shared only by Professional and Business profiles. */
.profile-page {
  --profile-gap-sm: 0.65rem;
  --profile-gap-md: 1rem;
  --profile-gap-lg: 1.5rem;
}

body.profile-page {
  padding: 0;
}

.profile-page .membership-shell {
  width: min(1000px, calc(100% - 2rem));
  margin: clamp(1rem, 3vw, 2.5rem) auto;
}

.profile-page .member-site-header .nav-container {
  flex-wrap: wrap;
}

.profile-page .member-site-nav {
  justify-content: flex-end;
  margin-left: auto;
}

.profile-page .profile-management-card {
  margin-top: var(--profile-gap-lg);
  padding: clamp(1rem, 2.5vw, 1.5rem);
  border: 1px solid #d9dfcf;
  border-radius: 1rem;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(23, 53, 31, 0.07);
}

.profile-page .profile-card-header {
  display: flex;
  gap: var(--profile-gap-md);
  align-items: start;
  justify-content: space-between;
  margin-bottom: var(--profile-gap-md);
}

.profile-page .profile-card-header h2,
.profile-page .profile-subsection-heading h3 {
  margin: 0;
}

.profile-page .profile-card-kicker {
  margin: 0 0 0.2rem;
  color: #526050;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.profile-page .profile-listing-card {
  border-left: 5px solid #1f6f43;
  background: #f7fbf5;
}

.profile-page .profile-status-row {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: var(--profile-gap-md) var(--profile-gap-lg);
  align-items: center;
}

.profile-page .profile-status-summary {
  display: flex;
  gap: var(--profile-gap-sm);
  align-items: center;
  flex-wrap: wrap;
}

.profile-page .profile-status-name {
  color: #17351f;
  font-weight: 750;
  text-transform: capitalize;
}

.profile-page .profile-visibility,
.profile-page .profile-privacy-marker {
  display: inline-flex;
  min-height: 1.75rem;
  align-items: center;
  padding: 0.2rem 0.55rem;
  color: #ffffff;
  background: #526050;
  border-radius: 0.35rem;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.2;
  text-transform: uppercase;
}

.profile-page .profile-visibility[data-visibility="public"],
.profile-page .profile-privacy-marker--public {
  background: #236b44;
}

.profile-page .profile-status-explanation {
  margin: 0;
  color: #344a38;
}

.profile-page .profile-account-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid #d9dfcf;
}

.profile-page .profile-subsection {
  min-width: 0;
  padding-top: var(--profile-gap-lg);
}

.profile-page .profile-account-grid > .profile-subsection + .profile-subsection {
  margin-left: var(--profile-gap-lg);
  padding-left: var(--profile-gap-lg);
  border-left: 1px solid #d9dfcf;
}

.profile-page .profile-subsection-heading {
  display: flex;
  gap: var(--profile-gap-sm);
  align-items: center;
  justify-content: space-between;
}

.profile-page .profile-definition-row {
  display: grid;
  gap: 0.2rem;
  margin: var(--profile-gap-md) 0;
  padding: 0.75rem;
  background: #eef2e7;
  border-radius: 0.65rem;
}

.profile-page .profile-definition-row span {
  color: #526050;
  font-size: 0.82rem;
  font-weight: 700;
}

.profile-page .profile-definition-row strong {
  overflow-wrap: anywhere;
}

.profile-page .profile-account-card .member-form {
  margin-top: var(--profile-gap-md);
}

.profile-page .profile-affiliation {
  margin-top: var(--profile-gap-lg);
  padding-top: var(--profile-gap-lg);
  border-top: 1px solid #d9dfcf;
}

.profile-page .profile-affiliation .payment-info {
  margin-top: var(--profile-gap-sm);
}

.profile-page .form-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}

.profile-page .form-actions .button,
.profile-page .form-actions button {
  width: auto;
}

.profile-page .profile-compact-card > h2 {
  margin: 0;
}

.profile-page .profile-card-intro {
  margin: 0.35rem 0 1rem;
  color: #344a38;
}

.profile-page .profile-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
  margin: 0.85rem 0;
}

.profile-page .profile-metric {
  min-width: 0;
  margin: 0;
  padding: 0.7rem 0.75rem;
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 0.7rem;
}

.profile-page .profile-metric span,
.profile-page .profile-metric strong {
  display: block;
}

.profile-page .profile-metric span {
  color: #526050;
  font-size: 0.76rem;
  font-weight: 750;
  line-height: 1.25;
}

.profile-page .profile-metric strong {
  margin-top: 0.15rem;
  color: #17351f;
  font-size: 1.2rem;
  overflow-wrap: anywhere;
}

.profile-page .seat-paid-through {
  margin: 0.65rem 0 0;
  color: #526050;
  font-size: 0.88rem;
}

.profile-page .profile-roster-section {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #d9dfcf;
}

.profile-page .profile-roster-section h3 {
  margin: 0 0 0.55rem;
  font-size: 1rem;
}

.profile-page .profile-roster,
.profile-page .profile-renewal-roster {
  display: grid;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.profile-page .profile-roster-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.7rem 0.75rem;
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 0.7rem;
}

.profile-page .profile-roster-details {
  display: grid;
  min-width: 0;
  gap: 0.12rem;
}

.profile-page .profile-roster-details strong {
  overflow-wrap: anywhere;
}

.profile-page .profile-roster-role,
.profile-page .profile-roster-details .help-text {
  color: #526050;
  font-size: 0.82rem;
}

.profile-page .profile-roster-details .help-text {
  margin: 0.15rem 0 0;
}

.profile-page .profile-roster-actions {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.profile-page .profile-roster-actions .button {
  min-height: 44px;
  margin: 0;
  padding: 0.55rem 0.75rem;
}

.profile-page .profile-empty {
  margin: 0.35rem 0 0;
  color: #526050;
  font-size: 0.9rem;
}

.profile-page #seatInvitationUnavailable {
  margin-top: 1rem;
  padding: 0.8rem;
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 0.7rem;
}

.profile-page #seatInvitationForm,
.profile-page .referral-editor .member-form {
  margin-top: 0.85rem;
}

.profile-page .profile-renewal-row {
  padding: 0.6rem 0.7rem;
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 0.65rem;
}

.profile-page .profile-renewal-row label {
  display: flex;
  min-height: 44px;
  gap: 0.5rem;
  align-items: center;
  margin: 0;
}

.profile-page #referralProgramCard .referral-primary-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.85rem;
}

.profile-page #referralProgramCard .referral-code {
  display: flex;
  gap: 0.45rem;
  align-items: baseline;
  margin: 0;
}

.profile-page #referralProgramCard .referral-code strong {
  color: #17351f;
  font-size: 1.1rem;
  overflow-wrap: anywhere;
}

.profile-page #referralProgramCard .referral-primary-row .button {
  min-height: 44px;
  flex: 0 0 auto;
  margin: 0;
}

.profile-page #referralProgramCard .referral-link-block {
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: #ffffff;
  border: 1px solid #d9dfcf;
  border-radius: 0.7rem;
}

.profile-page #referralProgramCard .referral-link-block > span {
  display: block;
  color: #526050;
  font-size: 0.78rem;
  font-weight: 750;
}

.profile-page #referralProgramCard .referral-link-block > a,
.profile-page #referralProgramCard .referral-custom-summary a {
  overflow-wrap: anywhere;
}

.profile-page #referralProgramCard .referral-link-block .help-text,
.profile-page #referralProgramCard .referral-custom-summary + .help-text {
  margin: 0.25rem 0 0;
}

.profile-page #referralProgramCard .referral-metrics {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.profile-page #referralProgramCard .referral-custom-summary {
  margin: 0.85rem 0 0;
}

.profile-page #referralProgramCard .referral-editor {
  margin-top: 0.75rem;
  border-top: 1px solid #d9dfcf;
}

.profile-page #referralProgramCard .referral-editor summary {
  display: list-item;
  min-height: 44px;
  padding: 0.65rem 0;
  color: #1f6f43;
  cursor: pointer;
  font-weight: 750;
}

.profile-page #referralProgramCard .referral-editor[open] {
  padding-bottom: 0.25rem;
}

@media (max-width: 760px) {
  .profile-page .membership-shell {
    width: 100%;
    margin: 0;
  }

  .profile-page .profile-account-grid,
  .profile-page .profile-status-row {
    grid-template-columns: 1fr;
  }

  .profile-page .profile-metrics,
  .profile-page #referralProgramCard .referral-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-page .profile-roster-row {
    grid-template-columns: 1fr;
  }

  .profile-page .profile-roster-actions {
    justify-content: flex-start;
  }

  .profile-page .profile-account-grid > .profile-subsection + .profile-subsection {
    margin: var(--profile-gap-lg) 0 0;
    padding: var(--profile-gap-lg) 0 0;
    border-top: 1px solid #d9dfcf;
    border-left: 0;
  }

  .profile-page .form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-page .form-actions .button,
  .profile-page .form-actions button {
    width: 100%;
  }
}

@media (max-width: 420px) {
  .profile-page #referralProgramCard .referral-primary-row {
    align-items: stretch;
    flex-direction: column;
  }

  .profile-page #referralProgramCard .referral-primary-row .button,
  .profile-page .profile-roster-actions .button {
    width: 100%;
  }
}

@media (max-width: 820px) {
  .profile-page .member-site-header .nav-container {
    display: flex;
    min-height: 3.75rem;
  }

  .profile-page .member-site-nav {
    display: flex;
    width: auto;
    gap: 0.35rem;
    padding: 0;
  }

  .profile-page .member-site-nav > a,
  .profile-page .member-site-nav .auth-status-badge--inline,
  .profile-page .member-site-nav .auth-status-sign-out--inline {
    width: auto;
    flex: 0 1 auto;
    padding: 0.5rem 0.6rem;
  }
}

/* Keep the native hidden contract stronger than profile display utilities. */
.profile-page [hidden] {
  display: none;
}
