/* Strona FIBO: paleta marki, jasny i ciemny motyw, wysoki kontrast. */
:root {
  --bg: #f6f5fc; --panel: #fff; --text: #1d1b3a; --muted: #5b5878; --line: #e2dff3;
  --accent: #6d5bf0; --accent-ink: #fff; --amber: #ffb627; --navy: #1e1b4b;
  --tonal: color-mix(in srgb, var(--accent) 12%, var(--panel));
  --r: 20px; --ease: cubic-bezier(.2,.8,.2,1);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #13112b; --panel: #1e1b4b; --text: #ecebf7; --muted: #aaa7c9; --line: #34306b; }
}
@media (prefers-contrast: more) { :root { --line: var(--text); --muted: var(--text); } }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { margin: 0; background: var(--bg); color: var(--text); font: 17px/1.6 system-ui, "Segoe UI", Roboto, sans-serif; }
a { color: var(--accent); }
@media (prefers-color-scheme: dark) { a { color: #a99dff; } }
img { max-width: 100%; height: auto; }
.wrap { width: min(1120px, 100% - 32px); margin: 0 auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: #fff; padding: 8px 14px; border-radius: 12px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 70%, transparent); outline-offset: 3px; border-radius: 6px; }

.top { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(16px); border-bottom: 1px solid var(--line); }
@media (prefers-contrast: more), (prefers-reduced-transparency: reduce) { .top { background: var(--bg); backdrop-filter: none; } }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; flex-wrap: wrap; padding: 6px 0; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font: 800 22px/1 system-ui; letter-spacing: .02em; }
.brand img { border-radius: 10px; }
.top nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.top nav a { text-decoration: none; color: var(--text); padding: 10px 14px; border-radius: 999px; font-size: 15px; min-height: 44px; display: inline-flex; align-items: center; }
.top nav a:hover { background: var(--tonal); }
.top nav a.lang { border: 1px solid var(--line); font-weight: 600; }

.hero { padding: 56px 0 32px; background: radial-gradient(900px 400px at 85% 0%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 70%); }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 32px; align-items: center; }
.eyebrow { margin: 0; color: var(--accent); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; font-size: 13px; }
.hero h1 { margin: 6px 0 12px; font: 800 clamp(56px, 11vw, 104px)/.95 system-ui; letter-spacing: -.02em; }
.lead { font-size: 20px; color: var(--muted); max-width: 36em; margin: 0 0 24px; }
.hero-art { display: grid; place-items: center; }
.hero-art img { width: min(520px, 100%); filter: drop-shadow(0 20px 40px color-mix(in srgb, var(--accent) 35%, transparent)); }
.dl-box { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 56px; padding: 14px 26px; border-radius: 16px; font: 700 18px/1 system-ui; text-decoration: none; transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.btn.primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 8px 24px color-mix(in srgb, var(--accent) 45%, transparent); }
@media (prefers-color-scheme: dark) { .btn.primary { color: #fff; } }
.btn.primary:hover { transform: translateY(-2px); }
.meta { margin: 0; color: var(--muted); font-size: 14.5px; }
.small { font-size: 13.5px; }
.note a { color: var(--muted); }

h2 { font: 750 clamp(26px, 4vw, 36px)/1.2 system-ui; margin: 56px 0 20px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 22px; }
.card h3 { margin: 14px 0 6px; font: 650 19px/1.25 system-ui; }
.card p { margin: 0; color: var(--muted); font-size: 16px; }
.ico { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: var(--tonal); color: var(--accent); }
@media (prefers-color-scheme: dark) {
  .ico { color: #a99dff; }
  .fi { fill: #ffb627 !important; fill-opacity: .95 !important; }
}

.docs { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 40px; align-items: start; }
.toc { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow-y: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 6px 8px; }
.toc summary { cursor: pointer; padding: 10px 12px; font-weight: 700; min-height: 44px; list-style: none; }
.toc summary::-webkit-details-marker { display: none; }
.toc ol { list-style: none; margin: 0; padding: 0 0 8px; }
.toc a { display: block; padding: 8px 12px; border-radius: 12px; text-decoration: none; color: var(--text); font-size: 15px; }
.toc a:hover { background: var(--tonal); }
.toc a.on { background: var(--tonal); font-weight: 700; color: var(--accent); }
@media (prefers-color-scheme: dark) { .toc a.on { color: #a99dff; } }
.doc-body, .toc, .hero-grid > div { min-width: 0; }
.doc-body h2 { margin-top: 0; }
.doc-body section { padding-bottom: 8px; }
.sec-title { font: 700 24px/1.25 system-ui; margin: 40px 0 12px; padding-top: 8px; border-top: 1px solid var(--line); }
.doc-body section:first-of-type .sec-title { border-top: 0; margin-top: 8px; }
.doc-body h3:not(.sec-title) { font: 650 18px/1.3 system-ui; margin: 22px 0 8px; }
.doc-body li { margin: 6px 0; }
code { background: var(--tonal); padding: 2px 7px; border-radius: 8px; font-size: .92em; }
pre { background: var(--navy); color: #ecebf7; padding: 16px 18px; border-radius: 16px; overflow-x: auto; }
pre code { background: none; padding: 0; color: inherit; }
kbd { background: var(--panel); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 8px; padding: 1px 8px; font: 600 .85em system-ui; }
table { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
th, td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--tonal); font-size: 14px; }
tr:last-child td { border-bottom: 0; }
.note { background: var(--tonal); border: 1px solid var(--line); border-left: 4px solid var(--amber); border-radius: 14px; padding: 14px 18px; margin: 16px 0; }
.note ul { margin: 6px 0 0; }
.doc-body details { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; margin: 10px 0; padding: 0 16px; }
.doc-body details summary { cursor: pointer; padding: 14px 0; font-weight: 600; min-height: 48px; }
.doc-body details p { margin: 0 0 14px; color: var(--muted); }
footer { border-top: 1px solid var(--line); margin-top: 72px; padding: 28px 0 40px; color: var(--muted); font-size: 15px; }

@media (max-width: 860px) {
  .hero-grid, .docs { grid-template-columns: minmax(0, 1fr); }
  table { display: block; overflow-x: auto; }
  .hero-art { order: -1; max-width: 320px; }
  .toc { position: static; max-height: none; }
  .top nav a { padding: 10px 10px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
