/* SAT Verbal Pro — Blue Book Style v2.0 */

#svp-app {
  font-family: Georgia, 'Times New Roman', serif;
  color: #1a1a1a;
  background: #fff;
  border: 1px solid #d0d7de;
  border-radius: 8px;
  overflow: hidden;
  max-width: 1100px;
  margin: 0 auto;
}

/* ── NO KEY ── */
.svp-no-key {
  text-align: center;
  padding: 60px 40px;
  background: #fffbf0;
  border: 2px dashed #e6c84a;
  border-radius: 8px;
  margin: 20px;
}
.svp-no-key-icon { font-size: 48px; margin-bottom: 12px; }
.svp-no-key h3   { font-size: 20px; color: #1a2b4a; margin-bottom: 8px; }
.svp-no-key p    { color: #666; font-size: 14px; }
.svp-no-key a    { color: #0055a5; }

/* ── TOP BAR ── */
.svp-topbar {
  background: #1a2b4a;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 56px;
}
.svp-logo {
  font-family: Georgia, serif;
  font-size: 18px;
  font-weight: bold;
  color: #fff;
  letter-spacing: .4px;
}
.svp-section-info {
  text-align: center;
  font-size: 13px;
  color: #aac4e8;
}
.svp-section-info strong {
  display: block;
  color: #fff;
  font-size: 14px;
}
.svp-timer-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #aac4e8;
}
.svp-timer-icon { font-size: 18px; }
#svp-timer {
  color: #fff;
  font-size: 20px;
  font-weight: bold;
  font-variant-numeric: tabular-nums;
  min-width: 60px;
  text-align: right;
}
#svp-timer.svp-urgent { color: #ff6b6b; }

/* ── INTRO ── */
#svp-intro { padding: 40px; }
.svp-intro-inner { max-width: 700px; margin: 0 auto; }
.svp-intro-title {
  font-size: 26px;
  font-weight: bold;
  color: #1a2b4a;
  margin: 0 0 8px;
}
.svp-intro-sub {
  font-size: 15px;
  color: #666;
  margin: 0 0 28px;
}
.svp-domain-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}
.svp-domain-card {
  border: 1.5px solid #d0d7de;
  border-radius: 10px;
  padding: 16px;
  cursor: pointer;
  transition: all .15s;
  background: #fff;
}
.svp-domain-card:hover  { border-color: #0055a5; background: #e8f0f9; }
.svp-domain-card.svp-selected { border-color: #0055a5; background: #e8f0f9; }
.svp-domain-icon { font-size: 24px; margin-bottom: 6px; }
.svp-domain-name { font-size: 14px; font-weight: bold; color: #1a2b4a; margin-bottom: 4px; }
.svp-domain-desc { font-size: 12px; color: #888; }

.svp-intro-info {
  background: #f0f4f8;
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 13px;
  color: #555;
  line-height: 1.6;
  margin-bottom: 20px;
}
.svp-intro-info strong { color: #1a2b4a; }

.svp-q-count-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  font-size: 14px;
  color: #555;
}
.svp-q-count-wrap select {
  padding: 8px 12px;
  border: 1.5px solid #d0d7de;
  border-radius: 6px;
  font-family: Georgia, serif;
  font-size: 14px;
  background: #fff;
  cursor: pointer;
}
.svp-start-btn {
  background: #0055a5;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 14px 32px;
  font-family: Georgia, serif;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  width: 100%;
  transition: all .15s;
  display: block;
  text-align: center;
  margin-bottom: 10px;
}
.svp-start-btn:hover { background: #004490; }
.svp-btn-secondary { background: #fff; color: #1a2b4a; border: 1.5px solid #d0d7de; }
.svp-btn-secondary:hover { background: #f0f4f8; }
.svp-btn-ghost { background: transparent; color: #0055a5; border: 1.5px solid #0055a5; }
.svp-btn-ghost:hover { background: #e8f0f9; }

/* ── LOADING ── */
#svp-loading { padding: 80px 40px; text-align: center; }
.svp-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid #d0e3f5;
  border-top-color: #0055a5;
  border-radius: 50%;
  animation: svp-spin 0.8s linear infinite;
  margin: 0 auto 20px;
}
@keyframes svp-spin { to { transform: rotate(360deg); } }
#svp-loading h3 { font-size: 20px; color: #1a2b4a; margin-bottom: 8px; }
#svp-loading p  { font-size: 14px; color: #888; margin-bottom: 24px; }
.svp-loading-bar {
  background: #d0e3f5;
  border-radius: 4px;
  height: 6px;
  max-width: 300px;
  margin: 0 auto;
  overflow: hidden;
}
#svp-loading-fill {
  background: #0055a5;
  height: 100%;
  width: 0%;
  border-radius: 4px;
  transition: width 0.4s ease;
}

/* ── DIRECTION BAR ── */
.svp-dirbar {
  background: #edf2f7;
  border-top: 1px solid #d0d7de;
  border-bottom: 1.5px solid #d0d7de;
  padding: 8px 24px;
  font-size: 12px;
  color: #666;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── TEST BODY ── */
.svp-test-body {
  display: flex;
  min-height: 500px;
}

/* ── QUESTION PANEL ── */
#svp-q-panel {
  flex: 1;
  padding: 32px 40px 32px 48px;
  overflow-y: auto;
  max-width: 680px;
  border-right: 1.5px solid #d0d7de;
}
.svp-q-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.svp-q-num {
  font-size: 12px;
  color: #888;
  text-transform: uppercase;
  letter-spacing: .8px;
}
.svp-domain-badge {
  font-size: 11px;
  background: #e8f0f9;
  color: #0055a5;
  padding: 3px 10px;
  border-radius: 20px;
  font-style: italic;
}
.svp-q-stem {
  font-size: 15px;
  font-weight: bold;
  color: #1a2b4a;
  margin-bottom: 16px;
  line-height: 1.55;
}
.svp-q-passage {
  background: #f8f9fb;
  border-left: 4px solid #0055a5;
  padding: 16px 20px;
  font-size: 14px;
  line-height: 1.85;
  color: #2a2a2a;
  margin-bottom: 20px;
  border-radius: 0 6px 6px 0;
}
.svp-q-passage em { font-style: italic; }
.svp-blank {
  display: inline-block;
  background: #d0e3f5;
  border-bottom: 2px solid #0055a5;
  padding: 1px 10px;
  min-width: 60px;
  border-radius: 2px;
  font-style: italic;
  color: #1a2b4a;
}

/* ── CHOICES ── */
.svp-choices { display: flex; flex-direction: column; gap: 10px; }
.svp-choice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  border: 1.5px solid #d0d7de;
  border-radius: 8px;
  cursor: pointer;
  transition: all .15s;
  background: #fff;
  font-size: 14px;
  line-height: 1.6;
}
.svp-choice:hover                                 { border-color: #0055a5; background: #e8f0f9; }
.svp-choice.svp-selected                          { border-color: #0055a5; background: #e8f0f9; }
.svp-choice.svp-correct                           { border-color: #1a7a3c; background: #e6f4ec; cursor: default; }
.svp-choice.svp-wrong                             { border-color: #c0392b; background: #fdecea; cursor: default; }
.svp-choice.svp-reveal-correct                    { border-color: #1a7a3c; background: #e6f4ec; cursor: default; }
.svp-choice.svp-checked:not(.svp-correct):not(.svp-wrong):not(.svp-reveal-correct) { cursor: default; }

.svp-choice-letter {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid #d0d7de;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: bold;
  color: #888;
  flex-shrink: 0;
  margin-top: 1px;
  transition: all .15s;
}
.svp-choice.svp-selected .svp-choice-letter       { background: #0055a5; border-color: #0055a5; color: #fff; }
.svp-choice.svp-correct  .svp-choice-letter       { background: #1a7a3c; border-color: #1a7a3c; color: #fff; }
.svp-choice.svp-wrong    .svp-choice-letter       { background: #c0392b; border-color: #c0392b; color: #fff; }
.svp-choice.svp-reveal-correct .svp-choice-letter { background: #1a7a3c; border-color: #1a7a3c; color: #fff; }
.svp-choice-text { flex: 1; color: #1a1a1a; }

/* ── EXPLANATION ── */
.svp-explanation {
  background: #fffdf0;
  border-top: 1.5px solid #e6c84a;
  padding: 16px 20px;
  margin-top: 18px;
  border-radius: 6px;
  font-size: 13px;
  line-height: 1.65;
}
.svp-exp-head {
  font-weight: bold;
  font-size: 14px;
  margin-bottom: 8px;
}
.svp-exp-head.svp-correct-head { color: #1a7a3c; }
.svp-exp-head.svp-wrong-head   { color: #c0392b; }
.svp-explanation p { color: #3a3000; }

/* ── SIDEBAR ── */
#svp-sidebar {
  width: 260px;
  padding: 24px 20px;
  background: #fafbfc;
  border-left: 1px solid #eee;
}
.svp-sidebar-section   { margin-bottom: 24px; }
.svp-sidebar-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: #888;
  margin-bottom: 10px;
  font-family: -apple-system, sans-serif;
}
.svp-score-box {
  background: #e8f0f9;
  border: 1px solid #d0e3f5;
  border-radius: 8px;
  padding: 14px 16px;
}
.svp-score-big   { font-size: 28px; font-weight: bold; color: #1a2b4a; font-variant-numeric: tabular-nums; }
.svp-score-detail { font-size: 12px; color: #888; margin-top: 4px; font-family: -apple-system, sans-serif; }

/* ── QUESTION GRID ── */
.svp-q-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.svp-qb {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  border: 1.5px solid #d0d7de;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  transition: all .15s;
  color: #888;
  background: #fff;
  font-family: -apple-system, sans-serif;
  position: relative;
}
.svp-qb:hover               { border-color: #0055a5; color: #0055a5; }
.svp-qb.svp-active          { background: #1a2b4a; border-color: #1a2b4a; color: #fff; }
.svp-qb.svp-answered        { background: #e8f0f9; border-color: #0055a5; color: #0055a5; }
.svp-qb.svp-correct         { background: #e6f4ec; border-color: #1a7a3c; color: #1a7a3c; }
.svp-qb.svp-wrong           { background: #fdecea; border-color: #c0392b; color: #c0392b; }
.svp-qb.svp-flagged::after  {
  content: '';
  width: 6px; height: 6px;
  background: #e67e00;
  border-radius: 50%;
  position: absolute;
  top: 2px; right: 2px;
}

.svp-new-set-btn {
  width: 100%;
  padding: 10px;
  background: #fff;
  border: 1.5px solid #d0d7de;
  border-radius: 6px;
  font-size: 13px;
  cursor: pointer;
  color: #555;
  font-family: Georgia, serif;
  transition: all .15s;
}
.svp-new-set-btn:hover { border-color: #0055a5; color: #0055a5; background: #e8f0f9; }

/* ── BOTTOM NAV ── */
.svp-bottomnav {
  background: #1a2b4a;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.svp-btn {
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-family: Georgia, serif;
  cursor: pointer;
  border: none;
  transition: all .15s;
  font-weight: bold;
  white-space: nowrap;
}
.svp-btn-outline  { background: transparent; border: 1.5px solid #aac4e8; color: #fff; }
.svp-btn-outline:hover { background: rgba(255,255,255,.1); }
.svp-btn-primary  { background: #fff; color: #1a2b4a; }
.svp-btn-primary:hover  { background: #e8f0f9; }
.svp-btn-check    { background: #1a7a3c; color: #fff; }
.svp-btn-check:hover    { background: #145e2e; }
.svp-btn-flag     { background: transparent; border: 1.5px solid #e6a800; color: #e6a800; font-size: 12px; padding: 8px 14px; }
.svp-btn-flag:hover     { background: rgba(230,168,0,.1); }
.svp-btn-flag.svp-flagged { background: #e6a800; color: #000; }
.svp-btn-sm       { background: transparent; border: 1.5px solid #aac4e8; color: #aac4e8; font-size: 12px; padding: 8px 14px; }
.svp-nav-center   { display: flex; gap: 8px; align-items: center; }

/* ── RESULTS ── */
#svp-results { padding: 40px; text-align: center; }
.svp-results-inner { max-width: 560px; margin: 0 auto; }
.svp-results-title  { font-size: 26px; font-weight: bold; color: #1a2b4a; margin-bottom: 8px; }
.svp-results-score  { font-size: 60px; font-weight: bold; color: #0055a5; margin: 16px 0; font-variant-numeric: tabular-nums; }
.svp-results-sub    { font-size: 16px; color: #666; margin-bottom: 28px; }
.svp-results-grid   { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 28px; }
.svp-results-card   { background: #f5f5f5; border-radius: 10px; padding: 20px; }
.svp-res-val        { font-size: 32px; font-weight: bold; margin-bottom: 4px; }
.svp-res-lbl        { font-size: 12px; color: #888; text-transform: uppercase; letter-spacing: .6px; font-family: -apple-system, sans-serif; }
.svp-green { color: #1a7a3c; }
.svp-red   { color: #c0392b; }
.svp-blue  { color: #0055a5; }

.svp-results-breakdown {
  background: #f8f9fb;
  border: 1px solid #e8ecf0;
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 24px;
  text-align: left;
  font-size: 13px;
  line-height: 2;
}
.svp-results-breakdown h4 { font-size: 14px; color: #1a2b4a; margin-bottom: 8px; }
.svp-bd-row { display: flex; justify-content: space-between; }
.svp-bd-domain { color: #555; }
.svp-bd-score  { font-weight: bold; }

.svp-results-actions { display: flex; flex-direction: column; gap: 10px; }

/* ── ERROR BANNER ── */
.svp-error {
  background: #fdecea;
  border: 1.5px solid #c0392b;
  border-radius: 8px;
  padding: 16px 20px;
  margin: 20px;
  font-size: 14px;
  color: #7a1a1a;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.svp-error-retry {
  margin-left: auto;
  background: #c0392b;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 8px 16px;
  cursor: pointer;
  font-family: Georgia, serif;
  font-size: 13px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .svp-test-body { flex-direction: column; }
  #svp-q-panel   { max-width: 100%; border-right: none; border-bottom: 1.5px solid #d0d7de; padding: 24px 20px; }
  #svp-sidebar   { width: 100%; padding: 16px 20px; }
  .svp-bottomnav { flex-wrap: wrap; gap: 8px; }
  .svp-nav-center { order: -1; width: 100%; justify-content: center; }
  .svp-domain-grid { grid-template-columns: 1fr 1fr; }
  .svp-results-grid { grid-template-columns: 1fr 1fr 1fr; }
}
@media (max-width: 480px) {
  #svp-q-panel { padding: 20px 16px; }
  .svp-domain-grid { grid-template-columns: 1fr; }
  .svp-topbar { padding: 0 16px; }
  .svp-logo { font-size: 15px; }
  #svp-timer { font-size: 17px; }
}
