/* components.css — Modals, toasts, banners, notifications, bottom nav, check-in flow, energy cards, mood buttons, onboarding */

input,textarea,select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

.nav-icon [data-lucide],.nav-icon .lucide {
  width: 23px;
  height: 23px;
}

.mode-opt-icon [data-lucide],.mode-opt-icon .lucide {
  width: 26px;
  height: 26px;
}

.priority-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}

.priority-dot.high {
  background: var(--danger);
}

.priority-dot.med {
  background: var(--gold);
}

.priority-dot.low {
  background: var(--green-light);
}

.chip-mood {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border);
  transition: all 0.2s var(--ease);
}

.chip-mood .mood-face {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  color: var(--text-muted);
  line-height: 1;
}

.chip-mood .mood-label {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.chip-mood.active {
  border-color: var(--green);
  background: var(--green-bg);
}

.chip-mood.active .mood-face {
  color: var(--green-dark);
}

.chip-mood.active .mood-label {
  color: var(--green);
  font-weight: 600;
}

.chip-mood[data-value="terrible"] .mood-face {
  color: var(--danger);
}

.chip-mood[data-value="poor"] .mood-face {
  color: var(--gold);
}

.chip-mood[data-value="okay"] .mood-face {
  color: var(--text-muted);
}

.chip-mood[data-value="great"] .mood-face {
  color: var(--green);
}

.chip-mood[data-value="amazing"] .mood-face {
  color: var(--purple);
}

.input {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s ease,box-shadow 0.2s ease;
}

.input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px var(--green-glow);
  background: rgba(255,255,255,0.95);
}

.input::placeholder {
  color: var(--text-faint);
  font-style: italic;
}

.btn-primary {
  width: 100%;
  padding: 16px 28px;
  background: var(--green);
  color: white;
  border-radius: var(--radius-full);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
  transition: transform 0.2s var(--ease),box-shadow 0.2s var(--ease),background 0.2s ease;
  box-shadow: 0 2px 12px rgba(74,103,65,0.18),0 1px 3px rgba(74,103,65,0.1);
  position: relative;
  overflow: hidden;
}

.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg,rgba(255,255,255,0.08) 0%,transparent 50%);
  pointer-events: none;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(74,103,65,0.22),0 2px 6px rgba(74,103,65,0.12);
  background: var(--green-dark);
}

.btn-primary:active {
  transform: scale(0.97);
  transition: transform 0.1s ease;
}

.btn-ghost {
  padding: 12px 22px;
  color: var(--green-dark);
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-full);
  transition: all 0.3s var(--ease);
}

.btn-ghost:hover {
  background: var(--green-bg);
}

.btn-add {
  width: 100%;
  padding: 16px;
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s var(--ease);
}

.btn-add:hover {
  background: var(--green-bg);
  border-color: var(--green-border);
  color: var(--green-dark);
  transform: translateY(-1px);
}

.chip {
  padding: 9px 18px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  background: var(--bg-card);
  border: 1px solid var(--border);
  transition: all 0.2s var(--ease);
  box-shadow: var(--shadow-whisper);
}

.chip:hover {
  border-color: var(--green-border);
  transform: translateY(-1px);
}

.chip.active {
  background: var(--green-bg);
  border-color: var(--green);
  color: var(--green-dark);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(107,143,94,0.15);
}

.chip-emoji {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  background: var(--bg-card);
  border: 2px solid transparent;
  box-shadow: var(--shadow-soft);
  transition: all 0.3s var(--ease-bounce);
}

.chip-emoji:hover {
  transform: scale(1.12) translateY(-2px);
  box-shadow: var(--shadow-float);
}

.chip-emoji.active {
  border-color: var(--green);
  background: var(--green-bg);
  transform: scale(1.08);
  box-shadow: 0 3px 12px rgba(107,143,94,0.2);
}

.toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--sand);
  border-radius: 28px;
  cursor: pointer;
  transition: all 0.4s var(--ease);
}

.toggle-slider::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 3px;
  width: 22px;
  height: 22px;
  background: white;
  border-radius: 50%;
  transition: transform 0.4s var(--ease-bounce);
  box-shadow: 0 2px 8px rgba(0,0,0,0.12),0 0 0 1px rgba(255,255,255,0.8) inset;
}

.toggle input:checked+.toggle-slider {
  background: linear-gradient(135deg,var(--green) 0%,var(--green-dark) 100%);
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.1),0 1px 3px rgba(122,158,109,0.3);
}

.toggle input:checked+.toggle-slider::before {
  transform: translateX(20px);
}

.mode-badge {
  padding: 7px 16px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg,rgba(221,233,214,0.65) 0%,rgba(220,239,212,0.5) 100%);
  font-size: 12px;
  font-weight: 600;
  color: var(--green-dark);
  transition: all 0.25s var(--ease);
  box-shadow: var(--shadow-whisper);
  border: 1px solid rgba(107,143,94,0.12);
  cursor: pointer;
  white-space: nowrap;
  backdrop-filter: blur(6px);
  position: relative;
  overflow: hidden;
  letter-spacing: 0;
}

.mode-badge:active {
  transform: scale(0.96);
}

.mode-badge-sm {
  font-size: 12px;
  padding: 6px 14px;
}

.time-block {
  display: flex;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
  align-items: flex-start;
  border-left: 3px solid var(--border-light);
  padding-left: 16px;
  min-height: 56px;
  transition: all 0.3s var(--ease);
}

.time-block.active {
  background: var(--green-bg);
  border-radius: var(--radius-sm);
  padding-left: 8px;
  margin-left: -8px;
  border-left-color: var(--green);
}

.time-block-time {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 56px;
  padding-top: 5px;
  letter-spacing: 0.02em;
}

.time-block-content {
  flex: 1;
  border-radius: var(--radius-xs);
  padding: 12px 16px;
  min-height: 28px;
  background: var(--bg-card);
  border: none;
  box-shadow: var(--shadow-soft);
  transition: all 0.3s var(--ease);
}

.time-block-content.empty-slot {
  background: none;
  border: 1px dashed var(--border-light);
  min-height: 16px;
  padding: 4px 12px;
}

.time-block-content.mental {
  background: rgba(76,175,80,0.12);
  border-left: 3px solid var(--green);
}

.time-block-content.physical {
  background: rgba(156,39,176,0.10);
  border-left: 3px solid var(--purple);
}

.time-block-content.spiritual {
  background: rgba(255,193,7,0.10);
  border-left: 3px solid var(--gold);
}

.time-block-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-warm);
}

.time-block-range {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 3px;
}

.modal-mode-title {
  text-align: center;
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 600;
  color: var(--text-warm);
  margin-bottom: 4px;
}

.modal-mode-sub {
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 24px;
}

.mode-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mode-option {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px;
  background: rgba(255,254,250,0.95);
  border: 2px solid var(--border-light);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.25s var(--ease);
  text-align: left;
  position: relative;
  box-shadow: var(--shadow-card);
}

.mode-option.active {
  border-color: var(--green);
  background: linear-gradient(135deg,rgba(221,233,214,0.25) 0%,rgba(255,254,250,0.98) 100%);
  box-shadow: 0 4px 20px rgba(122,158,109,0.1),0 0 0 1px rgba(122,158,109,0.05);
}

.mode-option:active {
  transform: scale(0.98);
}

.mode-opt-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--bg-inset);
  flex-shrink: 0;
  font-size: 28px;
  margin-top: 2px;
}

.mode-option.active .mode-opt-icon {
  background: var(--green-pale);
}

.mode-opt-info {
  flex: 1;
  min-width: 0;
  padding-right: 40px;
}

.mode-opt-info strong {
  font-size: 15px;
  color: var(--text-warm);
  display: block;
}

.mode-opt-info p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
  line-height: 1.5;
}

.mode-opt-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--border);
  flex-shrink: 0;
}

.mode-option.active .mode-opt-check {
  background: var(--green);
  border-color: var(--green);
  position: relative;
}

.mode-option.active .mode-opt-check::after {
  content: "✓";
  color: white;
  font-size: 13px;
  font-weight: 800;
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.notif-bell-btn {
  position: absolute;
  top: 4px;
  right: 0;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: var(--bg-card);
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.15s,box-shadow 0.15s;
  color: var(--green-dark);
}

.notif-bell-btn:hover {
  transform: scale(1.08);
  box-shadow: var(--shadow-float);
}

.notif-bell-btn:active {
  transform: scale(0.95);
}

.notif-bell-btn svg {
  width: 20px;
  height: 20px;
}

.notif-bell-badge {
  position: absolute;
  top: -4px;
  right: -6px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: var(--danger);
  color: white;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 16px;
  border: 2px solid var(--bg);
  text-align: center;
  pointer-events: none;
}

.notif-history-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 60px;
  animation: fadeIn 0.2s ease;
}

.notif-history-overlay.hidden {
  display: none;
}

.notif-history-panel {
  width: 92%;
  max-width: 420px;
  max-height: 70vh;
  background: var(--bg);
  border-radius: var(--radius-lg, 20px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: slideDown 0.25s var(--ease-out);
}

.notif-history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--border);
}

.notif-history-header h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-warm);
  margin: 0;
}

.notif-history-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.notif-history-clear {
  border: none;
  background: none;
  color: var(--text-muted);
  font-size: 12px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm, 8px);
}

.notif-history-clear:hover {
  color: var(--red, #e74c3c);
  background: rgba(231,76,60,0.08);
}

.notif-history-close {
  border: none;
  background: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 4px;
  display: flex;
}

.notif-history-close svg {
  width: 18px;
  height: 18px;
}

.notif-history-list {
  overflow-y: auto;
  padding: 8px 0;
  flex: 1;
}

.notif-history-item {
  display: flex;
  gap: 12px;
  padding: 14px 20px;
  transition: background 0.15s;
}

.notif-history-item:not(:last-child) {
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

.notif-history-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--sage);
  color: var(--green-dark);
}

.notif-type-reminder .notif-history-icon {
  background: rgba(231,166,76,0.12);
  color: #d4940a;
}

.notif-type-task_done .notif-history-icon {
  background: rgba(107,143,94,0.12);
  color: var(--green-dark);
}

.notif-type-partner .notif-history-icon {
  background: rgba(166,134,189,0.12);
  color: #8e6aad;
}

.notif-type-system .notif-history-icon {
  background: rgba(120,120,120,0.1);
  color: var(--text-muted);
}

.notif-history-content {
  flex: 1;
  min-width: 0;
}

.notif-history-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-warm);
  line-height: 1.3;
}

.notif-history-body {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 3px;
  line-height: 1.4;
  overflow-wrap: break-word;
}

.notif-history-time {
  font-size: 11px;
  color: var(--text-faint);
  margin-top: 4px;
}

.notif-history-empty {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-muted);
}

.notif-history-empty svg {
  color: var(--text-faint);
  margin-bottom: 12px;
}

.notif-history-empty p {
  font-size: 15px;
  font-weight: 500;
  margin: 0;
}

.notif-history-empty-sub {
  font-size: 12px;
  color: var(--text-faint);
  margin-top: 6px !important;
}

.filter-chip {
  padding: 7px 16px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.filter-chip:active {
  transform: scale(0.95);
}

.filter-chip.active {
  background: var(--green-bg);
  color: var(--green-dark);
  border-color: var(--green);
}

.task-event-badge {
  font-size: 9px;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: var(--gold-bg);
  color: var(--gold);
  font-weight: 700;
  letter-spacing: 0.3px;
}

.task-shared-badge {
  font-size: 9px;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: var(--purple-bg);
  color: var(--purple);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.done-section.collapsed .done-toggle-icon {
  transform: rotate(-90deg);
}

.task-min-badge {
  font-size: 9px;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  background: var(--green-bg);
  color: var(--green-dark);
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.task-delegate-badge {
  opacity: 0.5;
  display: inline-flex;
  align-items: center;
}

.task-priority-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
  flex-shrink: 0;
  vertical-align: middle;
}

.task-priority-dot.high {
  background: var(--danger);
  box-shadow: 0 0 6px rgba(196,80,80,0.3);
}

.task-priority-dot.low {
  background: var(--text-faint);
}

.time-block-content:hover {
  box-shadow: var(--shadow-float);
  transform: translateX(3px);
}

.back-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: none;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  box-shadow: var(--shadow-soft);
  transition: all 0.2s var(--ease);
  cursor: pointer;
  color: var(--text-secondary);
  -webkit-tap-highlight-color: transparent;
  flex-shrink: 0;
}

.back-btn:hover {
  transform: scale(1.05);
  background: var(--bg-inset);
  color: var(--text);
}

.back-btn:active {
  transform: scale(0.92);
  background: var(--bg-inset);
}

.filter-btn {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-nudge {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: transform 0.2s var(--ease);
}

.btn-nudge:hover {
  transform: scale(1.2);
}

.btn-nudge:active {
  transform: scale(0.9);
}

.btn-reminder {
  width: 100%;
  padding: 14px;
  margin-top: 12px;
  background: var(--green-bg);
  color: var(--green);
  border: 1px solid var(--green-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s var(--ease);
}

.btn-reminder:hover {
  background: var(--green);
  color: #fff;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.25);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 200;
  animation: fadeIn 0.2s ease;
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: var(--bg);
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-width: 480px;
  max-height: 92vh;
  overflow-y: auto;
  animation: modalSlideUp 0.35s var(--ease-out);
  box-shadow: 0-8px 48px rgba(80,60,30,0.08),0-2px 16px rgba(80,60,30,0.04);
}

.modal-sm {
  border-radius: 24px;
  margin: auto 20px;
  max-height: 75vh;
  box-shadow: var(--shadow-dream);
  padding: 28px 24px;
}

.modal:has(.modal-sm),.modal.modal-centered {
  align-items: center;
}

.modal-sm-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-warm);
  margin-bottom: 6px;
}

.modal-sm-subtitle {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.4;
  margin-bottom: 16px;
}

.modal-sm-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.modal-sm-actions .btn-ghost {
  flex: 1;
  text-align: center;
}

.modal-sm-actions .btn-primary {
  flex: 1.5;
}

.modal-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border-light);
  position: sticky;
  top: 0;
  background: inherit;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(80,60,30,0.03);
}

.modal-header h3 {
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-warm);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.modal-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.modal-close {
  cursor: pointer;
  font-size: 20px;
  opacity: 0.6;
  transition: background 0.15s ease,opacity 0.15s ease;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.modal-close:hover {
  opacity: 1;
  background: rgba(80,60,30,0.04);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: block;
  margin-bottom: 8px;
}

.dur-input {
  width: 60px;
  text-align: center;
  font-weight: 700;
}

.mode-option:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-float);
}

.mode-option.active::after {
  content: "✓";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  background: linear-gradient(135deg,var(--green),var(--green-dark));
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(107,143,94,0.3);
}

.mode-opt-details {
  margin-top: 10px;
  padding-left: 18px;
  font-size: 12px;
  color: var(--text-muted);
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.mode-opt-details li {
  margin-bottom: 4px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 400;
  padding-left: 14px;
  position: relative;
  line-height: 1.5;
}

.bottom-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  padding-bottom: var(--safe-bottom);
  background: rgba(255,254,250,0.94);
  border-top: none;
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 100;
  box-shadow: 0-1px 0 rgba(80,60,30,0.03),0-4px 16px rgba(80,60,30,0.02);
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  transition: all 0.2s var(--ease);
  color: var(--text-faint);
  -webkit-tap-highlight-color: transparent;
  position: relative;
  border: none;
  background: none;
  cursor: pointer;
}

.nav-item:hover {
  color: var(--text-secondary);
}

.nav-item.active {
  color: var(--green-dark);
  background: var(--green-bg);
  border-radius: var(--radius-xs);
}

.nav-item:active {
  transform: scale(0.92);
}

.nav-icon {
  font-size: 20px;
  transition: transform 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.nav-item:hover .nav-icon {
  transform: translateY(-1px);
}

.nav-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.nav-add {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(145deg,var(--green) 0%,var(--green-dark) 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  box-shadow: 0 4px 18px rgba(74,103,65,0.25),0 2px 6px rgba(74,103,65,0.12);
  transition: all 0.2s var(--ease);
  margin-top: -22px;
  -webkit-tap-highlight-color: transparent;
  animation: gentleGlow 4s ease-in-out infinite;
  position: relative;
}

.nav-add:active {
  transform: scale(0.92);
}

.nav-add .nav-icon {
  font-size: 28px;
  font-weight: 300;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-add .nav-label {
  display: none;
}

.toast {
  position: fixed;
  bottom: calc(var(--nav-height) + var(--safe-bottom) + 16px);
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg,var(--green-dark) 0%,#3d5835 100%);
  color: var(--cream);
  padding: 14px 24px;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 500;
  z-index: 500;
  animation: toastIn 0.35s var(--ease-out);
  box-shadow: 0 8px 32px rgba(74,103,65,0.3);
  letter-spacing: 0.01em;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: calc(100% - 32px);
  text-align: center;
}

.toast.hidden {
  display: none;
}

.priority-options {
  display: flex;
  gap: 8px;
}

.time-block-inputs {
  display: flex;
  gap: 10px;
}

.time-block-inputs .input {
  flex: 1;
}

.custom-date-wrap input[type="date"] {
  position: absolute;
  color: transparent;
  cursor: pointer;
  inset: 0;
  opacity: 0;
  z-index: 1;
}

.custom-date-wrap input[type="date"]::-webkit-datetime-edit {
  visibility: hidden;
}

.form-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
  font-style: italic;
  line-height: 1.4;
}

.btn-danger {
  width: 100%;
  padding: 14px;
  background: var(--danger-bg);
  color: var(--danger);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  margin-top: 10px;
  transition: all 0.2s ease;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-danger:hover {
  background: rgba(196,80,80,0.12);
  transform: translateY(-1px);
  border-color: var(--danger);
}

.day-picker {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.install-banner,.notif-banner {
  position: fixed;
  bottom: 80px;
  left: 18px;
  right: 18px;
  z-index: 1500;
  animation: modalSlideUp 0.5s var(--ease-out);
}

.install-banner-content,.notif-banner-content {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow-dream);
  border: none;
}

.install-banner-icon,.notif-banner-icon {
  font-size: 30px;
}

.install-banner-text,.notif-banner-text {
  flex: 1;
}

.install-banner-text strong,.notif-banner-text strong {
  font-size: 14px;
  display: block;
  font-weight: 600;
  color: var(--text-warm);
}

.install-banner-text p,.notif-banner-text p {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 3px;
}

.install-banner-btn,.notif-banner-btn {
  padding: 10px 20px;
  background: linear-gradient(135deg,var(--green-dark),#4a7040);
  color: white;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 3px 12px rgba(61,90,52,0.25);
}

.install-banner-close,.notif-banner-close {
  font-size: 18px;
  color: var(--text-muted);
  padding: 4px;
  opacity: 0.6;
  transition: opacity 0.2s;
}

.install-banner-close:hover,.notif-banner-close:hover {
  opacity: 1;
}

.update-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2000;
  animation: updateSlideDown 0.3s ease;
}

.update-banner-content {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg,#2d5a27 0%,#3d6e35 100%);
  padding: 14px 18px;
  padding-top: max(14px,env(safe-area-inset-top));
  color: white;
}

.update-banner-icon {
  flex-shrink: 0;
}

.update-banner-icon svg {
  width: 20px;
  height: 20px;
  color: rgba(255,255,255,0.9);
}

.update-banner-text {
  flex: 1;
}

.update-banner-text strong {
  font-size: 13px;
  display: block;
  font-weight: 600;
}

.update-banner-text p {
  font-size: 11px;
  opacity: 0.85;
  margin-top: 2px;
}

.update-banner-btn {
  padding: 8px 18px;
  background: rgba(255,255,255,0.2);
  color: white;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  border: 1px solid rgba(255,255,255,0.3);
}

.update-banner-btn:active {
  background: rgba(255,255,255,0.35);
}

.update-banner-close {
  font-size: 18px;
  color: rgba(255,255,255,0.7);
  padding: 4px;
}

.update-banner-close:active {
  color: white;
}

.chip-mood:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-float);
}

.input:focus,.textarea:focus,select:focus {
  border-color: var(--green-light);
  box-shadow: 0 0 0 3px rgba(122,158,109,0.08),0 2px 8px rgba(122,158,109,0.06);
  outline: none;
}

.bottom-nav::before {
  content: "";
  position: absolute;
  bottom: 100%;
  left: 0;
  right: 0;
  height: 30px;
  background: linear-gradient(to top,rgba(255,253,249,0.9),transparent);
  pointer-events: none;
}

.task-mini-badge {
  background: linear-gradient(135deg,#fbbf24,#f59e0b);
  color: #1a1a1a;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 8px;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 12px;
  border-radius: 8px;
}

.ics-import-area input[type="file"] {
  margin: 16px auto;
}

.btn-icon-sm {
  background: none;
  border: none;
  font-size: 14px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
}

.btn-icon-sm:hover {
  color: #ef4444;
  background: rgba(239,68,68,0.1);
}

.btn-ghost.btn-sm {
  background: none;
  border: none;
  color: var(--green);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 0;
}

.btn-ghost.btn-sm:hover {
  text-decoration: underline;
}

.mode-badge:hover {
  transform: scale(1.03);
  box-shadow: 0 3px 14px rgba(122,158,109,0.14);
}

.nav-item.active::after {
  content: "";
  position: absolute;
  top: 0px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  background: var(--green);
  border-radius: 50%;
  opacity: 0.7;
  bottom: 8px;
}

.modal-centered {
  align-items: center;
}

.modal-centered .modal-content {
  border-radius: var(--radius);
  max-height: 80vh;
}

.install-banner,.notif-banner,.update-banner {
  position: fixed;
  bottom: calc(var(--nav-height) + var(--safe-bottom) + 60px);
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 460px;
  z-index: 300;
  animation: toastIn 0.35s var(--ease-out);
}

.install-banner.hidden,.notif-banner.hidden,.update-banner.hidden {
  display: none;
}

.install-banner-content,.notif-banner-content,.update-banner-content {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-dream);
  border: 1px solid var(--border);
}

.install-banner-icon,.notif-banner-icon,.update-banner-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--green-bg);
  color: var(--green-dark);
  flex-shrink: 0;
}

.install-banner-text,.notif-banner-text,.update-banner-text {
  flex: 1;
  min-width: 0;
}

.install-banner-text strong,.notif-banner-text strong,.update-banner-text strong {
  font-size: 14px;
  color: var(--text-warm);
  display: block;
}

.install-banner-text p,.notif-banner-text p,.update-banner-text p {
  font-size: 12px;
  color: var(--text-muted);
  margin: 2px 0 0;
}

.install-banner-btn,.notif-banner-btn,.update-banner-btn {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: var(--green);
  color: white;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.install-banner-close,.notif-banner-close,.update-banner-close {
  background: none;
  border: none;
  color: var(--text-faint);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}

.filter-btn:hover {
  background: var(--green-bg);
  border-color: var(--green-border);
}

.task-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 4px 0;
}

.task-toggle-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.task-toggle-label i {
  color: var(--text-muted);
}

.toggle-slider-sm {
  position: relative;
  width: 40px;
  height: 22px;
  background: var(--bg-inset);
  border-radius: 11px;
  transition: background 0.2s;
  flex-shrink: 0;
}

.toggle-slider-sm::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
  transition: transform 0.2s;
}

input[type="checkbox"]:checked+.toggle-slider-sm {
  background: var(--green);
}

input[type="checkbox"]:checked+.toggle-slider-sm::after {
  transform: translateX(18px);
}

.task-toggles input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.task-toggles .form-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: 4px 0 0;
  padding-left: 24px;
}

.pillar-name-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  padding: 4px 0;
  border-bottom: 1px dashed var(--border);
  font-family: inherit;
}

.pillar-name-input:focus {
  outline: none;
  border-bottom-color: var(--green);
}

.heart-btn {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: var(--radius-full);
  transition: transform 0.3s var(--ease),filter 0.3s ease;
  filter: grayscale(1) opacity(0.4);
  line-height: 1;
}

.heart-btn:hover {
  filter: grayscale(0) opacity(0.8);
  transform: scale(1.1);
}

.heart-btn.hearted {
  filter: grayscale(0) opacity(1);
  animation: heartPop 0.4s ease;
}

.modal-overlay.active {
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.nav-add::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  background: radial-gradient(circle,rgba(122,158,109,0.08) 0%,transparent 70%);
  animation: addBtnGlow 3s ease-in-out infinite;
  pointer-events: none;
}

.mode-opt-details li::before {
  content: "•";
  position: absolute;
  left: 2px;
  color: var(--text-faint);
}

.mode-option.active .mode-opt-details li {
  color: var(--text-secondary);
}

.mode-option.active .mode-opt-details li::before {
  color: var(--green);
}

.mode-badge::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg,transparent 0%,rgba(255,255,255,0.2) 50%,transparent 100%);
  animation: chipShimmer 8s ease-in-out infinite 1s;
  pointer-events: none;
}

.toast-undo-btn {
  margin-left: 12px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.9);
  font-weight: 700;
  cursor: pointer;
  font-size: 13px;
  text-decoration: underline;
  text-underline-offset: 2px;
  padding: 2px 6px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.toast-undo-btn:hover {
  background: rgba(255,255,255,0.15);
  text-decoration: none;
}

.toast-undo-btn:active {
  transform: scale(0.95);
}

button:focus-visible,.chip:focus-visible,.filter-chip:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

.modal-content::-webkit-scrollbar {
  width: 3px;
}

.modal-content::-webkit-scrollbar-thumb {
  background: rgba(80,60,30,0.06);
  border-radius: 3px;
}

.btn-primary:focus-visible {
  box-shadow: 0 2px 12px rgba(74,103,65,0.18),0 0 0 3px rgba(122,158,109,0.25);
}

.btn-ghost:active {
  transform: scale(0.97);
}

.input.input-error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(196,80,80,0.08);
  animation: inputShake 0.3s ease;
}

.input.input-error:focus {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(196,80,80,0.12);
}

@media (display-mode:standalone) {
  .install-banner {
    display: none !important;
  }
}

@media (max-width:380px) {
  .modal-sm {
    padding: 22px 18px;
    margin: auto 12px;
  }
}
