/* ============================================================
   Help-Center / FAQ — Dark-Theme
   Layer 1: Tokens (vom main.css geerbt)
   Layer 2: Layout (Hero + Grid + Sidebar)
   Layer 3: Components (Cards, Pills, Suggest, Feedback, TOC)
   ============================================================ */

/* ---------- Hero über allen Help-Seiten ---------- */
.help-hero {
  padding: clamp(80px, 12vw, 140px) 0 clamp(40px, 6vw, 60px);
  background:
    radial-gradient(ellipse 50% 60% at 20% 0%, rgba(0,255,208,0.10) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 80% 30%, rgba(139,92,246,0.10) 0%, transparent 55%),
    var(--c-deep);
  border-bottom: 1px solid var(--c-border);
  position: relative;
  overflow: hidden;
}
.help-hero .container { position: relative; z-index: 1; }

.help-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(0,255,208,0.08);
  border: 1px solid rgba(0,255,208,0.25);
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-accent);
  margin-bottom: 20px;
}
.help-hero-eyebrow::before {
  content: '';
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--c-accent);
  box-shadow: 0 0 12px var(--c-accent);
}

.help-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(32px, 6vw, 56px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: #fff;
  margin: 0 0 14px;
}
.help-hero h1 .highlight {
  background: linear-gradient(135deg, var(--c-accent) 0%, var(--c-violet) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.help-hero-sub {
  font-size: clamp(15px, 2vw, 18px);
  color: var(--c-text-dim);
  max-width: 620px;
  margin-bottom: 28px;
}

.help-hero-stats {
  display: inline-flex;
  align-items: center;
  gap: 28px;
  padding: 10px 22px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--c-border);
  border-radius: 14px;
  margin-top: 8px;
}
.help-hero-stats > div { display: flex; align-items: baseline; gap: 6px; }
.help-hero-stats .stat-value {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}
.help-hero-stats .stat-label {
  font-size: 12px;
  color: var(--c-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---------- Suchfeld ---------- */
.help-search-form {
  display: flex;
  gap: 10px;
  max-width: 600px;
  margin-top: 28px;
  position: relative;
}
.faq-suggest-combo {
  position: relative;
  flex: 1;
}
.help-search-form input[type="search"] {
  width: 100%;
  padding: 14px 18px 14px 44px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--c-border-light);
  border-radius: 12px;
  color: var(--c-text);
  font-family: var(--font-body);
  font-size: 15px;
  transition: border-color .2s, background .2s;
}
.help-search-form input[type="search"]::placeholder { color: var(--c-text-muted); }
.help-search-form input[type="search"]:focus {
  outline: none;
  border-color: var(--c-accent);
  background: rgba(0,255,208,0.05);
}
.faq-suggest-combo::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='11' cy='11' r='7'/><path d='M21 21l-4.3-4.3'/></svg>") no-repeat center / contain;
  pointer-events: none;
  opacity: 0.6;
}
.help-search-form .btn {
  padding: 14px 24px;
  background: linear-gradient(135deg, var(--c-accent) 0%, var(--c-violet) 100%);
  border: none;
  border-radius: 12px;
  color: #06060f;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: transform .15s var(--ease-out), box-shadow .2s;
  white-space: nowrap;
}
.help-search-form .btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0,255,208,0.25);
}

/* ---------- Auto-Suggest-Dropdown ---------- */
.faq-suggest-list {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 1000;
  list-style: none;
  margin: 0;
  padding: 8px;
  background: var(--c-surface);
  border: 1px solid var(--c-border-light);
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.5);
  max-height: 360px;
  overflow-y: auto;
}
.faq-suggest-list li {
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: background .15s;
}
.faq-suggest-list li.faq-suggest-active,
.faq-suggest-list li:hover {
  background: rgba(0,255,208,0.08);
}
.faq-suggest-list a {
  display: block;
  font-weight: 600;
  color: var(--c-text);
  text-decoration: none;
}
.faq-suggest-list small {
  display: block;
  color: var(--c-text-muted);
  font-size: 13px;
  margin-top: 2px;
}

/* ---------- Kategorien-Grid auf /hilfe ---------- */
.help-categories {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.help-category-card {
  display: block;
  position: relative;
  padding: 28px 24px 24px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--c-text);
  transition: transform .25s var(--ease-out), border-color .25s, box-shadow .25s;
  overflow: hidden;
  isolation: isolate;
}
.help-category-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--card-glow, radial-gradient(ellipse 80% 50% at 50% 0%, rgba(0,255,208,0.10) 0%, transparent 60%));
  opacity: 0;
  transition: opacity .3s;
  z-index: -1;
}
.help-category-card:hover {
  transform: translateY(-3px);
  border-color: var(--card-accent, var(--c-accent));
  box-shadow: 0 12px 30px rgba(0,0,0,0.4);
}
.help-category-card:hover::before { opacity: 1; }

.help-category-icon {
  display: block;
  font-size: 14px;
  line-height: 1;
  color: var(--c-accent);
  margin-bottom: 16px;
}

.help-category-card h3 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.help-category-card p {
  font-size: 14px;
  line-height: 1.55;
  color: var(--c-text-dim);
  margin: 0 0 18px;
  min-height: 44px;
}
.help-category-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--c-border);
  font-size: 13px;
}
.help-category-count {
  color: var(--c-text-muted);
  font-weight: 500;
}
.help-category-arrow {
  color: var(--card-accent, var(--c-accent));
  font-weight: 600;
  transition: transform .2s var(--ease-out);
}
.help-category-card:hover .help-category-arrow { transform: translateX(4px); }

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  font-size: 13px;
  color: var(--c-text-muted);
  margin-bottom: 12px;
  letter-spacing: 0.02em;
}
.breadcrumb a {
  color: var(--c-text-dim);
  text-decoration: none;
  transition: color .15s;
}
.breadcrumb a:hover { color: var(--c-accent); }
.breadcrumb strong { color: #fff; font-weight: 500; }

/* ---------- Artikel-Liste auf Kategorie-Seite ---------- */
.help-article-list {
  display: grid;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.help-article-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 18px 22px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: 14px;
  text-decoration: none;
  color: var(--c-text);
  transition: border-color .2s, transform .2s var(--ease-out), background .2s;
}
.help-article-row:hover {
  border-color: var(--c-accent);
  transform: translateX(2px);
  background: rgba(0,255,208,0.03);
}
.help-article-marker {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--c-border-light);
  color: var(--c-text-dim);
  flex-shrink: 0;
}
.help-article-body { min-width: 0; }
.help-article-row h3 {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: -0.005em;
}
.help-article-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--c-text-muted);
}
.help-article-chevron {
  color: var(--c-text-muted);
  font-size: 18px;
  transition: transform .2s var(--ease-out), color .2s;
  flex-shrink: 0;
}
.help-article-row:hover .help-article-chevron {
  color: var(--c-accent);
  transform: translateX(3px);
}

/* Audience-Pill */
.audience-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.audience-pill[data-audience="all"] {
  background: rgba(139,92,246,0.12);
  color: #b89bf8;
  border: 1px solid rgba(139,92,246,0.3);
}
.audience-pill[data-audience="user"] {
  background: rgba(0,255,208,0.10);
  color: var(--c-accent);
  border: 1px solid rgba(0,255,208,0.25);
}
.audience-pill[data-audience="organizer"] {
  background: rgba(255,45,123,0.12);
  color: #ff7ba8;
  border: 1px solid rgba(255,45,123,0.3);
}

/* ---------- Suchergebnis-Seite ---------- */
.help-search-summary {
  font-size: 15px;
  color: var(--c-text-dim);
  margin-bottom: 28px;
}
.help-search-summary strong { color: #fff; }

.help-search-results {
  display: grid;
  gap: 14px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.help-search-result {
  display: block;
  padding: 22px 24px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: 14px;
  text-decoration: none;
  color: var(--c-text);
  transition: border-color .2s, background .2s;
}
.help-search-result:hover {
  border-color: var(--c-accent);
  background: rgba(0,255,208,0.03);
}
.help-search-result h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  margin: 0 0 6px;
}
.help-search-result mark {
  background: rgba(0,255,208,0.18);
  color: var(--c-accent);
  border-radius: 3px;
  padding: 0 3px;
  font-weight: 700;
}
.help-search-result-snippet {
  font-size: 14px;
  line-height: 1.55;
  color: var(--c-text-dim);
  margin: 6px 0 10px;
}
.help-search-result-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--c-text-muted);
}
.help-search-result-cat {
  color: var(--c-accent);
  font-weight: 500;
}

/* Did-you-mean */
.faq-did-you-mean {
  padding: 22px 24px;
  background: linear-gradient(135deg, rgba(251,191,36,0.06) 0%, rgba(251,191,36,0.02) 100%);
  border: 1px solid rgba(251,191,36,0.25);
  border-radius: 14px;
  margin-top: 24px;
}
.faq-did-you-mean p:first-child {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  color: var(--c-gold);
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.faq-did-you-mean p:first-child::before {
  content: '';
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 6px;
  vertical-align: -0.25em;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffd700' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M9 18h6M10 21h4'/><path d='M9 14a5 5 0 1 1 6 0c-1 1-1.5 2-1.5 3h-3c0-1-.5-2-1.5-3z'/></svg>") no-repeat center / contain;
}
.faq-did-you-mean ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.faq-did-you-mean li a {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--c-border);
  border-radius: 8px;
  color: var(--c-text);
  font-size: 14px;
  transition: border-color .15s, background .15s;
}
.faq-did-you-mean li a:hover {
  border-color: var(--c-gold);
  background: rgba(251,191,36,0.06);
}

.help-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--c-text-dim);
}

/* ---------- Artikel-Detail ---------- */
.help-article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 48px;
  align-items: start;
}
@media (max-width: 980px) {
  .help-article-layout { grid-template-columns: 1fr; gap: 28px; }
}

.help-article-main {
  max-width: 760px;
  min-width: 0;
}
.help-article-header { margin-bottom: 28px; }
.help-article-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 4vw, 38px);
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0 0 14px;
}
.help-article-info {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  color: var(--c-text-muted);
  flex-wrap: wrap;
}
.help-article-info::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--c-border-light);
}

.help-article-content {
  font-size: 16px;
  line-height: 1.75;
  color: var(--c-text);
}
.help-article-content > *:first-child { margin-top: 0; }
.help-article-content p { margin: 0 0 18px; }
.help-article-content h2,
.help-article-content h3 {
  font-family: var(--font-display);
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.01em;
  margin: 32px 0 14px;
  scroll-margin-top: 100px;
}
.help-article-content h2 { font-size: 24px; }
.help-article-content h3 {
  font-size: 19px;
  position: relative;
  padding-left: 16px;
}
.help-article-content h3::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.45em;
  bottom: 0.45em;
  width: 3px;
  background: linear-gradient(180deg, var(--c-accent) 0%, var(--c-violet) 100%);
  border-radius: 2px;
}
.help-article-content ul,
.help-article-content ol {
  margin: 0 0 18px;
  padding-left: 22px;
}
.help-article-content ul { list-style: none; padding-left: 0; }
.help-article-content ul li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 8px;
}
.help-article-content ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  background: var(--c-accent);
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(0,255,208,0.4);
}
.help-article-content ol li { margin-bottom: 8px; }
.help-article-content a {
  color: var(--c-accent);
  text-decoration: none;
  border-bottom: 1px solid rgba(0,255,208,0.3);
  transition: border-color .15s, color .15s;
}
.help-article-content a:hover {
  color: #fff;
  border-bottom-color: var(--c-accent);
}
.help-article-content code {
  background: rgba(0,255,208,0.08);
  color: var(--c-accent);
  padding: 2px 7px;
  border-radius: 4px;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 0.92em;
}
.help-article-content pre {
  background: var(--c-deep);
  border: 1px solid var(--c-border-light);
  border-radius: 10px;
  padding: 16px 18px;
  margin: 16px 0;
  overflow-x: auto;
}
.help-article-content pre code { background: none; padding: 0; color: var(--c-text); }
.help-article-content blockquote {
  border-left: 3px solid var(--c-violet);
  padding: 4px 0 4px 18px;
  margin: 16px 0;
  color: var(--c-text-dim);
  font-style: italic;
}
.help-article-content strong { color: #fff; font-weight: 600; }

/* ---------- Sidebar (TOC + Feedback + Related) ---------- */
.help-article-sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 100px;
}
@media (max-width: 980px) {
  .help-article-sidebar { position: static; }
}

.help-sidebar-card {
  padding: 22px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: 16px;
}
.help-sidebar-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--c-text-muted);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.help-sidebar-title::before {
  content: '';
  width: 16px;
  height: 1px;
  background: var(--c-accent);
}

/* TOC */
.faq-toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: toc;
}
.faq-toc ol li {
  counter-increment: toc;
  margin-bottom: 4px;
}
.faq-toc ol li a {
  display: block;
  padding: 8px 12px 8px 32px;
  position: relative;
  color: var(--c-text-dim);
  text-decoration: none;
  font-size: 14px;
  border-radius: 8px;
  transition: background .15s, color .15s;
}
.faq-toc ol li a::before {
  content: counter(toc);
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  font-size: 10px;
  font-weight: 700;
  color: var(--c-text-muted);
  text-align: center;
  line-height: 16px;
  font-family: var(--font-display);
}
.faq-toc ol li a:hover {
  background: rgba(0,255,208,0.06);
  color: var(--c-accent);
}
.faq-toc ol li a:hover::before {
  background: var(--c-accent);
  color: #06060f;
}

/* Feedback */
.faq-feedback p:first-child {
  font-family: var(--font-display);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  margin: 0 0 14px;
}
.faq-feedback-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  margin-right: 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--c-border-light);
  border-radius: 10px;
  color: var(--c-text);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color .15s, background .15s, transform .15s var(--ease-out);
}
.faq-feedback-btn:last-child { margin-right: 0; }
.faq-feedback-btn:hover:not(:disabled) {
  border-color: var(--c-accent);
  background: rgba(0,255,208,0.08);
  transform: translateY(-1px);
}
.faq-feedback-btn[data-vote="0"]:hover:not(:disabled) {
  border-color: var(--c-magenta);
  background: rgba(255,45,123,0.08);
}
.faq-feedback-btn.faq-feedback-active {
  background: var(--c-accent-dim);
  border-color: var(--c-accent);
  color: var(--c-accent);
}
.faq-feedback-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.faq-feedback-thanks {
  margin-top: 14px;
  padding: 10px 14px;
  background: rgba(52,211,153,0.08);
  border: 1px solid rgba(52,211,153,0.25);
  border-radius: 8px;
  color: var(--c-success);
  font-size: 14px;
}

/* Related */
.faq-related ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.faq-related li {
  border-bottom: 1px solid var(--c-border);
}
.faq-related li:last-child { border-bottom: none; }
.faq-related li a {
  display: block;
  padding: 10px 0;
  font-size: 14px;
  line-height: 1.4;
  color: var(--c-text-dim);
  text-decoration: none;
  transition: color .15s, padding-left .2s var(--ease-out);
}
.faq-related li a::before {
  content: '→';
  display: inline-block;
  margin-right: 8px;
  color: var(--c-text-muted);
  transition: color .15s, transform .2s var(--ease-out);
}
.faq-related li a:hover {
  color: var(--c-accent);
  padding-left: 4px;
}
.faq-related li a:hover::before {
  color: var(--c-accent);
  transform: translateX(2px);
}

/* Back-Link */
.help-back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 32px;
  padding: 8px 0;
  color: var(--c-text-muted);
  font-size: 14px;
  text-decoration: none;
  transition: color .15s, transform .15s var(--ease-out);
}
.help-back-link:hover { color: var(--c-accent); transform: translateX(-2px); }

/* Visually hidden */
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
  .help-search-form { flex-direction: column; }
  .help-search-form .btn { width: 100%; }
  .help-categories { grid-template-columns: 1fr; }
  .help-hero-stats { flex-wrap: wrap; gap: 16px; }
  .help-article-row { grid-template-columns: 1fr auto; }
  .help-article-marker { display: none; }
}
