[hidden] { display: none !important; }
.admin-page { background: #f5f6fa; }
.admin-header { background: #fff; border-bottom: 1px solid var(--border); padding: 20px max(24px, calc((100vw - 1240px)/2)); display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text-dark); font-weight: 750; }
.brand-mark { display: grid; place-items: center; width: 42px; height: 42px; background: var(--primary); color: white; border-radius: 12px; }
.brand small { display: block; font-size: 9px; letter-spacing: 2px; color: var(--text-light); margin-top: 2px; }
.header-actions { display: flex; align-items: center; gap: 20px; }
.header-actions a { font-size: 13px; color: var(--text-light); text-decoration: none; }
.dashboard { max-width: 1240px; margin: 42px auto; padding: 0 24px; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 28px; }
.eyebrow { color: var(--primary); font-weight: 700; letter-spacing: 1.5px; font-size: 10px; }
.admin-page h1 { font-size: clamp(25px, 3vw, 32px); letter-spacing: -1px; margin: 5px 0 8px; line-height: 1.25; }
.muted { color: var(--text-light); font-size: 13px; }
.button { border: 1px solid transparent; border-radius: 8px; padding: 10px 15px; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; line-height: 1.5; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; }
.button:disabled { opacity: .45; cursor: not-allowed; }
.button.primary { color: white; background: var(--primary); }
.button.primary:hover:not(:disabled) { background: var(--primary-dark); }
.button.secondary { background: white; color: var(--text-medium); border-color: #dfe2eb; }
.button.secondary:hover:not(:disabled) { background: var(--primary-light); }
.button:focus-visible, input:focus-visible, select:focus-visible, a:focus-visible { outline: 3px solid #aaa5ff; outline-offset: 3px; }
.summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat { display: flex; flex-direction: column; background: white; padding: 22px; border: 1px solid var(--border); border-radius: 12px; }
.stat > span { font-size: 13px; color: var(--text-medium); }
.stat strong { font-size: 34px; font-weight: 700; margin: 8px 0; letter-spacing: -1px; }
.stat small { font-size: 11px; color: var(--text-light); }
.stat.accent { background: var(--primary-light); border-color: #dcd9fc; }
.stat.accent strong { color: var(--primary); }
.summary-note { font-size: 11px; color: var(--text-light); margin: 12px 0 28px; }
.results-panel { border: 1px solid var(--border); background: white; border-radius: 12px; overflow: hidden; }
.panel-heading { padding: 22px 24px 0; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.panel-heading h2 { font-size: 17px; }
.filters { padding: 20px 24px 24px; display: flex; gap: 12px; align-items: end; flex-wrap: wrap; }
.filters .search-field { flex: 1; min-width: 210px; }
.admin-page label { display: block; font-size: 12px; font-weight: 600; margin-bottom: 7px; }
.admin-page input, .admin-page select { border: 1px solid #dfe2eb; border-radius: 8px; background: white; padding: 11px 12px; font: inherit; font-size: 13px; color: var(--text-dark); width: 100%; height: 42px; }
.table-scroll { overflow-x: auto; }
.admin-page table { width: 100%; border-collapse: collapse; text-align: left; }
.admin-page th { background: #f8f9fc; color: var(--text-light); font-size: 11px; font-weight: 600; padding: 13px 18px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); white-space: nowrap; }
.admin-page td { padding: 17px 18px; font-size: 13px; border-bottom: 1px solid #eff0f5; }
.admin-page tbody tr:hover { background: #fbfbfe; }
.participant-name { font-weight: 600; display: block; overflow-wrap: anywhere; min-width: 160px; }
.participant-email { display: block; color: var(--text-light); font-size: 11px; margin-top: 3px; overflow-wrap: anywhere; }
.nowrap { white-space: nowrap; }
.badge { display: inline-block; padding: 4px 9px; border-radius: 6px; font-size: 11px; font-weight: 600; white-space: nowrap; background: #f1f2f5; color: #555e6e; }
.badge.completed { color: #047857; background: #e5f7ef; }
.badge.processing, .badge.pending { color: #4338ca; background: #eeedff; }
.badge.failed { color: #b91c1c; background: #feecec; }
.badge.too_short { color: #a16207; background: #fff5dc; }
.empty-state { padding: 48px 20px; color: var(--text-light); text-align: center; font-size: 14px; }
.pagination { padding: 18px 24px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pagination > div { display: flex; align-items: center; gap: 12px; font-size: 12px; }
.login-card { margin: 72px auto; padding: 36px; width: calc(100% - 32px); max-width: 440px; border: 1px solid var(--border); background: white; border-radius: 16px; box-shadow: 0 12px 40px #27234108; }
.login-card h1 { font-size: 27px; margin-top: 14px; }
.login-card form { margin-top: 28px; }
.login-card input { margin-bottom: 20px; }
.login-card .button { width: 100%; margin-top: 8px; }
.login-note { font-size: 11px; color: var(--text-light); margin-top: 24px; text-align: center; }
.error-message { font-size: 13px; padding: 12px 14px; color: #b91c1c; background: #fff0f0; border-radius: 8px; overflow-wrap: anywhere; }
.panel-message { margin: 0 24px 18px; }
.boot-message { text-align: center; margin: 80px 20px; color: var(--text-light); }
.admin-page dialog { margin: auto; width: calc(100% - 32px); max-width: 820px; max-height: 90vh; border: 1px solid var(--border); border-radius: 16px; padding: 0; box-shadow: var(--shadow-lg); }
.admin-page dialog::backdrop { background: #13152a80; backdrop-filter: blur(3px); }
.detail-header { display: flex; justify-content: space-between; align-items: center; padding: 24px; border-bottom: 1px solid var(--border); gap: 16px; }
.detail-header h2 { font-size: 22px; margin-top: 4px; overflow-wrap: anywhere; }
.detail-content { padding: 24px; }
.detail-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 20px 0; }
.detail-meta dt { font-size: 11px; color: var(--text-light); margin-bottom: 3px; }
.detail-meta dd { font-size: 13px; overflow-wrap: anywhere; }
.detail-section { padding-top: 22px; margin-top: 22px; border-top: 1px solid var(--border); }
.detail-section h3 { font-size: 14px; margin-bottom: 10px; }
.detail-section h4 { font-size: 12px; margin: 14px 0 5px; color: var(--text-light); }
.detail-section p, .detail-section li { font-size: 13px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.detail-section ul { padding-left: 20px; }
.detail-scores { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 20px 0; }
.detail-score { background: var(--primary-light); border-radius: 8px; padding: 14px 10px; text-align: center; }
.detail-score small { display: block; font-size: 10px; color: var(--text-light); }
.detail-score strong { font-size: 25px; color: var(--primary); }
.detail-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 800px) {
  .summary { grid-template-columns: repeat(2, 1fr); }
  .filters > div:not(.search-field) { flex: 1; }
  .filters .search-field { flex-basis: 100%; }
  .pagination { flex-direction: column; }
  .page-heading { align-items: start; }
  .detail-scores { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 500px) {
  .admin-header { padding: 16px; gap: 10px; }
  .header-actions { gap: 10px; }
  .header-actions a { font-size: 11px; max-width: 65px; }
  .brand { font-size: 13px; gap: 8px; }
  .brand-mark { width: 34px; height: 34px; }
  .dashboard { margin-top: 28px; padding: 0 16px; }
  .page-heading { flex-direction: column; }
  .summary { gap: 10px; }
  .stat { padding: 16px; }
  .stat strong { font-size: 29px; }
  .filters, .detail-content, .detail-header { padding: 18px; }
  .panel-heading { padding: 18px 18px 0; flex-wrap: wrap; }
  .pagination { padding: 16px 10px; }
  .pagination > div { gap: 8px; }
  .pagination .button { padding: 8px; font-size: 11px; }
  .detail-meta { grid-template-columns: 1fr; }
}

/* Reporting workspace */
.admin-header { position: sticky; top: 0; z-index: 5; background: #ffffffed; backdrop-filter: blur(12px); }
.dashboard { max-width: 1380px; }
.page-heading { padding: 8px 0 6px; }
.heading-actions { display: flex; gap: 10px; }
.account-pill { padding: 5px 10px; border: 1px solid #e4e1f8; border-radius: 30px; font-size: 12px; color: #544b8a; background: #f6f4ff; }
.dashboard-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin: 0 0 16px; }
.scope-label { font-size: 12px; font-weight: 600; color: var(--text-light); overflow-wrap: anywhere; }
.admin-page .auto-refresh { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 11px; color: var(--text-light); white-space: nowrap; }
.admin-page .auto-refresh input { width: 15px; height: 15px; accent-color: var(--primary); }
.stat { position: relative; box-shadow: 0 3px 10px #22224403; }
.stat-symbol { float: right; font-size: 17px; color: var(--primary); }
.stat.accent { background: #4f46e5; border-color: #4f46e5; }
.stat.accent > span, .stat.accent strong { color: white; }
.stat.accent small { color: #dedbff; }
.attention-banner { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 20px; border-radius: 10px; border: 1px solid #f2dfb9; background: #fffaf0; margin-top: 20px; }
.attention-banner > div { display: flex; align-items: center; gap: 14px; }
.attention-icon { display: grid; place-items: center; width: 30px; height: 30px; flex-shrink: 0; border-radius: 50%; background: #ffebbc; color: #8b5d10; font-weight: 700; }
.attention-banner strong { font-size: 13px; color: #76501b; }
.attention-banner p { font-size: 11px; color: #987445; margin-top: 3px; }
.analytics-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 16px; margin-top: 22px; }
.analytics-card { border: 1px solid var(--border); border-radius: 12px; padding: 22px; background: #fff; min-width: 0; }
.analytics-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.analytics-heading h2 { font-size: 16px; font-weight: 650; margin-top: 6px; }
.analytics-heading .eyebrow { font-size: 9px; letter-spacing: 1.1px; color: var(--text-light); }
.chart-total { font-size: 25px; color: var(--primary); font-weight: 700; }
.activity-chart { display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; margin-top: 20px; height: 142px; }
.activity-day { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; }
.activity-track { width: 100%; height: 100px; display: flex; align-items: flex-end; border-bottom: 1px solid var(--border); }
.activity-bar { background: #ddd9fc; width: 100%; max-width: 34px; border-radius: 5px 5px 0 0; margin: 0 auto; min-height: 0; }
.activity-day:last-child .activity-bar { background: var(--primary); }
.activity-day:hover .activity-bar { background: #8b82ee; }
.activity-day strong { font-size: 11px; font-weight: 600; color: #65607c; }
.activity-day small { font-size: 9px; color: var(--text-light); white-space: nowrap; }
.chart-note { font-size: 10px; color: var(--text-light); margin-top: 15px; }
.skills-chart { display: grid; gap: 16px; margin-top: 20px; }
.skill-heading { display: flex; justify-content: space-between; align-items: center; font-size: 11px; gap: 12px; margin-bottom: 7px; }
.skill-heading strong { color: var(--primary); }
.skill-track { height: 6px; background: #f0eff7; border-radius: 4px; overflow: hidden; }
.skill-fill { height: 100%; border-radius: 4px; background: #8980e9; }
.levels-chart { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 18px; }
.level-cell { padding: 10px 6px; text-align: center; background: #f7f7fb; border-radius: 8px; }
.level-cell strong { display: block; font-size: 16px; margin-top: 3px; }
.level-cell span { font-size: 10px; color: var(--text-light); }
.level-cell.populated { background: #eeedff; }
.level-cell.populated strong { color: var(--primary); }
.quick-filters { display: flex; gap: 5px; margin: 20px 24px 0; border-bottom: 1px solid var(--border); overflow-x: auto; }
.quick-filters button { font: inherit; font-size: 12px; background: none; border: 0; border-bottom: 2px solid transparent; padding: 10px 14px; cursor: pointer; color: var(--text-light); white-space: nowrap; }
.quick-filters button[aria-pressed="true"] { border-color: var(--primary); color: var(--primary); font-weight: 700; }
.quick-filters button:focus-visible { outline: 2px solid var(--primary); outline-offset: -3px; }
.filters { display: grid; grid-template-columns: minmax(220px, 2fr) 1fr 1fr; }
.filters .search-field { min-width: 0; }
.filters > button { justify-self: start; }
.filters > button:last-child { margin-left: -2px; }
.participant-cell { display: flex; align-items: center; gap: 11px; }
.participant-avatar { width: 33px; height: 33px; display: grid; place-items: center; border-radius: 10px; background: #f0eefb; color: #6b60ac; font-size: 11px; font-weight: 700; flex-shrink: 0; }
.score-pill { display: inline-flex; gap: 3px; font-weight: 700; padding: 4px 8px; border-radius: 6px; background: #f2f3f7; }
.score-pill.high { color: #047857; background: #e6f6ee; }
.score-pill.medium { color: #8c640c; background: #fff5da; }
.score-pill.low { color: #a84732; background: #fff0eb; }
.password-field { position: relative; }
.password-field input { padding-right: 86px; }
.password-field button { position: absolute; right: 11px; top: 12px; background: none; border: 0; color: var(--primary); font: inherit; font-size: 11px; cursor: pointer; }
@media (min-width: 1150px) {
  .filters { grid-template-columns: minmax(210px, 1.7fr) 1fr .8fr 1fr 1fr 1fr; }
}
@media (max-width: 1000px) {
  .analytics-grid { grid-template-columns: 1fr 1fr; }
  .activity-card { grid-column: 1 / -1; }
  .activity-chart { gap: 20px; }
  .activity-bar { max-width: 60px; }
}
@media (max-width: 650px) {
  .dashboard-toolbar { align-items: start; flex-direction: column; gap: 10px; }
  .filters { grid-template-columns: 1fr 1fr; }
  .filters .search-field { grid-column: 1 / -1; }
  .attention-banner { align-items: start; flex-direction: column; gap: 12px; }
  .analytics-card { padding: 18px; }
  .account-pill { display: none; }
  .analytics-grid { grid-template-columns: 1fr; }
  .quick-filters { margin-left: 12px; margin-right: 12px; }
  .quick-filters button { padding: 10px; }
  .page-heading { align-items: stretch; }
  .heading-actions { width: 100%; }
  .heading-actions > button { flex: 1; }
}
