/* Day / night switch + the few things the generated day stylesheet can't derive. */

.stlh-mode-btn {
    width: 42px;
    height: 42px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(148, 163, 184, .28);
    border-radius: 12px;
    background: transparent;
    color: #e2e8f0;
    cursor: pointer;
    transition: background .2s, border-color .2s, color .2s;
}
.stlh-mode-btn:hover { background: rgba(124, 58, 237, .18); border-color: rgba(124, 58, 237, .6); color: #fff; }
.stlh-mode-btn:focus-visible { outline: 2px solid #a78bfa; outline-offset: 2px; }
.stlh-mode-btn__moon { display: none; }
html[data-theme="light"] .stlh-mode-btn__sun { display: none; }
html[data-theme="light"] .stlh-mode-btn__moon { display: block; }
html[data-theme="light"] .stlh-mode-btn { color: #334155; border-color: #cbd5e1; background: #fff; }
html[data-theme="light"] .stlh-mode-btn:hover { background: #ede9fe; border-color: #a78bfa; color: #5b21b6; }

html.stlh-theme-anim, html.stlh-theme-anim * { transition: background-color .25s ease, color .25s ease, border-color .25s ease !important; }
html[data-theme="light"] { color-scheme: light; }
html[data-theme="dark"] { color-scheme: dark; }

/* ---------------------------------------------------------------- DAY MODE */
html[data-theme="light"] body { background: #f3f5fa; color: #1e293b; }

/* The logo artwork has white lettering: re-ink it for a light header/footer. */
html[data-theme="light"] .logo img,
html[data-theme="light"] .footer-col img,
html[data-theme="light"] .stlh-auth__brand img { filter: invert(1) hue-rotate(180deg) saturate(1.15); }

/* Day-mode surfaces get a soft shadow instead of dark glow. */
html[data-theme="light"] .products-wrapper,
html[data-theme="light"] .stl-info,
html[data-theme="light"] .stl-gallery,
html[data-theme="light"] .reviews-section,
html[data-theme="light"] .shop-page-wrapper,
html[data-theme="light"] .related-products-section,
html[data-theme="light"] .about-hero,
html[data-theme="light"] .stlh-page__article { box-shadow: 0 6px 24px rgba(30, 41, 59, .07); }
html[data-theme="light"] .product-card { box-shadow: 0 2px 10px rgba(30, 41, 59, .06); }
html[data-theme="light"] .product-card:hover { box-shadow: 0 10px 28px rgba(109, 40, 217, .16); }

html[data-theme="light"] header { box-shadow: 0 1px 0 #e2e8f0; }
html[data-theme="light"] .top-header,
html[data-theme="light"] .bottom-header { background: #ffffff; }
html[data-theme="light"] .bottom-header a { color: #1e293b; }
html[data-theme="light"] .bottom-header a:hover { color: #6d28d9; }
html[data-theme="light"] .header-right a { color: #334155; }
html[data-theme="light"] .header-center input { background: #f8fafc; color: #0f172a; border-color: #c4b5fd; box-shadow: none; }
html[data-theme="light"] .header-center input::placeholder { color: #94a3b8; }

/* Auth popup variables */
html[data-theme="light"] .stlh-auth {
    --a-bg: #ffffff; --a-surface: #ffffff; --a-field: #f8fafc; --a-border: #dbe2ec; --a-border-strong: #b6c2d4;
    --a-text: #0f172a; --a-muted: #5b6b82; --a-accent-soft: rgba(124, 58, 237, .10);
}
html[data-theme="light"] .stlh-auth__dialog { background: #ffffff; box-shadow: 0 30px 80px rgba(15, 23, 42, .25); }
html[data-theme="light"] .stlh-auth__backdrop { background: rgba(15, 23, 42, .45); }
html[data-theme="light"] .stlh-field label,
html[data-theme="light"] .stlh-check { color: #334155; }
html[data-theme="light"] .stlh-auth__notice--error { color: #b91c1c; background: #fef2f2; border-color: #fecaca; }
html[data-theme="light"] .stlh-auth__notice--success { color: #166534; background: #f0fdf4; border-color: #bbf7d0; }
html[data-theme="light"] .stlh-auth__notice--info { color: #5b21b6; background: #f5f3ff; border-color: #ddd6fe; }
html[data-theme="light"] .stlh-auth .stlh-field input[type="text"],
html[data-theme="light"] .stlh-auth .stlh-field input[type="email"],
html[data-theme="light"] .stlh-auth .stlh-field input[type="password"] { background: #f8fafc; color: #0f172a; border-color: #cbd5e1; }
html[data-theme="light"] .stlh-auth__link,
html[data-theme="light"] .stlh-auth__switch button,
html[data-theme="light"] .stlh-auth__legal a { color: #6d28d9; }

/* Content pages */
html[data-theme="light"] .stlh-page { color: #334155; }
html[data-theme="light"] .stlh-page__title,
html[data-theme="light"] .stlh-page__content h2,
html[data-theme="light"] .stlh-page__content strong { color: #0f172a; }
html[data-theme="light"] .stlh-page__content h3 { color: #1e293b; }
html[data-theme="light"] .stlh-page__header { background: radial-gradient(120% 140% at 50% 0%, rgba(124, 58, 237, .14) 0%, rgba(124, 58, 237, 0) 60%), #faf9ff; border-bottom-color: #e2e8f0; }
html[data-theme="light"] .stlh-page__meta { color: #6d28d9; background: #f5f3ff; border-color: #ddd6fe; }
html[data-theme="light"] .stlh-page__content a { color: #6d28d9; }
html[data-theme="light"] .stlh-page__content .stlh-callout { background: linear-gradient(135deg, #f5f3ff, #eff6ff); border-color: #ddd6fe; color: #1e293b; }

/* Text on filled violet badges stays white in day mode. */
html[data-theme="light"] .sale-price,
html[data-theme="light"] .sale-price *,
html[data-theme="light"] .stl-price ins .woocommerce-Price-amount { color: #fff; }
html[data-theme="light"] .stl-price ins .woocommerce-Price-amount { color: #6d28d9; }

/* Form fields in day mode: clean light inputs everywhere (checkout, account, support). */
html[data-theme="light"] input[type="text"],
html[data-theme="light"] input[type="email"],
html[data-theme="light"] input[type="tel"],
html[data-theme="light"] input[type="password"],
html[data-theme="light"] input[type="search"],
html[data-theme="light"] input[type="number"],
html[data-theme="light"] textarea,
html[data-theme="light"] select,
html[data-theme="light"] .select2-selection {
    background-color: #f8fafc;
    color: #0f172a;
    border-color: #cbd5e1;
}
html[data-theme="light"] input:focus,
html[data-theme="light"] textarea:focus,
html[data-theme="light"] select:focus { border-color: #7c3aed; box-shadow: 0 0 0 3px rgba(124, 58, 237, .15); outline: 0; }
html[data-theme="light"] ::placeholder { color: #94a3b8; }

@media (max-width: 900px) { .stlh-mode-btn { width: 38px; height: 38px; border-radius: 10px; } }

/* ---- day / night pill switch: moon + stars <-> sun + clouds ---- */
html .stlh-mode-btn { width: 64px; height: 34px; padding: 0; border: 0; border-radius: 999px; background: none; overflow: visible; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
html .stlh-mode-btn:hover { background: none; border: 0; }
.stlh-sw { position: relative; display: block; width: 64px; height: 34px; border-radius: 999px; overflow: hidden; background: linear-gradient(135deg, #0b1330, #1e1b4b 60%, #312e81); box-shadow: inset 0 2px 6px rgba(0,0,0,.5), 0 0 0 1px rgba(124,58,237,.45); transition: background .5s, box-shadow .5s; }
.stlh-sw__knob { position: absolute; top: 4px; left: 4px; width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #f8fafc, #cbd5e1); box-shadow: 0 2px 6px rgba(0,0,0,.45), 0 0 12px rgba(226,232,240,.35); transition: transform .5s cubic-bezier(.6,-.2,.3,1.2), background .5s, box-shadow .5s; }
.stlh-sw__knob b { position: absolute; border-radius: 50%; background: rgba(100,116,139,.35); transition: opacity .3s; }
.stlh-sw__knob b:nth-child(1) { width: 7px; height: 7px; top: 5px; left: 12px; }
.stlh-sw__knob b:nth-child(2) { width: 5px; height: 5px; top: 14px; left: 5px; }
.stlh-sw__knob b:nth-child(3) { width: 4px; height: 4px; top: 16px; left: 15px; }
.stlh-sw__stars i { position: absolute; width: 3px; height: 3px; border-radius: 50%; background: #fff; box-shadow: 0 0 4px #fff; transition: opacity .4s, transform .5s; animation: stlhTwinkle 2.4s ease-in-out infinite; }
.stlh-sw__stars i:nth-child(1) { left: 34px; top: 8px; } .stlh-sw__stars i:nth-child(2) { left: 44px; top: 20px; animation-delay: .6s; }
.stlh-sw__stars i:nth-child(3) { left: 52px; top: 9px; width: 2px; height: 2px; animation-delay: 1.1s; } .stlh-sw__stars i:nth-child(4) { left: 39px; top: 25px; width: 2px; height: 2px; animation-delay: 1.6s; }
.stlh-sw__stars i:nth-child(5) { left: 56px; top: 22px; width: 2px; height: 2px; animation-delay: .3s; }
@keyframes stlhTwinkle { 0%,100% { opacity: 1; } 50% { opacity: .25; } }
.stlh-sw__clouds i { position: absolute; height: 9px; border-radius: 9px; background: #fff; opacity: 0; transform: translateX(14px); transition: opacity .4s, transform .5s; }
.stlh-sw__clouds i:nth-child(1) { width: 20px; left: 8px; top: 20px; } .stlh-sw__clouds i:nth-child(2) { width: 15px; left: 20px; top: 9px; opacity: 0; }
html[data-theme="light"] .stlh-sw { background: linear-gradient(135deg, #38bdf8, #7dd3fc 60%, #bae6fd); box-shadow: inset 0 2px 5px rgba(2,132,199,.35), 0 0 0 1px #7dd3fc; }
html[data-theme="light"] .stlh-sw__knob { transform: translateX(30px); background: radial-gradient(circle at 35% 35%, #fde68a, #fbbf24); box-shadow: 0 2px 6px rgba(180,83,9,.4), 0 0 14px rgba(251,191,36,.8); }
html[data-theme="light"] .stlh-sw__knob b { opacity: 0; }
html[data-theme="light"] .stlh-sw__stars i { opacity: 0; transform: translateY(-8px); animation: none; }
html[data-theme="light"] .stlh-sw__clouds i { opacity: .95; transform: none; }
html[data-theme="light"] .stlh-mode-btn, html[data-theme="light"] .stlh-mode-btn:hover { background: none; border: 0; }
@media (max-width: 900px) { html .stlh-mode-btn { width: 56px; height: 30px; border-radius: 999px; } .stlh-sw { width: 56px; height: 30px; } .stlh-sw__knob { width: 22px; height: 22px; } html[data-theme="light"] .stlh-sw__knob { transform: translateX(26px); } }

/* ==========================================================================
   2026-10 contrast fixes (WCAG AA, checked on every page in day and night mode)
   ========================================================================== */
.newsletter-right button { background: #7c3aed; }
.ff-btn, .fluent_form button.ff-btn-submit { background: #7e22ce; }
html[data-theme="light"] .newsletter-right button { background: #6d28d9; color: #fff; }
html[data-theme="light"] .product-badge { background: #15803d; color: #fff; }
html[data-theme="light"] .product-rating,
html[data-theme="light"] .product-rating span { color: #8a6512; }
html[data-theme="light"] .license-item.allowed { color: #1b6b3c; }
html[data-theme="light"] .license-item.not-allowed { color: #8e2929; }
html[data-theme="light"] .review-badge, html[data-theme="light"] .review-verified { color: #0b6a4b; }
html[data-theme="light"] .stl-save { color: #166534; }
html[data-theme="light"] .ff-btn { background: #7e22ce; color: #fff; }
html[data-theme="light"] .product-card .product-rating { color: #8a6512; }
html[data-theme="light"] .reviews-section .review-badge { color: #0b6a4b; }
html body .fluentform .ff-btn-submit, html body button.ff-btn { background: #7e22ce !important; color: #fff !important; }
html[data-theme="light"] .sup-step small { color: #52627a; }
/* night mode: muted greys and purples that were too dim on the dark background */
html:not([data-theme="light"]) .product-badge,
html[data-theme="light"] .product-badge { background: #15803d; color: #fff; }
html:not([data-theme="light"]) del,
html:not([data-theme="light"]) del bdi,
html:not([data-theme="light"]) .footer-bottom-left,
html:not([data-theme="light"]) .review-date,
html:not([data-theme="light"]) .stl-meta { color: #94a3b8; }
html:not([data-theme="light"]) .category-count { color: #a78bfa; }
html:not([data-theme="light"]) .woocommerce-breadcrumb a,
html:not([data-theme="light"]) .shop-breadcrumb a,
html:not([data-theme="light"]) nav.breadcrumb a { color: #a78bfa; }
html:not([data-theme="light"]) body del bdi,
html:not([data-theme="light"]) body del .amount,
html:not([data-theme="light"]) body .review-date,
html:not([data-theme="light"]) body .sup-step small { color: #94a3b8 !important; }
html:not([data-theme="light"]) body .woocommerce-breadcrumb a,
html:not([data-theme="light"]) body .shop-top-bar a { color: #a78bfa !important; }
html:not([data-theme="light"]) body .regular-price,
html:not([data-theme="light"]) body .regular-price .amount,
html:not([data-theme="light"]) body .regular-price bdi { color: #94a3b8 !important; }
html[data-theme="light"] .dm-rc-verified, html[data-theme="light"] .dm-rs-verified { color: #0b6a4b; }
.stlh-auth-social-btn--facebook { background: #1565d8; }
html:not([data-theme="light"]) body [class*="dm-rc-"] time, html:not([data-theme="light"]) body [class*="dm-rs-"] time { color: #94a3b8 !important; }
