/* SAWWA.AI 6.1.0 · FOUNDATION / CALM SYSTEM
   One font, five text levels, neutral content surfaces, translucent NAV ONLY.
   Intentionally last stylesheet: overrides legacy editorial experiments. */
:root{
  --ui-bg:#f6f7f9; --ui-surface:#ffffff; --ui-ink:#222b38;
  --ui-muted:#596777; --ui-subtle:#6b7786; --ui-line:#e3e7eb;
  --ui-tint:#f1f3f6; --ui-gold:#986b3b; --ui-gold-hover:#7a5129;
  --ui-focus:#b38b59; --ui-green:#21835a; --ui-red:#be3d47;
  --ui-radius:14px; --ui-shadow:0 4px 20px rgba(30,45,66,.035);
  --ui-font:Inter,"Segoe UI",Arial,sans-serif;
  --cream:var(--ui-bg); --paper:var(--ui-surface);--ink:var(--ui-ink);
  --muted:var(--ui-muted);--gold:var(--ui-gold);--gold-d:var(--ui-gold-hover);
  --border:var(--ui-line);--shadow:var(--ui-shadow);
  color-scheme:light;
}
html,body{font-family:var(--ui-font)!important;font-size:15px;line-height:1.55;background:var(--ui-bg)!important;color:var(--ui-ink)!important;letter-spacing:normal}
body{overflow-wrap:break-word}
:where(button,input,textarea,select){font-family:var(--ui-font)!important;font-size:14px}
:where(button,a,input,textarea,select):focus-visible{outline:2px solid var(--ui-focus)!important;outline-offset:3px!important}
:where(button){transition:background-color .12s ease,border-color .12s ease,color .12s ease}
:where(.page,.main-space,.card,.context-block,.v51-journal-main,.v51-selected-goal){min-width:0}
/* Readability: shared type hierarchy, including all legacy serif headings. */
.page-head h1,.v51-heading h1,.myth-hero h1,.dashboard-hero .myth-hero-copy h1,
.auth-art h1,.auth-v601-art .auth-art-inner h1,.profile-hero h1,
.auth-panel h2,.sawwa-ritual-card h2{font-family:var(--ui-font)!important;font-weight:650!important;font-size:clamp(28px,3vw,34px)!important;line-height:1.2!important;letter-spacing:-.035em!important;font-style:normal!important;color:var(--ui-ink)!important}
.page-head h2,.dashboard-heading h2,.v51-section-title h2,.v51-month,
.v51-detail-head h2,.v51-detail-section-title h3,
.card h2,.section-head h2,.profile-grid .card h2,
.chat-page-head h1,.v51-entry h3,.v51-aside-card h3,
.v51-journal-sidecard strong,.v51-goal-tab strong,
.v51-side-quote p,.v51-aside-quote,.v51-goal-description p,
.v51-hero p,.v51-goal-tab strong,.v51-stat strong,
.v51-progress-label span,.v51-entry-date b{
  font-family:var(--ui-font)!important;font-style:normal!important;font-weight:600!important;
  letter-spacing:-.02em!important;color:var(--ui-ink)!important;
}
.page-head h2,.dashboard-heading h2,.v51-section-title h2,.v51-month,.v51-detail-head h2{font-size:21px!important;line-height:1.32!important}
.card h2,.section-head h2,.profile-grid .card h2,.v51-detail-section-title h3,.v51-aside-card h3,.v51-entry h3{font-size:17px!important;line-height:1.4!important}
.v51-stat strong,.home-stat .stat-number{font-size:28px!important;font-weight:650!important;line-height:1.15!important}
.v51-progress-label span{font-size:20px!important}
.v51-journal-sidecard strong{font-size:22px!important}
.v51-entry-date b{font-size:23px!important}
.v51-goal-tab strong{font-size:15px!important;line-height:1.5!important}
.page-head p,.v51-heading p,.myth-hero p,.dashboard-heading p,
.v51-entry-copy,.v51-goal-description p,.v51-journal-sidecard p,.card p,
.context-block,.chat-bubble,.chat-welcome p,.task-meta,.task-row,
.v51-aside-card p,.v51-side-quote p,.v51-progress-hint,
.v51-entry-body,.profile-muted{font-family:var(--ui-font)!important;font-size:14px!important;line-height:1.55!important;color:var(--ui-muted)!important}
.v51-entry h3,.task-title,.dashboard-next-title,.home-stat strong,.v51-goal-tab strong{color:var(--ui-ink)!important}
.eyebrow,.v51-hero-eyebrow,.v51-goal-status,.v51-goal-tab .v51-goal-status,
.v51-stat span,.v51-field-label,.context-eyebrow,.side-label,
.dashboard-focus-label,.home-stat>span,.v51-label,.v51-entry-meta,
.v51-journal-side .eyebrow,.v51-entry-type,.v51-mini-label{
  font-family:var(--ui-font)!important;font-size:11px!important;font-weight:650!important;
  line-height:1.5!important;letter-spacing:.065em!important;color:var(--ui-subtle)!important;
}
/* Navigation layer is the only place using true translucency. */
.topbar{height:66px!important;padding:0 clamp(16px,2.6vw,38px)!important;background:rgba(255,255,255,.9)!important;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);border-color:var(--ui-line)!important;position:sticky;top:0;z-index:40}
.brand-button{font-family:var(--ui-font)!important;font-size:20px!important;font-weight:750!important;letter-spacing:.16em!important;color:var(--ui-ink)!important}
.dev-tag{font-size:11px!important;background:var(--ui-tint)!important;color:var(--ui-muted)!important;padding:5px 10px!important;letter-spacing:0!important}
.user-chip{color:var(--ui-muted)!important;font-size:12px!important}
.icon-btn{background:var(--ui-tint)!important;color:var(--ui-ink)!important}
.app-layout{grid-template-columns:190px minmax(0,1fr)!important;min-height:calc(100dvh - 66px)!important}
.side-nav{height:calc(100dvh - 66px)!important;padding:18px 12px!important;position:sticky;top:66px;background:rgba(255,255,255,.85)!important;border-color:var(--ui-line)!important;backdrop-filter:blur(12px)}
.side-label{padding:10px 10px 12px!important;font-size:11px!important;letter-spacing:.06em!important}
.nav-button{font-family:var(--ui-font)!important;min-height:45px!important;font-weight:550!important;font-size:14px!important;border-radius:11px!important;padding:10px 12px!important;color:var(--ui-muted)!important}
.nav-button span{font-size:17px!important;color:var(--ui-subtle)}
.nav-button.active{background:#eef0f3!important;color:var(--ui-ink)!important;font-weight:650!important}
.nav-button.active span{color:var(--ui-gold)}
.side-foot{font-size:11px!important;color:var(--ui-muted)!important;line-height:1.55!important;background:transparent!important;border:0!important}
.side-foot small{font-size:11px!important}
.main-space{padding:28px clamp(20px,3.1vw,52px) 48px!important;background:var(--ui-bg)!important;min-width:0}
.page,.v51-page{max-width:1140px!important;margin-left:auto!important;margin-right:auto!important}
.page-head,.v51-heading{margin:0 0 18px!important;align-items:center!important;gap:16px!important}
.page-head h1{margin:2px 0 5px!important}
.page-head .eyebrow{margin:0 0 5px!important}
.app-footer{font-size:11px!important;color:var(--ui-subtle)!important;padding:22px 0 6px!important;text-align:center}
/* Unified surfaces and components */
.card,.home-stat,.plan-card,.context-block,.v51-journal-sidecard,.v51-journal-toolbar,
.v51-entry,.v51-goal-tab,.v51-stat,.v51-aside-card,.v51-selected-goal,.v51-diary-empty,
.profile-grid .card,.conversation-list,.chat-card,.auth-screen,.v51-journal-sidecard,
.v51-unlinked,.v51-side-quote,.dashboard-recent-chat,.v51-diary-job{
  background:var(--ui-surface)!important;border:1px solid var(--ui-line)!important;
  box-shadow:var(--ui-shadow)!important;border-radius:var(--ui-radius)!important;color:var(--ui-ink)!important;
}
.card,.profile-grid .card,.dashboard-columns .card{padding:22px!important}
.primary,.quiet,.filter,.v51-filter,.v51-journal-buttons button,.v51-heading .path-actions button,
.dashboard-next-buttons button,.auth-actions button,.goldButton{
  min-height:42px!important;border-radius:10px!important;font-size:13px!important;font-weight:650!important;
  letter-spacing:0!important;box-shadow:none!important;line-height:1.4!important;
}
.primary,.filter.active,.v51-filter.active{background:var(--ui-gold)!important;color:#fff!important;border:1px solid var(--ui-gold)!important}
.primary:hover{background:var(--ui-gold-hover)!important}
.quiet,.filter,.v51-filter{color:var(--ui-ink)!important;background:#fff!important;border:1px solid var(--ui-line)!important}
.quiet:hover,.filter:hover,.v51-filter:hover{background:var(--ui-tint)!important}
.text-action,.v51-inline-action,.v51-more,.v51-history-link,.context-block .text-action{font-size:13px!important;color:var(--ui-gold)!important;font-weight:600!important}
label{font-size:13px!important;letter-spacing:0!important;font-weight:600!important;color:var(--ui-ink)!important}
label input,label textarea,label select,input[type=search],#messageText,#heroMessage{
  background:var(--ui-surface)!important;color:var(--ui-ink)!important;border-color:var(--ui-line)!important;
  font-family:var(--ui-font)!important;font-size:14px!important;min-height:42px;line-height:1.5!important;
}
::placeholder{color:#647181!important;opacity:1}
/* Home: simple greeting, no repeated large hero illustration */
#homeView .myth-hero,#profileView .myth-hero{
  min-height:152px!important;height:auto!important;padding:24px 30px!important;margin-bottom:24px!important;
  background:linear-gradient(110deg,#fff,#f2f4f6)!important;
  border:1px solid var(--ui-line)!important;border-radius:var(--ui-radius)!important;box-shadow:none!important;
}
#homeView .myth-hero::after,#profileView .myth-hero::after{background:none!important}
#homeView .myth-hero img,#profileView .myth-hero img{display:none!important}
#homeView .myth-hero .myth-hero-copy,#profileView .myth-hero .myth-hero-copy{max-width:100%!important}
#homeView .myth-hero h1,#profileView .myth-hero h1{font-size:30px!important;margin:6px 0 8px!important}
#homeView .myth-hero p,#profileView .myth-hero p{max-width:580px!important}
.hero-motto,.myth-hero .hero-motto{border:0!important;background:transparent!important;color:var(--ui-gold)!important;padding:8px 0 0!important;font-size:12px!important}
.dashboard-heading{margin:0 0 14px!important}
.dashboard-heading h2{margin:2px 0 6px!important}
.dashboard-stats{gap:12px!important;margin-bottom:14px!important}
.dashboard-stats .home-stat{padding:17px 18px!important;min-height:106px!important}
.dashboard-stats .home-stat strong{font-weight:650!important;font-size:16px!important;line-height:1.4!important}
.dashboard-columns{grid-template-columns:minmax(0,1.5fr) minmax(270px,1fr)!important;gap:14px!important}
.dashboard-columns .section-head{margin-bottom:14px!important}
.dashboard-columns .section-head h2{font-size:17px!important}
.dashboard-focus-card{background:var(--ui-surface)!important}
.dashboard-next-title{font-size:17px!important;font-weight:650!important}
.dashboard-focus-label{margin:2px 0 9px!important}
.dashboard-composer{border-color:var(--ui-line)!important;background:var(--ui-surface)!important}
.dashboard-task-card .task-row{padding:12px 0!important}
/* Path, diary: remove the opaque dark strips. The classical motif is now a light annotation. */
.v51-page{--v51-bg:var(--ui-surface);--v51-border:var(--ui-line);--v51-ink:var(--ui-ink);--v51-muted:var(--ui-muted);--v51-gold:var(--ui-gold);--v51-soft:var(--ui-tint);--v51-shadow:var(--ui-shadow)}
.v51-page .v51-hero{
  isolation:isolate;display:flex!important;align-items:center!important;min-height:100px!important;
  padding:20px 24px!important;margin:0 0 18px!important;border-radius:var(--ui-radius)!important;
  background:linear-gradient(108deg,#fff 0%,#f5f6f8 100%)!important;color:var(--ui-ink)!important;
  border:1px solid var(--ui-line)!important;box-shadow:none!important;
}
.v51-page .v51-hero::before{opacity:1!important;z-index:0!important;background:none!important}
.v51-page .v51-hero::after{content:'Ω';display:block!important;position:absolute!important;inset:auto 25px 0 auto!important;
  z-index:0!important;font:500 79px/1 var(--ui-font)!important;letter-spacing:-.06em;color:rgba(152,107,59,.085)!important;
  background:none!important;pointer-events:none}
.v51-page .v51-hero img{display:none!important}
.v51-page .v51-hero-text{position:relative!important;z-index:1!important;max-width:100%!important;padding:0!important}
.v51-page .v51-hero-eyebrow{display:block!important;font-size:11px!important;color:var(--ui-gold)!important;letter-spacing:.04em!important}
.v51-page .v51-hero p{margin:5px 0 0!important;font-size:16px!important;line-height:1.45!important;font-weight:500!important;color:var(--ui-ink)!important}
.v51-page .v51-hero-sub{color:var(--ui-muted)!important;font-size:12px!important;margin-top:4px!important}
.v51-path-stats{gap:12px!important;margin:0 0 22px!important}
.v51-stat{min-height:96px!important;padding:14px 17px!important;gap:4px!important}
.v51-stat small{font-size:12px!important;color:var(--ui-muted)!important}
.v51-goal-picker{gap:12px!important;margin-bottom:13px!important}
.v51-goal-tab{flex-basis:clamp(210px,30%,284px)!important;min-height:122px!important;padding:16px!important;gap:7px!important}
.v51-goal-tab.selected{background:#f5f2ed!important;border-color:#c6a47f!important;box-shadow:0 0 0 1px #c6a47f inset!important}
.v51-goal-tab small{font-size:12px!important}
.v51-goal-meter,.v51-progress-track{height:6px!important;background:var(--ui-line)!important}
.v51-goal-meter-fill,.v51-progress-fill{background:var(--ui-gold)!important}
.v51-path-layout{gap:14px!important}
.v51-selected-goal{padding:23px!important}
.v51-detail-head{margin:4px 0 13px!important}
.v51-goal-description{background:#f7f8fa!important;border-color:var(--ui-line)!important;margin:14px 0!important}
.v51-progress-hint{font-size:12px!important}
.v51-step .task-title{font-size:14px!important;line-height:1.45!important}
.v51-aside-card{padding:20px!important}
.v51-aside-card h3{margin:6px 0!important}
.v51-history-link{font-size:13px!important;border-color:var(--ui-line)!important}
.v51-aside-quote{background:#f6f7f9!important;border-color:var(--ui-line)!important;font-size:14px!important}
/* Journal as long-form personal reading surface */
.v51-journal-shell{grid-template-columns:minmax(170px,205px) minmax(0,1fr)!important;gap:16px!important}
.v51-journal-sidecard{padding:18px!important}
.v51-side-quote{background:#fff!important}
.v51-side-quote p{font-size:14px!important;line-height:1.6!important}
.v51-journal-toolbar{padding:16px!important;margin-bottom:12px!important}
.v51-search-label{background:var(--ui-surface)!important;border-color:var(--ui-line)!important;border-radius:10px!important;min-height:46px!important}
.v51-search-label input{font-size:14px!important}
.v51-filter-row{gap:8px!important}
.v51-filter{padding:8px 13px!important;font-size:13px!important;min-height:38px!important;border-radius:10px!important}
.v51-list-count{font-size:12px!important;color:var(--ui-muted)!important}
.v51-entry{grid-template-columns:56px minmax(0,1fr)!important;padding:19px!important;gap:16px!important;margin-bottom:11px!important}
.v51-entry-date{background:#f4f5f7!important;color:var(--ui-muted)!important;border-radius:10px!important;padding:10px 4px!important}
.v51-entry-date span{font-size:11px!important}
.v51-entry-meta{font-size:11px!important;letter-spacing:.05em!important}
.v51-entry-copy{font-size:14px!important;line-height:1.62!important;color:var(--ui-ink)!important}
.v51-entry-pill,.v51-related-tasks{font-size:12px!important;color:var(--ui-muted)!important;background:#f5f6f8!important;border:1px solid var(--ui-line)!important;border-radius:9px!important}
.v51-related-task{font-size:13px!important;color:var(--ui-gold)!important}
/* Chat: keep the successful three-pane navigation, improve readability and consistency. */
.chat-page-head{margin-bottom:14px!important}
.chat-mini-motto,.profile-affirmation{background:transparent!important;color:var(--ui-muted)!important;border:0!important;border-bottom:1px solid var(--ui-line)!important;border-radius:0!important;padding:9px 2px!important;font-size:13px!important;margin:0 0 14px!important}
.chat-mini-motto span,.profile-affirmation span{font-family:var(--ui-font)!important;font-size:17px!important;color:var(--ui-gold)!important}
.chat-card,.conversation-list{border-radius:var(--ui-radius)!important}
.chat-layout{gap:12px!important}
.chat-heading{background:#fff!important;border-color:var(--ui-line)!important}
.chat-heading strong,.conversation-row,.chat-welcome h2{font-family:var(--ui-font)!important;font-size:15px!important;font-weight:650!important;color:var(--ui-ink)!important}
.conversation-row{font-size:13px!important;line-height:1.4!important}
.conversation-row.selected{background:#eef1f5!important;color:var(--ui-ink)!important}
.chat-bubble{font-family:var(--ui-font)!important;font-size:14px!important;line-height:1.7!important;color:var(--ui-ink)!important}
.chat-bubble.is-user,.chat-bubble.user{background:#f0f2f5!important;color:var(--ui-ink)!important}
.chat-bubble.is-assistant,.chat-bubble.assistant{background:transparent!important;color:var(--ui-ink)!important}
.chat-compose,.home-talk-composer{background:#fff!important;border:1px solid var(--ui-line)!important;box-shadow:none!important}
.chat-context-cover{height:92px!important;overflow:hidden!important;border-radius:var(--ui-radius)!important}
.chat-context-cover img{opacity:.6!important}
.context-block{padding:16px!important}
/* Profile and onboarding adopt exactly the same visual language. */
.profile-grid{gap:14px!important}
.profile-grid .card{min-height:0!important}
.profile-settings .setting-line{font-size:14px!important}
.auth-screen{background:#fff!important;max-width:980px!important;min-height:480px!important}
.auth-v601-art{min-height:480px!important;background:linear-gradient(140deg,#fafbfc,#f0f2f5)!important;align-items:center!important}
.auth-v601-art::before,.auth-v601-art::after{display:none!important}
.auth-v601-art .auth-art-inner{background:transparent!important;backdrop-filter:none!important;padding:15px!important}
.auth-v601-art .auth-art-inner h1{font-size:clamp(30px,3vw,37px)!important}
.auth-v601-art .auth-art-inner h1 em{font-style:normal!important;color:var(--ui-gold)!important}
.auth-v601-art .auth-small{font-family:var(--ui-font)!important;font-size:11px!important}
.auth-panel{padding:34px!important}
.auth-v601-panel h2{font-size:25px!important}
/* First-visit ritual: clean transparent panels, no fake marble backdrop. */
.sawwa-ritual-overlay{background:rgba(32,43,56,.38)!important;backdrop-filter:blur(7px)!important}
.sawwa-ritual-backdrop{background:transparent!important}
.sawwa-ritual-card{background:var(--ui-surface)!important;border:1px solid var(--ui-line)!important;box-shadow:0 12px 45px rgba(22,34,51,.16)!important;color:var(--ui-ink)!important;border-radius:18px!important}
.sawwa-ritual-card h2{font-size:clamp(24px,3vw,31px)!important}
.sawwa-ritual-card p,.sawwa-ritual-note,.sawwa-ritual-hint{color:var(--ui-muted)!important;font-size:14px!important}
.sawwa-ritual-shell::before{font-family:var(--ui-font)!important;color:var(--ui-surface)!important;font-size:11px!important}
.sawwa-scenario-card{border:1px solid var(--ui-line)!important;border-radius:12px!important;background:#fff!important;min-height:85px!important;padding:15px 17px!important}
.sawwa-scenario-card.active{background:#f5f2ed!important;border-color:#b99669!important;box-shadow:0 0 0 1px #b99669 inset!important}
.sawwa-scenario-card strong{font-family:var(--ui-font)!important;color:var(--ui-ink)!important;font-size:15px!important;font-weight:650!important;line-height:1.4!important;margin-bottom:6px!important}
.sawwa-scenario-card span{font-family:var(--ui-font)!important;color:var(--ui-muted)!important;font-size:13px!important}
.sawwa-ritual-textarea{background:#fff!important;border-color:var(--ui-line)!important;color:var(--ui-ink)!important;border-radius:11px!important;font-size:14px!important;min-height:122px!important}
.sawwa-ritual-start{background:var(--ui-gold)!important;color:#fff!important;border-radius:10px!important;font-size:14px!important;min-height:45px!important}
.sawwa-ritual-ghost{color:var(--ui-ink)!important;border-color:var(--ui-line)!important;border-radius:10px!important}
.sawwa-ritual-close{color:var(--ui-ink)!important;background:var(--ui-tint)!important}
/* Important status text is never communicated by a dot alone. */
.ai-connection-line{font-size:12px!important}
/* Responsive layouts. */
@media(max-width:1100px){.dashboard-columns{grid-template-columns:minmax(0,1.25fr) minmax(250px,1fr)!important}}
@media(max-width:980px){.v51-journal-shell{grid-template-columns:1fr!important}.v51-journal-side{display:none!important}.v51-path-layout{grid-template-columns:1fr!important}.dashboard-columns{grid-template-columns:1fr!important}}
@media(max-width:800px){
  .topbar{height:60px!important;padding:0 16px!important}.brand-button{font-size:17px!important}
  .app-layout{display:block!important}.side-nav{display:none!important}
  .main-space{padding:18px 15px 90px!important}
  .page{padding:0!important}
  .mobile-nav{background:rgba(255,255,255,.94)!important;border-top:1px solid var(--ui-line)!important;backdrop-filter:blur(14px);z-index:50!important}
  .mobile-nav button{min-height:52px!important;color:var(--ui-muted)!important}
  .mobile-nav button.active{color:var(--ui-gold)!important}
  .mobile-nav small{font-family:var(--ui-font)!important;font-size:11px!important}
  #homeView .myth-hero,#profileView .myth-hero{padding:20px!important;min-height:116px!important;margin:0 0 18px!important}
  #homeView .myth-hero h1,#profileView .myth-hero h1{font-size:26px!important}
  .v51-page .v51-hero{padding:17px!important;min-height:90px!important}
  .v51-page .v51-hero::after{font-size:56px!important;right:15px!important}
  .v51-page .v51-hero p{font-size:14px!important;max-width:90%!important}
  .v51-heading h1,.page-head h1{font-size:28px!important}
  .v51-path-stats{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .v51-stat{padding:13px 10px!important}
  .v51-stat strong{font-size:24px!important}
  .v51-goal-tab{flex-basis:240px!important}
  .v51-selected-goal{padding:17px!important}
  .auth-screen{margin:12px!important;grid-template-columns:1fr!important}
  .auth-v601-art{min-height:auto!important;padding:18px!important}
  .auth-v601-panel{padding:20px!important}
  .chat-layout{grid-template-columns:1fr!important}
  .chat-context-cover{display:none!important}
  .chat-compose{min-height:53px!important}
}
@media(max-width:560px){
  .main-space{padding:14px 12px 86px!important}
  .dashboard-stats{grid-template-columns:1fr 1fr!important;gap:10px!important}
  .dashboard-stats .home-stat{min-height:92px!important}
  .dashboard-stats .home-stat:last-child{grid-column:1/-1}
  .dashboard-stats .home-stat strong{font-size:15px!important}
  .dashboard-columns .card{padding:16px!important}
  .page-head{flex-wrap:wrap!important}
  .v51-heading .path-actions,.v51-journal-buttons{width:100%!important;justify-content:flex-start!important}
  .v51-heading .path-actions button,.v51-journal-buttons button{min-height:42px!important;font-size:12px!important}
  .v51-entry{grid-template-columns:44px minmax(0,1fr)!important;padding:14px!important;gap:11px!important}
  .v51-entry-date b{font-size:19px!important}
  .v51-entry-copy{font-size:14px!important}
  .v51-goal-tab{flex-basis:83%!important}
  .v51-path-stats{gap:7px!important}
  .v51-stat span{font-size:10px!important}
  .v51-stat small{font-size:11px!important}
  .v51-journal-toolbar{padding:12px!important}
  .v51-filter{font-size:12px!important}
  .v51-hero-text{padding:0!important}
  .sawwa-scenario-grid{grid-template-columns:1fr!important}
  .sawwa-ritual-card{padding:20px 16px!important}
}
@media(max-width:360px){.v51-path-stats{grid-template-columns:1fr!important}.v51-stat{min-height:70px!important}.v51-entry{grid-template-columns:1fr!important}.v51-entry-date{flex-direction:row!important;justify-content:flex-start!important;gap:6px!important;padding:0!important;background:transparent!important}.dashboard-stats{grid-template-columns:1fr!important}.dashboard-stats .home-stat:last-child{grid-column:auto}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{transition-duration:.01ms!important;animation-duration:.01ms!important;scroll-behavior:auto!important}}
/* A consistent alternate palette when system/user switches to dark mode. */
html[data-theme='dark']{--ui-bg:#111923;--ui-surface:#1b2632;--ui-ink:#f0f3f6;--ui-muted:#c5cdd5;--ui-subtle:#b4bfca;--ui-line:#354252;--ui-tint:#253340;--ui-gold:#d0a975;--ui-gold-hover:#b98b57;--ui-focus:#d6ae7c;--ui-shadow:0 4px 20px rgba(0,0,0,.12);color-scheme:dark}
html[data-theme='dark'] .topbar,html[data-theme='dark'] .side-nav,html[data-theme='dark'] .mobile-nav{background:rgba(27,38,50,.93)!important}
html[data-theme='dark'] .nav-button.active,html[data-theme='dark'] .conversation-row.selected{background:#2a3b4c!important}
html[data-theme='dark'] #homeView .myth-hero,html[data-theme='dark'] #profileView .myth-hero,html[data-theme='dark'] .v51-page .v51-hero{background:linear-gradient(110deg,#1b2632,#243241)!important}
html[data-theme='dark'] .v51-goal-tab.selected,html[data-theme='dark'] .v51-goal-description,html[data-theme='dark'] .v51-entry-pill,html[data-theme='dark'] .v51-related-tasks{background:#283746!important}
html[data-theme='dark'] .quiet,html[data-theme='dark'] .v51-filter,html[data-theme='dark'] .sawwa-scenario-card,html[data-theme='dark'] .sawwa-ritual-textarea,html[data-theme='dark'] label input,html[data-theme='dark'] label select{background:var(--ui-surface)!important;color:var(--ui-ink)!important}
html[data-theme='dark'] .sawwa-scenario-card.active{background:#304050!important}
html[data-theme='dark'] .chat-heading,html[data-theme='dark'] .chat-compose,html[data-theme='dark'] .home-talk-composer{background:var(--ui-surface)!important}
html[data-theme='dark'] .v51-entry-date{background:#263545!important}
html[data-theme='dark'] .chat-bubble.is-user,html[data-theme='dark'] .chat-bubble.user{background:#2b3a49!important}
html[data-theme='dark'] .v51-page .v51-hero::after{color:#d0a97524!important}
