/* ---- Gantt / swimlane timeline（視圖②舊件保留樣式） ---- */
.timeline-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 8px;
}
.timeline-inner { position: relative; }

.ruler-row, .overlay-row, .tl-row {
  display: flex;
  border-bottom: 1px solid var(--border-soft);
}
.ruler-row { position: sticky; top: 0; background: var(--card); z-index: 5; }

.row-label {
  position: sticky;
  left: 0;
  z-index: 2;
  width: 220px;
  min-width: 220px;
  background: var(--card);
  border-right: 1px solid var(--border);
  padding: 6px 10px;
  font-size: 15px;
  line-height: 1.3;
}
.row-label .note { font-size: 13px; color: var(--muted); display: block; }
.row-label .lane-title { font-weight: 600; }

.ruler-row .row-label { background: var(--card-soft); }

.row-track {
  position: relative;
  flex: 1;
  min-height: 44px;
}

/* 全高格線層：貫穿整張圖（不只頂部尺規），方便逐列對照色塊落在哪一天 */
.tl-grid {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 0;
  pointer-events: none;
}
.day-weekend {
  position: absolute;
  top: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.03);
}
.day-tick {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--border-soft);
}
.day-tick.today { background: var(--today-bg); width: 22px; }
.month-label {
  position: absolute;
  top: 4px;
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}

.bar {
  position: absolute;
  top: 8px;
  height: 26px;
  border-radius: 4px;
  font-size: 12px;
  color: #fff;
  display: flex;
  align-items: center;
  padding: 0 6px;
  white-space: nowrap;
  overflow: hidden;
  background: #5a7fb8;
  z-index: 1;
}
.bar .bar-date { opacity: 0.9; }

.overlay-row .row-track { min-height: 20px; }
.overlay-band {
  position: absolute;
  top: 2px;
  height: 16px;
  border-radius: 3px;
  opacity: 0.85;
}

