/* Keep the setup, onboarding and controls on the selected palette. */
html[data-theme="light"] .setup,
html[data-theme="light"] .onboarding {
  background:radial-gradient(620px 440px at 50% 0,rgba(91,138,243,.13),transparent 72%),#f5f9fd!important;
  color:#172538!important;
}
html[data-theme="light"] .setup h1,
html[data-theme="light"] .onboard-stage h1,
html[data-theme="light"] .onboard-brand {color:#172538!important}
html[data-theme="light"] .setup p,
html[data-theme="light"] .onboard-stage p {color:#526276!important}
html[data-theme="light"] .setup input {background:#fff!important;color:#172538!important;border-color:#ccd9e8!important}
html[data-theme="light"] .setup input::placeholder {color:#637286!important;opacity:1}
html[data-theme="light"] .mode-choice,
html[data-theme="light"] .onboard-chip {background:#eaf1f9!important;border-color:#ccd9e8!important;color:#172538!important}
html[data-theme="light"] .mode-btn {color:#30435b!important;background:transparent!important}
html[data-theme="light"] .mode-btn.active {background:#fff!important;color:#13253b!important;border-color:#7cb5d8!important;box-shadow:0 2px 10px rgba(31,63,100,.1)!important}
html[data-theme="light"] .onboard-skip {color:#30435b!important;border-color:#ccd9e8!important;background:#fff!important}
html[data-theme="light"] .onboard-kicker {color:#14788c!important}
html[data-theme="light"] .onboard-progress i {background:#cfdae9!important}
html[data-theme="light"] .onboard-progress i.active {background:#268caa!important}
html[data-theme="light"] #themeBtnSetup {background:#fff!important;color:#172538!important;border:1px solid #ccd9e8!important;box-shadow:0 4px 14px rgba(35,67,99,.12)!important}
html[data-theme="dark"] #themeBtnSetup {background:#12223c!important;color:#eaf3ff!important;border:1px solid #45637e!important}
html[data-theme="light"] .setup button.go,
html[data-theme="light"] .onboard-primary {color:#071923!important}
html[data-theme="light"] .nav-item {color:#496178!important}
html[data-theme="light"] .nav-item.active {background:#e5f1fa!important;color:#173b57!important}
html[data-theme="light"] .nav-item.active .ni {color:#137e98!important}
html[data-theme="light"] .composer #photoBtn,
html[data-theme="light"] .composer #micBtn {background:#eaf2f9!important;color:#24445d!important;border-color:#c6d9e8!important}

/* 2026-09-29: scrolling screens must scroll, not shrink their cards to fit.
   Keep hidden/auth states intact; only visible content gets natural height. */
#mainApp > .panel {min-height:0!important;min-width:0!important}
#dashboard, #tasksList, #lifeList, #profileHub, #familyHub {
  min-height:0!important;
  box-sizing:border-box!important;
  overflow-y:auto!important;
  padding-bottom:calc(150px + env(safe-area-inset-bottom,0px))!important;
  scroll-padding-bottom:calc(150px + env(safe-area-inset-bottom,0px));
}
#dashboard > :not(.hidden),
#tasksList > :not(.hidden),
#lifeList > :not(.hidden),
#profileHub > :not(.hidden),
#familyHub > :not(.hidden) {
  flex:0 0 auto!important;
}
#lifeList .receipt-intel {
  height:auto!important;
  min-height:min-content;
}
html.kairo-android-webview #dashboard,
html.kairo-android-webview #tasksList,
html.kairo-android-webview #lifeList,
html.kairo-android-webview #profileHub,
html.kairo-android-webview #familyHub {
  padding-bottom:150px!important;
}

/* 2026-09-29: calmer personal-assistant surface. Keep existing modules intact,
   but make Today feel like a human brief instead of an AI dashboard. */
#romviLivingBrief{display:block!important;order:-10;padding:22px 20px 18px!important;border:1px solid #d9e7ed!important;border-radius:24px!important;background:#fff!important;color:#183247!important;box-shadow:0 8px 24px rgba(41,79,96,.06)!important}
#romviLivingBrief h2{margin:6px 0 5px!important;font:800 clamp(25px,6vw,34px)/1.08 Manrope,Inter,sans-serif!important;letter-spacing:-.045em!important;color:#173247!important}
#romviLivingBrief>p{margin:0 0 15px!important;color:#647985!important;font-size:13px!important;line-height:1.5!important}
#romviLivingBrief .eyebrow{color:#258b96!important;letter-spacing:.12em!important}
.romvi-brief-items{display:grid;gap:8px;margin:8px 0 14px!important}
.romvi-brief-item{display:flex;align-items:center;gap:10px;padding:10px 11px;border:1px solid #e0ebef;border-radius:14px;background:#f8fbfc}
.romvi-brief-icon{display:grid;place-items:center;width:30px;height:30px;flex:0 0 30px;border-radius:10px;background:#e1f3f3;color:#277e88;font-size:16px}
.romvi-brief-item b{display:block;font-size:12px;color:#19384b}.romvi-brief-item small{display:block;margin-top:2px;color:#6e8089;font-size:10px;line-height:1.35}
.romvi-brief-ask{width:100%;min-height:44px;border:1px solid #b8dce0;border-radius:13px;background:#eff9f9;color:#206975;font:700 12px Inter,sans-serif}
html[data-theme="dark"] #romviLivingBrief{background:#f7fbfc!important;color:#183247!important}
html[data-theme="dark"] #romviLivingBrief *{color:inherit}
html[data-theme="dark"] #romviLivingBrief .eyebrow{color:#258b96!important}
html[data-theme="dark"] #romviLivingBrief>p,.romvi-brief-item small{color:#647985!important}

/* Light metrics use the ROMVI blue/teal palette, never dark overlays. */
html[data-theme="light"] :is(.core60-stat,.work61-stats>div,.metric,.quick-card,.brain-stat,.receipt-metric,.life-overview-stat){
 background:linear-gradient(135deg,#e8f6fc,#edf0ff)!important;
 border:1px solid #cbdfea!important;color:#16354d!important;
}
.core60-pulse,.work61-stats{gap:8px!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}
.core60-stat,.work61-stats>div{min-width:0!important;padding:10px!important;box-sizing:border-box}
.core60-stat b,.work61-stats b{font-size:clamp(14px,3.6vw,21px)!important;overflow-wrap:anywhere}
html[data-theme="light"] :is(.core60-stat span,.work61-stats span,.life-overview-stat span,.receipt-metric span){color:#49677e!important}
html[data-theme="light"] :is(.core60-scope,.work61-scope,.life-engine-count){background:#e5f3fc!important;color:#216080!important;border-color:#bedbe9!important}
html[data-theme="light"] :is(.core60-eyebrow,.life-engine-kicker,.hub-kicker){color:#147c8e!important}


/* 2026-10-04: UX simplification layer — preserve all existing DOM IDs and handlers.
   Today stays the primary brief; secondary modules remain available lower on the page.
   The quick-chip strip duplicates Quick Add on small screens, so hide only that duplicate. */
@media(max-width:760px){
  #dashboard > .dash-hero{order:1!important}
  #dashboard > #core60Card{order:2!important}
  #dashboard > #romviLivingBrief{order:3!important}
  #dashboard > .life-engine-hero{order:4!important}
  #dashboard > .brief-card{order:5!important}
  #dashboard > #work61Card{order:6!important}
  #dashboard > .feature-strip{display:none!important}
}

/* The legacy tab row is an implementation bridge, not a second navigation surface. */
.tabs{display:none!important}
