/* Decorative fills stay absent in the original light theme. */
#sharemax-site.shmx-subpage-dark .shmx-subpage-band-fill {
  display: none;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark {
  --ink: #F5F7FA;
  --muted: #D3D9E3;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark > .header,
html[data-theme="dark"] #sharemax-site.shmx-subpage-dark > .footer {
  background-color: #18191C !important;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .shmx-subpage-band-dark {
  --shmx-band-bg: #14161A;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .shmx-subpage-band-soft {
  --shmx-band-bg: #2B3039;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .shmx-subpage-band {
  position: relative;
  isolation: isolate;
  background: var(--shmx-band-bg) !important;
}

/* Extend the background to the viewport edges without changing wrap widths
   or introducing a horizontal scrollbar. Clip only the decorative fill. */
html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .shmx-subpage-band > .shmx-subpage-band-fill {
  display: block;
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--shmx-band-bg);
  box-shadow: 0 0 0 100vmax var(--shmx-band-bg);
  clip-path: inset(0 -100vmax);
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .shmx-subpage-band.service:hover {
  --shmx-band-bg: #2C2023;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(h1,h2,h3,h4,strong,b,dd,.faq-question,.faq-trigger,.project-title,.notice-copy,.template-panel-caption) {
  color: #F5F7FA !important;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(p,li,dt,.hero-summary,.section-desc,.project-long-desc,.project-tags span,.faq-answer-content,.overview-copy,.stage-detail,.stage-detail span,.notice-count,.notice-number,.notice-date,.plan-note) {
  color: #D3D9E3 !important;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(.eyebrow,.plan-label,.care-overview-kicker,.care-task-index,.care-no,.stage-no,.project-category,.number,.index) {
  color: #FF6675 !important;
}

/* Keep the final hero-title letter white in dark mode. */
html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .page-hero h1 > span:last-child {
  color: #FFFFFF !important;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(button,.button,.plan-card > a,.type-nav a,.primary-cats button,.pagination .page-btn) {
  color: #F5F7FA !important;
}

/* These carousel controls invert to a light background on hover/focus. */
html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(.template-carousel-arrow,.template-carousel-toggle):is(:hover,:focus-visible) {
  color: #14161A !important;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(input,textarea,select) {
  color: #F5F7FA !important;
}

html[data-theme="dark"] #sharemax-site.shmx-subpage-dark main :is(input,textarea)::placeholder {
  color: #BBC4D2 !important;
}

/* Native notice detail/editor uses its existing banner and board surfaces. */
html[data-theme="dark"] #sharemax-site.shmx-subpage-dark .shmx-native :is(#bo_v_title,#bo_v_info,#bo_v_con,.bo_tit a,.td_name,.btn_b01,.btn_b02) {
  color: #F5F7FA !important;
}

/* Company introduction: retain red ShareMAX branding in the hero title. */
#sharemax-site[data-page="company-intro"] .page-hero h1.shmx-about-title > .shmx-about-title-line:last-child,
html[data-theme="dark"] #sharemax-site[data-page="company-intro"].shmx-subpage-dark .page-hero h1.shmx-about-title > .shmx-about-title-line:last-child {
  color: var(--red, #e50919) !important;
  -webkit-text-fill-color: var(--red, #e50919) !important;
}

/* ShareMAX subpage labels: consistent brand red from About to Customer Support. */
#sharemax-site.shmx-subpage-dark[data-page] main .eyebrow,
html[data-theme="dark"] #sharemax-site.shmx-subpage-dark[data-page] main .eyebrow {
  color: #E50919 !important;
  -webkit-text-fill-color: #E50919 !important;
}
