/* =============================================================
   Modo CMS — GitHub Pages landing
   Design system: dark / indigo (matches the admin dark theme)
   No external dependencies, no CDN.
   ============================================================= */

:root {
  --bg: #0b1120;
  --bg-deep: #070b15;
  --surface: #131c31;
  --surface-2: #0f172a;
  --primary: #6366f1;
  --primary-hover: #818cf8;
  --primary-strong: #4f46e5;
  --cyan: #22d3ee;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --border: rgba(148, 163, 184, 0.14);
  --border-strong: rgba(129, 140, 248, 0.35);
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.7);
  --glow: 0 0 60px -12px rgba(99, 102, 241, 0.65);
  --maxw: 1180px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "SFMono-Regular", "JetBrains Mono", "Fira Code", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Ambient background glows */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(60% 50% at 12% 0%, rgba(99, 102, 241, 0.22), transparent 70%),
    radial-gradient(55% 45% at 95% 8%, rgba(34, 211, 238, 0.14), transparent 70%),
    radial-gradient(70% 60% at 50% 100%, rgba(79, 70, 229, 0.12), transparent 70%);
  pointer-events: none;
}

/* Subtle noise texture (SVG data URI) */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: 0.035;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

img, svg { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3 { line-height: 1.1; margin: 0; letter-spacing: -0.02em; }

::selection { background: rgba(99, 102, 241, 0.4); color: #fff; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 22px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--primary); color: #fff; padding: 10px 16px; border-radius: 10px;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------------- Buttons ---------------- */
.btn {
  --btn-bg: var(--primary);
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 24px; border-radius: 999px;
  font-weight: 700; font-size: 15px; letter-spacing: 0.01em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease), border-color 0.25s var(--ease);
  background: linear-gradient(135deg, var(--primary-hover), var(--primary-strong));
  color: #fff; box-shadow: var(--glow);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 0 70px -8px rgba(99, 102, 241, 0.85); }
.btn:active { transform: translateY(0); }

.btn--ghost {
  background: rgba(148, 163, 184, 0.06);
  border-color: var(--border-strong);
  box-shadow: none; color: var(--text);
  backdrop-filter: blur(8px);
}
.btn--ghost:hover { border-color: var(--primary-hover); background: rgba(99, 102, 241, 0.12); box-shadow: none; }

.btn__icon { width: 18px; height: 18px; flex: 0 0 auto; }

/* ---------------- Nav ---------------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(14px);
  background: rgba(11, 17, 32, 0.72);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.nav.is-scrolled { border-bottom-color: var(--border); background: rgba(7, 11, 21, 0.85); }
.nav__inner { display: flex; align-items: center; gap: 18px; height: 72px; }

.brand { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 18px; letter-spacing: -0.02em; }
.brand img { width: 36px; height: 36px; border-radius: 10px; box-shadow: 0 6px 20px -6px rgba(99, 102, 241, 0.8); }
.brand span small { display: block; font-size: 11px; font-weight: 600; color: var(--muted-2); letter-spacing: 0.14em; text-transform: uppercase; white-space: nowrap; }

.nav__links { display: flex; align-items: center; gap: 6px; margin-inline-start: auto; }
.nav__link {
  padding: 9px 14px; border-radius: 10px; font-size: 14.5px; font-weight: 600; color: var(--muted);
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}
.nav__link:hover { color: var(--text); background: rgba(148, 163, 184, 0.08); }

.nav__actions { display: flex; align-items: center; gap: 10px; }

.lang-switch {
  display: inline-flex; padding: 3px; border: 1px solid var(--border);
  border-radius: 999px; background: rgba(148, 163, 184, 0.05);
}
.lang-switch button {
  border: 0; background: transparent; color: var(--muted); cursor: pointer;
  font-weight: 700; font-size: 12.5px; letter-spacing: 0.04em;
  padding: 6px 12px; border-radius: 999px; transition: all 0.2s var(--ease);
  font-family: inherit;
}
.lang-switch button[aria-pressed="true"] { background: var(--primary); color: #fff; }

.nav__burger {
  display: none; margin-inline-start: auto;
  width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--border);
  background: rgba(148, 163, 184, 0.05); cursor: pointer; color: var(--text);
  align-items: center; justify-content: center;
}
.nav__burger svg { width: 22px; height: 22px; }

/* ---------------- Hero ---------------- */
.hero { position: relative; padding: clamp(56px, 9vw, 110px) 0 clamp(40px, 6vw, 72px); }
.hero__grid {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.hero__grid > * { min-width: 0; }

.pill-badge {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 7px 15px; border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: rgba(99, 102, 241, 0.1);
  color: #c7d2fe; font-size: 13px; font-weight: 700; letter-spacing: 0.02em;
}
.pill-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 12px var(--cyan); }

.hero h1 {
  font-size: clamp(2.6rem, 7.4vw, 4.6rem);
  font-weight: 800; margin: 22px 0 18px;
}
.grad-text {
  background: linear-gradient(120deg, #a5b4fc 0%, #818cf8 40%, #22d3ee 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero__lead { font-size: clamp(1.05rem, 2.1vw, 1.28rem); color: var(--muted); max-width: 34ch; margin-bottom: 30px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.tag {
  font-size: 12.5px; font-weight: 700; color: var(--muted);
  padding: 7px 13px; border-radius: 999px; border: 1px solid var(--border);
  background: rgba(148, 163, 184, 0.05);
}

/* ---------------- Code / window mockup ---------------- */
.window {
  border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  box-shadow: var(--shadow);
}
.window__bar {
  display: flex; align-items: center; gap: 8px;
  padding: 13px 16px; border-bottom: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.55);
}
.window__dots { display: flex; gap: 6px; flex: 0 0 auto; }
.window__dots i { width: 11px; height: 11px; border-radius: 50%; display: block; }
.window__dots i:nth-child(1) { background: #f87171; }
.window__dots i:nth-child(2) { background: #fbbf24; }
.window__dots i:nth-child(3) { background: #34d399; }
.window__title { font-family: var(--mono); font-size: 12.5px; color: var(--muted-2); margin-inline-start: 8px; }

.code { margin: 0; padding: 20px 22px; overflow-x: auto; max-width: 100%; font-family: var(--mono); font-size: 13.5px; line-height: 1.75; }
.code code { display: block; white-space: pre; }
.code .c-key { color: #c084fc; }
.code .c-fn { color: #60a5fa; }
.code .c-str { color: #34d399; }
.code .c-com { color: #64748b; font-style: italic; }
.code .c-tag { color: #f472b6; }
.code .c-var { color: #fbbf24; }

.hero__visual { position: relative; min-width: 0; }
.hero__visual .window { transform: perspective(1200px) rotateY(-7deg) rotateX(2deg); }
.hero__orb {
  position: absolute; inset: auto -6% -12% auto; width: 60%; height: 60%;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.5), transparent 65%);
  filter: blur(30px); z-index: -1;
}

/* Hero headline + rotating word */
.hero__title { font-size: clamp(2.7rem, 7.6vw, 4.9rem); font-weight: 800; margin: 22px 0 18px; line-height: 1.04; }
.hero__title > span { display: block; }
.rotator { display: inline-block; }
.rotator__word { display: inline-block; transition: opacity 0.32s ease, transform 0.32s ease, filter 0.32s ease; }
.rotator__word.is-out { opacity: 0; transform: translateY(-0.35em); filter: blur(5px); }

/* Hero window: CMS editor fragment */
.hero-win {
  transform: perspective(1300px) rotateY(-6deg) rotateX(1.5deg);
  box-shadow: var(--shadow), 0 0 100px -34px rgba(99, 102, 241, 0.95);
}
.url-bar {
  font-family: var(--mono); font-size: 12px; color: var(--muted-2);
  margin-inline-start: 8px; padding: 4px 12px; border-radius: 999px;
  background: rgba(148, 163, 184, 0.07); border: 1px solid var(--border);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.url-bar b { color: var(--muted); font-weight: 600; }
.save-pill {
  flex: 0 0 auto;
  margin-inline-start: auto; display: inline-flex; align-items: center; gap: 7px;
  font-size: 11.5px; font-weight: 700; color: #a7f3d0;
  background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.32);
  padding: 4px 11px; border-radius: 999px;
}
.save-pill i { width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 10px #34d399; }

.cms { display: grid; grid-template-columns: 56px 1fr; min-height: 300px; }
.cms__rail {
  border-right: 1px solid var(--border); background: rgba(2, 6, 23, 0.45);
  padding: 14px 0; display: flex; flex-direction: column; align-items: center; gap: 7px;
}
.cms__ico {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  color: var(--muted-2); border: 1px solid transparent;
}
.cms__ico svg { width: 17px; height: 17px; }
.cms__ico.is-active { background: rgba(99, 102, 241, 0.16); color: #c7d2fe; border-color: var(--border-strong); }
.cms__canvas { padding: 20px 22px; min-width: 0; }
.cms__crumb { font-size: 12px; color: var(--muted-2); }
.cms__title { font-size: clamp(1.15rem, 2.5vw, 1.55rem); font-weight: 800; margin: 9px 0 16px; }
.cms__toolbar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 18px; }
.tb {
  width: 31px; height: 29px; border-radius: 8px; display: grid; place-items: center;
  border: 1px solid var(--border); background: rgba(148, 163, 184, 0.06);
  font-size: 12px; font-weight: 700; color: var(--muted);
}
.tb svg { width: 15px; height: 15px; }
.tb--b { font-weight: 800; }
.tb--i { font-style: italic; }
.tb--u { text-decoration: underline; }
.tb--sep { width: 1px; height: 20px; border: 0; background: var(--border); }
.tb--active { border-color: var(--border-strong); background: rgba(99, 102, 241, 0.18); color: #c7d2fe; }
.cms__lines { display: flex; flex-direction: column; gap: 9px; margin-bottom: 18px; }
.cms__lines span { display: block; height: 9px; border-radius: 999px; background: linear-gradient(90deg, rgba(148, 163, 184, 0.24), rgba(148, 163, 184, 0.07)); }
.cms__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cms__col { height: 58px; border-radius: 12px; border: 1px dashed var(--border-strong); background: rgba(99, 102, 241, 0.07); }

/* Floating elements over the hero window */
.toast {
  position: absolute; top: -30px; right: -4px; z-index: 2;
  display: flex; align-items: center; gap: 9px; padding: 10px 14px; border-radius: 12px;
  border: 1px solid var(--border); background: rgba(9, 13, 25, 0.92);
  backdrop-filter: blur(10px); box-shadow: var(--shadow);
  font-size: 12.5px; animation: floaty 6s ease-in-out infinite;
}
.toast__dot { width: 8px; height: 8px; border-radius: 50%; background: #34d399; box-shadow: 0 0 10px #34d399; }
.toast__name { font-family: var(--mono); color: var(--text); }
.toast__pill { font-size: 11px; font-weight: 700; color: #a7f3d0; background: rgba(52, 211, 153, 0.14); border: 1px solid rgba(52, 211, 153, 0.35); padding: 2px 8px; border-radius: 999px; }

.chip-code {
  position: absolute; bottom: -16px; left: -14px; z-index: 2;
  font-family: var(--mono); font-size: 12.5px; color: var(--muted);
  background: rgba(9, 13, 25, 0.92); border: 1px solid var(--border);
  border-radius: 12px; padding: 10px 14px; backdrop-filter: blur(10px);
  box-shadow: var(--shadow); animation: floaty 7s ease-in-out infinite reverse;
}
.chip-code .c-p { color: var(--cyan); }
.chip-code .c-s { color: #34d399; }

@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ---------------- Marquee ---------------- */
.marquee {
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 22px 0; overflow: hidden; margin: clamp(36px, 6vw, 70px) 0;
  background: rgba(2, 6, 23, 0.35);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track { display: flex; gap: 44px; width: max-content; animation: marquee 32s linear infinite; }
.marquee__track span {
  font-size: clamp(1rem, 2vw, 1.3rem); font-weight: 800; letter-spacing: -0.01em;
  color: var(--muted-2); white-space: nowrap;
}
.marquee__track span::after { content: "◆"; color: var(--primary); margin-inline-start: 44px; font-size: 0.7em; vertical-align: middle; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------------- Sections ---------------- */
.section { padding: clamp(48px, 8vw, 96px) 0; }
.section__head { max-width: 720px; margin-bottom: clamp(30px, 5vw, 54px); }
.eyebrow {
  font-size: 12.5px; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--primary-hover); display: block; margin-bottom: 14px;
}
.section__head h2 { font-size: clamp(1.8rem, 4.4vw, 2.9rem); font-weight: 800; }
.section__head p { color: var(--muted); font-size: clamp(1rem, 1.8vw, 1.15rem); margin: 16px 0 0; }

/* ---------------- Panel preview ---------------- */
.panel { padding: 0; }
.panel__win { display: grid; grid-template-columns: 220px 1fr; min-height: 360px; }
.panel__win > * { min-width: 0; }
.panel__side { border-right: 1px solid var(--border); background: rgba(2, 6, 23, 0.4); padding: 18px 14px; }
.panel__side .side-brand { display: flex; align-items: center; gap: 9px; font-weight: 800; font-size: 14px; margin-bottom: 18px; padding: 4px 8px; }
.panel__side .side-brand img { width: 26px; height: 26px; border-radius: 8px; }
.side-item {
  display: flex; align-items: center; gap: 11px; padding: 9px 11px; border-radius: 10px;
  color: var(--muted); font-size: 13.5px; font-weight: 600; margin-bottom: 3px;
}
.side-item svg { width: 17px; height: 17px; opacity: 0.85; }
.side-item.is-active { background: rgba(99, 102, 241, 0.16); color: #c7d2fe; border: 1px solid var(--border-strong); }
.panel__main { padding: 22px; }
.panel__main h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.panel__main .sub { font-size: 12.5px; color: var(--muted-2); margin-bottom: 18px; }
.panel__cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.panel__card { border: 1px solid var(--border); border-radius: 12px; padding: 14px; background: rgba(148, 163, 184, 0.04); }
.panel__card b { font-size: 22px; display: block; }
.panel__card small { color: var(--muted-2); font-size: 11.5px; }
.panel__bars { border: 1px solid var(--border); border-radius: 12px; padding: 16px; }
.bar { height: 9px; border-radius: 999px; background: rgba(148, 163, 184, 0.12); margin-bottom: 11px; overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--primary), var(--cyan)); }
.bar:last-child { margin-bottom: 0; }

/* ---------------- Features ---------------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 18px; }
.card {
  position: relative; padding: 26px; border-radius: var(--radius);
  border: 1px solid var(--border); background: linear-gradient(180deg, rgba(19, 28, 49, 0.9), rgba(15, 23, 42, 0.7));
  transition: transform 0.35s var(--ease), border-color 0.35s var(--ease), box-shadow 0.35s var(--ease);
  overflow: hidden;
}
.card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: radial-gradient(340px 160px at var(--mx, 50%) var(--my, 0%), rgba(99, 102, 241, 0.16), transparent 70%);
  opacity: 0; transition: opacity 0.35s var(--ease); pointer-events: none;
}
.card:hover { transform: translateY(-6px); border-color: var(--border-strong); box-shadow: var(--shadow); }
.card:hover::before { opacity: 1; }
.card__icon {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
  background: rgba(99, 102, 241, 0.14); border: 1px solid var(--border-strong); margin-bottom: 16px;
}
.card__icon svg { width: 23px; height: 23px; color: var(--primary-hover); }
.card h3 { font-size: 1.08rem; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 14.5px; margin: 0; }

/* ---------------- How it works ---------------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step { border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; background: rgba(148, 163, 184, 0.03); }
.step__n {
  font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--cyan);
  display: inline-block; margin-bottom: 14px; padding: 4px 10px; border-radius: 8px; border: 1px solid var(--border);
}
.step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 14.5px; margin: 0; }

/* ---------------- Stats ---------------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.stat { text-align: center; padding: 28px 16px; border: 1px solid var(--border); border-radius: var(--radius); background: rgba(148, 163, 184, 0.03); }
.stat b { font-size: clamp(1.9rem, 4vw, 2.7rem); font-weight: 800; display: block; background: linear-gradient(120deg, #a5b4fc, #22d3ee); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat span { color: var(--muted); font-size: 13.5px; }

/* ---------------- Quick start ---------------- */
.start { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(24px, 4vw, 48px); align-items: center; }
.start > * { min-width: 0; }
.term-list { list-style: none; margin: 0; padding: 0; counter-reset: s; }
.term-list li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px dashed var(--border); }
.term-list li:last-child { border-bottom: 0; }
.term-list .k {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: rgba(99, 102, 241, 0.14); border: 1px solid var(--border-strong);
  font-weight: 800; font-size: 13.5px; color: var(--primary-hover);
}
.term-list p { margin: 0; color: var(--muted); font-size: 14.5px; }
.term-list b { color: var(--text); }

.window--term .window__title { color: var(--muted); }
.copy-btn {
  margin-inline-start: auto; border: 1px solid var(--border); background: rgba(148, 163, 184, 0.06);
  color: var(--muted); font-family: var(--font); font-size: 12px; font-weight: 700;
  padding: 5px 11px; border-radius: 8px; cursor: pointer; transition: all 0.2s var(--ease);
}
.copy-btn:hover { color: var(--text); border-color: var(--primary-hover); }
.copy-btn.is-done { color: #34d399; border-color: #34d399; }
.term { font-family: var(--mono); font-size: 13.5px; line-height: 2; padding: 20px 22px; white-space: pre-wrap; word-break: break-word; }
.term .prompt { color: var(--cyan); }
.term .comment { color: var(--muted-2); }

/* ---------------- Docs tiles ---------------- */
.docs-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; }
.doc-tile {
  display: block; padding: 22px; border-radius: var(--radius); border: 1px solid var(--border);
  background: rgba(148, 163, 184, 0.03); transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.doc-tile:hover { transform: translateY(-4px); border-color: var(--border-strong); background: rgba(99, 102, 241, 0.08); }
.doc-tile b { display: block; font-size: 1.02rem; margin-bottom: 6px; }
.doc-tile span { color: var(--muted); font-size: 13.5px; }
.doc-tile .arrow { color: var(--primary-hover); font-weight: 800; }

/* ---------------- Final CTA ---------------- */
.cta {
  position: relative; text-align: center; padding: clamp(44px, 7vw, 84px) 26px;
  border-radius: 28px; border: 1px solid var(--border-strong);
  background:
    radial-gradient(60% 120% at 50% 0%, rgba(99, 102, 241, 0.25), transparent 70%),
    linear-gradient(180deg, rgba(19, 28, 49, 0.9), rgba(9, 13, 25, 0.9));
  overflow: hidden;
}
.cta h2 { font-size: clamp(1.9rem, 5vw, 3.1rem); font-weight: 800; }
.cta p { color: var(--muted); max-width: 52ch; margin: 16px auto 30px; font-size: 1.05rem; }
.cta .hero__cta { justify-content: center; }

/* ---------------- Footer ---------------- */
.footer { border-top: 1px solid var(--border); margin-top: clamp(56px, 8vw, 110px); padding: 46px 0 34px; background: rgba(2, 6, 23, 0.5); }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 28px; }
.footer p { color: var(--muted); font-size: 14px; max-width: 40ch; }
.footer h4 { font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.16em; color: var(--muted-2); margin: 0 0 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 9px; }
.footer a { color: var(--muted); font-size: 14px; transition: color 0.2s var(--ease); }
.footer a:hover { color: var(--text); }
.footer__bottom { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; margin-top: 36px; padding-top: 22px; border-top: 1px solid var(--border); color: var(--muted-2); font-size: 13px; }

/* ---------------- Reveal on scroll ---------------- */
[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
[data-reveal].is-visible { opacity: 1; transform: none; }
[data-reveal][data-delay="1"] { transition-delay: 0.08s; }
[data-reveal][data-delay="2"] { transition-delay: 0.16s; }
[data-reveal][data-delay="3"] { transition-delay: 0.24s; }

/* ---------------- Responsive ---------------- */
@media (max-width: 980px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual .window { transform: none; }
  .cms__canvas { padding: 16px; }
  .panel__win { grid-template-columns: 1fr; }
  .panel__side { display: none; }
  .start { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .nav__links { display: none; }
  .nav__burger { display: inline-flex; }
  .nav__actions { margin-inline-start: auto; }
  .nav__actions .lang-switch { display: inline-flex; }
  .nav__actions .btn span { display: none; }
  .nav__actions .btn { padding: 12px 14px; }
  .brand small { display: none; }
  .nav__inner { gap: 10px; }

  .nav.is-open .nav__links {
    display: flex; flex-direction: column; align-items: stretch; gap: 4px;
    position: absolute; left: 0; right: 0; top: 72px;
    padding: 14px 22px 20px;
    background: rgba(7, 11, 21, 0.98); border-bottom: 1px solid var(--border);
    backdrop-filter: blur(14px);
  }
  .nav.is-open .nav__link { padding: 13px 12px; font-size: 16px; }

  .panel__cards { grid-template-columns: 1fr 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .toast, .chip-code { display: none; }
}

@media (max-width: 760px) {
  .brand { font-size: 16px; gap: 9px; }
  .brand img { width: 32px; height: 32px; }
  .nav__actions { gap: 6px; }
  .nav__inner { gap: 8px; }
}

@media (max-width: 520px) {
  .hero__cta .btn { width: 100%; justify-content: center; }
  .lang-switch button, .lang-switch a { padding: 6px 9px; }
  .brand span { display: none; }
  .brand img { width: 34px; height: 34px; }
  .nav__actions .btn { padding: 10px 12px; }
}

/* Language visibility: elements specific to one language only */
[data-lang-only] { display: none; }
html[lang="pl"] [data-lang-only="pl"] { display: revert; }
html[lang="en"] [data-lang-only="en"] { display: revert; }

/* =============================================================
   Multi-page project site: subpage hero, docs layout, prose
   ============================================================= */

.nav__link.is-active {
  color: var(--text);
  background: rgba(99, 102, 241, 0.16);
  box-shadow: inset 0 0 0 1px var(--border-strong);
}

.lang-switch a {
  border: 0; background: transparent; color: var(--muted); cursor: pointer;
  font-weight: 700; font-size: 12.5px; letter-spacing: 0.04em;
  padding: 6px 12px; border-radius: 999px; transition: all 0.2s var(--ease);
  font-family: inherit; text-decoration: none;
}
.lang-switch a:hover { color: var(--text); }
.lang-switch a[aria-current="true"] { background: var(--primary); color: #fff; }

.page-hero { padding: clamp(48px, 8vw, 92px) 0 clamp(18px, 3vw, 32px); }
.page-hero h1 { font-size: clamp(2.1rem, 5.4vw, 3.7rem); font-weight: 800; margin: 14px 0 18px; }
.page-hero p { color: var(--muted); max-width: 68ch; font-size: clamp(1rem, 1.8vw, 1.18rem); margin: 0; }

.section__more { margin-top: 28px; }

.download-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 48px); align-items: start; }
.download-grid h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin: 10px 0 20px; }

.req-list { list-style: none; margin: 0; padding: 0; }
.req-list li {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 13px 0; border-bottom: 1px dashed var(--border); color: var(--muted); font-size: 14.5px;
}
.req-list li:last-child { border-bottom: 0; }
.req-list li::before { content: "✓"; color: var(--cyan); font-weight: 800; flex: 0 0 auto; }

.plugin-card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.plugin-card__top .card__icon { margin-bottom: 0; }
.plugin-card h3 { margin-top: 0; }

/* ---------------- Documentation layout ---------------- */
.docs-layout {
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr) 230px;
  gap: clamp(22px, 3vw, 40px);
  align-items: start;
  padding-top: clamp(34px, 5vw, 58px);
  padding-bottom: clamp(48px, 7vw, 90px);
}

.docs-sidebar {
  position: sticky; top: 92px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(19, 28, 49, 0.85), rgba(15, 23, 42, 0.65));
  padding: 16px;
}
.docs-sidebar__title {
  font-size: 11.5px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted-2); padding: 4px 10px 12px;
}
.docs-nav { display: flex; flex-direction: column; gap: 2px; }
.docs-nav a {
  display: block; padding: 9px 11px; border-radius: 9px;
  color: var(--muted); font-size: 14px; font-weight: 600;
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}
.docs-nav a:hover { color: var(--text); background: rgba(148, 163, 184, 0.08); }
.docs-nav a.is-active { color: #c7d2fe; background: rgba(99, 102, 241, 0.16); box-shadow: inset 0 0 0 1px var(--border-strong); }
.docs-sidebar__edit {
  display: block; margin-top: 14px; padding: 10px 11px 2px;
  border-top: 1px solid var(--border); color: var(--primary-hover);
  font-size: 12.5px; font-weight: 700;
}
.docs-sidebar__edit:hover { color: var(--text); }

.docs-content { min-width: 0; }
.docs-title { font-size: clamp(1.9rem, 4.6vw, 2.9rem); font-weight: 800; margin: 0 0 10px; }
.docs-lead { color: var(--muted); font-size: clamp(1rem, 1.8vw, 1.1rem); margin: 0 0 26px; max-width: 65ch; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; font-size: 12.5px; color: var(--muted-2); margin-bottom: 16px; }
.breadcrumbs a:hover { color: var(--text); }
.breadcrumbs span:last-child { color: var(--muted); }

.docs-toc { position: sticky; top: 92px; font-size: 12.5px; max-height: calc(100vh - 112px); overflow-y: auto; padding-right: 4px; }
.docs-toc::-webkit-scrollbar { width: 5px; }
.docs-toc::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 999px; }
.docs-toc__title { font-size: 11.5px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted-2); margin-bottom: 12px; }
.docs-toc a {
  display: block; padding: 4px 0 4px 11px; color: var(--muted); line-height: 1.45;
  border-left: 1px solid var(--border); transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.docs-toc a:hover { color: var(--text); border-color: var(--primary); }
.docs-toc .toc-level-3 { padding-left: 22px; font-size: 12px; }

.docs-hub__title { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: 22px; }
.docs-hub { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; }
.docs-hub__card .doc-tile__icon {
  width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(99, 102, 241, 0.14); border: 1px solid var(--border-strong);
  color: var(--primary-hover); margin-bottom: 14px;
}
.docs-hub__card .doc-tile__icon svg { width: 21px; height: 21px; }

/* ---------------- Prose (rendered docs) ---------------- */
.prose { color: #cbd5e1; font-size: 15.5px; line-height: 1.78; }
.prose > :first-child { margin-top: 0; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--text); scroll-margin-top: 92px; letter-spacing: -0.01em; }
.prose h1 { font-size: clamp(1.8rem, 4vw, 2.5rem); margin: 0 0 0.6em; }
.prose h2 { font-size: clamp(1.35rem, 2.6vw, 1.7rem); margin: 2.1em 0 0.6em; padding-top: 0.55em; border-top: 1px solid var(--border); }
.prose h3 { font-size: 1.18rem; margin: 1.7em 0 0.5em; }
.prose h4 { font-size: 1.03rem; margin: 1.4em 0 0.4em; }
.prose p { margin: 0.9em 0; }
.prose a { color: var(--primary-hover); text-decoration: underline; text-underline-offset: 2px; }
.prose a:hover { color: #c7d2fe; }
.prose ul, .prose ol { padding-left: 1.45em; margin: 0.9em 0; }
.prose li { margin: 0.35em 0; }
.prose li > ul, .prose li > ol { margin: 0.3em 0; }
.prose strong { color: var(--text); }
.prose code {
  font-family: var(--mono); font-size: 0.87em;
  background: rgba(148, 163, 184, 0.12); border: 1px solid var(--border);
  border-radius: 6px; padding: 0.12em 0.4em; word-break: break-word;
}
.prose pre {
  position: relative; margin: 1.25em 0; padding: 18px 18px;
  background: #070b15; border: 1px solid var(--border); border-radius: 14px;
  overflow-x: auto; box-shadow: var(--shadow);
}
.prose pre code { background: none; border: 0; padding: 0; font-size: 13px; line-height: 1.75; }
.prose pre .copy-btn {
  position: absolute; top: 9px; right: 9px; opacity: 0; z-index: 2;
  background: rgba(15, 23, 42, 0.92);
}
.prose pre:hover .copy-btn, .prose pre .copy-btn:focus { opacity: 1; }
.prose blockquote {
  margin: 1.2em 0; padding: 12px 18px;
  border-left: 3px solid var(--primary); background: rgba(99, 102, 241, 0.08);
  border-radius: 0 10px 10px 0; color: var(--muted);
}
.prose blockquote p { margin: 0.35em 0; }
.prose hr { border: 0; border-top: 1px solid var(--border); margin: 2em 0; }
.prose img { border-radius: 12px; border: 1px solid var(--border); }
.prose .table-wrap { overflow-x: auto; margin: 1.3em 0; border: 1px solid var(--border); border-radius: 12px; }
.prose .table-wrap table { border-collapse: collapse; width: 100%; min-width: 520px; margin: 0; }
.prose th, .prose td { border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); padding: 9px 13px; text-align: left; vertical-align: top; }
.prose th { background: rgba(148, 163, 184, 0.08); color: var(--text); font-size: 13px; }
.prose tr:last-child td { border-bottom: 0; }
.prose th:last-child, .prose td:last-child { border-right: 0; }
.prose .callout {
  padding: 13px 16px; border-radius: 12px;
  background: rgba(34, 211, 238, 0.08); border: 1px solid rgba(34, 211, 238, 0.25);
  color: #a5f3fc; font-size: 13.5px;
}

.docs-pager { display: flex; gap: 14px; justify-content: space-between; margin: 48px 0 6px; }
.docs-pager a {
  flex: 1 1 0; min-width: 0; display: block; padding: 14px 16px;
  border: 1px solid var(--border); border-radius: 12px;
  background: rgba(148, 163, 184, 0.03);
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease), transform 0.2s var(--ease);
}
.docs-pager a:hover { border-color: var(--border-strong); background: rgba(99, 102, 241, 0.08); transform: translateY(-2px); }
.docs-pager small { display: block; color: var(--muted-2); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 4px; }
.docs-pager b { display: block; font-size: 14px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.docs-pager__next { text-align: right; }

@media (max-width: 1100px) {
  .docs-layout { grid-template-columns: 230px minmax(0, 1fr); }
  .docs-toc { display: none; }
}

@media (max-width: 860px) {
  .docs-layout { grid-template-columns: 1fr; padding-top: 26px; }
  .docs-sidebar { position: static; }
  .docs-nav { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
  .download-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .docs-pager { flex-direction: column; }
  .docs-pager__next { text-align: left; }
  .page-hero { padding-top: 38px; }
  .prose pre .copy-btn { opacity: 1; }
}

/* ---------------- Reduced motion ---------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .marquee__track { animation: none; }
  [data-reveal] { opacity: 1; transform: none; }
}
