/* WP Rankify Dashboard */
@font-face { font-family: "Bricolage Grotesque"; font-weight: 600; font-display: swap; src: url(fonts/bricolage-grotesque-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Bricolage Grotesque"; font-weight: 800; font-display: swap; src: url(fonts/bricolage-grotesque-latin-800-normal.woff2) format("woff2"); }
@font-face { font-family: "Figtree"; font-weight: 400; font-display: swap; src: url(fonts/figtree-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Figtree"; font-weight: 500; font-display: swap; src: url(fonts/figtree-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Figtree"; font-weight: 600; font-display: swap; src: url(fonts/figtree-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Figtree"; font-weight: 700; font-display: swap; src: url(fonts/figtree-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-weight: 400; font-display: swap; src: url(fonts/jetbrains-mono-latin-400-normal.woff2) format("woff2"); }

:root {
  --orange: #F29400;
  --orange-soft: #FFF1D9;
  --orange-mid: #FFC766;
  --orange-ink: #8A4B00;
  --ink: #111111;
  --ink-2: #2B2925;
  --muted: #5F5A52;
  --paper: #FBF8F3;
  --card: #FFFFFF;
  --line: #E9E2D7;
  --line-2: #F2EDE5;
  --green: #1F7A4A;
  --green-soft: #E3F4EA;
  --red: #B42318;
  --red-soft: #FDECEA;
  --grey-bar: #CFC7BB;
  --radius: 14px;
  --display: "Bricolage Grotesque", "Figtree", system-ui, sans-serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.5; }
a { color: var(--orange-ink); }
a:hover { color: var(--ink); }
h1, h2, h3 { font-family: var(--display); font-weight: 800; letter-spacing: -0.02em; line-height: 1.12; margin: 0; }
h1 { font-size: clamp(26px, 3.4vw, 36px); }
h2 { font-size: 20px; }
h3 { font-size: 16px; font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0; }
code, pre, .mono { font-family: var(--mono); font-size: 12.5px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.logo svg { width: 34px; height: 34px; flex-shrink: 0; }
.logo-word { font-family: var(--display); font-size: 22px; letter-spacing: -0.02em; line-height: 1; }
.logo-word b { font-weight: 800; }
.logo-word span { font-weight: 600; color: var(--orange); }
.logo-tag { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; background: var(--ink); color: #fff; padding: 3px 7px; border-radius: 6px; }

/* ---------- Buttons & Forms ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 10px; border: 1px solid transparent; font: 600 15px/1 var(--body); cursor: pointer; text-decoration: none; transition: background .15s, transform .1s; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: #2d2b28; color: #fff; }
.btn-orange { background: var(--orange); color: var(--ink); }
.btn-orange:hover { background: #ffa51f; color: var(--ink); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: #fff; color: var(--ink); }
.btn-danger { background: var(--red); color: #fff; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 13.5px; border-radius: 8px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 600; font-size: 14px; }
.field .hint { font-size: 13px; color: var(--muted); }
input[type=text], input[type=email], input[type=password], input[type=search], select {
  width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #D8D0C3; border-radius: 10px; background: #fff;
  font: 400 15px var(--body); color: var(--ink);
}
input:focus, select:focus, .btn:focus-visible, a:focus-visible { outline: 3px solid rgba(242,148,0,.45); outline-offset: 1px; border-color: var(--orange); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--ink); }
form.stack { display: flex; flex-direction: column; gap: 18px; }

/* ---------- Flash ---------- */
.flash { padding: 12px 14px; border-radius: 10px; font-size: 14px; font-weight: 500; }
.flash-success { background: var(--green-soft); color: #14532D; }
.flash-error { background: var(--red-soft); color: #7A1810; }
.flash-info { background: var(--orange-soft); color: var(--orange-ink); }
.flashes { display: flex; flex-direction: column; gap: 8px; }

/* ---------- Gast-Layout (Login / Registrierung) ---------- */
.guest { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.guest-brand { background: var(--orange); position: relative; overflow: hidden; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.guest-brand .logo-word span { color: #fff; }
.guest-brand .bubble { position: absolute; border-radius: 50%; }
.guest-claim { position: relative; max-width: 460px; }
.guest-claim h2 { font-size: clamp(30px, 3.6vw, 48px); line-height: 1.02; }
.guest-claim p { margin-top: 16px; font-size: 17px; max-width: 400px; }
.guest-bots { position: relative; display: flex; flex-wrap: wrap; gap: 8px; max-width: 460px; }
.guest-bots span { background: rgba(17,17,17,.9); color: #fff; font: 12.5px var(--mono); padding: 6px 10px; border-radius: 999px; }
.guest-main { display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.guest-card { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 22px; }
.guest-card .sub { color: var(--muted); margin-top: 8px; }
.guest-foot { font-size: 14px; color: var(--muted); text-align: center; }
.mobile-logo { display: none; }

/* ---------- Onboarding ---------- */
.onb { min-height: 100vh; display: flex; flex-direction: column; }
.onb-top { display: flex; justify-content: space-between; align-items: center; padding: 18px 28px; border-bottom: 1px solid var(--line); background: #fff; gap: 16px; }
.onb-body { flex: 1; width: 100%; max-width: 860px; margin: 0 auto; padding: 40px 20px 64px; display: flex; flex-direction: column; gap: 28px; }
.steps { display: flex; gap: 8px; list-style: none; margin: 0; padding: 0; }
.steps li { flex: 1; display: flex; flex-direction: column; gap: 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.steps li::before { content: ""; height: 6px; border-radius: 3px; background: var(--line); }
.steps li.done::before, .steps li.current::before { background: var(--orange); }
.steps li.current { color: var(--ink); }
.onb-head p { margin-top: 10px; color: var(--muted); font-size: 16px; max-width: 640px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.domain-row { display: flex; gap: 10px; flex-wrap: wrap; }
.domain-row input { flex: 1 1 260px; font-size: 17px; }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-bottom: 20px; }
.tabs a { padding: 10px 14px; text-decoration: none; color: var(--muted); font-weight: 600; border-bottom: 3px solid transparent; margin-bottom: -1px; min-height: 44px; display: inline-flex; align-items: center; gap: 8px; }
.tabs a.active { color: var(--ink); border-bottom-color: var(--orange); }
.tabs .pill { font-size: 11px; background: var(--orange-soft); color: var(--orange-ink); padding: 2px 7px; border-radius: 999px; }
ol.howto { margin: 0; padding: 0; list-style: none; counter-reset: s; display: flex; flex-direction: column; gap: 18px; }
ol.howto > li { counter-increment: s; display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 14px; }
ol.howto > li::before { content: counter(s); width: 32px; height: 32px; border-radius: 50%; background: var(--ink); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; }
ol.howto h3 { margin-bottom: 4px; }
.code { position: relative; background: #17150F; color: #F4EEE4; border-radius: 12px; padding: 16px; overflow-x: auto; margin-top: 10px; }
.code pre { margin: 0; white-space: pre; line-height: 1.55; }
.code .copy { position: absolute; top: 8px; right: 8px; background: #2c2920; color: #fff; border: 0; border-radius: 8px; font: 600 12px var(--body); padding: 7px 10px; cursor: pointer; min-height: 32px; }
.code .copy:hover { background: var(--orange); color: var(--ink); }
.code.tall { max-height: 320px; }
.callout { background: var(--orange-soft); border-radius: 12px; padding: 14px 16px; font-size: 14px; color: #4A2A00; }
.onb-actions { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; }

.wait { display: flex; gap: 18px; align-items: center; }
.pulse { width: 18px; height: 18px; border-radius: 50%; background: var(--orange); flex-shrink: 0; animation: pulse 1.6s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(242,148,0,.55); } 70% { box-shadow: 0 0 0 16px rgba(242,148,0,0); } 100% { box-shadow: 0 0 0 0 rgba(242,148,0,0); } }
.ok-dot { width: 18px; height: 18px; border-radius: 50%; background: var(--green); flex-shrink: 0; }
.live-list { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.live-list li { display: grid; grid-template-columns: 74px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 8px 12px; background: var(--paper); border-radius: 8px; font-size: 13.5px; }
.live-list .path { font-family: var(--mono); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- App-Layout ---------- */
.topbar { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.topbar-in { max-width: 1320px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.topnav { display: flex; gap: 4px; flex-wrap: wrap; margin-left: auto; align-items: center; }
.topnav a, .topnav button { color: var(--ink-2); text-decoration: none; font: 600 14px var(--body); padding: 0 12px; min-height: 40px; display: inline-flex; align-items: center; border-radius: 8px; background: none; border: 0; cursor: pointer; }
.topnav a:hover, .topnav button:hover { background: var(--paper); }
.topnav a.active { background: var(--orange-soft); color: var(--orange-ink); }
.site-switch { display: flex; align-items: center; gap: 8px; }
.site-switch select { min-height: 40px; padding: 6px 10px; font-weight: 600; width: auto; max-width: 260px; }
.main { max-width: 1320px; margin: 0 auto; padding: 28px 24px 64px; display: flex; flex-direction: column; gap: 24px; }

.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.page-head .meta { margin-top: 6px; color: var(--muted); font-size: 14px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.status-dot { display: inline-flex; align-items: center; gap: 6px; }
.status-dot::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--green); }
.status-dot.off::before { background: #B8AFA2; }
.seg { display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 3px; gap: 2px; }
.seg a { text-decoration: none; color: var(--muted); font-weight: 600; font-size: 13.5px; padding: 0 12px; min-height: 36px; display: inline-flex; align-items: center; border-radius: 7px; }
.seg a.active { background: var(--ink); color: #fff; }

.kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: flex; flex-direction: column; gap: 6px; }
.kpi .label { font-size: 13px; font-weight: 600; color: var(--muted); }
.kpi .value { font-family: var(--display); font-weight: 800; font-size: 32px; letter-spacing: -0.03em; line-height: 1; }
.kpi .note { font-size: 12.5px; color: var(--muted); }
.kpi.accent { background: var(--orange); border-color: var(--orange); }
.kpi.accent .label, .kpi.accent .note { color: #3D2300; }
.kpi.warn .value { color: var(--red); }

.grid-2 { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 11px; height: 11px; border-radius: 3px; display: inline-block; }
.chart svg { width: 100%; height: auto; display: block; }
.chart .bar-ai { fill: var(--orange); }
.chart .bar-search { fill: var(--ink); }
.chart .bar-other { fill: var(--grey-bar); }
.chart text { font: 11px var(--body); fill: var(--muted); }
.chart .gridline { stroke: var(--line-2); }
.empty { padding: 36px 16px; text-align: center; color: var(--muted); font-size: 14px; }

table.data { width: 100%; border-collapse: collapse; font-size: 14px; }
table.data th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; padding: 0 10px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data td { padding: 10px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
table.data tr:last-child td { border-bottom: 0; }
table.data .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table-wrap { overflow-x: auto; margin: 0 -4px; }
.botname { font-weight: 600; text-decoration: none; color: var(--ink); }
.botname:hover { color: var(--orange-ink); text-decoration: underline; }
.share { display: flex; align-items: center; gap: 8px; }
.share b { height: 6px; border-radius: 3px; background: var(--orange); display: inline-block; min-width: 2px; }

.tag { display: inline-flex; align-items: center; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; background: var(--line-2); color: var(--ink-2); }
.tag-ai_user { background: var(--orange); color: var(--ink); }
.tag-ai_search { background: var(--orange-mid); color: var(--ink); }
.tag-ai_training { background: var(--orange-soft); color: var(--orange-ink); }
.tag-search { background: var(--ink); color: #fff; }
.v-ok { color: var(--green); font-weight: 600; font-size: 13px; white-space: nowrap; }
.v-fake { color: var(--red); font-weight: 700; font-size: 13px; white-space: nowrap; }
.v-na { color: #8B8378; font-size: 13px; white-space: nowrap; }

.filters { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)) auto; gap: 10px; align-items: end; margin-bottom: 16px; }
.filters .field label { font-size: 12.5px; color: var(--muted); }
.filters select, .filters input { min-height: 40px; padding: 7px 10px; font-size: 14px; }
.log td.path { font-family: var(--mono); font-size: 12.5px; word-break: break-all; min-width: 200px; }
.log td.ua { font-family: var(--mono); font-size: 11.5px; color: var(--muted); max-width: 360px; word-break: break-all; }
.log td.time { white-space: nowrap; font-variant-numeric: tabular-nums; }
.status { font-family: var(--mono); font-size: 12px; font-weight: 600; }
.status.s4, .status.s5 { color: var(--red); }
.status.s3 { color: var(--orange-ink); }
.pager { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 16px; flex-wrap: wrap; font-size: 14px; }
.pager .btns { display: flex; gap: 8px; }

.site-list { display: flex; flex-direction: column; gap: 12px; }
.site-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; }
.site-item h3 { font-size: 18px; font-family: var(--display); font-weight: 800; }
.site-stats { display: flex; gap: 16px; font-size: 13.5px; color: var(--muted); flex-wrap: wrap; margin-top: 4px; }
.site-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
details.danger summary { cursor: pointer; color: var(--red); font-weight: 600; font-size: 14px; }
details.danger form { margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap; }
details.danger input { flex: 1 1 220px; }

@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .guest { grid-template-columns: minmax(0, 1fr); }
  .guest-brand { display: none; }
  .mobile-logo { display: block; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .topbar-in, .main { padding-left: 16px; padding-right: 16px; }
  .onb-top { padding: 14px 16px; }
  .site-item { grid-template-columns: minmax(0, 1fr); }
  .site-actions { justify-content: flex-start; }
}
@media (max-width: 520px) {
  .filters { grid-template-columns: minmax(0, 1fr); }
  .steps li span { display: none; }
  .kpi .value { font-size: 26px; }
}
