/* Daily Todo - Warm Vintage Theme */
:root {
  --bg: #1c1816;
  --bg-end: #161311;
  --surface: #2d2826;
  --surface-elevated: #3f3936;
  --surface-hover: #4a443f;
  --border: #5c534a;
  --border-hover: #6d6358;
  --muted: #9a8f84;
  --text: #e8e2da;
  --accent: #c9a86c;
  --accent-soft: rgba(201, 168, 108, 0.15);
  --accent-border: rgba(201, 168, 108, 0.5);
  --success: #7cb88a;
  --danger: #c87a6d;
  --warning: #d4a574;
}
* { box-sizing: border-box; margin: 0; padding: 0; }

/* Loading overlay */
.loading-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  z-index: 9999;
  transition: opacity 0.2s;
}
.loading-overlay.hidden { opacity: 0; pointer-events: none; }
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Auth (in footer) */
.btn-auth {
  height: 40px;
  padding: 0 16px;
  font-size: 13px;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--muted);
  cursor: pointer;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: flex;
  align-items: center;
  transition: all 0.2s;
}
.btn-auth:hover { background: var(--border); color: var(--text); }
.btn-auth.signed-in {
  color: var(--accent);
  border-color: var(--accent-border);
}

/* Empty state */
.empty-state {
  padding: 20px 16px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  border: 1px dashed var(--border);
  border-radius: 10px;
  margin-bottom: 2px;
  background: rgba(63, 57, 54, 0.4);
}
.empty-state.hidden { display: none; }

/* Recurrence selector */
.add-form-recurrence {
  flex: 0 0 auto;
  padding: 0 8px;
  height: 36px;
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
  max-width: 70px;
}

/* Overdue */
.todo-item.overdue:not(.done) { border-left: 4px solid var(--danger); }

/* Toast */
.toast {
  position: fixed;
  bottom: 90px;
  left: 50%;
  transform: translateX(-50%);
  padding: 14px 24px;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-size: 14px;
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  max-width: 90%;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}
.toast.show { opacity: 1; }
.toast.error { border-color: var(--danger); }
.toast .toast-retry { margin-left: 12px; color: var(--accent); cursor: pointer; text-decoration: underline; }

/* Auth modal */
.auth-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}
.auth-modal.open { opacity: 1; pointer-events: auto; }
.auth-modal-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  width: 90%;
  max-width: 320px;
  box-shadow: 0 0 0 1px rgba(48,54,61,0.5), 0 24px 48px rgba(0,0,0,0.5);
}
.auth-modal-content h3 { margin-bottom: 16px; font-size: 1.1rem; }
.auth-modal-content input {
  display: block;
  width: 100%;
  padding: 10px 12px;
  margin-bottom: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-size: 14px;
}
.auth-error { color: var(--danger); font-size: 12px; margin-bottom: 8px; min-height: 16px; }
.auth-modal-buttons { display: flex; gap: 8px; margin-top: 16px; }
.auth-modal-buttons button { flex: 1; padding: 10px; border-radius: 6px; font-size: 14px; cursor: pointer; }
.auth-switch { margin-top: 12px; font-size: 13px; color: var(--muted); }
.auth-switch button { background: none; border: none; color: var(--accent); cursor: pointer; text-decoration: underline; }
input, textarea, [contenteditable] { -webkit-user-select: text; user-select: text; }
html {
  -webkit-tap-highlight-color: transparent;
  height: 100%;
  min-height: 100%;
  min-height: 100dvh;
  min-height: 100svh;
  min-height: -webkit-fill-available;
  background: var(--bg);
  -webkit-user-select: none;
  user-select: none;
}
@media (max-width: 1024px) {
  html { font-size: 87.5%; }
}
@media (display-mode: standalone) {
  html, body { min-height: 100vh; height: 100%; }
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-end) 100%);
  color: var(--text);
  margin: 0;
  width: 100%;
  min-width: 0;
  min-height: 100dvh;
  min-height: -webkit-fill-available;
  overflow-x: hidden;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
  display: flex;
  flex-direction: column;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  box-sizing: border-box;
}
@media (min-width: 1025px) {
  body { max-width: 480px; margin: 0 auto; }
}

.days-container {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 8px 6px;
  padding-bottom: 8px;
}

.day-block {
  margin-bottom: 8px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: all 0.2s ease;
}

.day-block.collapsed { margin-bottom: 8px; }

.day-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 10px;
  min-height: 36px;
  cursor: pointer;
  user-select: none;
  transition: background 0.2s ease;
}

.day-block.collapsed .day-block-header {
  background: var(--surface);
}

.day-block.expanded .day-block-header {
  background: var(--accent-soft);
  border-bottom: 1px solid var(--border);
}

.day-block.collapsed .day-block-header:hover {
  background: var(--surface-elevated);
}

.day-block-title {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #38bdf8;
}

.day-block.expanded .day-block-title { color: var(--accent); }

.day-block-summary {
  font-size: 12px;
  color: var(--muted);
  padding: 4px 10px;
  background: var(--surface-elevated);
  border-radius: 20px;
}

.day-block-content {
  padding: 6px 10px;
  background: var(--bg);
}

.day-block.collapsed .day-block-content { display: none; }

.add-form {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  margin-bottom: 0;
  margin-top: 6px;
  padding: 6px 10px;
  background: var(--surface-elevated);
  border-radius: 6px;
  border: 1px solid var(--border);
  transition: border-color 0.2s;
}

.add-form:focus-within { border-color: var(--accent-border); }

.add-form input {
  padding: 0 12px;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font-size: 14px;
  transition: box-shadow 0.2s;
}

.add-form input:focus {
  outline: none;
  box-shadow: none;
}

.add-form-time {
  flex: 0 0 56px;
  min-width: 56px;
  position: relative;
  display: flex;
  align-items: center;
  cursor: pointer;
}
.add-form-time input[type="time"] {
  width: 100%;
  min-width: 0;
  padding: 0;
  border: none;
  background: transparent;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
  color-scheme: dark;
}
.add-form-time input[type="time"]::-webkit-calendar-picker-indicator {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.add-form-priority {
  flex-shrink: 0;
  cursor: pointer;
  margin: 0 8px;
}

.add-form input[type="text"] {
  flex: 1;
  min-width: 80px;
  font-size: 15px;
}

.add-form input[type="text"]::placeholder {
  color: var(--muted);
}

.add-form button { display: none; }

.todo-list {
  list-style: none;
  min-height: 36px;
  padding: 2px 0 0;
}

.todo-item {
  display: flex;
  align-items: center;
  padding: 6px 10px;
  margin-bottom: 4px;
  min-height: 36px;
  background: var(--surface-elevated);
  border-radius: 10px;
  border: 1px solid var(--border);
  position: relative;
  overflow: visible;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  transition: all 0.2s ease;
}
.todo-item.dragging { touch-action: none; }

.todo-item:hover {
  border-color: var(--border-hover);
  background: var(--surface-hover);
}

.todo-item:last-child { margin-bottom: 0; }

.todo-item.done .todo-text { text-decoration: line-through; opacity: 0.5; }
.todo-item.done .todo-time { opacity: 0.5; }
.todo-item.done {
  border-color: var(--accent-border);
  background: var(--accent-soft);
}

.todo-time {
  flex: 0 0 56px;
  min-width: 56px;
  position: relative;
  z-index: 2;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-size: 13px;
}

.todo-text {
  flex: 1;
  min-width: 0;
  margin-left: 8px;
  font-size: 15px;
  position: relative;
  z-index: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.todo-priority {
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  position: relative;
  z-index: 1;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 11px;
  color: #fff;
  background: var(--danger);
  margin-left: 10px;
}

.todo-priority.B {
  background: var(--warning);
}

.todo-time,
.todo-priority,
.todo-text {
  cursor: pointer;
  transition: opacity 0.15s;
}

.todo-time:hover,
.todo-priority:hover,
.todo-text:hover {
  opacity: 0.9;
}

.todo-item .inline-edit {
  padding: 6px 12px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font-size: inherit;
  font-family: inherit;
  flex-shrink: 0;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.todo-item .inline-edit:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-soft);
}

.todo-item .todo-time {
  position: relative;
}

.todo-item .todo-time .inline-edit.time {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  border-radius: 0 !important;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  color-scheme: dark;
  font-size: 13px;
  color: var(--muted);
  background: transparent !important;
  text-align: left;
  box-sizing: border-box;
}

.todo-item .todo-time .inline-edit.time:focus {
  border: none;
  box-shadow: none;
  background: transparent;
}

.todo-item .todo-time .inline-edit.time::-webkit-calendar-picker-indicator {
  position: absolute;
  right: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
  margin: 0;
}

.inline-edit-priority-btns { display: flex; gap: 6px; }

.inline-edit-priority-btns .priority-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface-elevated);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

.inline-edit-priority-btns .priority-btn:hover {
  background: var(--border);
  color: var(--text);
}

.inline-edit-priority-btns .priority-btn.A { color: var(--danger); }
.inline-edit-priority-btns .priority-btn.A.active,
.inline-edit-priority-btns .priority-btn.A:hover {
  background: var(--danger);
  color: #fff;
  border-color: transparent;
}

.inline-edit-priority-btns .priority-btn.B { color: var(--warning); }
.inline-edit-priority-btns .priority-btn.B.active,
.inline-edit-priority-btns .priority-btn.B:hover {
  background: var(--warning);
  color: #fff;
  border-color: transparent;
}

.todo-item .inline-edit.text {
  flex: 1;
  min-width: 80px;
  font-size: 15px;
}

.todo-item.editing {
  overflow: visible;
  z-index: 2;
  position: relative;
}

/* Action sheet */
.action-sheet {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100;
  align-items: flex-end;
  justify-content: stretch;
}

.action-sheet.open { display: flex; }

.action-sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

.action-sheet-content {
  position: relative;
  width: 100%;
  max-width: 100%;
  background: var(--surface);
  border-radius: 20px 20px 0 0;
  padding: 16px max(20px, env(safe-area-inset-right)) calc(28px + env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  border: 1px solid var(--border);
  border-bottom: none;
  box-shadow: 0 -8px 32px rgba(0,0,0,0.4);
}

.action-sheet.open .action-sheet-content {
  transform: translateY(0);
}

.action-sheet-item {
  display: block;
  width: 100%;
  padding: 16px 24px;
  min-height: 52px;
  border: none;
  background: transparent;
  color: var(--text);
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  text-align: center;
  border-radius: 12px;
  transition: all 0.2s;
  margin-bottom: 4px;
}

.action-sheet-item:hover { background: var(--surface-elevated); }
.action-sheet-item:active { background: var(--border); transform: scale(0.99); }
.action-sheet-item.done { color: var(--accent); }
.action-sheet-item.undone { color: var(--muted); }
.action-sheet-item.move { color: var(--accent); }
.action-sheet-item.pomodoro { color: var(--accent); }
.action-sheet-item.mindfulness { color: var(--success); }
.action-sheet-item.delete { color: var(--danger); }

/* Footer - email, date, nav - sticks to bottom */
.app-footer {
  position: sticky;
  bottom: 0;
  width: 100%;
  margin-top: auto;
  flex-shrink: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 8px 10px;
  padding-bottom: calc(8px + env(safe-area-inset-bottom));
  font-size: 14px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  z-index: 100;
}
@media (min-width: 1025px) {
  .app-footer { max-width: 480px; margin-left: auto; margin-right: auto; margin-top: auto; }
}

.day-indicator-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
}
.day-indicator-user {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.day-indicator-user .btn-auth {
  min-width: 80px;
}

.day-indicator-nav .btn-today { flex-shrink: 0; }
.day-indicator-nav .date-picker-group { flex: 1; min-width: 0; display: flex; }

/* Date picker: single pill with arrows, same height */
.date-picker-group {
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--surface-elevated);
  display: flex;
  align-items: stretch;
}

.date-picker-group .day-nav-btn,
.date-picker-group .btn-date {
  height: 100%;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 0;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s;
  box-sizing: border-box;
}

.date-picker-group .day-nav-btn {
  width: 40px;
  flex-shrink: 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  border-right: 1px solid var(--border);
}
.date-picker-group .day-nav-btn:last-of-type {
  border-right: none;
  border-left: 1px solid var(--border);
}
.date-picker-group .day-nav-btn:hover { background: var(--border); color: var(--accent); }

.date-picker-group .btn-date {
  flex: 1;
  min-width: 0;
  padding: 0 12px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
}
.date-picker-group .btn-date:hover { background: var(--border); }
.date-picker-group .btn-date #dayIndicator {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.btn-today {
  height: 40px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-today:hover { background: var(--border); color: var(--text); }

/* Days overview / Calendar */
.days-overview {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(13, 17, 23, 0.98);
  backdrop-filter: blur(20px);
  z-index: 50;
  flex-direction: column;
  overflow: hidden;
  align-items: center;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  box-sizing: border-box;
}

.days-overview.open { display: flex; }

.days-overview-inner {
  width: 100%;
  max-width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
@media (min-width: 1025px) {
  .days-overview-inner { max-width: 480px; margin: 0 auto; }
}

.days-overview-header {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(92, 83, 74, 0.6);
  background: var(--surface);
  flex-shrink: 0;
}

.days-overview-close {
  position: absolute;
  right: 20px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: none;
  background: var(--surface-elevated);
  color: var(--muted);
  font-size: 18px;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
}

.days-overview-close:hover {
  background: var(--border);
  color: var(--text);
}

.days-overview-header h2 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
}

.days-table-wrap { flex: 1; overflow-y: auto; padding: 20px; }

.days-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
}

.days-table th {
  text-align: left;
  padding: 14px 18px;
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.days-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--surface-elevated);
}

.days-table tr.day-row { cursor: pointer; transition: background 0.15s; }
.days-table tr.day-row:hover { background: var(--surface-elevated); }
.days-table tr.day-row.current { background: var(--accent-soft); }

.day-done { color: var(--accent); font-weight: 500; }
.day-total { color: var(--muted); }
.day-preview { font-size: 13px; color: var(--muted); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.calendar-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 20px;
  gap: 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.calendar-nav-btn {
  flex: 1;
  max-width: 80px;
  padding: 12px 16px;
  min-height: 44px;
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-size: 20px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.calendar-nav-btn:hover {
  background: var(--border);
  border-color: var(--accent);
  color: var(--accent);
}

.calendar-nav-btn:active { transform: scale(0.98); }

#calendarYearDisplay {
  font-weight: 600;
  color: var(--accent);
  font-size: 18px;
  min-width: 64px;
  text-align: center;
}

.calendar-grid {
  flex: 1;
  padding: 20px 16px 24px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.calendar-months {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.calendar-month-block {
  background: var(--surface);
  border-radius: 8px;
  padding: 12px;
  border: 1px solid var(--border);
  transition: border-color 0.2s;
}

.calendar-month-block.current-month {
  border-color: var(--accent-border);
  background: var(--accent-soft);
}

.calendar-month-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.calendar-month-block.current-month .calendar-month-name { color: var(--accent); }

.calendar-month-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.calendar-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  min-height: 20px;
}

.calendar-day.empty { cursor: default; visibility: hidden; }
.calendar-day.today { background: var(--accent-soft); color: var(--accent); }
.calendar-day.current {
  background: #238636;
  color: #fff;
}
.calendar-day:hover:not(.empty) {
  background: var(--border);
}
.calendar-day:active:not(.empty) { transform: scale(0.95); }

/* Drag handle */
.drag-handle {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 40px;
  min-height: 40px;
  cursor: grab;
  touch-action: none;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  z-index: 2;
}

.todo-item.dragging .drag-handle { cursor: grabbing; }
.todo-item.dragging {
  opacity: 0.95;
  will-change: transform;
  z-index: 9999;
  position: relative;
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}
html.drag-active,
body.drag-active {
  overflow: hidden !important;
  touch-action: none !important;
  overscroll-behavior: none !important;
}
body.drag-active .days-container {
  overflow: hidden !important;
  touch-action: none !important;
  overscroll-behavior: none !important;
}
.drag-ghost { pointer-events: none !important; }

.todo-recurring {
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 10px;
  color: #fff;
  background: var(--accent);
  margin-left: 8px;
}

/* Mobile & touch - tap targets */
@media (max-width: 480px), (pointer: coarse) {
  .add-form { padding: 8px 10px; min-height: 44px; }
  .todo-item { min-height: 44px; }
  .day-block-header { min-height: 44px; }
  .btn-today, .day-nav-btn, .btn-date { min-height: 40px; }
}
@media (max-width: 480px) {
  .add-form-time { flex: 0 0 56px; min-width: 56px; }
  .day-block-content { padding: 8px 10px; }
  .todo-item { padding: 8px 10px; }
  .day-block-header { padding: 8px 10px; }
  .day-block-title { font-size: 0.9rem; }
  .day-block-summary { font-size: 11px; padding: 2px 6px; }
  .days-table-wrap { padding: 10px 12px; }
  .days-table th,
  .days-table td { padding: 8px 10px; font-size: 12px; }
  .days-table th { font-size: 11px; }
  .day-preview { max-width: 100px; font-size: 11px; }
  .calendar-months { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .calendar-month-block { padding: 8px; }
  .calendar-nav { padding: 10px 12px; }
  .calendar-grid { padding: 12px 10px 16px; }
  .calendar-nav-btn { max-width: 56px; font-size: 16px; }
  #calendarYearDisplay { font-size: 15px; }
  .days-overview-header { padding: 12px 16px; }
  .days-overview-close { right: 16px; }
  .days-overview-header h2 { font-size: 1.1rem; }
  .app-footer { padding: 8px 10px; padding-bottom: calc(8px + env(safe-area-inset-bottom)); gap: 6px; }
}
