﻿/* TouchTo — Progress screen redesign styles (owned by progress screen) */

/* Header: eyebrow + big serif title + lead on the left, PDF button on the right */
.progress-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  padding-top: 18px;
  margin-bottom: 28px;
}
.progress-head__text { min-width: 0; flex: 1 1 420px; }
.progress-head__text .page-title { margin: 4px 0 12px; }
.progress-head__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

/* Stat cards sit directly under the header */
.progress-dashboard .stat-grid { margin-bottom: 8px; }

/* Therapy-cycle section keeps the shared .section rhythm */
.progress-cycle .cycle-step__desc { min-height: 2.6em; }

@media (max-width: 700px) {
  .progress-head__actions { width: 100%; }
  .progress-head__actions .btn-ghost-pill { width: 100%; }
}

/* ── Förderschwerpunkte (focus-area picker) ─────────────────────────────── */
.progress-focus .focus-hint {
  margin: 0 0 14px;
  font-size: 13px;
  color: var(--color-text-muted, #6b7280);
  line-height: 1.4;
}
.progress-focus .focus-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.progress-focus .focus-pills { gap: 10px; }
.focus-pill {
  appearance: none;
  -webkit-appearance: none;
  display: flex;
  align-items: center;
  gap: 11px;
  text-align: left;
  border: 1.5px solid var(--color-border, #d6dbe3);
  background: var(--color-surface, #fff);
  color: var(--color-text);
  font: inherit;
  padding: 9px 16px 9px 9px;
  border-radius: 14px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, opacity 0.15s ease, transform 0.1s ease;
}
.focus-pill:hover { border-color: #4b698c; transform: translateY(-1px); }
.focus-pill__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  border-radius: 10px;
  background: rgba(75, 105, 140, 0.12);
  color: #4b698c;
}
.focus-pill__icon i, .focus-pill__icon svg { width: 20px; height: 20px; }
.focus-pill__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.focus-pill__title { font-size: 14px; font-weight: 700; line-height: 1.15; }
.focus-pill__desc { font-size: 12px; font-weight: 500; line-height: 1.2; color: var(--color-text-muted, #71717a); }
.focus-pill--on {
  background: #4b698c;
  border-color: #4b698c;
  color: #fff;
}
.focus-pill--on .focus-pill__icon { background: rgba(255, 255, 255, 0.22); color: #fff; }
.focus-pill--on .focus-pill__desc { color: rgba(255, 255, 255, 0.85); }
.focus-pill--disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.focus-pill--disabled:hover { border-color: var(--color-border, #d6dbe3); transform: none; }

/* ── WeeklyHeatmap (12-week activity calendar) ──────────────────────────── */
.progress-heatmap .heatmap-cal {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  overflow-x: auto;
  padding-top: 2px;
}
.heatmap-days {
  display: grid;
  grid-template-rows: repeat(7, 14px);
  gap: 3px;
  flex-shrink: 0;
  /* push down so the weekday labels line up under the month-hint row */
  padding-top: 16px;
}
.heatmap-day-label {
  font-size: 9px;
  line-height: 14px;
  color: var(--color-text-muted, #6b7280);
  text-align: right;
  padding-right: 2px;
}
.heatmap-body {
  display: flex;
  gap: 3px;
  flex-shrink: 0;
}
.heatmap-col {
  display: grid;
  grid-template-rows: 14px repeat(7, 14px);
  gap: 3px;
}
.heatmap-month-label {
  font-size: 9px;
  line-height: 14px;
  color: var(--color-text-muted, #6b7280);
  white-space: nowrap;
}
.heatmap-cell {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  background: var(--color-surface-alt, rgba(75,105,140,0.08));
}
.heatmap-cell--future { background: transparent; }
.heatmap-cell--today { box-shadow: 0 0 0 1.5px var(--color-text, #1f2937); }
.heatmap-legend {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
}
.heatmap-legend__label {
  font-size: 11px;
  color: var(--color-text-muted, #6b7280);
}
.heatmap-legend__swatches {
  display: flex;
  gap: 3px;
}

/* ── Analytics row: StarsSparkline + FocusDonut side by side ────────────── */
.progress-analytics-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 14px;
  margin-bottom: 12px;
  align-items: stretch;
}
@media (max-width: 700px) {
  .progress-analytics-row { grid-template-columns: 1fr; }
}

.progress-viz-empty {
  margin: 0;
  color: var(--color-text-muted, #6b7280);
  font-style: italic;
  font-size: 13px;
  line-height: 1.4;
}

/* ── StarsSparkline (compact star-rating trend) ─────────────────────────── */
.progress-spark-card,
.progress-donut-card {
  background: var(--color-surface, #fff);
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
}
.progress-spark-card__label {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-text-muted, #6b7280);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 10px;
}
.progress-spark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.progress-spark__svg { overflow: visible; }
.progress-spark__trend {
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  color: var(--color-text-muted, #6b7280);
}
.progress-spark-card__sub {
  margin-top: 10px;
  font-size: 11px;
  color: var(--color-text-muted, #6b7280);
}

/* ── FocusDonut (competency distribution donut + legend) ────────────────── */
.progress-donut {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
}
.progress-donut__svg {
  transform: rotate(-90deg);
  flex-shrink: 0;
  width: 140px;
  height: 140px;
}
.progress-donut__legend {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.progress-donut__row {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  font-size: 13px;
}
.progress-donut__dot {
  width: 12px;
  height: 12px;
  border-radius: 3px;
}
.progress-donut__label {
  color: var(--color-text, #1f2937);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.progress-donut__val {
  font-weight: 700;
  color: var(--color-text, #1f2937);
  font-variant-numeric: tabular-nums;
}
@media (max-width: 460px) {
  .progress-donut { grid-template-columns: 1fr; justify-items: center; }
  .progress-donut__legend { width: 100%; }
}

/* ── ProgressStory (brand-gradient narrative card) ──────────────────────── */
.progress-story {
  display: flex;
  gap: 18px;
  padding: 22px 24px;
  background: var(--gradient-brand, linear-gradient(135deg, #1a3a6a 0%, #4b698c 100%));
  color: #fff;
  border-radius: 18px;
  margin-bottom: 16px;
}
.progress-story__icon {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.progress-story__text { flex: 1; min-width: 0; }
.progress-story__eyebrow { color: rgba(255, 255, 255, 0.72); }
.progress-story__title {
  color: #fff;
  font-size: 22px;
  margin: 4px 0 12px;
  line-height: 1.2;
}
.progress-story__sentence {
  color: rgba(255, 255, 255, 0.92);
  font-size: 15px;
  line-height: 1.55;
  margin: 0 0 6px;
}
@media (max-width: 560px) {
  .progress-story { flex-direction: column; gap: 12px; padding: 18px; }
}
