/* Card Component Styles */

.card {
  cursor: grab;
  transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
  box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.15) !important;
}

.card:active {
  cursor: grabbing;
}

.card-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #172b4d;
}

.card-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.card-body {
  padding: 0.75rem;
}

/* Card detail modal */
.card-detail-modal .modal-body {
  padding: 1.5rem;
}

.modal-content {
  background-color: #f8f9fa;
}

.card-description {
  min-height: 100px;
  resize: vertical;
}

/* Due date display */
.card-due-date {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.875rem;
}

.card-due-date.overdue {
  color: #dc3545;
}

.card-due-date.due-soon {
  color: #ffc107;
}

/* Total time per column summary */
.column-time-totals {
  background-color: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 0.5rem;
  overflow: hidden;
}

.column-time-totals-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.875rem;
  background-color: #eef1f4;
  color: #6c757d;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #e9ecef;
}

.column-time-totals-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.875rem;
  font-size: 0.8rem;
  color: #172b4d;
  border-bottom: 1px solid #eef1f4;
}

.column-time-totals-row:last-child {
  border-bottom: none;
}

.column-time-totals-name {
  font-weight: 500;
}

.column-time-totals-metrics {
  display: flex;
  gap: 1.25rem;
}

.column-time-totals-metrics > span {
  min-width: 5rem;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.column-time-totals-working {
  color: #172b4d;
  font-weight: 600;
}

.column-time-totals-calendar {
  color: #6c757d;
}

.column-time-totals-hold {
  color: #b45309;
}

.modal.modal-stacked {
  z-index: 1060;
}

/* Movement History Timeline */
.movement-history-timeline {
  position: relative;
  padding-left: 1.5rem;
}

.movement-history-timeline::before {
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 0.5rem;
  bottom: 0.5rem;
  width: 2px;
  background-color: #dee2e6;
}

.movement-history-item {
  position: relative;
  padding-bottom: 1rem;
}

.movement-history-item:last-child {
  padding-bottom: 0;
}

.movement-history-dot {
  position: absolute;
  left: -1.25rem;
  top: 0.35rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #6c757d;
  border: 2px solid #fff;
  z-index: 1;
}

.movement-history-item.current .movement-history-dot {
  background-color: #198754;
  box-shadow: 0 0 0 3px rgba(25, 135, 84, 0.25);
}

.movement-history-content {
  background-color: #f8f9fa;
  border-radius: 0.375rem;
  padding: 0.5rem 0.75rem;
  border: 1px solid #e9ecef;
}

.movement-history-item.current .movement-history-content {
  background-color: #f0fdf4;
  border-color: #bbf7d0;
}

.movement-history-column {
  font-size: 0.9rem;
  color: #172b4d;
}

.movement-history-dates {
  margin-top: 0.25rem;
  font-size: 0.8rem;
}

.movement-history-duration .badge {
  font-weight: 500;
  font-size: 0.75rem;
}

/* Movement history on-hold items */
.movement-history-item.on-hold .movement-history-dot {
  background-color: #ffc107;
  box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.25);
}

.movement-history-item.on-hold .movement-history-content {
  background-color: #fffbeb;
  border-color: #fde68a;
  border-left: 3px solid #ffc107;
}

/* On-hold state */
.card-on-hold {
  opacity: 0.6;
  border-left: 3px solid #ffc107;
}

.card-on-hold .card-title {
  color: #6c757d;
}

/* Hold toggle button */
.card-hold-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.15s, box-shadow 0.2s;
  font-size: 0.75rem;
  line-height: 1;
}

.card-hold-btn:hover {
  transform: scale(1.15);
}

.card-hold-btn:active {
  transform: scale(0.95);
}

.card-hold-btn.pause {
  background-color: #fff3cd;
  color: #997404;
}

.card-hold-btn.pause:hover {
  background-color: #ffe69c;
  box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.25);
}

.card-hold-btn.resume {
  background-color: #d1e7dd;
  color: #0f5132;
}

.card-hold-btn.resume:hover {
  background-color: #a3cfbb;
  box-shadow: 0 0 0 3px rgba(25, 135, 84, 0.25);
}
