/* ===== SPROOCHENTEST PAGE ===== */

.sp-page { width: 100%; }

.sp-container {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 32px;
}

.sp-hero {
  background: var(--dark);
  padding: 96px 0 64px;
  text-align: center;
}

.sp-title {
  font-size: clamp(30px, 4vw, 44px);
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #fff;
  margin: 12px 0 8px;
}

.sp-subtitle {
  font-size: 1rem;
  color: #94A3B8;
  margin-bottom: 20px;
}

.sp-intro {
  font-size: 0.92rem;
  color: #CBD5E1;
  max-width: 600px;
  margin: 0 auto 24px;
  line-height: 1.6;
}

.sp-disclaimer {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(147, 51, 234, 0.08);
  border: 1px solid rgba(147, 51, 234, 0.2);
  border-radius: 4px;
  padding: 12px 18px;
  font-size: 0.78rem;
  color: #CBD5E1;
  text-align: left;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.5;
}

.sp-disclaimer i { color: var(--accent); margin-top: 2px; }
.sp-disclaimer a { color: var(--accent) !important; font-weight: 600; }

/* Sections */
.sp-section {
  padding: 56px 0;
}

.sp-section-alt {
  background: var(--slate-bg);
}

.sp-h2 {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--dark);
  margin: 0 0 20px;
}

.sp-section p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* Checklist */
.sp-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sp-checklist span,
.sp-checklist a {
  padding: 6px 12px;
  border: 1px solid var(--slate-border);
  border-radius: 3px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted) !important;
  transition: all var(--transition);
}

.sp-checklist a:hover {
  border-color: var(--accent);
  color: var(--accent) !important;
  background: rgba(147, 51, 234, 0.04);
}

/* Cards */
.sp-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.sp-card {
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  padding: 24px;
  background: var(--white);
}

.sp-card h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--dark);
  margin: 0 0 12px;
}

.sp-lux {
  font-size: 0.88rem;
  color: var(--dark);
  font-weight: 600;
  font-style: italic;
  margin-bottom: 6px !important;
}

.sp-en {
  font-size: 0.82rem;
  color: var(--text-soft);
  margin-bottom: 12px !important;
}

.sp-vocab {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  padding: 8px 10px;
  background: var(--slate-bg);
  border-radius: 3px;
}

.sp-questions {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sp-questions span {
  font-size: 0.78rem;
  color: var(--accent);
  font-weight: 500;
}

/* Formula */
.sp-formula {
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  padding: 24px;
  background: var(--white);
  margin-bottom: 20px;
}

.sp-formula h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--dark);
  margin: 0 0 12px;
}

.sp-formula ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sp-formula li {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}

/* Methods */
.sp-methods {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.sp-method {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--slate-border);
  border-radius: 4px;
}

.sp-method i {
  color: var(--accent);
  font-size: 0.9rem;
  margin-top: 2px;
}

.sp-method span {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Vocab grid */
.sp-vocab-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.sp-vocab-group {
  padding: 16px;
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  background: var(--white);
}

.sp-vocab-group h4 {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--dark);
  margin: 0 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.sp-vocab-group span {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Grammar */
.sp-grammar-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.sp-grammar-list div {
  padding: 12px 0;
  border-bottom: 1px solid var(--slate-border);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.sp-grammar-list div:last-child { border-bottom: none; }

/* Plan */
.sp-plan {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.sp-week {
  padding: 16px;
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  background: var(--white);
}

.sp-week span {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
  text-transform: uppercase;
}

.sp-week p {
  font-size: 0.85rem;
  color: var(--dark);
  font-weight: 600;
  margin: 6px 0 0 !important;
}

/* Downloads */
.sp-coming {
  font-size: 0.85rem;
  color: var(--text-soft);
  font-style: italic;
}

.sp-downloads {
  list-style: none;
  padding: 0;
}

.sp-downloads li {
  padding: 10px 0;
  border-bottom: 1px solid var(--slate-border);
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* Start links */
.sp-start-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.sp-start-links a {
  padding: 12px 20px;
  background: var(--dark);
  color: #fff !important;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: 4px;
  transition: background var(--transition);
}

.sp-start-links a:hover {
  background: var(--accent);
}

/* Responsive */
@media (max-width: 700px) {
  .sp-hero { padding: 72px 0 48px; }
  .sp-cards { grid-template-columns: 1fr; }
  .sp-methods { grid-template-columns: 1fr; }
  .sp-vocab-grid { grid-template-columns: 1fr; }
  .sp-plan { grid-template-columns: 1fr; }
  .sp-container { padding: 0 20px; }
  .sp-section { padding: 40px 0; }

  .sp-download-card {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 14px !important;
  }

  .sp-download-card .sp-download-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ===== SPROOCHENTEST TOPIC PAGES ===== */

.sp-topic-page {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: calc(100vh - 60px);
  padding-top: 60px;
}

.sp-topic-sidebar {
  background: var(--dark);
  padding: 40px 24px;
  position: sticky;
  top: 60px;
  height: calc(100vh - 60px);
  overflow-y: auto;
}

.sp-sidebar-nav .card-label {
  color: var(--accent);
  margin-bottom: 16px;
}

.sp-sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sp-sidebar-list li {
  margin-bottom: 2px;
}

.sp-sidebar-list a {
  display: block;
  padding: 8px 12px;
  font-size: 0.8rem;
  font-weight: 500;
  color: #94A3B8 !important;
  border-radius: 3px;
  transition: all var(--transition);
}

.sp-sidebar-list a:hover {
  color: #fff !important;
  background: rgba(255, 255, 255, 0.05);
}

.sp-sidebar-list a.sp-active {
  color: #fff !important;
  background: var(--accent);
  font-weight: 600;
}

.sp-sidebar-back {
  display: block;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid #334155;
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748B !important;
  transition: color var(--transition);
}

.sp-sidebar-back:hover {
  color: #fff !important;
}

/* Main content */

.sp-topic-main {
  padding: 48px 56px;
  max-width: 100%;
}

.sp-topic-header {
  margin-bottom: 36px;
}

.sp-topic-title {
  font-size: clamp(26px, 3.5vw, 36px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--dark);
  margin: 12px 0 8px;
}

.sp-topic-subtitle {
  font-size: 0.9rem;
  color: var(--text-soft);
}

.sp-topic-content ol {
  padding-left: 0;
  counter-reset: question;
  list-style: none;
}

.sp-topic-content ol li {
  counter-increment: question;
  position: relative;
  padding: 14px 0 14px 36px;
  border-bottom: 1px solid var(--slate-border);
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.55;
}

.sp-topic-content ol li::before {
  content: counter(question);
  position: absolute;
  left: 0;
  top: 14px;
  width: 24px;
  height: 24px;
  background: var(--slate-bg);
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--accent);
}

/* Questions gate */
.sp-questions-wrapper {
  position: relative;
}

.sp-questions-list.gated ol li:nth-child(n+6) {
  filter: blur(4px);
  user-select: none;
  pointer-events: none;
}

.sp-questions-gate {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 280px; /* roughly after 5 questions */
  background: linear-gradient(to bottom, transparent 200px, rgba(255,255,255,0.95) 300px, var(--white) 400px);
  z-index: 10;
}

.sp-questions-gate.hidden {
  display: none;
}

.sp-gate-card {
  background: var(--white);
  border: 1px solid var(--slate-border);
  border-radius: 14px;
  padding: 32px 28px;
  text-align: center;
  max-width: 380px;
  width: 100%;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

.sp-gate-card-icon {
  margin-bottom: 14px;
}

.sp-gate-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
  margin: 0 0 8px;
}

.sp-gate-card-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0 0 20px;
  line-height: 1.5;
}

.sp-gate-card-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sp-gate-card-form input {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--slate-border);
  border-radius: 8px;
  font-size: 0.88rem;
  background: var(--white);
  color: var(--dark);
  outline: none;
  box-sizing: border-box;
}

.sp-gate-card-form input:focus {
  border-color: #9333EA;
  box-shadow: 0 0 0 3px rgba(147, 51, 234, 0.08);
}

.sp-gate-card-form button[type="submit"] {
  width: 100%;
  padding: 12px 18px;
  background: #9333EA;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.sp-gate-card-form button[type="submit"]:hover {
  background: #7C22CB;
}

.sp-gate-card-note {
  font-size: 0.75rem;
  color: var(--text-soft);
  margin: 14px 0 0;
}

.sp-gate-card-note button {
  background: none;
  border: none;
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
  font-size: 0.75rem;
  text-decoration: underline;
}

@media (max-width: 480px) {
  .sp-gate-card {
    padding: 24px 20px;
    margin: 0 12px;
  }
  .sp-questions-gate {
    padding-top: 240px;
  }
}

/* Responsive */
@media (max-width: 800px) {
  .sp-topic-page {
    grid-template-columns: 1fr;
  }

  .sp-topic-sidebar {
    position: static;
    height: auto;
    padding: 24px 20px;
  }

  .sp-topic-main {
    padding: 32px 20px;
  }

  .sp-topic-right {
    padding: 32px 20px;
    border-left: none;
    border-top: 1px solid var(--slate-border);
  }
}

/* Sproochentest newsletter */

.sp-newsletter {
  margin-top: 48px;
  padding-top: 36px;
  border-top: 1px solid var(--slate-border);
}

.sp-newsletter .card-label {
  color: var(--accent);
}

.sp-newsletter-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 8px 0 16px;
}

/* Sproochentest right sidebar */

.sp-topic-right {
  background: var(--slate-bg);
  padding: 40px 24px;
  border-left: 1px solid var(--slate-border);
}

.sp-topic-right .sp-newsletter {
  border-top: none;
  margin-top: 0;
  padding-top: 0;
}

.sp-topic-right .sp-newsletter-desc {
  color: var(--text-muted);
}

.sp-topic-right .card-label {
  color: var(--accent);
}

/* ===== SPROOCHENTEST HEADER ===== */

.sp-header {
  background: var(--dark);
  border-bottom: 1px solid #334155;
  padding: 0 48px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1031;
}

.sp-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  height: 60px;
}

.sp-header-brand {
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff !important;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.sp-header-brand:hover {
  color: var(--accent) !important;
}

.sp-header-nav {
  display: flex;
  gap: 4px;
}

.sp-header-nav a {
  font-size: 0.85rem;
  font-weight: 550;
  color: #94A3B8 !important;
  padding: 6px 14px;
  border-radius: 3px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: all var(--transition);
}

.sp-header-nav a:hover {
  color: #fff !important;
  background: rgba(255, 255, 255, 0.05);
}

.sp-header-nav a.sp-nav-active {
  color: #fff !important;
  background: var(--accent);
}

@media (max-width: 700px) {
  .sp-header {
    padding: 0 16px;
  }

  .sp-header-inner {
    height: 56px;
  }

  .sp-header-brand {
    font-size: 0.75rem !important;
    letter-spacing: 0.1em !important;
  }
}

.sp-header-brand-sub {
  color: var(--accent);
  font-weight: 500;
}

.sp-header-nav a.sp-nav-materials {
  color: var(--accent) !important;
}

.sp-header-nav a.sp-nav-materials:hover {
  color: #fff !important;
  background: var(--accent);
}

.sp-header-nav a.sp-nav-back {
  color: #64748B !important;
  border-left: 1px solid #334155;
  margin-left: 8px;
  padding-left: 18px;
  font-size: 0.75rem;
}

.sp-header-nav a.sp-nav-back:hover {
  color: #fff !important;
  background: transparent;
}

@media (max-width: 700px) {
  .sp-header-nav a.sp-nav-back {
    border-left: none;
    border-top: 1px solid #334155;
    margin-left: 0;
    padding-left: 0;
    padding-top: 12px;
    margin-top: 4px;
  }
}

/* ===== SPROOCHENTEST IMAGE DESCRIPTION ===== */

.sp-img-section-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--dark);
  margin: 36px 0 14px;
  padding-top: 20px;
  border-top: 1px solid var(--slate-border);
}

.sp-img-section-title:first-of-type {
  border-top: none;
  padding-top: 0;
}

.sp-img-steps {
  padding-left: 20px;
  margin: 0;
}

.sp-img-steps li {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 6px;
  line-height: 1.5;
}

.sp-phrase-card {
  background: var(--slate-bg);
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  padding: 20px 24px;
  margin-top: 10px;
}

.sp-phrase-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sp-phrase-list li {
  padding: 6px 0;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
  border-bottom: 1px solid var(--slate-border);
}

.sp-phrase-list li:last-child {
  border-bottom: none;
}

.sp-phrase-list li strong {
  color: var(--dark);
}

.sp-phrase-example {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--slate-border);
  font-size: 0.88rem;
  color: var(--dark);
  font-style: italic;
}

.sp-phrase-highlight {
  margin-top: 16px;
  padding: 16px;
  background: rgba(147, 51, 234, 0.04);
  border: 1px solid rgba(147, 51, 234, 0.15);
  border-radius: 3px;
}

.sp-phrase-highlight strong {
  color: var(--accent);
  font-size: 0.82rem;
  display: block;
  margin-bottom: 8px;
}

.sp-phrase-example-full {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--dark);
}

.sp-phrase-example-full p {
  margin-bottom: 8px !important;
  color: var(--dark) !important;
}

.sp-formula-card ol {
  padding-left: 20px;
  margin: 0;
}

.sp-formula-card li {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--dark);
  padding: 6px 0;
}

.sp-practice-questions {
  padding-left: 20px;
  margin: 0;
}

.sp-practice-questions li {
  font-size: 0.88rem;
  color: var(--text-muted);
  padding: 8px 0;
  border-bottom: 1px solid var(--slate-border);
}

.sp-practice-questions li:last-child {
  border-bottom: none;
}

.sp-img-links {
  display: flex;
  gap: 16px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--slate-border);
}

.sp-img-links a {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent) !important;
  transition: opacity var(--transition);
}

.sp-img-links a:hover {
  opacity: 0.7;
}

/* Disclaimer in light background */
.sp-topic-content .sp-disclaimer {
  color: var(--text-muted);
  background: rgba(147, 51, 234, 0.04);
  border-color: rgba(147, 51, 234, 0.15);
}

.sp-topic-content .sp-disclaimer span {
  color: var(--text-muted);
}

/* ===== LISTENING PRACTICE PAGE ===== */

.listen-topics {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.listen-topic {
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  padding: 28px;
}

.listen-topic-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.listen-topic-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--dark);
  margin: 0;
}

.listen-level {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--white);
  background: var(--accent);
  padding: 3px 8px;
  border-radius: 3px;
}

.listen-details {
  margin-bottom: 16px;
}

.listen-details summary {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent);
  cursor: pointer;
  padding: 8px 0;
}

.listen-details summary:hover {
  opacity: 0.8;
}

.listen-transcript {
  background: var(--slate-bg);
  border-radius: 4px;
  padding: 16px 20px;
  margin-top: 8px;
}

.listen-transcript p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 8px !important;
  line-height: 1.6;
}

.listen-questions h4 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--dark);
  margin: 16px 0 10px;
}

.listen-questions ol {
  padding-left: 20px;
  margin: 0;
}

.listen-questions li {
  font-size: 0.88rem;
  color: var(--dark);
  padding: 10px 0;
  border-bottom: 1px solid var(--slate-border);
  line-height: 1.5;
}

.listen-questions li:last-child {
  border-bottom: none;
}

.listen-questions li em {
  color: var(--text-soft);
  font-size: 0.8rem;
}

.listen-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.listen-options span {
  font-size: 0.78rem;
  color: var(--text-muted);
  padding: 4px 10px;
  border: 1px solid var(--slate-border);
  border-radius: 3px;
}

.listen-corrections {
  background: #ECFDF5;
  border-radius: 4px;
  padding: 12px 16px;
  margin-top: 8px;
}

.listen-corrections ol {
  padding-left: 20px;
  margin: 0;
}

.listen-corrections li,
.listen-corrections p {
  font-size: 0.82rem;
  color: #065F46;
  font-weight: 600;
}

/* Listening audio link */
.listen-audio-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--accent);
  color: #fff !important;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: 4px;
  transition: background var(--transition);
}

.listen-audio-link:hover {
  background: var(--accent-hover);
  color: #fff !important;
}

.listen-audio-link i {
  font-size: 0.9rem;
}

/* Listening page content fixes */
.sp-topic-content ol {
  counter-reset: question;
  list-style: none;
  padding-left: 0;
}

.sp-topic-content ol > li {
  counter-increment: question;
  padding: 12px 0 12px 32px;
  border-bottom: 1px solid var(--slate-border);
  position: relative;
  font-weight: 600;
  color: var(--dark);
}

.sp-topic-content ol > li::before {
  content: counter(question) ".";
  position: absolute;
  left: 0;
  font-weight: 700;
  color: var(--accent);
}

.sp-topic-content ol > li > ul {
  list-style: none;
  padding: 6px 0 0 0;
  margin: 0;
}

.sp-topic-content ol > li > ul > li {
  padding: 3px 0;
  font-weight: 400;
  font-size: 0.88rem;
  color: var(--text-muted);
  border-bottom: none;
  counter-increment: none;
  position: static;
}

.sp-topic-content ol > li > ul > li::before {
  content: none !important;
  display: none !important;
}

/* Old transcript link — replaced by button */

/* ===== TRANSCRIPT SIDE PANEL ===== */

.transcript-panel {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  height: 100vh;
  background: var(--white);
  border-left: 1px solid var(--slate-border);
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.08);
  z-index: 2000;
  transition: right 0.3s ease;
  display: flex;
  flex-direction: column;
}

.transcript-panel.open {
  right: 0;
}

.transcript-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px solid var(--slate-border);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--dark);
}

.transcript-close {
  background: none !important;
  border: none !important;
  font-size: 1.5rem;
  color: var(--text-soft) !important;
  cursor: pointer;
  padding: 0 !important;
  line-height: 1;
}

.transcript-close:hover {
  color: var(--dark) !important;
}

.transcript-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--text-muted);
}

.transcript-panel-body p {
  margin-bottom: 10px;
}

.transcript-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.3);
  z-index: 1999;
  display: none;
}

.transcript-overlay.open {
  display: block;
}

/* Transcript button */
.listen-transcript-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: transparent;
  color: var(--dark) !important;
  font-size: 0.82rem;
  font-weight: 600;
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition);
}

.listen-transcript-btn:hover {
  border-color: var(--accent);
  color: var(--accent) !important;
}

/* Hide old details transcripts */
.sp-topic-content details[id="transcript"] {
  display: none;
}

/* Button row */
.listen-actions {
  display: flex;
  gap: 10px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

@media (max-width: 600px) {
  .transcript-panel {
    width: 100%;
    right: -100%;
  }
}

/* Transcript panel formatting */
.transcript-panel-body strong {
  color: var(--dark);
  font-weight: 700;
}

.transcript-panel-body h4 {
  color: var(--dark);
  border-bottom: 1px solid var(--slate-border);
  padding-bottom: 6px;
}

/* ===== QUIZ FUNCTIONALITY ===== */

.sp-topic-content ol > li > ul > li {
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 3px;
  transition: background var(--transition);
}

.sp-topic-content ol > li > ul > li:hover {
  background: var(--slate-bg);
}

.sp-topic-content ol > li > ul > li.selected {
  background: rgba(147, 51, 234, 0.08);
  border: 1px solid var(--accent);
  font-weight: 600;
  color: var(--dark);
}

.sp-topic-content ol > li > ul > li.correct {
  background: #ECFDF5;
  border: 1px solid #10B981;
  color: #065F46;
  font-weight: 600;
}

.sp-topic-content ol > li > ul > li.wrong {
  background: #FEF2F2;
  border: 1px solid #EF4444;
  color: #991B1B;
  font-weight: 600;
}

.sp-topic-content ol > li.question-correct {
  border-left: 3px solid #10B981;
  padding-left: 29px;
}

.sp-topic-content ol > li.question-wrong {
  border-left: 3px solid #EF4444;
  padding-left: 29px;
}

.quiz-check-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--dark);
  color: #fff !important;
  font-size: 0.85rem;
  font-weight: 600;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 24px;
  transition: background var(--transition);
}

.quiz-check-btn:hover {
  background: var(--accent);
}

.quiz-check-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.quiz-score {
  display: none;
  margin-top: 16px;
  padding: 14px 20px;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 600;
}

.quiz-score.show {
  display: block;
}

.quiz-score.good {
  background: #ECFDF5;
  color: #065F46;
  border: 1px solid #10B981;
}

.quiz-score.ok {
  background: #FFFBEB;
  color: #92400E;
  border: 1px solid #F59E0B;
}

.quiz-score.bad {
  background: #FEF2F2;
  color: #991B1B;
  border: 1px solid #EF4444;
}

.quiz-reset-btn {
  display: none;
  margin-top: 12px;
  padding: 8px 16px;
  background: transparent;
  color: var(--text-muted) !important;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid var(--slate-border) !important;
  border-radius: 4px;
  cursor: pointer;
}

.quiz-reset-btn.show {
  display: inline-block;
}

/* Listening overview grid */
.listen-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 16px;
}

.listen-overview-card {
  display: flex;
  flex-direction: column;
  padding: 20px;
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  color: var(--dark) !important;
  transition: all var(--transition);
}

.listen-overview-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 12px rgba(147, 51, 234, 0.06);
}

.listen-overview-card h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--dark);
  margin: 8px 0 6px;
}

.listen-overview-card p {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0 0 auto;
  padding-bottom: 12px;
  line-height: 1.4;
}

.listen-overview-meta {
  font-family: var(--mono);
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--text-soft);
  letter-spacing: 0.05em;
}

@media (max-width: 700px) {
  .listen-overview-grid {
    grid-template-columns: 1fr;
  }
}

/* Section CTA button */
.sp-section-btn {
  display: inline-block;
  padding: 12px 24px;
  background: var(--dark);
  color: #fff !important;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: 4px;
  transition: background var(--transition);
}

.sp-section-btn:hover {
  background: var(--accent);
  color: #fff !important;
}

/* Sproochentest footer */
.sp-footer {
  background: var(--dark) !important;
  border-top: none;
  padding: 0;
}

.sp-footer .footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 48px;
}

.sp-footer .footer-left {
  display: flex;
  align-items: center;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.sp-footer .footer-sep {
  margin: 0 12px;
  color: var(--text-soft);
}

.sp-footer .footer-right a {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #94A3B8 !important;
}

.sp-footer .footer-right a:hover {
  color: var(--accent) !important;
}

/* Sproochentest mobile menu */
.sp-menu-toggle {
  display: none;
  background: none !important;
  border: none !important;
  color: #fff !important;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 4px 8px !important;
}

@media (max-width: 700px) {
  .sp-menu-toggle {
    display: block;
  }

  .sp-header-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--dark);
    border-top: 1px solid #334155;
    padding: 12px 24px;
    flex-direction: column;
    gap: 0;
  }

  .sp-header-nav.open {
    display: flex;
  }

  .sp-header-nav a {
    padding: 10px 0 !important;
    border-bottom: 1px solid #334155;
  }

  .sp-header-nav a:last-child {
    border-bottom: none;
  }

  .sp-header-inner {
    position: relative;
  }
}

/* Mobile topic dropdown */
.sp-mobile-dropdown {
  display: none;
  padding: 16px 20px;
  background: var(--slate-bg);
  border-bottom: 1px solid var(--slate-border);
  position: relative;
  z-index: 10;
}

.sp-topic-select {
  width: 100%;
  padding: 10px 14px;
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--dark);
  background: var(--white);
  border: 1px solid var(--slate-border);
  border-radius: 4px;
  appearance: auto;
  cursor: pointer;
}

.sp-mobile-dropdown .sp-sidebar-back {
  display: block;
  margin-top: 12px;
  font-size: 0.75rem;
}

@media (max-width: 800px) {
  .sp-topic-sidebar {
    display: none !important;
  }

  .sp-mobile-dropdown {
    display: block;
    margin-top: 60px;
  }

  .sp-topic-page {
    grid-template-columns: 1fr !important;
  }
}

/* Sproochentest newsletter responsive */
.sp-newsletter-mobile {
  display: none;
}

@media (max-width: 800px) {
  .sp-newsletter-desktop {
    display: none;
  }
  .sp-newsletter-mobile {
    display: block;
  }
}

/* Sproochentest hero links */
.sp-hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
  justify-content: center;
}

.sp-hero-btn {
  display: inline-block;
  padding: 12px 24px;
  background: transparent;
  color: #fff !important;
  font-size: 0.82rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 4px;
  transition: all var(--transition);
}

.sp-hero-btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff !important;
}

.sp-hero-links .sp-section-btn:hover {
  background: var(--accent) !important;
  border-color: var(--accent) !important;
  color: #fff !important;
}

@media (max-width: 600px) {
  .sp-hero-links {
    flex-direction: column;
  }

  .sp-hero-links .sp-section-btn,
  .sp-hero-btn {
    text-align: center;
  }
}

