:root {
  --bg: #f4f6fb;
  --card: #ffffff;
  --ink: #1f2933;
  --muted: #6b7280;
  --line: #e5e9f0;
  --brand: #2563eb;
  --brand-dark: #1d4ed8;
  --green: #16a34a;
  --yellow: #d97706;
  --red: #dc2626;
  --shadow: 0 1px 3px rgba(16, 24, 40, 0.08), 0 1px 2px rgba(16, 24, 40, 0.06);
  --radius: 14px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
}

/* ---------- Topbar ---------- */
.topbar {
  background: linear-gradient(135deg, #2563eb, #1e40af);
  color: #fff;
  padding: 22px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}
.logo {
  font-size: 34px;
  line-height: 1;
}
.topbar h1 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -0.01em;
}
.subtitle {
  margin: 2px 0 0;
  font-size: 13px;
  opacity: 0.85;
}
.ai-status {
  font-size: 13px;
  background: rgba(255, 255, 255, 0.15);
  padding: 7px 14px;
  border-radius: 999px;
}

/* ---------- Layout ---------- */
.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 28px 20px 60px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px;
}
.add-card {
  margin-bottom: 32px;
}
.add-card h2,
.section-head h2 {
  margin: 0 0 16px;
  font-size: 17px;
}

/* ---------- Formular ---------- */
.add-form {
  display: flex;
  gap: 14px;
  align-items: flex-end;
  flex-wrap: wrap;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1 1 200px;
}
.field.small {
  flex: 0 0 110px;
}
.field label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.field input,
.field select {
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 15px;
  background: #fff;
  transition: border-color 0.15s;
}
.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--brand);
}
.btn {
  border: none;
  border-radius: 10px;
  padding: 11px 18px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.05s;
}
.btn:active {
  transform: translateY(1px);
}
.btn.primary {
  background: var(--brand);
  color: #fff;
}
.btn.primary:hover {
  background: var(--brand-dark);
}
.btn.ghost {
  background: #f1f5f9;
  color: var(--ink);
}
.btn.ghost:hover {
  background: #e2e8f0;
}
.btn.danger {
  background: #fef2f2;
  color: var(--red);
}
.btn.danger:hover {
  background: #fee2e2;
}
.btn.small {
  padding: 8px 12px;
  font-size: 13px;
}
.error-msg {
  color: var(--red);
  font-size: 13px;
  margin: 12px 0 0;
  min-height: 1px;
}

/* ---------- Sektion ---------- */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 14px;
}
.auto-note {
  font-size: 12px;
  color: var(--muted);
}

/* ---------- Projektkarten ---------- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 18px;
}
.empty {
  color: var(--muted);
  font-size: 14px;
}
.project {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.project-top {
  display: flex;
  gap: 14px;
  align-items: center;
}
.score-ring {
  flex: 0 0 64px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 18px;
  color: #fff;
}
.score-ring.gray {
  background: #cbd5e1;
}
.score-ring.green {
  background: var(--green);
}
.score-ring.yellow {
  background: var(--yellow);
}
.score-ring.red {
  background: var(--red);
}
.project-meta {
  min-width: 0;
}
.project-name {
  font-weight: 700;
  font-size: 16px;
  margin: 0;
}
.project-url {
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
  word-break: break-all;
}
.project-url:hover {
  color: var(--brand);
}
.project-status {
  font-size: 12px;
  margin-top: 4px;
}
.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 5px;
  vertical-align: middle;
}
.dot.ok {
  background: var(--green);
}
.dot.laeuft {
  background: var(--brand);
  animation: pulse 1s infinite;
}
.dot.fehler {
  background: var(--red);
}
.dot.neu {
  background: #cbd5e1;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}
.project-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ---------- Modal ---------- */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 50;
}
.modal.hidden {
  display: none;
}
.modal-box {
  background: #fff;
  border-radius: 16px;
  max-width: 760px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  padding: 28px;
  position: relative;
}
.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  border: none;
  background: #f1f5f9;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 15px;
}
.modal-close:hover {
  background: #e2e8f0;
}

/* ---------- Bericht-Inhalt ---------- */
.report-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 8px;
}
.report-head h2 {
  margin: 0;
  font-size: 20px;
}
.page-block {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  margin-top: 16px;
}
.page-block h3 {
  margin: 0 0 6px;
  font-size: 14px;
  word-break: break-all;
}
.page-block h3 a {
  color: var(--brand);
  text-decoration: none;
}
.issues {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
}
.issues li {
  font-size: 13px;
  padding: 4px 0;
  border-top: 1px solid var(--line);
}
.ai-box {
  background: #f0f7ff;
  border: 1px solid #d6e6ff;
  border-radius: 10px;
  padding: 14px;
  margin-top: 14px;
  font-size: 13px;
}
.ai-box h4 {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--brand-dark);
}
.ai-box .label {
  font-weight: 600;
}
.ai-box ul {
  margin: 6px 0 0;
  padding-left: 18px;
}
.tag {
  display: inline-block;
  background: #e0ecff;
  color: var(--brand-dark);
  border-radius: 6px;
  padding: 2px 8px;
  font-size: 12px;
  margin: 2px 4px 2px 0;
}
.loading {
  text-align: center;
  color: var(--muted);
  padding: 40px;
}

/* ---------- Diagramme ---------- */
.spark {
  width: 100%;
  height: 34px;
  display: block;
}
.history-section {
  margin-top: 18px;
}
.history-title {
  margin: 0 0 8px;
  font-size: 14px;
}
.chart-wrap {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fcfdff;
}
.history-chart {
  width: 100%;
  height: auto;
  display: block;
}

.footer {
  text-align: center;
  color: var(--muted);
  font-size: 12px;
  padding: 30px;
}

@media (max-width: 560px) {
  .add-form {
    flex-direction: column;
    align-items: stretch;
  }
  .field.small {
    flex: 1;
  }
}

/* ---------- Einstellungen (Keywords & FTP) ---------- */
.settings-panel {
  margin: 16px 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fafbfe;
}
.settings-panel > summary {
  cursor: pointer;
  padding: 12px 16px;
  font-weight: 600;
  list-style: none;
}
.settings-panel > summary::-webkit-details-marker { display: none; }
.settings-body { padding: 4px 16px 16px; }
.settings-body hr { border: none; border-top: 1px solid var(--line); margin: 14px 0; }
.settings-body .field { margin-bottom: 8px; }
.settings-body label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.settings-body input,
.settings-body select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
}
.ftp-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.ftp-grid label { font-weight: 500; }
.ftp-actions { display: flex; align-items: center; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.hint { font-size: 12.5px; color: var(--muted); }

/* ---------- Vorschläge (Vorher/Nachher) ---------- */
.prop-section { margin-top: 14px; }
.proposal {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  background: #fff;
}
.proposal.applied { background: #f0fdf4; border-color: #bbf7d0; }
.proposal .ok-line { color: var(--green); font-weight: 600; margin: 0 0 8px; }
.change {
  border-top: 1px solid var(--line);
  padding: 12px 0;
}
.change:first-of-type { border-top: none; }
.change-head { display: flex; align-items: center; gap: 8px; cursor: pointer; margin-bottom: 8px; }
.change-head input { width: 18px; height: 18px; }
.change-label { font-weight: 600; font-size: 14px; }
.change-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.col {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 13.5px;
  background: #fafbfe;
  overflow-wrap: anywhere;
}
.col-tag {
  display: inline-block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--muted);
  margin-bottom: 4px;
}
.col.before .col-tag { color: var(--red); }
.col.after .col-tag { color: var(--green); }
.col-text del { background: #fee2e2; color: #991b1b; text-decoration: line-through; }
.col-text ins { background: #dcfce7; color: #166534; text-decoration: none; }
.proposal-actions { display: flex; align-items: center; gap: 10px; margin-top: 12px; flex-wrap: wrap; }

@media (max-width: 560px) {
  .ftp-grid { grid-template-columns: 1fr; }
  .change-cols { grid-template-columns: 1fr; }
}

/* ---------- Rankings & Konkurrenz ---------- */
.rank-list { margin-top: 12px; }
.rank-row { border-top: 1px solid var(--line); padding: 10px 0; }
.rank-row:first-child { border-top: none; }
.rank-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rank-kw { font-weight: 600; flex: 1 1 auto; }
.rank-pos { font-size: 13.5px; color: var(--ink); }
.comp-box:not(:empty) { margin-top: 10px; }
.comp-result {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  background: #fafbfe;
}
.comp-table { width: 100%; border-collapse: collapse; font-size: 13px; margin-bottom: 8px; }
.comp-table th, .comp-table td {
  text-align: left; padding: 5px 6px; border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.comp-table th { color: var(--muted); font-weight: 600; }
.comp-summary { font-size: 14px; margin: 8px 0; }

/* ---------- Keyword-Recherche & KI-Sichtbarkeit ---------- */
.research-result { margin-top: 12px; }
.kw-cands { display: flex; flex-direction: column; gap: 4px; margin: 8px 0 12px; }
.kw-cand {
  display: grid;
  grid-template-columns: 22px 1fr;
  grid-template-areas: "chk main" ". tags" ". why";
  gap: 2px 8px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fafbfe;
  cursor: pointer;
}
.kw-cand input { grid-area: chk; width: 18px; height: 18px; }
.kw-main { grid-area: main; font-weight: 600; }
.kw-tags { grid-area: tags; font-size: 12px; color: var(--brand); }
.kw-why { grid-area: why; font-size: 12.5px; color: var(--muted); }
.aivis-q { border-top: 1px solid var(--line); padding: 8px 0; }
.aivis-q:first-child { border-top: none; }
.aivis-line { font-size: 14px; }

/* ---------- Ziel-Keywords pro Seite ---------- */
.page-kw {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px dashed var(--line);
  border-radius: 10px;
  background: #fafbfe;
}
.page-kw-label { display: block; font-weight: 600; font-size: 13.5px; margin-bottom: 6px; }
.page-kw-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.page-kw-input {
  flex: 1 1 220px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
}
.page-kw-suggest:not(:empty) { margin-top: 10px; }

/* ---------- Seiten-Übersicht & Status ---------- */
.page-nav {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  margin: 16px 0;
  background: #fff;
}
.page-nav-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.page-nav ul { list-style: none; margin: 10px 0 0; padding: 0; }
.page-nav li { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line); }
.page-nav li:first-child { border-top: none; }
.page-nav-link {
  flex: 1 1 auto; text-align: left; background: none; border: none; cursor: pointer;
  color: var(--brand); font-size: 14px; padding: 2px 0; overflow-wrap: anywhere;
}
.nav-score { width: 30px; height: 30px; font-size: 12px; flex: 0 0 auto; }
.pbadge { font-size: 11.5px; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.pbadge.ok { background: #dcfce7; color: #166534; }
.pbadge.ready { background: #dbeafe; color: #1e40af; }
.pbadge.none { background: #f1f5f9; color: #94a3b8; }
.page-block-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.page-block-head h3 { margin: 0; flex: 1 1 auto; font-size: 15px; overflow-wrap: anywhere; }
.page-block { scroll-margin-top: 12px; }

/* ---------- Passwort-Auge ---------- */
.pw-wrap, .dir-wrap { position: relative; display: flex; gap: 6px; align-items: center; }
.pw-wrap input { width: 100%; padding-right: 40px; }
.pw-eye {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; font-size: 18px; line-height: 1; padding: 4px;
}
.dir-wrap input { flex: 1 1 auto; }
.dir-wrap .btn { flex: 0 0 auto; white-space: nowrap; }

/* ---------- Verzeichnis-Browser ---------- */
.dir-browser {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 10px 12px;
  margin: 4px 0 12px;
}
.dir-browser.hidden { display: none; }
.dir-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.dir-head-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.dir-list { display: flex; flex-direction: column; gap: 2px; max-height: 260px; overflow-y: auto; }
.dir-item {
  text-align: left; background: #fafbfe; border: 1px solid var(--line);
  border-radius: 8px; padding: 9px 11px; cursor: pointer; font-size: 14px;
}
.dir-item:hover { background: #eef2ff; }
.dir-item.up { color: var(--muted); }

/* ---------- Verzeichnis-Browser: Dateien ---------- */
.dir-file {
  display: block; padding: 7px 11px; font-size: 13.5px; color: var(--muted);
  border: 1px dashed var(--line); border-radius: 8px; background: #fff;
}
.dir-file.idx { color: #166534; font-weight: 600; background: #f0fdf4; border-style: solid; border-color: #bbf7d0; }

/* ---------- Vorschlag bearbeiten / neu erzeugen ---------- */
.after-edit {
  width: 100%;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 13.5px;
  font-family: inherit;
  background: #f0fdf4;
  color: #14532d;
  resize: vertical;
  line-height: 1.45;
}
.after-edit:focus { outline: 2px solid #86efac; border-color: #86efac; }
.char-count { font-weight: 400; color: var(--muted); text-transform: none; letter-spacing: 0; }
.change-tools { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.regen-instr {
  flex: 1 1 180px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 13px;
}

/* ---------- Seiten-Übersicht: Buttons ---------- */
.page-nav-buttons { display: flex; gap: 6px; flex-wrap: wrap; }

/* ---------- Duplikate-Prüfung ---------- */
.pbadge.warn { background: #fef3c7; color: #92400e; }
.pbadge.danger { background: #fee2e2; color: #991b1b; }
.dup-panel > summary { color: #991b1b; }
.dup-list { list-style: none; margin: 8px 0; padding: 0; }
.dup-pair { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line); }
.dup-pair:first-child { border-top: none; }
.dup-names { font-size: 13.5px; overflow-wrap: anywhere; }
.dup-warn {
  background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412;
  border-radius: 8px; padding: 8px 10px; font-size: 13px; margin: 8px 0 0;
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
}

/* ---------- Business-Profil / Google-Sichtbarkeit ---------- */
.biz-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 10px 0; }
.biz-grid label { display: flex; flex-direction: column; font-size: 12.5px; color: var(--muted); gap: 3px; }
.biz-grid input { padding: 7px 9px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; color: var(--ink); }
.gbp-item { border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; margin: 6px 0; background: #fafbfe; }
.gbp-item-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.gbp-text { font-size: 13.5px; white-space: pre-wrap; overflow-wrap: anywhere; }
@media (max-width: 560px) { .biz-grid { grid-template-columns: 1fr; } }

/* ---------- Automatische Prüfung ---------- */
.monitor-row { margin: 14px 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #fafbfe; }
.monitor-label { font-weight: 600; font-size: 14px; display: block; margin-bottom: 4px; }
.monitor-row select { margin-left: 6px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; }

/* ---------- Webspace-Verbindungsstatus ---------- */
.deploy-status { border-radius: 10px; padding: 10px 12px; margin: 14px 0; font-size: 13.5px; }
.deploy-status.ok { background: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; }
.deploy-status.off { background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412; }

/* ---------- Anmeldung ---------- */
.topbar-right{display:flex;align-items:center;gap:14px;flex-wrap:wrap}
.user-box{display:flex;align-items:center;gap:10px}
.user-email{color:#fff;font-size:13px;opacity:.95;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.user-box.hidden{display:none}
.auth-overlay{position:fixed;inset:0;z-index:1000;background:var(--bg);display:flex;align-items:center;justify-content:center;padding:20px}
.auth-overlay.hidden{display:none}
.auth-card{width:100%;max-width:380px;background:var(--card);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow);padding:26px 24px}
.auth-brand{font-size:20px;margin-bottom:16px;display:flex;align-items:center;gap:8px}
.auth-brand .logo{font-size:26px}
.auth-tabs{display:flex;gap:6px;background:#f1f5f9;border-radius:10px;padding:4px;margin-bottom:16px}
.auth-tab{flex:1;border:none;background:none;padding:9px;border-radius:8px;cursor:pointer;font-size:14px;font-weight:600;color:var(--muted)}
.auth-tab.active{background:#fff;color:var(--ink);box-shadow:var(--shadow)}
.auth-form{display:flex;flex-direction:column;gap:12px}
.auth-form label{display:flex;flex-direction:column;gap:5px;font-size:13px;color:var(--muted);font-weight:600}
.auth-form input{padding:11px 12px;border:1px solid var(--line);border-radius:10px;font-size:15px;color:var(--ink)}
.auth-hint{margin:14px 0 0;font-size:12.5px;color:var(--muted);text-align:center}

/* ---------- Globale „arbeitet…"-Anzeige ---------- */
.busy{
  position:fixed;left:50%;bottom:20px;transform:translateX(-50%);z-index:1200;
  display:flex;align-items:center;gap:10px;background:var(--ink);color:#fff;
  padding:10px 16px;border-radius:999px;font-size:14px;font-weight:600;
  box-shadow:0 6px 24px rgba(16,24,40,.28);
}
.busy.hidden{display:none}
.spinner{
  width:16px;height:16px;border-radius:50%;
  border:2.5px solid rgba(255,255,255,.35);border-top-color:#fff;
  animation:spin .7s linear infinite;flex:0 0 auto;
}
@keyframes spin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){ .spinner{animation-duration:1.6s} }

/* ---------- Technische Fix-Karten ---------- */
.change.tech{background:#f5f8ff;border:1px solid #dbe4ff;border-radius:10px;padding:10px 12px;margin-top:8px}
.change.tech .change-head{margin-bottom:2px}
.tech-desc{font-size:13px;color:var(--muted);padding-left:26px;overflow-wrap:anywhere}
.tech-desc b{color:var(--ink)}

/* ---------- Bericht: Aktionen ---------- */
.report-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:12px 0 4px}

/* ---------- Hilfe-Center ---------- */
.help-btn{
  position:fixed;right:18px;bottom:18px;z-index:1300;width:52px;height:52px;border-radius:50%;
  background:var(--brand);color:#fff;border:none;font-size:26px;font-weight:700;cursor:pointer;
  box-shadow:0 6px 20px rgba(37,99,235,.4);
}
.help-btn.hidden{display:none}
.help-panel{
  position:fixed;right:18px;bottom:80px;z-index:1300;width:min(360px,92vw);max-height:70vh;
  background:var(--card);border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);
  display:flex;flex-direction:column;overflow:hidden;
}
.help-panel.hidden{display:none}
.help-head{display:flex;align-items:center;justify-content:space-between;padding:14px 16px;border-bottom:1px solid var(--line);font-size:15px}
.help-close{background:none;border:none;font-size:18px;cursor:pointer;color:var(--muted)}
.help-search{margin:12px 16px 4px;padding:10px 12px;border:1px solid var(--line);border-radius:10px;font-size:14px}
.help-list{overflow-y:auto;padding:6px 10px 12px}
.help-item{border-top:1px solid var(--line)}
.help-item:first-child{border-top:none}
.help-q{width:100%;text-align:left;background:none;border:none;padding:11px 8px;font-size:14px;font-weight:600;color:var(--ink);cursor:pointer}
.help-q:hover{color:var(--brand)}
.help-a{padding:0 8px 12px}
.help-a.hidden{display:none}
.help-a p{font-size:13.5px;color:var(--muted);margin:0 0 8px}
.help-flash{outline:3px solid var(--brand);outline-offset:2px;border-radius:12px;transition:outline-color .3s}

/* ---------- Tarif-Anzeige ---------- */
.user-plan{background:rgba(255,255,255,.18);color:#fff;font-size:12px;font-weight:600;padding:4px 10px;border-radius:999px;white-space:nowrap}

/* ---------- Owner: Kunden-Panel ---------- */
.admin-table{width:100%;border-collapse:collapse;font-size:14px;margin-top:8px}
.admin-table th,.admin-table td{text-align:left;padding:9px 10px;border-bottom:1px solid var(--line);white-space:nowrap}
.admin-table th{font-size:12px;text-transform:uppercase;letter-spacing:.04em;color:var(--muted)}
.admin-table select{padding:6px 8px;border:1px solid var(--line);border-radius:8px;font-size:14px}

/* ---------- Tarife / Upgrade ---------- */
.user-plan{cursor:pointer}
.bill-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-top:10px}
.bill-card{position:relative;border:1px solid var(--line);border-radius:14px;padding:16px;background:var(--surface-2,#f2f5fb);display:flex;flex-direction:column;gap:6px}
.bill-card.hot{border-color:var(--brand);box-shadow:0 0 0 1px var(--brand) inset}
.bill-card.cur{outline:2px solid var(--green)}
.bill-name{font-weight:800;font-size:15px}
.bill-price{font-size:22px;font-weight:800;letter-spacing:-.01em}
.bill-card ul{margin:.3em 0 auto;padding-left:1.05em;font-size:12.5px;color:var(--muted)}
.bill-card li{margin:.25em 0}
.bill-card .btn,.bill-card a.btn{margin-top:8px;text-align:center;text-decoration:none}
.bill-current{margin-top:8px;font-size:12.5px;font-weight:700;color:var(--green)}
.bill-card .best{position:absolute;top:-9px;right:10px;font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.05em;color:#fff;background:var(--brand);padding:3px 8px;border-radius:999px}
@media (max-width:640px){.bill-grid{grid-template-columns:1fr 1fr}}
@media (max-width:400px){.bill-grid{grid-template-columns:1fr}}

/* ---------- Willkommen / Onboarding ---------- */
.onboard{background:var(--card);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow);padding:24px 22px;text-align:center}
.onboard h3{margin:0 0 6px;font-size:20px}
.onboard>p{color:var(--muted);margin:0 auto 14px;max-width:52ch}
.onboard-steps{display:inline-block;text-align:left;margin:0 auto 16px;padding-left:22px;color:var(--ink)}
.onboard-steps li{margin:7px 0}
.onboard-actions{display:flex;gap:10px;justify-content:center;flex-wrap:wrap}

/* FAQ-Optimierung */
.faq-serp{display:block;margin:8px 0;font-size:13px;color:var(--muted)}
.faq-serp input{margin-right:6px}
.faq-badge{display:inline-block;font-size:11px;font-weight:600;padding:1px 7px;border-radius:10px;color:#fff;vertical-align:middle}
.faq-badge.google{background:#1a73e8}
.faq-badge.ai{background:#9333ea}
.faq-badge.both{background:#0f9d58}
.faq-targets{list-style:none;padding:0;margin:6px 0}
.faq-targets li{padding:5px 0;border-bottom:1px solid var(--line)}
.faq-code{display:flex;gap:8px;flex-wrap:wrap;margin:10px 0}
.faq-raw{margin-top:10px;font-size:13px;color:var(--muted)}
.faq-raw summary{cursor:pointer}
.faq-raw ul{margin:6px 0 0;padding-left:20px}
.faq-existing{background:#fff7ed;border:1px solid #fed7aa;color:#9a3412;border-radius:8px;padding:10px 12px;margin:8px 0;font-size:13px}
.faq-existing details{margin-top:6px}
.faq-existing summary{cursor:pointer}
.faq-existing ul{margin:6px 0 0;padding-left:20px}
