/* Sayfely-Handbuch – gemeinsame Gestaltung für Startseite, Anwender- und Admin-Handbuch.
   Statische Seiten ohne externe Abhängigkeiten: laufen auf sayfely.com, in der App und auf der Download-Seite des Servers. */
:root {
  --accent: #2D5BFF; --accent2: #4C74FF; --extern: #E8743B; --ok: #2F9E63; --warn: #E8743B; --err: #D93036;
  --bg: #F6F7FB; --paper: #FFFFFF; --text: #14182B; --dim: #5A6178; --line: #E2E5EF; --code: #EEF1F8;
  --hero1: #070B1F; --hero2: #12204F;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #070B1F; --paper: #0F1530; --text: #E8ECFF; --dim: #A3ABC8; --line: #232B4D; --code: #19213F;
  }
}
:root[data-theme="dark"] { --bg: #070B1F; --paper: #0F1530; --text: #E8ECFF; --dim: #A3ABC8; --line: #232B4D; --code: #19213F; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body { margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--accent2); }
img { max-width: 100%; }

/* Kopfzeile */
.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 18px; padding: 12px 24px;
  background: rgba(7, 11, 31, .92); backdrop-filter: blur(12px); color: #E8ECFF; border-bottom: 1px solid rgba(255,255,255,.08); }
.topbar .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; color: #fff; text-decoration: none; }
.topbar .brand img { width: 30px; height: 30px; border-radius: 8px; }
.topbar nav { display: flex; gap: 6px; margin-left: auto; flex-wrap: wrap; }
.topbar nav a { color: #C9D1F2; text-decoration: none; font-size: 14px; padding: 6px 12px; border-radius: 999px; }
.topbar nav a:hover, .topbar nav a[aria-current] { background: rgba(255,255,255,.1); color: #fff; }

/* Titelbereich */
.hero { color: #E8ECFF; padding: 56px 24px 48px;
  background: radial-gradient(60vmax 40vmax at 85% -20%, rgba(45,91,255,.55), transparent 60%),
              radial-gradient(50vmax 40vmax at 0% 120%, rgba(107,69,242,.35), transparent 60%), var(--hero1); }
.hero .inner { max-width: 1180px; margin: 0 auto; }
.hero h1 { font-size: 42px; letter-spacing: -.02em; line-height: 1.15; margin: 0 0 10px; }
.hero p { font-size: 18px; color: #B9C2E6; max-width: 760px; margin: 0; }
.hero .chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 18px; }
.chip { font-size: 13px; padding: 5px 12px; border-radius: 999px; border: 1px solid rgba(255,255,255,.18); color: #C9D1F2; background: rgba(255,255,255,.06); }

/* Seitenaufbau: Inhaltsverzeichnis links, Text rechts */
.layout { max-width: 1180px; margin: 0 auto; padding: 32px 24px 80px; display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 40px; }
.toc { position: sticky; top: 84px; align-self: start; max-height: calc(100vh - 100px); overflow: auto; font-size: 14px; }
.toc h2 { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); margin: 0 0 8px; }
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc li a { display: block; padding: 5px 10px; border-radius: 8px; color: var(--text); text-decoration: none; }
.toc li a:hover { background: var(--code); }
.toc li li a { padding-left: 22px; color: var(--dim); font-size: 13px; }
main { min-width: 0; }
main > section { background: var(--paper); border: 1px solid var(--line); border-radius: 20px; padding: 32px 36px; margin-bottom: 24px; }
h2 { font-size: 28px; letter-spacing: -.01em; margin: 0 0 8px; }
h3 { font-size: 20px; margin: 30px 0 8px; }
h4 { font-size: 16px; margin: 22px 0 6px; }
.lead { font-size: 17px; color: var(--dim); margin-top: 0; }
kbd { font: 13px ui-monospace, SFMono-Regular, Menlo, monospace; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line); background: var(--code); }
code { font: 14px ui-monospace, SFMono-Regular, Menlo, monospace; padding: 1px 5px; border-radius: 5px; background: var(--code); }
.ui { font-weight: 600; } /* Beschriftung eines Knopfs oder Menüs, z. B. <span class="ui">Beitreten</span> */

/* Schritt-für-Schritt */
ol.steps { counter-reset: s; list-style: none; padding: 0; margin: 14px 0; }
ol.steps > li { counter-increment: s; position: relative; padding: 12px 14px 12px 54px; margin: 8px 0; border-radius: var(--radius); background: var(--code); }
ol.steps > li::before { content: counter(s); position: absolute; left: 14px; top: 12px; width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 700; font-size: 13px; color: #fff; background: linear-gradient(180deg, var(--accent2), var(--accent)); }

/* Hinweiskästen */
.note, .tip, .warn, .security { border-radius: var(--radius); padding: 14px 16px 14px 48px; margin: 16px 0; position: relative; border: 1px solid; }
.note::before, .tip::before, .warn::before, .security::before { position: absolute; left: 16px; top: 13px; font-size: 18px; }
.note { background: rgba(45,91,255,.08); border-color: rgba(45,91,255,.3); } .note::before { content: "ℹ️"; }
.tip { background: rgba(47,158,99,.08); border-color: rgba(47,158,99,.35); } .tip::before { content: "💡"; }
.warn { background: rgba(232,116,59,.10); border-color: rgba(232,116,59,.4); } .warn::before { content: "⚠️"; }
.security { background: rgba(107,69,242,.08); border-color: rgba(107,69,242,.35); } .security::before { content: "🔒"; }

/* Bildschirmfotos */
figure { margin: 22px 0; }
figure img { display: block; border-radius: 12px; box-shadow: 0 14px 40px rgba(7,11,31,.22), 0 0 0 1px var(--line); }
figure.small img { max-width: 520px; }
figcaption { font-size: 14px; color: var(--dim); margin-top: 10px; }

/* Tabellen */
table { width: 100%; border-collapse: collapse; margin: 14px 0; font-size: 15px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--dim); }

/* Startseite: Karten */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; max-width: 1180px; margin: 32px auto; padding: 0 24px 60px; }
.cards a { display: block; padding: 28px; border-radius: 20px; background: var(--paper); border: 1px solid var(--line); color: var(--text); text-decoration: none; }
.cards a:hover { border-color: var(--accent); }
.cards h2 { font-size: 22px; margin: 10px 0 6px; }
.cards p { color: var(--dim); margin: 0; }
.cards .icon { font-size: 30px; }

details { border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; margin: 10px 0; }
details summary { cursor: pointer; font-weight: 600; }
footer.page { text-align: center; color: var(--dim); font-size: 13px; padding: 30px 24px 50px; }

@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; padding: 20px 16px 60px; }
  .toc { position: static; max-height: none; }
  main > section { padding: 22px 18px; }
  .hero h1 { font-size: 32px; }
  .topbar { padding: 10px 16px; }
}
@media print {
  .topbar, .toc { display: none; } .layout { display: block; } main > section { break-inside: avoid-page; border: none; }
}
