/* context.css — «Tu contexto» (#/context), su editor y la bienvenida (#/welcome). Ronda 6, docs/MEJORAS6.md. */

/* ---------- Lista ---------- */
.ctx-intro { margin: 0 0 4px; color: var(--text-2); font-size: calc(15px * var(--ts)); line-height: 1.4; }
.ctx-now { gap: 10px; }
.ctx-none { margin: 0; color: var(--muted); font-size: calc(15px * var(--ts)); line-height: 1.4; }
.ctx-add { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ctx-add .btn { min-height: 44px; padding: 0 8px; gap: 4px; font-size: calc(15px * var(--ts)); white-space: nowrap; }
.ctx-row { align-items: center; gap: 10px; min-height: 56px; }
.ctx-when-line { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.ctx-when { font-size: calc(13px * var(--ts)); font-weight: 650; line-height: 1.3; color: var(--text-2); }
.ctx-row .list-item-title { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.3; }
.ctx-notes {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ctx-badge { flex: none; }
.ctx-empty .empty-text { line-height: 1.45; }

/* ---------- Editor ---------- */
.ctx-form { display: flex; flex-direction: column; gap: 12px; }
.ctx-block { gap: 10px; }
.ctx-block > .card-title { font-size: calc(18px * var(--ts)); }
.ctx-types .chip, .ctx-sports .chip, .ctx-goals .chip { white-space: normal; text-align: left; line-height: 1.2; padding-top: 8px; padding-bottom: 8px; }
.ctx-approx .seg-btn { min-height: 44px; font-size: calc(15px * var(--ts)); }
.ctx-approx-fields { margin-top: 2px; }
.ctx-select { appearance: none; -webkit-appearance: none; }
.ctx-switch { padding: 4px 0; border-top: 1px solid var(--border); }
.ctx-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }

/* ---------- Hoy y Análisis ---------- */
.today-context { max-width: 100%; text-align: left; line-height: 1.3; }
.today-context-text { min-width: 0; }
.today-context-kicker { color: var(--text-2); font-weight: 650; }
.an-profile-more { text-align: left; line-height: 1.3; }

/* ---------- Bienvenida ---------- */
.wel-body { display: flex; flex-direction: column; gap: 12px; }
.wel-progress { display: flex; gap: 6px; }
.wel-dot { flex: 1; height: 4px; border-radius: 999px; background: var(--surface-3); }
.wel-dot.on { background: var(--accent); }
.wel-title { margin: 4px 0 0; font-size: calc(22px * var(--ts)); font-weight: 750; }
.wel-block { gap: 10px; }
.wel-block > .card-title { font-size: calc(18px * var(--ts)); }
.wel-phase .chip, .wel-secondary .chip { white-space: normal; text-align: left; line-height: 1.2; padding-top: 8px; padding-bottom: 8px; }
.wel-nav { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.wel-nav-row { display: flex; justify-content: space-between; }
.wel-nav-row .btn { min-height: 44px; }
/* «Tu semana» (ronda 8, B2): días de entreno y, por día, una rutina o una sesión libre. */
.wel-block[hidden] { display: none; }
.wel-day-row { display: flex; align-items: center; gap: 12px; }
.wel-day-name { flex: 0 0 calc(96px * var(--ts)); font-weight: 600; }
.wel-day-select { flex: 1; min-width: 0; }
html.text-large .wel-day-row { flex-direction: column; align-items: stretch; gap: 4px; }
html.text-large .wel-day-name, html.text-large .wel-day-select { flex: none; }

/* ---------- Resultado de carrera (hecho 'race_result') ---------- */
.ctx-result-custom { margin-top: 8px; max-width: 220px; }
.ctx-result-custom[hidden] { display: none; }
.ctx-result-pace { font-variant-numeric: tabular-nums; }
.ctx-result-pace[hidden] { display: none; }
.ctx-more-btn .icon { transition: transform 0.18s ease; }
.ctx-more-btn[aria-expanded="true"] .icon { transform: rotate(180deg); }
.ctx-more-body { display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }
.ctx-more-body[hidden] { display: none; }
.ctx-result-sub { font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) { .ctx-more-btn .icon { transition: none; } }
