/* Cyber Security Quiz styles */

.cq-page {
  max-width: 820px;
  margin: 0 auto;
  padding: 120px 20px 60px;
}

.cq-page .hidden { display: none; }

.cq-hero h1 { font-size: 2.4rem; margin-bottom: 0.5rem; }
.cq-hero .cq-subtitle {
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.cq-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  padding: 2rem;
  margin-bottom: 2rem;
}

.cq-meta-row {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

/* progress + score row */
.cq-bar-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.5rem;
}
#cq-progress-label { color: var(--text-muted); font-size: 0.85rem; }
#cq-score-label {
  color: var(--text-secondary);
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}
#cq-score-label svg { width: 15px; height: 15px; color: #4ade80; }
.cq-progress-track {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  height: 8px;
  overflow: hidden;
  margin-bottom: 1.25rem;
}
#cq-progress-fill {
  background: var(--accent-color);
  height: 100%;
  width: 0;
  border-radius: 999px;
  transition: width 0.25s ease;
}

#cq-topic {
  display: inline-block;
  color: var(--accent-color);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
}

/* ---- visual artifacts ---- */
.cq-visual { margin-bottom: 1.25rem; }
.cq-visual svg { width: 18px; height: 18px; vertical-align: -3px; }

/* fake email */
.cq-email {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.7rem;
  overflow: hidden;
}
.cq-email-head {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.cq-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(0, 217, 255, 0.15);
  color: var(--accent-color);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 600;
  flex-shrink: 0;
}
.cq-email-from { display: flex; flex-direction: column; min-width: 0; }
.cq-email-from strong { color: var(--text-primary); font-size: 0.95rem; }
.cq-email-addr { color: var(--text-muted); font-size: 0.8rem; overflow: hidden; text-overflow: ellipsis; }
.cq-email-body { padding: 1rem; }
.cq-email-subject { color: var(--text-primary); font-weight: 600; margin: 0 0 0.5rem; }
.cq-email-text { color: var(--text-secondary); line-height: 1.6; margin: 0 0 1rem; font-size: 0.95rem; }
.cq-email-btn {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: var(--accent-color); color: #06202a;
  font-size: 0.85rem; font-weight: 600;
  padding: 0.5rem 1rem; border-radius: 0.4rem;
}
.cq-email-btn svg { color: #06202a; }
.cq-attach {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.4rem;
  padding: 0.4rem 0.75rem;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

/* wifi picker */
.cq-wifi {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.7rem;
  overflow: hidden;
}
.cq-wifi-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.8rem 1rem;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.cq-wifi-row:last-child { border-bottom: none; }
.cq-wifi-open { color: var(--accent-tertiary); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em; }
.cq-wifi-lock svg { color: var(--text-muted); }

/* mfa push */
.cq-push {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.7rem;
  padding: 1rem 1.1rem;
  max-width: 340px;
}
.cq-push-head { color: var(--text-primary); font-weight: 600; display: flex; align-items: center; gap: 0.4rem; margin-bottom: 0.5rem; }
.cq-push-head svg { color: var(--accent-color); }
.cq-push-text { color: var(--text-secondary); margin: 0 0 0.3rem; }
.cq-push-meta { color: var(--text-muted); font-size: 0.8rem; margin: 0 0 0.9rem; }
.cq-push-btns { display: flex; gap: 0.6rem; }
.cq-push-deny, .cq-push-approve {
  flex: 1; text-align: center; padding: 0.45rem; border-radius: 0.4rem; font-size: 0.85rem; font-weight: 600;
}
.cq-push-deny { border: 1px solid rgba(255, 255, 255, 0.2); color: var(--text-muted); }
.cq-push-approve { background: var(--accent-color); color: #06202a; }

/* update dialog */
.cq-dialog {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.7rem;
  padding: 1.25rem;
  text-align: center;
  max-width: 360px;
}
.cq-dialog-icon svg { width: 30px; height: 30px; color: var(--accent-color); }
.cq-dialog-title { color: var(--text-primary); font-weight: 600; margin: 0.5rem 0 0.25rem; }
.cq-dialog-text { color: var(--text-muted); font-size: 0.9rem; margin: 0 0 1rem; }
.cq-dialog-btns { display: flex; gap: 0.6rem; justify-content: center; }
.cq-dialog-later { color: var(--text-muted); font-size: 0.85rem; padding: 0.45rem 0.9rem; }
.cq-dialog-now { background: var(--accent-color); color: #06202a; font-weight: 600; font-size: 0.85rem; padding: 0.45rem 0.9rem; border-radius: 0.4rem; }

/* ransomware lock screen */
.cq-lock {
  border: 1px solid rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.08);
  border-radius: 0.7rem;
  padding: 1.5rem;
  text-align: center;
}
.cq-lock-icon svg { width: 36px; height: 36px; color: #f87171; }
.cq-lock-title { color: #fca5a5; font-weight: 700; font-size: 1.2rem; margin: 0.5rem 0 0.4rem; }
.cq-lock-text { color: var(--text-secondary); margin: 0; line-height: 1.6; font-size: 0.9rem; }

/* ---- question + options ---- */
#cq-prompt { font-size: 1.3rem; line-height: 1.45; margin: 0 0 1.25rem; color: var(--text-primary); }

.cq-option {
  display: flex; align-items: center; gap: 0.8rem;
  width: 100%; text-align: left;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.6rem;
  color: var(--text-secondary);
  font-size: 1rem;
  padding: 0.9rem 1.1rem;
  margin-bottom: 0.6rem;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.cq-option-label { flex: 1; }

/* A / B / C letter badges — each a distinct colour so options stand out */
.cq-option-letter {
  flex-shrink: 0;
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.9rem;
}
.cq-opt-a .cq-option-letter { background: rgba(0, 217, 255, 0.16); color: var(--accent-color); }
.cq-opt-b .cq-option-letter { background: rgba(124, 58, 237, 0.25); color: #b9a4fb; }
.cq-opt-c .cq-option-letter { background: rgba(245, 158, 11, 0.18); color: #fbbf24; }
.cq-option:not(:disabled):hover { border-color: var(--accent-color); background: rgba(0, 217, 255, 0.06); }
.cq-option:disabled { cursor: default; }
.cq-option.correct { border-color: #4ade80 !important; background: rgba(34, 197, 94, 0.14) !important; color: #bbf7d0; }
.cq-option.incorrect { border-color: #f87171 !important; background: rgba(239, 68, 68, 0.14) !important; color: #fecaca; }
.cq-option-mark { flex-shrink: 0; width: 20px; height: 20px; }
.cq-option-mark svg { width: 20px; height: 20px; }
.cq-option.correct .cq-option-mark { color: #4ade80; }
.cq-option.incorrect .cq-option-mark { color: #f87171; }

.cq-why {
  border-radius: 0.6rem;
  padding: 1rem 1.2rem;
  line-height: 1.6;
  margin: 0.5rem 0 0;
  color: var(--text-secondary);
}
.cq-why.correct { border: 1px solid rgba(34, 197, 94, 0.4); background: rgba(34, 197, 94, 0.08); }
.cq-why.incorrect { border: 1px solid rgba(245, 158, 11, 0.4); background: rgba(245, 158, 11, 0.08); }
.cq-why strong { color: var(--text-primary); }

#cq-next {
  margin-top: 1.25rem;
}

/* ---- results ---- */
.cq-result-head { text-align: center; margin-bottom: 1.5rem; }
.cq-medal {
  width: 84px; height: 84px;
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 0.75rem;
}
.cq-medal svg { width: 46px; height: 46px; }
.cq-medal-gold { background: rgba(242, 176, 30, 0.16); color: #f2b01e; }
.cq-medal-silver { background: rgba(176, 186, 197, 0.16); color: #b8c3cf; }
.cq-medal-bronze { background: rgba(199, 123, 59, 0.16); color: #d08a4e; }
#cq-tier { font-size: 1.4rem; margin: 0 0 0.25rem; }
#cq-final-score { font-size: 2.4rem; font-weight: 800; color: var(--text-primary); display: block; margin-bottom: 0.5rem; }
#cq-result-text { color: var(--text-secondary); line-height: 1.6; max-width: 460px; margin: 0 auto; }

.cq-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; margin: 1.5rem 0; }
.cq-chip { font-size: 0.78rem; padding: 0.3rem 0.8rem; border-radius: 999px; }
.cq-chip.ok { background: rgba(34, 197, 94, 0.15); color: #4ade80; }
.cq-chip.miss { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }

.cq-share-wrap { text-align: center; margin: 1.5rem 0; }
#cq-share {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  padding: 0.6rem 1.2rem;
  cursor: pointer;
}
#cq-share svg { width: 18px; height: 18px; }
#cq-share:hover { border-color: var(--accent-color); color: var(--accent-color); }
#cq-share-status { color: var(--text-muted); font-size: 0.85rem; margin-top: 0.6rem; min-height: 1.2em; }

/* optional email result */
.cq-email {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--glass-border);
}
.cq-email h3 { margin: 0 0 0.5rem; }
.cq-email p { color: var(--text-secondary); line-height: 1.6; margin: 0 0 1rem; }
#cq-email-form { display: flex; gap: 0.6rem; flex-wrap: wrap; }
#cq-email-input {
  flex: 1; min-width: 220px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 1rem;
  padding: 0.75rem 1rem;
}
#cq-email-input:focus { outline: none; border-color: var(--accent-color); }
.cq-email-status { margin-top: 0.75rem; line-height: 1.5; font-size: 0.95rem; color: var(--text-secondary); }
.cq-email-status.success { color: #4ade80; }
.cq-email-status.error { color: #f87171; }
.cq-email-privacy { color: var(--text-muted) !important; font-size: 0.8rem !important; margin-top: 0.75rem !important; }

.cq-cta {
  text-align: center;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--glass-border);
}
.cq-cta p { color: var(--text-secondary); line-height: 1.6; max-width: 520px; margin: 0 auto 1.25rem; }
#cq-restart {
  background: none; border: none; color: var(--text-muted);
  cursor: pointer; font-size: 0.9rem; margin-top: 1rem; text-decoration: underline;
}
.cq-disclaimer { color: var(--text-muted); font-size: 0.8rem; line-height: 1.5; margin-top: 2rem; }

/* ---- SEO accordions ---- */
.cq-content details.cq-acc {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.75rem;
  margin-bottom: 0.9rem;
}
.cq-acc summary {
  cursor: pointer; padding: 1rem 1.3rem; list-style: none;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.cq-acc summary::-webkit-details-marker { display: none; }
.cq-acc summary::after { content: "+"; color: var(--accent-color); font-size: 1.4rem; font-weight: 600; line-height: 1; flex-shrink: 0; }
.cq-acc[open] summary::after { content: "\2212"; }
.cq-acc summary:hover h2, .cq-acc summary:hover h3 { color: var(--accent-color); }
.cq-content .cq-acc summary h2 { font-size: 1.25rem; margin: 0; }
.cq-acc summary h3 { font-size: 1.05rem; margin: 0; color: var(--text-primary); font-weight: 600; }
.cq-acc .cq-acc-body { padding: 0 1.3rem 1.1rem; }
.cq-acc .cq-acc-body > :first-child { margin-top: 0; }
.cq-acc .cq-acc-body p { color: var(--text-secondary); line-height: 1.7; margin: 0 0 0.8rem; }
.cq-acc .cq-acc-body p:last-child { margin-bottom: 0; }

@media (max-width: 600px) {
  .cq-page { padding-top: 100px; }
  .cq-hero h1 { font-size: 1.8rem; }
  .cq-card { padding: 1.25rem; }
  #cq-prompt { font-size: 1.15rem; }
  #cq-final-score { font-size: 2rem; }
}
