/* Afternoon light: quiet surfaces above a warm, organic background. */
:root {
  --ambient-veil: #f4eee6df;
  --card-shadow: 0 8px 28px #3b251609;
  --sidebar-surface: #f7f0e7;
}
[data-theme="dark"] {
  --ambient-veil: #37322f70;
  --card-shadow: 0 8px 28px #20191224;
  --sidebar-surface: #403833;
}
[data-theme="warm"] {
  --ambient-veil: #efe3d3d9;
  --sidebar-surface: #f2e6d7;
}
[data-theme="ocean"] {
  --ambient-veil: #eef4f8f2;
  --sidebar-surface: #f4f8fb;
}
body {
  position: relative;
  isolation: isolate;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(var(--ambient-veil), var(--ambient-veil)),
    url("/sunlight-texture.jpg") center top / cover no-repeat;
}
.sidebar {
  background: var(--sidebar-surface);
  padding-top: 38px;
}
.sidebar nav {
  gap: 8px;
}
.nav-item {
  border-radius: 16px;
  min-height: 48px;
}
.nav-item.active {
  box-shadow: inset 0 0 0 1px var(--line);
}
.sidebar .brand .icon {
  color: var(--brand);
}
.topbar {
  background: var(--bg);
  padding-top: 14px;
  padding-bottom: 14px;
}
.topbar-actions {
  gap: 12px;
}
.sync-status {
  min-height: 44px;
}
.language-select {
  min-height: 44px;
  border-radius: 14px;
  margin-top: 0;
}
.workspace main {
  padding-top: 36px;
}
.page-heading h1 {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 42px;
  font-weight: 550;
  line-height: 1.15;
  letter-spacing: -1.6px;
}
.date-heading {
  letter-spacing: 1.8px;
}
.date-tile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 12px 18px;
}
input::placeholder,
textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}
.task-list {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 4px 20px;
}
.page-heading p {
  color: var(--text);
}
.primary {
  box-shadow: 0 4px 14px #30201418;
}
.primary:hover {
  filter: brightness(1.06);
}
.secondary:hover,
.column-add:hover {
  background: var(--brand-soft);
}
.list-toolbar,
.section-switch,
.calendar-nav {
  gap: 12px;
}
.section-switch {
  padding: 6px;
  border-radius: 18px;
}
.section-switch button {
  border-radius: 12px;
  min-height: 44px;
}
.list-toolbar select {
  min-height: 44px;
  border-radius: 14px;
}
.planning-board {
  gap: 22px;
}
.planning-column,
.week-calendar,
.project-card,
.note-card {
  border-radius: 24px;
  box-shadow: var(--card-shadow);
}
.planning-column {
  padding: 18px;
}
.planning-column[data-drop-plan="today"] {
  border-top-width: 1px;
  box-shadow:
    inset 0 3px var(--brand),
    var(--card-shadow);
}
.column-heading {
  padding: 3px 0 18px;
}
.column-heading > span,
.task-list-heading small {
  display: inline-grid;
  place-items: center;
  min-width: 26px;
  min-height: 26px;
  border-radius: 9px;
  background: var(--soft);
}
.board-task .task-row {
  padding-top: 20px;
  gap: 10px;
}
.board-task .task-title {
  font-size: 15px;
  line-height: 1.5;
}
.task-notes-indicator {
  border-radius: 8px;
  padding: 4px 9px;
}
.task-list-group {
  border-left-width: 2px;
  padding-left: 14px;
}
.task-list-heading {
  margin-bottom: 6px;
}
.column-add {
  min-height: 44px;
  padding: 10px 14px;
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  justify-content: center;
  background: var(--soft);
  width: 100%;
}
.column-tasks {
  scrollbar-color: var(--muted) transparent;
  scrollbar-width: thin;
}
.week-calendar {
  padding: 20px;
  margin-bottom: 28px;
}
.calendar-day {
  border-radius: 14px;
}
.calendar-nav .icon-button {
  background: var(--soft);
  border: 1px solid var(--line);
}
.calendar-header {
  flex-wrap: wrap;
  gap: 14px;
}
.calendar-task,
.calendar-stay {
  border-radius: 9px;
  padding: 7px 8px;
}
.calendar-items {
  gap: 7px;
}
dialog,
dialog.task-panel {
  border-radius: 24px;
}
dialog::backdrop {
  background: #211b18a6;
}
.editor-header,
.note-editor-heading {
  padding-top: 26px;
  padding-bottom: 22px;
}
.modal-actions,
.note-actions,
.note-tools {
  gap: 12px;
}
.settings-card,
.choice-card {
  border-radius: 18px;
}
.note-tools button,
.note-actions button {
  min-height: 44px;
  border-radius: 12px;
}
.note-tools {
  padding: 10px;
}
.notes-controls {
  gap: 16px;
}
@media (max-width: 700px) {
  .topbar {
    padding: calc(16px + env(safe-area-inset-top))
      max(20px, env(safe-area-inset-right)) 8px
      max(20px, env(safe-area-inset-left));
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 4px 12px;
  }
  .topbar::before {
    content: "daybook";
    font-size: 21px;
    font-weight: 600;
    letter-spacing: -0.7px;
  }
  .topbar-actions {
    grid-column: 2;
    grid-row: 1;
    gap: 10px;
  }
  .topbar-actions .icon-button {
    border: 1px solid var(--line);
    background: var(--surface);
    border-radius: 14px;
  }
  .topbar .language-select {
    margin: 0;
    border-radius: 14px;
    font-size: 14px;
  }
  .sync-status {
    grid-column: 1 / -1;
    font-size: 11px;
  }
  .workspace main,
  .workspace main.board-main {
    padding: 28px 20px calc(134px + env(safe-area-inset-bottom));
  }
  .page-heading h1 {
    font-size: 36px;
  }
  .phone-today .page-heading {
    margin-bottom: 24px;
  }
  .primary,
  .secondary {
    min-height: 48px;
    border-radius: 16px;
    padding: 12px 18px;
  }
  .phone-add-task {
    margin-bottom: 30px;
  }
  .phone-add-task .primary {
    min-height: 52px;
    padding-left: 22px;
    padding-right: 24px;
  }
  .phone-today .task-list-group {
    border-left: 0;
    padding-left: 0;
    margin-top: 30px;
  }
  .phone-today .task-list-heading {
    margin-bottom: 14px;
    gap: 10px;
  }
  .phone-today .task-row {
    padding: 18px 16px;
    margin-bottom: 12px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: var(--surface);
    box-shadow: var(--card-shadow);
    gap: 14px;
    align-items: flex-start;
  }
  .phone-today .tick {
    width: 44px;
    height: 44px;
    margin-top: 0;
  }
  .phone-today .task-main {
    min-height: 44px;
  }
  .phone-today .task-title {
    font-size: 17px;
    line-height: 1.5;
  }
  .phone-today .task-notes-indicator {
    margin-top: 10px;
    padding: 5px 9px;
    border-radius: 9px;
  }
  .phone-tabs {
    left: 12px;
    right: 12px;
    bottom: calc(10px + env(safe-area-inset-bottom));
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 24px;
    gap: 8px;
    box-shadow: 0 8px 32px #211b1833;
  }
  .phone-tabs .nav-item {
    min-height: 62px;
    border-radius: 16px;
    gap: 6px;
  }
  .phone-tabs .nav-item.active {
    box-shadow: none;
  }
  .week-calendar {
    padding: 16px;
  }
  .calendar-grid {
    gap: 6px;
  }
  .calendar-date {
    min-height: 72px;
  }
  .calendar-selected {
    gap: 10px;
  }
  .calendar-selected .calendar-task,
  .calendar-selected .calendar-stay {
    border-radius: 14px;
    padding: 12px;
  }
  .form-grid {
    gap: 16px;
  }
  #plan-time {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 4px;
  }
  #plan-time .span-2 {
    grid-column: 1 / -1;
  }
  #plan-time input[type="time"] {
    inline-size: 100%;
    max-inline-size: 100%;
    min-inline-size: 0;
    min-height: 48px;
  }
  .modal-actions {
    flex-wrap: wrap;
  }
  .editor-header {
    padding: 24px 20px 20px;
  }
  .editor-scroll {
    padding: 20px;
  }
  .settings-actions > button,
  .phone-list-actions > button {
    flex: 1 1 120px;
  }
  .note-editor-heading {
    gap: 12px;
    flex-wrap: wrap;
  }
  .notes-controls {
    flex-wrap: wrap;
  }
  .list-toolbar {
    flex-wrap: wrap;
    gap: 16px;
  }
}
@media (max-width: 360px) {
  .topbar::before {
    content: none;
  }
  .topbar-actions {
    grid-column: 1 / -1;
    justify-content: space-between;
  }
  .workspace main,
  .workspace main.board-main {
    padding-left: 16px;
    padding-right: 16px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .phone-today .task-row {
    padding: 16px 12px;
    gap: 12px;
  }
  .phone-tabs {
    left: 8px;
    right: 8px;
    gap: 4px;
  }
}

/* Interactive enhancements: command palette, quick schedule chips, calendar
   actions, stay detail popover, phone overdue banner, and tactile feedback. */
.command-dialog {
  width: min(580px, calc(100vw - 24px));
  padding: 0;
  overflow: hidden;
}
.command-dialog .modal-close {
  top: 12px;
  right: 12px;
}
.command-palette {
  display: flex;
  flex-direction: column;
  max-height: min(76vh, 560px);
}
.command-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 56px 14px 18px;
  border-bottom: 1px solid var(--line);
}
.command-input-row .icon {
  color: var(--muted);
  flex: none;
}
.command-input-row input {
  border: 0;
  background: transparent;
  margin: 0;
  padding: 6px 0;
  font-size: 16px;
  min-height: 44px;
  flex: 1;
}
.command-input-row input:focus {
  outline: none;
}
.command-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 18px;
  background: var(--soft);
  border-bottom: 1px solid var(--line);
}
.command-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 12px;
  font-weight: 500;
}
.command-results {
  overflow-y: auto;
  padding: 8px;
  display: grid;
  gap: 4px;
}
.command-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border-radius: 12px;
  text-align: left;
  transition: background-color 120ms ease;
}
.command-item:hover,
.command-item.is-active {
  background: var(--brand-soft);
}
.command-item.is-add {
  color: var(--brand);
}
.command-item.is-done {
  opacity: 0.65;
}
.command-item-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 2px;
}
.command-item-text b {
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.command-item-text small {
  font-size: 12px;
  color: var(--muted);
}
.command-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 18px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}
.command-footer kbd {
  padding: 2px 7px;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: var(--soft);
  font-family: inherit;
  font-size: 11px;
}

/* Quick schedule chips inside the task editor */
.quick-schedule-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 6px;
}
.schedule-chip {
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--soft);
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  transition:
    background-color 140ms ease,
    border-color 140ms ease,
    color 140ms ease,
    transform 120ms ease;
}
.schedule-chip:hover {
  border-color: var(--brand);
  color: var(--brand);
}
.schedule-chip.is-active {
  background: var(--brand-soft);
  border-color: var(--brand);
  color: var(--brand);
}

/* Interactive 7-day calendar: add button, clickable stays, drag-drop highlight */
.calendar-day-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2px;
}
.calendar-day-add {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  color: var(--muted);
  opacity: 0;
  flex: none;
  transition:
    opacity 140ms ease,
    background-color 140ms ease,
    color 140ms ease;
}
.calendar-day:hover .calendar-day-add,
.calendar-day:focus-within .calendar-day-add {
  opacity: 1;
}
.calendar-day-add:hover {
  background: var(--surface);
  color: var(--brand);
}
.calendar-day-add .icon {
  width: 14px;
  height: 14px;
}
.calendar-day.drop-ready {
  box-shadow: inset 0 0 0 2px var(--brand);
  background: var(--brand-soft);
}
.calendar-stay {
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition:
    transform 120ms ease,
    filter 140ms ease;
}
.calendar-stay:hover {
  filter: brightness(0.96);
}
.calendar-selected-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.calendar-selected-add {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
}
.calendar-selected-add .icon {
  width: 14px;
  height: 14px;
}
.stay-detail-meta {
  color: var(--muted);
  margin: 6px 0 8px;
}
.stay-detail-guest {
  font-size: 16px;
  font-weight: 500;
  margin: 0 0 18px;
}

/* Phone Today overdue drawer */
.phone-overdue {
  margin: 0 0 18px;
  border: 1px solid color-mix(in srgb, var(--danger) 35%, var(--line));
  border-radius: 18px;
  background: color-mix(in srgb, var(--danger) 7%, var(--surface));
  overflow: hidden;
}
.phone-overdue-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--danger);
  list-style: none;
}
.phone-overdue-summary::-webkit-details-marker {
  display: none;
}
.phone-overdue-list {
  display: grid;
  gap: 8px;
  padding: 0 12px 12px;
}
.overdue-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.overdue-main {
  flex: 1;
  min-width: 0;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.overdue-title {
  font-size: 15px;
  font-weight: 500;
}
.overdue-main small {
  font-size: 12px;
  color: var(--muted);
}

/* Notes markdown inline code & linked tasks */
#note-preview code {
  padding: 2px 5px;
  border-radius: 5px;
  background: var(--soft);
  font-size: 0.9em;
}
.note-linked-tasks {
  margin: 14px 0;
  display: grid;
  gap: 8px;
}
.note-linked-tasks h3 {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

/* Tactile micro-interactions (respecting reduced-motion) */
@media (prefers-reduced-motion: no-preference) {
  .tick,
  .project-card,
  .note-card,
  .calendar-task,
  .calendar-stay,
  .nav-item,
  .primary,
  .secondary {
    transition:
      transform 140ms ease,
      background-color 140ms ease,
      border-color 140ms ease,
      box-shadow 140ms ease,
      opacity 140ms ease;
  }
  .tick:active {
    transform: scale(0.9);
  }
  .project-card:hover,
  .note-card:hover {
    transform: translateY(-2px);
  }
  .calendar-task:hover,
  .calendar-stay:hover {
    transform: translateY(-1px);
  }
  .task-row.completing {
    opacity: 0.45;
    transform: translateX(6px);
  }
}

@media (max-width: 900px) {
  .calendar-day-add {
    display: none;
  }
  .calendar-day-head {
    display: block;
  }
}
@media (max-width: 700px) {
  .phone-today .task-main > .task-place {
    display: block;
    margin-top: 4px;
    font-size: 13px;
    color: var(--muted);
  }
}

/* Interactive date tile progress ring */
button.date-tile {
  position: relative;
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  padding: 0;
  border-radius: 50%;
  cursor: pointer;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--card-shadow);
}
button.date-tile:hover {
  border-color: var(--brand);
  transform: translateY(-1px);
}
.date-ring {
  position: absolute;
  inset: 4px;
  width: calc(100% - 8px);
  height: calc(100% - 8px);
  transform: rotate(-90deg);
  pointer-events: none;
}
.date-ring-track {
  fill: none;
  stroke: var(--soft);
  stroke-width: 3.5;
}
.date-ring-fill {
  fill: none;
  stroke: var(--brand);
  stroke-width: 3.5;
  stroke-linecap: round;
  transition: stroke-dashoffset 320ms ease;
}
button.date-tile.is-complete .date-ring-fill {
  stroke: var(--arrive, #2e8555);
}
.date-tile-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
}
.date-tile-inner strong {
  font:
    500 22px/1 Georgia,
    serif;
}
.date-tile-inner span {
  margin-top: 2px;
  font:
    500 10px/1.2 -apple-system,
    sans-serif;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--muted);
}

/* Focus Mode dialog */
.focus-mode {
  text-align: center;
  padding: 8px 4px 4px;
}
.focus-mode h2 {
  margin: 8px 0 10px;
}
.focus-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 10px;
}
.focus-notes {
  max-width: 44ch;
  margin: 0 auto 14px;
  font-size: 14px;
  color: var(--muted);
}
.focus-timer-wrap {
  position: relative;
  width: 156px;
  height: 156px;
  margin: 18px auto 14px;
  display: grid;
  place-items: center;
}
.focus-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.focus-ring-track {
  fill: none;
  stroke: var(--soft);
  stroke-width: 6;
}
.focus-ring-fill {
  fill: none;
  stroke: var(--brand);
  stroke-width: 6;
  stroke-linecap: round;
  transition: stroke-dashoffset 450ms linear;
}
.focus-clock {
  font-size: 32px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.5px;
}
.focus-presets {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 18px;
}
.focus-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.focus-switcher {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}

/* Inline quick-move hover actions inside desktop board cards */
.board-drag-area {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.board-quick-moves {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  opacity: 0;
  transition: opacity 140ms ease;
}
.board-task:hover .board-quick-moves,
.board-task:focus-within .board-quick-moves {
  opacity: 1;
}
.quick-move-btn {
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  background: var(--soft);
  border: 1px solid var(--line);
  cursor: pointer;
}
.quick-move-btn:hover {
  color: var(--brand);
  border-color: var(--brand);
  background: var(--brand-soft);
}

/* Interactive Day Timeline bar inside Schedule group */
.day-timeline {
  margin: 6px 0 12px;
}
.timeline-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  margin-bottom: 4px;
}
.timeline-track {
  position: relative;
  height: 22px;
  border-radius: 9px;
  background: var(--soft);
  border: 1px solid var(--line);
  cursor: pointer;
  overflow: hidden;
}
.timeline-track:hover {
  border-color: var(--brand);
}
.timeline-block {
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: var(--left);
  width: var(--width);
  border-radius: 6px;
  background: var(--list-color);
  opacity: 0.85;
  cursor: pointer;
  transition:
    opacity 120ms ease,
    transform 120ms ease;
}
.timeline-block:hover {
  opacity: 1;
  transform: scaleY(1.08);
}
.timeline-now {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--left);
  width: 2px;
  background: var(--danger);
  pointer-events: none;
}

/* Interactive Project Cards: stage pill, progress bar, inline next-action tick */
.project-card {
  display: block;
  text-align: left;
  width: 100%;
}
.project-card-main {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0;
  cursor: pointer;
}
.project-open-btn {
  width: 34px;
  height: 34px;
  min-width: 34px;
  min-height: 34px;
}
button.project-status {
  cursor: pointer;
  border: 1px solid transparent;
}
button.project-status:hover {
  border-color: currentColor;
  filter: brightness(0.96);
}
.project-progress {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 8px 0 10px;
}
.project-progress-bar {
  flex: 1;
  height: 6px;
  border-radius: 999px;
  background: var(--soft);
  overflow: hidden;
}
.project-progress-bar > span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--accent, var(--brand));
  transition: width 260ms ease;
}
.project-progress small {
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.project-next {
  display: flex;
  align-items: center;
  gap: 10px;
}
.project-next-tick {
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 50%;
  border: 2px solid var(--muted);
  cursor: pointer;
  transition:
    border-color 140ms ease,
    background-color 140ms ease;
}
.project-next-tick:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
}
.project-next-main {
  flex: 1;
  min-width: 0;
  text-align: left;
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

/* Split Live-Preview Notes Drawer on wide desktops */
@media (min-width: 1000px) {
  dialog.note-dialog {
    margin: 0 0 0 auto;
    width: min(920px, 92vw);
    max-width: min(920px, 92vw);
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 24px 0 0 24px;
  }
  .note-editor-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px;
    align-items: stretch;
  }
  .note-editor-split #note-preview {
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 14px 16px;
    background: var(--soft);
    min-height: 260px;
    overflow-y: auto;
  }
  .note-editor-split textarea[hidden] + #note-preview {
    grid-column: 1 / -1;
  }
}

/* Mobile swipe feedback & touch drag ghost */
.phone-today .task-row {
  touch-action: pan-y;
}
.phone-today .task-row.swipe-right {
  border-color: var(--arrive, #2e8555);
  background: color-mix(in srgb, var(--arrive, #2e8555) 14%, var(--surface));
}
.phone-today .task-row.swipe-left {
  border-color: var(--brand);
  background: var(--brand-soft);
}
.touch-drag-ghost {
  position: fixed;
  z-index: 1000;
  transform: translate(-50%, -120%) scale(1.03);
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--surface);
  border: 1.5px solid var(--brand);
  box-shadow: 0 12px 32px #211b1840;
  font-size: 14px;
  font-weight: 500;
  pointer-events: none;
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
