/* Suchhimmel. Alles unter #seo-root, Klassen mit sg-. Masse folgen Welt Website Issues. */
#seo-root {
  --sg-meas: #5fd3bf;
  --sg-tgt: #f8c850;
  --sg-mut: #9aa3b5;
  --sg-ink2: #c5ccda;
  --sg-line: rgba(255, 255, 255, 0.14);
  --sg-blue: #3860c0;
  --sg-pad: clamp(16px, 3vw, 44px);
  position: fixed;
  inset: 0;
  z-index: 22;
  opacity: 0;
  pointer-events: none;
  background: #000;
  color: #fff;
  font: 400 16.5px/1.58 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
#seo-root.visible {
  opacity: 1;
  pointer-events: auto;
}
#seo-root.previs:not(.visible) {
  pointer-events: none;
  z-index: 20;
}
#seo-root canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
}
#seo-root * {
  box-sizing: border-box;
}
#seo-root button,
#seo-root input,
#seo-root textarea {
  font: inherit;
  color: inherit;
}
#seo-root button {
  cursor: pointer;
}
#seo-root :focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
  border-radius: 8px;
}
#seo-root .sg-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Kopfzeile ---------- */
#seo-root .sg-hud {
  position: absolute;
  z-index: 5;
  left: var(--sg-pad);
  right: var(--sg-pad);
  top: 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  pointer-events: none;
}
#seo-root .sg-hud a,
#seo-root .sg-hud button {
  pointer-events: auto;
}
#seo-root .sg-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--sg-mut);
  white-space: nowrap;
}
#seo-root .sg-sep {
  opacity: 0.4;
}
#seo-root a.back {
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
#seo-root a.back:hover {
  color: var(--sg-meas);
}
#seo-root .sg-badge {
  font: 700 10px var(--font-sans);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 99px;
  padding: 3px 8px;
  color: #e9edf5;
}
#seo-root .sg-right {
  display: flex;
  gap: 10px;
  align-items: center;
}

/* ---------- Geschichte links ---------- */
#seo-root .sg-story {
  position: absolute;
  z-index: 4;
  left: var(--sg-pad);
  top: 92px;
  width: min(430px, 34vw);
  max-height: calc(100% - 300px);
  overflow: auto;
  scrollbar-width: none;
}
#seo-root .sg-kick {
  font: 700 11.5px var(--font-sans);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #aeb8cc;
  margin: 0;
}
#seo-root .sg-story h1 {
  font-size: clamp(28px, 3vw, 45px);
  line-height: 1.06;
  letter-spacing: -0.03em;
  margin: 12px 0 0;
  font-weight: 800;
  text-wrap: balance;
}
#seo-root .sg-lead {
  margin: 16px 0 0;
  color: #cdd4e2;
  font-size: clamp(16px, 1.25vw, 18px);
  line-height: 1.6;
  max-width: 46ch;
}

/* ---------- Panel rechts: wächst mit dem Inhalt, scrollt innen ---------- */
#seo-root .sg-panel {
  position: absolute;
  z-index: 4;
  right: var(--sg-pad);
  top: 84px;
  width: min(440px, 38vw);
  max-height: calc(100% - 84px - 76px);
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  overflow: hidden;
  border-radius: 20px;
  background: linear-gradient(160deg, rgba(24, 28, 38, 0.78), rgba(8, 10, 14, 0.74));
  border: 1px solid var(--sg-line);
  backdrop-filter: blur(14px);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
#seo-root .sg-ph {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}
#seo-root .sg-ph h2,
#seo-root .sg-finale h2 {
  font-size: 20px;
  line-height: 1.2;
  font-weight: 800;
  margin: 0;
}
#seo-root .sg-sub {
  margin: -4px 0 0;
  font-size: 14px;
  color: var(--sg-ink2);
  flex: none;
}
#seo-root .sg-body {
  min-height: 0;
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
#seo-root .sg-foot {
  flex: none;
  margin: 0;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  font-size: 12px;
  line-height: 1.45;
  color: var(--sg-mut);
}
#seo-root .sg-h3 {
  margin: 6px 0 0;
  font: 700 11px var(--font-sans);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sg-mut);
}
#seo-root .sg-note {
  margin: 0;
  font-size: 12.5px;
  color: var(--sg-mut);
}

/* ---------- Labels: Türkis gemessen, Amber nur «Ziel», Entwurf neutral ---------- */
#seo-root .sg-chip {
  display: inline-block;
  flex: none;
  font: 700 10px/1.4 var(--font-sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 99px;
  border: 1px solid var(--sg-line);
  color: var(--sg-mut);
  white-space: nowrap;
  vertical-align: middle;
}
#seo-root .sg-chip.meas {
  color: #04221d;
  background: var(--sg-meas);
  border-color: var(--sg-meas);
}
#seo-root .sg-chip.tgt {
  color: #2a2108;
  background: var(--sg-tgt);
  border-color: var(--sg-tgt);
}
#seo-root .sg-chip.ent {
  color: #e9edf5;
  border-color: rgba(255, 255, 255, 0.45);
}

/* ---------- Kennzahlen (Start) ---------- */
#seo-root .sg-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
#seo-root .sg-stat {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
#seo-root .sg-stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
}
#seo-root .sg-stat b {
  font-size: 22px;
  line-height: 1;
  font-weight: 800;
}
#seo-root .sg-stat span {
  font-size: 12px;
  color: var(--sg-mut);
  line-height: 1.3;
}
#seo-root .sg-stat.meas b {
  color: var(--sg-meas);
}
#seo-root .sg-stat.tgt {
  border-color: rgba(248, 200, 80, 0.35);
}
#seo-root .sg-stat.tgt b {
  color: var(--sg-tgt);
}

/* ---------- Zeilen wie die Befundliste in Website Issues ---------- */
#seo-root .sg-rows {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
#seo-root .sg-row {
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.025);
  transition:
    border-color 0.25s,
    background 0.25s;
}
#seo-root .sg-row > button {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 8px 10px;
  background: none;
  border: 0;
  text-align: left;
  font-weight: 700;
  font-size: 14.5px;
}
#seo-root .sg-row > button:hover {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 12px;
}
#seo-root .sg-ix {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  flex: none;
  font: 800 12px var(--font-sans);
  background: #2a2f3a;
  color: #fff;
}
#seo-root .sg-rl {
  min-width: 0;
}
#seo-root .sg-side {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  text-align: right;
}
#seo-root .sg-side small {
  font-size: 11.5px;
  font-weight: 400;
  color: var(--sg-mut);
}
#seo-root .sg-row.open {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.05);
}
#seo-root .sg-row.open .sg-ix {
  background: #fff;
  color: #000;
}
#seo-root .sg-more {
  display: none;
  padding: 0 12px 12px 47px;
  font-size: 13.5px;
  color: var(--sg-ink2);
}
#seo-root .sg-row.open .sg-more {
  display: block;
}
#seo-root .sg-more p {
  margin: 6px 0 0;
}
#seo-root .sg-more b {
  color: #fff;
}
#seo-root .sg-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.5);
}
#seo-root .sg-dot.ok {
  border-color: #fff;
  background: #fff;
}
#seo-root .sg-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
#seo-root .sg-tags span {
  font-size: 12px;
  padding: 3px 9px;
  border-radius: 99px;
  border: 1px solid var(--sg-line);
  color: #d6dbe6;
}
#seo-root .sg-plain {
  margin: 4px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 5px;
  font-size: 13.5px;
  color: var(--sg-ink2);
}

/* ---------- Segment-Schalter ---------- */
#seo-root .sg-seg {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.05);
  width: max-content;
  max-width: 100%;
}
#seo-root .sg-seg button {
  padding: 6px 14px;
  border-radius: 99px;
  border: 0;
  background: none;
  color: var(--sg-mut);
  font-weight: 700;
  font-size: 13px;
}
#seo-root .sg-seg button.wait {
  opacity: 0.6;
}
#seo-root .sg-seg button[aria-selected="true"] {
  background: #fff;
  color: #000;
  opacity: 1;
}

/* ---------- Trefferliste ---------- */
#seo-root .sg-serp {
  padding: 14px 16px;
  border-radius: 14px;
  background: #0e1118;
  border: 1px solid var(--sg-line);
}
#seo-root .sg-serp.before {
  border-color: rgba(95, 211, 191, 0.45);
}
#seo-root .sg-serp.draft {
  border-color: rgba(255, 255, 255, 0.32);
}
#seo-root .sg-serp small {
  display: block;
  margin-top: 8px;
  font-size: 12.5px;
  color: #b9c3dc;
}
#seo-root .sg-serp b {
  display: block;
  margin: 4px 0;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 700;
  color: #8ab4ff;
}
#seo-root .sg-serp p {
  margin: 0;
  font-size: 14px;
  color: #a9b3c9;
}
#seo-root .sg-sl {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin-top: 8px;
  font-size: 13px;
  color: #8ab4ff;
}
#seo-root .sg-sl:empty {
  display: none;
}
#seo-root .sg-fills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
#seo-root label {
  display: block;
  font-size: 12px;
  color: var(--sg-mut);
}
#seo-root input,
#seo-root textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--sg-line);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-size: 14px;
  resize: vertical;
}
#seo-root .sg-checks {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 6px;
}
#seo-root .sg-checks li {
  display: flex;
  gap: 8px;
  font-size: 13.5px;
  color: #fff;
}
#seo-root .sg-checks i {
  flex: none;
  width: 14px;
  height: 14px;
  margin-top: 3px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.45);
}
#seo-root .sg-checks li.ok i {
  border-color: #fff;
  background: #fff;
  box-shadow: inset 0 0 0 3px #0e1118;
}
#seo-root .sg-checks li.open {
  color: var(--sg-ink2);
}
#seo-root .sg-checks small {
  display: block;
  color: var(--sg-mut);
  font-size: 12.5px;
}

/* ---------- Bausteine ---------- */
#seo-root .sg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  align-self: flex-start;
  padding: 7px 14px;
  border-radius: 99px;
  border: 1px solid var(--sg-line);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
}
#seo-root .sg-btn:hover {
  background: rgba(255, 255, 255, 0.14);
}
#seo-root .sg-pre {
  margin: 0;
  font:
    12.5px/1.45 ui-monospace,
    Menlo,
    Consolas,
    monospace;
  white-space: pre-wrap;
  word-break: break-word;
  background: #07090d;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 10px 12px;
  color: #d6dbe6;
  max-height: 200px;
  overflow: auto;
}
#seo-root .sg-page {
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(255, 255, 255, 0.3);
}
#seo-root .sg-pk {
  font: 700 10px var(--font-sans);
  letter-spacing: 0.14em;
  color: var(--sg-mut);
}
#seo-root .sg-page b {
  display: block;
  margin: 2px 0 10px;
  font-size: 17px;
  line-height: 1.25;
  font-weight: 800;
}
#seo-root .sg-page ol {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 4px;
  font-size: 14px;
  color: var(--sg-ink2);
}
#seo-root .sg-addr {
  font-style: normal;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 14px;
  color: var(--sg-ink2);
}
#seo-root .sg-addr b {
  display: block;
  color: #fff;
}
#seo-root .sg-addr a {
  display: block;
  margin-top: 4px;
  color: #8ab4ff;
  text-decoration: none;
}

/* ---------- Abflug ---------- */
#seo-root .sg-finale {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: auto;
}
#seo-root .sg-finale ul {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 6px;
  font-size: 14.5px;
  color: #d6dbe6;
}
#seo-root .sg-launch {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
  padding: 13px 20px;
  border-radius: 99px;
  border: 1px solid #7a9aef;
  background: linear-gradient(90deg, #3860c0, #6a45b0);
  box-shadow: 0 0 40px rgba(56, 96, 192, 0.5);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
}
#seo-root .sg-launch:hover {
  filter: brightness(1.12);
}
#seo-root .sg-rk {
  width: 18px;
  height: 18px;
  background:
    radial-gradient(circle at 50% 30%, #fff 0 2px, transparent 2.5px),
    linear-gradient(#e87048, #e87048);
  clip-path: polygon(50% 0, 80% 40%, 80% 80%, 100% 100%, 0 100%, 20% 80%, 20% 40%);
}
#seo-root .sg-finale .sg-note {
  text-align: center;
}
#seo-root .sg-fine {
  margin: 4px 0 0;
  font-size: 11px;
  line-height: 1.45;
  color: #6f778a;
}

/* ---------- Schritte unten, wie Website Issues ---------- */
#seo-root .sg-nav {
  position: absolute;
  z-index: 6;
  left: max(180px, 20vw);
  bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
#seo-root .sg-prog {
  display: flex;
  gap: 3px;
}
#seo-root .sg-prog button {
  position: relative;
  width: 28px;
  height: 18px;
  padding: 6px 0;
  border: 0;
  background: none;
}
#seo-root .sg-prog button::before {
  content: "";
  position: absolute;
  left: 1px;
  right: 1px;
  top: 6px;
  height: 6px;
  border-radius: 3px;
  background: #2a303d;
  transition: background 0.3s;
}
#seo-root .sg-prog button:hover::before {
  background: #4a5266;
}
#seo-root .sg-prog button.on::before {
  background: #6b7488;
}
#seo-root .sg-prog button.cur::before {
  background: #fff;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.6);
}
#seo-root .sg-navb {
  height: 30px;
  min-width: 30px;
  padding: 0 10px;
  border-radius: 99px;
  border: 1px solid var(--sg-line);
  background: rgba(14, 16, 22, 0.8);
  font-weight: 700;
  font-size: 13px;
}
#seo-root .sg-navb:hover {
  background: rgba(255, 255, 255, 0.12);
}
#seo-root .sg-navb:disabled {
  opacity: 0.3;
  cursor: default;
}
#seo-root .sg-where {
  font-size: 12px;
  color: var(--sg-mut);
  white-space: nowrap;
}

#seo-root .sg-story,
#seo-root .sg-panel,
#seo-root .sg-lead,
#seo-root .sg-pre,
#seo-root input,
#seo-root textarea {
  -webkit-user-select: text;
  user-select: text;
}
#seo-root button,
#seo-root .sg-btn,
#seo-root canvas {
  -webkit-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
}

#seo-root.bridge .sg-story,
#seo-root.bridge .sg-panel,
#seo-root.bridge .sg-hud,
#seo-root.bridge .sg-nav {
  opacity: 0 !important;
  pointer-events: none !important;
}
#seo-root.settled .sg-story {
  animation: sg-rise 0.7s ease both;
}
#seo-root.settled .sg-panel {
  animation: sg-rise 0.78s 0.06s ease both;
}
@keyframes sg-rise {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

body.seo-on > .hud-top,
body.seo-on > .hint,
body.seo-on > .tag,
body.seo-on > .hud-bot,
body.seo-on > #labels {
  opacity: 0;
  pointer-events: none;
}
body.seo-on > #character {
  z-index: 28;
  pointer-events: none;
}
body.tour-on.seo-on > #character {
  opacity: 1;
}
body.tour-on.seo-on > #character .char-hit {
  pointer-events: auto;
}
body.seo-on > #c {
  visibility: hidden;
}
body[data-start="seo"]:not(.seo-on) > #c,
body[data-start="seo"]:not(.seo-on) > #labels,
body[data-start="seo"]:not(.seo-on) > .hint,
body[data-start="seo"]:not(.seo-on) > .tag,
body[data-start="seo"]:not(.seo-on) > .hud-bot,
body[data-start="seo"]:not(.seo-on) > .hud-top {
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 1100px) {
  #seo-root .sg-where {
    display: none;
  }
}
@media (max-width: 820px) {
  #seo-root .sg-hud {
    top: 14px;
  }
  #seo-root .sg-brand > span:not(.sg-badge) {
    display: none;
  }
  #seo-root .snd-btn .slbl {
    display: none;
  }
  #seo-root .sg-story {
    left: 16px;
    right: 16px;
    top: 70px;
    width: auto;
    max-height: 30vh;
  }
  #seo-root .sg-story h1 {
    font-size: 25px;
    margin-top: 6px;
  }
  #seo-root .sg-lead {
    font-size: 14px;
    margin-top: 8px;
    max-width: none;
  }
  #seo-root .sg-story h1,
  #seo-root .sg-lead {
    text-shadow:
      0 2px 12px #000,
      0 0 3px #000;
  }
  #seo-root .sg-panel {
    left: 12px;
    right: 12px;
    top: auto;
    bottom: 56px;
    width: auto;
    max-height: 40vh;
    padding: 12px;
    gap: 8px;
    overflow: auto;
  }
  #seo-root .sg-body {
    flex: none;
    overflow: visible;
  }
  #seo-root .sg-nav {
    left: 12px;
    right: 12px;
    bottom: 12px;
    justify-content: center;
  }
  #seo-root .sg-prog button {
    width: 20px;
  }
  /* Krabbel klein über dem Panel, damit er den Inhalt nicht verdeckt. */
  body.seo-on > #character {
    width: 92px;
    height: 116px;
    left: 6px;
    bottom: calc(56px + 40vh + 6px);
  }
}
@media (prefers-reduced-motion: reduce) {
  #seo-root.settled .sg-story,
  #seo-root.settled .sg-panel {
    animation: none;
  }
  #seo-root * {
    transition-duration: 0.01ms !important;
  }
}
