/* Space Print Assessment styles */
:root {
  --bg: #fafafa;
  --card: #ffffff;
  --text: #111827;
  --muted: #6b7280;
  --primary: #1a1f36;
  --primary-hover: #0f1424;
  --accent: #f59e0b;
  --border: #e5e7eb;
  --err: #dc2626;
  --warn: #d97706;
  --ok: #16a34a;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--text); font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; line-height: 1.5; }
.wrap { max-width: 800px; margin: 0 auto; padding: 24px 20px 80px; }
header { padding: 0; border-bottom: 1px solid var(--border); margin: -24px -20px 24px; background: var(--primary); padding: 24px 20px 20px; color: white; }
.brand { font-size: 22px; font-weight: 700; color: white; letter-spacing: -0.01em; }
.brand.small { font-size: 14px; color: white; font-weight: 700; }
.sub { color: rgba(255, 255, 255, 0.85); font-size: 14px; margin-top: 6px; }
.test-header { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; margin: -24px -20px 16px; background: var(--primary); color: white; }
.test-header .brand.small { color: white; }
.test-name { font-size: 18px; font-weight: 600; margin-top: 2px; color: white; }
.timer-wrap { text-align: right; }
.timer-wrap .muted { color: rgba(255, 255, 255, 0.75); }
.timer { font-variant-numeric: tabular-nums; font-size: 22px; font-weight: 600; color: white; margin-left: 6px; }
.timer.warn { color: #fda4af; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 24px; margin-bottom: 16px; box-shadow: 0 1px 2px rgba(0,0,0,0.03); }
h1 { margin: 0 0 16px; font-size: 26px; }
h2 { margin: 0 0 8px; font-size: 20px; }
h3 { margin: 18px 0 8px; font-size: 16px; }
.body { color: var(--text); margin: 0 0 16px; }
ol.tests { padding-left: 22px; margin: 12px 0; }
ol.tests li { margin-bottom: 6px; }
form label { display: block; margin: 14px 0 4px; font-size: 14px; color: var(--muted); }
form input { display: block; width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 6px; font-size: 16px; background: white; }
button { padding: 10px 18px; font-size: 15px; border-radius: 6px; border: 1px solid var(--border); background: white; cursor: pointer; }
button:hover:not([disabled]) { border-color: var(--primary); }
button[disabled] { opacity: 0.5; cursor: not-allowed; }
button.primary { background: var(--primary); color: white; border-color: var(--primary); }
button.primary:hover:not([disabled]) { background: var(--primary-hover); }
.err { color: var(--err); margin-top: 12px; }
.progress { margin: 0 0 12px; }
.question h2 { margin-bottom: 8px; }
.options { display: flex; flex-direction: column; gap: 10px; }
.opt { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1px solid var(--border); border-radius: 8px; cursor: pointer; background: white; transition: all 0.15s ease; }
.opt:hover { border-color: var(--accent); background: #fffbeb; }
.opt.sel { border-color: var(--primary); background: #f3f4f6; }
.opt input { margin-top: 2px; flex-shrink: 0; }
.nav { display: flex; justify-content: space-between; margin-top: 16px; }
footer { text-align: center; color: var(--muted); padding-top: 32px; font-size: 13px; }
.table { width: 100%; border-collapse: collapse; margin-top: 16px; }
.table th, .table td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--border); font-size: 14px; }
.table th { color: var(--muted); font-weight: 600; }
.detail-list { list-style: none; padding: 0; margin: 8px 0 16px; }
.detail-list li { padding: 4px 0; font-size: 14px; }
.detail-list li.ok { color: var(--ok); }
.detail-list li.no { color: var(--err); }
.scores { margin-top: 12px; }
textarea { display: block; width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: 8px; font-family: inherit; font-size: 15px; line-height: 1.55; background: white; resize: vertical; min-height: 240px; box-sizing: border-box; }
textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,31,54,0.08); }
.audio-recorder { padding: 12px 0; }
.audio-recorder button { padding: 10px 18px; font-size: 15px; border-radius: 6px; }
#recBtn[data-state="recording"] { background: var(--err); color: white; border-color: var(--err); }
#recBtn[data-state="recording"]:hover { background: #b91c1c; }
audio { outline: none; }
#charCount { margin-top: 6px; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) {
  h1 { font-size: 22px; }
  .opt { padding: 12px; }
  .test-header { flex-direction: column; align-items: flex-start; gap: 6px; }
  .timer-wrap { text-align: left; }
}
