/* ExamBuilder public styles */
#eb-exam-wrap { max-width: 760px; margin: 0 auto; font-family: inherit; }

/* Start screen */
.eb-start-screen { text-align: center; padding: 40px 24px; background: #fff; border: 1px solid #e5e5e5; border-radius: 10px; }
.eb-start-screen h2 { margin: 0 0 12px; font-size: 22px; }
.eb-start-screen p { color: #666; margin: 8px 0; }
.eb-meta-grid { display: flex; justify-content: center; flex-wrap: wrap; gap: 20px; margin: 20px 0; }
.eb-meta-item { text-align: center; }
.eb-meta-value { font-size: 22px; font-weight: bold; color: #0073aa; display: block; }
.eb-meta-label { font-size: 12px; color: #888; text-transform: uppercase; letter-spacing: .5px; }

/* Buttons */
.eb-btn { display: inline-block; padding: 12px 28px; border-radius: 6px; font-size: 15px; font-weight: 600; cursor: pointer; border: none; text-decoration: none; transition: background .15s, transform .1s; }
.eb-btn:active { transform: scale(.97); }
.eb-btn-primary { background: #0073aa; color: #fff; }
.eb-btn-primary:hover { background: #005f8a; color: #fff; }
.eb-btn-secondary { background: #f0f0f0; color: #333; margin-left: 10px; }
.eb-btn-secondary:hover { background: #e0e0e0; }
.eb-cert-notice { background: #f0faf5; border: 1px solid #22a06b; color: #155724; border-radius: 6px; padding: 12px 20px; margin-top: 20px; font-size: 14px; }
.eb-result-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 28px; }
.eb-btn-close { background: #f0f0f0; color: #333; }
.eb-btn-close:hover { background: #e0e0e0; color: #333; }

/* Timer */
.eb-timer { position: sticky; top: 0; z-index: 100; background: #0073aa; color: #fff; text-align: center; padding: 8px; font-size: 15px; font-weight: bold; border-radius: 6px; margin-bottom: 16px; }
.eb-timer.eb-timer-warning { background: #e53e3e; }

/* Questions */
.eb-question { background: #fff; border: 1px solid #e5e5e5; border-radius: 8px; padding: 24px; margin-bottom: 16px; }
.eb-q-number { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; color: #888; margin-bottom: 10px; }
.eb-q-text { font-size: 16px; font-weight: 600; color: #1a1a1a; margin-bottom: 16px; line-height: 1.5; }
.eb-options { display: flex; flex-direction: column; gap: 8px; }
.eb-option { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border: 2px solid #e5e5e5; border-radius: 6px; cursor: pointer; transition: border-color .15s, background .15s; }
.eb-option:hover { border-color: #0073aa; background: #f0f7ff; }
.eb-option.eb-selected { border-color: #0073aa; background: #e8f4fd; }
.eb-option input[type=radio] { display: none; }
.eb-opt-label { min-width: 28px; height: 28px; border-radius: 50%; background: #f0f0f0; display: flex; align-items: center; justify-content: center; font-weight: bold; font-size: 13px; color: #555; flex-shrink: 0; }
.eb-option.eb-selected .eb-opt-label { background: #0073aa; color: #fff; }

/* Single question card */
.eb-question-single { min-height: 260px; }

/* Footer with navigation */
.eb-exam-footer { position: sticky; bottom: 0; background: #fff; border-top: 1px solid #e5e5e5; padding: 14px 0; display: flex; align-items: center; gap: 16px; margin-top: 24px; flex-wrap: wrap; }
.eb-progress-wrap { flex: 1; min-width: 120px; background: #e5e5e5; border-radius: 4px; height: 8px; position: relative; }
.eb-progress-bar { position: absolute; left: 0; top: 0; height: 100%; background: #22a06b; border-radius: 4px; transition: width .3s; }
#eb-progress-txt { font-size: 13px; color: #666; white-space: nowrap; flex-shrink: 0; }
.eb-nav-btns { display: flex; gap: 10px; flex-shrink: 0; }
.eb-btn-submit { background: #22a06b !important; color: #fff !important; }
.eb-btn-submit:hover { background: #1a8057 !important; }

/* Review */
.eb-section-title { font-size: 20px; margin-bottom: 20px; }
.eb-review-question { background: #fff; border: 1px solid #e5e5e5; border-radius: 8px; padding: 20px; margin-bottom: 12px; border-left: 4px solid #e5e5e5; }
.eb-review-question.eb-correct { border-left-color: #22a06b; }
.eb-review-question.eb-wrong   { border-left-color: #e53e3e; }
.eb-review-question .eb-q-number { font-weight: 700; }
.eb-review-question.eb-correct .eb-q-number { color: #22a06b; }
.eb-review-question.eb-wrong   .eb-q-number { color: #e53e3e; }
.eb-review-options { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; }
.eb-review-opt { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 5px; font-size: 14px; }
.eb-review-opt.eb-opt-correct { background: #d4edda; color: #155724; font-weight: 600; }
.eb-review-opt.eb-opt-wrong   { background: #f8d7da; color: #721c24; text-decoration: line-through; }
.eb-review-opt .eb-opt-label  { min-width: 24px; height: 24px; border-radius: 50%; background: rgba(0,0,0,.07); display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: bold; flex-shrink: 0; }

/* Results */
.eb-result-card { text-align: center; background: #fff; border: 1px solid #e5e5e5; border-radius: 12px; padding: 40px 24px; }
.eb-result-card.eb-passed { border-top: 5px solid #22a06b; }
.eb-result-card.eb-failed { border-top: 5px solid #e53e3e; }
.eb-result-icon { font-size: 52px; margin-bottom: 8px; }
.eb-result-title { font-size: 26px; margin: 0 0 12px; }
.eb-passed .eb-result-title { color: #22a06b; }
.eb-failed .eb-result-title { color: #e53e3e; }
.eb-result-score { font-size: 56px; font-weight: 800; color: #1a1a1a; line-height: 1; margin-bottom: 8px; }
.eb-result-detail { color: #666; font-size: 15px; margin-bottom: 6px; }
.eb-result-attempt { font-size: 13px; color: #aaa; margin-bottom: 20px; }
.eb-no-attempts { color: #e53e3e; font-size: 14px; margin-top: 16px; }

/* Category scores */
.eb-cat-scores { text-align: left; max-width: 480px; margin: 24px auto 0; }
.eb-cat-scores h3 { font-size: 15px; color: #555; margin-bottom: 12px; }
.eb-cat-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.eb-cat-name { width: 160px; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex-shrink: 0; }
.eb-cat-bar-wrap { flex: 1; background: #e5e5e5; border-radius: 4px; height: 10px; position: relative; }
.eb-cat-bar { position: absolute; left: 0; top: 0; height: 100%; background: #0073aa; border-radius: 4px; transition: width .6s ease; }
.eb-cat-pct { font-size: 12px; color: #666; white-space: nowrap; width: 80px; text-align: right; flex-shrink: 0; }

/* Login prompt */
.eb-login-prompt { text-align: center; padding: 32px; background: #fff3cd; border: 1px solid #ffc107; border-radius: 8px; }
.eb-login-prompt a { color: #0073aa; font-weight: 600; }

/* Misc */
.eb-loading { text-align: center; padding: 48px; color: #666; }
.eb-spinner { display: inline-block; width: 24px; height: 24px; border: 3px solid #ddd; border-top-color: #0073aa; border-radius: 50%; animation: eb-spin .7s linear infinite; margin-right: 8px; vertical-align: middle; }
@keyframes eb-spin { to { transform: rotate(360deg); } }
.eb-error-msg { background: #f8d7da; border: 1px solid #f5c6cb; color: #721c24; padding: 16px 20px; border-radius: 6px; }
.eb-error { color: #c0392b; }

@media (max-width: 600px) {
    .eb-question { padding: 16px; }
    .eb-result-score { font-size: 40px; }
    .eb-exam-footer { flex-wrap: wrap; }
    .eb-btn { padding: 10px 20px; font-size: 14px; }
}

/* Fase 1 */
.eb-notice { margin: 10px 0; padding: 10px 14px; background: #eef6ff; border-left: 4px solid #2271b1; border-radius: 4px; font-size: 14px; }
.eb-notice[hidden] { display: none; }
.eb-explanation { margin-top: 10px; padding: 10px 14px; background: #f6f7f7; border-left: 4px solid #7a8a99; border-radius: 4px; font-size: 14px; }
.eb-your { color: #555; font-size: 12px; margin-left: 6px; }

/* ── Publieke certificaatcontrole ────────────────────────────── */
.eb-verify { max-width: 560px; margin: 0 auto; }
.eb-verify-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.eb-verify-form label { flex: 1 0 100%; font-weight: 600; }
.eb-verify-form input[type=text] { flex: 1 1 240px; padding: 10px 12px; font-size: 16px; border: 1px solid #c5ccd3; border-radius: 6px; font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .5px; }
.eb-verify-btn { padding: 10px 18px; background: #22a06b; color: #fff; border: 0; border-radius: 6px; font-size: 15px; cursor: pointer; }
.eb-verify-hint { color: #666; font-size: 13px; }
.eb-verify-result { margin-top: 18px; padding: 14px 18px; border-radius: 8px; border: 1px solid; }
.eb-verify-valid { background: #f0faf5; border-color: #22a06b; color: #14532d; }
.eb-verify-valid strong { font-size: 18px; }
.eb-verify-valid dl { margin: 10px 0 0; display: grid; grid-template-columns: 90px 1fr; gap: 4px 12px; }
.eb-verify-valid dt { color: #555; }
.eb-verify-valid dd { margin: 0; font-weight: 600; }
.eb-verify-invalid { background: #fdf2f2; border-color: #e53e3e; color: #7b1d1d; }
.eb-verify-invalid strong { font-size: 18px; }
.eb-verify-limit { background: #fff8e6; border-color: #d69e2e; color: #744210; }

.eb-review-once { margin: 10px 0 0; color: #555; font-size: 13px; }
