/* Shared production theme layer. Page styles keep their composition; this file supplies one
   exact neutral hierarchy and repairs legacy dark-only surfaces at the theme boundary. */
html[data-theme="light"] {
  color-scheme: light;
  --bg: #FFFFFF !important;
  --screen: #FFFFFF !important;
  --surface: #F7F7F7 !important;
  --surface-2: #FFFFFF !important;
  --surface2: #FFFFFF !important;
  --surface3: #F7F7F7 !important;
  --panel: #F7F7F7 !important;
  --panel2: #FFFFFF !important;
  --panel3: #F7F7F7 !important;
  --card: #F7F7F7 !important;
  --card2: #FFFFFF !important;
  --card-2: #FFFFFF !important;
  --sidebar-bg: #F7F7F7 !important;
  --sidebar-item: #FFFFFF !important;
  --input-bg: #FFFFFF !important;
  --text: #4B4B4B !important;
  --ink: #4B4B4B !important;
  --muted: #777777 !important;
  --muted2: #AFAFAF !important;
  --disabled: #AFAFAF !important;
  --border: #E5E5E5 !important;
  --border-solid: #E5E5E5 !important;
  --line: #E5E5E5 !important;
  --line2: #E5E5E5 !important;
  --hair: #E5E5E5 !important;
  --hair-strong: #D7D7D7 !important;
  --hair2: #D7D7D7 !important;
  --accent: #F59E0B !important;
  --accent-text: #B45309 !important;
  --accent2: #D97706 !important;
  --amber: #F59E0B !important;
  --amber2: #D97706 !important;
  --amber-soft: rgba(245, 158, 11, .12) !important;
  --amber-line: rgba(180, 83, 9, .38) !important;
  --btn-bg: #F59E0B !important;
  --btn-text: #2B1A02 !important;
  --seg-bg: #F7F7F7 !important;
  --seg-active-bg: rgba(245, 158, 11, .12) !important;
  --seg-active-color: #B45309 !important;
  --faint: #AFAFAF !important;
  --ma-bg: #FFFFFF !important;
  --ma-bg-profile: #FFFFFF !important;
  --ma-card: #F7F7F7 !important;
  --ma-card-solid: #F7F7F7 !important;
  --ma-panel: #F7F7F7 !important;
  --ma-panel-2: #FFFFFF !important;
  --ma-sheet: #FFFFFF !important;
  --ma-menu: #FFFFFF !important;
  --ma-text: #4B4B4B !important;
  --ma-muted: #777777 !important;
  --ma-muted-2: #AFAFAF !important;
  --ma-hair: #E5E5E5 !important;
  --ma-hair-soft: #EEEEEE !important;
  --ma-amber: #F59E0B !important;
  --ma-amber-bright: #D97706 !important;
  --ma-amber-top: #FBBF24 !important;
  --ma-amber-active: #B45309 !important;
  --ma-ink: #2B1A02 !important;
}
html[data-theme="dark"] { color-scheme: dark; }
html[data-theme="light"],
html[data-theme="light"] body { background-color: #FFFFFF; color: #4B4B4B; }
html[data-theme="light"] :is(input,textarea,select)::placeholder { color: #777777 !important; opacity: 1; }

/* Keep filled controls unmistakably Learnara amber. Small amber copy uses dark amber for
   contrast on Snow/Polar instead of making the shared fill token brown. */
html[data-theme="light"][data-theme-page="marketing"] :is(.nav-logo span,.section-tag,.f-num,.hero-topic,.login-toggle a),
html[data-theme="light"][data-theme-page="subject"] :is(.nav-logo .brand-a,.hero h1 em,.stem-demo-field,.section-tag,.fc-formula,.faq summary::after,.accent,.footer-logo .brand-a),
html[data-theme="light"][data-theme-page="generate"] :is(.nav-logo span,.nav-chip-key,.nav-level-num,.ph-level-num,.ph-pts,.lb-name.is-you,.acct-subject,.mm-hero-line .pts,.mm-nextup-eyebrow span,.fav-btn.starred,.status a,.disc-tab.active,.fy-change-btn,.main .z-kicker,.main .z-support-link,.main .z-flag,.prem-sub),
html[data-theme="light"][data-theme-page="study"] :is(.nav-chip-key,.phead .eyebrow,.paste a,.contents-head .src a,.plabel,.sec.open .stitle,.lgen,.docchip .exp,.tool-tab.active,.tool-body .score .big,.tool-body .test-q .qn .qi,.prem-sub,.ph-level-num,.ph-pts),
html[data-theme="light"][data-theme-page="profile"] :is(.profile-provider,.subject-badge,.section-icon),
html[data-theme="light"][data-theme-page="account"] :is(a:not(.create-acct-cta),.toggle-mode a,.back,.back-link a),
html[data-theme="light"][data-theme-page="legal"] a,
html[data-theme="light"][data-theme-page="commerce"] :is(.checkout-logo b,.logo b),
html[data-theme="light"][data-theme-page="delete-account"] .brand .a,
html[data-theme="light"][data-theme-page="onboarding"] .signin b { color: #B45309 !important; }

/* Marketing subject pages use a cinematic dark-only backdrop outside their token map. */
html[data-theme="light"][data-theme-page="subject"] body::after { content: none !important; }
html[data-theme="light"][data-theme-page="subject"] #stars,
html[data-theme="light"][data-theme-page="subject"] .pglow,
html[data-theme="light"][data-theme-page="subject"] .cursor-glow { display: none !important; }
html[data-theme="light"][data-theme-page="subject"] nav.scrolled { background: rgba(255,255,255,.94) !important; border-bottom-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="subject"] .nav-logo,
html[data-theme="light"][data-theme-page="subject"] .footer-logo,
html[data-theme="light"][data-theme-page="subject"] .promobar-txt,
html[data-theme="light"][data-theme-page="subject"] .promobar-txt b { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="subject"] .nav-cta { background: #F59E0B !important; color: #2B1A02 !important; }
html[data-theme="light"][data-theme-page="subject"] .promobar::before { background: #F7F7F7 !important; }
html[data-theme="light"][data-theme-page="subject"] .shimmer { background-image: linear-gradient(90deg,#92400E,#D97706,#B45309,#F59E0B,#B45309,#D97706,#92400E) !important; }
html[data-theme="light"][data-theme-page="subject"] :is(.goals-tabs,.goals-left,.course,.tp,.subj-pill) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="subject"] :is(.goals-right,.course-thumb) { background: #FFFFFF !important; border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="subject"] .goals-card { border-color: #E5E5E5 !important; box-shadow: none !important; }
html[data-theme="light"][data-theme-page="subject"] :is(.gtab:hover,.gtab.active) { background: #FFFFFF !important; color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="subject"] .goals-more { border-bottom-color: #AFAFAF !important; }
html[data-theme="light"][data-theme-page="subject"] #playWaitOverlay { background: rgba(75,75,75,.35) !important; }
html[data-theme="light"][data-theme-page="subject"] #playWaitCard { background: #F7F7F7 !important; border-color: #E5E5E5 !important; box-shadow: none !important; }
html[data-theme="light"][data-theme-page="subject"] :is(.ap-soon-title,.ap-input) { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="subject"] :is(.ap-soon-sub,.ap-done) { color: #777777 !important; }
html[data-theme="light"][data-theme-page="subject"] .ap-input { background: #FFFFFF !important; border-color: #E5E5E5 !important; }

/* Commerce and account deletion were authored as isolated dark documents. */
html[data-theme="light"][data-theme-page="commerce"] body,
html[data-theme="light"][data-theme-page="delete-account"] body { background: #FFFFFF !important; color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="commerce"] body::after { content: none !important; }
html[data-theme="light"][data-theme-page="commerce"] :is(.checkout-card,.cancel-card,.summary-card,.card),
html[data-theme="light"][data-theme-page="delete-account"] .card { background: #F7F7F7 !important; border-color: #E5E5E5 !important; box-shadow: none !important; }
html[data-theme="light"][data-theme-page="delete-account"] :is(input[type=email],input[type=password]) { background: #FFFFFF !important; color: #4B4B4B !important; border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="delete-account"] .warn p { color: #7A3B3D !important; }

/* Legal documents are older light-only pages; retain that clean paper in light and add dark below. */
html[data-theme="light"][data-theme-page="legal"] body { background: #FFFFFF !important; color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="legal"] :is(.nav-logo,h1,h2,h3,strong,.provider-name) { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="legal"] :is(p,li,.notice) { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="legal"] :is(.nav-back,.last-updated,.provider-purpose) { color: #777777 !important; }
html[data-theme="light"][data-theme-page="legal"] :is(.divider,.provider-row,th,td) { border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="legal"] :is(.notice,.callout) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; }
html[data-theme="dark"][data-theme-page="legal"] body { background: #16161A !important; color: #F2F0EC !important; }
html[data-theme="dark"][data-theme-page="legal"] :is(.nav-logo,h1,h2,h3,strong,.provider-name) { color: #F2F0EC !important; }
html[data-theme="dark"][data-theme-page="legal"] :is(.nav-back,.last-updated,p,li,.provider-purpose) { color: #AFAFBA !important; }
html[data-theme="dark"][data-theme-page="legal"] :is(section,.section) { border-color: rgba(255,255,255,.1) !important; }
html[data-theme="dark"][data-theme-page="legal"] a { color: #F59E0B !important; }
html[data-theme="dark"][data-theme-page="legal"] :is(.notice,.callout) { background: #222228 !important; border-color: rgba(255,255,255,.1) !important; color: #AFAFBA !important; }
html[data-theme="dark"][data-theme-page="legal"] :is(.divider,.provider-row,th,td) { border-color: rgba(255,255,255,.1) !important; }

/* Onboarding host + renderer. Dark miniature device art remains an intentional illustration. */
html[data-theme="light"][data-theme-page="onboarding"] body,
html[data-theme="light"][data-theme-page="onboarding"] :is(#frameWrap,#win,#obFrame,#stage,.screen) { background: #FFFFFF !important; color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="onboarding"] :is(.gitem,.option,.choice,.card) { background-color: #F7F7F7 !important; border-color: #E5E5E5 !important; }
/* The renderer's art tiles use a late dark gradient shorthand, so overriding only
   background-color leaves that image painted on top. Replace the complete surface. */
html[data-theme="light"][data-theme-page="onboarding"] .grid.art .gitem {
  background: #F7F7F7 !important;
  border-color: #E5E5E5 !important;
  box-shadow: 0 2px 0 #E5E5E5 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .grid.art .gitem .gic {
  background: transparent !important;
  border-color: transparent !important;
  filter: drop-shadow(0 5px 5px rgba(75,75,75,.12)) !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .grid.art .gitem .glbl { color: #4B4B4B !important; }
/* One selected-answer material across every onboarding question. Keep this after
   the neutral art-card reset so list rows, label grids, subjects, and branches all
   receive the same translucent amber treatment on desktop and mobile web. */
html[data-theme="light"][data-theme-page="onboarding"] .opt.sel,
html[data-theme="light"][data-theme-page="onboarding"] .grid .gitem.sel {
  background: linear-gradient(180deg,#FFF4D8 0%,#FFE7B0 100%) !important;
  border-color: #D97706 !important;
  box-shadow: 0 2px 0 rgba(180,83,9,.26), 0 8px 18px rgba(180,83,9,.10) !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .opt.sel .lbl,
html[data-theme="light"][data-theme-page="onboarding"] .grid .gitem.sel .glbl {
  color: #7C4A03 !important;
  font-weight: 700 !important;
}
/* Curriculum previews are content cards, not dark-mode device mockups. */
html[data-theme="light"][data-theme-page="onboarding"] :is(.hero-anim.toc,.hero-anim.levelmap,.hero-anim.studytools) {
  background: #F7F7F7 !important;
  box-shadow: inset 0 0 0 1px #E5E5E5 !important;
}
/* These two question heroes contain graphite SVG presentation attributes for
   dark mode. Repaint only those shapes in light mode; the amber illustration
   details remain intact and the dark artwork is unchanged. */
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="The aha moment"] [fill="#1F1E24"] {
  fill: #FFF4D8 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="The aha moment"] [stroke="#F2F0EC"] {
  stroke: #B45309 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="The aha moment"] [stroke="#8A8A99"] {
  stroke: #777777 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="Other learning apps on a phone"] [fill="#1F1E24"] {
  fill: #FFFFFF !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="Other learning apps on a phone"] > rect:first-child {
  fill: #FFF9ED !important;
  stroke: #B45309 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="Other learning apps on a phone"] [fill="#8A8A99"] {
  fill: #777777 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .hero svg[aria-label="Other learning apps on a phone"] [stroke="#8A8A99"] {
  stroke: #777777 !important;
}
html[data-theme="light"][data-theme-page="onboarding"] .lmr-band:not(.active) { color: #777777 !important; }
html[data-theme="light"][data-theme-page="onboarding"] .lmr-band:not(.active) .lmr-tick { background: #D7D7D7 !important; }
html[data-theme="light"][data-theme-page="onboarding"] .lmr-item { border-bottom-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="onboarding"] .lmr-t { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="onboarding"] :is(.progress,.loader-bar) { background: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="onboarding"] :is(.opt-icon,.loader-card,.np-alert,.np-btn) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="onboarding"] :is(.np-title,.np-btn) { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="onboarding"] .headline { color: #4B4B4B !important; }

/* Brilliant-style light announcement strip: a continuous edge-to-edge pastel
   field, centered dark-violet copy, and a simple underlined action. */
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar {
  background: #F8EAF5 !important;
  border-bottom: 1px solid rgba(76,29,149,.10) !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar::before {
  background: linear-gradient(90deg,#E7ECFF 0%,#F0E8FF 27%,#FCE7F3 56%,#FFE9EA 76%,#FFF2DE 100%) !important;
  -webkit-mask-image: none !important;
  mask-image: none !important;
  box-shadow: none !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-inner {
  width: 100% !important;
  max-width: none !important;
  min-height: 42px !important;
  padding: 4px 24px !important;
  gap: 10px !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-gem {
  width: 22px !important;
  height: 22px !important;
  filter: drop-shadow(-3px 2px 0 rgba(124,58,237,.24)) drop-shadow(3px 2px 0 rgba(56,189,248,.22)) !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-txt {
  color: #31205F !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  letter-spacing: -.2px !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-txt b {
  color: #31205F !important;
  font-weight: 900 !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-cta {
  padding: 0 !important;
  background: none !important;
  background-image: none !important;
  -webkit-background-clip: border-box !important;
  background-clip: border-box !important;
  -webkit-text-fill-color: #4C1D95 !important;
  color: #4C1D95 !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  line-height: 1.2 !important;
  letter-spacing: -.2px !important;
  text-decoration: underline !important;
  text-decoration-color: #7C3AED !important;
  text-decoration-thickness: 2px !important;
  text-underline-offset: 4px !important;
  animation: none !important;
  filter: none !important;
}
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .android-app-banner-close { color: #595959 !important; }
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .android-app-banner .promobar-inner {
  min-height: 42px !important;
  padding: 4px 12px !important;
  gap: 8px !important;
}

@media (max-width:560px) {
  html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-inner {
    min-height: 42px !important;
    padding: 4px 12px !important;
    gap: 6px !important;
  }
  html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) :is(.promobar-txt,.promobar-cta) {
    font-size: 12.5px !important;
  }
  html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"],[data-theme-page="subject"]) .promobar-gem {
    width: 18px !important;
    height: 18px !important;
  }
}

/* Replace legacy cream light variants in the authenticated web app. */
html[data-theme="light"][data-theme-page="generate"] .prem-card,
html[data-theme="light"][data-theme-page="study"] .prem-card { background: #F7F7F7 !important; border-color: #E5E5E5 !important; box-shadow: none !important; }
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"]) .paywall-overlay,
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"]) .paywall-overlay::before { background: #FFFFFF !important; }
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"]) :is(.paywall-plan,.paywall-plan.selected) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; }
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"]) :is(.pw-headline,.pw-plan-price,.pw-feat,.pw-note) { color: #4B4B4B !important; }
html[data-theme="light"]:is([data-theme-page="generate"],[data-theme-page="study"]) :is(.pw-sub,.pw-plan-label,.pw-price-per,.pw-plan-period,.paywall-trial,.pw-footer) { color: #777777 !important; }
html[data-theme="light"][data-theme-page="generate"] .lb-list-fade { background: linear-gradient(to bottom,transparent,#FFFFFF) !important; }
html[data-theme="light"][data-theme-page="generate"] #discPopular {
  --lh-line: #E5E5E5 !important;
  --lh-soft: #565656 !important;
  --lh-ink: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-skeleton {
  --lh-skel-base: #E5E5E5 !important;
  --lh-skel-glint: #FFF0D2 !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-card,.lh-branch-card,.lh-empty-card) {
  background: #F7F7F7 !important;
  border-color: #E5E5E5 !important;
  box-shadow: 0 3px 0 #E5E5E5 !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-change-subject,.lh-arrow,.lh-settings,.lh-action.secondary,.lh-branch-switch,.lh-mobile-search,.lh-setting-menu,.lh-stepper button,.lh-search-back,.lh-count) {
  background: #FFFFFF !important;
  border-color: #E5E5E5 !important;
  box-shadow: 0 2px 0 #E5E5E5 !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-skel-subject,.lh-skel-settings,.lh-mobile-search) {
  background-color: #FFFFFF !important;
  border-color: #E5E5E5 !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-hello,.lh-topic-desc,.lh-topic-meta,.lh-setting-copy small,.lh-branch-head p,.lh-branch-head > span,.lh-switch-copy span,.lh-mobile-search p,.lh-empty p) { color: #565656 !important; }
html[data-theme="light"][data-theme-page="generate"] :is(.lh-change-subject,.lh-topic-title,.lh-unit,.lh-setting-value,.lh-branch-head h2,.lh-switch-copy b,.lh-mobile-search b,.lh-setting-row,.lh-stepper,.lh-stepper button) { color: #3F3F3F !important; }
html[data-theme="light"][data-theme-page="generate"] :is(.lh-setting-lock,.lh-stepper strong) { color: #7C4A03 !important; }
html[data-theme="light"][data-theme-page="generate"] :is(.lh-change-chev,.lh-setting-chev,.lh-search-orb) { background: rgba(245,158,11,.12) !important; color: #B45309 !important; box-shadow: none !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-setting-wrap + .lh-setting-wrap,
html[data-theme="light"][data-theme-page="generate"] .lh-setting-row { border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-setting-row:is(:hover,.active) { background: rgba(245,158,11,.12) !important; color: #B45309 !important; }
/* The map's return control used a 7px black spread shadow as an outer shell.
   On Snow that read as two misaligned pills, so light mode gets one clean,
   tactile cream control instead. */
html[data-theme="light"][data-theme-page="generate"] .fym-home-back {
  min-height: 42px !important;
  padding: 0 15px 0 12px !important;
  background: linear-gradient(180deg,#FFFFFF 0%,#FFF9ED 100%) !important;
  border: 1.5px solid #D6A34D !important;
  color: #92400E !important;
  box-shadow: 0 2px 0 #D6A34D, 0 8px 18px rgba(75,75,75,.10) !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  transition: background .15s ease,border-color .15s ease,box-shadow .15s ease,transform .1s ease !important;
}
html[data-theme="light"][data-theme-page="generate"] .fym-home-back:hover {
  background: linear-gradient(180deg,#FFFDF8 0%,#FFF0D2 100%) !important;
  border-color: #B45309 !important;
  box-shadow: 0 2px 0 #B45309, 0 10px 20px rgba(180,83,9,.12) !important;
}
html[data-theme="light"][data-theme-page="generate"] .fym-home-back:active {
  transform: translateY(1px) !important;
  box-shadow: 0 1px 0 #B45309, 0 5px 12px rgba(180,83,9,.10) !important;
}
html[data-theme="light"][data-theme-page="generate"] .fym-home-back:focus-visible {
  outline: 3px solid rgba(180,83,9,.22) !important;
  outline-offset: 3px !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-action.secondary {
  background: linear-gradient(180deg,#FFFDF8,#FFF0D2) !important;
  border-color: #D6A34D !important;
  color: #3A2C14 !important;
  box-shadow: 0 3px 0 #D6A34D, 0 8px 16px rgba(180,83,9,.10) !important;
  font-weight: 800 !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-action.secondary:is(:hover,:focus-visible) {
  background: linear-gradient(180deg,#FFF4D8,#FFE7B0) !important;
  color: #92400E !important;
  border-color: #B45309 !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-action.secondary:focus-visible { outline: 3px solid rgba(180,83,9,.22) !important; outline-offset: 3px; }
html[data-theme="light"][data-theme-page="generate"] .lh-arrow.lh-arrow {
  background: #FFF9ED !important;
  border-color: #D6A34D !important;
  color: #92400E !important;
  box-shadow: 0 2px 0 #E8BC69 !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-arrow.lh-arrow:disabled {
  background: #F7F7F7 !important;
  border-color: #D7D7D7 !important;
  color: #6B6B6B !important;
  box-shadow: 0 2px 0 #D7D7D7 !important;
  opacity: 1 !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-count.lh-count {
  background: #FFFFFF !important;
  border-color: #CFCFCF !important;
  color: #3A2C14 !important;
  box-shadow: 0 2px 0 #D7D7D7 !important;
  font-size: 10px !important;
  font-weight: 800 !important;
}
html[data-theme="light"][data-theme-page="generate"][data-mweb] .lh-count.lh-count { font-size: 9px !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-eyebrow { color: #B45309 !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-eyebrow.is-complete { color: #166534 !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-eyebrow.is-sequence-locked { color: #7C4A03 !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-action.primary.is-sequence-locked { background: #F7F7F7 !important; border-color: #E5E5E5 !important; color: #AFAFAF !important; box-shadow: 0 2px 0 #E5E5E5 !important; }

/* The subject and branch pickers are app content, so their dialog and illustrated
   cards follow Snow/Polar rather than retaining the dark presentation surface. */
html[data-theme="light"][data-theme-page="generate"] .lh-subject-overlay { background: rgba(75,75,75,.35) !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-subject-dialog {
  background: #FFFFFF !important;
  border-color: #E5E5E5 !important;
  box-shadow: 0 24px 64px rgba(75,75,75,.18) !important;
}
html[data-theme="light"][data-theme-page="generate"] .lh-subject-dialog-head { border-bottom-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-subject-dialog-head small { color: #B45309 !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-subject-dialog-head h2 { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="generate"] :is(.lh-subject-close,.lh-subject-back) {
  background: #F7F7F7 !important;
  border-color: #E5E5E5 !important;
  color: #6B6B6B !important;
  box-shadow: 0 2px 0 #E5E5E5 !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-subject-close,.lh-subject-back):hover {
  border-color: #D7D7D7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-subject-option,.lh-branch-option) {
  background: radial-gradient(100% 110% at 20% 0,var(--lh-subject-glow,rgba(245,158,11,.08)),transparent 70%),#F7F7F7 !important;
  border-color: #E5E5E5 !important;
  color: #4B4B4B !important;
  box-shadow: 0 2px 0 #E5E5E5 !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-subject-option,.lh-branch-option):hover,
html[data-theme="light"][data-theme-page="generate"] .lh-subject-option.active { border-color: rgba(180,83,9,.38) !important; }
html[data-theme="light"][data-theme-page="generate"] .lh-subject-option.active {
  background: rgba(245,158,11,.12) !important;
  box-shadow: 0 2px 0 rgba(180,83,9,.18) !important;
}
html[data-theme="light"][data-theme-page="generate"] :is(.lh-subject-option,.lh-branch-option) b { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="generate"] :is(.lh-subject-option span:last-child,.lh-branch-option p,.lh-branch-option span) { color: #6B6B6B !important; }

/* Product-tour chrome follows the app theme. The scrim stays translucent so the
   highlighted app context remains legible, while the dialog itself is Snow/Polar. */
html[data-theme="light"] body.visual-tour-active #tourOverlay {
  background: rgba(38,38,38,.52) !important;
}
html[data-theme="light"] #tourBubble {
  background: #FFFFFF !important;
  background-image: none !important;
  border-color: #E5E5E5 !important;
  color: #4B4B4B !important;
  box-shadow: 0 24px 64px rgba(38,38,38,.22), inset 0 1px #FFFFFF !important;
}
html[data-theme="light"] #tourKicker { color: #B45309 !important; }
html[data-theme="light"] #tourTitle { color: #4B4B4B !important; }
html[data-theme="light"] :is(.visual-tour-head,#tourText,#tourVisual,.visual-tour-footer) { background: #FFFFFF !important; }
html[data-theme="light"] #tourText { color: #565656 !important; }
html[data-theme="light"] :is(.visual-tour-progress,#tourStep) { color: #565656 !important; }
html[data-theme="light"] #tourProgressDots i:not(.active) { background: #D7D7D7 !important; }
html[data-theme="light"] :is(#tourSkipBtn,#tourBackBtn) {
  background: #F7F7F7 !important;
  border-color: #E5E5E5 !important;
  color: #4B4B4B !important;
  box-shadow: 0 2px 0 #E5E5E5 !important;
}
html[data-theme="light"] :is(#tourSkipBtn,#tourBackBtn):is(:hover,:focus-visible) {
  border-color: #D7D7D7 !important;
  color: #B45309 !important;
}
html[data-theme="light"] :is(#tourSkipBtn,#tourBackBtn):focus-visible { outline: 3px solid rgba(180,83,9,.22) !important; outline-offset: 2px; }

/* The mobile-app finale is a second dialog, outside #tourBubble. Keep every one of
   its surfaces light in light mode—including both platform panels—so finishing the
   white product tour can never flash the legacy black download card. */
html[data-theme="light"] #appPromoOverlay {
  background: rgba(75,75,75,.42) !important;
}
html[data-theme="light"] #appPromoCard {
  background: #FFFFFF !important;
  border-color: #E5E5E5 !important;
  color: #4B4B4B !important;
  box-shadow: 0 24px 64px rgba(75,75,75,.22) !important;
}
html[data-theme="light"] #appPromoCard .ap-glow {
  background: radial-gradient(circle at 50% 0%,rgba(245,158,11,.14),rgba(245,158,11,.04) 46%,transparent 72%) !important;
}
html[data-theme="light"] #appPromoCard .ap-eyebrow,
html[data-theme="light"] #appPromoCard .ap-soon-pill { color: #B45309 !important; }
html[data-theme="light"] #appPromoCard :is(.ap-title,.ap-soon-title) { color: #4B4B4B !important; }
html[data-theme="light"] #appPromoCard :is(.ap-sub,.ap-soon-sub,.ap-qr-cap) { color: #5F5F5F !important; }
html[data-theme="light"] #appPromoCard .ap-seg {
  background: #F7F7F7 !important;
  border-color: #E5E5E5 !important;
}
html[data-theme="light"] #appPromoCard .ap-seg-btn {
  background: transparent !important;
  color: #4B4B4B !important;
}
html[data-theme="light"] #appPromoCard .ap-seg-btn:not(.active):is(:hover,:focus-visible) {
  background: rgba(245,158,11,.10) !important;
  color: #92400E !important;
}
html[data-theme="light"] #appPromoCard .ap-seg-btn.active {
  background: #F59E0B !important;
  color: #2B1A02 !important;
  box-shadow: 0 3px 0 #B96C08, 0 7px 16px rgba(245,158,11,.22) !important;
}
html[data-theme="light"] #appPromoCard .ap-seg-btn:focus-visible,
html[data-theme="light"] #appPromoCard :is(.ap-store-btn,.ap-primary,.ap-done):focus-visible {
  outline: 3px solid rgba(180,83,9,.24) !important;
  outline-offset: 2px;
}
html[data-theme="light"] #appPromoCard .ap-panel { color: #4B4B4B !important; }
html[data-theme="light"] #appPromoCard .ap-qr {
  background: #FFFFFF !important;
  border: 1px solid #E5E5E5 !important;
  box-shadow: 0 10px 26px rgba(75,75,75,.14) !important;
}
html[data-theme="light"] #appPromoCard .ap-input {
  background: #F7F7F7 !important;
  border-color: #D7D7D7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"] #appPromoCard .ap-input:focus {
  background: #FFFFFF !important;
  border-color: #B45309 !important;
  box-shadow: 0 0 0 3px rgba(180,83,9,.14) !important;
}
html[data-theme="light"] #appPromoCard .ap-input::placeholder { color: #6B6B6B !important; }
html[data-theme="light"] #appPromoCard .ap-note.ok { color: #166534 !important; }
html[data-theme="light"] #appPromoCard .ap-note.err { color: #B91C1C !important; }
html[data-theme="light"] #appPromoCard .ap-done {
  background: #F7F7F7 !important;
  border: 1px solid #E5E5E5 !important;
  border-radius: 12px !important;
  color: #4B4B4B !important;
}
html[data-theme="light"] #appPromoCard .ap-done:hover {
  background: #FFFFFF !important;
  border-color: #D7D7D7 !important;
  color: #92400E !important;
}
/* Learning-path pucks are inline SVGs with dark presentation fills. Semantic SVG
   classes keep locked and completed nodes dimensional without leaving black discs
   on the Snow map. The active node deliberately remains Learnara amber. */
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-ground-outer { fill: rgba(75,75,75,.08) !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-ground-inner { fill: rgba(75,75,75,.12) !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-cap { fill: #D7D7D7 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-body { fill: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-top { fill: #F7F7F7 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-rim,
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-ring { stroke: #D7D7D7 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-shine { fill: #FFFFFF !important; fill-opacity: .72 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.locked .fym-puck-spec { fill: #FFFFFF !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-ground-outer { fill: rgba(180,83,9,.08) !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-ground-inner { fill: rgba(180,83,9,.12) !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-cap { fill: #D6A34D !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-body { fill: #E8BC69 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-top { fill: #FFF0D2 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-tint { fill: #B45309 !important; fill-opacity: .04 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-rim { stroke: #D6A34D !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-ring { stroke: rgba(180,83,9,.30) !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-shine,
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-spec { fill: #FFFFFF !important; fill-opacity: .68 !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-glyph-shadow { stroke: rgba(255,255,255,.72) !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-puck.complete .fym-puck-glyph { stroke: #92400E !important; }
html[data-theme="light"][data-theme-page="generate"] .fym-num { color: #777777 !important; }
html[data-theme="light"][data-theme-page="study"] :is(.acct-dropdown,.cmenu,.nmodal,.support-modal,.sheet-bar,.smenu,.docchip) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; box-shadow: none !important; }
html[data-theme="light"][data-theme-page="study"] :is(.sec .num,.sdesc,.phead p#cSub) { color: #4B4B4B !important; }

/* Study tool launchers are content cards, not dark presentation art. Both the
   uploaded-document panel and lesson dialog share these launcher styles. */
html[data-theme="light"][data-theme-page="study"] .tool-chip {
  background: linear-gradient(180deg,rgba(var(--tool-rgb),.09) 0%,#FFFFFF 68%) !important;
  border-color: #E5E5E5 !important;
  border-top-color: rgba(var(--tool-rgb),.24) !important;
  color: #4B4B4B !important;
  box-shadow: 0 8px 20px rgba(75,75,75,.10), inset 0 1px 0 #FFFFFF !important;
}
html[data-theme="light"][data-theme-page="study"] .tool-chip::before {
  background: radial-gradient(95% 72% at 50% 8%,rgba(var(--tool-rgb),.12),transparent 72%) !important;
}
html[data-theme="light"][data-theme-page="study"] .tool-chip::after {
  background: linear-gradient(90deg,transparent,rgba(var(--tool-rgb),.20),transparent) !important;
}
html[data-theme="light"][data-theme-page="study"] .tool-chip svg {
  filter: drop-shadow(0 7px 7px rgba(75,75,75,.16)) !important;
}
html[data-theme="light"][data-theme-page="study"] .tool-chip-label { color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="study"] .tool-chip:hover {
  border-color: rgba(var(--tool-rgb),.48) !important;
  box-shadow: 0 12px 26px rgba(75,75,75,.14), 0 0 18px rgba(var(--tool-rgb),.08), inset 0 1px 0 #FFFFFF !important;
}
html[data-theme="light"][data-theme-page="study"] :is(.ltool,.ask-panel) {
  background: #FFFFFF !important;
  border-color: #E5E5E5 !important;
  box-shadow: 0 24px 64px rgba(75,75,75,.18) !important;
}
html[data-theme="light"][data-theme-page="study"] :is(.ltool .ask-x,.ask-panel .ask-x):hover {
  background: #F7F7F7 !important;
  color: #4B4B4B !important;
}

/* The Study lesson configurator is dark by default. Give every interactive
   surface a Snow/Polar counterpart without changing the dark-mode component. */
html[data-theme="light"][data-theme-page="study"] .lmodal-backdrop { background: rgba(38,38,38,.38) !important; }
html[data-theme="light"][data-theme-page="study"] .lmodal {
  background: radial-gradient(120% 90px at 50% 0,rgba(245,158,11,.10),transparent 70%),#FFFFFF !important;
  border-color: #E5E5E5 !important;
  color: #4B4B4B !important;
  box-shadow: 0 28px 70px rgba(75,75,75,.20), inset 0 1px 0 #FFFFFF !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal-input {
  background: #FFFFFF !important;
  border-color: #D7D7D7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal-desc { color: #565656 !important; }
html[data-theme="light"][data-theme-page="study"] .lmodal-desc-shim {
  background: linear-gradient(90deg,#EEEEEE 25%,#F7F7F7 37%,#EEEEEE 63%) !important;
  background-size: 400% 100% !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal .seg-btn {
  background: #F7F7F7 !important;
  border-color: #E5E5E5 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal .seg-btn:hover { border-color: #D6A34D !important; }
html[data-theme="light"][data-theme-page="study"] .lmodal .seg-btn.active {
  background: rgba(245,158,11,.12) !important;
  border-color: rgba(180,83,9,.38) !important;
  color: #B45309 !important;
}
html[data-theme="light"][data-theme-page="study"] :is(.lmlen-chip,.lmlen-menu) {
  background: #FFFFFF !important;
  border-color: #D7D7D7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="study"] :is(.lmlen-row,.toggle-row) { border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="study"] .lm-lenbtn {
  background: #FFFFFF !important;
  border-color: #D7D7D7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="study"] .lm-lenbtn:hover { border-color: #D6A34D !important; }
html[data-theme="light"][data-theme-page="study"] .lm-lenhint { border-color: #E5E5E5 !important; color: #777777 !important; }
html[data-theme="light"][data-theme-page="study"] .toggle-switch {
  background: #E5E5E5 !important;
  border-color: #D7D7D7 !important;
}
html[data-theme="light"][data-theme-page="study"] .toggle-switch::after {
  background: #FFFFFF !important;
  box-shadow: 0 1px 3px rgba(75,75,75,.22) !important;
}
html[data-theme="light"][data-theme-page="study"] .toggle-row.on .toggle-switch {
  background: #F59E0B !important;
  border-color: #D97706 !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal-btn.secondary {
  background: #FFFFFF !important;
  border-color: #D7D7D7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal-btn.secondary:hover {
  background: #FFF9ED !important;
  border-color: #D6A34D !important;
  color: #92400E !important;
}
html[data-theme="light"][data-theme-page="study"] .lmodal-close:hover {
  background: #F7F7F7 !important;
  color: #4B4B4B !important;
}
html[data-theme="light"][data-theme-page="profile"] nav { background: rgba(255,255,255,.94) !important; border-color: #E5E5E5 !important; }
html[data-theme="light"][data-theme-page="profile"] :is(.stat-card.premium,.plan-badge.pro) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; box-shadow: none !important; }
html[data-theme="light"][data-theme-page="profile"] .stat-card.premium::before { content: none !important; }
html[data-theme="light"][data-theme-page="profile"] .stat-card.premium .stat-number { background: none !important; color: #4B4B4B !important; -webkit-text-fill-color: #4B4B4B !important; }
html[data-theme="light"][data-theme-page="profile"] .stat-card.premium .stat-label { color: #777777 !important; }
html[data-theme="light"][data-theme-page="profile"] .plan-badge.pro { color: #B45309 !important; }

/* Actual-phone web restyle: stronger selector + important beats the late dark app-parity sheet. */
html[data-theme="light"]:is([data-mpage="gen"],[data-mpage="study"],[data-mpage="profile"]) body,
html[data-theme="light"]:is([data-mpage="gen"],[data-mpage="study"],[data-mpage="profile"]) nav,
html[data-theme="light"]:is([data-mpage="gen"],[data-mpage="study"],[data-mpage="profile"]) #topBar,
html[data-theme="light"]:is([data-mpage="gen"],[data-mpage="study"],[data-mpage="profile"]) #iframeWrap { background-color: #FFFFFF !important; color: #4B4B4B !important; }
html[data-theme="light"][data-mpage="profile"] body { background-image: none !important; }
html[data-theme="light"][data-mpage="profile"] :is(.section,.stat-card:not(.premium),.plan-card,.profile-header) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; }
html[data-theme="light"]:is([data-mpage="gen"],[data-mpage="study"],[data-mpage="profile"]) :is(input,textarea,select) { background-color: #FFFFFF !important; color: #4B4B4B !important; border-color: #E5E5E5 !important; }
html[data-theme="light"][data-mpage="study"] :is(.course,.part,.sec,.nmodal,.ltool,.ask-panel,.ask-msgs .ai,.sheet-wrap,.paper.pdf) { background: #F7F7F7 !important; border-color: #E5E5E5 !important; color: #4B4B4B !important; box-shadow: none !important; }
html[data-theme="light"] :is(.flg-overlay,.flg-card) { background-color: #FFFFFF !important; color: #4B4B4B !important; border-color: #E5E5E5 !important; }

@media (prefers-reduced-motion: reduce) {
  html, body { transition: none !important; }
}
