/* Design tokens live in src/styles/tokens.css (§9.1 token merge). */


* {
  box-sizing: border-box;
}

html {
  /* iOS Safari inflates text in some multi-column blocks ("text autosizing"),
     which on iPhone widened grid items past the viewport and distorted the
     layout (it does not happen on Android). Pin it so layout matches the design. */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html,
body {
  min-height: 100%;
  margin: 0;
  width: 100%;
  max-width: 100%;
  /* clip (not hidden) prevents sideways scroll WITHOUT turning these into
     vertical scroll containers — hidden was hijacking touch and blocking
     the page from scrolling at all on phones. */
  overflow-x: clip;
  overscroll-behavior-y: none;
}

body {
  background: radial-gradient(circle at 80% 8%, rgba(140, 240, 230, 0.3), transparent 34%),
    radial-gradient(circle at 6% 34%, rgba(211, 196, 255, 0.2), transparent 40%),
    linear-gradient(135deg, var(--bg-1), var(--bg-2) 48%, var(--bg-3));
  color: var(--text-inverse);
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

.app-shell {
  width: 100%;
  max-width: 460px;
  min-height: 100dvh;
  margin: 0 auto;
  padding: max(18px, env(safe-area-inset-top)) 20px max(22px, env(safe-area-inset-bottom));
  position: relative;
  overflow-x: clip;
}

.page {
  min-height: calc(100dvh - 40px);
  padding-bottom: 86px;
}

.topbar {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.brand {
  margin: 0;
  text-align: center;
  font-size: 15px;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.tagline {
  margin: 18px 0 0;
  font-size: 28px;
  line-height: 1.05;
  font-weight: 650;
  letter-spacing: -0.04em;
}

.subtagline {
  margin: 8px 0 0;
  color: var(--text-soft);
  font-size: 13px;
}

.icon-button {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--glass);
  color: var(--text-inverse);
  display: grid;
  place-items: center;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.icon-button:active,
.pressable:active {
  transform: scale(0.97) translateY(1px);
}

.menu-lines,
.search-icon {
  width: 19px;
  height: 19px;
  position: relative;
}

.menu-lines::before,
.menu-lines::after,
.menu-lines span {
  content: "";
  display: block;
  height: 1.8px;
  background: currentColor;
  border-radius: 999px;
  position: absolute;
  left: 1px;
  right: 1px;
}

.menu-lines::before {
  top: 3px;
}

.menu-lines span {
  top: 8.5px;
}

.menu-lines::after {
  bottom: 3px;
}

.search-icon::before {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border: 1.8px solid currentColor;
  border-radius: 50%;
  left: 1px;
  top: 1px;
}

.search-icon::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 1.8px;
  background: currentColor;
  border-radius: 999px;
  transform: rotate(45deg);
  right: 1px;
  bottom: 3px;
}

.hero-copy {
  margin: 34px 0 20px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--text-soft);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.greeting {
  margin: 12px 0 0;
  font-size: 21px;
  line-height: 1.15;
  font-weight: 550;
  letter-spacing: -0.03em;
}

.support-copy {
  margin: 8px 0 0;
  color: var(--text-soft);
  font-size: 12.5px;
  line-height: 1.45;
}

.action-tile {
  min-width: 0;
  min-height: 104px;
  padding: 22px 20px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.08));
  color: var(--text-inverse);
  box-shadow: var(--shadow);
  text-align: left;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.action-tile:hover,
.folder:hover,
.folder-strip:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.28);
}

.action-icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  background: rgba(223, 251, 247, 0.9);
  color: var(--accent-dark);
}

.action-tile:nth-child(2) .action-icon {
  background: rgba(244, 236, 255, 0.95);
  color: #7869de;
}

.action-title {
  display: block;
  font-size: 15px;
  font-weight: 650;
  white-space: normal;
}

.action-copy {
  display: block;
  margin-top: 7px;
  color: var(--text-soft);
  font-size: 11px;
  line-height: 1.35;
}

.folder-stack {
  position: relative;
  height: 390px;
  margin-top: 20px;
}

.folder {
  position: absolute;
  left: 0;
  right: 0;
  min-height: 144px;
  border-radius: 22px 22px 26px 26px;
  border: 1px solid var(--folder-edge);
  color: var(--text-inverse);
  background-color: var(--folder-glass);
  backdrop-filter: blur(28px) saturate(135%);
  -webkit-backdrop-filter: blur(28px) saturate(135%);
  box-shadow: var(--folder-shadow);
  cursor: pointer;
  transition: transform 220ms cubic-bezier(.2,.8,.2,1), box-shadow 220ms ease, border-color 220ms ease;
  overflow: hidden;
}

.folder::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 18px;
  width: 150px;
  height: 44px;
  border-radius: 18px 18px 8px 0;
  background: inherit;
  border: 1px solid var(--folder-edge);
  border-bottom: 0;
}

.folder::after {
  /* a faint highlight rim along the top edge — gives the glass feel */
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.32), transparent);
  pointer-events: none;
}

.folder-inner {
  position: relative;
  padding: 62px 24px 20px;
}

.folder-title {
  margin: 0;
  font-size: 16px;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.folder .folder-title {
  color: var(--text-inverse);
}

.folder .folder-line {
  color: rgba(247, 251, 251, 0.78);
}

.folder .folder-meta {
  color: rgba(175, 248, 241, 0.92);
}

.folder-line {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.folder-meta {
  margin-top: 14px;
  color: var(--accent-dark);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.folder.brain {
  top: 0;
  transform: translateX(26px) scale(0.94);
  background: var(--brain);
}

.folder.family {
  top: 52px;
  transform: translateX(18px) scale(0.96);
  background: var(--family);
}

.folder.home {
  top: 104px;
  transform: translateX(9px) scale(0.98);
  background: var(--home);
}

.folder.personal {
  top: 166px;
  min-height: 214px;
  background: var(--personal);
}

.folder.front {
  z-index: 5;
}

.folder:not(.front) .folder-inner {
  padding-top: 58px;
}

.folder:not(.front) .folder-line:nth-of-type(n + 3),
.folder:not(.front) .folder-meta {
  display: none;
}

.folder-arrow {
  position: absolute;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 26px;
  color: rgba(175, 248, 241, 0.9);
}

.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: max(10px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: calc(100vw - 32px);
  max-width: 430px;
  height: 58px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 29px;
  background: rgba(243, 252, 251, 0.95);
  box-shadow: var(--shadow);
  z-index: 10;
}

.nav-item {
  min-width: 0;
  height: 48px;
  margin: 5px;
  border: 0;
  border-radius: 24px;
  background: transparent;
  color: var(--ink-3);
  display: grid;
  place-items: center;
  gap: 1px;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease, transform 180ms ease;
}

.nav-item.active {
  background: #ddf8f4;
  color: var(--accent-dark);
}

.nav-label {
  font-size: 9.5px;
  font-weight: 600;
  max-width: 68px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-icon svg,
.action-icon svg {
  display: block;
}

.placeholder-card,
.homeos-card {
  margin-top: 22px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
  padding: 22px;
}

.homeos-page {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.placeholder-card h2,
.homeos-card h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
}

.placeholder-card p,
.homeos-card p {
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.5;
}

.homeos-shell {
  background: radial-gradient(circle at 86% 2%, rgba(222, 246, 255, 0.9), transparent 25%),
    linear-gradient(180deg, #f7fcff, #eaf8ff);
  color: var(--ink-1);
  border-radius: 30px;
  padding: 18px;
  box-shadow: var(--paper-shadow);
}

.homeos-page .homeos-shell {
  min-height: calc(100dvh - 112px);
}

.homeos-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.homeos-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}

.homeos-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.homeos-panel {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  margin: 18px 0 12px;
  padding: 16px;
  border: 1px solid #d7eef5;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.72);
}

.homeos-panel strong {
  display: block;
  margin-top: 8px;
  color: var(--ink-1);
  font-size: 36px;
  line-height: 1;
}

.homeos-kicker {
  display: block;
  color: var(--ink-3);
  font-size: 11px;
  line-height: 1.25;
}

.homeos-mini-stats {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.homeos-mini-stats span {
  min-width: 0;
  min-height: 54px;
  display: grid;
  place-items: center;
  padding: 8px;
  border-radius: 16px;
  border: 1px solid #e2f1f5;
  background: rgba(255, 255, 255, 0.62);
  color: var(--ink-3);
  font-size: 10.5px;
  text-align: center;
}

.homeos-rhythm {
  margin: 0 0 12px;
  padding: 16px;
  border: 1px solid #d7eef5;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.64);
}

.homeos-rhythm span {
  color: var(--ink-3);
  font-size: 12px;
}

.homeos-progress {
  position: relative;
  height: 8px;
  margin-top: 14px;
  border-radius: 999px;
  background: #e4f3f8;
  overflow: hidden;
}

.homeos-progress i {
  display: block;
  width: 63%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #62dccf, #169e92);
}

.homeos-progress-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 9px;
}

.homeos-progress-labels span {
  font-size: 9.5px;
}

.homeos-notice,
.homeos-meals {
  width: 100%;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 18px;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(35,60,65,0.08);
  border-radius: 20px;
  background: #fff;
  color: var(--ink-1);
  text-align: left;
  cursor: pointer;
  box-shadow: 0 10px 26px -16px rgba(8,27,32,0.4);
}

.homeos-notice span,
.homeos-meals span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e1fbf7;
  color: var(--accent-dark);
}

.homeos-notice strong,
.homeos-meals strong {
  display: block;
  grid-column: 2;
  font-size: 18px;
  font-weight: 700;
}

.homeos-notice em,
.homeos-meals em {
  display: block;
  grid-column: 2;
  margin-top: 4px;
  color: var(--ink-3);
  font-size: 11px;
  font-style: normal;
}

.homeos-notice::after,
.homeos-meals::after {
  content: "›";
  grid-column: 3;
  grid-row: 1 / span 2;
  color: var(--accent-dark);
  font-size: 24px;
}

.homeos-task-states {
  margin-top: 12px;
  padding: 16px;
  border: 1px solid var(--homeos-line);
  border-radius: 24px;
  background: var(--homeos-card);
}

.homeos-task-states h4 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 15px;
}

.homeos-state-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.state-pill {
  min-width: 0;
  min-height: 82px;
  padding: 12px;
  border: 1px solid #e1eef3;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.66);
  color: var(--ink-1);
  text-align: left;
  cursor: pointer;
}

.state-pill span {
  width: 8px;
  height: 8px;
  display: block;
  border-radius: 50%;
  background: var(--accent);
}

.state-pill:nth-child(2) span { background: #d76072; }
.state-pill:nth-child(3) span { background: #d79b3d; }

.state-pill strong,
.state-pill em {
  display: block;
}

.state-pill strong {
  margin-top: 10px;
  color: var(--ink-3);
  font-size: 10.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.state-pill em {
  margin-top: 8px;
  font-size: 22px;
  font-style: normal;
  font-weight: 700;
}

.briefing-list {
  margin: 18px 0;
  padding: 0 0 0 22px;
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.6;
}

.briefing-list li + li {
  margin-top: 8px;
}

.homeos-stat {
  min-height: 86px;
  padding: 15px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid #d7eef5;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.homeos-stat strong {
  display: block;
  font-size: 24px;
  margin-top: 8px;
}

.homeos-stat span {
  color: var(--ink-3);
  font-size: 12px;
}

.list {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid #d7eef5;
  background: rgba(255, 255, 255, 0.72);
}

.list li {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border-bottom: 1px solid #e4f1f5;
  font-size: 13px;
}

.list li:last-child {
  border-bottom: 0;
}

.status {
  color: var(--ink-1);
  font-weight: 700;
  font-size: 11px;
}

.large-wave {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  border-radius: 50%;
  background: rgba(223, 251, 247, 0.92);
  color: var(--accent-dark);
}

.primary-pill {
  width: 100%;
  min-height: 52px;
  margin-top: 10px;
  border: 0;
  border-radius: 26px;
  background: linear-gradient(135deg, #baf5ec, #35cabb);
  color: #173b3f;
  font-weight: 700;
  cursor: pointer;
}

.example-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.example-list p {
  margin: 0;
  padding: 13px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.1);
}

@media (min-width: 960px) {
  .app-shell {
    /* The product is mobile-first / mobile-web.
       On desktop we keep the canvas a single phone-sized column,
       centered with a soft inset, instead of letting it sprawl. */
    max-width: 460px;
    padding-inline: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* Xortit demo refresh */
.brand-button { border: 0; background: transparent; color: var(--text-inverse); cursor: pointer; font: inherit; padding: 8px 10px; border-radius: 999px; }
.brand-button:active { transform: scale(0.98); }
.hero-centered { margin-top: 26px; text-align: center; }

.launch-line { margin: 14px 0 0; color: rgba(223,251,247,.94); font-size: 17px; font-weight: 620; letter-spacing: -0.02em; }
.hero-centered .subtagline { margin-top: 4px; font-size: 13px; color: rgba(223,235,236,.76); }
.hero-centered .greeting { margin-top: 24px; }
.attention-demo { position: relative; overflow: hidden; }
.attention-demo::after { content: ""; position: absolute; inset: auto 18px 14px 18px; height: 1px; background: rgba(255,255,255,.18); }
.attention-meter { position: absolute; left: 18px; right: 18px; bottom: 13px; height: 3px; border-radius: 999px; background: rgba(255,255,255,.12); overflow: hidden; }
.attention-meter i { display: block; width: 64%; height: 100%; border-radius: inherit; background: linear-gradient(90deg,#cfbfff,#9ff2eb); animation: meter-breathe 2.4s ease-in-out infinite; }

.chat-bubble.user { margin-left: auto; border-bottom-right-radius: 5px; background: rgba(195,247,236,.94); color: #174548; animation-delay: 250ms; }
.chat-bubble.xortit { border-bottom-left-radius: 5px; background: rgba(255,255,255,.16); color: rgba(244,251,251,.94); border: 1px solid rgba(255,255,255,.14); }
.chat-bubble.one { animation-delay: 1.1s; }
.chat-bubble.two { animation-delay: 2.1s; }

.folder-stack { height: 404px; margin-top: 22px; }
.folder { user-select: none; touch-action: none; }
.folder.slot-0 { top: 166px; min-height: 222px; transform: none; z-index: 5; }
.folder.slot-1 { top: 106px; transform: translateX(9px) scale(.98); z-index: 4; }
.folder.slot-2 { top: 54px; transform: translateX(18px) scale(.96); z-index: 3; }
.folder.slot-3 { top: 4px; transform: translateX(27px) scale(.94); z-index: 2; }
.folder.dragging { opacity: .72; transform: translateY(-5px) scale(.99) !important; }
.folder.drag-over { box-shadow: 0 0 0 2px rgba(175,248,241,.82), var(--paper-shadow); }
.folder:not(.slot-0) .folder-inner { padding-top: 56px; }
.folder:not(.slot-0) .folder-line:nth-of-type(n + 3), .folder:not(.slot-0) .folder-meta, .folder:not(.slot-0) .folder-title, .folder:not(.slot-0) .folder-arrow { display: none; }

.event-calendar-card p:not(.eyebrow) { margin: 8px 0 18px; color: var(--text-soft); font-size: 12px; line-height: 1.45; }

.hour-line.h1 { top: 14.2%; } .hour-line.h2 { top: 28.4%; } .hour-line.h3 { top: 42.6%; } .hour-line.h4 { top: 56.8%; } .hour-line.h5 { top: 71%; } .hour-line.h6 { top: 85.2%; }

.event-block.pet { background: #dffbf7; } .event-block.family { background: #efe7ff; } .event-block.personal { background: #fff2dc; } .event-block.renew { background: #e2f1ff; }
.interactive-decisions .decision-demo-card { margin-top: 18px; }
.decision-demo-card { padding: 16px; border-radius: 24px; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.12); }
.decision-tag { display: inline-flex; padding: 5px 9px; border-radius: 999px; background: rgba(223,251,247,.14); color: #baf5ec; font-size: 10px; font-weight: 650; }
.decision-demo-card h3 { margin: 12px 0 6px; font-size: 16px; }
.decision-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.mini-action { border: 1px solid rgba(255,255,255,.14); border-radius: 999px; padding: 9px 12px; background: rgba(255,255,255,.1); color: var(--text-inverse); cursor: pointer; }
.mini-action.approve { background: rgba(186,245,236,.86); color: #173b3f; }
.decision-output { display: block; margin-top: 12px; min-height: 24px; color: rgba(223,235,236,.76); font-size: 12px; }
.decision-complete { box-shadow: 0 0 0 2px rgba(186,245,236,.34), var(--shadow); }
@keyframes bubble-in { to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes typing-dot { 0%,100% { transform: translateY(0); opacity: .48; } 50% { transform: translateY(-3px); opacity: 1; } }
@keyframes typing-show { 0%,55% { opacity: 0; } 60%,100% { opacity: 1; } }
@keyframes meter-breathe { 0%,100% { opacity: .7; transform: scaleX(.94); } 50% { opacity: 1; transform: scaleX(1); } }
@media (min-width: 960px) { .folder-stack { height: 456px; } .folder.slot-0 { min-height: 238px; } .hero-centered { margin-top: 32px; } }

/* Public waitlist and signed-in dashboard split */
.public-page {
  /* Reserve space for the fixed bottom nav (58px nav + 10px inset + buffer) */
  padding-bottom: 110px;
}

.public-logo {
  margin: 0;
  font-size: clamp(64px, 19vw, 118px);
  line-height: 0.86;
  letter-spacing: -0.08em;
  font-weight: 790;
  color: #f5fcfc;
  text-shadow: 0 24px 70px rgba(0, 0, 0, 0.26);
}

.mini-folder.personal { top: 24px; transform: translateX(16px) scale(.94); background: var(--personal); z-index: 1; }
.mini-folder.home { top: 76px; transform: translateX(8px) scale(.97); background: var(--home); z-index: 2; }
.mini-folder.family { top: 128px; background: var(--family); z-index: 3; }

.waitlist-card {
  margin-top: 16px;
  padding: 22px;
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: linear-gradient(145deg, rgba(255,255,255,.18), rgba(255,255,255,.08));
  box-shadow: var(--shadow);
}

.waitlist-card h2 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -0.04em;
}

.waitlist-card p:not(.eyebrow) {
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.5;
}

.waitlist-form {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.waitlist-form input {
  width: 100%;
  min-height: 52px;
  padding: 0 16px;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.13);
  color: var(--text-inverse);
  outline: none;
}

.waitlist-form input::placeholder {
  color: rgba(223, 235, 236, 0.58);
}

.waitlist-form input:focus {
  border-color: rgba(186, 245, 236, 0.62);
  box-shadow: 0 0 0 4px rgba(186, 245, 236, 0.1);
}

.waitlist-status {
  min-height: 20px;
  margin-bottom: 0;
}

.dashboard-hero {
  margin-top: 28px;
}

.public-title-block {
  text-align: center;
  min-width: 0;
}

.preview-logo {
  font-size: clamp(44px, 14vw, 76px);
  line-height: 0.9;
}

.public-title-block .launch-line {
  margin-top: 10px;
  font-size: 15px;
}

.public-title-block .subtagline {
  margin-top: 3px;
  font-size: 11.5px;
}

.compact-public-stack .folder.slot-0 {
  top: 132px;
  min-height: 190px;
}

.compact-public-stack .folder.slot-1 {
  top: 86px;
}

.compact-public-stack .folder.slot-2 {
  top: 43px;
}

.compact-public-stack .folder.slot-3 {
  top: 2px;
}

.compact-public-stack .folder-inner {
  padding-bottom: 16px;
}

.mini-calendar-row.overlap {
  grid-template-columns: 48px 1fr 1fr;
}

.event-soft.family { background: #efe7ff; }
.event-soft.home { background: #dffbf7; }
.event-soft.personal { background: #fff2dc; }
.event-soft.pet { background: #e2f1ff; }

.waitlist-compact {
  margin: 14px 0 90px;
  padding: 16px;
  border-radius: 26px;
}

.waitlist-compact h2 {
  font-size: 17px;
}

.waitlist-form.compact {
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.waitlist-form.compact input {
  min-height: 46px;
  border-radius: 23px;
}

.waitlist-form.compact .primary-pill {
  width: auto;
  min-height: 46px;
  margin-top: 0;
  padding: 0 16px;
}

.waitlist-compact .waitlist-status {
  margin-top: 10px;
  font-size: 11px;
}

.preview-nav .nav-item {
  pointer-events: auto;
}

@media (max-width: 380px) {
  .waitlist-form.compact {
    grid-template-columns: 1fr;
  }
  .waitlist-form.compact .primary-pill {
    width: 100%;
  }
}

/* Public preview corrections */

.public-demo-panel.active {
  display: block;
}

.voice-orb {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(223,251,247,.9);
  color: var(--accent-dark);
  box-shadow: 0 0 0 0 rgba(186,245,236,.34);
  animation: voice-pulse 1.8s ease-in-out infinite;
}

.spoken-line {
  margin: 9px 0 0;
  color: rgba(244,251,251,.94);
  font-size: 12px;
  line-height: 1.35;
  opacity: 0;
  transform: translateY(6px);
  animation: spoken-line 6s ease-in-out infinite;
}

.spoken-line.line-one { animation-delay: .2s; }
.spoken-line.line-two { animation-delay: 1.3s; }
.spoken-line.line-three { animation-delay: 2.4s; }

.public-demo-trigger.active {
  border-color: rgba(186,245,236,.44);
  box-shadow: 0 0 0 1px rgba(186,245,236,.22), var(--shadow);
}

.compact-public-stack .folder {
  left: 4px;
  right: 4px;
  border-radius: 18px 18px 28px 28px;
  overflow: visible;
  transform-origin: center top;
}

.compact-public-stack .folder::before {
  left: 20px;
  width: 132px;
  height: 38px;
  border-radius: 18px 18px 8px 0;
}

.compact-public-stack .folder.slot-3 {
  top: 0;
  transform: translateX(26px) translateY(0) rotate(-1deg) scale(.92);
  z-index: 1;
}

.compact-public-stack .folder.slot-2 {
  top: 48px;
  transform: translateX(18px) translateY(0) rotate(.7deg) scale(.95);
  z-index: 2;
}

.compact-public-stack .folder.slot-1 {
  top: 98px;
  transform: translateX(10px) translateY(0) rotate(-.4deg) scale(.975);
  z-index: 3;
}

.compact-public-stack .folder.slot-0 {
  top: 150px;
  min-height: 196px;
  transform: translateX(0) translateY(0) rotate(0) scale(1);
  z-index: 4;
}

.compact-public-stack .folder:not(.slot-0) {
  min-height: 112px;
}

.compact-public-stack .folder:not(.slot-0) .folder-inner {
  padding: 47px 22px 12px;
}

.compact-public-stack .folder:not(.slot-0) .folder-line:nth-of-type(1) {
  display: block;
  max-width: 82%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.compact-public-stack .folder:not(.slot-0) .folder-line:nth-of-type(n + 2) {
  display: none;
}

@keyframes voice-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(186,245,236,.28); transform: scale(1); }
  50% { box-shadow: 0 0 0 10px rgba(186,245,236,0); transform: scale(1.04); }
}

@keyframes spoken-line {
  0%, 12% { opacity: 0; transform: translateY(6px); }
  18%, 82% { opacity: 1; transform: translateY(0); }
  100% { opacity: .72; transform: translateY(0); }
}

/* Restore public navigation and folder stack */
.preview-logo {
  font-size: clamp(24px, 7vw, 38px);
  letter-spacing: -0.055em;
}

.public-title-block .subtagline {
  font-size: 12.5px;
}

.public-briefing-page,
.public-calendar-route,
.say-card,
.decisions-card {
  margin-bottom: 92px;
}

/* Mobile fold tuning: nav, folder tabs, spacing */
.preview-nav .nav-item {
  pointer-events: auto !important;
}

.public-title-block .launch-line {
  margin-top: 18px;
}

.public-title-block .subtagline {
  margin-top: 7px;
  font-size: 13.5px;
  line-height: 1.35;
}

.waitlist-compact {
  margin-top: 10px;
}

.public-title-block {
  justify-self: center;
  text-align: center;
  transform: translateY(8px);
}

.preview-logo {
  font-size: clamp(24px, 7vw, 36px);
  text-align: center;
}

.public-title-block .launch-line {
  margin-top: 24px;
}

.public-title-block .subtagline {
  margin-top: 10px;
  font-size: 15.5px;
}

.waitlist-compact {
  padding: 13px 16px;
  border-radius: 24px;
  margin-top: 12px;
}

.waitlist-compact .eyebrow {
  display: none;
}

.waitlist-compact h2 {
  font-size: 14px;
  margin-bottom: 2px;
}

.waitlist-form.compact {
  margin-top: 8px;
}

.waitlist-form.compact input,
.waitlist-form.compact .primary-pill {
  min-height: 40px;
  border-radius: 20px;
}

.waitlist-form.compact input {
  font-size: 13px;
}

.waitlist-form.compact .primary-pill {
  font-size: 13px;
  padding-inline: 14px;
}

.waitlist-compact .waitlist-status:empty {
  display: none;
}

.briefing-visual {
  display: none;
  margin-top: 16px;
  padding: 16px;
  border-radius: 24px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.14);
}

.briefing-visual.active {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 12px;
  align-items: start;
}

.briefing-visual .voice-orb {
  grid-row: span 3;
}

.briefing-visual .spoken-line {
  margin: 0 0 8px;
}

.public-module-page .module-waitlist {
  margin-bottom: 0;
}

/* Final phone polish: aligned shell, calmer stack, matching signed-in demo */
.public-preview-topbar,
.logged-preview-topbar {
  align-items: center;
  grid-template-columns: 52px 1fr 52px;
  padding-top: 8px;
}

.public-preview-topbar > .icon-button,
.logged-preview-topbar > .icon-button {
  margin-top: 2px;
}

.public-title-block {
  transform: none;
}

.preview-logo,
.logged-logo {
  letter-spacing: -.02em;
  line-height: 1.05;
}

.logged-logo {
  font-size: clamp(24px, 7vw, 34px);
  color: #f7fffd;
  text-transform: none;
}

.public-title-block .launch-line {
  margin-top: 20px;
}

.public-title-block .subtagline {
  margin-top: 12px;
  font-size: 17.5px;
  line-height: 1.28;
}

.dashboard-hero {
  margin-top: 16px;
}

.dashboard-hero .greeting {
  margin-top: 0;
}

.dashboard-hero .support-copy {
  margin-inline: auto;
  max-width: 330px;
}

.waitlist-compact {
  margin-top: 24px;
  padding: 12px 16px 10px;
}

.waitlist-compact h2 {
  font-size: 14.5px;
}

.waitlist-form.compact input,
.waitlist-form.compact .primary-pill {
  min-height: 38px;
}

.briefing-visual.active {
  animation: briefingRise 420ms cubic-bezier(.18,1,.24,1) both;
}

@keyframes briefingRise {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Copy parity and single-line public subtag */
.public-title-block .subtagline {
  white-space: nowrap;
  font-size: clamp(15px, 4.4vw, 18px);
}

.event-calendar-card > .eyebrow:first-child {
  display: none;
}

/* Real-folder stair stack: equal size, contained, public + signed-in */
.public-preview-folders,
.dashboard-folder-section {
  overflow: visible;
}

.waitlist-compact {
  margin-top: 12px;
}

/* Folder legibility and compact waitlist refinement */
.logged-preview-topbar .logged-logo {
  text-transform: uppercase;
  font-size: clamp(24px, 7vw, 36px);
  font-weight: 790;
  color: #f7fffd;
}

.logged-preview-topbar + .dashboard-hero {
  margin-top: 18px;
}

.waitlist-compact {
  width: min(86vw, 330px);
  margin-left: auto;
  margin-right: auto;
  padding: 14px 16px 16px;
  border-radius: 24px;
}

.waitlist-form.compact {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.waitlist-form.compact input,
.waitlist-form.compact .primary-pill {
  width: 100%;
  min-height: 42px;
}

/* Visible folder tabs and clean logged-in header */
.logged-title-block .launch-line,
.logged-title-block .subtagline {
  display: none !important;
}

.logged-preview-topbar + .dashboard-hero {
  margin-top: 54px;
}

.logged-preview-topbar + .dashboard-hero {
  margin-top: 46px;
}

.dashboard-hero .support-copy {
  margin-top: 12px;
}

.menu-popover {
  position: absolute;
  top: 84px;
  left: 28px;
  z-index: 80;
  display: none;
  width: 154px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 20px;
  background: rgba(238, 252, 249, .16);
  box-shadow: 0 18px 36px rgba(6, 22, 28, .28);
  backdrop-filter: blur(18px);
}

.menu-popover.active {
  display: grid;
  gap: 6px;
  animation: menuIn 180ms ease-out both;
}

.menu-popover-item {
  width: 100%;
  border: 0;
  border-radius: 14px;
  padding: 11px 12px;
  color: rgba(247, 255, 253, .92);
  background: rgba(255, 255, 255, .08);
  font: inherit;
  font-size: 13px;
  text-align: left;
}

.menu-popover-item:active {
  transform: scale(.98);
  background: rgba(196, 255, 242, .16);
}

@keyframes menuIn {
  from { opacity: 0; transform: translateY(-6px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.menu-popover {
  pointer-events: auto;
}

.menu-popover-item {
  cursor: pointer;
}

.menu-popover {
  min-height: 96px;
}

.menu-popover-item {
  min-height: 42px;
}

/* =================================================================
   v2 — folder dashboards, calendar grid, meals, breadcrumb, ingredients
   Appended in one block so the existing system stays intact.
   ================================================================= */

/* --- OS BREADCRUMB (back-to-Xortit) ----------------------------- */
.os-breadcrumb {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-bottom: 16px;
  color: var(--ink-3);
}
.os-crumb-row {
  display: grid;
  grid-template-columns: 1fr minmax(0, auto) 1fr;
  align-items: center;
  gap: 8px;
  /* Preserve the app-bar height now that the 40px ☰ button moved out to the
     universal avatar — keeps every page's title at the same vertical position. */
  min-height: 40px;
}
.os-crumb-back { justify-self: start; display: flex; align-items: center; gap: 7px; }
/* .os-back* / .os-home-btn removed 2026-07-30 — the app-bar back arrow was retired
   (redundant with the bottom nav's Xortit-home slot). The .os-crumb-back cell stays
   as the empty left column that keeps the title centred. */
.os-crumb-sep { display: none; }
.os-breadcrumb .os-crumb-current {
  justify-self: center; text-align: center; margin: 0; min-width: 0;
  font-size: 22px; font-weight: 760; letter-spacing: -0.01em; color: var(--ink);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%;
}
.os-crumb-menu { justify-self: end; }

/* Add / Sort / Filter row: left aligned now that the universal menu lives at right. */
.os-crumb-actions { display: flex; justify-content: flex-start; gap: 8px; }

/* ============================================================
   Full-page modules (body.os-fullpage) — the module owns the whole
   viewport: light surface edge-to-edge, sticky app bar, no floating card.
   ============================================================ */
body.os-fullpage { background: linear-gradient(180deg, #f7fcff, #eaf8ff) !important; }
/* A module owns the WHOLE viewport (owner bug B3): lift the phone-column
   max-width cap so modules go edge-to-edge on tablets/wide windows instead of
   a narrow centered column. No effect ≤460px (phones), so golden masters and
   the on-phone look are unchanged. */
.os-fullpage .app-shell { padding: 0; color: var(--ink); max-width: none; }
.os-fullpage .page { padding-bottom: 88px; }
.os-fullpage .homeos-card.homeos-page,
.os-fullpage .meals-card.meals-page { margin: 0; }
.os-fullpage .homeos-shell,
.os-fullpage .meals-shell {
  border-radius: 0; box-shadow: none; border: 0;
  min-height: 100dvh; padding: 0 16px 28px;
}
.os-fullpage .cal-card { margin: 0; border-radius: 0; box-shadow: none; min-height: 100dvh; }
/* App bar breaks out to the viewport edges and sticks to the top. */
.os-fullpage .homeos-shell > .os-breadcrumb,
.os-fullpage .meals-header > .os-breadcrumb {
  position: sticky; top: 0; z-index: 30;
  margin: 0 -16px 16px;
  padding: max(12px, env(safe-area-inset-top)) 14px 11px;
  background: rgba(247, 252, 255, 0.93);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid rgba(35, 60, 65, 0.08);
}
.os-fullpage .meals-header { gap: 0; }

/* --- OS DASHBOARD shared --------------------------------------- */
.os-page .homeos-shell { min-height: calc(100dvh - 112px); }

/* HomeOS / OS dashboard text colors — dark on light shells */
.homeos-shell { color: var(--ink); }
.homeos-shell .folder-title { color: var(--ink); }
.homeos-shell .folder-line  { color: var(--ink-3); }
.homeos-card .homeos-shell p { color: var(--ink); }
.homeos-card .homeos-shell .folder-line { color: var(--ink-3); }
.meals-shell .folder-title { color: var(--ink); }
.meals-shell .folder-line { color: var(--ink-3); }

/* ============================================================
   HomeOS typography scale — ONE size for page headings, ONE for
   sub-headings, everywhere (dashboard, chores, calendar, meals,
   supplies, vendors, bills, notifications, menu, settings).
   ============================================================ */
.homeos-shell .folder-title,
.meals-shell  .folder-title,
.os-shell     .folder-title,
.hx-scope     .folder-title.hx-page-title,
.homeos-cal-card .cal-title,
.hx-sheet-title {
  font-size: 23px;
  font-weight: 760;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
/* Sub-line under a page title */
.homeos-shell .folder-line,
.meals-shell  .folder-line,
.os-shell     .folder-line { font-size: 13px; }
.hx-grp,
.hx-pick-grp {
  margin: 8px 0 7px;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.hx-grphead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 14px 2px 8px;
  color: var(--ink-3);
}
.hx-grphead h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-3);
}
.hx-grphead span {
  font-size: 12px;
  font-weight: 650;
  color: var(--ink-4);
}
/* Dashboard greeting (with name) — small, not a page heading */
.homeos-shell .folder-title.greeting-title { font-size: 15px; font-weight: 700; letter-spacing: -0.01em; }
/* Section sub-headings — readable, consistent (18px, item 5) */
.os-section-title { font-size: 18px; margin: 24px 0 11px; }
.os-section-title svg { width: 19px; height: 19px; }
.sample-badge {
  display: inline-block;
  vertical-align: middle;
  margin-left: 8px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-dark, #117d74);
  background: rgba(53, 202, 187, 0.14);
  border: 1px solid rgba(53, 202, 187, 0.3);
}
.os-stat-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 6px;
}
.os-stat {
  padding: 13px 12px 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(35, 60, 65, 0.06);
  min-height: 84px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.os-stat-kicker {
  font-size: 10.5px;
  color: var(--ink-3);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.os-stat strong {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--ink);
  display: block;
  margin-top: 4px;
}
.os-stat em {
  font-style: normal;
  font-size: 11px;
  color: var(--ink-3);
  margin-top: 4px;
  display: block;
}

.os-section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 24px 0 11px;
  font-size: 18px;
  font-weight: 700;
  color: var(--ink-3);
  letter-spacing: -0.01em;
}
.os-section-title svg { width: 19px; height: 19px; color: var(--accent-dark); }
.os-section-title span { display: inline-flex; align-items: center; justify-content: center; }

.os-card-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.os-card-list.muted .os-list-card { opacity: 0.78; }

.os-list-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 13px 14px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(35, 60, 65, 0.06);
  text-align: left;
  cursor: pointer;
  transition: background 160ms ease, transform 120ms ease, border-color 160ms ease;
}
.os-list-card:hover { background: rgba(255, 255, 255, 0.88); border-color: rgba(35, 60, 65, 0.14); }
.os-list-card strong {
  display: block;
  font-size: 13.5px;
  font-weight: 650;
  color: var(--ink);
  letter-spacing: -0.005em;
}
.os-list-card em {
  display: block;
  margin-top: 3px;
  font-style: normal;
  font-size: 11px;
  color: var(--ink-3);
}
.os-list-card.sorted { cursor: default; }

.os-pill {
  align-self: center;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(35, 60, 65, 0.08);
  color: var(--ink-2);
  border: 1px solid transparent;
  white-space: nowrap;
}
.os-pill.due  { background: #ffe7d6; color: #a44b1f; }
.os-pill.warn { background: #fff3cf; color: #946800; }
.os-pill.ok   { background: #d4f5e1; color: #1f6c44; }
.os-pill.soft { background: rgba(35, 60, 65, 0.08); color: var(--ink-2); }
.os-pill.family-tag   { background: rgba(186, 110, 162, 0.18); color: #7d3a6a; }
.os-pill.personal-tag { background: rgba(126, 114, 186, 0.18); color: #4d4286; }
.os-pill.home-tag     { background: rgba(86,  158, 152, 0.20); color: #1d5e58; }

.os-tile-card {
  margin-top: 6px;
  padding: 16px 18px;
  width: 100%;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(35, 60, 65, 0.06);
  text-align: left;
  cursor: pointer;
}
.os-tile-card strong { display: block; font-size: 14px; font-weight: 700; color: var(--ink); }
.os-tile-card em { display: block; margin-top: 5px; font-style: normal; font-size: 11.5px; color: var(--ink-3); }

/* People row (Family) */
.os-people-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.os-person {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 4px 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(35, 60, 65, 0.06);
  cursor: pointer;
}
.os-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--av, #c8a8e9);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: -0.01em;
}
.os-person strong { font-size: 11.5px; font-weight: 650; color: var(--ink); }
.os-person em { font-style: normal; font-size: 10px; color: var(--ink-3); }

/* PersonalOS / FamilyOS / BrainDump shell backgrounds — tinted, lighter than HomeOS */
.os-shell {
  background: radial-gradient(circle at 86% 2%, rgba(222, 246, 255, 0.9), transparent 25%),
              linear-gradient(180deg, #f7fcff, #eaf8ff);
}
.personal-shell {
  background: radial-gradient(circle at 90% 2%, rgba(232, 220, 255, 0.9), transparent 28%),
              linear-gradient(180deg, #fbfaff, #efeaff);
}
.family-shell {
  background: radial-gradient(circle at 90% 2%, rgba(255, 220, 240, 0.85), transparent 28%),
              linear-gradient(180deg, #fff7fb, #fbe9f1);
}
.brain-shell {
  background: radial-gradient(circle at 90% 2%, rgba(255, 232, 200, 0.85), transparent 28%),
              linear-gradient(180deg, #fffbf3, #fff0d8);
}

/* BrainDump capture button */
.brain-capture {
  display: grid;
  grid-template-columns: 36px 1fr;
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 12px;
  width: 100%;
  margin-bottom: 10px;
  padding: 16px 16px;
  border-radius: 18px;
  background: linear-gradient(135deg, #fff1d9, #ffe1b8);
  border: 1px solid rgba(35, 60, 65, 0.06);
  text-align: left;
  cursor: pointer;
}
.brain-capture-icon {
  grid-row: 1 / span 2;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.7);
  display: inline-flex; align-items: center; justify-content: center;
  color: #8c6122;
}
.brain-capture strong { font-size: 14px; color: var(--ink); }
.brain-capture em { font-style: normal; font-size: 11.5px; color: #7a5a25; }

/* --- HOMEOS CHORES -------------------------------------------- */

.chores-tab {
  flex: 1;
  padding: 9px 10px;
  border-radius: 999px;
  border: 1px solid rgba(35,60,65,0.10);
  background: rgba(255,255,255,0.65);
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
}
.chores-tab.active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.chore-card {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(35,60,65,0.06);
}
.chore-time {
  font-variant-numeric: tabular-nums;
  font-weight: 650;
  font-size: 13px;
  color: var(--ink);
}
.chore-body strong { display: block; font-size: 13.5px; color: var(--ink); font-weight: 650; }
.chore-body em { display: block; margin-top: 3px; font-style: normal; font-size: 11px; color: var(--ink-3); }

/* --- CALENDAR -------------------------------------------------- */
.cal-card {
  margin-top: 14px;
  padding: 16px 14px 22px;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,0.16);
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(28px) saturate(135%);
  -webkit-backdrop-filter: blur(28px) saturate(135%);
  box-shadow: var(--shadow);
  color: var(--text-inverse);
}
.cal-header { padding: 4px 4px 6px; }
.cal-header .os-breadcrumb {
  color: rgba(255,255,255,0.7);
}
.cal-header .os-crumb-sep { color: rgba(255,255,255,0.35); }
.cal-header .os-crumb-current { color: var(--text-inverse); }

.cal-title { margin: 4px 0 2px; font-size: 14.5px; font-weight: 650; letter-spacing: -0.01em; }
.cal-sub { margin: 0 0 12px; font-size: 12px; color: rgba(255,255,255,0.65); }

.cal-week-strip {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-bottom: 12px;
}
.cal-week-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 0;
  border-radius: 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  cursor: pointer;
  transition: background 160ms ease;
}
.cal-week-head:hover { background: rgba(255,255,255,0.12); }
.cal-week-head.today {
  background: rgba(53, 202, 187, 0.22);
  border-color: rgba(53, 202, 187, 0.55);
}
.cal-wd { font-size: 10px; font-weight: 650; color: rgba(255,255,255,0.7); letter-spacing: 0.06em; }
.cal-dn { font-size: 16px; font-weight: 700; margin-top: 2px; color: var(--text-inverse); }
.cal-week-head.today .cal-dn { color: var(--accent); }

/* Week navigation (live calendar) */

.cal-week-nav .cal-week-strip { flex: 1; margin-bottom: 0; }

.cal-week-head { position: relative; }
.cal-week-head.selected { background: var(--text-inverse); border-color: var(--text-inverse); }
.cal-week-head.selected .cal-wd { color: rgba(35,60,65,0.7); }
.cal-week-head.selected .cal-dn { color: var(--ink, #1a2b2e); }
.cal-dot-count {
  position: absolute; bottom: 4px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 4px; border-radius: 50%; background: var(--accent);
}
.cal-week-head.selected .cal-dot-count { background: var(--accent-dark, #1f8a7e); }
.cal-empty-day { text-align: center; color: rgba(255,255,255,0.6); font-size: 12.5px; padding: 18px 0 4px; }

/* Month selector button (item 2) — centered, 18px, opens the month picker */
.cal-month-btn {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin: 2px auto 12px; padding: 6px 12px; border-radius: 999px;
  background: transparent; border: 0; cursor: pointer; color: var(--ink, #1a2b2e);
}
.cal-month-label { font-size: 18px; font-weight: 750; letter-spacing: -0.01em; }
.cal-month-chev { font-size: 12px; opacity: 0.6; }
.homeos-cal-card .cal-month-btn:hover { background: rgba(35,60,65,0.06); }

/* Month-grid picker — overlay dropdown anchored under the month button (does
   not push the week strip / timeline down). */
.cal-month-wrap { position: relative; display: flex; flex-direction: column; align-items: center; }
.cal-mp-pop {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%); z-index: 40;
  margin-top: 6px; width: min(92vw, 340px); background: #fff;
  border: 1px solid rgba(35,60,65,0.1); border-radius: 18px; padding: 14px 14px 16px;
  box-shadow: 0 18px 44px -14px rgba(8,27,32,0.4);
}
.cal-mp-head { display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; margin-bottom: 12px; }
.cal-mp-title { text-align: center; font-size: 17px; font-weight: 760; color: var(--ink); }
.cal-mp-nav {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid rgba(35,60,65,0.12); background: #fff; color: var(--accent-dark);
  font-size: 20px; line-height: 1; cursor: pointer;
}
.cal-mp-nav:disabled { opacity: 0.3; cursor: default; }
.cal-mp-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-mp-wds { margin-bottom: 6px; }
.cal-mp-wd { text-align: center; font-size: 11px; font-weight: 700; color: var(--ink-4); letter-spacing: 0.04em; }
.cal-mp-day {
  aspect-ratio: 1 / 1; display: grid; place-items: center; border: 0; background: transparent;
  border-radius: 11px; font-size: 14px; font-weight: 600; color: var(--ink); cursor: pointer;
  font-family: inherit;
}
.cal-mp-day:hover:not(.empty):not(.off) { background: rgba(53,202,187,0.16); }
.cal-mp-day.empty { visibility: hidden; }
.cal-mp-day.off { color: #c4cfd2; cursor: default; }
.cal-mp-day.today { color: var(--accent-dark); font-weight: 800; }
.cal-mp-day.sel { background: var(--accent-dark, #1f8a7e); color: #fff; }

/* All-day band */
.cal-allday {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 8px;
  margin-bottom: 12px;
}
.cal-allday-label {
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  align-self: center;
}
.cal-allday-track {
  position: relative;
  min-height: 76px;
  padding: 6px 0;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
}
.cal-allday-cols {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  pointer-events: none;
}
.cal-allday-col {
  border-right: 1px dashed rgba(255,255,255,0.06);
}
.cal-allday-col:last-child { border-right: 0; }
.cal-allday-band {
  position: relative;
  display: block;
  margin: 4px 2px;
  padding: 7px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.18);
  color: rgba(20, 32, 36, 0.92);
  text-align: left;
  cursor: pointer;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.2;
}
.cal-allday-title { display: block; }
.cal-allday-note { display: block; font-size: 9.5px; font-weight: 550; opacity: 0.8; margin-top: 2px; }

.cal-allday-band.family   { background: rgba(226, 180, 208, 0.55); }
.cal-allday-band.home     { background: rgba(170, 222, 214, 0.55); }
.cal-allday-band.personal { background: rgba(186, 172, 232, 0.55); }
.cal-allday-band.brain    { background: rgba(230, 198, 158, 0.55); }

/* Day grid */
.cal-grid-wrap {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 8px;
  margin-top: 6px;
}
.cal-hours {
  display: grid;
  grid-auto-rows: calc(var(--cal-row-h, 36px) * 2);
  font-size: 10px;
  color: rgba(255,255,255,0.55);
  font-weight: 600;
  letter-spacing: 0.04em;
  padding-top: 4px;
}
.cal-hour-label {
  display: block;
  text-align: right;
  padding-right: 6px;
  border-top: 1px solid transparent;
}
.cal-grid {
  position: relative;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  height: calc(var(--cal-rows, 28) * var(--cal-row-h, 36px));
  overflow: hidden;
}
.cal-lines {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: repeat(var(--cal-rows, 28), 1fr);
  pointer-events: none;
}
.cal-half-line {
  border-top: 1px solid transparent;
}
.cal-half-line.on-hour { border-top-color: rgba(255,255,255,0.10); }
.cal-half-line.on-half { border-top-color: rgba(255,255,255,0.04); }
.cal-events { position: absolute; inset: 0; }
.cal-event {
  position: absolute;
  border-radius: 8px;
  padding: 6px 8px;
  border: 1px solid rgba(255,255,255,0.20);
  color: rgba(18, 30, 34, 0.94);
  text-align: left;
  cursor: pointer;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.2;
  overflow: hidden;
  transition: transform 160ms ease;
}
.cal-event:hover { transform: translateY(-1px); }
.cal-event-title { display: block; }
.cal-event-time {
  display: block;
  font-size: 9.5px;
  font-weight: 550;
  opacity: 0.75;
  margin-top: 2px;
  font-variant-numeric: tabular-nums;
}
.cal-event.home     { background: rgba(170, 222, 214, 0.80); }
.cal-event.family   { background: rgba(226, 180, 208, 0.80); }
.cal-event.personal { background: rgba(186, 172, 232, 0.80); }
.cal-event.brain    { background: rgba(230, 198, 158, 0.80); }

/* State-coloured events (HomeOS calendar) */
.cal-event.st-done     { background: #b6dcc0; border-color: rgba(40,90,60,0.28); color: #143524; }
.cal-event.st-sched    { background: #aedbe8; border-color: rgba(30,80,95,0.26); color: #123038; }
.cal-event.st-overdue  { background: #ecb7b0; border-color: rgba(120,40,30,0.30); color: #471812; }
.cal-event.st-cannotdo { background: #cfd3d6; border-color: rgba(50,60,65,0.26); color: var(--ink-1); }
.cal-event.st-progress { background: #ecd2a6; border-color: rgba(120,80,20,0.26); color: #41300c; }
.cal-event.st-done .cal-event-title { text-decoration: line-through; text-decoration-color: rgba(20,53,36,0.4); }
.cal-event-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; margin-top: 2px; }
.cal-event-state { font-size: 8.5px; font-weight: 750; letter-spacing: 0.03em; text-transform: uppercase; opacity: 0.72; white-space: nowrap; }

/* Horizontal-scroll grid for overlapping tasks */
.hcal-grid.scrollable { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.hcal-grid.scrollable::-webkit-scrollbar { height: 6px; }
.hcal-grid.scrollable::-webkit-scrollbar-thumb { background: rgba(35,60,65,0.25); border-radius: 999px; }
.cal-grid-inner { position: relative; height: 100%; min-width: 100%; }
.cal-scroll-cue { margin: 8px 4px 0; font-size: 10.5px; font-weight: 600; color: var(--ink-3); letter-spacing: 0.01em; }

.legend-dot.st-done     { background: #b6dcc0; }
.legend-dot.st-sched    { background: #aedbe8; }
.legend-dot.st-overdue  { background: #ecb7b0; }
.legend-dot.st-cannotdo { background: #cfd3d6; }

/* Now indicator */
.cal-now {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--accent);
  z-index: 2;
}
.cal-now span {
  position: absolute;
  left: -4px;
  top: -4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(53,202,187,0.18);
}

.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin: 14px 4px 0;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.72);
}
.legend-dot {
  display: inline-block;
  width: 10px; height: 10px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}
.legend-dot.home     { background: rgba(170, 222, 214, 0.85); }
.legend-dot.family   { background: rgba(226, 180, 208, 0.85); }
.legend-dot.personal { background: rgba(186, 172, 232, 0.85); }
.legend-dot.brain    { background: rgba(230, 198, 158, 0.85); }

/* --- MEALS ----------------------------------------------------- */
.meals-card {
  margin-top: 22px;
  border-radius: 30px;
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
}
.meals-shell {
  background: radial-gradient(circle at 86% 2%, rgba(222, 246, 255, 0.9), transparent 25%),
              linear-gradient(180deg, #f7fcff, #eaf8ff);
  border-radius: 30px;
  padding: 18px 16px 28px;
  border: 1px solid rgba(35,60,65,0.06);
  box-shadow: var(--shadow);
  color: var(--ink);
  min-height: calc(100dvh - 112px);
}

.meals-header { display: flex; flex-direction: column; gap: 10px; }
.meals-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.meals-tabs::-webkit-scrollbar { display: none; }
.meals-tab {
  flex: 0 0 auto;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(35,60,65,0.10);
  background: rgba(255,255,255,0.7);
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease;
  white-space: nowrap;
}
.meals-tab.active {
  background: var(--accent-dark, #1f8a7e);
  color: #fff;
  border-color: var(--accent-dark, #1f8a7e);
}

.meals-hero {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px;
  margin: 14px 0 12px;
}
.meals-hero .folder-title { color: var(--ink); }
.meals-hero .folder-line { color: var(--ink-3); }
.meal-replan {
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.8);
  border: 1px solid rgba(35,60,65,0.10);
  color: var(--ink);
  font-size: 11.5px;
  font-weight: 650;
  cursor: pointer;
}
.meal-replan:hover { background: #fff; }

.meal-edit {
  padding: 7px 12px;
  border-radius: 999px;
  background: transparent;
  border: 1px solid rgba(35,60,65,0.14);
  color: var(--ink);
  font-size: 11px;
  font-weight: 650;
  cursor: pointer;
}
.meal-edit:hover { background: rgba(35,60,65,0.06); }

/* Week */
.week-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.week-day-card {
  padding: 12px 14px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(35,60,65,0.06);
}
.week-day-head {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  margin-bottom: 6px;
}
.week-day-head strong { color: var(--ink-3); font-weight: 700; }
.week-day-head span { color: var(--ink-4); }
.week-day-meals {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.week-day-meals li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--ink);
}
.week-meal-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(53,202,187,0.18);
  color: var(--accent-dark);
  font-size: 10px;
  font-weight: 700;
  flex-shrink: 0;
}

/* Previous */
.prev-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.prev-plan-card {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(35,60,65,0.06);
  text-align: left;
  cursor: pointer;
}

.prev-plan-card strong { display: block; font-size: 13.5px; color: var(--ink); font-weight: 650; }
.prev-plan-card em { display: block; margin-top: 3px; font-style: normal; font-size: 11px; color: var(--ink-3); }

.prev-foot { margin-top: 14px; font-size: 11px; color: var(--ink-3); }

/* Ingredients */
.ing-sort {
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(35,60,65,0.10);
  background: rgba(255,255,255,0.8);
  color: var(--ink);
  font-size: 11.5px;
  font-weight: 650;
  cursor: pointer;
}
.cat-chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
  margin-bottom: 12px;
}
.cat-chips::-webkit-scrollbar { display: none; }
.cat-chip {
  flex: 0 0 auto;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(35,60,65,0.10);
  background: rgba(255,255,255,0.7);
  color: var(--ink);
  font-size: 11.5px;
  font-weight: 650;
  cursor: pointer;
  white-space: nowrap;
}
.cat-chip.active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}

.ing-list {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(35,60,65,0.06);
}
.ing-row {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) 60px 80px 64px;
  gap: 8px;
  align-items: center;
  padding: 10px 12px;
  background: rgba(255,255,255,0.6);
  font-size: 12px;
  color: var(--ink);
}
.ing-row:nth-child(odd) { background: rgba(255,255,255,0.4); }

/* Ingredients → Supplies export (multi-select) */
.meals-hero-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; align-items: center; }

.ing-list.selecting .ing-row { grid-template-columns: 26px minmax(0, 1.4fr) 56px 76px 60px; }

.ing-sel-bar .mp-generate, .ing-sel-bar .mp-bridge-btn { flex: 1; margin: 0; justify-content: center; }
.ing-sel-bar .mp-bridge-btn { padding: 15px; border-radius: 16px; font-size: 14px; font-weight: 600; }

/* Ingredients: this-week / next-week segmented toggle (item 3) */
.ing-week-toggle { display: flex; gap: 4px; padding: 4px; margin: 0 0 14px; background: rgba(35,60,65,0.06); border-radius: 12px; }
.ing-week-tab { flex: 1; padding: 9px; border: 0; border-radius: 9px; background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 650; font-family: inherit; cursor: pointer; }
.ing-week-tab.active { background: #fff; color: var(--ink, #14302f); box-shadow: 0 1px 3px rgba(2,10,12,0.12); }
@media (max-width: 430px) { .ing-list.selecting .ing-row { grid-template-columns: 24px minmax(0, 1.2fr) 46px 64px 52px; } }
.ing-name { font-weight: 650; }
.ing-qty {
  font-variant-numeric: tabular-nums;
  color: var(--ink-3);
  font-size: 11.5px;
}
.ing-cat {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
  text-align: center;
  background: rgba(35,60,65,0.08);
  color: var(--ink-2);
}
.ing-cat.cat-produce { background: #e1f5dc; color: #3c6b29; }
.ing-cat.cat-protein { background: #fcdacf; color: #8a3a20; }
.ing-cat.cat-dairy   { background: #e6f0ff; color: #2e508a; }
.ing-cat.cat-grains  { background: #f3e9d2; color: #7a5a1f; }
.ing-cat.cat-spices  { background: #f8d8c2; color: #8a4a1f; }
.ing-cat.cat-pantry  { background: #ece4f5; color: #4d3a73; }

.ing-foot { margin-top: 4px; font-size: 11px; color: var(--ink-3); line-height: 1.45; }

/* Quick commerce card */
.qc-card {
  margin-top: 18px;
  padding: 18px 18px 16px;
  border-radius: 22px;
  background: linear-gradient(135deg, #ffffff, #eef8fc);
  border: 1px dashed rgba(35,60,65,0.22);
  color: var(--ink);
}
.qc-card.qc-compact { margin-top: 6px; }
.qc-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}
.qc-head .eyebrow { margin: 0; font-size: 10px; }
.qc-head h3 { margin: 4px 0 4px; font-size: 14.5px; letter-spacing: -0.015em; line-height: 1.25; }
.qc-sub { margin: 0; font-size: 11.5px; color: var(--ink-3); }
.qc-sub em { font-style: italic; color: var(--ink-4); }
.qc-badge {
  align-self: start;
  padding: 5px 10px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(180, 70, 40, 0.10);
  color: #a44b1f;
  border-radius: 999px;
  white-space: nowrap;
}
.qc-providers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 14px 0 10px;
}
.qc-provider {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  padding: 10px;
  border-radius: 14px;
  background: rgba(255,255,255,0.6);
  border: 1px solid rgba(35,60,65,0.08);
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
  cursor: not-allowed;
  opacity: 0.85;
}
.qc-dot {
  width: 10px; height: 10px; border-radius: 50%; background: #ccc;
}
.qc-dot.blinkit   { background: #ffd23f; }
.qc-dot.zepto     { background: #6a4aff; }
.qc-dot.instamart { background: #f96f3f; }
.qc-primary {
  display: block;
  width: 100%;
  padding: 12px;
  border-radius: 999px;
  background: rgba(35,60,65,0.10);
  border: 1px solid rgba(35,60,65,0.10);
  color: var(--ink-2);
  font-size: 12.5px;
  font-weight: 700;
  cursor: not-allowed;
  letter-spacing: 0.01em;
}

/* Small screen polish */
@media (max-width: 430px) {
  .os-stat-row { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .os-stat { padding: 11px 10px; }
  .os-stat strong { font-size: 22px; }
  .os-people-row { grid-template-columns: repeat(4, 1fr); }
  
  .ing-row { grid-template-columns: minmax(0, 1.2fr) 50px 70px 60px; }
}

/* =================================================================
   v3 — final direction: Quiet Night (Xortit shell) × Sky (HomeOS).
   Pastel manila folders in 2x2 grid (file shape with tab).
   This block sits last and authoritatively overrides earlier rules.
   ================================================================= */

/* Quiet Night tokens */
/* Quiet Night tokens live in src/styles/tokens.css (§9.1 token merge). */


/* Page background → Quiet Night radial gradient */
html, body {
  background:
    radial-gradient(120% 90% at 20% 0%, #1d3735 0%, #0e1f1e 60%, #0a1716 100%) no-repeat fixed;
  background-color: var(--night-bg-flat);
  color: var(--night-ink);
}
.app-shell {
  color: var(--night-ink);
}
.page, .public-page {
  background: transparent;
}

/* Topbar — clean, brand centered */
.topbar {
  background: transparent;
  border: 0;
}
.topbar .brand,
.topbar .brand-button {
  color: var(--night-ink) !important;
  letter-spacing: 0.18em;
  font-weight: 700;
  font-size: 13.5px;
  background: transparent;
  border: 0;
}
.topbar .icon-button {
  background: var(--night-glass-strong);
  border: 1px solid var(--night-border);
  color: var(--night-ink2);
}

/* Dashboard hero copy */
.hero-copy.dashboard-hero,
.public-title-block {
  color: var(--night-ink);
}
.greeting {
  color: var(--night-ink);
  font-weight: 700;
  letter-spacing: -0.025em;
}
.support-copy, .launch-line, .subtagline {
  color: var(--night-ink2);
}
.action-tile {
  display: flex !important;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 16px 18px !important;
  border-radius: 22px !important;
  background: var(--night-glass) !important;
  border: 1px solid var(--night-border) !important;
  box-shadow: 0 16px 36px -22px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.05) !important;
  color: var(--night-ink) !important;
  text-align: left !important;
  min-height: 138px;
  transition: transform 160ms ease, background 160ms ease;
}
.action-tile:hover {
  transform: translateY(-2px);
  background: var(--night-glass-strong) !important;
  border-color: var(--night-border) !important;
}
.action-icon {
  width: 36px !important;
  height: 36px !important;
  border-radius: 12px !important;
  background: var(--mint-glow) !important;
  display: grid !important;
  place-items: center !important;
  color: var(--mint) !important;
  margin: 0 !important;
}
.attention-demo .action-icon {
  background: rgba(212,200,232,0.22) !important;
  color: #D4C8E8 !important;
}
.action-title {
  font-size: 18px !important;
  font-weight: 700 !important;
  letter-spacing: -0.015em !important;
  color: var(--night-ink) !important;
  margin: 4px 0 0 !important;
}
.action-copy {
  font-size: 12.5px !important;
  color: var(--night-ink3) !important;
  line-height: 1.4 !important;
  margin: 0 !important;
}
.action-copy b { color: var(--night-ink); font-weight: 700; }
.attention-meter {
  width: 100%; height: 4px;
  background: rgba(255,255,255,0.10);
  border-radius: 999px; overflow: hidden;
  margin-top: 6px;
}
.attention-meter i {
  display: block; height: 100%; width: 60%;
  background: linear-gradient(180deg, #A6F0DA 0%, #4DD6C0 100%);
  border-radius: 999px;
  animation: none;
}

/* Section heading above folder grid */
.folder-section-title {
  display: flex; align-items: center; justify-content: space-between;
  margin: 30px 4px 14px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--night-ink3);
}
.folder-section-title .see-all {
  color: var(--mint);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0;
  text-transform: none;
}

/* =============== FOLDER GRID (2×2 manila cards) ================= */

/* Nuke the previous absolute stack rules */
.folder-stack,
.public-folder-stack,
.dashboard-folder-stack,
.compact-public-stack {
  height: auto !important;
  position: static !important;
  margin: 0 !important;
}
.folder-stack > .folder,
.public-folder-stack > .folder,
.compact-public-stack > .folder {
  position: static !important;
  transform: none !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
}

.folder-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 16px;
  row-gap: 26px;
  margin: 14px 0 120px;
}

.folder-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
  margin-top: 13px;
  padding: 18px 17px 16px;
  min-height: 172px;
  border-radius: 4px 18px 18px 18px;
  border: 1px solid rgba(255,255,255,0.08);
  text-align: left;
  cursor: grab;
  user-select: none;
  touch-action: pan-y;
  -webkit-tap-highlight-color: transparent;
  box-shadow: 0 20px 40px -22px rgba(2,10,12,0.7), inset 0 1px 0 rgba(255,255,255,0.05);
  overflow: visible;
}
/* Folder TAB sticking out the top-left — shape only, name stays inside the card */
.folder-card::after {
  content: '';
  position: absolute;
  top: -11px; left: 0;
  width: 58px; height: 14px;
  border-radius: 7px 7px 0 0;
  border: 1px solid rgba(255,255,255,0.08);
  border-bottom: 0;
  z-index: -1;
  box-shadow: 0 -3px 7px -4px rgba(2,10,12,0.5);
}
.folder-card::before {
  /* soft top sheen — the glassy module tint */
  content: '';
  position: absolute; inset: 0;
  border-radius: inherit;
  background: radial-gradient(120% 80% at 0% 0%, rgba(255,255,255,0.07), transparent 60%);
  pointer-events: none;
}
.folder-card:active { cursor: grabbing; }

/* Header inside the card: accent bar · name+subtitle · icon */
.folder-card .folder-head {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 9px;
}
.folder-card .folder-accent {
  width: 4px; height: 30px;
  border-radius: 3px;
  margin-top: 1px;
}
.folder-card .folder-headings {
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.folder-card .folder-name {
  font-size: 16px;
  font-weight: 720;
  letter-spacing: -0.01em;
  line-height: 1.1;
}
.folder-card .folder-subtitle {
  font-size: 11px;
  font-weight: 500;
  line-height: 1.25;
  opacity: 0.66;
}
.folder-card .folder-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px;
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
}
.folder-card .folder-icon svg { width: 15px; height: 15px; }

/* Foot inside the card: signal pill + open count */
.folder-card .folder-foot {
  position: relative; z-index: 1;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 8px;
}
.folder-card .folder-signal-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 9px;
  border-radius: 9px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.07);
  max-width: 74%;
}
.folder-card .folder-signal-dot { width: 6px; height: 6px; border-radius: 50%; flex: 0 0 auto; }
.folder-card .folder-signal-text {
  font-size: 10.5px; font-weight: 550; line-height: 1.25;
  opacity: 0.82;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.folder-card .folder-count {
  display: inline-flex; align-items: baseline; gap: 4px; flex: 0 0 auto;
}
.folder-card .folder-count b {
  font-size: 28px; line-height: 1; letter-spacing: -0.03em; font-weight: 740;
}
.folder-card .folder-count em {
  font-style: normal; font-size: 9px; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.5;
}

/* Drag affordance */
.folder-card.dragging {
  opacity: 0.97; cursor: grabbing; pointer-events: none;
  box-shadow: 0 34px 60px -14px rgba(0,0,0,0.7), 0 0 0 2px rgba(255,255,255,0.4);
}
.folder-card.drag-over { outline: 2px solid var(--mint); outline-offset: 2px; }

/* Long-press armed: the folder lifts + wiggles to signal “now you can rearrange”. */
.folder-card.armed {
  cursor: grabbing;
  box-shadow: 0 28px 54px -16px rgba(0,0,0,0.7), 0 0 0 2px var(--mint);
  animation: folder-armed-wiggle 480ms ease-in-out 1;
}
.folder-card.armed.dragging { animation: none; }
@keyframes folder-armed-wiggle {
  0% { transform: scale(1); }
  30% { transform: scale(1.05) rotate(-1.1deg); }
  60% { transform: scale(1.04) rotate(1deg); }
  100% { transform: scale(1.04) rotate(0deg); }
}
@media (prefers-reduced-motion: reduce) { .folder-card.armed { animation: none; } }

/* Per-module glassy face + accent (corporate dark) */
.folder-card.folder-home     { background: var(--f-home-face);     color: var(--f-home-ink); }
.folder-card.folder-home::after { background: var(--f-home-tab); }
.folder-card.folder-personal::after { background: var(--f-personal-tab); }
.folder-card.folder-family::after   { background: var(--f-family-tab); }
.folder-card.folder-brain::after    { background: var(--f-brain-tab); }
.folder-card.folder-home     .folder-accent,
.folder-card.folder-home     .folder-signal-dot { background: var(--f-home-hue); }
.folder-card.folder-home     .folder-icon { color: var(--f-home-hue); }
.folder-card.folder-personal { background: var(--f-personal-face); color: var(--f-personal-ink); }
.folder-card.folder-personal .folder-accent,
.folder-card.folder-personal .folder-signal-dot { background: var(--f-personal-hue); }
.folder-card.folder-personal .folder-icon { color: var(--f-personal-hue); }
.folder-card.folder-family   { background: var(--f-family-face);   color: var(--f-family-ink); }
.folder-card.folder-family   .folder-accent,
.folder-card.folder-family   .folder-signal-dot { background: var(--f-family-hue); }
.folder-card.folder-family   .folder-icon { color: var(--f-family-hue); }
.folder-card.folder-brain    { background: var(--f-brain-face);    color: var(--f-brain-ink); }
.folder-card.folder-brain    .folder-accent,
.folder-card.folder-brain    .folder-signal-dot { background: var(--f-brain-hue); }
.folder-card.folder-brain    .folder-icon { color: var(--f-brain-hue); }

/* Bottom nav — night glass pill (not Sky) */
.bottom-nav {
  background: rgba(16, 30, 30, 0.72) !important;
  backdrop-filter: blur(22px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(22px) saturate(140%) !important;
  border: 1px solid var(--night-border) !important;
  box-shadow: 0 18px 40px -18px rgba(0,0,0,0.55) !important;
}
.bottom-nav .nav-item {
  color: var(--night-ink3) !important;
}
.bottom-nav .nav-item.active {
  color: var(--mint) !important;
  background: var(--mint-glow-soft) !important;
}

/* Xortit 5-slot switcher nav (owner Xortit-Home-Handoff §4, 2026-07-17) */
.bottom-nav.xh-nav { grid-template-columns: repeat(5, 1fr); overflow: visible; }
.bottom-nav.xh-nav.staff-homeos-nav { grid-template-columns: repeat(3, 1fr); }
.bottom-nav .nav-module.active { color: var(--nav-hue) !important; background: transparent !important; }
.bottom-nav .nav-module.active .nav-label { color: var(--nav-hue); }
/* Say-it centre halo — raised teal orb with a page-colour ring */
.bottom-nav .nav-halo { justify-self: center; align-self: center; border: 0; background: none; padding: 0; cursor: pointer; transform: translateY(-15px); }
.bottom-nav .nav-halo-orb {
  width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle at 50% 34%, #6ff0d6, #17998a 72%);
  box-shadow: 0 9px 22px -6px rgba(84,224,200,0.55), 0 0 0 4px rgba(16,30,30,0.9);
  color: #06231e;
}
.bottom-nav .nav-halo-orb svg { width: 22px; height: 22px; }
.bottom-nav .nav-halo:active { transform: translateY(-15px) scale(0.94); }

/* Calendar card sits on the night bg — slightly more glow */
.cal-card {
  background: rgba(255,255,255,0.04) !important;
  border-color: var(--night-border) !important;
}

/* When the OS-page card sits on night bg, push it into a soft Sky shell */
.homeos-card { background: transparent !important; border: 0 !important; box-shadow: none !important; }

/* Reset some legacy color rules from earlier versions */
.folder-tab-title,
.folder-line,
.folder-title,
.folder-meta { /* legacy classes — no longer used by new folder structure */
  text-shadow: none;
}
.folder.front, .folder.brain, .folder.home, .folder.personal, .folder.family,
.folder::before, .folder::after { all: unset; }
.folder.dragging, .folder.drag-over { all: unset; }

/* Polish */
@media (max-width: 380px) {
  .folder-grid { column-gap: 11px; row-gap: 24px; }
  .folder-card { padding: 14px 13px 12px; min-height: 138px; }
  .folder-card .folder-count b { font-size: 24px; }
}

/* ============================================================
   Public landing polish — Quiet Night, mobile-first, parity with
   "Xortit All Screens" finalised mockups.
   ============================================================ */

.launch-line .mint { color: #7BE5C9; }

.public-title-block .status-pill {
  display: inline-block;
  margin-top: 12px;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(123, 229, 201, 0.12);
  border: 1px solid rgba(123, 229, 201, 0.34);
  color: #7BE5C9;
  font-size: 11px;
  letter-spacing: 0.04em;
  font-weight: 600;
}

.folder-grid-eyebrow {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0 4px 10px;
  color: rgba(223, 235, 236, 0.6);
}
.folder-grid-eyebrow .eyebrow {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  color: rgba(223, 235, 236, 0.72);
}
.folder-grid-eyebrow .folder-grid-hint {
  font-size: 10.5px;
  color: rgba(223, 235, 236, 0.46);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
}

.waitlist-card.waitlist-compact .waitlist-hint {
  margin-top: 4px;
  font-size: 11.5px;
  line-height: 1.45;
  color: rgba(223, 235, 236, 0.6);
}

/* Mic icon size when used as a feature icon (Say it page) */
.large-mic { display: inline-grid; place-items: center; }
.large-mic svg { width: 36px; height: 36px; }

/* Ensure the public landing doesn't crash into the bottom nav.
   .public-page already reserves padding; this rule prevents the
   waitlist card from butting up against the fixed nav. */
.public-page .waitlist-compact { margin-bottom: 26px; }

/* ============================================================
   v3 polish — Anubhuti round 2
   - Lighter, more translucent background
   - Public title hierarchy (headline > subtitle)
   - Centered folder grid + fully visible folder names
   - Subtle floating animation on folders + bottom nav
   - Password field in waitlist form
   - Chore filter/sort, multi-select bar
   - Approvals page, task-state pages
   ============================================================ */

/* --- Lighter, more translucent backdrop ---------------------- */
body {
  background:
    radial-gradient(circle at 78% 4%,  rgba(170, 250, 240, 0.22), transparent 38%),
    radial-gradient(circle at 6% 38%,  rgba(220, 210, 255, 0.16), transparent 44%),
    radial-gradient(circle at 50% 92%, rgba(190, 230, 230, 0.14), transparent 50%),
    linear-gradient(165deg, #2b4448 0%, #36595d 48%, #4a7378 100%) !important;
}
.app-shell { color: #f0f8f8; }

/* --- Public title hierarchy: headline > subtitle ------------- */
.public-title-block .launch-line {
  margin-top: 14px !important;
  font-size: clamp(20px, 5.5vw, 26px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.025em !important;
  color: #f5fbfb !important;
  line-height: 1.15;
  white-space: nowrap;
}
.public-title-block .launch-line .mint { color: #7BE5C9; }
.public-title-block .subtagline {
  margin-top: 6px !important;
  font-size: clamp(11.5px, 3vw, 13px) !important;
  font-weight: 500 !important;
  color: rgba(223, 235, 236, 0.78) !important;
  white-space: normal !important;
  line-height: 1.35;
}
.folder-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  column-gap: 14px !important;
  row-gap: 18px !important;
  max-width: 460px;
  margin: 4px auto 40px !important;
  padding: 0 4px;
  justify-content: center;
}

/* --- Folders sit steady and pop (no floating bob) ------------ */
.folder-grid .folder-card { transition: transform 200ms cubic-bezier(.2,.8,.2,1); }
.folder-grid .folder-card:hover:not(.dragging) { transform: translateY(-4px); }
.folder-grid .folder-card:active { transform: translateY(-1px) scale(0.995); }
.folder-grid .folder-card.dragging { transition: none; }

/* --- Floating, glassy bottom nav on every screen (dark) ------ */
.bottom-nav {
  background: rgba(18, 33, 33, 0.86) !important;
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  box-shadow: 0 16px 44px rgba(4, 14, 16, 0.55), 0 1px 0 rgba(255,255,255,0.08) inset !important;
  animation: nav-float 7s ease-in-out infinite;
}
@keyframes nav-float {
  0%, 100% { transform: translate(-50%, 0); }
  50%      { transform: translate(-50%, -2px); }
}
.bottom-nav .nav-item {
  color: rgba(225, 240, 239, 0.66) !important;
  transition: background 180ms ease, color 180ms ease, transform 220ms ease;
}
.bottom-nav .nav-item .nav-label { color: inherit; }
.bottom-nav .nav-item.active {
  background: rgba(123, 229, 201, 0.16) !important;
  color: var(--mint) !important;
}
.bottom-nav .nav-item:hover:not(.active) { background: rgba(123, 229, 201, 0.08); }
.bottom-nav .nav-item:active { transform: scale(0.96); }

/* --- Password field on waitlist form ------------------------- */
.waitlist-form.compact.with-password {
  grid-template-columns: 1fr;
  gap: 8px;
}
.waitlist-form.compact.with-password input[type="email"],
.waitlist-form.compact.with-password input[type="password"] {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text-inverse);
  font-size: 14px;
}
.waitlist-form.compact.with-password input::placeholder { color: rgba(223, 235, 236, 0.5); }
.waitlist-form.compact.with-password .primary-pill {
  width: 100%;
  min-height: 44px;
  margin-top: 4px;
}
.waitlist-status.error { color: #ff9b80 !important; }

/* --- Waitlist/sign-in card on the LIGHT module sheets --------------
   The with-password inputs above are styled for the Quiet Night (dark)
   background. On the cream .homeos-shell landings (BrainDump, FamilyOS,
   PersonalOS, HomeOS) that made them invisible — white-on-cream (owner
   bug report 2026-07-13). Light-surface treatment, scoped to the shell. */
.homeos-shell .module-waitlist {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(35, 60, 65, 0.1);
  box-shadow: none;
}
.homeos-shell .module-waitlist h2 { color: var(--ink); }
.homeos-shell .waitlist-form.compact.with-password input[type="email"],
.homeos-shell .waitlist-form.compact.with-password input[type="password"] {
  background: #fff;
  border: 1px solid rgba(35, 60, 65, 0.18);
  color: var(--ink);
}
.homeos-shell .waitlist-form.compact.with-password input::placeholder { color: var(--muted); }
.homeos-shell .waitlist-form.compact.with-password input:focus {
  border-color: var(--accent-dark);
  box-shadow: 0 0 0 4px var(--accent-ring);
}
.homeos-shell .module-waitlist .waitlist-status { color: var(--muted); }

/* --- Status pill on public hero ------------------------------ */
.public-title-block .status-pill {
  margin-top: 10px;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.04em;
}

/* --- HomeOS bottom row of task-state pills ------------------- */
.homeos-state-row.second-row {
  grid-template-columns: 1fr;
  margin-top: 8px;
}
.homeos-state-row.second-row .state-pill { max-width: 220px; }

/* --- Chores filter / sort toolbar ---------------------------- */

.chore-cat-chip.active {
  background: #117D74;
  color: #fff;
  border-color: #117D74;
}
.chore-sort {
  flex: 1;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid #d2e3e6;
  background: #fff;
  color: var(--ink-1);
  font-size: 13px;
  font-weight: 600;
}

/* --- Chore card with selectable checkbox --------------------- */
.chores-list .chore-card {
  display: grid;
  grid-template-columns: 28px 56px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid #e2eef0;
  color: var(--ink-1);
  cursor: pointer;
  user-select: none;
  transition: transform 160ms ease, background 200ms ease, box-shadow 200ms ease;
}
.chores-list .chore-card:active { transform: scale(0.99); }
.chores-list .chore-card.selected {
  background: #e2f5f1;
  border-color: #7BE5C9;
  box-shadow: 0 0 0 2px rgba(123, 229, 201, 0.18);
}
.chore-checkbox {
  width: 22px; height: 22px;
  border-radius: 6px;
  border: 1.5px solid #b9cdd0;
  display: grid; place-items: center;
  font-size: 13px;
  font-weight: 700;
  color: #117D74;
  background: #fff;
}
.chores-list .chore-card.selected .chore-checkbox {
  background: #117D74;
  border-color: #117D74;
  color: #fff;
}
.chore-time { font-size: 12px; font-weight: 700; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.chore-body strong { display: block; font-size: 13.5px; font-weight: 650; line-height: 1.25; }
.chore-body em { display: block; margin-top: 2px; font-style: normal; font-size: 11.5px; color: var(--ink-3); }

/* --- Cadence-sectioned chore list (items 1-3) --------------- */
/* --- Page header (item 5): title + round Add/Sort/Filter icon buttons --- */
/* Title row sits under the breadcrumb; title left, round tools right. */

.os-list-head .folder-title { margin: 0; }

.os-head-tools { display: flex; gap: 9px; flex: 0 0 auto; }
.os-head-btn {
  position: relative; width: 40px; height: 40px; border-radius: 50%;
  display: inline-grid; place-items: center; cursor: pointer;
  background: #fff; border: 1px solid rgba(35,60,65,0.1);
  color: #3a5560; box-shadow: 0 2px 8px rgba(35,60,65,0.07);
  transition: background 140ms ease, box-shadow 140ms ease, transform 120ms ease;
}
.os-head-btn:hover { background: #f4fbfa; box-shadow: 0 4px 12px rgba(35,60,65,0.1); }
.os-head-btn:active { transform: scale(0.94); }
.os-head-btn svg { width: 19px; height: 19px; }
/* Sort & Filter are visually secondary → smaller than Add / Menu (item 4) */
.os-head-btn.sm { width: 32px; height: 32px; }
.os-head-btn.sm svg { width: 15px; height: 15px; }
/* Accent + (Plan / Re-plan) — teal-filled so the small icon reads as the primary add. */
.os-head-btn.accent { background: var(--accent-dark, #1f8a7e); border-color: var(--accent-dark, #1f8a7e); color: #fff; box-shadow: 0 4px 12px rgba(15,125,115,0.28); }
.os-head-btn.accent:hover { background: #0f7d73; box-shadow: 0 6px 16px rgba(15,125,115,0.34); }
.os-head-btn.accent svg { color: #fff; }
.os-menu-btn { color: var(--accent-dark); }

/* ============================================================
   Universal identity avatar — the ONE menu entry point, replacing the
   per-page ☰. Rendered once by shell/publicShell and fixed to the SAME
   top-right position on every screen so it never drifts. Circular and
   photo-ready (swap the letter for a background-image later); shows the
   first letter of the signed-in name.
   ============================================================ */
.app-avatar {
  position: fixed;
  top: max(16px, env(safe-area-inset-top));
  right: max(16px, calc(50% - 214px)); /* tracks the 460px column on wide screens, 16px on phones */
  z-index: 60;
  width: 40px; height: 40px; padding: 0;
  border-radius: 50%;
  display: inline-grid; place-items: center;
  cursor: pointer;
  background: var(--accent-dark, #117d74);
  background-size: cover; background-position: center;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 4px 14px rgba(15, 125, 115, 0.32);
  transition: transform 120ms ease, box-shadow 140ms ease;
}
.app-avatar:active { transform: scale(0.93); }
.app-avatar-ini { font-size: 16px; font-weight: 700; line-height: 1; letter-spacing: 0.01em; }
/* Full-page modules go edge-to-edge on wide screens → pin to the viewport edge. */
body.os-fullpage .app-avatar { right: max(16px, env(safe-area-inset-right)); }
/* Midnight canvas (home / calendar / say / decisions): same teal identity, softer ring. */
body.xortit-canvas .app-avatar { border-color: rgba(255, 255, 255, 0.34); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.42); }

.os-head-badge {
  position: absolute; top: -3px; right: -3px; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; background: var(--accent-dark); color: #fff; font-size: 10.5px; font-weight: 800;
  font-style: normal; display: grid; place-items: center; border: 2px solid #eaf8ff;
}

/* --- Collapsible cadence sections (items 3 & 4) --- */
.cadence-list { display: flex; flex-direction: column; gap: 10px; }
.cadence-section {
  display: block; overflow: hidden;
  border: 1px solid rgba(35,60,65,0.08); border-radius: 14px;
  background: rgba(255,255,255,0.58);
}
.cadence-section > summary.cadence-head {
  display: flex; align-items: center; gap: 10px; margin: 0;
  padding: 14px 15px; cursor: pointer; list-style: none;
  font-size: 18px; font-weight: 650; letter-spacing: 0; text-transform: none; color: var(--ink-3);
  -webkit-tap-highlight-color: transparent;
}
.cadence-section > summary.cadence-head::-webkit-details-marker { display: none; }
.cadence-section > summary.cadence-head::marker { content: ''; }
.cadence-head-label { flex: 1; }
.cadence-head .cadence-count {
  min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px;
  display: inline-grid; place-items: center; font-size: 12px; font-weight: 700;
  background: rgba(107,124,129,0.12); color: var(--ink-3); letter-spacing: 0;
}
.cadence-chev {
  width: 8px; height: 8px; flex: 0 0 auto;
  border-right: 2px solid #8aa0a5; border-bottom: 2px solid #8aa0a5;
  transform: rotate(-45deg); transition: transform 180ms ease;
}
.cadence-section[open] > summary.cadence-head { color: var(--ink-3); }
.cadence-section[open] > summary .cadence-chev { transform: rotate(45deg); border-color: var(--ink-4); }
.cadence-body { padding: 0 11px 11px; display: flex; flex-direction: column; gap: 6px; }
.cadence-empty { margin: 2px 3px 3px; padding: 4px 2px; font-size: 12.5px; color: var(--ink-4); font-style: italic; }
.chore-aside .chore-status { font-size: 10.5px; }
/* New chore card layout: checkbox · body · aside(priority+time) */
.cadence-list .chore-card {
  display: flex; align-items: center; gap: 11px;
  padding: 12px 13px; border-radius: 14px; background: rgba(255,255,255,0.92);
  border: 1px solid rgba(35,60,65,0.06);
}
/* Body flexes to fill; aside is content-sized and pinned hard right so the status
   pill column stays straight regardless of title length (no zigzag) and works
   whether or not a selection checkbox is present. */
.cadence-list .chore-card > .chore-body { flex: 1 1 auto; min-width: 0; }
.cadence-list .chore-card > .chore-aside { flex: 0 0 auto; margin-left: auto; }
.cadence-list .chore-card.selected { background: #e3f7f3; border-color: var(--accent-dark); }
.cadence-list .chore-card .chore-body strong { font-size: 16px; font-weight: 400; }
.recurring-page .cadence-section > summary.cadence-head {
  padding: 13px 15px;
  font-size: 18px;
  font-weight: 650;
  letter-spacing: 0;
}
.recurring-page .cadence-section,
.recurring-page .cadence-section[open],
.recurring-page .cadence-section[open] > summary.cadence-head,
.recurring-page .cadence-section[open] .cadence-body {
  background: #fff;
}
.recurring-page .cadence-body { gap: 8px; padding: 0 10px 10px; }
.recurring-page .cadence-list .chore-card .chore-body strong {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.3;
}
.recurring-page .cadence-list .chore-card .chore-body em {
  font-size: 12px;
  font-weight: 400;
  color: var(--ink-3);
  line-height: 1.35;
}
.chore-aside { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; }
.chore-prio { font-size: 10.5px; font-weight: 700; text-transform: capitalize; }
.chore-prio.prio-high { color: #c2403a; }
.chore-prio.prio-medium { color: #b06f12; }
.chore-prio.prio-low { color: var(--ink-3); }
.chore-aside .chore-time { font-size: 12px; font-weight: 700; color: var(--ink-2); font-variant-numeric: tabular-nums; }

.ft-icon-btn .ft-badge {
  position: absolute; top: -5px; right: -5px; min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 8px; background: var(--accent-dark); color: #fff; font-size: 10px; font-weight: 800;
  font-style: normal; display: grid; place-items: center;
}
.ft-icon-btn { position: relative; }

/* --- Bottom sheets (sort & filter) -------------------------- */
.sheet-backdrop { position: fixed; inset: 0; background: rgba(20,35,38,0.4); z-index: 60; animation: sheet-fade 160ms ease; }
@keyframes sheet-fade { from { opacity: 0; } to { opacity: 1; } }
.bottom-sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 61;
  background: #fff; border-radius: 20px 20px 0 0; padding: 10px 16px calc(20px + env(safe-area-inset-bottom));
  max-height: 80vh; display: flex; flex-direction: column;
  box-shadow: 0 -12px 40px -10px rgba(20,35,38,0.4); animation: sheet-rise 200ms cubic-bezier(0.2,0.8,0.2,1);
}
@keyframes sheet-rise { from { transform: translateY(100%); } to { transform: translateY(0); } }
.sheet-grip { width: 36px; height: 4px; border-radius: 2px; background: rgba(35,60,65,0.18); margin: 2px auto 10px; }
.sheet-title { margin: 0 2px 6px; font-size: 12px; font-weight: 750; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
/* Sheet header row: title on the left, close (✕) on the right so a sheet can
   always be dismissed without acting (owner bug 2026-07-15 — dish editor). */
.sheet-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.sheet-title-row .sheet-title { flex: 1 1 auto; }
.sheet-title-row .rc-close { flex: 0 0 auto; margin-top: -2px; }
.sheet-opt-list { overflow-y: auto; }
.sheet-opt {
  width: 100%; display: flex; align-items: center; justify-content: space-between;
  padding: 15px 4px; border: 0; border-top: 1px solid rgba(35,60,65,0.07); background: none;
  font-size: 15px; color: var(--ink); cursor: pointer; font-family: inherit; text-align: left;
}
.sheet-opt:first-child { border-top: 0; }
.sheet-opt.active { color: var(--accent-dark); font-weight: 700; }
.sheet-check { font-style: normal; color: var(--accent-dark); font-weight: 800; }
/* filter sheet: left rail + right options */
.filter-sheet { padding-bottom: 0; }
.fsheet-head { display: flex; align-items: center; justify-content: space-between; padding: 4px 2px 10px; }
.fsheet-head .sheet-title { margin: 0; }
.fsheet-clear { border: 0; background: none; color: #c2403a; font-size: 13px; font-weight: 650; cursor: pointer; font-family: inherit; }
.fsheet-body { display: grid; grid-template-columns: 116px 1fr; min-height: 280px; max-height: 56vh; border-top: 1px solid rgba(35,60,65,0.1); }
.fsheet-rail { display: flex; flex-direction: column; background: #f3f7f8; overflow-y: auto; }
.fsheet-rail-item {
  display: flex; align-items: center; justify-content: space-between; gap: 4px;
  padding: 15px 12px; border: 0; background: none; text-align: left; cursor: pointer;
  font-size: 13.5px; color: var(--ink-2); font-family: inherit;
}
.fsheet-rail-item.active { background: #fff; color: var(--ink); font-weight: 700; box-shadow: inset 3px 0 0 var(--accent-dark); }
.fsheet-railcount { font-style: normal; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--accent-dark); color: #fff; font-size: 10px; font-weight: 800; display: grid; place-items: center; }
.fsheet-opts { overflow-y: auto; padding: 2px 0; }
.fsheet-opt {
  width: 100%; display: flex; align-items: center; justify-content: space-between;
  padding: 14px 14px; border: 0; border-top: 1px solid rgba(35,60,65,0.06); background: none;
  font-size: 14.5px; color: var(--ink); cursor: pointer; font-family: inherit; text-align: left;
}
.fsheet-opt:first-child { border-top: 0; }
.fsheet-box { width: 20px; height: 20px; border-radius: 6px; border: 1.5px solid rgba(35,60,65,0.25); display: grid; place-items: center; font-size: 12px; color: #fff; font-style: normal; }
.fsheet-opt.on .fsheet-box { background: var(--accent-dark); border-color: var(--accent-dark); }
.fsheet-empty { padding: 20px; color: var(--ink-3); font-size: 13px; }
.fsheet-foot { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 12px 2px 2px; border-top: 1px solid rgba(35,60,65,0.1); }
.fsheet-close, .fsheet-apply { padding: 14px; border-radius: 13px; font-size: 14px; font-weight: 700; cursor: pointer; font-family: inherit; }
.fsheet-close { border: 1px solid rgba(35,60,65,0.18); background: #fff; color: var(--ink-1); }
.fsheet-apply { border: 0; background: var(--accent-dark); color: #fff; }

/* --- Multi-select action bar --------------------------------- */
.multiselect-bar {
  position: fixed;
  left: 50%;
  bottom: calc(74px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: calc(100vw - 24px);
  max-width: 430px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 16px;
  /* LIGHT frosted bar (Option C, owner 2026-07-14) — consistent with the light app
     in every module. Positive button themes per module (--accent-dark); negatives
     red, neutral grey — identical tone vocabulary to the card buttons (.dc-*). */
  background: #fff;
  color: var(--ink);
  border: 1px solid rgba(35, 60, 65, 0.10);
  box-shadow: 0 12px 30px -12px rgba(8, 27, 32, 0.45);
  z-index: 12;
  animation: bar-in 240ms ease;
}
@keyframes bar-in { from { opacity: 0; transform: translate(-50%, 6px); } to { opacity: 1; transform: translate(-50%, 0); } }
.multiselect-count { font-size: 12.5px; font-weight: 500; padding-left: 6px; color: var(--muted); }
.multiselect-count strong { font-size: 15px; color: var(--ink); margin-right: 4px; }
.multiselect-actions { display: flex; gap: 6px; }
.ms-action {
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 12.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}
.ms-action.ms-done   { background: var(--accent-dark); color: #fff; border-color: var(--accent-dark); }        /* positive = theme */
.ms-action.ms-cant   { background: var(--neg-soft); color: var(--neg-ink); border-color: var(--neg-border); }  /* negative = soft red */
.ms-action.ms-delete { background: var(--neg-solid); color: #fff; border-color: var(--neg-solid); }            /* negative = solid red */
.ms-action.ms-cancel { background: rgba(35, 60, 65, 0.05); color: var(--ink-1); border-color: rgba(35, 60, 65, 0.16); } /* neutral grey */
.ms-action:active { transform: scale(0.97); }

/* --- Approvals page ----------------------------------------- */
.approval-row {
  background: rgba(255,255,255,0.92);
  border: 1px solid #e2eef0;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 10px;
  color: var(--ink-1);
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.approval-row[data-approval-selectable] { cursor: pointer; -webkit-tap-highlight-color: transparent; }
.approval-row.selected { background: #e3f7f3; border-color: var(--accent-dark); }
.approval-row .chore-checkbox { margin-top: 2px; flex: 0 0 auto; }
.approval-row.selected .chore-checkbox { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.approval-main { flex: 1; min-width: 0; }
.approval-row header { display: flex; align-items: center; gap: 8px; }
.approval-row header strong { flex: 1; font-size: 16px; font-weight: 400; line-height: 1.25; }
.approvals-section-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.approvals-section-head .os-section-title-label { display: inline-flex; align-items: center; gap: 8px; }
.hx-select-toggle { border: 1px solid var(--accent-dark); background: transparent; color: var(--accent-dark); font-size: 12.5px; font-weight: 700; padding: 6px 13px; border-radius: 999px; cursor: pointer; }
.hx-select-toggle:active { transform: scale(0.96); }
.approval-amount { font-size: 13px; font-weight: 700; color: #117D74; }
.approval-folder {
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e2f5f1;
  color: #117D74;
}
.approval-folder.family { background: #f7e2ec; color: #8e3a64; }
.approval-context { margin: 6px 0 0; font-size: 11.5px; color: var(--ink-3); }
.approval-note { margin: 6px 0 0; font-size: 12.5px; color: var(--ink-1); }
.approval-actions { display: flex; gap: 6px; margin-top: 10px; }
.approval-actions .mini-action {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid #cfdee0;
  background: #fff;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.approval-actions .mini-action.approve { background: var(--accent-dark); color: #fff; border-color: var(--accent-dark); }
.approval-actions .mini-action.reject,
.approval-actions .mini-action.hold { background: transparent; color: var(--ink-1); border-color: rgba(35,60,65,0.18); }
.approval-actions .mini-action.reject:hover,
.approval-actions .mini-action.hold:hover { background: rgba(35,60,65,0.05); }
.approval-stamp { display: inline-block; margin-top: 10px; font-size: 11.5px; font-weight: 700; color: #117D74; }
.approval-acted { opacity: 0.7; }
.approvals-list.muted .approval-row { opacity: 0.85; }
.approved-title { margin-top: 22px; }
.approvals-page .approval-section + .approval-section { margin-top: 12px; }
.approval-detail-status { display: flex; align-items: center; margin-bottom: 10px; }
.approval-detail-actions { align-items: stretch; }

/* --- Task state group pages --------------------------------- */

/* --- Empty state -------------------------------------------- */
.empty-state {
  text-align: center;
  padding: 28px 20px;
  border-radius: 14px;
  border: 1px dashed #cfdee0;
  background: rgba(255,255,255,0.4);
  color: var(--ink-1);
}
.empty-state strong { display:block; font-size:14px; margin-bottom:4px; }
.empty-state em { font-style: normal; font-size: 12px; color: var(--ink-3); }
.empty-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}
.pill-action {
  border: 0;
  border-radius: 999px;
  background: rgba(128, 236, 219, 0.2);
  color: var(--accent-dark, #1f8a7a);
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 720;
  padding: 10px 16px;
}

/* --- HomeOS calendar card: Sky theme (matches rest of HomeOS) - */
.homeos-cal-card {
  background: radial-gradient(circle at 86% 2%, rgba(222, 246, 255, 0.9), transparent 25%),
              linear-gradient(180deg, #f7fcff, #eaf8ff) !important;
  border: 1px solid rgba(35,60,65,0.06) !important;
  color: var(--ink) !important;
}
.homeos-cal-card .cal-header .os-breadcrumb { color: var(--ink-3); }
.homeos-cal-card .cal-header .os-crumb-sep { color: rgba(35,60,65,0.35); }
.homeos-cal-card .cal-header .os-crumb-current { color: var(--ink); }
.homeos-cal-card .cal-title { color: var(--ink); }
.homeos-cal-card .cal-sub { color: var(--ink-3); }
.homeos-cal-card .cal-week-head {
  background: rgba(255,255,255,0.7);
  border-color: rgba(35,60,65,0.08);
}
.homeos-cal-card .cal-week-head:hover { background: #fff; }
.homeos-cal-card .cal-week-head.today {
  background: rgba(53, 202, 187, 0.18);
  border-color: rgba(53, 202, 187, 0.5);
}
.homeos-cal-card .cal-wd { color: var(--ink-3); }
.homeos-cal-card .cal-dn { color: var(--ink); }
.homeos-cal-card .cal-week-head.today .cal-dn { color: var(--accent-dark); }
.homeos-cal-card .cal-week-head.selected { background: var(--accent-dark, #1f8a7e); border-color: var(--accent-dark, #1f8a7e); }
.homeos-cal-card .cal-week-head.selected .cal-wd { color: rgba(255,255,255,0.8); }
.homeos-cal-card .cal-week-head.selected .cal-dn { color: #fff; }
.homeos-cal-card .cal-week-head.selected .cal-dot-count { background: #fff; }
.homeos-cal-card .cal-week-arrow {
  background: rgba(255,255,255,0.7); border-color: rgba(35,60,65,0.1); color: var(--ink);
}
.homeos-cal-card .cal-week-arrow:hover { background: #fff; }
.homeos-cal-card .cal-empty-day { color: var(--ink-3); }
.homeos-cal-card .cal-allday-label { color: var(--ink-3); }
.homeos-cal-card .cal-allday-track {
  background: rgba(255,255,255,0.55);
  border-color: rgba(35,60,65,0.08);
}
.homeos-cal-card .cal-allday-col { border-right-color: rgba(35,60,65,0.06); }
.homeos-cal-card .cal-hours { color: var(--ink-3); }
.homeos-cal-card .cal-grid {
  background: rgba(255,255,255,0.55);
  border-color: rgba(35,60,65,0.08);
}
.homeos-cal-card .cal-half-line.on-hour { border-top-color: rgba(35,60,65,0.12); }
.homeos-cal-card .cal-half-line.on-half { border-top-color: rgba(35,60,65,0.05); }
.homeos-cal-card .cal-legend { color: var(--ink-3); }

/* --- Folder grid eyebrow ----------------------------------- */
.folder-grid-eyebrow {
  display: flex !important;
  justify-content: space-between;
  align-items: baseline;
  max-width: 420px;
  margin: 8px auto 6px;
  padding: 0 10px;
}

/* --- Make sure dashboard hero is centred --------------------- */
.dashboard-hero,
.public-title-block { text-align: center !important; }

/* --- Smaller screens: keep 2 columns but tighter ------------- */
@media (max-width: 380px) {
  .folder-grid { column-gap: 10px !important; row-gap: 16px !important; }
}

/* ============================================================
   v4 — HomeOS dashboard refinements (round 3, May 29)
   - Horizontally-scrollable task-states banner
   - Live "now" dot on today's routine progress
   - Clickable "Recurring work today" panel
   - Recurring-only chores filter banner
   ============================================================ */

/* --- Recurring-work-today panel is now a real button --------- */
.homeos-recurring-btn {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  cursor: pointer;
  text-align: left;
  border: 1px solid var(--homeos-line, #d7eef5);
  background: var(--homeos-card, rgba(255,255,255,0.78));
  border-radius: 18px;
  padding: 14px 16px;
  margin: 0 0 12px;
  transition: transform 160ms ease, box-shadow 200ms ease;
}
.homeos-recurring-btn:active { transform: scale(0.99); }
.homeos-recurring-btn:hover { box-shadow: 0 8px 22px rgba(8, 27, 32, 0.10); }
.homeos-recurring-chevron {
  font-size: 22px;
  line-height: 1;
  color: var(--ink-3);
  padding-right: 2px;
}

/* --- Today's routine — live progress with now dot ----------- */
.homeos-rhythm.v2 {
  margin: 0 0 14px;
  padding: 14px 16px 18px;
  background: var(--homeos-card, rgba(255,255,255,0.78));
  border: 1px solid var(--homeos-line, #d7eef5);
  border-radius: 18px;
  color: var(--ink, #1a2a2e);
}
.homeos-rhythm.v2 .rhythm-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 10px;
  margin-bottom: 14px;
}
.homeos-rhythm.v2 .rhythm-head strong {
  display: block; font-size: 13px; font-weight: 700; color: var(--ink-1);
}
.homeos-rhythm.v2 .rhythm-head em {
  display: block; margin-top: 3px;
  font-style: normal; font-size: 11px; color: var(--ink-3);
}
.homeos-rhythm.v2 .rhythm-now-time {
  font-size: 12px; font-weight: 650; color: var(--ink-1);
  font-variant-numeric: tabular-nums;
}
.homeos-rhythm.v2 .rhythm-track {
  position: relative;
  height: 8px;
  border-radius: 999px;
  background: #e2eef0;
  overflow: visible;
  margin: 0 4px;
}
.homeos-rhythm.v2 .rhythm-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #7BE5C9, #35cabb);
  transition: width 600ms ease;
}
.homeos-rhythm.v2 .rhythm-divider {
  position: absolute;
  top: 50%;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #fff;
  border: 1.5px solid #b9cdd0;
  transform: translate(-50%, -50%);
  z-index: 1;
}
.homeos-rhythm.v2 .rhythm-now {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 14px; height: 14px;
  z-index: 2;
}
.homeos-rhythm.v2 .rhythm-now-dot {
  position: absolute; inset: 2px;
  border-radius: 50%;
  background: #117D74;
  box-shadow: 0 0 0 3px #fff, 0 4px 8px rgba(17, 125, 116, 0.4);
}
.homeos-rhythm.v2 .rhythm-now-pulse {
  position: absolute; inset: -2px;
  border-radius: 50%;
  background: rgba(123, 229, 201, 0.55);
  animation: rhythm-pulse 1.8s ease-in-out infinite;
}
@keyframes rhythm-pulse {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50%      { transform: scale(1.7); opacity: 0; }
}
.homeos-rhythm.v2 .rhythm-labels {
  position: relative;
  margin-top: 14px;
  height: 18px;
  font-size: 10.5px; font-weight: 600;
  color: var(--ink-3);
}
.homeos-rhythm.v2 .rhythm-labels .rl {
  position: absolute;
  top: 0;
  transform: translateX(-50%);
  white-space: nowrap;
}
.homeos-rhythm.v2 .rhythm-labels .rl.eod { transform: translateX(-100%); }
@media (prefers-reduced-motion: reduce) {
  .homeos-rhythm.v2 .rhythm-now-pulse { animation: none; opacity: 0; }
}

/* --- Recurring-work-today: rich card (Android-style) --------- */
.rc-card {
  margin: 0 0 14px;
  padding: 16px 16px 14px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid rgba(35,60,65,0.08);
  box-shadow: 0 10px 26px -16px rgba(8,27,32,0.4);
}
.rc-card[role="button"] { cursor: pointer; }
.rc-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  width: 100%; padding: 0; margin-bottom: 14px;
  background: none; border: 0; font-family: inherit; text-align: left;
}
.rc-head-title { display: inline-flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 750; color: var(--ink, #1a2a2e); letter-spacing: -0.01em; }
.rc-head-ico {
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: rgba(53,170,150,0.14); color: #1f8a7a;
}
.rc-chev { font-size: 22px; color: #b3c2c6; line-height: 1; }
.rc-stat-row { display: flex; align-items: stretch; gap: 12px; margin-bottom: 14px; }
.rc-total { flex: 0 0 auto; display: flex; flex-direction: column; justify-content: center; padding-right: 13px; border-right: 1px solid rgba(35,60,65,0.1); }
.rc-total strong { font-size: 20px; line-height: 1; font-weight: 770; color: var(--ink-1); letter-spacing: -0.02em; }
.rc-total span { margin-top: 4px; font-size: 11px; font-weight: 600; color: var(--ink-3); }
.rc-cells {
  flex: 1; min-width: 0;
  display: flex; gap: 7px;
  overflow-x: auto; overflow-y: hidden;
  -webkit-overflow-scrolling: touch; scrollbar-width: thin;
  scroll-snap-type: x proximity; padding-bottom: 3px;
}
.rc-cells > .rc-cell { flex: 0 0 auto; min-width: 78px; scroll-snap-align: start; }
.rc-cells::-webkit-scrollbar { height: 5px; }
.rc-cells::-webkit-scrollbar-thumb { background: rgba(35,60,65,0.22); border-radius: 999px; }
.rhythm-heartbeat { vertical-align: -2px; margin-left: 3px; color: var(--ink-3); }
.rc-cell {
  display: flex; flex-direction: column; gap: 3px;
  padding: 9px 10px; border-radius: 12px;
  background: #fbfdfd; border: 1px solid rgba(35,60,65,0.1);
}
.rc-cell-ico { color: var(--ink-4); }
.rc-cell-ico svg { width: 14px; height: 14px; }
.rc-cell-label { font-size: 11px; font-weight: 600; color: var(--ink-3); }
.rc-cell b { font-size: 16px; font-weight: 740; color: var(--ink, #1a2a2e); line-height: 1; }
.rc-cell.has b { color: var(--ink-1); }
.rc-cell.zero b { color: #c0cbce; }
/* Nested routine becomes an inset sub-card */
.rc-routine .homeos-rhythm.v2 {
  margin: 0; border: 0; box-shadow: none;
  background: #f3f8f8; border-radius: 14px;
  padding: 13px 14px 16px;
}

/* --- Task states — single horizontally-scrollable banner ----- */
.homeos-task-states.homeos-states-banner {
  background: #fff;
  border: 1px solid rgba(35,60,65,0.08);
  border-radius: 20px;
  padding: 12px 0 12px 16px;
  margin-top: 12px;
  box-shadow: 0 10px 26px -16px rgba(8,27,32,0.4);
}
.homeos-states-head {
  display: flex; align-items: center; justify-content: space-between;
  padding-right: 16px;
  margin-bottom: 8px;
}
.homeos-states-head h4 {
  margin: 0;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 700; color: var(--ink-1);
}
.homeos-states-more {
  font-size: 12px; font-weight: 600; color: #117D74;
  text-decoration: none;
}
.homeos-states-more:hover { text-decoration: underline; }

.homeos-state-scroller {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 4px 16px 4px 0;
}
.homeos-state-scroller::-webkit-scrollbar { display: none; }

.state-chip {
  flex: 0 0 96px;
  scroll-snap-align: start;
  display: grid;
  grid-template-rows: auto 1fr auto;
  align-items: start;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid #e2eef0;
  background: #fff;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 200ms ease;
  text-align: left;
}
.state-chip:active { transform: scale(0.97); }
.state-chip-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #b9cdd0;
}
.state-chip.state-adhoc     .state-chip-dot { background: #35cabb; }
.state-chip.state-overdue   .state-chip-dot { background: #d76072; }
.state-chip.state-moved     .state-chip-dot { background: #d79b3d; }
.state-chip.state-cannotdo  .state-chip-dot { background: #8a72c2; }
.state-chip.state-completed .state-chip-dot { background: #5fb38a; }
.state-chip strong {
  margin-top: 10px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-2);
  line-height: 1.25;
}
.state-chip em {
  margin-top: 6px;
  display: block;
  font-style: normal;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink-1);
}

/* --- Chore recur banner (when filtered to recurring-only) ---- */

/* ============================================================
   v5 — May 29: meals B/L/D + recipe modal + planner +
   collapsible filter/sort + tidy HomeOS menu
   ============================================================ */

/* --- Diet marks (V / E / NV / Side) -------------------------- */
.rc-mark {
  display: inline-block;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 3px 7px;
  border-radius: 999px;
  line-height: 1;
  vertical-align: middle;
}
.rc-mark.mk-veg  { background: #e1f5dc; color: #3c6b29; }
.rc-mark.mk-egg  { background: #fdeccb; color: #8a5a17; }
.rc-mark.mk-nv   { background: #fcdacf; color: #8a3a20; }
.rc-mark.mk-side { background: rgba(35,60,65,0.08); color: var(--ink-2); }

/* --- Meals: compact day banner + B/L/D slots ---------------- */
.meals-daybar {
  display: flex; align-items: center; gap: 6px 10px; flex-wrap: wrap;
  padding: 8px 12px;
  margin-bottom: 12px;
  border-radius: 14px;
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(35,60,65,0.07);
}
.meals-daybar-main { display: flex; align-items: baseline; gap: 8px; margin-right: auto; }

/* ===== Meals macro tokens: kcal/protein are muted figures; colour is reserved for actions. ===== */
.meals-page .k { color: var(--ink-3, #6b7c81); font-weight: 650; }
.meals-page .pr { color: var(--ink-4, #96a3a7); font-weight: 650; }
.meals-page .dot { color: #96a3a7; }
.meals-page .pill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 9px; font-weight: 800; }
.meals-page .pill.rdy { background: rgba(123,110,240,0.13); color: #5f52c8; }

/* ===== §1 Landing — day line, meal cards, swipe dish rows, twin tiles ===== */
.mt-topline { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 2px 2px 12px; }
.mt-today-label { margin: 0; font-size: 16px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; }
.mt-day-macro { font-size: 12px; font-weight: 650; white-space: nowrap; flex: none; }

.meal-card { padding: 13px 13px; margin-bottom: 12px; }
.meal-card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.meal-card-head .slot { font-size: 11.5px; font-weight: 750; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-3, #6b7c81); }
.meal-sub { font-size: 11px; font-weight: 650; white-space: nowrap; flex: none; }
.meal-card.meal-slot-section {
  padding: 0;
  margin-bottom: 12px;
  background: #fff;
}
.meal-card.meal-slot-section > summary.meal-slot-head {
  margin: 0;
  padding: 13px 15px;
}
.meal-card.meal-slot-section .meal-slot-body {
  padding: 0 13px 13px;
  gap: 7px;
}
.meal-card.meal-slot-section .adddish { margin-top: 0; }

/* Swipe dish row: face on top, Edit/Swap drawer revealed behind on swipe-left. */
.mt-dish { border: 1px solid rgba(35,60,65,0.1); border-radius: 13px; background: #fff; margin-bottom: 7px; }
.mt-dish:last-of-type { margin-bottom: 0; }
.mt-dish-face { display: flex; gap: 10px; align-items: flex-start; width: 100%; text-align: left; padding: 11px 12px; background: #fff; border: 0; border-radius: 13px; cursor: pointer; font-family: inherit; }
.mt-dish-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.mt-dish-name { margin: 0; font-size: 15px; font-weight: 400; color: var(--ink); line-height: 1.3; }
.mt-dish-note { margin: 0; font-size: 12px; font-weight: 400; line-height: 1.3; color: var(--ink-4, #96a3a7); }
.mt-dish-macs { margin: 0; font-size: 11.5px; font-weight: 500; line-height: 1.3; }
.mt-cooked { display: none; width: 20px; height: 20px; border-radius: 50%; background: var(--accent-dark, #117d74); color: #fff; font-size: 12px; font-weight: 800; place-items: center; flex: none; margin-top: 1px; }
.mt-dish.is-cooked .mt-cooked { display: grid; }
.mt-dish.is-cooked .mt-dish-name { color: var(--ink-3, #6b7c81); }
.mt-dish .vnv { width: 18px; height: 18px; border-radius: 50%; background: #d6f1ea; color: #1d6b5c; font-size: 8px; font-weight: 800; display: grid; place-items: center; flex: none; margin-top: 1px; }
.mt-dish .vnv.nv { background: #fbdccf; color: #a3322a; }

/* Dashed inline add-a-dish row (per meal card, per approved §1). */
.adddish { display: block; width: 100%; margin-top: 6px; padding: 8px; border: 1.4px dashed #bfe3e6; border-radius: 12px; background: rgba(53,202,187,0.05); color: var(--accent-dark, #117d74); font-size: 11.5px; font-weight: 700; cursor: pointer; font-family: inherit; text-align: center; }
.adddish:active { transform: scale(0.99); }
.mt-swipe-hint { font-size: 11px; color: var(--ink-3, #67797f); line-height: 1.45; margin: 2px 2px 14px; }

/* Twin nav tiles (This/Next week · Recipes/Ingredients). */
.mt-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 18px 0 calc(132px + env(safe-area-inset-bottom)); }
.mt-tile { display: flex; align-items: center; gap: 10px; padding: 14px; min-height: 66px; text-align: left; cursor: pointer; font-family: inherit; background: #fff; border-color: rgba(35,60,65,0.12); box-shadow: 0 10px 24px -18px rgba(8,27,32,0.55); }
.mt-tile.is-ready { border-color: rgba(123,110,240,0.3); }
.mt-tile-ic { width: 34px; height: 34px; border-radius: 11px; background: rgba(53,202,187,0.14); color: var(--accent-dark, #117d74); display: grid; place-items: center; flex: none; }
.mt-tile-ic.alt { background: rgba(123,110,240,0.13); color: #5f52c8; }
.mt-tile-ic svg { width: 18px; height: 18px; }
.mt-tile-body { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.mt-tile-body strong { font-size: 15px; font-weight: 650; color: var(--ink); display: inline-flex; align-items: center; gap: 6px; }
.mt-tile-body em { font-style: normal; font-size: 11.5px; color: var(--ink-3, #6b7c81); }

/* Weeks strip: horizontally-scrollable This/Next/Previous tiles. */
.mt-weekstrip { display: flex; gap: 9px; overflow-x: auto; margin-bottom: 9px; padding-bottom: 2px; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.mt-weekstrip::-webkit-scrollbar { display: none; }
.mt-wtile { flex: 0 0 62%; scroll-snap-align: start; display: flex; align-items: center; gap: 10px; padding: 13px 14px; min-height: 64px; text-align: left; cursor: pointer; font-family: inherit; background: #fff; border-color: rgba(35,60,65,0.1); box-shadow: 0 8px 18px -16px rgba(8,27,32,0.48); }
.mt-wtile.is-ready { border-color: rgba(123,110,240,0.3); }
.mt-wtile:last-child { flex-basis: 55%; }

/* Previous weeks — flat list of uploaded plan PDFs. */
.prev-pdf-list { display: flex; flex-direction: column; gap: 8px; }
.prev-pdf-item { display: flex; align-items: center; gap: 6px; }
.prev-pdf-open { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--homeos-line, #d7eef5); border-radius: 14px; background: #fff; text-align: left; cursor: pointer; font-family: inherit; }
.prev-pdf-ic { width: 34px; height: 34px; border-radius: 10px; background: rgba(53,202,187,0.14); color: var(--accent-dark, #117d74); display: grid; place-items: center; flex: none; }
.prev-pdf-ic svg { width: 20px; height: 20px; }
.prev-pdf-body { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.prev-pdf-body strong { font-size: 13px; font-weight: 700; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prev-pdf-body em { font-style: normal; font-size: 10.5px; color: var(--ink-3, #6b7c81); }

/* The ONE shared meals + (Meals-Module-Handoff §0): 44px solid-teal header circle. */
.meals-plus { width: 44px; height: 44px; border-radius: 50%; background: var(--accent-dark, #117d74); color: #fff; display: inline-grid; place-items: center; border: 0; cursor: pointer; box-shadow: 0 6px 16px rgba(17,125,116,0.3); flex: none; }
.meals-plus:active { transform: scale(0.94); }
.meals-plus svg { width: 20px; height: 20px; }

/* ===== §2/§3 This-week / Next-week macro accordion ===== */
.mw-hero { margin: 12px 2px 12px; }
.mw-hero-range { margin: 0; font-size: 16px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; display: inline-flex; align-items: center; gap: 8px; }
.mw-hero-sub { margin: 3px 0 0; font-size: 11.5px; color: var(--ink-3, #6b7c81); }
.meal-week-accordion { display: flex; flex-direction: column; gap: 8px; }
.mw-day { border: 1px solid var(--homeos-line, #d7eef5); border-radius: 14px; background: #fff; overflow: hidden; }
.mw-day-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 13px; cursor: pointer; list-style: none; }
.mw-day-head::-webkit-details-marker { display: none; }
.mw-day-head b { font-size: 18px; font-weight: 650; color: var(--ink-3); display: inline-flex; align-items: center; gap: 6px; letter-spacing: 0; }
.mw-today { font-size: 10px; font-weight: 800; color: var(--ink-2, #45575d); background: rgba(107,124,129,0.14); border-radius: 6px; padding: 1px 6px; }
.mw-macro { font-size: 12px; font-weight: 650; white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; flex: none; }
.mw-chev { color: var(--ink-4, #96a3a7); font-weight: 700; }
.mw-day-body { padding: 0 12px 10px; }
.mw-slot { margin: 8px 0 5px; display: flex; align-items: baseline; gap: 6px; }
.mw-day-body .mw-slot:first-child { margin-top: 2px; }
.mw-slot .slot { font-size: 11px; font-weight: 750; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-4, #96a3a7); }
.mw-slot-macro { font-size: 10.5px; font-weight: 650; }
.mw-past { padding: 11px 13px; border: 1px solid var(--homeos-line, #d7eef5); border-radius: 14px; background: rgba(255,255,255,0.5); color: var(--ink-4, #96a3a7); font-size: 11.5px; font-weight: 650; }
.mw-foot { margin-top: 10px; }

/* ===== §4 Ingredients — search field (category stays the section heading) ===== */
.ing-search { display: flex; align-items: center; gap: 8px; border: 1px solid var(--homeos-line, #d7eef5); border-radius: 12px; background: #fff; padding: 9px 12px; margin: 8px 0 10px; color: var(--ink-4, #96a3a7); }
.ing-search svg { flex: none; }
.ing-search input { flex: 1; min-width: 0; border: 0; background: none; font-family: inherit; font-size: 12.5px; color: var(--ink); outline: none; }
.ing-search input::placeholder { color: var(--ink-4, #96a3a7); }

/* ===== §5 Recipes — hero, filter chips, rows with status pill, FAB ===== */
.rec-hero { margin: 12px 2px 10px; }
.rec-hero-n { margin: 0; font-size: 16px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; }
.rec-hero-sub { margin: 3px 0 0; font-size: 11.5px; color: var(--ink-3, #6b7c81); }
.rec-chips { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 10px; }
.rec-chips .chip { display: inline-flex; align-items: center; gap: 5px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--homeos-line, #d7eef5); background: #fff; font-size: 11.5px; font-weight: 700; color: var(--ink-2, #45575d); cursor: pointer; font-family: inherit; }
.rec-chips .chip.on { background: var(--accent-dark, #117d74); border-color: var(--accent-dark, #117d74); color: #fff; }
.rec-chips .chip.needs:not(.on) { border-color: #e2b23a; color: #8a5a12; }
.rec-list { display: flex; flex-direction: column; gap: 8px; }
.rec { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--homeos-line, #d7eef5); border-radius: 14px; background: #fff; width: 100%; text-align: left; cursor: pointer; font-family: inherit; }
.rec-thumb { width: 38px; height: 38px; border-radius: 11px; background: rgba(53,202,187,0.14); color: var(--accent-dark, #117d74); display: grid; place-items: center; flex: none; }
.rec-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.rec-body p { margin: 0; font-size: 13px; font-weight: 700; color: var(--ink); }
.rec-body em { font-style: normal; font-size: 10.5px; color: var(--ink-3, #6b7c81); }
.stpill { display: inline-flex; padding: 2px 8px; border-radius: 999px; font-size: 9px; font-weight: 800; flex: none; }
.st-ok { background: #d4f5e1; color: #1f6c44; }
.st-need { background: #fff3cf; color: #8a5a12; }
/* 52px floating variant of the shared meals + (Recipes add). */
.meals-fab { position: fixed; right: 18px; bottom: 88px; width: 52px; height: 52px; border-radius: 50%; background: var(--accent-dark, #117d74); color: #fff; display: grid; place-items: center; border: 0; cursor: pointer; box-shadow: 0 10px 22px rgba(17,125,116,0.4); z-index: 20; }
.meals-fab:active { transform: scale(0.94); }
.meals-fab svg { width: 22px; height: 22px; }

/* Loading skeleton (item 2 — avoid the blank flash before the plan loads) */
.meals-skeleton { display: flex; flex-direction: column; gap: 12px; }
.meal-skel-daybar { height: 48px; border-radius: 14px; background: linear-gradient(90deg, rgba(255,255,255,0.55), rgba(255,255,255,0.85), rgba(255,255,255,0.55)); background-size: 200% 100%; animation: meal-skel 1.2s ease-in-out infinite; }
.meal-skel-card { border: 1px solid rgba(35,60,65,0.07); border-radius: 16px; background: rgba(255,255,255,0.5); padding: 14px; display: flex; flex-direction: column; gap: 14px; }
.meal-skel-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.meal-skel-bar { height: 14px; width: 62%; border-radius: 7px; background: linear-gradient(90deg, rgba(35,60,65,0.06), rgba(35,60,65,0.13), rgba(35,60,65,0.06)); background-size: 200% 100%; animation: meal-skel 1.2s ease-in-out infinite; }
.meal-skel-pill { height: 14px; width: 64px; border-radius: 999px; background: linear-gradient(90deg, rgba(35,60,65,0.06), rgba(35,60,65,0.13), rgba(35,60,65,0.06)); background-size: 200% 100%; animation: meal-skel 1.2s ease-in-out infinite; }
@keyframes meal-skel { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .meal-skel-daybar, .meal-skel-bar, .meal-skel-pill { animation: none; } }
.meals-daybar-main strong { font-size: 12.5px; font-weight: 740; color: var(--ink); letter-spacing: -0.01em; }
.meals-daybar-main span { font-size: 10.5px; color: var(--ink-3); }
.meals-daybar-stats { display: flex; gap: 10px; font-size: 10.5px; color: var(--ink-3); }
.meals-daybar-stats b { color: var(--ink); font-weight: 700; }
.meals-daybar .meal-replan { flex: 0 0 auto; padding: 6px 12px; font-size: 11px; }
  margin: 12px 0 16px;
  border-radius: 16px;
  background: rgba(255,255,255,0.62);
  border: 1px solid rgba(35,60,65,0.07);
}
.meals-daybar-main { display: flex; flex-direction: column; gap: 1px; margin-right: auto; }
.meals-daybar-main strong { font-size: 14px; font-weight: 750; color: var(--ink); letter-spacing: -0.01em; }
.meals-daybar-main span { font-size: 11px; color: var(--ink-3); }
.meals-daybar-stats { display: flex; gap: 12px; font-size: 11px; color: var(--ink-3); }
.meals-daybar-stats b { color: var(--ink); font-weight: 700; }
.meals-daybar .meal-replan { flex: 0 0 auto; }

.meal-slot-head { margin: 0 2px 5px; }
.meal-slot-head strong {
  font-size: 11px; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--ink-3);
}

.meal-dish {
  display: flex; align-items: center; gap: 8px;
  width: 100%;
  text-align: left;
  padding: 8px 12px;
  background: rgba(255,255,255,0.72);
  border: 0;
  cursor: pointer;
  transition: background 160ms ease;
}
.meal-dish:hover { background: #fff; }
.meal-dish:active { background: rgba(53,202,187,0.10); }
.meal-dish.no-recipe { cursor: default; }
.meal-dish.no-recipe:hover { background: rgba(255,255,255,0.72); }
.meal-dish-name { font-size: 13px; font-weight: 600; color: var(--ink); line-height: 1.2; flex: 1; min-width: 0; }
.meal-dish-who { font-size: 10.5px; color: var(--ink-4); white-space: nowrap; }
.meal-dish-go { font-size: 17px; color: #b3c2c6; line-height: 1; }

/* dish row = dish button + like/dislike */
.meal-dish-row { display: flex; align-items: center; background: rgba(255,255,255,0.72); transition: background 160ms ease; }
.meal-dish-row:hover { background: #fff; }
.meal-dish-row .meal-dish { background: transparent; flex: 1; min-width: 0; }
.meal-dish-row .meal-dish:hover, .meal-dish-row .meal-dish:active { background: transparent; }
.dish-react { flex: 0 0 auto; display: flex; gap: 3px; padding: 0 10px 0 4px; }
.dish-thumb {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  border: 0; background: transparent; color: var(--ink-4); cursor: pointer; transition: all 130ms ease;
}
.dish-thumb:hover { background: rgba(35,60,65,0.06); color: var(--ink-3); }
.dish-thumb.up.on   { background: #d3ecd9; color: #2c8a5f; }
.dish-thumb.down.on { background: #f0d7d1; color: #c0593f; }

/* --- Plan for next week CTA on meals today ------------------- */
.plan-next-cta {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 15px 16px;
  margin: 4px 0 6px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(53,202,187,0.16), rgba(123,229,201,0.10));
  border: 1px solid rgba(53,202,187,0.30);
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 200ms ease;
}
.plan-next-cta:hover { box-shadow: 0 10px 24px rgba(8,27,32,0.12); }
.plan-next-cta:active { transform: scale(0.99); }
.plan-next-icon {
  width: 38px; height: 38px; border-radius: 12px;
  display: grid; place-items: center;
  background: rgba(255,255,255,0.8); color: var(--accent-dark);
}
.plan-next-text strong { display: block; font-size: 14px; font-weight: 750; color: var(--ink); }
.plan-next-text em { display: block; margin-top: 3px; font-style: normal; font-size: 11.5px; color: var(--ink-3); line-height: 1.35; }
.plan-next-arrow { font-size: 24px; color: var(--accent-dark); }

/* --- Recipe modal ------------------------------------------- */
body.recipe-open { overflow: hidden; }
#recipe-layer { position: fixed; inset: 0; z-index: 60; pointer-events: none; }
#recipe-layer:empty { display: none; }
.recipe-modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(8,18,20,0.55);
  backdrop-filter: blur(3px);
  pointer-events: auto;
  animation: rc-fade 180ms ease;
}
@keyframes rc-fade { from { opacity: 0; } to { opacity: 1; } }
.recipe-modal {
  position: fixed;
  left: 50%; bottom: 0;
  transform: translateX(-50%);
  width: 100%; max-width: 460px;
  max-height: 92dvh;
  display: flex; flex-direction: column;
  background: linear-gradient(180deg, #ffffff, #f3fbfd);
  border-radius: 26px 26px 0 0;
  border: 1px solid rgba(35,60,65,0.10);
  box-shadow: 0 -20px 60px rgba(0,0,0,0.4);
  color: var(--ink);
  pointer-events: auto;
  animation: rc-rise 260ms cubic-bezier(.2,.8,.2,1);
  overflow: hidden;
}
@keyframes rc-rise { from { transform: translate(-50%, 30px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }
.recipe-modal-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 12px;
  padding: 20px 18px 12px;
  border-bottom: 1px solid rgba(35,60,65,0.07);
}
.recipe-modal-head h3 { margin: 8px 0 2px; font-size: 19px; font-weight: 750; letter-spacing: -0.02em; }
.rc-meta { margin: 0; font-size: 11.5px; color: var(--ink-3); }

/* Add-a-recipe options sheet (Meals UX Options v4 §5b): link · text · photo · write. */
.rc-add-opts { display: flex; flex-direction: column; gap: 9px; }
.rc-add-opts[hidden], .rc-add-method[hidden] { display: none !important; }
.rc-add-opt {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  padding: 13px 14px; border: 1px solid rgba(35,60,65,0.10); border-radius: 14px;
  background: #fff; cursor: pointer; font-family: inherit;
  transition: background 130ms ease, border-color 130ms ease;
}
.rc-add-opt:active { background: #f4fbfa; }
.rc-add-opt-ic { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; font-size: 19px; background: var(--asoft, rgba(53,202,187,0.14)); }
.rc-add-opt-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rc-add-opt-body strong { font-size: 14px; font-weight: 700; color: var(--ink-1); }
.rc-add-opt-body em { font-style: normal; font-size: 11px; color: var(--ink-3); }
.rc-add-opt-chev { flex: 0 0 auto; color: var(--ink-4); font-size: 18px; line-height: 1; }
.rc-add-note { margin: 6px 2px 0; font-size: 11px; color: var(--ink-3); line-height: 1.45; }
.rc-add-method { display: flex; flex-direction: column; gap: 10px; }
.rc-add-back { align-self: flex-start; border: 0; background: none; padding: 2px 0; font-family: inherit; font-size: 12.5px; font-weight: 700; color: var(--accent-dark, #0f7d73); cursor: pointer; }
.rc-close {
  flex-shrink: 0;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid rgba(35,60,65,0.12);
  background: #fff; color: var(--ink-2);
  font-size: 15px; cursor: pointer;
}
.rc-close:active { transform: scale(0.94); }
.rc-serving {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 18px;
  background: rgba(53,202,187,0.10);
  border-bottom: 1px solid rgba(35,60,65,0.07);
}
.rc-serving-label { font-size: 12.5px; font-weight: 650; color: var(--ink-1); }
.rc-serving-unit { font-size: 12.5px; color: var(--ink-3); }
.rc-stepper { display: inline-flex; align-items: center; gap: 6px; }
.rc-step-btn {
  width: 32px; height: 32px; border-radius: 10px;
  border: 1px solid rgba(35,60,65,0.16);
  background: #fff; color: var(--accent-dark);
  font-size: 19px; font-weight: 700; line-height: 1; cursor: pointer;
  display: grid; place-items: center;
}
.rc-step-btn:active { transform: scale(0.94); }
.rc-serving-count {
  min-width: 30px; text-align: center;
  font-size: 17px; font-weight: 800; color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.rc-body { padding: 16px 18px 28px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.rc-block-title {
  margin: 4px 0 10px;
  font-size: 11px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-3);
}
.rc-body .rc-block-title:not(:first-child) { margin-top: 22px; }
.rc-section { margin-bottom: 12px; }
.rc-section-head { margin: 0 0 6px; font-size: 13px; font-weight: 700; color: var(--ink); }
.rc-ing-table {
  border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(35,60,65,0.08);
}
.rc-ing-row {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 9px 12px;
  font-size: 13px;
  background: rgba(255,255,255,0.7);
}
.rc-ing-row:nth-child(even) { background: rgba(53,202,187,0.06); }
.rc-ing-name { color: var(--ink); }
.rc-ing-qty { color: var(--ink-2); font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rc-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.rc-step { display: flex; gap: 12px; }
.rc-step-num {
  flex-shrink: 0;
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent-dark); color: #fff;
  font-size: 12.5px; font-weight: 800;
}
.rc-step-group {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 12px; font-weight: 750; color: var(--ink); text-transform: uppercase; letter-spacing: 0.04em;
  margin-bottom: 3px;
}
.rc-step-time {
  text-transform: none; letter-spacing: 0;
  font-size: 10.5px; font-weight: 700;
  padding: 2px 8px; border-radius: 999px;
  background: rgba(53,202,187,0.16); color: var(--accent-dark);
}
.rc-step-body p { margin: 0; font-size: 13px; color: #3a4f55; line-height: 1.45; }
.rc-notes {
  margin-top: 20px;
  border: 1px solid rgba(35,60,65,0.10);
  border-radius: 14px;
  background: rgba(255,255,255,0.6);
  overflow: hidden;
}
.rc-notes summary {
  padding: 12px 14px;
  font-size: 13px; font-weight: 700; color: var(--accent-dark);
  cursor: pointer; list-style: none;
}
.rc-notes summary::-webkit-details-marker { display: none; }
.rc-notes ol { margin: 0; padding: 0 18px 14px 32px; display: flex; flex-direction: column; gap: 7px; }
.rc-notes li { font-size: 12.5px; color: #3a4f55; line-height: 1.45; }

/* --- Plan-for-next-week questionnaire ------------------------ */
.mp-step { margin: 18px 0 6px; }
.mp-step-head { display: flex; align-items: flex-start; gap: 11px; margin: 0 2px 12px; }
.mp-step-no {
  flex-shrink: 0;
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent-dark); color: #fff; font-size: 13px; font-weight: 800;
}
.mp-step-head strong { display: block; font-size: 15px; font-weight: 750; color: var(--ink); }
.mp-step-head em { display: block; margin-top: 2px; font-style: normal; font-size: 11.5px; color: var(--ink-3); line-height: 1.35; }
.mp-card {
  padding: 16px;
  border-radius: 18px;
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(35,60,65,0.08);
  display: flex; flex-direction: column; gap: 14px;
}
.mp-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.mp-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.mp-field { display: flex; flex-direction: column; gap: 7px; }
.mp-field-label { font-size: 12px; font-weight: 650; color: var(--ink-1); line-height: 1.2; }
.mp-field-label em { display: block; font-style: normal; font-size: 9.5px; color: var(--ink-3); margin-top: 1px; }
.mp-stepper {
  display: flex; align-items: center; justify-content: space-between;
  background: #fff; border: 1px solid rgba(35,60,65,0.12); border-radius: 12px;
  padding: 4px;
}
.mp-step-btn {
  width: 30px; height: 30px; border-radius: 8px;
  border: 0; background: rgba(53,202,187,0.12); color: var(--accent-dark);
  font-size: 18px; font-weight: 700; cursor: pointer; line-height: 1;
}
.mp-step-btn:active { transform: scale(0.93); }
.mp-step-val { font-size: 15px; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.mp-row { display: flex; flex-direction: column; gap: 8px; }
.mp-label { font-size: 12px; font-weight: 650; color: var(--ink-1); }
.mp-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mp-chip {
  padding: 7px 12px; border-radius: 999px;
  border: 1px solid rgba(35,60,65,0.14); background: #fff; color: var(--ink-1);
  font-size: 12px; font-weight: 650; cursor: pointer;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease;
}
.mp-chip.active { background: var(--accent-dark); color: #fff; border-color: var(--accent-dark); }

/* Collapsible cuisine rotation — keeps the long list from crowding the card */
.mp-cuisines { border: 1px solid rgba(35,60,65,0.12); border-radius: 14px; background: rgba(255,255,255,0.6); overflow: hidden; }
.mp-cuisines > summary {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; cursor: pointer; list-style: none;
}
.mp-cuisines > summary::-webkit-details-marker { display: none; }
.mp-cuisines-label { font-size: 12px; font-weight: 650; color: var(--ink-1); display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.mp-cuisines-label em { font-style: normal; font-size: 10.5px; font-weight: 700; color: var(--accent-dark); background: rgba(53,202,187,0.14); padding: 2px 8px; border-radius: 999px; }
.mp-cuisines-preview { flex: 1; min-width: 0; font-size: 11.5px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-cuisines-chev { color: var(--accent-dark); font-size: 18px; font-weight: 700; transition: transform 180ms ease; }
.mp-cuisines[open] .mp-cuisines-chev { transform: rotate(90deg); }
.mp-cuisines-body { padding: 0 14px 14px; }

/* ---- Import a plan panel (Previous tab) ---- */
.plan-import { margin-bottom: 16px; border: 1px solid rgba(53,202,187,0.28); border-radius: 18px; background: rgba(53,202,187,0.06); overflow: hidden; }
.plan-import-summary { display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; list-style: none; }
.plan-import-summary::-webkit-details-marker { display: none; }
.plan-import-spark { width: 34px; height: 34px; flex: 0 0 auto; border-radius: 11px; display: grid; place-items: center; background: rgba(53,202,187,0.16); color: var(--accent-dark); }
.plan-import-spark svg { width: 17px; height: 17px; }
.plan-import-head { flex: 1; min-width: 0; }
.plan-import-head strong { display: block; font-size: 14px; font-weight: 750; color: var(--ink); }
.plan-import-head em { display: block; margin-top: 2px; font-style: normal; font-size: 11.5px; color: var(--ink-3); line-height: 1.35; }
.plan-import-chev { color: var(--accent-dark); font-size: 22px; font-weight: 700; transition: transform 180ms ease; }
.plan-import[open] .plan-import-chev { transform: rotate(90deg); }
.plan-import-body { padding: 0 16px 16px; display: flex; flex-direction: column; gap: 12px; }
/* §2.2: previous-plans review-first import door (button, not a <details>). */
.plan-import-door { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; margin-bottom: 16px; border: 1px solid rgba(53,202,187,0.28); border-radius: 18px; background: rgba(53,202,187,0.06); padding: 14px 16px; cursor: pointer; font-family: inherit; }
.plan-import-door:active { transform: scale(0.99); }

.pi-method.active { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(2,10,12,0.12); }

.pi-file-input { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; opacity: 0; pointer-events: none; }
.pi-drop { width: 100%; display: flex; align-items: center; gap: 12px; padding: 16px; border: 1.5px dashed rgba(53,202,187,0.5); border-radius: 14px; background: rgba(255,255,255,0.6); cursor: pointer; text-align: left; font-family: inherit; transition: border-color 140ms ease, background 140ms ease; }
.pi-drop:hover { border-color: var(--accent-dark); background: rgba(255,255,255,0.85); }
.pi-drop.drag { border-color: var(--accent-dark); border-style: solid; background: rgba(53,202,187,0.12); }
.pi-drop-icon { color: var(--accent-dark); flex: 0 0 auto; }
.pi-drop-text strong { display: block; font-size: 13.5px; font-weight: 700; color: var(--ink); }
.pi-drop-text em { display: block; margin-top: 2px; font-style: normal; font-size: 11.5px; color: var(--ink-3); line-height: 1.35; }
.pi-status { margin: 0; font-size: 12px; color: var(--ink-3); }
.pi-status.busy { color: var(--accent-dark); font-weight: 650; }
.pi-status.error { color: #b4453a; font-weight: 650; }
.pi-result { display: block; }
.pi-pane[hidden], .pi-result[hidden], .pi-status[hidden] { display: none; }
.prev-group-label { margin: 16px 0 8px; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-4); }
.prev-imported { display: flex; align-items: center; gap: 12px; }
.prev-imported .prev-pdf-icon { color: var(--accent-dark); }
.prev-card-main { flex: 1; min-width: 0; text-align: left; background: none; border: 0; padding: 0; cursor: pointer; font-family: inherit; }
.prev-card-main strong { display: block; font-size: 13.5px; color: var(--ink); font-weight: 650; }
.prev-card-main em { display: block; margin-top: 3px; font-style: normal; font-size: 11px; color: var(--ink-3); }
.prev-del { flex: 0 0 auto; width: 28px; height: 28px; border-radius: 8px; border: 1px solid rgba(35,60,65,0.14); background: #fff; color: var(--ink-4); font-size: 13px; cursor: pointer; line-height: 1; }
.prev-del:hover { color: #b4453a; border-color: rgba(180,69,58,0.4); }
.plan-view-sheet { max-height: 86vh; overflow-y: auto; }
.plan-view-sheet .mpw-grid { margin-top: 4px; }
.plan-view-sheet .mp-generate { position: sticky; bottom: 0; }
.mp-text-field { display: flex; flex-direction: column; gap: 8px; }
.mp-text-field input, .mp-textarea {
  width: 100%; padding: 11px 12px;
  border-radius: 12px; border: 1px solid rgba(35,60,65,0.14);
  background: #fff; color: var(--ink); font-size: 13px; font-family: inherit;
}
.mp-textarea { resize: vertical; line-height: 1.45; }
.mp-text-field input:focus, .mp-textarea:focus { outline: 2px solid rgba(53,202,187,0.4); outline-offset: 0; border-color: transparent; }
.mp-rules { margin-top: 10px; border: 1px solid rgba(35,60,65,0.10); border-radius: 14px; background: rgba(255,255,255,0.5); overflow: hidden; }
.mp-rules summary { padding: 11px 14px; font-size: 12.5px; font-weight: 700; color: var(--ink-2); cursor: pointer; list-style: none; }
.mp-rules summary::-webkit-details-marker { display: none; }
.mp-rules ul { margin: 0; padding: 0 16px 12px 30px; display: flex; flex-direction: column; gap: 6px; }
.mp-rules li { font-size: 12px; color: var(--ink-2); line-height: 1.4; }
.mp-memory { margin-top: 4px; padding: 0; border-radius: 12px; background: rgba(53,202,187,0.08); border: 1px solid rgba(53,202,187,0.2); overflow: hidden; }
.mp-memory > summary.mp-memory-head { display: flex; align-items: center; gap: 8px; margin: 0; padding: 12px; cursor: pointer; list-style: none; }
.mp-memory > summary::-webkit-details-marker { display: none; }
.mp-memory-spark { display: inline-flex; color: var(--accent-dark); flex: 0 0 auto; }
.mp-memory-spark svg { width: 14px; height: 14px; }
.mp-memory-title { font-size: 12px; font-weight: 750; color: var(--accent-dark); flex: 0 0 auto; }
.mp-memory-head em[data-mp-memory-count] { flex: 1; font-style: normal; font-weight: 500; color: var(--ink-3); font-size: 11px; }
.mp-memory-chev { color: var(--accent-dark); font-size: 16px; font-weight: 700; transition: transform 180ms ease; flex: 0 0 auto; }
.mp-memory[open] .mp-memory-chev { transform: rotate(90deg); }
.mp-memory-list { list-style: none; margin: 0; padding: 0 12px 12px; display: flex; flex-direction: column; gap: 6px; }
.mp-memory-list li.mp-mem-item { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--ink-2); }
.mp-mem-text { flex: 1; min-width: 0; }
.mp-mem-item em { font-style: normal; color: var(--ink-4); font-size: 10.5px; white-space: nowrap; flex: 0 0 auto; }
.mp-mem-remove { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px; border: 1px solid rgba(35,60,65,0.14); background: rgba(255,255,255,0.7); color: var(--ink-4); font-size: 11px; line-height: 1; cursor: pointer; }
.mp-mem-remove:hover { color: #b4453a; border-color: rgba(180,69,58,0.4); }
.mp-mem-empty { font-size: 11.5px; color: var(--ink-4); }

/* ---- "View as role" switcher (launch-prep / non-prod only) ---- */
#rbac-role-switcher { position: fixed; left: 14px; bottom: 92px; z-index: 80; font-family: inherit; }
.rbac-toggle { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.18); background: rgba(20,40,40,0.85); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: #dff6f1; font-size: 12px; font-weight: 600; cursor: pointer; box-shadow: 0 10px 30px -10px rgba(0,0,0,0.6); }
.rbac-toggle b { color: #7BE5C9; font-weight: 750; }
.rbac-eye { display: inline-flex; opacity: 0.85; }
.rbac-eye svg { width: 14px; height: 14px; }
.rbac-menu { position: absolute; bottom: 46px; left: 0; min-width: 196px; padding: 8px; border-radius: 14px; border: 1px solid rgba(255,255,255,0.16); background: rgba(16,32,32,0.97); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 20px 50px -16px rgba(0,0,0,0.7); display: flex; flex-direction: column; gap: 2px; }
.rbac-menu[hidden] { display: none; }
.rbac-menu-head { margin: 2px 6px 6px; font-size: 10px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(255,255,255,0.5); }
.rbac-opt { text-align: left; padding: 9px 10px; border: 0; border-radius: 9px; background: transparent; color: #e6f5f1; font-size: 13px; font-weight: 600; cursor: pointer; }
.rbac-opt:hover { background: rgba(123,229,201,0.12); }
.rbac-opt.active { background: rgba(123,229,201,0.16); color: #7BE5C9; }
.rbac-menu-foot { margin: 6px 6px 2px; font-size: 10px; color: rgba(255,255,255,0.42); line-height: 1.3; }

/* RBAC affordances inside task modals */
.ts-readonly-note { padding: 14px 16px; margin: 0; font-size: 12.5px; color: var(--ink-3); background: rgba(35,60,65,0.05); border-top: 1px solid rgba(35,60,65,0.08); text-align: center; }
.task-approval-banner { margin: 0 0 12px; padding: 10px 12px; border-radius: 10px; background: rgba(53,202,187,0.12); border: 1px solid rgba(53,202,187,0.28); color: var(--accent-dark, #117d74); font-size: 12px; font-weight: 600; line-height: 1.35; }

/* Member/staff "today only" calendar agenda */
.today-only-note { margin: 6px 0 0; font-size: 12.5px; color: var(--ink-3); }
.today-agenda { display: flex; flex-direction: column; gap: 8px; padding: 16px; }
.today-ev { display: flex; align-items: flex-start; gap: 12px; padding: 13px 14px; border-radius: 13px; border: 1px solid rgba(35,60,65,0.1); background: #fff; text-align: left; cursor: pointer; box-shadow: 0 1px 2px rgba(2,10,12,0.04); }
.today-ev:hover { border-color: rgba(53,202,187,0.45); }
.today-ev-time { flex: 0 0 56px; font-size: 12.5px; font-weight: 700; color: var(--accent-dark, #117d74); padding-top: 1px; }
.today-ev-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.today-ev-body strong { font-size: 14px; font-weight: 650; color: var(--ink, #14302f); }
.today-ev-body em { font-style: normal; font-size: 11.5px; color: var(--ink-4); }
.today-ev.st-done { opacity: 0.62; }
.today-ev.st-done .today-ev-body strong { text-decoration: line-through; }
.cal-empty-day { padding: 28px 16px; text-align: center; color: var(--ink-4); font-size: 13px; }
/* Non-editable person rows (manager/member view) — no edit affordance, calmer hover */
.person-row-static { cursor: default; }
.person-row-static:hover { border-color: rgba(35,60,65,0.1); transform: none; }
.mp-context { flex-direction: row; flex-wrap: wrap; gap: 8px; }.mp-context-pill { font-size: 11.5px; font-weight: 650; color: var(--accent-dark); background: rgba(53,202,187,0.12); border-radius: 999px; padding: 6px 11px; }
.mp-generate {
  width: 100%; margin-top: 12px;
  padding: 15px; border: 0; border-radius: 16px;
  background: var(--accent-dark); color: #fff;
  font-size: 14.5px; font-weight: 750; cursor: pointer;
  box-shadow: 0 10px 24px -8px rgba(17,125,116,0.6);
}
.mp-generate:active { transform: scale(0.99); }
.mp-result {
  margin: 4px 0 16px;
  padding: 16px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(53,202,187,0.16), rgba(123,229,201,0.08));
  border: 1px solid rgba(53,202,187,0.34);
  animation: rc-fade 240ms ease;
}
.mp-result-head { display: flex; align-items: flex-start; gap: 11px; }
.mp-result-spark { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--accent-dark); flex-shrink: 0; }
.mp-result-head strong { display: block; font-size: 14.5px; font-weight: 750; color: var(--ink); }
.mp-result-head em { display: block; margin-top: 3px; font-style: normal; font-size: 12px; color: var(--ink-2); line-height: 1.4; }
.mp-result-carry { margin: 12px 0 6px; font-size: 10.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }

/* --- Generated week plan (agent output) --- */
.mp-result-error .mp-result-spark { background: #fff0ef; color: #c2403a; font-weight: 800; }
.mp-spin { animation: mp-spin 1.1s linear infinite; }
@keyframes mp-spin { to { transform: rotate(360deg); } }
.mpw-grid { display: flex; flex-direction: column; gap: 10px; margin: 14px 0 4px; }
.mpw-day { background: #fff; border: 1px solid rgba(35,60,65,0.08); border-radius: 14px; overflow: hidden; }
.mpw-day-head { display: flex; align-items: baseline; justify-content: space-between; padding: 10px 13px; background: rgba(107,124,129,0.08); }
.mpw-day-head strong { font-size: 13.5px; font-weight: 750; color: var(--ink-3); }
.mpw-day-head span { font-size: 11px; color: var(--ink-3); }
.mpw-slots { list-style: none; margin: 0; padding: 4px 0; }
.mpw-slot { display: grid; grid-template-columns: 72px 1fr auto; align-items: center; gap: 8px; padding: 7px 13px; border-top: 1px solid rgba(35,60,65,0.05); }
.mpw-slot:first-child { border-top: 0; }
.mpw-slot-name { font-size: 11px; font-weight: 650; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.03em; }
.mpw-dish { font-size: 13px; color: var(--ink); font-weight: 550; }
.mpw-note { grid-column: 2 / 3; font-size: 11px; color: var(--ink-3); }
.mpw-mark { grid-row: 1 / 3; align-self: center; font-size: 10px; font-weight: 700; padding: 3px 8px; border-radius: 999px; white-space: nowrap; }
.mpw-mark.mark-V { background: rgba(31,138,126,0.12); color: #1f8a7e; }
.mpw-mark.mark-NV { background: rgba(193,64,58,0.12); color: #c2403a; }
.mpw-mark.mark-E { background: rgba(207,143,42,0.14); color: #b06f12; }
.mpw-actions { display: flex; gap: 10px; margin-top: 12px; }
.mpw-actions .mp-generate { margin-top: 0; flex: 1; }
/* Secondary "Discard" beside Save — quiet, so Save stays the primary action. */
.mp-discard {
  flex: 0 0 auto; padding: 15px 18px; border-radius: 16px;
  border: 1px solid rgba(35,60,65,0.16); background: #fff;
  color: var(--muted); font-size: 14.5px; font-weight: 650; cursor: pointer;
}
.mp-discard:active { transform: scale(0.99); }
.mpw-dish { display: flex; flex-direction: column; gap: 1px; }
.mpw-kcal { font-size: 10.5px; color: var(--ink-4); font-weight: 500; }
.mpw-foot { font-size: 11.5px; color: var(--ink-3); margin: 10px 2px 0; text-wrap: pretty; }
/* Item 10: clickable dish (recipe), follow-up actions, uploads, recipe card */
.cadence-list .mpw-dish, .mpw-slot .mpw-dish { width: 100%; text-align: left; border: 0; background: none; cursor: pointer; font-family: inherit; padding: 0; position: relative; }
.mpw-dish .mpw-dish-go { font-size: 10px; font-weight: 700; color: var(--accent-dark); opacity: 0; transition: opacity 140ms ease; }
.mpw-dish:hover .mpw-dish-go { opacity: 1; }
.mpw-followups { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.mpw-upload { display: inline-flex; align-items: center; gap: 5px; padding: 8px 14px; border-radius: 10px; border: 1px dashed rgba(35,60,65,0.28); background: #fff; color: #3a5a5f; font-size: 12.5px; font-weight: 650; cursor: pointer; }
.mpw-upload:hover { border-color: var(--accent-dark); color: var(--accent-dark); }
.mpw-upload-status { font-size: 11.5px; color: var(--accent-dark); margin: 8px 2px 0; min-height: 14px; }
.mb-result { margin-top: 14px; }
.rc-card { background: #fff; border: 1px solid rgba(35,60,65,0.1); border-radius: 14px; padding: 14px; }
.rc-card-title { margin: 0 0 10px; font-size: 15px; font-weight: 750; color: var(--ink); display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.rc-kcal { font-size: 11px; font-weight: 600; color: var(--ink-4); }
.rc-ing-group { margin-bottom: 10px; }
.rc-ing-head { margin: 0 0 4px; font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: 0.04em; color: var(--accent-dark); }
.rc-ing-row { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; font-size: 13px; color: var(--ink); border-bottom: 1px solid rgba(35,60,65,0.05); }
.rc-ing-row b { font-weight: 650; color: var(--ink-2); white-space: nowrap; }
.rc-steps { margin-top: 8px; display: flex; flex-direction: column; gap: 8px; }

/* --- Meal agent: mode hint + bridge (use your own Claude plan) --- */
.mp-mode-hint { display: flex; align-items: center; gap: 7px; font-size: 12px; line-height: 1.4; margin: 4px 2px 12px; color: var(--ink-2); }
.mp-mode-hint svg { flex: 0 0 auto; width: 15px; height: 15px; color: var(--accent-dark, #1f8a7e); }
.mp-mode-hint.mode-bridge { color: var(--accent-dark, #1f8a7e); font-weight: 600; }
.mp-bridge { border: 1px solid rgba(53,202,187,0.32); background: rgba(53,202,187,0.05); border-radius: 16px; padding: 14px; margin-top: 8px; }
.mp-bridge-head { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; }
.mp-bridge-spark { flex: 0 0 auto; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 9px; background: rgba(53,202,187,0.16); color: var(--accent-dark, #1f8a7e); }
.mp-bridge-spark svg { width: 17px; height: 17px; }
.mp-bridge-head strong { display: block; font-size: 13.5px; color: var(--ink); }
.mp-bridge-head em { display: block; font-size: 11.5px; color: var(--ink-3); font-style: normal; margin-top: 1px; }
.mp-bridge-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.mp-bridge-steps > li { display: flex; gap: 10px; align-items: flex-start; }
.mp-bridge-n { flex: 0 0 auto; width: 21px; height: 21px; border-radius: 50%; background: var(--accent-dark, #1f8a7e); color: #fff; font-size: 11.5px; font-weight: 700; display: grid; place-items: center; margin-top: 1px; }
.mp-bridge-row { flex: 1; }
.mp-bridge-row > p { margin: 0 0 7px; font-size: 13px; color: var(--ink); font-weight: 550; }
.mp-bridge-row > p em { font-style: normal; color: var(--ink-3); font-weight: 400; }
.mp-bridge-btn { display: inline-flex; align-items: center; gap: 5px; padding: 8px 14px; border-radius: 10px; border: 1px solid var(--accent-dark, #1f8a7e); background: #fff; color: var(--accent-dark, #1f8a7e); font-size: 12.5px; font-weight: 650; cursor: pointer; text-decoration: none; }
.mp-bridge-btn:hover { background: rgba(53,202,187,0.1); }
.mp-bridge-btn.copied { background: var(--accent-dark, #1f8a7e); color: #fff; }
.mp-file-door {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px dashed rgba(53,202,187,0.42);
  border-radius: 12px;
  background: rgba(53,202,187,0.07);
  color: var(--accent-dark, #1f8a7e);
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  text-align: center;
}
.mp-file-door:active { transform: scale(0.99); }
.mp-bridge-paste .mp-textarea { width: 100%; box-sizing: border-box; margin-bottom: 8px; }
/* §2 recipe URL import row — a single-line link field + import button, above the paste flow. */
.mp-url-row { display: flex; gap: 8px; align-items: stretch; }
.mp-url-input { flex: 1; min-width: 0; height: auto; resize: none; }
.mp-url-row .mp-bridge-btn { white-space: nowrap; }
.mp-bridge-paste .mp-generate { margin-top: 0; }

/* --- Collapsible filter / sort (chores + ingredients) -------- */

/* Chores header: title left, filter/sort icons top-right */

.ft-icon-btn.icon-only { padding: 9px; width: 38px; height: 38px; justify-content: center; }
.ft-icon-btn.icon-only .ft-dot { position: absolute; top: 6px; right: 6px; margin: 0; }

.filter-toolbar { display: flex; align-items: center; gap: 8px; }
.ft-icon-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 13px; border-radius: 999px;
  border: 1px solid rgba(35,60,65,0.14);
  background: rgba(255,255,255,0.85); color: var(--ink-1);
  font-size: 12.5px; font-weight: 650; cursor: pointer;
  position: relative;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease;
}
.ft-icon-btn.open { background: var(--accent-dark); color: #fff; border-color: var(--accent-dark); }
.ft-icon-btn .ft-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--mint-deep, #34BFA8);
  margin-left: 1px;
}
.ft-icon-btn.open .ft-dot { background: #fff; }
.ft-summary { font-size: 11.5px; color: var(--ink-3); margin-left: 2px; }

@keyframes ft-open { from { transform: translateY(-4px); } to { transform: translateY(0); } }

.ft-opt.active { background: rgba(53,202,187,0.14); color: var(--accent-dark); font-weight: 750; }

/* --- HomeOS menu: declutter (drop preview descriptions) ------ */
.menu-page .os-list-card em { display: none; }
.menu-page .os-list-card {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 14px 16px; min-height: 0;
}
.menu-page .os-list-card strong { font-size: 14px; }

/* --- Task editor sheet (tap a chore / calendar item) -------- */
#task-layer .task-modal-backdrop {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(8, 22, 24, 0.55);
  backdrop-filter: blur(3px);
  animation: rc-fade 200ms ease;
}
.task-modal {
  position: fixed; z-index: 91;
  left: 50%; bottom: 0;
  transform: translateX(-50%);
  width: min(440px, 100%);
  max-height: 88vh; overflow-y: auto;
  background: #f6fbfc;
  border-radius: 22px 22px 0 0;
  border: 1px solid rgba(35,60,65,0.1);
  box-shadow: 0 -20px 50px -20px rgba(0,0,0,0.5);
  padding: 16px 18px 26px;
  color: var(--ink);
  animation: task-rise 240ms cubic-bezier(.2,.8,.2,1);
}
@keyframes task-rise { from { transform: translate(-50%, 24px); opacity: 0.6; } to { transform: translate(-50%, 0); opacity: 1; } }
.task-modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.task-modal-head h3 { margin: 0; font-size: 16px; font-weight: 750; }
.task-modal-body { display: flex; flex-direction: column; gap: 12px; }
.task-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.task-field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.task-field span { font-size: 10.5px; font-weight: 750; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.task-field input,
.task-field select {
  width: 100%;
  padding: 11px 12px;
  border-radius: 11px;
  border: 1px solid rgba(35,60,65,0.16);
  background: #fff;
  color: var(--ink);
  font-size: 14px; font-weight: 550;
  font-family: inherit;
  min-height: 44px;
}
.task-field input:focus,
.task-field select:focus { outline: 2px solid rgba(53,202,187,0.5); outline-offset: 1px; border-color: transparent; }
.task-instances-wrap {
  margin-top: 2px;
  gap: 0;
  border: 1px solid rgba(35,60,65,0.10);
  border-radius: 12px;
  background: rgba(255,255,255,0.58);
  overflow: hidden;
}
.task-instances-summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 12px;
  cursor: pointer;
  list-style: none;
}
.task-instances-summary::-webkit-details-marker { display: none; }
.task-instances-summary::marker { content: ''; }
.task-instances-summary span { flex: 1; }
.task-instances-summary em {
  min-width: 22px;
  height: 22px;
  padding: 0 7px;
  border-radius: 11px;
  display: inline-grid;
  place-items: center;
  background: rgba(53,202,187,0.16);
  color: var(--accent-dark);
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
}
.task-instances-summary i {
  width: 8px;
  height: 8px;
  border-right: 2px solid #8aa0a5;
  border-bottom: 2px solid #8aa0a5;
  transform: rotate(-45deg);
  transition: transform 180ms ease;
}
.task-instances-wrap[open] .task-instances-summary i { transform: rotate(45deg); border-color: var(--accent-dark); }
.task-instance-list { display: flex; flex-direction: column; gap: 6px; padding: 0 10px 10px; }
.ti-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid rgba(35,60,65,0.08);
  border-radius: 10px;
  background: rgba(255,255,255,0.72);
}
.ti-row.past { opacity: 0.72; }
.ti-when {
  min-width: 0;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--ink-2);
  line-height: 1.25;
}
.ti-state { flex: none; font-size: 10.5px; }

/* Themed native date/time controls (bug #16). The field box already matches .task-field;
   here we calm the picker indicator (kill the default browser blue) and hand the native
   popup the app accent, so a picked date/time reads on-theme in every module's hue. */
input[type="date"], input[type="time"], input[type="datetime-local"] { accent-color: var(--accent-dark); }
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator,
input[type="datetime-local"]::-webkit-calendar-picker-indicator {
  cursor: pointer; opacity: 0.55; filter: saturate(0); transition: opacity 0.15s ease;
}
input[type="date"]::-webkit-calendar-picker-indicator:hover,
input[type="time"]::-webkit-calendar-picker-indicator:hover,
input[type="datetime-local"]::-webkit-calendar-picker-indicator:hover { opacity: 0.9; }
.task-modal-actions { display: flex; gap: 10px; margin-top: 18px; }
/* Footer migrated to the design-system button vocabulary (dc-btn tones, §9.3
   item 4). Delete stays compact on the left; Cancel + Save fill the right. */
.task-modal-actions .dc-btn { min-height: 46px; }
.task-modal-actions .task-editor-del { flex: 0 0 auto; margin-right: auto; }

/* Comments + photo proof in the task editor */
.task-detail-wrap { margin-top: 4px; }
.task-detail-list { display: flex; flex-direction: column; gap: 6px; margin: 4px 0 8px; font-size: 12.5px; color: var(--ink); }
.td-comment { background: rgba(255,255,255,0.7); border: 1px solid rgba(35,60,65,0.08); border-radius: 10px; padding: 7px 10px; }
.td-comment strong { color: var(--accent-dark, #1f8a7e); margin-right: 4px; }
.td-empty { color: var(--ink-3); font-style: italic; }
.td-proofs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.td-proof img { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; border: 1px solid rgba(35,60,65,0.12); }
.task-detail-compose { display: flex; gap: 8px; margin-bottom: 8px; }
.task-detail-compose input { flex: 1; min-height: 38px; border-radius: 10px; border: 1px solid rgba(35,60,65,0.14); padding: 0 10px; font-size: 13px; }
.task-mini-btn { display: inline-flex; align-items: center; justify-content: center; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--accent-dark, #1f8a7e); background: rgba(53,202,187,0.14); color: var(--accent-dark, #1f8a7e); font-size: 12px; font-weight: 650; cursor: pointer; }
.task-proof-row { display: inline-flex; cursor: pointer; }

/* CSV paste area */

/* Invite member status line */
.invite-status { font-size: 12.5px; margin: 8px 2px 0; color: var(--accent-dark, #1f8a7e); min-height: 16px; }
.invite-status.error { color: #c2403a; }

/* Reminder channel picker */
.rem-channel { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; font-size: 13px; color: var(--ink); }
.rem-channel select { border-radius: 10px; border: 1px solid rgba(35,60,65,0.16); padding: 7px 10px; font-size: 13px; background: #fff; }
.task-cancel, .task-save {
  flex: 1; min-height: 46px; border-radius: 999px;
  font-size: 13.5px; font-weight: 700; cursor: pointer;
}
.task-cancel { background: transparent; border: 1px solid rgba(35,60,65,0.18); color: var(--ink-1); }
.task-cancel:hover { background: rgba(35,60,65,0.05); }
.task-save { background: var(--accent-dark); border: 0; color: #fff; }
.task-save:hover { filter: brightness(1.05); }

/* --- Task STATUS page (item 7) --- */
.ts-head-actions { display: flex; align-items: center; gap: 8px; }
.ts-edit { width: 34px; height: 34px; border-radius: 10px; border: 1px solid rgba(35,60,65,0.14); background: #fff; color: var(--accent-dark); display: grid; place-items: center; cursor: pointer; }
.ts-edit:hover { background: rgba(53,202,187,0.1); }
.ts-status { align-self: flex-start; margin-bottom: 12px; }
.ts-card { background: rgba(255,255,255,0.7); border: 1px solid rgba(35,60,65,0.08); border-radius: 14px; overflow: hidden; }
.ts-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 13px 14px; border-top: 1px solid rgba(35,60,65,0.06); }
.ts-row:first-child { border-top: 0; }
.ts-k { font-size: 13px; color: var(--ink-3); font-weight: 600; flex: 0 0 auto; }
.ts-v { font-size: 13.5px; color: var(--ink); text-align: right; }
.ts-actions { display: flex; gap: 10px; }
.ts-act { flex: 1; padding: 13px 10px; border-radius: 999px; font-size: 13.5px; font-weight: 700; cursor: pointer; font-family: inherit; border: 1px solid transparent; transition: transform 120ms ease, filter 120ms ease; }
.ts-act:active { transform: scale(0.97); }
.ts-done { background: var(--accent-dark); color: #fff; }
.ts-done:hover { filter: brightness(1.05); }
.ts-cant { background: rgba(211,147,74,0.16); color: #9a5e12; border-color: rgba(211,147,74,0.4); }
.ts-cant:hover { background: rgba(211,147,74,0.26); }
.ts-resched { background: #fff; color: var(--ink-1); border: 1px solid rgba(35,60,65,0.2); }
.ts-resched:hover { background: rgba(35,60,65,0.05); }

/* Reschedule sheet (item 4) */
.resched-task { font-size: 15px; font-weight: 700; color: var(--ink); margin: 0 0 12px; }
.resched-fields { display: flex; gap: 10px; margin-bottom: 14px; }
.resched-fields .task-field { flex: 1; }
.resched-fields input { width: 100%; box-sizing: border-box; padding: 11px 12px; border-radius: 11px; border: 1px solid rgba(35,60,65,0.18); background: #fff; font-size: 14px; font-family: inherit; color: var(--ink); }
.resched-scope-label { display: block; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; }
.resched-opt { display: flex; gap: 10px; align-items: flex-start; padding: 11px 12px; border-radius: 12px; border: 1px solid rgba(35,60,65,0.14); margin-bottom: 8px; cursor: pointer; transition: border-color 140ms ease, background 140ms ease; }
.resched-opt:has(input:checked) { border-color: var(--accent-dark); background: rgba(53,202,187,0.07); }
.resched-opt input { margin-top: 3px; accent-color: var(--accent-dark); }
.resched-opt span { display: flex; flex-direction: column; gap: 2px; }
.resched-opt b { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.resched-opt em { font-style: normal; font-size: 11.5px; color: var(--ink-3); line-height: 1.35; }

/* Person editor: toggles + delete */
.person-toggle-row { display: flex; flex-direction: column; gap: 9px; }
.person-toggle { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border-radius: 13px; background: #fff; border: 1px solid rgba(35,60,65,0.12); cursor: pointer; }
.person-toggle .pt-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.person-toggle .pt-text strong { font-size: 13.5px; font-weight: 680; color: var(--ink); }
.person-toggle .pt-text em { font-size: 11px; font-style: normal; color: var(--ink-3); }
.person-modal-actions { justify-content: space-between; }
/* Advance block (item 9 + enrichment) — collapsible: summary always, detail on click */
.advance-block { margin-top: 4px; border-radius: 12px; background: rgba(53,202,187,0.06); border: 1px solid rgba(53,202,187,0.16); overflow: hidden; }
.advance-summary { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px; background: none; border: 0; cursor: pointer; font-family: inherit; }
.advance-summary-main { display: flex; gap: 22px; }
.as-item { display: flex; flex-direction: column; gap: 2px; text-align: left; }
.as-item span { font-size: 10.5px; font-weight: 650; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-3); }
.as-item b { font-size: 15px; font-weight: 750; color: var(--ink); }
.advance-chevron { font-size: 13px; color: var(--accent-dark); transition: transform 180ms ease; }
.advance-block.open .advance-chevron { transform: rotate(180deg); }
.advance-detail { max-height: 0; overflow: hidden; transition: max-height 260ms ease; padding: 0 12px; }
.advance-block.open .advance-detail { max-height: 1100px; padding: 0 12px 12px; }
/* Statement: total advances − paid until now = outstanding */
.adv-statement { margin: 8px 0 12px; border: 1px solid rgba(53,202,187,0.22); border-radius: 11px; background: #fff; overflow: hidden; }
.adv-st-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 13px; border-bottom: 1px solid rgba(35,60,65,0.06); }
.adv-st-row:last-child { border-bottom: 0; }
.adv-st-k { font-size: 13px; color: var(--ink-2); font-weight: 600; }
.adv-st-tag { font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: rgba(53,202,187,0.14); color: var(--accent-dark); margin-left: 6px; }
.adv-st-v { font-size: 15px; font-weight: 740; color: var(--ink); font-variant-numeric: tabular-nums; }
.adv-st-v.minus { color: var(--accent-dark); }
.adv-st-row.total { background: #f1faf8; }
.adv-st-row.total .adv-st-k { font-weight: 740; color: var(--ink); }
.adv-st-v.out { font-size: 19px; font-weight: 820; color: var(--accent-dark); letter-spacing: -0.01em; }
/* This-month / last-month mini tiles */
.adv-month-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.adv-mini { background: rgba(35,60,65,0.04); border-radius: 11px; padding: 10px 12px; }
.adv-mini-k { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-3); font-weight: 700; margin: 0 0 3px; }
.adv-mini-v { font-size: 16px; font-weight: 760; color: var(--ink); font-variant-numeric: tabular-nums; }
.adv-mini-sub { font-size: 10px; color: var(--ink-4); font-weight: 600; margin: 2px 0 0; }
.adv-ledger-title { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3); font-weight: 700; margin: 14px 0 6px; }
.adv-ledger-empty { font-size: 12.5px; color: var(--ink-4); margin: 4px 0 8px; }
.advance-history { margin-bottom: 10px; border-top: 1px solid rgba(53,202,187,0.16); }
.advance-hrow { display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(35,60,65,0.05); font-size: 12.5px; color: var(--ink); }
.adv-h-date { font-family: "SF Mono", ui-monospace, Menlo, monospace; font-size: 11.5px; color: var(--ink-3); }
.adv-h-amt { font-weight: 740; font-variant-numeric: tabular-nums; }
.adv-del { width: 22px; height: 22px; border-radius: 6px; border: 1px solid rgba(193,64,58,0.28); background: #fff; color: #c2403a; font-size: 11px; line-height: 1; cursor: pointer; flex: 0 0 auto; }
.adv-del:hover { background: rgba(193,64,58,0.1); }
.advance-hrow.adv-removing { opacity: 0; transform: translateX(8px); transition: opacity 160ms ease, transform 160ms ease; }
.adv-stage-note { color: #b06f12; font-weight: 600; }
.advance-hrow b { font-weight: 700; }
.adv-status { font-style: normal; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 999px; }
.adv-open { background: rgba(207,143,42,0.14); color: #b06f12; }
.adv-deducted { background: rgba(31,138,126,0.12); color: #1f8a7e; }
.adv-waived { background: rgba(35,60,65,0.1); color: var(--ink-3); }
.advance-hint { font-size: 11px; color: var(--ink-3); line-height: 1.4; margin: 8px 0 0; }
.advance-add-row { margin: 4px 0 2px; }
.advance-add-toggle { display: inline-flex; align-items: center; gap: 7px; background: rgba(53,202,187,0.10); border: 1px dashed rgba(53,202,187,0.45); color: var(--accent-dark); font-family: inherit; font-size: 13px; font-weight: 700; padding: 9px 14px; border-radius: 10px; cursor: pointer; }
.advance-add-toggle:active { transform: scale(0.98); }
.advance-add-toggle .adv-add-plus { font-size: 16px; line-height: 1; font-weight: 800; }
.advance-add-row.open .advance-add-toggle { display: none; }
.advance-add-fields[hidden] { display: none; }
.person-delete { flex: 0 0 auto; min-height: 46px; padding: 0 20px; border-radius: 999px; border: 1px solid rgba(200,90,70,0.35); background: rgba(216,105,79,0.08); color: #c0593f; font-size: 13.5px; font-weight: 700; font-family: inherit; cursor: pointer; }
.person-delete:hover { background: rgba(216,105,79,0.16); }
.person-modal-actions .task-save { flex: 1; }

/* ============================================================
   TASK EDITOR — extra controls (priority / schedule / reminders)
   ============================================================ */
.task-field-label { font-size: 10.5px; font-weight: 750; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); display: block; margin-bottom: 7px; }

/* Segmented priority control */
.seg-control { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.seg-btn {
  min-height: 42px; border-radius: 11px; cursor: pointer;
  border: 1px solid rgba(35,60,65,0.16); background: #fff; color: var(--ink-2);
  font-size: 13px; font-weight: 650; font-family: inherit; transition: all 140ms ease;
}
.seg-btn.active.prio-low    { background: #b6dcc0; border-color: transparent; color: #143524; }
.seg-btn.active.prio-medium { background: #ecd2a6; border-color: transparent; color: #41300c; }
.seg-btn.active.prio-high   { background: #ecb7b0; border-color: transparent; color: #471812; }
/* Generic active state for non-priority segmented controls (e.g. dish Veg/Egg/Non-veg). */
.seg-btn.active { background: var(--ink, #233c41); border-color: transparent; color: #fff; }

/* Schedule control */
.sched-control { display: flex; flex-direction: column; gap: 9px; }
.sched-note { margin: 0; font-size: 13px; color: var(--ink-3); font-style: italic; }
.sched-hint { margin: 0; font-size: 11.5px; font-weight: 600; color: var(--ink-3); }
.day-chips { display: flex; gap: 6px; }
.day-chip {
  flex: 1; min-width: 0; height: 40px; border-radius: 10px; cursor: pointer;
  border: 1px solid rgba(35,60,65,0.16); background: #fff; color: var(--ink-2);
  font-size: 13px; font-weight: 700; font-family: inherit; transition: all 130ms ease;
}
.day-chip.active { background: var(--accent-dark, #1f8a7a); border-color: transparent; color: #fff; }
.week-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.week-chip {
  padding: 9px 14px; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(35,60,65,0.16); background: #fff; color: var(--ink-2);
  font-size: 12.5px; font-weight: 650; font-family: inherit; transition: all 130ms ease;
}
.week-chip.active { background: var(--accent-dark, #1f8a7a); border-color: transparent; color: #fff; }
.sched-date {
  width: 100%; padding: 11px 12px; border-radius: 11px; min-height: 44px;
  border: 1px solid rgba(35,60,65,0.16); background: #fff; color: var(--ink); font-size: 14px; font-family: inherit;
}

/* Reminder chips */

.rem-chip.active { background: #d7ecf2; border-color: transparent; color: #123038; }
.rem-chip.active::before { content: '✓ '; font-weight: 800; }

/* Cadence-aware reminder controls */
.rem-toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 13px; border-radius: 12px; background: #fff; border: 1px solid rgba(35,60,65,0.14); cursor: pointer; margin-bottom: 9px; }
.rem-toggle-row span:first-child { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.rem-lead-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.rem-stepper { display: flex; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 12px; background: #fbfdfd; border: 1px solid rgba(35,60,65,0.12); }
.rem-step-btn { width: 30px; height: 30px; border-radius: 8px; border: 1px solid rgba(35,60,65,0.16); background: #fff; color: var(--ink-1); font-size: 17px; line-height: 1; cursor: pointer; font-family: inherit; flex: 0 0 auto; }
.rem-step-btn:active { background: rgba(35,60,65,0.06); }
.rem-val { min-width: 18px; text-align: center; font-size: 16px; font-weight: 740; color: var(--ink); font-variant-numeric: tabular-nums; }
.rem-stepper em { font-size: 11.5px; font-style: normal; color: var(--ink-3); line-height: 1.2; }

/* ============================================================
   HOMEOS SETTINGS SUB-SCREENS
   ============================================================ */
.settings-head-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.settings-add {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 5px;
  padding: 9px 13px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--accent-dark, #1f8a7a); color: #fff; font-size: 12.5px; font-weight: 700; font-family: inherit;
}
.settings-add svg { width: 14px; height: 14px; }
.settings-foot { margin: 16px 2px 0; font-size: 11.5px; line-height: 1.5; color: var(--ink-3); }
.req-star { color: #d8694f; font-style: normal; font-weight: 800; }

/* People */
.person-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 6px; }
.person-row {
  display: flex; align-items: center; gap: 11px;
  width: 100%; text-align: left; cursor: pointer; font-family: inherit;
  padding: 11px 13px; border-radius: 14px;
  background: rgba(255,255,255,0.74); border: 1px solid rgba(35,60,65,0.06);
  transition: background 140ms ease, transform 120ms ease;
}
.person-row:hover { background: #fff; }
.person-row:active { transform: scale(0.995); }
.person-edit-chev { flex: 0 0 auto; font-size: 19px; color: #c0cbce; line-height: 1; margin-left: 1px; }
.person-avatar {
  flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; font-size: 13px; font-weight: 750; color: #fff;
}
.person-avatar.tone-admin   { background: #b07d9a; }
.person-avatar.tone-coadmin { background: #6a7fb0; }
.person-avatar.tone-member  { background: #6aa39a; }
.person-avatar.tone-staff   { background: #b59650; }
.person-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.person-main strong { font-size: 14px; font-weight: 680; color: var(--ink); }
.person-main em { font-size: 11.5px; font-style: normal; color: var(--ink-3); line-height: 1.3; }
.person-side { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.role-tag { font-size: 10px; font-weight: 750; letter-spacing: 0.03em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; }
.role-tag.tone-admin   { background: #f0dceb; color: #80315f; }
.role-tag.tone-coadmin { background: #dde3f2; color: #324a80; }
.role-tag.tone-member  { background: #d9ece8; color: #1f5a4f; }
.role-tag.tone-staff   { background: #efe3c8; color: #6e5413; }
.login-tag { font-size: 10px; font-weight: 650; color: var(--ink-4); }
.login-tag.on  { color: #2c8a5f; }
.login-tag.off { color: var(--ink-4); }

/* Staff directory */
.staff-list { display: flex; flex-direction: column; gap: 12px; }
.staff-card { padding: 14px; border-radius: 16px; background: rgba(255,255,255,0.78); border: 1px solid rgba(35,60,65,0.07); width: 100%; text-align: left; cursor: pointer; font-family: inherit; transition: background 140ms ease, transform 120ms ease; }
.staff-card:hover { background: #fff; }
.staff-card:active { transform: scale(0.995); }
.staff-card-head { display: flex; align-items: center; gap: 11px; margin-bottom: 12px; }
.staff-card-id { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.staff-card-id strong { font-size: 15px; font-weight: 720; color: var(--ink); }
.staff-card-id em { font-size: 12px; font-style: normal; color: var(--ink-3); }
.staff-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 11px 0; border-top: 1px solid rgba(35,60,65,0.08); border-bottom: 1px solid rgba(35,60,65,0.08); }
.staff-meta div { display: flex; flex-direction: column; gap: 3px; }
.staff-meta span { font-size: 9.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink-4); }
.staff-meta b { font-size: 12px; font-weight: 600; color: var(--ink); }
.staff-next { margin-top: 11px; font-size: 12px; font-weight: 600; color: #b06a4a; }

/* Import */
.import-cols { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.col-chip { font-size: 11px; font-weight: 600; color: var(--ink-2); background: rgba(255,255,255,0.8); border: 1px solid rgba(35,60,65,0.1); padding: 5px 10px; border-radius: 999px; }
.import-drop {
  display: flex; flex-direction: column; align-items: center; gap: 5px; text-align: center;
  padding: 22px 16px; border-radius: 16px; background: rgba(255,255,255,0.55);
  border: 1.5px dashed rgba(35,60,65,0.25);
}
.import-drop-icon { color: var(--ink-4); }
.import-drop strong { font-size: 14px; color: var(--ink); }
.import-drop em { font-size: 11.5px; font-style: normal; color: var(--ink-3); }
.import-browse { margin-top: 8px; padding: 9px 18px; border-radius: 999px; border: 0; cursor: pointer; background: var(--accent-dark, #1f8a7a); color: #fff; font-size: 12.5px; font-weight: 700; font-family: inherit; }
.import-status { min-height: 16px; margin: 8px 2px 0; color: var(--accent-dark, #1f8a7a); font-size: 12px; font-weight: 620; }
.import-status.error { color: #c2403a; }

.import-review-title { display: flex; align-items: center; }
.review-count { margin-left: auto; font-size: 11px; font-weight: 600; color: var(--ink-4); text-transform: none; letter-spacing: 0; }
.import-select-all {
  align-self: flex-start;
  border: 1px solid rgba(35,60,65,0.08);
  border-radius: 999px;
  background: rgba(255,255,255,0.78);
  color: var(--accent-dark, #1f8a7a);
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  font-weight: 720;
  margin: -2px 0 8px;
  padding: 8px 13px;
}
.import-list { display: flex; flex-direction: column; gap: 7px; }
.import-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 13px; background: rgba(255,255,255,0.74); border: 1px solid rgba(35,60,65,0.06); }
.import-row.invalid { background: rgba(236,183,176,0.18); border-color: rgba(200,90,70,0.25); }
.import-check { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; font-size: 13px; font-weight: 800; color: #fff; background: #cdd5d7; }
.import-check.on { background: var(--accent-dark, #1f8a7a); }
.import-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.import-main strong { font-size: 13.5px; font-weight: 650; color: var(--ink); }
.import-main em { font-size: 11px; font-style: normal; color: var(--ink-3); }
.import-flag { flex: 0 0 auto; font-size: 11px; font-weight: 700; }
.import-flag.ok { color: #2c8a5f; }
.import-flag.fix { color: #c0593f; }
.import-commit { width: 100%; margin-top: 14px; min-height: 48px; border-radius: 999px; border: 0; cursor: pointer; background: var(--accent-dark, #1f8a7a); color: #fff; font-size: 14px; font-weight: 720; font-family: inherit; }

/* Task format */
.field-list { display: flex; flex-direction: column; gap: 7px; }
.field-row { display: flex; align-items: center; gap: 10px; padding: 11px 13px; border-radius: 13px; background: rgba(255,255,255,0.74); border: 1px solid rgba(35,60,65,0.06); }
.field-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.field-main strong { font-size: 13.5px; font-weight: 680; color: var(--ink); }
.field-main em { font-size: 11.5px; font-style: normal; color: var(--ink-3); }
.field-type { flex: 0 0 auto; font-size: 10.5px; font-weight: 700; color: var(--ink-2); background: rgba(35,60,65,0.07); padding: 4px 10px; border-radius: 999px; }

/* Reminders & schedule */
.quiet-card { display: flex; align-items: center; gap: 12px; padding: 13px 15px; border-radius: 16px; background: rgba(255,255,255,0.78); border: 1px solid rgba(35,60,65,0.07); margin-bottom: 6px; }
.quiet-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.quiet-main strong { font-size: 14px; font-weight: 700; color: var(--ink); }
.quiet-main em { font-size: 11.5px; font-style: normal; color: var(--ink-3); }
.quiet-toggle { flex: 0 0 auto; width: 42px; height: 25px; border-radius: 999px; background: #cdd5d7; position: relative; transition: background 160ms ease; }
.quiet-toggle.on { background: var(--accent-dark, #1f8a7a); }
.quiet-toggle i { position: absolute; top: 3px; left: 3px; width: 19px; height: 19px; border-radius: 50%; background: #fff; transition: left 160ms ease; }
.quiet-toggle.on i { left: 20px; }
.rule-list { display: flex; flex-direction: column; gap: 9px; }
.rule-row { padding: 13px 15px; border-radius: 15px; background: rgba(255,255,255,0.76); border: 1px solid rgba(35,60,65,0.06); }
.rule-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.rule-head strong { font-size: 14px; font-weight: 720; color: var(--ink); }
.rule-sched { font-size: 11.5px; font-weight: 600; color: #4d7d86; background: rgba(53,150,160,0.1); padding: 4px 10px; border-radius: 999px; }
.rule-leads { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.rule-leads-label { font-size: 10px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-4); margin-right: 2px; }
.lead-chip { font-size: 11.5px; font-weight: 600; color: #123038; background: #d7ecf2; padding: 5px 11px; border-radius: 999px; }
.lead-chip.off { background: rgba(35,60,65,0.07); color: var(--ink-4); }
.lead-add { width: 26px; height: 26px; border-radius: 50%; border: 1px dashed rgba(35,60,65,0.3); background: transparent; color: var(--ink-3); font-size: 15px; line-height: 1; cursor: pointer; }

/* Audit log */
.audit-list { display: flex; flex-direction: column; gap: 0; position: relative; }
.audit-row { display: flex; gap: 12px; padding: 11px 2px 11px 0; border-bottom: 1px solid rgba(35,60,65,0.07); }
.audit-row:last-child { border-bottom: 0; }
.audit-dot { flex: 0 0 auto; width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; background: #aab6b9; }
.audit-dot.tone-done { background: #3f9e72; }
.audit-dot.tone-edit { background: #5f86c0; }
.audit-dot.tone-warn { background: #d8694f; }
.audit-dot.tone-sys  { background: #b59650; }
.audit-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.audit-main strong { font-size: 13px; font-weight: 700; color: var(--ink); line-height: 1.35; }
.audit-main strong span { font-weight: 500; color: var(--ink-2); }

/* ============================================================
   HomeOS menu — left slide-in drawer (item 7) + reduced items (item 8)
   ============================================================ */
.os-drawer-scrim {
  position: fixed; inset: 0; z-index: 80;
  background: rgba(16,28,31,0.42); backdrop-filter: blur(1.5px);
  opacity: 0; pointer-events: none; transition: opacity 200ms ease;
}
.os-drawer-scrim.open { opacity: 1; pointer-events: auto; }
.os-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 81;
  width: min(86vw, 320px); display: flex; flex-direction: column;
  background: #f6fbfb; border-left: 1px solid rgba(35,60,65,0.1);
  box-shadow: -18px 0 50px -22px rgba(8,27,32,0.5);
  transform: translateX(104%); transition: transform 260ms cubic-bezier(.22,.61,.36,1);
  padding: 18px 16px calc(18px + env(safe-area-inset-bottom));
  overflow-y: auto;
}
.os-drawer.open { transform: translateX(0); }
.os-drawer-head { display: flex; align-items: center; justify-content: space-between; margin: 4px 2px 14px; }
.os-drawer-title { margin: 0; font-size: 20px; font-weight: 780; letter-spacing: -0.02em; color: #2c4650; }
/* Shared ☰ menu (H2): profile row + notification badge */
.app-menu-head { align-items: flex-start; gap: 10px; }
.os-menu-profile { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 4px 2px; border: 0; background: none; cursor: pointer; text-align: left; font-family: inherit; }
.os-menu-avatar { width: 44px; height: 44px; flex: 0 0 auto; border-radius: 50%; display: grid; place-items: center; background: var(--accent-dark); color: #fff; font-weight: 700; font-size: 17px; }
.os-menu-prof { display: grid; gap: 2px; min-width: 0; }
.os-menu-prof strong { font-size: 15px; font-weight: 650; color: var(--ink-1); }
.os-menu-prof em { font-size: 12px; font-style: normal; color: var(--ink-3); }
.os-menu-badge { flex: 0 0 auto; min-width: 20px; height: 20px; margin-left: auto; padding: 0 6px; border-radius: 999px; background: var(--neg-solid); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.os-drawer-x {
  width: 38px; height: 38px; border-radius: 50%; display: inline-grid; place-items: center;
  background: #fff; border: 1px solid rgba(35,60,65,0.1); color: var(--ink-2); cursor: pointer; font-size: 18px;
}
.os-menu-list { display: flex; flex-direction: column; gap: 4px; }
.os-menu-item {
  display: flex; align-items: center; gap: 13px; width: 100%; text-align: left;
  padding: 13px 12px; border-radius: 13px; border: 0; background: transparent; cursor: pointer;
  color: var(--ink); font-family: inherit; transition: background 130ms ease;
}
.os-menu-item:hover { background: rgba(53,202,187,0.1); }
.os-menu-ico { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: rgba(53,202,187,0.14); color: var(--accent-dark); }
.os-menu-ico svg { width: 19px; height: 19px; }
.os-menu-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.os-menu-body strong { font-size: 15.5px; font-weight: 650; letter-spacing: -0.01em; }
.os-menu-body em { font-style: normal; font-size: 12px; color: var(--ink-3); }
.os-menu-item .os-menu-chev { color: #b3c2c6; font-size: 20px; line-height: 1; }
.os-menu-divider { height: 1px; background: rgba(35,60,65,0.08); margin: 10px 8px; }
.os-menu-signout {
  margin: 6px 2px 2px; display: flex; align-items: center; justify-content: center; gap: 9px;
  padding: 14px; border-radius: 13px; border: 0; cursor: pointer; font-family: inherit;
  font-size: 15px; font-weight: 700; color: #b4402f; background: rgba(214,90,70,0.12);
  transition: background 130ms ease;
}
.os-menu-signout:hover { background: rgba(214,90,70,0.2); }
.os-menu-signout svg { width: 18px; height: 18px; }
.task-import-link {
  display: inline-flex; align-items: center; gap: 4px; margin: 0 0 4px;
  background: none; border: 0; padding: 4px 0; cursor: pointer; font-family: inherit;
  font-size: 13px; font-weight: 650; color: var(--accent-dark);
}
.audit-main em { font-size: 11px; font-style: normal; color: var(--ink-4); }

/* ============================================================
   MEALS — collapsible day view, recipe card, recipes library, PDFs
   ============================================================ */
/* Collapsible Breakfast / Lunch / Dinner sections (item 6) — match cadence look. */
.meal-day-collapse, .meal-week-collapse { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.meal-slot-section {
  display: block; overflow: hidden; border: 1px solid rgba(35,60,65,0.08);
  border-radius: 14px; background: rgba(255,255,255,0.62);
}
.meal-slot-section > summary.meal-slot-head {
  display: flex; align-items: center; gap: 10px; margin: 0; padding: 13px 15px; cursor: pointer;
  list-style: none; font-size: 18px; font-weight: 650; letter-spacing: 0; color: var(--ink-3);
  -webkit-tap-highlight-color: transparent;
}
.meal-slot-section > summary::-webkit-details-marker { display: none; }
.meal-slot-name { flex: 1; color: var(--ink-3); }
.meal-slot-total { font-size: 12px; font-weight: 650; color: var(--ink-3, #6b7c81); }
.meal-slot-chev { width: 8px; height: 8px; flex: 0 0 auto; border-right: 2px solid #8aa0a5; border-bottom: 2px solid #8aa0a5; transform: rotate(-45deg); transition: transform 180ms ease; }
.meal-slot-section[open] > summary .meal-slot-chev { transform: rotate(45deg); border-color: var(--ink-4); }
.meal-slot-body { padding: 0 10px 10px; display: flex; flex-direction: column; gap: 6px; }
/* Dish row: name (left) · kcal-per-person (right). */
.meal-dish-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%;
  text-align: left; padding: 11px 12px; border: 1px solid rgba(35,60,65,0.07); border-radius: 11px;
  background: #fff; cursor: pointer; font-family: inherit; transition: background 130ms ease, border-color 130ms ease;
}
.meal-dish-row:hover { background: #f4fbfa; border-color: rgba(53,202,187,0.4); }
.mdr-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mdr-name { font-size: 15px; font-weight: 400; color: var(--ink); }
.mdr-sub { font-size: 12px; color: var(--ink-3); }
.mdr-sub b { color: var(--accent-dark); font-weight: 700; }
.mdr-right { flex: 0 0 auto; display: flex; align-items: center; gap: 9px; }
.mdr-mark { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.03em; padding: 3px 7px; border-radius: 7px; background: rgba(53,202,187,0.16); color: var(--accent-dark); }
.mdr-mark.mark-NV { background: rgba(214,128,80,0.18); color: #b5612e; }
.mdr-mark.mark-E { background: rgba(232,184,74,0.22); color: #9a7415; }
.mdr-kcal { font-size: 15px; font-weight: 750; color: var(--ink); white-space: nowrap; text-align: right; }
.mdr-kcal i { display: block; font-size: 9.5px; font-weight: 600; font-style: normal; color: var(--ink-4); letter-spacing: 0.02em; }
.meal-day-card { border: 1px solid rgba(35,60,65,0.08); border-radius: 16px; background: rgba(255,255,255,0.5); padding: 12px; display: flex; flex-direction: column; gap: 9px; }
.meal-day-card > .meal-day-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 2px 4px; }
.meal-day-card > .meal-day-head strong { font-size: 18px; font-weight: 650; color: var(--ink-3); }
.meal-day-card > .meal-day-head span { font-size: 12px; color: var(--ink-3); }

/* Interactive imported-recipe card (item 4) — reuses .recipe-modal shell. */
.recipe-modal.rc2 { max-width: min(760px, calc(100vw - 24px)); max-height: 94dvh; }
.rc2 .recipe-modal-head { position: sticky; top: 0; z-index: 3; background: linear-gradient(180deg,#ffffff,#fbfeff); }
.rc2 .recipe-modal-head h3 { font-size: 19px; }
/* Revamped header: tag · title · 2–3 point description */
.rc2-head-main { min-width: 0; }
.rc2-tag { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: var(--accent-dark); background: rgba(53,202,187,0.14); padding: 3px 9px; border-radius: 999px; }
.rc2-desc { margin: 6px 0 0; font-size: 13.5px; line-height: 1.5; color: var(--ink-3); text-wrap: pretty; }
/* Adaptive 3-stat row (changes per recipe) */
.rc2-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 12px 18px; border-bottom: 1px solid rgba(35,60,65,0.07); background: #fbfeff; }
.rc2-stats:empty { display: none; }
.rc2-stat { display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: 12px; background: rgba(35,60,65,0.04); }
.rc2-stat-k { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-3); }
.rc2-stat-v { font-size: 15px; font-weight: 750; color: var(--ink); }
/* Larger, clearer instruction text */
.rc2-step-time { display: inline-block; margin-top: 6px; }
.rc2-step-body { padding-top: 1px; }
/* Bottom kcal block + manage actions */
.rc2-kcal-block { margin-top: 18px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; padding: 12px 14px; border-radius: 12px; background: rgba(53,202,187,0.10); }
.rc2-kcal-block strong { font-size: 17px; font-weight: 800; color: var(--ink); }
.rc2-kcal-block span { font-size: 12.5px; color: var(--ink-3); }
.rc2-manage { margin-top: 18px; display: flex; gap: 10px; padding-top: 16px; border-top: 1px solid rgba(35,60,65,0.08); }
.rc2-manage-btn { flex: 1; min-height: 44px; border-radius: 12px; border: 1px solid rgba(35,60,65,0.18); background: #fff; font-family: inherit; font-size: 13.5px; font-weight: 700; color: var(--ink); cursor: pointer; transition: all 140ms ease; }
.rc2-manage-btn:active { transform: scale(0.98); }
.rc2-manage-btn.danger { color: #b4392f; border-color: rgba(180,57,47,0.3); }
.rc2-manage-btn.danger:hover { background: rgba(180,57,47,0.06); }
.rc2-meta { margin: 4px 0 0; font-size: 12.5px; color: var(--ink-3); }
.rc2-serving { position: sticky; top: 60px; z-index: 2; display: flex; align-items: center; gap: 10px; padding: 12px 18px; background: rgba(53,202,187,0.12); border-bottom: 1px solid rgba(35,60,65,0.08); margin: 0; }
.rc2-serving-label { font-size: 13px; font-weight: 650; color: var(--ink-1); }
.rc2-stepper { display: inline-flex; align-items: center; gap: 6px; }
.rc2-step-btn { width: 34px; height: 34px; border-radius: 50%; border: 1px solid rgba(53,202,187,0.4); background: #fff; font-size: 18px; cursor: pointer; color: var(--accent-dark); display: grid; place-items: center; }
.rc2-step-btn:active { transform: scale(0.92); }
.rc2-serving-count { min-width: 28px; text-align: center; font-size: 18px; font-weight: 800; color: var(--ink); }
.rc2-serving-unit { font-size: 13px; color: var(--ink-3); }
.rc2-body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 16px 18px 26px; }
.rc2-content-grid { display: grid; grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr); gap: 16px; align-items: start; }
.rc2-content-pane { min-width: 0; }
.rc2-block-title { margin: 6px 0 10px; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-3); }
.rc2-block-title + .rc2-block-title { margin-top: 18px; }
.rc2-steps + .rc2-block-title, .rc2-section + .rc2-block-title { margin-top: 22px; }
.rc2-section { margin-bottom: 10px; border: 1px solid rgba(35,60,65,0.09); border-radius: 14px; overflow: hidden; background: #fff; }
.rc2-section-head { margin: 0; padding: 9px 13px; font-size: 13px; font-weight: 700; color: var(--ink-3); background: rgba(107,124,129,0.08); border-bottom: 1px solid rgba(35,60,65,0.07); }
.rc2-ing-table { display: flex; flex-direction: column; }
.rc2-ing-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 13px; font-size: 14.5px; }
.rc2-ing-row:nth-child(even) { background: rgba(35,60,65,0.025); }
.rc2-ing-name { color: #33474c; }
.rc2-qty { font-weight: 750; color: var(--accent-dark); white-space: nowrap; font-variant-numeric: tabular-nums; }
.rc2-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.rc2-step { display: flex; gap: 12px; align-items: flex-start; }
.rc2-step-n { flex: 0 0 auto; width: 28px; height: 28px; border-radius: 50%; background: var(--accent-dark); color: #fff; display: grid; place-items: center; font-size: 13px; font-weight: 800; }
.rc2-step-group { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 13px; font-weight: 700; color: var(--ink-3); }
.rc2-step-time { font-size: 11px; font-weight: 700; color: var(--accent-dark); background: rgba(53,202,187,0.16); padding: 2px 8px; border-radius: 999px; }
.rc2-step-body { padding-top: 2px; }
.rc2-step-body p { margin: 3px 0 0; font-size: 13.5px; line-height: 1.48; color: var(--ink-2); }
.rc2-substeps { margin: 6px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.rc2-substeps li::marker { color: var(--accent-dark); font-weight: 700; }
.rc2-substeps p { margin: 0; }
.rc2-step-details { margin: 6px 0 0; padding-left: 17px; color: var(--ink-3); font-size: 13px; line-height: 1.4; }
.rc2-notes { margin-top: 18px; border: 1px solid rgba(53,202,187,0.25); border-radius: 12px; background: rgba(53,202,187,0.06); padding: 10px 13px; }
.rc2-notes summary { font-size: 13.5px; font-weight: 700; color: var(--accent-dark); cursor: pointer; list-style: none; }
.rc2-notes summary::-webkit-details-marker { display: none; }
.rc2-notes ol { margin: 8px 0 0; padding-left: 18px; font-size: 13.5px; color: var(--ink-2); display: flex; flex-direction: column; gap: 6px; line-height: 1.4; }
.rc2-empty { font-size: 13px; color: var(--ink-4); font-style: italic; }
.rc2-import-result { margin-top: 12px; }
@media (max-width: 700px) {
  .recipe-modal.rc2 { max-width: min(560px, calc(100vw - 18px)); }
  .rc2-content-grid { grid-template-columns: 1fr; gap: 12px; }
}

/* Recipes library (item 8) */
.rec-lib-searchbar { display: flex; align-items: center; gap: 8px; background: #fff; border: 1px solid rgba(35,60,65,0.12); border-radius: 12px; padding: 0 12px; margin: 4px 0 8px; }
.rec-lib-search-ico { font-size: 17px; color: var(--ink-4); }
.rec-lib-search { flex: 1; border: 0; outline: 0; background: none; padding: 12px 0; font-size: 15px; font-family: inherit; color: var(--ink); }
.rec-lib-count { margin: 0 2px 10px; font-size: 12px; color: var(--ink-3); }
.rec-lib-list { display: flex; flex-direction: column; gap: 6px; }
.rec-lib-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; text-align: left; padding: 13px 14px; border: 1px solid rgba(35,60,65,0.08); border-radius: 12px; background: #fff; cursor: pointer; font-family: inherit; transition: background 130ms ease, border-color 130ms ease; }
.rec-lib-row:hover { background: #f4fbfa; border-color: rgba(53,202,187,0.4); }
.rec-lib-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rec-lib-name { font-size: 15px; font-weight: 650; color: var(--ink); }
.rec-lib-tag { font-size: 11px; color: var(--ink-4); }
.rec-lib-tag.has { color: var(--ink-3); font-weight: 650; }
.rec-lib-kcal { flex: 0 0 auto; font-size: 15px; font-weight: 750; color: var(--ink); white-space: nowrap; text-align: right; }
.rec-lib-kcal i { display: block; font-size: 9.5px; font-weight: 600; font-style: normal; color: var(--ink-4); }
.rec-lib-empty { font-size: 13.5px; color: var(--ink-3); padding: 18px 4px; text-align: center; }

/* Previous weeks — raw PDF chips (item 7) */
.prev-week { display: flex; flex-direction: column; gap: 9px; }
.prev-week-head { display: flex; align-items: center; gap: 8px; }
.prev-pdf-row { display: flex; flex-wrap: wrap; gap: 8px; padding-left: 2px; }
.prev-pdf-chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 999px; border: 1px solid rgba(35,60,65,0.14); background: #fff; cursor: pointer; font-family: inherit; font-size: 12.5px; font-weight: 650; color: #3a5560; }
.prev-pdf-chip:hover { background: #f4fbfa; border-color: rgba(53,202,187,0.45); }
.prev-pdf-chip svg { width: 16px; height: 16px; }

/* Ingredients — category pill on each item card + active filter/sort icon */
.ing-buyday-chip { font-size: 10px; font-weight: 800; letter-spacing: 0.02em; padding: 3px 8px; border-radius: 7px; background: rgba(245,196,86,0.18); color: #8a6410; white-space: nowrap; }
.ing-buyday-chip.bd-both { background: rgba(160,120,200,0.18); color: #6f4ba8; }
.ing-fresh-chip { font-size: 10px; font-weight: 800; letter-spacing: 0.02em; padding: 3px 8px; border-radius: 7px; background: rgba(90,180,120,0.16); color: #2f7d4f; white-space: nowrap; }
.ing-cat-pill { font-size: 10px; font-weight: 800; letter-spacing: 0.03em; text-transform: uppercase; padding: 3px 8px; border-radius: 7px; background: rgba(53,202,187,0.14); color: var(--accent-dark); white-space: nowrap; }
.ing-cat-pill.cat-produce { background: rgba(120,190,90,0.16); color: #4f7a1f; }
.ing-cat-pill.cat-protein { background: rgba(214,128,80,0.16); color: #b5612e; }
.ing-cat-pill.cat-dairy   { background: rgba(90,150,220,0.16); color: #3463a8; }
.ing-cat-pill.cat-pantry  { background: rgba(160,120,200,0.16); color: #7a4fb0; }
.ing-cat-pill.cat-spice   { background: rgba(214,160,60,0.18); color: #9a6f12; }
.ingr-item-card { cursor: pointer; }
.os-head-btn.active { background: var(--accent-dark, #1f8a7e); border-color: var(--accent-dark, #1f8a7e); color: #fff; }
.os-head-btn.active svg { color: #fff; }
.ingr-cadence .cadence-body { gap: 6px; }

/* Meals — persistent action bar (Plan next week / Import), Today empty, edit mode */
.meals-actionbar { display: flex; gap: 9px; margin: 2px 0 14px; }
.meals-act { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 12px 14px; border-radius: 13px; border: 1px solid rgba(35,60,65,0.12); background: #fff; cursor: pointer; font-family: inherit; font-size: 14px; font-weight: 650; color: var(--ink); }
.meals-act svg { width: 17px; height: 17px; }
.meals-act.primary { background: var(--accent-dark, #1f8a7e); border-color: var(--accent-dark, #1f8a7e); color: #fff; }
.meals-act:active { transform: scale(0.98); }
.plan-next-cta.next-ready { border-color: rgba(53,202,187,0.4); background: linear-gradient(180deg, #f3fcfb, #eafaf7); }
/* .meals-today-empty / .meals-empty* retired — meals empties now render the
   shared EmptyState primitive (.ui-empty, upgraded to this look). §9.3 item 6. */
.meal-edit-hint { margin: 0 0 12px; font-size: 12.5px; color: #b06f12; background: rgba(214,160,60,0.1); padding: 9px 12px; border-radius: 10px; }
.meal-dish-rowwrap { display: flex; align-items: stretch; gap: 6px; }
.meal-dish-rowwrap .meal-dish-row { flex: 1; }
.mdr-edit { flex: 0 0 auto; width: 40px; border: 1px solid rgba(35,60,65,0.1); border-radius: 11px; background: #fff; color: var(--accent-dark); cursor: pointer; display: grid; place-items: center; }
.mdr-edit:hover { background: #f4fbfa; }
/* Cooked toggle (M1) — a round check pip; when set, the dish row dims + strikes. */
.mdr-cooked { flex: 0 0 auto; align-self: center; width: 26px; height: 26px; border: 1.5px solid rgba(35,60,65,0.2); border-radius: 50%; background: #fff; color: #fff; font-size: 14px; font-weight: 800; line-height: 1; cursor: pointer; display: grid; place-items: center; transition: background 0.15s ease, border-color 0.15s ease; }
.mdr-cooked.is-cooked { background: var(--pos-ink, #2f7d4f); border-color: var(--pos-ink, #2f7d4f); }
.meal-dish-rowwrap.is-cooked .mdr-name { text-decoration: line-through; opacity: 0.6; }
.meal-dish-rowwrap.is-cooked .meal-dish-row { opacity: 0.85; }
.mdr-add { width: 100%; margin-top: 2px; padding: 9px; border: 1px dashed rgba(35,60,65,0.2); border-radius: 11px; background: transparent; color: var(--accent-dark); font-weight: 650; font-size: 13px; cursor: pointer; font-family: inherit; }
.mdr-add:hover { background: rgba(53,202,187,0.08); }
.dish-edit-sheet .task-field { margin-bottom: 12px; }
.dish-edit-sheet .de-input { width: 100%; padding: 11px 12px; border: 1px solid rgba(35,60,65,0.16); border-radius: 11px; font-size: 15px; font-family: inherit; }
.dish-edit-actions { display: flex; gap: 10px; margin-top: 6px; }
.dish-edit-actions .mp-generate { flex: 1; }
.de-delete { padding: 12px 16px; border: 1px solid rgba(193,64,58,0.3); border-radius: 12px; background: rgba(193,64,58,0.06); color: #b4402f; font-weight: 650; cursor: pointer; font-family: inherit; }
.de-delete:hover { background: rgba(193,64,58,0.12); }
/* Dish Editor §2 — two-tab sheet (Choose existing / Write my own). */
.dish-edit-sheet .sheet-title-row { align-items: flex-start; }
.de-subtitle { margin: 2px 0 0; font-size: 12px; color: var(--muted, #67797f); }
.de-seg { display: inline-flex; background: rgba(35,60,65,0.06); border-radius: 999px; padding: 3px; gap: 2px; margin: 12px 0 4px; }
.de-seg-btn { padding: 7px 16px; border: 0; border-radius: 999px; font-size: 12.5px; font-weight: 700; color: var(--muted, #67797f); background: none; cursor: pointer; font-family: inherit; }
.de-seg-btn.on { background: #fff; color: var(--accent-dark, #0f7d73); box-shadow: 0 1px 3px rgba(20,48,54,0.12); }
.de-seg-btn:disabled { opacity: 0.4; cursor: default; }
.de-tabbody { margin-top: 10px; }
.de-search { display: flex; align-items: center; gap: 8px; border: 1px solid rgba(35,60,65,0.16); border-radius: 12px; background: #fff; padding: 9px 12px; margin: 4px 0 10px; }
.de-search-in { flex: 1; min-width: 0; border: 0; outline: 0; font-size: 14px; font-family: inherit; background: none; color: var(--ink, #26393f); }
.de-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.de-chip { padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(35,60,65,0.16); background: #fff; font-size: 12px; font-weight: 650; color: var(--body, #36474d); cursor: pointer; font-family: inherit; }
.de-chip.on { background: var(--accent-dark, #0f7d73); border-color: var(--accent-dark, #0f7d73); color: #fff; }
.de-results { max-height: 46vh; overflow-y: auto; margin-bottom: 10px; }
/* Search tab: fixed height so the sheet doesn't jitter as results change while typing;
   only the results scroll, keeping the search field pinned above the keyboard. `dvh`
   shrinks with the on-screen keyboard so the sheet never extends behind it. */
.dish-edit-sheet.de-tab-pick { height: 82dvh; max-height: 82dvh; }
.dish-edit-sheet.de-tab-pick .de-tabbody { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.dish-edit-sheet.de-tab-pick .de-search,
.dish-edit-sheet.de-tab-pick .de-chips { flex: 0 0 auto; }
.dish-edit-sheet.de-tab-pick .de-results { flex: 1 1 auto; min-height: 0; max-height: none; }
.dish-edit-sheet.de-tab-pick [data-de-use-go],
.dish-edit-sheet.de-tab-pick .de-note { flex: 0 0 auto; }
.de-res { display: flex; gap: 10px; align-items: center; width: 100%; text-align: left; padding: 10px 12px; border: 1px solid rgba(35,60,65,0.1); border-radius: 13px; background: #fff; margin-bottom: 8px; cursor: pointer; font-family: inherit; }
.de-res.on { border: 1.5px solid var(--accent-dark, #0f7d73); box-shadow: 0 0 0 3px rgba(53,202,187,0.14); }
.de-res-ic { width: 36px; height: 36px; border-radius: 11px; background: rgba(53,202,187,0.12); display: grid; place-items: center; font-size: 15px; flex: none; }
.de-res-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.de-res-name { font-size: 13px; font-weight: 650; color: var(--ink, #26393f); }
.de-res-sub { font-size: 11px; color: var(--muted, #67797f); }

.supplies-page .homeos-shell {
  min-height: calc(100dvh - 116px);
  display: flex;
  flex-direction: column;
}
.supplies-page .supplies-qc {
  margin-top: auto;
  padding-top: clamp(42px, 8dvh, 72px);
}
.supplies-page .supplies-qc .qc-card {
  margin-top: 0;
}

/* Shared HomeOS row-title contract: tasks, dishes, supplies and vendors should
   read as the same class of item everywhere. */
.chore-body strong,
.cadence-list .chore-card .chore-body strong,
.recurring-page .cadence-list .chore-card .chore-body strong,
.mt-dish-name,
.mdr-name,
.row-main strong,
.os-list-card strong,
.rec-body p,
.rec-lib-name,
.de-res-name {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: 0;
  color: var(--ink);
}
.de-empty { font-size: 12.5px; color: var(--muted, #67797f); text-align: center; padding: 18px 8px; }
.de-note { font-size: 11px; color: var(--muted, #67797f); line-height: 1.45; margin: 9px 0 0; }
.dish-edit-sheet .vnv { width: 20px; height: 20px; border-radius: 50%; background: #d6f1ea; color: #1d6b5c; font-size: 9px; font-weight: 800; display: grid; place-items: center; flex: none; }
.dish-edit-sheet .vnv.nv { background: #fcdacf; color: #8a3a20; }
.dish-edit-sheet [data-de-use-go]:disabled { opacity: 0.5; cursor: default; }

/* ============================================================
   Xortit home — "midnight liquid" hub (owner Xortit-Home-Handoff 2026-07-17).
   The ONLY dark page (a hub, not a module); module pages stay light + tinted.
   Light text here is intentional (dark surface) — not the ink ramp.
   ============================================================ */
/* Xortit PARENT surface — the shared "midnight liquid" dark glass (H6, handoff
   Xortit-Home §2 / `Xortit Home Final.html` .frame). Painted on the BODY so it
   FULL-BLEEDS the viewport edge-to-edge (the reference frame's bg covers the whole
   390×844; content is inset by the wrappers' own padding). ONE recipe for every
   Xortit-level surface (Home hub · What's-up/recital · Calendar · Say it · Decisions);
   `.xortit-shell` carries the matching #54e0c8 accent (tokens.css). This is the zone
   the theme-consistency guard enforces. Module routes (os-fullpage) and the public
   marketing home keep their own backgrounds. */
body.xortit-canvas {
  /* !important + higher specificity to beat the app's default `body` backdrop
     (styles.css ~L3970, itself !important). */
  background:
    radial-gradient(700px 420px at 85% -6%, rgba(64,224,199,.32), transparent 55%),
    radial-gradient(600px 500px at -10% 30%, rgba(120,110,255,.24), transparent 55%),
    linear-gradient(160deg, #0b1f24, #122e33 55%, #0d2226) !important;
  color: rgba(255,255,255,.92);
}
body.xortit-canvas .app-shell {
  max-width: none;
  padding: 0;
}
.xh-home {
  width: min(100%, 560px);
  min-height: 100dvh;
  margin: 0 auto;
  padding: max(18px, env(safe-area-inset-top)) 18px calc(98px + env(safe-area-inset-bottom));
}
.recital-page { min-height: 100vh; padding: 6px 16px 104px; }

/* osBreadcrumb on the Xortit dark canvas — the app bar is styled for LIGHT module
   pages by default (white buttons, ink title); on the midnight-liquid it needs light
   glass buttons + a light title (reference `.rndbtn`: translucent white, blur,
   #dcefee). Scoped to the canvas so light module pages are unaffected. */
body.xortit-canvas .os-crumb-current { color: rgba(255, 255, 255, 0.92); }
body.xortit-canvas .os-head-btn {
  background: rgba(255, 255, 255, 0.10);
  border-color: rgba(255, 255, 255, 0.20);
  color: #dcefee;
  box-shadow: none;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
body.xortit-canvas .os-menu-btn { color: #dcefee; }
.xh-greet { margin: 8px 2px 16px; }
.xh-date { margin: 0 0 7px; font-size: 12.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #54e0c8; }
.xh-greeting { margin: 0; font-size: 26px; font-weight: 700; letter-spacing: 0; color: rgba(255,255,255,.96); }

.xh-glass {
  border-radius: 20px; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,.2);
  background: linear-gradient(150deg, rgba(255,255,255,.13), rgba(255,255,255,.05));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.22);
}

.xh-orb-wrap { display: grid; justify-items: center; gap: 8px; width: 100%; border: 0; background: none; cursor: pointer; margin: 2px 0 16px; }
.xh-orb {
  width: 132px; height: 132px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  background: radial-gradient(circle at 38% 30%, rgba(255,255,255,.4), rgba(84,224,200,.16) 45%, rgba(10,40,42,.5) 78%);
  border: 1px solid rgba(255,255,255,.28);
  box-shadow: 0 0 60px rgba(84,224,200,.15), inset 0 2px 12px rgba(255,255,255,.2);
  color: #dffdf6;
}
.xh-orb svg { width: 40px; height: 40px; }
/* label lives INSIDE the orb, under the waveform (handoff §3.1 / reference .orb b) */
.xh-orb-label { font-size: 12.5px; font-weight: 600; color: #f2fbfa; }

.xh-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.xh-span2 { grid-column: 1 / -1; }
.xh-tile { display: flex; align-items: center; gap: 13px; padding: 14px 16px; text-align: left; cursor: pointer; color: rgba(255,255,255,.92); font-family: inherit; }
.xh-tile-ico { width: 42px; height: 42px; flex: 0 0 auto; border-radius: 13px; display: grid; place-items: center; background: rgba(84,224,200,.16); color: #7fe9d6; }
.xh-tile-ico svg { width: 18px; height: 18px; }
.xh-tile-body { flex: 1; min-width: 0; display: grid; gap: 3px; }
.xh-tile-body strong { font-size: 15px; font-weight: 600; color: rgba(255,255,255,.95); line-height: 1.25; }
.xh-tile-body em { font-size: 12px; font-style: normal; color: rgba(255,255,255,.66); line-height: 1.3; }
.xh-chev { flex: 0 0 auto; color: rgba(255,255,255,.5); font-size: 20px; }
/* half-tile (Sort / Needs) column layout — separate from the colour tints so a tint
   can also be used on a full-width bar (e.g. BrainDump amber). */
.xh-half { flex-direction: column; align-items: flex-start; gap: 9px; min-height: 92px; }
.xh-tile--amber { background: linear-gradient(160deg, rgba(240,207,138,.14), rgba(240,207,138,.03)); border-color: rgba(240,207,138,.3); }
.xh-tile--amber .xh-tile-ico { background: rgba(240,207,138,.16); color: #f0cf8a; }
.xh-tile--rose { background: linear-gradient(160deg, rgba(244,170,195,.14), rgba(244,170,195,.03)); border-color: rgba(244,170,195,.3); }
.xh-tile--rose .xh-tile-ico { background: rgba(244,170,195,.16); color: #f4aac3; }
.xh-tile--violet { background: linear-gradient(160deg, rgba(120,110,255,.16), rgba(120,110,255,.04)); border-color: rgba(120,110,255,.32); }
.xh-tile--violet .xh-tile-ico { background: rgba(120,110,255,.2); color: #b2a8ff; }
/* Meals = HomeOS teal hue (owner: each section takes its module's colour) */
.xh-tile--teal { background: linear-gradient(160deg, rgba(84,224,200,.14), rgba(84,224,200,.03)); border-color: rgba(84,224,200,.3); }
.xh-tile--teal .xh-tile-ico { background: rgba(84,224,200,.18); color: #7fe9d6; }
.xh-cal { flex-direction: column; align-items: stretch; gap: 10px; }
.xh-tile-head { display: flex; align-items: center; justify-content: space-between; }
.xh-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .12em; color: rgba(255,255,255,.55); }
.xh-link { font-size: 12.5px; font-weight: 600; color: #54e0c8; }
.xh-cal-empty { margin: 0; font-size: 13px; color: rgba(255,255,255,.55); }
.xh-cal-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.xh-cal-ev { display: grid; gap: 3px; padding: 9px 10px; border-radius: 12px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); }
.xh-cal-ev.xh-next { border-color: rgba(178,188,255,.4); background: rgba(178,188,255,.1); }
.xh-cal-tag { font-size: 9px; font-weight: 700; letter-spacing: .1em; color: #b2bcff; }
.xh-cal-time { font-size: 12px; font-weight: 700; color: rgba(255,255,255,.92); }
.xh-cal-title { font-size: 11.5px; color: rgba(255,255,255,.7); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ============================================================
   What's-up recital (H5, owner Xortit-Home-Handoff §3.1): pulsating 5-bar
   waveform while speaking + word-by-word streamed text. On the dark briefing page.
   ============================================================ */
.wave-orb { display: inline-grid; place-items: center; width: 92px; height: 92px; margin: 6px auto 14px; border-radius: 50%; background: rgba(84,224,200,0.12); border: 1px solid rgba(84,224,200,0.28); color: var(--mint); box-shadow: 0 0 44px rgba(84,224,200,0.14); }
.wave-orb .wf { width: 42px; height: 34px; }
.wf-bar { fill: currentColor; transform-box: fill-box; transform-origin: center; }
.wave-orb.speaking .wf-bar { animation: wf 0.9s ease-in-out infinite; }
.wave-orb.speaking .wf-bar:nth-child(1) { animation-delay: 0s; }
.wave-orb.speaking .wf-bar:nth-child(2) { animation-delay: .1s; }
.wave-orb.speaking .wf-bar:nth-child(3) { animation-delay: .2s; }
.wave-orb.speaking .wf-bar:nth-child(4) { animation-delay: .3s; }
.wave-orb.speaking .wf-bar:nth-child(5) { animation-delay: .4s; }
@keyframes wf { 0%, 100% { transform: scaleY(0.42); } 50% { transform: scaleY(1.65); } }
@media (prefers-reduced-motion: reduce) { .wave-orb.speaking .wf-bar { animation: none; } }
.placeholder-card .recital-stream { min-height: 46px; margin: 6px 0 14px; font-size: 16px; line-height: 1.5; font-weight: 500; color: var(--night-ink); }
.recital-stream:empty::before { content: "Tap play — Xortit recites your day."; color: var(--text-soft); font-weight: 400; font-size: 13.5px; }
.placeholder-card .recital-status { margin: 7px auto 4px; font-size: 12.5px; font-weight: 650; color: rgba(84,224,200,.9); }
.placeholder-card .recital-voice { margin: 10px 0 0; font-size: 11.5px; font-weight: 650; color: var(--text-soft); }
.recital-word { color: rgba(234,246,244,.38); transition: color .14s ease; }
.recital-word.spoken { color: var(--night-ink); }
.recital-controls { display: flex; gap: 10px; align-items: center; justify-content: center; flex-wrap: wrap; }
.recital-skip { background: var(--night-glass-strong); border: 1px solid var(--night-border); color: var(--night-ink2); border-radius: 999px; padding: 10px 16px; font-weight: 600; cursor: pointer; font-family: inherit; font-size: 13px; }
.see-all-link { margin: 16px auto 0; display: block; border: 0; background: none; color: var(--mint); font-family: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.recital-transcript { list-style: none; display: grid; gap: 6px; max-height: 112px; margin: 14px 0; padding: 0 4px 0 0; overflow-y: auto; overscroll-behavior: contain; }
.recital-transcript::-webkit-scrollbar { width: 4px; }
.recital-transcript::-webkit-scrollbar-thumb { background: rgba(84,224,200,.28); border-radius: 999px; }
.recital-transcript li,
.recital-transcript li + li { margin-top: 0; }
.recital-transcript li { position: relative; padding: 3px 0 3px 26px; color: rgba(234,246,244,.58); }
.recital-transcript li::before { content: ""; position: absolute; left: 6px; top: 12px; width: 7px; height: 7px; border-radius: 999px; background: rgba(255,255,255,.22); box-shadow: 0 0 0 4px rgba(255,255,255,.03); }
.recital-transcript li[data-state="current"] { color: var(--night-ink); font-weight: 650; }
.recital-transcript li[data-state="current"]::before { background: #54e0c8; box-shadow: 0 0 0 5px rgba(84,224,200,.14); }
.recital-transcript li[data-state="done"] { color: rgba(234,246,244,.76); }
.recital-transcript li[data-state="done"]::before { background: rgba(84,224,200,.7); }

/* ============================================================
   What's Up — live board cards (docs/frontend-handoff/WHATSUP-INTEGRATION.md).
   The recital briefing above reads the day back; these are the actionable
   triage cards beneath it. Dark glass on the midnight-liquid shell, mint accent.
   ============================================================ */
.wu-board { display: flex; flex-direction: column; gap: 12px; margin-top: 18px; transition: opacity .18s ease; }
.wu-board.wu-busy { opacity: .5; pointer-events: none; }
.wu-card { position: relative; border-radius: 18px; padding: 14px 15px 13px; background: var(--night-glass, rgba(255,255,255,0.05)); border: 1px solid var(--night-border, rgba(255,255,255,0.10)); box-shadow: 0 12px 30px -18px rgba(0,0,0,0.7); overflow: hidden; }
/* Left accent bar carries the quadrant urgency read. */
.wu-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: rgba(84,224,200,0.5); }
.wu-card.wu-q1::before { background: #ff8a80; }
.wu-card.wu-q2::before { background: #54e0c8; }
.wu-card.wu-q3::before { background: #ffcf7a; }
.wu-card.wu-q4::before { background: rgba(255,255,255,0.22); }
.wu-card-head { display: flex; align-items: center; gap: 8px; margin-bottom: 7px; }
.wu-dom { font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: #54e0c8; }
.wu-quad { font-size: 10.5px; font-weight: 700; color: var(--night-ink2, rgba(255,255,255,0.72)); background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.10); border-radius: 999px; padding: 2px 9px; }
.wu-when { margin-left: auto; font-size: 11.5px; font-weight: 700; color: var(--night-ink2, rgba(255,255,255,0.7)); }
.wu-when.wu-soon { color: #ffcf7a; }
.wu-when.wu-overdue { color: #ff8a80; }
.wu-sentence { margin: 0 0 4px; font-size: 15px; line-height: 1.45; font-weight: 550; color: var(--night-ink, #eaf6f4); }
.wu-deleg { margin: 4px 0 0; font-size: 12px; font-weight: 600; color: var(--night-ink2, rgba(255,255,255,0.66)); }
.wu-deleg.at-risk { color: #ff8a80; }
.wu-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 11px; }
.wu-act { flex: 1 1 auto; min-width: 68px; border-radius: 999px; padding: 8px 12px; font-family: inherit; font-size: 12.5px; font-weight: 650; cursor: pointer; background: var(--night-glass-strong, rgba(255,255,255,0.08)); border: 1px solid var(--night-border, rgba(255,255,255,0.12)); color: var(--night-ink, #eaf6f4); }
.wu-act.wu-done { background: rgba(84,224,200,0.16); border-color: rgba(84,224,200,0.4); color: #7ff0dd; }
.wu-act.wu-dismiss { color: var(--night-ink2, rgba(255,255,255,0.6)); }
.wu-act:active { transform: translateY(1px); }
.wu-nudge { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed rgba(255,255,255,0.12); font-size: 12px; font-weight: 600; color: var(--night-ink2, rgba(255,255,255,0.68)); }
.wu-nudge-btn { border-radius: 999px; padding: 6px 12px; font-family: inherit; font-size: 12px; font-weight: 650; cursor: pointer; background: rgba(255,207,122,0.14); border: 1px solid rgba(255,207,122,0.4); color: #ffcf7a; }
.wu-empty h2, .wu-skeleton h2 { margin: 4px 0 8px; }
.wu-empty-sub { font-size: 13.5px; line-height: 1.5; color: var(--text-soft, rgba(255,255,255,0.6)); max-width: 34ch; margin: 0 auto; }
.wu-skel-line { height: 13px; border-radius: 7px; margin: 10px auto; max-width: 30ch; background: linear-gradient(90deg, rgba(255,255,255,0.06), rgba(255,255,255,0.13), rgba(255,255,255,0.06)); background-size: 200% 100%; animation: wu-shimmer 1.3s ease-in-out infinite; }
.wu-skel-line.short { max-width: 20ch; }
@keyframes wu-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .wu-skel-line { animation: none; } }
.wu-preview-note { margin: 14px auto 0; max-width: 40ch; text-align: center; font-size: 12px; font-weight: 500; color: var(--text-soft, rgba(255,255,255,0.55)); }

/* ============================================================
   Meal import REVIEW SHEET (M3, src/xortit/meal-review.js) — a calm HomeOS
   operational surface: teal accent, grey ink ramp, dense but scannable. §14.
   ============================================================ */
.meal-review { display: flex; flex-direction: column; gap: 12px; padding-bottom: 76px; }
.mrv-head { display: grid; gap: 3px; }
.mrv-title { margin: 0; font-size: 18px; font-weight: 650; color: var(--ink-1); }
.mrv-src { margin: 0; font-size: 12.5px; color: var(--ink-3); }
.mrv-src b { color: var(--ink-2); font-weight: 650; }
.mrv-counts { margin: 0; font-size: 12px; color: var(--ink-3); }
.mrv-warnbar { font-size: 12.5px; font-weight: 600; color: var(--ink-2); background: rgba(35,60,65,0.05); border: 1px solid rgba(35,60,65,0.10); border-radius: 12px; padding: 9px 12px; }
.mrv-warnbar b { color: var(--neg-ink); }
.mrv-days { display: flex; flex-direction: column; gap: 10px; }
.mrv-day { border: 1px solid rgba(35,60,65,0.12); border-radius: 14px; background: #fff; overflow: hidden; }
.mrv-day-head { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px; padding: 12px 14px; font-weight: 650; }
.mrv-day-head::-webkit-details-marker { display: none; }
.mrv-day-name { color: var(--ink-3); font-size: 14px; }
.mrv-day-date { color: var(--ink-3); font-size: 11.5px; font-weight: 500; }
.mrv-day-warns { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--neg-ink); background: var(--neg-soft); padding: 3px 9px; border-radius: 999px; }
.mrv-day-ok { margin-left: auto; font-size: 11px; font-weight: 600; color: var(--ink-4); }
.mrv-day-body { padding: 0 12px 12px; display: flex; flex-direction: column; gap: 12px; }
.mrv-meal { display: flex; flex-direction: column; gap: 7px; }
.mrv-meal-head { display: flex; align-items: baseline; justify-content: space-between; }
.mrv-meal-name { font-size: 12px; font-weight: 700; letter-spacing: 0.03em; text-transform: uppercase; color: var(--ink-3); }
.mrv-meal-sum { font-size: 11px; color: var(--ink-3); }
.mrv-meal-empty { margin: 0; font-size: 12px; color: var(--ink-4); }
.mrv-dish { display: grid; grid-template-columns: 1fr auto 56px auto; align-items: center; gap: 6px; }
.mrv-dish--block .mrv-name { border-color: var(--neg-border); }
.mrv-name, .mrv-kcal, .mrv-type { font-family: inherit; font-size: 13px; border: 1px solid rgba(35,60,65,0.14); border-radius: 9px; padding: 8px 9px; background: #fbfdfd; color: var(--ink-1); min-width: 0; }
.mrv-name:focus, .mrv-kcal:focus, .mrv-type:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.mrv-type { padding: 8px 6px; }
.mrv-pill { grid-column: 1 / -1; justify-self: start; font-size: 10.5px; font-weight: 700; color: var(--ink-3); background: rgba(35,60,65,0.06); padding: 2px 8px; border-radius: 999px; }
.mrv-pill--block { color: var(--neg-ink); background: var(--neg-soft); }
.mrv-x { border: 0; background: rgba(35,60,65,0.06); color: var(--ink-3); width: 30px; height: 30px; border-radius: 50%; font-size: 17px; line-height: 1; cursor: pointer; }
.mrv-dish--reroll { grid-template-columns: 1fr auto 56px auto auto; }
.mrv-reroll { border: 0; background: var(--accent-ring); color: var(--accent-dark); width: 30px; height: 30px; border-radius: 50%; font-size: 15px; line-height: 1; cursor: pointer; transition: transform 0.2s ease; }
.mrv-reroll:hover { background: var(--accent-soft, var(--accent-ring)); }
.mrv-reroll--busy { opacity: 0.55; cursor: progress; animation: mrv-reroll-spin 0.7s linear infinite; }
@keyframes mrv-reroll-spin { to { transform: rotate(360deg); } }
.mrv-add { align-self: flex-start; border: 1px dashed rgba(35,60,65,0.2); background: none; color: var(--accent-dark); font-family: inherit; font-size: 12px; font-weight: 650; padding: 6px 11px; border-radius: 9px; cursor: pointer; }
.mrv-foot { position: sticky; bottom: 0; display: flex; gap: 10px; padding: 12px 0 10px; background: linear-gradient(180deg, rgba(255,255,255,0), #fff 30%); }
.mrv-discard { flex: 0 0 auto; border: 1px solid var(--neg-border); background: var(--neg-soft); color: var(--neg-ink); font-family: inherit; font-weight: 650; font-size: 13.5px; padding: 12px 16px; border-radius: 13px; cursor: pointer; }
.mrv-accept { flex: 1; border: 0; background: var(--accent-dark); color: #fff; font-family: inherit; font-weight: 700; font-size: 13.5px; padding: 12px 16px; border-radius: 13px; cursor: pointer; }
.mrv-accept[disabled] { background: rgba(35,60,65,0.18); color: rgba(255,255,255,0.85); cursor: not-allowed; }
.mrv-empty { text-align: center; padding: 28px 16px; display: grid; gap: 5px; }
.mrv-empty strong { color: var(--ink-1); font-size: 14px; }
.mrv-empty em { color: var(--ink-3); font-size: 12.5px; font-style: normal; }
.meal-review-sheet { max-height: 90vh; overflow-y: auto; padding: 6px 18px 16px; }

/* Recipe review (M3r, meal-review.js §7) — same calm HomeOS surface as the plan review. */
.recipe-review .rrv-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rrv-f { display: grid; gap: 3px; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--ink-3); }
.rrv-f-wide { grid-column: 1 / -1; }
.rrv-f input, .rrv-f select, .rrv-f textarea { font-family: inherit; font-size: 13px; font-weight: 400; text-transform: none; letter-spacing: 0; border: 1px solid rgba(35,60,65,0.14); border-radius: 9px; padding: 8px 9px; background: #fbfdfd; color: var(--ink-1); }
.rrv-f input:focus, .rrv-f select:focus, .rrv-f textarea:focus, .rrv-ing input:focus, .rrv-step-fields input:focus, .rrv-step-text:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.rrv-sec { display: flex; flex-direction: column; gap: 7px; margin-top: 14px; }
.rrv-sec-head { display: flex; align-items: baseline; justify-content: space-between; }
.rrv-ing { display: grid; grid-template-columns: minmax(78px, .8fr) minmax(110px, 1.2fr) 54px 54px auto; gap: 6px; align-items: center; }
.rrv-ing input { font-family: inherit; font-size: 13px; border: 1px solid rgba(35,60,65,0.14); border-radius: 9px; padding: 8px 9px; background: #fbfdfd; color: var(--ink-1); min-width: 0; }
.rrv-step { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: start; }
.rrv-step-n { width: 22px; height: 22px; margin-top: 6px; display: grid; place-items: center; font-size: 11px; font-weight: 700; color: var(--accent-dark); background: var(--accent-soft); border-radius: 50%; }
.rrv-step-fields { display: grid; grid-template-columns: minmax(86px, .42fr) minmax(130px, 1fr) 58px; gap: 6px; min-width: 0; }
.rrv-step-fields input { font-family: inherit; font-size: 13px; border: 1px solid rgba(35,60,65,0.14); border-radius: 9px; padding: 8px 9px; background: #fbfdfd; color: var(--ink-1); min-width: 0; }
.rrv-step-text { font-family: inherit; font-size: 13px; line-height: 1.4; border: 1px solid rgba(35,60,65,0.14); border-radius: 9px; padding: 8px 9px; background: #fbfdfd; color: var(--ink-1); resize: vertical; min-height: 34px; }
.rrv-step-ctrls { display: flex; flex-direction: column; gap: 3px; }
.rrv-notes { margin-top: 14px; }
.rrv-notes textarea { min-height: 86px; resize: vertical; }
.rrv-match { margin-top: 14px; }
.rrv-match-note { font-size: 12px; color: var(--ink-3); margin: 0; }
.rrv-match-card { width: 100%; text-align: left; display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1px solid var(--accent-ring); background: var(--accent-soft); border-radius: 12px; padding: 10px 12px; cursor: pointer; font-family: inherit; }
.rrv-match-card.on { border-color: var(--accent-dark); }
.rrv-match-eyebrow { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--ink-3); }
.rrv-match-name { display: block; font-size: 13px; font-weight: 600; color: var(--ink-1); margin-top: 2px; }
.rrv-match-check { flex: 0 0 auto; font-size: 12px; font-weight: 700; color: var(--accent-dark); }
.rrv-savelink { background: var(--accent); }
@media (max-width: 520px) {
  .rrv-ing { grid-template-columns: 1fr 64px 64px auto; }
  .rrv-ing-group { grid-column: 1 / -1; }
  .rrv-step-fields { grid-template-columns: 1fr 62px; }
  .rrv-step-group { grid-column: 1 / -1; }
  .rrv-step-text { grid-column: 1 / 2; }
}

/* M7 re-plan / plan sheet — 3-door chooser (agent · import · paste). */
.replan-sheet { padding: 8px 18px 20px; }
.replan-doors { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.replan-doors[hidden], .replan-paste[hidden] { display: none; } /* [hidden] must beat display:flex */
.replan-door { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 1px solid rgba(35,60,65,0.12); background: #fff; border-radius: 14px; padding: 13px 14px; cursor: pointer; font-family: inherit; }
.replan-door:active { transform: scale(0.99); }
.rs-ico { width: 40px; height: 40px; flex: 0 0 auto; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-dark); }
.rs-txt { flex: 1; display: grid; gap: 2px; min-width: 0; }
.rs-txt strong { font-size: 14px; font-weight: 650; color: var(--ink-1); }
.rs-txt em { font-size: 12px; font-style: normal; color: var(--ink-3); }
.rs-chev { color: var(--ink-4); font-size: 20px; flex: 0 0 auto; }
.replan-paste { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.replan-textarea { font-family: inherit; font-size: 13.5px; line-height: 1.45; border: 1px solid rgba(35,60,65,0.14); border-radius: 12px; padding: 11px 12px; background: #fbfdfd; color: var(--ink-1); resize: vertical; min-height: 120px; }
.replan-textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.replan-paste-actions { display: flex; gap: 10px; }
.replan-paste-actions .mrv-accept { flex: 1; }

/* meals-4 grocery questionnaire (2-step: frequency + buy-days) */
.gp-step { font-size: 12px; font-weight: 700; color: var(--ink-2); margin: 14px 0 8px; }
.gp-freq { display: grid; gap: 8px; }
.gp-freq-chip { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; text-align: left; border: 1px solid rgba(35,60,65,0.16); background: #fbfdfd; border-radius: 12px; padding: 10px 13px; font-family: inherit; cursor: pointer; }
.gp-freq-chip strong { font-size: 13.5px; color: var(--ink-1); }
.gp-freq-chip em { font-style: normal; font-size: 11.5px; color: var(--ink-3); }
.gp-freq-chip.active { border-color: var(--accent-dark); background: var(--accent-ring); }
.gp-days { margin-top: 2px; }
.gp-note { font-size: 12px; color: var(--ink-3); margin: 8px 0 2px; }
.mp-bridge-btn.ghost { border-color: rgba(35,60,65,0.16); color: var(--ink-2); }
/* §2.2: required historical-week picker at the top of the previous-import sheet. */
.replan-week { display: flex; flex-direction: column; gap: 5px; margin: 6px 0 2px; }
.replan-week-label { font-size: 12px; font-weight: 700; color: var(--ink-2); }
.replan-week-input { font-family: inherit; font-size: 14px; border: 1px solid rgba(35,60,65,0.16); border-radius: 12px; padding: 10px 12px; background: #fbfdfd; color: var(--ink-1); }
.replan-week-input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.replan-week-hint { margin: 2px 0 8px; font-size: 11.5px; color: var(--ink-3); line-height: 1.35; }
/* §5: scanned-PDF OCR job status sheet (queued / running / done / error). */
.ocr-status-row { display: flex; align-items: center; gap: 12px; margin: 10px 0 16px; }
.ocr-status { margin: 0; font-size: 13.5px; color: var(--ink-1); line-height: 1.4; }
.ocr-spin { width: 20px; height: 20px; flex: 0 0 auto; border-radius: 50%; border: 2.5px solid rgba(53,202,187,0.25); border-top-color: var(--accent); animation: ocr-spin 800ms linear infinite; }
.ocr-x { width: 20px; height: 20px; flex: 0 0 auto; border-radius: 50%; display: grid; place-items: center; background: rgba(220,80,70,0.14); color: #c0392b; font-weight: 800; font-size: 13px; }
@keyframes ocr-spin { to { transform: rotate(360deg); } }

/* M8 — plan-next-week: 3 collapsed setup groups (Household · Shape · Notes & memory). */
.mp-group { border: 1px solid rgba(35,60,65,0.12); border-radius: 16px; background: #fff; overflow: hidden; margin-bottom: 10px; }
.mp-group[open] { box-shadow: 0 4px 14px -10px rgba(35,60,65,0.25); }
.mp-group-head { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px; padding: 14px 15px; }
.mp-group-head::-webkit-details-marker { display: none; }
.mp-group-title { font-size: 14px; font-weight: 650; color: var(--ink-3); flex: 0 0 auto; }
.mp-group-sum { flex: 1; min-width: 0; font-size: 12px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mp-group-chev { flex: 0 0 auto; color: var(--ink-4); font-size: 18px; transition: transform 160ms ease; }
.mp-group[open] .mp-group-chev { transform: rotate(90deg); }
.mp-group > .mp-card { border: 0; border-top: 1px solid rgba(35,60,65,0.08); border-radius: 0; margin: 0; }
