/* YEEZER type & rhythm lock
   Baseline: footer-club h3 + p (Apple-like calm scale)
   Load LAST after site.css / stitch-pages.css / stitch-weight.css */

:root {
  /* Size scale — body/lead = footer-club p */
  --text-xs: 0.75rem; /* 12px eyebrows */
  --text-caption: 0.8125rem; /* 13px meta */
  --text-sm: 0.9375rem; /* 15px body / lead — baseline */
  --text-base: 0.9375rem; /* alias to baseline */
  --text-md: 1.0625rem; /* 17px rare emphasis */
  --text-card: 1.125rem; /* 18px card titles */
  --text-title: clamp(1.35rem, 2.4vw, 1.75rem); /* footer-club h3 */
  --text-display: clamp(1.5rem, 2.6vw, 2rem); /* page/hero h1 only */

  --fw-body: 500;
  --fw-ui: 600;
  --fw-display: 700;

  --lh-body: 1.55;
  --lh-tight: 1.2;
  --tracking-title: -0.03em;
  --tracking-display: -0.03em;
  --tracking-eyebrow: 0.14em;

  /* Spacing rhythm (8px grid) */
  --space-1: 8px;
  --space-2: 12px;
  --space-3: 16px;
  --space-4: 20px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 40px;
  --space-8: 48px;
  --title-gap: 10px; /* club h3 → p */
  --lead-gap: 20px; /* club p → action */
  --section-gap: clamp(64px, 8vw, 96px);
  --section-head-gap: 40px;
  --gutter: 24px;
  --page-gutter: 24px;
}

/* —— Global —— */
body {
  font-size: var(--text-sm);
  font-weight: var(--fw-body);
  line-height: var(--lh-body);
}

h1,
h2,
h3,
h4 {
  font-weight: var(--fw-display);
  letter-spacing: var(--tracking-title);
  line-height: var(--lh-tight);
}

h1 {
  font-size: var(--text-display);
  letter-spacing: var(--tracking-display);
}

h2 {
  font-size: var(--text-title);
}

h3 {
  font-size: var(--text-card);
}

p {
  font-size: var(--text-sm);
  line-height: var(--lh-body);
}

/* —— Section rhythm —— */
.section,
.footer-promise,
.stitch-catalog-section,
.stitch-procure-band,
.stitch-oem-tier,
.stitch-qc-flow-section,
.stitch-network-section,
.stitch-freight-section,
.stitch-freight-creds,
.stitch-map-section,
.stitch-about-work,
.stitch-page-head,
.stitch-policy-section,
.stitch-cta-dark,
.stitch-product-related,
.stitch-res-section,
.stitch-contact-map-section,
.stitch-qc-report,
.oem,
.logistics,
.products,
.process,
.paths,
.about-split,
.home-why,
.global-reach,
.qc,
.consult,
.cta-band,
.faq {
  padding-block: var(--section-gap);
}

:is(
  .section-head,
  .paths-head,
  .process-head,
  .products-head,
  .home-why-head,
  .global-reach-head,
  .logistics-head,
  .oem-intro,
  .stitch-catalog-head,
  .stitch-procure-head,
  .stitch-qc-flow-head,
  .stitch-freight-creds-head,
  .stitch-about-work-head,
  .stitch-map-copy,
  .stitch-res-section-head,
  .stitch-product-related-head
) {
  margin-bottom: var(--section-head-gap);
}

:is(
  .section-head h2,
  .paths-head h2,
  .process-head h2,
  .products-head h2,
  .home-why-head h2,
  .global-reach-head h2,
  .logistics-head h2,
  .oem-intro h2,
  .consult-grid h2,
  .cta-band h2,
  .footer-club h3,
  .footer-promise-title,
  .stitch-catalog-title,
  .stitch-procure-head h2,
  .stitch-qc-flow-head h2,
  .stitch-freight-creds-head h2,
  .stitch-about-work-head h2,
  .stitch-map-copy h2,
  .stitch-network-copy h2,
  .stitch-freight-copy h2,
  .stitch-qc-report-copy h2,
  .stitch-oem-capabilities-head h2,
  .stitch-oem-tier-head h2,
  .stitch-res-section-head h2,
  .stitch-product-section-title,
  .stitch-product-related-copy h2,
  .stitch-cta-dark h2,
  .stitch-policy-card h2,
  .stitch-checkout-title
) {
  font-size: var(--text-title) !important;
  font-weight: var(--fw-display) !important;
  letter-spacing: var(--tracking-title) !important;
  line-height: var(--lh-tight) !important;
  margin: 0 0 var(--title-gap) !important;
  max-width: 28ch;
}

:is(
  .section-head p,
  .paths-head p,
  .process-head p,
  .products-head p,
  .home-why-lead,
  .global-reach-lead,
  .logistics-head p,
  .oem-intro p,
  .consult-grid p,
  .cta-band-content > p,
  .footer-club > p,
  .about-split-head p,
  .stitch-catalog-meta-line,
  .stitch-procure-head p,
  .stitch-qc-flow-head p,
  .stitch-freight-creds-head p,
  .stitch-about-work-head p,
  .stitch-map-copy > p,
  .stitch-network-copy > p,
  .stitch-freight-copy > p,
  .stitch-qc-report-copy > p,
  .stitch-oem-capabilities-head p,
  .stitch-oem-tier-head p,
  .stitch-cta-dark p,
  .stitch-product-tagline
) {
  font-size: var(--text-sm) !important;
  font-weight: var(--fw-body) !important;
  line-height: var(--lh-body) !important;
  letter-spacing: 0 !important;
  max-width: 40rem;
  margin: 0 0 var(--lead-gap) !important;
  color: var(--muted);
}

/* Legal / policy pages — readable body ink, not card muted */
.stitch-policy-card p,
.stitch-policy-card li {
  font-size: 16px !important;
  font-weight: 400 !important;
  line-height: 1.7 !important;
  max-width: none;
  color: var(--ink, #0c1117) !important;
}
.stitch-policy-card p {
  margin: 0 0 12px !important;
}
.stitch-policy-card p:last-child {
  margin-bottom: 0 !important;
}

/* Hero leads: size/rhythm only — color stays with hero theme */
:is(
  .hero-lead,
  .stitch-products-hero-lead,
  .stitch-about-hero-lead,
  .stitch-oem-hero-lead,
  .stitch-qc-hero-lead,
  .stitch-ddp-hero-lead,
  .stitch-contact-hero-lead,
  .stitch-res-hero-lead
) {
  font-size: var(--text-sm) !important;
  font-weight: var(--fw-body) !important;
  line-height: var(--lh-body) !important;
  letter-spacing: 0 !important;
  max-width: 40rem;
  margin: 0 0 var(--lead-gap) !important;
}

/* Eyebrows / kickers */
:is(
  .eyebrow,
  .section-eyebrow,
  .paths-eyebrow,
  .products-eyebrow,
  .home-why-eyebrow,
  .hero-kicker,
  .stitch-ddp-eyebrow,
  .stitch-map-eyebrow,
  .stitch-products-hero-kicker,
  .stitch-about-hero-kicker,
  .stitch-oem-hero-kicker,
  .stitch-qc-hero-kicker,
  .stitch-contact-hero-kicker,
  .stitch-res-hero-kicker,
  .stitch-res-kicker,
  .stitch-section-eyebrow,
  .cta-band .eyebrow
) {
  display: block;
  font-size: var(--text-xs) !important;
  font-weight: var(--fw-display) !important;
  letter-spacing: var(--tracking-eyebrow) !important;
  text-transform: uppercase;
  line-height: 1.35;
  margin: 0 0 var(--space-2) !important;
}

/* Hero / page display titles — one step above section title */
:is(
  .hero-inner h1,
  .stitch-products-hero h1,
  .stitch-about-hero h1,
  .stitch-oem-hero h1,
  .stitch-qc-hero h1,
  .stitch-ddp-hero h1,
  .stitch-contact-hero h1,
  .stitch-contact-head h1,
  .stitch-res-hero h1,
  .stitch-page-head h1,
  .stitch-article-hero h1,
  .page-hero h1,
  .about-page-hero h1
) {
  font-size: var(--text-display) !important;
  font-weight: var(--fw-display) !important;
  letter-spacing: var(--tracking-display) !important;
  line-height: 1.15 !important;
  margin: 0 0 var(--title-gap) !important;
  max-width: 16ch;
}

/* Homepage carousel — center constrained title/lead boxes */
.hero-inner h1,
.hero-inner .hero-lead {
  margin-left: auto !important;
  margin-right: auto !important;
}

/* Dark CTA band — keep title/lead centered in the inset card */
.stitch-cta-dark h2,
.stitch-cta-dark p {
  margin-left: auto !important;
  margin-right: auto !important;
  text-align: center;
}

/* Card / step titles */
:is(
  .path-card-body h3,
  .process-body h3,
  .home-why-card-title,
  .global-markets h3,
  .logistics-grid h3,
  .oem-cards h4,
  .qc-grid h4,
  .footer-promise-card h3,
  .stitch-qc-flow-step h3,
  .stitch-about-work-step h3,
  .stitch-tier-card h3,
  .stitch-freight-cred-card h3,
  .stitch-network-block h3,
  .stitch-why-list h4,
  .stitch-catalog-title-row h2,
  .stitch-catalog-card h2,
  .product-body h3
) {
  font-size: var(--text-card) !important;
  font-weight: var(--fw-display) !important;
  letter-spacing: -0.025em !important;
  line-height: 1.25 !important;
  margin: 0 0 var(--space-2) !important;
}

:is(
  .process-body p,
  .home-why-card-desc,
  .global-markets p,
  .oem-cards p,
  .qc-grid p,
  .footer-promise-card p,
  .stitch-qc-flow-step p,
  .stitch-about-work-step p,
  .stitch-tier-card p,
  .stitch-freight-cred-card > p,
  .stitch-network-block > p,
  .stitch-catalog-tagline,
  .stitch-catalog-meta,
  .faq-item p,
  .cta-band-note
) {
  font-size: var(--text-sm) !important;
  line-height: var(--lh-body) !important;
  font-weight: var(--fw-body) !important;
  color: var(--muted);
}

/* Path cards sit on photo + dark overlay — keep light copy */
.path-card-body p {
  font-size: var(--text-sm) !important;
  line-height: var(--lh-body) !important;
  font-weight: var(--fw-body) !important;
  color: rgb(255 255 255 / 86%) !important;
  opacity: 1;
}

/* Footer club = source of truth (explicit) */
.footer-club h3 {
  font-size: var(--text-title) !important;
  font-weight: var(--fw-display) !important;
  letter-spacing: var(--tracking-title) !important;
  margin: 0 0 var(--title-gap) !important;
}
.footer-club > p {
  font-size: var(--text-sm) !important;
  line-height: var(--lh-body) !important;
  margin: 0 0 var(--lead-gap) !important;
}

/* Dark surfaces keep readable muted */
.stitch-cta-dark p {
  color: rgb(255 255 255 / 78%) !important;
}
.process-head p {
  color: var(--muted) !important;
}
.cta-band-content > p,
.cta-band-note {
  color: inherit;
}

/* Compact action rows */
:is(
  .hero-actions,
  .paths-head .btn,
  .products-head .btn,
  .stitch-products-hero-actions,
  .stitch-about-hero-actions,
  .stitch-oem-hero-actions,
  .stitch-qc-hero-actions,
  .stitch-ddp-hero-actions,
  .cta-band-actions,
  .home-why-cta
) {
  gap: var(--space-2);
}

.cta-band-actions {
  margin-bottom: var(--space-2);
}
.cta-band-note {
  margin-bottom: var(--space-5) !important;
}

/* Kill oversized display leftovers */
.stitch-weight :is(
  .stitch-about-hero h1,
  .stitch-qc-hero h1,
  .stitch-oem-hero h1,
  .stitch-ddp-hero h1,
  .stitch-products-hero h1,
  .stitch-contact-hero h1,
  .stitch-contact-head h1,
  .stitch-product-hero h1,
  .stitch-article-hero h1
) {
  font-size: var(--text-display) !important;
  letter-spacing: var(--tracking-display) !important;
  line-height: 1.15 !important;
  max-width: 16ch;
}

.stitch-weight :is(
  .stitch-about-hero-kicker,
  .stitch-qc-hero-kicker,
  .stitch-oem-hero-kicker,
  .stitch-ddp-eyebrow,
  .stitch-products-hero-kicker,
  .stitch-res-hero-kicker,
  .stitch-contact-hero-kicker
) {
  font-size: var(--text-xs) !important;
  letter-spacing: var(--tracking-eyebrow) !important;
}

/* Centered section heads (home why / global) */
.home-why-head,
.global-reach-head {
  text-align: center !important;
}
:is(
  .home-why-head h2,
  .global-reach-head h2,
  .home-why-lead,
  .global-reach-lead
) {
  margin-left: auto !important;
  margin-right: auto !important;
  text-align: center !important;
}
.faq .section-eyebrow {
  display: block;
  text-align: left !important;
  max-width: 48rem;
  margin-left: auto !important;
  margin-right: auto !important;
}
.faq-title {
  font-size: var(--text-title) !important;
  font-weight: var(--fw-display) !important;
  letter-spacing: var(--tracking-title) !important;
  line-height: var(--lh-tight) !important;
  text-align: left !important;
  max-width: 48rem;
  margin-top: 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  margin-bottom: 32px !important;
}

/* Homepage CTA band: centered stack (overrides earlier margin:0 !important) */
.home-weight .cta-band-content {
  text-align: center !important;
}
.home-weight .cta-band h2,
.home-weight .cta-band-content > .eyebrow,
.home-weight .cta-band-content > p,
.home-weight .cta-band-note,
.home-weight .cta-band-actions,
.home-weight .cta-band .stats {
  margin-left: auto !important;
  margin-right: auto !important;
  text-align: center !important;
}
.home-weight .cta-band .stats {
  justify-content: center !important;
}
.home-weight .cta-band-actions {
  justify-content: center !important;
}
