/* Toeflyar 1.0.1 — visual/accessibility patch.
   Additive. Does not mutate Elementor content or typography controls in light mode. */

/* Consistent sun/moon SVG, truly centered, including fallback theme header. */
button[data-mz-mode-toggle],
.mzui-global-header button.mzui-dark-toggle {
  display:inline-flex!important; align-items:center!important; justify-content:center!important;
  width:42px; height:42px; min-width:42px; min-height:42px;
  box-sizing:border-box; padding:0!important; line-height:1!important;
  border:1px solid var(--mz-border,#e8e0dc)!important;
  border-radius:50%!important; background:var(--mz-card,#fff)!important;
  color:var(--mz-ink,#1f1730)!important; box-shadow:none;
  cursor:pointer; vertical-align:middle;
  transition:background-color .2s,color .2s,border-color .2s,transform .2s;
}
button[data-mz-mode-toggle] .tf-theme-icon,
.mzui-global-header button.mzui-dark-toggle .tf-theme-icon {
  display:block!important; flex:0 0 21px; width:21px!important;height:21px!important;
  margin:0!important; padding:0!important; fill:none;
  stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round;
}
button[data-mz-mode-toggle]:hover,
.mzui-global-header button.mzui-dark-toggle:hover {
  color:var(--mz-accent,#f26b4d)!important;
  background:var(--mz-soft,#ffede5)!important; transform:translateY(-1px);
}
button[data-mz-mode-toggle]:focus-visible {outline:2px solid var(--mz-accent,#f26b4d);outline-offset:3px;}
html[data-mz-theme="dark"] button[data-mz-mode-toggle] {
  color:#ffbd79!important;background:#31243e!important;border-color:#675575!important;
}
html[data-mz-theme="dark"] button[data-mz-mode-toggle]:hover{background:#453052!important;color:#ffd69e!important;}

/* Mobile off-canvas close: Elementor's global button CSS must not take over. */
body .tf-menu-sheet button.tf-menu-sheet-close {
  appearance:none!important; display:flex!important; align-items:center!important; justify-content:center!important;
  flex:0 0 42px!important;width:42px!important;height:42px!important; min-height:42px!important;
  padding:0!important;margin:0!important; line-height:1!important; border-radius:50%!important;
  border:1px solid #efc7b9!important;background:#fff3ed!important;
  color:#bb4738!important;box-shadow:none!important;cursor:pointer;
  transition:background-color .18s,border-color .18s,color .18s,transform .18s;
}
body .tf-menu-sheet button.tf-menu-sheet-close svg{
  display:block; flex:0 0 20px;width:20px;height:20px;margin:0;padding:0;
  stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;
}
body .tf-menu-sheet button.tf-menu-sheet-close:hover{
  background:#ffdfd2!important;color:#8e2e21!important;border-color:#e9947a!important;
  transform:rotate(90deg);
}
body .tf-menu-sheet button.tf-menu-sheet-close:focus-visible{outline:2px solid #f26b4d!important;outline-offset:3px!important}
html[data-mz-theme="dark"] body .tf-menu-sheet button.tf-menu-sheet-close{
  background:#44304b!important;color:#ffb39f!important;border-color:#76607a!important;
}
html[data-mz-theme="dark"] body .tf-menu-sheet button.tf-menu-sheet-close:hover{
  background:#583751!important;color:#fff!important;border-color:#a57886!important;
}

/* About CTA centered even though the base theme aligns every button to flex-start. */
.mz-el-section-tf-about-cta .mz-el-inner > .elementor-widget-button,
.mz-el-section-tf-about-cta .elementor-widget-button {
  align-self:center!important;margin-inline:auto!important;text-align:center;
}
.mz-el-section-tf-about-cta .elementor-button-wrapper{text-align:center!important}

/* Table grid remains visually clear in both light and dark themes. */
.mzui-compare-scroller{
  border:1px solid #ded3cb!important;
  overflow-x:auto;overflow-y:hidden;
}
.mzui-compare{border-collapse:separate!important;border-spacing:0!important;}
.mzui-compare :is(th,td){border-inline-end:1px solid #ded3cb!important;border-bottom:1px solid #e7ded9!important;}
.mzui-compare tr>:last-child{border-inline-end:0!important;}
.mzui-compare tbody tr:last-child>*{border-bottom:0!important;}
html[data-mz-theme="dark"] .mzui-compare-scroller{border-color:#695774!important;background:#2a1e3c!important;}
html[data-mz-theme="dark"] .mzui-compare :is(th,td){border-inline-end-color:#695774!important;border-bottom-color:#584764!important;}
html[data-mz-theme="dark"] .mzui-compare thead th{color:#ff9b7f;}
html[data-mz-theme="dark"] .mzui-compare tbody th{color:#fff!important;}
html[data-mz-theme="dark"] .mzui-compare tbody td{color:#e8e0ec!important;}
html[data-mz-theme="dark"] .mzui-compare tbody tr:nth-child(even){background:#342641;}

/* Dark-mode readability for generated About and Contact pages, including
   labels, section subtitles, Elementor widgets and content outside the cards. */
html[data-mz-theme="dark"] :is(
  .mz-el-section-tf-about-hero,.mz-el-section-tf-about-values,
  .mz-el-section-tf-about-services,.mz-el-section-tf-contact-hero,
  .mz-el-section-tf-contact-content
 ) :is(.mz-el-heading,.mz-el-small-title) .elementor-heading-title {
  color:#f9f5ff!important;
}
html[data-mz-theme="dark"] :is(
  .mz-el-section-tf-about-hero,.mz-el-section-tf-about-values,
  .mz-el-section-tf-about-services,.mz-el-section-tf-contact-hero,
  .mz-el-section-tf-contact-content
 ) .mz-el-eyebrow .elementor-heading-title{color:#ff9b7f!important;}
html[data-mz-theme="dark"] :is(
  .mz-el-section-tf-about-hero,.mz-el-section-tf-about-values,
  .mz-el-section-tf-about-services,.mz-el-section-tf-contact-hero,
  .mz-el-section-tf-contact-content
 ) .mz-hot{color:#ff8a65!important;}
html[data-mz-theme="dark"] :is(.mz-el-section-tf-about-hero,.mz-el-section-tf-contact-hero)
  .elementor-widget-text-editor :is(p,span){color:#e3d9e9!important;}
html[data-mz-theme="dark"] .tf-contact-card{background:#2a1e3c;border-color:#5a4864;color:#f7f3fa;}
html[data-mz-theme="dark"] .tf-contact-form-card{background:linear-gradient(145deg,#513544,#2a1e3c 78%);}
html[data-mz-theme="dark"] .tf-contact-card > .elementor-widget-text-editor :is(p,span){color:#ddd2e3!important;}
html[data-mz-theme="dark"] .tf-contact-card .tf-contact-link a{color:#ff967c!important;}
/* Native Elementor form itself stays on a white card for contrast. */
html[data-mz-theme="dark"] .tf-pro-form-card :is(.elementor-heading-title,p,span){color:#1f1730!important;}
html[data-mz-theme="dark"] .tf-pro-form-card .elementor-button :is(span,svg){color:#fff!important;}
html[data-mz-theme="dark"] .tf-pro-form-card input{color:#1f1730!important;background:#fff9f5!important;}

/* Blog archive and single article: Elementor may have saved fixed navy text. */
html[data-mz-theme="dark"] .tf-blog{
  color:#f5effa!important;background:#160f24!important;
}
html[data-mz-theme="dark"] .tf-blog .mz-el-section-tf-blog-hero{
  background:radial-gradient(circle at right,rgba(242,107,77,.11),transparent 55%),#160f24!important;
}
html[data-mz-theme="dark"] .tf-blog :is(.tf-post-title,.tf-post-title *, .mz-el-heading .elementor-heading-title,
 .tf-article-card h2 a, .tf-related-card strong, .tf-article-body h2, .tf-article-body h3,
 .tf-article-body h4){color:#f9f5ff!important;}
html[data-mz-theme="dark"] .tf-blog .mz-el-eyebrow .elementor-heading-title{color:#ff9477!important;}
html[data-mz-theme="dark"] .tf-blog .mz-hot{color:#ff8a65!important;}
html[data-mz-theme="dark"] .tf-blog .mz-el-section-tf-blog-hero .elementor-widget-text-editor p,
html[data-mz-theme="dark"] .tf-blog .mz-el-section-tf-post-intro .elementor-widget-text-editor p,
html[data-mz-theme="dark"] .tf-blog .tf-article-body :is(p,li),
html[data-mz-theme="dark"] .tf-blog .tf-article-card :is(p,time){color:#dfd3e7!important;}
html[data-mz-theme="dark"] .tf-blog :is(.tf-article-card,.tf-related-card,.tf-empty){
  background:#2a1e3c!important;border-color:#584766!important;
}
html[data-mz-theme="dark"] .tf-blog :is(.tf-breadcrumb,.tf-post-meta){color:#d8cadd!important;}
html[data-mz-theme="dark"] .tf-blog .tf-blog-pagination .page-numbers:not(.current){color:#f9f5ff;background:#2a1e3c;border-color:#645171;}
html[data-mz-theme="dark"] .tf-blog .mz-el-section-tf-post-related{background:#20162e!important;}
html[data-mz-theme="dark"] .tf-blog .tf-article-body blockquote{background:#322343;color:#f9f5ff;}

/* Recurrent subtitle headings outside pastel/light cards on the homepage and services. */
html[data-mz-theme="dark"] :is(.mz-el-section-comparison,.mz-el-section-features,
 .mz-el-section-steps,.mz-el-section-team,.mz-el-section-study,
 .mz-el-section-articles,.mz-el-section-faq)
 :is(.mz-el-heading,.mz-el-hero-h1) .elementor-heading-title{color:#f9f5ff!important;}
html[data-mz-theme="dark"] .mz-el-section[class*="mz-el-section-ielts-"]
 :is(.mz-ielts-heading,.mz-ielts-h1) .elementor-heading-title,
html[data-mz-theme="dark"] .mz-el-section[class*="mz-el-section-toefl-"]
 :is(.mz-toefl-heading,.mz-toefl-h1) .elementor-heading-title,
html[data-mz-theme="dark"] .mz-el-section[class*="mz-el-section-gre-"]
 :is(.mz-gre-heading,.mz-gre-h1) .elementor-heading-title,
html[data-mz-theme="dark"] .mz-el-section[class*="mz-el-section-duolingo-"]
 :is(.mz-duolingo-heading,.mz-duolingo-h1) .elementor-heading-title{color:#f9f5ff!important;}
html[data-mz-theme="dark"] .mz-el-section .mz-hot{color:#ff8a65!important;}
/* Service sample score cards and native white form should KEEP their dark text. */
html[data-mz-theme="dark"] :is(.mz-ielts-score-values,.mz-toefl-score-values,.mz-gre-score-values,.mz-duolingo-score-values) b{color:#1f1730!important;}

@media (max-width:767px){
  .mzui-global-header button.mzui-dark-toggle{width:40px;height:40px;min-width:40px;min-height:40px;}
  .tf-menu-sheet-heading{gap:12px;}
  .tf-menu-sheet-heading strong{min-width:0;}
  .mzui-compare-scroller{max-width:100%;}
  .mzui-compare{min-width:650px!important;}
}
/* Hero subheadings use fixed palette colors in the 0.5–0.8 service stylesheets;
   provide lighter variants only in dark mode (not the light editing palette). */
html[data-mz-theme="dark"] .mz-el-section-ielts-hero .mz-ielts-subheading .elementor-heading-title,
html[data-mz-theme="dark"] .mz-el-section-toefl-hero .mz-toefl-subheading .elementor-heading-title{
  color:#ffae96!important;
}
html[data-mz-theme="dark"] .mz-el-section-gre-hero .mz-gre-subheading .elementor-heading-title{color:#a7eac5!important;}
html[data-mz-theme="dark"] .mz-el-section-duolingo-hero .mz-duolingo-subheading .elementor-heading-title{color:#d9c1ff!important;}
html[data-mz-theme="dark"] :is(.mz-ielts-intro,.mz-toefl-intro,.mz-gre-intro,.mz-duolingo-intro) p,
html[data-mz-theme="dark"] :is(.mz-ielts-hero-text,.mz-toefl-hero-text,.mz-gre-hero-text,.mz-duolingo-hero-text) p{
  color:#e2d7e8!important;
}
