/* modules/plans/plansView.css — routine template cards + the routine builder dialog's
   exercise list rows. Extracted from index.css to live next to plansView.js. */

.routine-card {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}
.routine-card:hover {
  border-color: rgba(79, 70, 229, 0.4);
}
.routine-title-info h3 {
  font-size: 18px;
  font-weight: 700;
  font-family: var(--font-header);
  margin-bottom: 4px;
}
.routine-title-info p {
  font-size: 13px;
  line-height: 1.4;
  margin-bottom: 12px;
}
.routine-exercise-preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}
.preview-tag {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 10px;
}
.preview-tag-detail {
  color: var(--primary);
  font-weight: 700;
  font-family: var(--font-mono);
} /* Exercise Database Library card items */
.routine-builder-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 250px;
  overflow-y: auto;
  padding-right: 4px;
  margin-top: 10px;
  margin-bottom: 10px;
}
/* Two lines: the exercise on the first, its four numbers and the remove button on the second. On
   one line the row needed 380px; at 390px it had 304, so the rest field and the remove button sat
   past the right edge of the screen. The exercise name is also no longer cut. */
.routine-builder-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  padding: 8px;
  border-radius: var(--border-radius-sm);
}
/* `min-width: 0` because a select is as wide as its longest option by default, and a flex item
   keeps that width: the longest exercise names of the Slovenian and German demo pushed the row
   25px past a 390px screen. The closed select cuts a long name; the open list shows it whole. */
.routine-builder-row select {
  flex: 1 0 100%;
  min-width: 0;
}
/* The four numbers share the line with the remove button and each takes an equal part of it, so a
   two-digit number is never cut at 390px. Each has a caption that stays when the field is filled. */
.routine-builder-row .routine-builder-field {
  flex: 1 1 0;
  min-width: 0;
}
.routine-builder-row .routine-builder-field input {
  width: 100%;
  min-width: 0;
  padding-inline: 6px;
}
.routine-builder-caption,
.routine-builder-field .load-unit {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.btn-remove-row {
  background: transparent;
  border: none;
  color: var(--danger);
  cursor: pointer;
  font-size: 14px;
  padding: 4px;
}
.routines-empty-state {
  grid-column: 1 / -1;
}
/* "+N more" tag on a truncated exercise-preview list: same shape as .preview-tag, primary-tinted
   instead of the neutral default. Chained to beat .preview-tag's own background/font-weight. */
.preview-tag.preview-tag-more {
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 700;
}
/* Sets/Reps/Load/Rest cells in the routine builder row sit tighter than the form's default
   .form-group gap. */
.form-group.routine-builder-field {
  gap: 2px;
}

/* --- Pending plan adjustments (dashboard widget) --- */
.adjustment-count-badge {
  display: inline-block;
}
.adjustments-empty-state {
  padding: 16px;
}
.adjustment-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px;
  margin-bottom: 8px;
  border-left: 4px solid var(--primary);
}
.adjustment-card-info {
  flex: 1;
}
.adjustment-card-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.adjustment-client-name {
  color: var(--text-main);
  font-size: 13px;
}
/* Chained to beat .badge's own font-size/padding. */
.badge.adjustment-tag-badge {
  font-size: 9px;
  padding: 2px 6px;
}
.adjustment-exercise-line {
  font-size: 11px;
  color: var(--text-muted);
}
.adjustment-exercise-name {
  color: var(--primary);
}
.adjustment-card-actions {
  display: flex;
  gap: 4px;
  flex: 0 0 auto;
}
/* What the trainer typed with the signal. */
.adjustment-remark {
  font-size: 13px;
  font-style: italic;
  margin: 4px 0 0;
  overflow-wrap: anywhere;
}
