
/* =========================================================
   FINAL TEXT CONTRAST LAYER
   Purpose: guarantee readable text across light-green theme.
   Loaded last so it wins over legacy theme rules.
   ========================================================= */

:root{
  --txt-main:#173f35;
  --txt-strong:#0d3029;
  --txt-body:#24483f;
  --txt-muted:#49675f;
  --txt-on-dark:#ffffff;
  --accent-gold:#8a6519;
  --link:#174e40;
}

/* Default readable foreground for site content */
html, body, main, section, article, .section, .content, .container,
.card, .result-card, .visage-item, .corps-item, .treatment-card,
.results-card, .review-card, .contact-card, .blog-card{
  color:var(--txt-body)!important;
}

/* Titles */
main h1, main h2, main h3, main h4, main h5, main h6,
section h1, section h2, section h3, section h4, section h5, section h6,
.card h1, .card h2, .card h3, .card h4,
.visage-item h3, .corps-item h3, .result-card h3{
  color:var(--txt-strong)!important;
  opacity:1!important;
  text-shadow:none!important;
}

/* Paragraphs, descriptions, captions and small text */
main p, section p, article p, .card p,
.description, .desc, .subtitle, .intro, .caption, figcaption,
small, .small, .meta, .details, .treatment-description,
.result-description, .review-text, .contact-text{
  color:var(--txt-body)!important;
  opacity:1!important;
}

/* Labels / eyebrows */
.eyebrow, .kicker, .section-label, .overline, .badge-label,
[class*="eyebrow"], [class*="kicker"]{
  color:var(--accent-gold)!important;
  opacity:1!important;
  font-weight:700!important;
}

/* Links in content */
main a:not(.btn):not(.button):not([class*="whatsapp"]):not([class*="instagram"]),
section a:not(.btn):not(.button):not([class*="whatsapp"]):not([class*="instagram"]){
  color:var(--link)!important;
  font-weight:700!important;
  text-decoration-color:rgba(23,78,64,.45)!important;
}

/* Breadcrumbs */
.breadcrumb, .breadcrumbs, [class*="breadcrumb"]{
  color:var(--txt-strong)!important;
}
.breadcrumb a, .breadcrumbs a, [class*="breadcrumb"] a{
  color:var(--accent-gold)!important;
}

/* Form labels and controls */
label, legend{
  color:var(--txt-strong)!important;
  opacity:1!important;
}
input, textarea, select{
  color:var(--txt-strong)!important;
}
input::placeholder, textarea::placeholder{
  color:#607c74!important;
  opacity:1!important;
}

/* Dark header/footer: force white readable text */
header, .site-header, .rm-header, .main-header,
footer, .site-footer, .footer{
  color:var(--txt-on-dark)!important;
}
header a, .site-header a, .rm-header a, .main-header a,
footer a, .site-footer a, .footer a,
header p, footer p{
  color:var(--txt-on-dark)!important;
  opacity:1!important;
}

/* Keep brand/gold accents readable */
header .active, header [aria-current="page"],
.site-header .active, .rm-header .active{
  color:#f0c768!important;
}

/* Buttons: explicit high-contrast pairs */
.btn, .button, button, [role="button"]{
  opacity:1!important;
}
.btn-primary, .button-primary, .whatsapp-btn,
[class*="whatsapp"]:not(.floating-whatsapp){
  color:#173f35!important;
}
.btn-secondary, .button-secondary{
  color:var(--txt-strong)!important;
}

/* Tabs: readable active/inactive states */
.tab-btn, .tab-button, [role="tab"]{
  color:var(--txt-strong)!important;
}
.tab-btn.active, .tab-button.active, [role="tab"][aria-selected="true"]{
  color:#ffffff!important;
}

/* Explicitly readable text inside light green hero/page banners */
.hero:not(.dark) h1, .page-hero h1, .section-hero h1,
.hero:not(.dark) p, .page-hero p, .section-hero p{
  color:var(--txt-strong)!important;
  opacity:1!important;
}

/* Reviews / ratings */
.rating, .review-score, .review-title, .reviews-title{
  color:var(--txt-strong)!important;
}

/* Accordion */
details summary, .accordion-title, .accordion button{
  color:var(--txt-strong)!important;
  opacity:1!important;
}

/* Prevent legacy low-opacity text */
main [style*="opacity:"], section [style*="opacity:"]{
  --final-text-opacity:1;
}

/* Accessibility */
@media (prefers-contrast: more){
  :root{
    --txt-main:#0a2b24;
    --txt-strong:#06251f;
    --txt-body:#163a31;
    --txt-muted:#294c43;
    --link:#0b4a3a;
  }
}
