/* ============================================================
   PA NOTARY EXAM PREP — PASS IT Study System
   ============================================================ */

.pane-app, .pane-gate {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    max-width: 780px;
    margin: 0 auto;
    padding: 0 0 60px;
    color: #1A1A1A;
}

/* ── Screens ─────────────────────────────────────────────── */
.pane-screen { display: none; }
.pane-screen--active { display: block; }

/* ── Header ──────────────────────────────────────────────── */
.pane-header { margin-bottom: 28px; }
.pane-header__title { font-size: 26px; font-weight: 800; margin: 0 0 4px; color: #1A1A1A; }
.pane-header__sub { font-size: 13px; color: #CC0000; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; margin: 0; }

/* ── Diagnostic ──────────────────────────────────────────── */
.pane-diagnostic {
    background: #1A1A1A;
    border-radius: 14px;
    padding: 24px;
    margin-bottom: 28px;
    color: #fff;
}
.pane-diagnostic__loading { color: rgba(255,255,255,0.5); font-size: 14px; }
.pane-diagnostic__header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 20px; flex-wrap: wrap; gap: 12px;
}
.pane-diagnostic__overall { display: flex; align-items: baseline; gap: 8px; }
.pane-diagnostic__pct { font-size: 36px; font-weight: 800; background: linear-gradient(90deg,#FFD700,#FF6B00); -webkit-background-clip:text; -webkit-text-fill-color:transparent; background-clip:text; }
.pane-diagnostic__label { font-size: 13px; color: rgba(255,255,255,0.6); }
.pane-readiness { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 20px; font-size: 12px; font-weight: 700; border: 1px solid rgba(255,255,255,0.2); }
.pane-diagnostic__recommend {
    background: rgba(204,0,0,0.2); border: 1px solid rgba(204,0,0,0.4);
    border-radius: 10px; padding: 12px 16px; margin-bottom: 16px;
    display: flex; align-items: center; gap: 12px;
}
.pane-diagnostic__recommend-label { font-size: 11px; color: rgba(255,255,255,0.5); text-transform: uppercase; letter-spacing: 0.06em; }
.pane-diagnostic__recommend-topic { font-size: 14px; font-weight: 600; color: #FFD700; }
.pane-diagnostic__drill-btn {
    margin-left: auto; padding: 6px 14px; background: #CC0000; color: #fff;
    border: none; border-radius: 6px; font-size: 12px; font-weight: 600; cursor: pointer;
    white-space: nowrap;
}
.pane-diagnostic__drill-btn:hover { background: #aa0000; }

/* Topic grid in diagnostic */
.pane-topic-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
@media (max-width: 520px) { .pane-topic-grid { grid-template-columns: 1fr; } }

.pane-topic-row {
    display: flex; align-items: center; justify-content: space-between;
    padding: 8px 12px; border-radius: 8px; background: rgba(255,255,255,0.05);
    gap: 10px;
}
.pane-topic-row__name { font-size: 12px; color: rgba(255,255,255,0.8); flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pane-topic-row__bar-wrap { width: 60px; height: 4px; background: rgba(255,255,255,0.1); border-radius: 2px; flex-shrink: 0; }
.pane-topic-row__bar { height: 100%; border-radius: 2px; transition: width 0.4s; }
.pane-topic-row__pct { font-size: 11px; font-weight: 600; width: 32px; text-align: right; flex-shrink: 0; }

/* Status colors */
.pane-status-strong .pane-topic-row__bar { background: #16a34a; }
.pane-status-strong .pane-topic-row__pct { color: #4ade80; }
.pane-status-good .pane-topic-row__bar { background: #2563eb; }
.pane-status-good .pane-topic-row__pct { color: #60a5fa; }
.pane-status-needs_work .pane-topic-row__bar { background: #d97706; }
.pane-status-needs_work .pane-topic-row__pct { color: #fbbf24; }
.pane-status-focus_here .pane-topic-row__bar { background: #CC0000; }
.pane-status-focus_here .pane-topic-row__pct { color: #f87171; }
.pane-status-not_started .pane-topic-row__bar { background: rgba(255,255,255,0.15); }
.pane-status-not_started .pane-topic-row__pct { color: rgba(255,255,255,0.3); }

/* ── Mode buttons ────────────────────────────────────────── */
.pane-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 24px; }
@media (max-width: 520px) { .pane-modes { grid-template-columns: 1fr; } }
.pane-mode-btn {
    background: #fff; border: 1.5px solid #e8e8e8; border-radius: 12px;
    padding: 20px 16px; cursor: pointer; text-align: left; transition: border-color 0.15s, box-shadow 0.15s;
    width: 100%;
}
.pane-mode-btn:hover { border-color: #CC0000; box-shadow: 0 4px 16px rgba(204,0,0,0.08); }
.pane-mode-btn__icon { font-size: 28px; margin-bottom: 10px; }
.pane-mode-btn__label { font-size: 15px; font-weight: 700; color: #1A1A1A; margin-bottom: 4px; }
.pane-mode-btn__sub { font-size: 12px; color: #888; }

/* ── Topic picker ────────────────────────────────────────── */
.pane-topic-picker { margin-bottom: 24px; }
.pane-topic-picker__title { font-size: 16px; font-weight: 700; margin-bottom: 14px; color: #1A1A1A; }
.pane-topic-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 520px) { .pane-topic-list { grid-template-columns: 1fr; } }
.pane-topic-item {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 14px; background: #fff; border: 1px solid #e8e8e8;
    border-radius: 10px; cursor: pointer; transition: border-color 0.12s, background 0.12s;
}
.pane-topic-item:hover { border-color: #CC0000; background: #fff8f8; }
.pane-topic-item__name { font-size: 13px; font-weight: 500; color: #1A1A1A; }
.pane-topic-item__badge {
    font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 10px;
    border: 1px solid #e8e8e8; color: #888;
}
.pane-topic-item--strong .pane-topic-item__badge { background: #f0fdf4; color: #16a34a; border-color: #bbf7d0; }
.pane-topic-item--needs_work .pane-topic-item__badge { background: #fffbeb; color: #d97706; border-color: #fde68a; }
.pane-topic-item--focus_here .pane-topic-item__badge { background: #fff0f0; color: #CC0000; border-color: #fecaca; }

/* ── Quiz screen ─────────────────────────────────────────── */
.pane-quiz-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 16px; gap: 12px; flex-wrap: wrap;
}
.pane-back-btn {
    background: none; border: 1px solid #e8e8e8; border-radius: 8px;
    padding: 7px 14px; font-size: 13px; cursor: pointer; color: #555;
    transition: border-color 0.12s; white-space: nowrap;
}
.pane-back-btn:hover { border-color: #CC0000; color: #CC0000; }
.pane-quiz-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pane-q-counter-text { font-size: 13px; color: #888; font-weight: 500; }
.pane-topic-badge {
    font-size: 11px; background: #f0f0f0; color: #555; padding: 3px 10px; border-radius: 12px; font-weight: 500;
}

/* Timer */
.pane-timer {
    font-size: 16px; font-weight: 700; color: #CC0000;
    background: #fff0f0; border: 1px solid #fecaca;
    padding: 5px 14px; border-radius: 8px; font-variant-numeric: tabular-nums;
}
.pane-timer--urgent { color: #CC0000; animation: pane-blink 1s ease-in-out infinite; }
@keyframes pane-blink { 0%,100%{opacity:1;} 50%{opacity:0.5;} }

/* Progress bar */
.pane-progress-bar {
    height: 5px; background: #f0f0f0; border-radius: 3px; margin-bottom: 28px; overflow: hidden;
}
.pane-progress-bar__fill {
    height: 100%; background: #CC0000; border-radius: 3px; transition: width 0.3s;
}

/* Question */
.pane-question__text {
    font-size: 17px; font-weight: 600; line-height: 1.5; margin-bottom: 24px; color: #1A1A1A;
}
.pane-options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.pane-option {
    display: flex; align-items: flex-start; gap: 14px;
    padding: 14px 16px; border: 1.5px solid #e8e8e8; border-radius: 10px;
    cursor: pointer; transition: border-color 0.12s, background 0.12s; background: #fff;
}
.pane-option:hover { border-color: #CC0000; background: #fff8f8; }
.pane-option.selected { border-color: #CC0000; background: #fff0f0; }
.pane-option.correct { border-color: #16a34a !important; background: #f0fdf4 !important; }
.pane-option.incorrect { border-color: #CC0000 !important; background: #fff0f0 !important; }
.pane-option.disabled { cursor: not-allowed; }
.pane-option__letter {
    width: 28px; height: 28px; border-radius: 50%; background: #f0f0f0;
    font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center;
    flex-shrink: 0; color: #555; transition: background 0.12s, color 0.12s;
}
.pane-option.correct .pane-option__letter { background: #16a34a; color: #fff; }
.pane-option.incorrect .pane-option__letter { background: #CC0000; color: #fff; }
.pane-option__text { font-size: 14px; line-height: 1.5; padding-top: 4px; color: #1A1A1A; }

/* Feedback */
.pane-feedback {
    padding: 16px 18px; border-radius: 10px; margin-bottom: 20px;
    font-size: 14px; line-height: 1.6;
}
.pane-feedback--correct { background: #f0fdf4; border-left: 4px solid #16a34a; }
.pane-feedback--incorrect { background: #fff0f0; border-left: 4px solid #CC0000; }
.pane-feedback__verdict { font-weight: 700; margin-bottom: 6px; font-size: 15px; }
.pane-feedback--correct .pane-feedback__verdict { color: #16a34a; }
.pane-feedback--incorrect .pane-feedback__verdict { color: #CC0000; }
.pane-feedback__text { color: #333; }

/* Next button */
.pane-next-btn {
    width: 100%; padding: 14px; background: #CC0000; color: #fff;
    border: none; border-radius: 10px; font-size: 15px; font-weight: 700;
    cursor: pointer; transition: background 0.15s;
}
.pane-next-btn:hover { background: #aa0000; }

/* ── Results screen ──────────────────────────────────────── */
.pane-results-header { text-align: center; padding: 32px 0 24px; }
.pane-results-score {
    font-size: 64px; font-weight: 900;
    background: linear-gradient(135deg, #CC0000, #FF6B00);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
    line-height: 1; margin-bottom: 8px;
}
.pane-results-score--pass { background: linear-gradient(135deg, #16a34a, #22c55e) !important; -webkit-background-clip: text; background-clip: text; }
.pane-results-status { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.pane-results-note { font-size: 14px; color: #666; }
.pane-pass-banner { background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 12px; padding: 16px 20px; margin-bottom: 24px; text-align: center; color: #16a34a; font-weight: 600; }
.pane-fail-banner { background: #fff0f0; border: 1px solid #fecaca; border-radius: 12px; padding: 16px 20px; margin-bottom: 24px; text-align: center; color: #CC0000; font-weight: 600; }

.pane-breakdown { margin-bottom: 32px; }
.pane-breakdown__title { font-size: 16px; font-weight: 700; margin-bottom: 14px; color: #1A1A1A; }
.pane-breakdown-row {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 0; border-bottom: 1px solid #f5f5f5;
}
.pane-breakdown-row:last-child { border-bottom: none; }
.pane-breakdown-row__icon { font-size: 16px; width: 24px; text-align: center; flex-shrink: 0; }
.pane-breakdown-row__topic { flex: 1; font-size: 13px; color: #1A1A1A; }
.pane-breakdown-row__bar-wrap { width: 80px; height: 6px; background: #f0f0f0; border-radius: 3px; flex-shrink: 0; }
.pane-breakdown-row__bar { height: 100%; border-radius: 3px; }
.pane-breakdown-row__pct { font-size: 13px; font-weight: 700; width: 40px; text-align: right; flex-shrink: 0; }

.pane-results-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.pane-results-actions .pane-next-btn { flex: 1; min-width: 140px; }
.pane-btn-secondary {
    flex: 1; min-width: 140px; padding: 14px; background: #fff; color: #CC0000;
    border: 1.5px solid #CC0000; border-radius: 10px; font-size: 15px; font-weight: 700;
    cursor: pointer; transition: background 0.15s;
}
.pane-btn-secondary:hover { background: #fff0f0; }

/* ── Gate ────────────────────────────────────────────────── */
.pane-gate { max-width: 560px; margin: 0 auto; padding: 36px 32px 40px; background: #fff; border: 1px solid #e8e8e8; border-radius: 16px; text-align: center; }
.pane-gate__icon { font-size: 44px; margin-bottom: 14px; }
.pane-gate__title { font-size: 22px; font-weight: 800; margin-bottom: 12px; color: #1A1A1A; }
.pane-gate__intro { font-size: 14px; color: #555; line-height: 1.65; margin-bottom: 24px; }
.pane-gate__steps { text-align: left; background: #f9f9f9; border-radius: 12px; padding: 20px; margin-bottom: 28px; display: flex; flex-direction: column; gap: 16px; }
.pane-gate__step { display: flex; gap: 14px; align-items: flex-start; }
.pane-gate__num { width: 28px; height: 28px; border-radius: 50%; background: #CC0000; color: #fff; font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 2px; }
.pane-gate__step strong { display: block; font-size: 14px; color: #1A1A1A; margin-bottom: 3px; }
.pane-gate__step p { font-size: 13px; color: #666; margin: 0 0 6px; }
.pane-gate__dos-link { font-size: 12px; font-weight: 600; color: #CC0000; text-decoration: none; }
.pane-gate__dos-link:hover { text-decoration: underline; }
.pane-gate__form { text-align: left; }
.pane-gate__field { margin-bottom: 16px; }
.pane-gate__field label { display: block; font-size: 13px; font-weight: 600; color: #333; margin-bottom: 6px; }
.pane-gate__field input[type="date"] { width: 100%; padding: 10px 12px; border: 1px solid #ddd; border-radius: 8px; font-size: 14px; box-sizing: border-box; }
.pane-gate__check label { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-weight: 400; }
.pane-gate__check input { margin-top: 2px; width: 16px; height: 16px; flex-shrink: 0; accent-color: #CC0000; }
.pane-gate__error { background: #fff0f0; border: 1px solid #fecaca; border-radius: 6px; padding: 10px 14px; font-size: 13px; color: #CC0000; margin-bottom: 14px; }
.pane-gate__btn { width: 100%; padding: 14px; background: #CC0000; color: #fff; border: none; border-radius: 10px; font-size: 15px; font-weight: 700; cursor: pointer; transition: background 0.15s; }
.pane-gate__btn:hover { background: #aa0000; }
.pane-gate__btn:disabled { background: #e0a0a0; cursor: not-allowed; }
.pane-gate__note { font-size: 12px; color: #aaa; margin-top: 16px; font-style: italic; }

/* ── Login gate ──────────────────────────────────────────── */
.pane-login-gate { padding: 40px; text-align: center; background: #f9f9f9; border-radius: 12px; }

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 520px) {
    .pane-question__text { font-size: 15px; }
    .pane-results-score { font-size: 48px; }
    .pane-gate { padding: 24px 20px; }
}

/* ── Question navigation pills ───────────────────────────── */
.pane-nav-bar-wrap {
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: thin;
    scrollbar-color: #e0e0e0 transparent;
}
.pane-nav-bar {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}
.pane-nav-pill {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 1.5px solid #e0e0e0;
    background: #fff;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    color: #888;
    transition: border-color 0.12s, background 0.12s, color 0.12s;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pane-nav-pill:hover { border-color: #CC0000; color: #CC0000; }
.pane-nav-pill--current { border-color: #CC0000; background: #CC0000; color: #fff; }
.pane-nav-pill--correct { border-color: #16a34a; background: #f0fdf4; color: #16a34a; }
.pane-nav-pill--wrong   { border-color: #CC0000; background: #fff0f0; color: #CC0000; }
.pane-nav-pill--skipped { border-color: #d97706; background: #fffbeb; color: #d97706; }

/* ── Bottom navigation row ───────────────────────────────── */
.pane-bottom-nav {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #efefef;
}
.pane-bottom-nav__centre {
    display: flex;
    justify-content: center;
}
.pane-nav-btn-prev {
    background: #fff;
    border: 1.5px solid #e0e0e0;
    border-radius: 10px;
    padding: 11px 18px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    color: #555;
    transition: border-color 0.12s, color 0.12s;
    justify-self: start;
}
.pane-nav-btn-prev:hover { border-color: #CC0000; color: #CC0000; }

.pane-skip-btn {
    background: #fff;
    border: 1.5px solid #d97706;
    border-radius: 10px;
    padding: 11px 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    color: #d97706;
    transition: background 0.12s;
}
.pane-skip-btn:hover { background: #fffbeb; }

.pane-skipped-btn {
    background: #fffbeb;
    border: 1.5px solid #d97706;
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    color: #d97706;
    justify-self: end;
    white-space: nowrap;
}
.pane-skipped-btn:hover { background: #fef3c7; }

.pane-nav-btn-finish {
    background: #1A1A1A;
    border: none;
    border-radius: 10px;
    padding: 11px 18px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    color: #fff;
    justify-self: end;
}
.pane-nav-btn-finish:hover { background: #333; }

/* Answer option states (updated) */
.pane-option--disabled { cursor: not-allowed; }
.pane-option--correct  { border-color: #16a34a !important; background: #f0fdf4 !important; }
.pane-option--wrong    { border-color: #CC0000 !important; background: #fff0f0 !important; }
.pane-option--correct .pane-option__letter { background: #16a34a; color: #fff; }
.pane-option--wrong .pane-option__letter   { background: #CC0000; color: #fff; }
.pane-option__icon {
    margin-left: auto;
    font-size: 14px;
    font-weight: 700;
    flex-shrink: 0;
    padding-top: 3px;
}
.pane-option--correct .pane-option__icon { color: #16a34a; }
.pane-option--wrong .pane-option__icon   { color: #CC0000; }

/* Feedback (updated class names) */
.pane-feedback--correct { background: #f0fdf4; border-left: 4px solid #16a34a; }
.pane-feedback--wrong   { background: #fff0f0; border-left: 4px solid #CC0000; }
.pane-feedback--correct .pane-feedback__verdict { color: #16a34a; }
.pane-feedback--wrong .pane-feedback__verdict   { color: #CC0000; }

@media (max-width: 520px) {
    .pane-bottom-nav { grid-template-columns: auto 1fr auto; }
    .pane-nav-pill { width: 28px; height: 28px; font-size: 10px; }
}
