:root {
  --bg-primary: #FFFFFF;
  --bg-page: #F6F5F0;
  --bg-secondary: #F4F3ED;
  --bg-info: #DCEBFB;
  --text-primary: #111111;
  --text-secondary: #62625D;
  --text-tertiary: #868680;
  --text-info: #2F6DB5;
  --border: #DEDDD8;
  --border-strong: #CFCFCA;
  --pressed: rgba(0,0,0,0.045);
  --radius-md: 12px;
  --radius-lg: 16px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg-page);
  overflow-x: hidden;
}

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg-page);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.35;
  display: flex;
  justify-content: center;
  padding: 12px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

button,
input {
  color: var(--text-primary);
  font: inherit;
  min-width: 0;
}

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

button:active {
  transform: translateY(0.5px);
}

.phone-shell {
  width: min(100vw - 24px, 560px);
  height: min(100dvh - 24px, 920px);
  min-height: 560px;
  background: var(--bg-primary);
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 12px 36px rgba(0,0,0,0.06);
  max-width: 100%;
}

.icon-row {
  display: flex;
  justify-content: center;
  gap: clamp(12px, 5vw, 28px);
  padding: calc(env(safe-area-inset-top, 0px) + 6px) 12px 6px;
  border-bottom: 1px solid var(--border);
  min-height: calc(env(safe-area-inset-top, 0px) + 54px);
}

.icon-button {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--text-tertiary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border-radius: 999px;
}

.icon-button i {
  font-size: 21px;
}

.icon-button.active-look {
  color: var(--text-secondary);
}

.tabs {
  padding: 14px 16px 0;
}

.tabbar {
  display: flex;
  background: var(--bg-secondary);
  border-radius: 999px;
  padding: 4px;
  min-height: 52px;
  min-width: 0;
}

.tabbar button {
  flex: 1;
  min-width: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  padding: 9px 6px;
  font-size: 17px;
  line-height: 1.1;
}

.tabbar button.active {
  background: var(--bg-primary);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.screen {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px 16px calc(env(safe-area-inset-bottom, 0px) + 84px);
  scrollbar-color: #9B9B96 transparent;
  scrollbar-width: thin;
}

.search-wrap {
  position: relative;
  margin-bottom: 12px;
  min-width: 0;
}

.search-wrap i {
  position: absolute;
  top: 50%;
  left: 15px;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  font-size: 19px;
}

.search-wrap input {
  width: 100%;
  border: 0;
  border-radius: 999px;
  background: var(--bg-secondary);
  min-height: 50px;
  padding: 12px 14px 12px 44px;
  outline: none;
  font-size: 18px;
}

textarea,
select {
  width: 100%;
  border: 0.5px solid var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--bg-primary);
  color: var(--text-primary);
  font: inherit;
  padding: 12px 12px;
  outline: none;
  font-size: 17px;
}

textarea {
  min-height: 96px;
  resize: vertical;
}

.note-editor-label { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.note-block-editor { min-height: 120px; border: .5px solid var(--border-strong); border-radius: 12px; background: var(--bg-primary); padding: 12px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }
.note-block-editor:empty::before { content: attr(data-placeholder); color: var(--text-tertiary); }
.note-text-block { white-space: pre-wrap; }
.note-image-block { position: relative; display: block; width: min(66%, 100%); margin: 12px 0; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--bg-secondary); }
.note-image-block.small { width: min(33%, 180px); }
.note-image-block.medium { width: min(66%, 360px); }
.note-image-block.large { width: 100%; }
.note-image-block img { display: block; width: 100%; height: auto; min-height: 64px; object-fit: contain; }
.note-image-block figcaption { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 9px; color: var(--text-secondary); font-size: 12px; }
.note-image-block figcaption span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.note-image-actions { flex: 0 0 34px; min-height: 34px; }
.note-image-block button, .note-file-block button { border: 0; background: transparent; color: var(--text-secondary); }
.note-file-block { display: flex; align-items: center; gap: 8px; max-width: 100%; margin: 10px 0; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-secondary); padding: 10px; }
.note-file-block > button[data-media-open] { min-width: 0; flex: 1; overflow: hidden; color: var(--text-primary); text-align: left; text-overflow: ellipsis; white-space: nowrap; }
.note-attachment-sheet { position: absolute; right: 0; bottom: 0; left: 0; z-index: 101; display: grid; gap: 1px; border-radius: 18px 18px 0 0; background: var(--bg-primary); box-shadow: 0 -12px 32px rgba(16,24,40,.2); overflow: hidden; }
.note-attachment-sheet button { min-height: 52px; border: 0; background: var(--bg-primary); padding: 0 18px; color: var(--text-primary); text-align: left; font: inherit; }
.note-attachment-sheet button:last-of-type { color: var(--text-secondary); text-align: center; }
.note-inline-actions { position: sticky; bottom: 0; z-index: 3; display: flex; flex-wrap: wrap; gap: 7px; border-top: 1px solid var(--border); background: var(--bg-primary); padding: 12px; }
.note-inline-actions span { width: 100%; color: var(--text-secondary); font-size: 13px; }
.note-inline-actions button { min-height: 38px; border: 1px solid var(--border); border-radius: 9px; background: var(--bg-secondary); padding: 0 10px; }
.note-inline-actions [data-delete-block] { color: #B4232A; }

.task-block-editor { min-height: 120px; border: .5px solid var(--border-strong); border-radius: 12px; background: var(--bg-primary); padding: 12px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }
.task-block-editor:empty::before { content: attr(data-placeholder); color: var(--text-tertiary); }
.task-text-block { white-space: pre-wrap; }
.task-image-block { position: relative; display: block; width: min(66%, 100%); margin: 12px 0; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: var(--bg-secondary); }
.task-image-block.small { width: min(33%, 180px); }
.task-image-block.medium { width: min(66%, 360px); }
.task-image-block.large { width: 100%; }
.task-image-block img { display: block; width: 100%; height: auto; min-height: 64px; object-fit: contain; }
.task-image-block figcaption { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 9px; color: var(--text-secondary); font-size: 12px; }
.task-image-block figcaption span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-image-actions { flex: 0 0 34px; min-height: 34px; }
.task-image-block button, .task-file-block button { border: 0; background: transparent; color: var(--text-secondary); }
.task-file-block { display: flex; align-items: center; gap: 8px; max-width: 100%; margin: 10px 0; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-secondary); padding: 10px; }
.task-file-block > button[data-task-media-open] { min-width: 0; flex: 1; overflow: hidden; color: var(--text-primary); text-align: left; text-overflow: ellipsis; white-space: nowrap; }
.task-attachment-sheet { position: absolute; right: 0; bottom: 0; left: 0; z-index: 101; display: grid; gap: 1px; border-radius: 18px 18px 0 0; background: var(--bg-primary); box-shadow: 0 -12px 32px rgba(16,24,40,.2); overflow: hidden; }
.task-attachment-sheet button { min-height: 52px; border: 0; background: var(--bg-primary); padding: 0 18px; color: var(--text-primary); text-align: left; font: inherit; }
.task-attachment-sheet button:last-of-type { color: var(--text-secondary); text-align: center; }
.task-inline-actions { position: sticky; bottom: 0; z-index: 3; display: flex; flex-wrap: wrap; gap: 7px; border-top: 1px solid var(--border); background: var(--bg-primary); padding: 12px; }
.task-inline-actions span { width: 100%; color: var(--text-secondary); font-size: 13px; }
.task-inline-actions button { min-height: 38px; border: 1px solid var(--border); border-radius: 9px; background: var(--bg-secondary); padding: 0 10px; }
.task-inline-actions [data-delete-task-block] { color: #B4232A; }

.sort-button {
  width: 100%;
  border: 0;
  border-radius: var(--radius-lg);
  background: var(--bg-info);
  color: var(--text-info);
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 13px 18px;
  margin-bottom: 16px;
  text-align: left;
  font-size: 17px;
  min-width: 0;
}

.sort-button span:nth-child(2) {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pill {
  display: inline-block;
  border-radius: 999px;
  padding: 5px 11px;
  font-size: 15px;
  line-height: 1;
}

.accent-pill {
  background: var(--bg-primary);
  color: var(--text-info);
}

.block {
  margin-bottom: 18px;
}

h2 {
  font-size: 18px;
  line-height: 1.25;
  margin: 0 0 10px;
  font-weight: 700;
  letter-spacing: 0;
}

.pinned-list {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  max-width: 100%;
  padding-bottom: 2px;
}

.pinned-card {
  flex: 0 0 min(74%, 240px);
  min-width: 0;
  max-width: 280px;
  min-height: 94px;
  background: var(--bg-info);
  border-radius: var(--radius-lg);
  padding: 14px;
  color: var(--text-info);
  border: 0;
  text-align: left;
}

.pinned-card i {
  font-size: 16px;
}

.pinned-card div {
  margin-top: 10px;
  font-size: 16px;
  line-height: 1.3;
  display: -webkit-box;
  overflow: hidden;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.empty-line {
  color: var(--text-tertiary);
  font-size: 15px;
  padding: 4px 0;
}

.row-list {
  display: grid;
  min-width: 0;
  max-width: 100%;
}

.row-line {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  padding: 10px 2px;
  border-bottom: 1px solid var(--border);
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.row-line i {
  width: 24px;
  color: var(--text-secondary);
  font-size: 20px;
  text-align: center;
}

.row-line .row-title {
  flex: 1;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 18px;
  line-height: 1.25;
}

.row-line .row-meta {
  flex: 0 1 auto;
  min-width: 0;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  font-size: 13px;
  max-width: 34%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 16px 0 18px;
}

.metric {
  min-width: 0;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 12px 6px 11px;
  text-align: center;
  min-height: 76px;
}

.metric b {
  display: block;
  font-size: clamp(23px, 7vw, 30px);
  line-height: 1.1;
  font-weight: 700;
}

.metric span {
  display: block;
  margin-top: 3px;
  font-size: 14px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.folders-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
  max-width: 100%;
}

.folder-card {
  min-height: 116px;
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: 16px 14px;
  border: 0;
  text-align: left;
  cursor: pointer;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.folder-card-wrap {
  position: relative;
  min-width: 0;
}

.folder-card-wrap .folder-card {
  width: 100%;
  height: 100%;
}

.folder-rename {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--bg-primary);
  color: var(--text-secondary);
}

.folder-rename i {
  font-size: 16px;
}

.folder-card i {
  font-size: 23px;
  color: var(--text-secondary);
}

.folder-card .name {
  margin-top: 18px;
  font-size: 17px;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.folder-card .count {
  margin-top: 4px;
  font-size: 14px;
  color: var(--text-tertiary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 720px) {
  body {
    padding: 0;
    background: var(--bg-primary);
  }

  .phone-shell {
    width: 100vw;
    height: 100dvh;
    min-height: 100dvh;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    max-width: 100vw;
  }
}

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

@media (max-width: 360px) {
  body {
    font-size: 16px;
  }

  .screen {
    padding-left: 12px;
    padding-right: 12px;
  }

  .tabbar button {
    font-size: 16px;
  }

  .row-line .row-meta {
    display: none;
  }

  .metric span {
    font-size: 12px;
  }
}

.floating-add {
  position: absolute;
  right: 18px;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 18px);
  width: 56px;
  height: 56px;
  border: 0;
  border-radius: 999px;
  background: var(--text-info);
  color: var(--bg-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  box-shadow: 0 8px 22px rgba(47,109,181,0.28);
}

.phone-shell {
  position: relative;
}

#overlay {
  position: absolute;
  inset: 0;
  z-index: 100;
  pointer-events: none;
}

.sheet-bg {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: flex-end;
  pointer-events: auto;
}

.sheet {
  width: 100%;
  max-width: 100%;
  max-height: 92dvh;
  overflow-y: auto;
  background: var(--bg-primary);
  border-radius: 20px 20px 0 0;
  border: 0.5px solid var(--border);
  padding: 16px;
}

.handle {
  width: 36px;
  height: 4px;
  background: var(--border-strong);
  border-radius: 2px;
  margin: 0 auto 14px;
}

.sheet-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.sheet-title-input {
  flex: 1;
  min-width: 0;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--text-primary);
  font: inherit;
  font-weight: 700;
  outline: none;
}

.quick-save-button {
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 12px;
  background: var(--text-info);
  color: #FFFFFF;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  transition: opacity 120ms ease, transform 120ms ease, background 120ms ease;
}

.quick-save-button.dirty {
  opacity: 1;
  transform: scale(1.03);
}

.quick-save-button.saving {
  opacity: 0.45;
}

.quick-save-button.saved {
  opacity: 0.7;
}

.quick-save-button.error {
  background: #B94A48;
  opacity: 1;
}

.sheet-actions,
.type-row,
.icon-picker,
.form-row,
.bulk-bar,
.task-input-row {
  display: flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.sheet-icon-button,
.round-check {
  width: 42px;
  height: 42px;
  border: 0;
  background: transparent;
  color: var(--text-tertiary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
}

.sheet-icon-button.active,
.type-button.active,
.icon-choice.active {
  color: var(--text-info);
  background: var(--bg-info);
}

.type-button,
.icon-choice {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-tertiary);
}

.field {
  margin-top: 12px;
}

.field label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-tertiary);
  font-size: 14px;
}

.readonly-box {
  background: var(--bg-secondary);
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  padding: 12px 12px;
  font-style: italic;
  line-height: 1.35;
  font-size: 16px;
}

.primary-button,
.secondary-button,
.danger-button {
  flex: 1;
  border-radius: var(--radius-md);
  min-height: 48px;
  padding: 12px 12px;
  font-size: 16px;
}

.primary-button {
  border: 0;
  background: var(--text-info);
  color: var(--bg-primary);
}

.secondary-button {
  border: 0.5px solid var(--border-strong);
  background: var(--bg-primary);
}

.danger-button {
  border: 0.5px solid var(--border-strong);
  background: var(--bg-primary);
  color: var(--text-secondary);
}

.crumbs {
  display: flex;
  gap: 6px;
  align-items: center;
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 14px;
  flex-wrap: wrap;
  min-width: 0;
  overflow-wrap: anywhere;
}

.crumbs button {
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
}

.bulk-bar {
  justify-content: space-between;
  margin-bottom: 8px;
}

.bulk-bar button,
.compact-button {
  border: 0.5px solid var(--border-strong);
  background: var(--bg-primary);
  border-radius: var(--radius-md);
  min-height: 40px;
  padding: 8px 11px;
  font-size: 15px;
}

.round-check {
  border: 0.5px solid var(--border-strong);
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
}

.round-check.done {
  background: var(--bg-info);
  color: var(--text-info);
  border-color: transparent;
}

.task-section-title {
  color: var(--text-secondary);
  font-size: 15px;
  margin: 14px 0 6px;
}

.progress-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.progress-bar {
  flex: 1;
  height: 6px;
  background: var(--bg-secondary);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--text-info);
}

.progress-label {
  color: var(--text-secondary);
  font-size: 15px;
}

.done-text {
  color: var(--text-tertiary);
  text-decoration: line-through;
}

.topic-card {
  background: var(--bg-secondary);
  border: 0;
  border-radius: var(--radius-lg);
  padding: 16px 14px;
  min-height: 82px;
  text-align: left;
  min-width: 0;
  overflow: hidden;
}

.topic-card .count,
.topic-card i {
  color: var(--text-tertiary);
  font-size: 14px;
}

.auth-empty {
  color: var(--text-tertiary);
  font-size: 15px;
  line-height: 1.4;
}

.tag-chip-group + .tag-chip-group { margin-top: 10px; }
.tag-chip-label { margin-bottom: 6px; color: var(--text-tertiary); font-size: 12px; }
.tag-chip-list { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-chip { min-height: 32px; padding: 6px 11px; border: 1px solid var(--tag-color); border-radius: 999px; background: transparent; color: var(--tag-color); font-size: 14px; }
.tag-chip.selected { background: var(--tag-color); color: #fff; }
.tag-chip.custom-tag { border-style: dashed; }
.tag-add-button { margin-top: 10px; }
.tag-add-form { margin-top: 8px; }

.tag-section-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tag-section-title label { margin: 0; }
.tag-plus-button { width: 30px; height: 30px; border: 1px solid var(--border-strong); border-radius: 10px; background: var(--bg-primary); color: var(--text-info); font-size: 20px; line-height: 1; }
.tag-plus-button:disabled { opacity: 0.4; }
.tag-empty { color: var(--text-tertiary); font-size: 13px; }
.tag-custom-area { margin-top: 10px; }

.section-header,
.recent-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.section-header h2 { margin: 0; }
.expand-button { border: 0.5px solid rgba(47, 109, 181, 0.18); background: var(--bg-info); color: var(--text-info); min-width: 68px; height: 34px; border-radius: 999px; padding: 0 11px; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-weight: 700; }
.expand-button i { font-size: 17px; }
.note-card-list { display: grid; gap: 10px; }
.note-card { width: 100%; border: 0.5px solid var(--border-strong); border-radius: var(--radius-lg); background: var(--bg-primary); padding: 14px; overflow: hidden; cursor: pointer; }
.note-card-main { display: flex; align-items: flex-start; gap: 12px; min-width: 0; }
.note-card-icon { display: grid; place-items: center; flex: 0 0 38px; width: 38px; height: 38px; border-radius: 12px; background: var(--bg-secondary); color: var(--text-secondary); font-size: 19px; }
.note-card-body { flex: 1; min-width: 0; }
.note-card-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; min-width: 0; }
.note-card-title-row > div:first-child { min-width: 0; }
.note-card-title { color: var(--text-primary); font-size: 16px; font-weight: 650; line-height: 1.25; overflow-wrap: anywhere; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
.note-card-category { margin-top: 3px; color: var(--text-tertiary); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.note-card-actions { display: flex; flex: 0 0 auto; gap: 4px; }
.note-card-action { display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 10px; background: transparent; color: var(--text-tertiary); font-size: 18px; }
.note-card-action.active { font-weight: 700; }
.note-card-action.favorite.active,
.sheet-icon-button.favorite.active { color: #F5B301; background: rgba(245, 179, 1, 0.12); }
.note-card-action.pin.active,
.sheet-icon-button.pin.active { color: #E5484D; background: rgba(229, 72, 77, 0.12); }
.note-card-action.delete,
.sheet-icon-button.delete { color: #B4232A; }
.note-card-action.delete:active,
.sheet-icon-button.delete:active { background: rgba(180, 35, 42, 0.12); }
.note-card-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; min-width: 0; }
.note-card-tag { max-width: 100%; border-radius: 999px; background: var(--bg-secondary); color: var(--text-secondary); padding: 3px 8px; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.note-card-preview { display: -webkit-box; margin-top: 9px; color: var(--text-secondary); font-size: 14px; line-height: 1.35; overflow: hidden; overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; }
.confirm-bg { align-items: center; justify-content: center; padding: 18px; }
.confirm-dialog { width: min(100%, 320px); background: var(--bg-primary); border: 0.5px solid var(--border); border-radius: 18px; padding: 18px; box-shadow: 0 18px 42px rgba(0,0,0,0.18); text-align: center; }
.confirm-icon { width: 46px; height: 46px; border-radius: 14px; margin: 0 auto 12px; display: grid; place-items: center; background: rgba(180, 35, 42, 0.1); color: #B4232A; font-size: 23px; }
.confirm-title { font-size: 19px; line-height: 1.2; font-weight: 750; }
.confirm-text { margin-top: 7px; color: var(--text-secondary); font-size: 14px; line-height: 1.35; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow-wrap: anywhere; }
.confirm-actions { display: flex; justify-content: center; gap: 12px; margin-top: 18px; }
.confirm-button { width: 54px; height: 44px; border: 0; border-radius: 13px; display: grid; place-items: center; font-size: 23px; }
.confirm-button.cancel { background: var(--bg-secondary); color: var(--text-secondary); }
.confirm-button.danger { background: #D92D20; color: #FFFFFF; box-shadow: 0 8px 18px rgba(217, 45, 32, 0.28); }

@media (max-width: 420px) {
  .note-card { padding: 12px; }
  .note-card-main { gap: 9px; }
  .note-card-icon { flex-basis: 34px; width: 34px; height: 34px; }
  .note-card-action { width: 30px; height: 32px; }
  .note-card-actions { gap: 2px; }
}

.moment-composer { display: grid; gap: 9px; padding: 12px; margin-bottom: 18px; border: 1px solid var(--border); border-radius: 18px; background: var(--bg-secondary); }
.moment-composer textarea { min-height: 78px; resize: vertical; }
.moment-attachment-preview { display: grid; gap: 8px; }
.moment-attachment-preview:empty { display: none; }
.moment-attachment-card { display: grid; grid-template-columns: 42px minmax(0, 1fr) 34px; align-items: center; gap: 9px; min-height: 50px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-primary); padding: 7px; }
.moment-attachment-card span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.moment-attachment-card > button { display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 9px; background: transparent; color: var(--text-secondary); }
.moment-attachment-image img { width: 42px; height: 36px; border-radius: 8px; object-fit: cover; }
.moment-attachment-file > i { display: grid; place-items: center; width: 42px; height: 36px; border-radius: 8px; background: var(--bg-secondary); color: var(--text-info); }
.moment-attachment-sheet { display: grid; gap: 1px; padding: 0; overflow: hidden; }
.moment-attachment-sheet > button { display: flex; align-items: center; gap: 12px; min-height: 54px; border: 0; background: var(--bg-primary); padding: 0 18px; color: var(--text-primary); text-align: left; font: inherit; }
.moment-attachment-sheet > button:last-child { justify-content: center; color: var(--text-secondary); }
.moment-topic-select { display: block; border-radius: 13px; }
.moment-topic-select.error { outline: 2px solid #E5484D; }
.moment-topic-error { min-height: 0; color: #E5484D; font-size: 13px; }
.moment-link-input, .emoji-search, #moment-topic-name { width: 100%; min-height: 44px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-primary); padding: 10px 12px; }
.moment-composer-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.moment-format-toolbar { display: flex; gap: 6px; }
.moment-format-toolbar button { width: 40px; height: 40px; border: 0; border-radius: 10px; background: var(--bg-primary); }
.moment-composer-primary-actions { display: flex; align-items: center; gap: 7px; }
.moment-attachment-add, .moment-voice-button { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--bg-primary); color: var(--text-secondary); font-size: 19px; }
.moment-send-button { display: grid; place-items: center; width: 46px; height: 46px; border: 0; border-radius: 50%; background: #2F80ED; color: #fff; font-size: 21px; }
.moment-send-button:disabled { opacity: .5; }
.moment-topic-list { display: grid; gap: 10px; }
.moment-topic-card { display: flex; align-items: flex-start; gap: 11px; min-width: 0; padding: 13px; border: 1px solid var(--border); border-radius: 16px; background: var(--bg-primary); }
.moment-topic-emoji { flex: 0 0 auto; font-size: 27px; }
.moment-topic-emoji-button { width: 42px; height: 42px; border: 0; border-radius: 12px; background: var(--bg-secondary); padding: 0; }
.moment-topic-body { flex: 1; min-width: 0; }
.moment-topic-title { font-weight: 700; overflow-wrap: anywhere; }
.moment-topic-preview { display: -webkit-box; margin-top: 3px; overflow: hidden; overflow-wrap: anywhere; color: var(--text-secondary); font-size: 14px; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
.moment-topic-meta { margin-top: 5px; color: var(--text-tertiary); font-size: 12px; }
.moment-topic-pin { flex: 0 0 38px; width: 38px; height: 38px; border: 0; border-radius: 11px; background: transparent; color: var(--text-tertiary); }
.moment-topic-pin.active { color: #E5484D; background: rgba(229, 72, 77, 0.12); }
.moment-topic-screen { min-height: 100%; display: flex; flex-direction: column; }
.moment-topic-header { position: sticky; top: -14px; z-index: 2; display: flex; align-items: center; gap: 7px; padding: 8px 0 12px; background: var(--bg-primary); }
.moment-topic-header h2 { flex: 1; min-width: 0; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.moment-topic-heading { flex: 1; min-width: 0; }
.moment-topic-heading h2 { margin: 0; }
.moment-topic-count { color: var(--text-tertiary); font-size: 12px; }
.moment-search-panel { display: grid; grid-template-columns: 1fr auto 42px 42px; gap: 7px; margin-bottom: 8px; }
.moment-search-panel input { min-width: 0; min-height: 42px; border: 1px solid var(--border); border-radius: 11px; padding: 8px 10px; }
.moment-search-panel button { border: 0; border-radius: 11px; background: var(--bg-secondary); }
.moment-pinned-bar { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; padding: 7px 4px 7px 10px; border-left: 3px solid #2F80ED; background: #F0F6FC; cursor: pointer; }
.moment-pinned-bar > div { flex: 1; min-width: 0; }
.moment-pinned-bar b, .moment-pinned-bar span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.moment-pinned-bar b { color: #2F80ED; font-size: 12px; }
.moment-pinned-bar span { font-size: 13px; }
.moment-pinned-bar button { width: 38px; height: 38px; border: 0; background: transparent; color: var(--text-tertiary); }
.moment-chat { flex: 1; display: flex; flex-direction: column; gap: 9px; min-height: 240px; overflow-y: auto; padding: 10px 0 14px; }
.moment-date-divider { align-self: center; position: sticky; top: 4px; z-index: 1; margin: 5px 0; padding: 5px 12px; border-radius: 999px; background: #E6EEF5; color: #40566A; font-size: 12px; font-weight: 700; }
.moment-message-row { align-self: flex-end; display: flex; align-items: center; justify-content: flex-end; max-width: 94%; }
.moment-message-menu { flex: 0 0 30px; width: 30px; height: 42px; border: 0; border-radius: 10px; background: transparent; color: var(--text-tertiary); font-size: 21px; }
.moment-message-menu:active { background: rgba(229, 72, 77, 0.10); }
.moment-message { position: relative; width: fit-content; max-width: calc(100% - 30px); min-width: 90px; padding: 10px 12px 7px; border-radius: 17px 17px 4px 17px; background: #DCF8C6; overflow-wrap: anywhere; transition: box-shadow .25s ease, background .25s ease; }
.moment-message.pinned { box-shadow: inset 3px 0 #E5484D; }
.moment-message-pin { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; border: 0; border-radius: 9px; background: transparent; color: var(--text-tertiary); }
.moment-message-pin.active { color: #E5484D; background: rgba(229, 72, 77, 0.12); }
.moment-message-highlight { background: #FFF1A8; box-shadow: 0 0 0 3px rgba(47, 128, 237, .35); }
.moment-entry-actions { display: grid; gap: 4px; }
.moment-entry-actions > button { display: flex; align-items: center; gap: 12px; min-height: 48px; border: 0; border-radius: 12px; background: transparent; padding: 10px 12px; text-align: left; }
.moment-entry-actions > button:active { background: var(--bg-secondary); }
.moment-entry-actions > button i { width: 24px; font-size: 21px; }
.moment-entry-actions > button.danger { color: #B4232A; }
.moment-entry-edit-save { display: grid; place-items: center; width: 52px; margin: 12px 0 0 auto; font-size: 23px; }
.moment-message-text { white-space: normal; line-height: 1.4; }
.moment-message-text code { padding: 1px 4px; border-radius: 5px; background: rgba(0,0,0,.08); }
.moment-message-media { display: block; max-width: 100%; margin-top: 8px; }
.moment-message-image { margin: 8px 0 0; overflow: hidden; border-radius: 11px; background: rgba(0,0,0,.06); }
.moment-message-image img { display: block; width: min(100%, 360px); max-height: 360px; object-fit: contain; }
.moment-message-file { display: flex; align-items: center; gap: 9px; width: 100%; border: 1px solid rgba(0,0,0,.1); border-radius: 11px; background: rgba(255,255,255,.46); padding: 10px; color: var(--text-primary); text-align: left; font: inherit; }
.moment-message-file span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.moment-message-link { display: block; max-width: 100%; margin-top: 7px; color: #2467A6; font-size: 13px; overflow-wrap: anywhere; }
.moment-message-time { display: block; margin-top: 5px; color: #777; font-size: 11px; text-align: right; }
.moment-bottom-composer { position: sticky; bottom: 0; z-index: 2; margin-top: auto; padding-top: 8px; padding-bottom: env(safe-area-inset-bottom, 0px); background: var(--bg-primary); }
.moment-bottom-composer .moment-composer { margin-bottom: 0; }
.emoji-choice { min-height: 48px; margin: 12px 0; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-secondary); padding: 9px 12px; }
.emoji-choice span { margin-right: 8px; font-size: 25px; }
.moment-topic-editor-actions { display: flex; gap: 10px; margin-top: 14px; }
.moment-topic-editor-actions .danger-button { flex: 0 0 52px; color: #B4232A; }
.moment-topic-save { flex: 0 0 52px; margin-left: auto; font-size: 23px; }
.emoji-picker { display: flex; flex-direction: column; min-height: min(72dvh, 620px); }
.emoji-search { margin-bottom: 10px; }
.emoji-category-tabs { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 9px; }
.emoji-category { flex: 0 0 auto; min-height: 36px; border: 0; border-radius: 999px; background: var(--bg-secondary); padding: 7px 11px; font-size: 13px; }
.emoji-category.active { background: var(--bg-info); color: var(--text-info); }
.emoji-grid { display: grid; grid-template-columns: repeat(7, minmax(36px, 1fr)); gap: 5px; overflow-y: auto; }
.emoji-button { aspect-ratio: 1; min-width: 0; border: 0; border-radius: 10px; background: transparent; font-size: 26px; }
.emoji-button.active, .emoji-button:active { background: var(--bg-secondary); }

@media (max-width: 380px) {
  .emoji-grid { grid-template-columns: repeat(6, minmax(36px, 1fr)); }
  .moment-message-row { max-width: 98%; }
}

/* Readable task card and compact, extensible authorship. */
.task-editor-header { grid-template-columns: 42px minmax(0,1fr) 42px 42px; }
.task-editor-title-preview { min-width: 0; overflow: hidden; color: var(--text-secondary); font-size: 14px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.task-editor-main-text { width: 100%; min-height: 104px; resize: vertical; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 12px 4px 14px; color: var(--text-primary); font: inherit; font-size: 19px; font-weight: 650; line-height: 1.42; outline: none; }
.task-editor-sheet.done .task-editor-main-text { color: var(--text-tertiary); text-decoration: line-through; }
.task-editor-description-optional { display: grid; gap: 7px; padding: 12px 0 4px; }
.task-editor-description-optional label { color: var(--text-tertiary); font-size: 12px; font-weight: 650; }
.task-editor-description-optional textarea { width: 100%; min-height: 78px; resize: vertical; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-secondary); padding: 10px 11px; color: var(--text-primary); font: inherit; line-height: 1.4; }
.task-editor-add-description { min-height: 44px; border: 0; background: transparent; padding: 8px 4px; color: #2F80ED; text-align: left; }
.task-editor-description-hint { display: none; }
.task-editor-menu-wrap { position: relative; }
.task-editor-menu { display: grid; place-items: center; width: 42px; height: 42px; border: 0; border-radius: 12px; background: transparent; color: var(--text-secondary); font-size: 20px; }
.task-editor-menu-popover { position: absolute; z-index: 8; top: 40px; right: 0; width: 184px; overflow: hidden; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-primary); box-shadow: 0 10px 28px rgba(0,0,0,.16); }
.task-editor-menu-popover button { display: block; width: 100%; min-height: 44px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 9px 12px; color: var(--text-primary); text-align: left; }
.task-editor-menu-popover button:last-child { border-bottom: 0; }
.task-editor-archived-badge, .task-editor-done-badge { display: inline-flex; align-items: center; gap: 5px; width: fit-content; margin: 2px 0 7px; border-radius: 999px; background: var(--bg-secondary); padding: 5px 8px; color: var(--text-tertiary); font-size: 11px; }
.task-row.archived { color: var(--text-tertiary); opacity: .82; }
.task-row.done .task-meta, .task-row.done .task-tags, .task-row.done .task-subtasks-progress { color: var(--text-tertiary); }
.author-badge { --author-color: var(--text-tertiary); display: inline-flex; align-items: center; width: fit-content; margin-top: 5px; border-radius: 999px; background: color-mix(in srgb, var(--author-color) 12%, transparent); padding: 3px 7px; color: var(--author-color); font-size: 10px; font-weight: 650; line-height: 1.2; }
.author-badge.user { --author-color: #3C8C62; }
.author-badge.tanya { --author-color: #2878D0; }
.author-badge.borya { --author-color: #B66A18; }
.author-badge.timur { --author-color: #7656B5; }
.author-badge.agent { --author-color: #667085; }

@media (max-width: 380px) {
  .task-editor-header { grid-template-columns: 38px minmax(0,1fr) 38px 38px; gap: 4px; }
}

/* Compact task category tree and colored tag picker. */
.task-picker-section-title { margin: 12px 0 7px; color: var(--text-tertiary); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.task-picker-frequent { display: grid; gap: 2px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.task-picker-frequent > button { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; min-height: 42px; border: 0; border-radius: 10px; background: transparent; padding: 7px 9px; color: var(--text-primary); text-align: left; }
.task-picker-frequent > button.selected { background: var(--bg-info); color: var(--text-info); }
.task-picker-frequent > button span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-picker-frequent > button b { color: var(--text-tertiary); font-size: 11px; }
.task-category-tree { display: grid; }
.task-category-tree-node { min-width: 0; }
.task-category-tree-row { display: grid; grid-template-columns: minmax(0,1fr) 42px; align-items: center; min-height: 44px; border-bottom: 1px solid var(--border); padding-left: calc(var(--task-tree-depth,0) * 16px); }
.task-category-tree-row.selected { border-radius: 10px; background: var(--bg-info); color: var(--text-info); }
.task-category-tree-row > button:first-child { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 8px; min-height: 44px; border: 0; background: transparent; padding: 7px 5px; color: inherit; text-align: left; }
.task-category-tree-row > button:first-child span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-category-tree-row > button:first-child b { color: var(--text-tertiary); font-size: 11px; }
.task-category-tree-toggle { display: grid; place-items: center; width: 42px; height: 42px; border: 0; border-radius: 10px; background: transparent; color: var(--text-tertiary); }
.task-category-tree-spacer { width: 42px; }
.task-picker-tag-section { margin-bottom: 9px; }
.task-picker-tag { min-height: 36px; border: 1px solid var(--tag-color); border-radius: 999px; background: color-mix(in srgb, var(--tag-color) 9%, transparent); padding: 6px 10px; color: var(--tag-color); }
.task-picker-tag.selected { background: var(--tag-color); color: #fff; box-shadow: 0 0 0 2px color-mix(in srgb, var(--tag-color) 22%, transparent); }
.task-create-tag-toggle { min-height: 42px; border: 0; background: transparent; padding: 8px 2px; color: #2F80ED; font-weight: 650; text-align: left; }
.task-tag-create-form { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; align-items: center; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-secondary); padding: 9px; }
.task-tag-create-form input { grid-column: 1 / -1; min-height: 42px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-primary); padding: 8px 10px; color: var(--text-primary); }
.task-tag-color-palette { display: flex; flex-wrap: wrap; gap: 7px; }
.task-tag-color-choice { width: 34px; height: 34px; border: 2px solid transparent; border-radius: 50%; background: var(--tag-color); }
.task-tag-color-choice.selected { border-color: var(--text-primary); box-shadow: 0 0 0 2px var(--bg-primary) inset; }
.task-tag-create-form > button:last-child { min-height: 40px; border: 0; border-radius: 10px; background: #2F80ED; padding: 7px 12px; color: #fff; }
.task-picker-error { min-height: 17px; color: #B4232A; font-size: 11px; }

@media (max-width: 440px) {
  .moment-search-panel { grid-template-columns: 1fr 42px 42px; }
  .moment-search-panel input[type="date"] { grid-column: 1 / -1; grid-row: 2; }
}

/* Tasks: dense TickTick-like shell, scoped to the Tasks tab. */
.tasks-shell { position: relative; min-height: 100%; padding-bottom: 18px; }
.tasks-header { position: sticky; top: -14px; z-index: 4; display: flex; align-items: center; gap: 10px; margin: -4px -2px 0; padding: 8px 2px 6px; background: var(--bg-primary); }
.tasks-menu-button, .tasks-search-button { flex: 0 0 44px; width: 44px; height: 44px; border: 0; border-radius: 13px; background: transparent; color: var(--text-secondary); font-size: 22px; }
.tasks-heading { flex: 1; min-width: 0; }
.tasks-heading h1 { margin: 0; font-size: 23px; line-height: 1.1; letter-spacing: -0.02em; }
.tasks-date-subtitle { margin-top: 3px; color: var(--text-tertiary); font-size: 13px; text-transform: capitalize; }
.tasks-summary { margin: 2px 0 12px 54px; color: var(--text-secondary); font-size: 13px; }
.tasks-search { display: none; margin: 0 0 10px; }
.tasks-search.open { display: block; }
.tasks-search input { width: 100%; height: 42px; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-secondary); padding: 0 12px; }
.tasks-view-toggle { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; margin-bottom: 11px; border-radius: 11px; background: var(--bg-secondary); padding: 3px; }
.tasks-view-toggle button { min-height: 38px; border: 0; border-radius: 9px; background: transparent; color: var(--text-secondary); font-size: 14px; font-weight: 650; }
.tasks-view-toggle button.active { background: var(--bg-primary); color: var(--text-primary); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.task-add-placeholder { display: flex; align-items: center; gap: 9px; width: 100%; min-height: 45px; margin-bottom: 10px; border: 0; border-radius: 11px; background: #F3F8F2; padding: 0 12px; color: #347A3B; text-align: left; }
.task-add-placeholder i { font-size: 20px; }
.tasks-content { min-width: 0; }
.tasks-calendar-placeholder { display: grid; place-items: center; gap: 10px; min-height: 230px; color: var(--text-tertiary); text-align: center; }
.tasks-calendar-placeholder i { font-size: 34px; }
.tasks-sidebar-backdrop { position: absolute; inset: -14px; z-index: 19; display: none; border: 0; background: rgba(17,17,17,.28); }
.tasks-sidebar-backdrop.open { display: block; }
.tasks-sidebar { position: absolute; top: -14px; bottom: -18px; left: -14px; z-index: 20; width: min(82vw, 310px); border-right: 1px solid var(--border); border-radius: 0 18px 18px 0; background: var(--bg-primary); padding: max(14px, env(safe-area-inset-top)) 10px 16px; box-shadow: 14px 0 34px rgba(0,0,0,.15); transform: translateX(calc(-100% - 18px)); transition: transform .2s ease; }
.tasks-sidebar.open { transform: translateX(0); }
.tasks-sidebar-head { display: flex; align-items: center; justify-content: space-between; min-height: 46px; padding: 0 8px 8px 12px; font-size: 20px; }
.tasks-sidebar-close { width: 42px; height: 42px; border: 0; border-radius: 12px; background: transparent; color: var(--text-secondary); font-size: 21px; }
.tasks-sidebar nav { display: grid; gap: 2px; }
.tasks-sidebar-section { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 9px; min-height: 46px; border: 0; border-radius: 12px; background: transparent; padding: 0 11px; text-align: left; }
.tasks-sidebar-section i { color: var(--text-tertiary); font-size: 20px; }
.tasks-sidebar-section.active { background: var(--bg-info); color: var(--text-info); }
.tasks-sidebar-section.active i { color: var(--text-info); }
.tasks-sidebar-count { min-width: 24px; color: var(--text-tertiary); font-size: 13px; text-align: right; }
.task-group { border-top: 1px solid var(--border); }
.task-group:first-child { border-top: 0; }
.task-group-header { display: flex; align-items: center; width: 100%; min-height: 43px; border: 0; background: transparent; padding: 0 4px; text-align: left; }
.task-group-title { font-weight: 750; }
.task-group-count { margin-left: 7px; color: var(--text-tertiary); font-size: 13px; font-weight: 650; }
.task-group-header i { margin-left: auto; color: var(--text-tertiary); }
.task-group-list { min-width: 0; }
.task-empty { padding: 14px 4px 18px; color: var(--text-tertiary); font-size: 14px; }
.task-row { display: grid; grid-template-columns: 38px 8px minmax(0,1fr) auto; align-items: start; gap: 8px; min-height: 64px; border-top: 1px solid var(--border); padding: 10px 2px; transition: background .16s ease; }
.task-row:first-child { border-top-color: transparent; }
.task-row.done { color: var(--text-tertiary); }
.task-row.done .task-title { text-decoration: line-through; }
.task-row-tapped { background: var(--pressed); }
.task-checkbox { display: grid; place-items: center; width: 34px; height: 34px; margin-top: 1px; border: 1.5px solid var(--border-strong); border-radius: 50%; background: var(--bg-primary); color: #fff; }
.task-checkbox.checked { border-color: #8B8B85; background: #8B8B85; }
.task-checkbox:disabled { border-color: var(--border); background: var(--bg-secondary); color: var(--text-tertiary); cursor: default; }
.task-priority { width: 4px; height: 30px; margin-top: 3px; border-radius: 999px; background: #C9C9C4; }
.task-priority.critical { background: #D92D20; }
.task-priority.high { background: #E69A22; }
.task-priority.medium { background: #2F80ED; }
.task-priority.none { background: #C9C9C4; }
.task-main { min-width: 0; }
.task-title { overflow: hidden; font-size: 15px; font-weight: 680; line-height: 1.3; text-overflow: ellipsis; white-space: nowrap; }
.task-meta { margin-top: 4px; overflow: hidden; color: var(--text-secondary); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.task-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.task-tag { border-radius: 999px; background: var(--bg-secondary); padding: 2px 6px; color: var(--text-secondary); font-size: 11px; }
.task-date { min-width: 72px; padding-left: 4px; text-align: right; }
.task-date b, .task-date span { display: block; white-space: nowrap; }
.task-date b { font-size: 12px; }
.task-date span { margin-top: 3px; font-size: 11px; }
.task-date.overdue { color: #D92D20; }
.task-date.today { color: #347A3B; }
.task-date.upcoming { color: #2F6DB5; }
.task-date.no-date { color: var(--text-tertiary); }
.task-date.done, .task-date.archived { color: var(--text-tertiary); }
.task-subtasks-progress { margin-top: 5px; color: var(--text-tertiary); font-size: 11px; }
.task-filter-list { display: grid; gap: 3px; }
.task-filter-list button { display: flex; align-items: center; gap: 10px; min-height: 46px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 0 8px 0 calc(8px + var(--task-filter-depth, 0) * 18px); text-align: left; }

@media (max-width: 380px) {
  .task-row { grid-template-columns: 36px 7px minmax(0,1fr); }
  .task-date { grid-column: 3; display: flex; gap: 6px; padding: 4px 0 0; text-align: left; }
  .task-date span { margin-top: 0; }
}

.task-quick-add { margin-bottom: 12px; border: 1px solid #CFE2CF; border-radius: 14px; background: #F8FBF7; padding: 10px; }
.task-quick-add > input { width: 100%; min-height: 44px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 6px 4px; font-size: 16px; outline: none; }
.task-quick-error { min-height: 17px; padding: 3px 4px 0; color: #D92D20; font-size: 12px; }
.task-quick-actions { display: flex; align-items: center; gap: 6px; overflow-x: auto; padding-top: 7px; scrollbar-width: none; }
.task-quick-actions::-webkit-scrollbar { display: none; }
.task-quick-actions button { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 5px; min-height: 38px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-primary); padding: 7px 9px; color: var(--text-secondary); font-size: 12px; }
.task-quick-actions .task-quick-save { margin-left: auto; border-color: #347A3B; background: #347A3B; color: #fff; }
.task-quick-priority { width: 8px; height: 8px; border-radius: 50%; background: #C9C9C4; }
.task-quick-priority.critical { background: #D92D20; }
.task-quick-priority.high { background: #E69A22; }
.task-quick-priority.medium { background: #2F80ED; }
.task-scheduler-sheet { max-height: min(88dvh, 760px); overflow-y: auto; }
.task-scheduler-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; margin-bottom: 12px; border-radius: 12px; background: var(--bg-secondary); padding: 3px; }
.task-scheduler-tabs button { min-height: 42px; border: 0; border-radius: 10px; background: transparent; color: var(--text-secondary); font-size: 13px; font-weight: 700; }
.task-scheduler-tabs button.active { background: var(--bg-primary); color: var(--text-primary); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.task-scheduler-presets { display: flex; gap: 7px; overflow-x: auto; margin-bottom: 12px; padding-bottom: 2px; }
.task-scheduler-presets button { flex: 0 0 auto; min-height: 38px; border: 1px solid var(--border); border-radius: 999px; background: var(--bg-primary); padding: 7px 12px; font-size: 12px; }
.task-calendar { border: 1px solid var(--border); border-radius: 15px; padding: 10px; }
.task-calendar-head { display: grid; grid-template-columns: 40px 1fr 40px 40px; align-items: center; margin-bottom: 6px; }
.task-calendar-head b { text-align: center; text-transform: capitalize; }
.task-calendar-head button { width: 38px; height: 38px; border: 0; border-radius: 10px; background: transparent; }
.task-calendar-weekdays, .task-calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.task-calendar-weekdays span { padding: 5px 0; color: var(--text-tertiary); font-size: 11px; font-weight: 700; text-align: center; }
.task-calendar-day { aspect-ratio: 1; min-height: 36px; border: 0; border-radius: 50%; background: transparent; font-size: 13px; }
.task-calendar-day.outside { color: #B4B4AF; }
.task-calendar-day.selected { background: #2F80ED; color: #fff; font-weight: 750; }
.task-scheduler-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; border-bottom: 1px solid var(--border); }
.task-scheduler-row select { max-width: 58%; border: 0; background: transparent; color: var(--text-secondary); text-align: right; }
.task-manual-time { display: none; width: 100%; min-height: 42px; border: 1px solid var(--border); border-radius: 10px; padding: 7px 10px; }
.task-manual-time.open { display: block; }
.task-period-fields { display: grid; gap: 12px; }
.task-period-fields label { display: grid; gap: 6px; color: var(--text-secondary); font-size: 13px; }
.task-period-fields input { min-height: 46px; border: 1px solid var(--border); border-radius: 11px; background: var(--bg-primary); padding: 8px 10px; }
.task-scheduler-error { min-height: 20px; padding: 7px 2px 0; color: #D92D20; font-size: 12px; }
.task-scheduler-buttons { display: flex; justify-content: flex-end; gap: 9px; margin-top: 8px; }
.task-scheduler-buttons button { min-width: 92px; min-height: 44px; border: 0; border-radius: 11px; background: var(--bg-secondary); }
.task-scheduler-buttons button.primary { background: #2F80ED; color: #fff; }
.task-priority-picker, .task-category-picker, .task-tags-picker { max-height: min(72dvh, 620px); overflow-y: auto; }
.task-priority-picker > button, .task-category-picker > button { display: block; width: 100%; min-height: 48px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 10px calc(10px + var(--task-filter-depth, 0) * 16px); text-align: left; }
.task-picker-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.task-picker-chips button { min-height: 38px; border: 1px solid var(--border); border-radius: 999px; background: var(--bg-secondary); padding: 7px 11px; }
.task-picker-chips button.selected { border-color: #2F80ED; background: var(--bg-info); color: var(--text-info); }
.task-picker-done { display: block; min-width: 110px; min-height: 44px; margin: 16px 0 0 auto; border: 0; border-radius: 11px; background: #2F80ED; color: #fff; }

@media (max-width: 400px) {
  .task-calendar-day { min-height: 32px; }
  .task-scheduler-sheet { padding-left: 12px; padding-right: 12px; }
}

.task-editor-bg { align-items: flex-end; }
.task-editor-sheet { width: min(100%, 620px); max-height: min(94dvh, 880px); overflow-y: auto; border-radius: 22px 22px 0 0; padding-bottom: calc(18px + env(safe-area-inset-bottom, 0px)); }
.task-editor-header { position: sticky; top: -18px; z-index: 3; display: grid; grid-template-columns: 42px minmax(0,1fr) 42px; align-items: center; gap: 8px; margin: -6px -4px 8px; padding: 10px 4px 8px; background: var(--bg-primary); }
.task-editor-header > button:last-child { width: 42px; height: 42px; border: 0; border-radius: 12px; background: transparent; color: var(--text-secondary); font-size: 22px; }
.task-editor-title-input { width: 100%; min-height: 44px; border: 0; background: transparent; padding: 4px; font-size: 20px; font-weight: 750; outline: none; }
.task-editor-sheet.done .task-editor-title-input { color: var(--text-tertiary); text-decoration: line-through; }
.task-editor-description { width: 100%; min-height: 96px; resize: vertical; border: 1px solid var(--border); border-radius: 14px; background: var(--bg-secondary); padding: 11px 12px; color: var(--text-primary); font: inherit; line-height: 1.4; }
.task-editor-section { margin-top: 14px; border: 1px solid var(--border); border-radius: 15px; background: var(--bg-primary); padding: 10px 12px; }
.task-editor-section h3 { margin: 0; font-size: 16px; }
.task-editor-author { display: grid; gap: 9px; }
.task-editor-author label { display: grid; gap: 5px; color: var(--text-secondary); font-size: 13px; }
.task-editor-author select, .task-editor-author input { width: 100%; min-height: 42px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-secondary); padding: 8px 10px; color: var(--text-primary); font: inherit; }
.task-editor-field-grid { display: grid; gap: 0; }
.task-editor-field { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 48px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 4px 2px; text-align: left; }
.task-editor-field:last-child { border-bottom: 0; }
.task-editor-field span { color: var(--text-secondary); }
.task-editor-field b { max-width: 58%; overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.task-editor-section-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.task-editor-section-head > button { min-height: 40px; border: 0; border-radius: 10px; background: var(--bg-secondary); padding: 7px 10px; color: var(--text-info); font-size: 12px; }
.task-subtasks { padding-bottom: 6px; }
.task-subtask-row { display: grid; grid-template-columns: 34px minmax(0,1fr) 38px; align-items: center; gap: 7px; min-height: 48px; border-top: 1px solid var(--border); }
.task-subtask-checkbox { display: grid; place-items: center; width: 28px; height: 28px; border: 1.5px solid var(--border-strong); border-radius: 50%; background: var(--bg-primary); color: #fff; }
.task-subtask-checkbox.checked { border-color: #347A3B; background: #347A3B; }
.task-subtask-title { width: 100%; min-height: 42px; border: 0; background: transparent; padding: 4px; outline: none; }
.task-subtask-row:has(.task-subtask-checkbox.checked) .task-subtask-title { color: var(--text-tertiary); text-decoration: line-through; }
.task-subtask-delete { width: 38px; height: 38px; border: 0; border-radius: 10px; background: transparent; color: var(--text-tertiary); }
.task-subtask-progress { display: block; margin-top: 3px; color: var(--text-tertiary); font-size: 12px; }
.task-editor-placeholder { display: flex; justify-content: space-between; gap: 12px; min-height: 42px; border-bottom: 1px solid var(--border); padding: 10px 2px; color: var(--text-secondary); font-size: 13px; }
.task-editor-placeholder:last-child { border-bottom: 0; }
.task-editor-placeholder span { text-align: right; }
.task-editor-error { min-height: 21px; padding: 7px 3px 0; color: #D92D20; font-size: 12px; }
.task-editor-actions { position: sticky; bottom: -18px; z-index: 3; display: grid; grid-template-columns: 1fr auto; gap: 9px; margin: 8px -4px -18px; padding: 10px 4px calc(10px + env(safe-area-inset-bottom, 0px)); background: var(--bg-primary); }
.task-editor-actions button { min-height: 46px; border: 0; border-radius: 12px; padding: 8px 14px; }
.task-editor-actions .primary { background: #2F80ED; color: #fff; font-weight: 700; }
.task-editor-danger { background: rgba(217,45,32,.1); color: #B4232A; }

@media (min-width: 760px) {
  .task-editor-bg { align-items: stretch; justify-content: flex-end; padding: 0; }
  .task-editor-sheet { width: min(48vw, 620px); max-height: 100%; height: 100%; border-radius: 0; }
}

.tasks-calendar { display: grid; gap: 14px; min-width: 0; }
.tasks-calendar-header { display: grid; gap: 10px; }
.tasks-calendar-mode-toggle { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; border-radius: 12px; background: var(--bg-secondary); padding: 3px; }
.tasks-calendar-mode-toggle button { min-height: 40px; border: 0; border-radius: 10px; background: transparent; color: var(--text-secondary); font-size: 12px; font-weight: 700; }
.tasks-calendar-mode-toggle button.active { background: var(--bg-primary); color: var(--text-primary); box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.tasks-calendar-nav { display: grid; grid-template-columns: 44px minmax(0,1fr) 44px; align-items: center; }
.tasks-calendar-nav button { min-height: 44px; border: 0; border-radius: 11px; background: transparent; }
.tasks-calendar-nav button:nth-child(2) { display: grid; justify-items: center; gap: 1px; }
.tasks-calendar-nav span { color: var(--text-info); font-size: 11px; }
.tasks-calendar-nav b { font-size: 14px; text-transform: capitalize; }
.calendar-day-view { display: grid; gap: 13px; }
.calendar-day-view > h2 { margin: 0; font-size: 18px; text-transform: capitalize; }
.calendar-day-section { border: 1px solid var(--border); border-radius: 14px; padding: 10px; }
.calendar-day-section h3 { margin: 0 0 7px; font-size: 13px; color: var(--text-secondary); }
.calendar-week-view { display: grid; grid-auto-columns: minmax(132px, 44vw); grid-auto-flow: column; gap: 8px; overflow-x: auto; scroll-snap-type: x proximity; padding-bottom: 5px; }
.calendar-week-day { min-height: 220px; scroll-snap-align: start; border: 1px solid var(--border); border-radius: 14px; background: var(--bg-primary); padding: 8px; }
.calendar-week-day > header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; color: var(--text-secondary); text-transform: capitalize; }
.calendar-week-day > header span { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; font-weight: 750; }
.calendar-week-day.calendar-today { border-color: rgba(52,122,59,.45); background: rgba(52,122,59,.04); }
.calendar-week-day.calendar-today > header span { background: #347A3B; color: #fff; }
.calendar-day-empty { color: var(--text-tertiary); font-size: 12px; }
.calendar-month-weekdays, .calendar-month-grid { display: grid; grid-template-columns: repeat(7, minmax(0,1fr)); }
.calendar-month-weekdays span { padding: 5px 0; color: var(--text-tertiary); font-size: 10px; font-weight: 700; text-align: center; }
.calendar-month-grid { overflow: hidden; border: 1px solid var(--border); border-radius: 12px; }
.calendar-month-cell { min-width: 0; min-height: 70px; overflow: hidden; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--bg-primary); padding: 4px 3px; cursor: pointer; }
.calendar-month-cell:nth-child(7n) { border-right: 0; }
.calendar-month-cell > span { display: grid; place-items: center; width: 22px; height: 22px; margin-bottom: 2px; border-radius: 50%; font-size: 11px; }
.calendar-month-cell.outside { background: var(--bg-secondary); color: var(--text-tertiary); }
.calendar-month-cell.calendar-today > span { background: #347A3B; color: #fff; font-weight: 750; }
.calendar-month-cell.calendar-selected-date { box-shadow: inset 0 0 0 2px #2F80ED; }
.calendar-selected-tasks { margin-top: 12px; }
.calendar-selected-tasks h3 { margin: 0 0 7px; font-size: 14px; }
.calendar-quarter-view { display: grid; gap: 10px; }
.calendar-quarter-card { min-height: 150px; border: 1px solid var(--border); border-radius: 15px; padding: 12px; }
.calendar-quarter-card > header { display: flex; align-items: center; justify-content: space-between; }
.calendar-quarter-card h3 { margin: 0; text-transform: capitalize; }
.calendar-quarter-card > header b { display: grid; place-items: center; min-width: 30px; height: 30px; border-radius: 999px; background: var(--bg-secondary); }
.calendar-quarter-card > p { margin: 4px 0 10px; color: var(--text-tertiary); font-size: 12px; }
.calendar-task { display: flex; width: 100%; min-width: 0; gap: 6px; align-items: flex-start; border: 0; border-left: 3px solid #A8A8A2; border-radius: 6px; background: var(--bg-secondary); margin: 3px 0; padding: 6px; color: var(--text-primary); text-align: left; }
.calendar-task.critical { border-left-color: #D92D20; }
.calendar-task.high { border-left-color: #E69A22; }
.calendar-task.medium { border-left-color: #2F80ED; }
.calendar-task.none { border-left-color: #A8A8A2; }
.calendar-task.done { opacity: .58; }
.calendar-task.done b { text-decoration: line-through; }
.calendar-task.overdue { color: #B4232A; }
.calendar-task.today { color: #347A3B; }
.calendar-task.upcoming { color: #2F80ED; }
.calendar-task-dot { flex: 0 0 5px; width: 5px; height: 5px; margin-top: 5px; border-radius: 50%; background: currentColor; }
.calendar-task-body { display: grid; min-width: 0; gap: 1px; }
.calendar-task-body b { overflow: hidden; font-size: 11px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.calendar-task-body small, .calendar-task-body em { overflow: hidden; color: var(--text-tertiary); font-size: 9px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.calendar-month-cell .calendar-task { padding: 2px 3px; margin: 1px 0; border-left-width: 2px; }
.calendar-month-cell .calendar-task-dot, .calendar-month-cell .calendar-task-body small, .calendar-month-cell .calendar-task-body em { display: none; }
.calendar-month-cell .calendar-task-body b { font-size: 8px; }
.calendar-no-date { border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.calendar-no-date > button { display: grid; grid-template-columns: 1fr auto 24px; align-items: center; width: 100%; min-height: 46px; border: 0; background: transparent; padding: 8px 11px; text-align: left; }
.calendar-no-date > button b { color: var(--text-tertiary); }
.calendar-no-date > div { padding: 0 9px 9px; }

@media (min-width: 760px) {
  .calendar-week-view { grid-template-columns: repeat(7, minmax(0,1fr)); grid-auto-flow: row; overflow: visible; }
  .calendar-week-day { min-height: 260px; }
  .calendar-quarter-view { grid-template-columns: repeat(3, 1fr); }
  .calendar-month-cell { min-height: 108px; padding: 6px; }
  .calendar-month-cell .calendar-task-body b { font-size: 10px; }
}

.tasks-header-actions { display: flex; align-items: center; gap: 2px; }
.tasks-filter-button { display: grid; place-items: center; width: 42px; height: 42px; border: 0; border-radius: 12px; background: transparent; color: var(--text-secondary); font-size: 20px; }
.task-search { display: none; grid-template-columns: 24px minmax(0,1fr) 40px; align-items: center; gap: 5px; min-height: 46px; margin: 7px 0; border: 1px solid var(--border); border-radius: 13px; background: var(--bg-secondary); padding: 0 4px 0 11px; }
.task-search.open { display: grid; }
.task-search > i { color: var(--text-tertiary); }
.task-search input { width: 100%; min-height: 42px; border: 0; background: transparent; outline: 0; font: inherit; }
.task-search-close { width: 38px; height: 38px; border: 0; border-radius: 10px; background: transparent; color: var(--text-tertiary); }
.task-filter-chips { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0; }
.task-filter-chips:empty { display: none; }
.task-filter-chip { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 5px; min-height: 34px; border: 1px solid rgba(47,128,237,.25); border-radius: 999px; background: var(--bg-info); padding: 5px 9px; color: var(--text-info); font-size: 11px; }
.task-filter-sheet { max-height: min(88dvh, 760px); overflow-y: auto; }
.task-filter-sheet > label { display: grid; grid-template-columns: minmax(0,1fr) minmax(140px,55%); align-items: center; gap: 10px; min-height: 49px; border-bottom: 1px solid var(--border); }
.task-filter-sheet > label span { font-size: 13px; font-weight: 650; }
.task-filter-sheet select, .task-filter-sheet input { min-width: 0; min-height: 40px; border: 0; border-radius: 9px; background: var(--bg-secondary); padding: 7px 9px; color: var(--text-primary); }
.task-filter-custom { display: none; grid-template-columns: 1fr 1fr; gap: 8px; padding: 9px 0; }
.task-filter-custom.open { display: grid; }
.task-filter-actions { position: sticky; bottom: -18px; display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 12px -2px -18px; padding: 10px 2px calc(10px + env(safe-area-inset-bottom,0px)); background: var(--bg-primary); }
.task-filter-actions button { min-height: 46px; border: 0; border-radius: 12px; background: var(--bg-secondary); }
.task-filter-actions .primary { background: #2F80ED; color: #fff; font-weight: 700; }
.task-sidebar-count { margin-left: auto; min-width: 24px; color: var(--text-tertiary); font-size: 11px; text-align: right; }
.task-empty-state, .task-loading-state, .task-error-state { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 76px; color: var(--text-tertiary); font-size: 13px; text-align: center; }
.task-empty-state i { font-size: 18px; }
.task-loading-state i { animation: task-spin .9s linear infinite; }
.task-error-state { flex-wrap: wrap; color: #B4232A; }
.task-error-state button { min-height: 38px; border: 0; border-radius: 10px; background: rgba(217,45,32,.1); padding: 7px 12px; color: #B4232A; }
@keyframes task-spin { to { transform: rotate(360deg); } }
.task-category-panel, .task-tags-panel { max-height: min(82dvh,700px); overflow-y: auto; }
.task-category-panel > button:not([data-close]), .task-tags-panel > button:not([data-close]) { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 9px; width: 100%; min-height: 48px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 8px 8px 8px calc(8px + var(--task-filter-depth,0) * 15px); text-align: left; }
.task-category-panel > button b, .task-tags-panel > button b { color: var(--text-tertiary); font-size: 11px; }
.task-reminder-section { display: grid; gap: 0; }
.task-reminder-item { border-bottom: 1px solid var(--border); }
.task-reminder-item .task-row { border-bottom: 0; }
.task-reminder-chips { display: flex; flex-wrap: wrap; gap: 5px; padding: 0 10px 8px 48px; }
.task-reminder-chips span { display: inline-flex; align-items: center; gap: 4px; border-radius: 999px; background: var(--bg-secondary); padding: 4px 7px; color: var(--text-secondary); font-size: 10px; }

@media (max-width: 420px) {
  .tasks-filter-button, .tasks-search-button { width: 40px; }
  .task-filter-sheet > label { grid-template-columns: minmax(0,1fr) minmax(125px,54%); }
}

/* Task category overview: dense, mobile-first grouping. */
.task-overview { display: grid; min-width: 0; }
.task-category-group { border-top: 1px solid var(--border); }
.task-category-group:first-child { border-top: 0; }
.task-category-group-header { display: grid; grid-template-columns: minmax(0,1fr) 42px 42px; align-items: center; min-height: 58px; }
.task-category-title { display: grid; min-width: 0; gap: 3px; border: 0; background: transparent; padding: 8px 4px; color: var(--text-primary); text-align: left; }
.task-category-title b { overflow: hidden; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.task-category-counts { color: var(--text-tertiary); font-size: 11px; line-height: 1.35; }
.task-category-counts .overdue { color: #D92D20; }
.task-category-counts .completed { color: var(--text-tertiary); }
.task-category-chevron, .task-category-menu { display: grid; place-items: center; width: 42px; height: 42px; border: 0; border-radius: 11px; background: transparent; color: var(--text-tertiary); }
.task-category-section { padding-left: 10px; }
.task-category-section-header { display: grid; grid-template-columns: minmax(0,1fr) auto 30px; align-items: center; width: 100%; min-height: 42px; border: 0; border-top: 1px solid var(--border); background: transparent; padding: 0 2px; text-align: left; }
.task-category-section-header b { color: var(--text-tertiary); font-size: 12px; }
.task-category-section-header i { color: var(--text-tertiary); text-align: right; }
.task-category-screen { min-width: 0; }
.task-category-screen-header { display: grid; grid-template-columns: 44px minmax(0,1fr); align-items: center; gap: 8px; min-height: 62px; border-bottom: 1px solid var(--border); }
.task-category-screen-header button { width: 44px; height: 44px; border: 0; border-radius: 12px; background: transparent; font-size: 21px; }
.task-category-screen-header h2 { margin: 0 0 3px; overflow: hidden; font-size: 18px; text-overflow: ellipsis; white-space: nowrap; }
.task-uncategorized-group { margin-top: 8px; border-top-color: var(--border-strong); }
.task-row { grid-template-columns: 38px 8px minmax(0,1fr) auto 42px; }
.task-row-menu-wrap { position: relative; align-self: center; }
.task-row-menu { position: absolute; z-index: 12; top: 38px; right: 0; width: 174px; overflow: hidden; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-primary); box-shadow: 0 10px 28px rgba(0,0,0,.16); }
.task-row-menu-item { display: block; width: 100%; min-height: 44px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 9px 12px; color: var(--text-primary); text-align: left; }
.task-row-menu-item:last-child { border-bottom: 0; }
.task-move-action:active { background: var(--pressed); }

@media (max-width: 380px) {
  .task-category-group-header { grid-template-columns: minmax(0,1fr) 40px 40px; }
  .task-category-section { padding-left: 5px; }
  .task-row { grid-template-columns: 36px 7px minmax(0,1fr) 40px; }
  .task-date { grid-column: 3; display: flex; gap: 6px; padding: 4px 0 0; text-align: left; }
  .task-row-menu-wrap { grid-column: 4; grid-row: 1 / span 2; }
}

/* Unified read-only shell: future Zametki direction, independent of legacy editors. */
.phone-shell[data-unified-shell] { width: min(100vw, 560px); height: 100dvh; min-height: 0; border: 0; border-radius: 0; background: radial-gradient(ellipse 90% 48% at 100% -8%, rgba(122,178,255,.24), transparent 64%), radial-gradient(ellipse 80% 52% at -15% 24%, rgba(126,214,165,.21), transparent 62%), linear-gradient(180deg, #f7faf8 0%, #f2f6f4 100%); box-shadow: none; }
.unified-header { display: grid; grid-template-columns: 42px minmax(0,1fr) 38px 38px 38px; gap: 7px; align-items: center; padding: calc(env(safe-area-inset-top, 0px) + 10px) 14px 9px; }
.unified-icon-button, .unified-avatar { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid rgba(255,255,255,.72); border-radius: 50%; background: rgba(255,255,255,.63); box-shadow: 0 2px 10px rgba(60,80,70,.08); color: #66707b; }
.unified-avatar { background: linear-gradient(135deg, #72ba8b, #4f8ecf); color: #fff; font-size: 13px; font-weight: 700; }
.unified-search { display: flex; min-width: 0; align-items: center; gap: 8px; height: 42px; border: 1px solid rgba(255,255,255,.72); border-radius: 22px; background: rgba(255,255,255,.63); box-shadow: 0 2px 10px rgba(60,80,70,.06); color: #98a1ab; padding: 0 12px; }
.unified-search input { width: 100%; border: 0; outline: 0; background: transparent; color: #23262b; font-size: 14px; }
.unified-tabs { display: flex; justify-content: center; gap: 25px; padding: 1px 18px 9px; }
.unified-tabs button { display: grid; justify-items: center; gap: 5px; min-width: 54px; border: 0; background: transparent; color: #98a1ab; font-size: 12px; font-weight: 600; padding: 3px 0; }
.unified-tab-dot { width: 18px; height: 4px; border-radius: 8px; background: rgba(140,155,150,.32); }
.unified-tabs button.active { color: #23262b; }
.unified-tabs button.active .unified-tab-dot { width: 25px; background: #3e9b5f; }
.unified-screen { padding: 8px 16px calc(env(safe-area-inset-bottom, 0px) + 28px); }
.unified-hero { margin: 6px 2px 16px; }
.unified-eyebrow { margin: 0 0 4px; color: #66707b; font-size: 11px; font-weight: 700; letter-spacing: .055em; text-transform: uppercase; }
.unified-hero h1, .unified-section h2, .unified-sheet h2 { margin: 0; color: #23262b; font-family: "Segoe UI", system-ui, sans-serif; font-size: 25px; letter-spacing: -.035em; }
.unified-hero > p:last-child { margin: 6px 0 0; color: #66707b; font-size: 13px; line-height: 1.45; }
.unified-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.unified-metrics article { display: grid; gap: 2px; min-height: 71px; border: 1px solid rgba(255,255,255,.7); border-radius: 16px; background: rgba(255,255,255,.54); padding: 11px; box-shadow: 0 2px 8px rgba(60,80,70,.04); }
.unified-metrics b { font-size: 22px; line-height: 1; }
.unified-metrics span, .unified-muted { color: #98a1ab; font-size: 11px; }
.unified-feature-row { display: grid; grid-template-columns: 26px minmax(0,1fr) 20px; align-items: center; gap: 8px; width: 100%; min-height: 63px; border: 1px solid rgba(62,155,95,.25); border-radius: 17px; background: rgba(255,255,255,.61); color: #3e9b5f; padding: 10px 12px; text-align: left; }
.unified-feature-row span { display: grid; gap: 2px; }
.unified-feature-row small { color: #66707b; font-size: 11px; }
.unified-section { margin-top: 21px; }
.unified-section-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin: 0 2px 8px; }
.unified-section-head h2 { font-size: 18px; }
.unified-section-head > span { min-width: 22px; border-radius: 12px; background: rgba(140,155,150,.13); color: #66707b; font-size: 11px; padding: 3px 7px; text-align: center; }
.unified-list { overflow: hidden; border: 1px solid rgba(255,255,255,.72); border-radius: 17px; background: rgba(255,255,255,.55); box-shadow: 0 2px 8px rgba(60,80,70,.04); }
.unified-card { display: grid; grid-template-columns: 29px minmax(0,1fr) 18px; align-items: center; gap: 9px; width: 100%; min-height: 70px; border: 0; border-bottom: 1px solid rgba(140,155,150,.14); background: transparent; color: #23262b; padding: 10px 11px; text-align: left; }
.unified-card:last-child { border-bottom: 0; }
.unified-card-icon { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 9px; background: rgba(62,155,95,.1); color: #3e9b5f; }
.unified-card-body { display: grid; min-width: 0; gap: 3px; }
.unified-card-body b, .unified-card-body small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.unified-card-body b { font-size: 13px; }
.unified-card-body small { color: #66707b; font-size: 11px; }
.unified-card-body em { color: #98a1ab; font-size: 10px; font-style: normal; }
.unified-card > .ti-chevron-right, .unified-card > .ti-lock { color: #98a1ab; font-size: 16px; }
.unified-task-card.done { opacity: .58; }
.unified-task-card.done b { text-decoration: line-through; }
.unified-category-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
.unified-category-card { display: grid; grid-template-columns: 27px minmax(0,1fr) auto; align-items: center; gap: 7px; min-height: 53px; border: 1px solid rgba(255,255,255,.72); border-radius: 15px; background: rgba(255,255,255,.55); color: #23262b; padding: 9px; text-align: left; }
.unified-category-card b { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.unified-category-card small { color: #98a1ab; font-size: 10px; }
.unified-chat-emoji { display: grid; place-items: center; width: 29px; height: 29px; border-radius: 10px; background: rgba(91,141,239,.11); font-size: 16px; }
.unified-placeholder-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px; }
.unified-placeholder-grid button { display: grid; justify-items: center; gap: 5px; min-height: 69px; border: 1px dashed rgba(140,155,150,.35); border-radius: 15px; background: rgba(255,255,255,.28); color: #66707b; font-size: 10px; }
.unified-placeholder-grid i { font-size: 18px; color: #98a1ab; }
.unified-state { display: grid; justify-items: center; gap: 8px; max-width: 290px; margin: 72px auto; color: #66707b; text-align: center; }
.unified-state > i { display: grid; place-items: center; width: 52px; height: 52px; border: 1px solid rgba(255,255,255,.7); border-radius: 17px; background: rgba(255,255,255,.5); color: #3e9b5f; font-size: 25px; }
.unified-state b { color: #23262b; font-size: 15px; }
.unified-state span { font-size: 12px; line-height: 1.45; }
.unified-spin { animation: unified-spin 1s linear infinite; }
.unified-secondary, .unified-primary-disabled { min-height: 42px; border-radius: 12px; padding: 0 13px; font: inherit; }
.unified-secondary { border: 1px solid rgba(62,155,95,.3); background: rgba(62,155,95,.1); color: #287642; }
.unified-primary-disabled { width: 100%; border: 0; background: rgba(62,155,95,.14); color: #287642; }
.unified-toast { position: absolute; z-index: 120; right: 16px; bottom: calc(env(safe-area-inset-bottom, 0px) + 15px); left: 16px; transform: translateY(16px); border-radius: 14px; background: rgba(35,38,43,.92); color: #fff; opacity: 0; padding: 11px 14px; pointer-events: none; font-size: 12px; line-height: 1.4; transition: opacity .2s, transform .2s; }
.unified-toast.show { transform: translateY(0); opacity: 1; }
.unified-sheet-backdrop { position: absolute; z-index: 110; inset: 0; display: flex; align-items: end; background: rgba(20,30,26,.28); backdrop-filter: blur(3px); padding: 16px; }
.unified-sheet { position: relative; width: 100%; max-height: min(76dvh, 650px); overflow: auto; border: 1px solid rgba(255,255,255,.76); border-radius: 22px; background: rgba(250,252,251,.97); box-shadow: 0 -12px 35px rgba(30,45,40,.2); padding: 23px 17px calc(env(safe-area-inset-bottom, 0px) + 18px); }
.unified-sheet-close { position: absolute; top: 10px; right: 10px; display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 50%; background: rgba(140,155,150,.12); color: #66707b; }
.unified-sheet > p:not(.unified-eyebrow), .unified-message-list p { color: #66707b; font-size: 13px; line-height: 1.5; }
.unified-chip-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 15px 0; }
.unified-chip-row span { border-radius: 10px; background: rgba(91,141,239,.1); color: #456fae; font-size: 11px; padding: 5px 8px; }
.unified-message-list { display: grid; gap: 8px; margin: 15px 0; }
.unified-message-list article { border-radius: 13px 13px 13px 3px; background: rgba(91,141,239,.09); padding: 9px 11px; }
.unified-message-list article p { margin: 0; white-space: pre-wrap; }
.unified-message-list article small { color: #98a1ab; font-size: 10px; }
@keyframes unified-spin { to { transform: rotate(360deg); } }
@media (min-width: 561px) { .phone-shell[data-unified-shell] { height: min(100dvh - 24px, 920px); margin: 12px 0; border: 1px solid var(--border); border-radius: 25px; } }

/* Unified visual layer: read-only data, richer mobile cards and bottom navigation. */
.phone-shell[data-unified-shell] .unified-screen { padding: 8px 14px calc(104px + env(safe-area-inset-bottom, 0px)); }
.unified-hotbar { position: absolute; z-index: 8; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); display: grid; grid-template-columns: 1fr 1fr 58px 1fr; align-items: end; min-height: 62px; padding: 7px 8px; border: 1px solid rgba(255,255,255,.76); border-radius: 22px; background: rgba(255,255,255,.78); box-shadow: 0 12px 34px rgba(37,61,54,.16); backdrop-filter: blur(18px) saturate(1.3); -webkit-backdrop-filter: blur(18px) saturate(1.3); }
.unified-hotbar button { display: grid; place-items: center; gap: 2px; min-height: 46px; border: 0; border-radius: 15px; background: transparent; color: #99a4a4; font: inherit; font-size: 10px; font-weight: 700; }
.unified-hotbar button i { font-size: 19px; }
.unified-hotbar button.active { color: #178d68; background: rgba(43,173,127,.11); }
.unified-hotbar .unified-fab { align-self: center; width: 52px; height: 52px; min-height: 52px; margin: -25px auto 0; border-radius: 18px; background: linear-gradient(145deg, #2ab27f, #168d70); box-shadow: 0 9px 18px rgba(27,148,108,.32); color: #fff; }
.unified-hotbar .unified-fab:active { transform: scale(.94); }
.unified-hotbar .unified-fab i { font-size: 25px; }
.unified-hero { position: relative; overflow: hidden; margin: 4px 0 10px; padding: 17px 17px 16px; border: 1px solid rgba(255,255,255,.76); border-radius: 23px; background: linear-gradient(135deg, rgba(255,255,255,.88), rgba(229,248,238,.72)); box-shadow: 0 8px 23px rgba(70,108,91,.08); }
.unified-hero::after { content: ""; position: absolute; width: 120px; height: 120px; right: -42px; top: -54px; border-radius: 50%; background: radial-gradient(circle, rgba(60,189,137,.29), transparent 68%); }
.unified-hero h1 { position: relative; z-index: 1; margin: 3px 0 5px; font-size: 27px; letter-spacing: -.05em; }
.unified-hero p:last-child { position: relative; z-index: 1; max-width: 270px; color: #6d797b; font-size: 12px; line-height: 1.48; }
.unified-metrics { gap: 8px; margin: 0 0 12px; }
.unified-metrics article { padding: 13px 8px; border: 1px solid rgba(255,255,255,.78); border-radius: 17px; background: rgba(255,255,255,.66); box-shadow: 0 5px 14px rgba(70,108,91,.06); }
.unified-metrics b { color: #24302e; font-size: 19px; }
.unified-section { margin: 15px 0; }
.unified-section-head { padding: 0 3px; }
.unified-section-head h2 { font-size: 17px; letter-spacing: -.025em; }
.unified-section-head > span { min-width: 25px; padding: 4px 8px; border-radius: 99px; background: rgba(33,158,116,.1); color: #168b69; font-size: 11px; text-align: center; }
.unified-note-plate { min-height: 78px; padding: 11px 11px 11px 12px; border: 1px solid rgba(219,229,225,.95); border-radius: 18px; background: rgba(255,255,255,.76); box-shadow: 0 5px 14px rgba(68,97,86,.055); }
.unified-note-plate::before { content: ""; align-self: stretch; width: 4px; margin: 2px 1px 2px 0; border-radius: 99px; background: linear-gradient(#79c99e, #b7e1c8); }
.unified-note-plate .unified-card-icon { width: 34px; height: 34px; border-radius: 12px; background: #eff8f2; color: #319c71; font-size: 18px; }
.unified-note-plate .unified-card-body b { font-size: 14px; }
.unified-note-plate .unified-card-body small { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; white-space: normal; }
.unified-note-plate .unified-card-body em { display: inline-flex; align-self: flex-start; margin-top: 3px; padding: 2px 7px; border-radius: 99px; background: rgba(112,138,129,.1); font-size: 9px; }
.unified-pinned-rail .unified-list { display: flex; gap: 10px; overflow-x: auto; padding: 1px 2px 5px; scroll-snap-type: x proximity; }
.unified-pinned-rail .unified-note-plate { flex: 0 0 min(78vw, 276px); scroll-snap-align: start; background: linear-gradient(145deg, rgba(255,250,229,.94), rgba(255,255,255,.88)); border-color: rgba(224,190,93,.34); }
.unified-pinned-rail .unified-note-plate::before { background: linear-gradient(#e8bf47, #f7e6a5); }
.unified-recent-stack .unified-note-plate { border-left-color: rgba(74,155,211,.36); }
.unified-recent-stack .unified-note-plate::before { background: linear-gradient(#77a9de, #c8ddf2); }
.unified-task-lane { min-height: 68px; padding: 10px 12px; border: 1px solid rgba(220,229,226,.95); border-radius: 17px; background: rgba(255,255,255,.74); box-shadow: 0 4px 13px rgba(68,97,86,.05); }
.unified-task-lane .unified-card-icon { color: #2d9c70; font-size: 23px; }
.unified-task-lane .unified-card-body b { font-size: 13.5px; }
.unified-task-lane.done { opacity: .7; background: rgba(241,246,243,.86); }
.unified-task-lane.done .unified-card-body b { text-decoration: line-through; }
.unified-chat-stack .unified-list { gap: 9px; }
.unified-chat-card { min-height: 74px; padding: 10px 12px; border: 1px solid rgba(218,229,225,.94); border-radius: 18px; background: rgba(255,255,255,.78); box-shadow: 0 4px 13px rgba(68,97,86,.045); }
.unified-chat-avatar { display: grid; flex: 0 0 42px; width: 42px; height: 42px; place-items: center; border-radius: 15px; background: linear-gradient(145deg, #d9f0e4, #c1e5db); box-shadow: inset 0 1px 0 rgba(255,255,255,.76); font-size: 20px; }
.unified-chat-card:nth-child(3n+2) .unified-chat-avatar { background: linear-gradient(145deg, #dceafa, #c9dbf1); }
.unified-chat-card:nth-child(3n) .unified-chat-avatar { background: linear-gradient(145deg, #f8e5b8, #f3d4b0); }
.unified-chat-card .unified-card-body b { font-size: 14px; }
.unified-chat-card .unified-card-body em { color: #2d9670; font-size: 10px; }
.unified-placeholder-grid { margin-bottom: 8px; }
@media (max-width: 370px) { .unified-hotbar { left: 8px; right: 8px; } .unified-hotbar button { font-size: 9px; } .unified-hotbar .unified-fab { width: 48px; height: 48px; min-height: 48px; } }

/* Home Notes v11: scoped visual parity layer for the unified Notes route only. */
.phone-shell[data-unified-shell] { background: radial-gradient(ellipse 84% 44% at 100% -8%, rgba(122,178,255,.30), transparent 66%), radial-gradient(ellipse 76% 44% at -12% 25%, rgba(126,214,165,.26), transparent 66%), radial-gradient(ellipse 62% 34% at 100% 76%, rgba(255,214,140,.17), transparent 68%), linear-gradient(180deg, #f7faf8 0%, #f1f6f3 100%); }
.unified-header { backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.unified-home-greeting { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 7px 2px 16px; }
.unified-home-greeting h1 { margin: 0; color: #23262b; font-family: "Trebuchet MS", system-ui, sans-serif; font-size: 21px; font-weight: 750; letter-spacing: -.045em; }
.unified-home-greeting h1 span { color: #3e9b5f; }
.unified-home-greeting p { margin: 4px 0 0; color: #98a1ab; font-size: 12px; }
.unified-home-stat { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; border: 1px solid rgba(255,255,255,.76); border-radius: 999px; background: rgba(255,255,255,.58); box-shadow: 0 3px 12px rgba(65,84,73,.06); color: #66707b; padding: 0 10px; font-size: 11px; font-weight: 700; }
.unified-home-stat i { color: #3e9b5f; font-size: 15px; }
.unified-home-section { margin: 0 0 22px; }
.unified-home-section-label { display: flex; align-items: center; gap: 7px; min-height: 26px; margin: 0 2px 8px; color: #66707b; font-size: 12px; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; }
.unified-home-section-label > small { color: #a4adb4; font-size: 11px; font-weight: 600; letter-spacing: 0; text-transform: none; }
.unified-home-section-label button { display: inline-flex; align-items: center; gap: 3px; margin-left: auto; border: 0; background: transparent; color: #7b858e; font: inherit; font-size: 11px; font-weight: 700; text-transform: none; }
.unified-home-section-label button i { font-size: 14px; }
.unified-pinned-carousel { display: flex; gap: 10px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; padding: 1px 2px 6px; scrollbar-width: none; }
.unified-pinned-carousel::-webkit-scrollbar { display: none; }
.unified-pinned-card { position: relative; display: grid; align-content: start; flex: 0 0 min(78%, 282px); min-height: 140px; overflow: hidden; scroll-snap-align: start; border: 1px solid rgba(255,255,255,.74); border-radius: 20px; background: linear-gradient(145deg, rgba(255,255,255,.82), rgba(224,243,232,.72)); box-shadow: 0 9px 24px rgba(67,105,83,.10); color: #27302d; padding: 16px; text-align: left; }
.unified-pinned-card::after { content: ""; position: absolute; width: 88px; height: 88px; right: -28px; top: -34px; border-radius: 50%; background: rgba(62,155,95,.16); }
.unified-pinned-card > i { position: relative; z-index: 1; width: 29px; height: 29px; display: grid; place-items: center; border-radius: 10px; background: rgba(255,255,255,.76); color: #3e9b5f; font-size: 16px; }
.unified-pinned-card-category { position: relative; z-index: 1; margin-top: 13px; color: #3e9b5f; font-size: 10px; font-weight: 750; }
.unified-pinned-card b { position: relative; z-index: 1; display: -webkit-box; margin-top: 3px; overflow: hidden; color: #27302d; font-size: 15px; line-height: 1.25; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.unified-pinned-card small { position: relative; z-index: 1; display: -webkit-box; margin-top: 5px; overflow: hidden; color: #718078; font-size: 11px; line-height: 1.35; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.unified-pinned-pagination { display: flex; justify-content: center; gap: 5px; margin-top: 1px; }
.unified-pinned-pagination i { width: 5px; height: 5px; border-radius: 50%; background: rgba(98,112,104,.26); }
.unified-pinned-pagination i:first-child { width: 17px; border-radius: 6px; background: #3e9b5f; }
.unified-recent-activity-list { display: grid; overflow: hidden; border: 1px solid rgba(213,225,218,.62); border-radius: 18px; background: rgba(255,255,255,.42); }
.unified-activity-card { position: relative; display: flex; min-width: 0; gap: 11px; border: 0; border-bottom: 1px solid rgba(173,188,180,.18); background: transparent; color: #26302c; padding: 13px 12px 13px 16px; text-align: left; }
.unified-activity-card:last-child { border-bottom: 0; }
.unified-activity-corner { position: absolute; left: 0; top: 0; bottom: 0; width: 4px; border-radius: 0 6px 6px 0; background: #4caf7d; }
.unified-activity-card.accent-1 .unified-activity-corner { background: #5b8def; }.unified-activity-card.accent-2 .unified-activity-corner { background: #e3b23c; }.unified-activity-card.accent-3 .unified-activity-corner { background: #bd78a6; }
.unified-activity-content { min-width: 0; flex: 1; }.unified-activity-content > small { display: block; overflow: hidden; color: #4b9870; font-size: 10px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }.unified-activity-content b { display: block; overflow: hidden; margin-top: 3px; color: #29302d; font-size: 14px; line-height: 1.22; text-overflow: ellipsis; white-space: nowrap; }.unified-activity-content em { display: -webkit-box; overflow: hidden; margin-top: 3px; color: #77827d; font-size: 11px; font-style: normal; line-height: 1.3; -webkit-box-orient: vertical; -webkit-line-clamp: 1; }.unified-activity-card > .ti { align-self: center; color: #adb7b1; font-size: 16px; }
.unified-activity-meta { display: flex; gap: 4px; overflow: hidden; margin-top: 7px; }.unified-activity-meta span { overflow: hidden; border-radius: 999px; background: rgba(104,130,115,.10); color: #63726b; padding: 2px 6px; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.unified-home-divider { height: 1px; margin: -2px 2px 20px; border-top: 1px dashed rgba(126,145,135,.38); }
.unified-category-grid-v11 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }.unified-category-card-v11 { --category-accent: #4caf7d; --category-soft: rgba(76,175,125,.12); min-width: 0; overflow: hidden; border: 1px solid color-mix(in srgb, var(--category-accent) 28%, white); border-radius: 19px; background: rgba(255,255,255,.60); box-shadow: 0 7px 20px rgba(70,95,81,.06); }.unified-category-card-v11.palette-1 { --category-accent: #5b8def; --category-soft: rgba(91,141,239,.12); }.unified-category-card-v11.palette-2 { --category-accent: #d29a38; --category-soft: rgba(227,178,60,.14); }.unified-category-card-v11.palette-3 { --category-accent: #a66a94; --category-soft: rgba(189,120,166,.13); }
.unified-category-card-head { display: grid; grid-template-columns: 27px minmax(0,1fr) auto; align-items: center; gap: 7px; width: 100%; border: 0; background: var(--category-soft); color: #303733; padding: 11px; text-align: left; }.unified-category-card-head > span { font-size: 19px; }.unified-category-card-head b { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }.unified-category-card-head small { min-width: 18px; border-radius: 999px; background: rgba(255,255,255,.66); color: var(--category-accent); padding: 2px 5px; font-size: 9px; font-weight: 800; text-align: center; }.unified-category-card-head > i { display: none; }
.unified-category-notes { display: grid; min-height: 74px; }.unified-category-note { display: grid; gap: 2px; min-width: 0; border: 0; border-bottom: 1px solid rgba(163,180,169,.16); background: transparent; color: #37403b; padding: 9px 10px; text-align: left; }.unified-category-note:last-child { border-bottom: 0; }.unified-category-note b, .unified-category-note small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.unified-category-note b { font-size: 11px; }.unified-category-note small { color: #849088; font-size: 9px; }.unified-category-empty { display: grid; place-items: center; align-content: center; gap: 4px; min-height: 74px; color: #98a39c; font-size: 10px; text-align: center; }.unified-category-empty i { color: var(--category-accent); font-size: 17px; }
.unified-category-card-footer { border-top: 1px dashed color-mix(in srgb, var(--category-accent) 30%, transparent); color: var(--category-accent); padding: 7px 10px; font-size: 10px; font-weight: 750; }
.unified-home-empty { display: flex; align-items: center; justify-content: center; min-height: 72px; gap: 8px; border: 1px dashed rgba(137,154,145,.42); border-radius: 16px; color: #8d9892; font-size: 12px; }.unified-home-empty i { color: #5b8def; font-size: 18px; }
.unified-hotbar { background: rgba(255,255,255,.56); box-shadow: 0 14px 36px rgba(37,61,54,.18); }.unified-hotbar .unified-fab { background: linear-gradient(145deg, #3e9b5f, #2d8c69); }
@media (min-width: 420px) { .unified-category-card-v11:first-child { grid-column: span 2; }.unified-category-card-v11:first-child .unified-category-notes { grid-template-columns: repeat(2, minmax(0, 1fr)); }.unified-category-card-v11:first-child .unified-category-note:nth-child(odd) { border-right: 1px solid rgba(163,180,169,.16); } }

/* Literal Home Notes port from FRAME_NOTES_B64.  The outer unified shell remains
   responsible for Notes / Chats / Tasks routing; this block owns the Notes body only. */
.phone-shell[data-unified-shell].home-notes-active { --home-ink:#23262b; --home-soft:#66707b; --home-faint:#98a1ab; --home-line:rgba(140,155,150,.18); --home-glass:rgba(255,255,255,.55); --home-accent:#3e9b5f; --home-sport:#4caf7d; --home-home:#5b8def; --home-agents:#e3b23c; --home-agents-ink:#c29222; background:radial-gradient(ellipse 90% 55% at 85% -5%,rgba(122,178,255,.28),transparent 60%),radial-gradient(ellipse 80% 50% at -10% 25%,rgba(126,214,165,.25),transparent 60%),radial-gradient(ellipse 70% 45% at 100% 75%,rgba(255,214,140,.20),transparent 60%),linear-gradient(180deg,#f7faf8 0%,#f2f6f4 100%); }
.phone-shell[data-unified-shell].home-notes-active .unified-screen { padding:8px 16px 130px; }
.phone-shell[data-unified-shell].home-notes-active > .unified-hotbar { display:none; }
.home-notes-port { color:var(--home-ink); font-family:"Golos Text",system-ui,sans-serif; }
.home-notes-port .content { padding:0; }
.home-notes-port .greeting-row { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; margin:8px 2px 14px; }
.home-notes-port .greeting h1 { margin:0; font-family:"Unbounded","Trebuchet MS",system-ui,sans-serif; font-size:19px; font-weight:600; letter-spacing:-.01em; }
.home-notes-port .greeting h1 span { color:var(--home-accent); }
.home-notes-port .greeting .date { margin-top:3px; color:var(--home-faint); font-size:12px; }
.home-notes-port .stat-chip { display:inline-flex; align-items:center; gap:5px; min-height:28px; border:1px solid rgba(255,255,255,.72); border-radius:14px; background:var(--home-glass); box-shadow:0 2px 10px rgba(60,80,70,.06); color:var(--home-soft); padding:4px 8px; font:500 10.5px inherit; }
.home-notes-port .stat-chip i { color:var(--home-accent); font-size:14px; }
.home-notes-port .section-label { display:flex; align-items:center; gap:6px; margin:0 2px 8px; color:var(--home-soft); font-size:12px; font-weight:600; letter-spacing:.06em; text-transform:uppercase; }
.home-notes-port .section-label .count { color:var(--home-faint); font-weight:500; letter-spacing:0; text-transform:none; }
.home-notes-port .gear-btn { display:grid; place-items:center; width:26px; height:26px; margin-left:auto; border:0; border-radius:8px; background:transparent; color:var(--home-faint); }
.home-notes-port .gear-btn:active { background:rgba(140,155,150,.15); color:var(--home-soft); }
.home-notes-port .pinned-wrap { margin-bottom:16px; border:1px solid rgba(76,175,125,.18); border-radius:20px; background:rgba(76,175,125,.08); backdrop-filter:blur(10px); -webkit-backdrop-filter:blur(10px); padding:12px 10px 10px; }
.home-notes-port .pinned-row { display:flex; gap:10px; }
.home-notes-port .pinned-card { position:relative; flex:1 1 0; min-width:0; border:1.5px solid var(--home-line); border-radius:14px; background:var(--home-glass); box-shadow:0 2px 12px rgba(60,80,70,.07); color:var(--home-ink); padding:10px 11px; text-align:left; backdrop-filter:blur(14px); -webkit-backdrop-filter:blur(14px); }
.home-notes-port .pinned-card.nc-home { border-color:rgba(91,141,239,.5); }.home-notes-port .pinned-card.nc-agents { border-color:rgba(227,178,60,.55); }.home-notes-port .pinned-card.nc-sport { border-color:rgba(76,175,125,.55); }
.home-notes-port .pinned-card .pin { position:absolute; top:8px; left:8px; color:var(--home-accent); font-size:13px; opacity:.85; }
.home-notes-port .pinned-card .pinned-kebab { position:absolute; top:5px; right:5px; color:var(--home-faint); font-size:14px; }
.home-notes-port .pinned-card h4 { overflow:hidden; margin:12px 14px 3px 0; font-size:12.5px; font-weight:600; text-overflow:ellipsis; white-space:nowrap; }
.home-notes-port .pinned-card p { display:-webkit-box; overflow:hidden; margin:0 0 5px; color:var(--home-soft); font-size:10.5px; line-height:1.35; -webkit-box-orient:vertical; -webkit-line-clamp:2; }
.home-notes-port .meta { display:flex; flex-wrap:wrap; align-items:center; gap:5px; }
.home-notes-port .ava { display:inline-flex; align-items:center; justify-content:center; width:18px; height:18px; flex:none; border:1.5px solid rgba(255,255,255,.9); border-radius:50%; box-shadow:0 1px 3px rgba(60,80,70,.15); color:#fff; font-size:9.5px; font-weight:700; }
.home-notes-port .ava-user { background:#3e9b5f; }.home-notes-port .ava-tanya { background:#6c63d2; }.home-notes-port .ava-borya { background:#d2704a; }
.home-notes-port .tag { border-radius:20px; background:rgba(140,155,150,.12); color:var(--home-soft); padding:2px 7px; font-size:9.5px; font-weight:500; }.home-notes-port .tag.cat-sport { background:rgba(76,175,125,.10); color:var(--home-sport); font-weight:600; }.home-notes-port .tag.cat-home { background:rgba(91,141,239,.10); color:var(--home-home); font-weight:600; }.home-notes-port .tag.cat-agents { background:rgba(227,178,60,.12); color:var(--home-agents-ink); font-weight:600; }
.home-notes-port .pinned-nav { display:flex; align-items:center; justify-content:center; gap:10px; padding-top:10px; }.home-notes-port .pn-arrow { display:grid; place-items:center; width:28px; height:28px; border:0; border-radius:50%; background:#fff; box-shadow:0 1px 4px rgba(60,80,70,.12); color:var(--home-soft); }.home-notes-port .pn-arrow:disabled { opacity:.35; }.home-notes-port .pn-dots { display:flex; align-items:center; gap:5px; }.home-notes-port .pn-dot { width:5px; height:5px; border-radius:50%; background:rgba(140,155,150,.4); }.home-notes-port .pn-dot.on { width:16px; border-radius:3px; background:var(--home-accent); }
.home-notes-port .recent-block { margin-bottom:18px; }.home-notes-port .note-card { position:relative; display:flex; width:100%; gap:9px; margin-bottom:0; border:0; border-bottom:1px solid var(--home-line); background:transparent; color:var(--home-ink); padding:11px 8px 12px 15px; text-align:left; }.home-notes-port .note-card::before { content:""; position:absolute; top:0; bottom:0; left:0; width:25%; border:1.5px solid var(--home-line); border-right:none; border-bottom:none; border-radius:14px 0 0 0; pointer-events:none; }.home-notes-port .note-card.nc-sport::before { border-color:var(--home-sport); }.home-notes-port .note-card.nc-home::before { border-color:var(--home-home); }.home-notes-port .note-card.nc-agents::before { border-color:var(--home-agents); }.home-notes-port .note-emoji { width:24px; flex:none; font-size:18px; line-height:1.4; text-align:center; }.home-notes-port .note-card .body { min-width:0; flex:1; }.home-notes-port .note-corner { position:absolute; top:8px; right:10px; display:flex; align-items:center; gap:5px; max-width:55%; font-size:9px; }.home-notes-port .cat-path { overflow:hidden; color:var(--home-faint); font-weight:600; text-overflow:ellipsis; white-space:nowrap; }.home-notes-port .cp-sport { color:var(--home-sport); }.home-notes-port .cp-home { color:var(--home-home); }.home-notes-port .cp-agents { color:var(--home-agents-ink); }.home-notes-port .type-text { flex:none; color:var(--home-faint); opacity:.9; }.home-notes-port .type-text::before { content:"· "; }.home-notes-port .note-card h4 { overflow:hidden; margin:0 0 2px; padding-right:58px; font-size:13px; font-weight:600; text-overflow:ellipsis; white-space:nowrap; }.home-notes-port .note-card p { overflow:hidden; margin:0 0 5px; color:var(--home-soft); font-size:11.5px; line-height:1.35; text-overflow:ellipsis; white-space:nowrap; }.home-notes-port .date { margin-left:auto; color:var(--home-faint); font-size:9.5px; }.home-notes-port .note-kebab { align-self:center; color:var(--home-faint); font-size:15px; }
.home-notes-port .recent-block .note-card { margin-bottom:8px; border:1.5px solid var(--home-line); border-radius:14px; background:var(--home-glass); box-shadow:0 1px 5px rgba(60,80,70,.05); padding:11px 10px 11px 13px; backdrop-filter:blur(11px); -webkit-backdrop-filter:blur(11px); }.home-notes-port .recent-block .note-card::before { display:none; }.home-notes-port .recent-block .note-card.nc-sport { border-color:rgba(76,175,125,.5); }.home-notes-port .recent-block .note-card.nc-home { border-color:rgba(91,141,239,.5); }.home-notes-port .recent-block .note-card.nc-agents { border-color:rgba(227,178,60,.55); }
.home-notes-port .expand-btn { display:flex; align-items:center; justify-content:center; width:calc(100% + 16px); gap:5px; margin:0 -8px; border:0; border-top:1px solid var(--home-line); background:transparent; color:var(--home-accent); padding:8px; font:600 12px inherit; }.home-notes-port .dashed { margin:2px 6px 16px; border:0; border-top:1.5px dashed rgba(120,135,130,.35); }
.home-notes-port .cat-grid { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin:0 -16px 14px; padding:0 10px; }.home-notes-port .cat-card { position:relative; overflow:hidden; margin:0; border:1px solid rgba(255,255,255,.55); border-radius:20px; background:rgba(255,255,255,.42); box-shadow:0 1px 5px rgba(60,80,70,.045); padding:0 8px; backdrop-filter:blur(11px); -webkit-backdrop-filter:blur(11px); }.home-notes-port .cat-card.wide { grid-column:1 / -1; }.home-notes-port .cat-card.c-sport { border-color:rgba(76,175,125,.35); }.home-notes-port .cat-card.c-home { border-color:rgba(91,141,239,.32); }.home-notes-port .cat-card.c-agents { border-color:rgba(227,178,60,.35); }.home-notes-port .cat-head { display:flex; align-items:center; gap:8px; padding:11px 3px 4px; }.home-notes-port .cat-emoji { flex:none; font-size:16px; }.home-notes-port .cat-head h3 { flex:1; margin:0; font-size:14.5px; font-weight:700; }.home-notes-port .cat-head .cat-count { color:var(--home-faint); font-size:12px; font-weight:600; }.home-notes-port .c-sport .cat-head h3 { color:var(--home-sport); }.home-notes-port .c-home .cat-head h3 { color:var(--home-home); }.home-notes-port .c-agents .cat-head h3 { color:var(--home-agents-ink); }.home-notes-port .notes-wrap { display:block; }.home-notes-port .cat-card .notes-wrap .note-card { padding:10px 6px 10px 13px; margin-bottom:8px; }.home-notes-port .cat-card .notes-wrap .note-card h4 { font-size:12px; }.home-notes-port .cat-card .notes-wrap .note-card p { margin-bottom:4px; font-size:10.5px; }.home-notes-port .cat-sub-pills { display:flex; flex-wrap:wrap; gap:6px; padding:8px 3px 10px; }.home-notes-port .cat-sub-pill { border:1px solid var(--home-line); border-radius:12px; background:var(--home-glass); color:var(--home-soft); padding:5px 10px; font-size:11px; font-weight:600; }.home-notes-port .cat-sub-pill b { margin-left:2px; color:var(--home-accent); }.home-notes-port .cat-more { display:flex; align-items:center; justify-content:space-between; width:calc(100% + 16px); margin:0 -8px; border:0; border-top:1px solid var(--home-line); background:transparent; color:var(--home-faint); padding:7px 11px 9px; font:10.5px inherit; text-align:left; }.home-notes-port .cat-more b { color:var(--home-soft); font-weight:600; }
.home-notes-fab { position:absolute; z-index:20; right:18px; bottom:calc(96px + env(safe-area-inset-bottom,0px)); display:grid; place-items:center; width:56px; height:56px; border:1px solid rgba(255,255,255,.5); border-radius:16px; background:rgba(62,155,95,.88); box-shadow:0 8px 22px rgba(62,155,95,.35); color:#fff; font-size:27px; backdrop-filter:blur(8px); -webkit-backdrop-filter:blur(8px); }.home-notes-fab:active { transform:scale(.92); }
.home-notes-hotbar { position:absolute; z-index:15; right:0; bottom:0; left:0; display:flex; justify-content:center; padding:0 16px calc(16px + env(safe-area-inset-bottom,0px)); pointer-events:none; }.home-notes-hotbar .hotbar { display:flex; align-items:center; justify-content:space-around; width:100%; max-width:368px; border:1px solid rgba(255,255,255,.8); border-radius:28px; background:rgba(255,255,255,.55); box-shadow:0 4px 24px rgba(60,80,70,.10),inset 0 1px 0 rgba(255,255,255,.9); padding:8px 10px; pointer-events:auto; backdrop-filter:blur(20px) saturate(1.4); -webkit-backdrop-filter:blur(20px) saturate(1.4); }.home-notes-hotbar .hot-btn { display:flex; flex:1; flex-direction:column; align-items:center; gap:3px; border:0; border-radius:16px; background:transparent; color:var(--home-soft); padding:6px 4px; font-family:inherit; }.home-notes-hotbar .hot-btn span { font-size:10px; font-weight:500; }.home-notes-hotbar .hot-btn i { font-size:21px; }.home-notes-hotbar .hot-btn:active { box-shadow:0 0 0 1px rgba(62,155,95,.35),0 2px 10px rgba(62,155,95,.18); background:rgba(255,255,255,.75); color:var(--home-accent); }
@media (max-width:370px) { .home-notes-port .cat-grid { gap:6px; padding:0 8px; }.home-notes-port .cat-sub-pill { padding:4px 7px; font-size:10px; } }

/* v11 Notes-only views: scoped so Chats and Tasks keep their existing bodies. */
.unified-notes-page { min-height:100%; color:#23262b; font-family:"Golos Text",system-ui,sans-serif; padding:2px 0 112px; }
.unified-notes-page-head { display:grid; grid-template-columns:36px minmax(0,1fr) 36px; align-items:center; gap:9px; margin:5px 0 15px; }
.unified-notes-page-head small,.unified-notes-sheet-kicker { color:#66707b; font-size:11px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; }
.unified-notes-page-head h1 { margin:2px 0 0; font-family:"Unbounded",system-ui,sans-serif; font-size:19px; letter-spacing:-.03em; }
.unified-notes-back,.unified-notes-page-add { display:grid; place-items:center; width:34px; height:34px; border:1px solid rgba(255,255,255,.78); border-radius:50%; background:rgba(255,255,255,.62); box-shadow:0 2px 8px rgba(60,80,70,.07); color:#66707b; }
.unified-notes-page-add { color:#3e9b5f; }
.unified-notes-collection { display:grid; gap:8px; }
.unified-notes-note-card { position:relative; display:grid; grid-template-columns:minmax(0,1fr) 32px; gap:5px; overflow:hidden; border:1.5px solid rgba(140,155,150,.20); border-radius:15px; background:rgba(255,255,255,.58); box-shadow:0 2px 9px rgba(60,80,70,.05); }
.unified-notes-note-card::before { content:""; position:absolute; inset:0 auto 0 0; width:24%; border:1.5px solid #4caf7d; border-right:0; border-bottom:0; border-radius:14px 0 0 0; pointer-events:none; }.unified-notes-note-card.tone-home::before { border-color:#5b8def; }.unified-notes-note-card.tone-agents::before { border-color:#e3b23c; }
.unified-notes-note-main { display:flex; min-width:0; gap:9px; border:0; background:transparent; color:#23262b; padding:12px 5px 12px 13px; text-align:left; }
.unified-notes-note-emoji { display:grid; place-items:center; width:24px; flex:none; color:#3e9b5f; font-size:18px; }.tone-home .unified-notes-note-emoji { color:#5b8def; }.tone-agents .unified-notes-note-emoji { color:#c29222; }
.unified-notes-note-copy { display:grid; min-width:0; gap:3px; }.unified-notes-note-copy b,.unified-notes-note-copy small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.unified-notes-note-copy b { padding-right:5px; font-size:13px; }.unified-notes-note-copy small { color:#66707b; font-size:11px; }
.unified-notes-note-corner { color:#98a1ab; font-size:9px; font-weight:600; }.unified-notes-note-meta { display:flex; align-items:center; gap:4px; overflow:hidden; color:#66707b; font-size:9px; }.unified-notes-note-meta span,.unified-notes-chip-row span { border-radius:12px; background:rgba(140,155,150,.12); padding:2px 6px; white-space:nowrap; }.unified-notes-note-meta em { overflow:hidden; margin-left:auto; color:#98a1ab; font-size:9px; font-style:normal; text-overflow:ellipsis; white-space:nowrap; }
.unified-notes-card-menu { align-self:center; width:30px; height:34px; border:0; border-radius:9px; background:transparent; color:#98a1ab; }
.unified-notes-empty { display:grid; justify-items:center; gap:8px; border:1px dashed rgba(140,155,150,.35); border-radius:16px; background:rgba(255,255,255,.32); color:#66707b; padding:42px 16px; font-size:12px; text-align:center; }.unified-notes-empty i { color:#3e9b5f; font-size:26px; }
.unified-notes-category-screen { display:grid; gap:12px; }.unified-notes-category-hero { display:flex; align-items:center; gap:11px; border:1px solid rgba(255,255,255,.68); border-radius:19px; background:rgba(255,255,255,.47); padding:12px; }.unified-notes-category-hero span { font-size:25px; }.unified-notes-category-hero p { margin:0; color:#66707b; font-size:12px; }
.unified-notes-subcategory-screen { display:grid; gap:7px; }.unified-notes-subcategory { display:grid; grid-template-columns:25px minmax(0,1fr) auto 16px; align-items:center; gap:8px; border:1px solid rgba(255,255,255,.72); border-radius:14px; background:rgba(255,255,255,.55); color:#23262b; padding:10px; text-align:left; }.unified-notes-subcategory b { overflow:hidden; font-size:13px; text-overflow:ellipsis; white-space:nowrap; }.unified-notes-subcategory small,.unified-notes-subcategory i { color:#98a1ab; font-size:11px; }
.unified-notes-hotbar { position:absolute; z-index:8; right:13px; bottom:calc(10px + env(safe-area-inset-bottom,0px)); left:13px; display:grid; grid-template-columns:repeat(3,1fr); gap:3px; border:1px solid rgba(255,255,255,.80); border-radius:23px; background:rgba(255,255,255,.72); box-shadow:0 9px 28px rgba(37,61,54,.14); padding:7px; backdrop-filter:blur(18px) saturate(1.3); }.unified-notes-hotbar button { display:grid; justify-items:center; gap:3px; border:0; border-radius:15px; background:transparent; color:#66707b; padding:5px; }.unified-notes-hotbar i { font-size:18px; }.unified-notes-hotbar span { font-size:9px; }
.unified-notes-fab { position:absolute; z-index:10; right:19px; bottom:calc(87px + env(safe-area-inset-bottom,0px)); display:grid; place-items:center; width:54px; height:54px; border:1px solid rgba(255,255,255,.5); border-radius:16px; background:rgba(62,155,95,.9); box-shadow:0 8px 22px rgba(62,155,95,.35); color:#fff; font-size:25px; }
.unified-sheet .unified-notes-note-view,.unified-sheet .unified-notes-editor,.unified-sheet .unified-notes-card-actions { display:grid; gap:12px; }.unified-sheet .unified-notes-note-view h2,.unified-sheet .unified-notes-card-actions h2 { margin:0; font-family:"Unbounded",system-ui,sans-serif; font-size:18px; line-height:1.35; }.unified-notes-note-body { color:#46505a; font-size:14px; line-height:1.55; white-space:pre-wrap; }.unified-notes-chip-row { display:flex; flex-wrap:wrap; gap:5px; color:#66707b; font-size:11px; }
.unified-notes-sheet-actions { display:grid; grid-template-columns:1fr 1fr; gap:8px; }.unified-notes-sheet-actions button,.unified-notes-card-actions button { min-height:43px; border:1px solid rgba(62,155,95,.25); border-radius:13px; background:rgba(62,155,95,.09); color:#287642; font:600 12px inherit; }.unified-notes-card-actions button { display:flex; align-items:center; gap:10px; width:100%; border-color:rgba(140,155,150,.18); background:rgba(255,255,255,.66); color:#46505a; padding:0 12px; text-align:left; }
.unified-notes-editor input,.unified-notes-editor textarea,.unified-notes-editor select { width:100%; border:1px solid rgba(140,155,150,.23); border-radius:13px; background:rgba(255,255,255,.82); color:#23262b; font:inherit; padding:11px 12px; }.unified-notes-editor textarea { min-height:155px; resize:vertical; }.unified-notes-editor label { display:grid; gap:6px; color:#66707b; font-size:11px; font-weight:600; }.unified-notes-save { min-height:47px; border:0; border-radius:14px; background:#3e9b5f; color:#fff; font:700 13px inherit; }
@media (min-width:561px) { .unified-notes-hotbar,.unified-notes-fab { position:fixed; max-width:534px; margin:auto; }.unified-notes-hotbar { right:0; left:0; }.unified-notes-fab { right:calc(50% - 245px); } }

/* Direct FRAME_NOTES_B64 port — isolated from Chats and Tasks. */
.frame-notes-root { --ink:#23262b; --ink-soft:#66707b; --ink-faint:#98a1ab; --line:rgba(140,155,150,.18); --glass:rgba(255,255,255,.55); --accent:#3e9b5f; --cat-sport:#4caf7d; --cat-home:#5b8def; --cat-agents:#e3b23c; min-height:100%; color:var(--ink); font-family:"Golos Text",system-ui,sans-serif; }
.frame-notes-root .content { overflow-y:auto; min-height:100%; padding:8px 16px 132px; }
.frame-notes-root .top-sticky { position:sticky; z-index:3; top:0; margin:0 -16px 4px; background:rgba(247,250,248,.68); padding:14px 16px 10px; backdrop-filter:blur(18px) saturate(1.3); }
.frame-notes-root .greeting-row { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; margin:8px 2px 14px; }
.frame-notes-root .greeting h1 { margin:0; font-family:"Unbounded",system-ui,sans-serif; font-size:19px; font-weight:600; letter-spacing:-.01em; }.frame-notes-root .greeting h1 span { color:var(--accent); }.frame-notes-root .date { margin-top:3px; color:var(--ink-faint); font-size:12px; }
.frame-notes-root .stat-chip { display:flex; align-items:center; gap:5px; border:1px solid rgba(62,155,95,.2); border-radius:16px; background:rgba(62,155,95,.08); color:#287642; padding:8px 10px; font:600 10px inherit; }.frame-notes-root .stat-chip i { font-size:15px; }
.frame-notes-root .section-label { display:flex; align-items:center; gap:5px; margin:16px 3px 8px; color:var(--ink-soft); font-size:12px; font-weight:700; }.frame-notes-root .section-label .count { color:var(--ink-faint); font-weight:500; }.frame-notes-root .gear-btn { display:grid; place-items:center; width:26px; height:26px; margin-left:auto; border:0; border-radius:50%; background:transparent; color:var(--ink-faint); }
.frame-notes-root .pinned-wrap { margin-bottom:17px; border:1px solid rgba(76,175,125,.18); border-radius:20px; background:rgba(76,175,125,.08); padding:12px 10px 10px; backdrop-filter:blur(10px); }.frame-notes-root .pinned-row { display:flex; gap:10px; }.frame-notes-root .pinned-card { position:relative; min-width:0; flex:1; border:1.5px solid var(--line); border-radius:14px; background:var(--glass); box-shadow:0 2px 12px rgba(60,80,70,.07); }.frame-notes-root .pinned-card.nc-home { border-color:rgba(91,141,239,.5); }.frame-notes-root .pinned-card.nc-agents { border-color:rgba(227,178,60,.55); }.frame-notes-root .pinned-card .frame-note-open { display:block; width:100%; min-height:110px; border:0; background:transparent; color:var(--ink); padding:10px 11px; text-align:left; }.frame-notes-root .pinned-card .pin { color:var(--accent); font-size:13px; }.frame-notes-root .pinned-card h4 { overflow:hidden; margin:8px 18px 3px 0; font-size:12.5px; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .pinned-card p { display:-webkit-box; overflow:hidden; min-height:28px; margin:0 0 5px; color:var(--ink-soft); font-size:10.5px; line-height:1.35; -webkit-box-orient:vertical; -webkit-line-clamp:2; }.frame-notes-root .pinned-kebab { position:absolute; top:5px; right:5px; border:0; background:transparent; color:var(--ink-faint); }
.frame-notes-root .meta { display:flex; align-items:center; gap:5px; min-width:0; }.frame-notes-root .ava { display:inline-grid; place-items:center; width:18px; height:18px; flex:none; border:1.5px solid #fff; border-radius:50%; background:#3e9b5f; color:#fff; font-size:8px; font-weight:700; }.frame-notes-root .tag { overflow:hidden; max-width:110px; border-radius:20px; background:rgba(140,155,150,.12); color:var(--ink-soft); padding:2px 7px; font-size:9px; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .date { margin-left:auto; color:var(--ink-faint); font-size:9.5px; }.frame-notes-root .pinned-nav { display:flex; align-items:center; justify-content:center; gap:10px; padding-top:10px; }.frame-notes-root .pn-arrow { display:grid; place-items:center; width:28px; height:28px; border:0; border-radius:50%; background:#fff; color:var(--ink-soft); }.frame-notes-root .pn-arrow:disabled { opacity:.35; }.frame-notes-root .pn-dots { display:flex; gap:5px; }.frame-notes-root .pn-dot { width:16px; height:5px; border-radius:3px; background:var(--accent); }
.frame-notes-root .recent-block { margin-bottom:18px; }.frame-notes-root .note-card { position:relative; display:grid; grid-template-columns:minmax(0,1fr) 30px; width:100%; overflow:hidden; margin-bottom:8px; border:1.5px solid var(--line); border-radius:14px; background:var(--glass); box-shadow:0 1px 5px rgba(60,80,70,.05); }.frame-notes-root .note-card::before { position:absolute; top:0; left:0; width:25%; height:18px; border:1.5px solid var(--cat-sport); border-right:0; border-bottom:0; border-radius:14px 0 0 0; content:""; pointer-events:none; }.frame-notes-root .note-card.nc-home::before { border-color:var(--cat-home); }.frame-notes-root .note-card.nc-agents::before { border-color:var(--cat-agents); }.frame-notes-root .frame-note-open { display:flex; min-width:0; gap:9px; border:0; background:transparent; color:var(--ink); padding:11px 5px 11px 13px; text-align:left; }.frame-notes-root .note-emoji { display:grid; place-items:center; width:24px; flex:none; color:var(--accent); font-size:17px; }.frame-notes-root .body { display:grid; min-width:0; gap:3px; }.frame-notes-root .note-corner { display:flex; gap:4px; overflow:hidden; font-size:9px; font-weight:600; }.frame-notes-root .cat-path { overflow:hidden; color:var(--cat-sport); text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .nc-home .cat-path { color:var(--cat-home); }.frame-notes-root .nc-agents .cat-path { color:#c29222; }.frame-notes-root .type-text { color:var(--ink-faint); white-space:nowrap; }.frame-notes-root .type-text::before { content:"· "; }.frame-notes-root .note-card b { overflow:hidden; padding-right:4px; font-size:13px; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .note-card p { overflow:hidden; margin:0; color:var(--ink-soft); font-size:11.5px; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .note-kebab { align-self:center; border:0; background:transparent; color:var(--ink-faint); font-size:15px; }
.frame-notes-root .expand-btn,.frame-notes-root .cat-more { display:flex; align-items:center; justify-content:center; width:100%; gap:5px; border:0; border-top:1px solid var(--line); background:transparent; color:var(--accent); padding:8px; font:600 12px inherit; }.frame-notes-root .dashed { margin:2px 6px 16px; border:0; border-top:1.5px dashed rgba(120,135,130,.35); }.frame-notes-root .cat-grid { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin:0 -6px; }.frame-notes-root .cat-card { overflow:hidden; border:1px solid rgba(255,255,255,.55); border-radius:20px; background:rgba(255,255,255,.42); box-shadow:0 1px 5px rgba(60,80,70,.045); padding:0 8px; }.frame-notes-root .cat-card.wide { grid-column:1 / -1; }.frame-notes-root .cat-head { display:flex; align-items:center; width:100%; gap:8px; border:0; background:transparent; color:var(--ink); padding:11px 3px 4px; text-align:left; }.frame-notes-root .cat-emoji { font-size:16px; }.frame-notes-root .cat-head h3 { overflow:hidden; flex:1; margin:0; font-size:14.5px; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .cat-count { color:var(--ink-faint); font-size:12px; font-weight:600; }.frame-notes-root .c-sport h3 { color:var(--cat-sport); }.frame-notes-root .c-home h3 { color:var(--cat-home); }.frame-notes-root .c-agents h3 { color:#c29222; }.frame-notes-root .cat-sub-pills { display:flex; flex-wrap:wrap; gap:6px; padding:8px 3px 10px; }.frame-notes-root .cat-sub-pill { border:1px solid var(--line); border-radius:12px; background:var(--glass); color:var(--ink-soft); padding:5px 8px; font:600 10px inherit; }.frame-notes-root .cat-sub-pill b { color:var(--accent); }.frame-notes-root .cat-more { justify-content:space-between; color:var(--ink-faint); font-size:10.5px; }
.frame-notes-hotbar { position:absolute; z-index:15; right:0; bottom:0; left:0; display:flex; justify-content:center; padding:0 16px calc(16px + env(safe-area-inset-bottom,0px)); pointer-events:none; }.frame-notes-hotbar .hotbar { display:flex; width:100%; max-width:368px; justify-content:space-around; border:1px solid rgba(255,255,255,.8); border-radius:28px; background:rgba(255,255,255,.55); box-shadow:0 4px 24px rgba(60,80,70,.1); padding:8px 10px; pointer-events:auto; backdrop-filter:blur(20px) saturate(1.4); }.frame-notes-hotbar .hot-btn { display:flex; flex:1; flex-direction:column; align-items:center; gap:3px; border:0; border-radius:16px; background:transparent; color:var(--ink-soft); padding:6px 4px; }.frame-notes-hotbar .hot-btn i { font-size:21px; }.frame-notes-hotbar .hot-btn span { font-size:10px; font-weight:500; }.frame-notes-fab { position:absolute; z-index:20; right:18px; bottom:calc(96px + env(safe-area-inset-bottom,0px)); display:grid; place-items:center; width:56px; height:56px; border:1px solid rgba(255,255,255,.5); border-radius:16px; background:rgba(62,155,95,.88); box-shadow:0 8px 22px rgba(62,155,95,.35); color:#fff; font-size:27px; }
.frame-notes-screen,.frame-notes-reminders-screen { position:absolute; z-index:28; inset:0; overflow:hidden; background:linear-gradient(180deg,#f7faf8,#f2f6f4); }.frame-notes-root .ns-head,.frame-notes-root .rem-head { display:grid; grid-template-columns:38px minmax(0,1fr) 38px; align-items:center; gap:10px; border-bottom:1px solid rgba(140,155,150,.13); background:rgba(247,250,248,.8); padding:14px 16px 10px; backdrop-filter:blur(18px); }.frame-notes-root .ns-back,.frame-notes-root .ns-gear,.frame-notes-root .rem-back { display:grid; place-items:center; width:36px; height:36px; border:1px solid rgba(255,255,255,.75); border-radius:50%; background:var(--glass); color:var(--ink-soft); }.frame-notes-root .ns-titles h1,.frame-notes-root .rem-titles h1 { margin:0; font-family:"Unbounded",system-ui,sans-serif; font-size:16px; letter-spacing:-.03em; }.frame-notes-root .ns-titles p,.frame-notes-root .rem-titles p { margin:3px 0 0; color:var(--ink-soft); font-size:11px; }.frame-notes-root .ns-body,.frame-notes-root .rem-body { height:calc(100% - 64px); overflow:auto; padding:14px 16px 112px; }.frame-notes-root .ns-group { margin:16px 3px 8px; color:var(--ink-soft); font-size:12px; font-weight:700; }.frame-notes-root .ns-cat-hero { display:flex; align-items:center; gap:12px; overflow:hidden; border-radius:20px; background:linear-gradient(135deg,#4caf7d,#84d6a9); color:#fff; padding:16px; }.frame-notes-root .ns-cat-hero.tone-home { background:linear-gradient(135deg,#5b8def,#93b6ff); }.frame-notes-root .ns-cat-hero.tone-agents { background:linear-gradient(135deg,#d99d2d,#f0d376); }.frame-notes-root .hero-emoji { font-size:32px; }.frame-notes-root .hero-info h2 { margin:0; font-size:19px; }.frame-notes-root .hero-sub { margin-top:4px; font-size:11px; opacity:.88; }.frame-notes-root .ns-subcard { display:grid; grid-template-columns:5px minmax(0,1fr) 20px; align-items:center; width:100%; gap:10px; margin-bottom:8px; border:1px solid var(--line); border-radius:14px; background:var(--glass); color:var(--ink); padding:11px; text-align:left; }.frame-notes-root .sub-marker { width:5px; height:29px; border-radius:5px; background:var(--cat-sport); }.frame-notes-root .sub-marker.tone-home { background:var(--cat-home); }.frame-notes-root .sub-marker.tone-agents { background:var(--cat-agents); }.frame-notes-root .sub-info { display:grid; gap:2px; min-width:0; }.frame-notes-root .sub-info b { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .sub-info small { color:var(--ink-faint); font-size:10px; }.frame-notes-root .subcard i { color:var(--ink-faint); }.frame-notes-root .cal-top { margin-bottom:12px; }.frame-notes-root .cal-bar { display:flex; align-items:center; justify-content:space-between; border:1px solid var(--line); border-radius:14px; background:var(--glass); padding:6px; }.frame-notes-root .navbtn { display:grid; place-items:center; width:32px; height:32px; border:0; border-radius:9px; background:transparent; color:var(--ink-faint); }
.frame-notes-root .ns-empty { display:grid; justify-items:center; gap:8px; border:1px dashed rgba(140,155,150,.35); border-radius:16px; background:rgba(255,255,255,.32); color:var(--ink-soft); padding:38px 16px; text-align:center; }.frame-notes-root .ns-empty .eico { display:grid; place-items:center; width:44px; height:44px; border-radius:50%; background:rgba(62,155,95,.1); color:var(--accent); font-size:23px; }.frame-notes-root .ns-empty h3 { margin:0; color:var(--ink); font-size:14px; }.frame-notes-root .ns-empty p { margin:0; font-size:11px; line-height:1.45; }.frame-notes-root .ns-empty.disabled { opacity:.75; }.frame-notes-root .frame-notes-placeholder { border-radius:10px; background:rgba(227,178,60,.15); color:#8b671a; padding:4px 8px; font-size:10px; font-weight:700; }.frame-notes-root .frame-notes-disabled { color:var(--ink-faint); font-size:10px; }.frame-notes-root .ns-hint { border:1px dashed var(--line); border-radius:13px; color:var(--ink-soft); padding:12px; font-size:11px; }
.frame-notes-root .sheet-backdrop,.frame-notes-root .sheet-backdrop-g,.frame-notes-root .modal-backdrop-g { position:absolute; z-index:40; inset:0; background:rgba(27,34,31,.28); backdrop-filter:blur(2px); }.frame-notes-root .sheet,.frame-notes-root .sheet-g { position:absolute; z-index:41; right:0; bottom:0; left:0; border-radius:24px 24px 0 0; background:#f9fbfa; box-shadow:0 -10px 35px rgba(32,48,41,.18); padding:10px 18px calc(24px + env(safe-area-inset-bottom,0px)); }.frame-notes-root .grip { width:38px; height:4px; margin:1px auto 15px; border-radius:9px; background:rgba(102,112,123,.28); }.frame-notes-root .sheet h3,.frame-notes-root .sheet-g h3 { margin:0 0 14px; font-family:"Unbounded",system-ui,sans-serif; font-size:15px; }.frame-notes-root .sheet-row { display:flex; align-items:center; justify-content:space-between; gap:12px; border-top:1px solid var(--line); padding:13px 0; color:var(--ink-soft); font-size:12px; }.frame-notes-root .switch { position:relative; width:42px; height:25px; border:0; border-radius:20px; background:#c5ccc8; }.frame-notes-root .switch i { position:absolute; top:3px; left:3px; width:19px; height:19px; border-radius:50%; background:#fff; box-shadow:0 1px 3px rgba(0,0,0,.18); transition:.15s; }.frame-notes-root .switch.on { background:var(--accent); }.frame-notes-root .switch.on i { transform:translateX(17px); }.frame-notes-root .sheet-hint { margin:10px 0 0; color:var(--ink-faint); font-size:11px; line-height:1.45; }.frame-notes-root .sheet-link { display:flex; align-items:center; justify-content:space-between; width:100%; border:0; border-top:1px solid var(--line); background:transparent; color:var(--ink); padding:13px 0; text-align:left; }.frame-notes-root .sheet-link.disabled { color:var(--ink-faint); }.frame-notes-root .frame-notes-range { accent-color:var(--accent); }.frame-notes-root .menu-action-grid { display:grid; grid-template-columns:1fr 1fr; gap:9px; }.frame-notes-root .menu-action-card { display:grid; justify-items:center; gap:7px; min-height:92px; border:1px solid var(--line); border-radius:16px; background:var(--glass); color:var(--ink-soft); padding:10px; font-size:11px; }.frame-notes-root .menu-action-card i { color:var(--accent); font-size:22px; }.frame-notes-root .menu-action-card.disabled { opacity:.6; }
.frame-notes-root .note-menu-modal,.frame-notes-menu-modal { position:absolute; z-index:51; top:50%; right:18px; left:18px; transform:translateY(-50%); overflow:hidden; border:1px solid rgba(255,255,255,.8); border-radius:20px; background:#fbfcfb; box-shadow:0 16px 48px rgba(25,40,32,.24); padding:8px; }.frame-notes-root .note-menu-modal button { display:flex; align-items:center; width:100%; gap:10px; border:0; border-radius:12px; background:transparent; color:var(--ink); padding:12px 10px; text-align:left; }.frame-notes-root .note-menu-modal button:hover { background:rgba(62,155,95,.08); }.frame-notes-root .note-menu-modal .nm-header { display:flex; align-items:center; justify-content:space-between; gap:8px; border-bottom:1px solid var(--line); padding:8px; }.frame-notes-root .note-menu-modal .nm-header b { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.frame-notes-root .note-menu-modal .nm-header button { width:auto; padding:4px; }.frame-notes-root .note-menu-modal .danger,.frame-notes-root .sheet-g .danger { color:#c53b3b; }.frame-notes-root .reminders-screen { position:absolute; z-index:52; inset:0; background:linear-gradient(180deg,#f7faf8,#f2f6f4); }.frame-notes-root .frame-notes-stat { display:grid; grid-template-columns:28px minmax(0,1fr) auto; align-items:center; gap:9px; margin-bottom:8px; border:1px solid var(--line); border-radius:14px; background:var(--glass); padding:12px; }.frame-notes-root .frame-notes-stat strong { color:var(--accent); }.frame-notes-root .pop { position:absolute; z-index:55; top:56px; right:16px; min-width:150px; border:1px solid rgba(255,255,255,.8); border-radius:14px; background:#fff; box-shadow:0 10px 28px rgba(25,40,32,.18); padding:6px; }.frame-notes-root .pop button { width:100%; border:0; border-radius:9px; background:transparent; color:var(--ink-soft); padding:9px; text-align:left; }.frame-notes-root .toast { position:absolute; z-index:70; right:20px; bottom:94px; left:20px; transform:translateY(14px); border-radius:13px; background:#263c32; box-shadow:0 8px 24px rgba(25,40,32,.24); color:#fff; opacity:0; padding:11px 13px; font-size:11px; pointer-events:none; transition:.18s; }.frame-notes-root .toast.show { transform:translateY(0); opacity:1; }
@media (max-width:370px) { .frame-notes-root .cat-grid { gap:6px; }.frame-notes-root .cat-sub-pill { padding:4px 6px; font-size:9px; }.frame-notes-root .pinned-card p { font-size:9.5px; } }
.frame-notes-home { min-height:100%; }
.frame-notes-sheet { max-height:86%; }

/* Direct FRAME_NOTE_CREATE_B64 port. */
.frame-note-create { position:absolute; z-index:90; inset:0; overflow:hidden; background:#f3f7f5; color:#23262b; font-family:"Golos Text",system-ui,sans-serif; }.frame-note-create .phone { position:relative; display:flex; min-height:100%; flex-direction:column; overflow:hidden; background:radial-gradient(ellipse 90% 55% at 85% -5%,rgba(122,178,255,.2),transparent 60%),radial-gradient(ellipse 80% 50% at -10% 25%,rgba(126,214,165,.2),transparent 60%),linear-gradient(180deg,#f7faf8,#f2f6f4); }
.frame-note-create .head { position:relative; z-index:3; display:flex; align-items:center; gap:9px; border-bottom:1px solid rgba(140,155,150,.2); background:rgba(247,250,248,.72); padding:12px; backdrop-filter:blur(18px) saturate(1.3); }.frame-note-create .hbtn { display:grid; width:38px; height:38px; flex:none; place-items:center; border:1px solid rgba(255,255,255,.8); border-radius:50%; background:rgba(255,255,255,.55); color:#66707b; }.frame-note-create .hbtn.on { border-color:#f0c94d; background:#fff4d6; color:#c9971f; }.frame-note-create .type-plate { display:flex; min-width:0; flex:1; align-items:center; gap:9px; border:1px solid rgba(255,255,255,.8); border-radius:20px; background:rgba(255,255,255,.55); color:#23262b; padding:6px 12px 6px 6px; text-align:left; }.frame-note-create .tp-ic { display:grid; width:32px; height:32px; flex:none; place-items:center; border-radius:11px; background:rgba(62,155,95,.1); font-size:16px; }.frame-note-create .tp-info { display:grid; min-width:0; gap:2px; }.frame-note-create .tp-info b,.frame-note-create .tp-info small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.frame-note-create .tp-info b { font-size:13.5px; }.frame-note-create .tp-info small { color:#98a1ab; font-size:10.5px; }.frame-note-create .head-actions { display:flex; gap:7px; flex:none; }
.frame-create-editor,.frame-note-create .editor { display:flex; min-height:0; flex:1; flex-direction:column; padding:14px 16px 0; }.frame-note-create .title-row { display:flex; align-items:center; gap:9px; }.frame-note-create .note-emoji-badge { display:grid; width:36px; height:36px; place-items:center; border:1.5px solid rgba(140,155,150,.2); border-radius:11px; background:rgba(255,255,255,.55); font-size:20px; }.frame-note-create .note-emoji-badge.empty::after { color:#98a1ab; content:"＋"; font-size:16px; }.frame-note-create .editor-scroll { display:flex; min-height:0; flex:1; flex-direction:column; overflow:auto; }.frame-note-create .plain-field { width:100%; border:0; outline:0; background:transparent; color:#23262b; font:inherit; }.frame-note-create .plain-text { min-height:185px; flex:1; resize:none; padding:13px 3px; font-size:16px; line-height:1.55; }.frame-note-create .plain-text::placeholder { color:#98a1ab; }.frame-note-create .voice-bubble,.frame-note-create .img-flow,.frame-note-create .rel-block { margin:6px 0 12px; border:1px dashed rgba(140,155,150,.35); border-radius:14px; background:rgba(255,255,255,.35); color:#98a1ab; padding:10px; font-size:11px; }.frame-note-create .voice-bubble { display:flex; align-items:center; gap:8px; }.frame-note-create .voice-bubble button { border:0; border-radius:50%; background:#e6ebe8; color:#98a1ab; padding:5px 7px; }.frame-note-create .voice-bubble #voiceDur { margin-left:auto; }.frame-note-create .rel-block { display:block; }.frame-note-create .rel-head { display:flex; justify-content:space-between; color:#66707b; font-weight:700; }.frame-note-create .rel-list { margin-top:6px; color:#98a1ab; }
.frame-note-create .markup-accordion { display:none; max-height:42vh; overflow:auto; border-top:1px solid rgba(140,155,150,.16); background:rgba(247,250,248,.92); padding:12px 16px; }.frame-note-create .markup-accordion.show { display:block; }.frame-note-create .cat-grid { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin:0; }.frame-note-create .cat-col { display:grid; gap:6px; }.frame-note-create .select { width:100%; border:1.5px solid rgba(140,155,150,.2); border-radius:12px; background:#fff; color:#23262b; padding:9px; font:12px inherit; }.frame-note-create .select:disabled { opacity:.55; }.frame-note-create .frame-create-inline-add { border:0; background:transparent; color:#3e9b5f; padding:2px 0; font:11px inherit; text-align:left; }.frame-note-create .general-tags-block,.frame-note-create .cascade-col { margin-top:13px; }.frame-note-create .field-label { margin-bottom:7px; color:#66707b; font-size:11px; font-weight:700; }.frame-note-create .chips { display:flex; flex-wrap:wrap; gap:6px; align-items:center; }.frame-note-create .chip { border:1.5px solid rgba(140,155,150,.2); border-radius:20px; background:rgba(255,255,255,.55); color:#66707b; padding:6px 11px; font:12px inherit; }.frame-note-create .chip.on { border-color:transparent; background:#3e9b5f; color:#fff; font-weight:600; }.frame-note-create .chip-plus { width:27px; height:27px; border:1.5px dashed rgba(62,155,95,.35); border-radius:50%; background:transparent; color:#3e9b5f; font-size:15px; }.frame-note-create .frame-create-tag-add { display:flex; gap:6px; margin-top:8px; }.frame-note-create .frame-create-tag-add input { min-width:0; flex:1; border:1.5px solid rgba(140,155,150,.2); border-radius:10px; background:#fff; padding:8px; font:12px inherit; }.frame-note-create .frame-create-tag-add button { width:34px; border:0; border-radius:10px; background:#3e9b5f; color:#fff; }.frame-note-create .frame-create-muted { color:#98a1ab; font-size:10.5px; }
.frame-note-create .markup-strip { display:flex; align-items:center; justify-content:space-between; gap:8px; margin:0 12px 8px; border:1.5px solid rgba(140,155,150,.2); border-radius:14px; background:rgba(255,255,255,.55); color:#66707b; padding:10px 12px; font-size:11px; }.frame-note-create .markup-strip button { border:0; background:transparent; color:#3e9b5f; }.frame-note-create .fmt-toolbar { display:none; align-items:center; justify-content:center; gap:8px; margin:0 12px 8px; border:1px solid rgba(140,155,150,.18); border-radius:14px; background:#fff; padding:6px; }.frame-note-create .fmt-toolbar.show { display:flex; }.frame-note-create .fmt-toolbar button { width:31px; height:30px; border:0; border-radius:9px; background:rgba(62,155,95,.08); color:#287642; }
.frame-create-bottom-bar,.frame-note-create .bottom-bar { display:flex; align-items:center; justify-content:space-between; border-top:1px solid rgba(140,155,150,.16); background:rgba(247,250,248,.86); padding:10px 14px calc(12px + env(safe-area-inset-bottom,0px)); backdrop-filter:blur(16px); }.frame-note-create .bb-left,.frame-note-create .bb-right { display:flex; align-items:center; gap:8px; }.frame-note-create .bb-btn,.frame-note-create .bb-mic { display:grid; width:36px; height:36px; place-items:center; border:0; border-radius:11px; background:transparent; color:#66707b; }.frame-note-create .bb-btn:active,.frame-note-create .bb-mic:active { background:rgba(62,155,95,.1); color:#3e9b5f; }.frame-note-create .bb-aa .aa-label { font-size:16px; font-weight:700; }.frame-note-create .bb-save { display:grid; width:43px; height:43px; place-items:center; border:0; border-radius:14px; background:#3e9b5f; box-shadow:0 5px 14px rgba(62,155,95,.28); color:#fff; font-size:18px; }
.frame-note-create .sheet-backdrop,.frame-note-create .pop-scrim { position:absolute; z-index:8; inset:0; background:rgba(28,40,34,.27); backdrop-filter:blur(2px); }.frame-create-sheet,.frame-note-create .sheet { position:absolute; z-index:9; right:0; bottom:0; left:0; max-height:82%; overflow:auto; border-radius:24px 24px 0 0; background:#f9fbfa; box-shadow:0 -12px 36px rgba(29,43,36,.18); padding:10px 18px calc(24px + env(safe-area-inset-bottom,0px)); }.frame-note-create .grip { width:38px; height:4px; margin:1px auto 15px; border-radius:9px; background:rgba(102,112,123,.28); }.frame-note-create .sheet h3 { margin:0 0 12px; font-family:"Unbounded",system-ui,sans-serif; font-size:15px; }.frame-note-create .desc { margin:0 0 12px; color:#66707b; font-size:11px; line-height:1.45; }.frame-note-create .type-row-setting { display:grid; grid-template-columns:28px minmax(0,1fr) 20px; align-items:center; width:100%; gap:8px; border:0; border-top:1px solid rgba(140,155,150,.16); background:transparent; color:#23262b; padding:11px 3px; text-align:left; }.frame-note-create .type-row-setting span:nth-child(2) { display:grid; gap:2px; }.frame-note-create .type-row-setting small { color:#98a1ab; font-size:10px; }.frame-note-create .type-row-setting.sel { color:#287642; }.frame-note-create .frame-create-disabled-action { width:100%; border:1px dashed rgba(140,155,150,.3); border-radius:12px; background:transparent; color:#98a1ab; padding:10px; }.frame-note-create .action-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:8px; }.frame-note-create .action-card { display:grid; min-height:78px; place-items:center; gap:5px; border:1px solid rgba(140,155,150,.18); border-radius:14px; background:rgba(255,255,255,.6); color:#66707b; padding:7px; font:10px inherit; }.frame-note-create .action-card i { color:#3e9b5f; font-size:19px; }.frame-note-create .action-card.danger,.frame-note-create .action-card.danger i { color:#c24d48; }.frame-note-create .sheet-head { display:grid; grid-template-columns:35px minmax(0,1fr) 35px; align-items:center; margin-bottom:10px; }.frame-note-create .sheet-head h3 { margin:0; text-align:center; }.frame-note-create .sheet-rnd { display:grid; width:32px; height:32px; place-items:center; border:0; border-radius:50%; background:rgba(62,155,95,.1); color:#287642; }.frame-note-create .sheet-rnd.ghost { background:transparent; color:#98a1ab; }.frame-note-create #frameCreateClean { min-height:120px; border:1.5px solid rgba(140,155,150,.2); border-radius:14px; background:rgba(255,255,255,.55); padding:12px; }.frame-note-create .frame-create-primary { width:100%; margin-top:12px; border:0; border-radius:14px; background:#3e9b5f; color:#fff; padding:12px; font:600 13px inherit; }.frame-note-create .info-row,.frame-note-create .sheet-item { display:flex; align-items:center; width:100%; gap:10px; border:0; border-top:1px solid rgba(140,155,150,.16); background:transparent; color:#23262b; padding:12px 3px; text-align:left; }.frame-note-create .info-ic { display:grid; width:27px; height:27px; place-items:center; border-radius:9px; background:rgba(62,155,95,.1); color:#287642; }.frame-note-create .info-tx { flex:1; color:#66707b; }.frame-note-create .info-row small { color:#98a1ab; font-size:10px; }
.frame-note-create .emoji-search { display:flex; align-items:center; gap:7px; border:1.5px solid rgba(140,155,150,.2); border-radius:12px; background:#fff; color:#98a1ab; padding:8px 10px; }.frame-note-create .emoji-search input { width:100%; border:0; outline:0; background:transparent; font:12px inherit; }.frame-create-emoji-grid,.frame-note-create .emoji-scroll { display:grid; grid-template-columns:repeat(6,1fr); gap:7px; max-height:270px; overflow:auto; margin:12px 0; }.frame-note-create .emoji-cell { display:grid; aspect-ratio:1; place-items:center; border:1px solid rgba(140,155,150,.18); border-radius:11px; background:#fff; font-size:20px; }.frame-note-create .emoji-cell.on { border-color:#3e9b5f; background:rgba(62,155,95,.1); }.frame-note-create .emoji-remove { width:100%; border:0; background:transparent; color:#c24d48; padding:8px; }.frame-note-create .pop { position:absolute; z-index:12; bottom:66px; left:14px; min-width:180px; overflow:hidden; border:1px solid rgba(255,255,255,.8); border-radius:15px; background:#fff; box-shadow:0 10px 30px rgba(25,40,32,.2); padding:5px; }.frame-note-create .pop-item { display:flex; align-items:center; width:100%; border:0; border-radius:10px; background:transparent; color:#23262b; padding:10px; text-align:left; }.frame-note-create .modal-wrap { position:absolute; z-index:14; inset:0; display:grid; place-items:center; background:rgba(28,40,34,.3); padding:20px; }.frame-note-create .modal { width:min(100%,330px); border-radius:20px; background:#fff; box-shadow:0 16px 45px rgba(25,40,32,.25); padding:15px; }.frame-note-create .modal-head { display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; }.frame-note-create .modal-head h3 { margin:0; font-family:"Unbounded",system-ui,sans-serif; font-size:15px; }.frame-note-create .modal-x { border:0; background:transparent; color:#98a1ab; }.frame-note-create .rem-opt { display:flex; align-items:center; width:100%; gap:10px; border:0; border-top:1px solid rgba(140,155,150,.16); background:transparent; color:#23262b; padding:12px 0; text-align:left; }.frame-note-create .rem-opt i { color:#3e9b5f; font-size:20px; }.frame-note-create .rem-opt span { display:grid; gap:3px; }.frame-note-create .rem-opt small { color:#98a1ab; font-size:10px; }.frame-note-create .toast { position:absolute; z-index:20; right:18px; bottom:76px; left:18px; transform:translateY(12px); border-radius:13px; background:#263c32; color:#fff; opacity:0; padding:11px 13px; font-size:11px; pointer-events:none; transition:.18s; }.frame-note-create .toast.show { transform:translateY(0); opacity:1; }

/* Direct FRAME_NOTE_VIEW_B64 additions; the view deliberately shares the decoded editor shell. */
.frame-note-view { position:absolute; z-index:91; inset:0; }
.frame-view-meta { display:flex; align-items:center; gap:8px; border-bottom:1px solid rgba(140,155,150,.16); background:rgba(247,250,248,.62); padding:8px 16px; }
.frame-note-view .ava-btn { border:0; cursor:pointer; }
.frame-note-view .note-meta > span:not(.frame-view-status) { display:grid; gap:1px; min-width:0; }
.frame-note-view .note-meta b { color:#3b443f; font-size:11px; }.frame-note-view .note-meta small { color:#98a1ab; font-size:10px; }
.frame-view-status { margin-left:auto; max-width:118px; color:#b47b23; font-size:9px; line-height:1.25; text-align:right; }
.frame-view-sheet { max-height:82%; }
.frame-view-bottom-bar { box-shadow:0 -5px 16px rgba(40,57,48,.04); }

/* FRAME_CHATS_B64 Stage 1 Home / Chats. Decoded frame primitives, scoped to
   Chats so the established Notes and Tasks surfaces keep their own layout. */
.phone-shell[data-unified-shell].chats-stage1-active { position:relative; }
.phone-shell[data-unified-shell].chats-stage1-active > .unified-hotbar { display:none; }
.phone-shell[data-unified-shell].chats-stage1-active .unified-screen { padding:8px 16px calc(82px + env(safe-area-inset-bottom,0px)); }
.frame-chats-root {
  --ink:#23262b; --ink-soft:#66707b; --ink-faint:#98a1ab;
  --line:rgba(140,155,150,.18); --glass:rgba(255,255,255,.55);
  --accent:#3e9b5f; --accent-soft:rgba(62,155,95,.10);
  --overdue:#e5484d; --overdue-soft:rgba(229,72,77,.09);
  --r-lg:20px; --r-md:14px;
  min-height:100%; color:var(--ink); font-family:"Golos Text",system-ui,sans-serif;
}
.frame-chats-root .screen { display:block; min-height:100%; padding:0; overflow:visible; }
.frame-chats-root button,.frame-chats-root input,.frame-chats-root textarea { font:inherit; }
.frame-chats-root button { border:0; cursor:pointer; -webkit-tap-highlight-color:transparent; }
.frame-chats-root button:active { transform:none; }
.frame-chats-root .content { padding:4px 2px 8px; }

/* Greeting and two-row QuickCaptureComposer are direct FRAME_CHATS_B64 forms. */
.frame-chats-root .greeting-row { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; margin:8px 2px 14px; }
.frame-chats-root .greeting h1 { margin:0; font-family:"Unbounded",sans-serif; font-size:19px; font-weight:600; letter-spacing:-.01em; }
.frame-chats-root .greeting h1 span { color:var(--accent); }
.frame-chats-root .greeting .date { margin-top:3px; color:var(--ink-faint); font-size:12px; }
.frame-chats-root .qc { margin:0 0 18px; border:1px solid rgba(255,255,255,.55); border-radius:20px; background:rgba(255,255,255,.42); box-shadow:0 1px 5px rgba(60,80,70,.045); padding:12px 14px 8px; backdrop-filter:blur(11px); -webkit-backdrop-filter:blur(11px); }
.frame-chats-root .qc-field { display:block; width:100%; min-height:30px; max-height:110px; overflow-y:auto; resize:none; border:0; outline:0; background:transparent; color:var(--ink); padding:2px 0 8px; font-size:14.5px; line-height:1.4; }
.frame-chats-root .qc-field::placeholder { color:var(--ink-faint); }
.frame-chats-root .qc-actions { display:flex; align-items:center; gap:6px; border-top:1px solid var(--line); padding-top:8px; }
.frame-chats-root .qc-ico { display:flex; width:34px; height:34px; flex:none; align-items:center; justify-content:center; border-radius:10px; background:transparent; color:var(--ink-soft); font-size:13px; font-weight:700; }
.frame-chats-root .qc-ico:active { background:rgba(140,155,150,.12); }
.frame-chats-root .qc-ico svg { width:19px; height:19px; }
.frame-chats-root .qc-format { font-family:Georgia,serif; }
.frame-chats-root .qc-dest { display:flex; min-width:0; max-width:150px; align-items:center; gap:4px; overflow:hidden; border-radius:12px; background:var(--accent-soft); color:var(--accent); padding:7px 11px; font-size:12.5px; font-weight:600; }
.frame-chats-root .qc-dest span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.frame-chats-root .qc-dest svg { width:12px; height:12px; flex:none; }
.frame-chats-root .qc-mic { display:flex; width:38px; height:38px; flex:none; align-items:center; justify-content:center; margin-left:auto; border-radius:50%; background:var(--accent); box-shadow:0 4px 12px rgba(62,155,95,.24); color:#fff; }
.frame-chats-root .qc-mic svg { width:18px; height:18px; }

.frame-chats-root .section-head { display:flex; align-items:center; justify-content:space-between; margin:20px 2px 6px; }
.frame-chats-root .section-head h2 { margin:0; color:var(--ink-faint); font-size:12.5px; font-weight:600; letter-spacing:0; }
.frame-chats-root .section-head .right { display:flex; align-items:center; gap:12px; }
.frame-chats-root .pin-count,.frame-chats-root .section-collapse { color:var(--ink-faint); font-size:11.5px; font-weight:600; }
.frame-chats-root .section-collapse { background:transparent; padding:4px 0; }

/* Approved transfer difference: pinned is a true horizontal carousel. */
.frame-chats-root .pinned-wrap { margin:0 -16px 4px; }
.frame-chats-root .pinned-carousel { display:flex; gap:10px; overflow-x:auto; padding:2px 16px 9px; scroll-snap-type:x proximity; scrollbar-width:none; }
.frame-chats-root .pinned-carousel::-webkit-scrollbar { display:none; }
.frame-chats-root .pinned-chat-card { position:relative; display:grid; grid-template-columns:56px minmax(0,1fr) 16px; align-items:center; gap:12px; width:min(82vw,330px); min-height:112px; flex:0 0 min(82vw,330px); scroll-snap-align:start; border:1px solid rgba(62,155,95,.14); border-radius:20px; background:linear-gradient(180deg,rgba(62,155,95,.065),rgba(255,255,255,.42)); color:var(--ink); padding:13px 12px; text-align:left; }
.frame-chats-root .pinned-chat-card.system-general { border-color:rgba(127,138,148,.34); background:linear-gradient(180deg,rgba(127,138,148,.09),rgba(255,255,255,.45)); }
.frame-chats-root .pinned-chat-card > svg { width:14px; color:var(--accent); }
.frame-chats-root .pinned-chat-card.system-general > svg { color:#7f8a94; }
.frame-chats-root .pinned-card-status { position:absolute; right:36px; bottom:10px; max-width:118px; overflow:hidden; border-radius:999px; background:rgba(255,255,255,.72); color:var(--ink-faint); padding:3px 7px; font-size:9.5px; font-weight:700; text-overflow:ellipsis; white-space:nowrap; }

/* Shared Telegram-density row primitives from the decoded frame. */
.frame-chats-root .chat-line,.frame-chats-root .rj-row { display:flex; width:100%; align-items:center; gap:13px; background:transparent; color:var(--ink); padding:9px 0; text-align:left; transition:opacity .12s; }
.frame-chats-root .chat-line:active,.frame-chats-root .rj-row:active { opacity:.55; }
.frame-chats-root .cl-ava { display:flex; width:52px; height:52px; flex:none; align-items:center; justify-content:center; border:1.5px solid rgba(255,255,255,.72); border-radius:50%; background:rgba(140,155,150,.14); background:color-mix(in srgb,var(--chat-color) 20%,#fff); box-shadow:0 1px 6px rgba(60,80,70,.13); font-size:23px; }
.frame-chats-root .pinned-chat-card .cl-ava.big { width:56px; height:56px; font-size:25px; }
.frame-chats-root .cl-body,.frame-chats-root .rj-body { min-width:0; flex:1; }
.frame-chats-root .cl-top,.frame-chats-root .rj-top { display:flex; align-items:center; gap:7px; }
.frame-chats-root .cl-title,.frame-chats-root .rj-title { min-width:0; flex:1; overflow:hidden; font-size:15px; font-weight:700; text-overflow:ellipsis; white-space:nowrap; }
.frame-chats-root .cl-time,.frame-chats-root .rj-time { flex:none; color:var(--ink-faint); font-size:11.5px; }
.frame-chats-root .cl-last,.frame-chats-root .rj-msg { overflow:hidden; margin-top:2px; color:var(--ink-soft); font-size:13px; text-overflow:ellipsis; white-space:nowrap; }
.frame-chats-root .cl-path,.frame-chats-root .rj-path { overflow:hidden; margin-top:3px; color:var(--ink-faint); font-size:11px; text-overflow:ellipsis; white-space:nowrap; }
.frame-chats-root .pinned-chat-card .cl-path { padding-right:72px; }
.frame-chats-root .cl-unread { display:flex; min-width:19px; height:19px; flex:none; align-items:center; justify-content:center; border-radius:10px; background:var(--accent); color:#fff; padding:0 6px; font-size:11px; font-weight:700; }
.frame-chats-root .chat-line > svg,.frame-chats-root .rj-row > svg { width:17px; height:17px; flex:none; color:var(--ink-faint); }

.frame-chats-root .recent-journal { padding:0; background:none; border:0; box-shadow:none; }
.frame-chats-root .rj-row.div { border-top:1px solid var(--line); }
.frame-chats-root .rj-msg { display:block; }
.frame-chats-root .rj-msg i { margin-right:4px; color:var(--accent); font-style:normal; }

/* Themes form one flowing group: bracket accent, no closed cards or pills. */
.frame-chats-root .themes-flow { margin-top:20px; }
.frame-chats-root .theme-cat { position:relative; margin-bottom:4px; border-left:1.5px solid var(--tc); border-top-left-radius:var(--r-md); padding:6px 12px 8px; }
.frame-chats-root .theme-cat::before { position:absolute; top:0; left:-2px; width:28%; height:1.5px; border-radius:2px; background:var(--tc); content:""; }
.frame-chats-root .theme-cat + .theme-cat { margin-top:1px; }
.frame-chats-root .theme-row { align-items:flex-start; }
.frame-chats-root .theme-row .cl-ava { margin-top:1px; }
.frame-chats-root .subtopic-text { display:block; overflow:hidden; margin-top:4px; color:var(--ink-faint); font-size:10.5px; text-overflow:ellipsis; white-space:nowrap; }
.frame-chats-root .empty-themes,.frame-chats-root .chats-home-state { display:grid; justify-items:center; gap:7px; border:1px dashed rgba(100,124,111,.28); border-radius:17px; color:var(--ink-soft); padding:25px 15px; text-align:center; }
.frame-chats-root .empty-themes h3,.frame-chats-root .empty-themes p { margin:0; }
.frame-chats-root .empty-themes h3,.frame-chats-root .chats-home-state b { color:var(--ink); font-size:13px; }
.frame-chats-root .empty-themes p,.frame-chats-root .chats-home-state span { max-width:270px; font-size:11px; line-height:1.45; }
.frame-chats-root .empty-themes button { border-radius:13px; background:var(--accent); color:#fff; padding:10px 14px; font-size:12px; font-weight:700; }
.frame-chats-root .chats-home-state { margin:24px 2px; }

/* Main FAB and bottom sheets remain real UI surfaces; unavailable items are
   labelled individually instead of replacing a menu with a lock notice. */
.frame-chats-root .fab-dial { position:fixed; z-index:35; right:18px; bottom:calc(18px + env(safe-area-inset-bottom,0px)); display:flex; flex-direction:column; align-items:flex-end; gap:12px; }
.frame-chats-root .fab-main { display:flex; width:56px; height:56px; align-items:center; justify-content:center; border:1px solid rgba(255,255,255,.5); border-radius:18px; background:rgba(62,155,95,.94); box-shadow:0 8px 22px rgba(62,155,95,.35); color:#fff; backdrop-filter:blur(8px); transition:.22s cubic-bezier(.3,.9,.3,1); }
.frame-chats-root .fab-main svg { width:24px; height:24px; transition:transform .22s; }
.frame-chats-root .fab-dial.open .fab-main { background:rgba(255,255,255,.94); box-shadow:0 8px 22px rgba(60,80,70,.2); color:var(--ink-soft); }
.frame-chats-root .fab-dial.open .fab-main svg { transform:rotate(135deg); }
.frame-chats-root .dial-items { display:flex; flex-direction:column; align-items:flex-end; gap:10px; margin-bottom:2px; opacity:0; pointer-events:none; transform:translateY(10px) scale(.96); transition:opacity .2s,transform .2s; }
.frame-chats-root .fab-dial.open .dial-items { opacity:1; pointer-events:auto; transform:none; }
.frame-chats-root .dial-pill { display:flex; align-items:center; gap:10px; border:1px solid rgba(255,255,255,.8); border-radius:22px; background:rgba(255,255,255,.94); box-shadow:0 6px 18px rgba(60,80,70,.14); color:var(--ink); padding:10px 15px; font-size:13px; font-weight:600; white-space:nowrap; backdrop-filter:blur(16px); }
.frame-chats-root .dial-pill span { display:grid; width:28px; height:28px; place-items:center; border-radius:10px; background:var(--accent-soft); font-size:15px; }
.frame-chats-root .stage1-backdrop { position:fixed; z-index:40; inset:0; width:100%; height:100%; background:rgba(35,38,43,.28); backdrop-filter:blur(2px); }
.frame-chats-root .stage1-sheet { position:fixed; z-index:41; right:0; bottom:0; left:0; max-height:min(82dvh,720px); overflow:auto; border-radius:24px 24px 0 0; background:#f9fbfa; box-shadow:0 -12px 36px rgba(29,43,36,.18); padding:9px 18px calc(22px + env(safe-area-inset-bottom,0px)); }
.frame-chats-root .stage1-sheet.compact { max-height:420px; }
.frame-chats-root .sheet-grip { width:38px; height:4px; margin:1px auto 13px; border-radius:9px; background:rgba(102,112,123,.28); }
.frame-chats-root .stage1-sheet header { display:grid; grid-template-columns:minmax(0,1fr) 34px; align-items:center; gap:8px; margin-bottom:6px; }
.frame-chats-root .stage1-sheet h3 { margin:0; font-family:"Unbounded",sans-serif; font-size:15px; }
.frame-chats-root .stage1-sheet header button { display:grid; width:32px; height:32px; place-items:center; border-radius:50%; background:rgba(140,155,150,.11); color:var(--ink-soft); font-size:23px; line-height:1; }
.frame-chats-root .stage1-menu-item { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:center; width:100%; min-height:49px; border-top:1px solid var(--line); background:transparent; color:var(--ink); text-align:left; }
.frame-chats-root .stage1-menu-item small,.frame-chats-root .stage1-primary-placeholder small { border-radius:999px; background:rgba(227,178,60,.12); color:#a97717; padding:3px 7px; font-size:9px; font-weight:700; }
.frame-chats-root .destination-list { display:grid; }
.frame-chats-root .destination-row { display:grid; grid-template-columns:42px minmax(0,1fr) 18px; align-items:center; gap:10px; width:100%; min-height:58px; border-top:1px solid var(--line); background:transparent; color:var(--ink); text-align:left; }
.frame-chats-root .destination-row .cl-ava { width:40px; height:40px; font-size:18px; }
.frame-chats-root .destination-row > span:not(.cl-ava) { display:grid; min-width:0; gap:2px; }
.frame-chats-root .destination-row b,.frame-chats-root .destination-row small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.frame-chats-root .destination-row b { font-size:13px; }
.frame-chats-root .destination-row small { color:var(--ink-faint); font-size:10px; }
.frame-chats-root .destination-row.selected { color:var(--accent); }
.frame-chats-root .destination-row > svg { width:16px; }
.frame-chats-root .create-sheet label { display:grid; gap:6px; color:var(--ink-soft); font-size:11px; }
.frame-chats-root .create-sheet input { width:100%; min-height:46px; border:1px solid var(--line); border-radius:13px; outline:0; background:#fff; color:var(--ink-faint); padding:10px 12px; }
.frame-chats-root .stage1-primary-placeholder { display:flex; width:100%; min-height:46px; align-items:center; justify-content:center; gap:8px; margin-top:12px; border-radius:14px; background:var(--accent); color:#fff; font-size:13px; font-weight:700; }

@media (min-width:561px) { .frame-chats-root .fab-dial,.frame-chats-root .stage1-backdrop,.frame-chats-root .stage1-sheet { position:absolute; } }
@media (min-width:600px) { .frame-chats-root .content { max-width:620px; margin:0 auto; padding-right:8px; padding-left:8px; } }
@media (max-width:370px) { .frame-chats-root .pinned-chat-card { width:86vw; flex-basis:86vw; } .frame-chats-root .cl-ava { width:48px; height:48px; font-size:21px; } .frame-chats-root .qc-dest { max-width:118px; } }
@media (prefers-reduced-motion:reduce) { .frame-chats-root * { animation:none!important; transition:none!important; } }

/* FRAME_NOTES correction: retain the airy source spacing, open corners and
   real secondary-state surfaces instead of collapsing them into generic cards. */
.frame-notes-root .note-card { min-height:82px; margin-bottom:10px; border-color:rgba(117,137,126,.22); border-radius:17px; box-shadow:0 7px 18px rgba(47,74,61,.055); }
.frame-notes-root .note-card::before { width:30%; height:21px; border-width:2px; border-radius:17px 0 0 0; }.frame-notes-root .note-card.is-favorite { background:linear-gradient(135deg,rgba(255,252,238,.83),rgba(255,255,255,.58)); }.frame-notes-root .note-card.is-pinned { border-color:rgba(76,175,125,.36); }
.frame-notes-root .note-card p { display:-webkit-box; white-space:normal; line-height:1.38; -webkit-box-orient:vertical; -webkit-line-clamp:2; }.frame-notes-root .note-state { align-self:center; margin-left:auto; color:#d29a38; font-size:12px; }
.frame-notes-root .pinned-wrap { margin-bottom:20px; border-color:rgba(76,175,125,.24); border-radius:22px; padding:13px 11px 11px; }.frame-notes-root .pinned-row { overflow-x:auto; padding:1px 2px 5px; scroll-snap-type:x proximity; }.frame-notes-root .pinned-card { min-width:min(72vw,250px); flex:0 0 min(72vw,250px); border-radius:17px; scroll-snap-align:start; }.frame-notes-root .pinned-card .date { color:var(--ink-faint); font-size:9px; }
.frame-notes-root .recent-block { display:grid; gap:0; margin-bottom:20px; }.frame-notes-root .recent-block .note-card { margin-bottom:9px; }.frame-notes-root .cat-grid { gap:10px; margin:0 -2px; }.frame-notes-root .cat-card { border-color:rgba(130,149,139,.20); border-radius:22px; background:linear-gradient(145deg,rgba(255,255,255,.68),rgba(242,248,244,.52)); box-shadow:0 8px 20px rgba(50,78,65,.06); padding:0 10px; }.frame-notes-root .cat-head { padding:13px 3px 6px; }.frame-notes-root .cat-sub-pills { min-height:42px; padding:9px 3px 12px; }.frame-notes-root .cat-sub-pill { border-radius:99px; box-shadow:inset 0 1px rgba(255,255,255,.78); }.frame-notes-root .cat-more { margin:0 -10px; width:calc(100% + 20px); padding:10px; }
.frame-notes-root .stat-chip { border-radius:999px; box-shadow:0 4px 12px rgba(47,103,71,.10); padding:8px 12px; }.frame-notes-root .cat-stats-screen { position:absolute; z-index:52; inset:0; overflow:auto; background:radial-gradient(ellipse 88% 42% at 100% -8%,rgba(122,178,255,.20),transparent 64%),linear-gradient(180deg,#f7faf8,#f1f6f3); }.frame-notes-root .cat-stats-screen .rem-body { display:grid; gap:10px; padding:14px; }.frame-notes-root .cat-stats-screen .frame-notes-stat { grid-template-columns:34px minmax(0,1fr) auto auto; gap:9px; min-height:67px; border-color:rgba(130,149,139,.20); border-radius:17px; background:rgba(255,255,255,.65); box-shadow:0 6px 17px rgba(50,78,65,.05); }.frame-notes-root .stat-title,.frame-notes-root .stat-values,.frame-notes-root .stat-placeholder { display:grid; gap:2px; }.frame-notes-root .stat-title small,.frame-notes-root .stat-values small,.frame-notes-root .stat-placeholder small { color:var(--ink-faint); font-size:9px; }.frame-notes-root .stat-values { text-align:right; }.frame-notes-root .stat-placeholder { min-width:42px; color:var(--ink-faint); font-size:12px; text-align:right; }.frame-notes-root .stat-placeholder small { max-width:47px; line-height:1.1; }

/* Direct create/view controls from the decoded frames. */
.frame-note-create .fmt-toolbar { justify-content:flex-start; padding:7px 10px; overflow-x:auto; }.frame-note-create .fmt-btn { display:grid; width:33px; height:32px; flex:none; place-items:center; border:1px solid rgba(140,155,150,.18); border-radius:9px; background:#fff; color:#287642; }.frame-note-create .fmt-btn svg { width:16px; height:16px; }.frame-note-create .fmt-x { margin-left:auto; color:#98a1ab; font-size:19px; }.frame-note-create .fmt-sep { width:1px; height:22px; flex:none; background:rgba(140,155,150,.2); }.frame-note-create .sheet-item > i { margin-left:auto; color:#98a1ab; }.frame-note-create .sel-row { display:grid; grid-template-columns:25px minmax(0,1fr) 18px; align-items:center; width:100%; gap:8px; border:0; border-top:1px solid rgba(140,155,150,.16); background:transparent; color:#23262b; padding:13px 3px; text-align:left; }.frame-note-create .sel-row > i { color:#98a1ab; }.frame-note-create .rel-card { display:grid; grid-template-columns:30px minmax(0,1fr); align-items:center; gap:8px; margin:4px 0 8px; border:1px dashed rgba(140,155,150,.34); border-radius:14px; background:rgba(255,255,255,.52); padding:10px; }.frame-note-create .rel-card.disabled { opacity:.76; }.frame-note-create .rel-label { display:grid; width:29px; height:29px; place-items:center; border-radius:9px; background:rgba(62,155,95,.10); color:#287642; }.frame-note-create .rel-main { display:grid; gap:2px; }.frame-note-create .rel-main small { color:#98a1ab; font-size:10px; line-height:1.3; }.frame-inline-svg { display:grid; width:20px; height:20px; flex:none; place-items:center; color:#3e9b5f; }.frame-inline-svg svg { width:19px; height:19px; }.frame-note-create .pop-item { gap:9px; }
.frame-notes-root .cat-card.placeholder,.frame-notes-root .frame-notes-stat.placeholder { border-style:dashed; opacity:.78; }.frame-notes-root .cat-card.placeholder .cat-count { color:#d29a38; }.frame-notes-root .frame-notes-uncategorized .ns-hint { margin-top:10px; }
