/*
 * AnimeRadar V2.4.335 - Unterstuetzung ueber Buy Me a Coffee.
 *
 * Ein normaler externer Link in AnimeRadar-Optik, kein Widget, kein iframe,
 * kein Fremdskript. Nur im Web; in der nativen App entfernt
 * renderSupportLinks (app-v2-4-153.js) beide Flaechen. Zwei Flaechen:
 *
 * 1. Desktop-Sidebar: kompakte Karte im unteren Account-Block, direkt ueber
 *    den Benachrichtigungen. Sichtbar unter derselben Bedingung wie der
 *    Block selbst (ab 960 px, nicht .native-app) und nie in der App-Huelle
 *    (html.capacitor-shell setzt capacitor-runtime.js schon im Kopf, also
 *    vor dem ersten Bild); sonst ausgeblendet.
 * 2. Mehr-Sheet (mobiles Web): eigener Bereich am Ende des Sheets, durch eine
 *    Linie von der Navigation getrennt.
 *
 * Masse und Farben aus den Nachbarn: Logout/Premium-Card (Flaeche, Rand,
 * Radius) in der Sidebar, Eintraege und Rahmen des Sheets im Sheet.
 */

/* ------------------------------------------------------------------------ */
/* 1. Desktop-Sidebar                                                        */
/* ------------------------------------------------------------------------ */

html body .sidebar-support-card {
  display: none;
}

@media (min-width: 960px) {
  /* Die Fussbreite betraegt 165 px. Titel 11 px und Unterzeile 10 px passen
     darin ohne Kuerzung; ein Hinweis auf externe Navigation haette keinen
     Platz mehr und entfaellt hier (im Sheet ist er vorhanden). */
  html:not(.native-app):not(.capacitor-shell) body .topbar .sidebar-support-card {
    width: 100%;
    min-width: 0;
    min-height: 40px;
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 7px;
    padding: 5px 6px 5px 7px;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--md-primary) 26%, var(--sidebar-account-line));
    border-radius: var(--sidebar-account-radius);
    background:
      linear-gradient(135deg, color-mix(in srgb, var(--md-primary) 10%, transparent), transparent 64%),
      var(--sidebar-account-surface);
    color: var(--md-on-surface);
    text-decoration: none;
    cursor: pointer;
    transition: border-color .16s ease, background .16s ease;
  }

  html:not(.native-app) body .topbar .sidebar-support-icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    display: grid;
    place-items: center;
    color: var(--md-primary);
  }

  html:not(.native-app) body .topbar .sidebar-support-icon svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  html:not(.native-app) body .topbar .sidebar-support-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  html:not(.native-app) body .topbar .sidebar-support-copy strong,
  html:not(.native-app) body .topbar .sidebar-support-copy small {
    overflow: hidden;
    font-family: var(--font-body);
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  html:not(.native-app) body .topbar .sidebar-support-copy strong {
    color: var(--md-on-surface);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: -.005em;
    line-height: 1.15;
  }

  html:not(.native-app) body .topbar .sidebar-support-copy small {
    color: var(--md-muted);
    font-size: 10px;
    font-weight: 500;
    line-height: 1.2;
  }

  html:not(.native-app) body .topbar .sidebar-support-card:hover {
    border-color: color-mix(in srgb, var(--md-primary) 46%, var(--sidebar-account-line));
    background:
      linear-gradient(135deg, color-mix(in srgb, var(--md-primary) 14%, transparent), transparent 64%),
      color-mix(in srgb, var(--md-primary) 8%, var(--sidebar-account-surface));
  }

  html:not(.native-app) body .topbar .sidebar-support-card:focus-visible {
    outline: 2px solid var(--md-primary);
    outline-offset: 2px;
  }
}

/* ------------------------------------------------------------------------ */
/* 2. Mehr-Sheet                                                             */
/* ------------------------------------------------------------------------ */

html body .more-sheet-support {
  margin: 8px 0 0;
  padding: 10px 0 0;
  border-top: 1px solid rgba(var(--ar-nav-red-bright, 255, 74, 90), .16);
}

/* Trefferflaeche hoeher als die 48 px der Eintraege, weil zwei Zeilen. */
html body .more-sheet-support-link {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 9px 12px;
  border: 1px solid rgba(var(--ar-nav-red-bright, 255, 74, 90), .26);
  border-radius: var(--ar-nav-item-radius, 14px);
  background:
    linear-gradient(135deg, rgba(var(--ar-nav-red, 226, 38, 55), .15), rgba(var(--ar-nav-red, 226, 38, 55), .04) 64%);
  color: #eef2f4;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .16s ease, border-color .16s ease;
}

html body .more-sheet-support-icon,
html body .more-sheet-support-external {
  display: grid;
  place-items: center;
}

html body .more-sheet-support-icon {
  width: 21px;
  height: 21px;
  flex: 0 0 21px;
  color: rgb(var(--ar-nav-red-bright, 255, 74, 90));
}

html body .more-sheet-support-external {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  margin-left: auto;
  color: #8a939a;
}

html body .more-sheet-support-icon svg,
html body .more-sheet-support-external svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

html body .more-sheet-support-copy {
  min-width: 0;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 3px;
}

html body .more-sheet-support-copy strong,
html body .more-sheet-support-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html body .more-sheet-support-copy strong {
  color: #f1f4f6;
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.2;
}

html body .more-sheet-support-copy small {
  color: #9aa3aa;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.25;
}

html body .more-sheet-support-link:hover,
html body .more-sheet-support-link:focus-visible {
  border-color: rgba(var(--ar-nav-red-bright, 255, 74, 90), .42);
  background:
    linear-gradient(135deg, rgba(var(--ar-nav-red, 226, 38, 55), .22), rgba(var(--ar-nav-red, 226, 38, 55), .08) 64%);
}

html body .more-sheet-support-link:focus-visible {
  outline: 2px solid rgb(var(--ar-nav-red-bright, 255, 74, 90));
  outline-offset: 2px;
}

html body .more-sheet-support-link:active {
  border-color: rgba(var(--ar-nav-red-bright, 255, 74, 90), .48);
  background:
    linear-gradient(135deg, rgba(var(--ar-nav-red, 226, 38, 55), .26), rgba(var(--ar-nav-red, 226, 38, 55), .12) 64%);
}
