/* Castlance Theme v12.0.0 — Light Mode Consistency Fix
   Scope: public website + customer portal.
   Dark mode behavior is intentionally left untouched.
   This stylesheet loads LAST and neutralizes legacy v8.4.x / v10 dark-only !important rules only when data-theme="light". */

html[data-theme="light"]{
  color-scheme:light!important;
  --c-page:#f5f7fb!important;
  --c-surface:#ffffff!important;
  --c-soft:#f1f5f9!important;
  --c-text:#102033!important;
  --c-muted:#607187!important;
  --c-faint:#8190a3!important;
  --c-line:#dbe4ee!important;
  --c-brand:#2d67e8!important;
  --c-shadow:0 14px 38px rgba(19,39,69,.075)!important;
  --cast-bg:#f5f7fb!important;
  --cast-surface:#ffffff!important;
  --cast-surface-2:#f1f5f9!important;
  --cast-text:#102033!important;
  --cast-muted:#607187!important;
  --cast-border:#dbe4ee!important;
  --cast-brand:#2d67e8!important;
  --cast-v6-bg:#f5f7fb!important;
  --cast-v6-surface:#ffffff!important;
  --cast-v6-surface-2:#f1f5f9!important;
  --cast-v6-text:#102033!important;
  --cast-v6-muted:#607187!important;
  --cast-v6-line:#dbe4ee!important;
  --v10-bg:#f5f7fb!important;
  --v10-bg2:#eef3f8!important;
  --v10-panel:#ffffff!important;
  --v10-panel2:#f7f9fc!important;
  --v10-panel3:#eef3f8!important;
  --v10-line:#dbe4ee!important;
  --v10-line2:#cad7e5!important;
  --v10-text:#102033!important;
  --v10-muted:#607187!important;
  --v10-faint:#8190a3!important;
  --xline:#dbe4ee!important;
  background:#f5f7fb!important;
}

/* Shared theme controls */
.c11-theme-toggle,.portal-theme-toggle,.portal-mobile-theme-toggle,.portal-login-theme-toggle{
  appearance:none;border:1px solid var(--c-line,#dbe4ee);background:var(--c-soft,#f1f5f9);color:var(--c-text,#102033);
  cursor:pointer;transition:background .18s ease,border-color .18s ease,color .18s ease,transform .18s ease;
}
.c11-theme-toggle:hover,.portal-theme-toggle:hover,.portal-mobile-theme-toggle:hover,.portal-login-theme-toggle:hover{transform:translateY(-1px)}
.site-header .c11-theme-toggle{display:inline-grid!important;place-items:center;width:40px;height:40px;border-radius:11px!important;padding:0!important}
.portal-theme-toggle{display:grid;place-items:center;width:40px;height:40px;border-radius:11px;flex:0 0 40px;font-size:17px}
.portal-mobile-theme-toggle{width:100%;min-height:44px;border-radius:10px;display:flex;align-items:center;gap:9px;justify-content:flex-start;padding:0 12px;font-weight:800}
.portal-login-theme-toggle{position:fixed;right:18px;top:18px;width:44px;height:44px;border-radius:12px;z-index:90;display:grid;place-items:center;font-size:18px;box-shadow:0 10px 30px rgba(0,0,0,.10)}

/* ============================================================
   PUBLIC WEBSITE — complete light mode
   ============================================================ */
html[data-theme="light"],
html[data-theme="light"] body,
html[data-theme="light"] body.castlance-public-v8,
html[data-theme="light"] body.castlance-public-v8 main,
html[data-theme="light"] body.castlance-public-v8 main>section,
html[data-theme="light"] body.castlance-public-v8 .section,
html[data-theme="light"] body.castlance-public-v8 .page-wrap,
html[data-theme="light"] body.castlance-public-v8 .content,
html[data-theme="light"] body.castlance-public-v8 .content-wrap{
  background:#f5f7fb!important;background-color:#f5f7fb!important;color:#102033!important;
}
html[data-theme="light"] body.castlance-public-v8 .section.soft,
html[data-theme="light"] body.castlance-public-v8 .soft{background:#eef3f8!important;background-color:#eef3f8!important}

html[data-theme="light"] body.castlance-public-v8 :where(h1,h2,h3,h4,h5,h6,strong,b,label,dt,dd,th,li,summary){
  color:#102033!important;-webkit-text-fill-color:#102033!important;
}
html[data-theme="light"] body.castlance-public-v8 :where(p,small,.muted,.subtitle,.description,.hint,.help,td){
  color:#607187!important;-webkit-text-fill-color:#607187!important;
}
html[data-theme="light"] body.castlance-public-v8 a:not(.btn):not(.nav-cta){color:#2d67e8!important}

/* All ordinary public surfaces become light. */
html[data-theme="light"] body.castlance-public-v8 :where(
  .card,.panel,.box,.white,.white-card,.surface-white,.bg-white,
  .value-bar,.value-bar>div,.value-grid,.value-grid>div,.versus-card,.journey>article,
  .premium-features>article,.premium-features>div,.platform-cards>article,.platform-cards>div,
  .premium-pricing>article,.pricing-card,.price-card,.pricing-card-v43,.pricing-hero-card,
  .pricing-demo-box,.pricing-demo-cta,.plan-card,.pricing-box,.pricing-grid>article,.package-card,
  .faq-item,.faq-card,.faq-box,.faq-list details,.faq-list>article,.faq-accordion-v43 details,
  .faq-content-v43,.faq-sidebar-v43,.faq-support-card,.faq-bottom-help,
  .download-platform,.download-card,.download-box,.platform-card,.requirements-grid>article,
  .release-card,.release-summary-grid,.download-panel,.download-shell,.download-wrap,
  .compare-table-wrap,.pricing-compare-v43,.roi-card,.account-card,.checkout-card,.pay-option,
  .lab,.ops-console,.ops-row,.trust-pills>span,.queue,.app-shot,.metric-card,.floating,
  .demo-card,.demo-box,.cta-box,.release-callout,.final-cta,.os-detect,.setup-step
){
  background:#fff!important;background-color:#fff!important;border-color:#dbe4ee!important;color:#102033!important;
  box-shadow:0 12px 34px rgba(19,39,69,.065)!important;
}
html[data-theme="light"] body.castlance-public-v8 :where(
  .card,.panel,.box,.value-bar,.value-grid,.versus-card,.journey>article,.premium-features>article,
  .premium-features>div,.platform-cards>article,.platform-cards>div,.premium-pricing>article,
  .pricing-card,.price-card,.pricing-card-v43,.pricing-hero-card,.pricing-demo-box,.pricing-demo-cta,
  .plan-card,.pricing-box,.pricing-grid>article,.package-card,.faq-item,.faq-card,.faq-box,
  .faq-list details,.faq-list>article,.faq-accordion-v43 details,.faq-content-v43,.faq-sidebar-v43,
  .faq-support-card,.faq-bottom-help,.download-platform,.download-card,.release-card,
  .requirements-grid>article,.release-summary-grid,.roi-card,.account-card,.checkout-card,.lab,
  .ops-console,.ops-row,.queue,.app-shot,.metric-card,.floating,.demo-card,.demo-box,.cta-box
) :where(h1,h2,h3,h4,h5,h6,b,strong,label,summary,li,th,span){
  color:#102033!important;-webkit-text-fill-color:#102033!important;
}
html[data-theme="light"] body.castlance-public-v8 :where(
  .card,.panel,.box,.value-bar,.value-grid,.versus-card,.journey>article,.premium-features>article,
  .premium-features>div,.platform-cards>article,.platform-cards>div,.premium-pricing>article,
  .pricing-card,.price-card,.pricing-card-v43,.pricing-hero-card,.pricing-demo-box,.pricing-demo-cta,
  .plan-card,.pricing-box,.pricing-grid>article,.package-card,.faq-item,.faq-card,.faq-box,
  .faq-list details,.faq-list>article,.faq-accordion-v43 details,.faq-content-v43,.faq-sidebar-v43,
  .faq-support-card,.faq-bottom-help,.download-platform,.download-card,.release-card,
  .requirements-grid>article,.release-summary-grid,.roi-card,.account-card,.checkout-card,.lab,
  .ops-console,.ops-row,.queue,.app-shot,.metric-card,.floating,.demo-card,.demo-box,.cta-box
) :where(p,small,.muted,td){
  color:#607187!important;-webkit-text-fill-color:#607187!important;
}

/* Previously hard-coded dark branded blocks now get a true light variant. */
html[data-theme="light"] body.castlance-public-v8 :where(.hero,.premium-hero,.labs,.try-card,.release-callout-box,.final-box){
  background:linear-gradient(180deg,#ffffff 0%,#f2f6ff 100%)!important;background-color:#fff!important;
  border-color:#dbe4ee!important;color:#102033!important;box-shadow:0 16px 42px rgba(19,39,69,.075)!important;
}
html[data-theme="light"] body.castlance-public-v8 :where(.hero,.premium-hero,.labs,.try-card,.release-callout-box,.final-box)
:where(h1,h2,h3,h4,h5,h6,b,strong,span){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 :where(.hero,.premium-hero,.labs,.try-card,.release-callout-box,.final-box)
:where(p,small){color:#607187!important;-webkit-text-fill-color:#607187!important}

/* Product/mockup pieces */
html[data-theme="light"] body.castlance-public-v8 :where(.app-layout,.app-layout>section,.app-main,.app-screen,.app-window,.mockup-window,.app-status,.metric-row,.ops-console-stats>div){
  background:#fff!important;background-color:#fff!important;color:#102033!important;border-color:#dbe4ee!important;
}
html[data-theme="light"] body.castlance-public-v8 :where(.app-title,.app-top,.app-head,.app-window-head,.mockup-head,.window-bar){
  background:#f4f7fb!important;background-color:#f4f7fb!important;color:#102033!important;border-color:#dbe4ee!important;
}
html[data-theme="light"] body.castlance-public-v8 .app-layout aside{background:#eef3f8!important;color:#51657d!important;border-color:#dbe4ee!important}
html[data-theme="light"] body.castlance-public-v8 .app-layout aside :where(strong,b,span,a){color:#22364c!important;-webkit-text-fill-color:#22364c!important}
html[data-theme="light"] body.castlance-public-v8 .roi-result{background:#edf4ff!important;color:#173b72!important}
html[data-theme="light"] body.castlance-public-v8 .roi-result :where(b,span){color:#173b72!important;-webkit-text-fill-color:#173b72!important}
html[data-theme="light"] body.castlance-public-v8 .roi-result small{color:#5f7691!important;-webkit-text-fill-color:#5f7691!important}

/* Header + menus */
html[data-theme="light"] body.castlance-public-v8 .site-header{background:rgba(255,255,255,.96)!important;border-color:#dbe4ee!important;box-shadow:0 8px 28px rgba(20,40,70,.08)!important;color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 .site-header :where(.brand,a,b,button){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 .site-header .brand small{color:#2d67e8!important;-webkit-text-fill-color:#2d67e8!important}
html[data-theme="light"] body.castlance-public-v8 .site-header .site-nav a{color:#54677e!important;-webkit-text-fill-color:#54677e!important}
html[data-theme="light"] body.castlance-public-v8 .site-header .site-nav a:hover,
html[data-theme="light"] body.castlance-public-v8 .site-header .site-nav a.active{color:#2d67e8!important;-webkit-text-fill-color:#2d67e8!important}
html[data-theme="light"] body.castlance-public-v8 .site-header :where(.lang-switch,.menu-btn,.c11-theme-toggle){background:#f1f5f9!important;border-color:#d6e0ea!important;color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 .site-header .lang-switch a{color:#61738a!important;-webkit-text-fill-color:#61738a!important}
html[data-theme="light"] body.castlance-public-v8 .site-header .lang-switch a.active{background:#fff!important;color:#102033!important;-webkit-text-fill-color:#102033!important}

/* Form/table normalization */
html[data-theme="light"] body.castlance-public-v8 :where(input,select,textarea,option){
  background:#fff!important;background-color:#fff!important;color:#102033!important;-webkit-text-fill-color:#102033!important;border-color:#cad7e5!important;caret-color:#102033!important;
}
html[data-theme="light"] body.castlance-public-v8 :where(input,textarea)::placeholder{color:#8190a3!important;-webkit-text-fill-color:#8190a3!important;opacity:1!important}
html[data-theme="light"] body.castlance-public-v8 input:-webkit-autofill{-webkit-box-shadow:0 0 0 1000px #fff inset!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 :where(table,thead,tbody,tr,td,th){border-color:#dbe4ee!important}
html[data-theme="light"] body.castlance-public-v8 :where(thead,th){background:#f4f7fb!important;color:#31445a!important;-webkit-text-fill-color:#31445a!important}
html[data-theme="light"] body.castlance-public-v8 :where(tbody,tr,td){background:#fff!important;background-color:#fff!important}

/* Buttons retain hierarchy, not night-mode chrome. */
html[data-theme="light"] body.castlance-public-v8 .btn:not(.primary):not(.nav-cta){background:#fff!important;border-color:#cad7e5!important;color:#1f3854!important;-webkit-text-fill-color:#1f3854!important}
html[data-theme="light"] body.castlance-public-v8 :where(.btn.primary,.nav-cta){color:#fff!important;-webkit-text-fill-color:#fff!important}
html[data-theme="light"] body.castlance-public-v8 .btn.white{background:#fff!important;color:#1f3854!important;-webkit-text-fill-color:#1f3854!important;border-color:#cad7e5!important}
html[data-theme="light"] body.castlance-public-v8 :where(.platform-icon,.download-label){background:#eaf1ff!important;color:#2d67e8!important}

/* Footer also follows light mode. */
html[data-theme="light"] body.castlance-public-v8 :where(.site-footer,.footer-payments,.footer-bottom){
  background:#fff!important;background-color:#fff!important;color:#607187!important;border-color:#dbe4ee!important;
}
html[data-theme="light"] body.castlance-public-v8 .site-footer :where(h2,h3,b,strong){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 .site-footer :where(p,span,small){color:#607187!important;-webkit-text-fill-color:#607187!important}
html[data-theme="light"] body.castlance-public-v8 .site-footer a{color:#2d67e8!important}

/* Categorized mobile navigation follows the selected theme. */
.c11-mobile-overlay{display:none}.c11-mobile-drawer{display:none}
@media(max-width:820px){
  .site-header .c11-theme-toggle{display:none!important}
  body.c11-nav-open{overflow:hidden!important;touch-action:none}
  .c8-mobile-drawer,.c8-mobile-overlay{display:none!important}
  .c11-mobile-overlay{display:block;position:fixed;inset:0;z-index:9998;background:rgba(2,10,20,.46);backdrop-filter:blur(3px);opacity:0;pointer-events:none;transition:opacity .2s ease}
  body.c11-nav-open .c11-mobile-overlay{opacity:1;pointer-events:auto}
  .c11-mobile-drawer{display:flex;position:fixed;right:0;top:0;bottom:0;width:min(90vw,390px);height:100dvh;z-index:9999;transform:translateX(103%);transition:transform .22s ease;flex-direction:column;background:var(--c-surface,#0f1b2d)!important;color:var(--c-text,#f5f7fb)!important;border-left:1px solid var(--c-line,#2b3d54)!important;box-shadow:-28px 0 70px rgba(0,0,0,.20)}
  body.c11-nav-open .c11-mobile-drawer{transform:translateX(0)}
  .c11-drawer-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:18px;border-bottom:1px solid var(--c-line,#2b3d54)}
  .c11-drawer-head small{display:block;color:var(--c-brand,#79aaff);font-size:9px;font-weight:900;letter-spacing:.14em}.c11-drawer-head b{display:block;margin-top:3px;font-size:18px;color:var(--c-text,#f5f7fb)!important;-webkit-text-fill-color:var(--c-text,#f5f7fb)!important}
  .c11-drawer-close{width:42px;height:42px;border:1px solid var(--c-line,#2b3d54);border-radius:11px;background:var(--c-soft,#15243a);color:var(--c-text,#f5f7fb);font-size:22px;cursor:pointer}
  .c11-drawer-body{padding:13px;overflow:auto;display:grid;gap:10px}
  .c11-mobile-group{display:grid;gap:5px;padding:10px;border:1px solid var(--c-line,#2b3d54);border-radius:14px;background:var(--c-soft,#15243a)}
  .c11-mobile-group>span{padding:3px 6px 7px;color:var(--c-muted,#a6b3c5);font-size:9px;font-weight:900;letter-spacing:.13em;text-transform:uppercase}
  .c11-mobile-group a{display:flex;align-items:center;min-height:44px;padding:9px 10px;border-radius:9px;color:var(--c-text,#f5f7fb)!important;-webkit-text-fill-color:var(--c-text,#f5f7fb)!important;font-size:13px;font-weight:750;text-decoration:none}
  .c11-mobile-group a:hover,.c11-mobile-group a:active{background:rgba(45,103,232,.10)}
  .c11-drawer-foot{margin-top:auto;padding:13px;border-top:1px solid var(--c-line,#2b3d54)}
  .c11-mobile-theme{width:100%;min-height:46px;border:1px solid var(--c-line,#2b3d54);border-radius:11px;background:var(--c-soft,#15243a);color:var(--c-text,#f5f7fb);display:flex;align-items:center;justify-content:center;gap:9px;font-weight:800;cursor:pointer}
}
html[data-theme="light"] body.castlance-public-v8 .c11-mobile-drawer{background:#fff!important;color:#102033!important;border-color:#dbe4ee!important}
html[data-theme="light"] body.castlance-public-v8 :where(.c11-drawer-head,.c11-drawer-foot){border-color:#dbe4ee!important}
html[data-theme="light"] body.castlance-public-v8 :where(.c11-mobile-group,.c11-drawer-close,.c11-mobile-theme){background:#f1f5f9!important;border-color:#dbe4ee!important;color:#102033!important}
html[data-theme="light"] body.castlance-public-v8 .c11-mobile-group>span{color:#607187!important;-webkit-text-fill-color:#607187!important}
html[data-theme="light"] body.castlance-public-v8 .c11-mobile-group a{color:#102033!important;-webkit-text-fill-color:#102033!important}

/* ============================================================
   CUSTOMER PORTAL — complete light mode
   ============================================================ */
html[data-theme="light"] body.castlance-portal-v8,
html[data-theme="light"] body.castlance-portal-v8 main,
html[data-theme="light"] body.castlance-portal-v8 .wrap,
html[data-theme="light"] body.castlance-portal-v8 .shell,
html[data-theme="light"] body.castlance-portal-v8 .portal-wrap,
html[data-theme="light"] body.castlance-portal-v8 .portal-main{
  background:#f4f7fb!important;background-color:#f4f7fb!important;color:#102033!important;
}
html[data-theme="light"] body.castlance-portal-v8 :where(h1,h2,h3,h4,h5,h6,b,strong,label,summary,th,li){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 :where(p,small,.muted,.subtitle,.description,.hint,.help,td){color:#607187!important;-webkit-text-fill-color:#607187!important}

html[data-theme="light"] body.castlance-portal-v8 :where(
 .card,.panel,.box,.portal-card,.release-center,.download-card,.portal-v64-title,.portal-v64-quick,.portal-pop,
 .login-card,.auth-card,.login-box,.auth-box,.portal-box,.portal-panel,.saas-card,.saas-notice,.portal-notice,
 .table-wrap,.table,.device-card,.support-card,.invoice-card,.order-card,.portal-accordion,.portal-new-ticket,
 .stat,.kpi,.quota-saas-grid>div,.release-meta>div,.portal-invoice-summary>div,.portal-invoice-row,
 .profile-collapse,.profile-collapse-body,.setup-guide,.setup-step,.setup-note,.transfer-form,.email-license-note,
 .quota-overview,.premium-quota,.section-card-head,.portal-notification-center,.saas-notification-center
){
  background:#fff!important;background-color:#fff!important;border-color:#dbe4ee!important;color:#102033!important;
  box-shadow:0 12px 34px rgba(19,39,69,.065)!important;
}
html[data-theme="light"] body.castlance-portal-v8 :where(
 .card,.panel,.box,.portal-card,.release-center,.download-card,.portal-v64-title,.portal-v64-quick,.portal-pop,
 .login-card,.auth-card,.login-box,.auth-box,.portal-box,.portal-panel,.saas-card,.saas-notice,.portal-notice,
 .device-card,.support-card,.invoice-card,.order-card,.portal-accordion,.portal-new-ticket,.stat,.kpi,
 .quota-saas-grid>div,.release-meta>div,.portal-invoice-summary>div,.portal-invoice-row,.profile-collapse,
 .profile-collapse-body,.setup-guide,.setup-step,.setup-note,.transfer-form,.email-license-note,.quota-overview,.premium-quota
) :where(h1,h2,h3,h4,h5,h6,b,strong,label,summary,th,span){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 :where(
 .card,.panel,.box,.portal-card,.release-center,.download-card,.portal-v64-title,.portal-v64-quick,.portal-pop,
 .login-card,.auth-card,.login-box,.auth-box,.portal-box,.portal-panel,.saas-card,.saas-notice,.portal-notice,
 .device-card,.support-card,.invoice-card,.order-card,.portal-accordion,.portal-new-ticket,.stat,.kpi,
 .quota-saas-grid>div,.release-meta>div,.portal-invoice-summary>div,.portal-invoice-row,.profile-collapse,
 .profile-collapse-body,.setup-guide,.setup-step,.setup-note,.transfer-form,.email-license-note,.quota-overview,.premium-quota
) :where(p,small,.muted,td){color:#607187!important;-webkit-text-fill-color:#607187!important}

/* Portal header */
html[data-theme="light"] body.castlance-portal-v8 .topbar{background:rgba(255,255,255,.97)!important;border-bottom:1px solid #dbe4ee!important;box-shadow:0 6px 22px rgba(19,39,69,.075)!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .topbar :where(.brand,b,a,button){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .topbar .brand small{color:#2d67e8!important;-webkit-text-fill-color:#2d67e8!important}
html[data-theme="light"] body.castlance-portal-v8 .topbar .secure{color:#087553!important;-webkit-text-fill-color:#087553!important}
html[data-theme="light"] body.castlance-portal-v8 .topbar .logout{color:#b4233f!important;-webkit-text-fill-color:#b4233f!important}
html[data-theme="light"] body.castlance-portal-v8 :where(.langs,.portal-bell summary,.portal-theme-toggle,.portal-menu-btn){background:#f1f5f9!important;border-color:#d6e0ea!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .langs a{color:#61738a!important;-webkit-text-fill-color:#61738a!important}
html[data-theme="light"] body.castlance-portal-v8 .langs a.on{background:#fff!important;color:#102033!important;-webkit-text-fill-color:#102033!important}

/* Hero/license no longer stays in dark mode. */
html[data-theme="light"] body.castlance-portal-v8 .hero-license{
  background:linear-gradient(135deg,#ffffff,#eef4ff 68%,#f4efff)!important;background-color:#fff!important;
  border-color:#cad9ee!important;color:#102033!important;box-shadow:0 16px 40px rgba(19,39,69,.085)!important;
}
html[data-theme="light"] body.castlance-portal-v8 .hero-license :where(h1,h2,h3,h4,b,strong,label,code,span){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .hero-license :where(p,small){color:#607187!important;-webkit-text-fill-color:#607187!important}
html[data-theme="light"] body.castlance-portal-v8 .license-code{background:#f7f9fc!important;border-color:#d6e1ed!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .copy{background:#fff!important;border-color:#cad7e5!important;color:#1f3854!important;-webkit-text-fill-color:#1f3854!important}

/* Nested portal surfaces */
html[data-theme="light"] body.castlance-portal-v8 :where(.row,.portal-accordion-body,.portal-chat,.support-thread,.release-meta>span,.quota-note){
  background:#f7f9fc!important;background-color:#f7f9fc!important;border-color:#e0e8f0!important;color:#102033!important;
}
html[data-theme="light"] body.castlance-portal-v8 .quota-saas-grid .quota-remaining{background:#ecf9f4!important;border-color:#bfe7d8!important;color:#075f48!important}
html[data-theme="light"] body.castlance-portal-v8 .quota-saas-grid .quota-remaining :where(b,span,small){color:#075f48!important;-webkit-text-fill-color:#075f48!important}
html[data-theme="light"] body.castlance-portal-v8 .email-license-note{background:#eef5ff!important;border-color:#cdddf1!important;color:#47617e!important;-webkit-text-fill-color:#47617e!important}

/* Support and notifications */
html[data-theme="light"] body.castlance-portal-v8 .chat-bubble{background:#e9eef5!important;border-color:#d6e0ea!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .chat-bubble.customer{background:#dce9ff!important;border-color:#c5d9f7!important;color:#173b72!important}
html[data-theme="light"] body.castlance-portal-v8 .chat-bubble :where(b,p,small,span){color:inherit!important;-webkit-text-fill-color:currentColor!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-pop{background:#fff!important;box-shadow:0 20px 50px rgba(20,40,70,.16)!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-pop a{background:#f1f5f9!important;color:#23466f!important;-webkit-text-fill-color:#23466f!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mark-all{color:#2d67e8!important;-webkit-text-fill-color:#2d67e8!important}
html[data-theme="light"] body.castlance-portal-v8 .support{background:linear-gradient(135deg,#eef5ff,#f7f4ff)!important;color:#102033!important}

/* Form controls */
html[data-theme="light"] body.castlance-portal-v8 :where(input:not([type="checkbox"]):not([type="radio"]),select,textarea,option){
  background:#fff!important;background-color:#fff!important;color:#102033!important;-webkit-text-fill-color:#102033!important;border-color:#cad7e5!important;caret-color:#102033!important;box-shadow:none!important;
}
html[data-theme="light"] body.castlance-portal-v8 :where(input,textarea)::placeholder{color:#8190a3!important;-webkit-text-fill-color:#8190a3!important;opacity:1!important}
html[data-theme="light"] body.castlance-portal-v8 input:-webkit-autofill{-webkit-box-shadow:0 0 0 1000px #fff inset!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 label.check{background:#f7f9fc!important;border-color:#d6e1ed!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 label.check input[type="checkbox"]{background:#d9e2ed!important;border-color:#bdcbd9!important}
html[data-theme="light"] body.castlance-portal-v8 label.check input[type="checkbox"]::after{background:#fff!important;box-shadow:0 1px 3px rgba(20,40,70,.20)!important}
html[data-theme="light"] body.castlance-portal-v8 label.check input[type="checkbox"]:checked{background:linear-gradient(135deg,#477bf4,#7657ed)!important;border-color:transparent!important}

/* Tables */
html[data-theme="light"] body.castlance-portal-v8 :where(table,thead,tbody,tr,td,th){border-color:#dbe4ee!important}
html[data-theme="light"] body.castlance-portal-v8 :where(thead,th){background:#f1f5f9!important;background-color:#f1f5f9!important;color:#31445a!important;-webkit-text-fill-color:#31445a!important}
html[data-theme="light"] body.castlance-portal-v8 :where(tbody,tr,td){background:#fff!important;background-color:#fff!important}

/* Portal buttons */
html[data-theme="light"] body.castlance-portal-v8 .btn:not(.primary){background:#fff!important;border-color:#cad7e5!important;color:#1f3854!important;-webkit-text-fill-color:#1f3854!important}
html[data-theme="light"] body.castlance-portal-v8 .btn.soft{background:#eef4ff!important;border-color:#d8e5ff!important;color:#1d4ed8!important;-webkit-text-fill-color:#1d4ed8!important}
html[data-theme="light"] body.castlance-portal-v8 .btn.primary{color:#fff!important;-webkit-text-fill-color:#fff!important}

/* Login */
html[data-theme="light"] body.castlance-portal-v8 .login-shell{background:radial-gradient(circle at 50% 0,#e8f0fb 0,#f5f7fb 52%,#eef3f8 100%)!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .login-note{background:#f7f9fc!important;border-color:#dbe4ee!important;color:#607187!important}

/* Mobile portal drawer */
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-nav{background:#fff!important;background-color:#fff!important;border-color:#dbe4ee!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-head{background:#fff!important;border-color:#dbe4ee!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-head :where(b,small){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-head small{color:#2d67e8!important;-webkit-text-fill-color:#2d67e8!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-nav :where(a,b,button){color:#102033!important;-webkit-text-fill-color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-group{background:#f7f9fc!important;border-color:#e0e7ef!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-group>span{color:#607187!important;-webkit-text-fill-color:#607187!important}
html[data-theme="light"] body.castlance-portal-v8 :where(.portal-mobile-theme-toggle,.portal-mobile-close){background:#f1f5f9!important;border-color:#d6e0ea!important;color:#102033!important}
html[data-theme="light"] body.castlance-portal-v8 .portal-mobile-logout{color:#b4233f!important;-webkit-text-fill-color:#b4233f!important}

@media(max-width:900px){body.castlance-portal-v8 .portal-theme-toggle{display:none!important}}
@media(min-width:901px){body.castlance-portal-v8 .portal-theme-toggle{display:grid!important}}
