/* ============================================================
   SatisForm — app-specific components (home, form, dashboard)
   ============================================================ */

/* ── Home choice cards ───────────────────────────────────── */
.choice-grid { display: flex; flex-direction: column; gap: 12px; }
.choice-card {
  display: flex; align-items: center; gap: 14px;
  padding: 18px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--r-lg);
  transition: all var(--t-fast);
  text-align: left;
}
.choice-card:hover { background: var(--bg-card-hover); border-color: var(--border-strong); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.choice-card-icon {
  width: 44px; height: 44px; flex-shrink: 0;
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  color: white;
}
.choice-card-icon svg { width: 22px; height: 22px; }
.choice-card--student .choice-card-icon { background: var(--brand); box-shadow: var(--shadow-brand); }
.choice-card--admin .choice-card-icon   { background: var(--purple); box-shadow: 0 4px 20px var(--purple-glow); }
.choice-card-text  { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.choice-card-title { font-size: 15px; font-weight: 700; color: var(--text-primary); }
.choice-card-sub   { font-size: 12px; color: var(--text-muted); }
.choice-card-arrow { margin-left: auto; color: var(--text-muted); flex-shrink: 0; }
.choice-card-arrow svg { width: 18px; height: 18px; }

/* ── App topbar (form + dashboard) ──────────────────────── */
.app-topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  padding: 18px 4px 22px;
  border-bottom: 1px solid var(--border-default);
  margin-bottom: 26px;
}
.app-shell { max-width: 1180px; margin: 0 auto; padding: 24px 24px 60px; }
.app-shell--narrow { max-width: 900px; }

/* ── Form sections ───────────────────────────────────────── */
.form-section {
  padding-bottom: 26px; margin-bottom: 26px;
  border-bottom: 1px solid var(--border-default);
}
.form-section:last-of-type { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }

/* ── Trainer picker ──────────────────────────────────────── */
.trainers-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.trainer-checkbox {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px;
  background: var(--bg-elevated);
  border: 1.5px solid var(--border-default);
  border-radius: var(--r-md);
  cursor: pointer; transition: all var(--t-fast); user-select: none;
}
.trainer-checkbox:hover { border-color: var(--border-strong); background: var(--bg-card-hover); }
.trainer-checkbox input[type="checkbox"] {
  width: 18px; height: 18px; cursor: pointer; accent-color: var(--brand); flex-shrink: 0;
}
.trainer-checkbox input[type="checkbox"]:checked ~ .trainer-info .trainer-name { color: var(--brand); }
.trainer-checkbox:has(input:checked) { border-color: var(--brand); background: var(--brand-glow); }
.trainer-info { flex: 1; min-width: 0; }
.trainer-name { font-size: 14px; font-weight: 600; color: var(--text-primary); transition: color var(--t-fast); }
.trainer-subject { font-size: 12px; color: var(--text-muted); margin-top: 1px; }
.no-trainers {
  grid-column: 1 / -1; text-align: center; padding: 32px; color: var(--text-muted);
  background: var(--bg-elevated); border-radius: var(--r-md); font-size: 13px;
}

/* ── Evaluation panel ────────────────────────────────────── */
.evaluation-form {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-left: 3px solid var(--brand);
  border-radius: var(--r-lg);
  padding: 20px; margin-bottom: 16px;
}
.trainer-header {
  display: flex; align-items: center; gap: 8px;
  font-size: 15px; font-weight: 700; color: var(--text-primary); margin-bottom: 16px;
}
.trainer-header svg { width: 16px; height: 16px; color: var(--brand); }
.criteria-group { margin-bottom: 16px; }
.criteria-group:last-child { margin-bottom: 0; }
.criteria-label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; }
.rating-buttons { display: flex; gap: 7px; }
.rating-btn {
  width: 38px; height: 38px;
  border: 1.5px solid var(--border-default);
  border-radius: var(--r-md);
  background: var(--bg-elevated);
  color: var(--text-muted);
  font-weight: 700; font-size: 14px;
  transition: all var(--t-fast);
}
.rating-btn:hover { border-color: var(--brand); color: var(--brand); }
.rating-btn.selected { background: var(--brand); border-color: var(--brand); color: white; box-shadow: var(--shadow-brand); }

/* ── Dashboard grid ──────────────────────────────────────── */
.dash-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 20px; margin-bottom: 24px; }
@media (max-width: 1000px) { .dash-grid { grid-template-columns: 1fr; } }

.mini-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 20px; }
.mini-stat {
  background: var(--bg-elevated); border: 1px solid var(--border-default);
  border-radius: var(--r-md); padding: 13px 14px;
  border-left: 3px solid var(--brand);
}
.mini-stat-label { font-size: 11px; color: var(--text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.4px; }
.mini-stat-value { font-size: 24px; font-weight: 800; color: var(--brand); margin-top: 2px; }

.trainers-list { margin-top: 18px; max-height: 420px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; }
.trainer-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 11px 13px;
  background: var(--bg-elevated); border: 1px solid var(--border-default);
  border-left: 3px solid var(--brand);
  border-radius: var(--r-md);
}
.trainer-item .trainer-name { font-size: 13px; }
.trainer-item .trainer-subject { font-size: 11px; }

.trainer-stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.trainer-stats-card {
  background: var(--bg-elevated); border: 1px solid var(--border-default);
  border-left: 3px solid var(--gold);
  border-radius: var(--r-md); padding: 16px;
}
.trainer-stats-name { font-size: 14px; font-weight: 700; color: var(--text-primary); margin-bottom: 12px; }
.trainer-stats-row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; font-size: 12px; }
.trainer-stats-row:last-child { margin-bottom: 0; }
.trainer-stats-crit { color: var(--text-muted); }
.trainer-stats-val { font-weight: 800; color: var(--gold); font-size: 15px; }

/* ── Modal (delete confirm) ──────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(5px);
  z-index: 1000;
  display: none; align-items: center; justify-content: center;
  animation: fadeIn var(--t-med);
}
.modal-overlay.show { display: flex; }
.modal-content {
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--r-xl); padding: 26px;
  max-width: 400px; width: calc(100% - 48px);
  box-shadow: var(--shadow-lg);
  animation: pageEnter 0.28s ease;
}
.modal-title { display: flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 800; color: var(--text-primary); margin-bottom: 10px; }
.modal-title svg { width: 18px; height: 18px; color: var(--gold); }
.modal-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.55; margin-bottom: 22px; }
.modal-actions { display: flex; gap: 10px; }
.modal-actions .btn { flex: 1; }

@media (max-width: 720px) {
  .app-shell { padding: 16px 14px 50px; }
}
