/* TPC Hybrid Athlete Assessment */

:root {
  --ha-bg: #0a0a0b;
  --ha-elevated: #121214;
  --ha-surface: #1a1a1d;
  --ha-line: #2a2a2e;
  --ha-brand: #83C236;
  --ha-brand-ink: #0b1d00;
  --ha-text: #ffffff;
  --ha-body: #c8c9cc;
  --ha-muted: #9a9ba0;
  --ha-danger: #f07178;
  --ha-radius: 12px;
  --ha-max: 640px;
  --ha-header: 64px;
  --ha-actions: 88px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.hybrid-assessment {
  margin: 0;
  min-height: 100%;
  font-family: 'Montserrat', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--ha-bg);
  color: var(--ha-text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

body.hybrid-assessment a { color: var(--ha-brand); }
body.hybrid-assessment img { max-width: 100%; display: block; }

.ha-skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: #000;
  color: #fff;
  padding: 8px 12px;
  z-index: 9999;
}
.ha-skip:focus { left: 8px; top: 8px; }

.ha-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 11, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--ha-line);
}
.ha-header-inner {
  width: min(960px, 92%);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  min-height: var(--ha-header);
}
.ha-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ha-text);
  text-decoration: none;
  font-weight: 800;
  font-size: 14px;
}
.ha-brand img { width: 36px; height: 36px; object-fit: contain; }

.ha-progress-wrap {
  flex: 1;
  max-width: 280px;
  margin-left: auto;
}
.ha-progress-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ha-muted);
  margin-bottom: 6px;
}
.ha-progress-track {
  height: 6px;
  background: var(--ha-surface);
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid var(--ha-line);
}
.ha-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--ha-brand);
  border-radius: 999px;
  transition: width 0.25s ease;
}

.ha-main {
  width: min(var(--ha-max), 92%);
  margin: 0 auto;
  padding: 28px 0 calc(var(--ha-actions) + env(safe-area-inset-bottom, 0px) + 24px);
}

.ha-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.ha-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ha-brand);
  margin: 0 0 12px;
}

.ha-title {
  font-size: clamp(24px, 5vw, 32px);
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 12px;
  color: var(--ha-text);
}

.ha-helper,
.ha-body {
  margin: 0 0 20px;
  color: var(--ha-body);
  font-size: 15px;
}

.ha-card {
  background: var(--ha-elevated);
  border: 1px solid var(--ha-line);
  border-radius: var(--ha-radius);
  padding: 20px;
}

.ha-options {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.ha-options legend { padding: 0; margin: 0 0 12px; }

.ha-option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 48px;
  padding: 14px 16px;
  border: 2px solid var(--ha-line);
  border-radius: 10px;
  background: var(--ha-surface);
  color: var(--ha-text);
  cursor: pointer;
  font: inherit;
  text-align: left;
  width: 100%;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.ha-option:hover { border-color: #3a3a40; }
.ha-option:focus-visible {
  outline: 2px solid var(--ha-brand);
  outline-offset: 2px;
}
.ha-option.is-selected {
  border-color: var(--ha-brand);
  background: rgba(131, 194, 54, 0.12);
}
.ha-option-mark {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--ha-muted);
  flex-shrink: 0;
  margin-top: 1px;
  display: grid;
  place-items: center;
}
.ha-option.is-selected .ha-option-mark {
  border-color: var(--ha-brand);
  background: var(--ha-brand);
  color: var(--ha-brand-ink);
  font-size: 11px;
}
.ha-option--check .ha-option-mark { border-radius: 5px; }
.ha-option-label { flex: 1; font-weight: 600; font-size: 15px; }

.ha-field { margin-bottom: 16px; }
.ha-field label,
.ha-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ha-body);
  margin-bottom: 6px;
}
.ha-input,
.ha-select,
.ha-textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 2px solid var(--ha-line);
  background: var(--ha-surface);
  color: var(--ha-text);
  font: inherit;
  font-size: 16px;
}
.ha-textarea { min-height: 120px; resize: vertical; }
.ha-input:focus-visible,
.ha-select:focus-visible,
.ha-textarea:focus-visible {
  outline: 2px solid var(--ha-brand);
  outline-offset: 1px;
  border-color: var(--ha-brand);
}
.ha-input.is-invalid,
.ha-select.is-invalid,
.ha-textarea.is-invalid,
.ha-option-group.is-invalid {
  border-color: var(--ha-danger);
}
.ha-error {
  color: var(--ha-danger);
  font-size: 13px;
  margin: 6px 0 0;
}
.ha-hint {
  font-size: 13px;
  color: var(--ha-muted);
  margin: 6px 0 0;
}

.ha-grid-2 {
  display: grid;
  gap: 14px;
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 520px) {
  .ha-grid-2 { grid-template-columns: 1fr; }
}

.ha-checklist {
  display: grid;
  gap: 12px;
}
.ha-check {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14px;
  color: var(--ha-body);
}
.ha-check input {
  width: 22px;
  height: 22px;
  margin-top: 2px;
  accent-color: var(--ha-brand);
  flex-shrink: 0;
}

.ha-points {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: grid;
  gap: 10px;
}
.ha-points li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--ha-body);
  font-size: 14px;
}
.ha-points i { color: var(--ha-brand); margin-top: 3px; }

.ha-steps {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  counter-reset: ha-step;
  display: grid;
  gap: 16px;
}
.ha-steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  counter-increment: ha-step;
  color: var(--ha-body);
  font-size: 14px;
}
.ha-steps li::before {
  content: counter(ha-step);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ha-brand);
  color: var(--ha-brand-ink);
  font-weight: 800;
  font-size: 13px;
  display: grid;
  place-items: center;
}

.ha-matrix {
  display: grid;
  gap: 14px;
}
.ha-matrix-row {
  border: 1px solid var(--ha-line);
  border-radius: 10px;
  padding: 12px;
  background: var(--ha-surface);
}
.ha-matrix-station {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 8px;
}
.ha-matrix-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.ha-matrix-choices button {
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  padding: 8px 10px;
  min-height: 40px;
  border-radius: 8px;
  border: 1px solid var(--ha-line);
  background: var(--ha-elevated);
  color: var(--ha-body);
  cursor: pointer;
}
.ha-matrix-choices button.is-selected {
  border-color: var(--ha-brand);
  background: rgba(131, 194, 54, 0.15);
  color: var(--ha-text);
}
.ha-matrix-choices button:focus-visible {
  outline: 2px solid var(--ha-brand);
}

.ha-actions {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  background: rgba(10, 10, 11, 0.96);
  border-top: 1px solid var(--ha-line);
  padding: 12px 0 calc(12px + env(safe-area-inset-bottom, 0px));
}
.ha-actions-inner {
  width: min(var(--ha-max), 92%);
  margin: 0 auto;
  display: flex;
  gap: 10px;
  align-items: center;
}
.ha-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 2px solid transparent;
  font: inherit;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease, filter 0.15s ease, background 0.15s ease;
}
.ha-btn:focus-visible {
  outline: 2px solid var(--ha-brand);
  outline-offset: 2px;
}
.ha-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}
.ha-btn--brand {
  background: var(--ha-brand);
  color: var(--ha-brand-ink);
  flex: 1;
}
.ha-btn--brand:hover:not(:disabled) { filter: brightness(0.96); }
.ha-btn--ghost {
  background: transparent;
  border-color: var(--ha-line);
  color: var(--ha-text);
}
.ha-btn--ghost:hover:not(:disabled) { background: var(--ha-surface); }
.ha-btn--link {
  background: none;
  border: none;
  color: var(--ha-muted);
  font-size: 13px;
  min-height: auto;
  padding: 8px;
}

.ha-resume {
  margin-bottom: 20px;
  padding: 16px;
  border: 1px dashed var(--ha-line);
  border-radius: var(--ha-radius);
  background: rgba(255, 255, 255, 0.02);
}
.ha-resume p { margin: 0 0 12px; color: var(--ha-body); font-size: 14px; }

.ha-review-group {
  border: 1px solid var(--ha-line);
  border-radius: var(--ha-radius);
  padding: 16px;
  margin-bottom: 12px;
  background: var(--ha-elevated);
}
.ha-review-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.ha-review-head h3 {
  margin: 0;
  font-size: 15px;
}
.ha-review-dl {
  margin: 0;
  display: grid;
  gap: 8px;
}
.ha-review-dl div {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
  font-size: 13px;
}
.ha-review-dl dt { color: var(--ha-muted); font-weight: 600; }
.ha-review-dl dd { margin: 0; color: var(--ha-body); white-space: pre-wrap; word-break: break-word; }

.ha-alert {
  padding: 14px 16px;
  border-radius: 10px;
  margin-bottom: 16px;
  font-size: 14px;
}
.ha-alert--error {
  background: rgba(240, 113, 120, 0.12);
  border: 1px solid rgba(240, 113, 120, 0.4);
  color: #ffc9cc;
}
.ha-alert--info {
  background: rgba(131, 194, 54, 0.1);
  border: 1px solid rgba(131, 194, 54, 0.35);
  color: var(--ha-body);
}

.ha-footer-note {
  margin-top: 24px;
  font-size: 12px;
  color: var(--ha-muted);
}

@media (prefers-reduced-motion: reduce) {
  .ha-progress-fill,
  .ha-btn,
  .ha-option { transition: none; }
}
