/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --sidebar-w: 220px;
  --col-gap: 1px;

  --bg: #f6f6f4;
  --surface: #ffffff;
  --surface-2: #f0efed;
  --border: rgba(0,0,0,0.09);
  --border-strong: rgba(0,0,0,0.16);

  --text-primary: #1a1a18;
  --text-secondary: #6b6b67;
  --text-muted: #9d9d98;

  --sidebar-bg: #16161a;
  --sidebar-text: rgba(255,255,255,0.75);
  --sidebar-text-active: #ffffff;
  --sidebar-hover: rgba(255,255,255,0.07);
  --sidebar-active: rgba(255,255,255,0.12);

  --accent: #3b6fca;
  --accent-light: #e8eef9;

  --priority-high: #d44b3a;
  --priority-high-bg: #fdf0ee;
  --priority-medium: #c47c25;
  --priority-medium-bg: #fdf5ea;
  --priority-low: #3a8a5c;
  --priority-low-bg: #edf7f2;

  --status-todo: #6b6b67;
  --status-inprogress: #3b6fca;
  --status-done: #3a8a5c;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08), 0 1px 4px rgba(0,0,0,0.04);

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html { font-size: 15px; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-primary);
  display: flex;
  min-height: 100vh;
  line-height: 1.5;
}

/* ===== SIDEBAR ===== */
.sidebar {
  width: var(--sidebar-w);
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  overflow-y: auto;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 24px 20px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.logo-mark {
  width: 32px; height: 32px;
  background: var(--accent);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; color: #fff;
  letter-spacing: 0.5px; flex-shrink: 0;
}
.logo-label {
  font-size: 15px; font-weight: 600;
  color: var(--sidebar-text-active);
  letter-spacing: -0.2px;
}

.sidebar-nav {
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: none;
  border: none;
  color: var(--sidebar-text);
  font-size: 14px;
  font-family: var(--font);
  cursor: pointer;
  width: 100%;
  text-align: left;
  transition: background 0.15s, color 0.15s;
}
.nav-item svg { width: 17px; height: 17px; flex-shrink: 0; opacity: 0.8; }
.nav-item:hover { background: var(--sidebar-hover); color: var(--sidebar-text-active); }
.nav-item.active { background: var(--sidebar-active); color: var(--sidebar-text-active); }
.nav-item.active svg { opacity: 1; }

.sidebar-section {
  padding: 12px 10px 8px;
  border-top: 1px solid rgba(255,255,255,0.07);
  margin-top: 6px;
  flex: 1;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: rgba(255,255,255,0.35);
  font-weight: 600;
}

.btn-icon {
  width: 24px; height: 24px;
  background: none; border: none;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}
.btn-icon:hover { background: rgba(255,255,255,0.1); color: #fff; }
.btn-icon svg { width: 14px; height: 14px; }

.project-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.project-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--sidebar-text);
  cursor: pointer;
  transition: background 0.12s;
}
.project-item:hover { background: var(--sidebar-hover); color: var(--sidebar-text-active); }
.project-dot {
  width: 8px; height: 8px;
  border-radius: 50%; flex-shrink: 0;
}
.project-icon { font-size: 14px; }
.project-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project-count {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
  font-variant-numeric: tabular-nums;
}

.sidebar-bottom {
  padding: 14px 16px;
  border-top: 1px solid rgba(255,255,255,0.07);
}
.stats-mini {
  display: flex; gap: 16px;
}
.stat {
  display: flex; flex-direction: column; gap: 2px;
}
.stat span {
  font-size: 20px; font-weight: 700;
  color: #fff;
}
.stat small {
  font-size: 11px;
  color: rgba(255,255,255,0.35);
}

/* ===== MAIN ===== */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  overflow: hidden;
}

.view { display: none; flex-direction: column; flex: 1; }
.view.active { display: flex; }

/* ===== VIEW HEADER ===== */
.view-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 28px 32px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  gap: 16px;
  flex-shrink: 0;
}
.view-title-block { display: flex; flex-direction: column; gap: 10px; }
.view-title-block h1 {
  font-size: 22px; font-weight: 700;
  letter-spacing: -0.4px;
  color: var(--text-primary);
}
.week-nav {
  display: flex; align-items: center; gap: 4px;
}

.filter-bar {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.filter-bar select {
  height: 32px;
  padding: 0 10px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 13px;
  font-family: var(--font);
  cursor: pointer;
}
.filter-bar select:focus { outline: none; border-color: var(--accent); }

/* ===== BUTTONS ===== */
.btn-primary {
  padding: 9px 18px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.15s;
  flex-shrink: 0;
}
.btn-primary:hover { opacity: 0.88; }

.btn-ghost {
  padding: 8px 14px;
  background: none;
  color: var(--text-secondary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-family: var(--font);
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.btn-ghost:hover { background: var(--surface-2); color: var(--text-primary); }
.btn-danger { color: #c0392b; border-color: #fbc4c4; }
.btn-danger:hover { background: #fdf0ee; }

/* ===== CALENDAR LAYOUT ===== */
.calendar-layout {
  display: flex;
  flex: 1;
  overflow: hidden;
  gap: 0;
}

/* Favourites panel */
.fav-panel {
  width: 0;
  flex-shrink: 0;
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: width 0.25s ease;
}
.fav-panel.fav-panel-open {
  width: 200px;
}

/* Toggle button — always visible tab on the left edge of the calendar */
.fav-toggle-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 0;
  width: 32px;
  flex-shrink: 0;
  background: var(--surface);
  border: none;
  border-right: 1px solid var(--border);
  cursor: pointer;
  color: var(--text-muted);
  font-size: 11px;
  font-family: var(--font);
  font-weight: 600;
  writing-mode: vertical-lr;
  text-orientation: mixed;
  letter-spacing: 0.5px;
  transition: background 0.15s, color 0.15s;
}
.fav-toggle-btn:hover { background: var(--surface-2); color: var(--text-secondary); }
.fav-toggle-btn.active { color: #b87d10; background: #fdf8ee; }
.fav-toggle-btn svg { flex-shrink: 0; }
.fav-toggle-btn span { writing-mode: vertical-rl; text-orientation: mixed; }
.fav-toggle-chevron {
  transition: transform 0.25s ease;
  transform: rotate(90deg);
}
.fav-toggle-btn.active .fav-toggle-chevron {
  transform: rotate(-90deg);
}

.fav-panel-header {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 16px 16px 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: var(--text-secondary);
  white-space: nowrap;
}
.fav-panel-header svg { color: #e8a020; flex-shrink: 0; }

.fav-count {
  margin-left: auto;
  background: #fdf3e0;
  color: #b87d10;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 20px;
}

.fav-hint {
  font-size: 11px;
  color: var(--text-muted);
  padding: 0 16px 10px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.fav-list {
  flex: 1;
  overflow-y: auto;
  padding: 10px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fav-empty {
  text-align: center;
  padding: 24px 12px;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.6;
}
.fav-empty svg { display: block; margin: 0 auto 8px; opacity: 0.3; }

.fav-item {
  padding: 9px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: grab;
  user-select: none;
  transition: box-shadow 0.15s, transform 0.1s, border-color 0.15s;
  position: relative;
}
.fav-item:hover {
  box-shadow: var(--shadow-sm);
  border-color: var(--border-strong);
  transform: translateY(-1px);
}
.fav-item:active { cursor: grabbing; transform: scale(0.98); }

.fav-item-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
  margin-bottom: 5px;
  padding-right: 18px;
}

.fav-item-meta {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}

.fav-item-dur {
  font-size: 11px;
  color: var(--text-muted);
}

.fav-priority-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.fav-priority-dot.high { background: var(--priority-high); }
.fav-priority-dot.medium { background: var(--priority-medium); }
.fav-priority-dot.low { background: var(--priority-low); }

.fav-item-unfav {
  position: absolute;
  top: 6px; right: 6px;
  width: 18px; height: 18px;
  background: none; border: none;
  cursor: pointer;
  color: #e8a020;
  display: flex; align-items: center; justify-content: center;
  border-radius: 3px;
  opacity: 0;
  transition: opacity 0.15s;
  padding: 0;
}
.fav-item:hover .fav-item-unfav { opacity: 1; }
.fav-item-unfav:hover { color: #c04f35; }
.fav-item-unfav svg { width: 13px; height: 13px; }

/* Star button in modal */
.btn-star {
  width: 32px; height: 32px;
  background: none;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  flex-shrink: 0;
}
.btn-star:hover { background: #fdf3e0; border-color: #e8a020; color: #e8a020; }
.btn-star.active { background: #fdf3e0; border-color: #e8a020; color: #e8a020; }
.btn-star.active svg { fill: #e8a020; stroke: #e8a020; }

/* ===== CALENDAR ===== */
.calendar-container {
  flex: 1;
  overflow: auto;
  padding: 20px 24px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: 54px repeat(7, 1fr);
  gap: 0;
  min-width: 800px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.cal-corner { background: var(--surface-2); border-bottom: 1px solid var(--border); }

.cal-day-header {
  text-align: center;
  padding: 12px 6px;
  background: var(--surface-2);
  border-left: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.cal-day-header .day-name {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--text-muted);
  font-weight: 600;
}
.cal-day-header .day-num {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-top: 2px;
}
.cal-day-header.today .day-num { color: var(--accent); }
.cal-day-header.today .day-name { color: var(--accent); opacity: 0.75; }

.cal-time-label {
  font-size: 11px;
  color: var(--text-muted);
  text-align: right;
  padding-right: 10px;
  height: 48px;
  display: flex;
  align-items: flex-start;
  padding-top: 4px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.cal-cell {
  border-left: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  height: 48px;
  position: relative;
  background: var(--surface);
  transition: background 0.1s;
  overflow: visible;
}
.cal-cell:hover { background: #f8f8f6; }
.cal-cell.drop-target { background: var(--accent-light); }
.cal-cell.today-col { background: #fafbff; }

/* Minute drop indicator */
.cal-min-indicator {
  position: absolute;
  left: 0; right: 0;
  height: 2px;
  background: var(--accent);
  pointer-events: none;
  z-index: 20;
}
.cal-min-indicator::before {
  content: attr(data-time);
  position: absolute;
  left: 4px;
  top: -9px;
  font-size: 10px;
  font-weight: 700;
  color: var(--accent);
  background: var(--surface);
  padding: 1px 5px;
  border-radius: 3px;
  border: 1px solid var(--accent);
  white-space: nowrap;
}

.cal-task-block {
  position: absolute;
  left: 3px; right: 3px;
  border-radius: 5px;
  padding: 4px 7px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: grab;
  z-index: 2;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  user-select: none;
  line-height: 1.3;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
  transition: box-shadow 0.15s, transform 0.1s;
}
.cal-task-block:hover { box-shadow: 0 3px 10px rgba(0,0,0,0.16); }
.cal-task-block:active { cursor: grabbing; transform: scale(1.02); }
.cal-task-block .block-title { font-weight: 600; font-size: 11.5px; }
.cal-task-block .block-time { font-size: 10px; opacity: 0.75; margin-top: 1px; }

.block-high   { background: #fbe9e7; color: #b83225; border-left: 3px solid #d44b3a; }
.block-medium { background: #fff8ec; color: #9d6020; border-left: 3px solid #c47c25; }
.block-low    { background: #e9f7ee; color: #256b45; border-left: 3px solid #3a8a5c; }
.block-done   { background: #f0f0ef; color: #888;    border-left: 3px solid #bbb; }

.block-unsched-btn {
  position: absolute;
  top: 3px; right: 3px;
  width: 16px; height: 16px;
  background: rgba(0,0,0,0.15);
  border: none;
  border-radius: 3px;
  color: inherit;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  transition: opacity 0.15s, background 0.15s;
  padding: 0;
  font-weight: 700;
}
.cal-task-block:hover .block-unsched-btn { opacity: 1; }
.block-unsched-btn:hover { background: rgba(0,0,0,0.3); }

/* ===== TASKS VIEW ===== */
.task-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding: 24px 32px;
  flex: 1;
  overflow-y: auto;
  align-content: start;
}

.task-col { display: flex; flex-direction: column; gap: 8px; }

.col-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 4px;
}
.col-header svg { width: 15px; height: 15px; }
.col-count {
  margin-left: auto;
  font-size: 12px;
  background: rgba(0,0,0,0.08);
  border-radius: 20px;
  padding: 2px 8px;
  font-weight: 600;
}
.col-header.todo { background: #f4f4f2; color: var(--text-secondary); }
.col-header.inprogress { background: var(--accent-light); color: var(--accent); }
.col-header.done { background: #edf7f2; color: var(--priority-low); }

.col-body { display: flex; flex-direction: column; gap: 8px; }

.task-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  cursor: pointer;
  transition: box-shadow 0.15s, transform 0.1s;
  position: relative;
}
.task-card:hover { box-shadow: var(--shadow-sm); transform: translateY(-1px); }

.task-card-header {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
}
.task-check {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  flex-shrink: 0;
  margin-top: 1px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s, border-color 0.15s;
}
.task-check:hover { border-color: var(--accent); }
.task-check.checked { background: var(--priority-low); border-color: var(--priority-low); }
.task-check.checked::after { content: '✓'; font-size: 10px; color: #fff; font-weight: 700; }

.task-name {
  font-size: 14px; font-weight: 600;
  color: var(--text-primary);
  flex: 1;
  line-height: 1.4;
}
.task-card.done-card .task-name { text-decoration: line-through; color: var(--text-muted); }

.task-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 20px;
}
.badge-high { background: var(--priority-high-bg); color: var(--priority-high); }
.badge-medium { background: var(--priority-medium-bg); color: var(--priority-medium); }
.badge-low { background: var(--priority-low-bg); color: var(--priority-low); }
.badge-project { background: var(--surface-2); color: var(--text-secondary); border: 1px solid var(--border); }
.badge-date { background: var(--surface-2); color: var(--text-muted); font-weight: 500; font-size: 11px; padding: 2px 7px; border-radius: 4px; }

.task-duration {
  font-size: 11px;
  color: var(--text-muted);
  margin-left: auto;
}
.task-desc-preview {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.task-timestamps {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
}
.timestamp {
  font-size: 11px;
  color: var(--text-muted);
}

/* ===== NOTES ===== */
.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  padding: 24px 32px;
  align-content: start;
}

.note-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  cursor: pointer;
  transition: box-shadow 0.15s, transform 0.1s;
  position: relative;
}
.note-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.note-card.color-blue { border-top: 3px solid #3b6fca; }
.note-card.color-green { border-top: 3px solid #3a8a5c; }
.note-card.color-amber { border-top: 3px solid #c47c25; }
.note-card.color-red { border-top: 3px solid #d44b3a; }
.note-card.color-purple { border-top: 3px solid #7340c8; }

.note-title {
  font-size: 15px; font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.note-content-preview {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.note-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.note-date { font-size: 11px; color: var(--text-muted); }
.note-project-tag {
  font-size: 11px; font-weight: 600;
  color: var(--text-secondary);
  background: var(--surface-2);
  padding: 2px 8px;
  border-radius: 20px;
}

/* empty state */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 60px 20px;
  color: var(--text-muted);
  text-align: center;
  grid-column: 1 / -1;
}
.empty-state svg { width: 40px; height: 40px; opacity: 0.3; }
.empty-state p { font-size: 14px; }

/* ===== MODALS ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 500;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(2px);
}
.modal-overlay.open { display: flex; }

.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
  animation: modal-in 0.2s ease;
}
.modal-sm { max-width: 420px; }

@keyframes modal-in {
  from { opacity: 0; transform: scale(0.96) translateY(8px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px 0;
  flex-shrink: 0;
}
.modal-header h2 { font-size: 17px; font-weight: 700; }
.modal-header .btn-icon { color: var(--text-muted); }
.modal-header .btn-icon:hover { color: var(--text-primary); background: var(--surface-2); }

.modal-body {
  padding: 20px 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.form-row {
  display: flex;
  gap: 14px;
  margin-bottom: 16px;
}
.form-group { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.form-group.full { flex: 1 1 100%; }
.form-group label {
  font-size: 12px; font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}
.form-group input[type="text"],
.form-group input[type="date"],
.form-group input[type="time"],
.form-group input[type="datetime-local"],
.form-group input[type="number"],
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font);
  color: var(--text-primary);
  background: var(--surface);
  transition: border-color 0.15s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(59,111,202,0.12);
}
.form-group textarea { resize: vertical; min-height: 80px; line-height: 1.6; }
.duration-row {
  display: flex; align-items: center; gap: 6px;
}
.duration-row input { flex: 1; }
.duration-row span { font-size: 13px; color: var(--text-muted); flex-shrink: 0; }

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px 22px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.modal-footer-left { display: flex; gap: 8px; }
.modal-footer-right { display: flex; gap: 8px; }

/* ===== TOAST ===== */
.toast {
  position: fixed;
  bottom: 28px; right: 28px;
  background: var(--text-primary);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  z-index: 9999;
  transform: translateY(80px);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
  pointer-events: none;
  max-width: 320px;
  box-shadow: var(--shadow-md);
}
.toast.show { transform: translateY(0); opacity: 1; }

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.14); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.25); }

