/* Help module (W-help): help centre, FAQ, contact, Ratgeber, legal pages, cookie settings. Tokens only. */
@layer modules {
  /* ---- Search ---------------------------------------------------------- */
  .mm-help-search { display: flex; flex-direction: column; gap: var(--mm-space-3); }
  .mm-help-search__title { font-size: var(--mm-text-lg); }
  .mm-help-search__form { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--mm-space-3); align-items: end; }
  @media (min-width: 48em) { .mm-help-search__form { grid-template-columns: minmax(0, 1fr) auto; } }
  .mm-help-search__form .mm-field { min-width: 0; }

  /* ---- Audience tabs (segmented links) --------------------------------- */
  .mm-help-audience .mm-segmented { flex-wrap: wrap; max-width: 100%; border-radius: var(--mm-radius-md); }

  /* ---- Topic cards ----------------------------------------------------- */
  .mm-help-topic { display: flex; flex-direction: column; gap: var(--mm-space-3); }
  .mm-help-topic__title { display: flex; align-items: center; gap: var(--mm-space-2); font-size: var(--mm-text-lg); }
  .mm-help-topic__icon { flex: none; color: var(--mm-color-brand); }
  .mm-help-topic__desc { color: var(--mm-color-ink-muted); font-size: var(--mm-text-sm); }
  .mm-help-topic__links { display: flex; flex-direction: column; gap: var(--mm-space-2); padding: 0; list-style: none; }
  .mm-help-topic__all { margin-top: auto; font-weight: 600; }

  /* ---- Article lists --------------------------------------------------- */
  .mm-help-list { display: flex; flex-direction: column; padding: 0; list-style: none; border-top: 1px solid var(--mm-color-border); }
  .mm-help-list__item { display: flex; flex-direction: column; gap: var(--mm-space-1); padding-block: var(--mm-space-4); border-bottom: 1px solid var(--mm-color-border); }
  .mm-help-list__title { font-size: var(--mm-text-base); }
  .mm-help-list__summary { color: var(--mm-color-ink-muted); }
  .mm-help-list__meta { color: var(--mm-color-ink-muted); font-size: var(--mm-text-sm); }
  .mm-help-related { display: flex; flex-direction: column; gap: var(--mm-space-2); padding: 0; list-style: none; }
  .mm-card__title + .mm-help-related { margin-top: var(--mm-space-3); }

  /* ---- Article page ---------------------------------------------------- */
  .mm-help-meta { display: flex; flex-wrap: wrap; gap: var(--mm-space-2) var(--mm-space-6); color: var(--mm-color-ink-muted); font-size: var(--mm-text-sm); }
  .mm-help-meta > div { display: flex; flex-wrap: wrap; align-items: center; gap: var(--mm-space-1); }
  .mm-help-meta dt { font-weight: 700; color: var(--mm-color-ink); }
  .mm-help-meta dt::after { content: ":"; }

  .mm-help-toc { padding: var(--mm-space-4) var(--mm-space-5); border: 1px solid var(--mm-color-border); border-radius: var(--mm-radius-md); background: var(--mm-color-surface); }
  .mm-help-toc__title { margin-bottom: var(--mm-space-2); font-weight: 700; }
  .mm-help-toc__list { display: flex; flex-direction: column; gap: var(--mm-space-1); padding-inline-start: 1.25em; }

  .mm-help-prose { overflow-wrap: anywhere; hyphens: auto; }
  .mm-help-prose :is(h2, h3) { scroll-margin-top: calc(var(--mm-header-height) + var(--mm-space-4)); }
  .mm-help-prose table { display: block; max-width: 100%; overflow-x: auto; }
  .mm-help-prose code { overflow-wrap: anywhere; }

  /* ---- FAQ accordions (<details>) -------------------------------------- */
  .mm-help-faq { scroll-margin-top: calc(var(--mm-header-height) + var(--mm-space-4)); }
  .mm-help-faq__item { border: 1px solid var(--mm-color-border); border-radius: var(--mm-radius-md); background: var(--mm-color-surface); }
  .mm-help-faq__item[open] { border-color: var(--mm-color-brand-tint-border); box-shadow: var(--mm-shadow-sm); }
  .mm-help-faq__question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--mm-space-3);
    min-height: var(--mm-control-height);
    padding: var(--mm-space-3) var(--mm-space-4);
    font-weight: 700;
    cursor: pointer;
    list-style: none;
    border-radius: var(--mm-radius-md);
  }
  .mm-help-faq__question::-webkit-details-marker { display: none; }
  .mm-help-faq__question:hover { color: var(--mm-color-brand-hover); }
  .mm-help-faq__question:focus-visible { outline: var(--mm-focus-width) solid var(--mm-color-focus); outline-offset: var(--mm-focus-offset); }
  .mm-help-faq__chevron { flex: none; transition: transform var(--mm-duration-base) var(--mm-ease); }
  .mm-help-faq__item[open] .mm-help-faq__chevron { transform: rotate(180deg); }
  .mm-help-faq__answer { padding: 0 var(--mm-space-4) var(--mm-space-4); max-width: none; }

  /* ---- Feedback -------------------------------------------------------- */
  .mm-help-feedback { display: flex; flex-direction: column; gap: var(--mm-space-3); padding: var(--mm-space-5); border-radius: var(--mm-radius-md); background: var(--mm-color-brand-tint); }
  .mm-help-feedback__title { font-size: var(--mm-text-lg); }
  .mm-help-feedback__status { display: flex; align-items: flex-start; gap: var(--mm-space-2); font-weight: 600; }
  .mm-help-feedback__status:empty { display: none; }

  /* ---- Emergency + CTA ------------------------------------------------- */
  .mm-help-emergency__call { display: inline-flex; align-items: center; gap: var(--mm-space-1); font-weight: 700; }
  .mm-help-support { align-items: start; }

  /* ---- Contact form ---------------------------------------------------- */
  .mm-help-hp { display: none; }

  /* ---- Ratgeber -------------------------------------------------------- */
  .mm-help-posts { padding: 0; list-style: none; }
  .mm-help-post { position: relative; display: flex; flex-direction: column; gap: var(--mm-space-2); }
  .mm-help-post__category { color: var(--mm-color-brand); font-size: var(--mm-text-sm); font-weight: 700; }
  .mm-help-post__title { font-size: var(--mm-text-lg); }
  .mm-help-post__excerpt { color: var(--mm-color-ink-muted); }
  .mm-help-post__meta { margin-top: auto; color: var(--mm-color-ink-muted); font-size: var(--mm-text-sm); }

  /* ---- Cookie settings ------------------------------------------------- */
  .mm-help-cookie-category { display: flex; flex-direction: column; gap: var(--mm-space-3); }
  .mm-help-cookie-list { display: flex; flex-direction: column; gap: var(--mm-space-2); padding-inline-start: 1.25em; font-size: var(--mm-text-sm); }
  .mm-help-cookie-list code { overflow-wrap: anywhere; }
}
