:root {
  --bg-1: #203539;
  --bg-2: #2c4a51;
  --bg-3: #3f5f63;
  --text-inverse: #f7fbfb;
  --text-soft: #c6d6d8;
  --ink: #26393f;
  --muted: #62757b;
  --line: rgba(255, 255, 255, 0.14);
  --glass: rgba(255, 255, 255, 0.12);
  --glass-strong: rgba(255, 255, 255, 0.18);
  --accent: #35cabb;
  --accent-dark: #117d74;
  /* Premium translucent folder surfaces. Soft gradient tints at low alpha
     so the dark backdrop reads through and the surface feels glassy. */
  --home:     linear-gradient(155deg, rgba(170, 222, 214, 0.22) 0%, rgba(58, 122, 118, 0.14) 100%);
  --personal: linear-gradient(155deg, rgba(186, 172, 232, 0.22) 0%, rgba(86,  80, 138, 0.14) 100%);
  --family:   linear-gradient(155deg, rgba(226, 180, 208, 0.22) 0%, rgba(132, 78,  112, 0.14) 100%);
  --brain:    linear-gradient(155deg, rgba(230, 198, 158, 0.22) 0%, rgba(130, 92,  56,  0.14) 100%);
  --folder-glass:     rgba(255, 255, 255, 0.06);
  --folder-edge:      rgba(255, 255, 255, 0.18);
  --folder-edge-soft: rgba(255, 255, 255, 0.10);
  --folder-shadow:    0 18px 42px rgba(6, 20, 24, 0.40), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  --homeos-bg: #effaff;
  --homeos-card: rgba(255, 255, 255, 0.76);
  --homeos-line: #d7eef5;
  --radius-xl: 30px;
  --radius-lg: 24px;
  --shadow: 0 18px 42px rgba(8, 27, 32, 0.28);
  --paper-shadow: 0 12px 28px rgba(8, 27, 32, 0.2);
  color-scheme: dark;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}

* {
  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;
}

.top-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
  margin-top: 18px;
}

.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;
}

.section-heading {
  margin: 42px 0 6px;
  font-size: 13.5px;
  font-weight: 550;
}

.section-note {
  margin: 0;
  color: var(--text-soft);
  font-size: 12px;
}

.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-tab-title {
  position: absolute;
  top: 16px;
  left: 42px;
  z-index: 1;
  margin: 0;
  font-size: 13.5px;
  font-weight: 750;
  color: var(--text-inverse);
  letter-spacing: 0.005em;
  opacity: 0.94;
  text-shadow: 0 1px 2px rgba(8, 24, 28, 0.35);
}

.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: #64777d;
  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: #26393f;
  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: #13988d;
  font-size: 36px;
  line-height: 1;
}

.homeos-kicker {
  display: block;
  color: #667b80;
  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: #667b80;
  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: #61757b;
  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: #26393f;
  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: #687c82;
  font-size: 11px;
  font-style: normal;
}
/* Approvals subtext matches the Vendors card sub (12.5px / #67797f). */
.homeos-notice em.homeos-notice-sub { font-size: 12.5px; color: #67797f; }

.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: #26393f;
  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: #60747a;
  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: #667b80;
  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: #117d74;
  font-weight: 700;
  font-size: 11px;
}

.dark-list {
  margin-top: 18px;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.14);
}

.dark-list li {
  border-color: rgba(255, 255, 255, 0.12);
}

.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);
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 22px 0 0;
  color: var(--text-inverse);
  text-decoration: none;
  font-size: 13px;
}

@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; }
.xortit-logo { margin: 0; font-size: clamp(52px, 16vw, 104px); line-height: 0.9; letter-spacing: -0.075em; font-weight: 780; color: #f4fbfb; text-shadow: 0 20px 55px rgba(0,0,0,.24); }
.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; }
.whatsapp-demo { margin-top: 18px; }
.demo-phone { position: relative; min-height: 212px; padding: 18px 16px 16px; border: 1px solid rgba(255,255,255,.22); border-radius: 32px; background: radial-gradient(circle at 20% 0%,rgba(180,253,244,.18),transparent 42%),linear-gradient(145deg,rgba(255,255,255,.17),rgba(255,255,255,.07)); box-shadow: var(--shadow); overflow: hidden; }
.demo-header { display: flex; align-items: center; gap: 9px; color: rgba(244,251,251,.92); font-size: 11px; margin-bottom: 16px; }
.demo-header span { width: 25px; height: 25px; border-radius: 50%; background: linear-gradient(135deg,#9ff2eb,#cfbfff); box-shadow: 0 0 0 6px rgba(255,255,255,.07); }
.demo-header strong { flex: 1; font-size: 12px; font-weight: 650; }
.demo-header em { color: rgba(223,235,236,.7); font-style: normal; }
.chat-bubble { width: fit-content; max-width: 82%; margin-top: 10px; padding: 10px 12px; border-radius: 18px; font-size: 11.5px; line-height: 1.35; opacity: 0; transform: translateY(10px) scale(.98); animation: bubble-in 620ms ease forwards; }
.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; }
.typing-dots { display: flex; gap: 4px; width: fit-content; margin-top: 12px; padding: 9px 11px; border-radius: 16px; background: rgba(255,255,255,.13); opacity: 0; animation: typing-show 6s ease infinite; }
.typing-dots i { width: 5px; height: 5px; border-radius: 50%; background: rgba(223,251,247,.86); animation: typing-dot 900ms ease-in-out infinite; }
.typing-dots i:nth-child(2) { animation-delay: 120ms; }
.typing-dots i:nth-child(3) { animation-delay: 240ms; }
.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 { margin-top: 28px; padding: 22px 16px 18px; border-radius: 30px; border: 1px solid var(--line); background: rgba(255,255,255,.12); box-shadow: var(--shadow); }
.event-calendar-card h2 { margin: 0; font-size: 22px; letter-spacing: -0.035em; }
.event-calendar-card p:not(.eyebrow) { margin: 8px 0 18px; color: var(--text-soft); font-size: 12px; line-height: 1.45; }
.day-calendar { display: grid; grid-template-columns: 48px minmax(0,1fr); min-height: 520px; border-radius: 24px; overflow: hidden; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.08); }
.time-col { display: grid; grid-template-rows: repeat(7,1fr); padding-top: 8px; color: rgba(223,235,236,.68); font-size: 10px; text-align: right; }
.time-col span { padding-right: 8px; }
.event-grid { position: relative; min-height: 520px; }
.hour-line { position: absolute; left: 0; right: 0; height: 1px; background: rgba(255,255,255,.11); }
.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 { position: absolute; top: var(--top); left: var(--left); width: var(--width); height: var(--height); padding: 10px; border: 1px solid rgba(255,255,255,.26); border-radius: 16px; text-align: left; color: #193c42; font-size: 11px; font-weight: 650; line-height: 1.2; box-shadow: 0 16px 28px rgba(0,0,0,.12); }
.event-block em { display: block; margin-top: 4px; font-size: 9px; font-style: normal; color: rgba(25,60,66,.68); }
.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-hero {
  min-height: 40dvh;
  display: grid;
  align-content: center;
  text-align: center;
  padding: 34px 0 18px;
}

.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);
}

.public-copy {
  max-width: 680px;
  margin: 18px auto 0;
  color: rgba(223, 235, 236, 0.84);
  font-size: 13px;
  line-height: 1.6;
}

.public-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 16px;
}

.public-feature {
  min-height: 112px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 28px;
  background: linear-gradient(135deg, rgba(255,255,255,0.18), rgba(255,255,255,0.07));
  box-shadow: var(--shadow);
}

.public-feature span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(223, 251, 247, 0.9);
  color: var(--accent-dark);
  margin-bottom: 12px;
}

.public-feature h2 {
  margin: 0;
  font-size: 17px;
  letter-spacing: -0.03em;
}

.public-feature p {
  margin: 8px 0 0;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.42;
}

.public-demo-grid {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.public-whatsapp {
  margin-top: 0;
}

.public-folder-preview {
  min-height: 220px;
  position: relative;
  border-radius: 32px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: var(--shadow);
}

.mini-folder {
  position: absolute;
  left: 18px;
  right: 18px;
  min-height: 92px;
  padding: 18px 20px;
  border-radius: 22px 22px 26px 26px;
  color: var(--ink);
  box-shadow: var(--paper-shadow);
  border: 1px solid rgba(255,255,255,.5);
}

.mini-folder::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 22px;
  width: 110px;
  height: 28px;
  border-radius: 15px 15px 6px 0;
  background: inherit;
  border: 1px solid rgba(255,255,255,.42);
  border-bottom: 0;
}

.mini-folder strong,
.mini-folder span {
  position: relative;
  display: block;
}

.mini-folder strong {
  margin-top: 20px;
  font-size: 15px;
}

.mini-folder span {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.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-logo {
  margin: 0;
  font-size: 30px;
  line-height: 1;
  letter-spacing: -0.045em;
  font-weight: 720;
  color: #f4fbfb;
}

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

.small-signout {
  margin: 14px auto 0;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255,255,255,.08);
  color: rgba(223,235,236,.78);
  font-size: 11px;
  cursor: pointer;
}

@media (min-width: 760px) {
  .public-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .public-demo-grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, .9fr);
    align-items: stretch;
  }
}


/* Public app-preview refinement */
.public-preview-topbar {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  gap: 12px;
  align-items: start;
  padding-top: 8px;
}

.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;
}

.public-preview-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 26px;
}

.preview-action {
  min-height: 108px;
  padding: 18px 16px 20px;
}

.public-preview-folders {
  margin-top: 14px;
}

.compact-public-stack {
  height: 332px;
  margin-top: 0;
}

.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;
}

.retained-preview-grid {
  margin-top: 14px;
}

.public-mini-calendar {
  padding: 16px;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,.16);
  background: linear-gradient(145deg, rgba(255,255,255,.16), rgba(255,255,255,.07));
  box-shadow: var(--shadow);
}

.mini-calendar-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: rgba(244,251,251,.92);
  margin-bottom: 12px;
}

.mini-calendar-head span {
  font-size: 16px;
  font-weight: 650;
}

.mini-calendar-head strong {
  color: rgba(223,235,236,.72);
  font-size: 11px;
  font-weight: 550;
}

.mini-calendar-row {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 10px;
  min-height: 50px;
  border-top: 1px solid rgba(255,255,255,.11);
  padding: 10px 0;
}

.mini-calendar-row time {
  color: rgba(223,235,236,.64);
  font-size: 11px;
}

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

.event-soft {
  margin: 0;
  padding: 9px 10px;
  border-radius: 14px;
  color: #173b3f;
  font-size: 10.5px;
  font-weight: 650;
  line-height: 1.2;
}

.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-stage {
  margin-top: 14px;
  min-height: 190px;
}

.public-demo-panel {
  display: none;
}

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

.spoken-briefing,
.approval-demo {
  padding: 18px;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,.16);
  background: linear-gradient(145deg, rgba(255,255,255,.17), rgba(255,255,255,.07));
  box-shadow: var(--shadow);
}

.spoken-briefing {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 14px;
  align-items: start;
}

.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;
}

.demo-kicker {
  margin: 0 0 10px;
  color: rgba(223,235,236,.7);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.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; }

.approval-demo h3 {
  margin: 0 0 8px;
  font-size: 17px;
  letter-spacing: -0.03em;
}

.approval-demo p:not(.demo-kicker) {
  margin: 0;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.45;
}

.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 {
  height: 355px;
  margin-top: 6px;
  perspective: 900px;
}

.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;
}

.retained-whatsapp {
  margin-top: 14px;
}

.public-calendar-route {
  margin-bottom: 92px;
}

@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-folder-stack {
  height: 390px;
  margin-top: 18px;
  perspective: 1000px;
}

.public-folder-stack .folder {
  left: 0;
  right: 0;
  min-height: 144px;
  border-radius: 22px 22px 26px 26px;
  overflow: hidden;
  transform-origin: center top;
}

.public-folder-stack .folder::before {
  left: 18px;
  width: 150px;
  height: 44px;
  border-radius: 18px 18px 8px 0;
}

.public-folder-stack .folder.slot-3 {
  top: 0;
  transform: translateX(26px) scale(0.94);
  z-index: 1;
}

.public-folder-stack .folder.slot-2 {
  top: 52px;
  transform: translateX(18px) scale(0.96);
  z-index: 2;
}

.public-folder-stack .folder.slot-1 {
  top: 104px;
  transform: translateX(9px) scale(0.98);
  z-index: 3;
}

.public-folder-stack .folder.slot-0 {
  top: 166px;
  min-height: 214px;
  transform: none;
  z-index: 5;
}

.public-folder-stack .folder-inner {
  padding: 62px 24px 20px;
}

.public-folder-stack .folder:not(.slot-0) .folder-inner {
  padding-top: 58px;
}

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

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

.retained-whatsapp,
.public-demo-stage {
  display: none !important;
}

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

.public-preview-actions .preview-action {
  cursor: pointer;
}


/* 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;
}

.public-preview-actions {
  margin-top: 22px;
}

.public-folder-stack {
  height: 308px;
  margin-top: 14px;
}

.public-folder-stack .folder {
  min-height: 104px;
  border-radius: 18px 18px 24px 24px;
  overflow: visible;
}

.public-folder-stack .folder::before {
  z-index: 1;
  top: -18px;
  left: 18px;
  width: 136px;
  height: 40px;
  border-radius: 16px 16px 8px 0;
  box-shadow: 0 -1px 0 rgba(255,255,255,.34) inset;
}

.public-folder-stack .folder-inner {
  position: relative;
  z-index: 2;
  padding: 42px 20px 16px;
}

.public-folder-stack .folder-tab-title {
  z-index: 4;
  top: -8px;
  left: 34px;
  max-width: 112px;
  color: var(--ink);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.public-folder-stack .folder.slot-3 {
  top: 18px;
  transform: translateX(24px) scale(.93);
}

.public-folder-stack .folder.slot-2 {
  top: 58px;
  transform: translateX(16px) scale(.955);
}

.public-folder-stack .folder.slot-1 {
  top: 98px;
  transform: translateX(8px) scale(.98);
}

.public-folder-stack .folder.slot-0 {
  top: 140px;
  min-height: 158px;
}

.public-folder-stack .folder-title {
  font-size: 14px;
}

.public-folder-stack .folder-line {
  margin-top: 7px;
  font-size: 10.5px;
}

.public-folder-stack .folder-meta {
  margin-top: 10px;
  font-size: 9.5px;
}

.public-folder-stack .folder:not(.slot-0) .folder-inner {
  padding: 34px 20px 10px;
}

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

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


/* Phone polish pass: liquid public preview */
.public-preview-topbar {
  grid-template-columns: 50px 1fr 50px;
  align-items: center;
  padding-top: 28px;
}

.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;
}

.public-preview-actions {
  margin-top: 46px;
}

.public-preview-actions .preview-action {
  min-height: 108px;
}

.public-preview-folders {
  margin-top: 26px;
}

.public-folder-stack {
  width: min(92vw, 382px);
  height: 304px;
  margin: 0 auto;
  perspective: 900px;
}

.public-folder-stack .folder {
  left: 18px;
  right: 18px;
  min-height: 92px;
  border-radius: 20px 20px 24px 24px;
  transition: transform 420ms cubic-bezier(.16,1,.3,1), box-shadow 300ms ease, filter 300ms ease;
  will-change: transform;
}

.public-folder-stack .folder:hover,
.public-folder-stack .folder:focus-visible {
  transform: translateY(-8px) scale(1.012) !important;
  filter: saturate(1.04) brightness(1.02);
}

.public-folder-stack .folder.dragging {
  opacity: .86;
  transform: translateY(-14px) scale(1.02) rotate(.8deg) !important;
  box-shadow: 0 26px 48px rgba(8,27,32,.28);
}

.public-folder-stack .folder.drag-over {
  transform: translateY(-5px) scale(1.01) !important;
}

.public-folder-stack .folder::before {
  top: -19px;
  left: 22px;
  width: 128px;
  height: 42px;
  border-radius: 17px 17px 8px 0;
}

.public-folder-stack .folder-tab-title {
  top: -10px;
  left: 42px;
  z-index: 5;
  max-width: 104px;
  font-size: 12px;
  color: #23393f;
}

.public-folder-stack .folder-inner {
  padding: 34px 22px 14px;
}

.public-folder-stack .folder.slot-3 {
  top: 18px;
  transform: translateX(22px) translateY(0) scale(.9) rotate(-1.3deg);
}

.public-folder-stack .folder.slot-2 {
  top: 67px;
  transform: translateX(14px) translateY(0) scale(.935) rotate(.8deg);
}

.public-folder-stack .folder.slot-1 {
  top: 116px;
  transform: translateX(7px) translateY(0) scale(.97) rotate(-.4deg);
}

.public-folder-stack .folder.slot-0 {
  top: 166px;
  min-height: 130px;
  transform: translateX(0) translateY(0) scale(1) rotate(0);
}

.public-folder-stack .folder-title {
  font-size: 13.5px;
  text-align: left;
}

.public-folder-stack .folder-line {
  font-size: 10px;
  line-height: 1.32;
  text-align: left;
}

.public-folder-stack .folder-meta {
  font-size: 9.3px;
}

.public-folder-stack .folder-arrow {
  font-size: 22px;
  right: 18px;
}

.public-folder-stack .folder:not(.slot-0) .folder-inner {
  padding: 30px 20px 10px;
}

.public-folder-stack .folder:not(.slot-0) .folder-line:first-of-type {
  display: block;
  max-width: 76%;
  margin-top: 6px;
  opacity: .74;
}

.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;
}

@media (max-width: 380px) {
  .public-preview-actions {
    gap: 10px;
  }
  .public-folder-stack {
    width: 94vw;
  }
  .public-folder-stack .folder {
    left: 12px;
    right: 12px;
  }
}


/* 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;
}

.public-preview-actions {
  margin-top: 40px;
}

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

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

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

.public-preview-folders {
  margin-top: 24px;
}

.public-folder-stack,
.dashboard-folder-stack {
  width: min(92vw, 382px);
  height: 294px;
  margin: 0 auto;
  perspective: 960px;
}

.public-folder-stack .folder,
.dashboard-folder-stack .folder {
  left: 30px;
  right: 30px;
  min-height: 88px;
  border-radius: 20px 20px 24px 24px;
  transition: transform 520ms cubic-bezier(.18,1.18,.24,1), box-shadow 280ms ease, filter 240ms ease;
  will-change: transform;
}

.public-folder-stack .folder::before,
.dashboard-folder-stack .folder::before {
  top: -20px;
  left: 18px;
  width: 140px;
  height: 44px;
  border-radius: 18px 18px 8px 0;
}

.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  top: -11px;
  left: 39px;
  max-width: 126px;
  font-size: 13.75px;
  font-weight: 720;
  color: #20373d;
}

.public-folder-stack .folder.home,
.dashboard-folder-stack .folder.home {
  background: linear-gradient(135deg, #dcfff8 0%, #bff5e8 100%);
}
.public-folder-stack .folder.personal,
.dashboard-folder-stack .folder.personal {
  background: linear-gradient(135deg, #eeeaff 0%, #cfc7ff 100%);
}
.public-folder-stack .folder.family,
.dashboard-folder-stack .folder.family {
  background: linear-gradient(135deg, #ffe9f9 0%, #f1c5ea 100%);
}
.public-folder-stack .folder.brain,
.dashboard-folder-stack .folder.brain {
  background: linear-gradient(135deg, #fff2cf 0%, #ffd99d 100%);
}

.public-folder-stack .folder.slot-3,
.dashboard-folder-stack .folder.slot-3 {
  top: 20px;
  transform: translateX(28px) translateY(0) scale(.905) rotate(-1.2deg);
}
.public-folder-stack .folder.slot-2,
.dashboard-folder-stack .folder.slot-2 {
  top: 64px;
  transform: translateX(18px) translateY(0) scale(.935) rotate(.7deg);
}
.public-folder-stack .folder.slot-1,
.dashboard-folder-stack .folder.slot-1 {
  top: 108px;
  transform: translateX(9px) translateY(0) scale(.967) rotate(-.35deg);
}
.public-folder-stack .folder.slot-0,
.dashboard-folder-stack .folder.slot-0 {
  top: 154px;
  min-height: 122px;
  transform: translateX(0) translateY(0) scale(1) rotate(0);
}

.public-folder-stack .folder-inner,
.dashboard-folder-stack .folder-inner {
  padding: 32px 20px 12px;
}

.public-folder-stack .folder-title,
.dashboard-folder-stack .folder-title {
  font-size: 13.5px;
}

.public-folder-stack .folder-line,
.dashboard-folder-stack .folder-line {
  font-size: 10px;
  line-height: 1.34;
}

.public-folder-stack .folder:not(.slot-0) .folder-line:first-of-type,
.dashboard-folder-stack .folder:not(.slot-0) .folder-line:first-of-type {
  display: block;
  max-width: 78%;
  margin-top: 6px;
  opacity: .72;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.public-folder-stack .folder.slot-3:hover,
.public-folder-stack .folder.slot-3:focus-visible,
.dashboard-folder-stack .folder.slot-3:hover,
.dashboard-folder-stack .folder.slot-3:focus-visible {
  transform: translateX(28px) translateY(-8px) scale(.92) rotate(-.8deg) !important;
}
.public-folder-stack .folder.slot-2:hover,
.public-folder-stack .folder.slot-2:focus-visible,
.dashboard-folder-stack .folder.slot-2:hover,
.dashboard-folder-stack .folder.slot-2:focus-visible {
  transform: translateX(18px) translateY(-8px) scale(.95) rotate(.3deg) !important;
}
.public-folder-stack .folder.slot-1:hover,
.public-folder-stack .folder.slot-1:focus-visible,
.dashboard-folder-stack .folder.slot-1:hover,
.dashboard-folder-stack .folder.slot-1:focus-visible {
  transform: translateX(9px) translateY(-8px) scale(.982) rotate(0deg) !important;
}
.public-folder-stack .folder.slot-0:hover,
.public-folder-stack .folder.slot-0:focus-visible,
.dashboard-folder-stack .folder.slot-0:hover,
.dashboard-folder-stack .folder.slot-0:focus-visible {
  transform: translateX(0) translateY(-8px) scale(1.01) rotate(0deg) !important;
}

.public-folder-stack .folder.dragging,
.dashboard-folder-stack .folder.dragging {
  opacity: .9;
  transform: translateY(-16px) scale(1.025) rotate(.6deg) !important;
  box-shadow: 0 30px 54px rgba(8,27,32,.3);
}

.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); }
}

@media (max-width: 380px) {
  .public-folder-stack,
  .dashboard-folder-stack {
    width: 94vw;
  }
  .public-folder-stack .folder,
  .dashboard-folder-stack .folder {
    left: 24px;
    right: 24px;
  }
}


/* 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;
}

.event-calendar-card > p {
  color: rgba(233, 246, 243, .82);
}


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

.public-folder-stack,
.dashboard-folder-stack {
  width: min(92vw, 370px);
  height: 336px;
  margin: 0 auto;
  perspective: 1000px;
  overflow: visible;
}

.public-folder-stack .folder,
.dashboard-folder-stack .folder {
  right: auto !important;
  width: min(76vw, 300px);
  min-height: 150px !important;
  height: 150px;
  border-radius: 20px 20px 25px 25px;
  overflow: visible;
  box-shadow: 0 18px 34px rgba(7, 24, 30, .26);
  transition: transform 560ms cubic-bezier(.18,1.22,.24,1), box-shadow 260ms ease, filter 260ms ease;
}

.public-folder-stack .folder::before,
.dashboard-folder-stack .folder::before {
  top: -18px;
  left: 18px;
  width: 138px;
  height: 42px;
  border-radius: 18px 18px 8px 0;
  box-shadow: inset 0 1px rgba(255,255,255,.34);
}

.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  top: -9px;
  left: 38px;
  max-width: 122px;
  font-size: 14px;
  font-weight: 760;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.public-folder-stack .folder-inner,
.dashboard-folder-stack .folder-inner {
  padding: 48px 22px 16px;
}

.public-folder-stack .folder-title,
.dashboard-folder-stack .folder-title {
  font-size: 15px;
  line-height: 1.15;
}

.public-folder-stack .folder-line,
.dashboard-folder-stack .folder-line {
  margin-top: 7px;
  font-size: 10.7px;
  line-height: 1.32;
}

.public-folder-stack .folder-meta,
.dashboard-folder-stack .folder-meta {
  margin-top: 12px;
  font-size: 9.5px;
}

.public-folder-stack .folder:not(.slot-0) .folder-inner,
.dashboard-folder-stack .folder:not(.slot-0) .folder-inner {
  padding: 42px 18px 12px;
}

.public-folder-stack .folder:not(.slot-0) .folder-title,
.public-folder-stack .folder:not(.slot-0) .folder-meta,
.public-folder-stack .folder:not(.slot-0) .folder-arrow,
.dashboard-folder-stack .folder:not(.slot-0) .folder-title,
.dashboard-folder-stack .folder:not(.slot-0) .folder-meta,
.dashboard-folder-stack .folder:not(.slot-0) .folder-arrow {
  display: none;
}

.public-folder-stack .folder:not(.slot-0) .folder-line:first-of-type,
.dashboard-folder-stack .folder:not(.slot-0) .folder-line:first-of-type {
  display: block;
  max-width: 84%;
  margin-top: 0;
  font-size: 10.2px;
  opacity: .76;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

.public-folder-stack .folder.slot-3,
.dashboard-folder-stack .folder.slot-3 {
  top: 18px;
  left: 18px;
  z-index: 1;
  transform: translate3d(0,0,-36px) rotate(-.6deg) scale(.985);
}
.public-folder-stack .folder.slot-2,
.dashboard-folder-stack .folder.slot-2 {
  top: 64px;
  left: 36px;
  z-index: 2;
  transform: translate3d(0,0,-24px) rotate(.25deg) scale(.99);
}
.public-folder-stack .folder.slot-1,
.dashboard-folder-stack .folder.slot-1 {
  top: 110px;
  left: 54px;
  z-index: 3;
  transform: translate3d(0,0,-12px) rotate(-.2deg) scale(.995);
}
.public-folder-stack .folder.slot-0,
.dashboard-folder-stack .folder.slot-0 {
  top: 158px;
  left: 72px;
  z-index: 4;
  transform: translate3d(0,0,0) rotate(0) scale(1);
}

.public-folder-stack .folder.slot-3:hover,
.public-folder-stack .folder.slot-3:focus-visible,
.dashboard-folder-stack .folder.slot-3:hover,
.dashboard-folder-stack .folder.slot-3:focus-visible {
  transform: translate3d(0,-9px,-36px) rotate(-.35deg) scale(1) !important;
}
.public-folder-stack .folder.slot-2:hover,
.public-folder-stack .folder.slot-2:focus-visible,
.dashboard-folder-stack .folder.slot-2:hover,
.dashboard-folder-stack .folder.slot-2:focus-visible {
  transform: translate3d(0,-9px,-24px) rotate(.05deg) scale(1.005) !important;
}
.public-folder-stack .folder.slot-1:hover,
.public-folder-stack .folder.slot-1:focus-visible,
.dashboard-folder-stack .folder.slot-1:hover,
.dashboard-folder-stack .folder.slot-1:focus-visible {
  transform: translate3d(0,-9px,-12px) rotate(0deg) scale(1.008) !important;
}
.public-folder-stack .folder.slot-0:hover,
.public-folder-stack .folder.slot-0:focus-visible,
.dashboard-folder-stack .folder.slot-0:hover,
.dashboard-folder-stack .folder.slot-0:focus-visible {
  transform: translate3d(0,-9px,0) rotate(0deg) scale(1.01) !important;
}

.public-folder-stack .folder.dragging,
.dashboard-folder-stack .folder.dragging {
  opacity: .94;
  transform: translateY(-18px) scale(1.025) rotate(.6deg) !important;
  box-shadow: 0 30px 58px rgba(7, 24, 30, .34);
}

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

@media (max-width: 380px) {
  .public-folder-stack,
  .dashboard-folder-stack {
    width: 94vw;
    height: 328px;
  }
  .public-folder-stack .folder,
  .dashboard-folder-stack .folder {
    width: min(75vw, 286px);
  }
  .public-folder-stack .folder.slot-0,
  .dashboard-folder-stack .folder.slot-0 { left: 58px; }
  .public-folder-stack .folder.slot-1,
  .dashboard-folder-stack .folder.slot-1 { left: 44px; }
  .public-folder-stack .folder.slot-2,
  .dashboard-folder-stack .folder.slot-2 { left: 30px; }
  .public-folder-stack .folder.slot-3,
  .dashboard-folder-stack .folder.slot-3 { left: 16px; }
}


/* 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;
}

.public-folder-stack,
.dashboard-folder-stack {
  height: 366px;
}

.public-folder-stack .folder,
.dashboard-folder-stack .folder {
  height: 168px;
  min-height: 168px !important;
  width: min(74vw, 292px);
}

.public-folder-stack .folder::before,
.dashboard-folder-stack .folder::before {
  top: -22px;
  left: 18px;
  width: 154px;
  height: 48px;
}

.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  top: -11px;
  left: 38px;
  z-index: 20;
  display: block !important;
  opacity: 1 !important;
  max-width: 138px;
  font-size: 15px;
  line-height: 1.05;
  color: #1f343a;
  text-shadow: 0 1px rgba(255,255,255,.34);
}

.public-folder-stack .folder-inner,
.dashboard-folder-stack .folder-inner {
  padding-top: 54px;
}

.public-folder-stack .folder:not(.slot-0) .folder-inner,
.dashboard-folder-stack .folder:not(.slot-0) .folder-inner {
  padding-top: 50px;
}

.public-folder-stack .folder.slot-3,
.dashboard-folder-stack .folder.slot-3 {
  top: 22px;
  left: 18px;
}
.public-folder-stack .folder.slot-2,
.dashboard-folder-stack .folder.slot-2 {
  top: 76px;
  left: 38px;
}
.public-folder-stack .folder.slot-1,
.dashboard-folder-stack .folder.slot-1 {
  top: 130px;
  left: 58px;
}
.public-folder-stack .folder.slot-0,
.dashboard-folder-stack .folder.slot-0 {
  top: 186px;
  left: 78px;
}

.public-folder-stack .folder-title,
.dashboard-folder-stack .folder-title {
  font-size: 15.5px;
}

.public-folder-stack .folder-line,
.dashboard-folder-stack .folder-line {
  font-size: 10.9px;
}

.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;
}

@media (max-width: 380px) {
  .public-folder-stack,
  .dashboard-folder-stack {
    height: 356px;
  }
  .public-folder-stack .folder,
  .dashboard-folder-stack .folder {
    width: min(73vw, 274px);
  }
  .public-folder-stack .folder.slot-0,
  .dashboard-folder-stack .folder.slot-0 { left: 64px; }
  .public-folder-stack .folder.slot-1,
  .dashboard-folder-stack .folder.slot-1 { left: 48px; }
  .public-folder-stack .folder.slot-2,
  .dashboard-folder-stack .folder.slot-2 { left: 32px; }
  .public-folder-stack .folder.slot-3,
  .dashboard-folder-stack .folder.slot-3 { left: 16px; }
  .public-folder-stack .folder-tab-title,
  .dashboard-folder-stack .folder-tab-title {
    font-size: 14px;
    max-width: 128px;
  }
}


/* 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;
}

.public-folder-stack .folder,
.dashboard-folder-stack .folder {
  overflow: visible !important;
}

.public-folder-stack .folder-inner,
.dashboard-folder-stack .folder-inner {
  position: static;
}

.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  position: absolute;
  top: -9px;
  left: 38px;
  z-index: 50;
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  color: #1f343a !important;
  background: transparent;
  pointer-events: none;
}

.public-folder-stack .folder.slot-3 .folder-tab-title,
.dashboard-folder-stack .folder.slot-3 .folder-tab-title,
.public-folder-stack .folder.slot-2 .folder-tab-title,
.dashboard-folder-stack .folder.slot-2 .folder-tab-title,
.public-folder-stack .folder.slot-1 .folder-tab-title,
.dashboard-folder-stack .folder.slot-1 .folder-tab-title,
.public-folder-stack .folder.slot-0 .folder-tab-title,
.dashboard-folder-stack .folder.slot-0 .folder-tab-title {
  display: block !important;
}

.public-folder-stack .folder::after,
.dashboard-folder-stack .folder::after {
  content: attr(aria-label);
  position: absolute;
  top: -9px;
  left: 38px;
  z-index: 49;
  max-width: 138px;
  font-size: 15px;
  line-height: 1.05;
  font-weight: 760;
  color: transparent;
}


/* Folder stack positioning and softer folder typography */
.public-folder-stack,
.dashboard-folder-stack {
  width: min(94vw, 380px);
  height: 380px;
}

.public-folder-stack .folder,
.dashboard-folder-stack .folder {
  width: min(79vw, 314px);
  height: 174px;
  min-height: 174px !important;
}

.public-folder-stack .folder.slot-3,
.dashboard-folder-stack .folder.slot-3 {
  top: 18px;
  left: 2px;
}
.public-folder-stack .folder.slot-2,
.dashboard-folder-stack .folder.slot-2 {
  top: 78px;
  left: 22px;
}
.public-folder-stack .folder.slot-1,
.dashboard-folder-stack .folder.slot-1 {
  top: 138px;
  left: 42px;
}
.public-folder-stack .folder.slot-0,
.dashboard-folder-stack .folder.slot-0 {
  top: 200px;
  left: 62px;
}

.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  color: #31464d !important;
  font-weight: 680;
  letter-spacing: -.01em;
}

.public-folder-stack .folder-title,
.dashboard-folder-stack .folder-title {
  color: #31464d;
  font-size: 15px;
  font-weight: 640;
  text-align: center;
}

.public-folder-stack .folder-line,
.dashboard-folder-stack .folder-line {
  color: rgba(56, 80, 87, .76);
  font-weight: 430;
  text-align: center;
}

.public-folder-stack .folder-meta,
.dashboard-folder-stack .folder-meta {
  color: rgba(18, 117, 106, .78);
  text-align: center;
  font-weight: 620;
}

.public-folder-stack .folder.slot-0 .folder-inner,
.dashboard-folder-stack .folder.slot-0 .folder-inner {
  display: flex;
  min-height: 100%;
  flex-direction: column;
  justify-content: center;
  padding: 48px 34px 18px;
}

.public-folder-stack .folder-arrow,
.dashboard-folder-stack .folder-arrow {
  top: 50%;
  transform: translateY(-50%);
}

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

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

@media (max-width: 380px) {
  .public-folder-stack,
  .dashboard-folder-stack {
    width: 94vw;
    height: 368px;
  }
  .public-folder-stack .folder,
  .dashboard-folder-stack .folder {
    width: min(78vw, 296px);
    height: 168px;
    min-height: 168px !important;
  }
  .public-folder-stack .folder.slot-3,
  .dashboard-folder-stack .folder.slot-3 { left: 2px; }
  .public-folder-stack .folder.slot-2,
  .dashboard-folder-stack .folder.slot-2 { left: 18px; }
  .public-folder-stack .folder.slot-1,
  .dashboard-folder-stack .folder.slot-1 { left: 34px; }
  .public-folder-stack .folder.slot-0,
  .dashboard-folder-stack .folder.slot-0 { left: 50px; }
}


/* Softer folder palette and logged-in menu */
.public-folder-stack .folder.home,
.dashboard-folder-stack .folder.home {
  background: linear-gradient(135deg, #d8f5ee 0%, #c6ebe3 100%);
}
.public-folder-stack .folder.personal,
.dashboard-folder-stack .folder.personal {
  background: linear-gradient(135deg, #e5e1f6 0%, #d4ceec 100%);
}
.public-folder-stack .folder.family,
.dashboard-folder-stack .folder.family {
  background: linear-gradient(135deg, #f3dfe9 0%, #e9cbdc 100%);
}
.public-folder-stack .folder.brain,
.dashboard-folder-stack .folder.brain {
  background: linear-gradient(135deg, #f4e6c5 0%, #ecd2a1 100%);
}

.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  color: rgba(45, 63, 69, .88) !important;
  font-weight: 590;
}

.public-folder-stack .folder-title,
.dashboard-folder-stack .folder-title {
  color: rgba(45, 63, 69, .9);
  font-weight: 560;
}

.public-folder-stack .folder-line,
.dashboard-folder-stack .folder-line {
  color: rgba(62, 84, 91, .68);
  font-weight: 390;
}

.public-folder-stack .folder-meta,
.dashboard-folder-stack .folder-meta {
  color: rgba(34, 113, 104, .66);
  font-weight: 540;
}

.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 wiring visual support and folder vertical balance */
.public-preview-folders {
  margin-top: 48px;
}

.top-actions + section {
  margin-top: 42px;
}

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

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


/* Folder spacing and menu tap robustness */
.public-preview-folders {
  margin-top: 62px;
}

.public-folder-stack,
.dashboard-folder-stack {
  margin-bottom: 26px;
}

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

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

@media (max-width: 430px) {
  .public-preview-folders {
    margin-top: 58px;
  }
}


/* =================================================================
   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: #5a6c72;
}
.os-crumb-row {
  display: grid;
  grid-template-columns: 1fr minmax(0, auto) 1fr;
  align-items: center;
  gap: 8px;
}
.os-crumb-back { justify-self: start; display: flex; align-items: center; gap: 7px; }
.os-back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 7px 12px 7px 9px;
  border-radius: 999px;
  border: 1px solid rgba(35, 60, 65, 0.12);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, transform 120ms ease;
}
.os-back:hover { background: rgba(255, 255, 255, 0.92); border-color: rgba(35, 60, 65, 0.22); }
.os-back-arrow { font-size: 18px; line-height: 1; transform: translateY(-1px); color: var(--accent-dark); font-weight: 700; }
.os-back-label { letter-spacing: 0.01em; }
/* Small round Xortit-home button shown alongside the module back chip on sub-pages */
.os-home-btn {
  width: 38px; height: 38px; border-radius: 50%;
  display: inline-grid; place-items: center;
  border: 1px solid rgba(35, 60, 65, 0.12); background: rgba(255, 255, 255, 0.7);
  color: var(--accent-dark); cursor: pointer;
  transition: background 160ms ease, transform 120ms ease;
}
.os-home-btn:hover { background: #fff; }
.os-home-btn:active { transform: scale(0.94); }
.os-home-btn svg { width: 18px; height: 18px; }
.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; }
.os-crumb-tools { justify-self: end; display: flex; gap: 9px; align-items: center; }
/* Add / Sort / Filter row, right-aligned beneath the menu (item 4) */
.os-crumb-actions { display: flex; justify-content: flex-end; 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; }
.os-fullpage .app-shell { padding: 0; color: var(--ink); }
.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: #5f7278; }
.homeos-card .homeos-shell p { color: var(--ink); }
.homeos-card .homeos-shell .folder-line { color: #5f7278; }
.meals-shell .folder-title { color: var(--ink); }
.meals-shell .folder-line { color: #5f7278; }

/* ============================================================
   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; }
/* 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: #67797f;
  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: #67797f;
  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);
  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: #67797f;
}
.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: #36505a;
  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: #36505a; }
.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: #67797f; }

/* 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: #67797f; }

/* 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-tabs {
  display: flex;
  gap: 6px;
  margin: 14px 0 12px;
}
.chore-scope-row { display: flex; flex-wrap: wrap; gap: 6px; margin: -2px 0 12px; }
.chore-scope-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 10px; border-radius: 999px;
  border: 1px solid var(--accent-dark, #1f8a7e);
  background: rgba(53,202,187,0.14); color: var(--accent-dark, #1f8a7e);
  font-size: 11.5px; font-weight: 650; cursor: pointer;
}
.chore-scope-chip i { font-style: normal; font-size: 11px; opacity: 0.8; }
.chore-scope-chip:hover { background: rgba(53,202,187,0.22); }
.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: #67797f; }

/* --- 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-back {
  background: rgba(255,255,255,0.10);
  border-color: rgba(255,255,255,0.18);
  color: var(--text-inverse);
}
.cal-header .os-back:hover { background: rgba(255,255,255,0.16); }
.cal-header .os-back-arrow { color: var(--accent); }
.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 { display: flex; align-items: stretch; gap: 6px; margin-bottom: 12px; }
.cal-week-nav .cal-week-strip { flex: 1; margin-bottom: 0; }
.cal-week-arrow {
  flex: 0 0 auto; width: 30px; border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.16); background: rgba(255,255,255,0.08);
  color: var(--text-inverse); font-size: 20px; line-height: 1; cursor: pointer;
  transition: background 160ms ease, opacity 160ms ease;
}
.cal-week-arrow:hover { background: rgba(255,255,255,0.16); }
.cal-week-arrow:disabled { opacity: 0.3; cursor: default; }
.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: #8295a0; 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: #2b3438; }
.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: #67797f; 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: #67797f; }
.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; }

.meals-summary {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  padding: 12px 14px;
  margin-bottom: 12px;
  border-radius: 16px;
  background: rgba(255,255,255,0.6);
  border: 1px solid rgba(35,60,65,0.06);
  font-size: 11.5px;
  color: #67797f;
}
.meals-summary strong { color: var(--ink); font-weight: 700; }

.meals-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}
.meal-row {
  display: grid;
  grid-template-columns: 60px 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);
}
.meal-time {
  font-variant-numeric: tabular-nums;
  font-weight: 650;
  font-size: 13px;
  color: var(--ink);
}
.meal-body strong { display: block; font-size: 11px; font-weight: 700; color: var(--accent-dark); text-transform: uppercase; letter-spacing: 0.06em; }
.meal-body p { margin: 3px 0 4px; font-size: 13.5px; color: var(--ink); font-weight: 650; letter-spacing: -0.005em; line-height: 1.25; }
.meal-body em { display: block; font-style: normal; font-size: 11px; color: #67797f; }
.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); }

.meals-jump {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 6px 0 18px;
}
.meal-jump-card {
  padding: 14px 12px;
  border-radius: 16px;
  background: rgba(255,255,255,0.7);
  border: 1px solid rgba(35,60,65,0.06);
  text-align: left;
  cursor: pointer;
}
.meal-jump-card strong { display: block; font-size: 12.5px; color: var(--ink); font-weight: 700; }
.meal-jump-card em { display: block; margin-top: 4px; font-style: normal; font-size: 10.5px; color: #67797f; line-height: 1.3; }

/* 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); font-weight: 700; }
.week-day-head span { color: #8a8f93; }
.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-pdf-icon { color: #b54a2c; display: inline-flex; align-items: center; justify-content: center; }
.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: #67797f; }
.prev-open { font-size: 12px; font-weight: 650; color: var(--accent-dark); }
.prev-foot { margin-top: 14px; font-size: 11px; color: #67797f; }

/* 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; }
.ingr-send-btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--accent-dark); background: rgba(53,202,187,0.12); color: var(--accent-dark); font-size: 12.5px; font-weight: 700; font-family: inherit; cursor: pointer; }
.ingr-send-btn:hover { background: rgba(53,202,187,0.2); }
.ingr-send-btn svg { width: 15px; height: 15px; }
.ing-sel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 4px 0 0; }
.ing-sel-count { font-size: 12.5px; font-weight: 700; color: var(--accent-dark); }
.ing-list.selecting .ing-row { grid-template-columns: 26px minmax(0, 1.4fr) 56px 76px 60px; }
.ing-pick { width: 19px; height: 19px; accent-color: var(--accent-dark); cursor: pointer; }
.ing-sel-bar { display: flex; gap: 10px; margin: 14px 0 8px; align-items: stretch; }
.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: #46606a; 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: #67797f;
  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: #36505a;
}
.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-order {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 4px 8px;
  border-radius: 999px;
  text-align: center;
  background: rgba(35,60,65,0.06);
  color: #36505a;
}
.ing-order.order-today    { background: #ffd9c4; color: #a43f1a; }
.ing-order.order-tomorrow { background: #ffe9c4; color: #8a5a17; }
.ing-order.order-daily    { background: #d6f1ea; color: #1d6b5c; }
.ing-order.order-sun      { background: rgba(53,202,187,0.18); color: var(--accent-dark); }
.ing-order.order-mon, .ing-order.order-tue, .ing-order.order-wed,
.ing-order.order-thu, .ing-order.order-fri, .ing-order.order-sat {
  background: rgba(35,60,65,0.10); color: #36505a;
}
.ing-foot { margin-top: 4px; font-size: 11px; color: #67797f; 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: #67797f; }
.qc-sub em { font-style: italic; color: #8a8f93; }
.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: #4d6066;
  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); }
  .meals-jump { grid-template-columns: 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 */
:root {
  --night-bg-flat: #0e1f1e;
  --night-glass: rgba(255,255,255,0.05);
  --night-glass-strong: rgba(255,255,255,0.09);
  --night-border: rgba(255,255,255,0.10);
  --night-border-soft: rgba(255,255,255,0.06);
  --night-ink: rgba(255,255,255,0.96);
  --night-ink2: rgba(255,255,255,0.74);
  --night-ink3: rgba(255,255,255,0.56);
  --night-ink4: rgba(255,255,255,0.40);
  --mint: #7BE5C9;
  --mint-deep: #34BFA8;
  --mint-glow: rgba(123,229,201,0.18);
  --mint-glow-soft: rgba(123,229,201,0.08);

  /* Manila folder faces — solid, muted, grounded (not bright, not glassy).
     Tab uses the SAME hue as the body so the name label matches the folder. */
  /* Folder faces — lighter, airier pastels harmonised around the brand teal.
     Calmer and more modern than the previous saturated manila tones. */
  /* Folder faces — corporate dark-glass (was pastel/childlike). Each module keeps a
     distinct hue as a subtle tint + accent dot; ink is light for contrast on the dark grid. */
  --f-home-face: linear-gradient(155deg, rgba(34,62,56,0.78) 0%, rgba(18,38,34,0.82) 100%);   --f-home-tab: rgba(30,56,50,0.82);   --f-home-ink: #e9f4f0;   --f-home-hue: #3ad6b0;
  --f-personal-face: linear-gradient(155deg, rgba(40,42,66,0.78) 0%, rgba(24,26,46,0.82) 100%); --f-personal-tab: rgba(36,38,60,0.82); --f-personal-ink: #eceefa;   --f-personal-hue: #8b9bf0;
  --f-family-face: linear-gradient(155deg, rgba(58,38,48,0.78) 0%, rgba(36,22,30,0.82) 100%); --f-family-tab: rgba(52,34,44,0.82); --f-family-ink: #f8eaef;   --f-family-hue: #e58aa6;
  --f-brain-face: linear-gradient(155deg, rgba(58,50,30,0.78) 0%, rgba(36,30,18,0.82) 100%);  --f-brain-tab: rgba(52,44,28,0.82);  --f-brain-ink: #f5eed9;  --f-brain-hue: #e0bd6a;
}

/* 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);
}

/* Hero / action tiles — night glass with mint accent */
.top-actions, .public-preview-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 0 4px;
  margin-top: 18px;
}
.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;
}

/* Make sure the home page wraps content with sensible spacing */
.public-page .public-preview-folders,
.dashboard-folder-stack { margin-top: 14px; }

/* 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;
}

/* Calendar breadcrumb on night */
.cal-header .os-back {
  background: var(--night-glass-strong);
  border-color: var(--night-border);
  color: var(--night-ink);
}
.cal-header .os-back:hover { background: var(--night-glass); }

/* 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;
}

/* --- Centered folder grid with proper max-width -------------- */
.folder-stack.public-folder-stack,
.folder-stack.dashboard-folder-stack {
  height: auto !important;
  position: relative;
  padding: 14px 0 0;
  margin-bottom: 0 !important;
}
.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; }

/* --- 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-toolbar {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 14px 12px;
  margin: 12px 0 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--homeos-line, #d7eef5);
  color: var(--ink, #1a2a2e);
  box-shadow: 0 6px 18px rgba(8, 27, 32, 0.10);
}
.chore-toolbar-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.chore-toolbar-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #5d7176;
  min-width: 48px;
}
.chore-cat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.chore-cat-chip {
  border: 1px solid #d2e3e6;
  background: #f3f9fa;
  color: #2a4146;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
}
.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: #1a2a2e;
  font-size: 13px;
  font-weight: 600;
}
.chore-toolbar-hint {
  margin: 0;
  font-size: 11.5px;
  color: #6a7c81;
  line-height: 1.4;
}

/* --- 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: #1a2a2e;
  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: #4a6065; 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: #6a7c81; }

/* --- 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 { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 2px 0 14px; }
.os-list-head .os-list-head-text { min-width: 0; }
.os-list-head .folder-title { margin: 0; }
.os-page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 6px 0 16px; }
.os-page-head-text { min-width: 0; }
.os-page-title { margin: 0; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; color: #2c4650; line-height: 1.1; }
.os-page-sub { margin: 5px 0 0; font-size: 12.5px; color: #6a7c81; }
.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; }
.os-menu-btn { color: var(--accent-dark); }
.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: 700; letter-spacing: -0.005em; text-transform: none; color: var(--ink);
  -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(53,202,187,0.16); color: var(--accent-dark); 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(--accent-dark); }
.cadence-section[open] > summary .cadence-chev { transform: rotate(45deg); border-color: var(--accent-dark); }
.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: #8295a0; 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; }
.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: #6a7c81; }
.chore-aside .chore-time { font-size: 12px; font-weight: 700; color: #4a6065; font-variant-numeric: tabular-nums; }
.chore-scope-note {
  margin: 0 2px 12px; padding: 9px 12px; border-radius: 11px; font-size: 12px; line-height: 1.45;
  background: rgba(53,202,187,0.1); color: #3a5a5f; border: 1px solid rgba(53,202,187,0.22);
}
.chore-scope-note strong { color: var(--accent-dark); font-weight: 700; }
.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: #6a7c81; }
.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: #4a6065; 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: #7c9094; 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: #2a4146; }
.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: 18px;
  background: rgba(20, 36, 40, 0.94);
  color: #f4fbfb;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.38);
  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: 600; padding-left: 6px; }
.multiselect-count strong { font-size: 15px; color: #7BE5C9; margin-right: 4px; }
.multiselect-actions { display: flex; gap: 6px; }
.ms-action {
  padding: 8px 12px;
  border: 0;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.ms-action.ms-done   { background: var(--accent-dark); color: #fff; }
.ms-action.ms-cant   { background: #d3934a; color: #1f1a14; }
.ms-action.ms-delete { background: #b9434a; color: #fff; }
.ms-action.ms-cancel { background: rgba(255, 255, 255, 0.10); color: #f4fbfb; }
.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: #1a2a2e;
  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: #6a7c81; }
.approval-note { margin: 6px 0 0; font-size: 12.5px; color: #2a4146; }
.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: #2a4146; 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; }

/* --- Task state group pages --------------------------------- */
.task-group { margin: 16px 0 8px; }
.task-group-title {
  display: flex; align-items: center; justify-content: space-between;
  margin: 12px 4px 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #2a4146;
}
.task-group-title em {
  font-style: normal;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e2eef0;
  color: #2a4146;
}
.task-state-hint {
  margin: 8px 4px 6px;
  font-size: 12px;
  color: #6a7c81;
  font-style: italic;
}

/* --- 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: #2a4146;
}
.empty-state strong { display:block; font-size:14px; margin-bottom:4px; }
.empty-state em { font-style: normal; font-size: 12px; color: #6a7c81; }
.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: #5d7176; }
.homeos-cal-card .cal-header .os-back {
  background: rgba(255,255,255,0.8);
  border-color: rgba(35,60,65,0.12);
  color: var(--ink);
}
.homeos-cal-card .cal-header .os-back:hover { background: #fff; }
.homeos-cal-card .cal-header .os-back-arrow { color: var(--accent-dark); }
.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: #67797f; }
.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: #67797f; }
.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: #67797f; }
.homeos-cal-card .cal-allday-label { color: #67797f; }
.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: #67797f; }
.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: #5d7176; }

/* --- Slot-positioning carryovers: kill the absolutely-positioned
       legacy folder slots so the new grid-layout works cleanly. -- */
.public-folder-stack .folder.slot-0,
.public-folder-stack .folder.slot-1,
.public-folder-stack .folder.slot-2,
.public-folder-stack .folder.slot-3,
.dashboard-folder-stack .folder.slot-0,
.dashboard-folder-stack .folder.slot-1,
.dashboard-folder-stack .folder.slot-2,
.dashboard-folder-stack .folder.slot-3 {
  position: static !important;
  top: auto !important; left: auto !important;
  transform: none !important;
}
.public-folder-stack .folder-tab-title,
.dashboard-folder-stack .folder-tab-title {
  display: none !important;
}
.public-folder-stack .folder:not(.slot-0) .folder-tab-icon,
.dashboard-folder-stack .folder:not(.slot-0) .folder-tab-icon { display: inline-flex !important; }

/* --- 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: #5d7176;
  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: 14.5px; font-weight: 700; color: #1a2a2e;
}
.homeos-rhythm.v2 .rhythm-head em {
  display: block; margin-top: 3px;
  font-style: normal; font-size: 11.5px; color: #5d7176;
}
.homeos-rhythm.v2 .rhythm-now-time {
  font-size: 12px; font-weight: 650; color: #2a4146;
  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: #5d7176;
}
.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: 18px; font-weight: 760; color: var(--ink, #1a2a2e); letter-spacing: -0.015em; }
.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: 34px; line-height: 1; font-weight: 770; color: #1f8a7a; letter-spacing: -0.03em; }
.rc-total span { margin-top: 4px; font-size: 11px; font-weight: 600; color: #7a8c90; }
.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: #1f8a7a; }
.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: #94a6aa; }
.rc-cell-ico svg { width: 14px; height: 14px; }
.rc-cell-label { font-size: 11px; font-weight: 600; color: #7a8c90; }
.rc-cell b { font-size: 18px; font-weight: 740; color: var(--ink, #1a2a2e); line-height: 1; }
.rc-cell.has b { color: #1f8a7a; }
.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: #1a2a2e;
}
.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: 15px;
  font-weight: 700;
  color: #41565b;
  line-height: 1.25;
}
.state-chip em {
  margin-top: 6px;
  display: block;
  font-style: normal;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #1a2a2e;
}

/* --- Chore recur banner (when filtered to recurring-only) ---- */
.chore-recur-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 8px 12px;
  margin: -6px -2px 6px;
  border-radius: 10px;
  background: rgba(123, 229, 201, 0.12);
  border: 1px solid rgba(53, 202, 187, 0.34);
  color: #117D74;
  font-size: 12px;
  font-weight: 600;
}
.chore-recur-clear {
  border: 0;
  background: #117D74;
  color: #fff;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
}
.chore-recur-clear:active { transform: scale(0.97); }

/* ============================================================
   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: #4a6065; }

/* --- 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; }
/* 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: #67797f; }
.meals-daybar-stats { display: flex; gap: 10px; font-size: 10.5px; color: #67797f; }
.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: #67797f; }
.meals-daybar-stats { display: flex; gap: 12px; font-size: 11px; color: #67797f; }
.meals-daybar-stats b { color: var(--ink); font-weight: 700; }
.meals-daybar .meal-replan { flex: 0 0 auto; }

.meal-slots { display: flex; flex-direction: column; gap: 11px; margin-bottom: 18px; }
.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: #5d7176;
}
.meal-dish-list {
  display: flex; flex-direction: column; gap: 1px;
  border-radius: 14px; overflow: hidden;
  border: 1px solid rgba(35,60,65,0.08);
}
.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: #8a9a9e; 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: #aab6b9; cursor: pointer; transition: all 130ms ease;
}
.dish-thumb:hover { background: rgba(35,60,65,0.06); color: #5d7176; }
.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: #5d7176; 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: #67797f; }
.rc-close {
  flex-shrink: 0;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid rgba(35,60,65,0.12);
  background: #fff; color: #4a6065;
  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: #2a4146; }
.rc-serving-unit { font-size: 12.5px; color: #5d7176; }
.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: #5d7176;
}
.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: #46606a; 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: #5d7176; 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: #2a4146; line-height: 1.2; }
.mp-field-label em { display: block; font-style: normal; font-size: 9.5px; color: #7c8d92; 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: #2a4146; }
.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: #2a4146;
  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: #2a4146; 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: #5d7176; 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: #5d7176; 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; }
.pi-methods { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 4px; border-radius: 12px; background: rgba(35,60,65,0.06); }
.pi-method { padding: 9px; border: 0; border-radius: 9px; background: transparent; color: #46606a; font-size: 12.5px; font-weight: 650; cursor: pointer; font-family: inherit; }
.pi-method.active { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(2,10,12,0.12); }
.pi-pane { display: flex; flex-direction: column; gap: 10px; }
.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: #5d7176; line-height: 1.35; }
.pi-status { margin: 0; font-size: 12px; color: #5d7176; }
.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: #8a9a9e; }
.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: #67797f; }
.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: #8a9a9e; 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: #46606a; 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: #4a6065; 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: #5d7176; 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: #36505a; }
.mp-mem-text { flex: 1; min-width: 0; }
.mp-mem-item em { font-style: normal; color: #8a9a9e; 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: #8a9a9e; 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: #8a9a9e; }

/* ---- "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: #5d7176; 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: #5d7176; }
.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: #8a9a9e; }
.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: #8a9a9e; 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: #46606a; 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: #5d7176; }
.mp-result-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.mp-result-list li { font-size: 12.5px; color: #36505a; line-height: 1.4; }

/* --- 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(53,202,187,0.08); }
.mpw-day-head strong { font-size: 13.5px; font-weight: 750; color: var(--ink); }
.mpw-day-head span { font-size: 11px; color: #6a7d82; }
.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: #6a7d82; 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: #7c9094; }
.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; }
.mpw-dish { display: flex; flex-direction: column; gap: 1px; }
.mpw-kcal { font-size: 10.5px; color: #8a9ca0; font-weight: 500; }
.mpw-foot { font-size: 11.5px; color: #7c9094; 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: #8a9ca0; }
.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: #4a6065; 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: #4a636a; }
.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: #5e757b; 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: #6a7d82; 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-bridge-paste .mp-textarea { width: 100%; box-sizing: border-box; margin-bottom: 8px; }
.mp-bridge-paste .mp-generate { margin-top: 0; }

/* --- Collapsible filter / sort (chores + ingredients) -------- */
.chore-toolbar-stack { display: flex; flex-direction: column; gap: 10px; margin: 12px 0 10px; }

/* Chores header: title left, filter/sort icons top-right */
.chores-head-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 2px 0 4px; }
.chores-head-text { min-width: 0; }
.chores-tools { display: flex; gap: 8px; flex: 0 0 auto; }
.chore-panel-stack { display: flex; flex-direction: column; gap: 10px; margin: 4px 0 6px; }
.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: #2a4146;
  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: #67797f; margin-left: 2px; }
.ft-panel {
  border-radius: 14px;
  padding: 12px;
  background: rgba(255,255,255,0.78);
  border: 1px solid rgba(35,60,65,0.1);
  opacity: 1;
  animation: ft-open 180ms ease;
}
@keyframes ft-open { from { transform: translateY(-4px); } to { transform: translateY(0); } }
.ft-opt-list { display: flex; flex-direction: column; gap: 4px; }
.ft-opt {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px; border-radius: 10px;
  border: 0; background: transparent; color: #2a4146;
  font-size: 13px; font-weight: 600; cursor: pointer; text-align: left;
}
.ft-opt:hover { background: rgba(53,202,187,0.08); }
.ft-opt.active { background: rgba(53,202,187,0.14); color: var(--accent-dark); font-weight: 750; }
.ft-opt .ft-check { font-style: normal; color: var(--accent-dark); }

/* --- 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; }

/* --- Folder stack fills content width (align with action tiles) - */
.public-folder-stack,
.dashboard-folder-stack {
  width: auto !important;
  max-width: none !important;
  height: auto !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* --- 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: #5d7176; }
.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-modal-actions { display: flex; gap: 10px; margin-top: 18px; }

/* 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: #7c9094; 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 */
.import-paste-wrap { display: flex; flex-direction: column; gap: 8px; margin: 10px 0 4px; }
.import-paste-area { width: 100%; border-radius: 12px; border: 1px solid rgba(35,60,65,0.16); padding: 10px; font: 12px/1.5 ui-monospace, Menlo, monospace; resize: vertical; }

/* 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: #2a4146; }
.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: #6a7c81; 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: #2a4146; 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: #6a7d82; 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: #6a7d82; 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: #7a8c90; }
.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: #6a7d82; }
.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: #41555a; 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: #7c8e93; 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: #8a999d; font-weight: 600; margin: 2px 0 0; }
.adv-ledger-title { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: #7c8e93; font-weight: 700; margin: 14px 0 6px; }
.adv-ledger-empty { font-size: 12.5px; color: #8a999d; 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: #6c8a87; }
.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: #5d7176; }
.advance-hint { font-size: 11px; color: #6a7d82; 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: #5d7176; 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: #41555a;
  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: #5d7176; font-style: italic; }
.sched-hint { margin: 0; font-size: 11.5px; font-weight: 600; color: #67797f; }
.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: #41555a;
  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: #41555a;
  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-chips { display: flex; gap: 7px; flex-wrap: wrap; }
.rem-chip {
  padding: 8px 13px; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(35,60,65,0.16); background: #fff; color: #41555a;
  font-size: 12px; font-weight: 600; font-family: inherit; transition: all 130ms ease;
}
.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: #2a4146; 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: #67797f; 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: #67797f; }
.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: #7a8c90; 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: #8a9a9e; }
.login-tag.on  { color: #2c8a5f; }
.login-tag.off { color: #aab6b9; }

/* 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: #7a8c90; }
.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: #95a4a8; }
.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: #4d6166; 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: #7e9196; }
.import-drop strong { font-size: 14px; color: var(--ink); }
.import-drop em { font-size: 11.5px; font-style: normal; color: #7a8c90; }
.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-paste-toggle { display: block; margin: 11px auto 4px; background: none; border: 0; color: #4d7d86; font-size: 12.5px; font-weight: 650; text-decoration: underline; cursor: pointer; font-family: inherit; }
.import-review-title { display: flex; align-items: center; }
.review-count { margin-left: auto; font-size: 11px; font-weight: 600; color: #8a9a9e; 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: #7a8c90; }
.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: #7a8c90; }
.field-type { flex: 0 0 auto; font-size: 10.5px; font-weight: 700; color: #4d6166; 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: #7a8c90; }
.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: #95a4a8; 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: #8a9a9e; }
.lead-add { width: 26px; height: 26px; border-radius: 50%; border: 1px dashed rgba(35,60,65,0.3); background: transparent; color: #5d7176; 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: #51656a; }

/* ============================================================
   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; }
.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: #46606a; 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: #6a7c81; }
.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: #95a4a8; }

/* ============================================================
   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: 700; letter-spacing: -0.005em; color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}
.meal-slot-section > summary::-webkit-details-marker { display: none; }
.meal-slot-name { flex: 1; }
.meal-slot-total { font-size: 13px; font-weight: 700; color: var(--accent-dark); }
.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(--accent-dark); }
.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: 16px; font-weight: 400; color: var(--ink); }
.mdr-sub { font-size: 12px; color: #7c8e93; }
.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: #95a4a8; 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: 16px; font-weight: 750; color: var(--ink); }
.meal-day-card > .meal-day-head span { font-size: 12px; color: #7c8e93; }

/* Interactive imported-recipe card (item 4) — reuses .recipe-modal shell. */
.recipe-modal.rc2 { max-width: 560px; 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: 21px; }
/* 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: #5d7176; 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: #7c8e93; }
.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; 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: #6f8389; }
.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: #6f8389; }
.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: #2a4146; }
.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: #6f8389; }
.rc2-body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 16px 18px 26px; }
.rc2-block-title { margin: 6px 0 10px; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-dark); }
.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: 13.5px; font-weight: 750; color: var(--ink); background: rgba(53,202,187,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: 750; color: var(--ink); }
.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: 15px; line-height: 1.5; color: #2f4348; }
.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: #43585d; display: flex; flex-direction: column; gap: 6px; line-height: 1.4; }
.rc2-empty { font-size: 13px; color: #95a4a8; font-style: italic; }
.rc2-import-result { margin-top: 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: #8295a0; }
.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: #7c8e93; }
.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: #95a4a8; }
.rec-lib-tag.has { color: var(--accent-dark); 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: #95a4a8; }
.rec-lib-empty { font-size: 13.5px; color: #7c8e93; 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-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 { text-align: center; padding: 30px 20px; display: flex; flex-direction: column; align-items: center; gap: 8px; border: 1px dashed rgba(35,60,65,0.18); border-radius: 18px; background: rgba(255,255,255,0.5); }
.meals-today-empty .meals-empty-spark { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: rgba(53,202,187,0.14); color: var(--accent-dark); }
.meals-today-empty strong { font-size: 16px; color: var(--ink); }
.meals-today-empty em { font-style: normal; font-size: 13px; color: #6f8389; max-width: 280px; }
.meals-today-empty .mp-bridge-btn { margin-top: 8px; }
.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; }
.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); }
