/* DM Physio detail-page visual refresh.
   Loaded only by procedure and condition detail templates. All rules are
   constrained to their existing main/section classes; media state, DOM order,
   links, accordion behavior and content remain owned by the original pages. */

main.page-content:has(> .procedure-journey),
main.page-content:has(> .hero-section) {
  --dmc-ink: #173f43;
  --dmc-copy: #334b55;
  --dmc-muted: #60747a;
  --dmc-line: #dce6e7;
  --dmc-teal: #0e7c86;
  --dmc-green: #118548;
  --dmc-soft: #f3f8f7;
  color: var(--dmc-copy);
}

/* Procedure journeys: a calm opening and consistent, readable step cards. */
main.page-content > .procedure-journey.section-green {
  background: linear-gradient(180deg, #f0f7f5 0%, #f8fbfa 62%, #fff 100%);
  border: 1px solid #e0eae6;
  border-radius: 20px;
  box-shadow: none;
  color: var(--dmc-copy, #334b55);
  padding-block: clamp(30px, 4vw, 48px);
  transform: none;
}
main.page-content > .procedure-journey.section-green:hover {
  transform: none;
  box-shadow: none;
}
main.page-content > .procedure-journey > .container > :is(h2, .procedure-main-title) {
  color: var(--dmc-ink, #173f43);
  font-size: clamp(29px, 3.1vw, 42px);
  line-height: 1.18;
  letter-spacing: -.025em;
  margin-bottom: 14px;
  text-wrap: balance;
}
main.page-content > .procedure-journey > .container > :is(h3, .procedure-subtitle) {
  color: var(--dmc-teal, #0e7c86);
  font-size: clamp(18px, 2vw, 23px);
  line-height: 1.4;
  font-weight: 600;
}
main.page-content .procedure-journey :is(.procedure-preamble, .procedure-intro-copy) {
  color: #50646c;
  font-size: 17px;
  line-height: 1.8;
  max-width: 72ch;
  margin-bottom: 30px;
}
main.page-content .procedure-journey .journey-steps-wrapper {
  gap: clamp(22px, 2.5vw, 32px);
}
main.page-content .procedure-journey .journey-step {
  background: #fff;
  border: 1px solid var(--dmc-line, #dce6e7);
  border-radius: 18px;
  box-shadow: 0 6px 22px #163e4308;
  padding: clamp(18px, 2.2vw, 26px);
  gap: clamp(20px, 2.5vw, 30px);
}
main.page-content .procedure-journey .journey-content {
  min-width: 0;
  color: var(--dmc-copy, #334b55);
}
main.page-content .procedure-journey .journey-content :is(h3, h4) {
  color: var(--dmc-ink, #173f43);
  text-align: left;
  font-size: clamp(21px, 2vw, 26px);
  line-height: 1.3;
  letter-spacing: -.015em;
  margin-top: 4px;
  margin-bottom: 14px;
}
main.page-content .procedure-journey .journey-content :is(p, li) {
  color: var(--dmc-copy, #334b55);
  font-size: 16.5px;
  line-height: 1.8;
  overflow-wrap: break-word;
}
main.page-content .procedure-journey .journey-content p {
  margin-top: 0;
  margin-bottom: 16px;
}
main.page-content .procedure-journey .step-label {
  background: #e7f3ef;
  color: #226247;
  border: 1px solid #cee6d9;
  padding: 5px 11px;
  font-size: 12px;
  line-height: 1.5;
}
main.page-content .procedure-journey .step-duration {
  color: #22764d;
  font-size: 14px;
  line-height: 1.6;
}
main.page-content .procedure-journey .step-highlights {
  gap: 10px;
  margin-top: 18px;
}
main.page-content .procedure-journey .step-highlights li {
  line-height: 1.65;
}
main.page-content .procedure-journey .procedure-price {
  color: var(--dmc-ink, #173f43);
  letter-spacing: -.015em;
}
main.page-content .procedure-journey .procedure-price-panel {
  background: #f2f7f4;
  border: 1px solid #dce8df;
  border-radius: 16px;
  padding: 24px 20px;
}
main.page-content .procedure-journey :is(.book-button, .procedure-secondary-button) {
  min-height: 48px;
  padding: 14px 22px;
  border-radius: 10px;
  font-size: 16px;
  line-height: 1.4;
  text-decoration: none;
  box-shadow: 0 4px 12px #11854817;
}
main.page-content .procedure-journey .book-button {
  background: #118548;
  color: #fff;
  border: 1px solid #118548;
}
main.page-content .procedure-journey .book-button:hover {
  background: #0d6c39;
  border-color: #0d6c39;
}
main.page-content .procedure-journey .procedure-secondary-button {
  background: #fff;
  color: #0b6871;
  border: 1px solid #bbd8d8;
}
main.page-content .procedure-journey .procedure-safety-note {
  background: #fbf7ef;
  border-color: #e7dcc7;
  border-radius: 12px;
  color: #635136;
  line-height: 1.75;
}

/* Native details keep their existing open/closed state and hit areas. */
main.page-content:has(> .procedure-journey) .details-accordion {
  padding-block: 34px;
  background: #f5f8f7;
  border-radius: 16px;
  font-family: inherit;
}
main.page-content:has(> .procedure-journey) .details-accordion h2 {
  color: #173f43;
  font-size: clamp(25px, 2.5vw, 32px);
  line-height: 1.25;
  letter-spacing: -.02em;
  margin-bottom: 24px;
}
main.page-content:has(> .procedure-journey) .accordion-details > summary {
  background: #fff;
  color: #224c4e;
  border: 1px solid #d6e3e1;
  border-radius: 10px;
  font-size: 16px;
  line-height: 1.55;
  font-weight: 600;
  padding: 18px 20px;
  box-shadow: 0 2px 8px #173f4304;
}
main.page-content:has(> .procedure-journey) .accordion-details[open] > summary {
  background: #eaf4f1;
  border-color: #abcfc3;
  color: #174b38;
  border-radius: 10px 10px 0 0;
}
main.page-content:has(> .procedure-journey) .accordion-panel {
  background: #fff;
  border-color: #d6e3e1;
  border-radius: 0 0 10px 10px;
  padding: 16px 20px;
}
main.page-content:has(> .procedure-journey) .accordion-panel :is(p, li) {
  color: #334b55;
  font-size: 16px;
  line-height: 1.8;
}
main.page-content:has(> .procedure-journey) .sidebar-conditions {
  border-color: #dce6e7;
  border-radius: 16px;
  box-shadow: 0 4px 20px #173f4307;
}
main.page-content:has(> .procedure-journey) .sidebar-conditions > h3 {
  color: #244c4f;
  border-color: #e2ece8;
  font-size: 18px;
  line-height: 1.4;
  padding-bottom: 12px;
}

/* Symptom/condition explanations: quieter sections, comfortable reading scale. */
main.page-content:has(> .hero-section) > .hero-section {
  background: linear-gradient(125deg, #edf6f4 0%, #f7faf9 60%, #eef5f5 100%);
  color: #173f43;
  border-bottom: 1px solid #dce8e5;
  padding-block: clamp(32px, 4vw, 58px);
}
main.page-content:has(> .hero-section) .hero-text-content :is(h1, h2) {
  color: #173f43;
  font-size: clamp(32px, 3.9vw, 52px);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: -.03em;
  text-shadow: none;
  margin-top: 0;
  margin-bottom: 20px;
  text-wrap: balance;
}
main.page-content:has(> .hero-section) .hero-text-content p {
  color: #50646c;
  font-size: clamp(17px, 1.55vw, 20px);
  line-height: 1.75;
  max-width: 65ch;
  margin-bottom: 26px;
}
main.page-content:has(> .hero-section) :is(.intro-section, .deg-causes, .inflammation-section, .healing-section, .recovery-section, .procedures-section) {
  padding-block: clamp(34px, 4.5vw, 60px);
}
main.page-content:has(> .hero-section) .intro-section {
  background: #fff;
}
main.page-content:has(> .hero-section) :is(.deg-causes, .inflammation-section) {
  background: #f2f7f7;
  border-block: 1px solid #e1ebea;
}
main.page-content:has(> .hero-section) :is(.healing-section.alternative-style, .recovery-section.alternative-style) {
  background: #f4f8f4;
}
main.page-content:has(> .hero-section) :is(.intro-text-content h2, .section-title, .deg-causes__title) {
  color: #173f43;
  font-size: clamp(27px, 3vw, 37px);
  font-weight: 700;
  line-height: 1.23;
  letter-spacing: -.025em;
  text-shadow: none;
  margin-top: 0;
  margin-bottom: 18px;
  text-wrap: balance;
}
main.page-content:has(> .hero-section) :is(.section-subtitle, .deg-causes__subtitle) {
  color: #60747a;
  font-size: 17px;
  line-height: 1.75;
  max-width: 72ch;
  margin-inline: auto;
  margin-bottom: 32px;
}
main.page-content:has(> .hero-section) .intro-text-content p {
  color: #334b55;
  font-size: 17px;
  line-height: 1.85;
  margin-bottom: 22px;
}
main.page-content:has(> .hero-section) .info-box {
  background: #faf7f2;
  border-left-color: #ba795b;
  border-radius: 12px;
  box-shadow: none;
  color: #594f48;
  padding: 20px;
  line-height: 1.75;
}
main.page-content:has(> .hero-section) .info-box p {
  font-size: 16px;
  line-height: 1.8;
}
main.page-content:has(> .hero-section) :is(.disc-card, .step-card, .healing-step, .recovery-step) {
  background: #fff;
  border: 1px solid #dce6e7;
  border-radius: 18px;
  box-shadow: 0 5px 20px #173f4308;
}
main.page-content:has(> .hero-section) .disc-card {
  padding: clamp(20px, 2.3vw, 28px);
}
main.page-content:has(> .hero-section) :is(.disc-card__title, .step-card h3, .healing-step h3, .recovery-step h3) {
  color: #17474b;
  font-size: clamp(21px, 2.1vw, 27px);
  line-height: 1.3;
  font-weight: 600;
  letter-spacing: -.015em;
}
main.page-content:has(> .hero-section) :is(.disc-card__text, .step-card p, .healing-step p, .recovery-step p) {
  color: #3b525b;
  font-size: 16px;
  line-height: 1.8;
}
main.page-content:has(> .hero-section) :is(.disc-badge, .step-number) {
  background: #0e7c86;
  color: #fff;
  box-shadow: 0 3px 10px #0e7c8617;
}
main.page-content:has(> .hero-section) .hero-buttons :is(.primary-button, .outline-button),
main.page-content:has(> .hero-section) .procedures-cta {
  min-height: 48px;
  padding: 13px 22px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.45;
  text-decoration: none;
  text-shadow: none;
  box-shadow: none;
}
main.page-content:has(> .hero-section) .hero-buttons .primary-button {
  background: #118548;
  border-color: #118548;
  color: #fff;
  box-shadow: 0 4px 12px #11854817;
}
main.page-content:has(> .hero-section) .hero-buttons .primary-button:hover {
  background: #0d6c39;
  border-color: #0d6c39;
}
main.page-content:has(> .hero-section) .hero-buttons .outline-button {
  background: #fff;
  border-color: #b7d3d2;
  color: #0b6871;
}
main.page-content:has(> .hero-section) .procedures-cta {
  background: #fff;
  border-color: #bad3ce;
  color: #17684c;
}

/* Tables and focus remain within the audited detail-page families. */
main.page-content:has(> :is(.procedure-journey, .hero-section)) table {
  max-width: 100%;
  border-collapse: collapse;
  background: #fff;
  color: #334b55;
  font-size: 16px;
  line-height: 1.7;
}
main.page-content:has(> :is(.procedure-journey, .hero-section)) :is(th, td) {
  border-color: #dce6e7;
  padding: 13px 16px;
  text-align: left;
  overflow-wrap: break-word;
}
main.page-content:has(> :is(.procedure-journey, .hero-section)) th {
  background: #edf5f3;
  color: #244c4f;
}
main.page-content:has(> :is(.procedure-journey, .hero-section)) :is(a, button, summary):focus-visible {
  outline: 3px solid #0e7c86;
  outline-offset: 4px;
}

@media (max-width: 768px) {
  main.page-content > .procedure-journey.section-green {
    padding-block: 28px;
    border-radius: 14px;
  }
  main.page-content .procedure-journey .journey-step {
    padding: 16px;
    gap: 20px;
    border-radius: 14px;
  }
  main.page-content .procedure-journey :is(.procedure-preamble, .procedure-intro-copy) {
    font-size: 16px;
    padding-inline: 0;
    line-height: 1.8;
  }
  main.page-content .procedure-journey .journey-content :is(p, li) {
    font-size: 16px;
  }
  main.page-content:has(> .procedure-journey) .accordion-details > summary {
    padding: 16px;
  }
  main.page-content:has(> .procedure-journey) .accordion-panel {
    padding: 14px 16px;
  }
  main.page-content:has(> .hero-section) .hero-text-content :is(h1, h2) {
    font-size: clamp(29px, 7.8vw, 38px);
    line-height: 1.18;
    letter-spacing: -.025em;
  }
  main.page-content:has(> .hero-section) .hero-text-content p {
    font-size: 17px;
    line-height: 1.75;
  }
  main.page-content:has(> .hero-section) .intro-text-content p {
    font-size: 16px;
    line-height: 1.8;
  }
  main.page-content:has(> .hero-section) .info-box {
    padding: 16px;
  }
  main.page-content:has(> .hero-section) :is(.intro-text-content h2, .section-title, .deg-causes__title) {
    font-size: clamp(25px, 6.7vw, 31px);
  }
}
